ivan.cuevas Posted January 7, 2016 Share Posted January 7, 2016 Hi all, I have added a WidgetEditLine in a WidgetMenuBox, it's redered Ok, but the problem is there is no way to set the focus to this widget and make keyboard inputs. It can be reproduced easely by modifying the menubox_02 and the following: MenuBox() { //... menubox.addItem("Third item"); WidgetEditLine edt= new WidgetEditLine(gui, "0"); menubox.setItemWidget(menubox.addItem(NULL),edt); childs.append(edt); menubox.setCallback(GUI_CLICKED,functionid(menubox_clicked_redirector),this,menubox); menubox.setFontRich(1); } Is this the expected behaviour? Should menubox to be configured in another way? Thanks. Link to comment
maxi Posted January 11, 2016 Share Posted January 11, 2016 Hi Iván, I am afraid, this is expected behaviour. WidgetMenuBox grabs back focus from children widgets when rendered. Maybe you need to make your own custom widget, that contains both menubox and editlines in this case. Link to comment
Recommended Posts