mirror of
https://gitlab.linphone.org/BC/public/linphone-android.git
synced 2026-01-19 12:38:07 +00:00
Continue integration
This commit is contained in:
parent
28a322a139
commit
e889c23a22
22 changed files with 532 additions and 304 deletions
|
|
@ -1,15 +1,15 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:background="@color/colorG"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/colorB"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/top_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="70dp"
|
||||
android:background="@color/colorF"
|
||||
android:layout_height="50dp"
|
||||
android:background="@color/colorB"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<View
|
||||
|
|
@ -19,14 +19,14 @@
|
|||
|
||||
<TextView
|
||||
android:id="@+id/menu_name"
|
||||
style="@style/font22"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="0.4"
|
||||
android:gravity="center"
|
||||
android:padding="15dp"
|
||||
android:singleLine="true"
|
||||
android:text="@string/about"/>
|
||||
android:text="@string/about"
|
||||
android:textColor="#ffffff"
|
||||
android:textSize="20sp"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/cancel"
|
||||
|
|
@ -34,31 +34,31 @@
|
|||
android:layout_height="match_parent"
|
||||
android:layout_weight="0.2"
|
||||
android:contentDescription="@string/content_description_dialer_back"
|
||||
android:padding="15dp"
|
||||
android:src="@drawable/dialer_back"/>
|
||||
android:padding="10dp"
|
||||
android:src="@drawable/footer_contacts"/>
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:background="@color/colorE"
|
||||
android:orientation="horizontal"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_gravity="center">
|
||||
android:layout_height="258dp"
|
||||
android:layout_gravity="center"
|
||||
android:layout_weight="1"
|
||||
android:background="@color/colorB"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<LinearLayout
|
||||
android:orientation="vertical"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:layout_gravity="center">
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/linphone_logo"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="60dp"
|
||||
android:layout_gravity="center"/>
|
||||
android:layout_width="90dp"
|
||||
android:layout_height="90dp"
|
||||
android:layout_gravity="center"
|
||||
android:src="@drawable/logo_secure_phone_big"/>
|
||||
|
||||
<TextView
|
||||
style="@style/font14"
|
||||
|
|
@ -71,12 +71,12 @@
|
|||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:orientation="vertical"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:layout_gravity="center">
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/about_android_version"
|
||||
|
|
@ -98,11 +98,12 @@
|
|||
</LinearLayout>
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/logo_orange"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:layout_margin="30dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_alignParentRight="true" android:layout_gravity="right"/>
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_gravity="right"
|
||||
android:layout_margin="30dp"
|
||||
android:src="@drawable/logo_orange"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
|
|
|||
|
|
@ -9,8 +9,8 @@
|
|||
android:id="@+id/status"
|
||||
android:name="org.linphone.fragments.StatusFragment"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="35dp"
|
||||
tools:layout="@layout/status" />
|
||||
android:layout_height="30dp"
|
||||
tools:layout="@layout/status"/>
|
||||
|
||||
<android.support.v4.widget.DrawerLayout
|
||||
android:id="@+id/side_menu"
|
||||
|
|
@ -74,107 +74,144 @@
|
|||
|
||||
<LinearLayout
|
||||
android:id="@+id/footer"
|
||||
android:layout_width="60dp"
|
||||
android:layout_width="50dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/history"
|
||||
android:background="@drawable/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="0dp">
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@drawable/footer_button">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/history_image"
|
||||
android:src="@drawable/footer_history"
|
||||
android:contentDescription="@string/content_description_history"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerInParent="true"
|
||||
android:contentDescription="@string/content_description_history"
|
||||
android:padding="15dp"
|
||||
android:layout_centerInParent="true"/>
|
||||
android:src="@drawable/footer_history"/>
|
||||
|
||||
<View
|
||||
android:id="@+id/history_select"
|
||||
android:background="@color/colorA"
|
||||
android:layout_width="5dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:background="@color/colorA"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/missed_calls"
|
||||
android:background="@drawable/history_chat_indicator"
|
||||
style="@style/font18"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:gravity="center"
|
||||
android:visibility="gone"
|
||||
android:layout_marginTop="15dp"
|
||||
android:layout_marginRight="5dp"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignParentEnd="true"/>
|
||||
android:layout_marginRight="5dp"
|
||||
android:layout_marginTop="15dp"
|
||||
android:background="@drawable/history_chat_indicator"
|
||||
android:gravity="center"
|
||||
android:visibility="gone"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/contacts"
|
||||
android:src="@drawable/footer_contacts"
|
||||
android:background="@drawable/footer_button"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="15dp"
|
||||
android:layout_centerInParent="true"/>
|
||||
<RelativeLayout
|
||||
android:id="@+id/contact_footer"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@drawable/footer_button">
|
||||
|
||||
<View
|
||||
android:id="@+id/contacts_select"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="3dp"
|
||||
android:layout_alignParentTop="true"
|
||||
android:background="@color/colorB"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/contacts"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_centerInParent="true"
|
||||
android:layout_margin="15dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@drawable/footer_button"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:src="@drawable/footer_contacts"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dialer"
|
||||
android:src="@drawable/footer_dialer"
|
||||
android:background="@drawable/footer_button"
|
||||
android:contentDescription="@string/content_description_dialer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="15dp"
|
||||
android:layout_centerInParent="true"/>
|
||||
<RelativeLayout
|
||||
android:id="@+id/dialer_footer"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@drawable/footer_button">
|
||||
|
||||
<View
|
||||
android:id="@+id/dialer_select"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="3dp"
|
||||
android:layout_alignParentTop="true"
|
||||
android:background="@color/colorB"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dialer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_centerInParent="true"
|
||||
android:layout_margin="15dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@drawable/footer_button"
|
||||
android:contentDescription="@string/content_description_dialer"
|
||||
android:src="@drawable/footer_dialer"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/chat"
|
||||
android:background="@drawable/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="0dp">
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@drawable/footer_button">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/chat_image"
|
||||
android:src="@drawable/footer_chat"
|
||||
android:contentDescription="@string/content_description_chat_button"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerInParent="true"
|
||||
android:contentDescription="@string/content_description_chat_button"
|
||||
android:padding="15dp"
|
||||
android:layout_centerInParent="true" />
|
||||
android:src="@drawable/footer_chat"/>
|
||||
|
||||
<View
|
||||
android:id="@+id/chat_select"
|
||||
android:background="@color/colorA"
|
||||
android:visibility="gone"
|
||||
android:layout_width="5dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentLeft="true"/>
|
||||
android:layout_alignParentLeft="true"
|
||||
android:background="@color/colorA"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/missed_chats"
|
||||
android:background="@drawable/history_chat_indicator"
|
||||
style="@style/font18"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:gravity="center"
|
||||
android:visibility="gone"
|
||||
android:layout_marginTop="15dp"
|
||||
android:layout_marginRight="5dp"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignParentEnd="true"/>
|
||||
android:layout_marginRight="5dp"
|
||||
android:layout_marginTop="15dp"
|
||||
android:background="@drawable/history_chat_indicator"
|
||||
android:gravity="center"
|
||||
android:visibility="gone"/>
|
||||
|
||||
</RelativeLayout>
|
||||
</LinearLayout>
|
||||
|
|
|
|||
|
|
@ -1,57 +1,60 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:background="@color/colorD"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/colorD"
|
||||
>
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/dialer_background"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="300dp"
|
||||
android:layout_centerVertical="true"/>
|
||||
android:layout_alignParentStart="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginStart="235dp"
|
||||
android:src="@drawable/linphone_logo"/>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/dialer"
|
||||
android:background="@color/colorH"
|
||||
android:layout_marginRight="50dp"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_width="300dp"
|
||||
android:layout_height="460dp">
|
||||
android:layout_height="460dp"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginRight="50dp"
|
||||
android:background="@color/colorH">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/address_bar"
|
||||
android:background="@color/colorF"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="60dp"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:layout_alignParentTop="true">
|
||||
android:background="@color/colorF">
|
||||
|
||||
<org.linphone.ui.EraseButton
|
||||
android:id="@+id/erase"
|
||||
android:src="@drawable/backspace"
|
||||
android:contentDescription="@string/content_description_backspace"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_marginRight="10dp"
|
||||
android:layout_marginLeft="10dp" />
|
||||
android:contentDescription="@string/content_description_backspace"
|
||||
android:src="@drawable/backspace"/>
|
||||
|
||||
<org.linphone.ui.AddressText
|
||||
android:id="@+id/address"
|
||||
android:background="@color/colorF"
|
||||
android:textColorHint="@color/colorE"
|
||||
style="@style/font5"
|
||||
android:ellipsize="start"
|
||||
android:inputType="textEmailAddress"
|
||||
android:hint="@string/address_bar_hint"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_toLeftOf="@id/erase"
|
||||
android:background="@color/colorF"
|
||||
android:ellipsize="start"
|
||||
android:hint="@string/address_bar_hint"
|
||||
android:inputType="textEmailAddress"
|
||||
android:paddingLeft="20dp"
|
||||
android:paddingRight="5dp"
|
||||
android:layout_toLeftOf="@id/erase"
|
||||
android:layout_centerVertical="true"/>
|
||||
android:textColorHint="@color/colorE"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
|
|
@ -59,45 +62,46 @@
|
|||
android:id="@+id/numpad"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="10dp"
|
||||
android:layout_above="@id/controls"
|
||||
android:layout_below="@id/address_bar"
|
||||
android:layout_centerInParent="true"/>
|
||||
android:layout_centerInParent="true"
|
||||
android:background="@color/colorB"
|
||||
android:padding="10dp"/>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/controls"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="60dp">
|
||||
android:layout_height="60dp"
|
||||
android:layout_alignParentBottom="true">
|
||||
|
||||
<RelativeLayout
|
||||
android:focusable="true"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:adjustViewBounds="true">
|
||||
android:adjustViewBounds="true"
|
||||
android:focusable="true"
|
||||
android:visibility="gone">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/add_contact"
|
||||
android:src="@drawable/contact_add_button"
|
||||
android:contentDescription="@string/content_description_add_contact"
|
||||
android:background="@drawable/toolbar_button"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:background="@drawable/toolbar_button"
|
||||
android:contentDescription="@string/content_description_add_contact"
|
||||
android:padding="15dp"
|
||||
android:layout_alignParentBottom="true"/>
|
||||
android:src="@drawable/contact_add_button"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<org.linphone.ui.CallButton
|
||||
android:id="@+id/call"
|
||||
android:src="@drawable/call_audio_start"
|
||||
android:contentDescription="@string/content_description_call"
|
||||
android:background="@drawable/call"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.5"
|
||||
android:contentDescription="@string/content_description_call"
|
||||
android:padding="12dp"
|
||||
android:layout_weight="0.5"/>
|
||||
android:src="@drawable/call_alt_start_selected"/>
|
||||
</LinearLayout>
|
||||
</RelativeLayout>
|
||||
|
||||
|
|
|
|||
|
|
@ -108,6 +108,7 @@
|
|||
android:layout_height="0dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/history_image"
|
||||
android:src="@drawable/footer_history"
|
||||
android:contentDescription="@string/content_description_history"
|
||||
android:layout_width="wrap_content"
|
||||
|
|
@ -117,7 +118,7 @@
|
|||
|
||||
<View
|
||||
android:id="@+id/history_select"
|
||||
android:background="@color/colorA"
|
||||
android:background="@color/colorB"
|
||||
android:layout_width="5dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentLeft="true"
|
||||
|
|
@ -139,13 +140,14 @@
|
|||
</RelativeLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/contacts"
|
||||
android:id="@+id/contacts_footer"
|
||||
android:background="@drawable/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="0dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/contacts"
|
||||
android:src="@drawable/footer_contacts"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:layout_width="match_parent"
|
||||
|
|
@ -155,7 +157,7 @@
|
|||
|
||||
<View
|
||||
android:id="@+id/contacts_select"
|
||||
android:background="@color/colorA"
|
||||
android:background="@color/colorB"
|
||||
android:layout_width="5dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentLeft="true"
|
||||
|
|
@ -163,13 +165,14 @@
|
|||
</RelativeLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/dialer"
|
||||
android:id="@+id/dialer_footer"
|
||||
android:background="@drawable/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="0dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dialer"
|
||||
android:src="@drawable/footer_dialer"
|
||||
android:contentDescription="@string/content_description_dialer"
|
||||
android:layout_width="match_parent"
|
||||
|
|
@ -179,7 +182,7 @@
|
|||
|
||||
<View
|
||||
android:id="@+id/dialer_select"
|
||||
android:background="@color/colorA"
|
||||
android:background="@color/colorB"
|
||||
android:layout_width="5dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentLeft="true"/>
|
||||
|
|
@ -194,6 +197,7 @@
|
|||
android:layout_height="0dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/chat_image"
|
||||
android:src="@drawable/footer_chat"
|
||||
android:contentDescription="@string/content_description_chat_button"
|
||||
android:layout_width="match_parent"
|
||||
|
|
@ -203,7 +207,7 @@
|
|||
|
||||
<View
|
||||
android:id="@+id/chat_select"
|
||||
android:background="@color/colorA"
|
||||
android:background="@color/colorB"
|
||||
android:visibility="gone"
|
||||
android:layout_width="5dp"
|
||||
android:layout_height="match_parent"
|
||||
|
|
|
|||
|
|
@ -5,10 +5,10 @@
|
|||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/dialer_background"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_width="400dp"
|
||||
android:layout_height="wrap_content"/>
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:src="@drawable/linphone_logo"/>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/dialer"
|
||||
|
|
@ -59,10 +59,11 @@
|
|||
android:id="@+id/numpad"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="10dp"
|
||||
android:layout_above="@id/controls"
|
||||
android:layout_below="@id/address_bar"
|
||||
android:layout_centerInParent="true"/>
|
||||
android:layout_centerInParent="true"
|
||||
android:background="@color/colorB"
|
||||
android:padding="10dp"/>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/controls"
|
||||
|
|
@ -71,33 +72,32 @@
|
|||
android:layout_height="60dp">
|
||||
|
||||
<RelativeLayout
|
||||
android:focusable="true"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:adjustViewBounds="true">
|
||||
android:adjustViewBounds="true"
|
||||
android:focusable="true"
|
||||
android:visibility="gone">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/add_contact"
|
||||
android:src="@drawable/contact_add_button"
|
||||
android:background="@drawable/toolbar_button"
|
||||
android:contentDescription="@string/content_description_add_contact"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:background="@drawable/toolbar_button"
|
||||
android:contentDescription="@string/content_description_add_contact"
|
||||
android:padding="15dp"
|
||||
android:layout_alignParentBottom="true"/>
|
||||
android:src="@drawable/contact_add_button"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<org.linphone.ui.CallButton
|
||||
android:id="@+id/call"
|
||||
android:src="@drawable/call_audio_start"
|
||||
android:background="@drawable/call"
|
||||
android:contentDescription="@string/content_description_call"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="12dp"
|
||||
android:layout_weight="0.5"/>
|
||||
android:layout_weight="0.5"
|
||||
android:contentDescription="@string/content_description_call"
|
||||
android:src="@drawable/call_alt_start_over"/>
|
||||
</LinearLayout>
|
||||
</RelativeLayout>
|
||||
|
||||
|
|
|
|||
|
|
@ -108,7 +108,7 @@
|
|||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/footer_history"
|
||||
android:id="@+id/history_image"
|
||||
android:src="@drawable/footer_history"
|
||||
android:contentDescription="@string/content_description_history"
|
||||
android:layout_width="match_parent"
|
||||
|
|
@ -118,7 +118,7 @@
|
|||
|
||||
<View
|
||||
android:id="@+id/history_select"
|
||||
android:background="@color/colorA"
|
||||
android:background="@color/colorB"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
|
|
@ -139,13 +139,14 @@
|
|||
</RelativeLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/contacts"
|
||||
android:id="@+id/contacts_footer"
|
||||
android:background="@drawable/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/contacts"
|
||||
android:src="@drawable/footer_contacts"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:layout_width="match_parent"
|
||||
|
|
@ -155,7 +156,7 @@
|
|||
|
||||
<View
|
||||
android:id="@+id/contacts_select"
|
||||
android:background="@color/colorA"
|
||||
android:background="@color/colorB"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
|
|
@ -163,13 +164,14 @@
|
|||
</RelativeLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/dialer"
|
||||
android:id="@+id/dialer_footer"
|
||||
android:background="@drawable/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dialer"
|
||||
android:src="@drawable/footer_dialer"
|
||||
android:contentDescription="@string/content_description_dialer"
|
||||
android:layout_width="match_parent"
|
||||
|
|
@ -179,7 +181,7 @@
|
|||
|
||||
<View
|
||||
android:id="@+id/dialer_select"
|
||||
android:background="@color/colorA"
|
||||
android:background="@color/colorB"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_alignParentBottom="true"/>
|
||||
|
|
@ -194,6 +196,7 @@
|
|||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/chat_image"
|
||||
android:src="@drawable/footer_chat"
|
||||
android:contentDescription="@string/content_description_chat"
|
||||
android:layout_width="match_parent"
|
||||
|
|
@ -203,7 +206,7 @@
|
|||
|
||||
<View
|
||||
android:id="@+id/chat_select"
|
||||
android:background="@color/colorA"
|
||||
android:background="@color/colorB"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
|
|
@ -10,17 +10,47 @@
|
|||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentStart="true"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_gravity="center"
|
||||
android:layout_weight="0.1"
|
||||
android:gravity="center">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/instruction"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_above="@+id/bottom_text"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:gravity="center_horizontal"
|
||||
android:lineSpacingExtra="0sp"
|
||||
android:paddingEnd="35dp"
|
||||
android:paddingStart="35dp"
|
||||
android:text="@string/assistant_instruction1"
|
||||
android:textColor="#000000"
|
||||
android:textSize="20sp"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/step"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_above="@+id/instruction"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:paddingBottom="10dp"
|
||||
android:text="@string/assistant_step1"
|
||||
android:textColor="#ff6600"
|
||||
android:textSize="16.7sp"/>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/header_text"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="120dp"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:layout_marginLeft="35dp"
|
||||
android:layout_marginRight="35dp">
|
||||
android:layout_marginEnd="35dp"
|
||||
android:layout_marginStart="35dp"
|
||||
android:layout_marginTop="30dp"
|
||||
android:gravity="center">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView2"
|
||||
|
|
@ -39,30 +69,63 @@ Mobile Security Intense"
|
|||
android:layout_height="65dp"
|
||||
android:layout_alignParentStart="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginRight="10dp"
|
||||
android:layout_marginRight="20dp"
|
||||
android:src="@drawable/logo_secure_phone_big"/>
|
||||
</RelativeLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/bottom_text"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_below="@+id/header_text"
|
||||
android:layout_width="250dp"
|
||||
android:layout_height="250dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_gravity="center"
|
||||
android:layout_margin="50dp"
|
||||
android:foreground="@drawable/avatar_mask_border"
|
||||
android:layout_marginBottom="30dp"
|
||||
android:gravity="center"
|
||||
>
|
||||
android:paddingTop="20dp">
|
||||
|
||||
<SurfaceView
|
||||
android:id="@+id/qrcodeCaptureSurface"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_weight="10"
|
||||
android:foreground="@drawable/avatar_mask_border"
|
||||
android:visibility="visible"/>
|
||||
|
||||
<EditText
|
||||
android:id="@+id/code_sms"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginBottom="15dp"
|
||||
android:background="#c4c4c4"
|
||||
android:inputType="text|textNoSuggestions"
|
||||
android:maxLines="1"
|
||||
android:textColor="@color/colorB"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<Button
|
||||
android:id="@+id/valider"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:layout_below="@+id/code_sms"
|
||||
android:layout_marginBottom="15dp"
|
||||
android:background="#ff6600"
|
||||
android:text="valider"
|
||||
android:textColor="#ffffff"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<Button
|
||||
android:id="@+id/retour"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:layout_below="@+id/valider"
|
||||
android:background="#595959"
|
||||
android:text="retour"
|
||||
android:textColor="#ffffff"
|
||||
android:visibility="gone"/>
|
||||
|
||||
</RelativeLayout>
|
||||
</RelativeLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</RelativeLayout>
|
||||
|
|
@ -1,33 +1,33 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/delete_message"
|
||||
android:button="@drawable/checkbox"
|
||||
android:contentDescription="@string/content_description_delete"
|
||||
android:layout_marginLeft="5dp"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:layout_alignParentRight="true"/>
|
||||
<CheckBox
|
||||
android:id="@+id/delete_message"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_marginLeft="5dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:button="@drawable/checkbox"
|
||||
android:contentDescription="@string/content_description_delete"/>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/event"
|
||||
android:orientation="horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_toLeftOf="@id/delete_message"
|
||||
android:gravity="center_vertical">
|
||||
android:layout_toLeftOf="@id/delete_message"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginRight="10dp"
|
||||
android:src="@drawable/event_gray"
|
||||
android:scaleType="fitXY"/>
|
||||
android:layout_weight="1"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/event_gray"/>
|
||||
|
||||
<!--<TextView
|
||||
android:id="@+id/event_date"
|
||||
|
|
@ -48,16 +48,16 @@
|
|||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:src="@drawable/event_gray"
|
||||
android:scaleType="fitXY"/>
|
||||
android:layout_weight="1"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/event_gray"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/bubble"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_toLeftOf="@id/delete_message">
|
||||
|
||||
|
|
@ -192,7 +192,6 @@
|
|||
android:layout_weight="1"
|
||||
android:gravity="right"
|
||||
android:orientation="horizontal"
|
||||
android:paddingRight="5dp"
|
||||
android:textColor="#595959"
|
||||
android:textSize="8.3sp"/>
|
||||
|
||||
|
|
@ -205,6 +204,7 @@
|
|||
android:layout_marginTop="2dp"
|
||||
android:gravity="right"
|
||||
android:orientation="horizontal"
|
||||
android:paddingLeft="5dp"
|
||||
android:visibility="gone">
|
||||
|
||||
<TextView
|
||||
|
|
|
|||
|
|
@ -13,18 +13,17 @@
|
|||
android:id="@+id/top_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:background="@color/colorF"
|
||||
android:background="@color/colorH"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/back"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="left"
|
||||
android:layout_gravity="left|center"
|
||||
android:layout_weight="0.2"
|
||||
android:background="@drawable/toolbar_button"
|
||||
android:contentDescription="@string/content_description_back"
|
||||
android:padding="18dp"
|
||||
android:src="@drawable/back"/>
|
||||
|
||||
<TextView
|
||||
|
|
@ -41,11 +40,9 @@
|
|||
android:id="@+id/confirm"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="right"
|
||||
android:layout_gravity="right|center"
|
||||
android:layout_weight="0.2"
|
||||
android:background="@drawable/toolbar_button"
|
||||
android:contentDescription="@string/content_description_valid"
|
||||
android:padding="18dp"
|
||||
android:src="@drawable/chat_room_creation_confirm"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
|
@ -54,18 +51,20 @@
|
|||
android:id="@+id/layoutSubjectField"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="10dp">
|
||||
android:layout_marginBottom="10dp"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:layout_marginRight="20dp"
|
||||
android:layout_marginTop="10dp">
|
||||
|
||||
<EditText
|
||||
android:id="@+id/subjectField"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:background="@drawable/resizable_textfield"
|
||||
android:background="#f3f3f3"
|
||||
android:contentDescription="@string/content_description_conversation_subject"
|
||||
android:hint="@string/conversation_subject_hint"
|
||||
android:gravity="center"
|
||||
android:hint="@string/conversation_subject_hint"
|
||||
android:inputType="textEmailSubject"
|
||||
android:paddingRight="5dp"
|
||||
android:textColor="@android:color/black"
|
||||
android:textCursorDrawable="@null"/>
|
||||
|
||||
|
|
@ -75,23 +74,23 @@
|
|||
android:id="@+id/addParticipantsLayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@color/colorG"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingBottom="8dp">
|
||||
android:background="@color/colorH"
|
||||
android:paddingBottom="8dp"
|
||||
android:paddingTop="8dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:textStyle="bold"
|
||||
android:textSize="15sp"
|
||||
android:text="@string/chat_room_participants"
|
||||
android:textColor="@color/colorB"
|
||||
android:text="@string/chat_room_participants" />
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/addParticipants"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="14dp"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:paddingRight="10dp"
|
||||
|
|
|
|||
|
|
@ -21,25 +21,36 @@
|
|||
|
||||
<ImageView
|
||||
android:id="@+id/contact_picture"
|
||||
android:src="@drawable/avatar"
|
||||
android:contentDescription="@string/content_description_contact_picture"
|
||||
android:layout_width="35dp"
|
||||
android:layout_height="35dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_marginLeft="5dp"/>
|
||||
android:layout_marginLeft="5dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/content_description_contact_picture"
|
||||
android:src="@drawable/avatar_big_secure1"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/mask"
|
||||
android:src="@drawable/avatar_mask"
|
||||
android:layout_width="35dp"
|
||||
android:layout_height="35dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_marginLeft="5dp"/>
|
||||
android:layout_marginLeft="5dp"
|
||||
android:adjustViewBounds="true"
|
||||
android:src="@drawable/avatar_mask"
|
||||
android:visibility="gone"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/secure"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="18dp"
|
||||
android:layout_centerInParent="true"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_marginRight="15dp"
|
||||
android:src="@drawable/security_1"
|
||||
android:visibility="visible"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/delete"
|
||||
android:src="@drawable/chat_group_delete"
|
||||
|
|
@ -87,23 +98,24 @@
|
|||
android:id="@+id/isNotAdminLayout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginRight="20dp">
|
||||
android:layout_marginRight="20dp"
|
||||
android:visibility="gone">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:paddingRight="5dp"
|
||||
android:layout_gravity="center"
|
||||
android:adjustViewBounds="true"
|
||||
android:paddingRight="5dp"
|
||||
android:scaleType="centerInside"
|
||||
android:src="@drawable/check_unselected" />
|
||||
android:src="@drawable/check_unselected"/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:textColor="@color/colorF"
|
||||
android:text="@string/chat_room_infos_admin"/>
|
||||
android:text="@string/chat_room_infos_admin"
|
||||
android:textColor="@color/colorF"/>
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
|
@ -113,7 +125,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:layout_toRightOf="@id/avatar_layout"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_toLeftOf="@id/adminLayout"
|
||||
android:layout_toLeftOf="@id/secure"
|
||||
android:layout_marginLeft="10dp">
|
||||
|
||||
<TextView
|
||||
|
|
|
|||
|
|
@ -103,8 +103,7 @@
|
|||
android:background=" #f3f3f3 "
|
||||
android:contentDescription="@string/content_description_search_contact"
|
||||
android:inputType="textPersonName"
|
||||
android:textColor="@android:color/black"
|
||||
android:textCursorDrawable="@null"/>
|
||||
android:textColor="@android:color/black"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/clearSearchField"
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ history_max_size=100
|
|||
enable_basic_to_client_group_chat_room_migration=0
|
||||
enable_simple_group_chat_message_state=0
|
||||
aggregate_imdn=1
|
||||
store_friends=1
|
||||
store_friends=0
|
||||
debug=1
|
||||
|
||||
[app]
|
||||
|
|
@ -50,6 +50,7 @@ activation_code_length=4
|
|||
prefer_basic_chat_room=1
|
||||
show_login_view=1
|
||||
debug_popup_magic=#1234
|
||||
debug=1
|
||||
server_url=http://85.233.205.218:443/xmlrpc
|
||||
|
||||
[in-app-purchase]
|
||||
|
|
|
|||
|
|
@ -119,6 +119,10 @@
|
|||
<string name="phone_number_info_content">\nThanks to your phone number, your friends will find you more easily.\n\n You will see in your address book who is using Linphone and your friends will know that they can reach you on Linphone as well.\n</string>
|
||||
<string name="phone_number_link_info_content">\nYour friends will find you more easily if you link your account to your phone number\n\nYou will see in your address book who is using Linphone and your friends will know that they can reach you on Linphone as well.\n</string>
|
||||
<string name="phone_number_link_info_content_already_account">You can only use your phone number with one Linphone account.\n\nIf you had already linked your number to an other account but you prefer to use this one, simply link it now and your number will automatically be moved to this account.</string>
|
||||
<string name="assistant_step1">Étape 1</string>
|
||||
<string name="assistant_step2">Étape 2</string>
|
||||
<string name="assistant_instruction1">Veuillez scanner le code reçu dans votre courriel.</string>
|
||||
<string name="assistant_instruction2">Veuillez saisir le code SMS</string>
|
||||
|
||||
<!-- Status -->
|
||||
<string name="invalid_email">Invalid email</string>
|
||||
|
|
|
|||
|
|
@ -1774,7 +1774,4 @@ public class LinphoneManager implements CoreListener, SensorEventListener, Accou
|
|||
mUnreadChatsPerRoom.put(key, 1);
|
||||
}
|
||||
}
|
||||
|
||||
public void onQrcodeFound(Core lc, String something){
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,17 +27,22 @@ import org.linphone.core.Core;
|
|||
import org.linphone.core.CoreListenerStub;
|
||||
import org.linphone.core.ProxyConfig;
|
||||
import org.linphone.core.RegistrationState;
|
||||
import org.linphone.mediastream.Log;
|
||||
import org.linphone.mediastream.video.AndroidVideoWindowImpl;
|
||||
import org.linphone.mediastream.video.capture.hwconf.AndroidCameraConfiguration;
|
||||
import org.linphone.xmlrpc.XmlRpcHelper;
|
||||
import org.linphone.xmlrpc.XmlRpcListenerBase;
|
||||
|
||||
import android.Manifest;
|
||||
import android.app.Activity;
|
||||
import android.app.ProgressDialog;
|
||||
import android.content.Intent;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.graphics.drawable.ColorDrawable;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.hardware.Camera;
|
||||
import android.os.Bundle;
|
||||
import android.support.v4.app.ActivityCompat;
|
||||
import android.support.v4.content.ContextCompat;
|
||||
import android.view.SurfaceView;
|
||||
import android.view.View;
|
||||
|
|
@ -45,52 +50,88 @@ import android.view.View.OnClickListener;
|
|||
import android.view.WindowManager;
|
||||
import android.widget.Button;
|
||||
import android.widget.EditText;
|
||||
import android.widget.RelativeLayout;
|
||||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
|
||||
import static android.os.SystemClock.sleep;
|
||||
|
||||
public class RemoteProvisioningLoginActivity extends Activity implements OnClickListener {
|
||||
private EditText login, password, domain;
|
||||
private Button connect;
|
||||
private static RemoteProvisioningLoginActivity instance;
|
||||
private EditText code_sms;
|
||||
private TextView step, instruction;
|
||||
private Button ok, back;
|
||||
private ProgressDialog progress;
|
||||
private String qrcodeString;
|
||||
private RelativeLayout bottom;
|
||||
private CoreListenerStub mListener;
|
||||
private SurfaceView mQrcodeView;
|
||||
private AndroidVideoWindowImpl androidVideoWindowImpl;
|
||||
private boolean cameraAuthorize = false;
|
||||
private boolean readQRCode = true;
|
||||
private int PERMISSION_CAMERA = 108;
|
||||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
instance = this;
|
||||
setContentView(R.layout.assistant_remote_provisioning_login);
|
||||
|
||||
if (getPackageManager().checkPermission(Manifest.permission.CAMERA,
|
||||
getPackageName()) != PackageManager.PERMISSION_GRANTED) {
|
||||
checkAndRequestVideoPermission();
|
||||
} else {
|
||||
cameraAuthorize = true;
|
||||
}
|
||||
|
||||
mQrcodeView = (SurfaceView) findViewById(R.id.qrcodeCaptureSurface);
|
||||
bottom = (RelativeLayout) findViewById(R.id.bottom_text);
|
||||
code_sms = (EditText) findViewById(R.id.code_sms);
|
||||
step = (TextView) findViewById(R.id.step);
|
||||
instruction = (TextView) findViewById(R.id.instruction);
|
||||
|
||||
ok = (Button) findViewById(R.id.valider);
|
||||
back = (Button) findViewById(R.id.retour);
|
||||
|
||||
ok.setOnClickListener(this);
|
||||
back.setOnClickListener(this);
|
||||
|
||||
mQrcodeView.setOnClickListener(new OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
if (readQRCode && getPackageManager().checkPermission(Manifest.permission.CAMERA,
|
||||
getPackageName()) != PackageManager.PERMISSION_GRANTED) {
|
||||
checkAndRequestVideoPermission();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
mListener = new CoreListenerStub() {
|
||||
@Override
|
||||
public void onQrcodeFound(Core lc, String result) {
|
||||
enableQrcodeReader(false);
|
||||
//AssistantActivity.instance().displayRemoteProvisioning(result);
|
||||
//TODO check validitée du qrcode
|
||||
instance.qrcodeString = result;
|
||||
runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
instance.enableQrcodeReader(false);
|
||||
instance.displayCodeSms();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
/*login = (EditText) findViewById(R.id.assistant_username);
|
||||
password = (EditText) findViewById(R.id.assistant_password);
|
||||
domain = (EditText) findViewById(R.id.assistant_domain);
|
||||
domain.setText(getString(R.string.default_domain));
|
||||
|
||||
connect = (Button) findViewById(R.id.assistant_connect);
|
||||
connect.setOnClickListener(this);
|
||||
|
||||
String defaultDomain = getIntent().getStringExtra("Domain");
|
||||
if (defaultDomain != null) {
|
||||
domain.setText(defaultDomain);
|
||||
domain.setEnabled(false);
|
||||
}
|
||||
|
||||
mListener = new CoreListenerStub(){
|
||||
@Override
|
||||
public void onConfiguringStatus(Core lc, final ConfiguringState state, String message) {
|
||||
if (state == ConfiguringState.Successful) {
|
||||
//TODO
|
||||
} else if (state == ConfiguringState.Failed) {
|
||||
Toast.makeText(RemoteProvisioningLoginActivity.this, R.string.remote_provisioning_failure, Toast.LENGTH_LONG).show();
|
||||
runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
instance.ok.setEnabled(true);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -103,7 +144,20 @@ public class RemoteProvisioningLoginActivity extends Activity implements OnClick
|
|||
}
|
||||
if (progress != null) progress.dismiss();
|
||||
}
|
||||
};*/
|
||||
|
||||
};
|
||||
|
||||
|
||||
displayQrCode();
|
||||
}
|
||||
|
||||
void checkAndRequestVideoPermission() {
|
||||
int permissionGranted = getPackageManager().checkPermission(Manifest.permission.CAMERA, getPackageName());
|
||||
Log.i("[Permission] " + Manifest.permission.CAMERA + " is " + (permissionGranted == PackageManager.PERMISSION_GRANTED ? "granted" : "denied"));
|
||||
|
||||
if (permissionGranted != PackageManager.PERMISSION_GRANTED) {
|
||||
ActivityCompat.requestPermissions(this, new String[]{Manifest.permission.CAMERA}, PERMISSION_CAMERA);
|
||||
}
|
||||
}
|
||||
|
||||
private void cancelWizard(boolean bypassCheck) {
|
||||
|
|
@ -114,56 +168,39 @@ public class RemoteProvisioningLoginActivity extends Activity implements OnClick
|
|||
}
|
||||
}
|
||||
|
||||
private boolean storeAccount(String username, String password, String domain) {
|
||||
/*XmlRpcHelper xmlRpcHelper = new XmlRpcHelper();
|
||||
xmlRpcHelper.getRemoteProvisioningFilenameAsync(new XmlRpcListenerBase() {
|
||||
@Override
|
||||
public void onRemoteProvisioningFilenameSent(String result) {
|
||||
LinphonePreferences.instance().setRemoteProvisioningUrl(result);
|
||||
LinphoneManager.getInstance().restartCore();
|
||||
}
|
||||
}, username.toString(), password.toString(), domain.toString());*/
|
||||
private void displayQrCode() {
|
||||
mQrcodeView.setVisibility(View.VISIBLE);
|
||||
code_sms.setVisibility(View.GONE);
|
||||
ok.setVisibility(View.GONE);
|
||||
back.setVisibility(View.GONE);
|
||||
|
||||
LinphonePreferences.instance().setRemoteProvisioningUrl("https://85.233.205.218/xmlrpc?username=" + username + "&password=" + password + "&domain=" + domain);
|
||||
///////// TODO
|
||||
LinphoneManager.getLc().iterate();
|
||||
LinphoneManager.getLc().iterate();
|
||||
LinphoneManager.getLc().iterate();
|
||||
LinphoneManager.getLc().iterate();
|
||||
LinphoneManager.getLc().iterate();
|
||||
LinphoneManager.getLc().iterate();
|
||||
///////// TODO
|
||||
LinphoneManager.getInstance().restartCore();
|
||||
LinphoneManager.getLc().addListener(mListener);
|
||||
//LinphonePreferences.instance().firstLaunchSuccessful();
|
||||
//setResult(Activity.RESULT_OK);
|
||||
//finish();
|
||||
/*String identity = "sip:" + username + "@" + domain;
|
||||
ProxyConfig prxCfg = lc.createProxyConfig();
|
||||
try {
|
||||
prxCfg.setIdentityAddress(identity);
|
||||
lc.addProxyConfig(prxCfg);
|
||||
} catch (CoreException e) {
|
||||
Log.e(e);
|
||||
return false;
|
||||
}
|
||||
step.setText(getString(R.string.assistant_step1));
|
||||
instruction.setText(getString(R.string.assistant_instruction1));
|
||||
|
||||
AuthInfo authInfo = Factory.instance().createAuthInfo(username, null, password, null, null, domain);
|
||||
lc.addAuthInfo(authInfo);
|
||||
readQRCode = true;
|
||||
}
|
||||
|
||||
if (LinphonePreferences.instance().getAccountCount() == 1)
|
||||
lc.setDefaultProxyConfig(prxCfg);
|
||||
*/
|
||||
return true;
|
||||
private void displayCodeSms() {
|
||||
mQrcodeView.setVisibility(View.GONE);
|
||||
code_sms.setVisibility(View.VISIBLE);
|
||||
ok.setVisibility(View.VISIBLE);
|
||||
back.setVisibility(View.VISIBLE);
|
||||
|
||||
step.setText(getString(R.string.assistant_step2));
|
||||
instruction.setText(getString(R.string.assistant_instruction2));
|
||||
|
||||
readQRCode = false;
|
||||
}
|
||||
|
||||
private void enableQrcodeReader(boolean enable) {
|
||||
LinphoneManager.getLc().enableQrcodeVideoPreview(enable);
|
||||
LinphoneManager.getLc().enableVideoPreview(enable);
|
||||
if (enable) {
|
||||
LinphoneManager.getLc().addListener(mListener);
|
||||
} else {
|
||||
LinphoneManager.getLc().removeListener(mListener);
|
||||
if (cameraAuthorize && readQRCode) {
|
||||
LinphoneManager.getLc().enableQrcodeVideoPreview(enable);
|
||||
LinphoneManager.getLc().enableVideoPreview(enable);
|
||||
if (enable) {
|
||||
LinphoneManager.getLc().addListener(mListener);
|
||||
} else {
|
||||
LinphoneManager.getLc().removeListener(mListener);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -177,6 +214,7 @@ public class RemoteProvisioningLoginActivity extends Activity implements OnClick
|
|||
String[] devices = LinphoneManager.getLc().getVideoDevicesList();
|
||||
String newDevice = devices[camId];
|
||||
LinphoneManager.getLc().setVideoDevice(newDevice);
|
||||
|
||||
}
|
||||
|
||||
private void launchQrcodeReader() {
|
||||
|
|
@ -196,7 +234,7 @@ public class RemoteProvisioningLoginActivity extends Activity implements OnClick
|
|||
}
|
||||
|
||||
public void onVideoPreviewSurfaceDestroyed(AndroidVideoWindowImpl vw) {
|
||||
|
||||
LinphoneManager.getLc().setNativePreviewWindowId(null);
|
||||
}
|
||||
});
|
||||
|
||||
|
|
@ -210,17 +248,17 @@ public class RemoteProvisioningLoginActivity extends Activity implements OnClick
|
|||
|
||||
@Override
|
||||
public void onResume() {
|
||||
Core lc = LinphoneManager.getLcIfManagerNotDestroyedOrNull();
|
||||
if (lc != null) {
|
||||
lc.addListener(mListener);
|
||||
}
|
||||
super.onResume();
|
||||
launchQrcodeReader();
|
||||
if (androidVideoWindowImpl != null) {
|
||||
synchronized (androidVideoWindowImpl) {
|
||||
LinphoneManager.getLc().setNativePreviewWindowId(androidVideoWindowImpl);
|
||||
}
|
||||
}
|
||||
super.onResume();
|
||||
Core lc = LinphoneManager.getLcIfManagerNotDestroyedOrNull();
|
||||
if (lc != null) {
|
||||
lc.addListener(mListener);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
@ -255,16 +293,42 @@ public class RemoteProvisioningLoginActivity extends Activity implements OnClick
|
|||
if (id == R.id.cancel) {
|
||||
cancelWizard(false);
|
||||
}
|
||||
/*if (id == R.id.assistant_connect){
|
||||
if (id == R.id.retour) {
|
||||
displayQrCode();
|
||||
enableQrcodeReader(true);
|
||||
}
|
||||
if (id == R.id.valider) {
|
||||
displayRemoteProvisioningInProgressDialog();
|
||||
connect.setEnabled(false);
|
||||
storeAccount(login.getText().toString(), password.getText().toString(), domain.getText().toString());
|
||||
}*/
|
||||
ok.setEnabled(false);
|
||||
storeAccount(qrcodeString);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBackPressed() {
|
||||
cancelWizard(false);
|
||||
public void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults) {
|
||||
for (int i = 0; i < permissions.length; i++) {
|
||||
Log.i("[Permission] " + permissions[i] + " is " + (grantResults[i] == PackageManager.PERMISSION_GRANTED ? "granted" : "denied"));
|
||||
}
|
||||
|
||||
if (requestCode == PERMISSION_CAMERA) {
|
||||
if (grantResults[0] == PackageManager.PERMISSION_GRANTED) {
|
||||
cameraAuthorize = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private boolean storeAccount(String url) {
|
||||
LinphonePreferences.instance().setRemoteProvisioningUrl(url);
|
||||
//TODO
|
||||
LinphoneManager.getLc().iterate();
|
||||
sleep(1000);
|
||||
LinphoneManager.getLc().iterate();
|
||||
//TODO
|
||||
|
||||
LinphoneManager.getInstance().restartCore();
|
||||
LinphoneManager.getLc().addListener(mListener);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
private void displayRemoteProvisioningInProgressDialog() {
|
||||
|
|
|
|||
|
|
@ -253,10 +253,10 @@ public class ChatEventsAdapter extends ListSelectionAdapter {
|
|||
|
||||
if (isEditionEnabled()) {
|
||||
layoutParams.addRule(RelativeLayout.LEFT_OF, holder.delete.getId());
|
||||
layoutParams.setMargins(100, 10, 10, 10);
|
||||
layoutParams.setMargins(200, 10, 10, 10);
|
||||
} else {
|
||||
layoutParams.addRule(RelativeLayout.ALIGN_PARENT_RIGHT);
|
||||
layoutParams.setMargins(100, 10, 10, 10);
|
||||
layoutParams.setMargins(200, 10, 10, 10);
|
||||
}
|
||||
|
||||
holder.background.setBackgroundColor(0x26ff6600);
|
||||
|
|
@ -275,10 +275,10 @@ public class ChatEventsAdapter extends ListSelectionAdapter {
|
|||
|
||||
if (isEditionEnabled()) {
|
||||
layoutParams.addRule(RelativeLayout.LEFT_OF, holder.delete.getId());
|
||||
layoutParams.setMargins(100, 10, 10, 10);
|
||||
layoutParams.setMargins(200, 10, 10, 10);
|
||||
} else {
|
||||
layoutParams.addRule(RelativeLayout.ALIGN_PARENT_LEFT);
|
||||
layoutParams.setMargins(10, 10, 100, 10);
|
||||
layoutParams.setMargins(10, 10, 200, 10);
|
||||
}
|
||||
|
||||
holder.background.setBackgroundColor(0x19595959);
|
||||
|
|
|
|||
|
|
@ -82,6 +82,7 @@ public class GroupInfoAdapter extends BaseAdapter {
|
|||
TextView name = view.findViewById(R.id.name);
|
||||
ImageView avatar = view.findViewById(R.id.contact_picture);
|
||||
ImageView delete = view.findViewById(R.id.delete);
|
||||
ImageView secure = view.findViewById(R.id.secure);
|
||||
final LinearLayout isAdmin = view.findViewById(R.id.isAdminLayout);
|
||||
final LinearLayout isNotAdmin = view.findViewById(R.id.isNotAdminLayout);
|
||||
|
||||
|
|
@ -101,6 +102,19 @@ public class GroupInfoAdapter extends BaseAdapter {
|
|||
});
|
||||
delete.setTag(ca);
|
||||
|
||||
final String sipUri = ca.getAddress().asStringUriOnly();
|
||||
final String nameString = name.getText().toString();
|
||||
|
||||
secure.setVisibility(View.VISIBLE);
|
||||
secure.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
if (LinphoneActivity.isInstanciated()) {
|
||||
LinphoneActivity.instance().setAddresGoToDialerAndCall(sipUri, nameString, null);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
isAdmin.setVisibility(ca.isAdmin() ? View.VISIBLE : View.GONE);
|
||||
isNotAdmin.setVisibility(ca.isAdmin() ? View.GONE : View.VISIBLE);
|
||||
|
||||
|
|
|
|||
|
|
@ -116,7 +116,13 @@ public class GroupInfoFragment extends Fragment implements ChatRoomListener {
|
|||
mParticipants.remove(ca);
|
||||
mAdapter.updateDataSet(mParticipants);
|
||||
mParticipantsList.setAdapter(mAdapter);
|
||||
mConfirmButton.setEnabled(mSubjectField.getText().length() > 0 && mParticipants.size() > 0);
|
||||
if (mSubjectField.getText().length() > 0 && mParticipants.size() > 0) {
|
||||
mConfirmButton.setClickable(true);
|
||||
mConfirmButton.setImageAlpha(255);
|
||||
} else {
|
||||
mConfirmButton.setClickable(false);
|
||||
mConfirmButton.setImageAlpha(140);
|
||||
}
|
||||
}
|
||||
});
|
||||
mParticipantsList.setAdapter(mAdapter);
|
||||
|
|
@ -216,7 +222,13 @@ public class GroupInfoFragment extends Fragment implements ChatRoomListener {
|
|||
|
||||
@Override
|
||||
public void afterTextChanged(Editable editable) {
|
||||
mConfirmButton.setEnabled(mSubjectField.getText().length() > 0 && mParticipants.size() > 0);
|
||||
if (mSubjectField.getText().length() > 0 && mParticipants.size() > 0) {
|
||||
mConfirmButton.setClickable(true);
|
||||
mConfirmButton.setImageAlpha(255);
|
||||
} else {
|
||||
mConfirmButton.setClickable(false);
|
||||
mConfirmButton.setImageAlpha(140);
|
||||
}
|
||||
}
|
||||
});
|
||||
mSubjectField.setText(mSubject);
|
||||
|
|
@ -309,7 +321,13 @@ public class GroupInfoFragment extends Fragment implements ChatRoomListener {
|
|||
}
|
||||
}
|
||||
});
|
||||
mConfirmButton.setEnabled(mSubjectField.getText().length() > 0 && mParticipants.size() > 0);
|
||||
if (mSubjectField.getText().length() > 0 && mParticipants.size() > 0) {
|
||||
mConfirmButton.setClickable(true);
|
||||
mConfirmButton.setImageAlpha(255);
|
||||
} else {
|
||||
mConfirmButton.setClickable(false);
|
||||
mConfirmButton.setImageAlpha(140);
|
||||
}
|
||||
|
||||
if (!mIsEditionEnabled) {
|
||||
mSubjectField.setEnabled(false);
|
||||
|
|
|
|||
|
|
@ -391,8 +391,8 @@ public class ContactsListFragment extends Fragment implements OnClickListener, O
|
|||
LinphoneActivity.instance().displayContact(contact, onlyDisplayChatAddress);
|
||||
}*/
|
||||
// Obiane spec
|
||||
if (LinphoneActivity.isInstanciated() && contact.getNumbersOrAddresses() != null) {
|
||||
LinphoneActivity.instance().displayHistoryDetail(contact.getNumbersOrAddresses().get(0).getValue(), null);
|
||||
if (LinphoneActivity.isInstanciated() && contact.getFriend() != null && contact.getFriend().getAddress() != null) {
|
||||
LinphoneActivity.instance().displayHistoryDetail(contact.getFriend().getAddress().asStringUriOnly(), null);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -183,7 +183,9 @@ public class ContactsManager extends ContentObserver {
|
|||
}
|
||||
|
||||
public boolean hasContactsAccess() {
|
||||
if (context == null) {
|
||||
//Obiane spec
|
||||
return false;
|
||||
/*if (context == null) {
|
||||
context = LinphoneManager.getInstance().getContext();
|
||||
}
|
||||
if (context == null) {
|
||||
|
|
@ -192,7 +194,7 @@ public class ContactsManager extends ContentObserver {
|
|||
boolean contactsR = (PackageManager.PERMISSION_GRANTED ==
|
||||
context.getPackageManager().checkPermission(android.Manifest.permission.READ_CONTACTS, context.getPackageName()));
|
||||
context.getPackageManager();
|
||||
return contactsR && !context.getResources().getBoolean(R.bool.force_use_of_linphone_friends);
|
||||
return contactsR && !context.getResources().getBoolean(R.bool.force_use_of_linphone_friends);*/
|
||||
}
|
||||
|
||||
public void setLinphoneContactsPrefered(boolean isPrefered) {
|
||||
|
|
@ -264,7 +266,9 @@ public class ContactsManager extends ContentObserver {
|
|||
}
|
||||
|
||||
public synchronized void setContacts(List<LinphoneContact> c) {
|
||||
if (contacts.isEmpty() || contacts.size() > c.size()) {
|
||||
// Obiane spec
|
||||
contacts = c;
|
||||
/*if (contacts.isEmpty() || contacts.size() > c.size()) {
|
||||
contacts = c;
|
||||
} else {
|
||||
for (LinphoneContact contact : c) {
|
||||
|
|
@ -273,11 +277,13 @@ public class ContactsManager extends ContentObserver {
|
|||
}
|
||||
}
|
||||
}
|
||||
Collections.sort(contacts);
|
||||
Collections.sort(contacts);*/
|
||||
}
|
||||
|
||||
public synchronized void setSipContacts(List<LinphoneContact> c) {
|
||||
if (sipContacts.isEmpty() || sipContacts.size() > c.size()) {
|
||||
// Obiane spec
|
||||
sipContacts = c;
|
||||
/*if (sipContacts.isEmpty() || sipContacts.size() > c.size()) {
|
||||
sipContacts = c;
|
||||
} else {
|
||||
for (LinphoneContact contact : c) {
|
||||
|
|
@ -286,7 +292,7 @@ public class ContactsManager extends ContentObserver {
|
|||
}
|
||||
}
|
||||
}
|
||||
Collections.sort(sipContacts);
|
||||
Collections.sort(sipContacts);*/
|
||||
}
|
||||
|
||||
public synchronized void refreshSipContact(Friend lf) {
|
||||
|
|
|
|||
|
|
@ -97,6 +97,8 @@ public class HistoryDetailFragment extends Fragment implements OnClickListener {
|
|||
contactName = (TextView) view.findViewById(R.id.contact_name);
|
||||
contactAddress = (TextView) view.findViewById(R.id.contact_address);
|
||||
|
||||
contactName.setText(displayName);
|
||||
|
||||
callDirection = (ImageView) view.findViewById(R.id.direction);
|
||||
|
||||
time = (TextView) view.findViewById(R.id.time);
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
Subproject commit 7bae67807795b0dc18dacfa6c463313b97af4936
|
||||
Subproject commit 87fc60ba8beb16721df9d14229f00a44c0631d7c
|
||||
Loading…
Add table
Reference in a new issue