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

Side by Side Diff: chrome/browser/chromeos/login/lock/webui_screen_locker.cc

Issue 2260653002: Pin keyboard works with virtual keyboard. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkgr
Patch Set: Nit. Created 4 years, 3 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
« no previous file with comments | « no previous file | chrome/browser/chromeos/login/screens/core_oobe_actor.h » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/lock/webui_screen_locker.h" 5 #include "chrome/browser/chromeos/login/lock/webui_screen_locker.h"
6 6
7 #include "ash/common/wm_shell.h" 7 #include "ash/common/wm_shell.h"
8 #include "ash/shell.h" 8 #include "ash/shell.h"
9 #include "ash/system/chromeos/power/power_event_observer.h" 9 #include "ash/system/chromeos/power/power_event_observer.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 355 matching lines...) Expand 10 before | Expand all | Expand 10 after
366 } 366 }
367 } 367 }
368 368
369 //////////////////////////////////////////////////////////////////////////////// 369 ////////////////////////////////////////////////////////////////////////////////
370 // keyboard::KeyboardControllerObserver: 370 // keyboard::KeyboardControllerObserver:
371 371
372 void WebUIScreenLocker::OnKeyboardBoundsChanging( 372 void WebUIScreenLocker::OnKeyboardBoundsChanging(
373 const gfx::Rect& new_bounds) { 373 const gfx::Rect& new_bounds) {
374 if (new_bounds.IsEmpty()) { 374 if (new_bounds.IsEmpty()) {
375 // Keyboard has been hidden. 375 // Keyboard has been hidden.
376 if (GetOobeUI()) 376 if (GetOobeUI()) {
377 GetOobeUI()->GetCoreOobeActor()->ShowControlBar(true); 377 GetOobeUI()->GetCoreOobeActor()->ShowControlBar(true);
378 GetOobeUI()->GetCoreOobeActor()->ShowPinKeyboard(true);
379 }
378 } else { 380 } else {
379 // Keyboard has been shown. 381 // Keyboard has been shown.
380 if (GetOobeUI()) 382 if (GetOobeUI()) {
381 GetOobeUI()->GetCoreOobeActor()->ShowControlBar(false); 383 GetOobeUI()->GetCoreOobeActor()->ShowControlBar(false);
384 GetOobeUI()->GetCoreOobeActor()->ShowPinKeyboard(false);
385 }
382 } 386 }
383 } 387 }
384 388
385 //////////////////////////////////////////////////////////////////////////////// 389 ////////////////////////////////////////////////////////////////////////////////
386 // display::DisplayObserver: 390 // display::DisplayObserver:
387 391
388 void WebUIScreenLocker::OnDisplayAdded(const display::Display& new_display) {} 392 void WebUIScreenLocker::OnDisplayAdded(const display::Display& new_display) {}
389 393
390 void WebUIScreenLocker::OnDisplayRemoved(const display::Display& old_display) {} 394 void WebUIScreenLocker::OnDisplayRemoved(const display::Display& old_display) {}
391 395
392 void WebUIScreenLocker::OnDisplayMetricsChanged(const display::Display& display, 396 void WebUIScreenLocker::OnDisplayMetricsChanged(const display::Display& display,
393 uint32_t changed_metrics) { 397 uint32_t changed_metrics) {
394 display::Display primary_display = 398 display::Display primary_display =
395 display::Screen::GetScreen()->GetPrimaryDisplay(); 399 display::Screen::GetScreen()->GetPrimaryDisplay();
396 if (display.id() != primary_display.id() || 400 if (display.id() != primary_display.id() ||
397 !(changed_metrics & DISPLAY_METRIC_BOUNDS)) { 401 !(changed_metrics & DISPLAY_METRIC_BOUNDS)) {
398 return; 402 return;
399 } 403 }
400 404
401 if (GetOobeUI()) { 405 if (GetOobeUI()) {
402 const gfx::Size& size = primary_display.size(); 406 const gfx::Size& size = primary_display.size();
403 GetOobeUI()->GetCoreOobeActor()->SetClientAreaSize(size.width(), 407 GetOobeUI()->GetCoreOobeActor()->SetClientAreaSize(size.width(),
404 size.height()); 408 size.height());
405 } 409 }
406 } 410 }
407 411
408 } // namespace chromeos 412 } // namespace chromeos
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/login/screens/core_oobe_actor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698