OSDN Git Service

CodeCleanup : Replace StringBuffer with String
[android-x86/packages-apps-Eleven.git] / src / com / cyanogenmod / eleven / loaders / LastAddedLoader.java
index f774394..6f948f5 100644 (file)
@@ -114,11 +114,10 @@ public class LastAddedLoader extends SectionCreator.SimpleListLoader<Song> {
         // use the most recent of the two timestamps
         if(cutoff < fourWeeksAgo) { cutoff = fourWeeksAgo; }
 
-        final StringBuilder selection = new StringBuilder();
-        selection.append(AudioColumns.IS_MUSIC + "=1");
-        selection.append(" AND " + AudioColumns.TITLE + " != ''"); //$NON-NLS-2$
-        selection.append(" AND " + MediaStore.Audio.Media.DATE_ADDED + ">"); //$NON-NLS-2$
-        selection.append(cutoff);
+        String selection = (AudioColumns.IS_MUSIC + "=1") +
+                " AND " + AudioColumns.TITLE + " != ''" +
+                " AND " + MediaStore.Audio.Media.DATE_ADDED + ">" +
+                cutoff;
 
         return context.getContentResolver().query(MediaStore.Audio.Media.EXTERNAL_CONTENT_URI,
                 new String[] {
@@ -136,6 +135,6 @@ public class LastAddedLoader extends SectionCreator.SimpleListLoader<Song> {
                         AudioColumns.DURATION,
                         /* 6 */
                         AudioColumns.YEAR,
-                }, selection.toString(), null, MediaStore.Audio.Media.DATE_ADDED + " DESC");
+                }, selection, null, MediaStore.Audio.Media.DATE_ADDED + " DESC");
     }
 }