I would like to ask you that if we can swipe up in the app. #133
-
I am trying on a project . The idea is that if we swipe down we could put something like text. For example if we swipe down at home screen it opens up the control center. But in app I wanted to put the text as we launch the control centre. So can you help me . The code is not working for me const isVertical = true
hmUI.setScrollView(true, -334, 1, isVertical);
hmUI.createWidget(hmUI.widget.FILL_RECT, {
x: 20,
y: -334,
w: 100,
h: 200,
radius: 20,
color: 0xFFAF60
}) Please tell me my errors or what should I do it to make the code work |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
You can use |
Beta Was this translation helpful? Give feedback.
hmUI.setScrollView
cannot be set to a negative value. This API only changes the up and down scrolling behavior of the page without affecting the drawing and layout of the control.You can use
hmUI.scrollToPage
when entering the page to directly turn to the second page, so that when entering the page, slide down to display the first page view. To simulate a similar effect.