78 lines
2.1 KiB
C++
78 lines
2.1 KiB
C++
/*----------------------------------------------------------------------------
|
|
* Copyright (c) TJD Technologies Co., Ltd. 2025. All rights reserved.
|
|
*
|
|
* Description: TjdUiTjdUiAppListView.h
|
|
*
|
|
* Author: luziquan@ss-tjd.com
|
|
*
|
|
* Create: 2025-02-11
|
|
*--------------------------------------------------------------------------*/
|
|
|
|
#ifndef TJD_UI_APP_LIST_VIEW_H
|
|
#define TJD_UI_APP_LIST_VIEW_H
|
|
|
|
#include "TjdUiAppListAdapter.h"
|
|
#include "TjdUiAppListPresenter.h"
|
|
#include "View.h"
|
|
#include "components/tjd_ui_grid_list.h"
|
|
#include "components/ui_custom_hexagons_list.h"
|
|
#include "components/ui_list.h"
|
|
#include "components/ui_sphere_view.h"
|
|
#include "components/ui_waterfall_list.h"
|
|
|
|
namespace TJD {
|
|
|
|
class TjdUiAppListView : public OHOS::View<TjdUiAppListPresenter>
|
|
{
|
|
public:
|
|
TjdUiAppListView();
|
|
~TjdUiAppListView() override;
|
|
|
|
void OnStart() override;
|
|
void OnStop() override;
|
|
void RefreshAppView(void);
|
|
void AddAppItemToList(const TjdAppItem &item);
|
|
void ClearAppItemToList();
|
|
void RefreshAppList(void);
|
|
void ResumeWaterFallDraggable();
|
|
void ResumeFocus();
|
|
|
|
private:
|
|
/* for list style */
|
|
class MenuList;
|
|
void ListStyleOnStart();
|
|
void ListStyleOnStop();
|
|
ApplistAdapter *listAdapter_{nullptr};
|
|
MenuList *contentList_{nullptr};
|
|
|
|
/* for hexagons style */
|
|
void HexagonsStyleOnStart();
|
|
void HexagonsStyleOnStop();
|
|
OHOS::UICustomHexagonsList *hexagonsList_{nullptr};
|
|
OHOS::List<HexagonsItemView *> listHexagonsView_;
|
|
uint16_t imgSize_ = 0;
|
|
uint16_t imgDistance_ = 0;
|
|
|
|
/* for waterfall style */
|
|
void WaterfallStyleOnStart();
|
|
void WaterfallStyleOnStop();
|
|
OHOS::UIWaterfallList *waterfallList_{nullptr};
|
|
OHOS::List<WaterfallItemView *> waterfallItemList_;
|
|
|
|
/* for sphere style */
|
|
void SphereStyleOnStart();
|
|
void SphereStyleOnStop();
|
|
OHOS::UISphereView *sphereList_{nullptr};
|
|
OHOS::List<SphereItemView *> sphereItemList_;
|
|
|
|
/* for grid style */
|
|
void GridStyleOnStart();
|
|
void GridStyleOnStop();
|
|
TjdUIGridList *gridList_{nullptr};
|
|
OHOS::List<GridItemView *> gridItemList_;
|
|
};
|
|
|
|
} // namespace TJD
|
|
|
|
#endif
|