|
|
commit cd26829099683fda116c3e1b02d9d30b713b6296
Author: Greg Ercolano <erco@seriss.com>
AuthorDate: Mon Aug 10 09:32:06 2020 -0700
Commit: Greg Ercolano <erco@seriss.com>
CommitDate: Mon Aug 10 09:32:06 2020 -0700
Fix missing Alt-N shortcut for newly created favorites
Fl_File_Chooser's "Add Favorite" function wasn't including the
Alt-N shortcut when initially added. Now just calls update_favorites()
to rebuild the menu with proper shortcut numbering.
src/Fl_File_Chooser2.cxx | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git src/Fl_File_Chooser2.cxx src/Fl_File_Chooser2.cxx
index 39010eb..c22860c 100644
--- src/Fl_File_Chooser2.cxx
+++ src/Fl_File_Chooser2.cxx
@@ -515,8 +515,7 @@ Fl_File_Chooser::favoritesButtonCB()
prefs_->set(menuname, directory_);
prefs_->flush();
- quote_pathname(menuname, directory_, sizeof(menuname));
- favoritesButton->add(menuname);
+ update_favorites(); // adds item to favorites with Alt-n shortcut
if (favoritesButton->size() > 104) {
((Fl_Menu_Item *)favoritesButton->menu())[0].deactivate();
[ Direct Link to Message ] | |
|
| |