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

Unified Diff: chrome/browser/ui/views/aura/chrome_shell_delegate.cc

Issue 9295049: Allow focus to be sent between browser window and launcher/status window (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/aura/chrome_shell_delegate.cc
diff --git a/chrome/browser/ui/views/aura/chrome_shell_delegate.cc b/chrome/browser/ui/views/aura/chrome_shell_delegate.cc
index b182cf0b0fadeed180f611793a1a8c9e56de4b4a..c24357d81a0408687d3a1afe0f60778b4eb4a444 100644
--- a/chrome/browser/ui/views/aura/chrome_shell_delegate.cc
+++ b/chrome/browser/ui/views/aura/chrome_shell_delegate.cc
@@ -7,6 +7,7 @@
#include "ash/launcher/launcher_types.h"
#include "ash/wm/window_util.h"
#include "base/command_line.h"
+#include "chrome/browser/chromeos/status/status_area_view.h"
#include "chrome/browser/defaults.h"
#include "chrome/browser/prefs/incognito_mode_prefs.h"
#include "chrome/browser/profiles/profile_manager.h"
@@ -111,6 +112,20 @@ std::vector<aura::Window*> ChromeShellDelegate::GetCycleWindowList(
return windows;
}
+void ChromeShellDelegate::RotateFocus(bool forward) {
+ if (!forward) {
+ StatusAreaView* status_area =
+ ChromeShellDelegate::instance()->GetStatusArea();
+ if (status_area->SetPaneFocusAndFocusDefault()) {
+ status_area->GetWidget()->Activate();
+ return;
+ }
+ // If we can't focus the status area, fall through and focus the browser.
+ }
+
+ // TODO: Focus Browser
+}
+
void ChromeShellDelegate::CreateNewWindow() {
Profile* profile = ProfileManager::GetDefaultProfile();
if (browser_defaults::kAlwaysOpenIncognitoWindow &&

Powered by Google App Engine
This is Rietveld 408576698