Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(29)

Side by Side Diff: webkit/glue/webpreferences.cc

Issue 293001: Delete glue/webview{_delegate}.h (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « webkit/glue/webpreferences.h ('k') | webkit/glue/webview.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "webkit/glue/webpreferences.h" 5 #include "webkit/glue/webpreferences.h"
6 6
7 #include "base/string_util.h" 7 #include "base/string_util.h"
8 #include "webkit/api/public/WebKit.h" 8 #include "webkit/api/public/WebKit.h"
9 #include "webkit/api/public/WebSettings.h" 9 #include "webkit/api/public/WebSettings.h"
10 #include "webkit/api/public/WebString.h" 10 #include "webkit/api/public/WebString.h"
11 #include "webkit/api/public/WebURL.h" 11 #include "webkit/api/public/WebURL.h"
12 #include "webkit/api/public/WebView.h"
12 #include "webkit/glue/webkit_glue.h" 13 #include "webkit/glue/webkit_glue.h"
13 #include "webkit/glue/webview.h"
14 14
15 using WebKit::WebSettings; 15 using WebKit::WebSettings;
16 using WebKit::WebString; 16 using WebKit::WebString;
17 using WebKit::WebURL; 17 using WebKit::WebURL;
18 using WebKit::WebView;
18 19
19 void WebPreferences::Apply(WebView* web_view) const { 20 void WebPreferences::Apply(WebView* web_view) const {
20 WebSettings* settings = web_view->settings(); 21 WebSettings* settings = web_view->settings();
21 settings->setStandardFontFamily(WideToUTF16Hack(standard_font_family)); 22 settings->setStandardFontFamily(WideToUTF16Hack(standard_font_family));
22 settings->setFixedFontFamily(WideToUTF16Hack(fixed_font_family)); 23 settings->setFixedFontFamily(WideToUTF16Hack(fixed_font_family));
23 settings->setSerifFontFamily(WideToUTF16Hack(serif_font_family)); 24 settings->setSerifFontFamily(WideToUTF16Hack(serif_font_family));
24 settings->setSansSerifFontFamily(WideToUTF16Hack(sans_serif_font_family)); 25 settings->setSansSerifFontFamily(WideToUTF16Hack(sans_serif_font_family));
25 settings->setCursiveFontFamily(WideToUTF16Hack(cursive_font_family)); 26 settings->setCursiveFontFamily(WideToUTF16Hack(cursive_font_family));
26 settings->setFantasyFontFamily(WideToUTF16Hack(fantasy_font_family)); 27 settings->setFantasyFontFamily(WideToUTF16Hack(fantasy_font_family));
27 settings->setDefaultFontSize(default_font_size); 28 settings->setDefaultFontSize(default_font_size);
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 // and support is compiled in. 84 // and support is compiled in.
84 settings->setExperimentalWebGLEnabled(experimental_webgl_enabled); 85 settings->setExperimentalWebGLEnabled(experimental_webgl_enabled);
85 86
86 // Web inspector settings need to be passed in differently. 87 // Web inspector settings need to be passed in differently.
87 web_view->setInspectorSettings(WebString::fromUTF8(inspector_settings)); 88 web_view->setInspectorSettings(WebString::fromUTF8(inspector_settings));
88 89
89 // Tabs to link is not part of the settings. WebCore calls 90 // Tabs to link is not part of the settings. WebCore calls
90 // ChromeClient::tabsToLinks which is part of the glue code. 91 // ChromeClient::tabsToLinks which is part of the glue code.
91 web_view->setTabsToLinks(tabs_to_links); 92 web_view->setTabsToLinks(tabs_to_links);
92 } 93 }
OLDNEW
« no previous file with comments | « webkit/glue/webpreferences.h ('k') | webkit/glue/webview.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698