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

Unified Diff: ash/wm/property_util.cc

Issue 10384212: fix property linkage warnings (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 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/wm/property_util.h ('k') | ash/wm/visibility_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/property_util.cc
diff --git a/ash/wm/property_util.cc b/ash/wm/property_util.cc
index 83082f6a5f4269606bf0f1780e098cfb1b29b21f..50a7bedb9c18a98ee3ee8adc9e162ea5d6757e8b 100644
--- a/ash/wm/property_util.cc
+++ b/ash/wm/property_util.cc
@@ -4,28 +4,17 @@
#include "ash/wm/property_util.h"
+#include "ash/ash_export.h"
+#include "ash/wm/window_properties.h"
#include "ash/wm/window_util.h"
#include "ui/aura/client/aura_constants.h"
#include "ui/aura/window.h"
-#include "ui/aura/window_property.h"
#include "ui/base/ui_base_types.h"
#include "ui/gfx/rect.h"
-DECLARE_WINDOW_PROPERTY_TYPE(bool)
-DECLARE_WINDOW_PROPERTY_TYPE(ash::WindowPersistsAcrossAllWorkspacesType)
-
namespace ash {
-
namespace {
-
-const aura::WindowProperty<bool> kWindowTrackedByWorkspaceProp = {true};
-
-const aura::WindowProperty<WindowPersistsAcrossAllWorkspacesType>
- kWindowPersistsAcrossAllWorkspacesProp =
- {WINDOW_PERSISTS_ACROSS_ALL_WORKSPACES_VALUE_DEFAULT};
-
bool g_default_windows_persist_across_all_workspaces = false;
-
} // namespace
void SetRestoreBounds(aura::Window* window, const gfx::Rect& bounds) {
@@ -51,29 +40,24 @@ void ToggleMaximizedState(aura::Window* window) {
: ui::SHOW_STATE_MAXIMIZED);
}
-const aura::WindowProperty<bool>* const
- kWindowTrackedByWorkspacePropKey = &kWindowTrackedByWorkspaceProp;
-
-const aura::WindowProperty<WindowPersistsAcrossAllWorkspacesType>* const
- kWindowPersistsAcrossAllWorkspacesPropKey =
- &kWindowPersistsAcrossAllWorkspacesProp;
-
void SetTrackedByWorkspace(aura::Window* window, bool value) {
- window->SetProperty(kWindowTrackedByWorkspacePropKey, value);
+ window->SetProperty(internal::kWindowTrackedByWorkspaceKey, value);
}
bool GetTrackedByWorkspace(aura::Window* window) {
- return window->GetProperty(kWindowTrackedByWorkspacePropKey);
+ return window->GetProperty(internal::kWindowTrackedByWorkspaceKey);
}
void SetPersistsAcrossAllWorkspaces(
aura::Window* window,
WindowPersistsAcrossAllWorkspacesType type) {
- window->SetProperty(kWindowPersistsAcrossAllWorkspacesPropKey, type);
+ window->SetProperty(
+ internal::kWindowPersistsAcrossAllWorkspacesKey, type);
}
bool GetPersistsAcrossAllWorkspaces(aura::Window* window) {
- switch (window->GetProperty(kWindowPersistsAcrossAllWorkspacesPropKey)) {
+ switch (window->GetProperty(
+ internal::kWindowPersistsAcrossAllWorkspacesKey)) {
case WINDOW_PERSISTS_ACROSS_ALL_WORKSPACES_VALUE_YES:
return true;
case WINDOW_PERSISTS_ACROSS_ALL_WORKSPACES_VALUE_NO:
« no previous file with comments | « ash/wm/property_util.h ('k') | ash/wm/visibility_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698