Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(173)

Side by Side Diff: Source/core/inspector/InspectorDOMAgent.h

Issue 397303002: DevTools: [Elements] Implement shortcut-based node cut-copy-pasting (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Make DOMAgent.copyTo hidden Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2009 Apple Inc. All rights reserved.
3 * Copyright (C) 2011 Google Inc. All rights reserved. 3 * Copyright (C) 2011 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 virtual void setInspectModeEnabled(ErrorString*, bool enabled, const bool* i nspectUAShadowDOM, const RefPtr<JSONObject>* highlightConfig) OVERRIDE; 136 virtual void setInspectModeEnabled(ErrorString*, bool enabled, const bool* i nspectUAShadowDOM, const RefPtr<JSONObject>* highlightConfig) OVERRIDE;
137 virtual void requestNode(ErrorString*, const String& objectId, int* nodeId) OVERRIDE; 137 virtual void requestNode(ErrorString*, const String& objectId, int* nodeId) OVERRIDE;
138 virtual void pushNodeByPathToFrontend(ErrorString*, const String& path, int* nodeId) OVERRIDE; 138 virtual void pushNodeByPathToFrontend(ErrorString*, const String& path, int* nodeId) OVERRIDE;
139 virtual void pushNodesByBackendIdsToFrontend(ErrorString*, const RefPtr<JSON Array>& nodeIds, RefPtr<TypeBuilder::Array<int> >&) OVERRIDE; 139 virtual void pushNodesByBackendIdsToFrontend(ErrorString*, const RefPtr<JSON Array>& nodeIds, RefPtr<TypeBuilder::Array<int> >&) OVERRIDE;
140 virtual void hideHighlight(ErrorString*) OVERRIDE; 140 virtual void hideHighlight(ErrorString*) OVERRIDE;
141 virtual void highlightRect(ErrorString*, int x, int y, int width, int height , const RefPtr<JSONObject>* color, const RefPtr<JSONObject>* outlineColor) OVERR IDE; 141 virtual void highlightRect(ErrorString*, int x, int y, int width, int height , const RefPtr<JSONObject>* color, const RefPtr<JSONObject>* outlineColor) OVERR IDE;
142 virtual void highlightQuad(ErrorString*, const RefPtr<JSONArray>& quad, cons t RefPtr<JSONObject>* color, const RefPtr<JSONObject>* outlineColor) OVERRIDE; 142 virtual void highlightQuad(ErrorString*, const RefPtr<JSONArray>& quad, cons t RefPtr<JSONObject>* color, const RefPtr<JSONObject>* outlineColor) OVERRIDE;
143 virtual void highlightNode(ErrorString*, const RefPtr<JSONObject>& highlight Config, const int* nodeId, const String* objectId) OVERRIDE; 143 virtual void highlightNode(ErrorString*, const RefPtr<JSONObject>& highlight Config, const int* nodeId, const String* objectId) OVERRIDE;
144 virtual void highlightFrame(ErrorString*, const String& frameId, const RefPt r<JSONObject>* color, const RefPtr<JSONObject>* outlineColor) OVERRIDE; 144 virtual void highlightFrame(ErrorString*, const String& frameId, const RefPt r<JSONObject>* color, const RefPtr<JSONObject>* outlineColor) OVERRIDE;
145 145
146 virtual void copyTo(ErrorString*, int nodeId, int targetElementId, const int * const anchorNodeId, int* newNodeId) OVERRIDE;
146 virtual void moveTo(ErrorString*, int nodeId, int targetNodeId, const int* a nchorNodeId, int* newNodeId) OVERRIDE; 147 virtual void moveTo(ErrorString*, int nodeId, int targetNodeId, const int* a nchorNodeId, int* newNodeId) OVERRIDE;
147 virtual void undo(ErrorString*) OVERRIDE; 148 virtual void undo(ErrorString*) OVERRIDE;
148 virtual void redo(ErrorString*) OVERRIDE; 149 virtual void redo(ErrorString*) OVERRIDE;
149 virtual void markUndoableState(ErrorString*) OVERRIDE; 150 virtual void markUndoableState(ErrorString*) OVERRIDE;
150 virtual void focus(ErrorString*, int nodeId) OVERRIDE; 151 virtual void focus(ErrorString*, int nodeId) OVERRIDE;
151 virtual void setFileInputFiles(ErrorString*, int nodeId, const RefPtr<JSONAr ray>& files) OVERRIDE; 152 virtual void setFileInputFiles(ErrorString*, int nodeId, const RefPtr<JSONAr ray>& files) OVERRIDE;
152 virtual void getBoxModel(ErrorString*, int nodeId, RefPtr<TypeBuilder::DOM:: BoxModel>&) OVERRIDE; 153 virtual void getBoxModel(ErrorString*, int nodeId, RefPtr<TypeBuilder::DOM:: BoxModel>&) OVERRIDE;
153 virtual void getNodeForLocation(ErrorString*, int x, int y, int* nodeId) OVE RRIDE; 154 virtual void getNodeForLocation(ErrorString*, int x, int y, int* nodeId) OVE RRIDE;
154 virtual void getRelayoutBoundary(ErrorString*, int nodeId, int* relayoutBoun daryNodeId) OVERRIDE; 155 virtual void getRelayoutBoundary(ErrorString*, int nodeId, int* relayoutBoun daryNodeId) OVERRIDE;
155 156
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 224
224 void setSearchingForNode(ErrorString*, SearchMode, JSONObject* highlightConf ig); 225 void setSearchingForNode(ErrorString*, SearchMode, JSONObject* highlightConf ig);
225 PassOwnPtr<HighlightConfig> highlightConfigFromInspectorObject(ErrorString*, JSONObject* highlightInspectorObject); 226 PassOwnPtr<HighlightConfig> highlightConfigFromInspectorObject(ErrorString*, JSONObject* highlightInspectorObject);
226 227
227 // Node-related methods. 228 // Node-related methods.
228 typedef WillBeHeapHashMap<RefPtrWillBeMember<Node>, int> NodeToIdMap; 229 typedef WillBeHeapHashMap<RefPtrWillBeMember<Node>, int> NodeToIdMap;
229 int bind(Node*, NodeToIdMap*); 230 int bind(Node*, NodeToIdMap*);
230 void unbind(Node*, NodeToIdMap*); 231 void unbind(Node*, NodeToIdMap*);
231 232
232 Node* assertEditableNode(ErrorString*, int nodeId); 233 Node* assertEditableNode(ErrorString*, int nodeId);
234 Node* assertEditableChildNode(ErrorString*, Element* parentElement, int node Id);
233 Element* assertEditableElement(ErrorString*, int nodeId); 235 Element* assertEditableElement(ErrorString*, int nodeId);
234 236
235 void inspect(Node*); 237 void inspect(Node*);
236 238
237 int pushNodePathToFrontend(Node*); 239 int pushNodePathToFrontend(Node*);
238 void pushChildNodesToFrontend(int nodeId, int depth = 1); 240 void pushChildNodesToFrontend(int nodeId, int depth = 1);
239 241
240 void invalidateFrameOwnerElement(LocalFrame*); 242 void invalidateFrameOwnerElement(LocalFrame*);
241 243
242 bool hasBreakpoint(Node*, int type); 244 bool hasBreakpoint(Node*, int type);
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 OwnPtrWillBeMember<InspectorHistory> m_history; 282 OwnPtrWillBeMember<InspectorHistory> m_history;
281 OwnPtrWillBeMember<DOMEditor> m_domEditor; 283 OwnPtrWillBeMember<DOMEditor> m_domEditor;
282 bool m_suppressAttributeModifiedEvent; 284 bool m_suppressAttributeModifiedEvent;
283 RawPtrWillBeMember<Listener> m_listener; 285 RawPtrWillBeMember<Listener> m_listener;
284 }; 286 };
285 287
286 288
287 } // namespace blink 289 } // namespace blink
288 290
289 #endif // !defined(InspectorDOMAgent_h) 291 #endif // !defined(InspectorDOMAgent_h)
OLDNEW
« no previous file with comments | « no previous file | Source/core/inspector/InspectorDOMAgent.cpp » ('j') | Source/core/inspector/InspectorDOMAgent.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698