Fix iOS build for XCode 4.6.
[chromium-blink-merge.git] / ppapi / api / ppb_fullscreen.idl
blob2f26418258ea2d4cff8f4fc832315df5f30d846e
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 */
7 /**
8 * This file defines the <code>PPB_Fullscreen</code> interface for
9 * handling transitions of a module instance to and from fullscreen mode.
12 label Chrome {
13 M16 = 1.0
16 /**
17 * The <code>PPB_Fullscreen</code> interface is implemented by the browser.
18 * This interface provides a way of checking the current screen mode and
19 * toggling fullscreen mode.
21 interface PPB_Fullscreen {
22 /**
23 * IsFullscreen() checks whether the module instance is currently in
24 * fullscreen mode.
26 * @param[in] instance A <code>PP_Instance</code> identifying one instance
27 * of a module.
29 * @return <code>PP_TRUE</code> if the module instance is in fullscreen mode,
30 * <code>PP_FALSE</code> if the module instance is not in fullscreen mode.
32 PP_Bool IsFullscreen(
33 [in] PP_Instance instance);
35 /**
36 * SetFullscreen() switches the module instance to and from fullscreen
37 * mode.
39 * The transition to and from fullscreen mode is asynchronous. During the
40 * transition, IsFullscreen() will return the previous value and
41 * no 2D or 3D device can be bound. The transition ends at DidChangeView()
42 * when IsFullscreen() returns the new value. You might receive other
43 * DidChangeView() calls while in transition.
45 * The transition to fullscreen mode can only occur while the browser is
46 * processing a user gesture, even if <code>PP_TRUE</code> is returned.
48 * @param[in] instance A <code>PP_Instance</code> identifying one instance
49 * of a module.
50 * @param[in] fullscreen <code>PP_TRUE</code> to enter fullscreen mode, or
51 * <code>PP_FALSE</code> to exit fullscreen mode.
53 * @return <code>PP_TRUE</code> on success or <code>PP_FALSE</code> on
54 * failure.
56 PP_Bool SetFullscreen(
57 [in] PP_Instance instance,
58 [in] PP_Bool fullscreen);
60 /**
61 * GetScreenSize() gets the size of the screen in pixels. The module instance
62 * will be resized to this size when SetFullscreen() is called to enter
63 * fullscreen mode.
65 * @param[in] instance A <code>PP_Instance</code> identifying one instance
66 * of a module.
67 * @param[out] size The size of the entire screen in pixels.
69 * @return <code>PP_TRUE</code> on success or <code>PP_FALSE</code> on
70 * failure.
72 PP_Bool GetScreenSize(
73 [in] PP_Instance instance,
74 [out] PP_Size size);