summaryrefslogtreecommitdiffstats
path: root/chrome/renderer
diff options
context:
space:
mode:
authordarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-04-01 23:07:19 +0000
committerdarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-04-01 23:07:19 +0000
commit12456fac1b181983b7ce52789be16e7e436a0996 (patch)
treea5a3a92808d8e78d5d620e6f900db60adcb84197 /chrome/renderer
parent31b882b2aac660139d1ea77b953e6c99ab184cb4 (diff)
downloadchromium_src-12456fac1b181983b7ce52789be16e7e436a0996.zip
chromium_src-12456fac1b181983b7ce52789be16e7e436a0996.tar.gz
chromium_src-12456fac1b181983b7ce52789be16e7e436a0996.tar.bz2
Replace webkit/glue/screen_info.h with WebKit/chromium/public/WebScreenInfo.h
This also eliminates webkit_glue::GetScreenInfo and webkit_glue::GetScreenInfoHelper. As part of this CL, I also extracted all of the ParamTraits for WebKit API types into chrome/common/webkit_param_traits.h. R=dglazkov Review URL: http://codereview.chromium.org/58008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12993 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/renderer')
-rw-r--r--chrome/renderer/render_widget.cc9
-rw-r--r--chrome/renderer/render_widget.h13
-rw-r--r--chrome/renderer/renderer_glue.cc7
3 files changed, 16 insertions, 13 deletions
diff --git a/chrome/renderer/render_widget.cc b/chrome/renderer/render_widget.cc
index 12d2315..9b05e19 100644
--- a/chrome/renderer/render_widget.cc
+++ b/chrome/renderer/render_widget.cc
@@ -14,6 +14,7 @@
#include "chrome/common/transport_dib.h"
#include "chrome/renderer/render_process.h"
#include "skia/ext/platform_canvas.h"
+#include "third_party/WebKit/WebKit/chromium/public/WebScreenInfo.h"
#if defined(OS_POSIX)
#include "skia/include/SkPixelRef.h"
@@ -24,6 +25,7 @@
#include "webkit/glue/webwidget.h"
using WebKit::WebInputEvent;
+using WebKit::WebScreenInfo;
RenderWidget::RenderWidget(RenderThreadBase* render_thread, bool activatable)
: routing_id_(MSG_ROUTING_NONE),
@@ -765,3 +767,10 @@ void RenderWidget::DidMove(WebWidget* webwidget,
if (i == plugin_window_moves_.size())
plugin_window_moves_.push_back(move);
}
+
+WebScreenInfo RenderWidget::GetScreenInfo(WebWidget* webwidget) {
+ WebScreenInfo results;
+ RenderThread::current()->Send(
+ new ViewHostMsg_GetScreenInfo(host_window_, &results));
+ return results;
+}
diff --git a/chrome/renderer/render_widget.h b/chrome/renderer/render_widget.h
index d7e28fa..7ee2c04 100644
--- a/chrome/renderer/render_widget.h
+++ b/chrome/renderer/render_widget.h
@@ -70,6 +70,11 @@ class RenderWidget : public IPC::Channel::Listener,
const gfx::Rect& clip_rect);
virtual void SetCursor(WebWidget* webwidget, const WebCursor& cursor);
virtual void Show(WebWidget* webwidget, WindowOpenDisposition disposition);
+ virtual void ShowWithItems(WebWidget* webwidget,
+ const gfx::Rect& bounds,
+ int item_height,
+ int selected_index,
+ const std::vector<MenuItem>& items);
virtual void CloseWidgetSoon(WebWidget* webwidget);
virtual void Focus(WebWidget* webwidget);
virtual void Blur(WebWidget* webwidget);
@@ -79,12 +84,8 @@ class RenderWidget : public IPC::Channel::Listener,
virtual void GetRootWindowResizerRect(WebWidget* webwidget, gfx::Rect* rect);
virtual void DidMove(WebWidget* webwidget, const WebPluginGeometry& move);
virtual void RunModal(WebWidget* webwidget) {}
- virtual bool IsHidden() { return is_hidden_; }
- virtual void ShowWithItems(WebWidget* webwidget,
- const gfx::Rect& bounds,
- int item_height,
- int selected_index,
- const std::vector<MenuItem>& items);
+ virtual bool IsHidden(WebWidget* webwidget) { return is_hidden_; }
+ virtual WebKit::WebScreenInfo GetScreenInfo(WebWidget* webwidget);
// Close the underlying WebWidget.
void Close();
diff --git a/chrome/renderer/renderer_glue.cc b/chrome/renderer/renderer_glue.cc
index e8d3c53..09f6676 100644
--- a/chrome/renderer/renderer_glue.cc
+++ b/chrome/renderer/renderer_glue.cc
@@ -219,13 +219,6 @@ bool GetPlugins(bool refresh, std::vector<WebPluginInfo>* plugins) {
new ViewHostMsg_GetPlugins(refresh, plugins));
}
-webkit_glue::ScreenInfo GetScreenInfo(gfx::NativeViewId window) {
- webkit_glue::ScreenInfo results;
- RenderThread::current()->Send(
- new ViewHostMsg_GetScreenInfo(window, &results));
- return results;
-}
-
// static factory function
ResourceLoaderBridge* ResourceLoaderBridge::Create(
const std::string& method,