am db672b6c: am 00e91901: Merge "DO NOT MERGE Don\'t take flags when creating app widget config activity." into lmp-mr1-dev

* commit 'db672b6cde256e27c1188c7e99f23e5a65252ba4':
  DO NOT MERGE Don't take flags when creating app widget config activity.
This commit is contained in:
Svet Ganov
2015-04-23 15:30:43 +00:00
committed by Android Git Automerger
3 changed files with 5 additions and 8 deletions

View File

@@ -221,10 +221,10 @@ public class AppWidgetHost {
int appWidgetId, int intentFlags, int requestCode, @Nullable Bundle options) { int appWidgetId, int intentFlags, int requestCode, @Nullable Bundle options) {
try { try {
IntentSender intentSender = sService.createAppWidgetConfigIntentSender( IntentSender intentSender = sService.createAppWidgetConfigIntentSender(
mContextOpPackageName, appWidgetId, intentFlags); mContextOpPackageName, appWidgetId);
if (intentSender != null) { if (intentSender != null) {
activity.startIntentSenderForResult(intentSender, requestCode, null, 0, 0, 0, activity.startIntentSenderForResult(intentSender, requestCode, null, 0,
options); intentFlags, intentFlags, options);
} else { } else {
throw new ActivityNotFoundException(); throw new ActivityNotFoundException();
} }

View File

@@ -41,8 +41,7 @@ interface IAppWidgetService {
void deleteAllHosts(); void deleteAllHosts();
RemoteViews getAppWidgetViews(String callingPackage, int appWidgetId); RemoteViews getAppWidgetViews(String callingPackage, int appWidgetId);
int[] getAppWidgetIdsForHost(String callingPackage, int hostId); int[] getAppWidgetIdsForHost(String callingPackage, int hostId);
IntentSender createAppWidgetConfigIntentSender(String callingPackage, int appWidgetId, IntentSender createAppWidgetConfigIntentSender(String callingPackage, int appWidgetId);
int intentFlags);
// //
// for AppWidgetManager // for AppWidgetManager

View File

@@ -673,8 +673,7 @@ class AppWidgetServiceImpl extends IAppWidgetService.Stub implements WidgetBacku
} }
@Override @Override
public IntentSender createAppWidgetConfigIntentSender(String callingPackage, int appWidgetId, public IntentSender createAppWidgetConfigIntentSender(String callingPackage, int appWidgetId) {
int intentFlags) {
final int userId = UserHandle.getCallingUserId(); final int userId = UserHandle.getCallingUserId();
if (DEBUG) { if (DEBUG) {
@@ -704,7 +703,6 @@ class AppWidgetServiceImpl extends IAppWidgetService.Stub implements WidgetBacku
Intent intent = new Intent(AppWidgetManager.ACTION_APPWIDGET_CONFIGURE); Intent intent = new Intent(AppWidgetManager.ACTION_APPWIDGET_CONFIGURE);
intent.putExtra(AppWidgetManager.EXTRA_APPWIDGET_ID, appWidgetId); intent.putExtra(AppWidgetManager.EXTRA_APPWIDGET_ID, appWidgetId);
intent.setComponent(provider.info.configure); intent.setComponent(provider.info.configure);
intent.setFlags(intentFlags);
// All right, create the sender. // All right, create the sender.
final long identity = Binder.clearCallingIdentity(); final long identity = Binder.clearCallingIdentity();