'How to click OK when pressing the Return key in Xdialog?
This is part of the source code in the file callbacks.c it handles the return only if the focus is outside the inputbox, how can I modify it to handle return when pressed inside the inputbox?
Xdialog --inputbox Test 10 50
if (event->type == GDK_KEY_PRESS && (event->keyval == GDK_Return ||
event->keyval == GDK_KP_Enter)) {
if (Xdialog.default_no)
Xdialog.exit_code = 1;
else
Xdialog.exit_code = 0;
return(FALSE);
}
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|

