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

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

Issue 10834079: views: Extract Widget observer into its own header file. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 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
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_frame.h" 5 #include "chrome/browser/ui/views/frame/browser_frame.h"
6 6
7 #include "base/chromeos/chromeos_version.h" 7 #include "base/chromeos/chromeos_version.h"
8 #include "base/i18n/rtl.h" 8 #include "base/i18n/rtl.h"
9 #include "chrome/browser/themes/theme_service.h" 9 #include "chrome/browser/themes/theme_service.h"
10 #include "chrome/browser/themes/theme_service_factory.h" 10 #include "chrome/browser/themes/theme_service_factory.h"
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 } 129 }
130 #endif 130 #endif
131 return browser_frame_view_; 131 return browser_frame_view_;
132 } 132 }
133 133
134 bool BrowserFrame::GetAccelerator(int command_id, 134 bool BrowserFrame::GetAccelerator(int command_id,
135 ui::Accelerator* accelerator) { 135 ui::Accelerator* accelerator) {
136 return browser_view_->GetAccelerator(command_id, accelerator); 136 return browser_view_->GetAccelerator(command_id, accelerator);
137 } 137 }
138 138
139 ThemeProvider* BrowserFrame::GetThemeProvider() const { 139 ui::ThemeProvider* BrowserFrame::GetThemeProvider() const {
140 return ThemeServiceFactory::GetForProfile( 140 return ThemeServiceFactory::GetForProfile(
141 browser_view_->browser()->profile()); 141 browser_view_->browser()->profile());
142 } 142 }
143 143
144 void BrowserFrame::OnNativeWidgetActivationChanged(bool active) { 144 void BrowserFrame::OnNativeWidgetActivationChanged(bool active) {
145 if (active) { 145 if (active) {
146 // When running under remote desktop, if the remote desktop client is not 146 // When running under remote desktop, if the remote desktop client is not
147 // active on the users desktop, then none of the windows contained in the 147 // active on the users desktop, then none of the windows contained in the
148 // remote desktop will be activated. However, NativeWidgetWin::Activate() 148 // remote desktop will be activated. However, NativeWidgetWin::Activate()
149 // will still bring this browser window to the foreground. We explicitly 149 // will still bring this browser window to the foreground. We explicitly
150 // set ourselves as the last active browser window to ensure that we get 150 // set ourselves as the last active browser window to ensure that we get
151 // treated as such by the rest of Chrome. 151 // treated as such by the rest of Chrome.
152 BrowserList::SetLastActive(browser_view_->browser()); 152 BrowserList::SetLastActive(browser_view_->browser());
153 } 153 }
154 Widget::OnNativeWidgetActivationChanged(active); 154 Widget::OnNativeWidgetActivationChanged(active);
155 } 155 }
156 156
157 AvatarMenuButton* BrowserFrame::GetAvatarMenuButton() { 157 AvatarMenuButton* BrowserFrame::GetAvatarMenuButton() {
158 return browser_frame_view_->avatar_button(); 158 return browser_frame_view_->avatar_button();
159 } 159 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/frame/app_non_client_frame_view_aura.h ('k') | chrome/browser/ui/views/frame/browser_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698