summaryrefslogtreecommitdiff
path: root/gtk/gtkfilesystemmodel.c
Commit message (Collapse)AuthorAgeFilesLines
* Fixes #136082 and #135265, patch by Morten Welinder.Federico Mena Quintero2004-03-061-0/+1
| | | | | | | | | | 2004-03-05 Federico Mena Quintero <federico@ximian.com> Fixes #136082 and #135265, patch by Morten Welinder. * configure.in: Use AC_SYS_LARGEFILE. * */*.c: #include <config.h>
* Simplify semantics and check for errors.Morten Welinder2004-03-011-10/+18
| | | | | | | | | | | | 2004-03-01 Morten Welinder <terra@gnome.org> * gtk/gtkfilesystemmodel.c (file_model_node_is_visible): Simplify semantics and check for errors. * gtk/gtkpathbar.c (gtk_path_bar_set_path): Propagate errors. * gtk/gtkfilefilter.c (gtk_file_filter_filter): Don't crash if display_name is NULL.
* Renamed from create_shortcuts_model(). (struct _GtkFileChooserDefault):Federico Mena Quintero2004-02-251-2/+83
| | | | | | | | | | | | | | | | | | 2004-02-24 Federico Mena Quintero <federico@ximian.com> * gtk/gtkfilechooserdefault.c (shortcuts_model_create): Renamed from create_shortcuts_model(). (struct _GtkFileChooserDefault): Renamed the shortcuts_tree field to shortcuts_list. (shortcuts_list_create): Renamed from shortcuts_tree_create(). (create_file_list): Enable the tree view as a model drag source. (create_folder_tree): Likewise. * gtk/gtkfilesystemmodel.c (_gtk_file_system_model_get_type): Register the drag source interface. (drag_source_iface_init): New function. (drag_source_row_draggable): New function. (drag_source_drag_data_get): New function.
* Add chains to the parent's ::finalize() handler (#134901, Morten Welinder,Matthias Clasen2004-02-221-1/+7
| | | | | | | | | | | | | | | | | | | | Sun Feb 22 03:03:29 2004 Matthias Clasen <maclas@gmx.de> * gtk/gtkaction.c: (gtk_action_finalize): * gtk/gtkclipboard.c: (gtk_clipboard_finalize): * gtk/gtkentrycompletion.c: (gtk_entry_completion_class_init), (gtk_entry_completion_finalize): * gtk/gtkfilechooserwidget.c: (gtk_file_chooser_widget_finalize): * gtk/gtkfilesystemmodel.c: (gtk_file_system_model_class_init), (gtk_file_system_model_finalize): * gtk/gtkicontheme.c: (gtk_icon_theme_class_init), (gtk_icon_theme_finalize): * gtk/gtktextchild.c: (gtk_text_child_anchor_finalize): * gtk/gtkuimanager.c: (gtk_ui_manager_class_init), (gtk_ui_manager_finalize): * modules/input/gtkimcontextxim.c: (gtk_im_context_xim_finalize): Add chains to the parent's ::finalize() handler (#134901, Morten Welinder, patch by Jan Arne Petersen)
* Free the path fields.Federico Mena Quintero2004-01-221-0/+6
| | | | | | | | | | | | | | | | | 2004-01-21 Federico Mena Quintero <federico@ximian.com> * gtk/gtkfilechooserdefault.c (gtk_file_chooser_default_finalize): Free the path fields. * gtk/gtkfilesystemmodel.c (gtk_file_system_model_finalize): Free the root_path, reported by <scott@asofyet.org> (gtk_file_system_model_finalize): Unref the file system. * gtk/gtkfilefilter.c (filter_rule_free): default: g_assert_not_reached(). (gtk_file_filter_finalize): Free the filter->name, reported by <scott@asofyet.org> (gtk_file_filter_finalize): Free the rules list.
* Added a has_editable field. (_gtk_file_system_model_add_editable): NewFederico Mena Quintero2004-01-171-5/+96
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-01-16 Federico Mena Quintero <federico@ximian.com> * gtk/gtkfilesystemmodel.c (struct _GtkFileSystemModel): Added a has_editable field. (_gtk_file_system_model_add_editable): New function. (_gtk_file_system_model_remove_editable): New function. (gtk_file_system_model_get_value): Return appropriate values for the temporary editable row. (_gtk_file_system_model_get_info): Handle the editable row. (_gtk_file_system_model_get_path): Likewise. * gtk/gtkfilechooserdefault.c (shortcuts_append_bookmarks): Removed an unused variable. (toolbar_button_new): Optionally show the button. (up_button_clicked_cb): Renamed from up_button_cb(), fixed prototype. (toolbar_create): Add a "New Folder" button for Save mode. (error_building_filename_dialog): New helper function. (gtk_file_chooser_default_get_paths): Use error_building_filename_dialog(). (create_file_list): Connect to the "edited" signal of the text cell renderer. Store the name column and text renderer in the impl structure. (renderer_edited_cb): New callback. (gtk_file_chooser_default_set_property): Show/hide the "New folder" button when the save action changes. (COMPARE_DIRECTORIES): Allow the info values to be NULL. (COMPARE_DIRECTORIES): Duh, use the list_model, not the tree_model. (get_list_file_info): Likewise! (list_icon_data_func): Handle the path being NULL. (new_folder_button_clicked): New callback. (list_name_data_func): If we are on the editable row, set the text to "Type name of new folder". (list_selection_changed): Handle the editable row. (list_mtime_data_func): Likewise. * gtk/gtkfilesystemunix.c (gtk_file_system_unix_make_path): Return NULL, not FALSE. (gtk_file_system_unix_create_folder): Test the result of mkdir() correctly.
* New get_volume_for_path() method. (struct _GtkFileSystemIface): FinallyFederico Mena Quintero2004-01-161-8/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-01-16 Federico Mena Quintero <federico@ximian.com> * gtk/gtkfilesystem.h (struct _GtkFileSystemIface): New get_volume_for_path() method. (struct _GtkFileSystemIface): Finally removed the list_roots() and get_root_info() methods, and the "roots-changed" signal. * gtk/gtkfilesystem.c (gtk_file_system_get_volume_for_path): New function. (gtk_file_system_list_roots): Removed. (gtk_file_system_get_root_info): Removed. * gtk/gtkfilesystemunix.c (gtk_file_system_unix_get_volume_for_path): Implement. (get_root_volume): New helper function. (gtk_file_system_unix_list_volumes): Use get_root_volume(). (gtk_file_system_unix_list_roots): Removed. (gtk_file_system_unix_get_root_info): Removed. * gtk/gtkfilesystemmodel.c (_gtk_file_system_model_new): Don't accept a NULL root_path. (struct _GtkFileSystemModel): Add a field to remember the root_path. (_gtk_file_system_model_new): Store the root_path in the model structure. (find_and_ref_path): Stop going up the hierarchy at the root_path of the model. Also, don't return prematurely when walking up the hierarchy. * gtk/gtkfilechooserdefault.c (create_file_list): Sigh, restore the rules_hint. (struct _GtkFileChooserDefault): Added a current_volume_path field. (set_tree_model): New function; create the folder tree model here. (create_folder_tree): Don't create the model here. (set_list_model): Set the show_hidden flag on the list model.
* Don't use freed memory. (#127698, Taavi Talvik)Matthias Clasen2003-11-271-2/+3
| | | | | | | Fri Nov 28 00:26:24 2003 Matthias Clasen <maclas@gmx.de> * gtk/gtkfilesystemmodel.c (gtk_file_system_model_finalize): Don't use freed memory. (#127698, Taavi Talvik)
* Add a stock icon to the "Add bookmark" button.Federico Mena Quintero2003-11-031-1/+2
| | | | | | | | | | | | | | 2003-11-03 Federico Mena Quintero <federico@ximian.com> * gtk/gtkfilechooserdefault.c (create_shortcuts_tree): Add a stock icon to the "Add bookmark" button. * gtk/gtkfilesystemunix.c: Mark missing strings for translation. * gtk/gtkfilesystemmodel.c: Likewise. * gtk/gtkfilechooser.c: Likewise. * gtk/gtkfilechooserdefault.c: Likewise. Mon Nov 3 20:56:28 2003 Matthias Clasen <maclas@gmx.de>
* gtk/gtkfilechooserutils.c gtk/gtkfilechooserprivate.[ch]: Basic frameworkOwen Taylor2003-10-231-2/+3
| | | | | | | | | | | | | | | | | | | | | | | 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.
* Free the display_key.Federico Mena Quintero2003-09-091-1/+1
| | | | | | | | | | | | | | | | | | | 2003-09-08 Federico Mena Quintero <federico@ximian.com> * gtkfilesystem.c (gtk_file_info_free): Free the display_key. * gtkfilechooserimpldefault.c (list_mtime_data_func): New function. (create_file_list): Add a modification time column; remove the size column. (mtime_sort_func): New callback. (tree_selection_changed): Add a sorting function for the mtime column. Have the model fetch the modification time as well. (tree_selection_changed): Do allow the file list model to show directories. * testfilechooser.c (my_new_from_file_at_size): Do not try to read non-regular files.
* Return parent path for dummy paths.Owen Taylor2003-07-231-1/+4
| | | | | | | Wed Jul 23 18:43:20 2003 Owen Taylor <otaylor@redhat.com> * gtkfilesystemmodel.c (_gtk_file_system_model_get_path): Return parent path for dummy paths.
* File filter objects.Owen Taylor2003-07-231-19/+43
| | | | | | | | | | | | | | | | | | | | | | | 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.
* Add gtk_file_chooser_set_current_name() to set the current entry contents.Owen Taylor2003-07-111-7/+7
| | | | | | | | | | | | | | 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.
* - Disconnect signal connections when appropriate. - Listen toOwen Taylor2003-04-091-44/+240
| | | | | | | | | | | | | | | | | | | | | Wed Apr 9 12:28:04 2003 Owen Taylor <otaylor@redhat.com> * gtkfilesystemmodel.c: - Disconnect signal connections when appropriate. - Listen to ::roots-changed on the file system - When the last reference count on a child is removed, queue an idle to unload the parent. * gtkfilesystemgnomevfs.c - When URI's outside of file:/// are acessed, add toplevel URI's to the list of roots. - Improve display name computations * gtkfilechooserentry.c: Don't complete on empty file parts; free stored folder when base directory changes. * gtkfilechooser.c: Fill in some docs.
* Move interface definition into a private header so it can refer toOwen Taylor2003-04-041-115/+113
| | | | | | | | | | | | | | 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.
* Finish monitoring, add a TODO, fill in details in README, fix some missing ↵Owen Taylor2003-03-271-60/+234
| | | | finalization chainups
* - Add GnomeVFS backendOwen Taylor2003-03-261-126/+286
| | | | | | - Add gtk_file_info_get_display_key() - Start switching from file_added => files_added - Switch over to Nautilus-like Loading.../Empty
* Make incrememtal searching work, some bug fixesOwen Taylor2003-03-241-2/+13
|
* Add sorting, a size column.Owen Taylor2003-03-211-0/+4
| | | | | | Try making the tree view on the left auto-expand/collapse when the selection changes. Some bug fixes.
* Add some documentation comments, fix some missing staticsOwen Taylor2003-03-211-10/+112
|
* Initial revisionOwen Taylor2003-03-211-0/+1040