Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 595c7ced authored by Steven Ng's avatar Steven Ng Committed by Automerger Merge Worker
Browse files

Merge "Fix PendingWidgetHostView overlapping UI" into sc-dev am: e8772c16

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/14980850

Change-Id: I462b605d109dcb9799bbf76f1c5adee0d283eccf
parents 1789b00e e8772c16
Loading
Loading
Loading
Loading
+4 −4
Original line number Original line Diff line number Diff line
@@ -190,11 +190,11 @@
    <!-- Widgets: -->
    <!-- Widgets: -->
    <skip />    
    <skip />    


    <!-- Text to show user in place of a gadget when we can't display it properly -->
    <!-- Error text that lets a user know that the widget can't load. -->
    <string name="gadget_error_text">Problem loading widget</string>
    <string name="gadget_error_text">Can\'t load widget</string>


    <!-- Text to show user in place of a gadget when it is not yet initialized. -->
    <!-- Instructional text to encourage a user to finish setting up the widget. -->
    <string name="gadget_setup_text">Setup</string>
    <string name="gadget_setup_text">Tap to finish setup</string>


    <!-- Text to inform the user that they can't uninstall a system application -->
    <!-- Text to inform the user that they can't uninstall a system application -->
    <string name="uninstall_system_app_text">This is a system app and can\'t be uninstalled.</string>
    <string name="uninstall_system_app_text">This is a system app and can\'t be uninstalled.</string>
+2 −2
Original line number Original line Diff line number Diff line
@@ -97,9 +97,9 @@ public class PendingAppWidgetHostView extends LauncherAppWidgetHostView


    @Override
    @Override
    public void updateAppWidget(RemoteViews remoteViews) {
    public void updateAppWidget(RemoteViews remoteViews) {
        super.updateAppWidget(remoteViews);
        WidgetManagerHelper widgetManagerHelper = new WidgetManagerHelper(getContext());
        WidgetManagerHelper widgetManagerHelper = new WidgetManagerHelper(getContext());
        if (widgetManagerHelper.isAppWidgetRestored(mInfo.appWidgetId)) {
        if (widgetManagerHelper.isAppWidgetRestored(mInfo.appWidgetId)) {
            super.updateAppWidget(remoteViews);
            reInflate();
            reInflate();
        }
        }
    }
    }
@@ -149,7 +149,7 @@ public class PendingAppWidgetHostView extends LauncherAppWidgetHostView
            // The view displays three modes,
            // The view displays three modes,
            //   1) App icon in the center
            //   1) App icon in the center
            //   2) Preload icon in the center
            //   2) Preload icon in the center
            //   3) Setup icon in the center and app icon in the top right corner.
            //   3) App icon in the center with a setup icon on the top left corner.
            if (mDisabledForSafeMode) {
            if (mDisabledForSafeMode) {
                FastBitmapDrawable disabledIcon = info.newIcon(getContext());
                FastBitmapDrawable disabledIcon = info.newIcon(getContext());
                disabledIcon.setIsDisabled(true);
                disabledIcon.setIsDisabled(true);