2 * @Author: Caisking 3449750381@qq.com
3 * @Date: 2024-03-19 17:37:18
4 * @LastEditors: Caisking 3449750381@qq.com
5 * @LastEditTime: 2024-03-29 19:23:56
6 * @FilePath: /sdk/application/wearable/fd230app/nativeui/traing/training_list_limit/include/TraingOtherPresenter.h
7 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
10 #ifndef _TraingOther_PRESENTER_H
11 #define _TraingOther_PRESENTER_H
13 #include "key/include/KeyInputListener.h"
14 #include "Presenter.h"
15 #include "TraingOtherView.h"
19 class TraingOtherView;
20 class TraingOtherModel;
21 class TraingOtherPresenter : public Presenter<TraingOtherView>,
22 public UIView::OnClickListener,
23 public RootView::OnKeyActListener,
24 public UIView::OnDragListener
27 TraingOtherPresenter();
28 virtual ~TraingOtherPresenter();
30 void OnStart() override;
31 void OnStop() override;
33 static TraingOtherPresenter *GetInstance();
36 // 因为继承了OnClickener,所以有OnClick属性,至于参数,原函数也这样直接继承;
37 bool OnClick(UIView &view, const ClickEvent &event) override;
38 bool OnDrag(UIView &view, const DragEvent &event) override;
39 bool OnDragEnd(UIView &view, const DragEvent &event) override;
40 bool OnKeyAct(UIView &view, const KeyEvent &event) override; // 增加按键事件
42 TraingOtherModel *p_TraingOtherModel{nullptr};
46 #endif // SLEEPDETAIL_PRESENTER_H