OLD | NEW |
| (Empty) |
1 // Copyright 2014 PDFium 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 | |
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | |
6 | |
7 #ifndef CORE_FXGE_APPLE_CFX_QUARTZDEVICE_H_ | |
8 #define CORE_FXGE_APPLE_CFX_QUARTZDEVICE_H_ | |
9 | |
10 #if _FXM_PLATFORM_ == _FXM_PLATFORM_APPLE_ | |
11 | |
12 #include "core/fxge/cfx_renderdevice.h" | |
13 | |
14 class CFX_QuartzDevice : public CFX_RenderDevice { | |
15 public: | |
16 CFX_QuartzDevice(); | |
17 ~CFX_QuartzDevice() override; | |
18 | |
19 bool Attach(CGContextRef context, int32_t nDeviceClass = FXDC_DISPLAY); | |
20 bool Attach(CFX_DIBitmap* pBitmap); | |
21 bool Create(int32_t width, int32_t height, FXDIB_Format format); | |
22 | |
23 CGContextRef GetContext(); | |
24 | |
25 protected: | |
26 CGContextRef m_pContext; | |
27 bool m_bOwnedBitmap; | |
28 }; | |
29 #endif | |
30 | |
31 #endif // CORE_FXGE_APPLE_CFX_QUARTZDEVICE_H_ | |
OLD | NEW |