/* * Copyright (c) CompanyNameMagicTag 2021-2021. All rights reserved. * Description: BluetoothPresenter view * Create: 2021-10-13 */ #ifndef BLUETOOTH_PRESENTER_H #define BLUETOOTH_PRESENTER_H #include "Presenter.h" #include "BluetoothModel.h" #include "MainBluetoothView.h" #include "components/ui_view.h" #include "components/ui_image_view.h" #include "components/ui_label_button.h" #include "components/ui_view_group.h" #include "VolumeSettingView.h" #include "UiViewId.h" namespace OHOS { enum BluetoothPresenterNum : uint8_t { BLUETOOTHEARPHONEVIEW = 0, BLUETOOTHEARLISTVIEW, BLUETOOTHDEVICELISTVIEW, BLUETOOTHEOPTIONSVIEW, BLUETOOTHRECONNECTVIEW, TIPSSUCCMESSAGEVIEW, TIPSCONNFAILMESSAGEVIEW, TIPSFAILMESSAGEVIEW, BLUETOOTHEVIEW, BLUETOOTHEVIEW_MAX, }; class MainBluetoothView; class BluetoothPresenter : public Presenter, public UIView::OnClickListener, public UIView::OnDragListener { public: BluetoothPresenter(); ~BluetoothPresenter(); bool OnClick(UIView &view, const ClickEvent &event) override; static BluetoothPresenter *GetInstance(); bool OnDragEnd(UIView& view, const DragEvent& event) override; void OnStop() override; void ClickRescanButton(void); void ClickNewEquipmentButton(void); void ClickCancelConnedRequestButton(void); void ClickUnpairButton(void); void ClickOptionsOneButton(void); void ClickSuccBackButton(void); void ClickFailBackButton(void); void ClickConnfailBackButton(void); private: BluetoothModel *bluetoothMode_{nullptr}; }; } // namespace OHOS #endif