Commit Graph

58 Commits

Author SHA1 Message Date
Pavel Roskin
a84b0fc9cd Fix some of the most ugly abuses of mixed caps in English texts,
especially in button captions.
2002-10-21 22:26:39 +00:00
Pavel Roskin
c011f62dea * color.c: Rename stalledlink to stalelink. Make the same
change elsewhere.
2002-10-13 22:23:17 +00:00
Pavel Roskin
c785d4195b * global.h: Move fcntl.h inclusion here. Define O_BINARY.
* mountlist.c: Remove more includes already handled in global.h.
2002-09-23 06:43:22 +00:00
Pavel Roskin
97148e3e55 Reuse the same title "Find File". Reformat most ugly code. 2002-09-03 20:04:54 +00:00
Pavel Roskin
6c2eb32b70 * dlg.c (x_set_dialog_title): Completely eliminate. Adjust all
dependencies.
2002-09-03 07:42:36 +00:00
Pavel Roskin
e000c69683 * wtools.c (common_dialog_callback): Fold into ...
* dlg.c (default_dlg_callback): ... this.  Don't redraw dialogs
that don't have colors.  Adjust all dependencies.
(std_callback): Elimitate.
2002-09-02 16:31:33 +00:00
Pavel Roskin
9e36fa257d * global.h: Move include for rx.h and eregex.h here. 2002-08-21 07:20:39 +00:00
Pavel Roskin
047a7f906e * dlg.h: Remove all unused flags for create_dlg(). Adjust all
dependencies.
2002-08-19 06:22:32 +00:00
Pavel Roskin
7ca687c8ed * eregex.h: Update from glibc-2.2.5.
* regex.c: Likewise.
* find.c: Use eregex.h, not regex.h.
* util.c: Likewise.
* view.c: Likewise.
From Alexander Varakin <avarakin00@hotmail.com>
2002-03-18 21:08:18 +00:00
Pavel Roskin
ebe22f53db * find.c (find_parameters): Invert condition when find is case
sensitive.
2002-03-18 20:04:13 +00:00
Andrew V. Samoilov
3de820819f * find.c (find_parameters): Compile content_pattern here.
Inform user about alformed regular expression.
(search_content): Use compiled regular expression.
(do_find): Eliminate `done'.  Call regfree for compiled
content_pattern.
2002-02-28 13:50:03 +00:00
Pavel Roskin
86213a2be0 * find.c (do_find): Re-sort the panel according to the current
settings when doing panelizing.
2001-11-14 19:59:31 +00:00
Pavel Roskin
3ab6f77fee * boxes.c (tree): Rename to tree_box() to avoid confusion.
Adjust all callers and headers.
* main.c (tree_box): Rename to tree_box_cmd().
2001-10-01 06:51:15 +00:00
Pavel Roskin
2168f2fc50 * find.c: Include rx.h or regex.h
(get_line_at): New function.  Returns malloc()ed null-terminated
line from file file_fd.  Input is buffered in buf_size long
buffer.
(search_content): Don't use external egrep.
Use get_line_at and regexp.
2001-09-23 04:06:35 +00:00
Pavel Roskin
c11389facb * global.h: Include io.h, pwd.h, grp.h and utime.h. Adjust all
sources not to include them and to include global.h at the right
place.
2001-09-07 17:52:19 +00:00
Pavel Roskin
a8ef641beb * x.h: Remove. Adjust all users. Make sure that global.h is
included instead.  Don't include sys/param.h unconditionally -
rely on global.h taking care of it.
* Makefile.in: Remove x.h.
2001-09-03 05:07:40 +00:00
Andrew V. Samoilov
d83a8e7b5e * find.c (find_parameters): Fix hotkeys duplication. 2001-07-31 12:18:07 +00:00
Pavel Roskin
e280cb5c8b * find.c: Remove code unused in the text edition. 2001-07-14 21:44:39 +00:00
Pavel Roskin
7205d0210c * background.c: Include "x.h".
* panelize.c: Likewise.
* treestore.c: Likewise.
* user.c: Likewise.
* util.c: Likewise.
* command.c: Reorder includes. Include "x.h".
* complete.c: Likewise.
* find.c: Likewise.
* user.h: Declare user_menu_cmd() inconditionally.
* i18n.h [GAVE_GNOME]: Remove code that is now in x.h.
2001-06-15 23:37:59 +00:00
Pavel Roskin
8c1534e4e6 * cons.handler.c (handle_console): Remove useless default.
* ext.c (regex_command): Initialize include_target_len.
* find.c [HAVE_GNOME]: Eliminate untyped declarations.
* fsusage.c: Remove untyped declaration of statfs().
[_AIX && _I386]: Rename statfs to aix_statfs and move
it before get_fs_usage(). Define statfs to aix_statfs.
2001-06-14 23:28:54 +00:00
Pavel Roskin
1bb43b9c1a * boxes.c [HAVE_GNOME]: Disable unused code.
* find.c [HAVE_GNOME]: Likewise.
2001-05-14 21:57:10 +00:00
Andrew V. Samoilov
ea0cfde3c9 * find.c (search_content): Redo recent change without infinite loop ;-),
egrep_path hardcoded to "egrep" as it is done in locate_egrep ()

(locate_egrep): commented out

(rotating_dash) [!HAVE_X]: moved into do_search to prevent warning
2001-04-27 10:07:45 +00:00
Pavel Roskin
c267347457 * find.c (search_content): Undo a recent change that caused an
infinite loop.
2001-04-26 23:59:59 +00:00
Andrew V. Samoilov
42dd6b0b90 * view.c (get_line_at): previous newline is right condition
for regexp '^' pattern also, fixed

(search) [HAVE_GNOME]: gnome_message_box_new don't expand printf
pattern, so g_strdup_printf used

* find.c (find_parameters): don't use stat structure if mc_stat failed
2001-04-24 14:39:38 +00:00
Pavel Roskin
bb912def1a * gtkedit/editcmd.c: Remove support for XView layout attributes.
* gtkedit/editoptions.c: Likewise.
* pc/chmod.c: Likewise.
* pc/drive.c: Likewise.
* src/boxes.c: Likewise.
* src/chmod.c: Likewise.
* src/dlg.c: Likewise.
* src/dlg.h: Likewise.
* src/filegui.c: Likewise.
* src/find.c: Likewise.
* src/hotlist.c: Likewise.
* src/layout.c: Likewise.
* src/listmode.c: Likewise.
* src/main.c: Likewise.
* src/option.c: Likewise.
* src/panelize.c: Likewise.
* src/wtools.c: Likewise.
* src/wtools.h: Likewise.
* vfs/smbfs.c: Likewise.
2001-04-06 21:48:11 +00:00
Pavel Roskin
5adecba2fd * find.c (find_parameters): Add a checkbox for case insensitive
content search.
(search_content): Pass `-i' to egrep for case insensitive
search.
2001-04-06 05:21:29 +00:00
Pavel Roskin
e828211662 Updated address of Free Software Foundation 2000-08-22 22:50:00 +00:00
Miguel de Icaza
d8c040ccb0 1999-04-25 Sergei Ivanov <svivanov@pdmi.ras.ru>
* find.c: The origin of the bug is in the function do_search (file
	find.c).  It limits the number of subdirectories to scan by the
	number stat.st_nlink-2, or infinite if st_nlink<2. On tar vfs,
	st_nlink is always 1, so it should be the second case.

	But before doing stat, do_search does opendir. And opendir on tar
	vfs (vfs_s_opendir in vfs/direntry.c) increases the st_nlink value
	in the stat data! So mc_stat called after mc_opendir on tar vfs
	returns st_nlink==2 instead of 1. This is interpreted as if the
	directory had no subdirs, thus subdirs are not searched in.

	Changing the order of calls to mc_stat and mc_opendir fixes the
	problem.
1999-04-25 19:57:53 +00:00
Miguel de Icaza
e1ec2e4556 1999-04-05 Miguel de Icaza <miguel@nuclecu.unam.mx>
* find.c (setup_gui): Do not scroll horizontally.  Why does the
	CList behave like this?
1999-04-06 03:48:21 +00:00
Norbert Warmuth
0c32b6f5f2 Tue Mar 2 22:28:39 1999 Norbert Warmuth <nwarmuth@privat.circular.de>
* main.c (panel_clean_dir): New function: reset all counters of a
WPanel and clean directory list.

* various places: Use panel_clean_dir instead of clean_dir whenever
a WPanel is available. This solves the problem reported by Enrico
Scholz (screen refresh while panel reload with an old/now invalid
panel->count).
1999-03-02 21:33:48 +00:00
Miguel de Icaza
8578ca5e2e 1999-02-26 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gdesktop.c (desktop_icon_info_open): Add needs terminal support.

	* gnome-file-property-dialog.c (create_settings_pane): Add Needs
	terminal check box

1999-02-25  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* gaction.c (gmc_open_filename): Add support for needsterminal.

	* gscreen.c: Add New Folder option to the panel popup.
1999-02-26 07:17:51 +00:00
Miguel de Icaza
ca444518b8 1999-02-23 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gdesktop.c (desktop_drag_data_received): Simplify.

	* gscreen.c (panel_icon_list_drag_data_received): Pass the full
	path to gdnd_perform_drop.
	(panel_clist_drag_data_received): same.

	* gdnd.c (drop_on_directory): We no longer take a file_entry
	here.  The directory we get passed is already a fully qualified
	name of the target location.

	* gwidget.c (x_create_input): Hook to the changed signal and sync
	the input with our view of the entry.  This fixes the paste bug
	reported.
1999-02-23 19:21:35 +00:00
Miguel de Icaza
8b9a77adf6 1999-02-12 Miguel de Icaza <miguel@nuclecu.unam.mx>
* find.c (add_to_list): Pass the data pointer as well.
1999-02-12 21:58:05 +00:00
Miguel de Icaza
da63ee80d9 Fixes. Lots.
Headache.

Pink Elephants on the roof.

Miguel
1999-02-12 02:42:42 +00:00
Miguel de Icaza
1266ed6d73 Bunch of changes:
1. desktop entries on the desktop work.
2. Update the mc.keys.in for using some gnome-libs icons
instead of the old ones.
3. Find command rewritten for GNOME.

miguel.
1999-02-11 05:52:55 +00:00
Timur Bakeyev
a39568367e Glibing..... (2)
Wed Jan 27 03:17:44 1999  Timur Bakeyev <mc@bat.ru>

	* Converted memory managment to Glib. Now we use g_new()/g_malloc()/
	g_strdup()/g_free() routings. Also, copy_strings() replaced by
	g_strconcat(), strcasecmp() -> g_strcasecmp(),and sprintf() by
	g_snprintf().

	* Some sequences of malloc()/sprintf() changed to g_strdup_printf().

	* mad.[ch]: Modified, to work with new GLib's memory managment. Fixed
	a missing #undef for tempnam, which caused dead loop. Add several new
	functions to emulate GLib memory managment.

	*main.c, mad.[ch]: Add a new switch  "-M", which allows to redirect MAD
	messages to the file.

	* util.[ch], utilunix.c: Modified, deleted our variants of strcasecmp()
	and strdup() - we have g_ equivalences. Remove get_full_name() - it is
	similar to concat_dir_and_file(). Some other tricks with g_* functions.

	* global.h: Modified, extended. Now it is main memory mangment include -
	i.e. all inclusions of <stdlib.h>, <malloc.h>, <glib.h>, "fs.h", "mem.h",
	"util.h" and "mad.h" done there. This elimanates problem with proper or-
	der of #include's.

	* All around the source - changed order of #include's, most of them gone
	to global.h (see above), minor changes, like "0" -> NULL in string func-
	tions.
1999-01-27 01:08:30 +00:00
Miguel de Icaza
e0faaa671f Merges from the FileOpContext-changes branch. Please see
the ChangeLogs for full information. - Federico
1999-01-14 01:10:32 +00:00
Miguel de Icaza
a7170a4f7a OS2 now uses property defines instead of OS2_NT 1999-01-10 08:55:35 +00:00
Norbert Warmuth
ffb83af112 If someone experiences strange colors in the text edition
try "make clean; make".

Tue Dec 29 15:49:45 1998  Norbert Warmuth  <nwarmuth@privat.circular.de>

* doc/mc.sgml, mc1.in (Color section): minor polishing
(Layout section): documented Highlight...

* gnome/gmain.c: According to the man page the color keyword for executable
files 	is `executable' and not `execute' -- changed.

* file.c (progress_update_one): Ignore files in subdirectories
when panel totals haven't been computed.

(erase_dir, erase_file): update progress bar (i.e. make it work
for OP_DELETE).

(panel_operate_flags): Don't compute panel totals for OP_MOVE.
When moving files on the same filesystem computing totals might
last much longer than the actual move operation.

(various places): adpations for the above changes.

* slint.c (try_alloc_color_pair): Changed hardcoded values into
defines.

* color.c, text.c: Added color "stalledlink" which is used for
stalled symbolic links. Formerly "viewunderline" was used for
this (IMO bad because function and name didn't match).
According to the man page the color keyword for executable files
is `executable' and not `execute' -- changed.

* color.c, color.h: When using SLang some color indexes are not
freely choosable (DEFAULT_COLOR clashed with A_BOLD_REVERSE).
Solved by adding holes in color_map.

* find.c (do_search): fixed possible memory leak
1998-12-29 16:52:49 +00:00
Norbert Warmuth
23cc8d469c Thu Dec 24 18:30:53 1998 Norbert Warmuth <nwarmuth@privat.circular.de>
* configure.in: Deleted du checks

* INSTALL: Deleted --with-dusum documentation.

* doc/mc.sgml, mc.1.in: Completed documentation about the Options/
Configuration dialog. Added Advanced chown subsection. Deleted
variables from the Special settings section which are now covered
by the configuration dialog.

* gnome/layout: Adapted for the new option Compute Totals in the
Configuration dialog.

* screen.c (recalculate_panel_summary): new function which recalculates
the summary information for the mini-status.

* screen.c (panel_reload): use recalculate_panel_summary

* screen.c (do_file_mark): Honour that dirsizes computed is now a
per entry flag.

* option.c: Added Compute Totals to the configuration dialog.

* file.c (compute_dir_size): made non static

(panel_operate_flags): Don't compute directory sizes if verbose
operation are off.

* cmd.c (dirsizes_cmd): Rewritten to use compute_dir_size as suggested
by Miguel, i.e. get rid of du. Now the dirsizes_cmd honours a
selection and computes sizes only for marked directories. Possible
improvement: add a dialog (or C-C?) to abort computation.

* dir.h (file_entry), panel.h (WPanel): Made the dirsizes computed
flag a per file flag.

* dir.c, find.c, panelize.c, screen.c: Adapted to new file_entry and
WPanel structure.

* features.inc: Deleted DUSUM information

* mc.hlp: remade because of changes in doc/mc.1.in
1998-12-24 21:37:24 +00:00
Miguel de Icaza
9c2404da81 1998-12-06 Federico Mena Quintero <federico@nuclecu.unam.mx>
* dir.c (link_isdir): Fetch the information from
	file->f.link_to_dir, since we already have it.

	* dir.h (file_entry): Removed the `cache' field in this structure,
	as it was only used for the deprecated Xview version.
	Also, removed the `exists' field, as it was not being used anywhere.

	* dir.c: Removed all occurrences of file_entry->cache.

	* find.c: Removed all occurrences of file_entry->cache.

	* panelize.c: Removed all occurrences of file_entry->cache.

	* screen.c (do_enter_on_file_entry): New public function that
	implements the functionality in do_enter(), but based on a file
	entry rather than on a panel.
	(do_enter): Use do_enter_on_file_entry() with the selection of the
	panel as an argument.
1998-12-07 02:36:23 +00:00
Miguel de Icaza
301e7fbfc3 Many changes:
- Beginning of the CORBA support for the file manager.
	- Tk and XView code dropped.

Miguel
1998-12-02 23:44:06 +00:00
Miguel de Icaza
bf682eb9d1 Warning fixes.
Miguel.
1998-12-02 21:27:27 +00:00
Miguel de Icaza
aaa7b5e9a2 Lots of changes:
- GNOME edition now compiles without any trace of the text mode
  dependencies.

- We no longer link with libraries we do not use (crypt, gpm), this
  fixes the recent bug reports.

- More tree updates, enhancements.

Miguel.
1998-12-02 05:18:20 +00:00
Miguel de Icaza
a7996c0a20 Weee!
Ok, finally splitted the GUI code that dealt with the file operations into
a separate file.  It is now possible to write a native Gtk version of this.

Until the Gtk-native version is done, the code in mc/gnome/ is linking with
filegui.c.

Miguel
1998-11-18 02:31:23 +00:00
Pavel Roskin
5e0a240dd2 MC now uses egrep found in PATH rather than in standard directories.
Minor fix to complie MC without VFS.
1998-10-01 17:48:03 +00:00
Norbert Warmuth
c10ecb8b0f Now gmc, tkmc and mc build one my glibc2 system (builddir != srcdir).
Mon Sep 28 21:55:13 1998  Norbert Warmuth  <nwarmuth@privat.circular.de>

* src/find.c: Changed hotkey of the continue-button (both Chdir and
Continue used `C').

* po/*.po: remade because one msgstr in find.c changed

* src/Makefile.in: search config.status in builddir and not in rootdir,
i.e. make it compile for builddir != srcdir

* vfs/vfs.h (struct vfs): renamed errno to verrno because glibc2
defines errno as macro (#define errno (*__errno_location ()))

* vfs/Makefile.in: search config.status in builddir and not in srcdir/..,
i.e. make it compile for builddir != srcdir
1998-09-28 20:41:28 +00:00
Miguel de Icaza
c457d7dd96 Pass2 of the QNX port of mc from Tamasi Gyorgy 1998-05-20 02:19:17 +00:00
Miguel de Icaza
f494ada890 Ok, most of the "Elliot Lee confidential bug report" has been dealt
with with this commit.  This also addresses a bunch of the comments
from the status.shtml from DrMike.

Miguel.

1998-04-15  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* screen.c (GT): Assign two spaces for the minimum size of the
	"type" field for the GNOME edition.  This gives some extra space
	for the icon that gets displayed.

	* dlg.c (remove_widget): New function:  used to remove a widget
	from an existing Dlg_head;
	(destroy_widget): Destroy a specific Widget.
	(add_widgetl): Extended to deal with the fact that a running
	Dlg_head can become empty.

	* panelize.c (l_call): Update the input line every time the user
	selects the entry with the mouse (pretty common in the gnome
	edition).

	* hotlist.c (add_new_group_input): Removed an extra field that was
	causing problems.

	* find.c (find_parameters): Tree button is gone for gnome until we
	get the tree function working on gnome.

	* cmd.c (save_setup_cmd): Per Elliot's suggestion, do not pop up a
	dialog box to inform the user about the saved setup.

1998-04-15  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* gcmd.c (gnome_close_panel): Implement the close-the-panel
	functionality.

	* gscreen.c (x_panel_destroy): Implement the gnome mode way of
	destroying the panel.

	* gview.c (view_status): Add cacheing of the information status,
	to avoid excessive flicker.  It would be better if GtkLabel did
	not flicker though.
	(scrollbar_moved): Scroll correctly.  We now use
	view_move_backward and view_move_forward to adjust the scrollbar
	contents.  This displays the scrollbar correctly.

	* gwidget.c (x_listbox_select_nth): This may be invoked before the
	widget has been created, work around this problem.

	* gscreen.c (show_dir): Set the title bar for the window to the
	current directoy.  Reported by both Mike and Elliot.

	* layout: Updated to the new hotlist dialog box.
1998-04-16 02:45:53 +00:00
Miguel de Icaza
036af40392 1998-04-15 Miguel de Icaza <miguel@nuclecu.unam.mx>
* screen.c (string_file_nlinks): The buffer was too small and we
	were overwriting parts of it.

	* subshell.c (do_subshell_chdir): Memory leak fix.

	* find.c (do_search): Do not use undefined order of evaluation.

	* user.c: Do not use undefined order of evaluation.

	* dlg.c (init_dlg): Do init the default return value.
1998-04-15 06:05:34 +00:00