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

Side by Side Diff: views/widget/widget_win.h

Issue 5184009: Revert 66784 - Converts usage of SetProp/GetProp to a map. Even after making ... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « views/widget/widget_gtk.cc ('k') | views/widget/widget_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef VIEWS_WIDGET_WIDGET_WIN_H_ 5 #ifndef VIEWS_WIDGET_WIDGET_WIN_H_
6 #define VIEWS_WIDGET_WIDGET_WIN_H_ 6 #define VIEWS_WIDGET_WIDGET_WIN_H_
7 #pragma once 7 #pragma once
8 8
9 #include <atlbase.h> 9 #include <atlbase.h>
10 #include <atlapp.h> 10 #include <atlapp.h>
11 #include <atlcrack.h> 11 #include <atlcrack.h>
12 #include <atlmisc.h> 12 #include <atlmisc.h>
13 13
14 #include <string> 14 #include <string>
15 #include <vector> 15 #include <vector>
16 16
17 #include "base/message_loop.h" 17 #include "base/message_loop.h"
18 #include "base/scoped_comptr_win.h" 18 #include "base/scoped_comptr_win.h"
19 #include "base/scoped_vector.h" 19 #include "base/scoped_vector.h"
20 #include "gfx/window_impl.h" 20 #include "gfx/window_impl.h"
21 #include "views/focus/focus_manager.h" 21 #include "views/focus/focus_manager.h"
22 #include "views/layout_manager.h" 22 #include "views/layout_manager.h"
23 #include "views/widget/widget.h" 23 #include "views/widget/widget.h"
24 24
25 namespace app { 25 namespace app {
26 class ViewProp; 26 namespace win {
27 class ScopedProp;
28 }
27 } 29 }
28 30
29 namespace gfx { 31 namespace gfx {
30 class CanvasSkia; 32 class CanvasSkia;
31 class Rect; 33 class Rect;
32 } 34 }
33 35
34 namespace views { 36 namespace views {
35 37
36 class DefaultThemeProvider; 38 class DefaultThemeProvider;
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 virtual Widget* GetRootWidget() const; 227 virtual Widget* GetRootWidget() const;
226 virtual bool IsVisible() const; 228 virtual bool IsVisible() const;
227 virtual bool IsActive() const; 229 virtual bool IsActive() const;
228 virtual bool IsAccessibleWidget() const; 230 virtual bool IsAccessibleWidget() const;
229 virtual TooltipManager* GetTooltipManager(); 231 virtual TooltipManager* GetTooltipManager();
230 virtual void GenerateMousePressedForView(View* view, 232 virtual void GenerateMousePressedForView(View* view,
231 const gfx::Point& point); 233 const gfx::Point& point);
232 virtual bool GetAccelerator(int cmd_id, menus::Accelerator* accelerator); 234 virtual bool GetAccelerator(int cmd_id, menus::Accelerator* accelerator);
233 virtual Window* GetWindow(); 235 virtual Window* GetWindow();
234 virtual const Window* GetWindow() const; 236 virtual const Window* GetWindow() const;
235 virtual void SetNativeWindowProperty(const char* name, void* value); 237 virtual void SetNativeWindowProperty(const std::wstring& name,
236 virtual void* GetNativeWindowProperty(const char* name); 238 void* value);
239 virtual void* GetNativeWindowProperty(const std::wstring& name);
237 virtual ThemeProvider* GetThemeProvider() const; 240 virtual ThemeProvider* GetThemeProvider() const;
238 virtual ThemeProvider* GetDefaultThemeProvider() const; 241 virtual ThemeProvider* GetDefaultThemeProvider() const;
239 virtual FocusManager* GetFocusManager(); 242 virtual FocusManager* GetFocusManager();
240 virtual void ViewHierarchyChanged(bool is_add, View *parent, 243 virtual void ViewHierarchyChanged(bool is_add, View *parent,
241 View *child); 244 View *child);
242 virtual bool ContainsNativeView(gfx::NativeView native_view); 245 virtual bool ContainsNativeView(gfx::NativeView native_view);
243 246
244 // Overridden from MessageLoop::Observer: 247 // Overridden from MessageLoop::Observer:
245 void WillProcessMessage(const MSG& msg); 248 void WillProcessMessage(const MSG& msg);
246 virtual void DidProcessMessage(const MSG& msg); 249 virtual void DidProcessMessage(const MSG& msg);
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after
477 // Whether or not we have capture the mouse. 480 // Whether or not we have capture the mouse.
478 bool has_capture_; 481 bool has_capture_;
479 482
480 // If true, the mouse is currently down. 483 // If true, the mouse is currently down.
481 bool is_mouse_down_; 484 bool is_mouse_down_;
482 485
483 // Are a subclass of WindowWin? 486 // Are a subclass of WindowWin?
484 bool is_window_; 487 bool is_window_;
485 488
486 private: 489 private:
487 typedef ScopedVector<app::ViewProp> ViewProps; 490 typedef ScopedVector<app::win::ScopedProp> ScopedProps;
488 491
489 // Implementation of GetWindow. Ascends the parents of |hwnd| returning the 492 // Implementation of GetWindow. Ascends the parents of |hwnd| returning the
490 // first ancestor that is a Window. 493 // first ancestor that is a Window.
491 static Window* GetWindowImpl(HWND hwnd); 494 static Window* GetWindowImpl(HWND hwnd);
492 495
493 // Resize the bitmap used to contain the contents of the layered window. This 496 // Resize the bitmap used to contain the contents of the layered window. This
494 // recreates the entire bitmap. 497 // recreates the entire bitmap.
495 void SizeContents(const gfx::Size& window_size); 498 void SizeContents(const gfx::Size& window_size);
496 499
497 // Paint into a DIB and then update the layered window with its contents. 500 // Paint into a DIB and then update the layered window with its contents.
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
585 static const int kMaxAccessibilityViewEvents = 20; 588 static const int kMaxAccessibilityViewEvents = 20;
586 589
587 // A vector used to access views for which we have sent notifications to 590 // A vector used to access views for which we have sent notifications to
588 // accessibility clients. It is used as a circular queue. 591 // accessibility clients. It is used as a circular queue.
589 std::vector<View*> accessibility_view_events_; 592 std::vector<View*> accessibility_view_events_;
590 593
591 // The current position of the view events vector. When incrementing, 594 // The current position of the view events vector. When incrementing,
592 // we always mod this value with the max view events above . 595 // we always mod this value with the max view events above .
593 int accessibility_view_events_index_; 596 int accessibility_view_events_index_;
594 597
595 ViewProps props_; 598 ScopedProps props_;
596 599
597 DISALLOW_COPY_AND_ASSIGN(WidgetWin); 600 DISALLOW_COPY_AND_ASSIGN(WidgetWin);
598 }; 601 };
599 602
600 } // namespace views 603 } // namespace views
601 604
602 #endif // VIEWS_WIDGET_WIDGET_WIN_H_ 605 #endif // VIEWS_WIDGET_WIDGET_WIN_H_
OLDNEW
« no previous file with comments | « views/widget/widget_gtk.cc ('k') | views/widget/widget_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698