im.pidgin.pidgin: 752ed735536991596dbe65043e784537f38a78c0
sadrul at pidgin.im
sadrul at pidgin.im
Wed Jan 9 03:40:43 EST 2008
-----------------------------------------------------------------
Revision: 752ed735536991596dbe65043e784537f38a78c0
Ancestor: 43a19998a89d2f7229e2703407a0fbfe7685896b
Author: sadrul at pidgin.im
Date: 2008-01-09T08:42:33
Branch: im.pidgin.pidgin
Modified files:
finch/gntft.c
ChangeLog:
Remove the completed/cancelled xfers when 'Clear finished transfers' is selected. (Did anyone notice our 'purple_xfer_is_canceled' is typoed?)
-------------- next part --------------
============================================================
--- finch/gntft.c 75afd71ad2c902635664a55ea772c232712456a6
+++ finch/gntft.c b645f863e49eae1d215dba04bb1b387d0569ab2b
@@ -142,15 +142,23 @@ toggle_clear_finished_cb(GntWidget *w)
xfer_dialog->auto_clear = !xfer_dialog->auto_clear;
purple_prefs_set_bool("/finch/filetransfer/clear_finished",
xfer_dialog->auto_clear);
+ if (xfer_dialog->auto_clear) {
+ GList *iter = purple_xfers_get_all();
+ while (iter) {
+ PurpleXfer *xfer = iter->data;
+ iter = iter->next;
+ if (purple_xfer_is_completed(xfer) || purple_xfer_is_canceled(xfer))
+ finch_xfer_dialog_remove_xfer(xfer);
+ }
+ }
}
static void
remove_button_cb(GntButton *button)
{
PurpleXfer *selected_xfer = gnt_tree_get_selection_data(GNT_TREE(xfer_dialog->tree));
- if (selected_xfer && (selected_xfer->status == PURPLE_XFER_STATUS_CANCEL_LOCAL ||
- selected_xfer->status == PURPLE_XFER_STATUS_CANCEL_REMOTE ||
- selected_xfer->status == PURPLE_XFER_STATUS_DONE)) {
+ if (selected_xfer && (purple_xfer_is_completed(selected_xfer) ||
+ purple_xfer_is_canceled(selected_xfer))) {
finch_xfer_dialog_remove_xfer(selected_xfer);
}
}
More information about the Commits
mailing list