Commit Graph

3748 Commits

Author SHA1 Message Date
Andrew Borodin
59a85303a8 Optimization: don't process the replacement string very often.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-07-05 16:19:33 +04:00
Andrew Borodin
3e6491dcac Fixups of replacement algorithm.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-07-05 16:19:33 +04:00
Andrew Borodin
cc975c8024 Fixed memory leak.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-07-05 16:19:33 +04:00
Andrew Borodin
d2aad0716b Ticket #2231: fixup of replacement algorithm in mcedit.
Type accuracy. Removed unused variables. Removed double assignment.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-07-05 16:19:33 +04:00
Andrew Borodin
955c95bc58 Applied MC indentation policy.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-28 16:22:49 +04:00
Andrew Borodin
dd2ff08a48 Ticket #2115: fixed button location in common input dialog.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-28 15:08:59 +04:00
Andrew Borodin
9dfe1ed070 Ticket #2248: mcedit: don't try set codepage again after file load.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-25 14:39:36 +04:00
Andrew Borodin
f86415f03e Ticket #1490: fix of exit from subshell handling.
If several screens are opened, exit from subshell is handled
icorrectly.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-25 14:26:42 +04:00
nikk
9b5a8dec33 Ticket #1907 (append filename to path copy/move operation)
append filename to path into copy/move dialog, "to:" input field

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-06-24 11:01:02 +04:00
Slava Zanko
48fe4e6881 Lock file is created and destroyed with full path.
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:44:53 +04:00
Andrew Borodin
0bd04ed34f Implemented file locking in hex editor.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:44:22 +04:00
Andrew Borodin
b2ee413f03 Allow use file locking in various components of MC.
Renamed and moved src/editor/editloc.[ch] -> lib/lock.[ch].
Renamed lock handling functions.
Fixed library order in src/Makefile.am.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:44:22 +04:00
Andrew Borodin
15a7b10191 Ask user before exit if there are opened screens in MC.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:44:22 +04:00
Andrew Borodin
768f48de29 SIGWINCH handling in suspended dialogs.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:44:22 +04:00
Andrew Borodin
cf6098505c Close dialogs during MC shutdown.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:44:15 +04:00
Andrew Borodin
56bbdeb15f Support of multiple editors and viewers.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:19 +04:00
Andrew Borodin
dfe9bc887a MC Edit: column_highlighting flag is a member of WEdit struct.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:19 +04:00
Andrew Borodin
2cc2f34912 MCView: reimplemented messages and commands handling.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:19 +04:00
Andrew Borodin
8024889126 Added type for MC viewer exit codes. Changed MC viewer run interface.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:19 +04:00
Andrew Borodin
a87165824c Added function to get dialog title.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:19 +04:00
Andrew Borodin
95e4424e92 Renamed current_dlg variable to top_dlg.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:19 +04:00
Andrew Borodin
74651f2e9f Added modal flag to the dialog structure.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:19 +04:00
Andrew Borodin
5c9826a897 Renamed dlg_id and parent fields of Widget structure.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:19 +04:00
Andrew Borodin
6efe7f2216 Reimplemented widget list in dialog using GList.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:19 +04:00
Andrew Borodin
0e0f9c8ccd Added dialog state (active, suspended, closed).
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:19 +04:00
Andrew Borodin
5ab573263a Modified dialog initialization.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:18 +04:00
Andrew Borodin
62f0f101d7 Reimplemented dialogs stack using GList.
Code reorganization in src/dialog.c.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:18 +04:00
Andrew Borodin
bb7a44d3e8 Ticket #1490: implementation of multiscreen engine.
Multiscreen engine allows to run several editors and viewers
at the same time and switch between them.

Initial commit: minor refactoring: redefine dialog flags using enum.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-22 21:16:18 +04:00
Andrew Borodin
e793117b21 struct WPanel: changed type of searching field form int to gboolean.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-16 13:42:23 +04:00
Andrew Borodin
166fcfc15f Stop quick search before executing any main menu command.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-16 13:42:23 +04:00
Andrew Borodin
ca0dd60500 Added CK_PanelStopSearch command to stop quick search.
Also added WIDGET_COMMAND handling in panel.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-16 13:42:23 +04:00
Andrew Borodin
893c020b01 Ticket #2175: clean quick search input line after interrupt of search.
Also quick search is interrupted now by any panel command.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-16 13:42:23 +04:00
Egmont Koblinger
86c1e06dee Ticket #2199: Buttonbar mouseclicks are off
Case 1: Make the terminal window 85 characters wide. Click (with the
mouse) on the right side of the "Copy" button on the bottom. See the
Move dialog appearing instead of the Copy dialog.

Case 2: Make the terminal 42 characters wide. Click on the bottom right
corner (the Re~ov button). MC invokes its menu or quits, depending on
the exact click location.

The patch that solves all these. The extra space is not assigned to the
first buttons, but distributed mostly evenly across buttons,
guaranteeing that the first five get exactly as much (or one character
less) than the second five, just as it works for the panels. Also, mouse
clicks use the exact same boundaries that were used when printing the
buttons.

Signed-off-by: Yury V. Zaytsev <yury@shurup.com>

Minor code cleanup, renamed local variable to avoid shadowing of global
variable, fixed formatting.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-15 09:46:01 +02:00
Andrew Borodin
8bcc49900b Applied MC indentation policy.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-14 14:04:02 +04:00
Andrew Borodin
dce8010059 Declaration of option_tab_spacing variable was moved from main.h to setup.h.
Includes were fixed.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-14 13:53:02 +04:00
Andrew Borodin
0485ae5026 Ticket #2196: editor hangup if editor_tab_spacing is equalt to 0.
Check and correct value of option_tab_spacing during options loading.
Check and correct value of option_word_wrap_line_length during options loading
and after editor options changing.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-14 13:53:02 +04:00
Ilia Maslakov
c46e2925e1 Ticket #30 (use external clipboard utility)
added params clipbord_store, clipbord_paste into [Misc] section.
    created src/clipbord.[ch]
    added copy_file_to_ext_clip, paste_to_file_from_ext_clip for copy/paste
    text to the global X clipboard.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-06-11 13:47:46 +00:00
Andrew Borodin
9769ada65c Applied MC indentation policy.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-10 13:42:37 +04:00
Andrew Borodin
03513734c7 Ticket #2236: mcview segfaults trying open a compressed man page file.
How to reproduce:

mcview /usr/share/man/man1/bash.1.gz

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-10 13:39:49 +04:00
Andrew Borodin
044b9eca12 Fixed inaccuracy brach merging.
The e40a84f538 commit actually reverted
the 3209f8e61b one. That is wrong.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-10 11:23:30 +04:00
Alexandr Prenko
eafa23a2a7 Ticket #45 (fix for man2hlp warnings)
fixed warnings with some 'man' files

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-06-08 14:30:04 +04:00
Andrew Borodin
3ddec0f89d g_strcasecmp() function is deprecated.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-08 13:07:11 +04:00
Vit Rosin
e40a84f538 g_string_sprintf() is deprecated.
Reimplemented error messages in src/editor/edit.c using g_strdup_printf().

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-08 13:07:11 +04:00
Andrew Borodin
9dc0a54ba1 Ticket #2085: replacement of deprecated GLib functions.
g_tree_traverse() is deprecated. g_tree_foreach() is used instead.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-08 13:03:26 +04:00
Andrew Borodin
a6b7f3ffe1 "Chown command" dialog: applied WGroupbox widget to draw frames.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-07 21:42:51 +04:00
Andrew Borodin
088c8f335b "Chmod command" dialog: applied WGroupbox widget to draw frames.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-07 21:42:51 +04:00
Andrew Borodin
aa0d96bd8b Ticket #1646: removed leading and trailing spaces in i18n resources.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-07 21:42:46 +04:00
Andrew Borodin
bef2bcebda Fixed int overflow in free modes calculation.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-07 13:03:53 +04:00
Andrew Borodin
f16ef2090d set_display_type(): fixed memory leak.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-07 13:03:53 +04:00
Andrew Borodin
2d90717ace Minor changes of info panel look'n'feel.
Added title.
Added LTEE and RTEE symbols to the separator line.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-06-07 13:03:53 +04:00