Title: [100153] trunk/Source
Revision
100153
Author
[email protected]
Date
2011-11-14 09:05:31 -0800 (Mon, 14 Nov 2011)

Log Message

Add support for the caretBrowsingEnabled preference in WebKit2
https://bugs.webkit.org/show_bug.cgi?id=72266

Reviewed by Chris Fleizach.

Source/WebCore:

* WebCore.exp.in: Exported settings for setCaretBrowsingEnabled.

Source/WebKit2:

* Shared/WebPreferencesStore.h: Add caretBrowsingEnabled getter
and setter macro.
* UIProcess/API/C/WKPreferences.h:
* UIProcess/API/C/WKPreferences.cpp:
(WKPreferencesSetCaretBrowsingEnabled): Added.
(WKPreferencesGetCaretBrowsingEnabled): Added.
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::updatePreferences): Update the
caretBrowsingEnabledKey preference.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (100152 => 100153)


--- trunk/Source/WebCore/ChangeLog	2011-11-14 17:01:39 UTC (rev 100152)
+++ trunk/Source/WebCore/ChangeLog	2011-11-14 17:05:31 UTC (rev 100153)
@@ -1,3 +1,12 @@
+2011-11-14  Mario Sanchez Prada  <[email protected]>
+
+        Add support for the caretBrowsingEnabled preference in WebKit2
+        https://bugs.webkit.org/show_bug.cgi?id=72266
+
+        Reviewed by Chris Fleizach.
+
+        * WebCore.exp.in: Exported settings for setCaretBrowsingEnabled.
+
 2011-11-14  Jonathan Backer  <[email protected]>
 
         [chromium] Plumb through partial swap

Modified: trunk/Source/WebCore/WebCore.exp.in (100152 => 100153)


--- trunk/Source/WebCore/WebCore.exp.in	2011-11-14 17:01:39 UTC (rev 100152)
+++ trunk/Source/WebCore/WebCore.exp.in	2011-11-14 17:05:31 UTC (rev 100153)
@@ -943,6 +943,7 @@
 __ZN7WebCore8Settings22setSansSerifFontFamilyERKN3WTF12AtomicStringE11UScriptCode
 __ZN7WebCore8Settings22setSessionStorageQuotaEj
 __ZN7WebCore8Settings22setShowsURLsInToolTipsEb
+__ZN7WebCore8Settings23setCaretBrowsingEnabledEb
 __ZN7WebCore8Settings23setDefaultFixedFontSizeEi
 __ZN7WebCore8Settings23setEditableLinkBehaviorENS_20EditableLinkBehaviorE
 __ZN7WebCore8Settings23setLoadDeferringEnabledEb

Modified: trunk/Source/WebKit2/ChangeLog (100152 => 100153)


--- trunk/Source/WebKit2/ChangeLog	2011-11-14 17:01:39 UTC (rev 100152)
+++ trunk/Source/WebKit2/ChangeLog	2011-11-14 17:05:31 UTC (rev 100153)
@@ -1,3 +1,20 @@
+2011-11-14  Mario Sanchez Prada  <[email protected]>
+
+        Add support for the caretBrowsingEnabled preference in WebKit2
+        https://bugs.webkit.org/show_bug.cgi?id=72266
+
+        Reviewed by Chris Fleizach.
+
+        * Shared/WebPreferencesStore.h: Add caretBrowsingEnabled getter
+        and setter macro.
+        * UIProcess/API/C/WKPreferences.h:
+        * UIProcess/API/C/WKPreferences.cpp:
+        (WKPreferencesSetCaretBrowsingEnabled): Added.
+        (WKPreferencesGetCaretBrowsingEnabled): Added.
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::updatePreferences): Update the
+        caretBrowsingEnabledKey preference.
+
 2011-11-14  Caio Marcelo de Oliveira Filho  <[email protected]>
 
         [Qt] Remove reference to QWebNavigationController

Modified: trunk/Source/WebKit2/Shared/WebPreferencesStore.h (100152 => 100153)


--- trunk/Source/WebKit2/Shared/WebPreferencesStore.h	2011-11-14 17:01:39 UTC (rev 100152)
+++ trunk/Source/WebKit2/Shared/WebPreferencesStore.h	2011-11-14 17:05:31 UTC (rev 100153)
@@ -97,6 +97,7 @@
     macro(ApplicationChromeModeEnabled, applicationChromeMode, Bool, bool, false) \
     macro(SuppressIncrementalRendering, suppressIncrementalRendering, Bool, bool, false) \
     macro(BackspaceKeyNavigationEnabled, backspaceKeyNavigationEnabled, Bool, bool, true) \
+    macro(CaretBrowsingEnabled, caretBrowsingEnabled, Bool, bool, false) \
     \
 
 #define FOR_EACH_WEBKIT_DOUBLE_PREFERENCE(macro) \

Modified: trunk/Source/WebKit2/UIProcess/API/C/WKPreferences.cpp (100152 => 100153)


--- trunk/Source/WebKit2/UIProcess/API/C/WKPreferences.cpp	2011-11-14 17:01:39 UTC (rev 100152)
+++ trunk/Source/WebKit2/UIProcess/API/C/WKPreferences.cpp	2011-11-14 17:05:31 UTC (rev 100153)
@@ -661,3 +661,13 @@
 {
     return toImpl(preferencesRef)->backspaceKeyNavigationEnabled();
 }
+
+void WKPreferencesSetCaretBrowsingEnabled(WKPreferencesRef preferencesRef, bool enabled)
+{
+    toImpl(preferencesRef)->setCaretBrowsingEnabled(enabled);
+}
+
+bool WKPreferencesGetCaretBrowsingEnabled(WKPreferencesRef preferencesRef)
+{
+    return toImpl(preferencesRef)->caretBrowsingEnabled();
+}

Modified: trunk/Source/WebKit2/UIProcess/API/C/WKPreferences.h (100152 => 100153)


--- trunk/Source/WebKit2/UIProcess/API/C/WKPreferences.h	2011-11-14 17:01:39 UTC (rev 100152)
+++ trunk/Source/WebKit2/UIProcess/API/C/WKPreferences.h	2011-11-14 17:05:31 UTC (rev 100153)
@@ -177,6 +177,10 @@
 WK_EXPORT void WKPreferencesSetBackspaceKeyNavigationEnabled(WKPreferencesRef preferencesRef, bool enabled);
 WK_EXPORT bool WKPreferencesGetBackspaceKeyNavigationEnabled(WKPreferencesRef preferencesRef);
 
+// Defaults to false
+WK_EXPORT void WKPreferencesSetCaretBrowsingEnabled(WKPreferencesRef preferencesRef, bool enabled);
+WK_EXPORT bool WKPreferencesGetCaretBrowsingEnabled(WKPreferencesRef preferencesRef);
+
 #ifdef __cplusplus
 }
 #endif

Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp (100152 => 100153)


--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp	2011-11-14 17:01:39 UTC (rev 100152)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp	2011-11-14 17:05:31 UTC (rev 100153)
@@ -1765,6 +1765,7 @@
     settings->setApplicationChromeMode(store.getBoolValueForKey(WebPreferencesKey::applicationChromeModeKey()));    
     settings->setSuppressIncrementalRendering(store.getBoolValueForKey(WebPreferencesKey::suppressIncrementalRenderingKey()));
     settings->setBackspaceKeyNavigationEnabled(store.getBoolValueForKey(WebPreferencesKey::backspaceKeyNavigationEnabledKey()));
+    settings->setCaretBrowsingEnabled(store.getBoolValueForKey(WebPreferencesKey::caretBrowsingEnabledKey()));
 
     platformPreferencesDidChange(store);
 }
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to