import android.os.Handler;
import android.os.HandlerThread;
import android.os.Parcelable;
-import android.os.RemoteException;
-import android.util.Log;
import android.os.Process;
+import android.os.RemoteException;
import android.os.SystemClock;
+import android.util.Log;
+ import java.lang.ref.WeakReference;
+ import java.net.URISyntaxException;
+ import java.text.Collator;
+ import java.util.ArrayList;
+ import java.util.Arrays;
+ import java.util.Collections;
+ import java.util.Comparator;
+ import java.util.HashMap;
+ import java.util.List;
+
import com.android.launcher.R;
/**
final ContentResolver cr = context.getContentResolver();
values.put(LauncherSettings.Favorites.CONTAINER, item.container);
- values.put(LauncherSettings.Favorites.CELLX, item.cellX);
- values.put(LauncherSettings.Favorites.CELLY, item.cellY);
+ values.put(LauncherSettings.Favorites.CELLX, cellX);
+ values.put(LauncherSettings.Favorites.CELLY, cellY);
values.put(LauncherSettings.Favorites.SCREEN, item.screen);
- new Thread("moveItemInDatabase") {
- public void run() {
- cr.update(uri, values, null, null);
- }
- }.start();
+ sWorker.post(new Runnable() {
+ public void run() {
+ cr.update(uri, values, null, null);
+ }
+ });
}
/**