# HG changeset patch # User Xeli # Date 1322493695 -3600 # Node ID c476061f0466d490c7801607a6f0208bb633e531 # Parent 2ca787ac8fc374271cbdd86e3990aac23942a630 android: use linkedlist instead of the deque interface, Deque<> isn't supported until gingerbread diff -r 2ca787ac8fc3 -r c476061f0466 project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadService.java --- a/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadService.java Mon Nov 28 16:20:48 2011 +0100 +++ b/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadService.java Mon Nov 28 16:21:35 2011 +0100 @@ -19,7 +19,6 @@ package org.hedgewars.hedgeroid.Downloader; -import java.util.Deque; import java.util.LinkedList; import java.util.List; @@ -57,7 +56,7 @@ private NotificationManager nM; private RemoteViews contentView; - private Deque downloadTasks = new LinkedList(); + private LinkedList downloadTasks = new LinkedList(); private DownloadTask currentTask = null; public class DownloadHandler extends Handler{ @@ -112,7 +111,7 @@ private void runNextTask(){ if(asyncExecutor == null){//if (task isnt running right now) ... - currentTask = downloadTasks.pollFirst(); + currentTask = downloadTasks.poll(); if(currentTask != null){ asyncExecutor = new DownloadAsyncTask(currentTask); asyncExecutor.execute(currentTask.getPackage());