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

Side by Side Diff: content/renderer/render_view_impl.cc

Issue 561453004: Add RenderView ResetDeviceColorProfileForTesting (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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
« no previous file with comments | « content/renderer/render_view_impl.h ('k') | content/renderer/render_widget.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/renderer/render_view_impl.h" 5 #include "content/renderer/render_view_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 9
10 #include "base/auto_reset.h" 10 #include "base/auto_reset.h"
(...skipping 3663 matching lines...) Expand 10 before | Expand all | Expand 10 after
3674 bool RenderViewImpl::SetDeviceColorProfile( 3674 bool RenderViewImpl::SetDeviceColorProfile(
3675 const std::vector<char>& profile) { 3675 const std::vector<char>& profile) {
3676 bool changed = RenderWidget::SetDeviceColorProfile(profile); 3676 bool changed = RenderWidget::SetDeviceColorProfile(profile);
3677 if (changed && webview()) { 3677 if (changed && webview()) {
3678 // TODO(noel): notify the webview() of the color profile change so it 3678 // TODO(noel): notify the webview() of the color profile change so it
3679 // can update and repaint all color profiled page elements. 3679 // can update and repaint all color profiled page elements.
3680 } 3680 }
3681 return changed; 3681 return changed;
3682 } 3682 }
3683 3683
3684 void RenderViewImpl::ResetDeviceColorProfileForTesting() {
3685 RenderWidget::ResetDeviceColorProfileForTesting();
3686 if (webview())
3687 webview()->resetDeviceColorProfile();
3688 }
3689
3684 ui::TextInputType RenderViewImpl::GetTextInputType() { 3690 ui::TextInputType RenderViewImpl::GetTextInputType() {
3685 #if defined(ENABLE_PLUGINS) 3691 #if defined(ENABLE_PLUGINS)
3686 if (focused_pepper_plugin_) 3692 if (focused_pepper_plugin_)
3687 return focused_pepper_plugin_->text_input_type(); 3693 return focused_pepper_plugin_->text_input_type();
3688 #endif 3694 #endif
3689 return RenderWidget::GetTextInputType(); 3695 return RenderWidget::GetTextInputType();
3690 } 3696 }
3691 3697
3692 void RenderViewImpl::GetSelectionBounds(gfx::Rect* start, gfx::Rect* end) { 3698 void RenderViewImpl::GetSelectionBounds(gfx::Rect* start, gfx::Rect* end) {
3693 #if defined(ENABLE_PLUGINS) 3699 #if defined(ENABLE_PLUGINS)
(...skipping 506 matching lines...) Expand 10 before | Expand all | Expand 10 after
4200 std::vector<gfx::Size> sizes; 4206 std::vector<gfx::Size> sizes;
4201 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); 4207 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes);
4202 if (!url.isEmpty()) 4208 if (!url.isEmpty())
4203 urls.push_back( 4209 urls.push_back(
4204 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); 4210 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes));
4205 } 4211 }
4206 SendUpdateFaviconURL(urls); 4212 SendUpdateFaviconURL(urls);
4207 } 4213 }
4208 4214
4209 } // namespace content 4215 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/render_view_impl.h ('k') | content/renderer/render_widget.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698