Author: manolo
Date: 2011-03-25 05:16:57 -0700 (Fri, 25 Mar 2011)
New Revision: 8532
Log:
Fl::focus(): allows the focus to be set to an Fl_Window widget.
Modified:
branches/branch-1.3/src/Fl.cxx
Modified: branches/branch-1.3/src/Fl.cxx
===================================================================
--- branches/branch-1.3/src/Fl.cxx 2011-03-25 12:02:31 UTC (rev 8531)
+++ branches/branch-1.3/src/Fl.cxx 2011-03-25 12:16:57 UTC (rev 8532)
@@ -813,7 +813,8 @@
// make sure that fl_xfocus is set to the top level window
// of this widget, or fl_fix_focus will clear our focus again
if (o) {
- Fl_Window *win = 0, *w1 = o->window();
+ Fl_Window *win = 0, *w1 = o->as_window();
+ if (!w1) w1 = o->window();
while (w1) { win=w1; w1=win->window(); }
if (win) fl_xfocus = win;
}
_______________________________________________
fltk-commit mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-commit