| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 59 public: | 59 public: |
| 60 static PassOwnPtr<InspectorDOMDebuggerAgent> create(InstrumentingAgents*, In
spectorState*, InspectorDOMAgent*, InspectorDebuggerAgent*, InspectorAgent*); | 60 static PassOwnPtr<InspectorDOMDebuggerAgent> create(InstrumentingAgents*, In
spectorState*, InspectorDOMAgent*, InspectorDebuggerAgent*, InspectorAgent*); |
| 61 | 61 |
| 62 virtual ~InspectorDOMDebuggerAgent(); | 62 virtual ~InspectorDOMDebuggerAgent(); |
| 63 | 63 |
| 64 // DOMDebugger API for InspectorFrontend | 64 // DOMDebugger API for InspectorFrontend |
| 65 void setXHRBreakpoint(ErrorString*, const String& url); | 65 void setXHRBreakpoint(ErrorString*, const String& url); |
| 66 void removeXHRBreakpoint(ErrorString*, const String& url); | 66 void removeXHRBreakpoint(ErrorString*, const String& url); |
| 67 void setEventListenerBreakpoint(ErrorString*, const String& eventName); | 67 void setEventListenerBreakpoint(ErrorString*, const String& eventName); |
| 68 void removeEventListenerBreakpoint(ErrorString*, const String& eventName); | 68 void removeEventListenerBreakpoint(ErrorString*, const String& eventName); |
| 69 void setInstrumentationBreakpoint(ErrorString*, const String& eventName); |
| 70 void removeInstrumentationBreakpoint(ErrorString*, const String& eventName); |
| 69 void setDOMBreakpoint(ErrorString*, int nodeId, const String& type); | 71 void setDOMBreakpoint(ErrorString*, int nodeId, const String& type); |
| 70 void removeDOMBreakpoint(ErrorString*, int nodeId, const String& type); | 72 void removeDOMBreakpoint(ErrorString*, int nodeId, const String& type); |
| 71 | 73 |
| 72 // InspectorInstrumentation API | 74 // InspectorInstrumentation API |
| 73 void willInsertDOMNode(Node*, Node* parent); | 75 void willInsertDOMNode(Node*, Node* parent); |
| 74 void didInvalidateStyleAttr(Node*); | 76 void didInvalidateStyleAttr(Node*); |
| 75 void didInsertDOMNode(Node*); | 77 void didInsertDOMNode(Node*); |
| 76 void willRemoveDOMNode(Node*); | 78 void willRemoveDOMNode(Node*); |
| 77 void didRemoveDOMNode(Node*); | 79 void didRemoveDOMNode(Node*); |
| 78 void willModifyDOMAttr(Element*); | 80 void willModifyDOMAttr(Element*); |
| 79 void willSendXMLHttpRequest(const String& url); | 81 void willSendXMLHttpRequest(const String& url); |
| 80 void pauseOnNativeEventIfNeeded(const String& categoryType, const String& ev
entName, bool synchronous); | 82 void pauseOnNativeEventIfNeeded(bool isDOMEvent, const String& eventName, bo
ol synchronous); |
| 81 | 83 |
| 82 virtual void clearFrontend(); | 84 virtual void clearFrontend(); |
| 83 virtual void discardAgent(); | 85 virtual void discardAgent(); |
| 84 | 86 |
| 85 private: | 87 private: |
| 86 InspectorDOMDebuggerAgent(InstrumentingAgents*, InspectorState*, InspectorDO
MAgent*, InspectorDebuggerAgent*, InspectorAgent*); | 88 InspectorDOMDebuggerAgent(InstrumentingAgents*, InspectorState*, InspectorDO
MAgent*, InspectorDebuggerAgent*, InspectorAgent*); |
| 87 | 89 |
| 88 // InspectorDebuggerAgent::Listener implementation. | 90 // InspectorDebuggerAgent::Listener implementation. |
| 89 virtual void debuggerWasEnabled(); | 91 virtual void debuggerWasEnabled(); |
| 90 virtual void debuggerWasDisabled(); | 92 virtual void debuggerWasDisabled(); |
| 91 void disable(); | 93 void disable(); |
| 92 | 94 |
| 93 void descriptionForDOMEvent(Node* target, int breakpointType, bool insertion
, InspectorObject* description); | 95 void descriptionForDOMEvent(Node* target, int breakpointType, bool insertion
, InspectorObject* description); |
| 94 void updateSubtreeBreakpoints(Node*, uint32_t rootMask, bool set); | 96 void updateSubtreeBreakpoints(Node*, uint32_t rootMask, bool set); |
| 95 bool hasBreakpoint(Node*, int type); | 97 bool hasBreakpoint(Node*, int type); |
| 96 void discardBindings(); | 98 void discardBindings(); |
| 99 void setBreakpoint(ErrorString*, const String& eventName); |
| 100 void removeBreakpoint(ErrorString*, const String& eventName); |
| 97 | 101 |
| 98 void clear(); | 102 void clear(); |
| 99 | 103 |
| 100 InspectorDOMAgent* m_domAgent; | 104 InspectorDOMAgent* m_domAgent; |
| 101 InspectorDebuggerAgent* m_debuggerAgent; | 105 InspectorDebuggerAgent* m_debuggerAgent; |
| 102 InspectorAgent* m_inspectorAgent; | 106 InspectorAgent* m_inspectorAgent; |
| 103 HashMap<Node*, uint32_t> m_domBreakpoints; | 107 HashMap<Node*, uint32_t> m_domBreakpoints; |
| 104 }; | 108 }; |
| 105 | 109 |
| 106 } // namespace WebCore | 110 } // namespace WebCore |
| 107 | 111 |
| 108 #endif // ENABLE(JAVASCRIPT_DEBUGGER) && ENABLE(INSPECTOR) | 112 #endif // ENABLE(JAVASCRIPT_DEBUGGER) && ENABLE(INSPECTOR) |
| 109 | 113 |
| 110 #endif // !defined(InspectorDOMDebuggerAgent_h) | 114 #endif // !defined(InspectorDOMDebuggerAgent_h) |
| OLD | NEW |