John Abd-El-Malek | 3f3b45c | 2014-05-23 17:28:10 -0700 | [diff] [blame] | 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. |
Lei Zhang | a6d9f0e | 2015-06-13 00:48:38 -0700 | [diff] [blame^] | 4 | |
John Abd-El-Malek | 3f3b45c | 2014-05-23 17:28:10 -0700 | [diff] [blame] | 5 | // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
| 6 | |
Tom Sepez | 19922bb | 2015-05-28 13:23:12 -0700 | [diff] [blame] | 7 | #ifndef FPDFSDK_INCLUDE_PDFWINDOW_PWL_SPECIALBUTTON_H_ |
| 8 | #define FPDFSDK_INCLUDE_PDFWINDOW_PWL_SPECIALBUTTON_H_ |
John Abd-El-Malek | 3f3b45c | 2014-05-23 17:28:10 -0700 | [diff] [blame] | 9 | |
Tom Sepez | 870292c | 2015-04-07 16:12:46 -0700 | [diff] [blame] | 10 | #include "PWL_Button.h" |
John Abd-El-Malek | 3f3b45c | 2014-05-23 17:28:10 -0700 | [diff] [blame] | 11 | |
Tom Sepez | 870292c | 2015-04-07 16:12:46 -0700 | [diff] [blame] | 12 | class PWL_CLASS CPWL_PushButton : public CPWL_Button |
John Abd-El-Malek | 3f3b45c | 2014-05-23 17:28:10 -0700 | [diff] [blame] | 13 | { |
| 14 | public: |
| 15 | CPWL_PushButton(); |
| 16 | virtual ~CPWL_PushButton(); |
| 17 | |
John Abd-El-Malek | 3f3b45c | 2014-05-23 17:28:10 -0700 | [diff] [blame] | 18 | virtual CFX_ByteString GetClassName() const; |
| 19 | virtual CPDF_Rect GetFocusRect() const; |
| 20 | }; |
| 21 | |
| 22 | class PWL_CLASS CPWL_CheckBox : public CPWL_Button |
| 23 | { |
| 24 | public: |
| 25 | CPWL_CheckBox(); |
| 26 | virtual ~CPWL_CheckBox(); |
| 27 | |
John Abd-El-Malek | 3f3b45c | 2014-05-23 17:28:10 -0700 | [diff] [blame] | 28 | virtual CFX_ByteString GetClassName() const; |
Nico Weber | f1d18bb | 2014-07-30 14:17:19 -0700 | [diff] [blame] | 29 | virtual FX_BOOL OnLButtonUp(const CPDF_Point & point, FX_DWORD nFlag); |
| 30 | virtual FX_BOOL OnChar(FX_WORD nChar, FX_DWORD nFlag); |
John Abd-El-Malek | 3f3b45c | 2014-05-23 17:28:10 -0700 | [diff] [blame] | 31 | |
| 32 | void SetCheck(FX_BOOL bCheck); |
| 33 | FX_BOOL IsChecked() const; |
| 34 | |
| 35 | private: |
| 36 | FX_BOOL m_bChecked; |
| 37 | }; |
| 38 | |
| 39 | class PWL_CLASS CPWL_RadioButton : public CPWL_Button |
| 40 | { |
| 41 | public: |
| 42 | CPWL_RadioButton(); |
| 43 | virtual ~CPWL_RadioButton(); |
| 44 | |
John Abd-El-Malek | 3f3b45c | 2014-05-23 17:28:10 -0700 | [diff] [blame] | 45 | virtual CFX_ByteString GetClassName() const; |
Nico Weber | f1d18bb | 2014-07-30 14:17:19 -0700 | [diff] [blame] | 46 | virtual FX_BOOL OnLButtonUp(const CPDF_Point & point, FX_DWORD nFlag); |
| 47 | virtual FX_BOOL OnChar(FX_WORD nChar, FX_DWORD nFlag); |
John Abd-El-Malek | 3f3b45c | 2014-05-23 17:28:10 -0700 | [diff] [blame] | 48 | |
| 49 | void SetCheck(FX_BOOL bCheck); |
| 50 | FX_BOOL IsChecked() const; |
| 51 | |
| 52 | private: |
| 53 | FX_BOOL m_bChecked; |
| 54 | }; |
| 55 | |
Tom Sepez | 19922bb | 2015-05-28 13:23:12 -0700 | [diff] [blame] | 56 | #endif // FPDFSDK_INCLUDE_PDFWINDOW_PWL_SPECIALBUTTON_H_ |