| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 #ifndef PPAPI_CPP_FULLSCREEN_H_ | 5 #ifndef PPAPI_CPP_FULLSCREEN_H_ |
| 6 #define PPAPI_CPP_FULLSCREEN_H_ | 6 #define PPAPI_CPP_FULLSCREEN_H_ |
| 7 | 7 |
| 8 #include "ppapi/cpp/instance_handle.h" |
| 9 |
| 8 /// @file | 10 /// @file |
| 9 /// This file defines the API for handling transitions of a module instance to | 11 /// This file defines the API for handling transitions of a module instance to |
| 10 /// and from fullscreen mode. | 12 /// and from fullscreen mode. |
| 11 | 13 |
| 12 namespace pp { | 14 namespace pp { |
| 13 | 15 |
| 14 class Instance; | |
| 15 class Size; | 16 class Size; |
| 16 | 17 |
| 17 /// The Fullscreen class allowing you to check and toggle fullscreen mode. | 18 /// The Fullscreen class allowing you to check and toggle fullscreen mode. |
| 18 class Fullscreen { | 19 class Fullscreen { |
| 19 public: | 20 public: |
| 20 /// A constructor for creating a <code>Fullscreen</code>. | 21 /// A constructor for creating a <code>Fullscreen</code>. |
| 21 /// | 22 /// |
| 22 /// @param[in] instance The instance that will own the new | 23 /// @param[in] instance The instance with which this resource will be |
| 23 /// <code>Fullscreen</code>. | 24 /// associated. |
| 24 Fullscreen(Instance* instance); | 25 explicit Fullscreen(const InstanceHandle& instance); |
| 25 | 26 |
| 26 /// Destructor. | 27 /// Destructor. |
| 27 virtual ~Fullscreen(); | 28 virtual ~Fullscreen(); |
| 28 | 29 |
| 29 /// IsFullscreen() checks whether the module instance is currently in | 30 /// IsFullscreen() checks whether the module instance is currently in |
| 30 /// fullscreen mode. | 31 /// fullscreen mode. |
| 31 /// | 32 /// |
| 32 /// @return <code>true</code> if the module instance is in fullscreen mode, | 33 /// @return <code>true</code> if the module instance is in fullscreen mode, |
| 33 /// <code>false</code> if the module instance is not in fullscreen mode. | 34 /// <code>false</code> if the module instance is not in fullscreen mode. |
| 34 bool IsFullscreen(); | 35 bool IsFullscreen(); |
| (...skipping 21 matching lines...) Expand all Loading... |
| 56 /// will be resized to this size when SetFullscreen() is called to enter | 57 /// will be resized to this size when SetFullscreen() is called to enter |
| 57 /// fullscreen mode. | 58 /// fullscreen mode. |
| 58 /// | 59 /// |
| 59 /// @param[out] size The size of the entire screen in pixels. | 60 /// @param[out] size The size of the entire screen in pixels. |
| 60 /// | 61 /// |
| 61 /// @return <code>true</code> on success or <code>false</code> on | 62 /// @return <code>true</code> on success or <code>false</code> on |
| 62 /// failure. | 63 /// failure. |
| 63 bool GetScreenSize(Size* size); | 64 bool GetScreenSize(Size* size); |
| 64 | 65 |
| 65 private: | 66 private: |
| 66 Instance* instance_; | 67 InstanceHandle instance_; |
| 67 }; | 68 }; |
| 68 | 69 |
| 69 } // namespace pp | 70 } // namespace pp |
| 70 | 71 |
| 71 #endif // PPAPI_CPP_FULLSCREEN_H_ | 72 #endif // PPAPI_CPP_FULLSCREEN_H_ |
| OLD | NEW |