mcu_hi3321_watch/tjd/ui/app/wf_select/TjdUiWatchFaceAdapter.cpp
2025-05-26 20:15:20 +08:00

32 lines
910 B
C++

/*----------------------------------------------------------------------------
* Copyright (c) TJD Technologies Co., Ltd. 2025. All rights reserved.
*
* Description: TjdUiWatchFaceAdapter.cpp
*
* Author: luziquan@ss-tjd.com
*
* Create: 2025-05-17
*--------------------------------------------------------------------------*/
#include "TjdUiWatchFaceAdapter.h"
namespace TJD {
WatchFaceCoverflowItemView::WatchFaceCoverflowItemView()
{
SetTouchable(true);
icon_.SetAutoEnable(false);
icon_.SetResizeMode(OHOS::UIImageView::ImageResizeMode::FILL);
icon_.LayoutCenterOfParent();
Add(&icon_);
}
WatchFaceCoverflowItemView::~WatchFaceCoverflowItemView() { RemoveAll(); }
void WatchFaceCoverflowItemView::Resize(int16_t width, int16_t height)
{
OHOS::UITransformGroup::Resize(width, height);
icon_.Resize(width, height);
icon_.LayoutCenterOfParent();
}
} // namespace TJD