Upstream version 9.38.198.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / Source / core / inspector / InspectorFrontendHost.h
index 47e8f48..e85cd1a 100644 (file)
 #ifndef InspectorFrontendHost_h
 #define InspectorFrontendHost_h
 
-#include "bindings/v8/ScriptWrappable.h"
-#include "core/platform/ContextMenu.h"
+#include "bindings/core/v8/ScriptWrappable.h"
 #include "wtf/RefCounted.h"
 #include "wtf/Vector.h"
 #include "wtf/text/WTFString.h"
 
-namespace WebCore {
+namespace blink {
 
 class ContextMenuItem;
-class DOMFileSystem;
 class Event;
 class FrontendMenuProvider;
 class InspectorFrontendClient;
 class Page;
 
-class InspectorFrontendHost : public RefCounted<InspectorFrontendHost>, public ScriptWrappable {
+class InspectorFrontendHost : public RefCountedWillBeGarbageCollectedFinalized<InspectorFrontendHost>, public ScriptWrappable {
 public:
-    static PassRefPtr<InspectorFrontendHost> create(InspectorFrontendClient* client, Page* frontendPage)
+    static PassRefPtrWillBeRawPtr<InspectorFrontendHost> create(InspectorFrontendClient* client, Page* frontendPage)
     {
-        return adoptRef(new InspectorFrontendHost(client, frontendPage));
+        return adoptRefWillBeNoop(new InspectorFrontendHost(client, frontendPage));
     }
 
     ~InspectorFrontendHost();
+    void trace(Visitor*);
     void disconnectClient();
 
-    void closeWindow();
     void setZoomFactor(float);
-    void inspectedURLChanged(const String&);
+    float zoomFactor();
 
     void setInjectedScriptForOrigin(const String& origin, const String& script);
 
@@ -64,25 +62,27 @@ public:
 
     // Called from [Custom] implementations.
     void showContextMenu(Event*, const Vector<ContextMenuItem>& items);
+    void showContextMenu(Page*, float x, float y, const Vector<ContextMenuItem>& items);
     void sendMessageToBackend(const String& message);
     void sendMessageToEmbedder(const String& message);
 
     String getSelectionBackgroundColor();
     String getSelectionForegroundColor();
 
-    PassRefPtr<DOMFileSystem> isolatedFileSystem(const String& fileSystemName, const String& rootURL);
-
     bool isUnderTest();
+    bool isHostedMode();
+
+    Page* frontendPage() { return m_frontendPage; }
 
 private:
     friend class FrontendMenuProvider;
     InspectorFrontendHost(InspectorFrontendClient* client, Page* frontendPage);
 
     InspectorFrontendClient* m_client;
-    Page* m_frontendPage;
+    RawPtrWillBeMember<Page> m_frontendPage;
     FrontendMenuProvider* m_menuProvider;
 };
 
-} // namespace WebCore
+} // namespace blink
 
 #endif // !defined(InspectorFrontendHost_h)