* components/html/ntl-web-browser.c: (browser_vfs_read_callback):
Fixed a bug my changes to GNOME VFS exposed. The callback couldn't
handle a "bytes_read" of 0.
* libnautilus/nautilus-directory-private.h:
* libnautilus/nautilus-directory.c:
* libnautilus/nautilus-directory.h:
* src/file-manager/fm-directory-view.c:
Added a new interface for monitoring files and directories.
Also fixed the self-check code that was failing since the
async. changes.
* libnautilus/nautilus-file.h:
Added the interface for monitoring single files, but it isn't
implemented yet.
* libnautilus/nautilus-icon-canvas-item.c:
* libnautilus/nautilus-icon-canvas-item.h:
* libnautilus/nautilus-icon-container.c:
* libnautilus/nautilus-icon-container.h:
* libnautilus/nautilus-icon-dnd.c:
* libnautilus/nautilus-icon-dnd.h:
* libnautilus/nautilus-icon-private.h:
Restructured Andy's modifier changes so the canvas item doesn't
have to know about modifiers. This makes the canvas item private
again. Users of NautilusIconContainer shouldn't have to know
about the canvas item.
* src/file-manager/fm-icon-view.c:
Reformatting.
* libnautilus/nautilus-directory.c
(read_some_metafile_data), (metafile_read_start),
(metafile_write_create_callback), (metafile_write_start),
(nautilus_directory_monitor_files_ref):
* libnautilus/gdk-pixbuf-extensions.c
(nautilus_gdk_pixbuf_load_async):
* src/ntl-uri-map.c (got_metadata_callback):
* components/html/ntl-web-browser.c (browser_vfs_callback),
(do_vfs_load):
Update for the new GNOME VFS which doesn't return an immediate error
code when doing an async. call.
improved title for non-vfs uris, used Gene's routine to escape http
parameters in service stuff, and finally weakened assert in
nautilus directory to allow non-vfs uris to continue to work
2000-04-12 Pavel Cisler <pavel@eazel.com>
* src/file-manager/fm-directory-view.c:
(fm_directory_duplicate_selection), (bonobo_menu_duplicate_cb),
(append_uri_one), (duplicate_cb), (fm_directory_view_real_update_menus):
Added a Duplicate menu item. (task 329)
* src/file-manager/dfos-xfer.c:
(fs_xfer)
Added support for the duplicate command. Passing in a NULL for
target directory now starts a duplicate operation.
* src/file-manager/dfos-xfer.c:
(fs_xfer)
Made the progress dialog receive the text for the setup state. Pass
in proper text for copy and move operations.
* src/file-manager/dfos-xfer.c:
(handle_xfer_ok)
Pin the values of the bytes_copied to the preflight maximum -- a copy
may end up copying more than it estimated when items are added to
the hierarchy after the copy started. (I was hitting this when copying
a folder into itself, which is a separate bug).
added framework for using custom images to reflect highlight state;
used it to make folders reflect drop-highlighting by opening (just
in eazel theme for now)
* check-FIXME.pl: This is a new Perl script for searching for FIXME
in the code. It reports any FIXME that does not have a bug number
next to it, or any with a bug number that's not an open bug.
* libnautilus/nautilus-bookmark.c: Attached a bug number to a FIXME
for script-testing purposes.
* docs/architecture.txt: Removed a FIXME. So sue me!
* src/file-manager/fm-icon-text-window.c
(create_attributes_option_menu): Added a call to gettext since the
attribute_labels are now N_ strings.
* po/.cvsignore: Ignore the generated files.
* libnautilus/nautilus-icon-factory.c: Formatting tweak.
2000-04-11 Pavel Cisler <pavel@eazel.com>
* libnautilus/nautilus-icon-dnd.c:
* libnautilus/nautilus-icon-dnd.h:
Fix a problem where drag actions did't update properly when dragging
between two windows. The pointer to the private GtkDragStatus needs
to be global, not stored in the drag originator widget.
directory views). Added new directory to CVS, so make
sure you do a "cvs update -d" and not just "cvs update".
"make install" now installs a file of mime-type-to-English
descriptions in the gnome-mime directory.
* data/mime/nautilus.keys: The actual mapping between
MIME types and English descriptions. Read these and send
me your abuse.
* data/mime/Makefile.am: New file, copies nautilus.keys to
gnome-mime directory.
* data/Makefile.am: includes "mime" subdirectory
* configure.in: configures "data/mime" directory
* libnautilus/nautilus-file.c:
(nautilus_file_get_mime_type_as_string_attribute):
New function, returns the raw MIME type as a string,
and handles the no-MIME-type case.
(nautilus_file_get_string_attribute): handle attribute
"mime_type", distinct from "type" which is now the
human-language one.
(nautilus_file_get_type_as_string): Use gnome-mime
to get human-language descriptions based on the MIME
type.
(nautilus_file_is_executable): Fixed this function which
was reading info->flags instead of info->permissions. Now
the special executable icon appears much more often (though
we still don't know what it's supposed to be).
* src/file-manager/fm-error-reporting.c:
(fm_report_error_renaming_file): Use "directory" instead of
"folder" to match our terminology elsewhere.
* src/file-manager/fm-icon-text-window.c:
add "mime type" to list of choices of text that can appear
beneath icons (in addition to just plain "type", which is
the human-language one).
synchronously).
Requires new GNOME VFS.
* libnautilus/nautilus-directory-private.h:
* libnautilus/nautilus-directory.c:
* libnautilus/nautilus-directory.h:
Changed code to read and write metafiles async. Too many functions
modified for me to list here.
* libnautilus/nautilus-file-private.h:
* libnautilus/nautilus-file.c:
* libnautilus/nautilus-file.h:
(nautilus_file_changed), (nautilus_file_emit_changed),
(nautilus_file_get_metadata), (nautilus_file_set_metadata),
(nautilus_file_call_when_ready), (nautilus_file_cancel_callback):
Changes to NautilusFile so it can participate in the new.
* components/notes/ntl-notes.c (notes_load_metainfo):
Fixed a bug in my recent changes where it would use a bad file
object when getting metadata.
* src/file-manager/fm-directory-view.c (notes_load_metainfo):
Renamed "tags" to "keys".
2000-04-11 Pavel Cisler <pavel@eazel.com>
Drop target highlighting.
Add new call to determine if a drop target can accept a drag.
Tweak modifiers for file copy.
2000-04-10 Pavel Cisler <pavel@eazel.com>
Nasty hack to allow drag&drop actions to respond to modifier keys
and the drop context properly. This will one day get fixed by
adding proper hooks to Gtk+ and using them. For now we have to
do this.
that is compatible with async. metadata reading.
* components/notes/ntl-notes.c:
(notes_load_metainfo): Changed to use nautilus_file_call_when_ready
to wait for the metadata. Also fixed a bug that was causing an assert
inside the call to gtk_editable_insert_text.
(main): Made warnings and criticals stop in the debugger.
* libnautilus/nautilus-directory.c:
* libnautilus/nautilus-directory.h:
(nautilus_directory_call_when_ready): Renamed the call to indicate
it can wait for more than just metadata. For now it does only wait
for metadata, though.
(nautilus_directory_cancel_callback): Renamed this too.
* libnautilus/nautilus-file.c:
(nautilus_file_call_when_ready), (nautilus_file_cancel_callback):
Made a corresponding call for the metadata of a single file.
* libnautilus/nautilus-gdk-extensions.c:
* src/nautilus-index-title.c:
Formatting changes.
* libnautilus/nautilus-metadata.h:
Clarified that ANNOTATION is a per-file piece of metadata.
* src/ntl-uri-map.c:
* src/file-manager/fm-directory-view.c:
Use new names of calls.
* src/file-manager/fm-icon-view.c:
* src/file-manager/fm-list-view.c:
Added comment.
* libnautilus/nautilus-list.c:
(nautilus_list_initialize_class), (nautilus_list_initialize),
(select_or_unselect_row_callback), (emit_selection_changed),
(select_range), (select_row), (select_row_from_mouse),
(row_set_selected), (select_row_unselect_others),
(nautilus_list_select_all), (nautilus_list_unselect_all),
(nautilus_list_button_press), (nautilus_list_keyboard_move_to),
(nautilus_list_motion), (nautilus_list_set_selection):
Reworked selection such that the SELECTION_CHANGED signal is
emitted only once for every selection-affecting operation,
and never if the selection hasn't changed at all. This makes
such operations as Select All, switch-from-icon-view-with-lots-
selected, and arrow-key-to-end-of-list significantly faster.
use same keys/behavior as in icon view). There are a few
minor bugs remaining that I'll write up separately.
* libnautilus/nautilus-list.c:
NautilusListDetails struct: added fields for
keyboard_row_to_reveal and keyboard_row_reveal_timer_id;
(nautilus_list_initialize_class): Removed key binding set for
this class (uses key_press_event function instead); used
gtk_binding_entry_clear to get rid of all the unwanted GtkCList
key bindings; wire up key_press_event function; wire up
destroy function
(nautilus_list_destroy): New function, destroy details struct
(this was storage leak) and clean up pending timer.
(nautilus_list_clear_keyboard_focus), (nautilus_list_set_keyboard_focus),
(nautilus_list_keyboard_move_to), (keyboard_row_reveal_timeout_callback),
(unschedule_keyboard_row_reveal), (schedule_keyboard_row_reveal),
(reveal_row), (nautilus_list_keyboard_navigation_key_press),
(nautilus_list_keyboard_home), (nautilus_list_keyboard_end),
(nautilus_list_keyboard_up), (nautilus_list_keyboard_down),
(nautilus_list_keyboard_page_up), (nautilus_list_keyboard_page_down),
(nautilus_list_keyboard_space), (nautilus_list_activate_selected_items),
(nautilus_list_get_first_selected_row),
(nautilus_list_get_last_selected_row),
(nautilus_list_key_press): New functions, all the mechanism for
handling key presses similarly to NautilusIconContainer. Bonus
key handling for Page Up and Page Down.
(nautilus_list_move_focus_row), (scroll_vertical): Removed these
functions that were used by the GtkCList key bindings in favor of
nautilus_list_key_press and friends.
be activated by clicking in white space past the name.
Also started making changes in the direction of getting
keyboard selection working properly in list view (but
most of the work remains).
* libnautilus/nautilus-gdk-extensions.h,
* libnautilus/nautilus-gdk-extensions.c:
(nautilus_stipple_bitmap): New function, returns pointer to
static 50% stipple bitmap.
* libnautilus/nautilus-icon-cvanvas-item.c:
remove global stipple object;
(nautilus_icon_canvas_item_initialize_class): Remove initialization
of global stipple object.
(draw_or_measure_label_text), (draw_stretch_handles): Use
nautilus_stipple_bitmap () in lieu of global stipple object
in this file.
* libnautilus/nautilus-list.c:
(get_cell_horizontal_start_position): New function, extracted
from draw_row so I could use it elsewhere.
(nautilus_list_key): Removed function.
(nautilus_list_draw_focus): New function, draws keyboard-focussed
row with the same stipple outline used in icon view.
(nautilus_list_move_function_row): New function, copied & simplified
from GtkCList. Will probably rewrite entirely or eliminate very soon.
(nautilus_list_scroll_vertical): New function, copied & simplified
from GtkCList. Handles various keyboard commands, though not yet with
the behavior we actually want.
(nautilus_list_initialize_class): Begin to override and eliminate
GtkCList key bindings that we want to change. I've just started this
work -- all I've done so far is make space do nothing but Control-space
toggle the selection status of the keyboard-focussed row. I need to
go through and fix up all the bad inherited bindings. Also in this
function replace GtkCList's scroll_vertical and draw_focus function
pointers, and removed the key_press_event and key_release_event
overrides that were deliberately preventing us from inheriting any
of GtkCList's keyboard behavior.
(nautilus_list_button_release): Only activate link-text if the click
is in the horizontal bounds of the text.
(draw_row) Use get_cell_horizontal_start_position that was extracted
from this function.
pointed service code at Jonathan's prototype server - registration is
now working. Also, implemented simple drag highliting, by treating it
exactly like selection highliting
* libnautilus/nautilus-gdk-extensions.h:
#defines for colors NAUTILUS_RGB_COLOR_RED, _GREEN,
_BLUE, _WHITE, and _BLACK.
* libnautilus/nautilus-gdk-extensions.c:
(nautilus_parse_rgb_with_white_default): Replaced
hard-wired numbers with these #defines.
* libnautilus/nautilus-list.h,
* libnautilus/nautilus-list.c:
added enum entry for NAUTILUS_CELL_LINK_TEXT;
(nautilus_list_mark_cell_as_link): New functions, converts
an ordinary text cell into a link-text cell.
(nautilus_list_button_release): Only activate link-text
cells on single click; other cells select as in other lists.
(draw_row): draw link-text cells with blue text and an
underline, so they look like typical web links.
(nautilus_list_set_cell_contents): Convert link-text cell
back to ordinary text cell before cleaning up old
contents so parent function will do the right thing.
* src/file-manager/fm-list-view.c:
(add_to_list): mark file name cell as link-text cell.
(remove_from_list): New function, extracted from...
(fm_list_view_file_changed): Followed Darin's advice on
how to simultaneously clarify this code and fix a
storage leak.
For Darin, fixed a typo that caused every file to be
displayed as if it were a directory.
* src/ntl-uri-map.c:
(my_notify_when_ready): Added two missing "== 0"s.
* src/file-manager/fm-directory-view.c
(notify_selection_change_cb, display_pending_files): Add a boolean
field have_pending_uris_selected to distinguish the case where we
have _no_ pending selection from the case where we have an empty
one (in both cases, the pending_uris_selected field should be
NULL).
Next I'll change the actual metafile access to work that way.
* libnautilus/nautilus-directory.h:
* libnautilus/nautilus-directory.c:
(nautilus_directory_metadata_call_when_ready): Added function
that requests a read of some metadata and calls back when the
data is ready.
* src/ntl-app.c: (nautilus_app_startup): Got rid of call to
nautilus_navinfo_init.
* src/ntl-types.h: Moved the NautilusNavigationInfo struct
and related defines to ntl-uri-map.h.
* src/ntl-uri-map.h:
* src/ntl-uri-map.c:
Reformatted and changed the names of many functions.
Added code to use the new metadata callback.
* src/ntl-index-panel.c:
* src/ntl-main.c:
* src/ntl-view.h:
* src/ntl-window-msgs.c:
* src/ntl-window.c:
* src/ntl-window.h:
Had to change includes a bit because of my changes to what
header files are including.
* src/ntl-window-msgs.c: (nautilus_window_update_state):
* src/ntl-window.h:
Use the new nautilus_navigation_info_cancel call instead of
reaching right in to cancel the underlying call.
* src/ntl-view-private.h:
Reformatting.
* libnautilus/nautilus-directory-background.c:
(nautilus_connect_background_to_directory_metadata):
Fixed code that was trying to disconnect the handler from the
new directory, not the old one.
* src/file-manager/fm-list-view.c:
(fm_list_view_file_changed): Only call nautilus_file_unref if
the file isn't gone. This cures some GTK-CRITICALS I ran into.
* src/file-manager/fm-properties-window.c:
(name_field_update): Renamed to name_field_update_to_match_file;
handle case where file name was changed elsewhere.
(create_properties_window): Hook up name_field_update_to_match_file
to get called when file changes externally.
(remove_properties_window_from_hash_table): New function.
(fm_properties_window_get_or_create): Use hash table so there's
only one Properties window per file. This was intended to be the
design but we forgot to implement it earlier.
made registration invoke the service cgi and give appropriate error
feedback or move on to the configuration step. Made it disable the
registration button unless something is typed into each of the 3 fields
* src/ntl-window-msgs.c: (nautilus_window_update_internals):
Don't update Back list when the location hasn't actually
changed, since (A) it would be silly and (B) the code that
sets up last_location_bookmark and current_location_bookmark
doesn't work right if you do.
yesterday. The largest change was making NautilusDirectory
send "files-changed" signal instead of "files-removed"
signal when a file is removed. That way interested callers
need register only for one signal. The callers can use
nautilus_file_is_gone () to test whether the file was removed.
* libnautilus/nautilus-directory-private.h:
(nautilus_directory_files_removed): Removed function.
* libnautilus/nautilus-directory.h:
(files_removed): Removed signal definition, updated comments.
* libnautilus/nautilus-directory.c:
Removed FILES_REMOVED signal enum entry;
(nautilus_directory_initialize_class): Removed FILES_REMOVED
signal creation.
(nautilus_directory_files_removed): Removed function.
* libnautilus/nautilus-file.c:
(get_file_for_parent_directory): New private function.
(nautilus_file_can_rename): This function was quite broken in
its initial check-in. It worked only on a random basis. Now it
works quite a bit better. It should only return FALSE if it's
darn well sure that the user can't rename the file; it returns
TRUE even if it isn't sure, so clients must handle failed
renames (which they would have to anyway).
(nautilus_file_delete): Call nautilus_file_changed instead of
nautilus_directory_files_removed when file is deleted.
* src/file-manager/fm-directory-view.h:
(remove_file): Remove signal definition, update comments.
* src/file-manager/fm-directory-view.c:
remove REMOVE_FILE signal enum entry;
remove files_removed_handler_id and pending_files_removed from
Details struct;
(fm_directory_view_initialize_class): remove REMOVE_FILE signal
initialization
(display_pending_files): remove "removed" case; made "changed"
case handle updating uri table; made "changed" case send signal
even if file is gone.
(files_removed_cb): Removed function.
(fm_directory_view_load_uri): removed connection to "files_removed"
signal
(disconnect_model_handlers): removed disconnect of files_removed_handler.
* src/file-manager/fm-icon-view.c:
(fm_icon_view_remove_file): Removed function.
(fm_icon_view_initialize_class): Remove remove_file signal handler override.
(fm_icon_view_file_changed): check if file is gone and do what
fm_icon_view_remove_file used to do if so.
* src/file-manager/fm-list-view.c:
(fm_list_view_remove_file): Removed function.
(fm_list_view_initialize_class): Remove remove_file signal handler override.
(fm_list_view_file_changed): check if file is gone and do what
fm_list_view_remove_file used to do if so.
* src/file-manager/fm-properties-window.c:
(properties_window_file_changed_callback): Don't update the window title
if you just nuked the window -- Doh! Now the Properties window will
vanish silently if the file is deleted.