diff options
author | rachytski <siarhei.rachytski@gmail.com> | 2012-07-03 11:25:17 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 01:40:29 +0300 |
commit | f4bba5a4ba47f5631d5d9604230397b45c0a2f8f (patch) | |
tree | 6845e060a97518a9fc1511e468d430ecd77c6024 | |
parent | fbfc930cc3ded001e116ba79ac6aaf266d1cc748 (diff) |
[android] added MapsWithMeLite and MapsWithMePro projects. using MapsWithMe as a separate library.
-rw-r--r-- | .gitignore | 56 | ||||
-rw-r--r-- | android/AndroidManifest.xml | 2 | ||||
-rw-r--r-- | android/MapsWithMeLite/AndroidManifest.xml | 60 | ||||
-rw-r--r-- | android/MapsWithMeLite/build.xml | 92 | ||||
-rw-r--r-- | android/MapsWithMeLite/proguard-project.txt | 20 | ||||
-rw-r--r-- | android/MapsWithMeLite/project.properties | 15 | ||||
-rw-r--r-- | android/MapsWithMeLite/res/values/strings.xml | 4 | ||||
-rw-r--r-- | android/MapsWithMeLite/res/values/styles.xml | 5 | ||||
-rw-r--r-- | android/MapsWithMePro/AndroidManifest.xml | 60 | ||||
-rw-r--r-- | android/MapsWithMePro/build.xml | 92 | ||||
-rw-r--r-- | android/MapsWithMePro/proguard-project.txt | 20 | ||||
-rw-r--r-- | android/MapsWithMePro/project.properties | 15 | ||||
-rw-r--r-- | android/MapsWithMePro/res/values/strings.xml | 4 | ||||
-rw-r--r-- | android/MapsWithMePro/res/values/styles.xml | 5 | ||||
-rw-r--r-- | android/project.properties | 1 | ||||
-rw-r--r-- | android/src/com/mapswithme/maps/MWMActivity.java | 7 | ||||
-rw-r--r-- | android/src/com/mapswithme/maps/MWMApplication.java | 12 |
17 files changed, 455 insertions, 15 deletions
diff --git a/.gitignore b/.gitignore index f7e2d52c97..e10a6187be 100644 --- a/.gitignore +++ b/.gitignore @@ -91,6 +91,62 @@ android/res/drawable-mdpi/uk_northern_ireland.png android/res/drawable-mdpi/uk_scotland.png android/res/drawable-mdpi/uk_wales.png +# android MapsWithMeLite +android/MapsWithMeLite/bin +android/MapsWithMeLite/gen +android/MapsWithMeLite/libs +android/MapsWithMeLite/obj +android/MapsWithMeLite/.settings +android/MapsWithMeLite/.classpath +android/MapsWithMeLite/.cproject +android/MapsWithMeLite/.project +android/MapsWithMeLite/assets +android/MapsWithMeLite/local.properties +android/MapsWithMeLite/ant.properties +# local android scripts, such as debugger helper scrips +android/MapsWithMeLite/local +# ignore flags symlinks +android/MapsWithMeLite/res/drawable-xhdpi/??.png +android/MapsWithMeLite/res/drawable-xhdpi/do_hack.png +android/MapsWithMeLite/res/drawable-xhdpi/uk_england.png +android/MapsWithMeLite/res/drawable-xhdpi/uk_northern_ireland.png +android/MapsWithMeLite/res/drawable-xhdpi/uk_scotland.png +android/MapsWithMeLite/res/drawable-xhdpi/uk_wales.png +android/MapsWithMeLite/res/drawable-mdpi/??.png +android/MapsWithMeLite/res/drawable-mdpi/do_hack.png +android/MapsWithMeLite/res/drawable-mdpi/uk_england.png +android/MapsWithMeLite/res/drawable-mdpi/uk_northern_ireland.png +android/MapsWithMeLite/res/drawable-mdpi/uk_scotland.png +android/MapsWithMeLite/res/drawable-mdpi/uk_wales.png + +# android MapsWithMePro +android/MapsWithMePro/bin +android/MapsWithMePro/gen +android/MapsWithMePro/libs +android/MapsWithMePro/obj +android/MapsWithMePro/.settings +android/MapsWithMePro/.classpath +android/MapsWithMePro/.cproject +android/MapsWithMePro/.project +android/MapsWithMePro/assets +android/MapsWithMePro/local.properties +android/MapsWithMePro/ant.properties +# local android scripts, such as debugger helper scrips +android/MapsWithMePro/local +# ignore flags symlinks +android/MapsWithMePro/res/drawable-xhdpi/??.png +android/MapsWithMePro/res/drawable-xhdpi/do_hack.png +android/MapsWithMePro/res/drawable-xhdpi/uk_england.png +android/MapsWithMePro/res/drawable-xhdpi/uk_northern_ireland.png +android/MapsWithMePro/res/drawable-xhdpi/uk_scotland.png +android/MapsWithMePro/res/drawable-xhdpi/uk_wales.png +android/MapsWithMePro/res/drawable-mdpi/??.png +android/MapsWithMePro/res/drawable-mdpi/do_hack.png +android/MapsWithMePro/res/drawable-mdpi/uk_england.png +android/MapsWithMePro/res/drawable-mdpi/uk_northern_ireland.png +android/MapsWithMePro/res/drawable-mdpi/uk_scotland.png +android/MapsWithMeLite/res/drawable-mdpi/uk_wales.png + # data data/intermediate_data diff --git a/android/AndroidManifest.xml b/android/AndroidManifest.xml index f85bb92e9d..d2b982e7fa 100644 --- a/android/AndroidManifest.xml +++ b/android/AndroidManifest.xml @@ -27,7 +27,7 @@ <application android:icon="@drawable/ic_launcher" android:label="@string/app_name" - android:name=".MWMApplication"> + android:name="com.mapswithme.maps.MWMApplication"> <activity android:name="com.mapswithme.maps.DownloadResourcesActivity" android:label="@string/app_name" diff --git a/android/MapsWithMeLite/AndroidManifest.xml b/android/MapsWithMeLite/AndroidManifest.xml new file mode 100644 index 0000000000..48b9e1555b --- /dev/null +++ b/android/MapsWithMeLite/AndroidManifest.xml @@ -0,0 +1,60 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.mapswithme.maps.lite" + android:versionCode="205" + android:versionName="2.0.5" + android:installLocation="preferExternal" + android:sharedUserId="com.mapswithme" + android:sharedUserLabel="@string/app_name"> + <uses-sdk android:minSdkVersion="7" android:targetSdkVersion="15"/> + <uses-feature android:glEsVersion="0x00020000" android:required="true" /> + <uses-feature android:required="true" android:name="android.hardware.touchscreen.multitouch" /> + <uses-feature android:required="false" android:name="android.hardware.wifi" /> + <uses-feature android:required="false" android:name="android.hardware.location" /> + <uses-feature android:required="false" android:name="android.hardware.location.network" /> + <uses-feature android:required="false" android:name="android.hardware.location.gps" /> + + <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/> + <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/> + <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/> + <uses-permission android:name="android.permission.INTERNET"/> + <uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/> + <uses-permission android:name="android.permission.CHANGE_WIFI_STATE"/> + <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/> + <uses-permission android:name="android.permission.WAKE_LOCK"/> + + <supports-screen android:largeScreens="true"/> + + <application android:icon="@drawable/ic_launcher" + android:label="@string/app_name" + android:name="com.mapswithme.maps.MWMApplication"> + + <activity android:name="com.mapswithme.maps.DownloadResourcesActivity" + android:label="@string/app_name" + android:screenOrientation="behind" + android:theme="@style/MWMNoTitle" + android:configChanges="orientation"> + <intent-filter> + <action android:name="android.intent.action.MAIN" /> + <category android:name="android.intent.category.LAUNCHER" /> + </intent-filter> + </activity> + <activity android:name="com.mapswithme.maps.MWMActivity" + android:label="@string/app_name" + android:screenOrientation="behind" + android:theme="@style/MWMNoTitle"> + </activity> + <activity android:name="com.mapswithme.maps.DownloadUI" + android:label="@string/download_maps" + android:screenOrientation="behind" + android:noHistory="true" + android:configChanges="orientation"> + </activity> + <activity android:name="com.mapswithme.maps.SearchActivity" + android:label="@string/search_map" + android:screenOrientation="behind" + android:noHistory="true" + android:configChanges="orientation"> + </activity> + </application> +</manifest> diff --git a/android/MapsWithMeLite/build.xml b/android/MapsWithMeLite/build.xml new file mode 100644 index 0000000000..e46820ab53 --- /dev/null +++ b/android/MapsWithMeLite/build.xml @@ -0,0 +1,92 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project name="MapsWithMeLite" default="help"> + + <!-- The local.properties file is created and updated by the 'android' tool. + It contains the path to the SDK. It should *NOT* be checked into + Version Control Systems. --> + <property file="local.properties" /> + + <!-- The ant.properties file can be created by you. It is only edited by the + 'android' tool to add properties to it. + This is the place to change some Ant specific build properties. + Here are some properties you may want to change/update: + + source.dir + The name of the source directory. Default is 'src'. + out.dir + The name of the output directory. Default is 'bin'. + + For other overridable properties, look at the beginning of the rules + files in the SDK, at tools/ant/build.xml + + Properties related to the SDK location or the project target should + be updated using the 'android' tool with the 'update' action. + + This file is an integral part of the build system for your + application and should be checked into Version Control Systems. + + --> + <property file="ant.properties" /> + + <!-- if sdk.dir was not set from one of the property file, then + get it from the ANDROID_HOME env var. + This must be done before we load project.properties since + the proguard config can use sdk.dir --> + <property environment="env" /> + <condition property="sdk.dir" value="${env.ANDROID_HOME}"> + <isset property="env.ANDROID_HOME" /> + </condition> + + <!-- The project.properties file is created and updated by the 'android' + tool, as well as ADT. + + This contains project specific properties such as project target, and library + dependencies. Lower level build properties are stored in ant.properties + (or in .classpath for Eclipse projects). + + This file is an integral part of the build system for your + application and should be checked into Version Control Systems. --> + <loadproperties srcFile="project.properties" /> + + <!-- quick check on sdk.dir --> + <fail + message="sdk.dir is missing. Make sure to generate local.properties using 'android update project' or to inject it through the ANDROID_HOME environment variable." + unless="sdk.dir" + /> + + <!-- + Import per project custom build rules if present at the root of the project. + This is the place to put custom intermediary targets such as: + -pre-build + -pre-compile + -post-compile (This is typically used for code obfuscation. + Compiled code location: ${out.classes.absolute.dir} + If this is not done in place, override ${out.dex.input.absolute.dir}) + -post-package + -post-build + -pre-clean + --> + <import file="custom_rules.xml" optional="true" /> + + <!-- Import the actual build file. + + To customize existing targets, there are two options: + - Customize only one target: + - copy/paste the target into this file, *before* the + <import> task. + - customize it to your needs. + - Customize the whole content of build.xml + - copy/paste the content of the rules files (minus the top node) + into this file, replacing the <import> task. + - customize to your needs. + + *********************** + ****** IMPORTANT ****** + *********************** + In all cases you must update the value of version-tag below to read 'custom' instead of an integer, + in order to avoid having your file be overridden by tools such as "android update project" + --> + <!-- version-tag: 1 --> + <import file="${sdk.dir}/tools/ant/build.xml" /> + +</project> diff --git a/android/MapsWithMeLite/proguard-project.txt b/android/MapsWithMeLite/proguard-project.txt new file mode 100644 index 0000000000..f2fe1559a2 --- /dev/null +++ b/android/MapsWithMeLite/proguard-project.txt @@ -0,0 +1,20 @@ +# To enable ProGuard in your project, edit project.properties +# to define the proguard.config property as described in that file. +# +# Add project specific ProGuard rules here. +# By default, the flags in this file are appended to flags specified +# in ${sdk.dir}/tools/proguard/proguard-android.txt +# You can edit the include path and order by changing the ProGuard +# include property in project.properties. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# Add any project specific keep options here: + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} diff --git a/android/MapsWithMeLite/project.properties b/android/MapsWithMeLite/project.properties new file mode 100644 index 0000000000..7bea6a3ccd --- /dev/null +++ b/android/MapsWithMeLite/project.properties @@ -0,0 +1,15 @@ +# This file is automatically generated by Android Tools. +# Do not modify this file -- YOUR CHANGES WILL BE ERASED! +# +# This file must be checked in Version Control Systems. +# +# To customize properties used by the Ant build system edit +# "ant.properties", and override values to adapt the script to your +# project structure. +# +# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home): +#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt + +# Project target. +target=android-8 +android.library.reference.1=.. diff --git a/android/MapsWithMeLite/res/values/strings.xml b/android/MapsWithMeLite/res/values/strings.xml new file mode 100644 index 0000000000..888194f8f6 --- /dev/null +++ b/android/MapsWithMeLite/res/values/strings.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<resources> + <string name="app_name">MapsWithMe</string> +</resources> diff --git a/android/MapsWithMeLite/res/values/styles.xml b/android/MapsWithMeLite/res/values/styles.xml new file mode 100644 index 0000000000..4dba0d0a4c --- /dev/null +++ b/android/MapsWithMeLite/res/values/styles.xml @@ -0,0 +1,5 @@ +<resources> + + <style name="AppTheme" parent="android:Theme.Light" /> + +</resources>
\ No newline at end of file diff --git a/android/MapsWithMePro/AndroidManifest.xml b/android/MapsWithMePro/AndroidManifest.xml new file mode 100644 index 0000000000..4a0b13a665 --- /dev/null +++ b/android/MapsWithMePro/AndroidManifest.xml @@ -0,0 +1,60 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android" + package="com.mapswithme.maps.pro" + android:versionCode="205" + android:versionName="2.0.5" + android:installLocation="preferExternal" + android:sharedUserId="com.mapswithme" + android:sharedUserLabel="@string/app_name"> + <uses-sdk android:minSdkVersion="7" android:targetSdkVersion="15"/> + <uses-feature android:glEsVersion="0x00020000" android:required="true" /> + <uses-feature android:required="true" android:name="android.hardware.touchscreen.multitouch" /> + <uses-feature android:required="false" android:name="android.hardware.wifi" /> + <uses-feature android:required="false" android:name="android.hardware.location" /> + <uses-feature android:required="false" android:name="android.hardware.location.network" /> + <uses-feature android:required="false" android:name="android.hardware.location.gps" /> + + <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/> + <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/> + <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/> + <uses-permission android:name="android.permission.INTERNET"/> + <uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/> + <uses-permission android:name="android.permission.CHANGE_WIFI_STATE"/> + <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/> + <uses-permission android:name="android.permission.WAKE_LOCK"/> + + <supports-screen android:largeScreens="true"/> + + <application android:icon="@drawable/ic_launcher" + android:label="@string/app_name" + android:name="com.mapswithme.maps.MWMApplication"> + + <activity android:name="com.mapswithme.maps.DownloadResourcesActivity" + android:label="@string/app_name" + android:screenOrientation="behind" + android:theme="@style/MWMNoTitle" + android:configChanges="orientation"> + <intent-filter> + <action android:name="android.intent.action.MAIN" /> + <category android:name="android.intent.category.LAUNCHER" /> + </intent-filter> + </activity> + <activity android:name="com.mapswithme.maps.MWMActivity" + android:label="@string/app_name" + android:screenOrientation="behind" + android:theme="@style/MWMNoTitle"> + </activity> + <activity android:name="com.mapswithme.maps.DownloadUI" + android:label="@string/download_maps" + android:screenOrientation="behind" + android:noHistory="true" + android:configChanges="orientation"> + </activity> + <activity android:name="com.mapswithme.maps.SearchActivity" + android:label="@string/search_map" + android:screenOrientation="behind" + android:noHistory="true" + android:configChanges="orientation"> + </activity> + </application> +</manifest> diff --git a/android/MapsWithMePro/build.xml b/android/MapsWithMePro/build.xml new file mode 100644 index 0000000000..163c3fb05b --- /dev/null +++ b/android/MapsWithMePro/build.xml @@ -0,0 +1,92 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project name="MapsWithMePro" default="help"> + + <!-- The local.properties file is created and updated by the 'android' tool. + It contains the path to the SDK. It should *NOT* be checked into + Version Control Systems. --> + <property file="local.properties" /> + + <!-- The ant.properties file can be created by you. It is only edited by the + 'android' tool to add properties to it. + This is the place to change some Ant specific build properties. + Here are some properties you may want to change/update: + + source.dir + The name of the source directory. Default is 'src'. + out.dir + The name of the output directory. Default is 'bin'. + + For other overridable properties, look at the beginning of the rules + files in the SDK, at tools/ant/build.xml + + Properties related to the SDK location or the project target should + be updated using the 'android' tool with the 'update' action. + + This file is an integral part of the build system for your + application and should be checked into Version Control Systems. + + --> + <property file="ant.properties" /> + + <!-- if sdk.dir was not set from one of the property file, then + get it from the ANDROID_HOME env var. + This must be done before we load project.properties since + the proguard config can use sdk.dir --> + <property environment="env" /> + <condition property="sdk.dir" value="${env.ANDROID_HOME}"> + <isset property="env.ANDROID_HOME" /> + </condition> + + <!-- The project.properties file is created and updated by the 'android' + tool, as well as ADT. + + This contains project specific properties such as project target, and library + dependencies. Lower level build properties are stored in ant.properties + (or in .classpath for Eclipse projects). + + This file is an integral part of the build system for your + application and should be checked into Version Control Systems. --> + <loadproperties srcFile="project.properties" /> + + <!-- quick check on sdk.dir --> + <fail + message="sdk.dir is missing. Make sure to generate local.properties using 'android update project' or to inject it through the ANDROID_HOME environment variable." + unless="sdk.dir" + /> + + <!-- + Import per project custom build rules if present at the root of the project. + This is the place to put custom intermediary targets such as: + -pre-build + -pre-compile + -post-compile (This is typically used for code obfuscation. + Compiled code location: ${out.classes.absolute.dir} + If this is not done in place, override ${out.dex.input.absolute.dir}) + -post-package + -post-build + -pre-clean + --> + <import file="custom_rules.xml" optional="true" /> + + <!-- Import the actual build file. + + To customize existing targets, there are two options: + - Customize only one target: + - copy/paste the target into this file, *before* the + <import> task. + - customize it to your needs. + - Customize the whole content of build.xml + - copy/paste the content of the rules files (minus the top node) + into this file, replacing the <import> task. + - customize to your needs. + + *********************** + ****** IMPORTANT ****** + *********************** + In all cases you must update the value of version-tag below to read 'custom' instead of an integer, + in order to avoid having your file be overridden by tools such as "android update project" + --> + <!-- version-tag: 1 --> + <import file="${sdk.dir}/tools/ant/build.xml" /> + +</project> diff --git a/android/MapsWithMePro/proguard-project.txt b/android/MapsWithMePro/proguard-project.txt new file mode 100644 index 0000000000..f2fe1559a2 --- /dev/null +++ b/android/MapsWithMePro/proguard-project.txt @@ -0,0 +1,20 @@ +# To enable ProGuard in your project, edit project.properties +# to define the proguard.config property as described in that file. +# +# Add project specific ProGuard rules here. +# By default, the flags in this file are appended to flags specified +# in ${sdk.dir}/tools/proguard/proguard-android.txt +# You can edit the include path and order by changing the ProGuard +# include property in project.properties. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# Add any project specific keep options here: + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} diff --git a/android/MapsWithMePro/project.properties b/android/MapsWithMePro/project.properties new file mode 100644 index 0000000000..7bea6a3ccd --- /dev/null +++ b/android/MapsWithMePro/project.properties @@ -0,0 +1,15 @@ +# This file is automatically generated by Android Tools. +# Do not modify this file -- YOUR CHANGES WILL BE ERASED! +# +# This file must be checked in Version Control Systems. +# +# To customize properties used by the Ant build system edit +# "ant.properties", and override values to adapt the script to your +# project structure. +# +# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home): +#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt + +# Project target. +target=android-8 +android.library.reference.1=.. diff --git a/android/MapsWithMePro/res/values/strings.xml b/android/MapsWithMePro/res/values/strings.xml new file mode 100644 index 0000000000..36b3de93ed --- /dev/null +++ b/android/MapsWithMePro/res/values/strings.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<resources> + <string name="app_name">MapsWithMe Pro</string> +</resources> diff --git a/android/MapsWithMePro/res/values/styles.xml b/android/MapsWithMePro/res/values/styles.xml new file mode 100644 index 0000000000..4dba0d0a4c --- /dev/null +++ b/android/MapsWithMePro/res/values/styles.xml @@ -0,0 +1,5 @@ +<resources> + + <style name="AppTheme" parent="android:Theme.Light" /> + +</resources>
\ No newline at end of file diff --git a/android/project.properties b/android/project.properties index ea89160e01..a2de03ee5b 100644 --- a/android/project.properties +++ b/android/project.properties @@ -9,3 +9,4 @@ # Project target. target=android-8 +android.library=true diff --git a/android/src/com/mapswithme/maps/MWMActivity.java b/android/src/com/mapswithme/maps/MWMActivity.java index dbe9a2cd54..090156ae0e 100644 --- a/android/src/com/mapswithme/maps/MWMActivity.java +++ b/android/src/com/mapswithme/maps/MWMActivity.java @@ -399,13 +399,12 @@ public class MWMActivity extends NvEventQueueActivity implements LocationService @Override public boolean onOptionsItemSelected(MenuItem item) { - switch (item.getItemId()) + if (item.getItemId() == R.id.menuitem_about_dialog) { - case R.id.menuitem_about_dialog: onAboutDialogClicked(); return true; - - default: + } else + { return super.onOptionsItemSelected(item); } } diff --git a/android/src/com/mapswithme/maps/MWMApplication.java b/android/src/com/mapswithme/maps/MWMApplication.java index 3d8ba3e651..814af84042 100644 --- a/android/src/com/mapswithme/maps/MWMApplication.java +++ b/android/src/com/mapswithme/maps/MWMApplication.java @@ -10,8 +10,6 @@ import com.mapswithme.maps.location.LocationService; public class MWMApplication extends android.app.Application { - public final static String PACKAGE_NAME = "com.mapswithme.maps"; - private LocationService mLocationService = null; @Override @@ -44,7 +42,7 @@ public class MWMApplication extends android.app.Application { try { - return getPackageManager().getApplicationInfo(PACKAGE_NAME, 0).sourceDir; + return getPackageManager().getApplicationInfo(getPackageName(), 0).sourceDir; } catch (NameNotFoundException e) { @@ -61,7 +59,7 @@ public class MWMApplication extends android.app.Application public String getExtAppDirectoryPath(String folder) { final String storagePath = Environment.getExternalStorageDirectory().getAbsolutePath(); - return storagePath.concat(String.format("/Android/data/%s/%s/", PACKAGE_NAME, folder)); + return storagePath.concat(String.format("/Android/data/%s/%s/", getPackageName(), folder)); } public boolean isProVersion() @@ -79,12 +77,6 @@ public class MWMApplication extends android.app.Application return getFilesDir().getAbsolutePath() + "/"; } - @Override - public String getPackageName() - { - return PACKAGE_NAME; - } - static { System.loadLibrary("mapswithme"); |