Commit Graph

203 Commits

Author SHA1 Message Date
Miguel de Icaza
8c2b018b56 1998-12-14 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gwidget.c (x_update_input): Use gtk_entry_get_text here.
1998-12-14 05:27:37 +00:00
Miguel de Icaza
5e69e9af71 Go figure how this was missing now. 1998-12-14 04:23:33 +00:00
Miguel de Icaza
accb3df6e6 1998-12-13 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdnd.c (perform_action): Fixed a pair of incorrect braces.
	Files were not being operated on because of this.
1998-12-14 01:36:24 +00:00
Owen Taylor
5f8bb62657 1998-12-12 Owen Taylor <otaylor@gtk.org>
* gscreen.c (panel_tree_drag_motion): Doubled timeout
	for autoexpand - reducing opening unwanted directories.
	(This, and auto-expand itself need to be configurable.)

	* gscreen.c (tree_drag_open_directory): Use
	gtk_ctree_expand() not gtk_ctree_expand_recursive,
	which increases confusion and could be
	_vvveeerrrryyyy_ expensive. (/afs ?)

	* gscreen.c (panel_tree_drag_leave): Fixed up
	signature - "drag_leave" has no x,y.

	* gscreen.[ch] (panel_tree_check_auto_expand): When
	we've expanded rows during a drag, collapse them
	again when the drag leaves that row. We try to
        collapse without changing the position of the current
        row on the screen.
1998-12-12 21:16:01 +00:00
Owen Taylor
5344eb2d94 1998-12-12 Owen Taylor <otaylor@gtk.org>
* gtkdtree.c (gtk_dtree_destroy): Remove timer upon
	destruction to be safe. (Should this, and
	dtree->timer_id itself be in gscreen.c instead?)

	* gscreen.c (panel_tree_drag_leave): Change == to !=
	so that timeouts are properly removed.
1998-12-12 19:29:38 +00:00
msw
4a445469be 1998-12-11 Matt Wilson <msw@redhat.com>
* gscreen.c: The solid lines in the tree are kinda harsh.  Replace
	them with soothing dotted lines.
1998-12-11 23:10:15 +00:00
msw
61619aac90 1998-12-11 Matt Wilson <msw@redhat.com>
* dir-open.xpm, dir-close.xpm: Away with the tacky yellow folders -
	I like these brown ones from tigert better.
1998-12-11 23:04:23 +00:00
Miguel de Icaza
b0eaee692b 1998-12-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gpopup.c (create_actions): The tests for F_PANEL and F_DICON
	were wrong.  Fixed them.  This does not mean that the popup menus
	are right, though.
1998-12-11 19:14:55 +00:00
Owen Taylor
bb4317f961 1998-12-11 Owen Taylor <otaylor@redhat.com>
* gscreen.c gdesktop.c gdnd.h: enable dragging locale files
	into Netscape.
1998-12-11 18:12:21 +00:00
Miguel de Icaza
b14a0d3432 1998-12-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gicon.c (gicon_get_icon_for_file): First try to fetch the inline
	icon data (i.e. thumbnails), second try the generic icon filename.
1998-12-11 17:58:43 +00:00
Owen Taylor
758260fcc5 1998-12-11 Owen Taylor <otaylor@redhat.com>
* gdesktop.c (window_button_press): Ehen cancelling editing
	account for clicks on other GMC windows.
1998-12-11 17:49:09 +00:00
Miguel de Icaza
fd76543150 1998-12-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c (click_proxy_filter): Doh.  We may get DestroyNotify
	for other windows than the proxy, so deal with it.
1998-12-11 15:39:59 +00:00
Miguel de Icaza
105a42e0bb 1998-12-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c (click_proxy_button_press): Use a nice arrow cursor
	for rubberbanding.
	(click_proxy_filter): Keep a firm jaw when the window manager dies
	and thus the proxy window is destroyed.
	(setup_desktop_click_proxy_window): Moved the proxy window
	creation code to this function.
	(click_proxy_property_notify): Handle PropertyNotify events from
	the root window for when the proxy window changes.  Now the window
	manager can restart itself as it pleases and GMC will handle it
	correctly.
1998-12-11 15:20:25 +00:00
Miguel de Icaza
741d37e4eb 1998-12-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
Wheeeee!  Desktop icons can be selected by rubberbanding.  You
	need Englightenment to do this, as so far it seems to be the only
	WM with support for the _WIN_DESKTOP_BUTTON_PROXY property.

	* gdesktop.c (click_proxy_filter): New event filter for button
	presses and releases on the root window.
	(click_proxy_button_press): New function to handle button presses
	on the desktop.
	(click_proxy_button_release): New function to handle button
	releases on the desktop.
	(click_proxy_motion): New function to handle rubberbanding motion
	on the desktop.
	(setup_xdnd_proxy): Flush the server after ungrabbing it.
	(find_click_proxy_window): Flush the server after ungrabbing it.
	(store_temp_selection): Stores the temporary selection to the
	master selection, or viceversa.  This is needed for dynamic
	updating while the user rubberbands.
	(update_drag_selection): New function to update the selection
	while the user is rubberbanding on the desktop.
	(icon_is_in_area): New function to see if an icon is inside the
	rubberbanding area.

	* gdesktop-icon.h: Added fields for querying the icon and text
	position and size.

	* gdesktop-icon.c (desktop_icon_reshape): Set the position and
	size fields as computed for layout.
1998-12-11 12:59:47 +00:00
Owen Taylor
3c8529fac4 1998-12-11 Owen Taylor <otaylor@redhat.com>
* gdesktop.c (editing_started): Grab on the window for the
	icon, not on the canvas, so we can properly detect
	clicks elsewhere.

	(icon_button_release_after): When the user stops selecting,
	regrab the pointer.
1998-12-11 08:58:26 +00:00
Jonathan Blandford
2f6ecf8738 1998-12-11 Jonathan Blandford <jrb@redhat.com>
* gtkdtree.c (gtk_dtree_do_select_dir): fixed a little bug --
	caused a segfault.

	* gscreen.c (x_create_panel): More changes.  The toolbar is moved
 	to a gtk_toolbar, and is movable.  The entry will be put in it's
 	own toolbar, too.
	(panel_create_cwd): For now, hardcode the usize of the entry
 	widget.  Later on, have it expand (when toolbar supports it)
1998-12-11 06:48:21 +00:00
Miguel de Icaza
34a33b2a7a 1998-12-10 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gcmd.c: #include "../vfs/vfs.h"

	* gdesktop.c (setup_icon_dnd_actions): Moved the code that calls
	gtk_drag_source_set() for an icon here.
	(editing_started): Temporarily disable drags while the icon's text
	is being edited.
	(editing_stopped): Re-enable DnD from the icon once editing has
	stopped.
1998-12-11 03:18:41 +00:00
Miguel de Icaza
920858cfaf 1998-12-10 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gcmd.c: #include "../vfs/vfs.h"

	* gdesktop.c (setup_icon_dnd_actions): Moved the code that calls
	gtk_drag_source_set() for an icon here.
	(editing_started): Temporarily disable drags while the icon's text
	is being edited.
	(editing_stopped): Re-enable DnD from the icon once editing has
	stopped.
1998-12-11 03:18:40 +00:00
Miguel de Icaza
51d2d5aff1 1998-12-10 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gcmd.c (gnome_close_panel): When a panel is destroyed, chdir to
	root directory, as the process will be holding the inode for the
	directory that was selected until an operation is performed in
	another panel.

	* gicon.c (gicon_get_icon_for_file): Invert the way the testing
	for icons is done to handle directories properly.
1998-12-11 02:58:48 +00:00
Jonathan Blandford
940cdf53c3 more gui. touch ups... The status bar is a bit more sane now 1998-12-11 02:47:09 +00:00
Owen Taylor
9022456a54 Thu Dec 10 21:38:55 1998 Owen Taylor <otaylor@redhat.com>
* gkey.c (delete_select_channel): Fixed list handling
	with g_list_remove().
1998-12-11 02:38:15 +00:00
Miguel de Icaza
30b4af8f26 1998-12-10 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c (dnd_select_icon_pending): Added this flag that
	specifies whether a selection is pending for an icon if the user
	was holding the Control key down while clicking.  We have to delay
	selection in this case so that DnD will work correctly, just like
	Windows.
	(icon_button_press): New function that handles button presses on
	icons; it obsoletes the old desktop_icon_info_event().
	(icon_button_release): New function that handles button releases
	on desktop icons; it will do what is appropriate if there was a
	pending icon selection.
	(drag_begin): Handle pending selections as appropriate.
	(unselect_all): Added an paremeter that specifies which icon to
	exclude from unselection.
	(editing_started): Unselect all icons but the one for which
	editing has started.
	(dnd_icon_sources): Changed the MIME-types for internal drops to
	"application/x-mc-desktop-icon".
	(click_proxy_window): New variable that stores the proxy window
	for clicks on the desktop.
	(setup_desktop_clicks): New function that sets up clicks on the
	root window.
	(find_click_proxy_window): New function to find and set up the
	window for proxying clicks from the root window.

	* image.metadata.in: Added case for `jpg', as there was only a
	case for `jpeg'.
1998-12-11 02:05:19 +00:00
Miguel de Icaza
771413102b 1998-12-07 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gicon.c (gnome_file_entry_color): If we do not have permissions
	for this directory, indicate this with a special icon.

	* gscreen.c (panel_icon_list_select_icon): Middle button opens a
	new panel on a directory.
1998-12-11 01:57:01 +00:00
Miguel de Icaza
44a1b32eeb 1998-12-08 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c: Moved the old DnD cruft to olddnd.c to keep it there
	for reference purposes.

	* gmetadata.c: Removed the gmeta_get_icon_for_file() function, as
	it is obsoleted by gicon_get_icon_for_file().

	* gdesktop.c (desktop_icon_info_new): Made it use
	gicon_get_icon_for_file().

	* gdesktop-icon.c (set_icon): Now we handle things internally
	using an imlib image, not a filename.
	(desktop_icon_new): Now takes an imlib image for the icon instead
	of a filename.
	(desktop_icon_set_icon): Likewise.
1998-12-09 17:23:38 +00:00
Miguel de Icaza
2f018f6938 1998-12-08 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gtkdtree.c (gtk_dtree_new): Use imlib's visual and colormap.
1998-12-09 01:56:24 +00:00
Miguel de Icaza
b7adce5cf3 1998-12-08 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c (icon_drag_data_received): Doh.  Use the correct
	pathname when calling gdnd_drop_on_directory().
1998-12-08 23:21:15 +00:00
Miguel de Icaza
f41a3e71b8 1998-12-07 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c (desktop_icon_info_new): Do not stat the file, as we
	do not need that information anymore.
	(setup_icon_dnd_source): Moved the DnD-as-source code to here.
	(setup_icon_dnd_dest): New function to set up an icon as a DnD
	destination.
1998-12-08 01:31:17 +00:00
Miguel de Icaza
23d7825dd2 1998-12-07 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c (desktop_icon_info_place): Doh, do not place icons
	past the edge of the *whole* screen :-)
	(dnd_press_x dnd_press_y): New variables to store the cursor
	hotspot for DnD icons.  Moved these over from the
	desktop_icon_info structure, as it does not make sense to have
	this inside every icon.
	(button_press): Use dnd_press_x and dnd_press_y.
	(drag_begin): Likewise.
	(drop_desktop_icons): Use dnd_press_x and dnd_press_y to fix the offsets.
	(drag_data_received): Fix the proxy window offsets for all types
	of targets.
	(drop_desktop_icons): Snap the coordinates as appropriate.
1998-12-07 21:07:27 +00:00
Miguel de Icaza
8942d7e613 1998-12-07 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c (drop_desktop_icons): New function to perform a drop
	from desktop icons to the desktop.  It effectively moves the icons
	around.
	(desktop_icon_info_place): Do not place the icons past the edge of
	the screen.
1998-12-07 15:47:00 +00:00
Miguel de Icaza
c7776d7577 1998-12-06 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c (file_entry_from_file): Finished implementing
	file_entry_from_file().
	(struct desktop_icon_info): Removed the `type' field.  We now stat
	the file when needed to figure out the file type.
	(desktop_icon_info_event): Test whether the file is a directory by
	ourselves, and if it is, open a new panel for it.
	(drag_data_get): Generate the uri-list for internal desktop icon
	drags as well.
1998-12-07 02:36:47 +00:00
Miguel de Icaza
9bd86254e3 1998-12-02 Miguel de Icaza <miguel@nuclecu.unam.mx>
* Makefile.in (codedirs): Dropped xv and tk ports from the
	distribution. include idl directory.

1998-12-01  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* configure.in (slang_use_system_installed_lib): Define slang
	here, to avoid having this on LIBS.

1998-11-26  Herbert Valerio Riedel  <hvr@hvrlab.ml.org>

	* gtkedit.c: changed occurence of 'va_list *ap' to 'va_list ap'

Thu Nov 26 12:20:06 1998  Pavel Roskin  <pavel_roskin@geocities.com>

	* config.h.in: Removed from CVS, added to .cvsignore

	* acconfig.h, macros/curses.m4, src/xcurses.c, src/tty.h,
	configure.in:
1998-12-06 21:01:30 +00:00
Miguel de Icaza
a2840e0a69 Forgot these files 1998-12-05 23:19:57 +00:00
Miguel de Icaza
b12350861b 1998-12-05 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gdnd.c (get_action): Typo fix.
1998-12-05 22:53:30 +00:00
Miguel de Icaza
4a72b02987 Metadata-aware Midnight Commander. WEEEcvs update . 1998-12-04 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gscreen.c (load_imlib_icons): Make it use the new gicon files.

	* gicon.c, gicon.h: New files: they keep an image cache and
	provide the right icon to use based on the filename.  They use the
	GNOME metadata to fecth the "icon-filename" and "icon-inline-png"
	keys.

	* gdialogs.c (file_mask_dialog): Commented the help messages until
	the warnings are figured out.
1998-12-05 21:54:25 +00:00
Miguel de Icaza
6067afb1fc 1998-12-04 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c (desktop_icon_info_new): Connect the signals for DnD
	so that we can drag icons from the desktop.
	(drag_begin): New function to set the drag cursor for icons on the desktop.
	(button_press): New function that stores the hot spot position for
	DnD cursors.
	(drag_data_get): New function to fetch the URI-list of selected icons.

	* gdialogs.c: Fixed some includes.

	* gdesktop.h: Removed the DnD target enum from here, since it is
	specific to each submodule.

	* gdnd.h: Moved the DnD target enums to here.  Added a new
	TARGET_MC_DESKTOP_ICON.

	* gdesktop.c (get_icon_snap_pos): Fixed icon snapping; the
	coordinates not being updated correctly.

	* gscreen.c (panel_drag_data_get): Free the uri list; it was being leaked.
1998-12-05 01:01:13 +00:00
Jonathan Blandford
77cc218e61 finished copy dialog. Move and delete are trivial now. Then, it's on to
error messages!!!
1998-12-04 22:35:23 +00:00
Miguel de Icaza
7d035cca51 Make the tree a drag source -mig 1998-12-04 21:32:19 +00:00
Jonathan Blandford
aa42db1042 more dialog changes 1998-12-04 20:21:11 +00:00
Miguel de Icaza
2eab3ff5f6 1998-12-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c (load_desktop_icons): Added arguments that specify
	where to place the newly-created icons.  This needs some tweaking still.
	(reload_desktop_icons): Now takes arguments for the position of
	the new icons.
	(drag_data_received): Pass in the drop position to reload_desktop_icons().

	* gscreen.c (panel_tree_drag_motion): Added missing variable declaration.

	* gdesktop.c (load_desktop_icons): Added an incremental flag that
	specifies whether icon creation is unconditional regardless of
	whether there is an icon for a file or not.
	(reload_desktop_icons): Use the incremental flag in load_desktop_icons().
	(drag_data_received): Reload the desktop incrementally, to avoid flicker.
	(desktop_icon_info_new): Use mc_lstat(), not mc_stat().  We do
	want to read symlinks, even dangling ones, if they exist.
	(load_desktop_icons): While we are reading the desktop directory,
	first place all the icons that have their metadata icon-position
	set, and build a list of the ones that don't.  *Then* place
	those.  This fixes overlapping icons on weird situations.

	* directory.xpm: Removed bogus garbage.  There was a stale pixmap here.

	* gdesktop.c (setup_desktop_dnd): Allow for GDK_ACTION_ASK as well.

	* gscreen.c (panel_widget_motion): The action argument to
	gtk_drag_begin() is a mask of possible actions, not a single action.

	* gdesktop.c (drag_data_received): Only reload the icons if the
	drop was successful.
1998-12-04 02:08:06 +00:00
Jonathan Blandford
60c82468ae op_win dialog stuff next 1998-12-04 00:13:53 +00:00
Miguel de Icaza
dbf640d8ad 1998-12-03 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gscreen.c (panel_tree_drag_motion): Improve interactivity
	(x_create_panel): Add a little decorating frame.
1998-12-03 22:08:04 +00:00
Miguel de Icaza
ac7fc9b8b2 1998-12-03 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gscreen.c (panel_create_icon_display, panel_create_file_list):
	Hook up to drag_begin and drag_end events.

	(panel_tree_drag_motion): Either queue a scroll on the tree, or
	queue an open-directory event.

	(panel_tree_scroll): Scroll the tree when the drag pointer is in
	one of the boundaries of the tree.

	(panel_tree_scrolling_is_desirable): new function to figure out if
	it is a good plan to scroll the tree view instead of opening it.

	(panel_chdir): Do not sync with the tree when we are in the middle
	of a drag and drop operation.

	(panel_drag_begin, panel_drag_end): New functions to keep track
	of the dragging operations.
1998-12-03 21:56:11 +00:00
Miguel de Icaza
414df0f7b7 1998-12-02 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gscreen.c (panel_tree_drag_data_received): Perform drag and drop
	operations on the Tree.
1998-12-03 16:10:25 +00:00
Miguel de Icaza
c0ac4984ab 1998-12-02 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdesktop.c (setup_desktop_dnd): New function to set up drops
	to the root window.
	(setup_xdnd_proxy): Function by Owen Taylor to set up a DnD proxy
	window.
	(drag_data_received): Function to handle drops on the root window.
	(desktop_destroy): Destroy the DnD setup.
	(reload_desktop_icons): New function to reload the desktop.

	* gscreen.c (drag_types, drop_types): Removed url-list; only
	uri-list should be there.

	* gdesktop.h: Removed TARGET_URL_LIST from the DnD enumerations.
1998-12-02 23:37:27 +00:00
Miguel de Icaza
befc99bf8d 1998-12-02 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtkdtree.c (gtk_dtree_do_select_dir): Made static, as it is for
	internal use only.
	Fixed a little bunch of compiler warnings.

	* gscreen.c (x_fill_panel): Use gtk_dtree_select_dir(), not
	gtk_ctree_do_select_dir().

	* gpopup.c (gpopup_do_popup): Fixed incorrect assertion and
	actually create the menu (doh).
	(gpopup_do_popup): Do the same magic as in gnome-popup-menu to
	fetch the item that was activated in the menu.  Keep this code out
	of reach of children.
	(fill_menu): New function to fill the menu using the
	gnome-popup-menu magic for fetching the activated menu item.
	Removed ifdef'ed code.
1998-12-02 20:24:25 +00:00
Miguel de Icaza
c983d57dd2 Duh. Here is the correct ChangeLog: 1998-12-02 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gscreen.c (tree_drag_open_directory, panel_tree_drag_motion,
	panel_tree_drag_leave): Drag and Drop support routines for the
	tree to auto-expand the tree when the user stays still on top of a
	directory.
1998-12-02 06:52:11 +00:00
Miguel de Icaza
dabe341f88 1998-12-01 Miguel de Icaza <miguel@nuclecu.unam.mx>
* configure.in (slang_use_system_installed_lib): Define slang
	here, to avoid having this on LIBS.

1998-11-26  Herbert Valerio Riedel  <hvr@hvrlab.ml.org>
1998-12-02 06:51:40 +00:00
Miguel de Icaza
e265fe2067 1998-12-01 Federico Mena Quintero <federico@nuclecu.unam.mx>
* glayout.c (file_menu): Use view_cmd and view_simple_cmd in the
	menu instead of panel_action_view and
	panel_action_view_unfiltered, respectively.

	* gpopup.c (create_regexp_actions): Create the menu items using
	gnome-app-helper, for visual consistency.
	(create_actions): Likewise.  Also, fixed S_ISLNK() confusion.
	(get_label_text): Extract the label from the GnomeUIInfo item in
	an ugly way.
1998-12-02 06:33:07 +00:00
Jonathan Blandford
b081558a24 moved functions around... 1998-12-02 04:33:26 +00:00
Miguel de Icaza
a065078165 1998-12-01 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gscreen.c (panel_switch_new_display_mode): Destroy the old
	widget.  Add the list view to the proper table.

	* glayout.c: Remove the exit menu option.

	* gtree.c (gtk_dtree_contains): New routine used to avoid
	duplicate entries in the tree display.
1998-12-01 21:56:54 +00:00