OLD | NEW |
1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium 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 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
6 | 6 |
7 #ifndef _FX_GE_WIN32_H_ | 7 #ifndef _FX_GE_WIN32_H_ |
8 #define _FX_GE_WIN32_H_ | 8 #define _FX_GE_WIN32_H_ |
9 #ifdef _WIN32 | 9 #ifdef _WIN32 |
10 #ifndef _WINDOWS_ | 10 #ifndef _WINDOWS_ |
(...skipping 20 matching lines...) Expand all Loading... |
31 static CFX_DIBitmap* LoadFromBuf(BITMAPINFO* pbmi, void* pData); | 31 static CFX_DIBitmap* LoadFromBuf(BITMAPINFO* pbmi, void* pData); |
32 | 32 |
33 static HBITMAP GetDDBitmap(const CFX_DIBitmap* pBitmap, HDC hDC
); | 33 static HBITMAP GetDDBitmap(const CFX_DIBitmap* pBitmap, HDC hDC
); |
34 | 34 |
35 static CFX_DIBitmap* LoadFromDDB(HDC hDC, HBITMAP hBitmap, FX_DWORD* pPalett
e = NULL, FX_DWORD size = 256); | 35 static CFX_DIBitmap* LoadFromDDB(HDC hDC, HBITMAP hBitmap, FX_DWORD* pPalett
e = NULL, FX_DWORD size = 256); |
36 | 36 |
37 static CFX_DIBitmap* LoadFromFile(FX_LPCWSTR filename); | 37 static CFX_DIBitmap* LoadFromFile(FX_LPCWSTR filename); |
38 | 38 |
39 static CFX_DIBitmap* LoadFromFile(FX_LPCSTR filename) | 39 static CFX_DIBitmap* LoadFromFile(FX_LPCSTR filename) |
40 { | 40 { |
41 return LoadFromFile(CFX_WideString::FromLocal(filename)); | 41 return LoadFromFile(CFX_WideString::FromLocal(filename).c_str()); |
42 } | 42 } |
43 | 43 |
44 static CFX_DIBitmap* LoadDIBitmap(WINDIB_Open_Args_ args); | 44 static CFX_DIBitmap* LoadDIBitmap(WINDIB_Open_Args_ args); |
45 | 45 |
46 CFX_WindowsDIB(HDC hDC, int width, int height); | 46 CFX_WindowsDIB(HDC hDC, int width, int height); |
47 | 47 |
48 ~CFX_WindowsDIB(); | 48 ~CFX_WindowsDIB(); |
49 | 49 |
50 HDC GetDC() const | 50 HDC GetDC() const |
51 { | 51 { |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 protected: | 96 protected: |
97 | 97 |
98 HBITMAP m_hBitmap; | 98 HBITMAP m_hBitmap; |
99 | 99 |
100 HBITMAP m_hOldBitmap; | 100 HBITMAP m_hOldBitmap; |
101 | 101 |
102 HDC m_hDC; | 102 HDC m_hDC; |
103 }; | 103 }; |
104 #endif | 104 #endif |
105 #endif | 105 #endif |
OLD | NEW |