InspectorFrontendClientLocal.h [plain text]
#ifndef InspectorFrontendClientLocal_h
#define InspectorFrontendClientLocal_h
#include "InspectorFrontendClient.h"
#include "ScriptState.h"
#include <wtf/Forward.h>
#include <wtf/Noncopyable.h>
namespace WebCore {
class InspectorController;
class InspectorFrontendHost;
class Page;
class InspectorFrontendClientLocal : public InspectorFrontendClient {
WTF_MAKE_NONCOPYABLE(InspectorFrontendClientLocal); WTF_MAKE_FAST_ALLOCATED;
public:
class Settings {
public:
Settings() { }
virtual ~Settings() { }
virtual String getProperty(const String& name);
virtual void setProperty(const String& name, const String& value);
};
InspectorFrontendClientLocal(InspectorController*, Page*, PassOwnPtr<Settings>);
virtual ~InspectorFrontendClientLocal();
virtual void windowObjectCleared();
virtual void frontendLoaded();
virtual void moveWindowBy(float x, float y);
virtual void requestAttachWindow();
virtual void requestDetachWindow();
virtual void changeAttachedWindowHeight(unsigned);
virtual bool canAttachWindow();
virtual void saveAs(const String&, const String&) { }
virtual void attachWindow() = 0;
virtual void detachWindow() = 0;
virtual void sendMessageToBackend(const String& message);
static unsigned constrainedAttachedWindowHeight(unsigned preferredHeight, unsigned totalWindowHeight);
protected:
virtual void setAttachedWindowHeight(unsigned) = 0;
void setAttachedWindow(bool);
void restoreAttachedWindowHeight();
private:
friend class FrontendMenuProvider;
InspectorController* m_inspectorController;
Page* m_frontendPage;
ScriptState* m_frontendScriptState;
RefPtr<InspectorFrontendHost> m_frontendHost;
OwnPtr<InspectorFrontendClientLocal::Settings> m_settings;
};
}
#endif