mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Projucer (Android): Avoid setting orientation key when unspecified by user
This commit is contained in:
parent
5e44c34377
commit
f30d70049c
5 changed files with 9 additions and 14 deletions
|
|
@ -24,8 +24,7 @@
|
|||
<application android:label="@string/app_name" android:name="com.rmsl.juce.JuceApp" android:icon="@drawable/icon" android:hardwareAccelerated="false">
|
||||
<receiver android:name="com.rmsl.juce.Receiver" android:exported="false"/>
|
||||
<activity android:name="com.rmsl.juce.JuceActivity" android:configChanges="keyboard|keyboardHidden|orientation|screenSize|navigation|smallestScreenSize|screenLayout"
|
||||
android:screenOrientation="unspecified" android:launchMode="singleTask" android:hardwareAccelerated="true"
|
||||
android:exported="true">
|
||||
android:launchMode="singleTask" android:hardwareAccelerated="true" android:exported="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<category android:name="android.intent.category.LAUNCHER"/>
|
||||
|
|
|
|||
|
|
@ -14,8 +14,7 @@
|
|||
<application android:label="@string/app_name" android:name="com.rmsl.juce.JuceApp" android:hardwareAccelerated="false">
|
||||
<receiver android:name="com.rmsl.juce.Receiver" android:exported="false"/>
|
||||
<activity android:name="com.rmsl.juce.JuceActivity" android:configChanges="keyboard|keyboardHidden|orientation|screenSize|navigation|smallestScreenSize|screenLayout"
|
||||
android:screenOrientation="unspecified" android:launchMode="singleTask" android:hardwareAccelerated="true"
|
||||
android:exported="true">
|
||||
android:launchMode="singleTask" android:hardwareAccelerated="true" android:exported="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<category android:name="android.intent.category.LAUNCHER"/>
|
||||
|
|
|
|||
|
|
@ -23,8 +23,7 @@
|
|||
<application android:label="@string/app_name" android:name="com.rmsl.juce.JuceApp" android:icon="@drawable/icon" android:hardwareAccelerated="false">
|
||||
<receiver android:name="com.rmsl.juce.Receiver" android:exported="false"/>
|
||||
<activity android:name="com.rmsl.juce.JuceActivity" android:configChanges="keyboard|keyboardHidden|orientation|screenSize|navigation|smallestScreenSize|screenLayout"
|
||||
android:screenOrientation="unspecified" android:launchMode="singleTask" android:hardwareAccelerated="true"
|
||||
android:exported="true">
|
||||
android:launchMode="singleTask" android:hardwareAccelerated="true" android:exported="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<category android:name="android.intent.category.LAUNCHER"/>
|
||||
|
|
|
|||
|
|
@ -15,8 +15,7 @@
|
|||
<application android:label="@string/app_name" android:name="com.rmsl.juce.JuceApp" android:icon="@drawable/icon" android:hardwareAccelerated="false">
|
||||
<receiver android:name="com.rmsl.juce.Receiver" android:exported="false"/>
|
||||
<activity android:name="com.rmsl.juce.JuceActivity" android:configChanges="keyboard|keyboardHidden|orientation|screenSize|navigation|smallestScreenSize|screenLayout"
|
||||
android:screenOrientation="unspecified" android:launchMode="singleTask" android:hardwareAccelerated="true"
|
||||
android:exported="true">
|
||||
android:launchMode="singleTask" android:hardwareAccelerated="true" android:exported="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<category android:name="android.intent.category.LAUNCHER"/>
|
||||
|
|
|
|||
|
|
@ -1848,13 +1848,12 @@ private:
|
|||
if (! act->hasAttribute ("android:configChanges"))
|
||||
act->setAttribute ("android:configChanges", "keyboard|keyboardHidden|orientation|screenSize|navigation|smallestScreenSize|screenLayout");
|
||||
|
||||
if (androidScreenOrientation.get() == "landscape")
|
||||
if (androidScreenOrientation.get() != "unspecified")
|
||||
{
|
||||
setAttributeIfNotPresent (*act, "android:screenOrientation", "userLandscape");
|
||||
}
|
||||
else
|
||||
{
|
||||
setAttributeIfNotPresent (*act, "android:screenOrientation", androidScreenOrientation.get());
|
||||
setAttributeIfNotPresent (*act,
|
||||
"android:screenOrientation",
|
||||
androidScreenOrientation.get() == "landscape" ? "userLandscape"
|
||||
: androidScreenOrientation.get());
|
||||
}
|
||||
|
||||
setAttributeIfNotPresent (*act, "android:launchMode", "singleTask");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue