diff options
Diffstat (limited to 'baobab')
-rw-r--r-- | baobab/src/baobab-cell-renderer-progress.c | 62 | ||||
-rw-r--r-- | baobab/src/baobab-chart.c | 64 | ||||
-rw-r--r-- | baobab/src/baobab-remote-connect-dialog.c | 192 | ||||
-rw-r--r-- | baobab/src/baobab.c | 4 |
4 files changed, 0 insertions, 322 deletions
diff --git a/baobab/src/baobab-cell-renderer-progress.c b/baobab/src/baobab-cell-renderer-progress.c index d4d26db5..94b44d88 100644 --- a/baobab/src/baobab-cell-renderer-progress.c +++ b/baobab/src/baobab-cell-renderer-progress.c @@ -99,11 +99,7 @@ baobab_cell_renderer_progress_set_property (GObject *object, static void baobab_cell_renderer_progress_get_size (GtkCellRenderer *cell, GtkWidget *widget, -#if GTK_CHECK_VERSION (3, 0, 0) const GdkRectangle *cell_area, -#else - GdkRectangle *cell_area, -#endif gint *x_offset, gint *y_offset, gint *width, @@ -146,7 +142,6 @@ baobab_cell_renderer_progress_get_size (GtkCellRenderer *cell, static void set_color_according_to_perc (cairo_t *cr, double value) { -#if GTK_CHECK_VERSION (3, 0, 0) static GdkRGBA red; static GdkRGBA yellow; static GdkRGBA green; @@ -181,42 +176,6 @@ set_color_according_to_perc (cairo_t *cr, double value) { gdk_cairo_set_source_rgba (cr, &red); return; -#else - static GdkColor red; - static GdkColor yellow; - static GdkColor green; - static gboolean colors_initialized = FALSE; - - if (!colors_initialized) - { - /* hardcoded tango colors */ - gdk_color_parse ("#cc0000", &red); - gdk_color_parse ("#edd400", &yellow); - gdk_color_parse ("#73d216", &green); - - colors_initialized = TRUE; - } - - if (value <= 0) - { - cairo_set_source_rgb (cr, 1, 1, 1); - return; - } - else if (value <= 33.33) - { - gdk_cairo_set_source_color (cr, &green); - return; - } - else if (value <= 66.66) - { - gdk_cairo_set_source_color (cr, &yellow); - return; - } - else if (value <= 100.0) - { - gdk_cairo_set_source_color (cr, &red); - return; -#endif } else g_assert_not_reached (); @@ -224,38 +183,21 @@ set_color_according_to_perc (cairo_t *cr, double value) static void baobab_cell_renderer_progress_render (GtkCellRenderer *cell, -#if GTK_CHECK_VERSION (3, 0, 0) cairo_t *cr, -#else - GdkWindow *window, -#endif GtkWidget *widget, -#if GTK_CHECK_VERSION (3, 0, 0) const GdkRectangle *background_area, const GdkRectangle *cell_area, -#else - GdkRectangle *background_area, - GdkRectangle *cell_area, - GdkRectangle *expose_area, -#endif guint flags) { BaobabCellRendererProgress *cellprogress = BAOBAB_CELL_RENDERER_PROGRESS (cell); gint x, y, w, h, perc_w; gboolean is_rtl; -#if !GTK_CHECK_VERSION (3, 0, 0) - cairo_t *cr; -#endif gint xpad; gint ypad; GtkStyle *style; is_rtl = gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL; -#if !GTK_CHECK_VERSION (3, 0, 0) - cr = gdk_cairo_create (window); -#endif - gtk_cell_renderer_get_padding (cell, &xpad, &ypad); x = cell_area->x + xpad; @@ -290,10 +232,6 @@ baobab_cell_renderer_progress_render (GtkCellRenderer *cell, cairo_rectangle (cr, is_rtl ? (x + w - perc_w) : x, y, perc_w, h); set_color_according_to_perc (cr, cellprogress->priv->perc); cairo_fill (cr); - -#if !GTK_CHECK_VERSION (3, 0, 0) - cairo_destroy (cr); -#endif } static void diff --git a/baobab/src/baobab-chart.c b/baobab/src/baobab-chart.c index 03c88338..d981c773 100644 --- a/baobab/src/baobab-chart.c +++ b/baobab/src/baobab-chart.c @@ -35,10 +35,8 @@ #include <gtk/gtk.h> #include <glib/gi18n.h> -#if GTK_CHECK_VERSION (3, 0, 0) /* needed for floor and ceil */ #include <math.h> -#endif #include "baobab-chart.h" @@ -149,11 +147,7 @@ static void baobab_chart_rows_reordered (GtkTreeModel *model, gint *new_order, gpointer data); static gboolean baobab_chart_expose (GtkWidget *chart, -#if GTK_CHECK_VERSION (3, 0, 0) cairo_t *cr); -#else - GdkEventExpose *event); -#endif static void baobab_chart_interpolate_colors (BaobabChartColor *color, BaobabChartColor colora, BaobabChartColor colorb, @@ -195,11 +189,7 @@ baobab_chart_class_init (BaobabChartClass *class) /* GtkWidget signals */ widget_class->realize = baobab_chart_realize; -#if GTK_CHECK_VERSION (3, 0, 0) widget_class->draw = baobab_chart_expose; -#else - widget_class->expose_event = baobab_chart_expose; -#endif widget_class->size_allocate = baobab_chart_size_allocate; widget_class->scroll_event = baobab_chart_scroll; @@ -314,9 +304,7 @@ baobab_chart_realize (GtkWidget *widget) gint attributes_mask; GtkAllocation allocation; GdkWindow *window; -#if GTK_CHECK_VERSION (3, 0, 0) GtkStyleContext *context; -#endif g_return_if_fail (BAOBAB_IS_CHART (widget)); @@ -332,16 +320,9 @@ baobab_chart_realize (GtkWidget *widget) attributes.height = allocation.height; attributes.wclass = GDK_INPUT_OUTPUT; attributes.visual = gtk_widget_get_visual (widget); -#if !GTK_CHECK_VERSION (3, 0, 0) - attributes.colormap = gtk_widget_get_colormap (widget); -#endif attributes.event_mask = gtk_widget_get_events (widget) | GDK_EXPOSURE_MASK; -#if GTK_CHECK_VERSION (3, 0, 0) attributes_mask = GDK_WA_X | GDK_WA_Y | GDK_WA_VISUAL; -#else - attributes_mask = GDK_WA_X | GDK_WA_Y | GDK_WA_VISUAL | GDK_WA_COLORMAP; -#endif window = gdk_window_new (gtk_widget_get_parent_window (widget), &attributes, @@ -349,15 +330,8 @@ baobab_chart_realize (GtkWidget *widget) gtk_widget_set_window (widget, window); gdk_window_set_user_data (window, chart); -#if GTK_CHECK_VERSION (3, 0, 0) context = gtk_widget_get_style_context (widget); gtk_style_context_set_background (context, window); -#else - gtk_widget_style_attach (widget); - gtk_style_set_background (gtk_widget_get_style (widget), - window, - GTK_STATE_NORMAL); -#endif gtk_widget_add_events (widget, GDK_EXPOSURE_MASK | GDK_BUTTON_PRESS_MASK | @@ -780,15 +754,8 @@ baobab_chart_rows_reordered (GtkTreeModel *model, } static gboolean -#if GTK_CHECK_VERSION (3, 0, 0) baobab_chart_expose (GtkWidget *chart, cairo_t *cr) -#else -baobab_chart_expose (GtkWidget *chart, GdkEventExpose *event) -#endif { -#if !GTK_CHECK_VERSION (3, 0, 0) - cairo_t *cr; -#endif BaobabChartPrivate *priv; gint w, h; gdouble p, sx, sy; @@ -796,7 +763,6 @@ baobab_chart_expose (GtkWidget *chart, GdkEventExpose *event) GtkTreePath *current_path = NULL; GtkAllocation allocation; -#if GTK_CHECK_VERSION (3, 0, 0) GdkRectangle area; gdouble x1, y1, x2, y2; cairo_clip_extents (cr, &x1, &y1, &x2, &y2); @@ -804,7 +770,6 @@ baobab_chart_expose (GtkWidget *chart, GdkEventExpose *event) area.y = floor (y1); area.width = ceil (x2) - area.x; area.height = ceil (y2) - area.y; -#endif priv = BAOBAB_CHART (chart)->priv; @@ -816,13 +781,8 @@ baobab_chart_expose (GtkWidget *chart, GdkEventExpose *event) cr = gdk_cairo_create (gtk_widget_get_window (chart)); cairo_rectangle (cr, -#if GTK_CHECK_VERSION (3, 0, 0) area.x, area.y, area.width, area.height); -#else - event->area.x, event->area.y, - event->area.width, event->area.height); -#endif /* there is no model we can not paint */ if ((priv->is_frozen) || (priv->model == NULL)) @@ -888,17 +848,9 @@ baobab_chart_expose (GtkWidget *chart, GdkEventExpose *event) gtk_tree_path_free (root_path); -#if GTK_CHECK_VERSION (3, 0, 0) baobab_chart_draw (chart, cr, area); -#else - baobab_chart_draw (chart, cr, event->area); -#endif } -#if !GTK_CHECK_VERSION (3, 0, 0) - cairo_destroy (cr); -#endif - return FALSE; } @@ -1229,16 +1181,8 @@ baobab_chart_get_pixbuf (GtkWidget *widget) h = gdk_window_get_height(gtk_widget_get_window(widget)); -#if GTK_CHECK_VERSION(3, 0, 0) pixbuf = gdk_pixbuf_get_from_window ( -#else - pixbuf = gdk_pixbuf_get_from_drawable (NULL, -#endif gtk_widget_get_window (widget), -#if !GTK_CHECK_VERSION(3, 0, 0) - gdk_colormap_get_system (), - 0, 0, -#endif 0, 0, w, h); @@ -1794,19 +1738,11 @@ baobab_chart_save_snapshot (GtkWidget *chart) gtk_file_chooser_set_do_overwrite_confirmation (GTK_FILE_CHOOSER (fs_dlg), TRUE); /* extra widget */ -#if GTK_CHECK_VERSION (3, 0, 0) vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0); -#else - vbox = gtk_vbox_new (FALSE, 0); -#endif gtk_container_set_border_width (GTK_CONTAINER (vbox), 0); gtk_file_chooser_set_extra_widget (GTK_FILE_CHOOSER (fs_dlg), vbox); -#if GTK_CHECK_VERSION (3, 0, 0) hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 12); -#else - hbox = gtk_hbox_new (FALSE, 12); -#endif gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE, TRUE, 6); label = gtk_label_new_with_mnemonic (_("_Image type:")); diff --git a/baobab/src/baobab-remote-connect-dialog.c b/baobab/src/baobab-remote-connect-dialog.c index e8eed953..c535a851 100644 --- a/baobab/src/baobab-remote-connect-dialog.c +++ b/baobab/src/baobab-remote-connect-dialog.c @@ -43,13 +43,7 @@ */ struct _BaobabRemoteConnectDialogDetails { - -#if GTK_CHECK_VERSION (3, 0, 0) GtkWidget *grid; -#else - GtkWidget *table; -#endif - GtkWidget *type_combo; GtkWidget *uri_entry; GtkWidget *server_entry; @@ -395,11 +389,7 @@ setup_for_type (BaobabRemoteConnectDialog *dialog) { struct MethodInfo *meth; int index, i; -#if GTK_CHECK_VERSION (3, 0, 0) GtkWidget *label, *grid; -#else - GtkWidget *label, *table; -#endif GtkTreeIter iter; /* Get our method info */ @@ -409,7 +399,6 @@ setup_for_type (BaobabRemoteConnectDialog *dialog) g_assert (index < G_N_ELEMENTS (methods) && index >= 0); meth = &(methods[index]); -#if GTK_CHECK_VERSION (3, 0, 0) if (gtk_widget_get_parent (dialog->details->uri_entry) != NULL) { gtk_container_remove (GTK_CONTAINER (dialog->details->grid), dialog->details->uri_entry); @@ -444,42 +433,6 @@ setup_for_type (BaobabRemoteConnectDialog *dialog) i = 1; grid = dialog->details->grid; -#else - if (gtk_widget_get_parent (dialog->details->uri_entry) != NULL) { - gtk_container_remove (GTK_CONTAINER (dialog->details->table), - dialog->details->uri_entry); - } - if (gtk_widget_get_parent (dialog->details->server_entry) != NULL) { - gtk_container_remove (GTK_CONTAINER (dialog->details->table), - dialog->details->server_entry); - } - if (gtk_widget_get_parent (dialog->details->share_entry) != NULL) { - gtk_container_remove (GTK_CONTAINER (dialog->details->table), - dialog->details->share_entry); - } - if (gtk_widget_get_parent (dialog->details->port_entry) != NULL) { - gtk_container_remove (GTK_CONTAINER (dialog->details->table), - dialog->details->port_entry); - } - if (gtk_widget_get_parent (dialog->details->folder_entry) != NULL) { - gtk_container_remove (GTK_CONTAINER (dialog->details->table), - dialog->details->folder_entry); - } - if (gtk_widget_get_parent (dialog->details->user_entry) != NULL) { - gtk_container_remove (GTK_CONTAINER (dialog->details->table), - dialog->details->user_entry); - } - if (gtk_widget_get_parent (dialog->details->domain_entry) != NULL) { - gtk_container_remove (GTK_CONTAINER (dialog->details->table), - dialog->details->domain_entry); - } - /* Destroy all labels */ - gtk_container_foreach (GTK_CONTAINER (dialog->details->table), - (GtkCallback) gtk_widget_destroy, NULL); - - i = 1; - table = dialog->details->table; -#endif if (meth->scheme == NULL) { label = gtk_label_new_with_mnemonic (_("_Location (URI):")); @@ -490,28 +443,12 @@ setup_for_type (BaobabRemoteConnectDialog *dialog) gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); #endif gtk_widget_show (label); -#if GTK_CHECK_VERSION (3, 0, 0) gtk_grid_attach (GTK_GRID (grid), label, 0, i, 1, 1); gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->uri_entry); gtk_widget_set_hexpand (dialog->details->uri_entry, TRUE); gtk_widget_show (dialog->details->uri_entry); gtk_grid_attach (GTK_GRID (grid), dialog->details->uri_entry, 1, i, 1, 1); -#else - gtk_table_attach (GTK_TABLE (table), label, - 0, 1, - i, i+1, - GTK_FILL, GTK_FILL, - 0, 0); - - gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->uri_entry); - gtk_widget_show (dialog->details->uri_entry); - gtk_table_attach (GTK_TABLE (table), dialog->details->uri_entry, - 1, 2, - i, i+1, - GTK_FILL | GTK_EXPAND, GTK_FILL, - 0, 0); -#endif i++; @@ -526,28 +463,12 @@ setup_for_type (BaobabRemoteConnectDialog *dialog) gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); #endif gtk_widget_show (label); -#if GTK_CHECK_VERSION (3, 0, 0) gtk_grid_attach (GTK_GRID (grid), label, 0, i, 1, 1); gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->server_entry); gtk_widget_set_hexpand (dialog->details->server_entry, TRUE); gtk_widget_show (dialog->details->server_entry); gtk_grid_attach (GTK_GRID (grid), dialog->details->server_entry, 1, i, 1, 1); -#else - gtk_table_attach (GTK_TABLE (table), label, - 0, 1, - i, i+1, - GTK_FILL, GTK_FILL, - 0, 0); - - gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->server_entry); - gtk_widget_show (dialog->details->server_entry); - gtk_table_attach (GTK_TABLE (table), dialog->details->server_entry, - 1, 2, - i, i+1, - GTK_FILL | GTK_EXPAND, GTK_FILL, - 0, 0); -#endif i++; @@ -559,15 +480,7 @@ setup_for_type (BaobabRemoteConnectDialog *dialog) gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); #endif gtk_widget_show (label); -#if GTK_CHECK_VERSION (3, 0, 0) gtk_grid_attach (GTK_GRID (grid), label, 0, i, 2, 1); -#else - gtk_table_attach (GTK_TABLE (table), label, - 0, 2, - i, i+1, - GTK_FILL, GTK_FILL, - 0, 0); -#endif i++; @@ -580,28 +493,12 @@ setup_for_type (BaobabRemoteConnectDialog *dialog) gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); #endif gtk_widget_show (label); -#if GTK_CHECK_VERSION (3, 0, 0) gtk_grid_attach (GTK_GRID (grid), label, 0, i, 1, 1); gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->share_entry); gtk_widget_set_hexpand (dialog->details->share_entry, TRUE); gtk_widget_show (dialog->details->share_entry); gtk_grid_attach (GTK_GRID (grid), dialog->details->share_entry, 1, i, 1, 1); -#else - gtk_table_attach (GTK_TABLE (table), label, - 0, 1, - i, i+1, - GTK_FILL, GTK_FILL, - 0, 0); - - gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->share_entry); - gtk_widget_show (dialog->details->share_entry); - gtk_table_attach (GTK_TABLE (table), dialog->details->share_entry, - 1, 2, - i, i+1, - GTK_FILL | GTK_EXPAND, GTK_FILL, - 0, 0); -#endif i++; } @@ -615,28 +512,12 @@ setup_for_type (BaobabRemoteConnectDialog *dialog) gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); #endif gtk_widget_show (label); -#if GTK_CHECK_VERSION (3, 0, 0) gtk_grid_attach (GTK_GRID (grid), label, 0, i, 1, 1); gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->port_entry); gtk_widget_set_hexpand (dialog->details->port_entry, TRUE); gtk_widget_show (dialog->details->port_entry); gtk_grid_attach (GTK_GRID (grid), dialog->details->port_entry, 1, i, 1, 1); -#else - gtk_table_attach (GTK_TABLE (table), label, - 0, 1, - i, i+1, - GTK_FILL, GTK_FILL, - 0, 0); - - gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->port_entry); - gtk_widget_show (dialog->details->port_entry); - gtk_table_attach (GTK_TABLE (table), dialog->details->port_entry, - 1, 2, - i, i+1, - GTK_FILL | GTK_EXPAND, GTK_FILL, - 0, 0); -#endif i++; } @@ -649,28 +530,12 @@ setup_for_type (BaobabRemoteConnectDialog *dialog) gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); #endif gtk_widget_show (label); -#if GTK_CHECK_VERSION (3, 0, 0) gtk_grid_attach (GTK_GRID (grid), label, 0, i, 1, 1); gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->folder_entry); gtk_widget_set_hexpand (dialog->details->folder_entry, TRUE); gtk_widget_show (dialog->details->folder_entry); gtk_grid_attach (GTK_GRID (grid), dialog->details->folder_entry, 1, i, 1, 1); -#else - gtk_table_attach (GTK_TABLE (table), label, - 0, 1, - i, i+1, - GTK_FILL, GTK_FILL, - 0, 0); - - gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->folder_entry); - gtk_widget_show (dialog->details->folder_entry); - gtk_table_attach (GTK_TABLE (table), dialog->details->folder_entry, - 1, 2, - i, i+1, - GTK_FILL | GTK_EXPAND, GTK_FILL, - 0, 0); -#endif i++; @@ -683,28 +548,12 @@ setup_for_type (BaobabRemoteConnectDialog *dialog) gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); #endif gtk_widget_show (label); -#if GTK_CHECK_VERSION (3, 0, 0) gtk_grid_attach (GTK_GRID (grid), label, 0, i, 1, 1); gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->user_entry); gtk_widget_set_hexpand (dialog->details->user_entry, TRUE); gtk_widget_show (dialog->details->user_entry); gtk_grid_attach (GTK_GRID (grid), dialog->details->user_entry, 1, i, 1, 1); -#else - gtk_table_attach (GTK_TABLE (table), label, - 0, 1, - i, i+1, - GTK_FILL, GTK_FILL, - 0, 0); - - gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->user_entry); - gtk_widget_show (dialog->details->user_entry); - gtk_table_attach (GTK_TABLE (table), dialog->details->user_entry, - 1, 2, - i, i+1, - GTK_FILL | GTK_EXPAND, GTK_FILL, - 0, 0); -#endif i++; } @@ -718,28 +567,12 @@ setup_for_type (BaobabRemoteConnectDialog *dialog) gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); #endif gtk_widget_show (label); -#if GTK_CHECK_VERSION (3, 0, 0) gtk_grid_attach (GTK_GRID (grid), label, 0, i, 1, 1); gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->domain_entry); gtk_widget_set_hexpand (dialog->details->user_entry, TRUE); gtk_widget_show (dialog->details->domain_entry); gtk_grid_attach (GTK_GRID (grid), dialog->details->domain_entry, 1, i, 1, 1); -#else - gtk_table_attach (GTK_TABLE (table), label, - 0, 1, - i, i+1, - GTK_FILL, GTK_FILL, - 0, 0); - - gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->details->domain_entry); - gtk_widget_show (dialog->details->domain_entry); - gtk_table_attach (GTK_TABLE (table), dialog->details->domain_entry, - 1, 2, - i, i+1, - GTK_FILL | GTK_EXPAND, GTK_FILL, - 0, 0); -#endif i++; } @@ -781,11 +614,7 @@ static void baobab_remote_connect_dialog_init (BaobabRemoteConnectDialog *dialog) { GtkWidget *label; -#if GTK_CHECK_VERSION (3, 0, 0) GtkWidget *grid; -#else - GtkWidget *table; -#endif GtkWidget *combo; GtkWidget *hbox; GtkWidget *vbox; @@ -800,21 +629,13 @@ baobab_remote_connect_dialog_init (BaobabRemoteConnectDialog *dialog) gtk_box_set_spacing (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), 2); gtk_window_set_resizable (GTK_WINDOW (dialog), FALSE); -#if GTK_CHECK_VERSION (3, 0, 0) vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 6); -#else - vbox = gtk_vbox_new (FALSE, 6); -#endif gtk_container_set_border_width (GTK_CONTAINER (vbox), 5); gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), vbox, FALSE, TRUE, 0); gtk_widget_show (vbox); -#if GTK_CHECK_VERSION (3, 0, 0) hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6); -#else - hbox = gtk_hbox_new (FALSE, 6); -#endif gtk_box_pack_start (GTK_BOX (vbox), hbox, FALSE, TRUE, 0); gtk_widget_show (hbox); @@ -890,11 +711,7 @@ baobab_remote_connect_dialog_init (BaobabRemoteConnectDialog *dialog) G_CALLBACK (combo_changed_callback), dialog); -#if GTK_CHECK_VERSION (3, 0, 0) hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6); -#else - hbox = gtk_hbox_new (FALSE, 6); -#endif gtk_box_pack_start (GTK_BOX (vbox), hbox, FALSE, TRUE, 0); gtk_widget_show (hbox); @@ -905,21 +722,12 @@ baobab_remote_connect_dialog_init (BaobabRemoteConnectDialog *dialog) label, FALSE, FALSE, 0); -#if GTK_CHECK_VERSION (3, 0, 0) dialog->details->grid = grid = gtk_grid_new (); gtk_grid_set_row_spacing (GTK_GRID (grid), 6); gtk_grid_set_column_spacing (GTK_GRID (grid), 12); gtk_widget_show (grid); gtk_box_pack_start (GTK_BOX (hbox), grid, TRUE, TRUE, 0); -#else - dialog->details->table = table = gtk_table_new (5, 2, FALSE); - gtk_table_set_row_spacings (GTK_TABLE (table), 6); - gtk_table_set_col_spacings (GTK_TABLE (table), 12); - gtk_widget_show (table); - gtk_box_pack_start (GTK_BOX (hbox), - table, TRUE, TRUE, 0); -#endif dialog->details->uri_entry = gtk_entry_new(); dialog->details->server_entry = gtk_entry_new (); diff --git a/baobab/src/baobab.c b/baobab/src/baobab.c index 9497e850..95b9f3f6 100644 --- a/baobab/src/baobab.c +++ b/baobab/src/baobab.c @@ -695,10 +695,6 @@ baobab_create_statusbar (void) return; } -#if !GTK_CHECK_VERSION (3, 0, 0) - gtk_statusbar_set_has_resize_grip (GTK_STATUSBAR (baobab.statusbar), TRUE); -#endif - g_settings_bind (baobab.ui_settings, BAOBAB_SETTINGS_STATUSBAR_VISIBLE, baobab.statusbar, "visible", |