diff --git a/Examples/restcomm-olympus/.idea/codeStyleSettings.xml b/Examples/restcomm-olympus/.idea/codeStyleSettings.xml
new file mode 100644
index 00000000..2a0ff8e7
--- /dev/null
+++ b/Examples/restcomm-olympus/.idea/codeStyleSettings.xml
@@ -0,0 +1,226 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Examples/restcomm-olympus/.idea/misc.xml b/Examples/restcomm-olympus/.idea/misc.xml
index fbb68289..5d199810 100644
--- a/Examples/restcomm-olympus/.idea/misc.xml
+++ b/Examples/restcomm-olympus/.idea/misc.xml
@@ -37,7 +37,7 @@
-
+
diff --git a/Examples/restcomm-olympus/app/app.iml b/Examples/restcomm-olympus/app/app.iml
index 2d848d21..ee5e2512 100644
--- a/Examples/restcomm-olympus/app/app.iml
+++ b/Examples/restcomm-olympus/app/app.iml
@@ -62,13 +62,6 @@
-
-
-
-
-
-
-
@@ -76,6 +69,13 @@
+
+
+
+
+
+
+
diff --git a/Examples/restcomm-olympus/app/src/main/java/org/restcomm/android/olympus/AddUserDialogFragment.java b/Examples/restcomm-olympus/app/src/main/java/org/restcomm/android/olympus/AddUserDialogFragment.java
index d06265a0..9f347edb 100644
--- a/Examples/restcomm-olympus/app/src/main/java/org/restcomm/android/olympus/AddUserDialogFragment.java
+++ b/Examples/restcomm-olympus/app/src/main/java/org/restcomm/android/olympus/AddUserDialogFragment.java
@@ -26,83 +26,89 @@
import android.app.AlertDialog;
import android.app.Dialog;
import android.app.DialogFragment;
+import android.app.ProgressDialog;
import android.content.DialogInterface;
+import android.database.Cursor;
+import android.os.AsyncTask;
import android.os.Bundle;
+import android.provider.ContactsContract;
import android.support.v7.app.AppCompatDialogFragment;
import android.view.View;
+import android.widget.Button;
import android.widget.EditText;
+import java.util.ArrayList;
+import java.util.Map;
+
import static org.restcomm.android.olympus.ContactsController.CONTACT_KEY;
import static org.restcomm.android.olympus.ContactsController.CONTACT_VALUE;
public class AddUserDialogFragment extends AppCompatDialogFragment {
- public static final int DIALOG_TYPE_ADD_CONTACT = 0;
- public static final int DIALOG_TYPE_UPDATE_CONTACT = 1;
- EditText txtUsername;
- EditText txtSipuri;
- // Use this instance of the interface to deliver action events
- ContactDialogListener listener;
-
-
- /* The activity that creates an instance of this dialog fragment must
- * implement this interface in order to receive event callbacks.
- * Each method passes the DialogFragment in case the host needs to query it. */
- public interface ContactDialogListener {
- public void onDialogPositiveClick(int type, String username, String sipuri);
-
- public void onDialogNegativeClick();
- }
-
- /**
- * Create a new instance of MyDialogFragment, providing "num"
- * as an argument.
- */
- public static AddUserDialogFragment newInstance(int type, String username, String sipuri)
- {
- AddUserDialogFragment f = new AddUserDialogFragment();
-
- // Supply num input as an argument.
- Bundle args = new Bundle();
- args.putInt("type", type);
- if (type == DIALOG_TYPE_UPDATE_CONTACT) {
- args.putString(CONTACT_KEY, username);
- args.putString(CONTACT_VALUE, sipuri);
- }
- f.setArguments(args);
-
- return f;
- }
-
- // Override the Fragment.onAttach() method to instantiate the NoticeDialogListener
- @Override
- public void onAttach(Activity activity)
- {
- super.onAttach(activity);
- // Verify that the host activity implements the callback interface
- try {
- // Instantiate the NoticeDialogListener so we can send events to the host
- listener = (ContactDialogListener) activity;
- }
- catch (ClassCastException e) {
- // The activity doesn't implement the interface, throw exception
- throw new ClassCastException(activity.toString()
- + " must implement ContactDialogListener");
- }
- }
-
- @Override
- public void onDetach()
- {
- super.onDetach();
- listener = null;
- }
-
- @Override
- public void onCreate(Bundle savedInstanceState)
- {
- super.onCreate(savedInstanceState);
-
- }
+ public static final int DIALOG_TYPE_ADD_CONTACT = 0;
+ public static final int DIALOG_TYPE_UPDATE_CONTACT = 1;
+ EditText txtUsername;
+ EditText txtSipuri;
+ private ArrayList