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

Side by Side Diff: public/web/WebDevToolsAgentClient.h

Issue 23187005: [DevTools] Use device metrics emulation implemented in content. (Closed) Base URL: svn://svn.chromium.org/blink/trunk/
Patch Set: Moved input events adjustments to Blink Created 7 years, 2 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 Google Inc. All rights reserved. 2 * Copyright (C) 2009 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 19 matching lines...) Expand all
30 30
31 #ifndef WebDevToolsAgentClient_h 31 #ifndef WebDevToolsAgentClient_h
32 #define WebDevToolsAgentClient_h 32 #define WebDevToolsAgentClient_h
33 33
34 #include "../platform/WebCString.h" 34 #include "../platform/WebCString.h"
35 #include "../platform/WebCommon.h" 35 #include "../platform/WebCommon.h"
36 36
37 namespace WebKit { 37 namespace WebKit {
38 class WebString; 38 class WebString;
39 struct WebDevToolsMessageData; 39 struct WebDevToolsMessageData;
40 struct WebRect;
41 struct WebSize;
40 42
41 class WebDevToolsAgentClient { 43 class WebDevToolsAgentClient {
42 public: 44 public:
43 virtual void sendMessageToInspectorFrontend(const WebString&) { } 45 virtual void sendMessageToInspectorFrontend(const WebString&) { }
44 virtual void sendDebuggerOutput(const WebString&) { } 46 virtual void sendDebuggerOutput(const WebString&) { }
45 47
46 // Returns the identifier of the entity hosting this agent. 48 // Returns the identifier of the entity hosting this agent.
47 virtual int hostIdentifier() { return -1; } 49 virtual int hostIdentifier() { return -1; }
48 50
49 // Save the agent state in order to pass it later into WebDevToolsAgent::rea ttach 51 // Save the agent state in order to pass it later into WebDevToolsAgent::rea ttach
(...skipping 26 matching lines...) Expand all
76 virtual ~InstrumentedObjectSizeProvider() { } 78 virtual ~InstrumentedObjectSizeProvider() { }
77 }; 79 };
78 virtual void dumpUncountedAllocatedObjects(const InstrumentedObjectSizeProvi der*) { } 80 virtual void dumpUncountedAllocatedObjects(const InstrumentedObjectSizeProvi der*) { }
79 81
80 typedef void (*TraceEventCallback)(char phase, const unsigned char*, const c har* name, unsigned long long id, 82 typedef void (*TraceEventCallback)(char phase, const unsigned char*, const c har* name, unsigned long long id,
81 int numArgs, const char* const* argNames, const unsigned char* argTypes, const unsigned long long* argValues, 83 int numArgs, const char* const* argNames, const unsigned char* argTypes, const unsigned long long* argValues,
82 unsigned char flags); 84 unsigned char flags);
83 85
84 virtual void setTraceEventCallback(TraceEventCallback) { } 86 virtual void setTraceEventCallback(TraceEventCallback) { }
85 87
88 // Called to emulate device dimensions and scale factor. Window should
pfeldman 2013/09/30 12:42:38 Called to emulate device dimensions, scale and inp
dgozman 2013/10/01 15:26:34 Done.
89 // occupy the whole device screen, while the view should be located at |view Rect|.
90 // With |fitToView| set, contents should be scaled down to fit into embedder window
91 // (see WebView::setDeviceEmulationParameters).
92 // All sizes are measured in device independent pixels.
93 virtual void emulateDevice(
94 bool enabled, const WebSize& screenSize, const WebRect& viewRect,
95 float deviceScaleFactor, bool fitToView) { }
96
86 protected: 97 protected:
87 ~WebDevToolsAgentClient() { } 98 ~WebDevToolsAgentClient() { }
88 }; 99 };
89 100
90 } // namespace WebKit 101 } // namespace WebKit
91 102
92 #endif 103 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698