xref: /aosp_15_r20/external/pdfium/fpdfsdk/pwl/cpwl_button.h (revision 3ac0a46f773bac49fa9476ec2b1cf3f8da5ec3a4)
1 // Copyright 2014 The PDFium Authors
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 FPDFSDK_PWL_CPWL_BUTTON_H_
8 #define FPDFSDK_PWL_CPWL_BUTTON_H_
9 
10 #include <memory>
11 
12 #include "fpdfsdk/pwl/cpwl_wnd.h"
13 #include "fpdfsdk/pwl/ipwl_fillernotify.h"
14 
15 class CPWL_Button : public CPWL_Wnd {
16  public:
17   CPWL_Button(const CreateParams& cp,
18               std::unique_ptr<IPWL_FillerNotify::PerWindowData> pAttachedData);
19   ~CPWL_Button() override;
20 
21   // CPWL_Wnd
22   bool OnLButtonDown(Mask<FWL_EVENTFLAG> nFlag,
23                      const CFX_PointF& point) override;
24   bool OnLButtonUp(Mask<FWL_EVENTFLAG> nFlag, const CFX_PointF& point) override;
25 
26  protected:
27   bool m_bMouseDown = false;
28 };
29 
30 #endif  // FPDFSDK_PWL_CPWL_BUTTON_H_
31