|
@@ -22,6 +22,7 @@ import android.view.KeyEvent;
|
|
import android.view.MotionEvent;
|
|
import android.view.MotionEvent;
|
|
import android.view.View;
|
|
import android.view.View;
|
|
import android.widget.RelativeLayout;
|
|
import android.widget.RelativeLayout;
|
|
|
|
+import com.util.LogUtil;
|
|
import kr.co.icontrols.wallpadoutmoderun.declare.Common;
|
|
import kr.co.icontrols.wallpadoutmoderun.declare.Common;
|
|
import kr.co.icontrols.wallpadoutmoderun.declare.ID;
|
|
import kr.co.icontrols.wallpadoutmoderun.declare.ID;
|
|
import kr.co.icontrols.wallpadoutmoderun.screen.OutModeSecurityRun;
|
|
import kr.co.icontrols.wallpadoutmoderun.screen.OutModeSecurityRun;
|
|
@@ -39,7 +40,7 @@ import kr.co.icontrols.wallpadsupport.WpadUtil;
|
|
* 를 여기서 처리한다.
|
|
* 를 여기서 처리한다.
|
|
*/
|
|
*/
|
|
public class MainActivity extends WpadActivity {
|
|
public class MainActivity extends WpadActivity {
|
|
- private final String TAG = "MainActivity";
|
|
|
|
|
|
+ static private final String TAG = "MainActivity";
|
|
|
|
|
|
private final boolean DEBUG_LOG_ON = true;
|
|
private final boolean DEBUG_LOG_ON = true;
|
|
private void DebugLogOutput(String s) { if(DEBUG_LOG_ON) Log.d(TAG, s); }
|
|
private void DebugLogOutput(String s) { if(DEBUG_LOG_ON) Log.d(TAG, s); }
|
|
@@ -129,7 +130,10 @@ public class MainActivity extends WpadActivity {
|
|
Log.d(TAG, "OperationMode = MODE_NOMAL");
|
|
Log.d(TAG, "OperationMode = MODE_NOMAL");
|
|
try {
|
|
try {
|
|
wpapi = new WallPadAPI(this);
|
|
wpapi = new WallPadAPI(this);
|
|
- } catch (Exception e) {
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ }
|
|
|
|
+ catch (Exception e) {
|
|
Log.e(TAG, "[ExceptionError] - new WallPadAPI : " + e);
|
|
Log.e(TAG, "[ExceptionError] - new WallPadAPI : " + e);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -228,8 +232,12 @@ public class MainActivity extends WpadActivity {
|
|
IntentFilter filter = new IntentFilter();
|
|
IntentFilter filter = new IntentFilter();
|
|
filter.addAction("Alarm Running");
|
|
filter.addAction("Alarm Running");
|
|
this.getContext().registerReceiver(m_EventAlarmBR, filter);
|
|
this.getContext().registerReceiver(m_EventAlarmBR, filter);
|
|
- } catch (Exception e) {
|
|
|
|
- e.printStackTrace();
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ }
|
|
|
|
+ catch (Exception e) {
|
|
|
|
+ //e.printStackTrace();
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, e);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
@@ -237,8 +245,12 @@ public class MainActivity extends WpadActivity {
|
|
try {
|
|
try {
|
|
am.cancel(pIntent);
|
|
am.cancel(pIntent);
|
|
this.getContext().unregisterReceiver(m_EventAlarmBR);
|
|
this.getContext().unregisterReceiver(m_EventAlarmBR);
|
|
- } catch (Exception e) {
|
|
|
|
- e.printStackTrace();
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ }
|
|
|
|
+ catch (Exception e) {
|
|
|
|
+ //e.printStackTrace();
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, e);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
@@ -315,8 +327,11 @@ public class MainActivity extends WpadActivity {
|
|
Log.d(TAG , "AutoIGALStatusReleaseSinario bSet: " + bSet);
|
|
Log.d(TAG , "AutoIGALStatusReleaseSinario bSet: " + bSet);
|
|
}
|
|
}
|
|
devset.closeDB();
|
|
devset.closeDB();
|
|
- } catch (Exception e) {
|
|
|
|
-
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ }
|
|
|
|
+ catch (Exception e) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, e);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
@@ -471,7 +486,10 @@ public class MainActivity extends WpadActivity {
|
|
OutModeReleaseLinkCtrl();
|
|
OutModeReleaseLinkCtrl();
|
|
finish();
|
|
finish();
|
|
}
|
|
}
|
|
- } catch (Exception e) {
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ }
|
|
|
|
+ catch (Exception e) {
|
|
Log.e(TAG, "[Exception Error] [onActivityResult] - data.getExtras().get");
|
|
Log.e(TAG, "[Exception Error] [onActivityResult] - data.getExtras().get");
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -532,7 +550,12 @@ public class MainActivity extends WpadActivity {
|
|
mCurrentScreenId = -1;
|
|
mCurrentScreenId = -1;
|
|
return false;
|
|
return false;
|
|
}
|
|
}
|
|
- } catch (Exception e) {
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ mCurrentScreenId = -1;
|
|
|
|
+ return false;
|
|
|
|
+ }
|
|
|
|
+ catch (Exception e) {
|
|
Log.e(TAG, "[ExceptionError] - setChangeScreen->Screen Create : " + e);
|
|
Log.e(TAG, "[ExceptionError] - setChangeScreen->Screen Create : " + e);
|
|
mCurrentScreenId = -1;
|
|
mCurrentScreenId = -1;
|
|
return false;
|
|
return false;
|
|
@@ -563,7 +586,10 @@ public class MainActivity extends WpadActivity {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
wdb.closeDB();
|
|
wdb.closeDB();
|
|
- } catch (Exception e) {
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ }
|
|
|
|
+ catch (Exception e) {
|
|
Log.d(TAG, "[Exception]-" + e.toString());
|
|
Log.d(TAG, "[Exception]-" + e.toString());
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -581,9 +607,14 @@ public class MainActivity extends WpadActivity {
|
|
intent.putExtra(Intent.EXTRA_KEY_EVENT, event);
|
|
intent.putExtra(Intent.EXTRA_KEY_EVENT, event);
|
|
intent.putExtra("keycode",code);
|
|
intent.putExtra("keycode",code);
|
|
getContext().sendBroadcast(intent);
|
|
getContext().sendBroadcast(intent);
|
|
- } catch (Exception e) {
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ return -100;
|
|
|
|
+ }
|
|
|
|
+ catch (Exception e) {
|
|
Log.e(TAG, "[setSendEventBR] - [Exception Error] code:" + code);
|
|
Log.e(TAG, "[setSendEventBR] - [Exception Error] code:" + code);
|
|
- e.printStackTrace();
|
|
|
|
|
|
+ //e.printStackTrace();
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, e);
|
|
return -100;
|
|
return -100;
|
|
}
|
|
}
|
|
return 0;
|
|
return 0;
|
|
@@ -598,9 +629,13 @@ public class MainActivity extends WpadActivity {
|
|
if (bEnable) TopManualBtn.setVisibility(View.VISIBLE);
|
|
if (bEnable) TopManualBtn.setVisibility(View.VISIBLE);
|
|
else TopManualBtn.setVisibility(View.INVISIBLE);
|
|
else TopManualBtn.setVisibility(View.INVISIBLE);
|
|
ViewRegistration(TopLayout, TopManualBtn, marginLeft, 0);
|
|
ViewRegistration(TopLayout, TopManualBtn, marginLeft, 0);
|
|
- } catch (Exception e) {
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ }
|
|
|
|
+ catch (Exception e) {
|
|
Log.e(TAG, "[Exception] setManualBtnVisible(boolean bEnable)");
|
|
Log.e(TAG, "[Exception] setManualBtnVisible(boolean bEnable)");
|
|
- e.printStackTrace();
|
|
|
|
|
|
+ //e.printStackTrace();
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, e);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
@@ -629,9 +664,13 @@ public class MainActivity extends WpadActivity {
|
|
Log.d(TAG, "[getManualUse] Not Use Manual [2]");
|
|
Log.d(TAG, "[getManualUse] Not Use Manual [2]");
|
|
return false;
|
|
return false;
|
|
}
|
|
}
|
|
- } catch (Exception ex) {
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ }
|
|
|
|
+ catch (Exception ex) {
|
|
Log.e(TAG, "[getManualUse] - Exception !!!");
|
|
Log.e(TAG, "[getManualUse] - Exception !!!");
|
|
- ex.printStackTrace();
|
|
|
|
|
|
+ //ex.printStackTrace();
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, ex);
|
|
}
|
|
}
|
|
return false;
|
|
return false;
|
|
}
|
|
}
|
|
@@ -670,9 +709,13 @@ public class MainActivity extends WpadActivity {
|
|
public static void resetCurrentManualScreenID() {
|
|
public static void resetCurrentManualScreenID() {
|
|
try {
|
|
try {
|
|
mCurrentManualScreenId = -1;
|
|
mCurrentManualScreenId = -1;
|
|
- } catch (Exception e) {
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ }
|
|
|
|
+ catch (Exception e) {
|
|
Log.e("MainActivity", "[Exception] resetCurrentManualScreenID()");
|
|
Log.e("MainActivity", "[Exception] resetCurrentManualScreenID()");
|
|
- e.printStackTrace();
|
|
|
|
|
|
+ //e.printStackTrace();
|
|
|
|
+ LogUtil.errorLogInfo("", "", e);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
@@ -683,9 +726,13 @@ public class MainActivity extends WpadActivity {
|
|
mCurrentManualScreenId = -1;
|
|
mCurrentManualScreenId = -1;
|
|
mManualActivity.finish();
|
|
mManualActivity.finish();
|
|
}
|
|
}
|
|
- } catch (Exception e) {
|
|
|
|
|
|
+ } catch (RuntimeException re) {
|
|
|
|
+ LogUtil.errorLogInfo("", TAG, re);
|
|
|
|
+ }
|
|
|
|
+ catch (Exception e) {
|
|
Log.e("MainActivity", "[Exception] FinishManualActivity()");
|
|
Log.e("MainActivity", "[Exception] FinishManualActivity()");
|
|
- e.printStackTrace();
|
|
|
|
|
|
+ //e.printStackTrace();
|
|
|
|
+ LogUtil.errorLogInfo("", "", e);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|