Commit Graph

2666 Commits

Author SHA1 Message Date
Roland Illig
bdf23438af mcedit can be invoked with the common filename:lineno syntax. 2008-12-18 12:21:23 +00:00
Roland Illig
c1eb75a515 Fixed a crash because of an uninitialized variable. 2008-12-02 22:32:46 +00:00
Pavel Tsekov
b0f2d1654c * edit/editlock.c (lock_build_name): Check the return value of getpwuid().
* src/cmd.c (save_setup_cmd): Remove redundant g_strconcat() call.
* src/hotlist.c (load_hotlist): Likewise.
* vfs/smbfs.c (smbfs_convert_path): Replaced NULL with (char *) NULL.
2007-11-02 14:02:23 +00:00
Pavel Tsekov
3efbdcb0f7 * src/myslang.h [HAS_ACS_AS_PCCHARS]: Remove all code ifdef-ed
HAS_ACS_AS_PCCHARS - it's unused.
* src/help.c [HAS_ACS_AS_PCCHARS]: Likewise.
* src/layout.c (init_curses) [HAS_ACS_AS_PCCHARS]: Remove redundant code.
2007-10-15 10:20:58 +00:00
Pavel Tsekov
7ad6feae42 * src/achown.c: Update copyright notice.
* src/chmod.c: Likewise.
* src/chown.c: Likewise.
* src/cmd.c: Likewise.
* src/color.c: Likewise.
* src/command.c: Likewise.
* src/cons.handler.c: Likewise.
* src/cons.saver.c: Likewise.
* src/dialog.c: Likewise.
* src/dir.c: Likewise.
* src/help.c: Likewise.
* src/info.c: Likewise.
* src/man2hlp.c: Likewise.
* src/menu.c: Likewise.
* src/mouse.c: Likewise.
* src/option.c: Likewise.
* src/profile.c: Likewise.
* src/screen.c: Likewise.
* src/setup.c: Likewise.
* src/subshell.c: Likewise.
* src/user.c: Likewise.
* src/win.c: Likewise.
* vfs/sfs.c: Likewise.
* vfs/tcputil.c: Likewise.
2007-09-26 10:22:25 +00:00
Pavel Tsekov
2f3df3af4e * edit/bookmark.c: Update copyright notice.
* edit/edit.c: Likewise.
* edit/editcmd.c: Likewise.
* edit/editdraw.c: Likewise.
* edit/editkeys.c: Likewise.
* edit/editlock.c: Likewise.
* edit/editmenu.c: Likewise.
* edit/editoptions.c: Likewise.
* edit/editwidget.c: Likewise.
* edit/syntax.c: Likewise.
* src/background.c: Likewise.
* src/boxes.c: Likewise.
* src/complete.c: Likewise.
* src/execute.c: Likewise.
* src/ext.c: Likewise.
* src/file.c: Likewise.
* src/filegui.c: Likewise.
* src/fileopctx.c: Likewise.
* src/find.c: Likewise.
* src/hotlist.c: Likewise.
* src/key.c: Likewise.
* src/keyxdef.c: Likewise.
* src/layout.c: Likewise.
* src/learn.c: Likewise.
* src/listmode.c: Likewise.
* src/main.c: Likewise.
* src/panelize.c: Likewise.
* src/slint.c: Likewise.
* src/textconf.c: Likewise.
* src/tree.c: Likewise.
* src/treestore.c: Likewise.
* src/tty.c: Likewise.
* src/util.c: Likewise.
* src/utilunix.c: Likewise.
* src/view.c: Likewise.
* src/widget.c: Likewise.
* src/wtools.c: Likewise.
* src/x11conn.c: Likewise.
* vfs/cpio.c: Likewise.
* vfs/extfs.c: Likewise.
* vfs/fish.c: Likewise.
* vfs/ftpfs.c: Likewise.
* vfs/gc.c: Likewise.
* vfs/mcfs.c: Likewise.
* vfs/mcserv.c: Likewise.
* vfs/smbfs.c: Likewise.
* vfs/tar.c: Likewise.
2007-09-25 15:33:35 +00:00
Pavel Tsekov
f560dfaa77 * src/ChangeLog: Fix last commit. 2007-09-24 13:40:40 +00:00
Pavel Tsekov
9df32b5790 * src/widget.h: Define new mode for listbox insertion.
* src/widget.c (listbox_append_item): Implement LISTBOX_APPEND_SORTED
by insertsort.
* src/chown.c (init_chown): Use LISTBOX_APPEND_SORTED for user and
group list.
* src/achown.c (do_enter_key): Likewise.
2007-09-24 13:38:48 +00:00
Pavel Tsekov
23361694b6 * src/background.c: Use the correct form of FSF's name in the copyright
notice.
* src/boxes.c: Ditto.
* src/complete.c: Ditto.
* src/execute.c: Ditto.
* src/ext.c: Ditto.
* src/file.c: Ditto.
* src/filegui.c: Ditto.
* src/fileopctx.c: Ditto.
* src/fileopctx.h: Ditto.
* src/find.c: Ditto.
* src/hotlist.c: Ditto.
* src/key.c: Ditto.
* src/keyxdef.c: Ditto.
* src/layout.c: Ditto.
* src/learn.c: Ditto.
* src/listmode.c: Ditto.
* src/main.c: Ditto.
* src/panelize.c: Ditto.
* src/slint.c: Ditto.
* src/textconf.c: Ditto.
* src/tree.c: Ditto.
* src/treestore.c: Ditto.
* src/tty.c: Ditto.
* src/util.c: Ditto.
* src/utilunix.c: Ditto.
* src/view.c: Ditto.
* src/widget.c: Ditto.
* src/wtools.c: Ditto.
* src/x11conn.c: Ditto.
* vfs/cpio.c: Ditto.
* vfs/extfs.c: Ditto.
* vfs/fish.c: Ditto.
* vfs/ftpfs.c: Ditto.
* vfs/gc.c: Ditto.
* vfs/mcfs.c: Ditto.
* vfs/mcserv.c: Ditto.
* vfs/smbfs.c: Ditto.
* vfs/tar.c: Ditto.
* vfs/undelfs.c: Ditto.
* vfs/utilvfs.c: Ditto.
* vfs/vfs.c: Ditto.
* edit/bookmark.c: Ditto.
* edit/edit.c: Ditto.
* edit/edit.h: Ditto.
* edit/editcmd.c: Ditto.
* edit/editdraw.c: Ditto.
* edit/editkeys.c: Ditto.
* edit/editlock.c: Ditto.
* edit/editmenu.c: Ditto.
* edit/editoptions.c: Ditto.
* edit/editwidget.c: Ditto.
* edit/syntax.c: Ditto.
2007-09-24 09:28:32 +00:00
Pavel Tsekov
2362e00199 * src/cmd.c (menu_edit_cmd): Rename a button label from "Home"
to "User".
2007-09-19 14:34:33 +00:00
Pavel Tsekov
bdcbed43de * src/widget.c (listbox_new): Remove redundant initialization of
WListbox fields.
2007-09-19 11:01:50 +00:00
Pavel Tsekov
2d297c4375 * src/util.c (file_date): Do not ignore the return value of localtime ().
Gentoo bug #184296.
2007-09-17 19:42:31 +00:00
Pavel Tsekov
e1386414af * src/find.c (find_parameters): Fix hotkey duplication. 2007-09-14 12:55:08 +00:00
Pavel Tsekov
adb84ceba8 * src/subshell.c (write_all): Do not use void pointer arithmetic. 2007-09-11 13:38:26 +00:00
Pavel Tsekov
20d32448f7 * src/mountlist.c: Fix a warning issued by gcc. 2007-09-11 08:37:51 +00:00
Pavel Tsekov
139e48183f * src/color.h: Add a new color pair.
* src/color.c: Likewise.
* edit/editdraw.c (print_to_widget): Make tabs and trailing whitespace
characters visible.
(edit_draw_this_line): Likewise.
2007-08-27 12:06:02 +00:00
Pavel Tsekov
dd208753b6 * src/screen.c (show_dir): Surrond the current directory with spaces. 2007-08-24 12:22:29 +00:00
Pavel Tsekov
339a66dc2f * src/screen.c (show_dir): Remove unneeded code. 2007-08-24 09:13:47 +00:00
Pavel Tsekov
e2424ae139 * src/filegui.c (rd_widgets) [_LARGE_FILES]: Use format string
capable of supporting 64 bit file sizes.
* vfs/fish.c (fish_linear_start) [_LARGE_FILES]: Use format string
capable of supporting 64 bit file sizes.
2007-08-23 13:16:39 +00:00
Pavel Tsekov
e6980eb09a * src/mountlist.c (fstype_to_string): Define only when
`MOUNTED_GETMNTINFO' or `MOUNTED_VMOUNT' is defined.
2007-08-23 12:33:36 +00:00
Pavel Tsekov
6cb718c0a8 * src/cmd.c (dirsizes_cmd): Re-sort the panel when done. 2007-05-02 12:01:13 +00:00
Pavel Tsekov
eca5afad0f * src/subshell.c (subshell_name_quote): Use the `printf' utility
instead of `echo' to quote the directory name.
2007-03-23 16:42:17 +00:00
Pavel Tsekov
64045fc8f0 * src/subshell.c (sigchld_handler) [__EMX__]: Remove unneeded code. 2007-03-08 17:53:56 +00:00
Pavel Tsekov
850542cebd * src/subshell.c (subshell_pty_slave): New global variable.
(init_subshell): Do not close the pseudo-terminal slave -
store it in `subshell_pty_slave' for later use.
(init_subshell_child): Do not open the pseudo-terminal slave
in the child. It is inherited from the parent now.
Use `subshell_pty_slave' as the file descriptor of the
opened pseudo-terminal slave.
Rearrange the code a bit.
(synchronize): Discard all data from the pseudo-terminal
slave input queue.
2007-03-01 11:07:04 +00:00
Pavel Tsekov
888ab78a1e * src/file.c (copy_file_file): chmod() the target file no matter whether
"preserve attributes" is checked or not, since the destination is
initially created with mode 0600.
2007-02-22 14:29:11 +00:00
Pavel Tsekov
8e04248ef9 * src/utilunix.c (mc_tmpdir): Do not accept relative path in TMPDIR. Use
a hardcoded value instead.
2007-02-22 11:49:01 +00:00
Pavel Roskin
d15f59038c * mountlist.c: Fix misuse of HAVE_STRUCT_STATFS_F_FSTYPENAME. 2007-02-03 01:06:55 +00:00
Pavel Tsekov
56eba6ed17 * src/help.c: Document the newline following the node header.
Teach all code dealing with nodes that the actual node data
starts right after the first newline following the node
header. Thanks to Grigory Trenin <gtrenin@gmail.com> .
2007-01-20 11:40:45 +00:00
Pavel Tsekov
b4046cd029 * src/dir.c (sort_time): Default to sort_name() if the
arguments are equal.
(sort_ctime): Likewise.
(sort_atime): Likewise.
(sort_size): Likewise.
2007-01-13 22:48:07 +00:00
Pavel Tsekov
bc146822b0 * src/dir.h (sort_type): Remove function declaration.
(sort_links): Likewise.
(sort_nuid): Likewise.
(sort_ngid): Likewise.
(sort_owner): Likewise.
(sort_group): Likewise.
* src/dir.c (sort_type): Remove function definition.
(sort_links): Likewise.
(sort_nuid): Likewise.
(sort_ngid): Likewise.
(sort_owner): Likewise.
(sort_group): Likewise.
(sort_orders): Reflect the changes above.
* src/screen.c (formats): Remove references to sort_type(), sort_links(),
sort_nuid(), sort_ngid(), sort_owner() and sort_group().
2007-01-13 22:38:48 +00:00
Pavel Tsekov
cfdc950171 * src/utilunix.c (mc_tmpdir): Call mc_mkstemps() with an absolute
path to prevent stack overflows due to circular dependecy.
2007-01-02 15:55:01 +00:00
Pavel Tsekov
8113a37d37 * src/help.c (startpoint): Remove global variable and all references
to it.
(select_prev_link): Remove the first argument.
Keep searching until a link is found or end of node delimiter is
reached.
(help_handle_key): Reflect the changes above.
Remove an unneeded check.
2006-12-30 23:03:48 +00:00
Pavel Tsekov
370c1d2cb2 * src/view.c (view_file_load_data): Do not to attempt to seek
beyond the end of file. Patch by Andrzej Zaborowski.
(view_moveto_addr_cmd): Display a warning message if the
user specified an invalid offset.
2006-12-30 13:16:54 +00:00
Pavel Tsekov
493a107f8b * src/fsusage.c: Remove references to HAVE_INFOMOUNT. 2006-12-21 18:47:06 +00:00
Pavel Tsekov
9ab2dde60c * src/fsusage.h: Update from gnulib.
* src/fsusage.c: Likewise.
2006-12-21 14:09:30 +00:00
Pavel Tsekov
393d1f5b43 * src/fsusage.h: Resurrect.
* src/fsusage.h: Likewise.
2006-12-21 11:55:00 +00:00
Pavel Tsekov
498c6c0cf1 * src/view.c (regexp_search): Keep the search string in a global
variable so that it can be reused when viewing another file.
Do not use the same variable to hold the search string for
both the "Search" and "Regexp Search" functions.
(view_normal_search_cmd): Likewise.
2006-12-10 21:36:46 +00:00
Leonard den Ottolander
0ac1df7d4f * src/subshell.c (subshell_name_quote): Bash < 2.05b (3-digit octals in
echo_e_cmd) no longer supported.
* NEWS: Comment reflecting above change.
2006-11-27 21:33:45 +00:00
Leonard den Ottolander
4c9ca90e8a * key.c (get_event): Eliminate timeouts on window resize event.
* layout.c (change_screen_size): Set winch_flag to 0 on entrance not exit of
function.
2006-11-08 13:37:24 +00:00
Pavel Tsekov
43b82f1201 * src/layout.c (layout_do_change): Remove global variable.
(layout_cmd): Reflect the changes above.
(layout_change): Ditto.
2006-09-25 08:34:48 +00:00
Pavel Tsekov
5d4d2db3f3 * src/main.c (xtoolkit_panel_setup): Remove - it is a noop.
(setup_panels_and_run_mc): Eliminate references to
`xtoolkit_panel_setup'.
2006-09-22 15:14:58 +00:00
Pavel Tsekov
5978bcc196 * src/key.c (get_key_code): Do not blindly strip the eight bit of the
key code when the 'use_8th_bit_as_meta' flag is set. Only key codes
in the range 128 - 255 should be stripped, the rest must be left
intact.
2006-09-18 21:06:58 +00:00
Pavel Tsekov
3f81ef4f96 * src/wtools.c (fg_input_dialog_help) [ENABLE_NLS]: Translate the
"Ok" and "Cancel" buttons here.
Mark the QuickDialog as translated so that quick_dialog() won't
try translate it again.
2006-09-14 09:12:49 +00:00
Pavel Tsekov
d407b130f4 * m4/ls-mntd-fs.m4: Update to serial#22, which adds support
for getmntinfo() returning its result in struct statvfs.
* m4/fstypename.m4: Update to serial#6, which replaces
HAVE_F_FSTYPENAME_IN_STATFS with HAVE_STRUCT_STATFS_F_FSTYPENAME.
* src/mountlist.c: Sync with gnulib.
All uses of HAVE_F_FSTYPENAME replaced by HAVE_STRUCT_STATFS_F_FSTYPENAME.
[MOUNTED_GETMNTINFO2] Include sys/statvfs.h.
(read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
2006-09-07 15:12:47 +00:00
Pavel Tsekov
f588181dc6 * acinclude.m4 (AC_GET_FS_INFO): Revert a failed attempt to properly detect
getmntinfo() returning its result in struct statvfs.
* src/mountlist.c: Revert a failed attempt to properly detect and use
getmntinfo() returning its result in struct statvfs.
2006-09-07 14:20:57 +00:00
Leonard den Ottolander
7fb17b353c * key.c (check_selects): Get rid of the now redundant else. 2006-08-12 18:22:44 +00:00
Leonard den Ottolander
01d80ec3c7 * key.c (check_selects): Initialize retry to FALSE every time we enter
the do/while loop (bug introduced when incorrectly rewriting the
	backward goto used by the original submitter).
2006-08-12 10:06:22 +00:00
Leonard den Ottolander
fc061342f4 * key.c (check_selects): Fix possible crash on reference to select list
element removed in callback.
2006-08-11 22:57:09 +00:00
Leonard den Ottolander
b7db76f81f * key.c: Make escape key timeout user configurable via the
environment variable KEYBOARD_KEY_TIMEOUT_US (in microseconds).
2006-08-09 21:19:18 +00:00
Andrew V. Samoilov
1868ddd520 * hotlist.c (update_path_name): Fix gcc4 warning. 2006-08-08 12:17:14 +00:00
Pavel Tsekov
bd24e2ea78 * src/hotlist.c (remove_from_hotlist): Fix erronous check of the return
value of query_dialog().
2006-08-06 11:43:34 +00:00
Roland Illig
ca988dd28e Added correct handling of Mac line endings. 2006-08-03 05:51:23 +00:00
Pavel Tsekov
56067d3258 * src/vfsdummy.h [!USE_VFS] (mc_getlocalcopy): Implement. 2006-07-26 09:55:55 +00:00
Pavel Tsekov
7785aa544e * src/mountlist.c (fstype_to_string): Update the code to match its
coreutils counterpart.
Guard the use of MOUNT_UFS and MOUNT_NFS with appropriate
ifdefs as the rest of the code does.
2006-06-17 18:27:40 +00:00
Pavel Tsekov
9e1dd4594d * m4/fstypename.m4: New file.
* acinclude.m4 (AC_GET_FS_INFO): Add a check to determine whether
getmntinfo() takes struct statvfs instead of struct statfs as its
first argument. Define MOUNTED_GETMNTINFO_STATVFS if it does.
Add a check to determine whether struct statvfs has a field named
f_fstypename.
Use gl_FSTYPENAME tp determine whether struct statfs has a field
named f_fstypename.
* src/mountlist.c (HAVE_F_FSTYPENAME): Define when getmntinfo() is
used and the struct which it fills has a field named f_fstypename.
(read_filesystem_list) [MOUNTED_GETMNTINFO]: Use
MOUNTED_GETMNTINFO_STATVFS to determine the type of the first
argument to getmntinfo().
2006-06-17 15:39:07 +00:00
Leonard den Ottolander
7115ed2243 * src/dir.c (sort_orders): Substitute duplicate hotkey 'C' in sort
order dialog.
	* po/*.po: Update changed string in sort order dialog.
2006-06-11 10:50:00 +00:00
Pavel Tsekov
5f21c0fa37 * src/mountlist.c: Revert last commit. 2006-06-07 12:11:38 +00:00
Pavel Tsekov
48f8e1dd69 * src/widget.c (disable_update): Remove redundant static variable.
(handle_char): Reflect the changes above.
2006-05-29 11:58:42 +00:00
Pavel Tsekov
5297c50278 * src/file.c (move_file_file): Do not collect progress information
when moving via copy/erase - copy_file_file() does that already.
Collect progress information when moving via rename ().
2006-05-23 09:35:06 +00:00
Pavel Tsekov
b535c4b08b * src/tty.c (tty_tgetstr) [HAVE_SLANG]: str_unconst() the argument
passed to SLtt_tgetstr().
2006-05-23 07:38:59 +00:00
Pavel Tsekov
d2f0a2a5a7 * src/file.c (move_dir_dir): Remove Win32 specific code. 2006-05-23 07:22:36 +00:00
Roland Illig
d647096f53 Fixed detection of the filesystem information on NetBSD 3.0. 2006-05-21 10:06:39 +00:00
Pavel Tsekov
fe251e620a * src/tty.h [USE_NCURSES]: Pull in term.h if WANT_TERM_H is defined.
(tty_tgetstr): Declare new function.
* src/tty.c [USE_NCURSES]: Request the inclusion of term.h.
(tty_tgetstr): Define new function
* src/main.c (init_xterm_support): Use tty_tgetstr().
2006-05-15 13:26:18 +00:00
Pavel Tsekov
d1b8ea7e7a * src/user.c: Do not include subshell.h . 2006-05-10 12:14:28 +00:00
Pavel Tsekov
19b2b16ca5 * src/subshell.c (resize_subshell): Do not try to resize the subshell tty
if the subshell is not running.
2006-05-08 14:38:36 +00:00
Leonard den Ottolander
85e87b2cdf * cons.handler.c (handle_console_linux): Remove redundant close() calls
before _exit().
2006-04-13 16:00:23 +00:00
Pavel Tsekov
d4c2af2154 * src/file.c (copy_file_file): When a hardlink is created successfully
report success (FILE_CONT) to the caller. Fixes debian bug #301537.
2006-03-29 11:38:25 +00:00
Pavel Tsekov
dc50393a8f * src/mouse.h (Mouse_Type): Add new enumerated values to describe
the xterm mouse reporting modes offered by various xterm-like
terminals.
* src/mouse.c: Adjust the code to reflect the changes above.
Send the proper terminal control codes when xterm normal mouse
tracking is requested.
* src/main.c (init_xterm_support): Try to fine-tune the mouse tracking
mode based on the terminal type.
2006-03-06 09:28:14 +00:00
Pavel Tsekov
049352e884 * src/widget.h (struct WRadio): Remove unused field
`upper_letter_is_hotkey'.
(radio_new): Remove the last argument from the function
declaration - it is unused.
* src/widget.c (radio_new): Remove the last argument from the
function declaration - it is unused.
* src/boxes.c: Adjust all callers to reflect the changes above.
* src/layout.c: Likewise.
* src/listmode.c: Likewise.
* src/option.c: Likewise.
* src/wtools.c: Likewise.
2006-02-28 16:15:21 +00:00
Pavel Tsekov
5d8f17a9c2 * src/boxes.c (configure_vfs) [!USE_NETCODE]: Fix off-by-one error. 2006-02-28 12:12:53 +00:00
Pavel Tsekov
389df305eb * src/subshell.c (synchronize): Do not discard user input if the panels are
off.
2006-02-24 19:43:48 +00:00
Pavel Tsekov
264697b010 * vfs/fish.h: New file.
* vfs/fish.c (fish_directory_timeout): Define new global variable.
(FISH_DIRECTORY_TIMEOUT): Eliminate - this macro is not used
anywhere.
(fish_dir_load): Use `fish_directory_timeout' to calculate the
expiration time of a newly created directory entries.
* src/setup.c [USE_NETCODE]: Include fish.h .
(int_options) [USE_NETCODE]: Add support for user configurable
expiration timeout of FISH directory cache entries.
* doc/mc.1.in: Document `fish_directory_timeout'.
2006-02-23 15:32:18 +00:00
Pavel Tsekov
979282dc40 * src/cons.saver.c [HAVE_CONFIG_H]: Include config.h . 2006-02-21 14:02:11 +00:00
David Martin
68e68c79fc Fix l18n macro N_() to _(). 2006-02-14 09:15:16 +00:00
Pavel Tsekov
ac27ef7c32 * src/wtools.c (quick_dialog_skip): Do not set lines' and cols' members
of the newly created dialog explicitly - create_dlg() does this.
2006-02-09 14:08:38 +00:00
Pavel Tsekov
84ba7897bb * src/screen.c (panel_callback): Reset the `dirty' flag after the panel has
been repainted on focus.
2006-02-08 10:10:37 +00:00
Pavel Tsekov
3652302618 * src/widget.c (buttonbar_set_label): Fix `comparison of distinct pointer types
lacks a cast' gcc warning.
2006-02-06 15:42:30 +00:00
Pavel Tsekov
d39462622b * hotlist.c (hotlist_has_dot_dot): Define new global variable.
(add_dotdot_to_list): Define new function.
(HotListType): Add HL_TYPE_DOTDOT.
(update_path_name): Handle HL_TYPE_DOTDOT entries the same way as
HL_TYPE_ENTRY entries.
(fill_listbox): Likewise.
(hotlist_button_callback): Go up one level when enter is pressed on
an entry of type HL_TYPE_DOTDOT.
(add2hotlist): Always attach a HL_TYPE_DOTDOT to each new HL_TYPE_GROUP
entry.
Make sure that the HL_TYPE_DOTDOT entry is the first one in the list.
(remove_from_hotlist): Do not remove HL_TYPE_DOTDOT entries.
(hot_save_group): Do nothing for HL_TYPE_DOTDOT entries.
2006-02-05 19:30:53 +00:00
Pavel Tsekov
ca2078a6ad * src/key.c (xterm_key_defines): Add sequences for iTerm. 2006-02-05 15:27:49 +00:00
Roland Illig
c29b321563 * edit.h: Removed the leading PATH_SEP_STR from EDIT_DIR, as the
latter is not an absolute directory.
	* edit.c: Adjusted the users of EDIT_DIR.
	* editcmd.c: Likewise.
	* syntax.c: Likewise.
	* src/user.c: Likewise.
2006-02-04 14:41:41 +00:00
Roland Illig
249e1c43e7 * main.c (init_xterm_support): Eterm can handle mouse events, too. 2006-02-04 12:29:30 +00:00
Roland Illig
0983e2d256 Fixed a typo. 2006-02-04 11:14:04 +00:00
Roland Illig
eddbf0e2e1 * Makefile.am: ecs-test needs $(MCLIBS). 2006-02-04 11:13:30 +00:00
Roland Illig
350c958f5e * cmd.c (mkdir_cmd): Fixed a memory leak. Instead of the
absolute path of the created directory, the input is passed to
	update_panels().
2006-02-04 11:12:28 +00:00
Roland Illig
f84cc04e70 * find.c: Added make_fullname() to avoid code duplication. 2006-02-04 11:03:35 +00:00
Roland Illig
0780979cbc Replaced the character comparison with string comparison, which
emphasizes the intention of the code. If the directory is either "." or
"./", the plain filename is chosen.
2006-02-04 00:00:47 +00:00
Roland Illig
2d6b472fb0 * find.c (find_do_view_edit): Only strip the leading "./" from a
directory name if the rest is not empty.
2006-02-03 23:17:45 +00:00
Roland Illig
3b1d56cb8a Replaced the printf format with __printf__. 2006-02-03 17:07:39 +00:00
Roland Illig
f7f06c0202 * util.h (str_unconst): This function is never needed to be
inlined.
2006-02-03 17:04:17 +00:00
Roland Illig
9b8eb2ad78 * find.c: After the "panelize" command, always select the first
file from the panel, not.
2006-02-03 16:59:52 +00:00
Roland Illig
ba9bd33681 * view.c: s/attrset/tty_setcolor/g 2006-02-03 14:42:36 +00:00
Roland Illig
bb683b54d1 * view.c: s/attrset/tty_setcolor/g 2006-02-03 14:33:19 +00:00
Roland Illig
36e8fec66c * widget.c: Added assertions to prevent bugs like the one from
view.c(view_labels) from hiding that long.
2006-02-03 14:28:54 +00:00
Pavel Tsekov
90bda57809 * src/view.c (view_labels): Use `buttonbar_clear_label' to make a
buttonbar button inactive.
2006-02-03 12:16:38 +00:00
Roland Illig
67f8cf661a * tty.h (tty_setcolor): Added.
* tty.c (tty_setcolor): Likewise.
2006-02-03 03:55:37 +00:00
Pavel Tsekov
5c1638523e * src/dir.c: (do_sort): Remove unused variable. 2006-02-02 22:10:58 +00:00
Pavel Tsekov
f4e0124cd2 * src/view.c (view_display_hex): Add missing bracket. 2006-02-01 15:59:21 +00:00
Roland Illig
250fd1ab8e * view.c (view_display_hex): Prevented any screen overflow in
hex display mode. The number of bytes per line in hex mode is
	always a multiple of four -- this makes the computation easier.
2006-01-31 14:39:30 +00:00
Roland Illig
008a1e3b7d Shortened the code for selecting the ``boldflag'' in hex display mode. 2006-01-31 13:45:27 +00:00
Pavel Roskin
9b774d1b7d * Makefile.am: Rename LIBDIR to SAVERDIR to avoid confusion.
Change its value to match the installation path of cons.saver.
* cons.handler.c: Adjust for the above.
2006-01-30 20:08:28 +00:00
Pavel Tsekov
b0ced33741 * edit/editcmd.c: Do not set the field histname' of QuickWidget' unless
the widget is of type `quick_input'.
* src/boxes.c: Likewise.
* src/filegui.c: Likewise.
* src/hotlist.c: Likewise.
2006-01-30 09:22:33 +00:00
Roland Illig
3f581584d5 * view.c (view_display_hex): Bug fix: The list iterator from the
bytes that have been changed in the hex editor must be advanced
	even if the cursor is currently on a changed byte.
2006-01-30 03:50:51 +00:00
Pavel Tsekov
04000dcf84 * doc/mc.1.in: Update the documentation to reflect the fact that
confirmation may be requested when deleting directory hotlist entries
based on a user configurable setting.
* src/file.h (safe_delete): Move declaration of `safe_delete'
* src/main.h: ... here.
(confirm_directory_hotlist_delete): Declare new global variable.
* src/file.c (safe_delete): Move definition of `safe_delete'
* src/main.c: ... here.
(confirm_directory_hotlist_delete): Define new global variable.
* src/hotlist.c (remove_from_hotlist): Based on a user configurable
setting, request confirmation when removing directory hotlist
entries. The confirmation dialog honours the `Safe delete'
setting.
Reorder the buttons in the hotlist group removal confirmation
dialog so that it becomes consistent with other confirmation
boxes.
* src/setup.c (int_options): Add support for user configurable
confirmation of directory hotlist entries removal.
* src/boxes.c (conf_widgets): Likewise.
(confirm_box): Likewise.
(my_directory_hotlist_delete): New module variable.
2006-01-29 20:26:05 +00:00
Pavel Tsekov
d05ad82ea6 * dir.c (do_sort): Do not try to reorder the entries so that ".." becomes
the first entry.
(do_load_dir): When filling the list of directory entriesmake sure that
".." occupies the first element.
(do_reload_dir): Likewise.
2006-01-29 11:23:36 +00:00
Pavel Tsekov
b3fa1f0a3e * src/cmd.c: When invoking external viewer, probe VIEWER environment
variable first, then PAGER, then fall back to "view".
* lib/mc.hint: Mention VIEWER environment variable.
* doc/mc.1.in: Document support for VIEWER environment variable.
2006-01-29 10:41:47 +00:00
Roland Illig
28f0a4ab24 Patch provided in #10557. Fixes #10557. 2006-01-28 09:27:11 +00:00
Roland Illig
cbf2c616ff * cmd.c (toggle_listing_cmd): Included the brief listing mode in
the list of listing modes that can be switched through using
	Alt-t.
2006-01-28 09:21:55 +00:00
Roland Illig
8f683b9789 Oops, we're already in the year 2006. 2006-01-28 00:24:57 +00:00
Roland Illig
282371e33b Rewrote the code so that it does what I intended it to do. 2006-01-28 00:23:55 +00:00
Roland Illig
e3fb94363e * Makefile.am, logging.h, logging.c: Added a new logging module
to allow easy tracing of function calls and other events. It is
	only intended for debugging.
2006-01-27 23:48:49 +00:00
Roland Illig
015ebfc2fe * Makefile.am: cons.saver is installed in $(pkglibexecdir), not
in $(pkglibdir), to conform to the usual directory hierarchy
	standards. Fixes #2796.
2006-01-27 21:53:50 +00:00
Pavel Tsekov
78535f6b60 * file.c (copy_file_file): In 'Reget' mode take into account
the partially retrieved data when drawing the progress bar.
From Jindrich Makovicka <makovick@kmlinux.fjfi.cvut.cz>
2006-01-24 14:07:07 +00:00
Andrew V. Samoilov
ee404fbebe * subshell.c: restart write() calls interrupted by sigchld which lead
to some bytes being swallowed from the subshell's output.
2006-01-23 18:55:36 +00:00
Roland Illig
adc2d181c7 * view.c: Replaced calls to printw() with tty_printf() to get
rid of the str_unconst() function.
2006-01-07 18:17:27 +00:00
Roland Illig
58337baa8d White-space and indentation fixes. Rewrote the expressions for the
*_PRESSED constants to emphasize they are in fact bit masks.
2006-01-07 12:49:08 +00:00
Roland Illig
63a504ffed It was not Redhat who changed the SLang API of SLsmg_write_char, but
actually Debian. Redhat only copied that code.
2006-01-07 12:17:07 +00:00
Pavel Roskin
dd8b442df5 * global.h [!ENABLE_NLS]: Provide replacement for ngettext.
* screen.c (display_mini_info): Cast panel->total to unsigned
long before passing it to ngettext() to avoid warnings.
2005-11-11 03:32:39 +00:00
Pavel Roskin
7b3b03f9db * glibcompat.c: Move Q_ back ...
* util.c: ... here.  Q_ is not defined by just including glib.h.
The glib implementation doesn't strip prefix from translations,
so it's not suitable for us.  Finally, it makes man2hlp depend
on libintl.
Reported by Leonard den Ottolander <leonard@den.ottolander.nl>
2005-11-03 02:18:38 +00:00
Leonard den Ottolander
894b343f90 * main.c (directory_history_add): Fix invalid directory preselection on cd. 2005-11-02 11:50:51 +00:00
Pavel Roskin
da6ee30252 * man2hlp.c (main): Fix using 0 instead of NULL. 2005-10-08 04:55:06 +00:00
Pavel Roskin
528e392458 * widget.c (listbox_fwd): Eliminate forward inline declaration. 2005-10-08 04:52:42 +00:00
Leonard den Ottolander
79567ed4a1 view.c (search): Fix backward regex search off by one. 2005-10-04 21:07:20 +00:00
Pavel Roskin
01f571f1d2 * util.c (gettext_ui): Rename to Q_() for glib compatibility,
move ...
* glibcompat.c: ... here.  Adjust all callers.
2005-10-04 15:20:10 +00:00
Pavel Roskin
0f46bb2632 * screen.c (display_mini_info): Use ngettext(). 2005-10-03 23:37:51 +00:00
Leonard den Ottolander
9ac5ed8d4e * key.c (xmouse_get_event): Catch GPM_DRAG event.
* mouse.c (enable_mouse, disable_mouse): Update printed escape sequence.
2005-09-28 17:21:53 +00:00
Leonard den Ottolander
a621fb9b67 * execute.c (do_execute): Flush stdout after printing the command to be
executed.
2005-09-17 12:08:19 +00:00
Leonard den Ottolander
13d8512c37 * util.c: Indentation cleanup (function result types on different lines
then function names).
2005-09-17 12:01:04 +00:00
Leonard den Ottolander
2319ac0f7b * file.c (make_symlink): Fix off by one in symlink creation. 2005-09-17 11:45:13 +00:00
Leonard den Ottolander
b2952be541 * util.c (diff_two_paths): Abort when second symlink can't be resolved
(fixes segfault).
2005-09-17 11:40:31 +00:00
Roland Illig
06f4ef50e6 option_backup_ext is only available when the internal editor is enabled. 2005-09-07 10:08:25 +00:00
Roland Illig
cd8cf54cbb * setup.c: Replaced the editor_option_backup_ext_int hack with a
string configuration variable, which allows the backup extension
	to have more than just four characters. Added generic support
	for string options.
2005-09-07 08:55:31 +00:00
Roland Illig
4df8fde197 * util.h: Added get_config_string() and set_config_string(),
which are analogous to get_int() and set_int().
	* util.c: Likewise.
2005-09-07 08:47:22 +00:00
Roland Illig
fa0d732112 * setup.c: Renamed options[] to int_options[]. 2005-09-07 07:55:15 +00:00
Roland Illig
689ee9f8ae * main.c (midnight_callback): Ctrl-space calculates the size of
the currently selected directory entry. This is mostly useful for
	directories.
2005-09-06 11:38:45 +00:00
Roland Illig
0e218318da * cmd.c: Added single_dirsize_cmd(), which computes the size of
the currently selected panel entry and moves down. Suggested by
	ForestCreature on mc-devel.
	* cmd.h: Likewise.
	* main.c (midnight_callback): When the space key is pressed and
	the command line is empty, single_dirsize_cmd() is called.
2005-09-06 06:41:35 +00:00
Roland Illig
2d64b1c884 Replaced const_cast with str_unconst. Removed unused mvaddstr. 2005-09-05 03:22:04 +00:00
Roland Illig
4486c5eec2 Replaced const_cast with str_unconst. 2005-09-05 03:20:53 +00:00
Roland Illig
500136d789 Removed unnecessary const_cast. 2005-09-05 03:20:27 +00:00
Roland Illig
16bb1e8eaa * tty.c: Don't use SLsmg_write_char, because Redhat provides a
different API to that function when the preprocessor symbol UTF8
	is defined.
2005-09-05 03:05:39 +00:00
Roland Illig
ad9acbde44 Moved printwstr() from src/slint.c to edit/editdraw.c. 2005-09-05 02:14:29 +00:00
Roland Illig
03759c8f34 * main.h: Added const qualifier to the global prompt variable.
* main.c: Likewise.
2005-09-05 02:10:48 +00:00
Roland Illig
1a0fad0d01 * main.h: Added const qualifier to the global prompt variable.
* main.c: Likewise.
2005-09-05 02:10:47 +00:00
Roland Illig
fed479813e Added const qualifier. 2005-09-05 02:04:23 +00:00
Roland Illig
14e619d39e Switched from printw() to tty_printf() to avoid gcc
warnings. st_ctime is not the creation time, but the status
	change time.
2005-09-05 01:36:58 +00:00
Roland Illig
1c1f2f5210 Switched from printw() to tty_printf() to avoid gcc
warnings. st_ctime is not the creation time, but the status
	change time.
2005-09-05 01:36:57 +00:00
Roland Illig
bb2feb9e7f * info.c: Switched from printw() to tty_printf() to avoid gcc
warnings. st_ctime is not the creation time, but the status
	change time.
2005-09-05 01:34:25 +00:00
Roland Illig
1efcbd27a7 * widget.c: Reduced the number of gcc warnings by using
tty_printf() instead of printw().
2005-09-04 22:04:32 +00:00
Roland Illig
612f1555eb * tty.h: Added tty_printf().
* tty.c: Likewise.
2005-09-04 22:02:25 +00:00
Roland Illig
6bbcb8ef76 Added a comment to ecs_strbox concerning characters with other width
than 1.
2005-09-04 16:34:36 +00:00
Roland Illig
e7917badfa * main.h: Removed unused variables acs_hline and acs_vline. 2005-09-04 16:32:09 +00:00
Roland Illig
26ffecfc09 * treestore.c (str_common): Don't require the arguments to be
different.
2005-09-01 20:56:10 +00:00
Roland Illig
49448bfa43 * view.c (view_fix_cursor_position): Renamed to
view_scroll_to_cursor.
2005-09-01 20:49:17 +00:00
Roland Illig
9fe9ad92a1 Reformatted the comments. 2005-09-01 17:06:38 +00:00
Roland Illig
7b95eee94a Added a comment that the user is responsible for not overflowing the
screen.
2005-09-01 17:04:05 +00:00
Roland Illig
f901a3549c Added line breaks before the function names. 2005-09-01 17:01:12 +00:00
Roland Illig
c3ba638d43 * myslang.h: Partly switched to the new tty functions. 2005-08-29 10:02:35 +00:00
Roland Illig
f85a7d8275 Removed unused variable. 2005-08-29 09:40:58 +00:00
Roland Illig
af781d96f8 Added tty.c. 2005-08-29 09:36:32 +00:00
Roland Illig
ab3005ff93 Added a type conversion to view_growbuf_read_until to suppress a gcc
warning. Instead of treating various expressions as booleans, compare
them with a 0 of appropriate type.
2005-08-29 09:34:43 +00:00
Roland Illig
0c4c461433 The got_interrupt function from tty.c is defined for ncurses, too. 2005-08-29 09:30:45 +00:00
Roland Illig
132ee7a361 Fixed indentation. 2005-08-29 09:05:24 +00:00
Roland Illig
e223667dc3 Removed trailing white-space. 2005-08-29 09:04:39 +00:00
Roland Illig
a1bf93f138 Changed the prototypes of tty_print_hline and tty_print_vline. 2005-08-29 09:03:10 +00:00
Roland Illig
2a0f1a1cd0 * view.c: Converted to use the new tty functions. 2005-08-29 08:53:28 +00:00
Roland Illig
66332a4fb1 * slint.c: The handling of user interrupts has been moved to ...
* tty.c: ... this newly created file, which contains a simple,
	not yet complete interface to the terminal library. It should be
	used instead of depending directly on ncurses or SLang features.
	* tty.h: Added the new function prototypes from tty.c and some
	legacy definitions.
2005-08-29 08:45:28 +00:00
Roland Illig
f1452c9580 * view.c (view_new): Separated the mode toggling functions from
updating the display. The non-updating functions are called on
	initialization.
2005-08-28 20:38:53 +00:00
Roland Illig
1d7b05f8f2 * view.c (view_hexedit_save_changes): Added an assertion that
view->filename be not NULL.
	* view.c (view_toggle_magic_mode): Check if filename != NULL
	before dereferencing the pointer.
	* view.c (view_change_nroff_mode_cmd): Renamed to
	view_toggle_nroff_mode_cmd.
	* view.c (view_new): Don't initialize the various view->mode
	variables by now. This needs to be done correctly.
2005-08-28 19:10:00 +00:00
Leonard den Ottolander
1d1af1d099 view.c (view_normal_search_cmd): Initialize exp to avoid freeing of
uninitialized pointer on cancel.
2005-08-27 11:35:03 +00:00
Leonard den Ottolander
81d7ee4f51 * key.c (xmouse_get_event): Disable double-click tracking for mouse wheel
events.
2005-08-25 20:36:40 +00:00
Roland Illig
55da46b128 * view.c (view_moveto_top): Simplified the code. 2005-08-22 19:19:51 +00:00
Roland Illig
de058c5488 * view.c (view_display_status): In normal display mode (that is:
not search progress), calculate the percentage based on dpy_end
	instead of dpy_start. This avoids a sudden break to 100 % when
	approaching the end of file.
2005-08-22 18:36:51 +00:00
Roland Illig
21640f491d * view.c (struct WView): Renamed dpy_topleft to dpy_start, as it
does not always represent the top-left corner of the screen.
	Replaced dpy_complete with dpy_end, the offset of the first byte
	after the displayed region.
2005-08-22 18:31:51 +00:00
Roland Illig
c0f14a906d * view.c: The search string is managed by the WView, not as
static variable in some functions.
2005-08-21 12:33:21 +00:00
Roland Illig
7abfd54b97 * view.c (free_change_list): Renamed to
view_hexedit_free_change_list.
2005-08-21 12:04:20 +00:00
Roland Illig
135ce37fef * view.c (view_done): Reordered the statements in the
destructor and added paragraph comments.
2005-08-21 11:57:45 +00:00
Roland Illig
2081f5f9fa * fileloc.h: Newly added this file, which provides a place where
all names of user specific configuration files are listed.
2005-08-21 04:00:43 +00:00
Roland Illig
03bdc998ca * view.h: Rewrote it. All functions are preceded by a describing
comment and the "extern" keyword.
2005-08-21 03:32:17 +00:00
Roland Illig
0d4be87ff8 * view.c: Added section headers. The functions are still
somewhat unordered. Renamed some functions to fit into the
	view_*_cmd naming convention.
2005-08-19 19:32:02 +00:00
Roland Illig
6baf73cfd9 Removed the rant from my commit message to make Pavel Tsekov happy. 2005-08-19 13:42:59 +00:00
Roland Illig
99f3df1591 * screen.c (string_file_name): Increased the buffer size to
MC_MAXPATHLEN + 1 bytes to avoid filename truncation.
2005-08-18 04:40:45 +00:00
Roland Illig
541c12241f * view.c (struct WView): Renamed found_len to search_length. 2005-08-18 04:11:52 +00:00
Roland Illig
0601d83324 * view.c (view_display_text): Removed the (almost) unused
variable boldflag.
2005-08-18 03:50:29 +00:00
Roland Illig
b7cba56d21 * view.c (view_display_hex): Completely rewritten. Now the code
distinguishes several phases (state selection, color selection,
	printing) and does not mix them wildly, as the previous code
	did.
2005-08-18 03:33:33 +00:00
Roland Illig
ba8ba542f0 * view.c (view_move_up): Don't scroll up if it is not necessary.
This fixes an inconsistency noted by Andrej Zebrowski on
	mc-devel.
	* view.c (view_move_down): Do nothing if we're already at the
	end of the file. This makes the cursor movement more consistent
	with the behavior of the <End> key.
	* view.c (regexp_search_cmd): Moved the code to save the changes
	of the hex editor out of this function. Whoever wrote that
	should be blamed for it, but the code has been there since the
	beginning.
2005-08-18 02:26:39 +00:00
Roland Illig
01432587b8 Changed the return type of view_toggle_ruler() to void. 2005-08-16 09:04:29 +00:00
Roland Illig
ad29def0c4 * view.c (view_init_growbuf): Mark the first page full instead
of empty. This saves one condition in view_growbuf_read_until().
2005-08-16 08:59:14 +00:00
Roland Illig
03d2e06c41 Layout change for better readability. 2005-08-16 08:51:55 +00:00
Roland Illig
0deeec756e Added some white-space for better readability. The coordinates of the
status line are computed like the other ones (was implicit before).
2005-08-16 08:47:15 +00:00
Roland Illig
9758c34a82 Added some white-space for better readability. 2005-08-16 08:37:05 +00:00
Roland Illig
c2564e99f6 * view.c (view_place_cursor): Made the call to widget_move()
look like the other calls.
2005-08-16 08:22:07 +00:00
Roland Illig
7b35eaa34d * view.c (view_percent): Fixed coordinate computation. 2005-08-16 08:16:12 +00:00
Roland Illig
d76dc9218b Fixed a typo in a comment. 2005-08-16 08:00:15 +00:00
Roland Illig
ae3c8a324d Don't mix enums with ints. 2005-08-15 22:59:20 +00:00
Roland Illig
08a40c8d17 * screen.c (use_display_format): Removed unused variable. 2005-08-15 22:40:58 +00:00
Roland Illig
5c7a219b36 Don't mix enums with ints. 2005-08-15 22:36:53 +00:00
Roland Illig
4e3e810973 * complete.c: Don't mix enums with ints. 2005-08-15 22:33:20 +00:00
Roland Illig
a94e34c698 * complete.c (fetch_hosts): Removed unused variable. 2005-08-15 22:30:36 +00:00
Roland Illig
b973c398dc * view.c (view_toggle_ruler): Don't mix enums with ints. 2005-08-15 21:59:08 +00:00
Roland Illig
d36a6c6cdb Replaced 0 with LISTBOX_APPEND_AT_END. 2005-08-15 21:46:34 +00:00
Roland Illig
66d059bcdf Replaced 0 with LISTBOX_APPEND_AT_END. 2005-08-15 21:46:34 +00:00
Roland Illig
7152139ad6 * wtools.h: Replaced 0 with LISTBOX_APPEND_AT_END. 2005-08-15 21:44:41 +00:00
Roland Illig
32f6020a0f * dialog.h (struct Dlg_head): Changed the bit fields of length one
from signed int to unsigned int.
2005-08-15 20:30:55 +00:00
Roland Illig
ae815922de view_init: Made the initialization order the same as the order in which the
fields appear in struct WView. Explicitly initialize view->marks[], as they
are used without other initialization.
2005-08-15 18:58:18 +00:00
Roland Illig
6e0a3be319 * view.c (view_ccache_lookup): Rewrote the calculation of the
cache entry. Also don't put entries in the cache when the
	current byte is '\r'.
	* view.c (view_ccache_dump): Extended the output by the offset
	of the next line.
2005-08-15 11:49:30 +00:00
Roland Illig
69e4d3f825 * view.c (toggle_hex_mode): Now the hex cursor is always visible
after switching to hex mode.
2005-08-15 10:22:18 +00:00
Roland Illig
3dd9ec536b * view.c (view_growbuf_read_until): When using mc_read, recover
from interrupted system calls.
2005-08-15 10:04:49 +00:00
Roland Illig
c4da4aecf2 Made the search function interruptible. 2005-08-15 09:55:19 +00:00
Roland Illig
6b874e13aa * view.c (view_growbuf_read_until): On short reads, try to read
one more byte to check whether we're already at the end of file.
	This makes the ">=" disappear earlier.
2005-08-06 18:19:14 +00:00
Roland Illig
725c9f7b34 * textconf.c: Include ecs_char in the list of type
characteristics that are printed.
2005-08-06 16:33:54 +00:00
Roland Illig
070b0dccf2 Use hline() instead of addch() to clear the menubar widget area. 2005-08-05 12:01:47 +00:00
Roland Illig
922043282d * view.h: Renamed view to mc_internal_viewer. This avoids
hundreds of shadowed names in view.c.
2005-07-31 20:29:35 +00:00
Roland Illig
ca0d773797 * view.c: Removed global variable have_fast_cpu. It is not used
anymore.
2005-07-31 20:16:12 +00:00
Roland Illig
1b18865579 * user.c (execute_menu_command): Allow execution on no-exec
filesystems. This fixes Savannah Bug #13832.
2005-07-31 19:29:04 +00:00
Roland Illig
ae2ec0ec2e Added missing #include. 2005-07-31 19:08:18 +00:00
Roland Illig
7bb3bea344 Removed redundant comment. 2005-07-31 18:57:20 +00:00
Roland Illig
16b7d7b60a Added standard file header. 2005-07-31 18:47:12 +00:00
Roland Illig
35a8f2b2a2 * Makefile.am: Added support for extended character sets.
* ecs.h: Support for extended character sets.
	* ecs.c: Likewise.
	* ecs-test.c: Testsuite for ecs.c.
2005-07-31 18:30:43 +00:00
Leonard den Ottolander
772c2600b9 * utilunix.c (mc_tmpdir): Check that tmpdir is correctly initialized. 2005-07-27 15:03:24 +00:00
Leonard den Ottolander
ed1899d211 * src/ChangeLog, edit/ChangeLog: Fix wrong dates on latest entries. 2005-07-24 13:42:28 +00:00
Leonard den Ottolander
f21564b9e6 * edit/choosesyntax.c: Create file. Menu option to override syntax
highlighting.
* edit/Makefile.am: Add choosesyntax.c.
* edit/edit.c (edit_init): Set option_auto_syntax to 1 on every invokation
of the editor.
* edit/edit.h: Pass char*** to edit_load_syntax(). Add parameters for
syntax dialog and override.
* edit/editmenu.c (menu_options): Add menu option to override syntax
hightlighting.
* edit/editoptions.c (edit_options_dialog): Pass option_syntax_type to
edit_load_syntax().
* edit/syntax.c (edit_read_syntax_file): Dynamically allocate and fill
syntax list pnames.
* edit/syntax.c (edit_load_syntax): Use char*** for syntax list.
* src/wtools.h: #include "widget.h" and remove redundant declarations
of Dlg_head and WListbox.
2005-07-24 13:37:58 +00:00
Roland Illig
be3ab1a3e0 * view.c: When saving and loading the file position, use the
full pathname instead of the one passed as argument.
2005-07-23 08:20:58 +00:00
Roland Illig
2bf2f0c38d * util.c (save_file_position): Only save the position if not
at the beginning of the file (1;0).
2005-07-23 08:20:03 +00:00
Roland Illig
df1477f1ec Fixed wrong comparison of the result of iconv(). 2005-07-22 23:21:45 +00:00
Roland Illig
c22e826761 Updated German translation. 2005-07-22 21:16:50 +00:00
Roland Illig
6e318ab041 * help.c: Fixed shadowing warnings from gcc. 2005-07-22 09:29:50 +00:00
Roland Illig
7b0f17ad6a fixed a bug that had been introduced by
me, when replacing Dlg_head * with void *.
2005-07-22 09:01:04 +00:00
Roland Illig
390f69bc30 * help.c: Fixed an invalid memory access, which has been noted
by Vitja Makarov.
2005-07-22 08:41:45 +00:00
Roland Illig
37ffcf9ae7 * ext.c: Fixed a typo which has been noted by Arpad Biro. 2005-07-22 07:27:01 +00:00
Roland Illig
1c8c676c76 * key.c: When the command line option -x is given, enable
additional key sequences that are typical for xterms.
	* main.c: First parse command line arguments, then initialize
	key sequences.
2005-07-20 20:29:08 +00:00
Roland Illig
3abff48000 * util.c: Added gettext_ui(), which translates a string and
strips everything before the first '|' character. This function
	is used to translate special elements of the user interface,
	like ButtonBar labels.
	* util.h: Likewise.
	* view.c: Using the new gettext_ui() function.
2005-07-20 15:39:47 +00:00
Roland Illig
77b5978cf1 Removed unused macros mc_mmap and mc_munmap. 2005-07-18 13:21:50 +00:00
Roland Illig
6d3226c4e7 * util.c: Added ascii_alpha_to_cntrl(), which converts 'x' to
^X. Useful for entering control characters literally.
	* util.h: Likewise.
	* widget.c: Use that function after C-q.
2005-07-18 09:31:37 +00:00
Roland Illig
ace71736b8 * view.c: The viewer can remember the last file position and
restore it, like the editor. This fixes Savannah bug #13734.
	* view.h: Likewise.
	* setup.c: Likewise.
2005-07-18 08:47:45 +00:00
Roland Illig
ecfbe13fa3 AC_CHECK_TYPES([mode_t off_t pid_t socklen_t uid_t nlink_t],,, 2005-07-14 06:31:29 +00:00
Roland Illig
de5d9b1d40 * view.c: Always call display() before close_error_pipe() to make
sure the screen looks nice.
	http://mail.gnome.org/archives/mc-devel/2005-July/msg00194.html
2005-07-13 21:30:28 +00:00
Roland Illig
fae0cabfc6 * view.c (view_hexedit_save_changes): Use the VFS file functions
instead of the native ones. This makes it possible to edit
	remote files using the hex editor.
2005-07-12 07:22:49 +00:00
Roland Illig
c61ea2f1c4 Removed leading underscores from variable names. 2005-07-12 07:01:47 +00:00
Roland Illig
8d475c4c35 * view.c: Added some paragraph comments. Changed some literal
expressions (e.g. 0 => '\0', 0 => NULL). Fixed indentation.
2005-07-12 06:04:38 +00:00
Roland Illig
9f62ed703a Changed three one-line comments to one multi-line comment. 2005-07-11 08:17:38 +00:00
Roland Illig
5d5afede78 (view_display_ruler): Reduced code size by declaring a string literal as
"static". (view_display_hex): Added a FIXME concerning screen overflow.
2005-07-11 08:14:44 +00:00
Roland Illig
8bbf0d25fe * view.c (view_update_bytes_per_line): Use a local variable to
do the computation. Update view->bytes_per_line only once, after
	all computations have finished.
2005-07-11 07:39:04 +00:00
Roland Illig
35b218fc69 (view_move_down): Brought to cursor-normal-form. 2005-07-11 07:26:31 +00:00
Leonard den Ottolander
1bf69bc163 info.c (info_show_info): Properly calculate the length of the line drawn
by hline().
2005-07-10 08:46:54 +00:00
Roland Illig
b8969ae3df * view.c (view_ccache_find): Replaced the linear search with a
binary search. This speeds up the viewer by a factor of 25 for
	large files (> 100 MB).
2005-07-07 22:34:31 +00:00
Roland Illig
ca15b965d6 Added to result-equivalent functions for view_ccache_find_linear_down().
All three work, but view_ccache_find_binary() is the fastest of all. So
the other ones will be removed in the next revision. This revision is
mainly for the records.
2005-07-07 22:30:56 +00:00
Roland Illig
0072aeb2e5 Provided multiple versions of view_ccache_find(), which can be selected by
defining C preprocessor symbols.
2005-07-07 21:46:01 +00:00
Roland Illig
bc446f0cee * dialog.h: Replaced object-like macros with implicit references
to an identifier ``h'' with function-like macros. Adjusted all
	users.
	* dialog.c: Likewise.
	* find.c: Likewise.
	* tree.c: Likewise.
	* widget.c: Likewise.
	* widget.c (widget_selectcolor): New function that selects a
	color among DLG_{HOT_,}{FOCUS,NORMAL}C.
2005-07-07 19:34:55 +00:00
Roland Illig
0c2b595997 * view.c (view_display_text): Fixed handling of tabulators. 2005-07-07 18:38:12 +00:00
Roland Illig
4fc6e727e7 Fixed the special handling of nroff character sequences at the beginning of
the screen. Removed the wrong comment. Only advance behind the backspace
character and display the rest of the nroff sequence.
2005-07-07 18:06:57 +00:00
Roland Illig
4d7a3f6779 * view.c (view_compute_areas, view_percent, view_display_status,
view_display_ruler): Fixed screen overflow bugs.
2005-07-07 17:49:01 +00:00