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

Unified Diff: chrome/browser/autocomplete/autocomplete_edit_view_win.h

Issue 4637002: Adds the ability for classes other than native control to process (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/chrome
Patch Set: Tweaks 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 | « no previous file | chrome/browser/autocomplete/autocomplete_edit_view_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/autocomplete/autocomplete_edit_view_win.h
diff --git a/chrome/browser/autocomplete/autocomplete_edit_view_win.h b/chrome/browser/autocomplete/autocomplete_edit_view_win.h
index c0abab664e61087a5d03538c798209536944e1bb..fdeaca66b8d31d590e1065d9dec46ae44a4a97ff 100644
--- a/chrome/browser/autocomplete/autocomplete_edit_view_win.h
+++ b/chrome/browser/autocomplete/autocomplete_edit_view_win.h
@@ -22,8 +22,9 @@
#include "chrome/browser/views/autocomplete/autocomplete_popup_contents_view.h"
#include "chrome/common/page_transition_types.h"
#include "gfx/font.h"
-#include "webkit/glue/window_open_disposition.h"
#include "views/controls/menu/menu_2.h"
+#include "views/widget/child_window_message_processor.h"
+#include "webkit/glue/window_open_disposition.h"
class Profile;
class TabContents;
@@ -31,6 +32,12 @@ namespace views {
class View;
}
+namespace app {
+namespace win {
+class ScopedProp;
+}
+}
+
class AutocompleteEditController;
class AutocompleteEditModel;
class AutocompleteEditView;
@@ -46,6 +53,7 @@ class AutocompleteEditViewWin
ES_NOHIDESEL> >,
public CRichEditCommands<AutocompleteEditViewWin>,
public menus::SimpleMenuModel::Delegate,
+ public views::ChildWindowMessageProcessor,
public AutocompleteEditView {
public:
struct State {
@@ -174,6 +182,7 @@ class AutocompleteEditViewWin
MSG_WM_CONTEXTMENU(OnContextMenu)
MSG_WM_COPY(OnCopy)
MSG_WM_CUT(OnCut)
+ MSG_WM_DESTROY(OnDestroy)
MESSAGE_HANDLER_EX(WM_GETOBJECT, OnGetObject)
MESSAGE_HANDLER_EX(WM_IME_COMPOSITION, OnImeComposition)
MESSAGE_HANDLER_EX(WM_IME_NOTIFY, OnImeNotify)
@@ -212,6 +221,11 @@ class AutocompleteEditViewWin
virtual std::wstring GetLabelForCommandId(int command_id) const;
virtual void ExecuteCommand(int command_id);
+ // views::ChildWindowMessageProcessor
+ virtual bool ProcessMessage(UINT message,
+ WPARAM w_param,
+ LPARAM l_param,
+ LRESULT* result);
private:
enum MouseButton {
kLeft = 0,
@@ -267,6 +281,7 @@ class AutocompleteEditViewWin
void OnContextMenu(HWND window, const CPoint& point);
void OnCopy();
void OnCut();
+ void OnDestroy();
LRESULT OnGetObject(UINT uMsg, WPARAM wparam, LPARAM lparam);
LRESULT OnImeComposition(UINT message, WPARAM wparam, LPARAM lparam);
LRESULT OnImeNotify(UINT message, WPARAM wparam, LPARAM lparam);
@@ -519,6 +534,9 @@ class AutocompleteEditViewWin
// Instance of accessibility information and handling.
mutable ScopedComPtr<IAccessible> autocomplete_accessibility_;
+ // ScopedProp returned from registering as a ChildWindowMessageProcessor.
+ scoped_ptr<app::win::ScopedProp> message_handler_prop_;
+
DISALLOW_COPY_AND_ASSIGN(AutocompleteEditViewWin);
};
« no previous file with comments | « no previous file | chrome/browser/autocomplete/autocomplete_edit_view_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698