Andrew Borodin
e7ac83b48a
Modified the hintbar draw update.
...
Since midnight_dlg can be invisible during screen resize,
don't update the hintbar in SIGWING signal handling function.
Now the hintbar is updated during DLG_DRAW message handling
in mignight_dlg callback.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
5feea4aead
Fixed dialog colors definition, setup and handling.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
791404055b
Revert "src/help.c: minor refactoring."
...
This reverts commit f070d94275c0e41bed4878caf60f8254473f3486.
Help is displayed incorrectly.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
d7d3267594
TTY: removed slang1 related code.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
e6e97f8cd9
src/help.c: minor refactoring.
...
Used TTY wrapper. Type accuracy.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
0c278498d5
src/main.c: minor refactoring
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
d1122efe92
TTY: moved SIGWINCH setup function to TTY layer.
...
Also renamed SIGWINCH signal handler.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
16ceccc6df
Panel: fixed width of second column in brief listing mode.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
cf2ecb4491
Moved do_possible_cd() function from main.c to execute.c.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
d21c8dc448
Screen: moved maybe_cd() function from main.c to screen.c.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
2c4beaafba
Fix after rebase.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
05b89b3bab
VFS: removed unnedeed includes of tty/tty.h header.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
5cd4a8ad83
Moved panel update functions from main.c to screen.c.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
c43bb6f576
TTY: moved alternate_plus_minus variable to TTY layer.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
d6dc828c0c
WListbox: some draw modifications.
...
Draw scrollbar if widget vertical size is less than item count.
Add leading space.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
1b343c7609
WListbox: removed widget sizes duplication.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Andrew Borodin
32a52f9fb5
Listbox window: without button, listbox only.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
ac37863688
Listbox window: apply main menu colors to the user menu.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
e7b35b6ef0
Dialog: create own copy of colors.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
a55cf8ae53
TTY: minor optimization of button bar draw.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
bd0d344802
TTY: moved repaint_screen() from src/main.[ch] to src/layout.[ch].
...
Fixed includes.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
509f4d5c4f
TTY: fixes after rebase.
...
Code clean up.
Modification of tty_refresh for NCurses: call doupdate() after refresh()
every time.
tty_draw_box_slow() is not private function of TTY now.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
7eb4f84dbd
TTY: reorganization of mouse handling.
...
Also small optimization.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
ef282af7ae
TTY: draw box for slow terminal was moved to TTY layer.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
05f3ee1f6c
TTY: modifed initialization.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
a691a99278
Fix after rebasing.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
3c902477cb
TTY: use direct cast instead of str_unconst() funcion.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
508c20c92d
TTY: modified color initialization.
...
Set color mode via tty_init_colors() function.
Made disable_colors and force_colors variables static in main.h.
Removed tty_disable_colors() function.
Some code optimization.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
aadc438c20
TTY: code reorganization.
...
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Andrew Borodin
6b07af2fc4
Some modification of initialization.
...
home_dir variable intialization is moved from main() to OS_setup().
Fixed memory leak ('shell' variable).
2009-08-12 21:23:54 +04:00
Andrew Borodin
7de080e123
Fixes after rebase to master.
2009-08-12 21:23:54 +04:00
Andrew Borodin
46559fd764
TTY: renamed functions.
...
getch have been renamed to tty_lowlevel_getch.
mi_getch have been renamed to tty_getch.
get_event have been renamed to tty_get_event.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:54 +04:00
Slava Zanko
7b74e49bd2
Added Copyringt information. Corrected 'Written by' field.
...
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-08-12 21:23:13 +04:00
Slava Zanko
ce54d07561
Fix include paths in some source files
...
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-08-12 21:23:13 +04:00
Andrew Borodin
0827144b5f
TTY: renamed functions.
...
init_curses have been renamed to tty_init_curses.
init_lang have been renamed to tty_init_slang.
2009-08-12 21:23:13 +04:00
Andrew Borodin
5ac4a4ec1a
TTY: new function: tty_display_8bit().
...
tty_display_8bit() is used instead of NCurses meta() and
S-Lang SLsmg_Display_Eight_Bit.
2009-08-12 21:23:13 +04:00
Andrew Borodin
4e40f6e98f
Screen repainting modifications.
...
src/main.c (repaint_screen): call tty_touch_screen() here.
src/execute.c (toggle_panels): fixed comment.
Call repaint_screen() instead of do_refresh().
src/cmd.c (do_view_cmd): small optimization.
(do_edit_at_line): likewise.
(swap_cmd): since tty_touch_screen() is called in repaint_screen()
now, don't call it here.
2009-08-12 21:23:13 +04:00
Andrew Borodin
3225c15e69
Removed draw_double_box() function.
...
Since S-Lang library actually doesn't provide double boxes drawing,
the draw_box() function is used always.
2009-08-12 21:23:13 +04:00
Andrew Borodin
11a1c151d9
Type accuracy and optimization in dialog handling routines.
...
src/dialog.c (update cursor): don't check h->current->options twice.
(dlg_try_hotkey): don't send WIDHET_HOTKEY message to h->current widget
twice. Type accuracy. Small optimization.
(dlg_key_event): type accuracy. Small optimization.
2009-08-12 21:23:13 +04:00
Andrew Borodin
3318a5fd98
Call repaint_screen() in screen repaint command handling.
2009-08-12 21:23:13 +04:00
Andrew Borodin
9c9180ce81
TTY: reimplemented colors string parser.
2009-08-12 21:23:13 +04:00
Andrew Borodin
87408d00e9
TTY: separate color initalization.
...
The call of color initialization function (tty_init_colors()) is moved out
from init_curses() function. Thus we avoid the color reinitialization
in SIGWINCH hangling function.
2009-08-12 21:23:13 +04:00
Andrew Borodin
828d1ed09e
RXVT: merged src/tty/rxvt.c into src/tty/win.c.
...
src/tty/win.c: formatted in accordance with maint/template.c.
2009-08-12 21:23:13 +04:00
Andrew Borodin
4f4d0fa5ee
Small optimization.
...
src/screen.c:
(mini_info_separator): since mini_info_separator() is called after
paint_dir(), no need to call tty_set_normal_attrs().
(paint_frame): removed unused code.
2009-08-12 21:23:13 +04:00
Andrew Borodin
a1bbecce76
Screen clearing have been modified.
...
src/layout.c (clr_scr): tty_fill_region() is used instead of dlg_erase()
to clear screen.
2009-08-12 21:23:13 +04:00
Andrew Borodin
30fd7fc34a
TTY: modified line drawing.
2009-08-12 21:23:13 +04:00
Andrew Borodin
28580ca023
done_screen() is moved from src/layout.c to src/main.c.
2009-08-12 21:23:13 +04:00
Andrew Borodin
16a15c0ee2
New functions.
...
tty_noecho() is used instead of noecho() function or macro.
tty_flush_input() is used instead of flushinp() function or macro.
tty_reset_screen() is used instead of endwin() function or macro.
tty_shutdown() is based on slang_shutdown(). Also implemented for
NCurses as wrapper for endwin().
2009-08-12 21:23:12 +04:00
Andrew Borodin
55e626726c
For NCurses, always call doupdate() in tty_refresh().
2009-08-12 21:23:12 +04:00
Andrew Borodin
86f77f3cb2
New functions.
...
tty_touch_screen() is used instead of touchwin() function or macro.
tty_set_normal_attrs() is used instead of standend() function or macro.
tty_set_alt_charset() is used instead of acs() and noacs()
functions or macros.
tty_baudrate() is used instead of baudrate() function or macro.
2009-08-12 21:23:12 +04:00