Title: [180765] trunk
Revision
180765
Author
bfulg...@apple.com
Date
2015-02-27 10:09:46 -0800 (Fri, 27 Feb 2015)

Log Message

[Win] Remove remaining SafariTheme cruft
https://bugs.webkit.org/show_bug.cgi?id=142075

Reviewed by Anders Carlsson.

Remove reference to SafariTheme-switching preference.

Source/WebCore:

Tested by existing layout tests.

* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* config.h:
* page/Settings.cpp:
(WebCore::Settings::fontRenderingMode):
(WebCore::Settings::setShouldPaintNativeControls): Deleted.
* page/Settings.h:
(WebCore::Settings::shouldPaintNativeControls): Deleted.
* platform/win/ScrollbarThemeWin.cpp:
(WebCore::ScrollbarTheme::nativeTheme):
* rendering/RenderThemeWin.cpp:
(WebCore::RenderTheme::themeForPage):

Source/WebKit/win:

* Interfaces/IWebPreferencesPrivate.idl:
* WebKitClassFactory.cpp:
(WebKitClassFactory::WebKitClassFactory):
(WebKitClassFactory::QueryInterface):
(WebKitClassFactory::AddRef):
(WebKitClassFactory::Release):
(WebKitClassFactory::CreateInstance):
(WebKitClassFactory::LockServer):
* WebPreferences.cpp:
(WebPreferences::shouldPaintNativeControls): Deleted.
(WebPreferences::setShouldPaintNativeControls): Deleted.
* WebPreferences.h:
* WebView.cpp:
(WebView::initWithFrame):
(WebView::notifyPreferencesChanged):

Tools:

* DumpRenderTree/win/DumpRenderTree.cpp:
(resetWebPreferencesToConsistentValues):
(prepareConsistentTestingEnvironment):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (180764 => 180765)


--- trunk/Source/WebCore/ChangeLog	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebCore/ChangeLog	2015-02-27 18:09:46 UTC (rev 180765)
@@ -1,3 +1,27 @@
+2015-02-26  Brent Fulgham  <bfulg...@apple.com>
+
+        [Win] Remove remaining SafariTheme cruft
+        https://bugs.webkit.org/show_bug.cgi?id=142075
+
+        Reviewed by Anders Carlsson.
+
+        Remove reference to SafariTheme-switching preference.
+
+        Tested by existing layout tests.
+
+        * WebCore.vcxproj/WebCore.vcxproj:
+        * WebCore.vcxproj/WebCore.vcxproj.filters:
+        * config.h:
+        * page/Settings.cpp:
+        (WebCore::Settings::fontRenderingMode):
+        (WebCore::Settings::setShouldPaintNativeControls): Deleted.
+        * page/Settings.h:
+        (WebCore::Settings::shouldPaintNativeControls): Deleted.
+        * platform/win/ScrollbarThemeWin.cpp:
+        (WebCore::ScrollbarTheme::nativeTheme):
+        * rendering/RenderThemeWin.cpp:
+        (WebCore::RenderTheme::themeForPage):
+
 2015-02-27  Myles C. Maxfield  <mmaxfi...@apple.com>
 
         Add comment about CSS value name mangling

Modified: trunk/Source/WebCore/WebCore.vcxproj/WebCore.vcxproj (180764 => 180765)


--- trunk/Source/WebCore/WebCore.vcxproj/WebCore.vcxproj	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebCore/WebCore.vcxproj/WebCore.vcxproj	2015-02-27 18:09:46 UTC (rev 180765)
@@ -8024,7 +8024,6 @@
     <ClCompile Include="..\platform\win\PlatformMouseEventWin.cpp" />
     <ClCompile Include="..\platform\win\PlatformScreenWin.cpp" />
     <ClCompile Include="..\platform\win\PopupMenuWin.cpp" />
-    <ClCompile Include="..\platform\win\ScrollbarThemeSafari.cpp" />
     <ClCompile Include="..\platform\win\ScrollbarThemeWin.cpp" />
     <ClCompile Include="..\platform\win\SearchPopupMenuWin.cpp" />
     <ClCompile Include="..\platform\win\SharedBufferWin.cpp" />
@@ -11528,7 +11527,6 @@
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
     </ClCompile>
-    <ClCompile Include="..\rendering\RenderThemeSafari.cpp" />
     <ClCompile Include="..\rendering\RenderThemeWin.cpp">
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
@@ -19591,7 +19589,6 @@
     <ClInclude Include="..\platform\win\PathWalker.h" />
     <ClInclude Include="..\platform\win\PEImage.h" />
     <ClInclude Include="..\platform\win\PopupMenuWin.h" />
-    <ClInclude Include="..\platform\win\ScrollbarThemeSafari.h" />
     <ClInclude Include="..\platform\win\ScrollbarThemeWin.h" />
     <ClInclude Include="..\platform\win\SearchPopupMenuWin.h" />
     <ClInclude Include="..\platform\win\SoftLinking.h" />
@@ -20394,7 +20391,6 @@
     <ClInclude Include="..\rendering\RenderTextFragment.h" />
     <ClInclude Include="..\rendering\RenderTextLineBoxes.h" />
     <ClInclude Include="..\rendering\RenderTheme.h" />
-    <CustomBuildStep Include="..\rendering\RenderThemeSafari.h" />
     <CustomBuildStep Include="..\rendering\RenderThemeWin.h" />
     <ClInclude Include="..\rendering\RenderTreeAsText.h" />
     <ClInclude Include="..\rendering\RenderVTTCue.h" />

Modified: trunk/Source/WebCore/WebCore.vcxproj/WebCore.vcxproj.filters (180764 => 180765)


--- trunk/Source/WebCore/WebCore.vcxproj/WebCore.vcxproj.filters	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebCore/WebCore.vcxproj/WebCore.vcxproj.filters	2015-02-27 18:09:46 UTC (rev 180765)
@@ -1269,9 +1269,6 @@
     <ClCompile Include="..\platform\win\PopupMenuWin.cpp">
       <Filter>platform\win</Filter>
     </ClCompile>
-    <ClCompile Include="..\platform\win\ScrollbarThemeSafari.cpp">
-      <Filter>platform\win</Filter>
-    </ClCompile>
     <ClCompile Include="..\platform\win\ScrollbarThemeWin.cpp">
       <Filter>platform\win</Filter>
     </ClCompile>
@@ -2673,9 +2670,6 @@
     <ClCompile Include="..\rendering\RenderTheme.cpp">
       <Filter>rendering</Filter>
     </ClCompile>
-    <ClCompile Include="..\rendering\RenderThemeSafari.cpp">
-      <Filter>rendering</Filter>
-    </ClCompile>
     <ClCompile Include="..\rendering\RenderThemeWin.cpp">
       <Filter>rendering</Filter>
     </ClCompile>
@@ -8340,9 +8334,6 @@
     <ClInclude Include="..\platform\win\PopupMenuWin.h">
       <Filter>platform\win</Filter>
     </ClInclude>
-    <ClInclude Include="..\platform\win\ScrollbarThemeSafari.h">
-      <Filter>platform\win</Filter>
-    </ClInclude>
     <ClInclude Include="..\platform\win\ScrollbarThemeWin.h">
       <Filter>platform\win</Filter>
     </ClInclude>
@@ -15395,9 +15386,6 @@
     <CustomBuildStep Include="..\rendering\RenderMediaControls.h">
       <Filter>rendering</Filter>
     </CustomBuildStep>
-    <CustomBuildStep Include="..\rendering\RenderThemeSafari.h">
-      <Filter>rendering</Filter>
-    </CustomBuildStep>
     <CustomBuildStep Include="..\rendering\RenderThemeWin.h">
       <Filter>rendering</Filter>
     </CustomBuildStep>

Modified: trunk/Source/WebCore/config.h (180764 => 180765)


--- trunk/Source/WebCore/config.h	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebCore/config.h	2015-02-27 18:09:46 UTC (rev 180765)
@@ -116,10 +116,6 @@
 #endif
 #endif /* USE(CG) */
 
-#if PLATFORM(WIN) && USE(CG)
-#define WTF_USE_SAFARI_THEME 1
-#endif
-
 #if PLATFORM(IOS)
 #define WEBCORE_NAVIGATOR_PLATFORM wkGetPlatformNameForNavigator();
 #define WEBCORE_NAVIGATOR_VENDOR wkGetVendorNameForNavigator();

Modified: trunk/Source/WebCore/page/Settings.cpp (180764 => 180765)


--- trunk/Source/WebCore/page/Settings.cpp	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebCore/page/Settings.cpp	2015-02-27 18:09:46 UTC (rev 180765)
@@ -73,10 +73,6 @@
 double Settings::gDefaultDOMTimerAlignmentInterval = 0;
 double Settings::gHiddenPageDOMTimerAlignmentInterval = 1.0;
 
-#if USE(SAFARI_THEME)
-bool Settings::gShouldPaintNativeControls = true;
-#endif
-
 #if USE(AVFOUNDATION)
 bool Settings::gAVFoundationEnabled = false;
 #endif
@@ -529,13 +525,6 @@
     return static_cast<FontRenderingMode>(m_fontRenderingMode);
 }
 
-#if USE(SAFARI_THEME)
-void Settings::setShouldPaintNativeControls(bool shouldPaintNativeControls)
-{
-    gShouldPaintNativeControls = shouldPaintNativeControls;
-}
-#endif
-
 void Settings::setDNSPrefetchingEnabled(bool dnsPrefetchingEnabled)
 {
     if (m_dnsPrefetchingEnabled == dnsPrefetchingEnabled)

Modified: trunk/Source/WebCore/page/Settings.h (180764 => 180765)


--- trunk/Source/WebCore/page/Settings.h	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebCore/page/Settings.h	2015-02-27 18:09:46 UTC (rev 180765)
@@ -214,12 +214,6 @@
 
     static const unsigned defaultMaximumHTMLParserDOMTreeDepth = 512;
 
-#if USE(SAFARI_THEME)
-    // Windows debugging pref (global) for switching between the Aqua look and a native windows look.
-    static void setShouldPaintNativeControls(bool);
-    static bool shouldPaintNativeControls() { return gShouldPaintNativeControls; }
-#endif
-
     WEBCORE_EXPORT static void setMockScrollbarsEnabled(bool flag);
     WEBCORE_EXPORT static bool mockScrollbarsEnabled();
 
@@ -340,9 +334,6 @@
     static bool gMockScrollbarsEnabled;
     static bool gUsesOverlayScrollbars;
 
-#if USE(SAFARI_THEME)
-    static bool gShouldPaintNativeControls;
-#endif
 #if PLATFORM(WIN)
     static bool gShouldUseHighResolutionTimers;
 #endif

Modified: trunk/Source/WebCore/platform/win/ScrollbarThemeWin.cpp (180764 => 180765)


--- trunk/Source/WebCore/platform/win/ScrollbarThemeWin.cpp	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebCore/platform/win/ScrollbarThemeWin.cpp	2015-02-27 18:09:46 UTC (rev 180765)
@@ -87,13 +87,11 @@
         scrollbarTheme = OpenThemeData(0, L"Scrollbar");
 }
 
-#if !USE(SAFARI_THEME)
 ScrollbarTheme* ScrollbarTheme::nativeTheme()
 {
     static ScrollbarThemeWin winTheme;
     return &winTheme;
 }
-#endif
 
 ScrollbarThemeWin::ScrollbarThemeWin()
 {

Modified: trunk/Source/WebCore/rendering/RenderThemeWin.cpp (180764 => 180765)


--- trunk/Source/WebCore/rendering/RenderThemeWin.cpp	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebCore/rendering/RenderThemeWin.cpp	2015-02-27 18:09:46 UTC (rev 180765)
@@ -187,13 +187,11 @@
     return adoptRef(new RenderThemeWin);
 }
 
-#if !USE(SAFARI_THEME)
 PassRefPtr<RenderTheme> RenderTheme::themeForPage(Page* page)
 {
     static RenderTheme* winTheme = RenderThemeWin::create().leakRef();
     return winTheme;
 }
-#endif
 
 RenderThemeWin::RenderThemeWin()
     : m_buttonTheme(0)

Modified: trunk/Source/WebKit/win/ChangeLog (180764 => 180765)


--- trunk/Source/WebKit/win/ChangeLog	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebKit/win/ChangeLog	2015-02-27 18:09:46 UTC (rev 180765)
@@ -1,3 +1,28 @@
+2015-02-26  Brent Fulgham  <bfulg...@apple.com>
+
+        [Win] Remove remaining SafariTheme cruft
+        https://bugs.webkit.org/show_bug.cgi?id=142075
+
+        Reviewed by Anders Carlsson.
+
+        Remove reference to SafariTheme-switching preference.
+
+        * Interfaces/IWebPreferencesPrivate.idl:
+        * WebKitClassFactory.cpp:
+        (WebKitClassFactory::WebKitClassFactory):
+        (WebKitClassFactory::QueryInterface):
+        (WebKitClassFactory::AddRef):
+        (WebKitClassFactory::Release):
+        (WebKitClassFactory::CreateInstance):
+        (WebKitClassFactory::LockServer):
+        * WebPreferences.cpp:
+        (WebPreferences::shouldPaintNativeControls): Deleted.
+        (WebPreferences::setShouldPaintNativeControls): Deleted.
+        * WebPreferences.h:
+        * WebView.cpp:
+        (WebView::initWithFrame):
+        (WebView::notifyPreferencesChanged):
+
 2015-02-26  Chris Dumez  <cdu...@apple.com>
 
         Rename DatabaseManager::manager() to DatabaseManager::singleton()

Modified: trunk/Source/WebKit/win/Interfaces/IWebPreferencesPrivate.idl (180764 => 180765)


--- trunk/Source/WebKit/win/Interfaces/IWebPreferencesPrivate.idl	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebKit/win/Interfaces/IWebPreferencesPrivate.idl	2015-02-27 18:09:46 UTC (rev 180765)
@@ -58,9 +58,6 @@
     HRESULT localStorageDatabasePath([out, retval] BSTR* location);
     HRESULT setLocalStorageDatabasePath([in] BSTR location);
 
-    HRESULT setShouldPaintNativeControls([in] BOOL shouldPaint);
-    HRESULT shouldPaintNativeControls([out, retval] BOOL* enabled);
-
     HRESULT setDatabasesEnabled([in] BOOL enabled);
     HRESULT databasesEnabled([out, retval] BOOL *enabled);
 

Modified: trunk/Source/WebKit/win/WebKitClassFactory.cpp (180764 => 180765)


--- trunk/Source/WebKit/win/WebKitClassFactory.cpp	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebKit/win/WebKitClassFactory.cpp	2015-02-27 18:09:46 UTC (rev 180765)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2006, 2007, 2014 Apple Inc.  All rights reserved.
+ * Copyright (C) 2006, 2007, 2014-2015 Apple Inc.  All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
@@ -61,29 +61,10 @@
 #include <wtf/MainThread.h>
 
 // WebKitClassFactory ---------------------------------------------------------
-#if USE(SAFARI_THEME)
-#ifdef DEBUG_ALL
-SOFT_LINK_DEBUG_LIBRARY(SafariTheme)
-#else
-SOFT_LINK_LIBRARY(SafariTheme)
-#endif
-
-SOFT_LINK(SafariTheme, STInitialize, void, APIENTRY, (), ())
-#endif
-
 WebKitClassFactory::WebKitClassFactory(CLSID targetClass)
 : m_targetClass(targetClass)
 , m_refCount(0)
 {
-#if USE(SAFARI_THEME)
-    static bool didInitializeSafariTheme;
-    if (!didInitializeSafariTheme) {
-        if (SafariThemeLibrary())
-            STInitialize();
-        didInitializeSafariTheme = true;
-    }
-#endif
-
     JSC::initializeThreading();
     WTF::initializeMainThread();
 
@@ -98,8 +79,7 @@
 }
 
 // IUnknown -------------------------------------------------------------------
-
-HRESULT STDMETHODCALLTYPE WebKitClassFactory::QueryInterface(REFIID riid, void** ppvObject)
+HRESULT WebKitClassFactory::QueryInterface(REFIID riid, void** ppvObject)
 {
     *ppvObject = 0;
     if (IsEqualGUID(riid, IID_IUnknown))
@@ -113,12 +93,12 @@
     return S_OK;
 }
 
-ULONG STDMETHODCALLTYPE WebKitClassFactory::AddRef(void)
+ULONG WebKitClassFactory::AddRef(void)
 {
     return ++m_refCount;
 }
 
-ULONG STDMETHODCALLTYPE WebKitClassFactory::Release(void)
+ULONG WebKitClassFactory::Release(void)
 {
     ULONG newRef = --m_refCount;
     if (!newRef && !gLockCount)
@@ -141,8 +121,7 @@
 }
 
 // IClassFactory --------------------------------------------------------------
-
-HRESULT STDMETHODCALLTYPE WebKitClassFactory::CreateInstance(IUnknown* pUnkOuter, REFIID riid, void** ppvObject)
+HRESULT WebKitClassFactory::CreateInstance(IUnknown* pUnkOuter, REFIID riid, void** ppvObject)
 {
     IUnknown* unknown = 0;
     *ppvObject = 0;
@@ -182,7 +161,7 @@
     return hr;
 }
 
-HRESULT STDMETHODCALLTYPE WebKitClassFactory::LockServer(BOOL fLock)
+HRESULT WebKitClassFactory::LockServer(BOOL fLock)
 {
     if (fLock)
         gLockCount++;

Modified: trunk/Source/WebKit/win/WebPreferences.cpp (180764 => 180765)


--- trunk/Source/WebKit/win/WebPreferences.cpp	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebKit/win/WebPreferences.cpp	2015-02-27 18:09:46 UTC (rev 180765)
@@ -1412,18 +1412,6 @@
     return E_FAIL;
 }
 
-HRESULT WebPreferences::shouldPaintNativeControls(BOOL* shouldPaint)
-{
-    *shouldPaint = boolValueForKey(WebKitPaintNativeControlsPreferenceKey);
-    return S_OK;
-}
-
-HRESULT WebPreferences::setShouldPaintNativeControls(BOOL shouldPaint)
-{
-    setBoolValue(WebKitPaintNativeControlsPreferenceKey, shouldPaint);
-    return S_OK;
-}
-
 HRESULT WebPreferences::setDeveloperExtrasEnabled(BOOL enabled)
 {
     setBoolValue(WebKitDeveloperExtrasEnabledPreferenceKey, enabled);

Modified: trunk/Source/WebKit/win/WebPreferences.h (180764 => 180765)


--- trunk/Source/WebKit/win/WebPreferences.h	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebKit/win/WebPreferences.h	2015-02-27 18:09:46 UTC (rev 180765)
@@ -377,12 +377,6 @@
     virtual HRESULT STDMETHODCALLTYPE setExperimentalNotificationsEnabled(
         /* [in] */ BOOL enabled);
 
-    virtual HRESULT STDMETHODCALLTYPE setShouldPaintNativeControls( 
-    /* [in] */ BOOL shouldPaint);
-
-    virtual HRESULT STDMETHODCALLTYPE shouldPaintNativeControls( 
-    /* [retval][out] */ BOOL *shouldPaint);
-
     virtual HRESULT STDMETHODCALLTYPE setZoomsTextOnly( 
     /* [retval][out] */ BOOL zoomsTextOnly);
 

Modified: trunk/Source/WebKit/win/WebView.cpp (180764 => 180765)


--- trunk/Source/WebKit/win/WebView.cpp	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Source/WebKit/win/WebView.cpp	2015-02-27 18:09:46 UTC (rev 180765)
@@ -2788,12 +2788,6 @@
         didOneTimeInitialization = true;
      }
 
-#if USE(SAFARI_THEME)
-    BOOL shouldPaintNativeControls;
-    if (SUCCEEDED(m_preferences->shouldPaintNativeControls(&shouldPaintNativeControls)))
-        Settings::setShouldPaintNativeControls(shouldPaintNativeControls);
-#endif
-
     BOOL useHighResolutionTimer;
     if (SUCCEEDED(m_preferences->shouldUseHighResolutionTimers(&useHighResolutionTimer)))
         Settings::setShouldUseHighResolutionTimers(useHighResolutionTimer);
@@ -5033,13 +5027,6 @@
         return hr;
     settings.setXSSAuditorEnabled(!!enabled);
 
-#if USE(SAFARI_THEME)
-    hr = prefsPrivate->shouldPaintNativeControls(&enabled);
-    if (FAILED(hr))
-        return hr;
-    settings.setShouldPaintNativeControls(!!enabled);
-#endif
-
     hr = prefsPrivate->shouldUseHighResolutionTimers(&enabled);
     if (FAILED(hr))
         return hr;

Modified: trunk/Tools/ChangeLog (180764 => 180765)


--- trunk/Tools/ChangeLog	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Tools/ChangeLog	2015-02-27 18:09:46 UTC (rev 180765)
@@ -1,3 +1,16 @@
+2015-02-26  Brent Fulgham  <bfulg...@apple.com>
+
+        [Win] Remove remaining SafariTheme cruft
+        https://bugs.webkit.org/show_bug.cgi?id=142075
+
+        Reviewed by Anders Carlsson.
+
+        Remove reference to SafariTheme-switching preference.
+
+        * DumpRenderTree/win/DumpRenderTree.cpp:
+        (resetWebPreferencesToConsistentValues):
+        (prepareConsistentTestingEnvironment):
+
 2015-02-26  Doug Russell  <d_russ...@apple.com>
 
         AX: Expose caret browsing preference to accessibility API

Modified: trunk/Tools/DumpRenderTree/win/DumpRenderTree.cpp (180764 => 180765)


--- trunk/Tools/DumpRenderTree/win/DumpRenderTree.cpp	2015-02-27 17:49:22 UTC (rev 180764)
+++ trunk/Tools/DumpRenderTree/win/DumpRenderTree.cpp	2015-02-27 18:09:46 UTC (rev 180765)
@@ -839,7 +839,6 @@
     preferences->setCSSRegionsEnabled(TRUE);
     // Set uses HTML5 parser quirks: NO
     // Async spellcheck: NO
-    prefsPrivate->setShouldPaintNativeControls(TRUE);
     prefsPrivate->setMockScrollbarsEnabled(TRUE);
 
     preferences->setFontSmoothing(FontSmoothingTypeStandard);
@@ -1378,7 +1377,6 @@
     ASSERT(standardPreferencesPrivate);
     standardPreferences->setAutosaves(FALSE);
 
-    standardPreferencesPrivate->setShouldPaintNativeControls(TRUE);
     standardPreferences->setJavaScriptEnabled(TRUE);
     standardPreferences->setDefaultFontSize(16);
 #if USE(CG)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to