blob: 7ee2737944cfc79c769c6da546ac1c653590b170 [file] [log] [blame]
kumarashishg826308d2023-06-23 13:21:22 +00001// Copyright 2014 The PDFium Authors
Philip P. Moltmann4d3acf42017-03-20 11:05:52 -07002// 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 XFA_FWL_CFWL_COMBOLIST_H_
8#define XFA_FWL_CFWL_COMBOLIST_H_
9
Philip P. Moltmann4d3acf42017-03-20 11:05:52 -070010#include "xfa/fwl/cfwl_listbox.h"
11#include "xfa/fwl/cfwl_widget.h"
Philip P. Moltmann4d3acf42017-03-20 11:05:52 -070012
Haibo Huang49cc9302020-04-27 16:14:24 -070013class CFWL_ComboList final : public CFWL_ListBox {
Philip P. Moltmann4d3acf42017-03-20 11:05:52 -070014 public:
kumarashishg826308d2023-06-23 13:21:22 +000015 CONSTRUCT_VIA_MAKE_GARBAGE_COLLECTED;
16 ~CFWL_ComboList() override;
Philip P. Moltmann4d3acf42017-03-20 11:05:52 -070017
18 // CFWL_ListBox.
19 void OnProcessMessage(CFWL_Message* pMessage) override;
20
Haibo Huang49cc9302020-04-27 16:14:24 -070021 int32_t MatchItem(WideStringView wsMatch);
Philip P. Moltmann4d3acf42017-03-20 11:05:52 -070022 void ChangeSelected(int32_t iSel);
Philip P. Moltmann4d3acf42017-03-20 11:05:52 -070023
24 private:
kumarashishg826308d2023-06-23 13:21:22 +000025 CFWL_ComboList(CFWL_App* app,
26 const Properties& properties,
27 CFWL_Widget* pOuter);
28
Philip P. Moltmann33357ca2017-05-11 09:25:13 -070029 CFX_PointF ClientToOuter(const CFX_PointF& point);
Philip P. Moltmann4d3acf42017-03-20 11:05:52 -070030 void OnDropListFocusChanged(CFWL_Message* pMsg, bool bSet);
31 void OnDropListMouseMove(CFWL_MessageMouse* pMsg);
32 void OnDropListLButtonDown(CFWL_MessageMouse* pMsg);
33 void OnDropListLButtonUp(CFWL_MessageMouse* pMsg);
34 bool OnDropListKey(CFWL_MessageKey* pKey);
35 void OnDropListKeyDown(CFWL_MessageKey* pKey);
36
Haibo Huang49cc9302020-04-27 16:14:24 -070037 bool m_bNotifyOwner = true;
Philip P. Moltmann4d3acf42017-03-20 11:05:52 -070038};
39
40#endif // XFA_FWL_CFWL_COMBOLIST_H_