зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1153193 - Add EXTRA_DEVICES_ONLY flag to share intents. r=rnewman
Before we only added this flag to the share intent used by the browser toolbar menu. Practically, this has the effect of having "Add to <current channel>" opening the share overlay with *only* the device list wherever getShareIntent() is used. Ideally, this method is used anywhere we use ACTION_SEND. I've noticed this change makes both sharing from the long-press context menu and about:reader to display *only* the device list. --HG-- extra : rebase_source : 63fd4c7ebfa43ed3f2f7fc3d0ef9809a5458aa9f
This commit is contained in:
Родитель
638ae38563
Коммит
6b55c804ac
|
@ -43,6 +43,7 @@ import org.mozilla.gecko.mozglue.JNITarget;
|
|||
import org.mozilla.gecko.mozglue.RobocopTarget;
|
||||
import org.mozilla.gecko.mozglue.generatorannotations.OptionalGeneratedParameter;
|
||||
import org.mozilla.gecko.mozglue.generatorannotations.WrapElementForJNI;
|
||||
import org.mozilla.gecko.overlays.ui.ShareDialog;
|
||||
import org.mozilla.gecko.prompts.PromptService;
|
||||
import org.mozilla.gecko.util.EventCallback;
|
||||
import org.mozilla.gecko.util.GeckoRequest;
|
||||
|
@ -1162,6 +1163,7 @@ public class GeckoAppShell
|
|||
Intent shareIntent = getIntentForActionString(Intent.ACTION_SEND);
|
||||
shareIntent.putExtra(Intent.EXTRA_TEXT, targetURI);
|
||||
shareIntent.putExtra(Intent.EXTRA_SUBJECT, title);
|
||||
shareIntent.putExtra(ShareDialog.INTENT_EXTRA_DEVICES_ONLY, true);
|
||||
|
||||
// Note that EXTRA_TITLE is intended to be used for share dialog
|
||||
// titles. Common usage (e.g., Pocket) suggests that it's sometimes
|
||||
|
|
Загрузка…
Ссылка в новой задаче