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

Side by Side Diff: chrome/browser/chromeos/login/screen_locker.cc

Issue 7740044: Implement fullscreen info bubble on Win and Mac (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix license Created 9 years, 2 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) 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/chromeos/login/screen_locker.h" 5 #include "chrome/browser/chromeos/login/screen_locker.h"
6 6
7 #include <X11/extensions/XTest.h> 7 #include <X11/extensions/XTest.h>
8 #include <X11/keysym.h> 8 #include <X11/keysym.h>
9 #include <gdk/gdkkeysyms.h> 9 #include <gdk/gdkkeysyms.h>
10 #include <gdk/gdkx.h> 10 #include <gdk/gdkx.h>
(...skipping 1071 matching lines...) Expand 10 before | Expand all | Expand 10 after
1082 void ScreenLocker::Show() { 1082 void ScreenLocker::Show() {
1083 VLOG(1) << "In ScreenLocker::Show"; 1083 VLOG(1) << "In ScreenLocker::Show";
1084 UserMetrics::RecordAction(UserMetricsAction("ScreenLocker_Show")); 1084 UserMetrics::RecordAction(UserMetricsAction("ScreenLocker_Show"));
1085 DCHECK(MessageLoop::current()->type() == MessageLoop::TYPE_UI); 1085 DCHECK(MessageLoop::current()->type() == MessageLoop::TYPE_UI);
1086 1086
1087 // Exit fullscreen. 1087 // Exit fullscreen.
1088 Browser* browser = BrowserList::GetLastActive(); 1088 Browser* browser = BrowserList::GetLastActive();
1089 // browser can be NULL if we receive a lock request before the first browser 1089 // browser can be NULL if we receive a lock request before the first browser
1090 // window is shown. 1090 // window is shown.
1091 if (browser && browser->window()->IsFullscreen()) { 1091 if (browser && browser->window()->IsFullscreen()) {
1092 browser->ToggleFullscreenMode(); 1092 browser->ToggleFullscreenMode(false);
1093 } 1093 }
1094 1094
1095 if (!screen_locker_) { 1095 if (!screen_locker_) {
1096 VLOG(1) << "Show: Locking screen"; 1096 VLOG(1) << "Show: Locking screen";
1097 ScreenLocker* locker = 1097 ScreenLocker* locker =
1098 new ScreenLocker(UserManager::Get()->logged_in_user()); 1098 new ScreenLocker(UserManager::Get()->logged_in_user());
1099 #if defined(TOUCH_UI) 1099 #if defined(TOUCH_UI)
1100 // The screen locker does not reliably work on TOUCH_UI builds. In order 1100 // The screen locker does not reliably work on TOUCH_UI builds. In order
1101 // to effectively "lock" the screen we will sign out the user for now. 1101 // to effectively "lock" the screen we will sign out the user for now.
1102 // TODO(flackr): Implement lock screen in WebUI and remove this hack. 1102 // TODO(flackr): Implement lock screen in WebUI and remove this hack.
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
1285 1285
1286 bool ScreenLocker::AcceleratorPressed(const views::Accelerator& accelerator) { 1286 bool ScreenLocker::AcceleratorPressed(const views::Accelerator& accelerator) {
1287 if (!background_view_->IsScreenSaverVisible()) { 1287 if (!background_view_->IsScreenSaverVisible()) {
1288 StartScreenSaver(); 1288 StartScreenSaver();
1289 return true; 1289 return true;
1290 } 1290 }
1291 return false; 1291 return false;
1292 } 1292 }
1293 1293
1294 } // namespace chromeos 1294 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/app/nibs/FullscreenExitBubble.xib ('k') | chrome/browser/chromeos/login/screen_locker_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698