diff options
author | daniel oeh <daniel.oeh@gmail.com> | 2014-04-18 23:36:00 +0200 |
---|---|---|
committer | daniel oeh <daniel.oeh@gmail.com> | 2014-04-18 23:36:00 +0200 |
commit | 9ad429fcf644b9bf21aaff41e2e5e5fa58e73b8e (patch) | |
tree | b7789e090158667bbefd85a45a01dea2965f8905 /src/de/danoeh/antennapod/fragment | |
parent | d0b620fdc53a985acb16beac77171ec5584ddb3c (diff) | |
download | AntennaPod-9ad429fcf644b9bf21aaff41e2e5e5fa58e73b8e.zip |
Moved RemoveListener into DragSortListener
Diffstat (limited to 'src/de/danoeh/antennapod/fragment')
-rw-r--r-- | src/de/danoeh/antennapod/fragment/QueueFragment.java | 21 |
1 files changed, 7 insertions, 14 deletions
diff --git a/src/de/danoeh/antennapod/fragment/QueueFragment.java b/src/de/danoeh/antennapod/fragment/QueueFragment.java index 093151d98..f9b00a616 100644 --- a/src/de/danoeh/antennapod/fragment/QueueFragment.java +++ b/src/de/danoeh/antennapod/fragment/QueueFragment.java @@ -136,19 +136,6 @@ public class QueueFragment extends Fragment { } }); - listView.setRemoveListener(new DragSortListView.RemoveListener() { - @Override - public void remove(int which) { - stopItemLoader(); - FeedItem item = (FeedItem) listView.getAdapter().getItem(which); - DBWriter.removeQueueItem(getActivity(), item.getId(), true); - undoBarController.showUndoBar(false, - getString(R.string.removed_from_queue), new FeedItemUndoToken(item, - which) - ); - } - }); - undoBarController = new UndoBarController(root.findViewById(R.id.undobar), new UndoBarController.UndoListener() { @Override public void onUndo(Parcelable token) { @@ -182,7 +169,13 @@ public class QueueFragment extends Fragment { @Override public void remove(int which) { - + stopItemLoader(); + FeedItem item = (FeedItem) listView.getAdapter().getItem(which); + DBWriter.removeQueueItem(getActivity(), item.getId(), true); + undoBarController.showUndoBar(false, + getString(R.string.removed_from_queue), new FeedItemUndoToken(item, + which) + ); } }); |