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

Unified Diff: mash/wm/property_util.cc

Issue 1527183003: Change mojo enums to be scoped enums in the generated C++ bindings. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@mojo-binding-equals
Patch Set: rebase Created 4 years, 11 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 | « mash/wm/property_util.h ('k') | mash/wm/public/interfaces/user_window_controller.mojom » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mash/wm/property_util.cc
diff --git a/mash/wm/property_util.cc b/mash/wm/property_util.cc
index 67b11b67ac5b105cc54e92bff625f7b36a751b09..5fa4931b3b3532424b53fa92072b89428d44b2c6 100644
--- a/mash/wm/property_util.cc
+++ b/mash/wm/property_util.cc
@@ -27,7 +27,7 @@ mus::mojom::ShowState GetWindowShowState(const mus::Window* window) {
window->GetSharedProperty<int32_t>(
mus::mojom::WindowManager::kShowState_Property));
}
- return mus::mojom::SHOW_STATE_RESTORED;
+ return mus::mojom::ShowState::RESTORED;
}
void SetWindowUserSetBounds(mus::Window* window, const gfx::Rect& bounds) {
@@ -68,17 +68,16 @@ mojom::Container GetRequestedContainer(const mus::Window* window) {
return static_cast<mojom::Container>(
window->GetSharedProperty<int32_t>(mojom::kWindowContainer_Property));
}
- return mojom::CONTAINER_USER_WINDOWS;
+ return mojom::Container::USER_WINDOWS;
}
-mus::mojom::ResizeBehavior GetResizeBehavior(const mus::Window* window) {
+int32_t GetResizeBehavior(const mus::Window* window) {
if (window->HasSharedProperty(
mus::mojom::WindowManager::kResizeBehavior_Property)) {
- return static_cast<mus::mojom::ResizeBehavior>(
- window->GetSharedProperty<int32_t>(
- mus::mojom::WindowManager::kResizeBehavior_Property));
+ return window->GetSharedProperty<int32_t>(
+ mus::mojom::WindowManager::kResizeBehavior_Property);
}
- return mus::mojom::RESIZE_BEHAVIOR_NONE;
+ return mus::mojom::kResizeBehaviorNone;
}
void SetRestoreBounds(mus::Window* window, const gfx::Rect& bounds) {
@@ -116,7 +115,7 @@ mus::mojom::WindowType GetWindowType(
mojo::TypeConverter<int32_t, const std::vector<uint8_t>>::Convert(
iter->second));
}
- return mus::mojom::WINDOW_TYPE_POPUP;
+ return mus::mojom::WindowType::POPUP;
}
} // namespace wm
« no previous file with comments | « mash/wm/property_util.h ('k') | mash/wm/public/interfaces/user_window_controller.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698