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

Side by Side Diff: chrome/browser/ui/views/frame/browser_desktop_window_tree_host_win.cc

Issue 171413002: linux_aura: Keep GTK state from leaking between profiles. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix mac compile. Created 6 years, 10 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 | « chrome/browser/ui/libgtk2ui/gtk2_ui.cc ('k') | ui/base/default_theme_provider.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 "chrome/browser/ui/views/frame/browser_desktop_window_tree_host_win.h" 5 #include "chrome/browser/ui/views/frame/browser_desktop_window_tree_host_win.h"
6 6
7 #include <dwmapi.h> 7 #include <dwmapi.h>
8 8
9 #include "chrome/browser/lifetime/application_lifetime.h" 9 #include "chrome/browser/lifetime/application_lifetime.h"
10 #include "chrome/browser/themes/theme_service.h" 10 #include "chrome/browser/themes/theme_service.h"
(...skipping 21 matching lines...) Expand all
32 32
33 // DesktopThemeProvider maps resource ids using MapThemeImage(). This is 33 // DesktopThemeProvider maps resource ids using MapThemeImage(). This is
34 // necessary for BrowserDesktopWindowTreeHostWin so that it uses the windows 34 // necessary for BrowserDesktopWindowTreeHostWin so that it uses the windows
35 // theme images rather than the ash theme images. 35 // theme images rather than the ash theme images.
36 class DesktopThemeProvider : public ui::ThemeProvider { 36 class DesktopThemeProvider : public ui::ThemeProvider {
37 public: 37 public:
38 explicit DesktopThemeProvider(ui::ThemeProvider* delegate) 38 explicit DesktopThemeProvider(ui::ThemeProvider* delegate)
39 : delegate_(delegate) { 39 : delegate_(delegate) {
40 } 40 }
41 41
42 virtual bool UsingNativeTheme() const OVERRIDE {
43 return delegate_->UsingNativeTheme();
44 }
42 virtual gfx::ImageSkia* GetImageSkiaNamed(int id) const OVERRIDE { 45 virtual gfx::ImageSkia* GetImageSkiaNamed(int id) const OVERRIDE {
43 return delegate_->GetImageSkiaNamed( 46 return delegate_->GetImageSkiaNamed(
44 chrome::MapThemeImage(chrome::HOST_DESKTOP_TYPE_NATIVE, id)); 47 chrome::MapThemeImage(chrome::HOST_DESKTOP_TYPE_NATIVE, id));
45 } 48 }
46 virtual SkColor GetColor(int id) const OVERRIDE { 49 virtual SkColor GetColor(int id) const OVERRIDE {
47 return delegate_->GetColor(id); 50 return delegate_->GetColor(id);
48 } 51 }
49 virtual int GetDisplayProperty(int id) const OVERRIDE { 52 virtual int GetDisplayProperty(int id) const OVERRIDE {
50 return delegate_->GetDisplayProperty(id); 53 return delegate_->GetDisplayProperty(id);
51 } 54 }
(...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after
325 BrowserDesktopWindowTreeHost::CreateBrowserDesktopWindowTreeHost( 328 BrowserDesktopWindowTreeHost::CreateBrowserDesktopWindowTreeHost(
326 views::internal::NativeWidgetDelegate* native_widget_delegate, 329 views::internal::NativeWidgetDelegate* native_widget_delegate,
327 views::DesktopNativeWidgetAura* desktop_native_widget_aura, 330 views::DesktopNativeWidgetAura* desktop_native_widget_aura,
328 BrowserView* browser_view, 331 BrowserView* browser_view,
329 BrowserFrame* browser_frame) { 332 BrowserFrame* browser_frame) {
330 return new BrowserDesktopWindowTreeHostWin(native_widget_delegate, 333 return new BrowserDesktopWindowTreeHostWin(native_widget_delegate,
331 desktop_native_widget_aura, 334 desktop_native_widget_aura,
332 browser_view, 335 browser_view,
333 browser_frame); 336 browser_frame);
334 } 337 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/libgtk2ui/gtk2_ui.cc ('k') | ui/base/default_theme_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698