[gthumb] just use a link button for "more extensions"
- From: Paolo Bacchilega <paobac src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gthumb] just use a link button for "more extensions"
- Date: Thu, 7 Jan 2010 13:54:19 +0000 (UTC)
commit a0704b41be22fa14d6539fdddb89b99cdf4a2a64
Author: Paolo Bacchilega <paobac src gnome org>
Date: Thu Jan 7 14:52:39 2010 +0100
just use a link button for "more extensions"
this way it's clear that it's not an action but just a link to a
web page.
data/ui/extensions.ui | 75 ++++++++++++++++++++++++++++------------------
gthumb/dlg-extensions.c | 39 ------------------------
2 files changed, 46 insertions(+), 68 deletions(-)
---
diff --git a/data/ui/extensions.ui b/data/ui/extensions.ui
index d9e2a57..4fb4163 100644
--- a/data/ui/extensions.ui
+++ b/data/ui/extensions.ui
@@ -36,16 +36,48 @@
</packing>
</child>
<child>
- <object class="GtkScrolledWindow" id="extensions_scrolledwindow">
- <property name="width_request">300</property>
- <property name="height_request">350</property>
+ <object class="GtkVBox" id="vbox2">
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
- <property name="shadow_type">in</property>
+ <property name="orientation">vertical</property>
<child>
- <placeholder/>
+ <object class="GtkScrolledWindow" id="extensions_scrolledwindow">
+ <property name="width_request">350</property>
+ <property name="height_request">350</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">automatic</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox2">
+ <property name="visible">True</property>
+ <child>
+ <object class="GtkLinkButton" id="linkbutton1">
+ <property name="label" translatable="yes">More extensions...</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="relief">none</property>
+ <property name="uri">http://live.gnome.org/gthumb/extensions</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
</child>
</object>
<packing>
@@ -68,7 +100,7 @@
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="about_button">
- <property name="label" translatable="yes">gtk-about</property>
+ <property name="label">gtk-about</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
@@ -78,26 +110,12 @@
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkButton" id="more_button">
- <property name="label" translatable="yes">_More</property>
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="receives_default">True</property>
- <property name="tooltip_markup">Additional user-contributed extensions are available for download.</property>
- <property name="use_underline">True</property>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">1</property>
+ <property name="secondary">True</property>
</packing>
</child>
<child>
<object class="GtkButton" id="preferences_button">
- <property name="label" translatable="yes">gtk-preferences</property>
+ <property name="label">gtk-preferences</property>
<property name="visible">True</property>
<property name="sensitive">False</property>
<property name="can_focus">True</property>
@@ -108,12 +126,12 @@
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
- <property name="position">-1</property>
+ <property name="position">1</property>
</packing>
</child>
<child>
<object class="GtkButton" id="close_button">
- <property name="label" translatable="yes">gtk-close</property>
+ <property name="label">gtk-close</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
@@ -122,7 +140,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
- <property name="position">3</property>
+ <property name="position">2</property>
</packing>
</child>
</object>
@@ -136,7 +154,6 @@
</child>
<action-widgets>
<action-widget response="0">about_button</action-widget>
- <action-widget response="0">more_button</action-widget>
<action-widget response="0">preferences_button</action-widget>
<action-widget response="0">close_button</action-widget>
</action-widgets>
diff --git a/gthumb/dlg-extensions.c b/gthumb/dlg-extensions.c
index a5aebf4..7c4a41a 100644
--- a/gthumb/dlg-extensions.c
+++ b/gthumb/dlg-extensions.c
@@ -353,41 +353,6 @@ about_button_clicked_cb (GtkButton *button,
}
-static void
-more_button_clicked_cb (GtkButton *button,
- gpointer user_data)
-{
- DialogData *data = user_data;
- GError *error = NULL;
-
- if (! gtk_show_uri (gtk_window_get_screen (GTK_WINDOW (data->dialog)),
- "http://live.gnome.org/gthumb/extensions",
- GDK_CURRENT_TIME,
- &error)) {
- GtkWidget *dialog;
-
- dialog = _gtk_message_dialog_new (GTK_WINDOW (data->dialog),
- GTK_DIALOG_DESTROY_WITH_PARENT,
- GTK_STOCK_DIALOG_ERROR,
- _("Could not load extensions web page in browser"),
- error->message,
- GTK_STOCK_OK, GTK_RESPONSE_OK,
- NULL);
- gtk_dialog_set_default_response (GTK_DIALOG (dialog), GTK_RESPONSE_OK);
-
- g_signal_connect (G_OBJECT (dialog), "response",
- G_CALLBACK (gtk_widget_destroy),
- NULL);
-
- gtk_window_set_resizable (GTK_WINDOW (dialog), FALSE);
-
- gtk_widget_show (dialog);
-
- g_clear_error (&error);
- }
-}
-
-
void
dlg_extensions (GthBrowser *browser)
{
@@ -461,10 +426,6 @@ dlg_extensions (GthBrowser *browser)
"clicked",
G_CALLBACK (about_button_clicked_cb),
data);
- g_signal_connect (GET_WIDGET ("more_button"),
- "clicked",
- G_CALLBACK (more_button_clicked_cb),
- data);
g_signal_connect (gtk_tree_view_get_selection (GTK_TREE_VIEW (data->list_view)),
"changed",
G_CALLBACK (list_view_selection_changed_cb),
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]