Revision: 2317
http://sourceforge.net/p/swingme/code/2317
Author: yuranet
Date: 2014-07-21 17:11:00 +0000 (Mon, 21 Jul 2014)
Log Message:
-----------
can load maps from external dirs
Modified Paths:
--------------
AndroidME/src_Android/net/yura/android/AndroidMeApp.java
Modified: AndroidME/src_Android/net/yura/android/AndroidMeApp.java
===================================================================
--- AndroidME/src_Android/net/yura/android/AndroidMeApp.java 2014-07-05 20:11:46 UTC (rev 2316)
+++ AndroidME/src_Android/net/yura/android/AndroidMeApp.java 2014-07-21 17:11:00 UTC (rev 2317)
@@ -91,7 +91,7 @@
super.onCreate();
//#debug debug
- Logger.debug("\xA3EP AndroidMeApp onCreate");
+ Logger.debug("AndroidMeApp onCreate");
this.eventThread = Thread.currentThread();
try {
@@ -112,7 +112,7 @@
public void onTerminate() {
super.onTerminate();
//#debug debug
- Logger.debug("\xA3EP AndroidMeApp onTerminate");
+ Logger.debug("AndroidMeApp onTerminate");
try {
for (BroadcastReceiver receiver : broadcastReceiverList) {
@@ -266,6 +266,10 @@
System.setProperty("java.io.tmpdir", getCacheDir().toString() ); // OLD: java.io.tmpdir=/sdcard
System.setProperty("user.home", getFilesDir().toString() ); // OLD: user.home=
+ File externalStorageDirectory = Environment.getExternalStorageDirectory();
+ if (externalStorageDirectory != null && externalStorageDirectory.exists()) {
+ System.setProperty("ExternalStorageDirectory", externalStorageDirectory.toString() );
+ }
// Hardware properties.
// Returns the unique device ID, for example, the IMEI for GSM and the MEID or ESN for CDMA phones
@@ -353,7 +357,7 @@
}
//fall back to WIFI. Android documentation says:
- //It may be possible to retrieve a Mac address from a device\xD5s WiFi or Bluetooth hardware. We do not recommend using this as a unique identifier.
+ //It may be possible to retrieve a Mac address from a device's WiFi or Bluetooth hardware. We do not recommend using this as a unique identifier.
//To start with, not all devices have WiFi. Also, if the WiFi is not turned on, the hardware may not report the Mac address.
if(isValidId(uniqueId)) {
WifiManager wifiMan = (WifiManager) this.getSystemService(Context.WIFI_SERVICE);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|