Commit fdcb7c1f authored by narinder Rana's avatar narinder Rana
Browse files

Merge branch '191-widgetNotResizable' into 'master'

191 widget not resizable

See merge request !71
parents e4961ec5 20dd92d6
Pipeline #178238 passed with stage
in 2 minutes and 4 seconds
......@@ -4,11 +4,9 @@ import android.appwidget.AppWidgetManager;
import android.appwidget.AppWidgetProviderInfo;
import android.content.Context;
import android.os.Bundle;
import android.util.Log;
import android.widget.LinearLayout;
import android.widget.Toast;
import androidx.annotation.NonNull;
import foundation.e.blisslauncher.BlissLauncher;
import foundation.e.blisslauncher.R;
import foundation.e.blisslauncher.core.customviews.RoundedWidgetView;
......@@ -16,8 +14,10 @@ import foundation.e.blisslauncher.features.launcher.LauncherActivity;
public class WidgetViewBuilder {
private static final String TAG = "WidgetViewBuilder";
public static RoundedWidgetView create(LauncherActivity launcherActivity,
@NonNull RoundedWidgetView roundedWidgetView) {
@NonNull RoundedWidgetView roundedWidgetView) {
if (BlissLauncher.getApplication(launcherActivity).getAppWidgetHost() == null) return null;
roundedWidgetView.post(() -> updateWidgetOption(launcherActivity, roundedWidgetView,
roundedWidgetView.getAppWidgetInfo()));
......@@ -35,8 +35,7 @@ public class WidgetViewBuilder {
== AppWidgetProviderInfo.RESIZE_VERTICAL) {
launcherActivity.showWidgetResizeContainer(roundedWidgetView);
} else {
Toast.makeText(launcherActivity, "Widget is not resizable",
Toast.LENGTH_SHORT).show();
Log.i(TAG, launcherActivity.getString(R.string.widget_is_not_resizable));
}
return true;
});
......
......@@ -176,4 +176,5 @@
<string name="widgets">Widgets</string>
<string name="uninstall_shortcut_dialog">Do you want to uninstall this shortcut?</string>
<string name="ok">ok</string>
<string name="widget_is_not_resizable">Widget is not resizable</string>
</resources>
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment