diff options
author | stuartmorgan@chromium.org <stuartmorgan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-04 23:10:27 +0000 |
---|---|---|
committer | stuartmorgan@chromium.org <stuartmorgan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-04 23:10:27 +0000 |
commit | 9f1e5d235d5bdb3a0fe626fe47f5468cddaf75e4 (patch) | |
tree | a3ae0ccbf0909fb958d5be4b4d73de1fadda70b3 | |
parent | cbb50db9d9184a60265d95d7d4401eb3df8033fd (diff) | |
download | chromium_src-9f1e5d235d5bdb3a0fe626fe47f5468cddaf75e4.zip chromium_src-9f1e5d235d5bdb3a0fe626fe47f5468cddaf75e4.tar.gz chromium_src-9f1e5d235d5bdb3a0fe626fe47f5468cddaf75e4.tar.bz2 |
Remove zoom handling from Mac plugin event conversion
This was cruft left over from the workaround for handling plugins on zoomed pages; now that the underlying bug is fixed and the workaround removed, it's no longer called.
BUG=None
TEST=None
Review URL: http://codereview.chromium.org/3602009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@61434 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | webkit/glue/plugins/plugin_web_event_converter_mac.h | 6 | ||||
-rw-r--r-- | webkit/glue/plugins/plugin_web_event_converter_mac.mm | 28 |
2 files changed, 0 insertions, 34 deletions
diff --git a/webkit/glue/plugins/plugin_web_event_converter_mac.h b/webkit/glue/plugins/plugin_web_event_converter_mac.h index 02f113a..ec5b86f 100644 --- a/webkit/glue/plugins/plugin_web_event_converter_mac.h +++ b/webkit/glue/plugins/plugin_web_event_converter_mac.h @@ -25,12 +25,6 @@ class PluginWebEventConverter { // could not be converted. virtual bool InitWithEvent(const WebKit::WebInputEvent& web_event); - // Sets a zoom level to apply to mouse coordinates. Must be called after - // InitWithEvent. - // TODO(stuartmorgan): Re-evaluate whether this is necessary when - // http://crbug.com/9996 is fixed. - virtual void SetZoomLevel(float zoom) = 0; - // Returns a pointer to a plugin event--suitable for passing to // NPP_HandleEvent--corresponding to the the web event this converter was // created with. The pointer is valid only as long as this object is. diff --git a/webkit/glue/plugins/plugin_web_event_converter_mac.mm b/webkit/glue/plugins/plugin_web_event_converter_mac.mm index d8b5c05..030ed06 100644 --- a/webkit/glue/plugins/plugin_web_event_converter_mac.mm +++ b/webkit/glue/plugins/plugin_web_event_converter_mac.mm @@ -49,8 +49,6 @@ class CarbonPluginWebEventConverter : public PluginWebEventConverter { virtual bool InitWithEvent(const WebInputEvent& web_event); - virtual void SetZoomLevel(float zooom); - virtual void* plugin_event() { return &carbon_event_; } protected: @@ -77,12 +75,6 @@ bool CarbonPluginWebEventConverter::InitWithEvent( return PluginWebEventConverter::InitWithEvent(web_event); } -void CarbonPluginWebEventConverter::SetZoomLevel(float zoom) { - // Nothing to do here; because the event is built using the WebMouseEvent's - // global coordinates, and the dummy window is in the right place, zoom has - // no effect. -} - bool CarbonPluginWebEventConverter::ConvertKeyboardEvent( const WebKeyboardEvent& key_event) { // TODO: Figure out how to handle Unicode input to plugins, if that's @@ -185,8 +177,6 @@ public: virtual bool InitWithEvent(const WebInputEvent& web_event); - virtual void SetZoomLevel(float zoom); - virtual void* plugin_event() { return &cocoa_event_; } protected: @@ -212,24 +202,6 @@ bool CocoaPluginWebEventConverter::InitWithEvent( return PluginWebEventConverter::InitWithEvent(web_event); } -void CocoaPluginWebEventConverter::SetZoomLevel(float zoom) { - // Make sure we are dealing with a mouse event. - if (!(cocoa_event_.type != NPCocoaEventMouseDown || - cocoa_event_.type != NPCocoaEventMouseUp || - cocoa_event_.type != NPCocoaEventMouseMoved || - cocoa_event_.type != NPCocoaEventMouseEntered || - cocoa_event_.type != NPCocoaEventMouseExited || - cocoa_event_.type != NPCocoaEventMouseDragged || - cocoa_event_.type != NPCocoaEventScrollWheel)) { - NOTREACHED(); - return; - } - cocoa_event_.data.mouse.pluginX = - round(cocoa_event_.data.mouse.pluginX * zoom); - cocoa_event_.data.mouse.pluginY = - round(cocoa_event_.data.mouse.pluginY * zoom); -} - bool CocoaPluginWebEventConverter::ConvertKeyboardEvent( const WebKeyboardEvent& key_event) { cocoa_event_.data.key.keyCode = key_event.nativeKeyCode; |