1. 06 Mar, 2004 1 commit
  2. 05 Mar, 2004 1 commit
    • Federico Mena Quintero's avatar
      Add gboolean return values and GError arguments to ::set_current_folder() · 385bd6a5
      Federico Mena Quintero authored
      2004-03-05  Federico Mena Quintero  <federico@ximian.com>
      
      	* gtk/gtkfilechooserprivate.h (struct _GtkFileChooserIface): Add
      	gboolean return values and GError arguments to
      	::set_current_folder() and ::select_path().
      
      	* gtk/gtkfilechooser.c (gtk_file_chooser_set_current_folder):
      	Return a boolean value for success/failure.
      	(gtk_file_chooser_set_current_folder_uri): Likewise.
      	(gtk_file_chooser_select_filename): Likewise.
      	(gtk_file_chooser_select_uri): Likewise.
      	(gtk_file_chooser_set_filename): Likewise.
      	(gtk_file_chooser_set_uri): Likewise.
      	(_gtk_file_chooser_set_current_folder_path): Likewise, plus take
      	in a GError.
      	(_gtk_file_chooser_select_path): Likewise.
      
      	* gtk/gtkfilechooserutils.c (delegate_set_current_folder):
      	Likewise.
      	(delegate_select_path): Likewise.
      
      	* gtk/gtkfilechooserdefault.c
      	(gtk_file_chooser_default_select_path): Likewise.
      	(gtk_file_chooser_default_set_current_folder): Likewise.
      	(error_changing_folder_dialog): New helper function.
      	(change_folder_and_display_error): New helper function.
      	(switch_to_selected_folder): Use change_folder_and_display_error().
      	(tree_selection_changed): Likewise.
      	(shortcuts_activate_volume): Likewise.
      	(shortcuts_activate_item): Likewise.
      	(list_row_activated): Likewise.
      	(path_bar_clicked): Likewise.
      	(update_from_entry): Likewise.
      	(up_folder_handler): Likewise.
      	(home_folder_handler): Get the home path from the shortcuts model,
      	and use change_folder_and_display_error().
      
      	* tests/testfilechooser.c (set_current_folder): New helper
      	function; pops up a simple error dialog if necessary.
      	(set_filename): Likewise.
      	(set_folder_nonexistent_cb): Use set_current_folder().
      	(set_folder_existing_nonexistent_cb): Likewise.
      	(set_filename_nonexistent_cb): Use set_filename().
      	(set_filename_existing_nonexistent_cb): Likewise.
      385bd6a5
  3. 29 Feb, 2004 1 commit
    • Federico Mena Quintero's avatar
      Handle GTK_FILE_CHOOSER_PROP_USE_PREVIEW_LABEL. · 17e840f7
      Federico Mena Quintero authored
      2004-02-29  Federico Mena Quintero  <federico@ximian.com>
      
      	* gtk/gtkfilechooserdefault.c
      	(gtk_file_chooser_default_set_property): Handle
      	GTK_FILE_CHOOSER_PROP_USE_PREVIEW_LABEL.
      	(gtk_file_chooser_default_get_property): Likewise.
      	(struct _GtkFileChooserDefault): Added fields for preview_label,
      	use_preview_label, preview_display_name, preview_box.  Removed
      	preview_frame.
      	(set_preview_widget): Reorder the widget in relation to the label.
      	(update_preview_widget_visibility): Create or destroy the preview
      	label.
      	(check_preview_change): Update impl->preview_display_name and the
      	label.
      	(find_good_size_from_style): Use the preview_box.
      	(gtk_file_chooser_default_finalize): Free
      	impl->preview_display_name.
      	(gtk_file_chooser_default_init): Initialize
      	impl->use_preview_label.
      
      	* gtk/gtkfilechooser.c (gtk_file_chooser_class_init): Add a
      	"use-preview-label" property.
      	(gtk_file_chooser_set_use_preview_label): New function.  This sets
      	whether one wants the file chooser to display a stock label with
      	the previewed filename.  Apps that do really fancy previews can
      	turn this off and draw the name themselves.
      	(gtk_file_chooser_get_use_preview_label): New function.
      	(gtk_file_chooser_get_preview_widget_active): Documentation fix.
      
      	* gtk/gtkfilechooserutils.h (GtkFileChooserProp): Add a
      	GTK_FILE_CHOOSER_PROP_USE_PREVIEW_LABEL value.
      
      	* gtk/gtkfilechooserutils.c
      	(_gtk_file_chooser_install_properties): Override the
      	"use-preview-label" property.
      17e840f7
  4. 27 Feb, 2004 1 commit
    • Jonathan Blandford's avatar
      remove folder-mode property. · 528b02a8
      Jonathan Blandford authored
      Fri Feb 27 15:06:00 2004  Jonathan Blandford  <jrb@redhat.com>
      
              * gtk/gtkfilechooser.c (gtk_file_chooser_class_init): remove
              folder-mode property.
      
              * gtk/gtkfilechooserutils.c
              (_gtk_file_chooser_install_properties): remove FOLDER_MODE property.
      528b02a8
  5. 19 Feb, 2004 1 commit
    • Alexander Larsson's avatar
      Remove old file-system property. Add new file-system-backend string · 824548f1
      Alexander Larsson authored
      2004-02-19  Alexander Larsson  <alexl@redhat.com>
      
      	* gtk/gtkfilechooser.c: (gtk_file_chooser_class_init):
      	* gtk/gtkfilechooserutils.c:
      	* gtk/gtkfilechooserutils.h:
      	* gtk/gtkfilechooserwidget.c:
      	Remove old file-system property.
      	Add new file-system-backend string property
      
      	* gtk/gtkfilechooserdefault.[ch]:
      	Handle the file-system-backend property
      
      	* gtk/gtkfilechooserdialog.[ch]:
      	(gtk_file_chooser_dialog_new_with_backend):
      	Remove old file-system property.
      	Add new file-system-backend string property
      	Add new function gtk_file_chooser_dialog_new_with_backend
      
      	* gtk/gtkfilesystem.c:
      	* gtk/gtkfilesystem.h:
      	Add filesystem module support.
      824548f1
  6. 29 Oct, 2003 1 commit
  7. 23 Oct, 2003 1 commit
    • Owen Taylor's avatar
      gtk/gtkfilechooserutils.c gtk/gtkfilechooserprivate.[ch]: Basic framework · b3bae3b4
      Owen Taylor authored
      Wed Oct 22 23:20:04 2003  Owen Taylor  <otaylor@redhat.com>
      
              * gtk/gtkfilechooser.[ch] gtk/gtkfilefilter.[ch]
              gtk/gtkfilechooserwidget.[ch] gtk/gtkfilechooserdialog.[ch]:
              gtk/gtkfilechooserutils.c gtk/gtkfilechooserprivate.[ch]:
              Basic framework for the new file selector widget.
      
              * gtk/gtkfilechooserdefault.[ch] gtk/gtkcellrenderersep.[ch]
              gtk/gtkfilechooserentry.[ch] gtk/gtkfilesystemmodel.[ch]:
              Initial implementation of the GtkFileChooser user interface.
      
              * gtk/gtkfilesystemunix.[ch]: GtkFileSystem implementation
              for Unix files.
      
              * configure.in gtk/Makefile.am gtk/xdgmime: Build code
              for freedesktop.org MIME system on Unix.
      
              * tests/testfilechooser.c: Test program for GtkFileChooser
      
              * tests/prop-editor.c: Add support for properties on interfaces.
      b3bae3b4
  8. 18 Oct, 2003 1 commit
    • Federico Mena Quintero's avatar
      Removed. (gtk_file_system_gnome_vfs_set_bookmarks): Removed. · b49a5ec5
      Federico Mena Quintero authored
      2003-10-17  Federico Mena Quintero  <federico@ximian.com>
      
      	* gtkfilesystemgnomevfs.c
      	(gtk_file_system_gnome_vfs_get_supports_bookmarks): Removed.
      	(gtk_file_system_gnome_vfs_set_bookmarks): Removed.
      	(gtk_file_system_gnome_vfs_add_bookmark): Implement.
      	(gtk_file_system_gnome_vfs_remove_bookmark): Implement.
      
      	* gtkfilechooserprivate.h (struct _GtkFileChooserIface): Replaced
      	the ::set_shortcut_folders() method with :;add_shortcut_folder()
      	and ::remove_shortcut_folder().
      
      	* gtkfilechooserutils.c (delegate_add_shortcut_folder): New function.
      	(delegate_remove_shortcut_folder): New function.
      	(delegate_list_shortcut_folders): New function.
      
      	* gtkfilechooserimpldefault.c (create_shortcuts_model): Insert the
      	Desktop directory as well.
      	(shortcuts_insert_path): Renamed from shortcuts_append_path; now
      	takes a position index instead of a parent node iter.  Also takes
      	a GError argument.
      	(struct _GtkFileChooserImplDefault): Removed the shortcuts_folder
      	list.  It is all kept in the model now.
      	(shortcuts_append_home): Save whether adding a shortcut for the
      	home directory was successful.
      	(shortcuts_append_desktop): Likewise for the desktop.
      	(shortcuts_append_file_system_roots): Count and save the number of
      	roots added.
      	(shortcuts_append_shortcut_folders): Removed.
      	(gtk_file_chooser_impl_default_add_shortcut_folder): Implement.
      	(shortcuts_append_bookmarks): Now that we don't have a bookmarks
      	parent node, don't expand the tree.
      	(add_bookmark_button_clicked_cb): Use gtk_file_system_add_bookmark().
      	(remove_bookmark_button_clicked_cb): Use gtk_file_system_remove_bookmark().
      	(gtk_file_chooser_impl_default_list_shortcut_folders): Get the
      	folders from the shortcuts model; we no longer keep a separate list.
      
      	* gtkfilesystem.h (struct _GtkFileSystemIface): Oops, there
      	shouldn't be shortcuts-related virtual methods here.
      
      	* gtkfilechooser.c (file_paths_to_strings): New helper function.
      	(gtk_file_chooser_get_filenames): Use file_paths_to_strings().
      	(gtk_file_chooser_get_uris): Likewise.
      	(gtk_file_chooser_set_shortcut_folders): Removed.
      	(gtk_file_chooser_list_shortcut_folders): Return a list of
      	strings, not of GtkFilePath*.
      	(gtk_file_chooser_list_shortcut_folder_uris): New function.
      	(gtk_file_chooser_add_shortcut_folder): New function.
      	(gtk_file_chooser_remove_shortcut_folder): New function.
      	(gtk_file_chooser_add_shortcut_folder_uri): New function.
      	(gtk_file_chooser_remove_shortcut_folder_uri): New function.
      	(_gtk_file_chooser_add_shortcut_folder): New function.
      	(_gtk_file_chooser_remove_shortcut_folder): New function.
      
      	* gtkfilechooser.h: New enum.
      
      	* gtkfilechooser.c (gtk_file_chooser_error_quark): New function.
      
      	* gtkfilesystem.c (gtk_file_system_get_supports_bookmarks): Removed.
      	(gtk_file_system_set_bookmarks): Removed.
      	(gtk_file_system_add_bookmark): New function.
      	(gtk_file_system_remove_bookmark): New function.
      
      	* gtkfilesystemunix.c
      	(gtk_file_system_unix_get_supports_bookmarks): Removed.
      	(gtk_file_system_unix_set_bookmarks): Removed.
      	(gtk_file_system_unix_add_bookmark): Just a stub for now.
      	(gtk_file_system_unix_remove_bookmark): Likewise.
      
      	* testfilechooser.c (main): Add a shortcut for testing purposes.
      b49a5ec5
  9. 11 Sep, 2003 1 commit
    • Federico Mena Quintero's avatar
      Connect to "row_activated" on the file list. (list_row_activated): New · aa22566e
      Federico Mena Quintero authored
      2003-09-10  Federico Mena Quintero  <federico@ximian.com>
      
      	* gtkfilechooserimpldefault.c (create_file_list): Connect to
      	"row_activated" on the file list.
      	(list_row_activated): New function.  Changes to folders or emits
      	the "file-activated" signal depending on what type of row was
      	activated.
      	(create_folder_tree): Renamed from create_directory_tree(), since
      	"folder" is the new politically-correct name.
      
      	* gtkfilechooserprivate.h (struct _GtkFileChooserIface): Added a
      	file-activated signal.
      
      	* gtkfilechooser.c (gtk_file_chooser_class_init): Register the
      	signal.
      
      	* gtkfilechooserutils.c (_gtk_file_chooser_set_delegate): Connect
      	to "file-activated" on the delegate.
      	(delegate_file_activated): New function.
      
      	* TODO: Added an API item about Clipart-like folders provided by
      	applications.
      aa22566e
  10. 03 Sep, 2003 2 commits
    • Owen Taylor's avatar
      Update. · a653ea3a
      Owen Taylor authored
      Wed Sep  3 15:32:26 2003  Owen Taylor  <otaylor@redhat.com>
      
              * glib-interface-propreties-{0.4,0.5}.patch: Update.
      
              * gtkfilechooserutils.c prop-editor.c: Update for
              newer interface-properties API.
      a653ea3a
    • Federico Mena Quintero's avatar
      Removed the "extra widget" bit, implemented with the following: · 36dfea8e
      Federico Mena Quintero authored
      2003-09-03  Federico Mena Quintero  <federico@ximian.com>
      
      	* TODO: Removed the "extra widget" bit, implemented with the
      	following:
      
      	* gtkfilechooser.h: Added gtk_file_chooser_{set,get}_extra_widget().
      
      	* gtkfilechooser.c (gtk_file_chooser_base_init): Install an
      	"extra-widget" interface property.
      	(gtk_file_chooser_set_extra_widget): Implemented.
      	(gtk_file_chooser_get_extra_widget): Implemented.
      
      	* gtkfilechooserutils.h (GtkFileChooserProp): Added
      	GTK_FILE_CHOOSER_PROP_EXTRA_WIDGET.
      
      	* gtkfilechooserutils.c (_gtk_file_chooser_install_properties):
      	Added the "extra-widget" property.
      
      	* gtkfilechooserimpldefault.c (struct _GtkFileChooserImplDefault):
      	Added an extra_widget field.
      	(gtk_file_chooser_impl_default_set_property): Handle the
      	"extra-widget" property.
      	(gtk_file_chooser_impl_default_get_property): Likewise.
      	(set_preview_widget): Fix the call gtk_container_remove().  Also,
      	we don't need to ref/sink/unref the preview widget, as that gets
      	already done by container_add/remove.
      	(set_extra_widget): New utility function.
      
      	* testfilechooser.c (main): Add an extra widget.
      36dfea8e
  11. 23 Jul, 2003 2 commits
    • Owen Taylor's avatar
      Add over-big test case for preview (much of size from a modified copy of · d97d7df9
      Owen Taylor authored
      Wed Jul 23 17:52:01 2003  Owen Taylor  <otaylor@redhat.com>
      
              * testfilechooser.c: Add over-big test case for preview
              (much of size from a modified copy of
              gdk_pixbuf_new_from_file_at_size())
      
              * gtkfilechooserutils.[ch] gtkfilechooser.c
              gtkfilechooserprivate.h gtkfilechooserimpldefault.c:
              Add get_preview_path() as a virtual function; implement
              update-preview signal that was in the header file.
      
              * gtkfilechooserimpldefault.c: Finish a simple preview
              widget implementation.
      d97d7df9
    • Owen Taylor's avatar
      File filter objects. · 733f4489
      Owen Taylor authored
      Wed Jul 23 11:23:43 2003  Owen Taylor  <otaylor@redhat.com>
      
              * gtkfilefilter.[ch]: File filter objects.
      
              * gtkfilechooser.[ch] gtkfilechooserutils.[ch]: Add
              file filtering to API.
      
              * gtkfilechooserimpldefault.c: Implement file filters.
      
              * testfilechooser.c: Try out the filter functionality.
      
              * gtkfilesystemmodel.c: Add
              _gtk_file_system_model_set_filter() to set a callback
              function for filtering.
      
              * gtkfilechooserutils.c: Propagate property notification
              to the receiver.
      
              * fnmatch.c: Copy this from GTK+ temporarily to get
              UTF-8 pattern matching functionality.
      733f4489
  12. 11 Jul, 2003 1 commit
    • Owen Taylor's avatar
      Add gtk_file_chooser_set_current_name() to set the current entry contents. · 7f8ae32c
      Owen Taylor authored
      Fri Jul 11 14:37:07 2003  Owen Taylor  <otaylor@redhat.com>
      
              * gtkfilechooser.[ch] gtkfilechooserprivate.h
              gtkfilechooserimpldefault.c: Add
              gtk_file_chooser_set_current_name() to set the current
              entry contents.
      
              * *.c: Consistently use '-' not '_' in property names and
              signal names.
      
              * gtkfilechooser.c: Document all exported functions.
      7f8ae32c
  13. 04 Apr, 2003 1 commit
    • Owen Taylor's avatar
      Move interface definition into a private header so it can refer to · bc3fb55c
      Owen Taylor authored
      Fri Apr  4 17:30:27 2003  Owen Taylor  <otaylor@redhat.com>
      
              * gtkfilechooserprivate.h gtkfilechooser.h: Move
              interface definition into a private header so it
              can refer to GtkFileSystem.
      
              * *.[ch]: Switch over from using gchar *uri internally
              to using GtkFilePath * internally, and add
              conversion routines to GtkFileSystem.
      
              * TODO README: Updates.
      bc3fb55c
  14. 26 Mar, 2003 1 commit
  15. 21 Mar, 2003 2 commits