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.
8 * This file defines the <code>PPB_Fullscreen</code> interface for
9 * handling transitions of a module instance to and from fullscreen mode.
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
{
23 * IsFullscreen() checks whether the module instance is currently in
26 * @param[in] instance A <code>PP_Instance</code> identifying one instance
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.
33 [in] PP_Instance instance
);
36 * SetFullscreen() switches the module instance to and from fullscreen
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
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
56 PP_Bool SetFullscreen
(
57 [in] PP_Instance instance
,
58 [in] PP_Bool fullscreen
);
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
65 * @param[in] instance A <code>PP_Instance</code> identifying one instance
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
72 PP_Bool GetScreenSize
(
73 [in] PP_Instance instance
,