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

Unified Diff: ui/base/cursor/ozone/bitmap_cursor_factory_ozone.h

Issue 543643003: ozone: Plumb animated cursors from BitmapCursorFactoryOzone to DriSurfaceFactory (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix dri_surface_factory_unittest Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ui/base/cursor/ozone/bitmap_cursor_factory_ozone.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/cursor/ozone/bitmap_cursor_factory_ozone.h
diff --git a/ui/base/cursor/ozone/bitmap_cursor_factory_ozone.h b/ui/base/cursor/ozone/bitmap_cursor_factory_ozone.h
index 7576af1da666a1dc8508a594a6ecfa8029e52fa9..dc51602cf13426ccab76b3f74d87c64db6320d4c 100644
--- a/ui/base/cursor/ozone/bitmap_cursor_factory_ozone.h
+++ b/ui/base/cursor/ozone/bitmap_cursor_factory_ozone.h
@@ -20,18 +20,25 @@ namespace ui {
class UI_BASE_EXPORT BitmapCursorOzone
: public base::RefCounted<BitmapCursorOzone> {
public:
- BitmapCursorOzone(const SkBitmap& bitmap, const gfx::Point& hotspot)
- : bitmap_(bitmap), hotspot_(hotspot) {}
+ BitmapCursorOzone(const SkBitmap& bitmap, const gfx::Point& hotspot);
+ BitmapCursorOzone(const std::vector<SkBitmap>& bitmaps,
+ const gfx::Point& hotspot,
+ int frame_delay_ms);
- const gfx::Point& hotspot() { return hotspot_; }
- const SkBitmap& bitmap() { return bitmap_; }
+ const gfx::Point& hotspot();
+ const SkBitmap& bitmap();
+
+ // For animated cursors.
+ const std::vector<SkBitmap>& bitmaps();
+ int frame_delay_ms();
private:
friend class base::RefCounted<BitmapCursorOzone>;
- ~BitmapCursorOzone() {}
+ ~BitmapCursorOzone();
- SkBitmap bitmap_;
+ std::vector<SkBitmap> bitmaps_;
gfx::Point hotspot_;
+ int frame_delay_ms_;
DISALLOW_COPY_AND_ASSIGN(BitmapCursorOzone);
};
« no previous file with comments | « no previous file | ui/base/cursor/ozone/bitmap_cursor_factory_ozone.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698