Reviewed by Martin Robinson.
[GTK] Support the Mozilla-style Fullscreen Javascript API
https://bugs.webkit.org/show_bug.cgi?id=50572
* configure.ac: new configure flag to disable the new Javascript
Fullscreen API build. It is enabled by default.
WebCore:
Reviewed by Martin Robinson.
[GTK] Support the Mozilla-style Fullscreen Javascript API
https://bugs.webkit.org/show_bug.cgi?id=50572
* GNUmakefile.am: enable the Javascript Fullscreen API feature if
it's been requested at configure time.
WebKit/gtk:
Reviewed by Martin Robinson.
[GTK] Support the Mozilla-style Fullscreen Javascript API
https://bugs.webkit.org/show_bug.cgi?id=50572
Fullscreen API support. It is controlled at runtime using a new
setting called enable-fullscreen, set to FALSE by default.
* WebCoreSupport/ChromeClientGtk.cpp:
(WebKit::ChromeClient::supportsFullScreenForElement):
(WebKit::ChromeClient::enterFullScreenForElement):
(WebKit::ChromeClient::exitFullScreenForElement):
* WebCoreSupport/ChromeClientGtk.h:
* webkit/webkitwebsettings.cpp:
(webkit_web_settings_class_init):
(webkit_web_settings_set_property):
(webkit_web_settings_get_property):
(webkit_web_settings_copy):
* webkit/webkitwebview.cpp:
(webkit_web_view_update_settings):
WebKitTools:
Reviewed by Martin Robinson.
[GTK] Support the Mozilla-style Fullscreen Javascript API
https://bugs.webkit.org/show_bug.cgi?id=50572
Enable the Javascript Fullscreen support in the GtkLauncher. Also
make DRT update the Chrome when the WebView settings have been
reset to consistent values.
* DumpRenderTree/gtk/DumpRenderTree.cpp:
(resetDefaultsToConsistentValues):
* GtkLauncher/main.c:
(create_window):
* Scripts/build-webkit:
LayoutTests:
Reviewed by Martin Robinson.
[GTK] Support the Mozilla-style Fullscreen Javascript API
https://bugs.webkit.org/show_bug.cgi?id=50572
* platform/gtk/Skipped: Unskip now passing fullscreen tests.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@73624
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2010-12-06 Philippe Normand <pnormand@igalia.com>
+
+ Reviewed by Martin Robinson.
+
+ [GTK] Support the Mozilla-style Fullscreen Javascript API
+ https://bugs.webkit.org/show_bug.cgi?id=50572
+
+ * configure.ac: new configure flag to disable the new Javascript
+ Fullscreen API build. It is enabled by default.
+
2010-12-09 Philippe Normand <pnormand@igalia.com>
Reviewed by Xan Lopez.
+2010-12-06 Philippe Normand <pnormand@igalia.com>
+
+ Reviewed by Martin Robinson.
+
+ [GTK] Support the Mozilla-style Fullscreen Javascript API
+ https://bugs.webkit.org/show_bug.cgi?id=50572
+
+ * platform/gtk/Skipped: Unskip now passing fullscreen tests.
+
2010-12-09 Michael Saboff <msaboff@apple.com>
Reviewed by Geoffrey Garen.
# https://bugs.webkit.org/show_bug.cgi?id=44784
fast/history/history-subframe-with-name.html
-# Full Screen support is not yet enabled.
-fullscreen/
-
# https://bugs.webkit.org/show_bug.cgi?id=44932
canvas/philip/tests/2d.path.isPointInPath.edge.html
+2010-12-06 Philippe Normand <pnormand@igalia.com>
+
+ Reviewed by Martin Robinson.
+
+ [GTK] Support the Mozilla-style Fullscreen Javascript API
+ https://bugs.webkit.org/show_bug.cgi?id=50572
+
+ * GNUmakefile.am: enable the Javascript Fullscreen API feature if
+ it's been requested at configure time.
+
2010-12-09 Yong Li <yoli@rim.com>
Reviewed by Darin Adler.
endif # END ENABLE_VIDEO
# ----
+# Javascript Fullscreen Support
+# ----
+if ENABLE_FULLSCREEN_API
+FEATURE_DEFINES += ENABLE_FULLSCREEN_API=1
+webcore_cppflags += -DENABLE_FULLSCREEN_API=1
+endif # END ENABLE_FULLSCREEN_API
+
+# ----
# XHTML-MP Support
# ----
if ENABLE_XHTMLMP
$(WebCore)/css/svg.css \
$(WebCore)/css/wml.css \
$(WebCore)/css/mediaControls.css \
- $(WebCore)/css/mediaControlsGtk.css
+ $(WebCore)/css/mediaControlsGtk.css \
+ $(WebCore)/css/fullscreen.css
# new-style JavaScript bindings
SCRIPTS_BINDINGS = \
+2010-12-06 Philippe Normand <pnormand@igalia.com>
+
+ Reviewed by Martin Robinson.
+
+ [GTK] Support the Mozilla-style Fullscreen Javascript API
+ https://bugs.webkit.org/show_bug.cgi?id=50572
+
+ Fullscreen API support. It is controlled at runtime using a new
+ setting called enable-fullscreen, set to FALSE by default.
+
+ * WebCoreSupport/ChromeClientGtk.cpp:
+ (WebKit::ChromeClient::supportsFullScreenForElement):
+ (WebKit::ChromeClient::enterFullScreenForElement):
+ (WebKit::ChromeClient::exitFullScreenForElement):
+ * WebCoreSupport/ChromeClientGtk.h:
+ * webkit/webkitwebsettings.cpp:
+ (webkit_web_settings_class_init):
+ (webkit_web_settings_set_property):
+ (webkit_web_settings_get_property):
+ (webkit_web_settings_copy):
+ * webkit/webkitwebview.cpp:
+ (webkit_web_view_update_settings):
+
2010-12-09 Joone Hur <joone@kldp.org>
Reviewed by Martin Robinson.
}
#endif
+#if ENABLE(FULLSCREEN_API)
+bool ChromeClient::supportsFullScreenForElement(const WebCore::Element* element)
+{
+ return true;
+}
+
+void ChromeClient::enterFullScreenForElement(WebCore::Element* element)
+{
+ element->document()->webkitWillEnterFullScreenForElement(element);
+ element->document()->webkitDidEnterFullScreenForElement(element);
+}
+
+void ChromeClient::exitFullScreenForElement(WebCore::Element* element)
+{
+ element->document()->webkitWillExitFullScreenForElement(element);
+ element->document()->webkitDidExitFullScreenForElement(element);
+}
+#endif
+
+
}
virtual void exitFullscreenForNode(WebCore::Node*);
#endif
+#if ENABLE(FULLSCREEN_API)
+ virtual bool supportsFullScreenForElement(const WebCore::Element*);
+ virtual void enterFullScreenForElement(WebCore::Element*);
+ virtual void exitFullScreenForElement(WebCore::Element*);
+#endif
+
private:
WebKitWebView* m_webView;
WebCore::KURL m_hoveredLinkURL;
gboolean auto_resize_window;
gboolean enable_java_applet;
gboolean enable_hyperlink_auditing;
+ gboolean enable_fullscreen;
};
#define WEBKIT_WEB_SETTINGS_GET_PRIVATE(obj) (G_TYPE_INSTANCE_GET_PRIVATE((obj), WEBKIT_TYPE_WEB_SETTINGS, WebKitWebSettingsPrivate))
PROP_ENABLE_PAGE_CACHE,
PROP_AUTO_RESIZE_WINDOW,
PROP_ENABLE_JAVA_APPLET,
- PROP_ENABLE_HYPERLINK_AUDITING
+ PROP_ENABLE_HYPERLINK_AUDITING,
+ PROP_ENABLE_FULLSCREEN
};
// Create a default user agent string
FALSE,
flags));
+ /* Undocumented for now */
+ g_object_class_install_property(gobject_class,
+ PROP_ENABLE_FULLSCREEN,
+ g_param_spec_boolean("enable-fullscreen",
+ _("Enable Fullscreen"),
+ _("Whether the Mozilla style API should be enabled."),
+ FALSE,
+ flags));
+
g_type_class_add_private(klass, sizeof(WebKitWebSettingsPrivate));
}
case PROP_ENABLE_HYPERLINK_AUDITING:
priv->enable_hyperlink_auditing = g_value_get_boolean(value);
break;
+ case PROP_ENABLE_FULLSCREEN:
+ priv->enable_fullscreen = g_value_get_boolean(value);
+ break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID(object, prop_id, pspec);
break;
case PROP_ENABLE_HYPERLINK_AUDITING:
g_value_set_boolean(value, priv->enable_hyperlink_auditing);
break;
+ case PROP_ENABLE_FULLSCREEN:
+ g_value_set_boolean(value, priv->enable_fullscreen);
+ break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID(object, prop_id, pspec);
break;
"auto-resize-window", priv->auto_resize_window,
"enable-java-applet", priv->enable_java_applet,
"enable-hyperlink-auditing", priv->enable_hyperlink_auditing,
+ "enable-fullscreen", priv->enable_fullscreen,
NULL));
return copy;
javaScriptCanAccessClipboard, enableOfflineWebAppCache,
enableUniversalAccessFromFileURI, enableFileAccessFromFileURI,
enableDOMPaste, tabKeyCyclesThroughElements,
- enableSiteSpecificQuirks, usePageCache, enableJavaApplet, enableHyperlinkAuditing;
+ enableSiteSpecificQuirks, usePageCache, enableJavaApplet, enableHyperlinkAuditing, enableFullscreen;
WebKitEditingBehavior editingBehavior;
"enable-page-cache", &usePageCache,
"enable-java-applet", &enableJavaApplet,
"enable-hyperlink-auditing", &enableHyperlinkAuditing,
+ "enable-fullscreen", &enableFullscreen,
NULL);
settings->setDefaultTextEncodingName(defaultEncoding);
settings->setUsesPageCache(usePageCache);
settings->setJavaEnabled(enableJavaApplet);
settings->setHyperlinkAuditingEnabled(enableHyperlinkAuditing);
-
+#if ENABLE(FULLSCREEN_API)
+ settings->setFullScreenEnabled(enableFullscreen);
+#endif
Page* page = core(webView);
if (page)
page->setTabKeyCyclesThroughElements(tabKeyCyclesThroughElements);
+2010-12-06 Philippe Normand <pnormand@igalia.com>
+
+ Reviewed by Martin Robinson.
+
+ [GTK] Support the Mozilla-style Fullscreen Javascript API
+ https://bugs.webkit.org/show_bug.cgi?id=50572
+
+ Enable the Javascript Fullscreen support in the GtkLauncher. Also
+ make DRT update the Chrome when the WebView settings have been
+ reset to consistent values.
+
+ * DumpRenderTree/gtk/DumpRenderTree.cpp:
+ (resetDefaultsToConsistentValues):
+ * GtkLauncher/main.c:
+ (create_window):
+ * Scripts/build-webkit:
+
2010-12-09 Koan-Sin Tan <koansin.tan@gmail.com>
Reviewed by Tor Arne Vestbø
"enable-plugins", TRUE,
"enable-hyperlink-auditing", FALSE,
"editing-behavior", WEBKIT_EDITING_BEHAVIOR_MAC,
+ "enable-fullscreen", TRUE,
NULL);
+ webkit_web_view_set_settings(webView, settings);
DumpRenderTreeSupportGtk::clearMainFrameName(mainFrame);
static GtkWidget* createWindow(WebKitWebView** outWebView)
{
WebKitWebView *webView;
+ WebKitWebSettings *webSettings;
GtkWidget *vbox;
GtkWidget *window;
GtkWidget *uriEntry;
gtk_container_add(GTK_CONTAINER(window), vbox);
+ webSettings = webkit_web_view_get_settings(webView);
+ g_object_set(G_OBJECT(webSettings), "enable-fullscreen", TRUE, NULL);
+ webkit_web_view_set_settings(webView, webSettings);
+
g_signal_connect(window, "destroy", G_CALLBACK(destroyCb), NULL);
if (outWebView)
define => "ENABLE_FILTERS", default => (isAppleWebKit() || isGtk() || isQt() || isEfl()), value => \$filtersSupport },
{ option => "fullscreen-api", desc => "Toggle Fullscreen API support",
- define => "ENABLE_FULLSCREEN_API", default => isAppleMacWebKit(), value => \$fullscreenAPISupport },
+ define => "ENABLE_FULLSCREEN_API", default => (isAppleMacWebKit() || isGtk()), value => \$fullscreenAPISupport },
{ option => "geolocation", desc => "Toggle Geolocation support",
define => "ENABLE_GEOLOCATION", default => (isAppleWebKit() || isGtk()), value => \$geolocationSupport },
[],[enable_video="yes"])
AC_MSG_RESULT([$enable_video])
+# check whether to enable Javascript Fullscreen API support
+AC_MSG_CHECKING([whether to enable Fullscreen API support])
+AC_ARG_ENABLE(fullscreen_api,
+ AC_HELP_STRING([--enable-fullscreen-api],
+ [enable the Fullscreen API support [default=yes]]),
+ [],[enable_fullscreen_api="yes"])
+AC_MSG_RESULT([$enable_fullscreen_api])
+
# check whether to enable XHTML-MP support
AC_MSG_CHECKING([whether to enable XHTML-MP support])
AC_ARG_ENABLE(xhtmlmp,
AM_CONDITIONAL([ENABLE_GEOLOCATION], [test "$enable_geolocation" = "yes"])
AM_CONDITIONAL([ENABLE_MATHML], [test "$enable_mathml" = "yes"])
AM_CONDITIONAL([ENABLE_VIDEO],[test "$enable_video" = "yes"])
+AM_CONDITIONAL([ENABLE_FULLSCREEN_API],[test "$enable_fullscreen_api" = "yes"])
AM_CONDITIONAL([ENABLE_NOTIFICATIONS],[test "$enable_notifications" = "yes"])
AM_CONDITIONAL([ENABLE_ORIENTATION_EVENTS],[test "$enable_orientation_events" = "yes"])
AM_CONDITIONAL([ENABLE_SVG],[test "$enable_svg" = "yes"])
HTML5 sandboxed iframe support : $enable_sandbox
HTML5 server-sent events support : $enable_eventsource
HTML5 video element support : $enable_video
+ Fullscreen API support : $enable_fullscreen_api
Icon database support : $enable_icon_database
Image resizer support : $enable_image_resizer
Link prefetch support : $enable_link_prefetch