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

Side by Side Diff: ash/aura/wm_window_aura.cc

Issue 2075923002: mash: Convert FocusCycler to wm common types and move to //ash/common (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 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
« no previous file with comments | « ash/aura/wm_window_aura.h ('k') | ash/common/focus_cycler.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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "ash/aura/wm_window_aura.h" 5 #include "ash/aura/wm_window_aura.h"
6 6
7 #include "ash/aura/aura_layout_manager_adapter.h" 7 #include "ash/aura/aura_layout_manager_adapter.h"
8 #include "ash/aura/wm_root_window_controller_aura.h" 8 #include "ash/aura/wm_root_window_controller_aura.h"
9 #include "ash/aura/wm_shell_aura.h" 9 #include "ash/aura/wm_shell_aura.h"
10 #include "ash/common/ash_constants.h" 10 #include "ash/common/ash_constants.h"
(...skipping 499 matching lines...) Expand 10 before | Expand all | Expand 10 after
510 } 510 }
511 511
512 void WmWindowAura::Hide() { 512 void WmWindowAura::Hide() {
513 window_->Hide(); 513 window_->Hide();
514 } 514 }
515 515
516 void WmWindowAura::Show() { 516 void WmWindowAura::Show() {
517 window_->Show(); 517 window_->Show();
518 } 518 }
519 519
520 views::Widget* WmWindowAura::GetInternalWidget() {
521 return views::Widget::GetWidgetForNativeView(window_);
522 }
523
520 void WmWindowAura::CloseWidget() { 524 void WmWindowAura::CloseWidget() {
521 DCHECK(views::Widget::GetWidgetForNativeView(window_)); 525 DCHECK(GetInternalWidget());
522 views::Widget::GetWidgetForNativeView(window_)->Close(); 526 GetInternalWidget()->Close();
523 } 527 }
524 528
525 bool WmWindowAura::IsFocused() const { 529 bool WmWindowAura::IsFocused() const {
526 return window_->HasFocus(); 530 return window_->HasFocus();
527 } 531 }
528 532
529 bool WmWindowAura::IsActive() const { 533 bool WmWindowAura::IsActive() const {
530 return wm::IsActiveWindow(window_); 534 return wm::IsActiveWindow(window_);
531 } 535 }
532 536
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
694 bool visible) { 698 bool visible) {
695 FOR_EACH_OBSERVER(WmWindowObserver, observers_, 699 FOR_EACH_OBSERVER(WmWindowObserver, observers_,
696 OnWindowVisibilityChanging(this, visible)); 700 OnWindowVisibilityChanging(this, visible));
697 } 701 }
698 702
699 void WmWindowAura::OnWindowTitleChanged(aura::Window* window) { 703 void WmWindowAura::OnWindowTitleChanged(aura::Window* window) {
700 FOR_EACH_OBSERVER(WmWindowObserver, observers_, OnWindowTitleChanged(this)); 704 FOR_EACH_OBSERVER(WmWindowObserver, observers_, OnWindowTitleChanged(this));
701 } 705 }
702 706
703 } // namespace ash 707 } // namespace ash
OLDNEW
« no previous file with comments | « ash/aura/wm_window_aura.h ('k') | ash/common/focus_cycler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698