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

Unified Diff: ash/wm/maximize_mode/maximize_mode_window_manager_unittest.cc

Issue 2542493002: Replace kCanMaximize/Minimize/Resize with kResizeBehavior. (Closed)
Patch Set: Fix int->bool compile issue. Created 4 years 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/wm/lock_layout_manager_unittest.cc ('k') | ash/wm/toplevel_window_event_handler_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/maximize_mode/maximize_mode_window_manager_unittest.cc
diff --git a/ash/wm/maximize_mode/maximize_mode_window_manager_unittest.cc b/ash/wm/maximize_mode/maximize_mode_window_manager_unittest.cc
index 5e483a17f2001e5b820ba256d2ff3c08305612e9..7c25413e34cdf24c865e5dd9fb052ab454fec04f 100644
--- a/ash/wm/maximize_mode/maximize_mode_window_manager_unittest.cc
+++ b/ash/wm/maximize_mode/maximize_mode_window_manager_unittest.cc
@@ -27,6 +27,7 @@
#include "base/strings/stringprintf.h"
#include "base/strings/utf_string_conversions.h"
#include "base/values.h"
+#include "services/ui/public/interfaces/window_manager_constants.mojom.h"
#include "ui/aura/client/aura_constants.h"
#include "ui/aura/test/test_window_delegate.h"
#include "ui/aura/test/test_windows.h"
@@ -130,9 +131,10 @@ class MaximizeModeWindowManagerTest : public test::AshTestBase {
}
aura::Window* window = aura::test::CreateTestWindowWithDelegateAndType(
delegate, type, 0, bounds, NULL);
- window->SetProperty(aura::client::kCanMaximizeKey, can_maximize);
- if (!can_resize)
- window->SetProperty(aura::client::kCanResizeKey, false);
+ int32_t behavior = ui::mojom::kResizeBehaviorNone;
+ behavior |= can_resize ? ui::mojom::kResizeBehaviorCanResize : 0;
+ behavior |= can_maximize ? ui::mojom::kResizeBehaviorCanMaximize : 0;
+ window->SetProperty(aura::client::kResizeBehaviorKey, behavior);
aura::Window* container = Shell::GetContainer(
Shell::GetPrimaryRootWindow(), wm::kSwitchableWindowContainerIds[0]);
container->AddChild(window);
« no previous file with comments | « ash/wm/lock_layout_manager_unittest.cc ('k') | ash/wm/toplevel_window_event_handler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698