From b8c083daeddb5c295728af65d82db8e42fdcd802 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Fri, 19 Feb 2016 11:11:22 +0100 Subject: [PATCH 001/131] fix test --- .../src/org/linphone/tester/WrapperTester.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/liblinphone_tester/src/org/linphone/tester/WrapperTester.java b/liblinphone_tester/src/org/linphone/tester/WrapperTester.java index 7635a67ba..0ecfb5c30 100644 --- a/liblinphone_tester/src/org/linphone/tester/WrapperTester.java +++ b/liblinphone_tester/src/org/linphone/tester/WrapperTester.java @@ -7,6 +7,7 @@ import org.linphone.core.LinphoneCoreListenerBase; import org.linphone.core.LinphoneFriend; import org.linphone.core.PayloadType; import org.linphone.mediastream.MediastreamerAndroidContext; +import org.linphone.mediastream.Factory; import android.test.AndroidTestCase; import junit.framework.Assert; @@ -87,9 +88,11 @@ public class WrapperTester extends AndroidTestCase { friend.setRefKey(key); Assert.assertEquals(friend.getRefKey(),key); - MediastreamerAndroidContext.enableFilterFromName("MSUlawEnc", false); - Assert.assertFalse(MediastreamerAndroidContext.filterFromNameEnabled("MSUlawEnc")); - MediastreamerAndroidContext.enableFilterFromName("MSUlawEnc", true); + //Test filter enablement + Factory factory = mCore.getMSFactory(); + factory.enableFilterFromName("MSUlawEnc", false); + Assert.assertFalse(factory.filterFromNameEnabled("MSUlawEnc")); + factory.enableFilterFromName("MSUlawEnc", true); } @Override From 93aacfb66860b795b5a9e8b5279604bd924e3058 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Fri, 19 Feb 2016 11:49:46 +0100 Subject: [PATCH 002/131] update submodules --- submodules/bctoolbox | 2 +- submodules/belle-sip | 2 +- submodules/linphone | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/submodules/bctoolbox b/submodules/bctoolbox index 1f469d085..c9384ab7d 160000 --- a/submodules/bctoolbox +++ b/submodules/bctoolbox @@ -1 +1 @@ -Subproject commit 1f469d085dfd67dd05288ff7dc8af00201fab31c +Subproject commit c9384ab7d7eef23d62479e07fc2715362312dd36 diff --git a/submodules/belle-sip b/submodules/belle-sip index c130b4eba..2d03590cb 160000 --- a/submodules/belle-sip +++ b/submodules/belle-sip @@ -1 +1 @@ -Subproject commit c130b4eba162cdcc4c03838e5430867f8b418257 +Subproject commit 2d03590cb774328b3ab0db4968d5795e83040d3c diff --git a/submodules/linphone b/submodules/linphone index 1c06fe5f7..9f05b7aad 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 1c06fe5f7700bb5c94433004d4862ab9d0a94a03 +Subproject commit 9f05b7aadcbf7570cca28689d71f74d11a9d52ed From 0e3dd22b52325627a15b032631aac6e3d4836283 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Fri, 19 Feb 2016 12:33:44 +0100 Subject: [PATCH 003/131] update linphone submodule --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index 9f05b7aad..b961e494d 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 9f05b7aadcbf7570cca28689d71f74d11a9d52ed +Subproject commit b961e494dd2dc84c9d178a84c1d79605cdffbb4c From a772ab303e905e70c9642b3f09d5386551a353d3 Mon Sep 17 00:00:00 2001 From: Margaux Clerc Date: Mon, 22 Feb 2016 14:11:26 +0100 Subject: [PATCH 004/131] Add inprogress popup assistant registration in progress --- res/layout/progress_dialog.xml | 13 +++++++++++ .../linphone/assistant/AssistantActivity.java | 23 +++++++++++++++++++ 2 files changed, 36 insertions(+) create mode 100644 res/layout/progress_dialog.xml diff --git a/res/layout/progress_dialog.xml b/res/layout/progress_dialog.xml new file mode 100644 index 000000000..cde6ce898 --- /dev/null +++ b/res/layout/progress_dialog.xml @@ -0,0 +1,13 @@ + + + + + + \ No newline at end of file diff --git a/src/org/linphone/assistant/AssistantActivity.java b/src/org/linphone/assistant/AssistantActivity.java index ff01fd8a9..9bad3ac14 100644 --- a/src/org/linphone/assistant/AssistantActivity.java +++ b/src/org/linphone/assistant/AssistantActivity.java @@ -37,14 +37,19 @@ import android.app.AlertDialog; import android.app.Dialog; import android.app.Fragment; import android.app.FragmentTransaction; +import android.app.ProgressDialog; import android.content.Context; import android.content.DialogInterface; import android.content.pm.ActivityInfo; +import android.graphics.drawable.ColorDrawable; +import android.graphics.drawable.Drawable; import android.os.Bundle; import android.text.TextUtils; import android.view.View; import android.view.View.OnClickListener; +import android.view.Window; +import android.view.WindowManager; import android.view.inputmethod.InputMethodManager; import android.widget.ImageView; import android.widget.Toast; @@ -62,6 +67,7 @@ public class AssistantActivity extends Activity implements OnClickListener { private LinphoneCoreListenerBase mListener; private LinphoneAddress address; private StatusFragment status; + private ProgressDialog progress; private Dialog dialog; protected void onCreate(Bundle savedInstanceState) { @@ -93,14 +99,18 @@ public class AssistantActivity extends Activity implements OnClickListener { if(accountCreated && !newAccount){ if(address != null && address.asString().equals(cfg.getIdentity()) ) { if (state == RegistrationState.RegistrationOk) { + progress.dismiss(); if (LinphoneManager.getLc().getDefaultProxyConfig() != null) { launchEchoCancellerCalibration(true); } } else if (state == RegistrationState.RegistrationFailed) { + progress.dismiss(); if(dialog == null || !dialog.isShowing()) { dialog = createErrorDialog(cfg, smessage); dialog.show(); } + } else if(!(state == RegistrationState.RegistrationProgress)) { + progress.dismiss(); } } } @@ -385,12 +395,25 @@ public class AssistantActivity extends Activity implements OnClickListener { try { builder.saveNewAccount(); + displayRegistrationInProgressDialog(); accountCreated = true; } catch (LinphoneCoreException e) { e.printStackTrace(); } } + public void displayRegistrationInProgressDialog(){ + if(LinphoneManager.getLc().isNetworkReachable()) { + progress = ProgressDialog.show(this,null,null); + Drawable d = new ColorDrawable(getResources().getColor(R.color.colorE)); + d.setAlpha(200); + progress.getWindow().setLayout(WindowManager.LayoutParams.MATCH_PARENT, WindowManager.LayoutParams.MATCH_PARENT); + progress.getWindow().setBackgroundDrawable(d); + progress.setContentView(R.layout.progress_dialog); + progress.show(); + } + } + public void displayWizardConfirm(String username) { CreateAccountActivationFragment fragment = new CreateAccountActivationFragment(); From c7bc95e28a0d7c6fc3b8dce7d84f7aac94bfc1af Mon Sep 17 00:00:00 2001 From: Margaux Clerc Date: Mon, 22 Feb 2016 14:11:44 +0100 Subject: [PATCH 005/131] Fix ZRTP popup --- src/org/linphone/StatusFragment.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/org/linphone/StatusFragment.java b/src/org/linphone/StatusFragment.java index a0913c030..c2e3a9488 100644 --- a/src/org/linphone/StatusFragment.java +++ b/src/org/linphone/StatusFragment.java @@ -405,7 +405,7 @@ public class StatusFragment extends Fragment { TextView customText = (TextView) ZRTPdialog.findViewById(R.id.customText); String newText = getString(R.string.zrtp_dialog).replace("%s", call.getAuthenticationToken()); customText.setText(newText); - Button delete = (Button) ZRTPdialog.findViewById(R.id.delete); + Button delete = (Button) ZRTPdialog.findViewById(R.id.delete_button); delete.setText(R.string.accept); Button cancel = (Button) ZRTPdialog.findViewById(R.id.cancel); cancel.setText(R.string.deny); From bc57fde9c97a06ce329795a7d34c84bc4c794387 Mon Sep 17 00:00:00 2001 From: Margaux Clerc Date: Mon, 22 Feb 2016 14:19:06 +0100 Subject: [PATCH 006/131] Fix empty fragment for tablet version --- src/org/linphone/LinphoneActivity.java | 90 ++++++++++++++------------ 1 file changed, 50 insertions(+), 40 deletions(-) diff --git a/src/org/linphone/LinphoneActivity.java b/src/org/linphone/LinphoneActivity.java index d316da70a..d24b2f66a 100644 --- a/src/org/linphone/LinphoneActivity.java +++ b/src/org/linphone/LinphoneActivity.java @@ -109,7 +109,7 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta private ChatFragment chatFragment; private Fragment.SavedState dialerSavedState; private boolean newProxyConfig; - private boolean isAnimationDisabled = false, preferLinphoneContacts = false; + private boolean isAnimationDisabled = true, preferLinphoneContacts = false; private OrientationEventListener mOrientationHelper; private LinphoneCoreListenerBase mListener; private LinearLayout mTabBar; @@ -382,6 +382,9 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta case ABOUT: newFragment = new AboutFragment(); break; + case EMPTY: + newFragment = new EmptyFragment(); + break; case CHAT_LIST: newFragment = new ChatListFragment(); chatListFragment = newFragment; @@ -453,54 +456,62 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta LinearLayout ll = (LinearLayout) findViewById(R.id.fragmentContainer2); FragmentTransaction transaction = getFragmentManager().beginTransaction(); - if (newFragmentType.shouldAddItselfToTheRightOf(currentFragment)) { + + if(newFragmentType == FragmentsAvailable.EMPTY){ ll.setVisibility(View.VISIBLE); - - if(newFragmentType == FragmentsAvailable.CONTACT_EDITOR){ - transaction.addToBackStack(newFragmentType.toString()); - } transaction.replace(R.id.fragmentContainer2, newFragment); + transaction.commitAllowingStateLoss(); + getFragmentManager().executePendingTransactions(); } else { - if(newFragmentType == FragmentsAvailable.EMPTY) { + if (newFragmentType.shouldAddItselfToTheRightOf(currentFragment)) { ll.setVisibility(View.VISIBLE); - transaction.replace(R.id.fragmentContainer2, new EmptyFragment()); - } - if (newFragmentType == FragmentsAvailable.DIALER - || newFragmentType == FragmentsAvailable.ABOUT - || newFragmentType == FragmentsAvailable.SETTINGS - || newFragmentType == FragmentsAvailable.ACCOUNT_SETTINGS) { - ll.setVisibility(View.GONE); + if (newFragmentType == FragmentsAvailable.CONTACT_EDITOR) { + transaction.addToBackStack(newFragmentType.toString()); + } + transaction.replace(R.id.fragmentContainer2, newFragment); } else { - ll.setVisibility(View.VISIBLE); - transaction.replace(R.id.fragmentContainer2, new EmptyFragment()); - } + if (newFragmentType == FragmentsAvailable.EMPTY) { + ll.setVisibility(View.VISIBLE); + transaction.replace(R.id.fragmentContainer2, new EmptyFragment()); + } - if (!withoutAnimation && !isAnimationDisabled && currentFragment.shouldAnimate()) { - if (newFragmentType.isRightOf(currentFragment)) { - transaction.setCustomAnimations(R.anim.slide_in_right_to_left, R.anim.slide_out_right_to_left, R.anim.slide_in_left_to_right, R.anim.slide_out_left_to_right); + if (newFragmentType == FragmentsAvailable.DIALER + || newFragmentType == FragmentsAvailable.ABOUT + || newFragmentType == FragmentsAvailable.SETTINGS + || newFragmentType == FragmentsAvailable.ACCOUNT_SETTINGS) { + ll.setVisibility(View.GONE); } else { - transaction.setCustomAnimations(R.anim.slide_in_left_to_right, R.anim.slide_out_left_to_right, R.anim.slide_in_right_to_left, R.anim.slide_out_right_to_left); + ll.setVisibility(View.VISIBLE); + transaction.replace(R.id.fragmentContainer2, new EmptyFragment()); + } + + if (!withoutAnimation && !isAnimationDisabled && currentFragment.shouldAnimate()) { + if (newFragmentType.isRightOf(currentFragment)) { + transaction.setCustomAnimations(R.anim.slide_in_right_to_left, R.anim.slide_out_right_to_left, R.anim.slide_in_left_to_right, R.anim.slide_out_left_to_right); + } else { + transaction.setCustomAnimations(R.anim.slide_in_left_to_right, R.anim.slide_out_left_to_right, R.anim.slide_in_right_to_left, R.anim.slide_out_right_to_left); + } + } + transaction.replace(R.id.fragmentContainer, newFragment); + } + transaction.commitAllowingStateLoss(); + getFragmentManager().executePendingTransactions(); + + currentFragment = newFragmentType; + if (newFragmentType == FragmentsAvailable.DIALER + || newFragmentType == FragmentsAvailable.SETTINGS + || newFragmentType == FragmentsAvailable.CONTACTS_LIST + || newFragmentType == FragmentsAvailable.CHAT_LIST + || newFragmentType == FragmentsAvailable.HISTORY_LIST) { + try { + getFragmentManager().popBackStackImmediate(null, FragmentManager.POP_BACK_STACK_INCLUSIVE); + } catch (java.lang.IllegalStateException e) { + } } - transaction.replace(R.id.fragmentContainer, newFragment); + fragmentsHistory.add(currentFragment); } - transaction.commitAllowingStateLoss(); - getFragmentManager().executePendingTransactions(); - - currentFragment = newFragmentType; - if (newFragmentType == FragmentsAvailable.DIALER - || newFragmentType == FragmentsAvailable.SETTINGS - || newFragmentType == FragmentsAvailable.CONTACTS_LIST - || newFragmentType == FragmentsAvailable.CHAT_LIST - || newFragmentType == FragmentsAvailable.HISTORY_LIST) { - try { - getFragmentManager().popBackStackImmediate(null, FragmentManager.POP_BACK_STACK_INCLUSIVE); - } catch (java.lang.IllegalStateException e) { - - } - } - fragmentsHistory.add(currentFragment); } public void displayHistoryDetail(String sipUri, LinphoneCallLog log) { @@ -551,7 +562,7 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta } public void displayEmptyFragment(){ - changeCurrentFragment(FragmentsAvailable.HISTORY_LIST,new Bundle()); + changeCurrentFragment(FragmentsAvailable.EMPTY, new Bundle()); } @SuppressLint("SimpleDateFormat") @@ -1271,7 +1282,6 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta if (call.getCurrentParamsCopy().getVideoEnabled()) { //startVideoActivity(call); } else { - Log.w("outgoing call"); //startIncallActivity(call); } } From abb3be94213952eba66e602da92811f4bc91acec Mon Sep 17 00:00:00 2001 From: Margaux Clerc Date: Mon, 22 Feb 2016 15:18:58 +0100 Subject: [PATCH 007/131] Fix contact edition --- res/layout/contact_edit_row.xml | 2 +- src/org/linphone/ContactEditorFragment.java | 4 ++-- tests/src/org/linphone/test/CallsAudio.java | 2 +- tests/src/org/linphone/test/Contacts.java | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/res/layout/contact_edit_row.xml b/res/layout/contact_edit_row.xml index 6dc03cd3d..0fcd30a54 100644 --- a/res/layout/contact_edit_row.xml +++ b/res/layout/contact_edit_row.xml @@ -18,7 +18,7 @@ android:layout_toStartOf="@+id/delete"/> Date: Tue, 23 Feb 2016 16:45:19 +0100 Subject: [PATCH 008/131] submodules: update belle-sip and linphone --- submodules/belle-sip | 2 +- submodules/linphone | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/submodules/belle-sip b/submodules/belle-sip index 2d03590cb..0d7d95df4 160000 --- a/submodules/belle-sip +++ b/submodules/belle-sip @@ -1 +1 @@ -Subproject commit 2d03590cb774328b3ab0db4968d5795e83040d3c +Subproject commit 0d7d95df4806cf4751355f577437ab2da1e3ea72 diff --git a/submodules/linphone b/submodules/linphone index b961e494d..5f6547048 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit b961e494dd2dc84c9d178a84c1d79605cdffbb4c +Subproject commit 5f654704862b395b2274491306948e5a2f59f0e1 From 88e830b1c0802ed2c30a8bac33608844928047f0 Mon Sep 17 00:00:00 2001 From: Margaux Clerc Date: Tue, 23 Feb 2016 17:58:06 +0100 Subject: [PATCH 009/131] Update linphone --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index 5f6547048..723c62899 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 5f654704862b395b2274491306948e5a2f59f0e1 +Subproject commit 723c6289965cef0dc0a31d4cbab38f52c90e8a14 From 8067e8773c59b540a5693f3768aeaa727ca71167 Mon Sep 17 00:00:00 2001 From: Margaux Clerc Date: Tue, 23 Feb 2016 17:58:45 +0100 Subject: [PATCH 010/131] Fix chatlist row --- res/layout-land/chatlist_cell.xml | 10 +- res/layout-sw533dp-land/chatlist_cell.xml | 30 +++--- res/layout-sw533dp/chatlist_cell.xml | 112 ++++++++++++++++++++++ res/layout/chatlist_cell.xml | 4 +- 4 files changed, 133 insertions(+), 23 deletions(-) create mode 100644 res/layout-sw533dp/chatlist_cell.xml diff --git a/res/layout-land/chatlist_cell.xml b/res/layout-land/chatlist_cell.xml index 3b02ab4ff..0ffda4749 100644 --- a/res/layout-land/chatlist_cell.xml +++ b/res/layout-land/chatlist_cell.xml @@ -18,7 +18,7 @@ android:adjustViewBounds="true" android:layout_alignParentRight="true" android:layout_centerVertical="true" - android:visibility="invisible" /> + android:visibility="invisible" android:layout_alignParentTop="true"/> + android:layout_alignParentEnd="true" android:layout_alignParentTop="true"/> + android:visibility="invisible" android:layout_alignParentTop="true"/> + + - - diff --git a/res/layout-sw533dp/chatlist_cell.xml b/res/layout-sw533dp/chatlist_cell.xml new file mode 100644 index 000000000..692be473b --- /dev/null +++ b/res/layout-sw533dp/chatlist_cell.xml @@ -0,0 +1,112 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/res/layout/chatlist_cell.xml b/res/layout/chatlist_cell.xml index 054d8f639..0d9ee3e44 100644 --- a/res/layout/chatlist_cell.xml +++ b/res/layout/chatlist_cell.xml @@ -12,13 +12,12 @@ android:id="@+id/delete_chatroom" android:button="@drawable/checkbox" android:contentDescription="@string/content_description_delete" - android:paddingRight="5dp" android:layout_width="wrap_content" android:layout_height="wrap_content" android:adjustViewBounds="true" android:layout_alignParentRight="true" android:layout_centerVertical="true" - android:visibility="invisible" /> + android:visibility="invisible" android:layout_alignParentTop="true"/> From 56ec983bddff8519f941ef28123d8a5ce4499cec Mon Sep 17 00:00:00 2001 From: Margaux Clerc Date: Tue, 23 Feb 2016 17:59:16 +0100 Subject: [PATCH 011/131] Fix outgoingcall state changed --- src/org/linphone/CallOutgoingActivity.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/org/linphone/CallOutgoingActivity.java b/src/org/linphone/CallOutgoingActivity.java index 4d20037ff..508a9a7e9 100644 --- a/src/org/linphone/CallOutgoingActivity.java +++ b/src/org/linphone/CallOutgoingActivity.java @@ -97,7 +97,7 @@ public class CallOutgoingActivity extends Activity implements OnClickListener{ finish(); } - if (call == mCall && State.StreamsRunning == state){ + if (call == mCall && (State.StreamsRunning == state || State.Connected == state)){ if (!LinphoneActivity.isInstanciated()) { return; } From 89ff575cbbae7a09fba8489bde760418ce5ec2dd Mon Sep 17 00:00:00 2001 From: Margaux Clerc Date: Wed, 24 Feb 2016 11:14:31 +0100 Subject: [PATCH 012/131] Fix edit chat incoming bubble --- res/layout/chat_bubble_incoming.xml | 190 +++++++++++++++------------- res/layout/chat_bubble_outgoing.xml | 4 +- src/org/linphone/ChatFragment.java | 18 ++- 3 files changed, 114 insertions(+), 98 deletions(-) diff --git a/res/layout/chat_bubble_incoming.xml b/res/layout/chat_bubble_incoming.xml index b4cabbd4f..b442b3db2 100644 --- a/res/layout/chat_bubble_incoming.xml +++ b/res/layout/chat_bubble_incoming.xml @@ -1,100 +1,13 @@ - - - - - - - - - - - - - - - - - - - - - - - -