Andrew Borodin
b9cf2898c4
Ticket #4057 : blank screen with invisible error.
...
How to reproduce:
Run `mcedit .` from an empty shell. mc used to show an error banner. Now
it shows black-on-black error message.
do_refresh() function expects that at least one fullscreen dialog (file
manager, editor, etc) is existing in the dialog stack. If query dialog
is created before any fullscreen one, do_refresh() do nothing.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-05-11 10:43:05 +03:00
Andrew Borodin
bcdd81c628
WGroup: support colors.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:17:32 +03:00
Andrew Borodin
d38eb77c8c
WGroup: support state.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:17:32 +03:00
Andrew Borodin
f0e13d8fba
Make WST_CONSTRUCT a default widget state.
2020-03-08 20:17:32 +03:00
Andrew Borodin
f39f05632a
WGroup: support key events.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:17:32 +03:00
Andrew Borodin
2e734e5618
Make keybind map a member of Widget.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:17:32 +03:00
Andrew Borodin
326c4ce1d9
(dlg_key_event): clarify post-hotkey handling.
...
Current widget is the sender of MSG_UNHANDLED_KEY message.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:17:32 +03:00
Andrew Borodin
c2aadb2ad5
WGroup: support mouse events.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:17:32 +03:00
Andrew Borodin
4b3b49faad
(widget_draw): support groups.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:17:32 +03:00
Andrew Borodin
d1f9e698ac
WDialog: use WBackground in frameless dialogs (screens).
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:17:32 +03:00
Andrew Borodin
ed9199e94e
Create WFrame widget.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:17:02 +03:00
Andrew Borodin
c77dc88ff9
WGroup: support draw.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:15:37 +03:00
Andrew Borodin
2a265e38a0
WDialog set/change size API: move to WGroup.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:15:37 +03:00
Andrew Borodin
04f04ba130
Send new widget size as parameter of MSG_RESIZE message.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:15:37 +03:00
Andrew Borodin
045816ed13
(dlg_set_position): use WRect.
...
(widget_set_size_rect): new API.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:15:37 +03:00
Andrew Borodin
6acd8475dd
Update cursor API: support groups.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:13:35 +03:00
Andrew Borodin
e9d23e90f0
Find widget API: support groups.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:13:33 +03:00
Andrew Borodin
fdf3d9c3b7
WGroup: implement init & destroy.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:12:45 +03:00
Andrew Borodin
b9cf650605
Move send broadcast message API from WDialog to WGroup.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:11:55 +03:00
Andrew Borodin
22ad70ed02
Move widget add/del API from WDialog to WGroup.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:11:55 +03:00
Andrew Borodin
6eedbce076
Move widget selection API from WDialog to WGroup.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:11:39 +03:00
Andrew Borodin
d575c7058b
Move winch_pending member from WDialog to WGroup.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:09:13 +03:00
Andrew Borodin
e4e0070db5
Ticket #2919 : implement WGroup widget.
...
WGroup is the base widget for complex objects such as windows, dialog
windows, etc.
Initial steps:
* move widget list of dialog into WGroup class;
* inherit WGroup from Widget;
* inherit WDialog from WGroup.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-03-08 20:09:12 +03:00
Andrew Borodin
31b37a1f79
Ticket #4050 : code cleanup before 4.8.25 release.
...
Update copyright years.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2020-02-29 19:10:17 +03:00
Andrew Borodin
65e12d1a9f
(dlg_redraw): rename to dlg_draw.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-12-15 12:53:20 +03:00
Andrew Borodin
35f14be028
(widget_move): rename to widget_gotoyx.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-12-15 12:53:20 +03:00
Andrew Borodin
baca4ba045
Widget and WDialog API changes:
...
* (widget_destroy): new API to destroy widget.
* (del_widget): don't destroy widget after remove it from dialog.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-12-15 12:53:20 +03:00
Andrew Borodin
297391fd60
(dlg_adjust_position): rename to widget_adjust_position and make public.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-09-01 19:41:12 +03:00
Andrew Borodin
29110e5681
Move history operation routines from lib/widget/history.c to lib/mcconfig/history.c.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-09-01 19:41:12 +03:00
Andrew Borodin
37ffc02422
Ticket #117 : refactoring of SIGWINCH hangling.
...
Use pipe to collect consecutive raised SIGWINCH events.
Then handle multiple events at a time treating them
as a single one.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-09-01 19:22:21 +03:00
Andrew Borodin
3b997974ec
Refactor dialog command execution.
2019-04-27 19:29:24 +03:00
Andrew Borodin
433ae45bdd
Clarify checks of dialog and widget existence.
...
Widget list in the dialog cannot contain empty elements.
Dialog list cannot contain empty elements too.
Therefore simplify some checks.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-02-03 13:10:00 +03:00
Andrew Borodin
1dd8a47987
Ticket #3955 : code cleanup before 4.8.23 release.
...
Update copyright years.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-02-03 12:44:40 +03:00
Andrew Borodin
669a8e3e17
(dlg_run_done): fix possible NULL dereference.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2018-09-09 19:10:43 +03:00
Andrew Borodin
b9194d8c8a
(dlg_init): fix possible NULL dereference.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2018-09-09 19:10:43 +03:00
Andrew Borodin
a38c7f19e9
Ticket #3453 : Find file: show pattern and content in the results dialog title.
...
Initial step:
* (dlg_set_title): new API.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2018-09-04 10:26:35 +03:00
Andrew Borodin
ddd645526a
Update copyright years.
2018-02-04 11:30:22 +03:00
Andrew Borodin
e83409b6d7
Ticket #3766 : add_widget_autopos() doesn't remove focus from the previously focused widget.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-02-09 17:49:34 +02:00
Andrew Borodin
e9fd11bfcd
Update copyright years.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-22 19:12:55 +03:00
Andrew Borodin
8b14798cc4
setup: split integer and boolean options.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-22 18:44:22 +03:00
Andrew Borodin
36cc88b5f2
Reimplement widget focus/selection.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-09-11 11:30:20 +03:00
Andrew Borodin
599361b3fc
(dlg_set_bottom_widget): rename to widget_set_bottom.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-09-11 11:30:20 +03:00
Andrew Borodin
d200893347
(dlg_select_widget): rename to widget_select.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-09-11 11:30:20 +03:00
Andrew Borodin
35451978f6
Rename WDialog APIs:
...
dlg_one_up -> dlg_select_prev_widget
dlg_one_down -> dlg_select_next_widget
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-09-11 11:30:20 +03:00
Andrew Borodin
b19ae2b938
Refactoring of change of current widget.
...
Add new WDialog APIs:
* dlg_set_current_widget_next
* dlg_set_current_widget_prev
* dlg_get_widget_next_of
* dlg_get_widget_prev_of
and use them:
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-09-11 11:30:20 +03:00
Andrew Borodin
240350db95
Refactoring of widget drawing to avoid multiple widget redraw.
...
Send MSG_DRAW message immediately after MSG_FOCUS/MSG_UNFOCUS.
Thus, the MSG_DRAW message handler is the only place where widget
should be drawn. Widget should not draw itself in other message
handlers.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-09-11 11:30:20 +03:00
Andrew Borodin
c37f9b770a
WST_FOCUSED: add new state and handle it.
...
Notify widget's owner that widget gets or loses focus.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-09-11 11:26:00 +03:00
Andrew Borodin
c90b806728
Don't focus widget that doesn't have the WOP_SELECTABLE option.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-09-11 11:26:00 +03:00
Andrew Borodin
5ac1c5a3e0
Ticket #2919 : refactoring of focus/unfocus of widgets.
...
Initial step: add WOP_SELECTABLE option and set it up explicitly for
widgets that can be selected.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-09-11 11:26:00 +03:00
Andrew Borodin
adc6bd83d6
(dlg_adjust_position): refactoring.
2016-09-11 11:11:01 +03:00