|
@@ -581,7 +581,12 @@ public class CallController extends CallManager implements SIPEventListener {
|
|
|
mCallInfo.setCallStatus(eCallType, CALLSTATUS.CALLING);
|
|
|
if (eCallOwner == CALLOWNER.MOBILE) {
|
|
|
LOG("[CallScenarioManager] CALLOWNER [" + eCallOwner + "]");
|
|
|
- if (MainActivity.mDataSender != null) MainActivity.mDataSender.start();
|
|
|
+
|
|
|
+ if(MainActivity.mDataSender !=null)
|
|
|
+ {
|
|
|
+ MainActivity.mDataSender.Init();
|
|
|
+ MainActivity.mDataSender.start();
|
|
|
+ }
|
|
|
}
|
|
|
mCallEventListener.onCallEvent(eCallOwner, CALLSTATUS.CALLING, eCallType, strRemoteIP, strRemoteSIPID, strMessage);
|
|
|
MainActivity.mSubPhoneController.sendACKFrontMonitoring(eCallOwner, eCallType);
|
|
@@ -595,7 +600,12 @@ public class CallController extends CallManager implements SIPEventListener {
|
|
|
else if (eCallType == CALLTYPE.RESIDENCE) {
|
|
|
if (eCallOwner == CALLOWNER.MOBILE) {
|
|
|
((MainActivity) mContext).changeMenuNScreen(ID.MENU.MENU_TALKRESIDENCE);
|
|
|
- if (MainActivity.mDataSender != null) MainActivity.mDataSender.start();
|
|
|
+
|
|
|
+ if(MainActivity.mDataSender !=null)
|
|
|
+ {
|
|
|
+ MainActivity.mDataSender.Init();
|
|
|
+ MainActivity.mDataSender.start();
|
|
|
+ }
|
|
|
|
|
|
if (mCallEventListener != null) {
|
|
|
mCallInfo.setCallStatus(eCallType, CALLSTATUS.HOMEVIEW);
|
|
@@ -702,7 +712,12 @@ public class CallController extends CallManager implements SIPEventListener {
|
|
|
RemoteCallMSG.REMOTE_CALLTYPE = eCallType;
|
|
|
RemoteCallMSG.REMOTE_CALLSTATUS = CALLSTATUS.CALLED;
|
|
|
MainActivity.mRemoteCallController.sendOpenRemoteCall(RemoteCallMSG.REMOTE_CALLTYPE, RemoteCallMSG.REMOTE_CALLSTATUS);
|
|
|
- if (MainActivity.mDataSender != null) MainActivity.mDataSender.start();
|
|
|
+
|
|
|
+ if(MainActivity.mDataSender !=null)
|
|
|
+ {
|
|
|
+ MainActivity.mDataSender.Init();
|
|
|
+ MainActivity.mDataSender.start();
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
else if (eCallType == CALLTYPE.LOBBY) {
|
|
@@ -712,7 +727,12 @@ public class CallController extends CallManager implements SIPEventListener {
|
|
|
RemoteCallMSG.REMOTE_CALLTYPE = eCallType;
|
|
|
RemoteCallMSG.REMOTE_CALLSTATUS = CALLSTATUS.CALLED;
|
|
|
MainActivity.mRemoteCallController.sendOpenRemoteCall(RemoteCallMSG.REMOTE_CALLTYPE, RemoteCallMSG.REMOTE_CALLSTATUS);
|
|
|
- if (MainActivity.mDataSender != null) MainActivity.mDataSender.start();
|
|
|
+
|
|
|
+ if(MainActivity.mDataSender !=null)
|
|
|
+ {
|
|
|
+ MainActivity.mDataSender.Init();
|
|
|
+ MainActivity.mDataSender.start();
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
else if (eCallType == CALLTYPE.GUARD) {
|
|
@@ -720,7 +740,12 @@ public class CallController extends CallManager implements SIPEventListener {
|
|
|
if (ConfigValues.bRemoteCall) {
|
|
|
RemoteCallMSG.REMOTE_CALLTYPE = eCallType;
|
|
|
MainActivity.mRemoteCallController.sendOpenRemoteCall(RemoteCallMSG.REMOTE_CALLTYPE, strRemoteSIPID, strRemoteIP);
|
|
|
- if (MainActivity.mDataSender != null) MainActivity.mDataSender.start();
|
|
|
+
|
|
|
+ if (MainActivity.mDataSender != null)
|
|
|
+ {
|
|
|
+ MainActivity.mDataSender.Init();
|
|
|
+ MainActivity.mDataSender.start();
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
else if (eCallType == CALLTYPE.RESIDENCE) {
|
|
@@ -856,7 +881,11 @@ public class CallController extends CallManager implements SIPEventListener {
|
|
|
if (RemoteCallMSG.REMOTE_CALLTYPE == CALLTYPE.LOBBY) {
|
|
|
if (mSIPInterface != null) mSIPInterface.videoSet(false, false, false);
|
|
|
}
|
|
|
- if (MainActivity.mDataSender != null) MainActivity.mDataSender.interrupt();
|
|
|
+
|
|
|
+ if (MainActivity.mDataSender != null) {
|
|
|
+ MainActivity.mDataSender.onClose();
|
|
|
+ MainActivity.mDataSender.interrupt();
|
|
|
+ }
|
|
|
RemoteCallMSG.REMOTE_CALLTYPE = CALLTYPE.NONE;
|
|
|
RemoteCallMSG.REMOTE_CALLSTATUS = CALLSTATUS.IDLE;
|
|
|
RemoteCallMSG.REMOTE_CALLOWNER = CALLOWNER.NONE;
|
|
@@ -2844,6 +2873,10 @@ public class CallController extends CallManager implements SIPEventListener {
|
|
|
} finally {
|
|
|
try {
|
|
|
mFileOutputStream.close();
|
|
|
+
|
|
|
+
|
|
|
+ if(bitmap!=null) bitmap.recycle();
|
|
|
+ bitmap = null;
|
|
|
} catch (IOException e) {
|
|
|
Log.e(TAG, "[IOException] saveBMPtoJPG(Bitmap bitmap, String strFilePath)");
|
|
|
|