summaryrefslogtreecommitdiffstats
path: root/ash/wm/window_properties.h
diff options
context:
space:
mode:
authorbenrg@chromium.org <benrg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-02-11 00:29:18 +0000
committerbenrg@chromium.org <benrg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-02-11 00:29:18 +0000
commit36e4151d009b1ae6274f5af9449e49f3b6e2198f (patch)
treebe96c516fc90ce183cc1671bd670e35dc89ccb42 /ash/wm/window_properties.h
parent557d199404f668006ab48a4ecc1f8e7f3cc2d2ed (diff)
downloadchromium_src-36e4151d009b1ae6274f5af9449e49f3b6e2198f.zip
chromium_src-36e4151d009b1ae6274f5af9449e49f3b6e2198f.tar.gz
chromium_src-36e4151d009b1ae6274f5af9449e49f3b6e2198f.tar.bz2
aura::Window only supports void* and int values for custom properties, which must be cast to and from the correct type at each use point. This CL introduces typed properties and templated aura::Window::[GS]etProperty methods that enforce the use of the declared type. Only pointer types and integral types that fits in intptr_t are supported, and ownership behavior is the same as before. This CL also adds support for default property values other than NULL/0.
BUG=none TEST=updated unit tests Review URL: http://codereview.chromium.org/8533025 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@121583 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ash/wm/window_properties.h')
-rw-r--r--ash/wm/window_properties.h11
1 files changed, 7 insertions, 4 deletions
diff --git a/ash/wm/window_properties.h b/ash/wm/window_properties.h
index a090c35..a2edb8a 100644
--- a/ash/wm/window_properties.h
+++ b/ash/wm/window_properties.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -6,6 +6,9 @@
#define ASH_WM_WINDOW_PROPERTIES_H_
#pragma once
+#include "ash/wm/shadow_types.h"
+#include "ui/aura/window.h"
+
namespace ash {
namespace internal {
@@ -13,9 +16,9 @@ namespace internal {
// Alphabetical sort.
-// A property key for a value from ShadowType describing the drop shadow that
-// should be displayed under the window. If unset, no shadow is displayed.
-extern const char kShadowTypeKey[];
+// A property key describing the drop shadow that should be displayed under the
+// window. If unset, no shadow is displayed.
+extern const aura::WindowProperty<ShadowType>* const kShadowTypeKey;
// Alphabetical sort.