diff --git a/packages/home_widget/android/src/main/kotlin/es/antonborri/home_widget/HomeWidgetPlugin.kt b/packages/home_widget/android/src/main/kotlin/es/antonborri/home_widget/HomeWidgetPlugin.kt index 1fc63c4..24552f6 100644 --- a/packages/home_widget/android/src/main/kotlin/es/antonborri/home_widget/HomeWidgetPlugin.kt +++ b/packages/home_widget/android/src/main/kotlin/es/antonborri/home_widget/HomeWidgetPlugin.kt @@ -109,6 +109,7 @@ class HomeWidgetPlugin : AppWidgetManager.getInstance(context.applicationContext) .getAppWidgetIds(ComponentName(context, javaClass)) intent.putExtra(AppWidgetManager.EXTRA_APPWIDGET_IDS, ids) + intent.putExtra(HomeWidgetPlugin.TRIGGERED_FROM_HOME_WIDGET, true) context.sendBroadcast(intent) result.success(true) } catch (classException: ClassNotFoundException) { @@ -235,6 +236,8 @@ class HomeWidgetPlugin : private const val WIDGET_INFO_KEY_ANDROID_CLASS_NAME = "androidClassName" private const val WIDGET_INFO_KEY_LABEL = "label" + const val TRIGGERED_FROM_HOME_WIDGET = "triggeredFromHomeWidget" + private fun saveCallbackHandle(context: Context, dispatcher: Long, handle: Long) { context .getSharedPreferences(INTERNAL_PREFERENCES, Context.MODE_PRIVATE)