cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michal Mocny (JIRA)" <>
Subject [jira] [Commented] (CB-6048) Add config setting for Android app launchMode
Date Wed, 28 May 2014 15:16:03 GMT


Michal Mocny commented on CB-6048:

Frederico: I can confirm this bug as you describe.  The cause is that we are only parsing
the top-level config.xml at cordova prepare time, and not using the defaults.xml at all.

The original version of this patch set the default in the android application template explicitly,
and a subsequent user patch changed to using a <preference>.  I think the <preference>
is a better model, and although I recall testing that patch successfully, I cannot replicate
it ever working now.

I'll work on a fix, but please follow progress on CB-6772 from now on.

> Add config setting for Android app launchMode
> ---------------------------------------------
>                 Key: CB-6048
>                 URL:
>             Project: Apache Cordova
>          Issue Type: New Feature
>          Components: Android, CLI
>            Reporter: Michal Mocny
>            Assignee: Michal Mocny
> As raised on mailing list: "[Android] Apps restart instead of resume when brought to
focus by clicking app icon"
> "TLDR; AndroidManifest.xml <activity> needs: android:launchMode="singleTop" --
can I add it?
> Quick search brings up:
> ..which advises to add android:launchMode="singleTask" to AndroidManifest.xml <activity>,
which does fix the issue.
> According to the descriptions in
the differences mostly stem in how the app handles intents, however, there is a comment in
the table of descriptions which labels singleTask launchMode as  "(not recommended for general
> On the other hand, singleTop mode *is* recommended, and also fixes the issue, and according
to the description, sounds to me like a much better default."

This message was sent by Atlassian JIRA

View raw message