mirror of
https://github.com/fltk/fltk.git
synced 2026-06-05 08:06:35 +08:00
Changing the shorcut of a widget in fluid now marks the document as dirty (STR #1382)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@5328 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
CHANGES IN FLTK 1.1.8
|
||||
|
||||
- Changing the shorcut of a widget in fluid now marks
|
||||
the document as dirty (STR #1382)
|
||||
- Fl_Text_Editor now correctly handles middle mouse
|
||||
clicks (STR #1384)
|
||||
- Added some GLUT4 functions (STR #1370)
|
||||
|
||||
@@ -583,12 +583,15 @@ void shortcut_in_cb(Shortcut_Button* i, void* v) {
|
||||
i->svalue = ((Fl_Button*)(current_widget->o))->shortcut();
|
||||
i->redraw();
|
||||
} else {
|
||||
int mod = 0;
|
||||
for (Fl_Type *o = Fl_Type::first; o; o = o->next)
|
||||
if (o->selected && o->is_button()) {
|
||||
Fl_Button* b = (Fl_Button*)(((Fl_Widget_Type*)o)->o);
|
||||
if (b->shortcut()!=i->svalue) mod = 1;
|
||||
b->shortcut(i->svalue);
|
||||
if (o->is_menu_item()) ((Fl_Widget_Type*)o)->redraw();
|
||||
}
|
||||
if (mod) set_modflag(1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user