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

Side by Side Diff: services/ui/public/interfaces/cursor/cursor.mojom

Issue 2786983003: [aura-mus] Add ui::CursorData, with mojo serialization. (Closed)
Patch Set: Enhance the test and comment mojom. Created 3 years, 8 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 module ui.mojom; 5 module ui.mojom;
6 6
7 import "ui/gfx/geometry/mojo/geometry.mojom";
8 import "skia/public/interfaces/bitmap_array.mojom";
9
7 // Standard Cursor numbers. These are the same as Chrome's ui::Cursor and 10 // Standard Cursor numbers. These are the same as Chrome's ui::Cursor and
8 // blink's WebCursorInfo. 11 // blink's WebCursorInfo.
9 enum CursorType { 12 enum CursorType {
10 // NULL is kept for compatibility with chrome declarations. In chrome code, it 13 // NULL is kept for compatibility with chrome declarations. In chrome code, it
11 // is treated exactly like POINTER, the default pointer. 14 // is treated exactly like POINTER, the default pointer.
12 CURSOR_NULL = 0, 15 CURSOR_NULL = 0,
13 POINTER, 16 POINTER,
14 CROSS, 17 CROSS,
15 HAND, 18 HAND,
16 IBEAM, 19 IBEAM,
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 NO_DROP, 51 NO_DROP,
49 COPY, 52 COPY,
50 NONE, 53 NONE,
51 NOT_ALLOWED, 54 NOT_ALLOWED,
52 ZOOM_IN, 55 ZOOM_IN,
53 ZOOM_OUT, 56 ZOOM_OUT,
54 GRAB, 57 GRAB,
55 GRABBING, 58 GRABBING,
56 CUSTOM 59 CUSTOM
57 }; 60 };
61
62 // A description of a cursor.
63 struct CursorData {
64 // The type of cursor. If CUSTOM, the rest of the fields are relevant.
65 CursorType native_type;
sky 2017/03/31 04:57:57 cursor_type?
Elliot Glaysher 2017/03/31 21:18:15 Done.
66
67 // The delay between cursor frames in milliseconds.
68 uint32 frame_delay_ms;
69
70 // The hotspot in cursor frames.
71 gfx.mojom.Point hotspot;
sky 2017/03/31 04:57:57 Is this pixels or dips? Generally if we don't say
Elliot Glaysher 2017/03/31 21:18:15 added "_in_pixels" suffix.
72
73 // The frames of the cursor.
74 skia.mojom.BitmapArray cursor_frames;
sky 2017/03/31 04:57:57 Do cursors vary depending upon dpi? Is it expected
sky 2017/03/31 04:57:57 Would it be better to use shared memory for the bi
Tom Sepez 2017/03/31 16:07:07 Arbitrarily deep? Not sure it matters ...
Elliot Glaysher 2017/03/31 21:18:15 Assuming the user is actually checking IsSameAs()
Elliot Glaysher 2017/03/31 21:18:15 I'm not sure what you're asking here.
Elliot Glaysher 2017/03/31 21:18:15 You're right and I misread this. Added an |image_s
75 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698