mirror of
https://codeberg.org/adnano/wmenu.git
synced 2025-11-02 09:01:43 -05:00
Don't set selection if there are no pages
This commit is contained in:
parent
7284f5958b
commit
da25fbfb27
1 changed files with 3 additions and 1 deletions
4
main.c
4
main.c
|
|
@ -236,7 +236,9 @@ static void match_items(struct menu *menu) {
|
||||||
}
|
}
|
||||||
|
|
||||||
page_items(menu);
|
page_items(menu);
|
||||||
menu->sel = menu->pages->first;
|
if (menu->pages) {
|
||||||
|
menu->sel = menu->pages->first;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void insert(struct menu *menu, const char *s, ssize_t n) {
|
static void insert(struct menu *menu, const char *s, ssize_t n) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue