summaryrefslogtreecommitdiff
path: root/src/trg-torrent-move-dialog.c
diff options
context:
space:
mode:
authorGravatar Alan Fitton <ajf@eth0.org.uk>2011-10-25 21:25:50 +0000
committerGravatar Alan Fitton <ajf@eth0.org.uk>2011-10-25 21:25:50 +0000
commit48780131a32188263501c094bff8afcbc687e189 (patch)
treeeb79b55d14709b5fef778017b3db28b21eed2438 /src/trg-torrent-move-dialog.c
parent33256bc2004f729c6829d812a3ca6c89fa7e7b7a (diff)
When implementing labels in TrgDestinationCombo, I somehow overlooked the fact that I made it no longer editable and some work would be needed to make it actually send the directory and not the label. Fixed, I have some more ideas for this widget though.
Diffstat (limited to 'src/trg-torrent-move-dialog.c')
-rw-r--r--src/trg-torrent-move-dialog.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/trg-torrent-move-dialog.c b/src/trg-torrent-move-dialog.c
index 8ea6802..3f80e72 100644
--- a/src/trg-torrent-move-dialog.c
+++ b/src/trg-torrent-move-dialog.c
@@ -80,10 +80,7 @@ static void location_changed(GtkWidget * w, gpointer data)
{
TrgTorrentMoveDialogPrivate *priv =
TRG_TORRENT_MOVE_DIALOG_GET_PRIVATE(data);
- gchar *location =
- gtk_combo_box_get_active_text(GTK_COMBO_BOX(priv->location_combo));
- gtk_widget_set_sensitive(priv->move_button, strlen(location) > 0);
- g_free(location);
+ gtk_widget_set_sensitive(priv->move_button, trg_destination_combo_has_text(TRG_DESTINATION_COMBO(priv->location_combo)));
}
static GObject *trg_torrent_move_dialog_constructor(GType type,
@@ -108,7 +105,7 @@ static GObject *trg_torrent_move_dialog_constructor(GType type,
t = hig_workarea_create();
w = priv->location_combo = trg_destination_combo_new(priv->client);
- g_signal_connect(w, "changed", G_CALLBACK(location_changed), object);
+ g_signal_connect(trg_destination_combo_get_entry(TRG_DESTINATION_COMBO(w)), "changed", G_CALLBACK(location_changed), object);
hig_workarea_add_row(t, &row, _("Location:"), w, NULL);
priv->move_check =