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

Unified Diff: ash/system/rotation/tray_rotation_lock.cc

Issue 2909763002: Revert of Rename MaximizeMode to TabletMode (Closed)
Patch Set: Created 3 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/system/rotation/tray_rotation_lock.h ('k') | ash/system/rotation/tray_rotation_lock_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/system/rotation/tray_rotation_lock.cc
diff --git a/ash/system/rotation/tray_rotation_lock.cc b/ash/system/rotation/tray_rotation_lock.cc
index e3254f30a6f090386b0cec7c846317cf7f360e9f..1c6a3e6c4b075e23c3002c5b048ba76f4a2b3a8a 100644
--- a/ash/system/rotation/tray_rotation_lock.cc
+++ b/ash/system/rotation/tray_rotation_lock.cc
@@ -15,7 +15,7 @@
#include "ash/system/tray/tray_popup_item_style.h"
#include "ash/system/tray/tray_popup_utils.h"
#include "ash/system/tray/tri_view.h"
-#include "ash/wm/tablet_mode/tablet_mode_controller.h"
+#include "ash/wm/maximize_mode/maximize_mode_controller.h"
#include "ui/accessibility/ax_node_data.h"
#include "ui/base/l10n/l10n_util.h"
#include "ui/display/display.h"
@@ -29,10 +29,10 @@
namespace {
-bool IsTabletModeWindowManagerEnabled() {
+bool IsMaximizeModeWindowManagerEnabled() {
return Shell::Get()
- ->tablet_mode_controller()
- ->IsTabletModeWindowManagerEnabled();
+ ->maximize_mode_controller()
+ ->IsMaximizeModeWindowManagerEnabled();
}
bool IsUserRotationLocked() {
@@ -71,8 +71,8 @@
bool PerformAction(const ui::Event& event) override;
// ShellObserver:
- void OnTabletModeStarted() override;
- void OnTabletModeEnded() override;
+ void OnMaximizeModeStarted() override;
+ void OnMaximizeModeEnded() override;
// ScreenOrientationController::Obsever:
void OnUserRotationLockChanged() override;
@@ -100,9 +100,9 @@
SetInkDropMode(InkDropHostView::InkDropMode::ON);
- SetVisible(IsTabletModeWindowManagerEnabled());
+ SetVisible(IsMaximizeModeWindowManagerEnabled());
Shell::Get()->AddShellObserver(this);
- if (IsTabletModeWindowManagerEnabled())
+ if (IsMaximizeModeWindowManagerEnabled())
Shell::Get()->screen_orientation_controller()->AddObserver(this);
}
@@ -153,13 +153,13 @@
return true;
}
-void RotationLockDefaultView::OnTabletModeStarted() {
+void RotationLockDefaultView::OnMaximizeModeStarted() {
Update();
SetVisible(true);
Shell::Get()->screen_orientation_controller()->AddObserver(this);
}
-void RotationLockDefaultView::OnTabletModeEnded() {
+void RotationLockDefaultView::OnMaximizeModeEnded() {
SetVisible(false);
StopObservingRotation();
}
@@ -191,13 +191,13 @@
return nullptr;
}
-void TrayRotationLock::OnTabletModeStarted() {
+void TrayRotationLock::OnMaximizeModeStarted() {
tray_view()->SetVisible(ShouldBeVisible());
UpdateTrayImage();
Shell::Get()->screen_orientation_controller()->AddObserver(this);
}
-void TrayRotationLock::OnTabletModeEnded() {
+void TrayRotationLock::OnMaximizeModeEnded() {
tray_view()->SetVisible(false);
StopObservingRotation();
}
@@ -219,7 +219,7 @@
}
bool TrayRotationLock::ShouldBeVisible() {
- return OnPrimaryDisplay() && IsTabletModeWindowManagerEnabled();
+ return OnPrimaryDisplay() && IsMaximizeModeWindowManagerEnabled();
}
bool TrayRotationLock::OnPrimaryDisplay() const {
« no previous file with comments | « ash/system/rotation/tray_rotation_lock.h ('k') | ash/system/rotation/tray_rotation_lock_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698