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

Side by Side Diff: views/controls/tree/tree_view.h

Issue 115309: Remove even more ATL dependencies. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « views/controls/text_field.cc ('k') | views/controls/tree/tree_view.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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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_CONTROLS_TREE_TREE_VIEW_H_ 5 #ifndef VIEWS_CONTROLS_TREE_TREE_VIEW_H_
6 #define VIEWS_CONTROLS_TREE_TREE_VIEW_H_ 6 #define VIEWS_CONTROLS_TREE_TREE_VIEW_H_
7 7
8 #include <windows.h>
9 #include <commctrl.h>
10
8 #include <map> 11 #include <map>
9 12
10 #include "app/tree_model.h" 13 #include "app/tree_model.h"
11 #include "base/basictypes.h" 14 #include "base/basictypes.h"
12 #include "base/logging.h" 15 #include "base/logging.h"
13 #include "views/controls/native_control.h" 16 #include "views/controls/native_control.h"
14 17
15 namespace views { 18 namespace views {
16 19
17 class TreeView; 20 class TreeView;
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
152 // Invoked when the native control sends a WM_NOTIFY message to its parent. 155 // Invoked when the native control sends a WM_NOTIFY message to its parent.
153 // Handles a variety of potential TreeView messages. 156 // Handles a variety of potential TreeView messages.
154 virtual LRESULT OnNotify(int w_param, LPNMHDR l_param); 157 virtual LRESULT OnNotify(int w_param, LPNMHDR l_param);
155 158
156 // Yes, we want to be notified of key down for two reasons. To circumvent 159 // Yes, we want to be notified of key down for two reasons. To circumvent
157 // VK_ENTER from toggling the expaned state when processes_enter_ is false, 160 // VK_ENTER from toggling the expaned state when processes_enter_ is false,
158 // and to have F2 start editting. 161 // and to have F2 start editting.
159 virtual bool NotifyOnKeyDown() const { return true; } 162 virtual bool NotifyOnKeyDown() const { return true; }
160 virtual bool OnKeyDown(int virtual_key_code); 163 virtual bool OnKeyDown(int virtual_key_code);
161 164
162 virtual void OnContextMenu(const CPoint& location); 165 virtual void OnContextMenu(const WTL::CPoint& location);
163 166
164 // Returns the TreeModelNode for |tree_item|. 167 // Returns the TreeModelNode for |tree_item|.
165 TreeModelNode* GetNodeForTreeItem(HTREEITEM tree_item); 168 TreeModelNode* GetNodeForTreeItem(HTREEITEM tree_item);
166 169
167 // Returns the tree item for |node|. 170 // Returns the tree item for |node|.
168 HTREEITEM GetTreeItemForNode(TreeModelNode* node); 171 HTREEITEM GetTreeItemForNode(TreeModelNode* node);
169 172
170 private: 173 private:
171 // See notes in TableView::TableViewWrapper for why this is needed. 174 // See notes in TableView::TableViewWrapper for why this is needed.
172 struct TreeViewWrapper { 175 struct TreeViewWrapper {
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
296 bool has_custom_icons_; 299 bool has_custom_icons_;
297 300
298 HIMAGELIST image_list_; 301 HIMAGELIST image_list_;
299 302
300 DISALLOW_COPY_AND_ASSIGN(TreeView); 303 DISALLOW_COPY_AND_ASSIGN(TreeView);
301 }; 304 };
302 305
303 } // namespace views 306 } // namespace views
304 307
305 #endif // VIEWS_CONTROLS_TREE_TREE_VIEW_H_ 308 #endif // VIEWS_CONTROLS_TREE_TREE_VIEW_H_
OLDNEW
« no previous file with comments | « views/controls/text_field.cc ('k') | views/controls/tree/tree_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698