[gtk+/places-sidebar] #if out a few things
- From: Federico Mena Quintero <federico src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/places-sidebar] #if out a few things
- Date: Thu, 17 Nov 2011 19:21:23 +0000 (UTC)
commit 6a2ffadf06c928834122e1740f641b274a9af06b
Author: Federico Mena Quintero <federico gnome org>
Date: Thu Nov 17 08:08:49 2011 -0600
#if out a few things
gtk/gtkfilechooserdefault.c | 8 ++++++++
gtk/gtkfilechooserprivate.h | 6 ++++++
2 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkfilechooserdefault.c b/gtk/gtkfilechooserdefault.c
index fc3e817..777af02 100644
--- a/gtk/gtkfilechooserdefault.c
+++ b/gtk/gtkfilechooserdefault.c
@@ -176,6 +176,7 @@ enum {
static guint signals[LAST_SIGNAL] = { 0 };
+#if REMOVE_FOR_PLACES_SIDEBAR
/* Column numbers for the shortcuts tree. Keep these in sync with shortcuts_model_create() */
enum {
SHORTCUTS_COL_PIXBUF,
@@ -195,6 +196,7 @@ typedef enum {
SHORTCUT_TYPE_SEARCH,
SHORTCUT_TYPE_RECENT
} ShortcutType;
+#endif
#define MODEL_ATTRIBUTES "standard::name,standard::type,standard::display-name," \
"standard::is-hidden,standard::is-backup,standard::size," \
@@ -233,6 +235,7 @@ enum {
GTK_TREE_MODEL_ROW,
};
+#if REMOVE_FOR_PLACES_SIDEBAR
/* Interesting places in the shortcuts bar */
typedef enum {
SHORTCUTS_SEARCH,
@@ -247,6 +250,7 @@ typedef enum {
SHORTCUTS_CURRENT_FOLDER_SEPARATOR,
SHORTCUTS_CURRENT_FOLDER
} ShortcutsIndex;
+#endif
/* Icon size for if we can't get it from the theme */
#define FALLBACK_ICON_SIZE 16
@@ -439,6 +443,7 @@ static void unset_file_system_backend (GtkFileChooserDefault *impl);
+#if REMOVE_FOR_PLACES_SIDEBAR
/* Drag and drop interface declarations */
typedef struct {
@@ -465,6 +470,7 @@ G_DEFINE_TYPE_WITH_CODE (ShortcutsPaneModelFilter,
static GtkTreeModel *shortcuts_pane_model_filter_new (GtkFileChooserDefault *impl,
GtkTreeModel *child_model,
GtkTreePath *root);
+#endif
@@ -725,6 +731,7 @@ gtk_file_chooser_embed_default_iface_init (GtkFileChooserEmbedIface *iface)
iface->initial_focus = gtk_file_chooser_default_initial_focus;
}
+#if REMOVE_FOR_PLACES_SIDEBAR
static void
bookmarks_changed_cb (gpointer data)
{
@@ -732,6 +739,7 @@ bookmarks_changed_cb (gpointer data)
volumes_bookmarks_changed_cb (impl->file_system, impl);
}
+#endif
static void
_gtk_file_chooser_default_init (GtkFileChooserDefault *impl)
diff --git a/gtk/gtkfilechooserprivate.h b/gtk/gtkfilechooserprivate.h
index 8cfe5ca..bfcf5b4 100644
--- a/gtk/gtkfilechooserprivate.h
+++ b/gtk/gtkfilechooserprivate.h
@@ -153,6 +153,8 @@ typedef enum {
OPERATION_MODE_RECENT
} OperationMode;
+#define REMOVE_FOR_PLACES_SIDEBAR 0
+
struct _GtkFileChooserDefault
{
GtkBox parent_instance;
@@ -170,12 +172,14 @@ struct _GtkFileChooserDefault
/* The file browsing widgets */
GtkWidget *browse_widgets_box;
GtkWidget *browse_header_box;
+#if REMOVE_FOR_PLACES_SIDEBAR
GtkWidget *browse_shortcuts_tree_view;
GtkWidget *browse_shortcuts_add_button;
GtkWidget *browse_shortcuts_remove_button;
GtkWidget *browse_shortcuts_popup_menu;
GtkWidget *browse_shortcuts_popup_menu_remove_item;
GtkWidget *browse_shortcuts_popup_menu_rename_item;
+#endif
GtkWidget *browse_files_tree_view;
GtkWidget *browse_files_popup_menu;
GtkWidget *browse_files_popup_menu_add_shortcut_item;
@@ -224,10 +228,12 @@ struct _GtkFileChooserDefault
GtkListStore *shortcuts_model;
+#if REMOVE_FOR_PLACES_SIDEBAR
/* Filter for the shortcuts pane. We filter out the "current folder" row and
* the separator that we use for the "Save in folder" combo.
*/
GtkTreeModel *shortcuts_pane_filter_model;
+#endif
/* Handles */
GSList *loading_shortcuts;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]