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
432af88b06
(hotkey_draw): minor optimization.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-12-15 13:02:31 +03:00
Andrew Borodin
53314c58b5
(hotkey_get_text): new hotkey API.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-12-15 13:02:31 +03:00
Andrew Borodin
851d2022a9
(hotkey_equal): new hotkey API.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-12-15 13:02:31 +03:00
Andrew Borodin
32a4b1ac85
Rename hotkey API:
...
* parse_hotkey to hotkey_new;
* release_hotkey to hotkey_free.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2019-12-15 13:02:31 +03:00
Andrew Borodin
60fe701b76
(widget_redraw): rename to widget_draw.
...
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
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
ddd645526a
Update copyright years.
2018-02-04 11:30:22 +03:00
Mooffie
ac23a4807c
Pressing <right> and <left> in hotlist dialog doesn't refresh it.
...
Signed-off-by: Mooffie <mooffie@gmail.com>
2017-02-26 12:38:39 +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
8550044635
Ticket #3731 : add new MSG_CHANGED_FOCUS message.
...
This message is sent to widgets'owner when widget's focus state is
changed.
Find file dialog: fix initial draw of ignore directories input line.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-10 18:31:03 +03:00
Andrew Borodin
716479ba4f
Ticket #3700 : fix segfault after switch left panel to info mode.
...
(widget_replace): if new widget cannot take focus, move focus to other widget
before widget replacement.
In our case, the focused file panel is replaced by Info one. Info panel
a) isn't selectable (it never takes focus) and b) uses CWD of current
panel. Therefore focus must be moved to other file panel to make it
current and correctly set up it's CWD before first draw of Info panel.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-10-23 08:08:15 +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
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
91c72122a8
(widget_set_size): send MSG_DRAW after MSG_RESIZE.
...
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
41144d619c
(widget_set_state): return cb_ret_t instead of gboolean.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-09-11 11:26:00 +03:00
Andrew Borodin
d44220c75f
If widget wants cursor, define that explicitly.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-06-02 20:34:38 +03:00
Andrew Borodin
4b72fb5f5e
Join widget_state_t and dlg_state_t.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-06-02 20:34:38 +03:00
Andrew Borodin
b337287336
Move WOP_DISABLED option to widget_state_t flags
...
...and rename to WST_DISABLED.
* Widget::state: new field.
* (widget_set_state): new function.
* (widget_set_options): symplify.
* (input_set_options): remove.
* MSG_ENABLE, MSG_DISABLE: new messages.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-06-02 20:34:38 +03:00
Andrew Borodin
f5a1dfcef4
(widget_get_options): new widget API.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-06-02 20:34:38 +03:00
Andrew Borodin
4a0cd948df
Change prefix of widget options: W_ -> WOP_.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-06-02 20:34:38 +03:00
Andrew Borodin
619480c68b
Ticket #3632 : refactoring of widget flags.
...
Initial commit: rename functions:
* widget_default_set_options_callback -> widget_default_set_options
* input_set_options_callback -> input_set_options
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-06-02 20:34:38 +03:00
Andreas Mohr
5a7d7d0087
(mouse_get_local): cleanup uninitialized warning.
...
Cleanup uninitialized warning with gcc compiler (gcc-4.4.7-4.el6).
Signed-off-by: Andreas Mohr <and@gmx.li>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-05-07 16:19:02 +03:00
Andreas Mohr
16f229114a
Ticket #3598 : cleanup some -Wcast-qual compiler warnings.
...
Introduce CONST_WIDGET helper and use it.
Signed-off-by: Andreas Mohr <and@gmx.li>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-04-16 10:23:43 +03:00
Mooffie
438e841226
Rename mouse.was_drag to mouse.last_msg.
...
Get rid of the 'click' variable.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-04-01 15:29:55 +03:00
Andrew Borodin
8490ca7be4
Drop old mouse API and use the new one.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-04-01 15:29:55 +03:00
Mooffie
03daa62e19
Ticket #3571 : high-level mouse API.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-04-01 14:16:08 +03:00
Andrew Borodin
471ea781ca
Update copyright years.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-01-01 11:48:10 +03:00
Andrew Borodin
454479549c
Update copyright years.
2015-02-26 09:12:08 +03:00
Andrew Borodin
e786d8266e
(mouse_get_local): set Gpm_Event::modifiers only if libgpm is used.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2014-07-22 13:35:51 +04:00
Andrew Borodin
76d61edc1e
(mouse_get_local): initialize local.modifiers.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2014-07-22 13:10:40 +04:00
Andrew Borodin
e5203cb023
Fix name of FSF in all *.c files.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2014-02-28 13:33:17 +04:00
Andrew Borodin
f0da49345a
Collapse list of copyright years to ranges. Add 2014 year.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2014-02-10 16:27:03 +04:00
Andrew Borodin
200cb115ab
(widget_init): init pos_flags member to WPOS_KEEP_DEFAULT.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2013-10-04 09:14:07 +04:00
Andrew Borodin
48abe8735f
Rename functions:
...
init_widget -> widget_init
create_dlg -> dlg_create
init_dlg -> dlg_init
run_dlg -> dlg_run
destroy_dlg -> dlg_destroy
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2013-06-28 09:21:17 +04:00
Andrew Borodin
0adf569b54
(dlg_overlap): rename to widget_overlapped()
...
...and move to lib/widget/widget-common.c.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2013-06-28 09:21:17 +04:00
Andrew Borodin
c7da120588
(dlg_replace_widget): rename to widget_replace()
...
...and move to lib/widget/widget-common.c.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2013-06-28 09:21:17 +04:00
Andrew Borodin
1672fa44dd
(dlg_widget_active): rename to widget_is_active()
...
...and move to lib/widget/widget-common.c.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2013-06-28 09:21:17 +04:00
Andrew Borodin
30959e0b7d
Clarify widget redraw in runtime.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2013-03-09 16:04:19 +04:00
Andrew Borodin
281209c79d
lib/widget/*.[ch]: fix indentation.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-20 13:27:10 +04:00
Andrew Borodin
665d238ffa
Unify widget and dialog message handling.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:44:14 +04:00
Andrew Borodin
843dcd104e
Rename Dlg_head to WDialog.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:42:47 +04:00
Andrew Borodin
0078874613
Rename default callbacks of widget and dialog.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:42:47 +04:00
Andrew Borodin
1206d156bf
(widget_set_options): new function to set/reset widget options.
...
Adjust enable/disable widgets.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:42:45 +04:00
Andrew Borodin
c6ddd28366
Unification of widget and dialog callback functions.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:42:44 +04:00