@ -1,6 +1,7 @@
@@ -1,6 +1,7 @@
package org.transdroid.core.gui ;
import java.util.ArrayList ;
import java.util.Collections ;
import java.util.List ;
import org.androidannotations.annotations.AfterViews ;
@ -35,7 +36,8 @@ import de.keyboardsurfer.android.widget.crouton.Crouton;
@@ -35,7 +36,8 @@ import de.keyboardsurfer.android.widget.crouton.Crouton;
/ * *
* Fragment that shows detailed statistics about some torrent . These come from some already fetched { @link Torrent }
* object , but it also retrieves further detailed statistics .
* object , but it also retrieves further detailed statistics . The actual execution of tasks is performed by the activity
* that contains this fragment , as per the { @link TorrentTasksExecutor } interface .
* @author Eric Kok
* /
@EFragment ( resName = "fragment_details" )
@ -122,6 +124,7 @@ public class DetailsFragment extends SherlockFragment {
@@ -122,6 +124,7 @@ public class DetailsFragment extends SherlockFragment {
// Check if these are actually the details of the torrent we are now showing
if ( ! torrent . getUniqueID ( ) . equals ( checkTorrent . getUniqueID ( ) ) )
return ;
Collections . sort ( newTorrentFiles ) ;
this . torrentFiles = newTorrentFiles ;
( ( DetailsAdapter ) detailsList . getAdapter ( ) ) . updateTorrentFiles ( newTorrentFiles ) ;
}
@ -297,7 +300,8 @@ public class DetailsFragment extends SherlockFragment {
@@ -297,7 +300,8 @@ public class DetailsFragment extends SherlockFragment {
& & detailsList . getAdapter ( ) . getItem ( detailsList . getCheckedItemPositions ( ) . keyAt ( i ) ) instanceof TorrentFile )
checkedCount + + ;
}
mode . setTitle ( getResources ( ) . getQuantityString ( R . plurals . navigation_filesselected , checkedCount , checkedCount ) ) ;
mode . setTitle ( getResources ( ) . getQuantityString ( R . plurals . navigation_filesselected , checkedCount ,
checkedCount ) ) ;
}
@Override