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

Side by Side Diff: chrome/browser/ui/views/download/download_item_view.h

Issue 10824295: Rid the world of the last of views::Event types: TouchEvent, GestureEvent, MouseWheelEvent, ScrollE… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 4 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // A ChromeView that implements one download on the Download shelf. 5 // A ChromeView that implements one download on the Download shelf.
6 // Each DownloadItemView contains an application icon, a text label 6 // Each DownloadItemView contains an application icon, a text label
7 // indicating the download's file name, a text label indicating the 7 // indicating the download's file name, a text label indicating the
8 // download's status (such as the number of bytes downloaded so far) 8 // download's status (such as the number of bytes downloaded so far)
9 // and a button for canceling an in progress download, or opening 9 // and a button for canceling an in progress download, or opening
10 // the completed download. 10 // the completed download.
(...skipping 14 matching lines...) Expand all
25 #include "base/time.h" 25 #include "base/time.h"
26 #include "base/timer.h" 26 #include "base/timer.h"
27 #include "chrome/browser/cancelable_request.h" 27 #include "chrome/browser/cancelable_request.h"
28 #include "chrome/browser/icon_manager.h" 28 #include "chrome/browser/icon_manager.h"
29 #include "content/public/browser/download_item.h" 29 #include "content/public/browser/download_item.h"
30 #include "content/public/browser/download_manager.h" 30 #include "content/public/browser/download_manager.h"
31 #include "ui/base/animation/animation_delegate.h" 31 #include "ui/base/animation/animation_delegate.h"
32 #include "ui/gfx/font.h" 32 #include "ui/gfx/font.h"
33 #include "ui/views/context_menu_controller.h" 33 #include "ui/views/context_menu_controller.h"
34 #include "ui/views/controls/button/button.h" 34 #include "ui/views/controls/button/button.h"
35 #include "ui/views/events/event.h"
36 #include "ui/views/view.h" 35 #include "ui/views/view.h"
37 36
38 class BaseDownloadItemModel; 37 class BaseDownloadItemModel;
39 class DownloadShelfView; 38 class DownloadShelfView;
40 class DownloadShelfContextMenuView; 39 class DownloadShelfContextMenuView;
41 40
42 namespace gfx { 41 namespace gfx {
43 class Image; 42 class Image;
44 class ImageSkia; 43 class ImageSkia;
45 } 44 }
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 virtual void Layout() OVERRIDE; 83 virtual void Layout() OVERRIDE;
85 virtual gfx::Size GetPreferredSize() OVERRIDE; 84 virtual gfx::Size GetPreferredSize() OVERRIDE;
86 virtual bool OnMousePressed(const ui::MouseEvent& event) OVERRIDE; 85 virtual bool OnMousePressed(const ui::MouseEvent& event) OVERRIDE;
87 virtual bool OnMouseDragged(const ui::MouseEvent& event) OVERRIDE; 86 virtual bool OnMouseDragged(const ui::MouseEvent& event) OVERRIDE;
88 virtual void OnMouseReleased(const ui::MouseEvent& event) OVERRIDE; 87 virtual void OnMouseReleased(const ui::MouseEvent& event) OVERRIDE;
89 virtual void OnMouseCaptureLost() OVERRIDE; 88 virtual void OnMouseCaptureLost() OVERRIDE;
90 virtual void OnMouseMoved(const ui::MouseEvent& event) OVERRIDE; 89 virtual void OnMouseMoved(const ui::MouseEvent& event) OVERRIDE;
91 virtual void OnMouseExited(const ui::MouseEvent& event) OVERRIDE; 90 virtual void OnMouseExited(const ui::MouseEvent& event) OVERRIDE;
92 virtual bool OnKeyPressed(const ui::KeyEvent& event) OVERRIDE; 91 virtual bool OnKeyPressed(const ui::KeyEvent& event) OVERRIDE;
93 virtual ui::GestureStatus OnGestureEvent( 92 virtual ui::GestureStatus OnGestureEvent(
94 const views::GestureEvent& event) OVERRIDE; 93 const ui::GestureEvent& event) OVERRIDE;
95 virtual bool GetTooltipText(const gfx::Point& p, 94 virtual bool GetTooltipText(const gfx::Point& p,
96 string16* tooltip) const OVERRIDE; 95 string16* tooltip) const OVERRIDE;
97 virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE; 96 virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE;
98 97
99 // Overridden from views::ContextMenuController. 98 // Overridden from views::ContextMenuController.
100 virtual void ShowContextMenuForView(View* source, 99 virtual void ShowContextMenuForView(View* source,
101 const gfx::Point& point) OVERRIDE; 100 const gfx::Point& point) OVERRIDE;
102 101
103 // ButtonListener implementation. 102 // ButtonListener implementation.
104 virtual void ButtonPressed(views::Button* sender, 103 virtual void ButtonPressed(views::Button* sender,
(...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after
320 319
321 // The icon loaded in the download shelf is based on the file path of the 320 // The icon loaded in the download shelf is based on the file path of the
322 // item. Store the path used, so that we can detect a change in the path 321 // item. Store the path used, so that we can detect a change in the path
323 // and reload the icon. 322 // and reload the icon.
324 FilePath last_download_item_path_; 323 FilePath last_download_item_path_;
325 324
326 DISALLOW_COPY_AND_ASSIGN(DownloadItemView); 325 DISALLOW_COPY_AND_ASSIGN(DownloadItemView);
327 }; 326 };
328 327
329 #endif // CHROME_BROWSER_UI_VIEWS_DOWNLOAD_DOWNLOAD_ITEM_VIEW_H__ 328 #endif // CHROME_BROWSER_UI_VIEWS_DOWNLOAD_DOWNLOAD_ITEM_VIEW_H__
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/chrome_to_mobile_bubble_view.cc ('k') | chrome/browser/ui/views/download/download_item_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698