summaryrefslogtreecommitdiff
path: root/meta
diff options
context:
space:
mode:
Diffstat (limited to 'meta')
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/automake-lossage.patch24
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/combo-arrow-size.patch67
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/disable-tooltips.patch11
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/filechooser-default.patch4609
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/filechooser-respect-style.patch77
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/filesystem-volumes.patch182
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/gtk+-handhelds.patch236
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/gtklabel-resize-patch10
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/hardcoded_libtool.patch29
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/menu-deactivate.patch50
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/no-demos.patch10
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/no-xwc.patch151
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/range-no-redraw.patch18
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/scroll-timings.patch15
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/smaller-filechooser.patch47
-rw-r--r--meta/packages/gtk+/gtk+-2.6.10/toggle-font.diff69
-rw-r--r--meta/packages/gtk+/gtk+_2.6.10.bb54
17 files changed, 0 insertions, 5659 deletions
diff --git a/meta/packages/gtk+/gtk+-2.6.10/automake-lossage.patch b/meta/packages/gtk+/gtk+-2.6.10/automake-lossage.patch
deleted file mode 100644
index 0d423ddbb..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/automake-lossage.patch
+++ /dev/null
@@ -1,24 +0,0 @@
---- gtk+-2.4.1/docs/tutorial/Makefile.am~ 2003-05-06 22:54:20.000000000 +0100
-+++ gtk+-2.4.1/docs/tutorial/Makefile.am 2004-05-08 12:31:41.000000000 +0100
-@@ -52,21 +52,5 @@
-
- dist-hook: html
- cp -Rp $(srcdir)/html $(distdir)
--else
--html:
-- echo "***"
-- echo "*** Warning: Tutorial not built"
-- echo "***"
--
--pdf:
-- echo "***"
-- echo "*** Warning: Tutorial not built"
-- echo "***"
--
--dist-hook:
-- echo "***"
-- echo "*** Warning: Tutorial not built"
-- echo "*** DISTRIBUTION IS INCOMPLETE"
-- echo "***"
- endif
-
diff --git a/meta/packages/gtk+/gtk+-2.6.10/combo-arrow-size.patch b/meta/packages/gtk+/gtk+-2.6.10/combo-arrow-size.patch
deleted file mode 100644
index aecbd4366..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/combo-arrow-size.patch
+++ /dev/null
@@ -1,67 +0,0 @@
-Index: gtk/gtkcombobox.c
-===================================================================
-RCS file: /cvs/gnome/gtk+/gtk/gtkcombobox.c,v
-retrieving revision 1.185
-diff -u -p -r1.185 gtkcombobox.c
---- gtk/gtkcombobox.c 12 Oct 2006 13:48:07 -0000 1.185
-+++ gtk/gtkcombobox.c 1 Nov 2006 19:01:09 -0000
-@@ -756,6 +756,25 @@ gtk_combo_box_class_init (GtkComboBoxCla
- FALSE,
- GTK_PARAM_READABLE));
-
-+ /**
-+ * GtkComboBox:arrow-size:
-+ *
-+ * Sets the minimum size of the arrow in the combo box. Note
-+ * that the arrow size is coupled to the font size, so in case
-+ * a larger font is used, the arrow will be larger than set
-+ * by arrow size.
-+ *
-+ * Since: 2.12
-+ */
-+ gtk_widget_class_install_style_property (widget_class,
-+ g_param_spec_int ("arrow-size",
-+ P_("Arrow Size"),
-+ P_("The minimum size of the arrow in the combo box"),
-+ 0,
-+ G_MAXINT,
-+ 15,
-+ G_PARAM_READABLE));
-+
- g_type_class_add_private (object_class, sizeof (GtkComboBoxPrivate));
- }
-
-@@ -1897,7 +1916,12 @@ gtk_combo_box_size_request (GtkWidget
- {
- gint width, height;
- gint focus_width, focus_pad;
-+ gint font_size;
-+ gint arrow_size;
- GtkRequisition bin_req;
-+ PangoContext *context;
-+ PangoFontMetrics *metrics;
-+ PangoFontDescription *font_desc;
-
- GtkComboBox *combo_box = GTK_COMBO_BOX (widget);
-
-@@ -1910,7 +1934,20 @@ gtk_combo_box_size_request (GtkWidget
- gtk_widget_style_get (GTK_WIDGET (widget),
- "focus-line-width", &focus_width,
- "focus-padding", &focus_pad,
-+ "arrow-size", &arrow_size,
- NULL);
-+
-+ font_desc = GTK_BIN (widget)->child->style->font_desc;
-+ context = gtk_widget_get_pango_context (widget);
-+ metrics = pango_context_get_metrics (context, font_desc,
-+ pango_context_get_language (context));
-+ font_size = PANGO_PIXELS (pango_font_metrics_get_ascent (metrics) +
-+ pango_font_metrics_get_descent (metrics));
-+ pango_font_metrics_unref (metrics);
-+
-+ arrow_size = MAX (arrow_size, font_size);
-+
-+ gtk_widget_set_size_request (combo_box->priv->arrow, arrow_size, arrow_size);
-
- if (!combo_box->priv->tree_view)
- {
diff --git a/meta/packages/gtk+/gtk+-2.6.10/disable-tooltips.patch b/meta/packages/gtk+/gtk+-2.6.10/disable-tooltips.patch
deleted file mode 100644
index d71d839c3..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/disable-tooltips.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- gtk+-2.4.3/gtk/gtktooltips.c.old 2004-07-04 18:52:04.000000000 +0100
-+++ gtk+-2.4.3/gtk/gtktooltips.c 2004-07-04 18:52:08.000000000 +0100
-@@ -118,7 +118,7 @@
- tooltips->tips_data_list = NULL;
-
- tooltips->delay = DEFAULT_DELAY;
-- tooltips->enabled = TRUE;
-+ tooltips->enabled = FALSE;
- tooltips->timer_tag = 0;
- tooltips->use_sticky_delay = FALSE;
- tooltips->last_popdown.tv_sec = -1;
diff --git a/meta/packages/gtk+/gtk+-2.6.10/filechooser-default.patch b/meta/packages/gtk+/gtk+-2.6.10/filechooser-default.patch
deleted file mode 100644
index 46931f7de..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/filechooser-default.patch
+++ /dev/null
@@ -1,4609 +0,0 @@
----
- gtk/gtkfilechooserdefault.c | 3689 ++++----------------------------------------
- 1 file changed, 415 insertions(+), 3274 deletions(-)
-
-Index: gtk+-2.6.10/gtk/gtkfilechooserdefault.c
-===================================================================
---- gtk+-2.6.10.orig/gtk/gtkfilechooserdefault.c 2007-06-08 09:29:24.000000000 +0100
-+++ gtk+-2.6.10/gtk/gtkfilechooserdefault.c 2007-06-08 11:08:41.000000000 +0100
-@@ -31,7 +31,6 @@
- #include "gtkcombobox.h"
- #include "gtkentry.h"
- #include "gtkeventbox.h"
--#include "gtkexpander.h"
- #include "gtkfilechooserdefault.h"
- #include "gtkfilechooserembed.h"
- #include "gtkfilechooserentry.h"
-@@ -50,7 +49,6 @@
- #include "gtkmarshalers.h"
- #include "gtkmenuitem.h"
- #include "gtkmessagedialog.h"
--#include "gtkpathbar.h"
- #include "gtkprivate.h"
- #include "gtkscrolledwindow.h"
- #include "gtkseparatormenuitem.h"
-@@ -79,18 +77,23 @@
- #include <string.h>
- #include <time.h>
-
-+#define DEFAULT_SPACING 5
-+
-+#define GTK26
- typedef struct _GtkFileChooserDefaultClass GtkFileChooserDefaultClass;
-
- #define GTK_FILE_CHOOSER_DEFAULT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GTK_TYPE_FILE_CHOOSER_DEFAULT, GtkFileChooserDefaultClass))
- #define GTK_IS_FILE_CHOOSER_DEFAULT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GTK_TYPE_FILE_CHOOSER_DEFAULT))
- #define GTK_FILE_CHOOSER_DEFAULT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GTK_TYPE_FILE_CHOOSER_DEFAULT, GtkFileChooserDefaultClass))
-
-+#ifdef GTK26
- typedef enum {
- LOAD_EMPTY, /* There is no model */
- LOAD_PRELOAD, /* Model is loading and a timer is running; model isn't inserted into the tree yet */
- LOAD_LOADING, /* Timeout expired, model is inserted into the tree, but not fully loaded yet */
- LOAD_FINISHED /* Model is fully loaded and inserted into the tree */
- } LoadState;
-+#endif
-
- #define MAX_LOADING_TIME 500
-
-@@ -109,63 +112,38 @@ struct _GtkFileChooserDefault
-
- /* Save mode widgets */
- GtkWidget *save_widgets;
--
- GtkWidget *save_file_name_entry;
-- GtkWidget *save_folder_label;
-- GtkWidget *save_folder_combo;
-- GtkWidget *save_expander;
-
- /* The file browsing widgets */
- GtkWidget *browse_widgets;
-- GtkWidget *browse_shortcuts_tree_view;
-- GtkWidget *browse_shortcuts_add_button;
-- GtkWidget *browse_shortcuts_remove_button;
- GtkWidget *browse_files_tree_view;
-- GtkWidget *browse_files_popup_menu;
-- GtkWidget *browse_files_popup_menu_add_shortcut_item;
-- GtkWidget *browse_files_popup_menu_hidden_files_item;
- GtkWidget *browse_new_folder_button;
-- GtkWidget *browse_path_bar;
--
-+ GtkWidget *bar;
-+ GtkWidget * up_button;
-+
- GtkFileSystemModel *browse_files_model;
-
-- GtkWidget *filter_combo_hbox;
- GtkWidget *filter_combo;
-- GtkWidget *preview_box;
-- GtkWidget *preview_label;
-- GtkWidget *preview_widget;
-- GtkWidget *extra_align;
-- GtkWidget *extra_widget;
--
-- GtkListStore *shortcuts_model;
-- GtkTreeModel *shortcuts_filter_model;
--
-+
- GtkTreeModelSort *sort_model;
-
- LoadState load_state;
- guint load_timeout_id;
-
- GSList *pending_select_paths;
--
-+ GSList * path_history;
-+
- GtkFileFilter *current_filter;
- GSList *filters;
-
- GtkTooltips *tooltips;
-
-- gboolean has_home;
-- gboolean has_desktop;
--
- int num_volumes;
-- int num_shortcuts;
-- int num_bookmarks;
-
- gulong volumes_changed_id;
-- gulong bookmarks_changed_id;
-
- GtkFilePath *current_volume_path;
- GtkFilePath *current_folder;
-- GtkFilePath *preview_path;
-- char *preview_display_name;
-
- GtkTreeViewColumn *list_name_column;
- GtkCellRenderer *list_name_renderer;
-@@ -179,25 +157,15 @@ struct _GtkFileChooserDefault
- gulong toplevel_set_focus_id;
- GtkWidget *toplevel_last_focus_widget;
-
--#if 0
-- GdkDragContext *shortcuts_drag_context;
-- GSource *shortcuts_drag_outside_idle;
--#endif
--
-+ gchar * root_folder;
-+
- /* Flags */
-
- guint local_only : 1;
-- guint preview_widget_active : 1;
-- guint use_preview_label : 1;
- guint select_multiple : 1;
- guint show_hidden : 1;
- guint list_sort_ascending : 1;
- guint changing_folder : 1;
-- guint shortcuts_current_folder_active : 1;
--
--#if 0
-- guint shortcuts_drag_outside : 1;
--#endif
- };
-
- /* Signal IDs */
-@@ -211,17 +179,6 @@ enum {
-
- static guint signals[LAST_SIGNAL] = { 0 };
-
--/* Column numbers for the shortcuts tree. Keep these in sync with shortcuts_model_create() */
--enum {
-- SHORTCUTS_COL_PIXBUF,
-- SHORTCUTS_COL_NAME,
-- SHORTCUTS_COL_DATA,
-- SHORTCUTS_COL_IS_VOLUME,
-- SHORTCUTS_COL_REMOVABLE,
-- SHORTCUTS_COL_PIXBUF_VISIBLE,
-- SHORTCUTS_COL_NUM_COLUMNS
--};
--
- /* Column numbers for the file list */
- enum {
- FILE_LIST_COL_NAME,
-@@ -236,23 +193,6 @@ enum {
- TEXT_URI_LIST
- };
-
--/* Target types for dragging from the shortcuts list */
--static const GtkTargetEntry shortcuts_source_targets[] = {
-- { "GTK_TREE_MODEL_ROW", GTK_TARGET_SAME_WIDGET, GTK_TREE_MODEL_ROW }
--};
--
--static const int num_shortcuts_source_targets = (sizeof (shortcuts_source_targets)
-- / sizeof (shortcuts_source_targets[0]));
--
--/* Target types for dropping into the shortcuts list */
--static const GtkTargetEntry shortcuts_dest_targets[] = {
-- { "GTK_TREE_MODEL_ROW", GTK_TARGET_SAME_WIDGET, GTK_TREE_MODEL_ROW },
-- { "text/uri-list", 0, TEXT_URI_LIST }
--};
--
--static const int num_shortcuts_dest_targets = (sizeof (shortcuts_dest_targets)
-- / sizeof (shortcuts_dest_targets[0]));
--
- /* Target types for DnD from the file list */
- static const GtkTargetEntry file_list_source_targets[] = {
- { "text/uri-list", 0, TEXT_URI_LIST }
-@@ -270,22 +210,10 @@ static const int num_file_list_dest_targ
- / sizeof (file_list_dest_targets[0]));
-
-
--/* Interesting places in the shortcuts bar */
--typedef enum {
-- SHORTCUTS_HOME,
-- SHORTCUTS_DESKTOP,
-- SHORTCUTS_VOLUMES,
-- SHORTCUTS_SHORTCUTS,
-- SHORTCUTS_BOOKMARKS_SEPARATOR,
-- SHORTCUTS_BOOKMARKS,
-- SHORTCUTS_CURRENT_FOLDER_SEPARATOR,
-- SHORTCUTS_CURRENT_FOLDER
--} ShortcutsIndex;
--
- /* Icon size for if we can't get it from the theme */
- #define FALLBACK_ICON_SIZE 16
-
--#define PREVIEW_HBOX_SPACING 12
-+#define LIST_HBOX_SPACING DEFAULT_SPACING
- #define NUM_LINES 40
- #define NUM_CHARS 60
-
-@@ -348,7 +276,6 @@ static gboolean gtk_file_chooser_d
- const GtkFilePath *path,
- GError **error);
- static GSList * gtk_file_chooser_default_list_shortcut_folders (GtkFileChooser *chooser);
--
- static void gtk_file_chooser_default_get_default_size (GtkFileChooserEmbed *chooser_embed,
- gint *default_width,
- gint *default_height);
-@@ -365,37 +292,11 @@ static void down_folder_handler (GtkF
- static void home_folder_handler (GtkFileChooserDefault *impl);
- static void update_appearance (GtkFileChooserDefault *impl);
-
--static void set_current_filter (GtkFileChooserDefault *impl,
-- GtkFileFilter *filter);
--static void check_preview_change (GtkFileChooserDefault *impl);
--
- static void filter_combo_changed (GtkComboBox *combo_box,
- GtkFileChooserDefault *impl);
--static void shortcuts_row_activated_cb (GtkTreeView *tree_view,
-- GtkTreePath *path,
-- GtkTreeViewColumn *column,
-- GtkFileChooserDefault *impl);
--
--static gboolean shortcuts_key_press_event_cb (GtkWidget *widget,
-- GdkEventKey *event,
-- GtkFileChooserDefault *impl);
--
--static gboolean shortcuts_select_func (GtkTreeSelection *selection,
-- GtkTreeModel *model,
-- GtkTreePath *path,
-- gboolean path_currently_selected,
-- gpointer data);
--static gboolean shortcuts_get_selected (GtkFileChooserDefault *impl,
-- GtkTreeIter *iter);
--static void shortcuts_activate_iter (GtkFileChooserDefault *impl,
-- GtkTreeIter *iter);
--static int shortcuts_get_index (GtkFileChooserDefault *impl,
-- ShortcutsIndex where);
--static int shortcut_find_position (GtkFileChooserDefault *impl,
-- const GtkFilePath *path);
--
--static void bookmarks_check_add_sensitivity (GtkFileChooserDefault *impl);
-
-+static void set_current_filter (GtkFileChooserDefault *impl,
-+ GtkFileFilter *filter);
- static gboolean list_select_func (GtkTreeSelection *selection,
- GtkTreeModel *model,
- GtkTreePath *path,
-@@ -414,16 +315,6 @@ static void select_func (GtkFileSystemMo
- GtkTreeIter *iter,
- gpointer user_data);
-
--static void path_bar_clicked (GtkPathBar *path_bar,
-- GtkFilePath *file_path,
-- gboolean child_is_hidden,
-- GtkFileChooserDefault *impl);
--
--static void add_bookmark_button_clicked_cb (GtkButton *button,
-- GtkFileChooserDefault *impl);
--static void remove_bookmark_button_clicked_cb (GtkButton *button,
-- GtkFileChooserDefault *impl);
--
- static void list_icon_data_func (GtkTreeViewColumn *tree_column,
- GtkCellRenderer *cell,
- GtkTreeModel *tree_model,
-@@ -455,36 +346,6 @@ static void browse_files_center_selected
-
- static GObjectClass *parent_class;
-
--
--
--/* Drag and drop interface declarations */
--
--typedef struct {
-- GtkTreeModelFilter parent;
--
-- GtkFileChooserDefault *impl;
--} ShortcutsModelFilter;
--
--typedef struct {
-- GtkTreeModelFilterClass parent_class;
--} ShortcutsModelFilterClass;
--
--#define SHORTCUTS_MODEL_FILTER_TYPE (_shortcuts_model_filter_get_type ())
--#define SHORTCUTS_MODEL_FILTER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SHORTCUTS_MODEL_FILTER_TYPE, ShortcutsModelFilter))
--
--static void shortcuts_model_filter_drag_source_iface_init (GtkTreeDragSourceIface *iface);
--
--G_DEFINE_TYPE_WITH_CODE (ShortcutsModelFilter,
-- _shortcuts_model_filter,
-- GTK_TYPE_TREE_MODEL_FILTER,
-- G_IMPLEMENT_INTERFACE (GTK_TYPE_TREE_DRAG_SOURCE,
-- shortcuts_model_filter_drag_source_iface_init));
--
--static GtkTreeModel *shortcuts_model_filter_new (GtkFileChooserDefault *impl,
-- GtkTreeModel *child_model,
-- GtkTreePath *root);
--
--
-
- GType
- _gtk_file_chooser_default_get_type (void)
-@@ -534,6 +395,11 @@ _gtk_file_chooser_default_get_type (void
- return file_chooser_default_type;
- }
-
-+enum
-+{
-+ GTK_FILE_CHOOSER_PROP_ROOT_FOLDER = GTK_FILE_CHOOSER_PROP_LAST + 1,
-+};
-+
- static void
- gtk_file_chooser_default_class_init (GtkFileChooserDefaultClass *class)
- {
-@@ -631,6 +497,14 @@ gtk_file_chooser_default_class_init (Gtk
- "home-folder",
- 0);
-
-+ g_object_class_install_property (gobject_class,
-+ GTK_FILE_CHOOSER_PROP_ROOT_FOLDER,
-+ g_param_spec_string ("root-folder",
-+ P_("File System Root"),
-+ P_("Root folder for the file system below which the user should not be able to switch"),
-+ NULL,
-+ G_PARAM_WRITABLE));
-+
- _gtk_file_chooser_install_properties (gobject_class);
-
- gtk_settings_install_property (g_param_spec_string ("gtk-file-chooser-backend",
-@@ -648,7 +522,6 @@ gtk_file_chooser_default_iface_init (Gtk
- iface->select_all = gtk_file_chooser_default_select_all;
- iface->unselect_all = gtk_file_chooser_default_unselect_all;
- iface->get_paths = gtk_file_chooser_default_get_paths;
-- iface->get_preview_path = gtk_file_chooser_default_get_preview_path;
- iface->get_file_system = gtk_file_chooser_default_get_file_system;
- iface->set_current_folder = gtk_file_chooser_default_set_current_folder;
- iface->get_current_folder = gtk_file_chooser_default_get_current_folder;
-@@ -656,9 +529,12 @@ gtk_file_chooser_default_iface_init (Gtk
- iface->add_filter = gtk_file_chooser_default_add_filter;
- iface->remove_filter = gtk_file_chooser_default_remove_filter;
- iface->list_filters = gtk_file_chooser_default_list_filters;
-+
-+ /* these are only stubs */
-+ iface->get_preview_path = gtk_file_chooser_default_get_preview_path;
- iface->add_shortcut_folder = gtk_file_chooser_default_add_shortcut_folder;
- iface->remove_shortcut_folder = gtk_file_chooser_default_remove_shortcut_folder;
-- iface->list_shortcut_folders = gtk_file_chooser_default_list_shortcut_folders;
-+
- }
-
- static void
-@@ -673,71 +549,22 @@ static void
- gtk_file_chooser_default_init (GtkFileChooserDefault *impl)
- {
- impl->local_only = TRUE;
-- impl->preview_widget_active = TRUE;
-- impl->use_preview_label = TRUE;
- impl->select_multiple = FALSE;
- impl->show_hidden = FALSE;
- impl->icon_size = FALLBACK_ICON_SIZE;
- impl->load_state = LOAD_EMPTY;
- impl->pending_select_paths = NULL;
--
-+ impl->path_history = NULL;
-+
- gtk_widget_set_redraw_on_allocate (GTK_WIDGET (impl), TRUE);
-- gtk_box_set_spacing (GTK_BOX (impl), 12);
-+ gtk_box_set_spacing (GTK_BOX (impl), DEFAULT_SPACING);
-
- impl->tooltips = gtk_tooltips_new ();
- g_object_ref (impl->tooltips);
- gtk_object_sink (GTK_OBJECT (impl->tooltips));
--}
--
--/* Frees the data columns for the specified iter in the shortcuts model*/
--static void
--shortcuts_free_row_data (GtkFileChooserDefault *impl,
-- GtkTreeIter *iter)
--{
-- gpointer col_data;
-- gboolean is_volume;
--
-- gtk_tree_model_get (GTK_TREE_MODEL (impl->shortcuts_model), iter,
-- SHORTCUTS_COL_DATA, &col_data,
-- SHORTCUTS_COL_IS_VOLUME, &is_volume,
-- -1);
-- if (!col_data)
-- return;
--
-- if (is_volume)
-- {
-- GtkFileSystemVolume *volume;
--
-- volume = col_data;
-- gtk_file_system_volume_free (impl->file_system, volume);
-- }
-- else
-- {
-- GtkFilePath *path;
--
-- path = col_data;
-- gtk_file_path_free (path);
-- }
--}
--
--/* Frees all the data columns in the shortcuts model */
--static void
--shortcuts_free (GtkFileChooserDefault *impl)
--{
-- GtkTreeIter iter;
-
-- if (!impl->shortcuts_model)
-- return;
--
-- if (gtk_tree_model_get_iter_first (GTK_TREE_MODEL (impl->shortcuts_model), &iter))
-- do
-- {
-- shortcuts_free_row_data (impl, &iter);
-- }
-- while (gtk_tree_model_iter_next (GTK_TREE_MODEL (impl->shortcuts_model), &iter));
--
-- g_object_unref (impl->shortcuts_model);
-- impl->shortcuts_model = NULL;
-+ if (!impl->root_folder)
-+ impl->root_folder = g_strdup ("/");
- }
-
- static void
-@@ -757,6 +584,7 @@ pending_select_paths_free (GtkFileChoose
- impl->pending_select_paths = NULL;
- }
-
-+
- static void
- pending_select_paths_add (GtkFileChooserDefault *impl,
- const GtkFilePath *path)
-@@ -796,20 +624,30 @@ pending_select_paths_store_selection (Gt
- }
-
- static void
--gtk_file_chooser_default_finalize (GObject *object)
-+path_history_free (GtkFileChooserDefault *impl)
- {
-- GtkFileChooserDefault *impl = GTK_FILE_CHOOSER_DEFAULT (object);
- GSList *l;
-
-- if (impl->shortcuts_filter_model)
-- g_object_unref (impl->shortcuts_filter_model);
-+ for (l = impl->path_history; l; l = l->next)
-+ {
-+ GtkFilePath *path;
-
-- shortcuts_free (impl);
-+ path = l->data;
-+ gtk_file_path_free (path);
-+ }
-+
-+ g_slist_free (impl->path_history);
-+ impl->path_history = NULL;
-+}
-+
-+static void
-+gtk_file_chooser_default_finalize (GObject *object)
-+{
-+ GSList *l;
-+ GtkFileChooserDefault *impl = GTK_FILE_CHOOSER_DEFAULT (object);
-
- g_signal_handler_disconnect (impl->file_system, impl->volumes_changed_id);
- impl->volumes_changed_id = 0;
-- g_signal_handler_disconnect (impl->file_system, impl->bookmarks_changed_id);
-- impl->bookmarks_changed_id = 0;
- g_object_unref (impl->file_system);
-
- for (l = impl->filters; l; l = l->next)
-@@ -830,11 +668,9 @@ gtk_file_chooser_default_finalize (GObje
- if (impl->current_folder)
- gtk_file_path_free (impl->current_folder);
-
-- if (impl->preview_path)
-- gtk_file_path_free (impl->preview_path);
--
- pending_select_paths_free (impl);
--
-+ path_history_free (impl);
-+
- load_remove_timer (impl);
-
- /* Free all the Models we have */
-@@ -844,12 +680,12 @@ gtk_file_chooser_default_finalize (GObje
- if (impl->sort_model)
- g_object_unref (impl->sort_model);
-
-- g_free (impl->preview_display_name);
--
- g_free (impl->edited_new_text);
-
- g_object_unref (impl->tooltips);
-
-+ g_free (impl->root_folder);
-+
- G_OBJECT_CLASS (parent_class)->finalize (object);
- }
-
-@@ -930,28 +766,6 @@ error_getting_info_dialog (GtkFileChoose
- path, error);
- }
-
--/* Shows an error dialog about not being able to add a bookmark */
--static void
--error_adding_bookmark_dialog (GtkFileChooserDefault *impl,
-- const GtkFilePath *path,
-- GError *error)
--{
-- error_dialog (impl,
-- _("Could not add a bookmark"),
-- path, error);
--}
--
--/* Shows an error dialog about not being able to remove a bookmark */
--static void
--error_removing_bookmark_dialog (GtkFileChooserDefault *impl,
-- const GtkFilePath *path,
-- GError *error)
--{
-- error_dialog (impl,
-- _("Could not remove bookmark"),
-- path, error);
--}
--
- /* Shows an error dialog about not being able to create a folder */
- static void
- error_creating_folder_dialog (GtkFileChooserDefault *impl,
-@@ -963,21 +777,6 @@ error_creating_folder_dialog (GtkFileCho
- path, error);
- }
-
--/* Shows an error about not being able to create a folder because a file with
-- * the same name is already there.
-- */
--static void
--error_creating_folder_over_existing_file_dialog (GtkFileChooserDefault *impl,
-- const GtkFilePath *path,
-- GError *error)
--{
-- error_dialog (impl,
-- _("The folder could not be created, as a file with the same name "
-- "already exists. Try using a different name for the folder, "
-- "or rename the file first."),
-- path, error);
--}
--
- /* Shows an error dialog about not being able to create a filename */
- static void
- error_building_filename_dialog (GtkFileChooserDefault *impl,
-@@ -1007,6 +806,7 @@ change_folder_and_display_error (GtkFile
- GError *error;
- gboolean result;
- GtkFilePath *path_copy;
-+ gchar * file_name;
-
- /* We copy the path because of this case:
- *
-@@ -1019,6 +819,29 @@ change_folder_and_display_error (GtkFile
-
- path_copy = gtk_file_path_copy (path);
-
-+ file_name = gtk_file_system_path_to_filename (impl->file_system, path_copy);
-+
-+ /* refuse to change below the root */
-+ if (file_name && impl->root_folder &&
-+ strcmp (file_name, impl->root_folder) &&
-+ !strncmp (file_name, impl->root_folder, strlen (file_name)))
-+ {
-+
-+ gtk_file_path_free (path_copy);
-+ g_free (file_name);
-+ return 0;
-+ }
-+ else if (file_name && impl->root_folder &&
-+ !strcmp (file_name, impl->root_folder))
-+ {
-+ gtk_widget_set_sensitive (impl->up_button, FALSE);
-+ }
-+ else
-+ {
-+ gtk_widget_set_sensitive (impl->up_button, TRUE);
-+ }
-+
-+
- error = NULL;
- result = gtk_file_chooser_default_update_current_folder (GTK_FILE_CHOOSER (impl), path_copy, TRUE, &error);
-
-@@ -1026,189 +849,11 @@ change_folder_and_display_error (GtkFile
- error_changing_folder_dialog (impl, path_copy, error);
-
- gtk_file_path_free (path_copy);
--
-+ g_free (file_name);
-+
- return result;
- }
-
--static void
--update_preview_widget_visibility (GtkFileChooserDefault *impl)
--{
-- if (impl->use_preview_label)
-- {
-- if (!impl->preview_label)
-- {
-- impl->preview_label = gtk_label_new (impl->preview_display_name);
-- gtk_box_pack_start (GTK_BOX (impl->preview_box), impl->preview_label, FALSE, FALSE, 0);
-- gtk_box_reorder_child (GTK_BOX (impl->preview_box), impl->preview_label, 0);
-- gtk_label_set_ellipsize (GTK_LABEL (impl->preview_label), PANGO_ELLIPSIZE_MIDDLE);
-- gtk_widget_show (impl->preview_label);
-- }
-- }
-- else
-- {
-- if (impl->preview_label)
-- {
-- gtk_widget_destroy (impl->preview_label);
-- impl->preview_label = NULL;
-- }
-- }
--
-- if (impl->preview_widget_active && impl->preview_widget)
-- gtk_widget_show (impl->preview_box);
-- else
-- gtk_widget_hide (impl->preview_box);
--
-- g_signal_emit_by_name (impl, "default-size-changed");
--}
--
--static void
--set_preview_widget (GtkFileChooserDefault *impl,
-- GtkWidget *preview_widget)
--{
-- if (preview_widget == impl->preview_widget)
-- return;
--
-- if (impl->preview_widget)
-- gtk_container_remove (GTK_CONTAINER (impl->preview_box),
-- impl->preview_widget);
--
-- impl->preview_widget = preview_widget;
-- if (impl->preview_widget)
-- {
-- gtk_widget_show (impl->preview_widget);
-- gtk_box_pack_start (GTK_BOX (impl->preview_box), impl->preview_widget, TRUE, TRUE, 0);
-- gtk_box_reorder_child (GTK_BOX (impl->preview_box),
-- impl->preview_widget,
-- (impl->use_preview_label && impl->preview_label) ? 1 : 0);
-- }
--
-- update_preview_widget_visibility (impl);
--}
--
--/* Re-reads all the icons for the shortcuts, used when the theme changes */
--static void
--shortcuts_reload_icons (GtkFileChooserDefault *impl)
--{
-- GtkTreeIter iter;
--
-- if (!gtk_tree_model_get_iter_first (GTK_TREE_MODEL (impl->shortcuts_model), &iter))
-- return;
--
-- do {
-- gpointer data;
-- gboolean is_volume;
-- gboolean pixbuf_visible;
-- GdkPixbuf *pixbuf;
--
-- gtk_tree_model_get (GTK_TREE_MODEL (impl->shortcuts_model), &iter,
-- SHORTCUTS_COL_DATA, &data,
-- SHORTCUTS_COL_IS_VOLUME, &is_volume,
-- SHORTCUTS_COL_PIXBUF_VISIBLE, &pixbuf_visible,
-- -1);
--
-- if (pixbuf_visible && data)
-- {
-- if (is_volume)
-- {
-- GtkFileSystemVolume *volume;
--
-- volume = data;
-- pixbuf = gtk_file_system_volume_render_icon (impl->file_system, volume, GTK_WIDGET (impl),
-- impl->icon_size, NULL);
-- }
-- else
-- {
-- const GtkFilePath *path;
--
-- path = data;
-- pixbuf = gtk_file_system_render_icon (impl->file_system, path, GTK_WIDGET (impl),
-- impl->icon_size, NULL);
-- }
--
-- gtk_list_store_set (impl->shortcuts_model, &iter,
-- SHORTCUTS_COL_PIXBUF, pixbuf,
-- -1);
-- if (pixbuf)
-- g_object_unref (pixbuf);
-- }
-- } while (gtk_tree_model_iter_next (GTK_TREE_MODEL (impl->shortcuts_model),&iter));
--}
--
--static void
--shortcuts_find_folder (GtkFileChooserDefault *impl,
-- GtkFilePath *folder)
--{
-- GtkTreeSelection *selection;
-- int pos;
-- GtkTreePath *path;
--
-- selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (impl->browse_shortcuts_tree_view));
--
-- g_assert (folder != NULL);
-- pos = shortcut_find_position (impl, folder);
-- if (pos == -1)
-- {
-- gtk_tree_selection_unselect_all (selection);
-- return;
-- }
--
-- path = gtk_tree_path_new_from_indices (pos, -1);
-- gtk_tree_selection_select_path (selection, path);
-- gtk_tree_path_free (path);
--}
--
--/* If a shortcut corresponds to the current folder, selects it */
--static void
--shortcuts_find_current_folder (GtkFileChooserDefault *impl)
--{
-- shortcuts_find_folder (impl, impl->current_folder);
--}
--
--/* Convenience function to get the display name and icon info for a path */
--static GtkFileInfo *
--get_file_info (GtkFileSystem *file_system,
-- const GtkFilePath *path,
-- gboolean name_only,
-- GError **error)
--{
-- GtkFilePath *parent_path;
-- GtkFileFolder *parent_folder;
-- GtkFileInfo *info;
-- GError *tmp = NULL;
--
-- parent_path = NULL;
-- info = NULL;
--
-- if (!gtk_file_system_get_parent (file_system, path, &parent_path, &tmp))
-- goto out;
--
-- parent_folder = gtk_file_system_get_folder (file_system, parent_path ? parent_path : path,
-- GTK_FILE_INFO_DISPLAY_NAME
-- | (name_only ? 0 : GTK_FILE_INFO_IS_FOLDER),
-- &tmp);
-- if (!parent_folder)
-- goto out;
--
-- info = gtk_file_folder_get_info (parent_folder, parent_path ? path : NULL, &tmp);
-- g_object_unref (parent_folder);
--
-- out:
-- if (parent_path)
-- gtk_file_path_free (parent_path);
--
-- if (tmp)
-- {
-- g_set_error (error,
-- GTK_FILE_CHOOSER_ERROR,
-- GTK_FILE_CHOOSER_ERROR_BAD_FILENAME,
-- _("Could not get information about '%s': %s"),
-- gtk_file_path_get_string (path),
-- tmp->message);
-- g_error_free (tmp);
-- }
--
-- return info;
--}
-
- /* Returns whether a path is a folder */
- static gboolean
-@@ -1217,8 +862,11 @@ check_is_folder (GtkFileSystem *fil
- GError **error)
- {
- GtkFileFolder *folder;
--
-+#ifdef GTK26
- folder = gtk_file_system_get_folder (file_system, path, 0, error);
-+#else
-+ folder = gtk_file_system_get_folder (file_system, path, 0, NULL, NULL);
-+#endif
- if (!folder)
- return FALSE;
-
-@@ -1226,515 +874,6 @@ check_is_folder (GtkFileSystem *fil
- return TRUE;
- }
-
--/* Inserts a path in the shortcuts tree, making a copy of it; alternatively,
-- * inserts a volume. A position of -1 indicates the end of the tree.
-- */
--static gboolean
--shortcuts_insert_path (GtkFileChooserDefault *impl,
-- int pos,
-- gboolean is_volume,
-- GtkFileSystemVolume *volume,
-- const GtkFilePath *path,
-- const char *label,
-- gboolean removable,
-- GError **error)
--{
-- char *label_copy;
-- GdkPixbuf *pixbuf;
-- gpointer data;
-- GtkTreeIter iter;
--
-- if (is_volume)
-- {
-- data = volume;
-- label_copy = gtk_file_system_volume_get_display_name (impl->file_system, volume);
-- pixbuf = gtk_file_system_volume_render_icon (impl->file_system, volume, GTK_WIDGET (impl),
-- impl->icon_size, NULL);
-- }
-- else
-- {
-- if (!check_is_folder (impl->file_system, path, error))
-- return FALSE;
--
-- if (label)
-- label_copy = g_strdup (label);
-- else
-- {
-- GtkFileInfo *info = get_file_info (impl->file_system, path, TRUE, error);
--
-- if (!info)
-- return FALSE;
--
-- label_copy = g_strdup (gtk_file_info_get_display_name (info));
-- gtk_file_info_free (info);
-- }
--
-- data = gtk_file_path_copy (path);
-- pixbuf = gtk_file_system_render_icon (impl->file_system, path, GTK_WIDGET (impl),
-- impl->icon_size, NULL);
-- }
--
-- if (pos == -1)
-- gtk_list_store_append (impl->shortcuts_model, &iter);
-- else
-- gtk_list_store_insert (impl->shortcuts_model, &iter, pos);
--
-- gtk_list_store_set (impl->shortcuts_model, &iter,
-- SHORTCUTS_COL_PIXBUF, pixbuf,
-- SHORTCUTS_COL_PIXBUF_VISIBLE, TRUE,
-- SHORTCUTS_COL_NAME, label_copy,
-- SHORTCUTS_COL_DATA, data,
-- SHORTCUTS_COL_IS_VOLUME, is_volume,
-- SHORTCUTS_COL_REMOVABLE, removable,
-- -1);
--
-- g_free (label_copy);
--
-- if (pixbuf)
-- g_object_unref (pixbuf);
--
-- return TRUE;
--}
--
--/* Appends an item for the user's home directory to the shortcuts model */
--static void
--shortcuts_append_home (GtkFileChooserDefault *impl)
--{
-- const char *home;
-- GtkFilePath *home_path;
-- GError *error;
--
-- home = g_get_home_dir ();
-- if (home == NULL)
-- return;
--
-- home_path = gtk_file_system_filename_to_path (impl->file_system, home);
--
-- error = NULL;
-- impl->has_home = shortcuts_insert_path (impl, -1, FALSE, NULL, home_path, _("Home"), FALSE, &error);
-- if (!impl->has_home)
-- error_getting_info_dialog (impl, home_path, error);
--
-- gtk_file_path_free (home_path);
--}
--
--/* Appends the ~/Desktop directory to the shortcuts model */
--static void
--shortcuts_append_desktop (GtkFileChooserDefault *impl)
--{
-- char *name;
-- GtkFilePath *path;
--
--#ifdef G_OS_WIN32
-- name = _gtk_file_system_win32_get_desktop ();
--#else
-- const char *home = g_get_home_dir ();
-- if (home == NULL)
-- return;
--
-- name = g_build_filename (home, "Desktop", NULL);
--#endif
--
-- path = gtk_file_system_filename_to_path (impl->file_system, name);
-- g_free (name);
--
-- impl->has_desktop = shortcuts_insert_path (impl, -1, FALSE, NULL, path, _("Desktop"), FALSE, NULL);
-- /* We do not actually pop up an error dialog if there is no desktop directory
-- * because some people may really not want to have one.
-- */
--
-- gtk_file_path_free (path);
--}
--
--/* Appends a list of GtkFilePath to the shortcuts model; returns how many were inserted */
--static int
--shortcuts_append_paths (GtkFileChooserDefault *impl,
-- GSList *paths)
--{
-- int start_row;
-- int num_inserted;
--
-- /* As there is no separator now, we want to start there.
-- */
-- start_row = shortcuts_get_index (impl, SHORTCUTS_BOOKMARKS_SEPARATOR);
-- num_inserted = 0;
--
-- for (; paths; paths = paths->next)
-- {
-- GtkFilePath *path;
-- GError *error;
--
-- path = paths->data;
-- error = NULL;
--
-- if (impl->local_only &&
-- !gtk_file_system_path_is_local (impl->file_system, path))
-- continue;
--
-- /* NULL GError, but we don't really want to show error boxes here */
-- if (shortcuts_insert_path (impl, start_row + num_inserted, FALSE, NULL, path, NULL, TRUE, NULL))
-- num_inserted++;
-- }
--
-- return num_inserted;
--}
--
--/* Returns the index for the corresponding item in the shortcuts bar */
--static int
--shortcuts_get_index (GtkFileChooserDefault *impl,
-- ShortcutsIndex where)
--{
-- int n;
--
-- n = 0;
--
-- if (where == SHORTCUTS_HOME)
-- goto out;
--
-- n += impl->has_home ? 1 : 0;
--
-- if (where == SHORTCUTS_DESKTOP)
-- goto out;
--
-- n += impl->has_desktop ? 1 : 0;
--
-- if (where == SHORTCUTS_VOLUMES)
-- goto out;
--
-- n += impl->num_volumes;
--
-- if (where == SHORTCUTS_SHORTCUTS)
-- goto out;
--
-- n += impl->num_shortcuts;
--
-- if (where == SHORTCUTS_BOOKMARKS_SEPARATOR)
-- goto out;
--
-- /* If there are no bookmarks there won't be a separator */
-- n += (impl->num_bookmarks > 0) ? 1 : 0;
--
-- if (where == SHORTCUTS_BOOKMARKS)
-- goto out;
--
-- n += impl->num_bookmarks;
--
-- if (where == SHORTCUTS_CURRENT_FOLDER_SEPARATOR)
-- goto out;
--
-- n += 1;
--
-- if (where == SHORTCUTS_CURRENT_FOLDER)
-- goto out;
--
-- g_assert_not_reached ();
--
-- out:
--
-- return n;
--}
--
--/* Removes the specified number of rows from the shortcuts list */
--static void
--shortcuts_remove_rows (GtkFileChooserDefault *impl,
-- int start_row,
-- int n_rows)
--{
-- GtkTreePath *path;
--
-- path = gtk_tree_path_new_from_indices (start_row, -1);
--
-- for (; n_rows; n_rows--)
-- {
-- GtkTreeIter iter;
--
-- if (!gtk_tree_model_get_iter (GTK_TREE_MODEL (impl->shortcuts_model), &iter, path))
-- g_assert_not_reached ();
--
-- shortcuts_free_row_data (impl, &iter);
-- gtk_list_store_remove (impl->shortcuts_model, &iter);
-- }
--
-- gtk_tree_path_free (path);
--}
--
--/* Adds all the file system volumes to the shortcuts model */
--static void
--shortcuts_add_volumes (GtkFileChooserDefault *impl)
--{
-- int start_row;
-- GSList *list, *l;
-- int n;
-- gboolean old_changing_folders;
--
-- old_changing_folders = impl->changing_folder;
-- impl->changing_folder = TRUE;
--
-- start_row = shortcuts_get_index (impl, SHORTCUTS_VOLUMES);
-- shortcuts_remove_rows (impl, start_row, impl->num_volumes);
-- impl->num_volumes = 0;
--
-- list = gtk_file_system_list_volumes (impl->file_system);
--
-- n = 0;
--
-- for (l = list; l; l = l->next)
-- {
-- GtkFileSystemVolume *volume;
--
-- volume = l->data;
--
-- if (impl->local_only)
-- {
-- GtkFilePath *base_path = gtk_file_system_volume_get_base_path (impl->file_system, volume);
-- gboolean is_local = gtk_file_system_path_is_local (impl->file_system, base_path);
-- gtk_file_path_free (base_path);
--
-- if (!is_local)
-- {
-- gtk_file_system_volume_free (impl->file_system, volume);
-- continue;
-- }
-- }
--
-- if (shortcuts_insert_path (impl, start_row + n, TRUE, volume, NULL, NULL, FALSE, NULL))
-- n++;
-- else
-- gtk_file_system_volume_free (impl->file_system, volume);
-- }
--
-- impl->num_volumes = n;
-- g_slist_free (list);
--
-- if (impl->shortcuts_filter_model)
-- gtk_tree_model_filter_refilter (GTK_TREE_MODEL_FILTER (impl->shortcuts_filter_model));
--
-- impl->changing_folder = old_changing_folders;
--}
--
--/* Inserts a separator node in the shortcuts list */
--static void
--shortcuts_insert_separator (GtkFileChooserDefault *impl,
-- ShortcutsIndex where)
--{
-- GtkTreeIter iter;
--
-- g_assert (where == SHORTCUTS_BOOKMARKS_SEPARATOR || where == SHORTCUTS_CURRENT_FOLDER_SEPARATOR);
--
-- gtk_list_store_insert (impl->shortcuts_model, &iter,
-- shortcuts_get_index (impl, where));
-- gtk_list_store_set (impl->shortcuts_model, &iter,
-- SHORTCUTS_COL_PIXBUF, NULL,
-- SHORTCUTS_COL_PIXBUF_VISIBLE, FALSE,
-- SHORTCUTS_COL_NAME, NULL,
-- SHORTCUTS_COL_DATA, NULL,
-- -1);
--}
--
--/* Updates the list of bookmarks */
--static void
--shortcuts_add_bookmarks (GtkFileChooserDefault *impl)
--{
-- GSList *bookmarks;
-- gboolean old_changing_folders;
-- GtkTreeIter iter;
-- GtkFilePath *list_selected = NULL;
-- GtkFilePath *combo_selected = NULL;
-- gboolean is_volume;
-- gpointer col_data;
--
-- old_changing_folders = impl->changing_folder;
-- impl->changing_folder = TRUE;
--
-- if (shortcuts_get_selected (impl, &iter))
-- {
-- gtk_tree_model_get (GTK_TREE_MODEL (impl->shortcuts_model),
-- &iter,
-- SHORTCUTS_COL_DATA, &col_data,
-- SHORTCUTS_COL_IS_VOLUME, &is_volume,
-- -1);
--
-- if (col_data && !is_volume)
-- list_selected = gtk_file_path_copy (col_data);
-- }
--
-- if (impl->save_folder_combo &&
-- gtk_combo_box_get_active_iter (GTK_COMBO_BOX (impl->save_folder_combo),
-- &iter))
-- {
-- gtk_tree_model_get (GTK_TREE_MODEL (impl->shortcuts_model),
-- &iter,
-- SHORTCUTS_COL_DATA, &col_data,
-- SHORTCUTS_COL_IS_VOLUME, &is_volume,
-- -1);
--
-- if (col_data && !is_volume)
-- combo_selected = gtk_file_path_copy (col_data);
-- }
--
-- if (impl->num_bookmarks > 0)
-- shortcuts_remove_rows (impl,
-- shortcuts_get_index (impl, SHORTCUTS_BOOKMARKS_SEPARATOR),
-- impl->num_bookmarks + 1);
--
-- bookmarks = gtk_file_system_list_bookmarks (impl->file_system);
-- impl->num_bookmarks = shortcuts_append_paths (impl, bookmarks);
-- gtk_file_paths_free (bookmarks);
--
-- if (impl->num_bookmarks > 0)
-- shortcuts_insert_separator (impl, SHORTCUTS_BOOKMARKS_SEPARATOR);
--
-- if (impl->shortcuts_filter_model)
-- gtk_tree_model_filter_refilter (GTK_TREE_MODEL_FILTER (impl->shortcuts_filter_model));
--
-- if (list_selected)
-- {
-- shortcuts_find_folder (impl, list_selected);
-- gtk_file_path_free (list_selected);
-- }
--
-- if (combo_selected)
-- {
-- gint pos;
--
-- pos = shortcut_find_position (impl, combo_selected);
-- if (pos != -1)
-- gtk_combo_box_set_active (GTK_COMBO_BOX (impl->save_folder_combo),
-- pos);
-- gtk_file_path_free (combo_selected);
-- }
--
-- impl->changing_folder = old_changing_folders;
--}
--
--/* Appends a separator and a row to the shortcuts list for the current folder */
--static void
--shortcuts_add_current_folder (GtkFileChooserDefault *impl)
--{
-- int pos;
-- gboolean success;
--
-- g_assert (!impl->shortcuts_current_folder_active);
--
-- success = TRUE;
--
-- g_assert (impl->current_folder != NULL);
--
-- pos = shortcut_find_position (impl, impl->current_folder);
-- if (pos == -1)
-- {
-- GtkFileSystemVolume *volume;
-- GtkFilePath *base_path;
--
-- /* Separator */
--
-- shortcuts_insert_separator (impl, SHORTCUTS_CURRENT_FOLDER_SEPARATOR);
--
-- /* Item */
--
-- pos = shortcuts_get_index (impl, SHORTCUTS_CURRENT_FOLDER);
--
-- volume = gtk_file_system_get_volume_for_path (impl->file_system, impl->current_folder);
-- if (volume)
-- base_path = gtk_file_system_volume_get_base_path (impl->file_system, volume);
-- else
-- base_path = NULL;
--
-- if (base_path &&
-- strcmp (gtk_file_path_get_string (base_path), gtk_file_path_get_string (impl->current_folder)) == 0)
-- {
-- success = shortcuts_insert_path (impl, pos, TRUE, volume, NULL, NULL, FALSE, NULL);
-- if (success)
-- volume = NULL;
-- }
-- else
-- success = shortcuts_insert_path (impl, pos, FALSE, NULL, impl->current_folder, NULL, FALSE, NULL);
--
-- if (volume)
-- gtk_file_system_volume_free (impl->file_system, volume);
--
-- if (base_path)
-- gtk_file_path_free (base_path);
--
-- if (!success)
-- shortcuts_remove_rows (impl, pos - 1, 1); /* remove the separator */
--
-- impl->shortcuts_current_folder_active = success;
-- }
--
-- if (success)
-- gtk_combo_box_set_active (GTK_COMBO_BOX (impl->save_folder_combo), pos);
--}
--
--/* Updates the current folder row in the shortcuts model */
--static void
--shortcuts_update_current_folder (GtkFileChooserDefault *impl)
--{
-- int pos;
--
-- pos = shortcuts_get_index (impl, SHORTCUTS_CURRENT_FOLDER_SEPARATOR);
--
-- if (impl->shortcuts_current_folder_active)
-- {
-- shortcuts_remove_rows (impl, pos, 2);
-- impl->shortcuts_current_folder_active = FALSE;
-- }
--
-- shortcuts_add_current_folder (impl);
--}
--
--/* Filter function used for the shortcuts filter model */
--static gboolean
--shortcuts_filter_cb (GtkTreeModel *model,
-- GtkTreeIter *iter,
-- gpointer data)
--{
-- GtkFileChooserDefault *impl;
-- GtkTreePath *path;
-- int pos;
--
-- impl = GTK_FILE_CHOOSER_DEFAULT (data);
--
-- path = gtk_tree_model_get_path (model, iter);
-- if (!path)
-- return FALSE;
--
-- pos = *gtk_tree_path_get_indices (path);
-- gtk_tree_path_free (path);
--
-- return (pos < shortcuts_get_index (impl, SHORTCUTS_CURRENT_FOLDER_SEPARATOR));
--}
--
--/* Creates the list model for shortcuts */
--static void
--shortcuts_model_create (GtkFileChooserDefault *impl)
--{
-- /* Keep this order in sync with the SHORCUTS_COL_* enum values */
-- impl->shortcuts_model = gtk_list_store_new (SHORTCUTS_COL_NUM_COLUMNS,
-- GDK_TYPE_PIXBUF, /* pixbuf */
-- G_TYPE_STRING, /* name */
-- G_TYPE_POINTER, /* path or volume */
-- G_TYPE_BOOLEAN, /* is the previous column a volume? */
-- G_TYPE_BOOLEAN, /* removable */
-- G_TYPE_BOOLEAN); /* pixbuf cell visibility */
--
-- if (impl->file_system)
-- {
-- shortcuts_append_home (impl);
-- shortcuts_append_desktop (impl);
-- shortcuts_add_volumes (impl);
-- shortcuts_add_bookmarks (impl);
-- }
--
-- impl->shortcuts_filter_model = shortcuts_model_filter_new (impl,
-- GTK_TREE_MODEL (impl->shortcuts_model),
-- NULL);
--
-- gtk_tree_model_filter_set_visible_func (GTK_TREE_MODEL_FILTER (impl->shortcuts_filter_model),
-- shortcuts_filter_cb,
-- impl,
-- NULL);
--}
-
- /* Callback used when the "New Folder" button is clicked */
- static void
-@@ -1793,7 +932,11 @@ edited_idle_cb (GtkFileChooserDefault *i
- if (file_path)
- {
- error = NULL;
-+#ifdef GTK26
- if (gtk_file_system_create_folder (impl->file_system, file_path, &error))
-+#else
-+ if (gtk_file_system_create_folder (impl->file_system, file_path, NULL, NULL))
-+#endif
- change_folder_and_display_error (impl, file_path);
- else
- error_creating_folder_dialog (impl, file_path, error);
-@@ -1864,245 +1007,12 @@ static GtkWidget *
- filter_create (GtkFileChooserDefault *impl)
- {
- impl->filter_combo = gtk_combo_box_new_text ();
-- gtk_combo_box_set_focus_on_click (GTK_COMBO_BOX (impl->filter_combo), FALSE);
--
- g_signal_connect (impl->filter_combo, "changed",
- G_CALLBACK (filter_combo_changed), impl);
-
- return impl->filter_combo;
- }
-
--static GtkWidget *
--button_new (GtkFileChooserDefault *impl,
-- const char *text,
-- const char *stock_id,
-- gboolean sensitive,
-- gboolean show,
-- GCallback callback)
--{
-- GtkWidget *button;
-- GtkWidget *hbox;
-- GtkWidget *widget;
-- GtkWidget *align;
--
-- button = gtk_button_new ();
-- hbox = gtk_hbox_new (FALSE, 2);
-- align = gtk_alignment_new (0.5, 0.5, 0.0, 0.0);
--
-- gtk_container_add (GTK_CONTAINER (button), align);
-- gtk_container_add (GTK_CONTAINER (align), hbox);
-- widget = gtk_image_new_from_stock (stock_id, GTK_ICON_SIZE_BUTTON);
--
-- gtk_box_pack_start (GTK_BOX (hbox), widget, FALSE, FALSE, 0);
--
-- widget = gtk_label_new_with_mnemonic (text);
-- gtk_label_set_mnemonic_widget (GTK_LABEL (widget), GTK_WIDGET (button));
-- gtk_box_pack_start (GTK_BOX (hbox), widget, FALSE, FALSE, 0);
--
-- gtk_widget_set_sensitive (button, sensitive);
-- g_signal_connect (button, "clicked", callback, impl);
--
-- gtk_widget_show_all (align);
--
-- if (show)
-- gtk_widget_show (button);
--
-- return button;
--}
--
--/* Looks for a path among the shortcuts; returns its index or -1 if it doesn't exist */
--static int
--shortcut_find_position (GtkFileChooserDefault *impl,
-- const GtkFilePath *path)
--{
-- GtkTreeIter iter;
-- int i;
-- int current_folder_separator_idx;
--
-- if (!gtk_tree_model_get_iter_first (GTK_TREE_MODEL (impl->shortcuts_model), &iter))
-- return -1;
--
-- current_folder_separator_idx = shortcuts_get_index (impl, SHORTCUTS_CURRENT_FOLDER_SEPARATOR);
--
-- for (i = 0; i < current_folder_separator_idx; i++)
-- {
-- gpointer col_data;
-- gboolean is_volume;
--
-- gtk_tree_model_get (GTK_TREE_MODEL (impl->shortcuts_model), &iter,
-- SHORTCUTS_COL_DATA, &col_data,
-- SHORTCUTS_COL_IS_VOLUME, &is_volume,
-- -1);
--
-- if (col_data)
-- {
-- if (is_volume)
-- {
-- GtkFileSystemVolume *volume;
-- GtkFilePath *base_path;
-- gboolean exists;
--
-- volume = col_data;
-- base_path = gtk_file_system_volume_get_base_path (impl->file_system, volume);
--
-- exists = strcmp (gtk_file_path_get_string (path),
-- gtk_file_path_get_string (base_path)) == 0;
-- g_free (base_path);
--
-- if (exists)
-- return i;
-- }
-- else
-- {
-- GtkFilePath *model_path;
--
-- model_path = col_data;
--
-- if (model_path && gtk_file_path_compare (model_path, path) == 0)
-- return i;
-- }
-- }
--
-- gtk_tree_model_iter_next (GTK_TREE_MODEL (impl->shortcuts_model), &iter);
-- }
--
-- return -1;
--}
--
--/* Tries to add a bookmark from a path name */
--static gboolean
--shortcuts_add_bookmark_from_path (GtkFileChooserDefault *impl,
-- const GtkFilePath *path,
-- int pos)
--{
-- GError *error;
--
-- if (shortcut_find_position (impl, path) != -1)
-- return FALSE;
--
-- /* FIXME: this check really belongs in gtk_file_system_insert_bookmark. */
-- error = NULL;
-- if (!check_is_folder (impl->file_system, path, &error))
-- {
-- error_adding_bookmark_dialog (impl, path, error);
-- return FALSE;
-- }
--
-- error = NULL;
-- if (!gtk_file_system_insert_bookmark (impl->file_system, path, pos, &error))
-- {
-- error_adding_bookmark_dialog (impl, path, error);
-- return FALSE;
-- }
--
-- return TRUE;
--}
--
--static void
--add_bookmark_foreach_cb (GtkTreeModel *model,
-- GtkTreePath *path,
-- GtkTreeIter *iter,
-- gpointer data)
--{
-- GtkFileChooserDefault *impl;
-- GtkFileSystemModel *fs_model;
-- GtkTreeIter child_iter;
-- const GtkFilePath *file_path;
--
-- impl = (GtkFileChooserDefault *) data;
--
-- fs_model = impl->browse_files_model;
-- gtk_tree_model_sort_convert_iter_to_child_iter (impl->sort_model, &child_iter, iter);
--
-- file_path = _gtk_file_system_model_get_path (fs_model, &child_iter);
-- shortcuts_add_bookmark_from_path (impl, file_path, -1);
--}
--
--/* Adds a bookmark from the currently selected item in the file list */
--static void
--bookmarks_add_selected_folder (GtkFileChooserDefault *impl)
--{
-- GtkTreeSelection *selection;
--
-- selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (impl->browse_files_tree_view));
--
-- if (gtk_tree_selection_count_selected_rows (selection) == 0)
-- shortcuts_add_bookmark_from_path (impl, impl->current_folder, -1);
-- else
-- gtk_tree_selection_selected_foreach (selection,
-- add_bookmark_foreach_cb,
-- impl);
--}
--
--/* Callback used when the "Add bookmark" button is clicked */
--static void
--add_bookmark_button_clicked_cb (GtkButton *button,
-- GtkFileChooserDefault *impl)
--{
-- bookmarks_add_selected_folder (impl);
--}
--
--/* Returns TRUE plus an iter in the shortcuts_model if a row is selected;
-- * returns FALSE if no shortcut is selected.
-- */
--static gboolean
--shortcuts_get_selected (GtkFileChooserDefault *impl,
-- GtkTreeIter *iter)
--{
-- GtkTreeSelection *selection;
-- GtkTreeIter parent_iter;
--
-- if (!impl->browse_shortcuts_tree_view)
-- return FALSE;
--
-- selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (impl->browse_shortcuts_tree_view));
--
-- if (!gtk_tree_selection_get_selected (selection, NULL, &parent_iter))
-- return FALSE;
--
-- gtk_tree_model_filter_convert_iter_to_child_iter (GTK_TREE_MODEL_FILTER (impl->shortcuts_filter_model),
-- iter,
-- &parent_iter);
-- return TRUE;
--}
--
--/* Removes the selected bookmarks */
--static void
--remove_selected_bookmarks (GtkFileChooserDefault *impl)
--{
-- GtkTreeIter iter;
-- gpointer col_data;
-- GtkFilePath *path;
-- gboolean removable;
-- GError *error;
--
-- if (!shortcuts_get_selected (impl, &iter))
-- return;
--
-- gtk_tree_model_get (GTK_TREE_MODEL (impl->shortcuts_model), &iter,
-- SHORTCUTS_COL_DATA, &col_data,
-- SHORTCUTS_COL_REMOVABLE, &removable,
-- -1);
-- g_assert (col_data != NULL);
--
-- if (!removable)
-- return;
--
-- path = col_data;
--
-- error = NULL;
-- if (!gtk_file_system_remove_bookmark (impl->file_system, path, &error))
-- error_removing_bookmark_dialog (impl, path, error);
--}
--
--/* Callback used when the "Remove bookmark" button is clicked */
--static void
--remove_bookmark_button_clicked_cb (GtkButton *button,
-- GtkFileChooserDefault *impl)
--{
-- remove_selected_bookmarks (impl);
--}
--
- struct selection_check_closure {
- GtkFileChooserDefault *impl;
- int num_selected;
-@@ -2171,864 +1081,13 @@ struct get_selected_path_closure {
- const GtkFilePath *path;
- };
-
--static void
--get_selected_path_foreach_cb (GtkTreeModel *model,
-- GtkTreePath *path,
-- GtkTreeIter *iter,
-- gpointer data)
--{
-- struct get_selected_path_closure *closure;
-- GtkTreeIter child_iter;
--
-- closure = data;
--
-- gtk_tree_model_sort_convert_iter_to_child_iter (closure->impl->sort_model, &child_iter, iter);
-- closure->path = _gtk_file_system_model_get_path (closure->impl->browse_files_model, &child_iter);
--}
--
- /* Returns a selected path from the file list */
--static const GtkFilePath *
--get_selected_path (GtkFileChooserDefault *impl)
--{
-- struct get_selected_path_closure closure;
-- GtkTreeSelection *selection;
--
-- closure.impl = impl;
-- closure.path = NULL;
--
-- selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (impl->browse_files_tree_view));
-- gtk_tree_selection_selected_foreach (selection,
-- get_selected_path_foreach_cb,
-- &closure);
--
-- return closure.path;
--}
-
- typedef struct {
- GtkFileChooserDefault *impl;
- gchar *tip;
- } UpdateTooltipData;
-
--static void
--update_tooltip (GtkTreeModel *model,
-- GtkTreePath *path,
-- GtkTreeIter *iter,
-- gpointer data)
--{
-- UpdateTooltipData *udata = data;
-- GtkTreeIter child_iter;
-- const GtkFileInfo *info;
--
-- if (udata->tip == NULL)
-- {
-- gtk_tree_model_sort_convert_iter_to_child_iter (udata->impl->sort_model,
-- &child_iter,
-- iter);
--
-- info = _gtk_file_system_model_get_info (udata->impl->browse_files_model, &child_iter);
-- udata->tip = g_strdup_printf (_("Add the folder '%s' to the bookmarks"),
-- gtk_file_info_get_display_name (info));
-- }
--}
--
--
--/* Sensitize the "add bookmark" button if all the selected items are folders, or
-- * if there are no selected items *and* the current folder is not in the
-- * bookmarks list. De-sensitize the button otherwise.
-- */
--static void
--bookmarks_check_add_sensitivity (GtkFileChooserDefault *impl)
--{
-- gint num_selected;
-- gboolean all_folders;
-- gboolean active;
-- gchar *tip;
--
-- selection_check (impl, &num_selected, NULL, &all_folders);
--
-- if (num_selected == 0)
-- active = (impl->current_folder != NULL) && (shortcut_find_position (impl, impl->current_folder) == -1);
-- else if (num_selected == 1)
-- {
-- const GtkFilePath *path;
--
-- path = get_selected_path (impl);
-- active = all_folders && (shortcut_find_position (impl, path) == -1);
-- }
-- else
-- active = all_folders;
--
-- gtk_widget_set_sensitive (impl->browse_shortcuts_add_button, active);
--
-- if (impl->browse_files_popup_menu_add_shortcut_item)
-- gtk_widget_set_sensitive (impl->browse_files_popup_menu_add_shortcut_item,
-- (num_selected == 0) ? FALSE : active);
--
-- if (active)
-- {
-- if (num_selected == 0)
-- tip = g_strdup_printf (_("Add the current folder to the bookmarks"));
-- else if (num_selected > 1)
-- tip = g_strdup_printf (_("Add the selected folders to the bookmarks"));
-- else
-- {
-- GtkTreeSelection *selection;
-- UpdateTooltipData data;
--
-- selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (impl->browse_files_tree_view));
-- data.impl = impl;
-- data.tip = NULL;
-- gtk_tree_selection_selected_foreach (selection, update_tooltip, &data);
-- tip = data.tip;
--
-- }
-- gtk_tooltips_set_tip (impl->tooltips, impl->browse_shortcuts_add_button, tip, NULL);
-- g_free (tip);
-- }
--}
--
--/* Sets the sensitivity of the "remove bookmark" button depending on whether a
-- * bookmark row is selected in the shortcuts tree.
-- */
--static void
--bookmarks_check_remove_sensitivity (GtkFileChooserDefault *impl)
--{
-- GtkTreeIter iter;
-- gboolean removable = FALSE;
-- gchar *name = NULL;
--
-- if (shortcuts_get_selected (impl, &iter))
-- gtk_tree_model_get (GTK_TREE_MODEL (impl->shortcuts_model), &iter,
-- SHORTCUTS_COL_REMOVABLE, &removable,
-- SHORTCUTS_COL_NAME, &name,
-- -1);
--
-- gtk_widget_set_sensitive (impl->browse_shortcuts_remove_button, removable);
--
-- if (removable)
-- {
-- gchar *tip;
--
-- tip = g_strdup_printf (_("Remove the bookmark '%s'"), name);
-- gtk_tooltips_set_tip (impl->tooltips, impl->browse_shortcuts_remove_button,
-- tip, NULL);
-- g_free (tip);
-- }
--
-- g_free (name);
--}
--
--/* GtkWidget::drag-begin handler for the shortcuts list. */
--static void
--shortcuts_drag_begin_cb (GtkWidget *widget,
-- GdkDragContext *context,
-- GtkFileChooserDefault *impl)
--{
--#if 0
-- impl->shortcuts_drag_context = g_object_ref (context);
--#endif
--}
--
--#if 0
--/* Removes the idle handler for outside drags */
--static void
--shortcuts_cancel_drag_outside_idle (GtkFileChooserDefault *impl)
--{
-- if (!impl->shortcuts_drag_outside_idle)
-- return;
--
-- g_source_destroy (impl->shortcuts_drag_outside_idle);
-- impl->shortcuts_drag_outside_idle = NULL;
--}
--#endif
--
--/* GtkWidget::drag-end handler for the shortcuts list. */
--static void
--shortcuts_drag_end_cb (GtkWidget *widget,
-- GdkDragContext *context,
-- GtkFileChooserDefault *impl)
--{
--#if 0
-- g_object_unref (impl->shortcuts_drag_context);
--
-- shortcuts_cancel_drag_outside_idle (impl);
--
-- if (!impl->shortcuts_drag_outside)
-- return;
--
-- gtk_button_clicked (GTK_BUTTON (impl->browse_shortcuts_remove_button));
--
-- impl->shortcuts_drag_outside = FALSE;
--#endif
--}
--
--/* GtkWidget::drag-data-delete handler for the shortcuts list. */
--static void
--shortcuts_drag_data_delete_cb (GtkWidget *widget,
-- GdkDragContext *context,
-- GtkFileChooserDefault *impl)
--{
-- g_signal_stop_emission_by_name (widget, "drag-data-delete");
--}
--
--#if 0
--/* Creates a suitable drag cursor to indicate that the selected bookmark will be
-- * deleted or not.
-- */
--static void
--shortcuts_drag_set_delete_cursor (GtkFileChooserDefault *impl,
-- gboolean delete)
--{
-- GtkTreeView *tree_view;
-- GtkTreeIter iter;
-- GtkTreePath *path;
-- GdkPixmap *row_pixmap;
-- GdkBitmap *mask;
-- int row_pixmap_y;
-- int cell_y;
--
-- tree_view = GTK_TREE_VIEW (impl->browse_shortcuts_tree_view);
--
-- /* Find the selected path and get its drag pixmap */
--
-- if (!shortcuts_get_selected (impl, &iter))
-- g_assert_not_reached ();
--
-- path = gtk_tree_model_get_path (GTK_TREE_MODEL (impl->shortcuts_model), &iter);
--
-- row_pixmap = gtk_tree_view_create_row_drag_icon (tree_view, path);
-- gtk_tree_path_free (path);
--
-- mask = NULL;
-- row_pixmap_y = 0;
--
-- if (delete)
-- {
-- GdkPixbuf *pixbuf;
--
-- pixbuf = gtk_widget_render_icon (impl->browse_shortcuts_tree_view,
-- GTK_STOCK_DELETE,
-- GTK_ICON_SIZE_DND,
-- NULL);
-- if (pixbuf)
-- {
-- GdkPixmap *composite;
-- int row_pixmap_width, row_pixmap_height;
-- int pixbuf_width, pixbuf_height;
-- int composite_width, composite_height;
-- int pixbuf_x, pixbuf_y;
-- GdkGC *gc, *mask_gc;
-- GdkColor color;
-- GdkBitmap *pixbuf_mask;
--
-- /* Create pixmap and mask for composite image */
--
-- gdk_drawable_get_size (row_pixmap, &row_pixmap_width, &row_pixmap_height);
-- pixbuf_width = gdk_pixbuf_get_width (pixbuf);
-- pixbuf_height = gdk_pixbuf_get_height (pixbuf);
--
-- composite_width = MAX (row_pixmap_width, pixbuf_width);
-- composite_height = MAX (row_pixmap_height, pixbuf_height);
--
-- row_pixmap_y = (composite_height - row_pixmap_height) / 2;
--
-- if (gtk_widget_get_direction (impl->browse_shortcuts_tree_view) == GTK_TEXT_DIR_RTL)
-- pixbuf_x = 0;
-- else
-- pixbuf_x = composite_width - pixbuf_width;
--
-- pixbuf_y = (composite_height - pixbuf_height) / 2;
--
-- composite = gdk_pixmap_new (row_pixmap, composite_width, composite_height, -1);
-- gc = gdk_gc_new (composite);
--
-- mask = gdk_pixmap_new (row_pixmap, composite_width, composite_height, 1);
-- mask_gc = gdk_gc_new (mask);
-- color.pixel = 0;
-- gdk_gc_set_foreground (mask_gc, &color);
-- gdk_draw_rectangle (mask, mask_gc, TRUE, 0, 0, composite_width, composite_height);
--
-- color.red = 0xffff;
-- color.green = 0xffff;
-- color.blue = 0xffff;
-- gdk_gc_set_rgb_fg_color (gc, &color);
-- gdk_draw_rectangle (composite, gc, TRUE, 0, 0, composite_width, composite_height);
--
-- /* Composite the row pixmap and the pixbuf */
--
-- gdk_pixbuf_render_pixmap_and_mask_for_colormap
-- (pixbuf,
-- gtk_widget_get_colormap (impl->browse_shortcuts_tree_view),
-- NULL, &pixbuf_mask, 128);
-- gdk_draw_drawable (mask, mask_gc, pixbuf_mask,
-- 0, 0,
-- pixbuf_x, pixbuf_y,
-- pixbuf_width, pixbuf_height);
-- g_object_unref (pixbuf_mask);
--
-- gdk_draw_drawable (composite, gc, row_pixmap,
-- 0, 0,
-- 0, row_pixmap_y,
-- row_pixmap_width, row_pixmap_height);
-- color.pixel = 1;
-- gdk_gc_set_foreground (mask_gc, &color);
-- gdk_draw_rectangle (mask, mask_gc, TRUE, 0, row_pixmap_y, row_pixmap_width, row_pixmap_height);
--
-- gdk_draw_pixbuf (composite, gc, pixbuf,
-- 0, 0,
-- pixbuf_x, pixbuf_y,
-- pixbuf_width, pixbuf_height,
-- GDK_RGB_DITHER_MAX,
-- 0, 0);
--
-- g_object_unref (pixbuf);
-- g_object_unref (row_pixmap);
--
-- row_pixmap = composite;
-- }
-- }
--
-- /* The hotspot offsets here are copied from gtk_tree_view_drag_begin(), ugh */
--
-- gtk_tree_view_get_path_at_pos (tree_view,
-- tree_view->priv->press_start_x,
-- tree_view->priv->press_start_y,
-- NULL,
-- NULL,
-- NULL,
-- &cell_y);
--
-- gtk_drag_set_icon_pixmap (impl->shortcuts_drag_context,
-- gdk_drawable_get_colormap (row_pixmap),
-- row_pixmap,
-- mask,
-- tree_view->priv->press_start_x + 1,
-- row_pixmap_y + cell_y + 1);
--
-- g_object_unref (row_pixmap);
-- if (mask)
-- g_object_unref (mask);
--}
--
--/* We set the delete cursor and the shortcuts_drag_outside flag in an idle
-- * handler so that we can tell apart the drag_leave event that comes right
-- * before a drag_drop, from a normal drag_leave. We don't want to set the
-- * cursor nor the flag in the latter case.
-- */
--static gboolean
--shortcuts_drag_outside_idle_cb (GtkFileChooserDefault *impl)
--{
-- GDK_THREADS_ENTER ();
--
-- shortcuts_drag_set_delete_cursor (impl, TRUE);
-- impl->shortcuts_drag_outside = TRUE;
--
-- shortcuts_cancel_drag_outside_idle (impl);
--
-- GDK_THREADS_LEAVE ();
--
-- return FALSE;
--}
--#endif
--
--/* GtkWidget::drag-leave handler for the shortcuts list. We unhighlight the
-- * drop position.
-- */
--static void
--shortcuts_drag_leave_cb (GtkWidget *widget,
-- GdkDragContext *context,
-- guint time_,
-- GtkFileChooserDefault *impl)
--{
--#if 0
-- if (gtk_drag_get_source_widget (context) == widget && !impl->shortcuts_drag_outside_idle)
-- {
-- impl->shortcuts_drag_outside_idle = g_idle_source_new ();
-- g_source_set_closure (impl->shortcuts_drag_outside_idle,
-- g_cclosure_new_object (G_CALLBACK (shortcuts_drag_outside_idle_cb),
-- G_OBJECT (impl)));
-- g_source_attach (impl->shortcuts_drag_outside_idle, NULL);
-- }
--#endif
--
-- gtk_tree_view_set_drag_dest_row (GTK_TREE_VIEW (impl->browse_shortcuts_tree_view),
-- NULL,
-- GTK_TREE_VIEW_DROP_BEFORE);
--
-- g_signal_stop_emission_by_name (widget, "drag-leave");
--}
--
--/* Computes the appropriate row and position for dropping */
--static void
--shortcuts_compute_drop_position (GtkFileChooserDefault *impl,
-- int x,
-- int y,
-- GtkTreePath **path,
-- GtkTreeViewDropPosition *pos)
--{
-- GtkTreeView *tree_view;
-- GtkTreeViewColumn *column;
-- int cell_y;
-- GdkRectangle cell;
-- int row;
-- int bookmarks_index;
--
-- tree_view = GTK_TREE_VIEW (impl->browse_shortcuts_tree_view);
--
-- bookmarks_index = shortcuts_get_index (impl, SHORTCUTS_BOOKMARKS);
--
-- if (!gtk_tree_view_get_path_at_pos (tree_view,
-- x,
-- y - TREE_VIEW_HEADER_HEIGHT (tree_view),
-- path,
-- &column,
-- NULL,
-- &cell_y))
-- {
-- row = bookmarks_index + impl->num_bookmarks - 1;
-- *path = gtk_tree_path_new_from_indices (row, -1);
-- *pos = GTK_TREE_VIEW_DROP_AFTER;
-- return;
-- }
--
-- row = *gtk_tree_path_get_indices (*path);
-- gtk_tree_view_get_background_area (tree_view, *path, column, &cell);
-- gtk_tree_path_free (*path);
--
-- if (row < bookmarks_index)
-- {
-- row = bookmarks_index;
-- *pos = GTK_TREE_VIEW_DROP_BEFORE;
-- }
-- else if (row > bookmarks_index + impl->num_bookmarks - 1)
-- {
-- row = bookmarks_index + impl->num_bookmarks - 1;
-- *pos = GTK_TREE_VIEW_DROP_AFTER;
-- }
-- else
-- {
-- if (cell_y < cell.height / 2)
-- *pos = GTK_TREE_VIEW_DROP_BEFORE;
-- else
-- *pos = GTK_TREE_VIEW_DROP_AFTER;
-- }
--
-- *path = gtk_tree_path_new_from_indices (row, -1);
--}
--
--/* GtkWidget::drag-motion handler for the shortcuts list. We basically
-- * implement the destination side of DnD by hand, due to limitations in
-- * GtkTreeView's DnD API.
-- */
--static gboolean
--shortcuts_drag_motion_cb (GtkWidget *widget,
-- GdkDragContext *context,
-- gint x,
-- gint y,
-- guint time_,
-- GtkFileChooserDefault *impl)
--{
-- GtkTreePath *path;
-- GtkTreeViewDropPosition pos;
-- GdkDragAction action;
--
--#if 0
-- if (gtk_drag_get_source_widget (context) == widget)
-- {
-- shortcuts_cancel_drag_outside_idle (impl);
--
-- if (impl->shortcuts_drag_outside)
-- {
-- shortcuts_drag_set_delete_cursor (impl, FALSE);
-- impl->shortcuts_drag_outside = FALSE;
-- }
-- }
--#endif
--
-- if (context->suggested_action == GDK_ACTION_COPY || (context->actions & GDK_ACTION_COPY) != 0)
-- action = GDK_ACTION_COPY;
-- else if (context->suggested_action == GDK_ACTION_MOVE || (context->actions & GDK_ACTION_MOVE) != 0)
-- action = GDK_ACTION_MOVE;
-- else
-- {
-- action = 0;
-- goto out;
-- }
--
-- shortcuts_compute_drop_position (impl, x, y, &path, &pos);
-- gtk_tree_view_set_drag_dest_row (GTK_TREE_VIEW (impl->browse_shortcuts_tree_view), path, pos);
-- gtk_tree_path_free (path);
--
-- out:
--
-- g_signal_stop_emission_by_name (widget, "drag-motion");
--
-- if (action != 0)
-- {
-- gdk_drag_status (context, action, time_);
-- return TRUE;
-- }
-- else
-- return FALSE;
--}
--
--/* GtkWidget::drag-drop handler for the shortcuts list. */
--static gboolean
--shortcuts_drag_drop_cb (GtkWidget *widget,
-- GdkDragContext *context,
-- gint x,
-- gint y,
-- guint time_,
-- GtkFileChooserDefault *impl)
--{
--#if 0
-- shortcuts_cancel_drag_outside_idle (impl);
--#endif
--
-- g_signal_stop_emission_by_name (widget, "drag-drop");
-- return TRUE;
--}
--
--/* Parses a "text/uri-list" string and inserts its URIs as bookmarks */
--static void
--shortcuts_drop_uris (GtkFileChooserDefault *impl,
-- const char *data,
-- int position)
--{
-- gchar **uris;
-- gint i;
--
-- uris = g_uri_list_extract_uris (data);
--
-- for (i = 0; uris[i]; i++)
-- {
-- char *uri;
-- GtkFilePath *path;
--
-- uri = uris[i];
-- path = gtk_file_system_uri_to_path (impl->file_system, uri);
--
-- if (path)
-- {
-- if (shortcuts_add_bookmark_from_path (impl, path, position))
-- position++;
--
-- gtk_file_path_free (path);
-- }
-- else
-- {
-- GError *error;
--
-- g_set_error (&error,
-- GTK_FILE_CHOOSER_ERROR,
-- GTK_FILE_CHOOSER_ERROR_BAD_FILENAME,
-- _("Could not add a bookmark for '%s' "
-- "because it is an invalid path name."),
-- uri);
-- error_adding_bookmark_dialog (impl, path, error);
-- }
-- }
--
-- g_strfreev (uris);
--}
--
--/* Reorders the selected bookmark to the specified position */
--static void
--shortcuts_reorder (GtkFileChooserDefault *impl,
-- int new_position)
--{
-- GtkTreeIter iter;
-- gpointer col_data;
-- gboolean is_volume;
-- GtkTreePath *path;
-- int old_position;
-- int bookmarks_index;
-- const GtkFilePath *file_path;
-- GtkFilePath *file_path_copy;
-- GError *error;
--
-- /* Get the selected path */
--
-- if (!shortcuts_get_selected (impl, &iter))
-- g_assert_not_reached ();
--
-- path = gtk_tree_model_get_path (GTK_TREE_MODEL (impl->shortcuts_model), &iter);
-- old_position = *gtk_tree_path_get_indices (path);
-- gtk_tree_path_free (path);
--
-- bookmarks_index = shortcuts_get_index (impl, SHORTCUTS_BOOKMARKS);
-- old_position -= bookmarks_index;
-- g_assert (old_position >= 0 && old_position < impl->num_bookmarks);
--
-- gtk_tree_model_get (GTK_TREE_MODEL (impl->shortcuts_model), &iter,
-- SHORTCUTS_COL_DATA, &col_data,
-- SHORTCUTS_COL_IS_VOLUME, &is_volume,
-- -1);
-- g_assert (col_data != NULL);
-- g_assert (!is_volume);
--
-- file_path = col_data;
-- file_path_copy = gtk_file_path_copy (file_path); /* removal below will free file_path, so we need a copy */
--
-- /* Remove the path from the old position and insert it in the new one */
--
-- if (new_position > old_position)
-- new_position--;
--
-- if (old_position == new_position)
-- goto out;
--
-- error = NULL;
-- if (gtk_file_system_remove_bookmark (impl->file_system, file_path_copy, &error))
-- shortcuts_add_bookmark_from_path (impl, file_path_copy, new_position);
-- else
-- error_adding_bookmark_dialog (impl, file_path_copy, error);
--
-- out:
--
-- gtk_file_path_free (file_path_copy);
--}
--
--/* Callback used when we get the drag data for the bookmarks list. We add the
-- * received URIs as bookmarks if they are folders.
-- */
--static void
--shortcuts_drag_data_received_cb (GtkWidget *widget,
-- GdkDragContext *context,
-- gint x,
-- gint y,
-- GtkSelectionData *selection_data,
-- guint info,
-- guint time_,
-- gpointer data)
--{
-- GtkFileChooserDefault *impl;
-- GtkTreePath *tree_path;
-- GtkTreeViewDropPosition tree_pos;
-- int position;
-- int bookmarks_index;
--
-- impl = GTK_FILE_CHOOSER_DEFAULT (data);
--
-- /* Compute position */
--
-- bookmarks_index = shortcuts_get_index (impl, SHORTCUTS_BOOKMARKS);
--
-- shortcuts_compute_drop_position (impl, x, y, &tree_path, &tree_pos);
-- position = *gtk_tree_path_get_indices (tree_path);
-- gtk_tree_path_free (tree_path);
--
-- if (tree_pos == GTK_TREE_VIEW_DROP_AFTER)
-- position++;
--
-- g_assert (position >= bookmarks_index);
-- position -= bookmarks_index;
--
-- if (selection_data->target == gdk_atom_intern ("text/uri-list", FALSE))
-- shortcuts_drop_uris (impl, selection_data->data, position);
-- else if (selection_data->target == gdk_atom_intern ("GTK_TREE_MODEL_ROW", FALSE))
-- shortcuts_reorder (impl, position);
--
-- g_signal_stop_emission_by_name (widget, "drag-data-received");
--}
--
--/* Callback used when the selection in the shortcuts tree changes */
--static void
--shortcuts_selection_changed_cb (GtkTreeSelection *selection,
-- GtkFileChooserDefault *impl)
--{
-- bookmarks_check_remove_sensitivity (impl);
--}
--
--static gboolean
--shortcuts_row_separator_func (GtkTreeModel *model,
-- GtkTreeIter *iter,
-- gpointer data)
--{
-- gint column = GPOINTER_TO_INT (data);
-- gchar *text;
--
-- gtk_tree_model_get (model, iter, column, &text, -1);
--
-- if (!text)
-- return TRUE;
--
-- g_free (text);
--
-- return FALSE;
--}
--
--/* Since GtkTreeView has a keybinding attached to '/', we need to catch
-- * keypresses before the TreeView gets them.
-- */
--static gboolean
--tree_view_keybinding_cb (GtkWidget *tree_view,
-- GdkEventKey *event,
-- GtkFileChooserDefault *impl)
--{
-- if (event->keyval == GDK_slash &&
-- ! (event->state & (~GDK_SHIFT_MASK & gtk_accelerator_get_default_mod_mask ())))
-- {
-- location_popup_handler (impl, "/");
-- return TRUE;
-- }
--
-- return FALSE;
--}
--
--
--/* Creates the widgets for the shortcuts and bookmarks tree */
--static GtkWidget *
--shortcuts_list_create (GtkFileChooserDefault *impl)
--{
-- GtkWidget *swin;
-- GtkTreeSelection *selection;
-- GtkTreeViewColumn *column;
-- GtkCellRenderer *renderer;
--
-- /* Scrolled window */
--
-- swin = gtk_scrolled_window_new (NULL, NULL);
-- gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (swin),
-- GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
-- gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (swin),
-- GTK_SHADOW_IN);
-- gtk_widget_show (swin);
--
-- /* Tree */
--
-- impl->browse_shortcuts_tree_view = gtk_tree_view_new ();
-- g_signal_connect (impl->browse_shortcuts_tree_view, "key-press-event",
-- G_CALLBACK (tree_view_keybinding_cb), impl);
-- atk_object_set_name (gtk_widget_get_accessible (impl->browse_shortcuts_tree_view), _("Shortcuts"));
-- gtk_tree_view_set_headers_visible (GTK_TREE_VIEW (impl->browse_shortcuts_tree_view), FALSE);
--
-- gtk_tree_view_set_model (GTK_TREE_VIEW (impl->browse_shortcuts_tree_view), impl->shortcuts_filter_model);
--
-- gtk_tree_view_enable_model_drag_source (GTK_TREE_VIEW (impl->browse_shortcuts_tree_view),
-- GDK_BUTTON1_MASK,
-- shortcuts_source_targets,
-- num_shortcuts_source_targets,
-- GDK_ACTION_MOVE);
--
-- gtk_drag_dest_set (impl->browse_shortcuts_tree_view,
-- GTK_DEST_DEFAULT_ALL,
-- shortcuts_dest_targets,
-- num_shortcuts_dest_targets,
-- GDK_ACTION_COPY | GDK_ACTION_MOVE);
--
-- selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (impl->browse_shortcuts_tree_view));
-- gtk_tree_selection_set_mode (selection, GTK_SELECTION_BROWSE);
-- gtk_tree_selection_set_select_function (selection,
-- shortcuts_select_func,
-- impl, NULL);
--
-- g_signal_connect (selection, "changed",
-- G_CALLBACK (shortcuts_selection_changed_cb), impl);
--
-- g_signal_connect (impl->browse_shortcuts_tree_view, "row-activated",
-- G_CALLBACK (shortcuts_row_activated_cb), impl);
--
-- g_signal_connect (impl->browse_shortcuts_tree_view, "key-press-event",
-- G_CALLBACK (shortcuts_key_press_event_cb), impl);
--
-- g_signal_connect (impl->browse_shortcuts_tree_view, "drag-begin",
-- G_CALLBACK (shortcuts_drag_begin_cb), impl);
-- g_signal_connect (impl->browse_shortcuts_tree_view, "drag-end",
-- G_CALLBACK (shortcuts_drag_end_cb), impl);
-- g_signal_connect (impl->browse_shortcuts_tree_view, "drag-data-delete",
-- G_CALLBACK (shortcuts_drag_data_delete_cb), impl);
--
-- g_signal_connect (impl->browse_shortcuts_tree_view, "drag-leave",
-- G_CALLBACK (shortcuts_drag_leave_cb), impl);
-- g_signal_connect (impl->browse_shortcuts_tree_view, "drag-motion",
-- G_CALLBACK (shortcuts_drag_motion_cb), impl);
-- g_signal_connect (impl->browse_shortcuts_tree_view, "drag-drop",
-- G_CALLBACK (shortcuts_drag_drop_cb), impl);
-- g_signal_connect (impl->browse_shortcuts_tree_view, "drag-data-received",
-- G_CALLBACK (shortcuts_drag_data_received_cb), impl);
--
-- gtk_container_add (GTK_CONTAINER (swin), impl->browse_shortcuts_tree_view);
-- gtk_widget_show (impl->browse_shortcuts_tree_view);
--
-- /* Column */
--
-- column = gtk_tree_view_column_new ();
-- gtk_tree_view_column_set_title (column, _("Folder"));
--
-- renderer = gtk_cell_renderer_pixbuf_new ();
-- gtk_tree_view_column_pack_start (column, renderer, FALSE);
-- gtk_tree_view_column_set_attributes (column, renderer,
-- "pixbuf", SHORTCUTS_COL_PIXBUF,
-- "visible", SHORTCUTS_COL_PIXBUF_VISIBLE,
-- NULL);
--
-- renderer = gtk_cell_renderer_text_new ();
-- gtk_tree_view_column_pack_start (column, renderer, TRUE);
-- gtk_tree_view_column_set_attributes (column, renderer,
-- "text", SHORTCUTS_COL_NAME,
-- NULL);
--
-- gtk_tree_view_set_row_separator_func (GTK_TREE_VIEW (impl->browse_shortcuts_tree_view),
-- shortcuts_row_separator_func,
-- GINT_TO_POINTER (SHORTCUTS_COL_NAME),
-- NULL);
--
-- gtk_tree_view_append_column (GTK_TREE_VIEW (impl->browse_shortcuts_tree_view), column);
--
-- return swin;
--}
--
--/* Creates the widgets for the shortcuts/bookmarks pane */
--static GtkWidget *
--shortcuts_pane_create (GtkFileChooserDefault *impl,
-- GtkSizeGroup *size_group)
--{
-- GtkWidget *vbox;
-- GtkWidget *hbox;
-- GtkWidget *widget;
--
-- vbox = gtk_vbox_new (FALSE, 6);
-- gtk_widget_show (vbox);
--
-- /* Shortcuts tree */
--
-- widget = shortcuts_list_create (impl);
-- gtk_box_pack_start (GTK_BOX (vbox), widget, TRUE, TRUE, 0);
--
-- /* Box for buttons */
--
-- hbox = gtk_hbox_new (TRUE, 6);
-- gtk_size_group_add_widget (size_group, hbox);
-- gtk_box_pack_start (GTK_BOX (vbox), hbox, FALSE, FALSE, 0);
-- gtk_widget_show (hbox);
--
-- /* Add bookmark button */
--
-- impl->browse_shortcuts_add_button = button_new (impl,
-- _("_Add"),
-- GTK_STOCK_ADD,
-- FALSE,
-- TRUE,
-- G_CALLBACK (add_bookmark_button_clicked_cb));
-- gtk_box_pack_start (GTK_BOX (hbox), impl->browse_shortcuts_add_button, TRUE, TRUE, 0);
-- gtk_tooltips_set_tip (impl->tooltips, impl->browse_shortcuts_add_button,
-- _("Add the selected folder to the bookmarks"), NULL);
--
-- /* Remove bookmark button */
--
-- impl->browse_shortcuts_remove_button = button_new (impl,
-- _("_Remove"),
-- GTK_STOCK_REMOVE,
-- FALSE,
-- TRUE,
-- G_CALLBACK (remove_bookmark_button_clicked_cb));
-- gtk_box_pack_start (GTK_BOX (hbox), impl->browse_shortcuts_remove_button, TRUE, TRUE, 0);
-- gtk_tooltips_set_tip (impl->tooltips, impl->browse_shortcuts_remove_button,
-- _("Remove the selected bookmark"), NULL);
--
-- return vbox;
--}
-
- /* Handles key press events on the file list, so that we can trap Enter to
- * activate the default button on our own. Also, checks to see if '/' has been
-@@ -3040,14 +1099,11 @@ trap_activate_cb (GtkWidget *widget,
- gpointer data)
- {
- GtkFileChooserDefault *impl;
-- int modifiers;
-
- impl = (GtkFileChooserDefault *) data;
--
-- modifiers = gtk_accelerator_get_default_mod_mask ();
-
- if (event->keyval == GDK_slash &&
-- ! (event->state & (~GDK_SHIFT_MASK & modifiers)))
-+ ! (event->state & (~GDK_SHIFT_MASK & gtk_accelerator_get_default_mod_mask ())))
- {
- location_popup_handler (impl, "/");
- return TRUE;
-@@ -3057,7 +1113,6 @@ trap_activate_cb (GtkWidget *widget,
- || event->keyval == GDK_ISO_Enter
- || event->keyval == GDK_KP_Enter
- || event->keyval == GDK_space)
-- && ((event->state && modifiers) == 0)
- && !(impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER ||
- impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER))
- {
-@@ -3077,37 +1132,7 @@ trap_activate_cb (GtkWidget *widget,
- return FALSE;
- }
-
--/* Callback used when the file list's popup menu is detached */
--static void
--popup_menu_detach_cb (GtkWidget *attach_widget,
-- GtkMenu *menu)
--{
-- GtkFileChooserDefault *impl;
--
-- impl = g_object_get_data (G_OBJECT (attach_widget), "GtkFileChooserDefault");
-- g_assert (GTK_IS_FILE_CHOOSER_DEFAULT (impl));
--
-- impl->browse_files_popup_menu = NULL;
-- impl->browse_files_popup_menu_add_shortcut_item = NULL;
-- impl->browse_files_popup_menu_hidden_files_item = NULL;
--}
--
--/* Callback used when the "Add to Shortcuts" menu item is activated */
--static void
--add_to_shortcuts_cb (GtkMenuItem *item,
-- GtkFileChooserDefault *impl)
--{
-- bookmarks_add_selected_folder (impl);
--}
--
--/* Callback used when the "Open Location" menu item is activated */
--static void
--open_location_cb (GtkMenuItem *item,
-- GtkFileChooserDefault *impl)
--{
-- location_popup_handler (impl, "");
--}
--
-+#if 0
- /* Callback used when the "Show Hidden Files" menu item is toggled */
- static void
- show_hidden_toggled_cb (GtkCheckMenuItem *item,
-@@ -3238,145 +1263,7 @@ file_list_drag_motion_cb (GtkWidget
- g_signal_stop_emission_by_name (widget, "drag-motion");
- return TRUE;
- }
--
--/* Constructs the popup menu for the file list if needed */
--static void
--file_list_build_popup_menu (GtkFileChooserDefault *impl)
--{
-- GtkWidget *item;
--
-- if (impl->browse_files_popup_menu)
-- return;
--
-- impl->browse_files_popup_menu = gtk_menu_new ();
-- gtk_menu_attach_to_widget (GTK_MENU (impl->browse_files_popup_menu),
-- impl->browse_files_tree_view,
-- popup_menu_detach_cb);
--
-- item = gtk_image_menu_item_new_with_mnemonic (_("_Add to Shortcuts"));
-- impl->browse_files_popup_menu_add_shortcut_item = item;
-- gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (item),
-- gtk_image_new_from_stock (GTK_STOCK_ADD, GTK_ICON_SIZE_MENU));
-- gtk_widget_set_sensitive (item, FALSE);
-- g_signal_connect (item, "activate",
-- G_CALLBACK (add_to_shortcuts_cb), impl);
-- gtk_widget_show (item);
-- gtk_menu_shell_append (GTK_MENU_SHELL (impl->browse_files_popup_menu), item);
--
-- item = gtk_image_menu_item_new_with_mnemonic (_("Open _Location"));
-- gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (item),
-- gtk_image_new_from_stock (GTK_STOCK_OPEN, GTK_ICON_SIZE_MENU));
-- g_signal_connect (item, "activate",
-- G_CALLBACK (open_location_cb), impl);
-- gtk_widget_show (item);
-- gtk_menu_shell_append (GTK_MENU_SHELL (impl->browse_files_popup_menu), item);
--
-- item = gtk_separator_menu_item_new ();
-- gtk_widget_show (item);
-- gtk_menu_shell_append (GTK_MENU_SHELL (impl->browse_files_popup_menu), item);
--
-- item = gtk_check_menu_item_new_with_mnemonic (_("Show _Hidden Files"));
-- impl->browse_files_popup_menu_hidden_files_item = item;
-- g_signal_connect (item, "toggled",
-- G_CALLBACK (show_hidden_toggled_cb), impl);
-- gtk_widget_show (item);
-- gtk_menu_shell_append (GTK_MENU_SHELL (impl->browse_files_popup_menu), item);
--}
--
--/* Updates the popup menu for the file list, creating it if necessary */
--static void
--file_list_update_popup_menu (GtkFileChooserDefault *impl)
--{
-- file_list_build_popup_menu (impl);
--
-- /* The sensitivity of the Add to Shortcuts item is set in
-- * bookmarks_check_add_sensitivity()
-- */
--
-- g_signal_handlers_block_by_func (impl->browse_files_popup_menu_hidden_files_item,
-- G_CALLBACK (show_hidden_toggled_cb), impl);
-- gtk_check_menu_item_set_active (GTK_CHECK_MENU_ITEM (impl->browse_files_popup_menu_hidden_files_item),
-- impl->show_hidden);
-- g_signal_handlers_unblock_by_func (impl->browse_files_popup_menu_hidden_files_item,
-- G_CALLBACK (show_hidden_toggled_cb), impl);
--}
--
--static void
--popup_position_func (GtkMenu *menu,
-- gint *x,
-- gint *y,
-- gboolean *push_in,
-- gpointer user_data)
--{
-- GtkWidget *widget = GTK_WIDGET (user_data);
-- GdkScreen *screen = gtk_widget_get_screen (widget);
-- GtkRequisition req;
-- gint monitor_num;
-- GdkRectangle monitor;
--
-- g_return_if_fail (GTK_WIDGET_REALIZED (widget));
--
-- gdk_window_get_origin (widget->window, x, y);
--
-- gtk_widget_size_request (GTK_WIDGET (menu), &req);
--
-- *x += (widget->allocation.width - req.width) / 2;
-- *y += (widget->allocation.height - req.height) / 2;
--
-- monitor_num = gdk_screen_get_monitor_at_point (screen, *x, *y);
-- gtk_menu_set_monitor (menu, monitor_num);
-- gdk_screen_get_monitor_geometry (screen, monitor_num, &monitor);
--
-- *x = CLAMP (*x, monitor.x, monitor.x + MAX (0, monitor.width - req.width));
-- *y = CLAMP (*y, monitor.y, monitor.y + MAX (0, monitor.height - req.height));
--
-- *push_in = FALSE;
--}
--
--static void
--file_list_popup_menu (GtkFileChooserDefault *impl,
-- GdkEventButton *event)
--{
-- file_list_update_popup_menu (impl);
-- if (event)
-- gtk_menu_popup (GTK_MENU (impl->browse_files_popup_menu),
-- NULL, NULL, NULL, NULL,
-- event->button, event->time);
-- else
-- {
-- gtk_menu_popup (GTK_MENU (impl->browse_files_popup_menu),
-- NULL, NULL,
-- popup_position_func, impl->browse_files_tree_view,
-- 0, GDK_CURRENT_TIME);
-- gtk_menu_shell_select_first (GTK_MENU_SHELL (impl->browse_files_popup_menu),
-- FALSE);
-- }
--
--}
--
--/* Callback used for the GtkWidget::popup-menu signal of the file list */
--static gboolean
--list_popup_menu_cb (GtkWidget *widget,
-- GtkFileChooserDefault *impl)
--{
-- file_list_popup_menu (impl, NULL);
-- return TRUE;
--}
--
--/* Callback used when a button is pressed on the file list. We trap button 3 to
-- * bring up a popup menu.
-- */
--static gboolean
--list_button_press_event_cb (GtkWidget *widget,
-- GdkEventButton *event,
-- GtkFileChooserDefault *impl)
--{
-- if (event->button != 3)
-- return FALSE;
--
-- file_list_popup_menu (impl, event);
-- return TRUE;
--}
-+#endif
-
- /* Creates the widgets for the file list */
- static GtkWidget *
-@@ -3414,17 +1301,6 @@ create_file_list (GtkFileChooserDefault
- G_CALLBACK (list_row_activated), impl);
- g_signal_connect (impl->browse_files_tree_view, "key-press-event",
- G_CALLBACK (trap_activate_cb), impl);
-- g_signal_connect (impl->browse_files_tree_view, "popup-menu",
-- G_CALLBACK (list_popup_menu_cb), impl);
-- g_signal_connect (impl->browse_files_tree_view, "button-press-event",
-- G_CALLBACK (list_button_press_event_cb), impl);
--
-- g_signal_connect (impl->browse_files_tree_view, "drag-data-received",
-- G_CALLBACK (file_list_drag_data_received_cb), impl);
-- g_signal_connect (impl->browse_files_tree_view, "drag-drop",
-- G_CALLBACK (file_list_drag_drop_cb), impl);
-- g_signal_connect (impl->browse_files_tree_view, "drag-motion",
-- G_CALLBACK (file_list_drag_motion_cb), impl);
-
- selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (impl->browse_files_tree_view));
- gtk_tree_selection_set_select_function (selection,
-@@ -3495,70 +1371,163 @@ create_file_list (GtkFileChooserDefault
- return swin;
- }
-
--static GtkWidget *
--create_path_bar (GtkFileChooserDefault *impl)
-+static void
-+up_button_clicked_cb (GtkButton *button, gpointer data)
- {
-- GtkWidget *path_bar;
--
-- path_bar = g_object_new (GTK_TYPE_PATH_BAR, NULL);
-- _gtk_path_bar_set_file_system (GTK_PATH_BAR (path_bar), impl->file_system);
--
-- return path_bar;
-+ GtkFileChooserDefault *impl = GTK_FILE_CHOOSER_DEFAULT (data);
-+ up_folder_handler (impl);
- }
-
- static void
--set_filter_tooltip (GtkWidget *widget,
-- gpointer data)
-+volume_button_clicked_cb (GtkButton *button, gpointer data)
- {
-- GtkTooltips *tooltips = (GtkTooltips *)data;
--
-- if (GTK_IS_BUTTON (widget))
-- gtk_tooltips_set_tip (tooltips, widget,
-- _("Select which types of files are shown"),
-- NULL);
-+ GtkFileChooserDefault *impl = GTK_FILE_CHOOSER_DEFAULT (data);
-+ GtkFilePath * path = g_object_get_data (G_OBJECT (button), "file-path");
-+
-+ change_folder_and_display_error (impl, path);
- }
-
--static void
--realize_filter_combo (GtkWidget *combo,
-- gpointer data)
-+static GtkWidget *
-+create_bar (GtkFileChooserDefault *impl)
- {
-- GtkFileChooserDefault *impl = (GtkFileChooserDefault *)data;
-+ GSList *list, *l;
-+ int n;
-+ GtkWidget *bar = gtk_hbox_new (FALSE, DEFAULT_SPACING);
-+ GtkWidget *img;
-
-- gtk_container_forall (GTK_CONTAINER (combo),
-- set_filter_tooltip,
-- impl->tooltips);
-+ /* first the Up button */
-+ img = gtk_image_new_from_stock (GTK_STOCK_GO_UP, GTK_ICON_SIZE_BUTTON);
-+ gtk_widget_show (img);
-+
-+ impl->up_button = gtk_button_new ();
-+ gtk_container_add (GTK_CONTAINER (impl->up_button), img);
-+ gtk_widget_show (impl->up_button);
-+ gtk_widget_set_sensitive (impl->up_button, FALSE);
-+ gtk_button_set_focus_on_click (GTK_BUTTON (impl->up_button), FALSE);
-+
-+ g_signal_connect (impl->up_button, "clicked",
-+ G_CALLBACK (up_button_clicked_cb), impl);
-+ gtk_box_pack_start (GTK_BOX(bar), impl->up_button, FALSE, FALSE, 0);
-+
-+ impl->num_volumes = 0;
-+ list = gtk_file_system_list_volumes (impl->file_system);
-+
-+ n = 0;
-+
-+ for (l = list; l; l = l->next, n++)
-+ {
-+ GtkFileSystemVolume *volume;
-+ GdkPixbuf *pixbuf;
-+ GtkWidget *button;
-+ GtkWidget *image;
-+ GtkFilePath *base_path;
-+ gchar * file_name = NULL;
-+
-+ volume = l->data;
-+ base_path =
-+ gtk_file_system_volume_get_base_path (impl->file_system, volume);
-+
-+ if (impl->local_only)
-+ {
-+ gboolean is_local =
-+ gtk_file_system_path_is_local (impl->file_system, base_path);
-+
-+ if (!is_local)
-+ {
-+ gtk_file_path_free (base_path);
-+ gtk_file_system_volume_free (impl->file_system, volume);
-+ continue;
-+ }
-+ }
-+
-+#if 0
-+ label_copy =
-+ gtk_file_system_volume_get_display_name (impl->file_system, volume);
-+#endif
-+ pixbuf =
-+ gtk_file_system_volume_render_icon (impl->file_system, volume,
-+ GTK_WIDGET (impl),
-+ impl->icon_size, NULL);
-+
-+ button = gtk_button_new ();
-+ image = gtk_image_new_from_pixbuf (pixbuf);
-+ g_object_unref (G_OBJECT (pixbuf));
-+ gtk_container_add (GTK_CONTAINER (button), image);
-+ gtk_button_set_focus_on_click (GTK_BUTTON (button), FALSE);
-+
-+ file_name =
-+ gtk_file_system_path_to_filename (impl->file_system, base_path);
-+
-+ if (file_name && impl->root_folder &&
-+ strcmp (file_name, impl->root_folder) &&
-+ !strncmp (file_name, impl->root_folder, strlen (file_name)))
-+ {
-+ /* The base path is below the root folder; we replace it with
-+ * the root folder
-+ */
-+ gtk_file_path_free (base_path);
-+ base_path = gtk_file_system_filename_to_path (impl->file_system,
-+ impl->root_folder);
-+ }
-+
-+ g_free (file_name);
-+
-+ gtk_widget_show_all (button);
-+
-+ g_object_set_data (G_OBJECT (button), "file-path", base_path);
-+
-+ g_signal_connect (button, "clicked",
-+ G_CALLBACK (volume_button_clicked_cb), impl);
-+
-+ gtk_box_pack_start (GTK_BOX(bar), button, FALSE, FALSE, 0);
-+ }
-+
-+ impl->num_volumes = n;
-+ g_slist_free (list);
-+
-+ gtk_widget_show (bar);
-+
-+ return bar;
- }
-
- /* Creates the widgets for the files/folders pane */
- static GtkWidget *
--file_pane_create (GtkFileChooserDefault *impl,
-- GtkSizeGroup *size_group)
-+file_pane_create (GtkFileChooserDefault *impl)
- {
- GtkWidget *vbox;
- GtkWidget *hbox;
- GtkWidget *widget;
--
-- vbox = gtk_vbox_new (FALSE, 6);
-+ vbox = gtk_vbox_new (FALSE, DEFAULT_SPACING);
- gtk_widget_show (vbox);
-
-- /* The path bar and 'Create Folder' button */
-- hbox = gtk_hbox_new (FALSE, 12);
-+ /* The volume bar and 'Create Folder' button */
-+ hbox = gtk_hbox_new (FALSE, DEFAULT_SPACING);
- gtk_widget_show (hbox);
-- impl->browse_path_bar = create_path_bar (impl);
-- g_signal_connect (impl->browse_path_bar, "path-clicked", G_CALLBACK (path_bar_clicked), impl);
-- gtk_widget_show_all (impl->browse_path_bar);
-- gtk_box_pack_start (GTK_BOX (hbox), impl->browse_path_bar, TRUE, TRUE, 0);
-+ impl->bar = create_bar (impl);
-+ gtk_widget_show_all (impl->bar);
-+ gtk_box_pack_start (GTK_BOX (hbox), impl->bar, TRUE, TRUE, 0);
-
- /* Create Folder */
-- impl->browse_new_folder_button = gtk_button_new_with_mnemonic (_("Create Fo_lder"));
-+ widget = gtk_image_new_from_icon_name ("folder-new", GTK_ICON_SIZE_BUTTON);
-+ gtk_widget_show (widget);
-+ impl->browse_new_folder_button = gtk_button_new ();
-+ gtk_container_add (GTK_CONTAINER (impl->browse_new_folder_button), widget);
-+ gtk_button_set_focus_on_click (GTK_BUTTON (impl->browse_new_folder_button),
-+ FALSE);
-+
- g_signal_connect (impl->browse_new_folder_button, "clicked",
- G_CALLBACK (new_folder_button_clicked), impl);
- gtk_box_pack_end (GTK_BOX (hbox), impl->browse_new_folder_button, FALSE, FALSE, 0);
-+
-+ widget = filter_create (impl);
-+ gtk_widget_hide (widget);
-+ gtk_box_pack_end (GTK_BOX (hbox), widget, FALSE, FALSE, 0);
-+
- gtk_box_pack_start (GTK_BOX (vbox), hbox, FALSE, FALSE, 0);
-
-- /* Box for lists and preview */
-+ /* Box for lists */
-
-- hbox = gtk_hbox_new (FALSE, PREVIEW_HBOX_SPACING);
-+ hbox = gtk_hbox_new (FALSE, LIST_HBOX_SPACING);
- gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE, TRUE, 0);
- gtk_widget_show (hbox);
-
-@@ -3567,157 +1536,37 @@ file_pane_create (GtkFileChooserDefault
- widget = create_file_list (impl);
- gtk_box_pack_start (GTK_BOX (hbox), widget, TRUE, TRUE, 0);
-
-- /* Preview */
--
-- impl->preview_box = gtk_vbox_new (FALSE, 12);
-- gtk_box_pack_start (GTK_BOX (hbox), impl->preview_box, FALSE, FALSE, 0);
-- /* Don't show preview box initially */
--
-- /* Filter combo */
--
-- impl->filter_combo_hbox = gtk_hbox_new (FALSE, 12);
--
-- widget = filter_create (impl);
--
-- g_signal_connect (widget, "realize",
-- G_CALLBACK (realize_filter_combo), impl);
--
-- gtk_widget_show (widget);
-- gtk_box_pack_end (GTK_BOX (impl->filter_combo_hbox), widget, FALSE, FALSE, 0);
--
-- gtk_size_group_add_widget (size_group, impl->filter_combo_hbox);
-- gtk_box_pack_end (GTK_BOX (vbox), impl->filter_combo_hbox, FALSE, FALSE, 0);
--
- return vbox;
- }
--/* Callback used when the "Browse for more folders" expander is toggled */
--static void
--expander_changed_cb (GtkExpander *expander,
-- GParamSpec *pspec,
-- GtkFileChooserDefault *impl)
--{
-- update_appearance (impl);
--}
--
--/* Callback used when the selection changes in the save folder combo box */
--static void
--save_folder_combo_changed_cb (GtkComboBox *combo,
-- GtkFileChooserDefault *impl)
--{
-- GtkTreeIter iter;
--
-- if (impl->changing_folder)
-- return;
--
-- if (gtk_combo_box_get_active_iter (combo, &iter))
-- shortcuts_activate_iter (impl, &iter);
--}
--
--/* Creates the combo box with the save folders */
--static GtkWidget *
--save_folder_combo_create (GtkFileChooserDefault *impl)
--{
-- GtkWidget *combo;
-- GtkCellRenderer *cell;
--
-- combo = g_object_new (GTK_TYPE_COMBO_BOX,
-- "model", impl->shortcuts_model,
-- "focus-on-click", FALSE,
-- NULL);
-- gtk_widget_show (combo);
--
-- cell = gtk_cell_renderer_pixbuf_new ();
-- gtk_cell_layout_pack_start (GTK_CELL_LAYOUT (combo), cell, FALSE);
-- gtk_cell_layout_set_attributes (GTK_CELL_LAYOUT (combo), cell,
-- "pixbuf", SHORTCUTS_COL_PIXBUF,
-- "visible", SHORTCUTS_COL_PIXBUF_VISIBLE,
-- "sensitive", SHORTCUTS_COL_PIXBUF_VISIBLE,
-- NULL);
--
-- cell = gtk_cell_renderer_text_new ();
-- gtk_cell_layout_pack_start (GTK_CELL_LAYOUT (combo), cell, TRUE);
-- gtk_cell_layout_set_attributes (GTK_CELL_LAYOUT (combo), cell,
-- "text", SHORTCUTS_COL_NAME,
-- "sensitive", SHORTCUTS_COL_PIXBUF_VISIBLE,
-- NULL);
--
-- gtk_combo_box_set_row_separator_func (GTK_COMBO_BOX (combo),
-- shortcuts_row_separator_func,
-- GINT_TO_POINTER (SHORTCUTS_COL_NAME),
-- NULL);
--
-- g_signal_connect (combo, "changed",
-- G_CALLBACK (save_folder_combo_changed_cb), impl);
--
-- return combo;
--}
-
- /* Creates the widgets specific to Save mode */
- static GtkWidget *
- save_widgets_create (GtkFileChooserDefault *impl)
- {
- GtkWidget *vbox;
-- GtkWidget *table;
-+ GtkWidget *hbox;
- GtkWidget *widget;
-- GtkWidget *alignment;
--
-- vbox = gtk_vbox_new (FALSE, 12);
-
-- table = gtk_table_new (2, 2, FALSE);
-- gtk_box_pack_start (GTK_BOX (vbox), table, FALSE, FALSE, 0);
-- gtk_widget_show (table);
-- gtk_table_set_row_spacings (GTK_TABLE (table), 12);
-- gtk_table_set_col_spacings (GTK_TABLE (table), 12);
--
-- /* Name entry */
--
-- widget = gtk_label_new_with_mnemonic (_("_Name:"));
-+ vbox = gtk_vbox_new (FALSE, 0);
-+ hbox = gtk_hbox_new (FALSE, DEFAULT_SPACING);
-+
-+ widget = gtk_label_new (_("Name:"));
- gtk_misc_set_alignment (GTK_MISC (widget), 0.0, 0.5);
-- gtk_table_attach (GTK_TABLE (table), widget,
-- 0, 1, 0, 1,
-- GTK_FILL, GTK_FILL,
-- 0, 0);
-+ gtk_box_pack_start (GTK_BOX (hbox), widget, FALSE, FALSE, 0);
- gtk_widget_show (widget);
-
- impl->save_file_name_entry = _gtk_file_chooser_entry_new (TRUE);
- _gtk_file_chooser_entry_set_file_system (GTK_FILE_CHOOSER_ENTRY (impl->save_file_name_entry),
- impl->file_system);
-- gtk_entry_set_width_chars (GTK_ENTRY (impl->save_file_name_entry), 45);
-+/* gtk_entry_set_width_chars (GTK_ENTRY (impl->save_file_name_entry), 45); */
- gtk_entry_set_activates_default (GTK_ENTRY (impl->save_file_name_entry), TRUE);
-- gtk_table_attach (GTK_TABLE (table), impl->save_file_name_entry,
-- 1, 2, 0, 1,
-- GTK_EXPAND | GTK_FILL, 0,
-- 0, 0);
-+ gtk_box_pack_start (GTK_BOX (hbox), impl->save_file_name_entry,
-+ TRUE, TRUE, 0);
- gtk_widget_show (impl->save_file_name_entry);
-- gtk_label_set_mnemonic_widget (GTK_LABEL (widget), impl->save_file_name_entry);
--
-- /* Folder combo */
-- impl->save_folder_label = gtk_label_new (NULL);
-- gtk_misc_set_alignment (GTK_MISC (impl->save_folder_label), 0.0, 0.5);
-- gtk_table_attach (GTK_TABLE (table), impl->save_folder_label,
-- 0, 1, 1, 2,
-- GTK_FILL, GTK_FILL,
-- 0, 0);
-- gtk_widget_show (impl->save_folder_label);
--
-- impl->save_folder_combo = save_folder_combo_create (impl);
-- gtk_table_attach (GTK_TABLE (table), impl->save_folder_combo,
-- 1, 2, 1, 2,
-- GTK_EXPAND | GTK_FILL, GTK_FILL,
-- 0, 0);
-- gtk_label_set_mnemonic_widget (GTK_LABEL (impl->save_folder_label), impl->save_folder_combo);
--
-- /* Expander */
-- alignment = gtk_alignment_new (0.0, 0.5, 1.0, 1.0);
-- gtk_box_pack_start (GTK_BOX (vbox), alignment, FALSE, FALSE, 0);
--
-- impl->save_expander = gtk_expander_new_with_mnemonic (_("_Browse for other folders"));
-- gtk_container_add (GTK_CONTAINER (alignment), impl->save_expander);
-- g_signal_connect (impl->save_expander, "notify::expanded",
-- G_CALLBACK (expander_changed_cb),
-- impl);
-- gtk_widget_show_all (alignment);
-
-+ gtk_widget_show (hbox);
-+ gtk_box_pack_start (GTK_BOX (vbox), hbox, FALSE, FALSE, 0);
-+
- return vbox;
- }
-
-@@ -3725,29 +1574,11 @@ save_widgets_create (GtkFileChooserDefau
- static GtkWidget *
- browse_widgets_create (GtkFileChooserDefault *impl)
- {
-- GtkWidget *vbox;
-- GtkWidget *hpaned;
- GtkWidget *widget;
-- GtkSizeGroup *size_group;
--
-- /* size group is used by the [+][-] buttons and the filter combo */
-- size_group = gtk_size_group_new (GTK_SIZE_GROUP_VERTICAL);
-- vbox = gtk_vbox_new (FALSE, 12);
--
-- /* Paned widget */
-- hpaned = gtk_hpaned_new ();
-- gtk_widget_show (hpaned);
-- gtk_paned_set_position (GTK_PANED (hpaned), 200); /* FIXME: this sucks */
-- gtk_box_pack_start (GTK_BOX (vbox), hpaned, TRUE, TRUE, 0);
--
-- widget = shortcuts_pane_create (impl, size_group);
-- gtk_paned_pack1 (GTK_PANED (hpaned), widget, FALSE, FALSE);
-- widget = file_pane_create (impl, size_group);
-- gtk_paned_pack2 (GTK_PANED (hpaned), widget, TRUE, FALSE);
-
-- g_object_unref (size_group);
-+ widget = file_pane_create (impl);
-
-- return vbox;
-+ return widget;
- }
-
- static GObject*
-@@ -3767,56 +1598,20 @@ gtk_file_chooser_default_constructor (GT
-
- gtk_widget_push_composite_child ();
-
-- /* Shortcuts model */
--
-- shortcuts_model_create (impl);
--
-- /* Widgets for Save mode */
-- impl->save_widgets = save_widgets_create (impl);
-- gtk_box_pack_start (GTK_BOX (impl), impl->save_widgets, FALSE, FALSE, 0);
--
- /* The browse widgets */
- impl->browse_widgets = browse_widgets_create (impl);
- gtk_box_pack_start (GTK_BOX (impl), impl->browse_widgets, TRUE, TRUE, 0);
-
-- /* Alignment to hold extra widget */
-- impl->extra_align = gtk_alignment_new (0.0, 0.5, 1.0, 1.0);
-- gtk_box_pack_start (GTK_BOX (impl), impl->extra_align, FALSE, FALSE, 0);
--
-+ /* Widgets for Save mode */
-+ impl->save_widgets = save_widgets_create (impl);
-+ gtk_box_pack_start (GTK_BOX (impl), impl->save_widgets, FALSE, FALSE, 0);
-+
- gtk_widget_pop_composite_child ();
- update_appearance (impl);
-
- return object;
- }
-
--/* Sets the extra_widget by packing it in the appropriate place */
--static void
--set_extra_widget (GtkFileChooserDefault *impl,
-- GtkWidget *extra_widget)
--{
-- if (extra_widget)
-- {
-- g_object_ref (extra_widget);
-- /* FIXME: is this right ? */
-- gtk_widget_show (extra_widget);
-- }
--
-- if (impl->extra_widget)
-- {
-- gtk_container_remove (GTK_CONTAINER (impl->extra_align), impl->extra_widget);
-- g_object_unref (impl->extra_widget);
-- }
--
-- impl->extra_widget = extra_widget;
-- if (impl->extra_widget)
-- {
-- gtk_container_add (GTK_CONTAINER (impl->extra_align), impl->extra_widget);
-- gtk_widget_show (impl->extra_align);
-- }
-- else
-- gtk_widget_hide (impl->extra_align);
--}
--
- static void
- set_local_only (GtkFileChooserDefault *impl,
- gboolean local_only)
-@@ -3825,12 +1620,6 @@ set_local_only (GtkFileChooserDefault *i
- {
- impl->local_only = local_only;
-
-- if (impl->shortcuts_model && impl->file_system)
-- {
-- shortcuts_add_volumes (impl);
-- shortcuts_add_bookmarks (impl);
-- }
--
- if (local_only &&
- !gtk_file_system_path_is_local (impl->file_system, impl->current_folder))
- {
-@@ -3857,18 +1646,7 @@ static void
- volumes_changed_cb (GtkFileSystem *file_system,
- GtkFileChooserDefault *impl)
- {
-- shortcuts_add_volumes (impl);
--}
--
--/* Callback used when the set of bookmarks changes in the file system */
--static void
--bookmarks_changed_cb (GtkFileSystem *file_system,
-- GtkFileChooserDefault *impl)
--{
-- shortcuts_add_bookmarks (impl);
--
-- bookmarks_check_add_sensitivity (impl);
-- bookmarks_check_remove_sensitivity (impl);
-+ /* FIXME -- not needed */
- }
-
- /* Sets the file chooser to multiple selection mode */
-@@ -3890,8 +1668,6 @@ set_select_multiple (GtkFileChooserDefau
-
- impl->select_multiple = select_multiple;
- g_object_notify (G_OBJECT (impl), "select-multiple");
--
-- check_preview_change (impl);
- }
-
- static void
-@@ -3902,8 +1678,6 @@ set_file_system_backend (GtkFileChooserD
- {
- g_signal_handler_disconnect (impl->file_system, impl->volumes_changed_id);
- impl->volumes_changed_id = 0;
-- g_signal_handler_disconnect (impl->file_system, impl->bookmarks_changed_id);
-- impl->bookmarks_changed_id = 0;
- g_object_unref (impl->file_system);
- }
-
-@@ -3939,9 +1713,6 @@ set_file_system_backend (GtkFileChooserD
- impl->volumes_changed_id = g_signal_connect (impl->file_system, "volumes-changed",
- G_CALLBACK (volumes_changed_cb),
- impl);
-- impl->bookmarks_changed_id = g_signal_connect (impl->file_system, "bookmarks-changed",
-- G_CALLBACK (bookmarks_changed_cb),
-- impl);
- }
- }
-
-@@ -3956,30 +1727,8 @@ update_appearance (GtkFileChooserDefault
- if (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE ||
- impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER)
- {
-- const char *text;
--
- gtk_widget_show (impl->save_widgets);
--
-- if (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE)
-- text = _("Save in _folder:");
-- else
-- text = _("Create in _folder:");
--
-- gtk_label_set_text_with_mnemonic (GTK_LABEL (impl->save_folder_label), text);
--
-- if (gtk_expander_get_expanded (GTK_EXPANDER (impl->save_expander)))
-- {
-- gtk_widget_set_sensitive (impl->save_folder_label, FALSE);
-- gtk_widget_set_sensitive (impl->save_folder_combo, FALSE);
-- gtk_widget_show (impl->browse_widgets);
-- }
-- else
-- {
-- gtk_widget_set_sensitive (impl->save_folder_label, TRUE);
-- gtk_widget_set_sensitive (impl->save_folder_combo, TRUE);
-- gtk_widget_hide (impl->browse_widgets);
-- }
--
-+ gtk_widget_show (impl->browse_widgets);
- gtk_widget_show (impl->browse_new_folder_button);
-
- if (impl->select_multiple)
-@@ -3993,6 +1742,7 @@ update_appearance (GtkFileChooserDefault
- impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER)
- {
- gtk_widget_hide (impl->save_widgets);
-+ gtk_widget_hide (impl->browse_new_folder_button);
- gtk_widget_show (impl->browse_widgets);
- }
-
-@@ -4025,12 +1775,9 @@ gtk_file_chooser_default_set_property (G
- {
- gtk_file_chooser_default_unselect_all (GTK_FILE_CHOOSER (impl));
-
-- if ((action == GTK_FILE_CHOOSER_ACTION_SAVE || action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER)
-- && impl->select_multiple)
-+ if (action == GTK_FILE_CHOOSER_ACTION_SAVE && impl->select_multiple)
- {
-- g_warning ("Tried to change the file chooser action to SAVE or CREATE_FOLDER, but "
-- "this is not allowed in multiple selection mode. Resetting the file chooser "
-- "to single selection mode.");
-+ g_warning ("Multiple selection mode is not allowed in Save mode");
- set_select_multiple (impl, FALSE, TRUE);
- }
- impl->action = action;
-@@ -4051,29 +1798,12 @@ gtk_file_chooser_default_set_property (G
- case GTK_FILE_CHOOSER_PROP_LOCAL_ONLY:
- set_local_only (impl, g_value_get_boolean (value));
- break;
-- case GTK_FILE_CHOOSER_PROP_PREVIEW_WIDGET:
-- set_preview_widget (impl, g_value_get_object (value));
-- break;
-- case GTK_FILE_CHOOSER_PROP_PREVIEW_WIDGET_ACTIVE:
-- impl->preview_widget_active = g_value_get_boolean (value);
-- update_preview_widget_visibility (impl);
-- break;
-- case GTK_FILE_CHOOSER_PROP_USE_PREVIEW_LABEL:
-- impl->use_preview_label = g_value_get_boolean (value);
-- update_preview_widget_visibility (impl);
-- break;
-- case GTK_FILE_CHOOSER_PROP_EXTRA_WIDGET:
-- set_extra_widget (impl, g_value_get_object (value));
-- break;
- case GTK_FILE_CHOOSER_PROP_SELECT_MULTIPLE:
- {
- gboolean select_multiple = g_value_get_boolean (value);
-- if ((impl->action == GTK_FILE_CHOOSER_ACTION_SAVE || impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER)
-- && select_multiple)
-+ if (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE && select_multiple)
- {
-- g_warning ("Tried to set the file chooser to multiple selection mode, but this is "
-- "not allowed in SAVE or CREATE_FOLDER modes. Ignoring the change and "
-- "leaving the file chooser in single selection mode.");
-+ g_warning ("Multiple selection mode is not allowed in Save mode");
- return;
- }
-
-@@ -4092,6 +1822,19 @@ gtk_file_chooser_default_set_property (G
- }
- }
- break;
-+ case GTK_FILE_CHOOSER_PROP_ROOT_FOLDER:
-+ {
-+ impl->root_folder = g_strdup (g_value_get_string (value));
-+ }
-+ break;
-+
-+ /* These are not supported */
-+ case GTK_FILE_CHOOSER_PROP_PREVIEW_WIDGET:
-+ case GTK_FILE_CHOOSER_PROP_PREVIEW_WIDGET_ACTIVE:
-+ case GTK_FILE_CHOOSER_PROP_USE_PREVIEW_LABEL:
-+ case GTK_FILE_CHOOSER_PROP_EXTRA_WIDGET:
-+ break;
-+
- default:
- G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
- break;
-@@ -4117,24 +1860,30 @@ gtk_file_chooser_default_get_property (G
- case GTK_FILE_CHOOSER_PROP_LOCAL_ONLY:
- g_value_set_boolean (value, impl->local_only);
- break;
-+ case GTK_FILE_CHOOSER_PROP_SELECT_MULTIPLE:
-+ g_value_set_boolean (value, impl->select_multiple);
-+ break;
-+ case GTK_FILE_CHOOSER_PROP_SHOW_HIDDEN:
-+ g_value_set_boolean (value, impl->show_hidden);
-+ break;
-+ case GTK_FILE_CHOOSER_PROP_ROOT_FOLDER:
-+ g_value_set_string (value, impl->root_folder);
-+ break;
-+
-+ /* These are not supported */
- case GTK_FILE_CHOOSER_PROP_PREVIEW_WIDGET:
-- g_value_set_object (value, impl->preview_widget);
-+ g_value_set_object (value, NULL);
- break;
- case GTK_FILE_CHOOSER_PROP_PREVIEW_WIDGET_ACTIVE:
-- g_value_set_boolean (value, impl->preview_widget_active);
-+ g_value_set_boolean (value, FALSE);
- break;
- case GTK_FILE_CHOOSER_PROP_USE_PREVIEW_LABEL:
-- g_value_set_boolean (value, impl->use_preview_label);
-+ g_value_set_boolean (value, FALSE);
- break;
- case GTK_FILE_CHOOSER_PROP_EXTRA_WIDGET:
-- g_value_set_object (value, impl->extra_widget);
-- break;
-- case GTK_FILE_CHOOSER_PROP_SELECT_MULTIPLE:
-- g_value_set_boolean (value, impl->select_multiple);
-- break;
-- case GTK_FILE_CHOOSER_PROP_SHOW_HIDDEN:
-- g_value_set_boolean (value, impl->show_hidden);
-+ g_value_set_object (value, NULL);
- break;
-+
- default:
- G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
- break;
-@@ -4162,12 +1911,6 @@ gtk_file_chooser_default_dispose (GObjec
- {
- GtkFileChooserDefault *impl = (GtkFileChooserDefault *) object;
-
-- if (impl->extra_widget)
-- {
-- g_object_unref (impl->extra_widget);
-- impl->extra_widget = NULL;
-- }
--
- remove_settings_signal (impl, gtk_widget_get_screen (GTK_WIDGET (impl)));
-
- G_OBJECT_CLASS (parent_class)->dispose (object);
-@@ -4180,12 +1923,7 @@ gtk_file_chooser_default_dispose (GObjec
- static void
- gtk_file_chooser_default_show_all (GtkWidget *widget)
- {
-- GtkFileChooserDefault *impl = (GtkFileChooserDefault *) widget;
--
- gtk_widget_show (widget);
--
-- if (impl->extra_widget)
-- gtk_widget_show_all (impl->extra_widget);
- }
-
- /* Handler for GtkWindow::set-focus; this is where we save the last-focused
-@@ -4244,7 +1982,6 @@ change_icon_theme (GtkFileChooserDefault
- else
- impl->icon_size = FALLBACK_ICON_SIZE;
-
-- shortcuts_reload_icons (impl);
- gtk_widget_queue_resize (impl->browse_files_tree_view);
- }
-
-@@ -4380,8 +2117,6 @@ gtk_file_chooser_default_map (GtkWidget
- pending_select_paths_store_selection (impl);
- change_folder_and_display_error (impl, impl->current_folder);
- }
--
-- bookmarks_changed_cb (impl->file_system, impl);
- }
-
- static gboolean
-@@ -4668,18 +2403,21 @@ show_and_select_paths (GtkFileChooserDef
- GtkFileFolder *folder;
- gboolean success;
- gboolean have_hidden;
-- gboolean have_filtered;
-
- if (!only_one_path && !paths)
- return TRUE;
-
-+#ifdef GTK26
- folder = gtk_file_system_get_folder (impl->file_system, parent_path, GTK_FILE_INFO_IS_HIDDEN, error);
-+#else
-+ folder = gtk_file_system_get_folder (impl->file_system, parent_path, GTK_FILE_INFO_IS_HIDDEN, NULL, NULL);
-+#endif
-+
- if (!folder)
- return FALSE;
-
- success = FALSE;
- have_hidden = FALSE;
-- have_filtered = FALSE;
-
- if (only_one_path)
- {
-@@ -4690,7 +2428,6 @@ show_and_select_paths (GtkFileChooserDef
- {
- success = TRUE;
- have_hidden = gtk_file_info_get_is_hidden (info);
-- have_filtered = get_is_file_filtered (impl, only_one_path, info);
- gtk_file_info_free (info);
- }
- }
-@@ -4712,12 +2449,9 @@ show_and_select_paths (GtkFileChooserDef
- if (!have_hidden)
- have_hidden = gtk_file_info_get_is_hidden (info);
-
-- if (!have_filtered)
-- have_filtered = get_is_file_filtered (impl, path, info);
--
- gtk_file_info_free (info);
-
-- if (have_hidden && have_filtered)
-+ if (have_hidden)
- break; /* we now have all the information we need */
- }
- }
-@@ -4733,9 +2467,6 @@ show_and_select_paths (GtkFileChooserDef
- if (have_hidden)
- g_object_set (impl, "show-hidden", TRUE, NULL);
-
-- if (have_filtered)
-- set_current_filter (impl, NULL);
--
- if (only_one_path)
- _gtk_file_system_model_path_do (impl->browse_files_model, only_one_path, select_func, impl);
- else
-@@ -4778,13 +2509,11 @@ pending_select_paths_process (GtkFileCho
- * that case, the chooser's selection should be what the caller expects,
- * as the user can't see that something else got selected. See bug #165264.
- *
-- * Also, we don't select the first file if we are not in OPEN mode. Doing
-- * so would change the contents of the filename entry for SAVE or
-- * CREATE_FOLDER, which is undesired; in SELECT_FOLDER, we don't want to
-- * select a *different* folder from the one into which the user just
-- * navigated.
-+ * Also, we don't select the first file if we are in SAVE or CREATE_FOLDER
-+ * modes. Doing so would change the contents of the filename entry.
- */
-- if (GTK_WIDGET_MAPPED (impl) && impl->action == GTK_FILE_CHOOSER_ACTION_OPEN)
-+ if (GTK_WIDGET_MAPPED (impl)
-+ && !(impl->action == GTK_FILE_CHOOSER_ACTION_SAVE || impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER))
- browse_files_select_first_row (impl);
- }
-
-@@ -4874,19 +2603,15 @@ update_chooser_entry (GtkFileChooserDefa
- const GtkFileInfo *info;
- GtkTreeIter iter;
- GtkTreeIter child_iter;
-- gboolean change_entry;
-
-- if (!(impl->action == GTK_FILE_CHOOSER_ACTION_SAVE || impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER))
-+ if (impl->action != GTK_FILE_CHOOSER_ACTION_SAVE)
- return;
-
- g_assert (!impl->select_multiple);
- selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (impl->browse_files_tree_view));
-
- if (!gtk_tree_selection_get_selected (selection, NULL, &iter))
-- {
-- _gtk_file_chooser_entry_set_file_part (GTK_FILE_CHOOSER_ENTRY (impl->save_file_name_entry), "");
-- return;
-- }
-+ return;
-
- gtk_tree_model_sort_convert_iter_to_child_iter (impl->sort_model,
- &child_iter,
-@@ -4894,12 +2619,7 @@ update_chooser_entry (GtkFileChooserDefa
-
- info = _gtk_file_system_model_get_info (impl->browse_files_model, &child_iter);
-
-- if (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE)
-- change_entry = !gtk_file_info_get_is_folder (info); /* We don't want the name to change when clicking on a folder... */
-- else
-- change_entry = TRUE; /* ... unless we are in CREATE_FOLDER mode */
--
-- if (change_entry)
-+ if (!gtk_file_info_get_is_folder (info))
- _gtk_file_chooser_entry_set_file_part (GTK_FILE_CHOOSER_ENTRY (impl->save_file_name_entry),
- gtk_file_info_get_display_name (info));
- }
-@@ -4938,9 +2658,6 @@ gtk_file_chooser_default_update_current_
- if (!check_is_folder (impl->file_system, path, error))
- return FALSE;
-
-- if (!_gtk_path_bar_set_path (GTK_PATH_BAR (impl->browse_path_bar), path, keep_trail, error))
-- return FALSE;
--
- if (impl->current_folder != path)
- {
- if (impl->current_folder)
-@@ -4949,17 +2666,6 @@ gtk_file_chooser_default_update_current_
- impl->current_folder = gtk_file_path_copy (path);
- }
-
-- /* Update the widgets that may trigger a folder change themselves. */
--
-- if (!impl->changing_folder)
-- {
-- impl->changing_folder = TRUE;
--
-- shortcuts_update_current_folder (impl);
--
-- impl->changing_folder = FALSE;
-- }
--
- /* Set the folder on the save entry */
-
- _gtk_file_chooser_entry_set_base_folder (GTK_FILE_CHOOSER_ENTRY (impl->save_file_name_entry),
-@@ -4973,13 +2679,7 @@ gtk_file_chooser_default_update_current_
-
- /* Refresh controls */
-
-- shortcuts_find_current_folder (impl);
--
- g_signal_emit_by_name (impl, "current-folder-changed", 0);
--
-- check_preview_change (impl);
-- bookmarks_check_add_sensitivity (impl);
--
- g_signal_emit_by_name (impl, "selection-changed", 0);
-
- return result;
-@@ -5002,7 +2702,6 @@ gtk_file_chooser_default_set_current_nam
- g_return_if_fail (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE
- || impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER);
-
-- pending_select_paths_free (impl);
- _gtk_file_chooser_entry_set_file_part (GTK_FILE_CHOOSER_ENTRY (impl->save_file_name_entry), name);
- }
-
-@@ -5141,24 +2840,13 @@ gtk_file_chooser_default_unselect_all (G
- GtkTreeSelection *selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (impl->browse_files_tree_view));
-
- gtk_tree_selection_unselect_all (selection);
-- pending_select_paths_free (impl);
- }
-
--/* Checks whether the filename entry for the Save modes contains a well-formed filename.
-- *
-- * is_well_formed_ret - whether what the user typed passes gkt_file_system_make_path()
-- *
-- * is_empty_ret - whether the file entry is totally empty
-- *
-- * is_file_part_empty_ret - whether the file part is empty (will be if user types "foobar/", and
-- * the path will be "$cwd/foobar")
-- */
--static void
-+/* Checks whether the filename entry for the Save modes contains a valid filename */
-+static GtkFilePath *
- check_save_entry (GtkFileChooserDefault *impl,
-- GtkFilePath **path_ret,
-- gboolean *is_well_formed_ret,
-- gboolean *is_empty_ret,
-- gboolean *is_file_part_empty_ret)
-+ gboolean *is_valid,
-+ gboolean *is_empty)
- {
- GtkFileChooserEntry *chooser_entry;
- const GtkFilePath *current_folder;
-@@ -5171,31 +2859,17 @@ check_save_entry (GtkFileChooserDefault
-
- chooser_entry = GTK_FILE_CHOOSER_ENTRY (impl->save_file_name_entry);
-
-- if (strlen (gtk_entry_get_text (GTK_ENTRY (chooser_entry))) == 0)
-- {
-- *path_ret = NULL;
-- *is_well_formed_ret = TRUE;
-- *is_empty_ret = TRUE;
-- *is_file_part_empty_ret = TRUE;
--
-- return;
-- }
--
-- *is_empty_ret = FALSE;
--
- current_folder = _gtk_file_chooser_entry_get_current_folder (chooser_entry);
- file_part = _gtk_file_chooser_entry_get_file_part (chooser_entry);
-
- if (!file_part || file_part[0] == '\0')
- {
-- *path_ret = gtk_file_path_copy (current_folder);
-- *is_well_formed_ret = TRUE;
-- *is_file_part_empty_ret = TRUE;
--
-- return;
-+ *is_valid = FALSE;
-+ *is_empty = TRUE;
-+ return NULL;
- }
-
-- *is_file_part_empty_ret = FALSE;
-+ *is_empty = FALSE;
-
- error = NULL;
- path = gtk_file_system_make_path (impl->file_system, current_folder, file_part, &error);
-@@ -5203,14 +2877,12 @@ check_save_entry (GtkFileChooserDefault
- if (!path)
- {
- error_building_filename_dialog (impl, current_folder, file_part, error);
-- *path_ret = NULL;
-- *is_well_formed_ret = FALSE;
--
-- return;
-+ *is_valid = FALSE;
-+ return NULL;
- }
-
-- *path_ret = path;
-- *is_well_formed_ret = TRUE;
-+ *is_valid = TRUE;
-+ return path;
- }
-
- struct get_paths_closure {
-@@ -5256,21 +2928,11 @@ gtk_file_chooser_default_get_paths (GtkF
- if (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE
- || impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER)
- {
-- gboolean is_well_formed, is_empty, is_file_part_empty;
--
-- check_save_entry (impl, &info.path_from_entry, &is_well_formed, &is_empty, &is_file_part_empty);
-+ gboolean is_valid, is_empty;
-
-- if (!is_well_formed)
-+ info.path_from_entry = check_save_entry (impl, &is_valid, &is_empty);
-+ if (!is_valid && !is_empty)
- return NULL;
--
-- if (!is_empty)
-- {
-- if (is_file_part_empty && impl->action == GTK_FILE_CHOOSER_ACTION_SAVE)
-- {
-- gtk_file_path_free (info.path_from_entry);
-- return NULL;
-- }
-- }
- }
-
- if (!info.path_from_entry || impl->select_multiple)
-@@ -5295,17 +2957,6 @@ gtk_file_chooser_default_get_paths (GtkF
- return g_slist_reverse (info.result);
- }
-
--static GtkFilePath *
--gtk_file_chooser_default_get_preview_path (GtkFileChooser *chooser)
--{
-- GtkFileChooserDefault *impl = GTK_FILE_CHOOSER_DEFAULT (chooser);
--
-- if (impl->preview_path)
-- return gtk_file_path_copy (impl->preview_path);
-- else
-- return NULL;
--}
--
- static GtkFileSystem *
- gtk_file_chooser_default_get_file_system (GtkFileChooser *chooser)
- {
-@@ -5320,9 +2971,9 @@ show_filters (GtkFileChooserDefault *imp
- gboolean show)
- {
- if (show)
-- gtk_widget_show (impl->filter_combo_hbox);
-+ gtk_widget_show (impl->filter_combo);
- else
-- gtk_widget_hide (impl->filter_combo_hbox);
-+ gtk_widget_hide (impl->filter_combo);
- }
-
- static void
-@@ -5332,6 +2983,8 @@ gtk_file_chooser_default_add_filter (Gtk
- GtkFileChooserDefault *impl = GTK_FILE_CHOOSER_DEFAULT (chooser);
- const gchar *name;
-
-+ g_debug ("adding filter");
-+
- if (g_slist_find (impl->filters, filter))
- {
- g_warning ("gtk_file_chooser_add_filter() called on filter already in list\n");
-@@ -5400,140 +3053,6 @@ gtk_file_chooser_default_list_filters (G
- return g_slist_copy (impl->filters);
- }
-
--/* Returns the position in the shortcuts tree where the nth specified shortcut would appear */
--static int
--shortcuts_get_pos_for_shortcut_folder (GtkFileChooserDefault *impl,
-- int pos)
--{
-- return pos + shortcuts_get_index (impl, SHORTCUTS_SHORTCUTS);
--}
--
--static gboolean
--gtk_file_chooser_default_add_shortcut_folder (GtkFileChooser *chooser,
-- const GtkFilePath *path,
-- GError **error)
--{
-- GtkFileChooserDefault *impl = GTK_FILE_CHOOSER_DEFAULT (chooser);
-- gboolean result;
-- int pos;
--
-- /* Test validity of path here. */
-- if (!check_is_folder (impl->file_system, path, error))
-- return FALSE;
--
-- pos = shortcuts_get_pos_for_shortcut_folder (impl, impl->num_shortcuts);
--
-- result = shortcuts_insert_path (impl, pos, FALSE, NULL, path, NULL, FALSE, error);
--
-- if (result)
-- impl->num_shortcuts++;
--
-- if (impl->shortcuts_filter_model)
-- gtk_tree_model_filter_refilter (GTK_TREE_MODEL_FILTER (impl->shortcuts_filter_model));
--
-- return result;
--}
--
--static gboolean
--gtk_file_chooser_default_remove_shortcut_folder (GtkFileChooser *chooser,
-- const GtkFilePath *path,
-- GError **error)
--{
-- GtkFileChooserDefault *impl = GTK_FILE_CHOOSER_DEFAULT (chooser);
-- int pos;
-- GtkTreeIter iter;
-- char *uri;
-- int i;
--
-- if (impl->num_shortcuts == 0)
-- goto out;
--
-- pos = shortcuts_get_pos_for_shortcut_folder (impl, 0);
-- if (!gtk_tree_model_iter_nth_child (GTK_TREE_MODEL (impl->shortcuts_model), &iter, NULL, pos))
-- g_assert_not_reached ();
--
-- for (i = 0; i < impl->num_shortcuts; i++)
-- {
-- gpointer col_data;
-- gboolean is_volume;
-- GtkFilePath *shortcut;
--
-- gtk_tree_model_get (GTK_TREE_MODEL (impl->shortcuts_model), &iter,
-- SHORTCUTS_COL_DATA, &col_data,
-- SHORTCUTS_COL_IS_VOLUME, &is_volume,
-- -1);
-- g_assert (col_data != NULL);
-- g_assert (!is_volume);
--
-- shortcut = col_data;
-- if (gtk_file_path_compare (shortcut, path) == 0)
-- {
-- shortcuts_remove_rows (impl, pos + i, 1);
-- impl->num_shortcuts--;
-- return TRUE;
-- }
--
-- if (!gtk_tree_model_iter_next (GTK_TREE_MODEL (impl->shortcuts_model), &iter))
-- g_assert_not_reached ();
-- }
--
-- out:
--
-- uri = gtk_file_system_path_to_uri (impl->file_system, path);
-- g_set_error (error,
-- GTK_FILE_CHOOSER_ERROR,
-- GTK_FILE_CHOOSER_ERROR_NONEXISTENT,
-- _("Shortcut %s does not exist"),
-- uri);
-- g_free (uri);
--
-- return FALSE;
--}
--
--static GSList *
--gtk_file_chooser_default_list_shortcut_folders (GtkFileChooser *chooser)
--{
-- GtkFileChooserDefault *impl = GTK_FILE_CHOOSER_DEFAULT (chooser);
-- int pos;
-- GtkTreeIter iter;
-- int i;
-- GSList *list;
--
-- if (impl->num_shortcuts == 0)
-- return NULL;
--
-- pos = shortcuts_get_pos_for_shortcut_folder (impl, 0);
-- if (!gtk_tree_model_iter_nth_child (GTK_TREE_MODEL (impl->shortcuts_model), &iter, NULL, pos))
-- g_assert_not_reached ();
--
-- list = NULL;
--
-- for (i = 0; i < impl->num_shortcuts; i++)
-- {
-- gpointer col_data;
-- gboolean is_volume;
-- GtkFilePath *shortcut;
--
-- gtk_tree_model_get (GTK_TREE_MODEL (impl->shortcuts_model), &iter,
-- SHORTCUTS_COL_DATA, &col_data,
-- SHORTCUTS_COL_IS_VOLUME, &is_volume,
-- -1);
-- g_assert (col_data != NULL);
-- g_assert (!is_volume);
--
-- shortcut = col_data;
-- list = g_slist_prepend (list, gtk_file_path_copy (shortcut));
--
-- if (i != impl->num_shortcuts - 1)
-- {
-- if (!gtk_tree_model_iter_next (GTK_TREE_MODEL (impl->shortcuts_model), &iter))
-- g_assert_not_reached ();
-- }
-- }
--
-- return g_slist_reverse (list);
--}
--
- /* Guesses a size based upon font sizes */
- static void
- find_good_size_from_style (GtkWidget *widget,
-@@ -5544,7 +3063,6 @@ find_good_size_from_style (GtkWidget *wi
- gint default_width, default_height;
- int font_size;
- GtkRequisition req;
-- GtkRequisition preview_req;
-
- g_assert (widget->style != NULL);
- impl = GTK_FILE_CHOOSER_DEFAULT (widget);
-@@ -5558,12 +3076,7 @@ find_good_size_from_style (GtkWidget *wi
- /* Use at least the requisition size not including the preview widget */
- gtk_widget_size_request (widget, &req);
-
-- if (impl->preview_widget_active && impl->preview_widget)
-- gtk_widget_size_request (impl->preview_box, &preview_req);
-- else
-- preview_req.width = 0;
--
-- default_width = MAX (default_width, (req.width - (preview_req.width + PREVIEW_HBOX_SPACING)));
-+ default_width = MAX (default_width, (req.width - (LIST_HBOX_SPACING)));
- default_height = MAX (default_height, req.height);
-
- *width = default_width;
-@@ -5581,8 +3094,6 @@ gtk_file_chooser_default_get_default_siz
-
- find_good_size_from_style (GTK_WIDGET (chooser_embed), default_width, default_height);
-
-- if (impl->preview_widget_active && impl->preview_widget)
-- *default_width += impl->preview_box->requisition.width + PREVIEW_HBOX_SPACING;
- }
-
- static void
-@@ -5599,16 +3110,6 @@ gtk_file_chooser_default_get_resizable_h
-
- *resize_horizontally = TRUE;
- *resize_vertically = TRUE;
--
-- if (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE ||
-- impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER)
-- {
-- if (! gtk_expander_get_expanded (GTK_EXPANDER (impl->save_expander)))
-- {
-- *resize_horizontally = FALSE;
-- *resize_vertically = FALSE;
-- }
-- }
- }
-
- struct switch_folder_closure {
-@@ -5675,84 +3176,49 @@ gtk_file_chooser_default_should_respond
-
- if (current_focus == impl->browse_files_tree_view)
- {
-- /* The following array encodes what we do based on the impl->action and the
-- * number of files selected.
-- */
-- typedef enum {
-- NOOP, /* Do nothing (don't respond) */
-- RESPOND, /* Respond immediately */
-- RESPOND_OR_SWITCH, /* Respond immediately if the selected item is a file; switch to it if it is a folder */
-- ALL_FILES, /* Respond only if everything selected is a file */
-- ALL_FOLDERS, /* Respond only if everything selected is a folder */
-- SAVE_ENTRY, /* Go to the code for handling the save entry */
-- NOT_REACHED /* Sanity check */
-- } ActionToTake;
-- static const ActionToTake what_to_do[4][3] = {
-- /* 0 selected 1 selected many selected */
-- /* ACTION_OPEN */ { NOOP, RESPOND_OR_SWITCH, ALL_FILES },
-- /* ACTION_SAVE */ { SAVE_ENTRY, RESPOND_OR_SWITCH, NOT_REACHED },
-- /* ACTION_SELECT_FOLDER */ { RESPOND, ALL_FOLDERS, ALL_FOLDERS },
-- /* ACTION_CREATE_FOLDER */ { SAVE_ENTRY, ALL_FOLDERS, NOT_REACHED }
-- };
--
- int num_selected;
- gboolean all_files, all_folders;
-- int k;
-- ActionToTake action;
-
- file_list:
-
-- g_assert (impl->action >= GTK_FILE_CHOOSER_ACTION_OPEN && impl->action <= GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER);
--
- selection_check (impl, &num_selected, &all_files, &all_folders);
-
-- if (num_selected > 2)
-- k = 2;
-- else
-- k = num_selected;
--
-- action = what_to_do [impl->action] [k];
--
-- switch (action)
-+ if (impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER)
- {
-- case NOOP:
-- return FALSE;
--
-- case RESPOND:
-- return TRUE;
--
-- case RESPOND_OR_SWITCH:
-- g_assert (num_selected == 1);
--
-- if (all_folders)
-+ if (num_selected != 1)
-+ return TRUE; /* zero means current folder; more than one means use the whole selection */
-+ else if (current_focus != impl->browse_files_tree_view)
- {
-- switch_to_selected_folder (impl);
-- return FALSE;
-+ /* a single folder is selected and a button was clicked */
-+ switch_to_selected_folder (impl);
-+ return TRUE;
- }
-- else
-- return TRUE;
--
-- case ALL_FILES:
-- return all_files;
--
-- case ALL_FOLDERS:
-- return all_folders;
-+ }
-
-- case SAVE_ENTRY:
-- goto save_entry;
-+ if (num_selected == 0)
-+ {
-+ if (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE
-+ || impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER)
-+ goto save_entry; /* it makes sense to use the typed name */
-+ else
-+ return FALSE;
-+ }
-
-- default:
-- g_assert_not_reached ();
-+ if (num_selected == 1 && all_folders)
-+ {
-+ switch_to_selected_folder (impl);
-+ return FALSE;
- }
-+ else
-+ return all_files;
- }
- else if (current_focus == impl->save_file_name_entry)
- {
- GtkFilePath *path;
-- gboolean is_well_formed, is_empty, is_file_part_empty;
-+ gboolean is_valid, is_empty;
- gboolean is_folder;
- gboolean retval;
-- GtkFileChooserEntry *entry;
-- GError *error;
-+ GtkFileChooserEntry *entry;
-
- save_entry:
-
-@@ -5760,103 +3226,39 @@ gtk_file_chooser_default_should_respond
- || impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER);
-
- entry = GTK_FILE_CHOOSER_ENTRY (impl->save_file_name_entry);
-- check_save_entry (impl, &path, &is_well_formed, &is_empty, &is_file_part_empty);
-+ path = check_save_entry (impl, &is_valid, &is_empty);
-
-- if (is_empty || !is_well_formed)
-+ if (!is_empty && !is_valid)
- return FALSE;
-
-- g_assert (path != NULL);
--
-- error = NULL;
-- is_folder = check_is_folder (impl->file_system, path, &error);
-+ if (is_empty)
-+ path = gtk_file_path_copy (_gtk_file_chooser_entry_get_current_folder (entry));
-+
-+ is_folder = check_is_folder (impl->file_system, path, NULL);
- if (is_folder)
- {
-- if (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE)
-- {
-- _gtk_file_chooser_entry_set_file_part (entry, "");
-- change_folder_and_display_error (impl, path);
-- retval = FALSE;
-- }
-- else /* GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER */
-- {
-- /* The folder already exists, so we do not need to create it.
-- * Just respond to terminate the dialog.
-- */
-- retval = TRUE;
-- }
-+ _gtk_file_chooser_entry_set_file_part (entry, "");
-+ change_folder_and_display_error (impl, path);
-+ retval = FALSE;
- }
- else
- {
-- if (impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER
-- && g_error_matches (error, GTK_FILE_SYSTEM_ERROR, GTK_FILE_SYSTEM_ERROR_NOT_FOLDER))
-+ /* check that everything up to the last component exists */
-+ gtk_file_path_free (path);
-+ path = gtk_file_path_copy (_gtk_file_chooser_entry_get_current_folder (entry));
-+ is_folder = check_is_folder (impl->file_system, path, NULL);
-+ if (!is_folder)
- {
-- /* Oops, the user typed the name of an existing path which is not a folder */
-- error_creating_folder_over_existing_file_dialog (impl, path, error);
-- error = NULL; /* as it will be freed below for the general case */
-+ change_folder_and_display_error (impl, path);
- retval = FALSE;
- }
- else
-- {
-- GtkFilePath *parent_path;
--
-- /* check that everything up to the last component exists */
--
-- parent_path = gtk_file_path_copy (_gtk_file_chooser_entry_get_current_folder (entry));
-- is_folder = check_is_folder (impl->file_system, parent_path, NULL);
-- if (is_folder)
-- {
-- if (impl->action == GTK_FILE_CHOOSER_ACTION_SAVE)
-- retval = TRUE;
-- else /* GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER */
-- {
-- GError *create_error;
--
-- create_error = NULL;
-- if (gtk_file_system_create_folder (impl->file_system, path, &create_error))
-- retval = TRUE;
-- else
-- {
-- error_creating_folder_dialog (impl, path, create_error);
-- retval = FALSE;
-- }
-- }
-- }
-- else
-- {
-- /* This will display an error, which is what we want */
-- change_folder_and_display_error (impl, parent_path);
-- retval = FALSE;
-- }
--
-- gtk_file_path_free (parent_path);
-- }
--
-- if (error != NULL)
-- g_error_free (error);
-+ retval = TRUE;
- }
-
- gtk_file_path_free (path);
- return retval;
- }
-- else if (impl->toplevel_last_focus_widget == impl->browse_shortcuts_tree_view)
-- {
-- /* The focus is on a dialog's action area button, *and* the widget that
-- * was focused immediately before it is the shortcuts list. Switch to the
-- * selected shortcut and tell the caller not to respond.
-- */
-- GtkTreeIter iter;
--
-- if (shortcuts_get_selected (impl, &iter))
-- {
-- shortcuts_activate_iter (impl, &iter);
--
-- gtk_widget_grab_focus (impl->browse_files_tree_view);
-- }
-- else
-- goto file_list;
--
-- return FALSE;
-- }
- else if (impl->toplevel_last_focus_widget == impl->browse_files_tree_view)
- {
- /* The focus is on a dialog's action area button, *and* the widget that
-@@ -5944,199 +3346,6 @@ filter_combo_changed (GtkComboBox
- set_current_filter (impl, new_filter);
- }
-
--static void
--check_preview_change (GtkFileChooserDefault *impl)
--{
-- GtkTreePath *cursor_path;
-- const GtkFilePath *new_path;
-- const GtkFileInfo *new_info;
--
-- gtk_tree_view_get_cursor (GTK_TREE_VIEW (impl->browse_files_tree_view), &cursor_path, NULL);
-- if (cursor_path && impl->sort_model)
-- {
-- GtkTreeIter iter;
-- GtkTreeIter child_iter;
--
-- gtk_tree_model_get_iter (GTK_TREE_MODEL (impl->sort_model), &iter, cursor_path);
-- gtk_tree_path_free (cursor_path);
--
-- gtk_tree_model_sort_convert_iter_to_child_iter (impl->sort_model, &child_iter, &iter);
--
-- new_path = _gtk_file_system_model_get_path (impl->browse_files_model, &child_iter);
-- new_info = _gtk_file_system_model_get_info (impl->browse_files_model, &child_iter);
-- }
-- else
-- {
-- new_path = NULL;
-- new_info = NULL;
-- }
--
-- if (new_path != impl->preview_path &&
-- !(new_path && impl->preview_path &&
-- gtk_file_path_compare (new_path, impl->preview_path) == 0))
-- {
-- if (impl->preview_path)
-- {
-- gtk_file_path_free (impl->preview_path);
-- g_free (impl->preview_display_name);
-- }
--
-- if (new_path)
-- {
-- impl->preview_path = gtk_file_path_copy (new_path);
-- impl->preview_display_name = g_strdup (gtk_file_info_get_display_name (new_info));
-- }
-- else
-- {
-- impl->preview_path = NULL;
-- impl->preview_display_name = NULL;
-- }
--
-- if (impl->use_preview_label && impl->preview_label)
-- gtk_label_set_text (GTK_LABEL (impl->preview_label), impl->preview_display_name);
--
-- g_signal_emit_by_name (impl, "update-preview");
-- }
--}
--
--/* Activates a volume by mounting it if necessary and then switching to its
-- * base path.
-- */
--static void
--shortcuts_activate_volume (GtkFileChooserDefault *impl,
-- GtkFileSystemVolume *volume)
--{
-- GtkFilePath *path;
--
-- /* We ref the file chooser since volume_mount() may run a main loop, and the
-- * user could close the file chooser window in the meantime.
-- */
-- g_object_ref (impl);
--
-- if (!gtk_file_system_volume_get_is_mounted (impl->file_system, volume))
-- {
-- GError *error;
-- gboolean result;
--
-- set_busy_cursor (impl, TRUE);
--
-- error = NULL;
-- result = gtk_file_system_volume_mount (impl->file_system, volume, &error);
--
-- if (!result)
-- {
-- char *msg;
--
-- msg = g_strdup_printf (_("Could not mount %s"),
-- gtk_file_system_volume_get_display_name (impl->file_system, volume));
-- error_message (impl, msg, error->message);
-- g_free (msg);
-- g_error_free (error);
-- }
--
-- set_busy_cursor (impl, FALSE);
--
-- if (!result)
-- goto out;
-- }
--
-- path = gtk_file_system_volume_get_base_path (impl->file_system, volume);
-- change_folder_and_display_error (impl, path);
-- gtk_file_path_free (path);
--
-- out:
--
-- g_object_unref (impl);
--}
--
--/* Opens the folder or volume at the specified iter in the shortcuts model */
--static void
--shortcuts_activate_iter (GtkFileChooserDefault *impl,
-- GtkTreeIter *iter)
--{
-- gpointer col_data;
-- gboolean is_volume;
--
-- gtk_tree_model_get (GTK_TREE_MODEL (impl->shortcuts_model), iter,
-- SHORTCUTS_COL_DATA, &col_data,
-- SHORTCUTS_COL_IS_VOLUME, &is_volume,
-- -1);
--
-- if (!col_data)
-- return; /* We are on a separator */
--
-- if (is_volume)
-- {
-- GtkFileSystemVolume *volume;
--
-- volume = col_data;
--
-- shortcuts_activate_volume (impl, volume);
-- }
-- else
-- {
-- const GtkFilePath *file_path;
--
-- file_path = col_data;
-- change_folder_and_display_error (impl, file_path);
-- }
--}
--
--/* Callback used when a row in the shortcuts list is activated */
--static void
--shortcuts_row_activated_cb (GtkTreeView *tree_view,
-- GtkTreePath *path,
-- GtkTreeViewColumn *column,
-- GtkFileChooserDefault *impl)
--{
-- GtkTreeIter iter;
-- GtkTreeIter child_iter;
--
-- if (!gtk_tree_model_get_iter (impl->shortcuts_filter_model, &iter, path))
-- return;
--
-- gtk_tree_model_filter_convert_iter_to_child_iter (GTK_TREE_MODEL_FILTER (impl->shortcuts_filter_model),
-- &child_iter,
-- &iter);
-- shortcuts_activate_iter (impl, &child_iter);
--
-- gtk_widget_grab_focus (impl->browse_files_tree_view);
--}
--
--/* Handler for GtkWidget::key-press-event on the shortcuts list */
--static gboolean
--shortcuts_key_press_event_cb (GtkWidget *widget,
-- GdkEventKey *event,
-- GtkFileChooserDefault *impl)
--{
-- guint modifiers;
--
-- modifiers = gtk_accelerator_get_default_mod_mask ();
--
-- if ((event->keyval == GDK_BackSpace
-- || event->keyval == GDK_Delete
-- || event->keyval == GDK_KP_Delete)
-- && (event->state & modifiers) == 0)
-- {
-- remove_selected_bookmarks (impl);
-- return TRUE;
-- }
--
-- return FALSE;
--}
--
--static gboolean
--shortcuts_select_func (GtkTreeSelection *selection,
-- GtkTreeModel *model,
-- GtkTreePath *path,
-- gboolean path_currently_selected,
-- gpointer data)
--{
-- GtkFileChooserDefault *impl = data;
--
-- return (*gtk_tree_path_get_indices (path) != shortcuts_get_index (impl, SHORTCUTS_BOOKMARKS_SEPARATOR));
--}
--
- static gboolean
- list_select_func (GtkTreeSelection *selection,
- GtkTreeModel *model,
-@@ -6180,7 +3389,7 @@ list_selection_changed (GtkTreeSelection
- g_assert (!impl->select_multiple);
- selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (impl->browse_files_tree_view));
- if (!gtk_tree_selection_get_selected (selection, NULL, &iter))
-- goto out; /* normal processing */
-+ return;
-
- gtk_tree_model_sort_convert_iter_to_child_iter (impl->sort_model,
- &child_iter,
-@@ -6191,11 +3400,7 @@ list_selection_changed (GtkTreeSelection
- return; /* We are on the editable row for New Folder */
- }
-
-- out:
--
- update_chooser_entry (impl);
-- check_preview_change (impl);
-- bookmarks_check_add_sensitivity (impl);
-
- g_signal_emit_by_name (impl, "selection-changed", 0);
- }
-@@ -6232,23 +3437,6 @@ list_row_activated (GtkTreeView
- g_signal_emit_by_name (impl, "file-activated");
- }
-
--static void
--path_bar_clicked (GtkPathBar *path_bar,
-- GtkFilePath *file_path,
-- gboolean child_is_hidden,
-- GtkFileChooserDefault *impl)
--{
-- if (!change_folder_and_display_error (impl, file_path))
-- return;
--
-- /* Say we have "/foo/bar/[.baz]" and the user clicks on "bar". We should then
-- * show hidden files so that ".baz" appears in the file list, as it will still
-- * be shown in the path bar: "/foo/[bar]/.baz"
-- */
-- if (child_is_hidden)
-- g_object_set (impl, "show-hidden", TRUE, NULL);
--}
--
- static const GtkFileInfo *
- get_list_file_info (GtkFileChooserDefault *impl,
- GtkTreeIter *iter)
-@@ -6415,33 +3603,31 @@ list_mtime_data_func (GtkTreeViewColumn
-
- time_mtime = gtk_file_info_get_modification_time (info);
-
-- if (time_mtime == 0)
-- strcpy (buf, _("Unknown"));
-- else
-- {
-- g_date_set_time (&mtime, (GTime) time_mtime);
-+#ifdef GTK26
-+ g_date_set_time (&mtime, (GTime) time_mtime);
-+#else
-+ g_date_set_time_t (&mtime, time_mtime);
-+#endif
-+ time_now = (GTime ) time (NULL);
-+ g_date_set_time (&now, (GTime) time_now);
-
-- time_now = (GTime ) time (NULL);
-- g_date_set_time (&now, (GTime) time_now);
-+ days_diff = g_date_get_julian (&now) - g_date_get_julian (&mtime);
-
-- days_diff = g_date_get_julian (&now) - g_date_get_julian (&mtime);
-+ if (days_diff == 0)
-+ strcpy (buf, _("Today"));
-+ else if (days_diff == 1)
-+ strcpy (buf, _("Yesterday"));
-+ else
-+ {
-+ char *format;
-
-- if (days_diff == 0)
-- strcpy (buf, _("Today"));
-- else if (days_diff == 1)
-- strcpy (buf, _("Yesterday"));
-+ if (days_diff > 1 && days_diff < 7)
-+ format = "%A"; /* Days from last week */
- else
-- {
-- char *format;
--
-- if (days_diff > 1 && days_diff < 7)
-- format = "%A"; /* Days from last week */
-- else
-- format = "%x"; /* Any other date */
-+ format = "%x"; /* Any other date */
-
-- if (g_date_strftime (buf, sizeof (buf), format, &mtime) == 0)
-- strcpy (buf, _("Unknown"));
-- }
-+ if (g_date_strftime (buf, sizeof (buf), format, &mtime) == 0)
-+ strcpy (buf, _("Unknown"));
- }
-
- if (impl->action == GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER ||
-@@ -6534,8 +3720,11 @@ update_from_entry (GtkFileChooserDefault
- */
-
- error = NULL;
-+#ifdef GTK26
- folder = gtk_file_system_get_folder (impl->file_system, folder_path, GTK_FILE_INFO_IS_FOLDER, &error);
--
-+#else
-+ folder = gtk_file_system_get_folder (impl->file_system, folder_path, GTK_FILE_INFO_IS_FOLDER, NULL, NULL);
-+#endif
- if (!folder)
- {
- error_getting_info_dialog (impl, folder_path, error);
-@@ -6645,8 +3834,8 @@ location_popup_handler (GtkFileChooserDe
- accept_stock, GTK_RESPONSE_ACCEPT,
- NULL);
- gtk_window_set_default_size (GTK_WINDOW (dialog), 300, -1);
-- gtk_container_set_border_width (GTK_CONTAINER (dialog), 5);
-- gtk_box_set_spacing (GTK_BOX (GTK_DIALOG (dialog)->vbox), 2);
-+ gtk_container_set_border_width (GTK_CONTAINER (dialog), DEFAULT_SPACING);
-+ gtk_box_set_spacing (GTK_BOX (GTK_DIALOG (dialog)->vbox), DEFAULT_SPACING);
- gtk_dialog_set_default_response (GTK_DIALOG (dialog), GTK_RESPONSE_ACCEPT);
-
- gtk_dialog_set_alternative_button_order (GTK_DIALOG (dialog),
-@@ -6654,17 +3843,16 @@ location_popup_handler (GtkFileChooserDe
- GTK_RESPONSE_CANCEL,
- -1);
-
-- hbox = gtk_hbox_new (FALSE, 12);
-+ hbox = gtk_hbox_new (FALSE, DEFAULT_SPACING);
- gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), hbox, FALSE, FALSE, 0);
- gtk_container_set_border_width (GTK_CONTAINER (hbox), 5);
-
-- label = gtk_label_new_with_mnemonic (_("_Location:"));
-+ label = gtk_label_new (_("Location:"));
- gtk_box_pack_start (GTK_BOX (hbox), label, FALSE, FALSE, 0);
-
- entry = location_entry_create (impl, path);
-
- gtk_box_pack_start (GTK_BOX (hbox), entry, TRUE, TRUE, 0);
-- gtk_label_set_mnemonic_widget (GTK_LABEL (label), entry);
-
- /* Run */
-
-@@ -6713,115 +3901,68 @@ location_popup_handler (GtkFileChooserDe
- static void
- up_folder_handler (GtkFileChooserDefault *impl)
- {
-+ GtkFilePath * parent;
- pending_select_paths_add (impl, impl->current_folder);
-- _gtk_path_bar_up (GTK_PATH_BAR (impl->browse_path_bar));
-+
-+ if (gtk_file_system_get_parent (impl->file_system, impl->current_folder,
-+ &parent, NULL) && parent)
-+ {
-+ impl->path_history = g_slist_prepend (impl->path_history,
-+ gtk_file_path_copy (impl->current_folder));
-+
-+ change_folder_and_display_error (impl, parent);
-+ gtk_file_path_free (parent);
-+ }
- }
-
- /* Handler for the "down-folder" keybinding signal */
- static void
- down_folder_handler (GtkFileChooserDefault *impl)
- {
-- _gtk_path_bar_down (GTK_PATH_BAR (impl->browse_path_bar));
-+ if (impl->path_history)
-+ {
-+ const GtkFilePath * path = impl->path_history->data;
-+
-+ change_folder_and_display_error (impl, path);
-+ impl->path_history = g_slist_remove (impl->path_history, path);
-+ gtk_file_path_free (path);
-+ }
- }
-
- /* Handler for the "home-folder" keybinding signal */
- static void
- home_folder_handler (GtkFileChooserDefault *impl)
- {
-- int pos;
-- GtkTreeIter iter;
--
-- if (!impl->has_home)
-- return; /* Should we put up an error dialog? */
--
-- pos = shortcuts_get_index (impl, SHORTCUTS_HOME);
-- if (!gtk_tree_model_iter_nth_child (GTK_TREE_MODEL (impl->shortcuts_model), &iter, NULL, pos))
-- g_assert_not_reached ();
--
-- shortcuts_activate_iter (impl, &iter);
--}
--
--
--
--/* Drag and drop interfaces */
--
--static void
--_shortcuts_model_filter_class_init (ShortcutsModelFilterClass *class)
--{
- }
-
--static void
--_shortcuts_model_filter_init (ShortcutsModelFilter *model)
-+static GtkFilePath *
-+gtk_file_chooser_default_get_preview_path (GtkFileChooser *chooser)
- {
-- model->impl = NULL;
-+ return NULL;
- }
-
--/* GtkTreeDragSource::row_draggable implementation for the shortcuts filter model */
- static gboolean
--shortcuts_model_filter_row_draggable (GtkTreeDragSource *drag_source,
-- GtkTreePath *path)
-+gtk_file_chooser_default_add_shortcut_folder (GtkFileChooser *chooser,
-+ const GtkFilePath *path,
-+ GError **error)
- {
-- ShortcutsModelFilter *model;
-- int pos;
-- int bookmarks_pos;
--
-- model = SHORTCUTS_MODEL_FILTER (drag_source);
--
-- pos = *gtk_tree_path_get_indices (path);
-- bookmarks_pos = shortcuts_get_index (model->impl, SHORTCUTS_BOOKMARKS);
--
-- return (pos >= bookmarks_pos && pos < bookmarks_pos + model->impl->num_bookmarks);
-+ return FALSE;
- }
-
--/* GtkTreeDragSource::drag_data_get implementation for the shortcuts filter model */
- static gboolean
--shortcuts_model_filter_drag_data_get (GtkTreeDragSource *drag_source,
-- GtkTreePath *path,
-- GtkSelectionData *selection_data)
--{
-- ShortcutsModelFilter *model;
--
-- model = SHORTCUTS_MODEL_FILTER (drag_source);
--
-- /* FIXME */
--
-- return FALSE;
--}
--
--/* Fill the GtkTreeDragSourceIface vtable */
--static void
--shortcuts_model_filter_drag_source_iface_init (GtkTreeDragSourceIface *iface)
-+gtk_file_chooser_default_remove_shortcut_folder (GtkFileChooser *chooser,
-+ const GtkFilePath *path,
-+ GError **error)
- {
-- iface->row_draggable = shortcuts_model_filter_row_draggable;
-- iface->drag_data_get = shortcuts_model_filter_drag_data_get;
-+ return TRUE;
- }
-
--#if 0
--/* Fill the GtkTreeDragDestIface vtable */
--static void
--shortcuts_model_filter_drag_dest_iface_init (GtkTreeDragDestIface *iface)
-+static GSList *
-+gtk_file_chooser_default_list_shortcut_folders (GtkFileChooser *chooser)
- {
-- iface->drag_data_received = shortcuts_model_filter_drag_data_received;
-- iface->row_drop_possible = shortcuts_model_filter_row_drop_possible;
-+ return NULL;
- }
--#endif
--
--static GtkTreeModel *
--shortcuts_model_filter_new (GtkFileChooserDefault *impl,
-- GtkTreeModel *child_model,
-- GtkTreePath *root)
--{
-- ShortcutsModelFilter *model;
--
-- model = g_object_new (SHORTCUTS_MODEL_FILTER_TYPE,
-- "child_model", child_model,
-- "virtual_root", root,
-- NULL);
-
-- model->impl = impl;
--
-- return GTK_TREE_MODEL (model);
--}
-
- #define __GTK_FILE_CHOOSER_DEFAULT_C__
- #include "gtkaliasdef.c"
diff --git a/meta/packages/gtk+/gtk+-2.6.10/filechooser-respect-style.patch b/meta/packages/gtk+/gtk+-2.6.10/filechooser-respect-style.patch
deleted file mode 100644
index 76c66a7d2..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/filechooser-respect-style.patch
+++ /dev/null
@@ -1,77 +0,0 @@
---- gtk+-2.6.8/gtk/gtkfilechooserdialog.c.orig 2007-02-09 12:18:25.000000000 +0000
-+++ gtk+-2.6.8/gtk/gtkfilechooserdialog.c 2007-02-09 12:18:25.000000000 +0000
-@@ -62,8 +62,6 @@
-
- static void gtk_file_chooser_dialog_map (GtkWidget *widget);
- static void gtk_file_chooser_dialog_unmap (GtkWidget *widget);
--static void gtk_file_chooser_dialog_style_set (GtkWidget *widget,
-- GtkStyle *previous_style);
-
- static void response_cb (GtkDialog *dialog,
- gint response_id);
-@@ -122,7 +120,6 @@
-
- widget_class->map = gtk_file_chooser_dialog_map;
- widget_class->unmap = gtk_file_chooser_dialog_unmap;
-- widget_class->style_set = gtk_file_chooser_dialog_style_set;
-
- _gtk_file_chooser_install_properties (gobject_class);
-
-@@ -135,13 +132,19 @@
- GtkFileChooserDialogPrivate *priv = G_TYPE_INSTANCE_GET_PRIVATE (dialog,
- GTK_TYPE_FILE_CHOOSER_DIALOG,
- GtkFileChooserDialogPrivate);
-+
-+ GtkDialog *fc_dialog = GTK_DIALOG (dialog);
-+
- dialog->priv = priv;
- dialog->priv->default_width = -1;
- dialog->priv->default_height = -1;
- dialog->priv->resize_horizontally = TRUE;
- dialog->priv->resize_vertically = TRUE;
-
-- gtk_dialog_set_has_separator (GTK_DIALOG (dialog), FALSE);
-+ gtk_dialog_set_has_separator (fc_dialog, FALSE);
-+ gtk_container_set_border_width (GTK_CONTAINER (fc_dialog), 5);
-+ gtk_box_set_spacing (GTK_BOX (fc_dialog->vbox), 2); /* 2 * 5 + 2 = 12 */
-+ gtk_container_set_border_width (GTK_CONTAINER (fc_dialog->action_area), 5);
-
- /* We do a signal connection here rather than overriding the method in
- * class_init because GtkDialog::response is a RUN_LAST signal. We want *our*
-@@ -394,6 +397,7 @@
- g_signal_connect (priv->widget, "default-size-changed",
- G_CALLBACK (file_chooser_widget_default_size_changed), object);
-
-+ gtk_container_set_border_width (GTK_CONTAINER (priv->widget), 5);
- gtk_box_pack_start (GTK_BOX (GTK_DIALOG (object)->vbox), priv->widget, TRUE, TRUE, 0);
-
- gtk_widget_show (priv->widget);
-@@ -522,28 +526,6 @@
- gtk_widget_unmap (priv->widget);
- }
-
--static void
--gtk_file_chooser_dialog_style_set (GtkWidget *widget,
-- GtkStyle *previous_style)
--{
-- GtkDialog *dialog;
--
-- if (GTK_WIDGET_CLASS (parent_class)->style_set)
-- GTK_WIDGET_CLASS (parent_class)->style_set (widget, previous_style);
--
-- dialog = GTK_DIALOG (widget);
--
-- /* Override the style properties with HIG-compliant spacings. Ugh.
-- * http://developer.gnome.org/projects/gup/hig/1.0/layout.html#layout-dialogs
-- * http://developer.gnome.org/projects/gup/hig/1.0/windows.html#alert-spacing
-- */
--
-- gtk_container_set_border_width (GTK_CONTAINER (dialog->vbox), 12);
-- gtk_box_set_spacing (GTK_BOX (dialog->vbox), 24);
--
-- gtk_container_set_border_width (GTK_CONTAINER (dialog->action_area), 0);
-- gtk_box_set_spacing (GTK_BOX (dialog->action_area), 6);
--}
-
- /* GtkDialog::response handler */
- static void
diff --git a/meta/packages/gtk+/gtk+-2.6.10/filesystem-volumes.patch b/meta/packages/gtk+/gtk+-2.6.10/filesystem-volumes.patch
deleted file mode 100644
index 4386d83ee..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/filesystem-volumes.patch
+++ /dev/null
@@ -1,182 +0,0 @@
---- gtk+-2.6.8/gtk/gtkfilesystemunix.c.orig 2007-02-08 12:01:19.000000000 +0000
-+++ gtk+-2.6.8/gtk/gtkfilesystemunix.c 2007-02-08 12:01:19.000000000 +0000
-@@ -33,6 +33,7 @@
- #include <errno.h>
- #include <string.h>
- #include <sys/stat.h>
-+#include <sys/statvfs.h>
- #include <sys/types.h>
- #include <pwd.h>
- #ifdef HAVE_UNISTD_H
-@@ -358,7 +359,49 @@
- static GSList *
- gtk_file_system_unix_list_volumes (GtkFileSystem *file_system)
- {
-- return g_slist_append (NULL, get_root_volume ());
-+ struct statvfs stv;
-+ struct stat st;
-+ GSList * l = g_slist_append (NULL, get_root_volume ());
-+
-+ if (!statvfs ("/.", &stv))
-+ {
-+ fsblkcnt_t root_blocks = stv.f_blocks;
-+ fsfilcnt_t root_files = stv.f_files;
-+
-+ GDir * dir;
-+ if ((dir = g_dir_open ("/media", 0, NULL)) != NULL)
-+ {
-+ const gchar * name;
-+ while ((name = g_dir_read_name (dir)) != NULL)
-+ {
-+ gchar * abs_name = g_strconcat ("/media/", name, NULL);
-+
-+ if (!stat (abs_name, &st) && S_ISDIR (st.st_mode))
-+ {
-+ gchar * dot = g_strconcat (abs_name, "/.", NULL);
-+ if (!statvfs (dot, &stv) &&
-+ (stv.f_blocks != root_blocks ||
-+ stv.f_files != root_files))
-+ {
-+ GtkFilePath * path =
-+ gtk_file_system_filename_to_path (file_system,
-+ abs_name);
-+
-+ if (path)
-+ l = g_slist_append (l, path);
-+ }
-+
-+ g_free (dot);
-+ }
-+
-+ g_free (abs_name);
-+ }
-+
-+ g_dir_close (dir);
-+ }
-+ }
-+
-+ return l;
- }
-
- static GtkFileSystemVolume *
-@@ -375,10 +418,15 @@
-
- len = strlen (filename);
-
-- if (len > 1 && filename[len - 1] == '/')
-- return g_strndup (filename, len - 1);
-- else
-- return g_memdup (filename, len + 1);
-+ if (len > 1)
-+ {
-+ gchar *c = g_utf8_prev_char (filename + len);
-+
-+ if (c && *c == '/')
-+ return g_strndup (filename, len - 1);
-+ }
-+
-+ return g_memdup (filename, len + 1);
- }
-
- static GtkFileFolder *
-@@ -590,7 +638,7 @@
- gtk_file_system_unix_volume_get_base_path (GtkFileSystem *file_system,
- GtkFileSystemVolume *volume)
- {
-- return gtk_file_path_new_dup ("/");
-+ return gtk_file_path_copy ((GtkFilePath*)volume);
- }
-
- static gboolean
-@@ -616,7 +664,32 @@
- gtk_file_system_unix_volume_get_display_name (GtkFileSystem *file_system,
- GtkFileSystemVolume *volume)
- {
-- return g_strdup (_("Filesystem")); /* Same as Nautilus */
-+ gchar * slash;
-+ gchar * path;
-+ gchar * c;
-+
-+ g_return_val_if_fail (file_system && volume, NULL);
-+
-+ path = gtk_file_system_path_to_filename (file_system, (GtkFilePath*) volume);
-+
-+ g_return_val_if_fail (path && *path, NULL);
-+
-+ if (path[0] == '/' && !path[1])
-+ return g_strdup (_("Filesystem")); /* Same as Nautilus */
-+
-+ /* Now the media volumes */
-+ /* strip trailing / if any */
-+ c = g_utf8_prev_char (path + strlen(path));
-+
-+ if (*c == '/')
-+ *c = 0;
-+
-+ slash = g_utf8_strrchr (path, -1, '/');
-+
-+ if (!slash)
-+ return g_strdup (path);
-+
-+ return g_strdup (slash + 1);
- }
-
- static IconType
-@@ -787,11 +860,54 @@
- GError **error)
- {
- GdkPixbuf *pixbuf;
-+ gchar * slash;
-+ gchar * path;
-+ gchar * c;
-+ const gchar * id = NULL;
-+
-+ g_return_val_if_fail (file_system && volume, NULL);
-+
-+ path = gtk_file_system_path_to_filename (file_system, (GtkFilePath*) volume);
-
-- pixbuf = get_cached_icon (widget, "gnome-fs-blockdev", pixel_size);
-- if (pixbuf)
-- return pixbuf;
-+ g_return_val_if_fail (path && *path, NULL);
-+
-+ if (path[0] == '/' && !path[1])
-+ id = "gnome-fs-blockdev";
-+ else
-+ {
-+ /* Now the media volumes */
-+ /* strip trailing / if any */
-+ c = g_utf8_prev_char (path + strlen(path));
-+
-+ if (*c == '/')
-+ *c = 0;
-+
-+ slash = g_utf8_strrchr (path, -1, '/');
-
-+ if (slash)
-+ {
-+ slash++;
-+
-+ if (!strcmp (slash, "card"))
-+ id = "gnome-dev-media-sdmmc";
-+ else if (!strcmp (slash, "cf"))
-+ id = "gnome-dev-media-cf";
-+ else if (!strncmp (slash, "mmc", 3))
-+ id = "gnome-dev-media-sdmmc";
-+ else if (!strcmp (slash, "usbhdd"))
-+ id = "gnome-dev-removable-usb";
-+ else
-+ id = "gnome-dev-removable";
-+ }
-+ }
-+
-+ if (id)
-+ {
-+ pixbuf = get_cached_icon (widget, id, pixel_size);
-+ if (pixbuf)
-+ return pixbuf;
-+ }
-+
- pixbuf = get_fallback_icon (widget, ICON_BLOCK_DEVICE, error);
- g_assert (pixbuf != NULL);
-
diff --git a/meta/packages/gtk+/gtk+-2.6.10/gtk+-handhelds.patch b/meta/packages/gtk+/gtk+-2.6.10/gtk+-handhelds.patch
deleted file mode 100644
index 20481f059..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/gtk+-handhelds.patch
+++ /dev/null
@@ -1,236 +0,0 @@
---- gtk+-2.4.1/gtk/gtkarrow.c 2004-03-13 09:51:13.000000000 +1100
-+++ gtk+-2.4.1/gtk/gtkarrow.c 2004-05-26 14:52:17.000000000 +1000
-@@ -29,7 +29,7 @@
- #include "gtkarrow.h"
- #include "gtkintl.h"
-
--#define MIN_ARROW_SIZE 15
-+#define MIN_ARROW_SIZE 7
-
- enum {
- PROP_0,
-@@ -53,6 +53,8 @@
- guint prop_id,
- GValue *value,
- GParamSpec *pspec);
-+static void gtk_arrow_size_request (GtkWidget *arrow,
-+ GtkRequisition *requisition);
-
- GType
- gtk_arrow_get_type (void)
-@@ -111,6 +113,7 @@
- G_PARAM_READABLE | G_PARAM_WRITABLE));
-
- widget_class->expose_event = gtk_arrow_expose;
-+ widget_class->size_request = gtk_arrow_size_request;
- }
-
- static void
-@@ -166,13 +169,18 @@
- }
-
- static void
-+gtk_arrow_size_request (GtkWidget *arrow,
-+ GtkRequisition *requisition)
-+{
-+ requisition->width = MIN_ARROW_SIZE + GTK_MISC (arrow)->xpad * 2;
-+ requisition->height = MIN_ARROW_SIZE + GTK_MISC (arrow)->ypad * 2;
-+}
-+
-+static void
- gtk_arrow_init (GtkArrow *arrow)
- {
- GTK_WIDGET_SET_FLAGS (arrow, GTK_NO_WINDOW);
-
-- GTK_WIDGET (arrow)->requisition.width = MIN_ARROW_SIZE + GTK_MISC (arrow)->xpad * 2;
-- GTK_WIDGET (arrow)->requisition.height = MIN_ARROW_SIZE + GTK_MISC (arrow)->ypad * 2;
--
- arrow->arrow_type = GTK_ARROW_RIGHT;
- arrow->shadow_type = GTK_SHADOW_OUT;
- }
---- gtk+-2.4.1/gtk/gtkcalendar.c 2004-03-06 14:37:26.000000000 +1100
-+++ gtk+-2.4.1/gtk/gtkcalendar.c 2004-05-26 14:58:57.000000000 +1000
-@@ -340,6 +340,9 @@
- static void gtk_calendar_select_and_focus_day (GtkCalendar *calendar,
- guint day);
-
-+static void gtk_calendar_do_select_day (GtkCalendar *calendar,
-+ guint day);
-+
- static void gtk_calendar_paint_arrow (GtkWidget *widget,
- guint arrow);
- static void gtk_calendar_paint_day_num (GtkWidget *widget,
-@@ -861,13 +864,13 @@
- if (month_len < calendar->selected_day)
- {
- calendar->selected_day = 0;
-- gtk_calendar_select_day (calendar, month_len);
-+ gtk_calendar_do_select_day (calendar, month_len);
- }
- else
- {
- if (calendar->selected_day < 0)
- calendar->selected_day = calendar->selected_day + 1 + month_length[leap (calendar->year)][calendar->month + 1];
-- gtk_calendar_select_day (calendar, calendar->selected_day);
-+ gtk_calendar_do_select_day (calendar, calendar->selected_day);
- }
-
- gtk_widget_queue_draw (GTK_WIDGET (calendar));
-@@ -908,10 +911,10 @@
- if (month_len < calendar->selected_day)
- {
- calendar->selected_day = 0;
-- gtk_calendar_select_day (calendar, month_len);
-+ gtk_calendar_do_select_day (calendar, month_len);
- }
- else
-- gtk_calendar_select_day (calendar, calendar->selected_day);
-+ gtk_calendar_do_select_day (calendar, calendar->selected_day);
-
- gtk_widget_queue_draw (GTK_WIDGET (calendar));
- gtk_calendar_thaw (calendar);
-@@ -939,10 +942,10 @@
- if (month_len < calendar->selected_day)
- {
- calendar->selected_day = 0;
-- gtk_calendar_select_day (calendar, month_len);
-+ gtk_calendar_do_select_day (calendar, month_len);
- }
- else
-- gtk_calendar_select_day (calendar, calendar->selected_day);
-+ gtk_calendar_do_select_day (calendar, calendar->selected_day);
-
- gtk_widget_queue_draw (GTK_WIDGET (calendar));
- gtk_calendar_thaw (calendar);
-@@ -974,10 +977,10 @@
- if (month_len < calendar->selected_day)
- {
- calendar->selected_day = 0;
-- gtk_calendar_select_day (calendar, month_len);
-+ gtk_calendar_do_select_day (calendar, month_len);
- }
- else
-- gtk_calendar_select_day (calendar, calendar->selected_day);
-+ gtk_calendar_do_select_day (calendar, calendar->selected_day);
-
- gtk_widget_queue_draw (GTK_WIDGET (calendar));
- gtk_calendar_thaw (calendar);
-@@ -2480,9 +2483,9 @@
- return TRUE;
- }
-
--void
--gtk_calendar_select_day (GtkCalendar *calendar,
-- guint day)
-+static void
-+gtk_calendar_do_select_day (GtkCalendar *calendar,
-+ guint day)
- {
- g_return_if_fail (GTK_IS_CALENDAR (calendar));
- g_return_if_fail (day <= 31);
-@@ -2499,6 +2502,13 @@
- if (GTK_WIDGET_DRAWABLE (GTK_WIDGET (calendar)))
- gtk_calendar_paint_day_num (GTK_WIDGET (calendar), selected_day);
- }
-+}
-+
-+void
-+gtk_calendar_select_day (GtkCalendar *calendar,
-+ guint day)
-+{
-+ gtk_calendar_do_select_day (calendar, day);
-
- calendar->selected_day = day;
-
---- gtk+-2.4.1/gtk/gtkentry.c 2004-04-22 08:08:08.000000000 +1000
-+++ gtk+-2.4.1/gtk/gtkentry.c 2004-05-26 14:52:17.000000000 +1000
-@@ -557,6 +557,15 @@
- 0.0,
- G_PARAM_READABLE | G_PARAM_WRITABLE));
-
-+ gtk_widget_class_install_style_property (widget_class,
-+ g_param_spec_int ("min_width",
-+ _("Minimum width"),
-+ _("Minimum width of the entry field"),
-+ 0,
-+ G_MAXINT,
-+ MIN_ENTRY_WIDTH,
-+ G_PARAM_READABLE));
-+
- signals[POPULATE_POPUP] =
- g_signal_new ("populate_popup",
- G_OBJECT_CLASS_TYPE (gobject_class),
-@@ -1124,7 +1133,7 @@
- {
- GtkEntry *entry = GTK_ENTRY (widget);
- PangoFontMetrics *metrics;
-- gint xborder, yborder;
-+ gint xborder, yborder, min_width;
- PangoContext *context;
-
- gtk_widget_ensure_style (widget);
-@@ -1140,9 +1149,11 @@
-
- xborder += INNER_BORDER;
- yborder += INNER_BORDER;
--
-+
-+ gtk_widget_style_get (widget, "min_width", &min_width, NULL);
-+
- if (entry->width_chars < 0)
-- requisition->width = MIN_ENTRY_WIDTH + xborder * 2;
-+ requisition->width = min_width + xborder * 2;
- else
- {
- gint char_width = pango_font_metrics_get_approximate_char_width (metrics);
---- gtk+-2.4.1/gtk/gtkrange.c 2004-03-06 14:38:08.000000000 +1100
-+++ gtk+-2.4.1/gtk/gtkrange.c 2004-05-26 14:52:17.000000000 +1000
-@@ -180,6 +180,7 @@
- static GtkWidgetClass *parent_class = NULL;
- static guint signals[LAST_SIGNAL];
-
-+static GdkAtom recognize_protocols_atom, atom_atom;
-
- GType
- gtk_range_get_type (void)
-@@ -220,6 +221,9 @@
- object_class = (GtkObjectClass*) class;
- widget_class = (GtkWidgetClass*) class;
-
-+ recognize_protocols_atom = gdk_atom_intern ("RECOGNIZE_PROTOCOLS", FALSE);
-+ atom_atom = gdk_atom_intern ("ATOM", FALSE);
-+
- parent_class = g_type_class_peek_parent (class);
-
- gobject_class->set_property = gtk_range_set_property;
-@@ -815,6 +819,12 @@
- &attributes, attributes_mask);
- gdk_window_set_user_data (range->event_window, range);
-
-+ gdk_property_change (range->event_window,
-+ recognize_protocols_atom,
-+ atom_atom,
-+ 32, GDK_PROP_MODE_REPLACE,
-+ NULL, 0);
-+
- widget->style = gtk_style_attach (widget->style, widget->window);
- }
-
-@@ -1186,7 +1196,7 @@
-
- /* ignore presses when we're already doing something else. */
- if (range->layout->grab_location != MOUSE_OUTSIDE)
-- return FALSE;
-+ return TRUE;
-
- range->layout->mouse_x = event->x;
- range->layout->mouse_y = event->y;
-@@ -1364,7 +1374,7 @@
- return TRUE;
- }
-
-- return FALSE;
-+ return TRUE;
- }
-
- /**
diff --git a/meta/packages/gtk+/gtk+-2.6.10/gtklabel-resize-patch b/meta/packages/gtk+/gtk+-2.6.10/gtklabel-resize-patch
deleted file mode 100644
index df2965634..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/gtklabel-resize-patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- gtk+-2.4.3/gtk/gtklabel.c~ 2004-06-11 13:50:34.000000000 +0100
-+++ gtk+-2.4.3/gtk/gtklabel.c 2004-07-05 13:33:57.000000000 +0100
-@@ -1623,6 +1623,7 @@
-
- /* We have to clear the layout, fonts etc. may have changed */
- gtk_label_clear_layout (label);
-+ gtk_widget_queue_resize (GTK_WIDGET (label));
- }
-
- static void
diff --git a/meta/packages/gtk+/gtk+-2.6.10/hardcoded_libtool.patch b/meta/packages/gtk+/gtk+-2.6.10/hardcoded_libtool.patch
deleted file mode 100644
index b2afddcc6..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/hardcoded_libtool.patch
+++ /dev/null
@@ -1,29 +0,0 @@
---- gtk+-2.6.0/configure.in.old 2005-01-01 16:23:45.000000000 +0000
-+++ gtk+-2.6.0/configure.in 2005-01-01 16:24:03.000000000 +0000
-@@ -360,7 +360,7 @@
- AC_MSG_CHECKING([Whether to write dependencies into .pc files])
- case $enable_explicit_deps in
- auto)
-- deplib_check_method=`(./libtool --config; echo eval echo \\$deplib_check_method) | sh`
-+ deplib_check_method=`($host_alias-libtool --config; echo eval echo \\$deplib_check_method) | sh`
- if test "X$deplib_check_method" = Xnone || test "x$enable_static" = xyes ; then
- enable_explicit_deps=yes
- else
-@@ -688,7 +688,7 @@
- dnl Now we check to see if our libtool supports shared lib deps
- dnl (in a rather ugly way even)
- if $dynworks; then
-- pixbuf_libtool_config="${CONFIG_SHELL-/bin/sh} ./libtool --config"
-+ pixbuf_libtool_config="${CONFIG_SHELL-/bin/sh} $host_alias-libtool --config"
- pixbuf_deplibs_check=`$pixbuf_libtool_config | \
- grep '^[[a-z_]]*check[[a-z_]]*_method=[['\''"]]' | \
- sed 's/.*[['\''"]]\(.*\)[['\''"]]$/\1/'`
-@@ -1512,7 +1512,7 @@
- #
- # We are using gmodule-no-export now, but I'm leaving the stripping
- # code in place for now, since pango and atk still require gmodule.
--export_dynamic=`(./libtool --config; echo eval echo \\$export_dynamic_flag_spec) | sh`
-+export_dynamic=`($host_alias-libtool --config; echo eval echo \\$export_dynamic_flag_spec) | sh`
- if test -n "$export_dynamic"; then
- GDK_PIXBUF_DEP_LIBS=`echo $GDK_PIXBUF_DEP_LIBS | sed -e "s/$export_dynamic//"`
- GDK_PIXBUF_XLIB_DEP_LIBS=`echo $GDK_PIXBUF_XLIB_DEP_LIBS | sed -e "s/$export_dynamic//"`
diff --git a/meta/packages/gtk+/gtk+-2.6.10/menu-deactivate.patch b/meta/packages/gtk+/gtk+-2.6.10/menu-deactivate.patch
deleted file mode 100644
index 29e665fbf..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/menu-deactivate.patch
+++ /dev/null
@@ -1,50 +0,0 @@
---- gtk+-2.4.4/gtk/gtkmenushell.c.old Thu Aug 26 23:45:28 2004
-+++ gtk+-2.4.4/gtk/gtkmenushell.c Fri Aug 27 00:13:33 2004
-@@ -37,7 +37,7 @@
- #include "gtktearoffmenuitem.h"
- #include "gtkwindow.h"
-
--#define MENU_SHELL_TIMEOUT 500
-+#define MENU_SHELL_TIMEOUT 2000
-
- enum {
- DEACTIVATE,
-@@ -156,6 +156,7 @@
- static GtkContainerClass *parent_class = NULL;
- static guint menu_shell_signals[LAST_SIGNAL] = { 0 };
-
-+static int last_crossing_time;
-
- GType
- gtk_menu_shell_get_type (void)
-@@ -418,6 +419,7 @@
- gtk_grab_add (GTK_WIDGET (menu_shell));
- menu_shell->have_grab = TRUE;
- menu_shell->active = TRUE;
-+ last_crossing_time = 0;
- }
- }
-
-@@ -545,6 +547,13 @@
- menu_shell->activate_time = 0;
- deactivate = FALSE;
- }
-+
-+ if (last_crossing_time != 0
-+ && ((event->time - last_crossing_time) < 500))
-+ {
-+ last_crossing_time = 0;
-+ deactivate = FALSE;
-+ }
-
- if (deactivate)
- {
-@@ -597,6 +606,8 @@
- if (menu_shell->active)
- {
- menu_item = gtk_get_event_widget ((GdkEvent*) event);
-+
-+ last_crossing_time = event->time;
-
- if (!menu_item ||
- (GTK_IS_MENU_ITEM (menu_item) &&
diff --git a/meta/packages/gtk+/gtk+-2.6.10/no-demos.patch b/meta/packages/gtk+/gtk+-2.6.10/no-demos.patch
deleted file mode 100644
index 2f10a30dd..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/no-demos.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- gtk+-2.4.1/Makefile.am~ 2004-01-17 22:15:56.000000000 +0000
-+++ gtk+-2.4.1/Makefile.am 2004-05-08 12:25:32.000000000 +0100
-@@ -1,6 +1,6 @@
- ## Makefile.am for GTK+
-
--SRC_SUBDIRS = gdk-pixbuf gdk gtk modules demos tests contrib
-+SRC_SUBDIRS = gdk-pixbuf gdk gtk modules tests contrib
- SUBDIRS = po po-properties $(SRC_SUBDIRS) docs build m4macros
-
- # require automake 1.4
diff --git a/meta/packages/gtk+/gtk+-2.6.10/no-xwc.patch b/meta/packages/gtk+/gtk+-2.6.10/no-xwc.patch
deleted file mode 100644
index affb4a303..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/no-xwc.patch
+++ /dev/null
@@ -1,151 +0,0 @@
-diff -urNd ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkdrawable-x11.c gtk+-2.6.0/gdk/x11/gdkdrawable-x11.c
---- ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkdrawable-x11.c 2004-11-30 14:57:14 +00:00
-+++ gtk+-2.6.0/gdk/x11/gdkdrawable-x11.c 2005-01-02 15:38:06 +00:00
-@@ -576,12 +576,14 @@
- GDK_GC_GET_XGC (gc), x, y, (XChar2b *) text, text_length / 2);
- }
- }
-+#ifdef HAVE_XWC
- else if (font->type == GDK_FONT_FONTSET)
- {
- XFontSet fontset = (XFontSet) GDK_FONT_XFONT (font);
- XmbDrawString (xdisplay, impl->xid,
- fontset, GDK_GC_GET_XGC (gc), x, y, text, text_length);
- }
-+#endif
- else
- g_error("undefined font type\n");
- }
-@@ -613,6 +615,7 @@
- GDK_GC_GET_XGC (gc), x, y, text_8bit, text_length);
- g_free (text_8bit);
- }
-+#ifdef HAVE_XWC
- else if (font->type == GDK_FONT_FONTSET)
- {
- if (sizeof(GdkWChar) == sizeof(wchar_t))
-@@ -633,6 +636,7 @@
- g_free (text_wchar);
- }
- }
-+#endif
- else
- g_error("undefined font type\n");
- }
-diff -urNd ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkfont-x11.c gtk+-2.6.0/gdk/x11/gdkfont-x11.c
---- ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkfont-x11.c 2004-08-26 01:23:46 +01:00
-+++ gtk+-2.6.0/gdk/x11/gdkfont-x11.c 2005-01-02 15:45:39 +00:00
-@@ -525,10 +525,12 @@
- width = XTextWidth16 (xfont, (XChar2b *) text, text_length / 2);
- }
- break;
-+#ifdef HAVE_XWC
- case GDK_FONT_FONTSET:
- fontset = (XFontSet) private->xfont;
- width = XmbTextEscapement (fontset, text, text_length);
- break;
-+#endif
- default:
- width = 0;
- }
-@@ -578,6 +580,7 @@
- width = 0;
- }
- break;
-+#ifdef HAVE_XWC
- case GDK_FONT_FONTSET:
- if (sizeof(GdkWChar) == sizeof(wchar_t))
- {
-@@ -595,6 +598,7 @@
- g_free (text_wchar);
- }
- break;
-+#endif
- default:
- width = 0;
- }
-@@ -667,6 +671,7 @@
- if (descent)
- *descent = overall.descent;
- break;
-+#ifdef HAVE_XWC
- case GDK_FONT_FONTSET:
- fontset = (XFontSet) private->xfont;
- XmbTextExtents (fontset, text, text_length, &ink, &logical);
-@@ -681,6 +686,7 @@
- if (descent)
- *descent = ink.y + ink.height;
- break;
-+#endif
- }
-
- }
-@@ -753,6 +759,7 @@
- *descent = overall.descent;
- break;
- }
-+#ifdef HAVE_XWC
- case GDK_FONT_FONTSET:
- fontset = (XFontSet) private->xfont;
-
-@@ -780,6 +787,7 @@
- if (descent)
- *descent = ink.y + ink.height;
- break;
-+#endif
- }
-
- }
-diff -urNd ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkim-x11.c gtk+-2.6.0/gdk/x11/gdkim-x11.c
---- ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkim-x11.c 2004-11-17 00:55:10 +00:00
-+++ gtk+-2.6.0/gdk/x11/gdkim-x11.c 2005-01-02 15:42:04 +00:00
-@@ -48,6 +48,7 @@
- void
- _gdk_x11_initialize_locale (void)
- {
-+#ifdef HAVE_XWC
- wchar_t result;
- gchar *current_locale;
- static char *last_locale = NULL;
-@@ -93,7 +94,8 @@
- GDK_NOTE (XIM,
- g_message ("%s multi-byte string functions.",
- gdk_use_mb ? "Using" : "Not using"));
--
-+#endif
-+
- return;
- }
-
-@@ -136,6 +138,7 @@
- {
- gchar *mbstr;
-
-+#ifdef HAVE_XWC
- if (gdk_use_mb)
- {
- GdkDisplay *display = find_a_display ();
-@@ -178,6 +181,7 @@
- XFree (tpr.value);
- }
- else
-+#endif
- {
- gint length = 0;
- gint i;
-@@ -210,6 +214,7 @@
- gint
- gdk_mbstowcs (GdkWChar *dest, const gchar *src, gint dest_max)
- {
-+#ifdef HAVE_XWC
- if (gdk_use_mb)
- {
- GdkDisplay *display = find_a_display ();
-@@ -242,6 +247,7 @@
- return len_cpy;
- }
- else
-+#endif
- {
- gint i;
-
diff --git a/meta/packages/gtk+/gtk+-2.6.10/range-no-redraw.patch b/meta/packages/gtk+/gtk+-2.6.10/range-no-redraw.patch
deleted file mode 100644
index d16871228..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/range-no-redraw.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-Index: gtk/gtkrange.c
-===================================================================
---- gtk/gtkrange.c (revision 18542)
-+++ gtk/gtkrange.c (working copy)
-@@ -1569,9 +1569,12 @@
-
- gtk_widget_queue_draw (GTK_WIDGET (range));
- /* This is so we don't lag the widget being scrolled. */
-+#if 0
-+ /* Disable this, the scroll bar lags a bit but the end result is that
-+ scrolling treeviews is *a lot* smoother. See GNOME #460534. */
- if (GTK_WIDGET_REALIZED (range))
- gdk_window_process_updates (GTK_WIDGET (range)->window, FALSE);
--
-+#endif
- /* Note that we don't round off to range->round_digits here.
- * that's because it's really broken to change a value
- * in response to a change signal on that value; round_digits
diff --git a/meta/packages/gtk+/gtk+-2.6.10/scroll-timings.patch b/meta/packages/gtk+/gtk+-2.6.10/scroll-timings.patch
deleted file mode 100644
index a38b21dcc..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/scroll-timings.patch
+++ /dev/null
@@ -1,15 +0,0 @@
---- gtk+-2.4.4/gtk/gtkrange.c~ 2004-08-23 01:50:22.000000000 +0100
-+++ gtk+-2.4.4/gtk/gtkrange.c 2004-08-27 15:48:49.000000000 +0100
-@@ -35,9 +35,9 @@
- #include "gtkintl.h"
- #include "gtkscrollbar.h"
-
--#define SCROLL_INITIAL_DELAY 250 /* must hold button this long before ... */
--#define SCROLL_LATER_DELAY 100 /* ... it starts repeating at this rate */
--#define UPDATE_DELAY 300 /* Delay for queued update */
-+#define SCROLL_INITIAL_DELAY 500 /* must hold button this long before ... */
-+#define SCROLL_LATER_DELAY 200 /* ... it starts repeating at this rate */
-+#define UPDATE_DELAY 1000 /* Delay for queued update */
-
- enum {
- PROP_0,
diff --git a/meta/packages/gtk+/gtk+-2.6.10/smaller-filechooser.patch b/meta/packages/gtk+/gtk+-2.6.10/smaller-filechooser.patch
deleted file mode 100644
index 3c6f7217e..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/smaller-filechooser.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-Index: gtkfilechooserdefault.c
-===================================================================
-RCS file: /cvs/gnome/gtk+/gtk/gtkfilechooserdefault.c,v
-retrieving revision 1.240.2.25
-diff -u -p -r1.240.2.25 gtkfilechooserdefault.c
---- gtk+/gtk/gtkfilechooserdefault.c 7 Jul 2005 17:14:09 -0000 1.240.2.25
-+++ gtk+/gtk/gtkfilechooserdefault.c 27 Oct 2006 14:22:28 -0000
-@@ -3728,6 +3728,7 @@ browse_widgets_create (GtkFileChooserDef
- GtkWidget *vbox;
- GtkWidget *hpaned;
- GtkWidget *widget;
-+ GtkWidget *shortcuts_pane;
- GtkSizeGroup *size_group;
-
- /* size group is used by the [+][-] buttons and the filter combo */
-@@ -3740,12 +3741,29 @@ browse_widgets_create (GtkFileChooserDef
- gtk_paned_set_position (GTK_PANED (hpaned), 200); /* FIXME: this sucks */
- gtk_box_pack_start (GTK_BOX (vbox), hpaned, TRUE, TRUE, 0);
-
-- widget = shortcuts_pane_create (impl, size_group);
-- gtk_paned_pack1 (GTK_PANED (hpaned), widget, FALSE, FALSE);
-+ shortcuts_pane = shortcuts_pane_create (impl, size_group);
-+ gtk_paned_pack1 (GTK_PANED (hpaned), shortcuts_pane, FALSE, FALSE);
- widget = file_pane_create (impl, size_group);
- gtk_paned_pack2 (GTK_PANED (hpaned), widget, TRUE, FALSE);
-
- g_object_unref (size_group);
-+
-+
-+ /* remove excess baggage from the filechooser for small displays */
-+
-+ /* get the columns in the tree view and remove the last column (should be Modified column) */
-+ GList *column_list;
-+ column_list = gtk_tree_view_get_columns (GTK_TREE_VIEW (impl->browse_files_tree_view));
-+ gtk_tree_view_remove_column (GTK_TREE_VIEW (impl->browse_files_tree_view), (g_list_last (column_list))->data);
-+ g_list_free (column_list);
-+
-+ /* hide the tree view headers */
-+ gtk_tree_view_set_headers_visible (GTK_TREE_VIEW (impl->browse_files_tree_view), FALSE);
-+
-+ /* hide the shortcuts pane */
-+ gtk_widget_hide (GTK_WIDGET (shortcuts_pane));
-+
-+
-
- return vbox;
- }
diff --git a/meta/packages/gtk+/gtk+-2.6.10/toggle-font.diff b/meta/packages/gtk+/gtk+-2.6.10/toggle-font.diff
deleted file mode 100644
index ad3bc6e38..000000000
--- a/meta/packages/gtk+/gtk+-2.6.10/toggle-font.diff
+++ /dev/null
@@ -1,69 +0,0 @@
-Index: gtk/gtkcellrenderertoggle.c
-===================================================================
---- gtk/gtkcellrenderertoggle.c (revision 18542)
-+++ gtk/gtkcellrenderertoggle.c (working copy)
-@@ -80,6 +80,8 @@
- typedef struct _GtkCellRendererTogglePrivate GtkCellRendererTogglePrivate;
- struct _GtkCellRendererTogglePrivate
- {
-+ gint indicator_size;
-+ GtkWidget *cached_widget;
- guint inconsistent : 1;
- };
-
-@@ -281,6 +283,27 @@
- }
-
- static void
-+on_widget_style_set (GtkWidget *widget, GtkStyle *previous, gpointer user_data)
-+{
-+ GtkCellRendererTogglePrivate *priv = user_data;
-+ PangoContext *context;
-+ PangoFontMetrics *metrics;
-+ int height;
-+
-+ context = gtk_widget_get_pango_context (widget);
-+ metrics = pango_context_get_metrics (context,
-+ widget->style->font_desc,
-+ pango_context_get_language (context));
-+
-+ height = pango_font_metrics_get_ascent (metrics) +
-+ pango_font_metrics_get_descent (metrics);
-+
-+ pango_font_metrics_unref (metrics);
-+
-+ priv->indicator_size = PANGO_PIXELS (height * 0.85);
-+}
-+
-+static void
- gtk_cell_renderer_toggle_get_size (GtkCellRenderer *cell,
- GtkWidget *widget,
- GdkRectangle *cell_area,
-@@ -291,10 +314,25 @@
- {
- gint calc_width;
- gint calc_height;
-+ GtkCellRendererTogglePrivate *priv;
-
-- calc_width = (gint) cell->xpad * 2 + TOGGLE_WIDTH;
-- calc_height = (gint) cell->ypad * 2 + TOGGLE_WIDTH;
-+ priv = GTK_CELL_RENDERER_TOGGLE_GET_PRIVATE (cell);
-
-+ if (priv->cached_widget != widget) {
-+ if (priv->cached_widget) {
-+ g_object_remove_weak_pointer (widget, &priv->cached_widget);
-+ g_signal_handlers_disconnect_by_func (priv->cached_widget, on_widget_style_set, priv);
-+ }
-+ priv->cached_widget = widget;
-+ g_object_add_weak_pointer (widget, &priv->cached_widget);
-+ g_signal_connect (widget, "style-set", on_widget_style_set, priv);
-+
-+ on_widget_style_set (widget, NULL, priv);
-+ }
-+
-+ calc_width = (gint) cell->xpad * 2 + priv->indicator_size;
-+ calc_height = (gint) cell->ypad * 2 + priv->indicator_size;
-+
- if (width)
- *width = calc_width;
-
diff --git a/meta/packages/gtk+/gtk+_2.6.10.bb b/meta/packages/gtk+/gtk+_2.6.10.bb
deleted file mode 100644
index 73e6fc395..000000000
--- a/meta/packages/gtk+/gtk+_2.6.10.bb
+++ /dev/null
@@ -1,54 +0,0 @@
-require gtk+.inc
-
-PR = "r15"
-
-SRC_URI = "ftp://ftp.gtk.org/pub/gtk/v2.6/gtk+-${PV}.tar.bz2 \
- file://no-demos.patch;patch=1 \
- file://no-xwc.patch;patch=1 \
- file://automake-lossage.patch;patch=1 \
- file://gtk+-handhelds.patch;patch=1 \
- file://hardcoded_libtool.patch;patch=1 \
- file://disable-tooltips.patch;patch=1 \
- file://gtklabel-resize-patch;patch=1 \
- file://menu-deactivate.patch;patch=1 \
- file://scroll-timings.patch;patch=1 \
- file://filesystem-volumes.patch;patch=1 \
- file://filechooser-respect-style.patch;patch=1 \
- file://filechooser-default.patch;patch=1 \
- file://toggle-font.diff;patch=1;pnum=0 \
- file://combo-arrow-size.patch;patch=1;pnum=0 \
- file://range-no-redraw.patch;patch=1;pnum=0 \
- "
-
-EXTRA_OECONF = "--without-libtiff --disable-xkb --disable-glibtest"
-
-LIBV = "2.4.0"
-LEAD_SONAME = "libgtk-x11*"
-
-
-do_configure_prepend() {
- for i in `find . -name "Makefile.am"`
- do
- sed -i -e s,-DG_DISABLE_DEPRECATED,-DSED_ROCKS_DUDES, $i
- done
-}
-
-
-PACKAGES_DYNAMIC = "gdk-pixbuf-loader-* gtk-immodule-*"
-
-python populate_packages_prepend () {
- import os.path
-
- prologue = bb.data.getVar("postinst_prologue", d, 1)
- postinst_pixbufloader = bb.data.getVar("postinst_pixbufloader", d, 1)
-
- gtk_libdir = bb.data.expand('${libdir}/gtk-2.0/${LIBV}', d)
- loaders_root = os.path.join(gtk_libdir, 'loaders')
- immodules_root = os.path.join(gtk_libdir, 'immodules')
-
- do_split_packages(d, loaders_root, '^libpixbufloader-(.*)\.so$', 'gdk-pixbuf-loader-%s', 'GDK pixbuf loader for %s', postinst_pixbufloader)
- do_split_packages(d, immodules_root, '^im-(.*)\.so$', 'gtk-immodule-%s', 'GTK input module for %s', prologue + 'gtk-query-immodules-2.0 > /etc/gtk-2.0/gtk.immodules')
-
- if (bb.data.getVar('DEBIAN_NAMES', d, 1)):
- bb.data.setVar('PKG_${PN}', 'libgtk-2.0', d)
-}
'#n8862'>8862 8863 8864 8865 8866 8867 8868 8869 8870 8871 8872 8873 8874 8875 8876 8877 8878 8879 8880 8881 8882 8883 8884 8885 8886 8887 8888 8889 8890 8891 8892 8893 8894 8895 8896 8897 8898 8899 8900 8901 8902 8903 8904 8905 8906 8907 8908 8909 8910 8911 8912 8913 8914 8915 8916 8917 8918 8919 8920 8921 8922 8923 8924 8925 8926 8927 8928 8929 8930 8931 8932 8933 8934 8935 8936 8937 8938 8939 8940 8941 8942 8943 8944 8945 8946 8947 8948 8949 8950 8951 8952 8953 8954 8955 8956 8957 8958 8959 8960 8961 8962 8963 8964 8965 8966 8967 8968 8969 8970 8971 8972 8973 8974 8975 8976 8977 8978 8979 8980 8981 8982 8983 8984 8985 8986 8987 8988 8989 8990 8991 8992 8993 8994 8995 8996 8997 8998 8999 9000 9001 9002 9003 9004 9005 9006 9007 9008 9009 9010 9011 9012 9013 9014 9015 9016 9017 9018 9019 9020 9021 9022 9023 9024 9025 9026 9027 9028 9029 9030 9031 9032 9033 9034 9035 9036 9037 9038 9039 9040 9041 9042 9043 9044 9045 9046 9047 9048 9049 9050 9051 9052 9053 9054 9055 9056 9057 9058 9059 9060 9061 9062 9063 9064 9065 9066 9067 9068 9069 9070 9071 9072 9073 9074 9075 9076 9077 9078 9079 9080 9081 9082 9083 9084 9085 9086 9087 9088 9089 9090 9091 9092 9093 9094 9095 9096 9097 9098 9099 9100 9101 9102 9103 9104 9105 9106 9107 9108 9109 9110 9111 9112 9113 9114 9115 9116 9117 9118 9119 9120 9121 9122 9123 9124 9125 9126 9127 9128 9129 9130 9131 9132 9133 9134 9135 9136 9137 9138 9139 9140 9141 9142 9143 9144 9145 9146 9147 9148 9149 9150 9151 9152 9153 9154 9155 9156 9157 9158 9159 9160 9161 9162 9163 9164 9165 9166 9167 9168 9169 9170 9171 9172 9173 9174 9175 9176 9177 9178 9179 9180 9181 9182 9183 9184 9185 9186 9187 9188 9189 9190 9191 9192 9193 9194 9195 9196 9197 9198 9199 9200 9201 9202 9203 9204 9205 9206 9207 9208 9209 9210 9211 9212 9213 9214 9215 9216 9217 9218 9219 9220 9221 9222 9223 9224 9225 9226 9227 9228 9229 9230 9231 9232 9233 9234 9235 9236 9237 9238 9239 9240 9241 9242 9243 9244 9245 9246 9247 9248 9249 9250 9251 9252 9253 9254 9255 9256 9257 9258 9259 9260 9261 9262 9263 9264 9265 9266 9267 9268 9269 9270 9271 9272 9273 9274 9275 9276 9277 9278 9279 9280 9281 9282 9283 9284 9285 9286 9287 9288 9289 9290 9291 9292 9293 9294 9295 9296 9297 9298 9299 9300 9301 9302 9303 9304 9305 9306 9307 9308 9309 9310 9311 9312 9313 9314 9315 9316 9317 9318 9319 9320 9321 9322 9323 9324 9325 9326 9327 9328 9329 9330 9331 9332 9333 9334 9335 9336 9337 9338 9339 9340 9341 9342 9343 9344 9345 9346 9347 9348 9349 9350 9351 9352 9353 9354 9355 9356 9357 9358 9359 9360 9361 9362 9363 9364 9365 9366 9367 9368 9369 9370 9371 9372 9373 9374 9375 9376 9377 9378 9379 9380 9381 9382 9383 9384 9385 9386 9387 9388 9389 9390 9391 9392 9393 9394 9395 9396 9397 9398 9399 9400 9401 9402 9403 9404 9405 9406 9407 9408 9409 9410 9411 9412 9413 9414 9415 9416 9417 9418 9419 9420 9421 9422 9423 9424 9425 9426 9427 9428 9429 9430 9431 9432 9433 9434 9435 9436 9437 9438 9439 9440 9441 9442 9443 9444 9445 9446 9447 9448 9449 9450 9451 9452 9453 9454 9455 9456 9457 9458 9459 9460 9461 9462 9463 9464 9465 9466 9467 9468 9469 9470 9471 9472 9473 9474 9475 9476 9477 9478 9479 9480 9481 9482 9483 9484 9485 9486 9487 9488 9489 9490 9491 9492 9493 9494 9495 9496 9497 9498 9499 9500 9501 9502 9503 9504 9505 9506 9507 9508 9509 9510 9511 9512 9513 9514 9515 9516 9517 9518 9519 9520 9521 9522 9523 9524 9525 9526 9527 9528 9529 9530 9531 9532 9533 9534 9535 9536 9537 9538 9539 9540 9541 9542 9543 9544 9545 9546 9547 9548 9549 9550 9551 9552 9553 9554 9555 9556 9557 9558 9559 9560 9561 9562 9563 9564 9565 9566 9567 9568 9569 9570 9571 9572 9573 9574 9575 9576 9577 9578 9579 9580 9581 9582 9583 9584 9585 9586 9587 9588 9589 9590 9591 9592 9593 9594 9595 9596 9597 9598 9599 9600 9601 9602 9603 9604 9605 9606 9607 9608 9609 9610 9611 9612 9613 9614 9615 9616 9617 9618 9619 9620 9621 9622 9623 9624 9625 9626 9627 9628 9629 9630 9631 9632 9633 9634 9635 9636 9637 9638 9639 9640 9641 9642 9643 9644 9645 9646 9647 9648 9649 9650 9651 9652 9653 9654 9655 9656 9657 9658 9659 9660 9661 9662 9663 9664 9665 9666 9667 9668 9669 9670 9671 9672 9673 9674 9675 9676 9677 9678 9679 9680 9681 9682 9683 9684 9685 9686 9687 9688 9689 9690 9691 9692 9693 9694 9695 9696 9697 9698 9699 9700 9701 9702 9703 9704 9705 9706 9707 9708 9709 9710 9711 9712 9713 9714 9715 9716 9717 9718 9719 9720 9721 9722 9723 9724 9725 9726 9727 9728 9729 9730 9731 9732 9733 9734 9735 9736 9737 9738 9739 9740 9741 9742 9743 9744 9745 9746 9747 9748 9749 9750 9751 9752 9753 9754 9755 9756 9757 9758 9759 9760 9761 9762 9763 9764 9765 9766 9767 9768 9769 9770 9771 9772 9773 9774 9775 9776 9777 9778 9779 9780 9781 9782 9783 9784 9785 9786 9787 9788 9789 9790 9791 9792 9793 9794 9795 9796 9797 9798 9799 9800 9801 9802 9803 9804 9805 9806 9807 9808 9809 9810 9811 9812 9813 9814 9815 9816 9817 9818 9819 9820 9821 9822 9823 9824 9825 9826 9827 9828 9829 9830 9831 9832 9833 9834 9835 9836 9837 9838 9839 9840 9841 9842 9843 9844 9845 9846 9847 9848 9849 9850 9851 9852 9853 9854 9855 9856 9857 9858 9859 9860 9861 9862 9863 9864 9865 9866 9867 9868 9869 9870 9871 9872 9873 9874 9875 9876 9877 9878 9879 9880 9881 9882 9883 9884 9885 9886 9887 9888 9889 9890 9891 9892 9893 9894 9895 9896 9897 9898 9899 9900 9901 9902 9903 9904 9905 9906 9907 9908 9909 9910 9911 9912 9913 9914 9915 9916 9917 9918 9919 9920 9921 9922 9923 9924 9925 9926 9927 9928 9929 9930 9931 9932 9933 9934 9935 9936 9937 9938 9939 9940 9941 9942 9943 9944 9945 9946 9947 9948 9949 9950 9951 9952 9953 9954 9955 9956 9957 9958 9959 9960 9961 9962 9963 9964 9965 9966 9967 9968 9969 9970 9971 9972 9973 9974 9975 9976 9977 9978 9979 9980 9981 9982 9983 9984 9985 9986 9987 9988 9989 9990 9991 9992 9993 9994 9995 9996 9997 9998 9999 10000 10001 10002 10003 10004 10005 10006 10007 10008 10009 10010 10011 10012 10013 10014 10015 10016 10017 10018 10019 10020 10021 10022 10023 10024 10025 10026 10027 10028 10029 10030 10031 10032 10033 10034 10035 10036 10037 10038 10039 10040 10041 10042 10043 10044 10045 10046 10047 10048 10049 10050 10051 10052 10053 10054 10055 10056 10057 10058 10059 10060 10061 10062 10063 10064 10065 10066 10067 10068 10069 10070 10071 10072 10073 10074 10075 10076 10077 10078 10079 10080 10081 10082 10083 10084 10085 10086 10087 10088 10089 10090 10091 10092 10093 10094 10095 10096 10097 10098 10099 10100 10101 10102 10103 10104 10105 10106 10107 10108 10109 10110 10111 10112 10113 10114 10115 10116 10117 10118 10119 10120 10121 10122 10123 10124 10125 10126 10127 10128 10129 10130 10131 10132 10133 10134 10135 10136 10137 10138 10139 10140 10141 10142 10143 10144 10145 10146 10147 10148 10149 10150 10151 10152 10153 10154 10155 10156 10157 10158 10159 10160 10161 10162 10163 10164 10165 10166 10167 10168 10169 10170 10171 10172 10173 10174 10175 10176 10177 10178 10179 10180 10181 10182 10183 10184 10185 10186 10187 10188 10189 10190 10191 10192 10193 10194 10195 10196 10197 10198 10199 10200 10201 10202 10203 10204 10205 10206 10207 10208 10209 10210 10211 10212 10213 10214 10215 10216 10217 10218 10219 10220 10221 10222 10223 10224 10225 10226 10227 10228 10229 10230 10231 10232 10233 10234 10235 10236 10237 10238 10239 10240 10241 10242 10243 10244 10245 10246 10247 10248 10249 10250 10251 10252 10253 10254 10255 10256 10257 10258 10259 10260 10261 10262 10263 10264 10265 10266 10267 10268 10269 10270 10271 10272 10273 10274 10275 10276 10277 10278 10279 10280 10281 10282 10283 10284 10285 10286 10287 10288 10289 10290 10291 10292 10293 10294 10295 10296 10297 10298 10299 10300 10301 10302 10303 10304 10305 10306 10307 10308 10309 10310 10311 10312 10313 10314 10315 10316 10317 10318 10319 10320 10321 10322 10323 10324 10325 10326 10327 10328 10329 10330 10331 10332 10333 10334 10335 10336 10337 10338 10339 10340 10341 10342 10343 10344 10345 10346 10347 10348 10349 10350 10351 10352 10353 10354 10355 10356 10357 10358 10359 10360 10361 10362 10363 10364 10365 10366 10367 10368 10369 10370 10371 10372 10373 10374 10375 10376 10377 10378 10379 10380 10381 10382 10383 10384 10385 10386 10387 10388 10389 10390 10391 10392 10393 10394 10395 10396 10397 10398 10399 10400 10401 10402 10403 10404 10405 10406 10407 10408 10409 10410 10411 10412 10413 10414 10415 10416 10417 10418 10419 10420 10421 10422 10423 10424 10425 10426 10427 10428 10429 10430 10431 10432 10433 10434 10435 10436 10437 10438 10439 10440 10441 10442 10443 10444 10445 10446 10447 10448 10449 10450 10451 10452 10453 10454 10455 10456 10457 10458 10459 10460 10461 10462 10463 10464 10465 10466 10467 10468 10469 10470 10471 10472 10473 10474 10475 10476 10477 10478 10479 10480 10481 10482 10483 10484 10485 10486 10487 10488 10489 10490 10491 10492 10493 10494 10495 10496 10497 10498 10499 10500 10501 10502 10503 10504 10505 10506 10507 10508 10509 10510 10511 10512 10513 10514 10515 10516 10517 10518 10519 10520 10521 10522 10523 10524 10525 10526 10527 10528 10529 10530 10531 10532 10533 10534 10535 10536 10537 10538 10539 10540 10541 10542 10543 10544 10545 10546 10547 10548 10549 10550 10551 10552 10553 10554 10555 10556 10557 10558 10559 10560 10561 10562 10563 10564 10565 10566 10567 10568 10569 10570 10571 10572 10573 10574 10575 10576 10577 10578 10579 10580 10581 10582 10583 10584 10585 10586 10587 10588 10589 10590 10591 10592 10593 10594 10595 10596 10597 10598 10599 10600 10601 10602 10603 10604 10605 10606 10607 10608 10609 10610 10611 10612 10613 10614 10615 10616 10617 10618 10619 10620 10621 10622 10623 10624 10625 10626 10627 10628 10629 10630 10631 10632 10633 10634 10635 10636 10637 10638 10639 10640 10641 10642 10643 10644 10645 10646 10647 10648 10649 10650 10651 10652 10653 10654 10655 10656 10657 10658 10659 10660 10661 10662 10663 10664 10665 10666 10667 10668 10669 10670 10671 10672 10673 10674 10675 10676 10677 10678 10679 10680 10681 10682 10683 10684 10685 10686 10687 10688 10689 10690 10691 10692 10693 10694 10695 10696 10697 10698 10699 10700 10701 10702 10703 10704 10705 10706 10707 10708 10709 10710 10711 10712 10713 10714 10715 10716 10717 10718 10719 10720 10721 10722 10723 10724 10725 10726 10727 10728 10729 10730 10731 10732 10733 10734 10735 10736 10737 10738 10739 10740 10741 10742 10743 10744 10745 10746 10747 10748 10749 10750 10751 10752 10753 10754 10755 10756 10757 10758 10759 10760 10761 10762 10763 10764 10765 10766 10767 10768 10769 10770 10771 10772 10773 10774 10775 10776 10777 10778 10779 10780 10781 10782 10783 10784 10785 10786 10787 10788 10789 10790 10791 10792 10793 10794 10795 10796 10797 10798 10799 10800 10801 10802 10803 10804 10805 10806 10807 10808 10809 10810 10811 10812 10813 10814 10815 10816 10817 10818 10819 10820 10821 10822 10823 10824 10825 10826 10827 10828 10829 10830 10831 10832 10833 10834 10835 10836 10837 10838 10839 10840 10841 10842 10843 10844 10845 10846 10847 10848 10849 10850 10851 10852 10853 10854 10855 10856 10857 10858 10859 10860 10861 10862 10863 10864 10865 10866 10867 10868 10869 10870 10871 10872 10873 10874 10875 10876 10877 10878 10879 10880 10881 10882 10883 10884 10885 10886 10887 10888 10889 10890 10891 10892 10893 10894 10895 10896 10897 10898 10899 10900 10901 10902 10903 10904 10905 10906 10907 10908 10909 10910 10911 10912 10913 10914 10915 10916 10917 10918 10919 10920 10921 10922 10923 10924 10925 10926 10927 10928 10929 10930 10931 10932 10933 10934 10935 10936 10937 10938 10939 10940 10941 10942 10943 10944 10945 10946 10947 10948 10949 10950 10951 10952 10953 10954 10955 10956 10957 10958 10959 10960 10961 10962 10963 10964 10965 10966 10967 10968 10969 10970 10971 10972 10973 10974 10975 10976 10977 10978 10979 10980 10981 10982 10983 10984 10985 10986 10987 10988 10989 10990 10991 10992 10993 10994 10995 10996 10997 10998 10999 11000 11001 11002 11003 11004 11005 11006 11007 11008 11009 11010 11011 11012 11013 11014 11015 11016 11017 11018 11019 11020 11021 11022 11023 11024 11025 11026 11027 11028 11029 11030 11031 11032 11033 11034 11035 11036 11037 11038 11039 11040 11041 11042 11043 11044 11045 11046 11047 11048 11049 11050 11051 11052 11053 11054 11055 11056 11057 11058 11059 11060 11061 11062 11063 11064 11065 11066 11067 11068 11069 11070 11071 11072 11073 11074 11075 11076 11077 11078 11079 11080 11081 11082 11083 11084 11085 11086 11087 11088 11089 11090 11091 11092 11093 11094 11095 11096 11097 11098 11099 11100 11101 11102 11103 11104 11105 11106 11107 11108 11109 11110 11111 11112 11113 11114 11115 11116 11117 11118 11119 11120 11121 11122 11123 11124 11125 11126 11127 11128 11129 11130 11131 11132 11133 11134 11135 11136 11137 11138 11139 11140 11141 11142 11143 11144 11145 11146 11147 11148 11149 11150 11151 11152 11153 11154 11155 11156 11157 11158 11159 11160 11161 11162 11163 11164 11165 11166 11167 11168 11169 11170 11171 11172 11173 11174 11175 11176 11177 11178 11179 11180 11181 11182 11183 11184 11185 11186 11187 11188 11189 11190 11191 11192 11193 11194 11195 11196 11197 11198 11199 11200 11201 11202 11203 11204 11205 11206 11207 11208 11209 11210 11211 11212 11213 11214 11215 11216 11217 11218 11219 11220 11221 11222 11223 11224 11225 11226 11227 11228 11229 11230 11231 11232 11233 11234 11235 11236 11237 11238 11239 11240 11241 11242 11243 11244 11245 11246 11247 11248 11249 11250 11251 11252 11253 11254 11255 11256 11257 11258 11259 11260 11261 11262 11263 11264 11265 11266 11267 11268 11269 11270 11271 11272 11273 11274 11275 11276 11277 11278 11279 11280 11281 11282 11283 11284 11285 11286 11287 11288 11289 11290 11291 11292 11293 11294 11295 11296 11297 11298 11299 11300 11301 11302 11303 11304 11305 11306 11307 11308 11309 11310 11311 11312 11313 11314 11315 11316 11317 11318 11319 11320 11321 11322 11323 11324 11325 11326 11327 11328 11329 11330 11331 11332 11333 11334 11335 11336 11337 11338 11339 11340 11341 11342 11343 11344 11345 11346 11347 11348 11349 11350 11351 11352 11353 11354 11355 11356 11357 11358 11359 11360 11361 11362 11363 11364 11365 11366 11367 11368 11369 11370 11371 11372 11373 11374 11375 11376 11377 11378 11379 11380 11381 11382 11383 11384 11385 11386 11387 11388 11389 11390 11391 11392 11393 11394 11395 11396 11397 11398 11399 11400 11401 11402 11403 11404 11405 11406 11407 11408 11409 11410 11411 11412 11413 11414 11415 11416 11417 11418 11419 11420 11421 11422 11423 11424 11425 11426 11427 11428 11429 11430 11431 11432 11433 11434 11435 11436 11437 11438 11439 11440 11441 11442 11443 11444 11445 11446 11447 11448 11449 11450 11451 11452 11453 11454 11455 11456 11457 11458 11459 11460 11461 11462 11463 11464 11465 11466 11467 11468 11469 11470 11471 11472 11473 11474 11475 11476 11477 11478 11479 11480 11481 11482 11483 11484 11485 11486 11487 11488 11489 11490 11491 11492 11493 11494 11495 11496 11497 11498 11499 11500 11501 11502 11503 11504 11505 11506 11507 11508 11509 11510 11511 11512 11513 11514 11515 11516 11517 11518 11519 11520 11521 11522 11523 11524 11525 11526 11527 11528 11529 11530 11531 11532 11533 11534 11535 11536 11537 11538 11539 11540 11541 11542 11543 11544 11545 11546 11547 11548 11549 11550 11551 11552 11553 11554 11555 11556 11557 11558 11559 11560 11561 11562 11563 11564 11565 11566 11567 11568 11569 11570 11571 11572 11573 11574 11575 11576 11577 11578 11579 11580 11581 11582 11583 11584 11585 11586 11587 11588 11589 11590 11591 11592 11593 11594 11595 11596 11597 11598 11599 11600 11601 11602 11603 11604 11605 11606 11607 11608 11609 11610 11611 11612 11613 11614 11615 11616 11617 11618 11619 11620 11621 11622 11623 11624 11625 11626 11627 11628 11629 11630 11631 11632 11633 11634 11635 11636 11637 11638 11639 11640 11641 11642 11643 11644 11645 11646 11647 11648 11649 11650 11651 11652 11653 11654 11655 11656 11657 11658 11659 11660 11661 11662 11663 11664 11665 11666 11667 11668 11669 11670 11671 11672 11673 11674 11675 11676 11677 11678 11679 11680 11681 11682 11683 11684 11685 11686 11687 11688 11689 11690 11691 11692 11693 11694 11695 11696 11697 11698 11699 11700 11701 11702 11703 11704 11705 11706 11707 11708 11709 11710 11711 11712 11713 11714 11715 11716 11717 11718 11719 11720 11721 11722 11723 11724 11725 11726 11727 11728 11729 11730 11731 11732 11733 11734 11735 11736 11737 11738 11739 11740 11741 11742 11743 11744 11745 11746 11747 11748 11749 11750 11751 11752 11753 11754 11755 11756 11757 11758 11759 11760 11761 11762 11763 11764 11765 11766 11767 11768 11769 11770 11771 11772 11773 11774 11775 11776 11777 11778 11779 11780 11781 11782 11783 11784 11785 11786 11787 11788 11789 11790 11791 11792 11793 11794 11795 11796 11797 11798 11799 11800 11801 11802 11803 11804 11805 11806 11807 11808 11809 11810 11811 11812 11813 11814 11815 11816 11817 11818 11819 11820 11821 11822 11823 11824 11825 11826 11827 11828 11829 11830 11831 11832 11833 11834 11835 11836 11837 11838 11839 11840 11841 11842 11843 11844 11845 11846 11847 11848 11849 11850 11851 11852 11853 11854 11855 11856 11857 11858 11859 11860 11861 11862 11863 11864 11865 11866 11867 11868 11869 11870 11871 11872 11873 11874 11875 11876 11877 11878 11879 11880 11881 11882 11883 11884 11885 11886 11887 11888 11889 11890 11891 11892 11893 11894 11895 11896 11897 11898 11899 11900 11901 11902 11903 11904 11905 11906 11907 11908 11909 11910 11911 11912 11913 11914 11915 11916 11917 11918 11919 11920 11921 11922 11923 11924 11925 11926 11927 11928 11929 11930 11931 11932 11933 11934 11935 11936 11937 11938 11939 11940 11941 11942 11943 11944 11945 11946 11947 11948 11949 11950 11951 11952 11953 11954 11955 11956 11957 11958 11959 11960 11961 11962 11963 11964 11965 11966 11967 11968 11969 11970 11971 11972 11973 11974 11975 11976 11977 11978 11979 11980 11981 11982 11983 11984 11985 11986 11987 11988 11989 11990 11991 11992 11993 11994 11995 11996 11997 11998 11999 12000 12001 12002 12003 12004 12005 12006 12007 12008 12009 12010 12011 12012 12013 12014 12015 12016 12017 12018 12019 12020 12021 12022 12023 12024 12025 12026 12027 12028 12029 12030 12031 12032 12033 12034 12035 12036 12037 12038 12039 12040 12041 12042 12043 12044 12045 12046 12047 12048 12049 12050 12051 12052 12053 12054 12055 12056 12057 12058 12059 12060 12061 12062 12063 12064 12065 12066 12067 12068 12069 12070 12071 12072 12073 12074 12075 12076 12077 12078 12079 12080 12081 12082 12083 12084 12085 12086 12087 12088 12089 12090 12091 12092 12093 12094 12095 12096 12097 12098 12099 12100 12101 12102 12103 12104 12105 12106 12107 12108 12109 12110 12111 12112 12113 12114 12115 12116 12117 12118 12119 12120 12121 12122 12123 12124 12125 12126 12127 12128 12129 12130 12131 12132 12133 12134 12135 12136 12137 12138 12139 12140 12141 12142 12143 12144 12145 12146 12147 12148 12149 12150 12151 12152 12153 12154 12155 12156 12157 12158 12159 12160 12161 12162 12163 12164 12165 12166 12167 12168 12169 12170 12171 12172 12173 12174 12175 12176 12177 12178 12179 12180 12181 12182 12183 12184 12185 12186 12187 12188 12189 12190 12191 12192 12193 12194 12195 12196 12197 12198 12199 12200 12201 12202 12203 12204 12205 12206 12207 12208 12209 12210 12211 12212 12213 12214 12215 12216 12217 12218 12219 12220 12221 12222 12223 12224 12225 12226 12227 12228 12229 12230 12231 12232 12233 12234 12235 12236 12237 12238 12239 12240 12241 12242 12243 12244 12245 12246 12247 12248 12249 12250 12251 12252 12253 12254 12255 12256 12257 12258 12259 12260 12261 12262 12263 12264 12265 12266 12267 12268 12269 12270 12271 12272 12273 12274 12275 12276 12277 12278 12279 12280 12281 12282 12283 12284 12285 12286 12287 12288 12289 12290 12291 12292 12293 12294 12295 12296 12297 12298 12299 12300 12301 12302 12303 12304 12305 12306 12307 12308 12309 12310 12311 12312 12313 12314 12315 12316 12317 12318 12319 12320 12321 12322 12323 12324 12325 12326 12327 12328 12329 12330 12331 12332 12333 12334 12335 12336 12337 12338 12339 12340 12341 12342 12343 12344 12345 12346 12347 12348 12349 12350 12351 12352 12353 12354 12355 12356 12357 12358 12359 12360 12361 12362 12363 12364 12365 12366 12367 12368 12369 12370 12371 12372 12373 12374 12375 12376 12377 12378 12379 12380 12381 12382 12383 12384 12385 12386 12387 12388 12389 12390 12391 12392 12393 12394 12395 12396 12397 12398 12399 12400 12401 12402 12403 12404 12405 12406 12407 12408 12409 12410 12411 12412 12413 12414 12415 12416 12417 12418 12419 12420 12421 12422 12423 12424 12425 12426 12427 12428 12429 12430 12431 12432 12433 12434 12435 12436 12437 12438 12439 12440 12441 12442 12443 12444 12445 12446 12447 12448 12449 12450 12451 12452 12453 12454 12455 12456 12457 12458 12459 12460 12461 12462 12463 12464 12465 12466 12467 12468 12469 12470 12471 12472 12473 12474 12475 12476 12477 12478 12479 12480 12481 12482 12483 12484 12485 12486 12487 12488 12489 12490 12491 12492 12493 12494 12495 12496 12497 12498 12499 12500 12501 12502 12503 12504 12505 12506 12507 12508 12509 12510 12511 12512 12513 12514 12515 12516 12517 12518 12519 12520 12521 12522 12523 12524 12525 12526 12527 12528 12529 12530 12531 12532 12533 12534 12535 12536 12537 12538 12539 12540 12541 12542 12543 12544 12545 12546 12547 12548 12549 12550 12551 12552 12553 12554 12555 12556 12557 12558 12559 12560 12561 12562 12563 12564 12565 12566 12567 12568 12569 12570 12571 12572 12573 12574 12575 12576 12577 12578 12579 12580 12581 12582 12583 12584 12585 12586 12587 12588 12589 12590 12591 12592 12593 12594 12595 12596 12597 12598 12599 12600 12601 12602 12603 12604 12605 12606 12607 12608 12609 12610 12611 12612 12613 12614 12615 12616 12617 12618 12619 12620 12621 12622 12623 12624 12625 12626 12627 12628 12629 12630 12631 12632 12633 12634 12635 12636 12637 12638 12639 12640 12641 12642 12643 12644 12645 12646 12647 12648 12649 12650 12651 12652 12653 12654 12655 12656 12657 12658 12659 12660 12661 12662 12663 12664 12665 12666 12667 12668 12669 12670 12671 12672 12673 12674 12675 12676 12677 12678 12679 12680 12681 12682 12683 12684 12685 12686 12687 12688 12689 12690 12691 12692 12693 12694 12695 12696 12697 12698 12699 12700 12701 12702 12703 12704 12705 12706 12707 12708 12709 12710 12711 12712 12713 12714 12715 12716 12717 12718 12719 12720 12721 12722 12723 12724 12725 12726 12727 12728 12729 12730 12731 12732 12733 12734 12735 12736 12737 12738 12739 12740 12741 12742 12743 12744 12745 12746 12747 12748 12749 12750 12751 12752 12753 12754 12755 12756 12757 12758 12759 12760 12761 12762 12763 12764 12765 12766 12767 12768 12769 12770 12771 12772 12773 12774 12775 12776 12777 12778 12779 12780 12781 12782 12783 12784 12785 12786 12787 12788 12789 12790 12791 12792 12793 12794 12795 12796 12797 12798 12799 12800 12801 12802 12803 12804 12805 12806 12807 12808 12809 12810 12811 12812 12813 12814 12815 12816 12817 12818 12819 12820 12821 12822 12823 12824 12825 12826 12827 12828 12829 12830 12831 12832 12833 12834 12835 12836 12837 12838 12839 12840 12841 12842 12843 12844 12845 12846 12847 12848 12849 12850 12851 12852 12853 12854 12855 12856 12857 12858 12859 12860 12861 12862 12863 12864 12865 12866 12867 12868 12869 12870 12871 12872 12873 12874 12875 12876 12877 12878 12879 12880 12881 12882 12883 12884 12885 12886 12887 12888 12889 12890 12891 12892 12893 12894 12895 12896 12897 12898 12899 12900 12901 12902 12903 12904 12905 12906 12907 12908 12909 12910 12911 12912 12913 12914 12915 12916 12917 12918 12919 12920 12921 12922 12923 12924 12925 12926 12927 12928 12929 12930 12931 12932 12933 12934 12935 12936 12937 12938 12939 12940 12941 12942 12943 12944 12945 12946 12947 12948 12949 12950 12951 12952 12953 12954 12955 12956 12957 12958 12959 12960 12961 12962 12963 12964 12965 12966 12967 12968 12969 12970 12971 12972 12973 12974 12975 12976 12977 12978 12979 12980 12981 12982 12983 12984 12985 12986 12987 12988 12989 12990 12991 12992 12993 12994 12995 12996 12997 12998 12999 13000 13001 13002 13003 13004 13005 13006 13007 13008 13009 13010 13011 13012 13013 13014 13015 13016 13017 13018 13019 13020 13021 13022 13023 13024 13025 13026 13027 13028 13029 13030 13031 13032 13033 13034 13035 13036 13037 13038 13039 13040 13041 13042 13043 13044 13045 13046 13047 13048 13049 13050 13051 13052 13053 13054 13055 13056 13057 13058 13059 13060 13061 13062 13063 13064 13065 13066 13067 13068 13069 13070 13071 13072 13073 13074 13075 13076 13077 13078 13079 13080 13081 13082 13083 13084 13085 13086 13087 13088 13089 13090 13091 13092 13093 13094 13095 13096 13097 13098 13099 13100 13101 13102 13103 13104 13105 13106 13107 13108 13109 13110 13111 13112 13113 13114 13115 13116 13117 13118 13119 13120 13121 13122 13123 13124 13125 13126 13127 13128 13129 13130 13131 13132 13133 13134 13135 13136 13137 13138 13139 13140 13141 13142 13143 13144 13145 13146 13147 13148 13149 13150 13151 13152 13153 13154 13155 13156 13157 13158 13159 13160 13161 13162 13163 13164 13165 13166 13167 13168 13169 13170 13171 13172 13173 13174 13175 13176 13177 13178 13179 13180 13181 13182 13183 13184 13185 13186 13187 13188 13189 13190 13191 13192 13193 13194 13195 13196 13197 13198 13199 13200 13201 13202 13203 13204 13205 13206 13207 13208 13209 13210 13211 13212 13213 13214 13215 13216 13217 13218 13219 13220 13221 13222 13223 13224 13225 13226 13227 13228 13229 13230 13231 13232 13233 13234 13235 13236 13237 13238 13239 13240 13241 13242 13243 13244 13245 13246 13247 13248 13249 13250 13251 13252 13253 13254 13255 13256 13257 13258 13259 13260 13261 13262 13263 13264 13265 13266 13267 13268 13269 13270 13271 13272 13273 13274 13275 13276 13277 13278 13279 13280 13281 13282 13283 13284 13285 13286 13287 13288 13289 13290 13291 13292 13293 13294 13295 13296 13297 13298 13299 13300 13301 13302 13303 13304 13305 13306 13307 13308 13309 13310 13311 13312 13313 13314 13315 13316 13317 13318 13319 13320 13321 13322 13323 13324 13325 13326 13327 13328 13329 13330 13331 13332 13333 13334 13335 13336 13337 13338 13339 13340 13341 13342 13343 13344 13345 13346 13347 13348 13349 13350 13351 13352 13353 13354 13355 13356 13357 13358 13359 13360 13361 13362 13363 13364 13365 13366 13367 13368 13369 13370 13371 13372 13373 13374 13375 13376 13377 13378 13379 13380 13381 13382 13383 13384 13385 13386 13387 13388 13389 13390 13391 13392 13393 13394 13395 13396 13397 13398 13399 13400 13401 13402 13403 13404 13405 13406 13407 13408 13409 13410 13411 13412 13413 13414 13415 13416 13417 13418 13419 13420 13421 13422 13423 13424 13425 13426 13427 13428 13429 13430 13431 13432 13433 13434 13435 13436 13437 13438 13439 13440 13441 13442 13443 13444 13445 13446 13447 13448 13449 13450 13451 13452 13453 13454 13455 13456 13457 13458 13459 13460 13461 13462 13463 13464 13465 13466 13467 13468 13469 13470 13471 13472 13473 13474 13475 13476 13477 13478 13479 13480 13481 13482 13483 13484 13485 13486 13487 13488 13489 13490 13491 13492 13493 13494 13495 13496 13497 13498 13499 13500 13501 13502 13503 13504 13505 13506 13507 13508 13509 13510 13511 13512 13513 13514 13515 13516 13517 13518 13519 13520 13521 13522 13523 13524 13525 13526 13527 13528 13529 13530 13531 13532 13533 13534 13535 13536 13537 13538 13539 13540 13541 13542 13543 13544 13545 13546 13547 13548 13549 13550 13551 13552 13553 13554 13555 13556 13557 13558 13559 13560 13561 13562 13563 13564 13565 13566 13567 13568 13569 13570 13571 13572 13573 13574 13575 13576 13577 13578 13579 13580 13581 13582 13583 13584 13585 13586 13587 13588 13589 13590 13591 13592 13593 13594 13595 13596 13597 13598 13599 13600 13601 13602 13603 13604 13605 13606 13607 13608 13609 13610 13611 13612 13613 13614 13615 13616 13617 13618 13619 13620 13621 13622 13623 13624 13625 13626 13627 13628 13629 13630 13631 13632 13633 13634 13635 13636 13637 13638 13639 13640 13641 13642 13643 13644 13645 13646 13647 13648 13649 13650 13651 13652 13653 13654 13655 13656 13657 13658 13659 13660 13661 13662 13663 13664 13665 13666 13667 13668 13669 13670 13671 13672 13673 13674 13675 13676 13677 13678 13679 13680 13681 13682 13683 13684 13685 13686 13687 13688 13689 13690 13691 13692 13693 13694 13695 13696 13697 13698 13699 13700 13701 13702 13703 13704 13705 13706 13707 13708 13709 13710 13711 13712 13713 13714 13715 13716 13717 13718 13719 13720 13721 13722 13723 13724 13725 13726 13727 13728 13729 13730 13731 13732 13733 13734 13735 13736 13737 13738 13739 13740 13741 13742 13743 13744 13745 13746 13747 13748 13749 13750 13751 13752 13753 13754 13755 13756 13757 13758 13759 13760 13761 13762 13763 13764 13765 13766 13767 13768 13769 13770 13771 13772 13773 13774 13775 13776 13777 13778 13779 13780 13781 13782 13783 13784 13785 13786 13787 13788 13789 13790 13791 13792 13793 13794 13795 13796 13797 13798 13799 13800 13801 13802 13803 13804 13805 13806 13807 13808 13809 13810 13811 13812 13813 13814 13815 13816 13817 13818 13819 13820 13821 13822 13823 13824 13825 13826 13827 13828 13829 13830 13831 13832 13833 13834 13835 13836 13837 13838 13839 13840 13841 13842 13843 13844 13845 13846 13847 13848 13849 13850 13851 13852 13853 13854 13855 13856 13857 13858 13859 13860 13861 13862 13863 13864 13865 13866 13867 13868 13869 13870 13871 13872 13873 13874 13875 13876 13877 13878 13879 13880 13881 13882 13883 13884 13885 13886 13887 13888 13889 13890 13891 13892 13893 13894 13895 13896 13897 13898 13899 13900 13901 13902 13903 13904 13905 13906 13907 13908 13909 13910 13911 13912 13913 13914 13915 13916 13917 13918 13919 13920 13921 13922 13923 13924 13925 13926 13927 13928 13929 13930 13931 13932 13933 13934 13935 13936 13937 13938 13939 13940 13941 13942 13943 13944 13945 13946 13947 13948 13949 13950 13951 13952 13953 13954 13955 13956 13957 13958 13959 13960 13961 13962 13963 13964 13965 13966 13967 13968 13969 13970 13971 13972 13973 13974 13975 13976 13977 13978 13979 13980 13981 13982 13983 13984 13985 13986 13987 13988 13989 13990 13991 13992 13993 13994 13995 13996 13997 13998 13999 14000 14001 14002 14003 14004 14005 14006 14007 14008 14009 14010 14011 14012 14013 14014 14015 14016 14017 14018 14019 14020 14021 14022 14023 14024 14025 14026 14027 14028 14029 14030 14031 14032 14033 14034 14035 14036 14037 14038 14039 14040 14041 14042 14043 14044 14045 14046 14047 14048 14049 14050 14051 14052 14053 14054 14055 14056 14057 14058 14059 14060 14061 14062 14063 14064 14065 14066 14067 14068 14069 14070 14071 14072 14073 14074 14075 14076 14077 14078 14079 14080 14081 14082 14083 14084 14085 14086 14087 14088 14089 14090 14091 14092 14093 14094 14095 14096 14097 14098 14099 14100 14101 14102 14103 14104 14105 14106 14107 14108 14109 14110 14111 14112 14113 14114 14115 14116 14117 14118 14119 14120 14121 14122 14123 14124 14125 14126 14127 14128 14129 14130 14131 14132 14133 14134 14135 14136 14137 14138 14139 14140 14141 14142 14143 14144 14145 14146 14147 14148 14149 14150 14151 14152 14153 14154 14155 14156 14157 14158 14159 14160 14161 14162 14163 14164 14165 14166 14167 14168 14169 14170 14171 14172 14173 14174 14175 14176 14177 14178 14179 14180 14181 14182 14183 14184 14185 14186 14187 14188 14189 14190 14191 14192 14193 14194 14195 14196 14197 14198 14199 14200 14201 14202 14203 14204 14205 14206 14207 14208 14209 14210 14211 14212 14213 14214 14215 14216 14217 14218 14219 14220 14221 14222 14223 14224 14225 14226 14227 14228 14229 14230 14231 14232 14233 14234 14235 14236 14237 14238 14239 14240 14241 14242 14243 14244 14245 14246 14247 14248 14249 14250 14251 14252 14253 14254 14255 14256 14257 14258 14259 14260 14261 14262 14263 14264 14265 14266 14267 14268 14269 14270 14271 14272 14273 14274 14275 14276 14277 14278 14279 14280 14281 14282 14283 14284 14285 14286 14287 14288 14289 14290 14291 14292 14293 14294 14295 14296 14297 14298 14299 14300 14301 14302 14303 14304 14305 14306 14307 14308 14309 14310 14311 14312 14313 14314 14315 14316 14317 14318 14319 14320 14321 14322 14323 14324 14325 14326 14327 14328 14329 14330 14331 14332 14333 14334 14335 14336 14337 14338 14339 14340 14341 14342 14343 14344 14345 14346 14347 14348 14349 14350 14351 14352 14353 14354 14355 14356 14357 14358 14359 14360 14361 14362 14363 14364 14365 14366 14367 14368 14369 14370 14371 14372 14373 14374 14375 14376 14377 14378 14379 14380 14381 14382 14383 14384 14385 14386 14387 14388 14389 14390 14391 14392 14393 14394 14395 14396 14397 14398 14399 14400 14401 14402 14403 14404 14405 14406 14407 14408 14409 14410 14411 14412 14413 14414 14415 14416 14417 14418 14419 14420 14421 14422 14423 14424 14425 14426 14427 14428 14429 14430 14431 14432 14433 14434 14435 14436 14437 14438 14439 14440 14441 14442 14443 14444 14445 14446 14447 14448 14449 14450 14451 14452 14453 14454 14455 14456 14457 14458 14459 14460 14461 14462 14463 14464 14465 14466 14467 14468 14469 14470 14471 14472 14473 14474 14475 14476 14477 14478 14479 14480 14481 14482 14483 14484 14485 14486 14487 14488 14489 14490 14491 14492 14493 14494 14495 14496 14497 14498 14499 14500 14501 14502 14503 14504 14505 14506 14507 14508 14509 14510 14511 14512 14513 14514 14515 14516 14517 14518 14519 14520 14521 14522 14523 14524 14525 14526 14527 14528 14529 14530 14531 14532 14533 14534 14535 14536 14537 14538 14539 14540 14541 14542 14543 14544 14545 14546 14547 14548 14549 14550 14551 14552 14553 14554 14555 14556 14557 14558 14559 14560 14561 14562 14563 14564 14565 14566 14567 14568 14569 14570 14571 14572 14573 14574 14575 14576 14577 14578 14579 14580 14581 14582 14583 14584 14585 14586 14587 14588 14589 14590 14591 14592 14593 14594 14595 14596 14597 14598 14599 14600 14601 14602 14603 14604 14605 14606 14607 14608 14609 14610 14611 14612 14613 14614 14615 14616 14617 14618 14619 14620 14621 14622 14623 14624 14625 14626 14627 14628 14629 14630 14631 14632 14633 14634 14635 14636 14637 14638 14639 14640 14641 14642 14643 14644 14645 14646 14647 14648 14649 14650 14651 14652 14653 14654 14655 14656 14657 14658 14659 14660 14661 14662 14663 14664 14665 14666 14667 14668 14669 14670 14671 14672 14673 14674 14675 14676 14677 14678 14679 14680 14681 14682 14683 14684 14685 14686 14687 14688 14689 14690 14691 14692 14693 14694 14695 14696 14697 14698 14699 14700 14701 14702 14703 14704 14705 14706 14707 14708 14709 14710 14711 14712 14713 14714 14715 14716 14717 14718 14719 14720 14721 14722 14723 14724 14725 14726 14727 14728 14729 14730 14731 14732 14733 14734 14735 14736 14737 14738 14739 14740 14741 14742 14743 14744 14745 14746 14747 14748 14749 14750 14751 14752 14753 14754 14755 14756 14757 14758 14759 14760 14761 14762 14763 14764 14765 14766 14767 14768 14769 14770 14771 14772 14773 14774 14775 14776 14777 14778 14779 14780 14781 14782 14783 14784 14785 14786 14787 14788 14789 14790 14791 14792 14793 14794 14795 14796 14797 14798 14799 14800 14801 14802 14803 14804 14805 14806 14807 14808 14809 14810 14811 14812 14813 14814 14815 14816 14817 14818 14819 14820 14821 14822 14823 14824 14825 14826 14827 14828 14829 14830 14831 14832 14833 14834 14835 14836 14837 14838 14839 14840 14841 14842 14843 14844 14845 14846 14847 14848 14849 14850 14851 14852 14853 14854 14855 14856 14857 14858 14859 14860 14861 14862 14863 14864 14865 14866 14867 14868 14869 14870 14871 14872 14873 14874 14875 14876 14877 14878 14879 14880 14881 14882 14883 14884 14885 14886 14887 14888 14889 14890 14891 14892 14893 14894 14895 14896 14897 14898 14899 14900 14901 14902 14903 14904 14905 14906 14907 14908 14909 14910 14911 14912 14913 14914 14915 14916 14917 14918 14919 14920 14921 14922 14923 14924 14925 14926 14927 14928 14929 14930 14931 14932 14933 14934 14935 14936 14937 14938 14939 14940 14941 14942 14943 14944 14945 14946 14947 14948 14949 14950 14951 14952 14953 14954 14955 14956 14957 14958 14959 14960 14961 14962 14963 14964 14965 14966 14967 14968 14969 14970 14971 14972 14973 14974 14975 14976 14977 14978 14979 14980 14981 14982 14983 14984 14985 14986 14987 14988 14989 14990 14991 14992 14993 14994 14995 14996 14997 14998 14999 15000 15001 15002 15003 15004 15005 15006 15007 15008 15009 15010 15011 15012 15013 15014 15015 15016 15017 15018 15019 15020 15021 15022 15023 15024 15025 15026 15027 15028 15029 15030 15031 15032 15033 15034 15035 15036 15037 15038 15039 15040 15041 15042 15043 15044 15045 15046 15047 15048 15049 15050 15051 15052 15053 15054 15055 15056 15057 15058 15059 15060 15061 15062 15063 15064 15065 15066 15067 15068 15069 15070 15071 15072 15073 15074 15075 15076