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

Side by Side Diff: chrome/browser/browser_main.cc

Issue 6975057: Listen to XI_HierarchyChanged events and call setxkbmap when needed. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: added workaround for crbug.com/84694 Created 9 years, 6 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 | « no previous file | chrome/browser/browser_shutdown.cc » ('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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/browser_main.h" 5 #include "chrome/browser/browser_main.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 #include "chrome/browser/chromeos/customization_document.h" 138 #include "chrome/browser/chromeos/customization_document.h"
139 #include "chrome/browser/chromeos/external_metrics.h" 139 #include "chrome/browser/chromeos/external_metrics.h"
140 #include "chrome/browser/chromeos/login/authenticator.h" 140 #include "chrome/browser/chromeos/login/authenticator.h"
141 #include "chrome/browser/chromeos/login/login_utils.h" 141 #include "chrome/browser/chromeos/login/login_utils.h"
142 #include "chrome/browser/chromeos/login/ownership_service.h" 142 #include "chrome/browser/chromeos/login/ownership_service.h"
143 #include "chrome/browser/chromeos/login/screen_locker.h" 143 #include "chrome/browser/chromeos/login/screen_locker.h"
144 #include "chrome/browser/chromeos/login/user_manager.h" 144 #include "chrome/browser/chromeos/login/user_manager.h"
145 #include "chrome/browser/chromeos/metrics_cros_settings_provider.h" 145 #include "chrome/browser/chromeos/metrics_cros_settings_provider.h"
146 #include "chrome/browser/chromeos/net/network_change_notifier_chromeos.h" 146 #include "chrome/browser/chromeos/net/network_change_notifier_chromeos.h"
147 #include "chrome/browser/chromeos/system_key_event_listener.h" 147 #include "chrome/browser/chromeos/system_key_event_listener.h"
148 #include "chrome/browser/chromeos/xinput_hierarchy_changed_event_listener.h"
148 #include "chrome/browser/oom_priority_manager.h" 149 #include "chrome/browser/oom_priority_manager.h"
149 #include "chrome/browser/ui/views/browser_dialogs.h" 150 #include "chrome/browser/ui/views/browser_dialogs.h"
150 #endif 151 #endif
151 152
152 // TODO(port): several win-only methods have been pulled out of this, but 153 // TODO(port): several win-only methods have been pulled out of this, but
153 // BrowserMain() as a whole needs to be broken apart so that it's usable by 154 // BrowserMain() as a whole needs to be broken apart so that it's usable by
154 // other platforms. For now, it's just a stub. This is a serious work in 155 // other platforms. For now, it's just a stub. This is a serious work in
155 // progress and should not be taken as an indication of a real refactoring. 156 // progress and should not be taken as an indication of a real refactoring.
156 157
157 #if defined(OS_WIN) 158 #if defined(OS_WIN)
(...skipping 1620 matching lines...) Expand 10 before | Expand all | Expand 10 after
1778 // Initialize the brightness observer so that we'll display an onscreen 1779 // Initialize the brightness observer so that we'll display an onscreen
1779 // indication of brightness changes during login. 1780 // indication of brightness changes during login.
1780 static chromeos::BrightnessObserver* brightness_observer = 1781 static chromeos::BrightnessObserver* brightness_observer =
1781 new chromeos::BrightnessObserver(); 1782 new chromeos::BrightnessObserver();
1782 chromeos::CrosLibrary::Get()->GetBrightnessLibrary()->AddObserver( 1783 chromeos::CrosLibrary::Get()->GetBrightnessLibrary()->AddObserver(
1783 brightness_observer); 1784 brightness_observer);
1784 1785
1785 // Listen for system key events so that the user will be able to adjust the 1786 // Listen for system key events so that the user will be able to adjust the
1786 // volume on the login screen. 1787 // volume on the login screen.
1787 chromeos::SystemKeyEventListener::GetInstance(); 1788 chromeos::SystemKeyEventListener::GetInstance();
1789
1790 // TODO(yusukes): Remove the #if once the ARM bot (crbug.com/84694) is fixed.
1791 #if defined(HAVE_XINPUT2)
1792 // Listen for XI_HierarchyChanged events.
1793 chromeos::XInputHierarchyChangedEventListener::GetInstance();
1794 #endif
1788 #endif 1795 #endif
1789 1796
1790 // Initialize extension event routers. Note that on Chrome OS, this will 1797 // Initialize extension event routers. Note that on Chrome OS, this will
1791 // not succeed if the user has not logged in yet, in which case the 1798 // not succeed if the user has not logged in yet, in which case the
1792 // event routers are initialized in LoginUtilsImpl::CompleteLogin instead. 1799 // event routers are initialized in LoginUtilsImpl::CompleteLogin instead.
1793 if (profile->GetExtensionService()) { 1800 if (profile->GetExtensionService()) {
1794 // This will initialize bookmarks. Call it after bookmark import is done. 1801 // This will initialize bookmarks. Call it after bookmark import is done.
1795 // See issue 40144. 1802 // See issue 40144.
1796 profile->GetExtensionService()->InitEventRouters(); 1803 profile->GetExtensionService()->InitEventRouters();
1797 } 1804 }
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
1956 #if defined(OS_CHROMEOS) 1963 #if defined(OS_CHROMEOS)
1957 // To be precise, logout (browser shutdown) is not yet done, but the 1964 // To be precise, logout (browser shutdown) is not yet done, but the
1958 // remaining work is negligible, hence we say LogoutDone here. 1965 // remaining work is negligible, hence we say LogoutDone here.
1959 chromeos::BootTimesLoader::Get()->AddLogoutTimeMarker("LogoutDone", 1966 chromeos::BootTimesLoader::Get()->AddLogoutTimeMarker("LogoutDone",
1960 false); 1967 false);
1961 chromeos::BootTimesLoader::Get()->WriteLogoutTimes(); 1968 chromeos::BootTimesLoader::Get()->WriteLogoutTimes();
1962 #endif 1969 #endif
1963 TRACE_EVENT_END_ETW("BrowserMain", 0, 0); 1970 TRACE_EVENT_END_ETW("BrowserMain", 0, 0);
1964 return result_code; 1971 return result_code;
1965 } 1972 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/browser_shutdown.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698