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

Side by Side Diff: ash/common/wm_window.cc

Issue 2780943002: Enables ScreenPinningController for mash/mus (Closed)
Patch Set: local Created 3 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
« no previous file with comments | « ash/common/wm_window.h ('k') | ash/mus/bridge/wm_shell_mus.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/common/wm_window.h" 5 #include "ash/common/wm_window.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_shell_aura.h" 8 #include "ash/aura/wm_shell_aura.h"
9 #include "ash/common/ash_constants.h" 9 #include "ash/common/ash_constants.h"
10 #include "ash/common/wm/window_state.h" 10 #include "ash/common/wm/window_state.h"
(...skipping 560 matching lines...) Expand 10 before | Expand all | Expand 10 after
571 } 571 }
572 572
573 void WmWindow::StackChildAbove(WmWindow* child, WmWindow* target) { 573 void WmWindow::StackChildAbove(WmWindow* child, WmWindow* target) {
574 window_->StackChildAbove(GetAuraWindow(child), GetAuraWindow(target)); 574 window_->StackChildAbove(GetAuraWindow(child), GetAuraWindow(target));
575 } 575 }
576 576
577 void WmWindow::StackChildBelow(WmWindow* child, WmWindow* target) { 577 void WmWindow::StackChildBelow(WmWindow* child, WmWindow* target) {
578 window_->StackChildBelow(GetAuraWindow(child), GetAuraWindow(target)); 578 window_->StackChildBelow(GetAuraWindow(child), GetAuraWindow(target));
579 } 579 }
580 580
581 void WmWindow::SetPinned(bool trusted) {
582 if (WmShell::Get()->IsRunningInMash()) {
583 // TODO: fix, see http://crbug.com/622486. With aura-mus pinning may just
584 // work.
585 NOTIMPLEMENTED();
586 return;
587 }
588 wm::PinWindow(window_, trusted);
589 }
590
591 void WmWindow::SetAlwaysOnTop(bool value) { 581 void WmWindow::SetAlwaysOnTop(bool value) {
592 window_->SetProperty(aura::client::kAlwaysOnTopKey, value); 582 window_->SetProperty(aura::client::kAlwaysOnTopKey, value);
593 } 583 }
594 584
595 bool WmWindow::IsAlwaysOnTop() const { 585 bool WmWindow::IsAlwaysOnTop() const {
596 return window_->GetProperty(aura::client::kAlwaysOnTopKey); 586 return window_->GetProperty(aura::client::kAlwaysOnTopKey);
597 } 587 }
598 588
599 void WmWindow::Hide() { 589 void WmWindow::Hide() {
600 window_->Hide(); 590 window_->Hide();
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after
794 observer.OnTransientChildAdded(this, Get(transient)); 784 observer.OnTransientChildAdded(this, Get(transient));
795 } 785 }
796 786
797 void WmWindow::OnTransientChildRemoved(aura::Window* window, 787 void WmWindow::OnTransientChildRemoved(aura::Window* window,
798 aura::Window* transient) { 788 aura::Window* transient) {
799 for (auto& observer : transient_observers_) 789 for (auto& observer : transient_observers_)
800 observer.OnTransientChildRemoved(this, Get(transient)); 790 observer.OnTransientChildRemoved(this, Get(transient));
801 } 791 }
802 792
803 } // namespace ash 793 } // namespace ash
OLDNEW
« no previous file with comments | « ash/common/wm_window.h ('k') | ash/mus/bridge/wm_shell_mus.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698