| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "components/exo/shell_surface.h" | 5 #include "components/exo/shell_surface.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "ash/common/frame/custom_frame_view_ash.h" | 9 #include "ash/common/frame/custom_frame_view_ash.h" |
| 10 #include "ash/common/shelf/wm_shelf.h" | 10 #include "ash/common/shelf/wm_shelf.h" |
| (...skipping 457 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 468 } else { | 468 } else { |
| 469 // At the moment, we cannot just unpin the window state, due to ash | 469 // At the moment, we cannot just unpin the window state, due to ash |
| 470 // implementation. Instead, we call Restore() to unpin, if it is Pinned | 470 // implementation. Instead, we call Restore() to unpin, if it is Pinned |
| 471 // state. In this implementation, we may loose the previous state, | 471 // state. In this implementation, we may loose the previous state, |
| 472 // if the previous state is fullscreen, etc. | 472 // if the previous state is fullscreen, etc. |
| 473 if (ash::wm::GetWindowState(widget_->GetNativeWindow())->IsPinned()) | 473 if (ash::wm::GetWindowState(widget_->GetNativeWindow())->IsPinned()) |
| 474 widget_->Restore(); | 474 widget_->Restore(); |
| 475 } | 475 } |
| 476 } | 476 } |
| 477 | 477 |
| 478 void ShellSurface::SetSystemUiVisibility(bool autohide) { |
| 479 TRACE_EVENT1("exo", "ShellSurface::SetSystemUiVisibility", "autohide", |
| 480 autohide); |
| 481 // TODO: Implemented in next CL. crbug.com/705723 |
| 482 NOTIMPLEMENTED(); |
| 483 } |
| 484 |
| 478 void ShellSurface::SetTitle(const base::string16& title) { | 485 void ShellSurface::SetTitle(const base::string16& title) { |
| 479 TRACE_EVENT1("exo", "ShellSurface::SetTitle", "title", | 486 TRACE_EVENT1("exo", "ShellSurface::SetTitle", "title", |
| 480 base::UTF16ToUTF8(title)); | 487 base::UTF16ToUTF8(title)); |
| 481 | 488 |
| 482 title_ = title; | 489 title_ = title; |
| 483 if (widget_) | 490 if (widget_) |
| 484 widget_->UpdateWindowTitle(); | 491 widget_->UpdateWindowTitle(); |
| 485 } | 492 } |
| 486 | 493 |
| 487 void ShellSurface::SetSystemModal(bool system_modal) { | 494 void ShellSurface::SetSystemModal(bool system_modal) { |
| (...skipping 1099 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1587 // small style shadow for them. | 1594 // small style shadow for them. |
| 1588 if (!activatable_) | 1595 if (!activatable_) |
| 1589 shadow->SetElevation(wm::ShadowElevation::SMALL); | 1596 shadow->SetElevation(wm::ShadowElevation::SMALL); |
| 1590 // We don't have rounded corners unless frame is enabled. | 1597 // We don't have rounded corners unless frame is enabled. |
| 1591 if (!frame_enabled_) | 1598 if (!frame_enabled_) |
| 1592 shadow->SetRoundedCornerRadius(0); | 1599 shadow->SetRoundedCornerRadius(0); |
| 1593 } | 1600 } |
| 1594 } | 1601 } |
| 1595 | 1602 |
| 1596 } // namespace exo | 1603 } // namespace exo |
| OLD | NEW |