Version 2.2.7: Better tablet recognization
This commit is contained in:
parent
cbdd4ec80f
commit
4f25216ce8
4 changed files with 12 additions and 9 deletions
|
@ -6,10 +6,10 @@ android {
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId "de.marcelkapfer.morseconverter"
|
applicationId "de.marcelkapfer.morseconverter"
|
||||||
minSdkVersion 11
|
minSdkVersion 15
|
||||||
targetSdkVersion 22
|
targetSdkVersion 22
|
||||||
versionCode 226
|
versionCode 227
|
||||||
versionName "2.2.6<"
|
versionName "2.2.7"
|
||||||
}
|
}
|
||||||
buildTypes {
|
buildTypes {
|
||||||
release {
|
release {
|
||||||
|
|
|
@ -25,10 +25,13 @@ import android.content.ClipData;
|
||||||
import android.content.ClipboardManager;
|
import android.content.ClipboardManager;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
|
import android.content.res.Configuration;
|
||||||
import android.content.res.Resources;
|
import android.content.res.Resources;
|
||||||
|
import android.graphics.Point;
|
||||||
import android.net.Uri;
|
import android.net.Uri;
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.support.v7.widget.CardView;
|
import android.support.v7.widget.CardView;
|
||||||
|
import android.util.DisplayMetrics;
|
||||||
import android.view.Display;
|
import android.view.Display;
|
||||||
import android.view.Surface;
|
import android.view.Surface;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
|
@ -102,12 +105,12 @@ public class MainActivity extends MaterialNavigationDrawer implements BillingPro
|
||||||
this.disableLearningPattern(); //Doesn't open the drawer always when the app starts
|
this.disableLearningPattern(); //Doesn't open the drawer always when the app starts
|
||||||
setBackPattern(MaterialNavigationDrawer.BACKPATTERN_BACK_TO_FIRST);
|
setBackPattern(MaterialNavigationDrawer.BACKPATTERN_BACK_TO_FIRST);
|
||||||
|
|
||||||
Display display = ((WindowManager) getSystemService(WINDOW_SERVICE)).getDefaultDisplay();
|
// Enables shadow only on devices with landscape. Necessary because of the list views
|
||||||
|
DisplayMetrics metrics = new DisplayMetrics();
|
||||||
|
getWindowManager().getDefaultDisplay().getMetrics(metrics);
|
||||||
|
|
||||||
if(display.getRotation() == Surface.ROTATION_90 ||
|
if(metrics.widthPixels < metrics.heightPixels){
|
||||||
display.getRotation() == Surface.ROTATION_270){
|
|
||||||
enableToolbarElevation();
|
enableToolbarElevation();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
mDrawerToggle = new MaterialActionBarDrawerToggle(this, null, null, 0, 0){
|
mDrawerToggle = new MaterialActionBarDrawerToggle(this, null, null, 0, 0){
|
||||||
|
|
|
@ -38,7 +38,7 @@
|
||||||
<string name="aboutBug">Wenn Du einen Fehler gefunden hast, schreibe mir bitte ein E-Mail an marcelmichaelkapfer@yahoo.co.nz</string>
|
<string name="aboutBug">Wenn Du einen Fehler gefunden hast, schreibe mir bitte ein E-Mail an marcelmichaelkapfer@yahoo.co.nz</string>
|
||||||
<string name="aboutHow">Du kannst eine ausführliche Anleitung auf marcel-kapfer.de/writtenmorse/index.html#howto_android finden.</string>
|
<string name="aboutHow">Du kannst eine ausführliche Anleitung auf marcel-kapfer.de/writtenmorse/index.html#howto_android finden.</string>
|
||||||
<string name="aboutMissing">Wenn Du auf einen fehlenden Code aufmerksam geworden bist, dann schreibe eine E-Mail an marcelmichaelkapfer@yahoo.co.nz.</string>
|
<string name="aboutMissing">Wenn Du auf einen fehlenden Code aufmerksam geworden bist, dann schreibe eine E-Mail an marcelmichaelkapfer@yahoo.co.nz.</string>
|
||||||
<string name="aboutVersion">2.2.6 \n29. Mai 2015</string>
|
<string name="aboutVersion">2.2.7 \n01. Juni 2015</string>
|
||||||
<string name="sectionBug">Fehler</string>
|
<string name="sectionBug">Fehler</string>
|
||||||
<string name="sectionContact">Kontakt</string>
|
<string name="sectionContact">Kontakt</string>
|
||||||
<string name="sectionDeveloper">Entwickler</string>
|
<string name="sectionDeveloper">Entwickler</string>
|
||||||
|
|
|
@ -43,7 +43,7 @@
|
||||||
<string name="sectionHow">How to</string>
|
<string name="sectionHow">How to</string>
|
||||||
<string name="sectionMissing">Missing Code</string>
|
<string name="sectionMissing">Missing Code</string>
|
||||||
<!--About Texts-->
|
<!--About Texts-->
|
||||||
<string name="aboutVersion">2.2.6 \n29 May 2015</string>
|
<string name="aboutVersion">2.2.7 \n01 June 2015</string>
|
||||||
<string name="aboutDeveloper" translatable="false">Marcel Michael Kapfer</string>
|
<string name="aboutDeveloper" translatable="false">Marcel Michael Kapfer</string>
|
||||||
<string name="aboutWebsite" translatable="false">marcel-kapfer.de/writtenmorse</string>
|
<string name="aboutWebsite" translatable="false">marcel-kapfer.de/writtenmorse</string>
|
||||||
<string name="aboutContact" translatable="false">marcelmichaelkapfer@yahoo.co.nz</string>
|
<string name="aboutContact" translatable="false">marcelmichaelkapfer@yahoo.co.nz</string>
|
||||||
|
|
Reference in a new issue