Created
November 14, 2015 17:04
AppWidgetProvider for configurable widget, onDelete example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Override | |
public void onDeleted(Context context, int[] appWidgetIds) { | |
super.onDeleted(context, appWidgetIds); | |
WidgetEntryDao dao = new WidgetEntryDao(new DbHelper(context)); | |
final int N = appWidgetIds.length; | |
for (int i = 0; i < N; i++) { | |
dao.deleteByWidgetId(appWidgetIds[i]); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment