summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--AndroidManifest.xml5
-rw-r--r--src/com/android/launcher2/Folder.java13
-rw-r--r--src/com/android/launcher2/Launcher.java6
-rw-r--r--src/com/android/launcher2/LauncherProvider.java3
4 files changed, 10 insertions, 17 deletions
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index ebcdea59..ffedec7f 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -94,11 +94,6 @@
</intent-filter>
</activity>
- <!-- Enable system-default search mode for any activity in Home -->
- <meta-data
- android:name="android.app.default_searchable"
- android:value="*" />
-
<!-- Intent received used to install shortcuts from other applications -->
<receiver
android:name=".InstallShortcutReceiver"
diff --git a/src/com/android/launcher2/Folder.java b/src/com/android/launcher2/Folder.java
index 7c35f799..435004d3 100644
--- a/src/com/android/launcher2/Folder.java
+++ b/src/com/android/launcher2/Folder.java
@@ -17,6 +17,7 @@
package com.android.launcher2;
import android.content.Context;
+import android.graphics.Rect;
import android.util.AttributeSet;
import android.view.View;
import android.view.View.OnClickListener;
@@ -47,7 +48,6 @@ public class Folder extends LinearLayout implements DragSource, OnItemLongClickL
* Which item is being dragged
*/
protected ShortcutInfo mDragItem;
- private boolean mCloneInfo;
/**
* Used to inflate the Workspace from XML.
@@ -75,6 +75,10 @@ public class Folder extends LinearLayout implements DragSource, OnItemLongClickL
public void onItemClick(AdapterView parent, View v, int position, long id) {
ShortcutInfo app = (ShortcutInfo) parent.getItemAtPosition(position);
+ int[] pos = new int[2];
+ v.getLocationOnScreen(pos);
+ app.intent.setSourceBounds(new Rect(pos[0], pos[1],
+ pos[0] + v.getWidth(), pos[1] + v.getHeight()));
mLauncher.startActivitySafely(app.intent);
}
@@ -94,9 +98,6 @@ public class Folder extends LinearLayout implements DragSource, OnItemLongClickL
}
ShortcutInfo app = (ShortcutInfo) parent.getItemAtPosition(position);
- if (mCloneInfo) {
- app = new ShortcutInfo(app);
- }
mDragController.startDrag(view, this, app, DragController.DRAG_ACTION_COPY);
mLauncher.closeFolder(this);
@@ -105,10 +106,6 @@ public class Folder extends LinearLayout implements DragSource, OnItemLongClickL
return true;
}
- void setCloneInfo(boolean cloneInfo) {
- mCloneInfo = cloneInfo;
- }
-
public void setDragController(DragController dragController) {
mDragController = dragController;
}
diff --git a/src/com/android/launcher2/Launcher.java b/src/com/android/launcher2/Launcher.java
index 7f9b0d7e..11b26c54 100644
--- a/src/com/android/launcher2/Launcher.java
+++ b/src/com/android/launcher2/Launcher.java
@@ -1258,11 +1258,11 @@ public final class Launcher extends Activity
Object tag = v.getTag();
if (tag instanceof ShortcutInfo) {
// Open shortcut
- final Intent intent = ((ShortcutInfo)tag).intent;
+ final Intent intent = ((ShortcutInfo) tag).intent;
int[] pos = new int[2];
v.getLocationOnScreen(pos);
- intent.setSourceBounds(
- new Rect(pos[0], pos[1], pos[0]+v.getWidth(), pos[1]+v.getHeight()));
+ intent.setSourceBounds(new Rect(pos[0], pos[1],
+ pos[0] + v.getWidth(), pos[1] + v.getHeight()));
startActivitySafely(intent);
} else if (tag instanceof FolderInfo) {
handleFolderClick((FolderInfo) tag);
diff --git a/src/com/android/launcher2/LauncherProvider.java b/src/com/android/launcher2/LauncherProvider.java
index 24b877b8..14c83b3e 100644
--- a/src/com/android/launcher2/LauncherProvider.java
+++ b/src/com/android/launcher2/LauncherProvider.java
@@ -55,7 +55,8 @@ import java.util.List;
import org.xmlpull.v1.XmlPullParserException;
import org.xmlpull.v1.XmlPullParser;
-import com.android.common.XmlUtils;
+
+import com.android.internal.util.XmlUtils;
import com.android.launcher2.LauncherSettings.Favorites;
public class LauncherProvider extends ContentProvider {