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

Side by Side Diff: content/browser/webui/web_ui_impl.cc

Issue 293563002: GetScaleFactorForNativeView should return scale factor in float (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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 | « content/browser/webui/web_ui_impl.h ('k') | content/public/browser/web_ui.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "content/browser/webui/web_ui_impl.h" 5 #include "content/browser/webui/web_ui_impl.h"
6 6
7 #include "base/json/json_writer.h" 7 #include "base/json/json_writer.h"
8 #include "base/strings/utf_string_conversions.h" 8 #include "base/strings/utf_string_conversions.h"
9 #include "base/values.h" 9 #include "base/values.h"
10 #include "content/browser/child_process_security_policy_impl.h" 10 #include "content/browser/child_process_security_policy_impl.h"
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 91
92 #if defined(TOOLKIT_VIEWS) 92 #if defined(TOOLKIT_VIEWS)
93 render_view_host->SetWebUIProperty("toolkit", "views"); 93 render_view_host->SetWebUIProperty("toolkit", "views");
94 #endif // defined(TOOLKIT_VIEWS) 94 #endif // defined(TOOLKIT_VIEWS)
95 } 95 }
96 96
97 WebContents* WebUIImpl::GetWebContents() const { 97 WebContents* WebUIImpl::GetWebContents() const {
98 return web_contents_; 98 return web_contents_;
99 } 99 }
100 100
101 ui::ScaleFactor WebUIImpl::GetDeviceScaleFactor() const { 101 float WebUIImpl::GetDeviceScaleFactor() const {
102 return GetScaleFactorForView(web_contents_->GetRenderWidgetHostView()); 102 return GetScaleFactorForView(web_contents_->GetRenderWidgetHostView());
103 } 103 }
104 104
105 const base::string16& WebUIImpl::GetOverriddenTitle() const { 105 const base::string16& WebUIImpl::GetOverriddenTitle() const {
106 return overridden_title_; 106 return overridden_title_;
107 } 107 }
108 108
109 void WebUIImpl::OverrideTitle(const base::string16& title) { 109 void WebUIImpl::OverrideTitle(const base::string16& title) {
110 overridden_title_ = title; 110 overridden_title_ = title;
111 } 111 }
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
250 } 250 }
251 251
252 void WebUIImpl::AddToSetIfFrameNameMatches( 252 void WebUIImpl::AddToSetIfFrameNameMatches(
253 std::set<RenderFrameHost*>* frame_set, 253 std::set<RenderFrameHost*>* frame_set,
254 RenderFrameHost* host) { 254 RenderFrameHost* host) {
255 if (host->GetFrameName() == frame_name_) 255 if (host->GetFrameName() == frame_name_)
256 frame_set->insert(host); 256 frame_set->insert(host);
257 } 257 }
258 258
259 } // namespace content 259 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/webui/web_ui_impl.h ('k') | content/public/browser/web_ui.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698