Pepper_31_C_interfaces
Main Page
Modules
Classes
Files
File List
File Members
ppb_mouse_cursor.h
Go to the documentation of this file.
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
3
* found in the LICENSE file.
4
*/
5
6
/* From ppb_mouse_cursor.idl modified Thu Mar 28 10:11:32 2013. */
7
8
#ifndef PPAPI_C_PPB_MOUSE_CURSOR_H_
9
#define PPAPI_C_PPB_MOUSE_CURSOR_H_
10
11
#include "ppapi/c/pp_bool.h"
12
#include "ppapi/c/pp_instance.h"
13
#include "ppapi/c/pp_macros.h"
14
#include "ppapi/c/pp_point.h"
15
#include "ppapi/c/pp_resource.h"
16
#include "ppapi/c/pp_stdint.h"
17
18
#define PPB_MOUSECURSOR_INTERFACE_1_0 "PPB_MouseCursor;1.0"
19
#define PPB_MOUSECURSOR_INTERFACE PPB_MOUSECURSOR_INTERFACE_1_0
20
21
/**
22
* @file
23
* This file defines the <code>PPB_MouseCursor</code> interface for setting
24
* the mouse cursor.
25
*/
26
27
28
/**
29
* @addtogroup Enums
30
* @{
31
*/
32
/**
33
* The <code>PP_MouseCursor_Type</code> enumeration lists the available stock
34
* cursor types.
35
*/
36
enum
PP_MouseCursor_Type
{
37
PP_MOUSECURSOR_TYPE_CUSTOM
= -1,
38
PP_MOUSECURSOR_TYPE_POINTER
= 0,
39
PP_MOUSECURSOR_TYPE_CROSS
= 1,
40
PP_MOUSECURSOR_TYPE_HAND
= 2,
41
PP_MOUSECURSOR_TYPE_IBEAM
= 3,
42
PP_MOUSECURSOR_TYPE_WAIT
= 4,
43
PP_MOUSECURSOR_TYPE_HELP
= 5,
44
PP_MOUSECURSOR_TYPE_EASTRESIZE
= 6,
45
PP_MOUSECURSOR_TYPE_NORTHRESIZE
= 7,
46
PP_MOUSECURSOR_TYPE_NORTHEASTRESIZE
= 8,
47
PP_MOUSECURSOR_TYPE_NORTHWESTRESIZE
= 9,
48
PP_MOUSECURSOR_TYPE_SOUTHRESIZE
= 10,
49
PP_MOUSECURSOR_TYPE_SOUTHEASTRESIZE
= 11,
50
PP_MOUSECURSOR_TYPE_SOUTHWESTRESIZE
= 12,
51
PP_MOUSECURSOR_TYPE_WESTRESIZE
= 13,
52
PP_MOUSECURSOR_TYPE_NORTHSOUTHRESIZE
= 14,
53
PP_MOUSECURSOR_TYPE_EASTWESTRESIZE
= 15,
54
PP_MOUSECURSOR_TYPE_NORTHEASTSOUTHWESTRESIZE
= 16,
55
PP_MOUSECURSOR_TYPE_NORTHWESTSOUTHEASTRESIZE
= 17,
56
PP_MOUSECURSOR_TYPE_COLUMNRESIZE
= 18,
57
PP_MOUSECURSOR_TYPE_ROWRESIZE
= 19,
58
PP_MOUSECURSOR_TYPE_MIDDLEPANNING
= 20,
59
PP_MOUSECURSOR_TYPE_EASTPANNING
= 21,
60
PP_MOUSECURSOR_TYPE_NORTHPANNING
= 22,
61
PP_MOUSECURSOR_TYPE_NORTHEASTPANNING
= 23,
62
PP_MOUSECURSOR_TYPE_NORTHWESTPANNING
= 24,
63
PP_MOUSECURSOR_TYPE_SOUTHPANNING
= 25,
64
PP_MOUSECURSOR_TYPE_SOUTHEASTPANNING
= 26,
65
PP_MOUSECURSOR_TYPE_SOUTHWESTPANNING
= 27,
66
PP_MOUSECURSOR_TYPE_WESTPANNING
= 28,
67
PP_MOUSECURSOR_TYPE_MOVE
= 29,
68
PP_MOUSECURSOR_TYPE_VERTICALTEXT
= 30,
69
PP_MOUSECURSOR_TYPE_CELL
= 31,
70
PP_MOUSECURSOR_TYPE_CONTEXTMENU
= 32,
71
PP_MOUSECURSOR_TYPE_ALIAS
= 33,
72
PP_MOUSECURSOR_TYPE_PROGRESS
= 34,
73
PP_MOUSECURSOR_TYPE_NODROP
= 35,
74
PP_MOUSECURSOR_TYPE_COPY
= 36,
75
PP_MOUSECURSOR_TYPE_NONE
= 37,
76
PP_MOUSECURSOR_TYPE_NOTALLOWED
= 38,
77
PP_MOUSECURSOR_TYPE_ZOOMIN
= 39,
78
PP_MOUSECURSOR_TYPE_ZOOMOUT
= 40,
79
PP_MOUSECURSOR_TYPE_GRAB
= 41,
80
PP_MOUSECURSOR_TYPE_GRABBING
= 42
81
};
82
PP_COMPILE_ASSERT_ENUM_SIZE_IN_BYTES
(
PP_MouseCursor_Type
, 4);
83
/**
84
* @}
85
*/
86
87
/**
88
* @addtogroup Interfaces
89
* @{
90
*/
91
/**
92
* The <code>PPB_MouseCursor</code> allows setting the mouse cursor.
93
*/
94
struct
PPB_MouseCursor_1_0
{
95
/**
96
* Sets the given mouse cursor. The mouse cursor will be in effect whenever
97
* the mouse is over the given instance until it is set again by another
98
* call. Note that you can hide the mouse cursor by setting it to the
99
* <code>PP_MOUSECURSOR_TYPE_NONE</code> type.
100
*
101
* This function allows setting both system defined mouse cursors and
102
* custom cursors. To set a system-defined cursor, pass the type you want
103
* and set the custom image to 0 and the hot spot to NULL. To set a custom
104
* cursor, set the type to <code>PP_MOUSECURSOR_TYPE_CUSTOM</code> and
105
* specify your image and hot spot.
106
*
107
* @param[in] instance A <code>PP_Instance</code> identifying the instance
108
* that the mouse cursor will affect.
109
*
110
* @param[in] type A <code>PP_MouseCursor_Type</code> identifying the type of
111
* mouse cursor to show.
112
*
113
* @param[in] image A <code>PPB_ImageData</code> resource identifying the
114
* custom image to set when the type is
115
* <code>PP_MOUSECURSOR_TYPE_CUSTOM</code>. The image must be less than 32
116
* pixels in each direction and must be of the system's native image format.
117
* When you are specifying a predefined cursor, this parameter must be 0.
118
*
119
* @param[in] hot_spot When setting a custom cursor, this identifies the
120
* pixel position within the given image of the "hot spot" of the cursor.
121
* When specifying a stock cursor, this parameter is ignored.
122
*
123
* @return PP_TRUE on success, or PP_FALSE if the instance or cursor type
124
* is invalid, or if the image is too large.
125
*/
126
PP_Bool
(*
SetCursor
)(
PP_Instance
instance,
127
enum
PP_MouseCursor_Type
type,
128
PP_Resource
image,
129
const
struct
PP_Point
* hot_spot);
130
};
131
132
typedef
struct
PPB_MouseCursor_1_0
PPB_MouseCursor
;
133
/**
134
* @}
135
*/
136
137
#endif
/* PPAPI_C_PPB_MOUSE_CURSOR_H_ */
138
PP_MOUSECURSOR_TYPE_PROGRESS
Definition:
ppb_mouse_cursor.h:72
PP_MOUSECURSOR_TYPE_NORTHEASTPANNING
Definition:
ppb_mouse_cursor.h:61
PP_MOUSECURSOR_TYPE_NODROP
Definition:
ppb_mouse_cursor.h:73
PP_MOUSECURSOR_TYPE_EASTPANNING
Definition:
ppb_mouse_cursor.h:59
PP_MOUSECURSOR_TYPE_SOUTHEASTPANNING
Definition:
ppb_mouse_cursor.h:64
PPB_MouseCursor_1_0
Definition:
ppb_mouse_cursor.h:94
PP_MouseCursor_Type
PP_MouseCursor_Type
Definition:
ppb_mouse_cursor.h:36
PP_MOUSECURSOR_TYPE_SOUTHWESTPANNING
Definition:
ppb_mouse_cursor.h:65
PP_MOUSECURSOR_TYPE_NONE
Definition:
ppb_mouse_cursor.h:75
PP_MOUSECURSOR_TYPE_VERTICALTEXT
Definition:
ppb_mouse_cursor.h:68
PP_MOUSECURSOR_TYPE_IBEAM
Definition:
ppb_mouse_cursor.h:41
PP_MOUSECURSOR_TYPE_SOUTHEASTRESIZE
Definition:
ppb_mouse_cursor.h:49
PP_MOUSECURSOR_TYPE_NORTHSOUTHRESIZE
Definition:
ppb_mouse_cursor.h:52
PP_COMPILE_ASSERT_ENUM_SIZE_IN_BYTES
PP_COMPILE_ASSERT_ENUM_SIZE_IN_BYTES(PP_MouseCursor_Type, 4)
PP_MOUSECURSOR_TYPE_EASTRESIZE
Definition:
ppb_mouse_cursor.h:44
PP_MOUSECURSOR_TYPE_NORTHWESTPANNING
Definition:
ppb_mouse_cursor.h:62
PP_MOUSECURSOR_TYPE_NORTHPANNING
Definition:
ppb_mouse_cursor.h:60
PP_MOUSECURSOR_TYPE_NORTHWESTRESIZE
Definition:
ppb_mouse_cursor.h:47
PP_MOUSECURSOR_TYPE_NORTHRESIZE
Definition:
ppb_mouse_cursor.h:45
PP_MOUSECURSOR_TYPE_GRAB
Definition:
ppb_mouse_cursor.h:79
PP_Resource
int32_t PP_Resource
Definition:
pp_resource.h:40
PP_MOUSECURSOR_TYPE_NORTHEASTRESIZE
Definition:
ppb_mouse_cursor.h:46
PP_MOUSECURSOR_TYPE_NORTHEASTSOUTHWESTRESIZE
Definition:
ppb_mouse_cursor.h:54
PP_MOUSECURSOR_TYPE_ROWRESIZE
Definition:
ppb_mouse_cursor.h:57
PP_MOUSECURSOR_TYPE_MIDDLEPANNING
Definition:
ppb_mouse_cursor.h:58
PP_MOUSECURSOR_TYPE_POINTER
Definition:
ppb_mouse_cursor.h:38
PP_MOUSECURSOR_TYPE_COPY
Definition:
ppb_mouse_cursor.h:74
PP_Point
Definition:
pp_point.h:28
PP_MOUSECURSOR_TYPE_WESTPANNING
Definition:
ppb_mouse_cursor.h:66
PP_MOUSECURSOR_TYPE_HELP
Definition:
ppb_mouse_cursor.h:43
PP_MOUSECURSOR_TYPE_CELL
Definition:
ppb_mouse_cursor.h:69
PP_MOUSECURSOR_TYPE_CONTEXTMENU
Definition:
ppb_mouse_cursor.h:70
PP_MOUSECURSOR_TYPE_SOUTHRESIZE
Definition:
ppb_mouse_cursor.h:48
PP_MOUSECURSOR_TYPE_ZOOMIN
Definition:
ppb_mouse_cursor.h:77
PPB_MouseCursor_1_0::SetCursor
PP_Bool(* SetCursor)(PP_Instance instance, enum PP_MouseCursor_Type type, PP_Resource image, const struct PP_Point *hot_spot)
Definition:
ppb_mouse_cursor.h:126
PP_Instance
int32_t PP_Instance
Definition:
pp_instance.h:34
PP_MOUSECURSOR_TYPE_NOTALLOWED
Definition:
ppb_mouse_cursor.h:76
PP_MOUSECURSOR_TYPE_EASTWESTRESIZE
Definition:
ppb_mouse_cursor.h:53
PP_MOUSECURSOR_TYPE_SOUTHWESTRESIZE
Definition:
ppb_mouse_cursor.h:50
PP_MOUSECURSOR_TYPE_SOUTHPANNING
Definition:
ppb_mouse_cursor.h:63
PP_MOUSECURSOR_TYPE_CROSS
Definition:
ppb_mouse_cursor.h:39
PP_MOUSECURSOR_TYPE_CUSTOM
Definition:
ppb_mouse_cursor.h:37
PP_Bool
PP_Bool
Definition:
pp_bool.h:30
PP_MOUSECURSOR_TYPE_ALIAS
Definition:
ppb_mouse_cursor.h:71
PP_MOUSECURSOR_TYPE_HAND
Definition:
ppb_mouse_cursor.h:40
PP_MOUSECURSOR_TYPE_WAIT
Definition:
ppb_mouse_cursor.h:42
PP_MOUSECURSOR_TYPE_ZOOMOUT
Definition:
ppb_mouse_cursor.h:78
PP_MOUSECURSOR_TYPE_NORTHWESTSOUTHEASTRESIZE
Definition:
ppb_mouse_cursor.h:55
PP_MOUSECURSOR_TYPE_WESTRESIZE
Definition:
ppb_mouse_cursor.h:51
PP_MOUSECURSOR_TYPE_COLUMNRESIZE
Definition:
ppb_mouse_cursor.h:56
PP_MOUSECURSOR_TYPE_MOVE
Definition:
ppb_mouse_cursor.h:67
PP_MOUSECURSOR_TYPE_GRABBING
Definition:
ppb_mouse_cursor.h:80
Generated on Wed May 4 2016 11:31:13 for Pepper_31_C_interfaces by
1.8.6