| 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 | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 544 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 555 overlayPageHTMLResource.data(), overlayPageHTMLResource.size()); | 555 overlayPageHTMLResource.data(), overlayPageHTMLResource.size()); |
| 556 loader.load(FrameLoadRequest( | 556 loader.load(FrameLoadRequest( |
| 557 0, blankURL(), SubstituteData(data, "text/html", "UTF-8", KURL(), | 557 0, blankURL(), SubstituteData(data, "text/html", "UTF-8", KURL(), |
| 558 ForceSynchronousLoad))); | 558 ForceSynchronousLoad))); |
| 559 v8::Isolate* isolate = toIsolate(frame); | 559 v8::Isolate* isolate = toIsolate(frame); |
| 560 ScriptState* scriptState = ScriptState::forMainWorld(frame); | 560 ScriptState* scriptState = ScriptState::forMainWorld(frame); |
| 561 DCHECK(scriptState); | 561 DCHECK(scriptState); |
| 562 ScriptState::Scope scope(scriptState); | 562 ScriptState::Scope scope(scriptState); |
| 563 v8::Local<v8::Object> global = scriptState->context()->Global(); | 563 v8::Local<v8::Object> global = scriptState->context()->Global(); |
| 564 v8::Local<v8::Value> overlayHostObj = | 564 v8::Local<v8::Value> overlayHostObj = |
| 565 toV8(m_overlayHost.get(), global, isolate); | 565 ToV8(m_overlayHost.get(), global, isolate); |
| 566 DCHECK(!overlayHostObj.IsEmpty()); | 566 DCHECK(!overlayHostObj.IsEmpty()); |
| 567 global | 567 global |
| 568 ->Set(scriptState->context(), | 568 ->Set(scriptState->context(), |
| 569 v8AtomicString(isolate, "InspectorOverlayHost"), overlayHostObj) | 569 v8AtomicString(isolate, "InspectorOverlayHost"), overlayHostObj) |
| 570 .ToChecked(); | 570 .ToChecked(); |
| 571 | 571 |
| 572 #if OS(WIN) | 572 #if OS(WIN) |
| 573 evaluateInOverlay("setPlatform", "windows"); | 573 evaluateInOverlay("setPlatform", "windows"); |
| 574 #elif OS(MACOSX) | 574 #elif OS(MACOSX) |
| 575 evaluateInOverlay("setPlatform", "mac"); | 575 evaluateInOverlay("setPlatform", "mac"); |
| (...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 785 bool InspectorOverlay::shouldSearchForNode() { | 785 bool InspectorOverlay::shouldSearchForNode() { |
| 786 return m_inspectMode != InspectorDOMAgent::NotSearching; | 786 return m_inspectMode != InspectorDOMAgent::NotSearching; |
| 787 } | 787 } |
| 788 | 788 |
| 789 void InspectorOverlay::inspect(Node* node) { | 789 void InspectorOverlay::inspect(Node* node) { |
| 790 if (m_domAgent) | 790 if (m_domAgent) |
| 791 m_domAgent->inspect(node); | 791 m_domAgent->inspect(node); |
| 792 } | 792 } |
| 793 | 793 |
| 794 } // namespace blink | 794 } // namespace blink |
| OLD | NEW |