summaryrefslogtreecommitdiffstats
path: root/WebKit/android/plugins/PluginWidgetAndroid.h
diff options
context:
space:
mode:
Diffstat (limited to 'WebKit/android/plugins/PluginWidgetAndroid.h')
-rw-r--r--WebKit/android/plugins/PluginWidgetAndroid.h36
1 files changed, 23 insertions, 13 deletions
diff --git a/WebKit/android/plugins/PluginWidgetAndroid.h b/WebKit/android/plugins/PluginWidgetAndroid.h
index 9fc2209..ef3e40c 100644
--- a/WebKit/android/plugins/PluginWidgetAndroid.h
+++ b/WebKit/android/plugins/PluginWidgetAndroid.h
@@ -13,7 +13,7 @@
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS ``AS IS'' AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
@@ -67,12 +67,6 @@ struct PluginWidgetAndroid {
*/
void setWindow(NPWindow* window, bool isTransparent);
- /* Called to notify us of the plugin's java class that implements the
- * PluginStub interface. A local copy is made of the className so the caller
- * can safely free the memory as soon as the function returns.
- */
- bool setPluginStubJavaClassName(const char* className);
-
/* Called whenever the plugin itself requests a new drawing model. If the
hardware does not support the requested model then false is returned,
otherwise true is returned.
@@ -131,11 +125,25 @@ struct PluginWidgetAndroid {
*/
void setVisibleRects(const ANPRectI rects[], int32_t count);
- /** Called when a plugin wishes to enter into full screen mode. The plugin's
- Java class (set using setPluginStubJavaClassName(...)) will be called
- asynchronously to provide a View to be displayed in full screen.
+ /** Returns a java object that implements the WebkitPlugin interface. The
+ implementation is located in the plugin's apk and is described in the
+ apk's manifest file. For each plugin instance in webkit there is at
+ most one instance of the java object associated with that plugin.
+ */
+ jobject getJavaPluginInstance();
+
+ /** Called when a plugin wishes to enter into full screen mode. It invokes
+ the plugin's Java class (defined in the plugin's apk manifest), which is
+ called asynchronously and provides a View to be displayed full screen.
+ */
+ void requestFullScreen();
+
+ /** Called when a plugin wishes to exit from full screen mode. As a result,
+ the plugin's full-screen view is discarded by the view system. It is also
+ called in order to notify the native code that the browser has discarded
+ the view.
*/
- void requestFullScreenMode();
+ void exitFullScreen(bool pluginInitiated);
private:
WebCore::IntPoint frameToDocumentCoords(int frameX, int frameY) const;
@@ -148,12 +156,14 @@ private:
ANPDrawingModel m_drawingModel;
ANPEventFlags m_eventFlags;
NPWindow* m_pluginWindow;
+ SkIRect m_pluginBounds;
SkIRect m_visibleDocRect;
SkIRect m_requestedFrameRect;
bool m_hasFocus;
+ bool m_isFullScreen;
float m_zoomLevel;
- char* m_javaClassName;
- jobject m_childView;
+ jobject m_webkitPlugin;
+ jobject m_embeddedView;
/* We limit the number of rectangles to minimize storage and ensure adequate
speed.