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

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

Issue 10828265: Replace views::LocatedEvent with ui::LocatedEvent (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 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 void OpenDownload(); 147 void OpenDownload();
148 148
149 void LoadIcon(); 149 void LoadIcon();
150 void LoadIconIfItemPathChanged(); 150 void LoadIconIfItemPathChanged();
151 151
152 // Shows the context menu at the specified location. |point| is in the view's 152 // Shows the context menu at the specified location. |point| is in the view's
153 // coordinate system. 153 // coordinate system.
154 void ShowContextMenuImpl(const gfx::Point& point, bool is_mouse_gesture); 154 void ShowContextMenuImpl(const gfx::Point& point, bool is_mouse_gesture);
155 155
156 // Common code for handling pointer events (i.e. mouse or gesture). 156 // Common code for handling pointer events (i.e. mouse or gesture).
157 void HandlePressEvent(const views::LocatedEvent& event, bool active_event); 157 void HandlePressEvent(const ui::LocatedEvent& event, bool active_event);
158 void HandleClickEvent(const views::LocatedEvent& event, bool active_event); 158 void HandleClickEvent(const ui::LocatedEvent& event, bool active_event);
159 159
160 // Convenience method to paint the 3 vertical images (bottom, middle, top) 160 // Convenience method to paint the 3 vertical images (bottom, middle, top)
161 // that form the background. 161 // that form the background.
162 void PaintImages(gfx::Canvas* canvas, 162 void PaintImages(gfx::Canvas* canvas,
163 const gfx::ImageSkia* top_image, 163 const gfx::ImageSkia* top_image,
164 const gfx::ImageSkia* center_image, 164 const gfx::ImageSkia* center_image,
165 const gfx::ImageSkia* bottom_image, 165 const gfx::ImageSkia* bottom_image,
166 int x, 166 int x,
167 int y, 167 int y,
168 int height, 168 int height,
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
320 320
321 // The icon loaded in the download shelf is based on the file path of the 321 // 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 322 // item. Store the path used, so that we can detect a change in the path
323 // and reload the icon. 323 // and reload the icon.
324 FilePath last_download_item_path_; 324 FilePath last_download_item_path_;
325 325
326 DISALLOW_COPY_AND_ASSIGN(DownloadItemView); 326 DISALLOW_COPY_AND_ASSIGN(DownloadItemView);
327 }; 327 };
328 328
329 #endif // CHROME_BROWSER_UI_VIEWS_DOWNLOAD_DOWNLOAD_ITEM_VIEW_H__ 329 #endif // CHROME_BROWSER_UI_VIEWS_DOWNLOAD_DOWNLOAD_ITEM_VIEW_H__
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698