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

Side by Side Diff: ppapi/api/ppp_instance.idl

Issue 8951014: Change the DidChangeView update to take a new ViewChanged resource. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: new patch Created 9 years 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) 2011 The Chromium Authors. All rights reserved. 1 /* Copyright (c) 2011 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 5
6 /** 6 /**
7 * This file defines the <code>PPP_Instance</code> structure - a series of 7 * This file defines the <code>PPP_Instance</code> structure - a series of
8 * pointers to methods that you must implement in your module. 8 * pointers to methods that you must implement in your module.
9 */ 9 */
10 10
11 label Chrome { 11 label Chrome {
12 M14 = 1.0 12 M14 = 1.0,
13 M17 = 1.1
13 }; 14 };
14 15
15 /** 16 /**
16 * The <code>PPP_Instance</code> interface contains pointers to a series of 17 * The <code>PPP_Instance</code> interface contains pointers to a series of
17 * functions that you must implement in your module. These functions can be 18 * functions that you must implement in your module. These functions can be
18 * trivial (simply return the default return value) unless you want your module 19 * trivial (simply return the default return value) unless you want your module
19 * to handle events such as change of focus or input events (keyboard/mouse) 20 * to handle events such as change of focus or input events (keyboard/mouse)
20 * events. 21 * events.
21 */ 22 */
22 interface PPP_Instance { 23 interface PPP_Instance {
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 * The module will just be unloaded and the process terminated. 104 * The module will just be unloaded and the process terminated.
104 * 105 *
105 * @param[in] instance A <code>PP_Instance</code> identifying one instance 106 * @param[in] instance A <code>PP_Instance</code> identifying one instance
106 * of a module. 107 * of a module.
107 */ 108 */
108 void DidDestroy( 109 void DidDestroy(
109 /* A PP_Instance identifying one instance of a module. */ 110 /* A PP_Instance identifying one instance of a module. */
110 [in] PP_Instance instance); 111 [in] PP_Instance instance);
111 112
112 /** 113 /**
114 * Deprecated in 1.1 in favor of the version that takes a Resource.
115 *
113 * DidChangeView() is called when the position, the size, of the clip 116 * DidChangeView() is called when the position, the size, of the clip
114 * rectangle of the element in the browser that corresponds to this 117 * rectangle of the element in the browser that corresponds to this
115 * instance has changed. 118 * instance has changed.
116 * 119 *
117 * A typical implementation will check the size of the <code>position</code> 120 * A typical implementation will check the size of the <code>position</code>
118 * argument and reallocate the graphics context when a different size is 121 * argument and reallocate the graphics context when a different size is
119 * received. Note that this function will be called for scroll events where 122 * received. Note that this function will be called for scroll events where
120 * the size doesn't change, so you should always check that the size is 123 * the size doesn't change, so you should always check that the size is
121 * actually different before doing any reallocations. 124 * actually different before doing any reallocations.
122 * 125 *
(...skipping 27 matching lines...) Expand all
150 * page is scrolled. 153 * page is scrolled.
151 */ 154 */
152 [in] PP_Rect position, 155 [in] PP_Rect position,
153 /* The visible region of the NaCl module. This is relative to the top 156 /* The visible region of the NaCl module. This is relative to the top
154 * left of the plugin's coordinate system (not the page) If the plugin 157 * left of the plugin's coordinate system (not the page) If the plugin
155 * is invisible, clip will be (0, 0, 0, 0). 158 * is invisible, clip will be (0, 0, 0, 0).
156 */ 159 */
157 [in] PP_Rect clip); 160 [in] PP_Rect clip);
158 161
159 /** 162 /**
163 * <code>DidChangeView() is called when the position, size, or other view
164 * attributes of the instance has changed.
165 */
166 [version=1.1]
167 void DidChangeView(
168 /* A PP_Instance identifying the instance whose view changed. */
169 [in] PP_Instance instance,
170 /**
171 * A handle to a <code>PPB_View</code> resource identifying the new view.
172 */
173 [in] PP_Resource view_resource);
174
175 /**
160 * DidChangeFocus() is called when an instance has gained or lost focus. 176 * DidChangeFocus() is called when an instance has gained or lost focus.
161 * Having focus means that keyboard events will be sent to the instance. 177 * Having focus means that keyboard events will be sent to the instance.
162 * An instance's default condition is that it will not have focus. 178 * An instance's default condition is that it will not have focus.
163 * 179 *
164 * <strong>Note:</strong>Clicks on instances will give focus only if you 180 * <strong>Note:</strong>Clicks on instances will give focus only if you
165 * handle the click event. Return <code>true</code> from 181 * handle the click event. Return <code>true</code> from
166 * <code>HandleInputEvent</code> in <code>PPP_InputEvent</code> (or use 182 * <code>HandleInputEvent</code> in <code>PPP_InputEvent</code> (or use
167 * unfiltered events) to signal that the click event was handled. Otherwise, 183 * unfiltered events) to signal that the click event was handled. Otherwise,
168 * the browser will bubble the event and give focus to the element on the page 184 * the browser will bubble the event and give focus to the element on the page
169 * that actually did end up consuming it. If you're not getting focus, check 185 * that actually did end up consuming it. If you're not getting focus, check
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 PP_Bool HandleDocumentLoad( 227 PP_Bool HandleDocumentLoad(
212 /* A PP_Instance identifying one instance of a module. */ 228 /* A PP_Instance identifying one instance of a module. */
213 [in] PP_Instance instance, 229 [in] PP_Instance instance,
214 /* A PP_Resource an open PPB_URLLoader instance. */ 230 /* A PP_Resource an open PPB_URLLoader instance. */
215 [in] PP_Resource url_loader); 231 [in] PP_Resource url_loader);
216 232
217 }; 233 };
218 234
219 #inline c 235 #inline c
220 236
221 typedef struct PPP_Instance PPP_Instance_1_0; 237 typedef struct PPP_Instance PPP_Instance_1_1;
222 238
223 #endinl 239 #endinl
224 240
OLDNEW
« no previous file with comments | « ppapi/api/ppb_view.idl ('k') | ppapi/c/ppb_fullscreen.h » ('j') | ppapi/example/example.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698