pub enum DocumentLaunchMode {
IntoExisting,
Always,
None,
Never,
}
Expand description
Four values which produce the following effects when the user opens a document with the application
Variants§
IntoExisting
The system searches for a task whose base intent’s ComponentName
and data URI
match those of the launching intent. If the system finds such a task, the
system clears the task, and restarts with the root activity receiving a call
to onNewIntent(android.content.Intent)
. If the system does not find such a
task, the system creates a new task.
Always
The activity creates a new task for the document, even if the document is already
opened. This is the same as setting both the FLAG_ACTIVITY_NEW_DOCUMENT
and FLAG_ACTIVITY_MULTIPLE_TASK
flags.
None
The activity does not create a new task for the activity. This is the default
value, which creates a new task only when FLAG_ACTIVITY_NEW_TASK
is set. The overview screen treats the activity as it would by
default: it displays a single task for the app, which resumes from
whatever activity the user last invoked.
Never
This activity is not launched into a new document even if the Intent contains
FLAG_ACTIVITY_NEW_DOCUMENT
. Setting this overrides the behavior of the
FLAG_ACTIVITY_NEW_DOCUMENT
and FLAG_ACTIVITY_MULTIPLE_TASK
flags, if
either of these are set in the activity, and the overview screen displays a
single task for the app, which resumes from whatever activity the user last
invoked.
Trait Implementations§
Source§impl Clone for DocumentLaunchMode
impl Clone for DocumentLaunchMode
Source§fn clone(&self) -> DocumentLaunchMode
fn clone(&self) -> DocumentLaunchMode
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
source
. Read more