Changeset 55583 in webkit


Ignore:
Timestamp:
Mar 5, 2010 8:07:44 AM (14 years ago)
Author:
tonikitoo@webkit.org
Message:

[Gtk] Add 'enable-spatial-navigation' setting for Spatial Navigation on/off.
https://bugs.webkit.org/show_bug.cgi?id=35701

Reviewed by Gustavo Noronha.
Patch by Antonio Gomes <tonikitoo@webkit.org>

  • 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:

(DNDContentsRequest::webkit_web_view_update_settings):
(DNDContentsRequest::webkit_web_view_settings_notify):

Location:
trunk/WebKit/gtk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKit/gtk/ChangeLog

    r55457 r55583  
     12010-03-03  Antonio Gomes  <tonikitoo@webkit.org>
     2
     3        Reviewed by Gustavo Noronha.
     4        Patch by Antonio Gomes <tonikitoo@webkit.org>
     5
     6        [Gtk] Add 'enable-spatial-navigation' setting for toggle Spatial Navigation on/off
     7        https://bugs.webkit.org/show_bug.cgi?id=35701
     8
     9        * webkit/webkitwebsettings.cpp:
     10        (webkit_web_settings_class_init):
     11        (webkit_web_settings_set_property):
     12        (webkit_web_settings_get_property):
     13        (webkit_web_settings_copy):
     14        * webkit/webkitwebview.cpp:
     15        (DNDContentsRequest::webkit_web_view_update_settings):
     16        (DNDContentsRequest::webkit_web_view_settings_notify):
     17
    1182010-03-03  Fridrich Strba  <fridrich.strba@bluewin.ch>
    219
  • trunk/WebKit/gtk/webkit/webkitwebsettings.cpp

    r55222 r55583  
    9494    gboolean enable_html5_local_storage;
    9595    gboolean enable_xss_auditor;
     96    gboolean enable_spatial_navigation;
    9697    gchar* user_agent;
    9798    gboolean javascript_can_open_windows_automatically;
     
    142143    PROP_ENABLE_HTML5_LOCAL_STORAGE,
    143144    PROP_ENABLE_XSS_AUDITOR,
     145    PROP_ENABLE_SPATIAL_NAVIGATION,
    144146    PROP_USER_AGENT,
    145147    PROP_JAVASCRIPT_CAN_OPEN_WINDOWS_AUTOMATICALLY,
     
    569571                                                         TRUE,
    570572                                                         flags));
    571 
     573    /**
     574    * WebKitWebSettings:enable-spatial-navigation
     575    *
     576    * Whether to enable the Spatial Navigation. This feature consists in the ability
     577    * to navigate between focusable elements in a Web page, such as hyperlinks and
     578    * form controls, by using Left, Right, Up and Down arrow keys. For example, if
     579    * an user presses the Right key, heuristics determine whether there is an element
     580    * he might be trying to reach towards the right, and if there are multiple elements,
     581    * which element he probably wants.
     582    *
     583    * Since: 1.1.23
     584    */
     585    g_object_class_install_property(gobject_class,
     586                                    PROP_ENABLE_SPATIAL_NAVIGATION,
     587                                    g_param_spec_boolean("enable-spatial-navigation",
     588                                                         _("Enable Spatial Navigation"),
     589                                                         _("Whether to enable Spatial Navigation"),
     590                                                         FALSE,
     591                                                         flags));
    572592    /**
    573593     * WebKitWebSettings:user-agent:
     
    9911011        priv->enable_xss_auditor = g_value_get_boolean(value);
    9921012        break;
     1013    case PROP_ENABLE_SPATIAL_NAVIGATION:
     1014        priv->enable_spatial_navigation = g_value_get_boolean(value);
     1015        break;
    9931016    case PROP_USER_AGENT:
    9941017        g_free(priv->user_agent);
     
    11291152    case PROP_ENABLE_XSS_AUDITOR:
    11301153        g_value_set_boolean(value, priv->enable_xss_auditor);
     1154        break;
     1155    case PROP_ENABLE_SPATIAL_NAVIGATION:
     1156        g_value_set_boolean(value, priv->enable_spatial_navigation);
    11311157        break;
    11321158    case PROP_USER_AGENT:
     
    12271253                 "enable-html5-local-storage", priv->enable_html5_local_storage,
    12281254                 "enable-xss-auditor", priv->enable_xss_auditor,
     1255                 "enable-spatial-navigation", priv->enable_spatial_navigation,
    12291256                 "user-agent", webkit_web_settings_get_user_agent(web_settings),
    12301257                 "javascript-can-open-windows-automatically", priv->javascript_can_open_windows_automatically,
  • trunk/WebKit/gtk/webkit/webkitwebview.cpp

    r55454 r55583  
    26732673        enableScripts, enablePlugins, enableDeveloperExtras, resizableTextAreas,
    26742674        enablePrivateBrowsing, enableCaretBrowsing, enableHTML5Database, enableHTML5LocalStorage,
    2675         enableXSSAuditor, javascriptCanOpenWindows, enableOfflineWebAppCache,
     2675        enableXSSAuditor, enableSpatialNavigation, javascriptCanOpenWindows, enableOfflineWebAppCache,
    26762676        enableUniversalAccessFromFileURI, enableFileAccessFromFileURI,
    26772677        enableDOMPaste, tabKeyCyclesThroughElements,
     
    27012701                 "enable-html5-local-storage", &enableHTML5LocalStorage,
    27022702                 "enable-xss-auditor", &enableXSSAuditor,
     2703                 "enable-spatial-navigation", &enableSpatialNavigation,
    27032704                 "javascript-can-open-windows-automatically", &javascriptCanOpenWindows,
    27042705                 "enable-offline-web-application-cache", &enableOfflineWebAppCache,
     
    27362737    settings->setLocalStorageEnabled(enableHTML5LocalStorage);
    27372738    settings->setXSSAuditorEnabled(enableXSSAuditor);
     2739    settings->setSpatialNavigationEnabled(enableSpatialNavigation);
    27382740    settings->setJavaScriptCanOpenWindowsAutomatically(javascriptCanOpenWindows);
    27392741    settings->setOfflineWebApplicationCacheEnabled(enableOfflineWebAppCache);
     
    28312833    else if (name == g_intern_string("enable-xss-auditor"))
    28322834        settings->setXSSAuditorEnabled(g_value_get_boolean(&value));
     2835    else if (name == g_intern_string("enable-spatial-navigation"))
     2836        settings->setSpatialNavigationEnabled(g_value_get_boolean(&value));
    28332837    else if (name == g_intern_string("javascript-can-open-windows-automatically"))
    28342838        settings->setJavaScriptCanOpenWindowsAutomatically(g_value_get_boolean(&value));
Note: See TracChangeset for help on using the changeset viewer.