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

Side by Side Diff: chrome/browser/ui/ash/chrome_shell_delegate_chromeos.cc

Issue 232133005: ozone: Protect X11-specific code under ash (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase, one more X11 line showed up Created 6 years, 8 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/ash/ash_init.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/ash/chrome_shell_delegate.h" 5 #include "chrome/browser/ui/ash/chrome_shell_delegate.h"
6 6
7 #include "ash/accelerators/magnifier_key_scroller.h" 7 #include "ash/accelerators/magnifier_key_scroller.h"
8 #include "ash/accelerators/spoken_feedback_toggler.h" 8 #include "ash/accelerators/spoken_feedback_toggler.h"
9 #include "ash/accessibility_delegate.h" 9 #include "ash/accessibility_delegate.h"
10 #include "ash/media_delegate.h" 10 #include "ash/media_delegate.h"
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 void InitAfterSessionStart() { 48 void InitAfterSessionStart() {
49 // Restore focus after the user session is started. It's needed because some 49 // Restore focus after the user session is started. It's needed because some
50 // windows can be opened in background while login UI is still active because 50 // windows can be opened in background while login UI is still active because
51 // we currently restore browser windows before login UI is deleted. 51 // we currently restore browser windows before login UI is deleted.
52 ash::Shell* shell = ash::Shell::GetInstance(); 52 ash::Shell* shell = ash::Shell::GetInstance();
53 ash::MruWindowTracker::WindowList mru_list = 53 ash::MruWindowTracker::WindowList mru_list =
54 shell->mru_window_tracker()->BuildMruWindowList(); 54 shell->mru_window_tracker()->BuildMruWindowList();
55 if (!mru_list.empty()) 55 if (!mru_list.empty())
56 mru_list.front()->Focus(); 56 mru_list.front()->Focus();
57 57
58 #if defined(USE_X11)
58 // Enable magnifier scroll keys as there may be no mouse cursor in kiosk mode. 59 // Enable magnifier scroll keys as there may be no mouse cursor in kiosk mode.
59 ash::MagnifierKeyScroller::SetEnabled(chrome::IsRunningInForcedAppMode()); 60 ash::MagnifierKeyScroller::SetEnabled(chrome::IsRunningInForcedAppMode());
60 61
61 // Enable long press action to toggle spoken feedback with hotrod 62 // Enable long press action to toggle spoken feedback with hotrod
62 // remote which can't handle shortcut. 63 // remote which can't handle shortcut.
63 ash::SpokenFeedbackToggler::SetEnabled(chrome::IsRunningInForcedAppMode()); 64 ash::SpokenFeedbackToggler::SetEnabled(chrome::IsRunningInForcedAppMode());
65 #endif
64 } 66 }
65 67
66 class AccessibilityDelegateImpl : public ash::AccessibilityDelegate { 68 class AccessibilityDelegateImpl : public ash::AccessibilityDelegate {
67 public: 69 public:
68 AccessibilityDelegateImpl() {} 70 AccessibilityDelegateImpl() {}
69 virtual ~AccessibilityDelegateImpl() {} 71 virtual ~AccessibilityDelegateImpl() {}
70 72
71 virtual void ToggleHighContrast() OVERRIDE { 73 virtual void ToggleHighContrast() OVERRIDE {
72 DCHECK(chromeos::AccessibilityManager::Get()); 74 DCHECK(chromeos::AccessibilityManager::Get());
73 chromeos::AccessibilityManager::Get()->EnableHighContrast( 75 chromeos::AccessibilityManager::Get()->EnableHighContrast(
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after
294 } 296 }
295 297
296 void ChromeShellDelegate::PlatformInit() { 298 void ChromeShellDelegate::PlatformInit() {
297 registrar_.Add(this, 299 registrar_.Add(this,
298 chrome::NOTIFICATION_LOGIN_USER_PROFILE_PREPARED, 300 chrome::NOTIFICATION_LOGIN_USER_PROFILE_PREPARED,
299 content::NotificationService::AllSources()); 301 content::NotificationService::AllSources());
300 registrar_.Add(this, 302 registrar_.Add(this,
301 chrome::NOTIFICATION_SESSION_STARTED, 303 chrome::NOTIFICATION_SESSION_STARTED,
302 content::NotificationService::AllSources()); 304 content::NotificationService::AllSources());
303 } 305 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/ash/ash_init.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698