summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/com/cyanogenmod/trebuchet/AppWidgetResizeFrame.java18
-rw-r--r--src/com/cyanogenmod/trebuchet/Workspace.java13
-rw-r--r--src/com/cyanogenmod/trebuchet/preference/PreferencesProvider.java3
3 files changed, 7 insertions, 27 deletions
diff --git a/src/com/cyanogenmod/trebuchet/AppWidgetResizeFrame.java b/src/com/cyanogenmod/trebuchet/AppWidgetResizeFrame.java
index 0493f76..5b868c1 100644
--- a/src/com/cyanogenmod/trebuchet/AppWidgetResizeFrame.java
+++ b/src/com/cyanogenmod/trebuchet/AppWidgetResizeFrame.java
@@ -13,8 +13,6 @@ import android.view.Gravity;
import android.widget.FrameLayout;
import android.widget.ImageView;
-import com.cyanogenmod.trebuchet.preference.PreferencesProvider;
-
public class AppWidgetResizeFrame extends FrameLayout {
private LauncherAppWidgetHostView mWidgetView;
private CellLayout mCellLayout;
@@ -120,19 +118,9 @@ public class AppWidgetResizeFrame extends FrameLayout {
mWidgetPaddingBottom = p.bottom;
// Resize any widget
- if (PreferencesProvider.Interface.Homescreen.getResizeAnyWidget()) {
- mResizeMode = AppWidgetProviderInfo.RESIZE_BOTH;
- mMinHSpan = 1;
- mMinVSpan = 1;
- }
-
- if (mResizeMode == AppWidgetProviderInfo.RESIZE_HORIZONTAL) {
- mTopHandle.setVisibility(GONE);
- mBottomHandle.setVisibility(GONE);
- } else if (mResizeMode == AppWidgetProviderInfo.RESIZE_VERTICAL) {
- mLeftHandle.setVisibility(GONE);
- mRightHandle.setVisibility(GONE);
- }
+ mResizeMode = AppWidgetProviderInfo.RESIZE_BOTH;
+ mMinHSpan = 1;
+ mMinVSpan = 1;
final float density = mLauncher.getResources().getDisplayMetrics().density;
mBackgroundPadding = (int) Math.ceil(density * BACKGROUND_PADDING);
diff --git a/src/com/cyanogenmod/trebuchet/Workspace.java b/src/com/cyanogenmod/trebuchet/Workspace.java
index b78b448..e4e19da 100644
--- a/src/com/cyanogenmod/trebuchet/Workspace.java
+++ b/src/com/cyanogenmod/trebuchet/Workspace.java
@@ -389,7 +389,6 @@ public class Workspace extends PagedView
mStretchScreens = PreferencesProvider.Interface.Homescreen.getStretchScreens();
mShowSearchBar = PreferencesProvider.Interface.Homescreen.getShowSearchBar();
mShowHotseat = PreferencesProvider.Interface.Dock.getShowDock();
- mResizeAnyWidget = PreferencesProvider.Interface.Homescreen.getResizeAnyWidget();
mHideIconLabels = PreferencesProvider.Interface.Homescreen.getHideIconLabels();
mTransitionEffect = PreferencesProvider.Interface.Homescreen.Scrolling.getTransitionEffect(
res.getString(R.string.config_workspaceDefaultTransitionEffect));
@@ -2908,16 +2907,13 @@ public class Workspace extends PagedView
// in its final location
final LauncherAppWidgetHostView hostView = (LauncherAppWidgetHostView) cell;
- AppWidgetProviderInfo pinfo = hostView.getAppWidgetInfo();
- if (pinfo != null &&
- pinfo.resizeMode != AppWidgetProviderInfo.RESIZE_NONE || mResizeAnyWidget) {
- final Runnable addResizeFrame = new Runnable() {
+ final Runnable addResizeFrame = new Runnable() {
public void run() {
DragLayer dragLayer = mLauncher.getDragLayer();
dragLayer.addResizeFrame(hostView, cellLayout);
}
- };
- resizeRunnable = (new Runnable() {
+ };
+ resizeRunnable = new Runnable() {
public void run() {
if (!isPageMoving()) {
addResizeFrame.run();
@@ -2925,8 +2921,7 @@ public class Workspace extends PagedView
mDelayedResizeRunnable = addResizeFrame;
}
}
- });
- }
+ };
}
LauncherModel.moveItemInDatabase(mLauncher, info, container, screen, lp.cellX,
diff --git a/src/com/cyanogenmod/trebuchet/preference/PreferencesProvider.java b/src/com/cyanogenmod/trebuchet/preference/PreferencesProvider.java
index a20d812..045a9df 100644
--- a/src/com/cyanogenmod/trebuchet/preference/PreferencesProvider.java
+++ b/src/com/cyanogenmod/trebuchet/preference/PreferencesProvider.java
@@ -82,9 +82,6 @@ public final class PreferencesProvider {
public static boolean getShowSearchBar() {
return getBoolean("ui_homescreen_general_search", true);
}
- public static boolean getResizeAnyWidget() {
- return getBoolean("ui_homescreen_general_resize_any_widget", false);
- }
public static boolean getHideIconLabels() {
return getBoolean("ui_homescreen_general_hide_icon_labels", false);
}