From 6464b4c1fa4b1553547dbf9096ddc8209bc555c8 Mon Sep 17 00:00:00 2001
From: "mihaip@chromium.org"
 <mihaip@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Thu, 30 Dec 2010 19:41:24 +0000
Subject: [PATCH] Expose Mac WebThemeEngine hooks added by r70278 (and r74581
 on the WebKit side) to test_shell/DRT.

BUG=23498
TEST=Layout tests

Review URL: http://codereview.chromium.org/6090002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70319 0039d316-1c4b-4281-b951-d872f2087c98
---
 webkit/support/test_webkit_client.cc | 2 +-
 webkit/support/test_webkit_client.h  | 4 ++--
 webkit/support/webkit_support.cc     | 4 ++--
 webkit/support/webkit_support.h      | 2 +-
 4 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/webkit/support/test_webkit_client.cc b/webkit/support/test_webkit_client.cc
index e45c263314acb..0360d29157ece 100644
--- a/webkit/support/test_webkit_client.cc
+++ b/webkit/support/test_webkit_client.cc
@@ -331,7 +331,7 @@ void TestWebKitClient::createIDBKeysFromSerializedValuesAndKeyPath(
   keys_out.swap(keys);
 }
 
-#if defined(OS_WIN)
+#if defined(OS_WIN) || defined(OS_MACOSX)
 void TestWebKitClient::SetThemeEngine(WebKit::WebThemeEngine* engine) {
   active_theme_engine_ = engine ? engine : WebKitClientImpl::themeEngine();
 }
diff --git a/webkit/support/test_webkit_client.h b/webkit/support/test_webkit_client.h
index 07beae7921390..93bb693681b3f 100644
--- a/webkit/support/test_webkit_client.h
+++ b/webkit/support/test_webkit_client.h
@@ -68,7 +68,7 @@ class TestWebKitClient : public webkit_glue::WebKitClientImpl {
       const WebKit::WebString& keyPath,
       WebKit::WebVector<WebKit::WebIDBKey>& keys_out);
 
-#if defined(OS_WIN)
+#if defined(OS_WIN) || defined(OS_MACOSX)
   void SetThemeEngine(WebKit::WebThemeEngine* engine);
   virtual WebKit::WebThemeEngine *themeEngine();
 #endif
@@ -98,7 +98,7 @@ class TestWebKitClient : public webkit_glue::WebKitClientImpl {
   WebURLLoaderMockFactory url_loader_factory_;
   bool unit_test_mode_;
 
-#if defined(OS_WIN)
+#if defined(OS_WIN) || defined(OS_MACOSX)
   WebKit::WebThemeEngine* active_theme_engine_;
 #endif
   DISALLOW_COPY_AND_ASSIGN(TestWebKitClient);
diff --git a/webkit/support/webkit_support.cc b/webkit/support/webkit_support.cc
index d088d3caccaab..e9eed2e631836 100644
--- a/webkit/support/webkit_support.cc
+++ b/webkit/support/webkit_support.cc
@@ -125,7 +125,7 @@ class TestEnvironment {
 
   TestWebKitClient* webkit_client() const { return webkit_client_.get(); }
 
-#if defined(OS_WIN)
+#if defined(OS_WIN) || defined(OS_MACOSX)
   void set_theme_engine(WebKit::WebThemeEngine* engine) {
     DCHECK(webkit_client_ != 0);
     webkit_client_->SetThemeEngine(engine);
@@ -490,7 +490,7 @@ void SetAcceptAllCookies(bool accept) {
 }
 
 // Theme engine
-#if defined(OS_WIN)
+#if defined(OS_WIN) || defined(OS_MACOSX)
 
 void SetThemeEngine(WebKit::WebThemeEngine* engine) {
   DCHECK(test_environment);
diff --git a/webkit/support/webkit_support.h b/webkit/support/webkit_support.h
index b835ef2123f5a..321a0bbd26153 100644
--- a/webkit/support/webkit_support.h
+++ b/webkit/support/webkit_support.h
@@ -146,7 +146,7 @@ void ClearAllDatabases();
 void SetAcceptAllCookies(bool accept);
 
 // - Theme engine
-#if defined(OS_WIN)
+#if defined(OS_WIN) || defined(OS_MACOSX)
 void SetThemeEngine(WebKit::WebThemeEngine* engine);
 WebKit::WebThemeEngine* GetThemeEngine();
 #endif
-- 
GitLab