Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ENH: Wrap-around scrolling through DynamicViews #74

Open
ba58smith opened this issue Nov 2, 2021 · 4 comments
Open

ENH: Wrap-around scrolling through DynamicViews #74

ba58smith opened this issue Nov 2, 2021 · 4 comments
Labels
enhancement New feature or request

Comments

@ba58smith
Copy link
Collaborator

After you reach the last DynamicView when swiping, the next swipe would "wrap around" back to the Watch's home screen.

@ba58smith
Copy link
Collaborator Author

I found this in the LVGL forums: https://forum.lvgl.io/t/tab-view-circular-scrolling/2473/11 (If the link doesn't take you to it, look at the post from June 22, by kisvegabor.)
Unfortunately, the Issue that was created to make this a formal part of LVGL was closed due to inactivity. But there are some comments in there that might be helpful: lvgl/lvgl#1604

@JohnySeven
Copy link
Owner

Yesterday I was trying to get this stuff working, but we're running LVGL 7 version and this code is v8 only. So we first need to add support for v8 of LVGL and then we would be able to make this code working.

plan B: Maybe I could use what we already have with following algorithm:

We have 3 views + watch face:
A B C D WF

Startup position - ( ) is fully in user view
A B (WF) C D
When user swipes right it will be detected (easy) and as user is scrolling to right it will move view A after D when user shows C and continues to rearrange the view that way until WF is placed to start.
B WF (C) D A
user continues to swipe right
WF C (D) A B
user continues to swipe right
C D (A) B WF
user continues to swipe right
D A (B) WF C
user swipes to left
C D (A) B WF C

This way we could simulate desired outcome. Will need to test it first if there are no artifacts during scrolling.

@ba58smith
Copy link
Collaborator Author

So all of the views would be represented in some kind of container, and each time a swipe is detected, the views get moved within the container? Looks like it should work. RE: artifacts, you might just need to do some kind of "clear screen" before an after each swipe is completed?

@JohnySeven
Copy link
Owner

We will still use TileView, but we will manage it little more dynamically. But generally yes, we'll follow user and update grid as required.

@ba58smith ba58smith added the enhancement New feature or request label Nov 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants