Pepper (Flash): Make pp::flash::Flash::InvokePrinting() return a bool.
[chromium-blink-merge.git] / ppapi / cpp / private / flash.h
blobd14dbfe3c2678ecaca924a5c53db719ac6c9c7d1
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.
5 #ifndef PPAPI_CPP_PRIVATE_FLASH_H_
6 #define PPAPI_CPP_PRIVATE_FLASH_H_
8 #include <string>
10 #include "ppapi/c/private/ppb_flash.h"
11 #include "ppapi/c/pp_stdint.h"
12 #include "ppapi/c/pp_time.h"
14 struct PP_Point;
16 namespace pp {
18 class FontDescription_Dev;
19 class ImageData;
20 class InstanceHandle;
21 class Module;
22 class Point;
23 class Rect;
24 class URLRequestInfo;
25 class Var;
27 namespace flash {
29 class Flash {
30 public:
31 // Returns true if the required interface is available.
32 static bool IsAvailable();
34 static void SetInstanceAlwaysOnTop(const InstanceHandle& instance,
35 bool on_top);
36 static bool DrawGlyphs(const InstanceHandle& instance,
37 ImageData* image,
38 const FontDescription_Dev& font_desc,
39 uint32_t color,
40 const Point& position,
41 const Rect& clip,
42 const float transformation[3][3],
43 bool allow_subpixel_aa,
44 uint32_t glyph_count,
45 const uint16_t glyph_indices[],
46 const PP_Point glyph_advances[]);
47 static Var GetProxyForURL(const InstanceHandle& instance,
48 const std::string& url);
49 static int32_t Navigate(const URLRequestInfo& request_info,
50 const std::string& target,
51 bool from_user_action);
52 static void RunMessageLoop(const InstanceHandle& instance);
53 static void QuitMessageLoop(const InstanceHandle& instance);
54 static double GetLocalTimeZoneOffset(const InstanceHandle& instance,
55 PP_Time t);
56 static Var GetCommandLineArgs(Module* module);
57 static void PreloadFontWin(const void* logfontw);
58 static bool IsRectTopmost(const InstanceHandle& instance, const Rect& rect);
59 static void UpdateActivity(const InstanceHandle& instance);
60 static Var GetDeviceID(const InstanceHandle& instance);
61 static int32_t GetSettingInt(const InstanceHandle& instance,
62 PP_FlashSetting setting);
63 static void SetAllowSuddenTermination(const InstanceHandle& instance,
64 bool allowed);
65 // PPB_Flash_Print.
66 static bool InvokePrinting(const InstanceHandle& instance);
69 } // namespace flash
70 } // namespace pp
72 #endif // PPAPI_CPP_PRIVATE_FLASH_H_