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

Add menu wrap around #145

Merged
merged 2 commits into from
Feb 27, 2021
Merged

Add menu wrap around #145

merged 2 commits into from
Feb 27, 2021

Conversation

AliceGrey
Copy link
Member

Menu's now wrap around in both directions!
Makes navigating long menu's easier!
Helps when one of your buttons is broken!

@@ -102,13 +102,28 @@ static bool has_next_index(const MenuLayer *menu_layer, const MenuIndex *index,
|| (!up && (index->section < menu_layer->end_index.section || index->row < menu_layer->end_index.row - 1));
}

static MenuIndex get_next_index(MenuLayer *menu_layer, bool up)
static MenuIndex get_next_index(MenuLayer *menu_layer, ClickRecognizerRef ref, bool up)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Architectural nit: I would probably make this a bool do_wrap that gets passed through to this layer (similar to the bool up), rather than passing the ClickRecognizerRef through.

@jwise jwise merged commit 5465477 into pebble-dev:master Feb 27, 2021
tertty pushed a commit to tertty/RebbleOS that referenced this pull request Mar 4, 2021
* Add menu wrap around

Menu's now wrap around in both directions

* Don't infinite scroll if button is being held
tertty pushed a commit to tertty/RebbleOS that referenced this pull request Mar 4, 2021
Add menu wrap around (pebble-dev#145)

* Add menu wrap around

Menu's now wrap around in both directions

* Don't infinite scroll if button is being held

Set alignment to MenuRowAlignCenter on submenu return (pebble-dev#138)

* Set alignment to MenuRowAlignCenter on submenu return

* Handle setting non-animated content offsets

Get RebbleOS compiling on Python 3.9 & Arch (pebble-dev#137)

* Get RebbleOS compiling on Python 3.9 & Arch

* stm32_crc: add backwards compatibility, sigh

add switch for python backwards compatibility

Add dvb2  (pebble-dev#140)

* asterix_vla_dvb2

Initial build config. A lot is probably wrong but it's a start :)

* Update UART pin

* asterix_vla_dvb2: fix up pinmappings and flash ID number

* Add SPI locking mechanism for boards that share SPI interface.  Switch vla_dvb2 to ls013b7dh05.

* Swap button GPIO pins

Correct GPIO pins

* Fix asterix build

* Remove nrf52_ls013b7dh03 as it's not needed

* Add dvb2 to CI

* Fix dvb2 make

Don't edit make files at 1AM

Co-authored-by: Joshua Wise <joshua@joshuawise.com>

Notifications - Add "Clear All" option (pebble-dev#148)

* Add Clear All to notification app

* Use consistent UI styling on notification app

Stage changes for the macro PR
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants