Works on assistant for tablet
This commit is contained in:
parent
967ab77533
commit
f1d3a1bfac
10 changed files with 261 additions and 236 deletions
|
@ -23,7 +23,8 @@
|
||||||
android:paddingTop="10dp"
|
android:paddingTop="10dp"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"/>
|
android:layout_height="wrap_content"
|
||||||
|
android:id="@+id/message_create_account"/>
|
||||||
|
|
||||||
|
|
||||||
<TableLayout
|
<TableLayout
|
||||||
|
@ -133,7 +134,8 @@
|
||||||
android:id="@+id/sip_uri"
|
android:id="@+id/sip_uri"
|
||||||
style="@style/font9"
|
style="@style/font9"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"/>
|
android:layout_height="wrap_content"
|
||||||
|
android:visibility="visible"/>
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
@ -141,51 +143,57 @@
|
||||||
|
|
||||||
</TableRow>
|
</TableRow>
|
||||||
|
|
||||||
<TableRow
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="left"
|
|
||||||
android:layout_marginLeft="10dp"
|
|
||||||
android:layout_marginRight="10dp">
|
|
||||||
|
|
||||||
<CheckBox
|
|
||||||
android:id="@+id/use_username"
|
|
||||||
android:visibility="visible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/use_username_instead_or_phone_number"
|
|
||||||
android:checked="false" android:layout_column="1"/>
|
|
||||||
</TableRow>
|
|
||||||
|
|
||||||
<TableRow
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="left"
|
|
||||||
android:layout_marginLeft="10dp"
|
|
||||||
android:layout_marginRight="10dp">
|
|
||||||
|
|
||||||
<CheckBox
|
|
||||||
android:id="@+id/use_email"
|
|
||||||
android:visibility="visible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/use_email_for_validation" android:layout_column="1"
|
|
||||||
android:checked="false"/>
|
|
||||||
|
|
||||||
</TableRow>
|
|
||||||
|
|
||||||
<TableRow
|
<TableRow
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:layout_marginLeft="10dp"
|
android:layout_marginLeft="10dp"
|
||||||
android:layout_marginRight="10dp">
|
android:layout_marginRight="10dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/username_layout"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:visibility="gone"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_column="0">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/username_label"
|
||||||
|
android:text="@string/username"
|
||||||
|
style="@style/font13"
|
||||||
|
android:textAllCaps="true"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"/>
|
||||||
|
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/username"
|
||||||
|
android:background="@drawable/resizable_textfield"
|
||||||
|
android:textColor="@color/colorB"
|
||||||
|
android:inputType="text|textNoSuggestions"
|
||||||
|
android:contentDescription="@string/content_description_username_field"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:singleLine="true"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/username_error"
|
||||||
|
android:text="@string/error"
|
||||||
|
style="@style/font20"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:visibility="invisible"/>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/password_layout"
|
android:id="@+id/password_layout"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:visibility="visible"
|
android:visibility="gone"
|
||||||
android:paddingLeft="30dp"
|
android:paddingLeft="30dp"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:layout_height="wrap_content" android:layout_column="0">
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_column="1">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/password_label"
|
android:id="@+id/password_label"
|
||||||
|
@ -215,41 +223,8 @@
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:visibility="invisible"/>
|
android:visibility="invisible"/>
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/username_layout"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="0dp"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:layout_height="wrap_content" android:layout_column="1">
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/username_label"
|
|
||||||
android:text="@string/username"
|
|
||||||
style="@style/font13"
|
|
||||||
android:textAllCaps="true"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"/>
|
|
||||||
|
|
||||||
<EditText
|
|
||||||
android:id="@+id/username"
|
|
||||||
android:background="@drawable/resizable_textfield"
|
|
||||||
android:textColor="@color/colorB"
|
|
||||||
android:inputType="text|textNoSuggestions"
|
|
||||||
android:contentDescription="@string/content_description_username_field"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="40dp"
|
|
||||||
android:singleLine="true"/>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/username_error"
|
|
||||||
android:text="@string/error"
|
|
||||||
style="@style/font20"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:visibility="invisible"/>
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
</TableRow>
|
</TableRow>
|
||||||
|
|
||||||
<TableRow
|
<TableRow
|
||||||
|
@ -264,7 +239,6 @@
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:paddingLeft="30dp"
|
|
||||||
android:layout_height="wrap_content" android:layout_column="0">
|
android:layout_height="wrap_content" android:layout_column="0">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
@ -297,13 +271,15 @@
|
||||||
android:visibility="invisible"/>
|
android:visibility="invisible"/>
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/password_confirm_layout"
|
android:id="@+id/password_confirm_layout"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:layout_height="wrap_content" android:layout_column="1">
|
android:layout_height="wrap_content" android:layout_column="1"
|
||||||
|
android:paddingLeft="30dp">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/confirm_password_label"
|
android:id="@+id/confirm_password_label"
|
||||||
|
@ -336,6 +312,39 @@
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</TableRow>
|
</TableRow>
|
||||||
|
|
||||||
|
<TableRow
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="left"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginRight="10dp">
|
||||||
|
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/use_username"
|
||||||
|
android:visibility="visible"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/use_username_instead_or_phone_number"
|
||||||
|
android:checked="false"
|
||||||
|
android:layout_column="1"/>
|
||||||
|
</TableRow>
|
||||||
|
|
||||||
|
<TableRow
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="left"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginRight="10dp">
|
||||||
|
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/use_email"
|
||||||
|
android:visibility="visible"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/use_email_for_validation"
|
||||||
|
android:layout_column="1"
|
||||||
|
android:checked="false"/>
|
||||||
|
|
||||||
|
</TableRow>
|
||||||
</TableLayout>
|
</TableLayout>
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
|
|
|
@ -19,7 +19,8 @@
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:paddingTop="10dp"
|
android:paddingTop="10dp"
|
||||||
android:layout_gravity="center"/>
|
android:layout_gravity="center"
|
||||||
|
android:id="@+id/message_phone_number"/>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -110,25 +111,19 @@
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/phone_number_error_2"
|
||||||
|
android:text="@string/error"
|
||||||
|
style="@style/font20"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:visibility="invisible"/>
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
</TableRow>
|
</TableRow>
|
||||||
|
|
||||||
<TableRow
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:gravity="left"
|
|
||||||
android:layout_marginLeft="10dp"
|
|
||||||
android:layout_marginRight="10dp">
|
|
||||||
|
|
||||||
<CheckBox
|
|
||||||
android:id="@+id/use_username"
|
|
||||||
android:visibility="visible"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/login_with_username"/>
|
|
||||||
</TableRow>
|
|
||||||
|
|
||||||
<TableRow
|
<TableRow
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
|
@ -233,6 +228,20 @@
|
||||||
android:layout_height="0dp"/>
|
android:layout_height="0dp"/>
|
||||||
|
|
||||||
</TableRow>
|
</TableRow>
|
||||||
|
|
||||||
|
<TableRow
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="left"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginRight="10dp">
|
||||||
|
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/use_username"
|
||||||
|
android:visibility="visible"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/login_with_username"/>
|
||||||
|
</TableRow>
|
||||||
</TableLayout>
|
</TableLayout>
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
|
|
|
@ -24,7 +24,8 @@
|
||||||
android:paddingTop="10dp"
|
android:paddingTop="10dp"
|
||||||
android:gravity="center_horizontal"
|
android:gravity="center_horizontal"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"/>
|
android:layout_height="wrap_content"
|
||||||
|
android:id="@+id/message_create_account"/>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -121,21 +122,6 @@
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<CheckBox
|
|
||||||
android:id="@+id/use_username"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/use_username_instead_or_phone_number"/>
|
|
||||||
|
|
||||||
<CheckBox
|
|
||||||
android:id="@+id/use_email"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="@string/use_email_for_validation"/>
|
|
||||||
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/username_layout"
|
android:id="@+id/username_layout"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
|
@ -171,6 +157,49 @@
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/email_layout"
|
||||||
|
android:visibility="gone"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/email_label"
|
||||||
|
android:text="@string/email"
|
||||||
|
style="@style/font13"
|
||||||
|
android:textAllCaps="true"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"/>
|
||||||
|
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/email"
|
||||||
|
android:background="@drawable/resizable_textfield"
|
||||||
|
android:textColor="@color/colorB"
|
||||||
|
android:inputType="textEmailAddress"
|
||||||
|
android:contentDescription="@string/content_description_email_field"
|
||||||
|
android:textCursorDrawable="@null"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:paddingLeft="10dp"
|
||||||
|
android:paddingRight="10dp"
|
||||||
|
android:singleLine="true"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/email_error"
|
||||||
|
android:text="@string/error"
|
||||||
|
style="@style/font20"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:visibility="invisible"/>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/password_layout"
|
android:id="@+id/password_layout"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
|
@ -253,51 +282,22 @@
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/email_layout"
|
|
||||||
android:visibility="gone"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content">
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content">
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/email_label"
|
|
||||||
android:text="@string/email"
|
|
||||||
style="@style/font13"
|
|
||||||
android:textAllCaps="true"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"/>
|
|
||||||
|
|
||||||
<EditText
|
|
||||||
android:id="@+id/email"
|
|
||||||
android:background="@drawable/resizable_textfield"
|
|
||||||
android:textColor="@color/colorB"
|
|
||||||
android:inputType="textEmailAddress"
|
|
||||||
android:contentDescription="@string/content_description_email_field"
|
|
||||||
android:textCursorDrawable="@null"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="40dp"
|
|
||||||
android:paddingLeft="10dp"
|
|
||||||
android:paddingRight="10dp"
|
|
||||||
android:singleLine="true"/>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/email_error"
|
|
||||||
android:text="@string/error"
|
|
||||||
style="@style/font20"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:visibility="invisible"/>
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/use_username"
|
||||||
|
android:visibility="gone"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/use_username_instead_or_phone_number"/>
|
||||||
|
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/use_email"
|
||||||
|
android:visibility="gone"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/use_email_for_validation"/>
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/assistant_create"
|
android:id="@+id/assistant_create"
|
||||||
android:text="@string/assistant_create_account"
|
android:text="@string/assistant_create_account"
|
||||||
|
|
|
@ -96,7 +96,7 @@
|
||||||
android:textCursorDrawable="@null"
|
android:textCursorDrawable="@null"
|
||||||
android:inputType="textShortMessage|textMultiLine"
|
android:inputType="textShortMessage|textMultiLine"
|
||||||
android:contentDescription="@string/content_description_message"
|
android:contentDescription="@string/content_description_message"
|
||||||
android:maxLines="2"
|
android:maxLines="50"
|
||||||
android:padding="5dp"
|
android:padding="5dp"
|
||||||
android:layout_margin="5dp"
|
android:layout_margin="5dp"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
|
|
|
@ -1,34 +0,0 @@
|
||||||
#
|
|
||||||
#This file shall not contain path referencing package name, in order to be portable when app is renamed.
|
|
||||||
#Paths to resources must be set from LinphoneManager, after creating LinphoneCore.
|
|
||||||
|
|
||||||
[net]
|
|
||||||
mtu=1300
|
|
||||||
|
|
||||||
[sip]
|
|
||||||
guess_hostname=1
|
|
||||||
inc_timeout=15
|
|
||||||
register_only_when_network_is_up=1
|
|
||||||
auto_net_state_mon=0
|
|
||||||
auto_answer_replacing_calls=1
|
|
||||||
ping_with_options=0
|
|
||||||
|
|
||||||
[rtp]
|
|
||||||
audio_rtp_port=7076
|
|
||||||
video_rtp_port=9078
|
|
||||||
audio_jitt_comp=60
|
|
||||||
video_jitt_comp=60
|
|
||||||
nortp_timeout=30
|
|
||||||
disable_upnp=1
|
|
||||||
|
|
||||||
[sound]
|
|
||||||
playback_dev_id=
|
|
||||||
ringer_dev_id=
|
|
||||||
capture_dev_id=
|
|
||||||
dtmf_player_amp=0.1
|
|
||||||
|
|
||||||
#remove this property for any application that is not Linphone public version itself
|
|
||||||
ec_calibrator_cool_tones=1
|
|
||||||
|
|
||||||
[misc]
|
|
||||||
max_calls=10
|
|
|
@ -81,6 +81,7 @@
|
||||||
<string name="assistant_remote_provisioning">Fetch remote configuration</string>
|
<string name="assistant_remote_provisioning">Fetch remote configuration</string>
|
||||||
<string name="assistant_create_account_part_1">Please confirm your country code and enter your phone number</string>
|
<string name="assistant_create_account_part_1">Please confirm your country code and enter your phone number</string>
|
||||||
<string name="assistant_create_account_part_2">We have sent you a SMS with a validation code.\n\nTo complete your phone number verification, please enter the 4 digit code below:\n</string>
|
<string name="assistant_create_account_part_2">We have sent you a SMS with a validation code.\n\nTo complete your phone number verification, please enter the 4 digit code below:\n</string>
|
||||||
|
<string name="assistant_create_account_part_email">Please enter an username, email and password for your Linphone account</string>
|
||||||
<string name="assistant_display_name_optional">Display name (optional)</string>
|
<string name="assistant_display_name_optional">Display name (optional)</string>
|
||||||
<string name="assistant_linphone_account">Use your Linphone account</string>
|
<string name="assistant_linphone_account">Use your Linphone account</string>
|
||||||
<string name="assistant_generic_account">Use SIP account</string>
|
<string name="assistant_generic_account">Use SIP account</string>
|
||||||
|
|
|
@ -57,6 +57,7 @@ import org.linphone.mediastream.video.capture.hwconf.Hacks;
|
||||||
|
|
||||||
import android.app.Activity;
|
import android.app.Activity;
|
||||||
import android.app.AlertDialog;
|
import android.app.AlertDialog;
|
||||||
|
import android.app.Dialog;
|
||||||
import android.content.ContentResolver;
|
import android.content.ContentResolver;
|
||||||
import android.content.ContentValues;
|
import android.content.ContentValues;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
|
@ -619,17 +620,17 @@ public final class LinphoneUtils {
|
||||||
return ctxt.getString(R.string.invalid_display_name);
|
return ctxt.getString(R.string.invalid_display_name);
|
||||||
if (status.equals(LinphoneAccountCreator.Status.Failed))
|
if (status.equals(LinphoneAccountCreator.Status.Failed))
|
||||||
return ctxt.getString(R.string.request_failed);
|
return ctxt.getString(R.string.request_failed);
|
||||||
if (status.equals(LinphoneAccountCreator.Status.ErrorServeur))
|
if (status.equals(LinphoneAccountCreator.Status.ErrorServer))
|
||||||
return ctxt.getString(R.string.wizard_failed);
|
return ctxt.getString(R.string.wizard_failed);
|
||||||
if (status.equals(LinphoneAccountCreator.Status.TransportNotSupported))
|
if (status.equals(LinphoneAccountCreator.Status.TransportNotSupported))
|
||||||
return ctxt.getString(R.string.transport_unsupported);
|
return ctxt.getString(R.string.transport_unsupported);
|
||||||
if (status.equals(LinphoneAccountCreator.Status.AccountExist))
|
if (status.equals(LinphoneAccountCreator.Status.AccountExist)
|
||||||
|
|| status.equals(LinphoneAccountCreator.Status.AccountExistWithAlias))
|
||||||
return ctxt.getString(R.string.account_already_exist);
|
return ctxt.getString(R.string.account_already_exist);
|
||||||
if (status.equals(LinphoneAccountCreator.Status.CountryCodeInvalid))
|
if (status.equals(LinphoneAccountCreator.Status.CountryCodeInvalid))
|
||||||
return ctxt.getString(R.string.country_code_invalid);
|
return ctxt.getString(R.string.country_code_invalid);
|
||||||
if (status.equals(LinphoneAccountCreator.Status.PhoneNumberUsedAccount)
|
if (status.equals(LinphoneAccountCreator.Status.PhoneNumberUsedAccount)
|
||||||
|| status.equals(LinphoneAccountCreator.Status.PhoneNumberUsedAlias)
|
|| status.equals(LinphoneAccountCreator.Status.PhoneNumberUsedAlias))
|
||||||
|| status.equals(LinphoneAccountCreator.Status.AccountExistWithAlias))
|
|
||||||
return ctxt.getString(R.string.assistant_phone_number_unavailable);
|
return ctxt.getString(R.string.assistant_phone_number_unavailable);
|
||||||
if (status.equals(LinphoneAccountCreator.Status.AccountNotExist))
|
if (status.equals(LinphoneAccountCreator.Status.AccountNotExist))
|
||||||
return ctxt.getString(R.string.assistant_error_bad_credentials);
|
return ctxt.getString(R.string.assistant_error_bad_credentials);
|
||||||
|
|
|
@ -22,6 +22,7 @@ import java.util.Locale;
|
||||||
import java.util.regex.Matcher;
|
import java.util.regex.Matcher;
|
||||||
import java.util.regex.Pattern;
|
import java.util.regex.Pattern;
|
||||||
|
|
||||||
|
import org.linphone.LinphoneActivity;
|
||||||
import org.linphone.LinphoneManager;
|
import org.linphone.LinphoneManager;
|
||||||
import org.linphone.LinphonePreferences;
|
import org.linphone.LinphonePreferences;
|
||||||
import org.linphone.LinphoneUtils;
|
import org.linphone.LinphoneUtils;
|
||||||
|
@ -31,6 +32,7 @@ import org.linphone.core.LinphoneAccountCreator.LinphoneAccountCreatorListener;
|
||||||
import org.linphone.core.LinphoneAccountCreator.Status;
|
import org.linphone.core.LinphoneAccountCreator.Status;
|
||||||
import org.linphone.core.LinphoneCoreFactory;
|
import org.linphone.core.LinphoneCoreFactory;
|
||||||
import org.linphone.core.LinphoneProxyConfig;
|
import org.linphone.core.LinphoneProxyConfig;
|
||||||
|
import org.w3c.dom.Text;
|
||||||
|
|
||||||
import android.accounts.Account;
|
import android.accounts.Account;
|
||||||
import android.accounts.AccountManager;
|
import android.accounts.AccountManager;
|
||||||
|
@ -63,7 +65,7 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
private EditText phoneNumberEdit, usernameEdit, passwordEdit, passwordConfirmEdit
|
private EditText phoneNumberEdit, usernameEdit, passwordEdit, passwordConfirmEdit
|
||||||
, emailEdit, dialCode;
|
, emailEdit, dialCode;
|
||||||
private TextView phoneNumberError, passwordError, passwordConfirmError
|
private TextView phoneNumberError, passwordError, passwordConfirmError
|
||||||
, emailError, assisstantTitle, sipUri, skip;
|
, emailError, assisstantTitle, sipUri, skip, instruction;
|
||||||
private ImageView phoneNumberInfo;
|
private ImageView phoneNumberInfo;
|
||||||
|
|
||||||
private boolean passwordOk = false;
|
private boolean passwordOk = false;
|
||||||
|
@ -88,6 +90,8 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
accountCreator.setDomain(getResources().getString(R.string.default_domain));
|
accountCreator.setDomain(getResources().getString(R.string.default_domain));
|
||||||
accountCreator.setListener(this);
|
accountCreator.setListener(this);
|
||||||
|
|
||||||
|
instruction = (TextView) view.findViewById(R.id.message_create_account);
|
||||||
|
|
||||||
createAccount = (Button) view.findViewById(R.id.assistant_create);
|
createAccount = (Button) view.findViewById(R.id.assistant_create);
|
||||||
|
|
||||||
phoneNumberLayout = (LinearLayout) view.findViewById(R.id.phone_number_layout);
|
phoneNumberLayout = (LinearLayout) view.findViewById(R.id.phone_number_layout);
|
||||||
|
@ -243,9 +247,6 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
if (buttonView.getId() == R.id.use_username) {
|
if (buttonView.getId() == R.id.use_username) {
|
||||||
if (isChecked) {
|
if (isChecked) {
|
||||||
usernameLayout.setVisibility(View.VISIBLE);
|
usernameLayout.setVisibility(View.VISIBLE);
|
||||||
if (getResources().getBoolean(R.bool.isTablet)) {
|
|
||||||
passwordLayout.setVisibility(View.INVISIBLE);
|
|
||||||
}
|
|
||||||
onTextChanged2();
|
onTextChanged2();
|
||||||
} else {
|
} else {
|
||||||
usernameLayout.setVisibility(View.GONE);
|
usernameLayout.setVisibility(View.GONE);
|
||||||
|
@ -254,19 +255,33 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
}
|
}
|
||||||
} else if (buttonView.getId() == R.id.use_email) {
|
} else if (buttonView.getId() == R.id.use_email) {
|
||||||
if (isChecked) {
|
if (isChecked) {
|
||||||
|
dialCode.setBackgroundResource(R.drawable.resizable_textfield);
|
||||||
|
phoneNumberEdit.setBackgroundResource(R.drawable.resizable_textfield);
|
||||||
|
useUsername.setEnabled(false);
|
||||||
|
dialCode.setEnabled(false);
|
||||||
|
selectCountry.setEnabled(false);
|
||||||
|
phoneNumberEdit.setEnabled(false);
|
||||||
emailLayout.setVisibility(View.VISIBLE);
|
emailLayout.setVisibility(View.VISIBLE);
|
||||||
passwordLayout.setVisibility(View.VISIBLE);
|
passwordLayout.setVisibility(View.VISIBLE);
|
||||||
passwordConfirmLayout.setVisibility(View.VISIBLE);
|
passwordConfirmLayout.setVisibility(View.VISIBLE);
|
||||||
usernameLayout.setVisibility(View.VISIBLE);
|
usernameLayout.setVisibility(View.VISIBLE);
|
||||||
|
useUsername.setVisibility(CheckBox.GONE);
|
||||||
|
phoneNumberLayout.setVisibility(LinearLayout.GONE);
|
||||||
|
instruction.setText(getString(R.string.assistant_create_account_part_email));
|
||||||
} else {
|
} else {
|
||||||
if (!useUsername.isChecked()) {
|
if (!useUsername.isChecked()) {
|
||||||
usernameLayout.setVisibility(View.GONE);
|
usernameLayout.setVisibility(View.GONE);
|
||||||
}
|
}
|
||||||
|
useUsername.setEnabled(true);
|
||||||
|
dialCode.setEnabled(true);
|
||||||
|
selectCountry.setEnabled(true);
|
||||||
|
phoneNumberEdit.setEnabled(true);
|
||||||
emailLayout.setVisibility(View.GONE);
|
emailLayout.setVisibility(View.GONE);
|
||||||
passwordLayout.setVisibility(View.GONE);
|
passwordLayout.setVisibility(View.GONE);
|
||||||
passwordConfirmLayout.setVisibility(View.GONE);
|
passwordConfirmLayout.setVisibility(View.GONE);
|
||||||
usernameLayout.setVisibility(View.GONE);
|
useUsername.setVisibility(CheckBox.VISIBLE);
|
||||||
|
phoneNumberLayout.setVisibility(LinearLayout.VISIBLE);
|
||||||
|
instruction.setText(getString(R.string.assistant_create_account_part_1));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -302,10 +317,17 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
|
|
||||||
case R.id.assistant_create: {
|
case R.id.assistant_create: {
|
||||||
createAccount.setEnabled(false);
|
createAccount.setEnabled(false);
|
||||||
if (linkAccount)
|
if (linkAccount) {
|
||||||
addAlias();
|
addAlias();
|
||||||
else
|
} else {
|
||||||
accountCreator.isAccountUsed();
|
if (getUsername().length() > 0) {
|
||||||
|
accountCreator.isAccountUsed();
|
||||||
|
} else {
|
||||||
|
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(Status.UsernameTooShort)
|
||||||
|
, AssistantActivity.instance());
|
||||||
|
createAccount.setEnabled(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -331,14 +353,14 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
accountCreator.linkPhoneNumberWithAccount();
|
accountCreator.linkPhoneNumberWithAccount();
|
||||||
} else {
|
} else {
|
||||||
createAccount.setEnabled(true);
|
createAccount.setEnabled(true);
|
||||||
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status), getContext());
|
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status), AssistantActivity.instance());
|
||||||
LinphoneUtils.displayError(isOk, phoneNumberError, LinphoneUtils.errorForStatus(status));
|
LinphoneUtils.displayError(isOk, phoneNumberError, LinphoneUtils.errorForStatus(status));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void createAccount() {
|
private void createAccount() {
|
||||||
if (getResources().getBoolean(R.bool.isTablet)
|
if ((getResources().getBoolean(R.bool.isTablet) || !getResources().getBoolean(R.bool.use_phone_number_validation))
|
||||||
|| !getResources().getBoolean(R.bool.use_phone_number_validation)) {
|
&& useEmail.isChecked()) {
|
||||||
Status emailStatus;
|
Status emailStatus;
|
||||||
Status passwordStatus;
|
Status passwordStatus;
|
||||||
|
|
||||||
|
@ -347,10 +369,12 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
|
|
||||||
if (!emailOk) {
|
if (!emailOk) {
|
||||||
LinphoneUtils.displayError(false, emailError, LinphoneUtils.errorForStatus(emailStatus));
|
LinphoneUtils.displayError(false, emailError, LinphoneUtils.errorForStatus(emailStatus));
|
||||||
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(emailStatus), getContext());
|
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(emailStatus)
|
||||||
|
, AssistantActivity.instance());
|
||||||
} else if (!passwordOk) {
|
} else if (!passwordOk) {
|
||||||
LinphoneUtils.displayError(false, passwordError, LinphoneUtils.errorForStatus(passwordStatus));
|
LinphoneUtils.displayError(false, passwordError, LinphoneUtils.errorForStatus(passwordStatus));
|
||||||
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(passwordStatus), getContext());
|
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(passwordStatus)
|
||||||
|
, AssistantActivity.instance());
|
||||||
} else if (!confirmPasswordOk) {
|
} else if (!confirmPasswordOk) {
|
||||||
String msg;
|
String msg;
|
||||||
if (passwordConfirmEdit.getText().toString().equals(passwordEdit.getText().toString())) {
|
if (passwordConfirmEdit.getText().toString().equals(passwordEdit.getText().toString())) {
|
||||||
|
@ -359,7 +383,7 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
msg = getString(R.string.wizard_passwords_unmatched);
|
msg = getString(R.string.wizard_passwords_unmatched);
|
||||||
}
|
}
|
||||||
LinphoneUtils.displayError(false, passwordError, msg);
|
LinphoneUtils.displayError(false, passwordError, msg);
|
||||||
LinphoneUtils.displayErrorAlert(msg, getContext());
|
LinphoneUtils.displayErrorAlert(msg, AssistantActivity.instance());
|
||||||
} else {
|
} else {
|
||||||
accountCreator.createAccount();
|
accountCreator.createAccount();
|
||||||
}
|
}
|
||||||
|
@ -381,15 +405,16 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
accountCreator.createAccount();
|
accountCreator.createAccount();
|
||||||
} else {
|
} else {
|
||||||
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(phoneStatus)
|
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(phoneStatus)
|
||||||
, getContext());
|
, AssistantActivity.instance());
|
||||||
LinphoneUtils.displayError(isOk, phoneNumberError
|
LinphoneUtils.displayError(isOk, phoneNumberError
|
||||||
, LinphoneUtils.errorForStatus(phoneStatus));
|
, LinphoneUtils.errorForStatus(phoneStatus));
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
LinphoneUtils.displayErrorAlert(getString(R.string.assistant_create_account_part_1)
|
LinphoneUtils.displayErrorAlert(getString(R.string.assistant_create_account_part_1)
|
||||||
, getContext());
|
, AssistantActivity.instance());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
createAccount.setEnabled(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
private LinphoneAccountCreator.Status getPhoneNumberStatus() {
|
private LinphoneAccountCreator.Status getPhoneNumberStatus() {
|
||||||
|
@ -400,41 +425,43 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
}
|
}
|
||||||
|
|
||||||
public void onTextChanged2() {
|
public void onTextChanged2() {
|
||||||
String msg;
|
String msg = "";
|
||||||
LinphoneAccountCreator.Status status = getPhoneNumberStatus();
|
|
||||||
boolean isOk = status.equals(LinphoneAccountCreator.Status.Ok);
|
|
||||||
LinphoneUtils.displayError(isOk, phoneNumberError, LinphoneUtils.errorForStatus(status));
|
|
||||||
|
|
||||||
accountCreator.setUsername(getUsername());
|
accountCreator.setUsername(getUsername());
|
||||||
|
|
||||||
// Username or phone number
|
if (!useEmail.isChecked() && getResources().getBoolean(R.bool.use_phone_number_validation)) {
|
||||||
if (getResources().getBoolean(R.bool.assistant_allow_username) && useUsername.isChecked()
|
LinphoneAccountCreator.Status status = getPhoneNumberStatus();
|
||||||
|| (getResources().getBoolean(R.bool.isTablet) || useEmail.isChecked()
|
boolean isOk = status.equals(LinphoneAccountCreator.Status.Ok);
|
||||||
|| !getResources().getBoolean(R.bool.use_phone_number_validation))) {
|
LinphoneUtils.displayError(isOk, phoneNumberError, LinphoneUtils.errorForStatus(status));
|
||||||
addressSip = getUsername();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!isOk) {
|
// Username or phone number
|
||||||
if (status.equals(LinphoneAccountCreator.Status.CountryCodeInvalid)) {
|
if (getResources().getBoolean(R.bool.assistant_allow_username) && useUsername.isChecked()) {
|
||||||
dialCode.setBackgroundResource(R.drawable.resizable_textfield_error);
|
addressSip = getUsername();
|
||||||
phoneNumberEdit.setBackgroundResource(R.drawable.resizable_textfield);
|
}
|
||||||
sipUri.setText("");
|
|
||||||
|
if (!isOk) {
|
||||||
|
if (status.equals(LinphoneAccountCreator.Status.CountryCodeInvalid)) {
|
||||||
|
dialCode.setBackgroundResource(R.drawable.resizable_textfield_error);
|
||||||
|
phoneNumberEdit.setBackgroundResource(R.drawable.resizable_textfield);
|
||||||
|
} else {
|
||||||
|
dialCode.setBackgroundResource(R.drawable.resizable_textfield);
|
||||||
|
phoneNumberEdit.setBackgroundResource(R.drawable.resizable_textfield_error);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
dialCode.setBackgroundResource(R.drawable.resizable_textfield);
|
dialCode.setBackgroundResource(R.drawable.resizable_textfield);
|
||||||
phoneNumberEdit.setBackgroundResource(R.drawable.resizable_textfield_error);
|
phoneNumberEdit.setBackgroundResource(R.drawable.resizable_textfield);
|
||||||
sipUri.setText("");
|
if (!linkAccount && addressSip.length() > 0) {
|
||||||
|
msg = getResources().getString(R.string.assistant_create_account_phone_number_address)
|
||||||
|
+ " <" + addressSip + "@" + getResources().getString(R.string.default_domain) + ">";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
dialCode.setBackgroundResource(R.drawable.resizable_textfield);
|
addressSip = getUsername();
|
||||||
phoneNumberEdit.setBackgroundResource(R.drawable.resizable_textfield);
|
if (addressSip.length() > 0) {
|
||||||
if (!linkAccount && addressSip.length() > 0) {
|
|
||||||
msg = getResources().getString(R.string.assistant_create_account_phone_number_address)
|
msg = getResources().getString(R.string.assistant_create_account_phone_number_address)
|
||||||
+ " <" + addressSip + "@" + getResources().getString(R.string.default_domain) + ">";
|
+ " <" + addressSip + "@" + getResources().getString(R.string.default_domain) + ">";
|
||||||
sipUri.setText(msg);
|
|
||||||
} else {
|
|
||||||
sipUri.setText("");
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
sipUri.setText(msg);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void addPhoneNumberHandler(final EditText field, final ImageView icon) {
|
private void addPhoneNumberHandler(final EditText field, final ImageView icon) {
|
||||||
|
@ -557,7 +584,13 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
@Override
|
@Override
|
||||||
public void onAccountCreatorIsAccountUsed(LinphoneAccountCreator accountCreator, final Status status) {
|
public void onAccountCreatorIsAccountUsed(LinphoneAccountCreator accountCreator, final Status status) {
|
||||||
if (status.equals(Status.AccountExist) || status.equals(Status.AccountExistWithAlias)) {
|
if (status.equals(Status.AccountExist) || status.equals(Status.AccountExistWithAlias)) {
|
||||||
accountCreator.isPhoneNumberUsed();
|
if (useEmail.isChecked()) {
|
||||||
|
createAccount.setEnabled(true);
|
||||||
|
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status)
|
||||||
|
, AssistantActivity.instance());
|
||||||
|
} else {
|
||||||
|
accountCreator.isPhoneNumberUsed();
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
createAccount();
|
createAccount();
|
||||||
}
|
}
|
||||||
|
@ -576,7 +609,8 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
createAccount.setEnabled(true);
|
createAccount.setEnabled(true);
|
||||||
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status), getContext());
|
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status)
|
||||||
|
, AssistantActivity.instance());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -613,7 +647,8 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
createAccount.setEnabled(true);
|
createAccount.setEnabled(true);
|
||||||
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status), getContext());
|
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status)
|
||||||
|
, AssistantActivity.instance());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -625,7 +660,8 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
} else {
|
} else {
|
||||||
createAccount.setEnabled(true);
|
createAccount.setEnabled(true);
|
||||||
//SMS error
|
//SMS error
|
||||||
LinphoneUtils.displayErrorAlert(getString(R.string.request_failed), getContext());
|
LinphoneUtils.displayErrorAlert(getString(R.string.request_failed)
|
||||||
|
, AssistantActivity.instance());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -640,7 +676,8 @@ public class CreateAccountFragment extends Fragment implements CompoundButton.On
|
||||||
accountCreator.isAccountActivated();
|
accountCreator.isAccountActivated();
|
||||||
} else {
|
} else {
|
||||||
createAccount.setEnabled(true);
|
createAccount.setEnabled(true);
|
||||||
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status), getContext());
|
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status)
|
||||||
|
, AssistantActivity.instance());
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
accountCreator.isAccountActivated();
|
accountCreator.isAccountActivated();
|
||||||
|
|
|
@ -162,7 +162,7 @@ public class LinphoneLoginFragment extends Fragment implements CompoundButton.On
|
||||||
|
|
||||||
public void linphoneLogIn() {
|
public void linphoneLogIn() {
|
||||||
if (login.getText() == null || login.length() == 0 || password.getText() == null || password.length() == 0) {
|
if (login.getText() == null || login.length() == 0 || password.getText() == null || password.length() == 0) {
|
||||||
LinphoneUtils.displayErrorAlert(getString(R.string.first_launch_no_login_password), getContext());
|
LinphoneUtils.displayErrorAlert(getString(R.string.first_launch_no_login_password), AssistantActivity.instance());
|
||||||
apply.setEnabled(true);
|
apply.setEnabled(true);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -244,12 +244,14 @@ public class LinphoneLoginFragment extends Fragment implements CompoundButton.On
|
||||||
accountCreator.isPhoneNumberUsed();
|
accountCreator.isPhoneNumberUsed();
|
||||||
} else {
|
} else {
|
||||||
apply.setEnabled(true);
|
apply.setEnabled(true);
|
||||||
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status), getContext());
|
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status),
|
||||||
LinphoneUtils.displayError(isOk, phoneNumberError, LinphoneUtils.errorForStatus(status));
|
AssistantActivity.instance());
|
||||||
|
LinphoneUtils.displayError(isOk, phoneNumberError,
|
||||||
|
LinphoneUtils.errorForStatus(status));
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
apply.setEnabled(true);
|
apply.setEnabled(true);
|
||||||
LinphoneUtils.displayErrorAlert(getString(R.string.assistant_create_account_part_1), getContext());
|
LinphoneUtils.displayErrorAlert(getString(R.string.assistant_create_account_part_1), AssistantActivity.instance());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -347,7 +349,7 @@ public class LinphoneLoginFragment extends Fragment implements CompoundButton.On
|
||||||
accountCreator.recoverPhoneAccount();
|
accountCreator.recoverPhoneAccount();
|
||||||
} else {
|
} else {
|
||||||
apply.setEnabled(true);
|
apply.setEnabled(true);
|
||||||
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status), getContext());
|
LinphoneUtils.displayErrorAlert(LinphoneUtils.errorForStatus(status), AssistantActivity.instance());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 565f83f13d731e5ed90fe1a466c5f21a55eb44ce
|
Subproject commit 43b61677f39580147ae622ba7716f6b9731580be
|
Loading…
Reference in a new issue