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

Unified Diff: views/focus/focus_util_win.cc

Issue 5144005: Converts usage of SetProp/GetProp to a map. Even after making sure we (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/chrome
Patch Set: Fix build Created 10 years, 1 month 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 | « views/focus/focus_util_win.h ('k') | views/widget/child_window_message_processor.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/focus/focus_util_win.cc
diff --git a/views/focus/focus_util_win.cc b/views/focus/focus_util_win.cc
index 266a8919f9d5eb46e769f053af80225de69724c8..23172ad71bf281456d2041437034e082cbc099d3 100644
--- a/views/focus/focus_util_win.cc
+++ b/views/focus/focus_util_win.cc
@@ -6,24 +6,26 @@
#include <windowsx.h>
-#include "app/win/scoped_prop.h"
+#include "app/view_prop.h"
#include "base/auto_reset.h"
#include "base/win_util.h"
+using app::ViewProp;
+
namespace views {
// Property used to indicate the HWND supports having mouse wheel messages
// rerouted to it.
-static const wchar_t* const kHWNDSupportMouseWheelRerouting =
- L"__HWND_MW_REROUTE_OK";
+static const char* const kHWNDSupportMouseWheelRerouting =
+ "__HWND_MW_REROUTE_OK";
static bool WindowSupportsRerouteMouseWheel(HWND window) {
while (GetWindowLong(window, GWL_STYLE) & WS_CHILD) {
if (!IsWindow(window))
break;
- if (reinterpret_cast<bool>(GetProp(window,
- kHWNDSupportMouseWheelRerouting))) {
+ if (reinterpret_cast<bool>(
+ ViewProp::GetValue(window, kHWNDSupportMouseWheelRerouting))) {
return true;
}
window = GetParent(window);
@@ -53,9 +55,9 @@ static bool CanRedirectMouseWheelFrom(HWND window) {
return true;
}
-app::win::ScopedProp* SetWindowSupportsRerouteMouseWheel(HWND hwnd) {
- return new app::win::ScopedProp(hwnd, kHWNDSupportMouseWheelRerouting,
- reinterpret_cast<HANDLE>(true));
+ViewProp* SetWindowSupportsRerouteMouseWheel(HWND hwnd) {
+ return new ViewProp(hwnd, kHWNDSupportMouseWheelRerouting,
+ reinterpret_cast<HANDLE>(true));
}
bool RerouteMouseWheel(HWND window, WPARAM w_param, LPARAM l_param) {
« no previous file with comments | « views/focus/focus_util_win.h ('k') | views/widget/child_window_message_processor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698