Remove/add assets
Main and dialer view in progress
This commit is contained in:
parent
cbd7e4805d
commit
f9f9f7ddd5
45 changed files with 633 additions and 613 deletions
|
@ -1,10 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@drawable/add_call_more_over" />
|
||||
<item android:state_enabled="false"
|
||||
android:drawable="@drawable/add_call_more_disable" />
|
||||
<item
|
||||
android:drawable="@drawable/add_call_more_default" />
|
||||
android:drawable="@drawable/call_add" />
|
||||
</selector>
|
||||
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@drawable/add_contact_over" />
|
||||
<item android:state_enabled="false"
|
||||
android:drawable="@drawable/add_contact_disabled" />
|
||||
<item
|
||||
android:drawable="@drawable/add_contact_default" />
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@drawable/contact_add" />
|
||||
<item android:state_enabled="false"
|
||||
android:drawable="@drawable/contact_add" />
|
||||
<item
|
||||
android:drawable="@drawable/contact_add" />
|
||||
</selector>
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true" android:color="@color/button_addContactGrey" />
|
||||
<item android:color="@color/button_addContact"/>
|
||||
<item android:state_pressed="true" android:drawable="@color/button_addContactGrey" />
|
||||
<item android:drawable="@color/button_addContact"/>
|
||||
</selector>
|
|
@ -1,8 +1,10 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@drawable/call_over" />
|
||||
android:drawable="@color/call_selected" />
|
||||
<item android:state_enabled="false"
|
||||
android:drawable="@color/call_selected" />
|
||||
<item
|
||||
android:drawable="@drawable/call_default" />
|
||||
android:drawable="@color/footer_select" />
|
||||
</selector>
|
||||
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@drawable/chat_over" />
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@color/footer_select" />
|
||||
<item android:state_selected="true"
|
||||
android:drawable="@drawable/chat_selected" />
|
||||
android:drawable="@color/footer_button" />
|
||||
<item
|
||||
android:drawable="@drawable/chat_default" />
|
||||
android:drawable="@color/footer_button" />
|
||||
</selector>
|
||||
|
|
|
@ -1,7 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@drawable/chat_photo_over" />
|
||||
<item android:state_enabled="false"
|
||||
android:drawable="@drawable/chat_photo_disabled" />
|
||||
<item
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_enabled="true"
|
||||
android:drawable="@drawable/contacts_all_default" />
|
||||
android:drawable="@drawable/contacts_all_selected" />
|
||||
<item android:state_enabled="false"
|
||||
android:drawable="@drawable/contacts_all_selected" />
|
||||
</selector>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_enabled="true"
|
||||
android:drawable="@drawable/contacts_linphone_default" />
|
||||
android:drawable="@drawable/contacts_sip_selected" />
|
||||
<item android:state_enabled="false"
|
||||
android:drawable="@drawable/contacts_linphone_selected" />
|
||||
android:drawable="@drawable/contacts_sip_default" />
|
||||
</selector>
|
|
@ -1,9 +1,9 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@drawable/dialer_over" />
|
||||
<item android:state_selected="true"
|
||||
android:drawable="@drawable/dialer_selected" />
|
||||
<item
|
||||
android:drawable="@drawable/dialer_default" />
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@color/footer_select" />
|
||||
<item android:state_selected="true"
|
||||
android:drawable="@color/footer_button" />
|
||||
<item
|
||||
android:drawable="@color/footer_button" />
|
||||
</selector>
|
||||
|
|
9
res/drawable/footer_button.xml
Normal file
9
res/drawable/footer_button.xml
Normal file
|
@ -0,0 +1,9 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@color/footer_select" />
|
||||
<item android:state_selected="true"
|
||||
android:drawable="@color/footer_button" />
|
||||
<item
|
||||
android:drawable="@color/footer_button" />
|
||||
</selector>
|
|
@ -1,7 +1,7 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@drawable/list_detail_over" />
|
||||
android:drawable="@drawable/list_details_over" />
|
||||
<item
|
||||
android:drawable="@drawable/list_detail_default" />
|
||||
android:drawable="@drawable/list_details_default" />
|
||||
</selector>
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@drawable/numpad_eight_over" />
|
||||
android:drawable="@drawable/numpad_8" />
|
||||
<item
|
||||
android:drawable="@drawable/numpad_eight_default" />
|
||||
android:drawable="@drawable/numpad_8" />
|
||||
</selector>
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true"
|
||||
android:drawable="@drawable/switch_camera_over" />
|
||||
android:drawable="@drawable/camera_switch_over" />
|
||||
<item
|
||||
android:drawable="@drawable/switch_camera_default" />
|
||||
android:drawable="@drawable/camera_switch_default" />
|
||||
</selector>
|
||||
|
|
|
@ -124,8 +124,6 @@
|
|||
android:contentDescription="@string/content_description_dialer"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/dialer" />
|
||||
|
||||
<include layout="@layout/menu_about_chat_button" />
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/completeChat"
|
||||
|
@ -150,8 +148,6 @@
|
|||
|
||||
<include layout="@layout/menu_settings_button" />
|
||||
|
||||
<include layout="@layout/menu_about_settings_button" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
|
|
|
@ -1,30 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout
|
||||
android:id="@+id/about_chat"
|
||||
android:visibility="gone"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_weight="0.2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/image"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/content_description_about"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/about_chat" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_alignBottom="@id/image"
|
||||
android:paddingBottom="5dp"
|
||||
android:textColor="@drawable/text_color"
|
||||
android:text="@string/button_about"
|
||||
android:textSize="12sp" />
|
||||
|
||||
</RelativeLayout>
|
|
@ -1,30 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout
|
||||
android:id="@+id/about_settings"
|
||||
android:visibility="gone"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_weight="0.2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/image"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/content_description_about"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/about_settings" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_alignBottom="@id/image"
|
||||
android:paddingBottom="5dp"
|
||||
android:textColor="@drawable/text_color"
|
||||
android:text="@string/button_about"
|
||||
android:textSize="12sp" />
|
||||
|
||||
</RelativeLayout>
|
|
@ -70,7 +70,7 @@
|
|||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/content_description_add_contact"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/add_contact" />
|
||||
android:src="@drawable/add_contact_button" />
|
||||
|
||||
<org.linphone.ui.CallButton
|
||||
android:id="@+id/Call"
|
||||
|
|
|
@ -149,8 +149,7 @@
|
|||
android:contentDescription="@string/content_description_dialer"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/dialer" />
|
||||
|
||||
<include layout="@layout/menu_about_chat_button" />
|
||||
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/completeChat"
|
||||
|
@ -174,8 +173,7 @@
|
|||
</RelativeLayout>
|
||||
|
||||
<include layout="@layout/menu_settings_button" />
|
||||
|
||||
<include layout="@layout/menu_about_settings_button" />
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
|
|
@ -1,29 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout
|
||||
android:id="@+id/about_chat"
|
||||
android:visibility="gone"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_weight="0.2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/image"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/content_description_about"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/about_chat" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:textColor="@drawable/text_color"
|
||||
android:text="@string/button_about"
|
||||
android:textSize="18dp" />
|
||||
|
||||
</RelativeLayout>
|
|
@ -1,29 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout
|
||||
android:id="@+id/about_settings"
|
||||
android:visibility="gone"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_weight="0.2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/image"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/content_description_about"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/about_settings" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:textColor="@drawable/text_color"
|
||||
android:text="@string/button_about"
|
||||
android:textSize="18dp" />
|
||||
|
||||
</RelativeLayout>
|
|
@ -146,8 +146,7 @@
|
|||
android:contentDescription="@string/content_description_dialer"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/dialer" />
|
||||
|
||||
<include layout="@layout/menu_about_chat_button" />
|
||||
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/completeChat"
|
||||
|
@ -171,8 +170,7 @@
|
|||
</RelativeLayout>
|
||||
|
||||
<include layout="@layout/menu_settings_button" />
|
||||
|
||||
<include layout="@layout/menu_about_settings_button" />
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
|
|
@ -2,67 +2,89 @@
|
|||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@drawable/background">
|
||||
|
||||
<org.linphone.ui.AddressText
|
||||
android:id="@+id/Adress"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@android:color/white"
|
||||
android:background="@drawable/dialer_address_background"
|
||||
android:inputType="textEmailAddress"
|
||||
android:hint="@string/addressHint"
|
||||
android:paddingLeft="20dp"
|
||||
android:paddingRight="20dp"
|
||||
android:layout_gravity="center"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_centerHorizontal="true"/>
|
||||
android:background="@color/background">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/AddressBar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="60dp"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_marginRight="10dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:layout_alignParentTop="true">
|
||||
|
||||
<org.linphone.ui.EraseButton
|
||||
android:id="@+id/Erase"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:paddingRight="10dp"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/backspace" />
|
||||
|
||||
<org.linphone.ui.AddressText
|
||||
android:id="@+id/Address"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center"
|
||||
android:ellipsize="start"
|
||||
android:background="@color/transparent"
|
||||
android:inputType="phone"
|
||||
android:enabled="false"
|
||||
android:paddingLeft="5dp"
|
||||
android:paddingRight="5dp"
|
||||
android:layout_toLeftOf="@id/Erase"
|
||||
android:layout_centerVertical="true" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/controls"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<ImageView
|
||||
android:contentDescription="@string/content_description_add_contact"
|
||||
android:id="@+id/addContact"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitXY"
|
||||
android:layout_weight="1"
|
||||
android:src="@drawable/add_contact" />
|
||||
|
||||
android:layout_height="60dp">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/addContact"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:background="@drawable/add_contact_button"
|
||||
android:adjustViewBounds="true">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="center"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:src="@drawable/add_contact_button" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<org.linphone.ui.CallButton
|
||||
android:contentDescription="@string/content_description_call"
|
||||
android:id="@+id/Call"
|
||||
android:background="@drawable/call"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitXY"
|
||||
android:layout_weight="1"
|
||||
android:src="@drawable/call" />
|
||||
|
||||
<org.linphone.ui.EraseButton
|
||||
android:contentDescription="@string/content_description_backspace"
|
||||
android:id="@+id/Erase"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitXY"
|
||||
android:layout_weight="1"
|
||||
android:src="@drawable/backspace" />
|
||||
|
||||
</LinearLayout>
|
||||
android:scaleType="center"
|
||||
android:layout_weight="0.5"
|
||||
android:src="@drawable/call_alt_start" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<org.linphone.ui.Numpad
|
||||
android:contentDescription="@string/content_description_numpad"
|
||||
android:id="@+id/Dialer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_centerInParent="true"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_above="@id/controls"
|
||||
android:layout_below="@id/Adress" />
|
||||
|
||||
android:layout_below="@id/AddressBar" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
|
12
res/layout/drawer_list_item.xml
Normal file
12
res/layout/drawer_list_item.xml
Normal file
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@android:id/text1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:textAppearance="?android:attr/textAppearanceListItemSmall"
|
||||
android:gravity="center_vertical"
|
||||
android:paddingLeft="16dp"
|
||||
android:paddingRight="16dp"
|
||||
android:textColor="@color/text_contrast"
|
||||
android:background="?android:attr/activatedBackgroundIndicator"
|
||||
android:minHeight="?android:attr/listPreferredItemHeightSmall"/>
|
|
@ -2,7 +2,7 @@
|
|||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@drawable/background"
|
||||
android:background="@color/background"
|
||||
android:orientation="vertical" >
|
||||
|
||||
<LinearLayout
|
||||
|
|
|
@ -1,12 +1,13 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/background_splashscreen">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:src="@drawable/splashscreen_logo"
|
||||
android:src="@drawable/splashscreen"
|
||||
android:scaleType="center"/>
|
||||
|
||||
<ProgressBar
|
||||
|
|
|
@ -1,141 +1,166 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<android.support.v4.widget.DrawerLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/drawer_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
<!-- The main content view -->
|
||||
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/topLayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<!-- Hack to adjust perfectly on every screen the bottom of the fragment with the curved menu -->
|
||||
<LinearLayout
|
||||
android:id="@+id/mark"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
android:contentDescription="@string/content_description_mark"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.2"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/mark"
|
||||
android:visibility="invisible" />
|
||||
|
||||
<ImageView
|
||||
android:contentDescription="@string/content_description_mark"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.2"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/mark"
|
||||
android:visibility="invisible" />
|
||||
|
||||
<ImageView
|
||||
android:contentDescription="@string/content_description_mark"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.2"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/mark"
|
||||
android:visibility="invisible" />
|
||||
|
||||
<ImageView
|
||||
android:contentDescription="@string/content_description_mark"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.2"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/mark"
|
||||
android:visibility="invisible" />
|
||||
|
||||
<ImageView
|
||||
android:contentDescription="@string/content_description_mark"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.2"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/mark"
|
||||
android:visibility="invisible" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_above="@id/mark"
|
||||
android:layout_alignParentTop="true">
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:layout_above="@id/footer">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/fragmentContainer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="horizontal"
|
||||
android:paddingTop="40dp" />
|
||||
<include layout="@layout/status" android:id="@+id/status" />
|
||||
|
||||
<include layout="@layout/toolbar" android:id="@+id/toolbar" />
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentTop="true">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/fragmentContainer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="horizontal" />
|
||||
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<fragment
|
||||
android:id="@+id/status"
|
||||
android:name="org.linphone.StatusFragment"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
tools:layout="@layout/status" />
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/menu"
|
||||
android:id="@+id/footer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="80dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
<RelativeLayout
|
||||
android:id="@+id/history"
|
||||
android:background="@drawable/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:layout_margin="10dp"
|
||||
android:scaleType="center"
|
||||
android:contentDescription="@string/content_description_history"
|
||||
android:src="@drawable/footer_history" />
|
||||
|
||||
<RelativeLayout
|
||||
android:visibility="gone"
|
||||
android:id="@+id/history_select"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:background="@color/footer_select" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/missedCalls"
|
||||
android:layout_width="25dp"
|
||||
android:layout_height="25dp"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignParentTop="true"
|
||||
android:background="@drawable/missed_calls_bg"
|
||||
android:gravity="center"
|
||||
android:textSize="20sp"
|
||||
android:visibility="gone" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/contacts"
|
||||
android:background="@drawable/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:adjustViewBounds="true">
|
||||
|
||||
<include layout="@layout/menu_history_button" />
|
||||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="center"
|
||||
android:layout_margin="10dp"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:src="@drawable/footer_contacts" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/missedCalls"
|
||||
android:layout_width="25dp"
|
||||
android:layout_height="25dp"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignParentTop="true"
|
||||
android:background="@drawable/missed_calls_bg"
|
||||
android:gravity="center"
|
||||
android:textSize="20sp"
|
||||
android:visibility="gone" />
|
||||
</RelativeLayout>
|
||||
<RelativeLayout
|
||||
android:visibility="gone"
|
||||
android:id="@+id/contacts_select"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:background="@color/footer_select" />
|
||||
</RelativeLayout>
|
||||
|
||||
<include layout="@layout/menu_contact_button" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dialer"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitCenter"
|
||||
android:contentDescription="@string/content_description_dialer"
|
||||
android:src="@drawable/dialer" />
|
||||
|
||||
<include layout="@layout/menu_about_chat_button" />
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/completeChat"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
<RelativeLayout
|
||||
android:id="@+id/dialer"
|
||||
android:background="@drawable/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:adjustViewBounds="true">
|
||||
|
||||
<include layout="@layout/menu_chat_button" />
|
||||
<ImageView
|
||||
android:id="@+id/image"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="center"
|
||||
android:layout_margin="10dp"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:src="@drawable/footer_dialer" />
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/dialer_select"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:background="@color/footer_select" />
|
||||
</RelativeLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/chat"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:background="@drawable/footer_button"
|
||||
android:adjustViewBounds="true">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="center"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:src="@drawable/footer_chat" />
|
||||
|
||||
<RelativeLayout
|
||||
android:visibility="gone"
|
||||
android:id="@+id/chat_select"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:background="@color/footer_select" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/missedChats"
|
||||
|
@ -149,10 +174,6 @@
|
|||
android:visibility="gone" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<include layout="@layout/menu_settings_button" />
|
||||
|
||||
<include layout="@layout/menu_about_settings_button" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
@ -166,3 +187,15 @@
|
|||
</LinearLayout>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<!-- The navigation drawer -->
|
||||
<ListView android:id="@+id/left_drawer"
|
||||
android:layout_width="300dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="start"
|
||||
android:choiceMode="singleChoice"
|
||||
android:divider="@android:color/transparent"
|
||||
android:dividerHeight="0dp"
|
||||
android:background="@color/background"/>
|
||||
|
||||
</android.support.v4.widget.DrawerLayout>
|
|
@ -1,31 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout
|
||||
android:id="@+id/about_chat"
|
||||
android:visibility="gone"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/image"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/content_description_about"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/about_chat" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_alignBottom="@id/image"
|
||||
android:paddingBottom="10dp"
|
||||
android:textColor="@drawable/text_color"
|
||||
android:text="@string/button_about"
|
||||
android:textSize="12sp" />
|
||||
|
||||
</RelativeLayout>
|
|
@ -1,31 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout
|
||||
android:id="@+id/about_settings"
|
||||
android:visibility="gone"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/image"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/content_description_about"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/about_settings" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_alignBottom="@id/image"
|
||||
android:paddingBottom="10dp"
|
||||
android:textColor="@drawable/text_color"
|
||||
android:text="@string/button_about"
|
||||
android:textSize="12sp" />
|
||||
|
||||
</RelativeLayout>
|
|
@ -2,8 +2,10 @@
|
|||
<RelativeLayout
|
||||
android:id="@+id/chat"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
android:background="@color/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/image"
|
||||
|
@ -11,7 +13,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:contentDescription="@string/content_description_chat_button"
|
||||
android:src="@drawable/chat" />
|
||||
android:src="@drawable/footer_chat" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text"
|
||||
|
|
|
@ -1,10 +1,11 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout
|
||||
android:id="@+id/contacts"
|
||||
android:background="@color/footer_button"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:adjustViewBounds="true">
|
||||
|
||||
<ImageView
|
||||
|
@ -12,18 +13,16 @@
|
|||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="center"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:src="@drawable/contacts" />
|
||||
android:src="@drawable/footer_contacts" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_alignBottom="@id/image"
|
||||
android:paddingBottom="10dp"
|
||||
android:textColor="@drawable/text_color"
|
||||
android:text="@string/button_contacts"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<RelativeLayout
|
||||
android:visibility="gone"
|
||||
android:id="@+id/select"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="8dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:background="@color/footer_select" />
|
||||
</RelativeLayout>
|
|
@ -2,26 +2,28 @@
|
|||
<RelativeLayout
|
||||
android:id="@+id/history"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
android:background="@color/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:adjustViewBounds="true">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/image"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="center"
|
||||
android:contentDescription="@string/content_description_history"
|
||||
android:src="@drawable/history" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_alignBottom="@id/image"
|
||||
android:paddingBottom="10dp"
|
||||
android:textColor="@drawable/text_color"
|
||||
android:text="@string/button_history"
|
||||
android:textSize="12sp" />
|
||||
android:src="@drawable/footer_history" />
|
||||
|
||||
<RelativeLayout
|
||||
android:visibility="gone"
|
||||
android:id="@+id/select"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="8dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:background="@color/footer_select" />
|
||||
|
||||
</RelativeLayout>
|
|
@ -4,27 +4,27 @@
|
|||
android:layout_width="match_parent" android:layout_height="match_parent" android:layout_weight="1">
|
||||
|
||||
<TableRow android:layout_weight="1">
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit1" android:text="1" style="@style/DialerDigit" android:background="@drawable/numpad_one" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit2" android:text="2" style="@style/DialerDigit" android:background="@drawable/numpad_two" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit3" android:text="3" style="@style/DialerDigit" android:background="@drawable/numpad_three" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit1" android:text="1" style="@style/DialerDigit" android:background="@drawable/numpad_one" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit2" android:text="2" style="@style/DialerDigit" android:background="@drawable/numpad_two" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit3" android:text="3" style="@style/DialerDigit" android:background="@drawable/numpad_three" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
</TableRow>
|
||||
|
||||
<TableRow android:layout_weight="1">
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit4" android:text="4" style="@style/DialerDigit" android:background="@drawable/numpad_four" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit5" android:text="5" style="@style/DialerDigit" android:background="@drawable/numpad_five" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit6" android:text="6" style="@style/DialerDigit" android:background="@drawable/numpad_six" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit4" android:text="4" style="@style/DialerDigit" android:background="@drawable/numpad_four" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit5" android:text="5" style="@style/DialerDigit" android:background="@drawable/numpad_five" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit6" android:text="6" style="@style/DialerDigit" android:background="@drawable/numpad_six" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
</TableRow>
|
||||
|
||||
<TableRow android:layout_weight="1">
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit7" android:text="7" style="@style/DialerDigit" android:background="@drawable/numpad_seven" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit8" android:text="8" style="@style/DialerDigit" android:background="@drawable/numpad_eight" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit9" android:text="9" style="@style/DialerDigit" android:background="@drawable/numpad_nine" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit7" android:text="7" style="@style/DialerDigit" android:background="@drawable/numpad_seven" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit8" android:text="8" style="@style/DialerDigit" android:background="@drawable/numpad_eight" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit9" android:text="9" style="@style/DialerDigit" android:background="@drawable/numpad_nine" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
</TableRow>
|
||||
|
||||
<TableRow android:layout_weight="1">
|
||||
<org.linphone.ui.Digit android:id="@+id/DigitStar" android:text="*" style="@style/DialerDigit" android:background="@drawable/numpad_star" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit00" android:text="0+" style="@style/DialerDigit" android:background="@drawable/numpad_zero" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/DigitHash" android:text="#" style="@style/DialerDigit" android:background="@drawable/numpad_sharp" android:soundEffectsEnabled="true" />
|
||||
<org.linphone.ui.Digit android:id="@+id/DigitStar" android:text="*" style="@style/DialerDigit" android:background="@drawable/numpad_star" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
<org.linphone.ui.Digit android:id="@+id/Digit00" android:text="0+" style="@style/DialerDigit" android:background="@drawable/numpad_zero" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
<org.linphone.ui.Digit android:id="@+id/DigitHash" android:text="#" style="@style/DialerDigit" android:background="@drawable/numpad_sharp" android:soundEffectsEnabled="true" android:layout_margin="10dp"/>
|
||||
</TableRow>
|
||||
|
||||
</TableLayout>
|
||||
|
|
|
@ -105,7 +105,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:textColor="@android:color/black"
|
||||
android:contentDescription="@string/content_description_validate"
|
||||
android:background="@drawable/resizable_assistant_button_2"
|
||||
android:background="@drawable/resizable_assistant_button"
|
||||
android:text="@string/setup_apply"
|
||||
android:layout_centerVertical="true"/>
|
||||
|
||||
|
|
|
@ -85,7 +85,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:textColor="@android:color/black"
|
||||
android:contentDescription="@string/content_description_validate"
|
||||
android:background="@drawable/resizable_assistant_button_2"
|
||||
android:background="@drawable/resizable_assistant_button"
|
||||
android:text="@string/setup_apply"
|
||||
android:layout_centerVertical="true"/>
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@
|
|||
android:textColor="@android:color/black"
|
||||
android:textAllCaps="true"
|
||||
android:contentDescription="@string/setup_create_account"
|
||||
android:background="@drawable/resizable_assistant_button_2"
|
||||
android:background="@drawable/resizable_assistant_button"
|
||||
android:text="@string/setup_create_account"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
@ -55,7 +55,7 @@
|
|||
android:textAllCaps="true"
|
||||
android:textColor="@android:color/black"
|
||||
android:contentDescription="@string/setup_login_linphone"
|
||||
android:background="@drawable/resizable_assistant_button_2"
|
||||
android:background="@drawable/resizable_assistant_button"
|
||||
android:text="@string/setup_login_linphone"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
@ -74,7 +74,7 @@
|
|||
android:textColor="@android:color/black"
|
||||
android:textAllCaps="true"
|
||||
android:contentDescription="@string/setup_login_generic"
|
||||
android:background="@drawable/resizable_assistant_button_2"
|
||||
android:background="@drawable/resizable_assistant_button"
|
||||
android:text="@string/setup_login_generic"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
@ -93,7 +93,7 @@
|
|||
android:textColor="@android:color/black"
|
||||
android:textAllCaps="true"
|
||||
android:contentDescription="@string/setup_remote_provisioning"
|
||||
android:background="@drawable/resizable_assistant_button_2"
|
||||
android:background="@drawable/resizable_assistant_button"
|
||||
android:text="@string/setup_remote_provisioning"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
|
|
@ -62,7 +62,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:textColor="@android:color/black"
|
||||
android:contentDescription="@string/content_description_validate"
|
||||
android:background="@drawable/resizable_assistant_button_2"
|
||||
android:background="@drawable/resizable_assistant_button"
|
||||
android:text="@string/setup_apply"
|
||||
android:layout_centerVertical="true"/>
|
||||
|
||||
|
|
|
@ -200,7 +200,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:textColor="@android:color/black"
|
||||
android:contentDescription="@string/content_description_validate"
|
||||
android:background="@drawable/resizable_assistant_button_2"
|
||||
android:background="@drawable/resizable_assistant_button"
|
||||
android:text="@string/setup_create"
|
||||
android:layout_centerVertical="true"/>
|
||||
|
||||
|
|
|
@ -40,7 +40,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:textColor="@android:color/black"
|
||||
android:contentDescription="@string/setup_check_account_validation"
|
||||
android:background="@drawable/resizable_assistant_button_2"
|
||||
android:background="@drawable/resizable_assistant_button"
|
||||
android:text="@string/setup_create"
|
||||
android:layout_centerVertical="true"/>
|
||||
|
||||
|
|
|
@ -1,25 +1,21 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout
|
||||
xmlns:linphone="http://schemas.android.com/apk/res-auto"
|
||||
android:id="@+id/statusBar"
|
||||
android:background="@color/footer_select"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<org.linphone.ui.SlidingDrawer
|
||||
android:id="@+id/statusBar"
|
||||
linphone:direction="topToBottom"
|
||||
android:layout_height="50dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
linphone:handle="@+id/handle"
|
||||
linphone:content="@+id/content">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@id/content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
|
||||
|
||||
<TableLayout
|
||||
<!-- <TableLayout
|
||||
android:id="@+id/callStats"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
|
@ -165,42 +161,39 @@
|
|||
|
||||
</TableRow>
|
||||
|
||||
</TableLayout>
|
||||
|
||||
<ListView
|
||||
android:id="@+id/accounts"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:stackFromBottom="true"
|
||||
android:paddingBottom="10dp"
|
||||
android:background="@android:color/black"/>
|
||||
|
||||
</RelativeLayout>
|
||||
</TableLayout> -->
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@id/handle"
|
||||
android:id="@+id/handle"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginBottom="10dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/background"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/statebar_background"/>
|
||||
|
||||
<ImageView
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/menu_bar"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:scaleType="center"
|
||||
android:src="@drawable/menu"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginLeft="5dp"
|
||||
android:layout_centerInParent="true"
|
||||
android:layout_alignParentLeft="true"/>
|
||||
|
||||
<ImageView
|
||||
android:contentDescription="@string/content_description_led"
|
||||
android:id="@+id/statusLed"
|
||||
android:paddingLeft="5dp"
|
||||
android:src="@drawable/led_disconnected"
|
||||
android:src="@drawable/led_disconnected"
|
||||
android:adjustViewBounds="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_toRightOf="@+id/menu_bar"
|
||||
android:layout_toEndOf="@+id/menu_bar"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/statusText"
|
||||
android:text="@string/status_not_connected"
|
||||
android:textColor="@android:color/white"
|
||||
|
@ -256,17 +249,11 @@
|
|||
android:layout_height="match_parent"
|
||||
android:gravity="center_vertical"
|
||||
android:visibility="gone" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</org.linphone.ui.SlidingDrawer>
|
||||
|
||||
<ImageView
|
||||
android:contentDescription="@string/content_description_encryption"
|
||||
android:id="@+id/encryption"
|
||||
android:paddingRight="5dp"
|
||||
android:paddingLeft="5dp"
|
||||
android:paddingTop="5dp"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
|
@ -275,5 +262,5 @@
|
|||
android:visibility="gone"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_alignParentRight="true" />
|
||||
|
||||
|
||||
</RelativeLayout>
|
50
res/layout/toolbar.xml
Normal file
50
res/layout/toolbar.xml
Normal file
|
@ -0,0 +1,50 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/toolbar"
|
||||
android:background="@color/button_addContact"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="60dp">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/back"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="10dp"
|
||||
android:contentDescription="@string/content_description_back"
|
||||
android:src="@drawable/back" />
|
||||
</RelativeLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/toolbar_text"
|
||||
android:text="@string/setup_title"
|
||||
android:textColor="@color/footer_select"
|
||||
android:textSize="28sp"
|
||||
android:textAllCaps="true"
|
||||
android:textStyle="bold"
|
||||
android:paddingLeft="10dp"
|
||||
android:layout_centerInParent="true"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center_vertical"/>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/dialer"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentRight="true">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="10dp"
|
||||
android:contentDescription="@string/content_description_dialer"
|
||||
android:src="@drawable/dialer_back" />
|
||||
</RelativeLayout>
|
||||
|
||||
|
||||
|
||||
</RelativeLayout>
|
|
@ -1,8 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<style name="DialerDigit" parent="@android:style/TextAppearance.Medium">
|
||||
<item name="android:layout_width">fill_parent</item>
|
||||
<item name="android:layout_height">fill_parent</item>
|
||||
<item name="android:layout_width">wrap_content</item>
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:textColor">@android:color/transparent</item>
|
||||
<item name="android:textSize">20sp</item>
|
||||
<item name="android:layout_weight">1</item>
|
||||
|
|
|
@ -22,6 +22,12 @@
|
|||
<item>always</item>
|
||||
<item>auto</item>
|
||||
</string-array>
|
||||
<string-array name="params">
|
||||
<item>name</item>
|
||||
<item>about</item>
|
||||
<item>lala</item>
|
||||
<item>exit</item>
|
||||
</string-array>
|
||||
<string name="incall_notif_active">Audio call ongoing</string>
|
||||
<string name="incall_notif_paused">Paused call ongoing</string>
|
||||
<string name="incall_notif_video">Video capturing call ongoing</string>
|
||||
|
|
|
@ -33,6 +33,7 @@ import android.view.View;
|
|||
import android.view.View.OnClickListener;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.RelativeLayout;
|
||||
|
||||
/**
|
||||
* @author Sylvain Berfini
|
||||
|
@ -44,7 +45,7 @@ public class DialerFragment extends Fragment {
|
|||
public boolean mVisible;
|
||||
private AddressText mAddress;
|
||||
private CallButton mCall;
|
||||
private ImageView mAddContact;
|
||||
private RelativeLayout mAddContact;
|
||||
private OnClickListener addContactListener, cancelListener, transferListener;
|
||||
private boolean shouldEmptyAddressField = true;
|
||||
|
||||
|
@ -54,7 +55,7 @@ public class DialerFragment extends Fragment {
|
|||
instance = this;
|
||||
View view = inflater.inflate(R.layout.dialer, container, false);
|
||||
|
||||
mAddress = (AddressText) view.findViewById(R.id.Adress);
|
||||
mAddress = (AddressText) view.findViewById(R.id.Address);
|
||||
mAddress.setDialerFragment(this);
|
||||
|
||||
EraseButton erase = (EraseButton) view.findViewById(R.id.Erase);
|
||||
|
@ -69,7 +70,7 @@ public class DialerFragment extends Fragment {
|
|||
mCall.setImageResource(R.drawable.add_call);
|
||||
}
|
||||
} else {
|
||||
mCall.setImageResource(R.drawable.call);
|
||||
mCall.setImageResource(R.drawable.call_audio_start);
|
||||
}
|
||||
|
||||
AddressAware numpad = (AddressAware) view.findViewById(R.id.Dialer);
|
||||
|
@ -77,7 +78,7 @@ public class DialerFragment extends Fragment {
|
|||
numpad.setAddressWidget(mAddress);
|
||||
}
|
||||
|
||||
mAddContact = (ImageView) view.findViewById(R.id.addContact);
|
||||
mAddContact = (RelativeLayout) view.findViewById(R.id.addContact);
|
||||
|
||||
addContactListener = new OnClickListener() {
|
||||
@Override
|
||||
|
@ -165,12 +166,13 @@ public class DialerFragment extends Fragment {
|
|||
mCall.resetClickListener();
|
||||
}
|
||||
mAddContact.setEnabled(true);
|
||||
mAddContact.setImageResource(R.drawable.cancel);
|
||||
//mAddContact.setImageResource(R.drawable.cancel);
|
||||
mAddContact.setOnClickListener(cancelListener);
|
||||
} else {
|
||||
mCall.setImageResource(R.drawable.call);
|
||||
mCall.setImageResource(R.drawable.call_audio_start);
|
||||
//mCall.setAlpha(30);
|
||||
mAddContact.setEnabled(true);
|
||||
mAddContact.setImageResource(R.drawable.add_contact);
|
||||
//mAddContact.setImageResource(R.drawable.add_contact_button);
|
||||
mAddContact.setOnClickListener(addContactListener);
|
||||
enableDisableAddContact();
|
||||
}
|
||||
|
|
|
@ -53,16 +53,24 @@ import android.app.Activity;
|
|||
import android.app.Fragment;
|
||||
import android.app.FragmentManager;
|
||||
import android.app.FragmentTransaction;
|
||||
import android.app.SearchManager;
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.content.pm.ActivityInfo;
|
||||
import android.content.res.Configuration;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.BitmapFactory;
|
||||
import android.net.Uri;
|
||||
import android.os.Bundle;
|
||||
import android.support.v4.app.ActionBarDrawerToggle;
|
||||
import android.support.v4.view.GravityCompat;
|
||||
import android.view.Gravity;
|
||||
import android.view.KeyEvent;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.Menu;
|
||||
import android.view.MenuInflater;
|
||||
import android.view.MenuItem;
|
||||
import android.view.OrientationEventListener;
|
||||
import android.view.Surface;
|
||||
import android.view.View;
|
||||
|
@ -71,11 +79,17 @@ import android.view.ViewGroup;
|
|||
import android.view.WindowManager;
|
||||
import android.view.animation.AnimationUtils;
|
||||
import android.widget.AdapterView;
|
||||
import android.widget.ArrayAdapter;
|
||||
import android.widget.BaseExpandableListAdapter;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.ListView;
|
||||
import android.widget.RelativeLayout;
|
||||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
import android.support.v4.widget.DrawerLayout;
|
||||
import android.support.v4.app.ActionBarDrawerToggle;
|
||||
import android.support.v4.view.GravityCompat;
|
||||
|
||||
/**
|
||||
* @author Sylvain Berfini
|
||||
|
@ -90,11 +104,11 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
|
||||
private static LinphoneActivity instance;
|
||||
|
||||
private StatusFragment statusFragment;
|
||||
//private StatusFragment statusFragment;
|
||||
private TextView missedCalls, missedChats;
|
||||
private ImageView dialer;
|
||||
private LinearLayout menu, mark;
|
||||
private RelativeLayout contacts, history, settings, chat, aboutChat, aboutSettings;
|
||||
private RelativeLayout contacts, history, dialer, chat;
|
||||
private RelativeLayout contacts_selected, history_selected, dialer_selected, chat_selected;
|
||||
private FragmentsAvailable currentFragment, nextFragment;
|
||||
private List<FragmentsAvailable> fragmentsHistory;
|
||||
private Fragment dialerFragment, messageListFragment, friendStatusListenerFragment;
|
||||
|
@ -103,6 +117,11 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
private boolean isAnimationDisabled = false, preferLinphoneContacts = false;
|
||||
private OrientationEventListener mOrientationHelper;
|
||||
private LinphoneCoreListenerBase mListener;
|
||||
private String[] mParams;
|
||||
private String mTitle;
|
||||
private ListView mDrawerList;
|
||||
private DrawerLayout mDrawerLayout;
|
||||
private ActionBarDrawerToggle mDrawerToggle;
|
||||
|
||||
static final boolean isInstanciated() {
|
||||
return instance != null;
|
||||
|
@ -160,6 +179,9 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
setContentView(R.layout.main);
|
||||
instance = this;
|
||||
fragmentsHistory = new ArrayList<FragmentsAvailable>();
|
||||
|
||||
|
||||
createDrawer();
|
||||
initButtons();
|
||||
|
||||
currentFragment = nextFragment = FragmentsAvailable.DIALER;
|
||||
|
@ -255,6 +277,129 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
updateAnimationsState();
|
||||
}
|
||||
|
||||
public void createDrawer() {
|
||||
mTitle = "lala";
|
||||
mDrawerLayout = (DrawerLayout) findViewById(R.id.drawer_layout);
|
||||
mParams = getResources().getStringArray(R.array.params);
|
||||
mDrawerList = (ListView) findViewById(R.id.left_drawer);
|
||||
|
||||
// set a custom shadow that overlays the main content when the drawer opens
|
||||
//mDrawerLayout.setDrawerShadow(R.drawable.drawer_shadow, GravityCompat.START);
|
||||
// set up the drawer's list view with items and click listener
|
||||
mDrawerList.setAdapter(new ArrayAdapter<String>(this,
|
||||
R.layout.drawer_list_item, mParams));
|
||||
mDrawerList.setOnItemClickListener(new DrawerItemClickListener());
|
||||
|
||||
// enable ActionBar app icon to behave as action to toggle nav drawer
|
||||
//getActionBar().setDisplayHomeAsUpEnabled(true);
|
||||
//getActionBar().setHomeButtonEnabled(true);
|
||||
|
||||
// ActionBarDrawerToggle ties together the the proper interactions
|
||||
// between the sliding drawer and the action bar app icon
|
||||
mDrawerToggle = new ActionBarDrawerToggle(
|
||||
this, /* host Activity */
|
||||
mDrawerLayout, /* DrawerLayout object */
|
||||
R.drawable.menu, /* nav drawer image to replace 'Up' caret */
|
||||
R.string.menu_about, /* "open drawer" description for accessibility */
|
||||
R.string.menu_exit /* "close drawer" description for accessibility */
|
||||
) {
|
||||
public void onDrawerClosed(View view) {
|
||||
//getActionBar().setTitle(mTitle);
|
||||
//invalidateOptionsMenu(); // creates call to onPrepareOptionsMenu()
|
||||
}
|
||||
|
||||
public void onDrawerOpened(View drawerView) {
|
||||
//getActionBar().setTitle(mTitle);
|
||||
//invalidateOptionsMenu(); // creates call to onPrepareOptionsMenu()
|
||||
}
|
||||
};
|
||||
mDrawerLayout.setDrawerListener(mDrawerToggle);
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onCreateOptionsMenu(Menu menu) {
|
||||
MenuInflater inflater = getMenuInflater();
|
||||
inflater.inflate(R.menu.main, menu);
|
||||
return super.onCreateOptionsMenu(menu);
|
||||
}
|
||||
|
||||
/* Called whenever we call invalidateOptionsMenu() */
|
||||
@Override
|
||||
public boolean onPrepareOptionsMenu(Menu menu) {
|
||||
// If the nav drawer is open, hide action items related to the content view
|
||||
boolean drawerOpen = mDrawerLayout.isDrawerOpen(mDrawerList);
|
||||
menu.findItem(R.id.action_websearch).setVisible(!drawerOpen);
|
||||
return super.onPrepareOptionsMenu(menu);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onOptionsItemSelected(MenuItem item) {
|
||||
// The action bar home/up action should open or close the drawer.
|
||||
// ActionBarDrawerToggle will take care of this.
|
||||
if (mDrawerToggle.onOptionsItemSelected(item)) {
|
||||
return true;
|
||||
}
|
||||
// Handle action buttons
|
||||
switch(item.getItemId()) {
|
||||
case R.id.action_websearch:
|
||||
|
||||
return true;
|
||||
default:
|
||||
return super.onOptionsItemSelected(item);
|
||||
}
|
||||
}
|
||||
|
||||
/* The click listner for ListView in the navigation drawer */
|
||||
private class DrawerItemClickListener implements ListView.OnItemClickListener {
|
||||
@Override
|
||||
public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
|
||||
selectItem(position);
|
||||
}
|
||||
}
|
||||
|
||||
private void selectItem(int position) {
|
||||
// update the main content by replacing fragments
|
||||
/*Fragment fragment = new PlanetFragment();
|
||||
Bundle args = new Bundle();
|
||||
args.putInt(PlanetFragment.ARG_PLANET_NUMBER, position);
|
||||
fragment.setArguments(args);
|
||||
|
||||
FragmentManager fragmentManager = getFragmentManager();
|
||||
fragmentManager.beginTransaction().replace(R.id.content_frame, fragment).commit();
|
||||
|
||||
// update selected item and title, then close the drawer
|
||||
mDrawerList.setItemChecked(position, true);
|
||||
setTitle(mPlanetTitles[position]);*/
|
||||
mDrawerLayout.closeDrawer(mDrawerList);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setTitle(CharSequence title) {
|
||||
mTitle = (String) title;
|
||||
//getActionBar().setTitle(mTitle);
|
||||
}
|
||||
|
||||
/**
|
||||
* When using the ActionBarDrawerToggle, you must call it during
|
||||
* onPostCreate() and onConfigurationChanged()...
|
||||
*/
|
||||
|
||||
@Override
|
||||
protected void onPostCreate(Bundle savedInstanceState) {
|
||||
super.onPostCreate(savedInstanceState);
|
||||
// Sync the toggle state after onRestoreInstanceState has occurred.
|
||||
mDrawerToggle.syncState();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onConfigurationChanged(Configuration newConfig) {
|
||||
super.onConfigurationChanged(newConfig);
|
||||
// Pass any configuration change to the drawer toggls
|
||||
mDrawerToggle.onConfigurationChanged(newConfig);
|
||||
}
|
||||
|
||||
|
||||
private void initButtons() {
|
||||
menu = (LinearLayout) findViewById(R.id.menu);
|
||||
|
@ -264,27 +409,24 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
history.setOnClickListener(this);
|
||||
contacts = (RelativeLayout) findViewById(R.id.contacts);
|
||||
contacts.setOnClickListener(this);
|
||||
dialer = (ImageView) findViewById(R.id.dialer);
|
||||
dialer = (RelativeLayout) findViewById(R.id.dialer);
|
||||
dialer.setOnClickListener(this);
|
||||
settings = (RelativeLayout) findViewById(R.id.settings);
|
||||
settings.setOnClickListener(this);
|
||||
chat = (RelativeLayout) findViewById(R.id.chat);
|
||||
chat.setOnClickListener(this);
|
||||
aboutChat = (RelativeLayout) findViewById(R.id.about_chat);
|
||||
aboutSettings = (RelativeLayout) findViewById(R.id.about_settings);
|
||||
|
||||
history_selected = (RelativeLayout) findViewById(R.id.history_select);
|
||||
contacts_selected = (RelativeLayout) findViewById(R.id.contacts_select);
|
||||
dialer_selected = (RelativeLayout) findViewById(R.id.dialer_select);
|
||||
chat_selected = (RelativeLayout) findViewById(R.id.chat_select);
|
||||
|
||||
if (getResources().getBoolean(R.bool.replace_chat_by_about)) {
|
||||
chat.setVisibility(View.GONE);
|
||||
chat.setOnClickListener(null);
|
||||
findViewById(R.id.completeChat).setVisibility(View.GONE);
|
||||
aboutChat.setVisibility(View.VISIBLE);
|
||||
aboutChat.setOnClickListener(this);
|
||||
}
|
||||
if (getResources().getBoolean(R.bool.replace_settings_by_about)) {
|
||||
settings.setVisibility(View.GONE);
|
||||
settings.setOnClickListener(null);
|
||||
aboutSettings.setVisibility(View.VISIBLE);
|
||||
aboutSettings.setOnClickListener(this);
|
||||
//settings.setVisibility(View.GONE);
|
||||
//settings.setOnClickListener(null);
|
||||
}
|
||||
|
||||
missedCalls = (TextView) findViewById(R.id.missedCalls);
|
||||
|
@ -300,7 +442,7 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
return;
|
||||
}
|
||||
|
||||
findViewById(R.id.status).setVisibility(View.GONE);
|
||||
//findViewById(R.id.status).setVisibility(View.GONE);
|
||||
findViewById(R.id.fragmentContainer).setPadding(0, 0, 0, 0);
|
||||
}
|
||||
|
||||
|
@ -309,12 +451,12 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
return;
|
||||
}
|
||||
|
||||
if (statusFragment != null && !statusFragment.isVisible()) {
|
||||
/*if (statusFragment != null && !statusFragment.isVisible()) {
|
||||
// Hack to ensure statusFragment is visible after coming back to
|
||||
// dialer from chat
|
||||
statusFragment.getView().setVisibility(View.VISIBLE);
|
||||
}
|
||||
findViewById(R.id.status).setVisibility(View.VISIBLE);
|
||||
}*/
|
||||
//findViewById(R.id.status).setVisibility(View.VISIBLE);
|
||||
findViewById(R.id.fragmentContainer).setPadding(0, LinphoneUtils.pixelsToDpi(getResources(), 40), 0, 0);
|
||||
}
|
||||
|
||||
|
@ -415,9 +557,9 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
}
|
||||
|
||||
private void changeFragment(Fragment newFragment, FragmentsAvailable newFragmentType, boolean withoutAnimation) {
|
||||
if (statusFragment != null) {
|
||||
/*if (statusFragment != null) {
|
||||
statusFragment.closeStatusBar();
|
||||
}
|
||||
}*/
|
||||
|
||||
FragmentTransaction transaction = getFragmentManager().beginTransaction();
|
||||
|
||||
|
@ -458,9 +600,9 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
// hideStatusBar();
|
||||
// }
|
||||
// }
|
||||
if (statusFragment != null) {
|
||||
/*if (statusFragment != null) {
|
||||
statusFragment.closeStatusBar();
|
||||
}
|
||||
}*/
|
||||
|
||||
LinearLayout ll = (LinearLayout) findViewById(R.id.fragmentContainer2);
|
||||
|
||||
|
@ -599,7 +741,7 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
|
||||
public void displayAbout() {
|
||||
changeCurrentFragment(FragmentsAvailable.ABOUT, null);
|
||||
settings.setSelected(true);
|
||||
//settings.setSelected(true);
|
||||
}
|
||||
|
||||
public boolean displayChatMessageNotification(String address){
|
||||
|
@ -680,42 +822,26 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
|
||||
if (id == R.id.history) {
|
||||
changeCurrentFragment(FragmentsAvailable.HISTORY, null);
|
||||
history.setSelected(true);
|
||||
history_selected.setVisibility(View.VISIBLE);
|
||||
LinphoneManager.getLc().resetMissedCallsCount();
|
||||
displayMissedCalls(0);
|
||||
} else if (id == R.id.contacts) {
|
||||
changeCurrentFragment(FragmentsAvailable.CONTACTS, null);
|
||||
contacts.setSelected(true);
|
||||
contacts_selected.setVisibility(View.VISIBLE);
|
||||
} else if (id == R.id.dialer) {
|
||||
changeCurrentFragment(FragmentsAvailable.DIALER, null);
|
||||
dialer.setSelected(true);
|
||||
} else if (id == R.id.settings) {
|
||||
changeCurrentFragment(FragmentsAvailable.SETTINGS, null);
|
||||
settings.setSelected(true);
|
||||
} else if (id == R.id.about_chat) {
|
||||
Bundle b = new Bundle();
|
||||
b.putSerializable("About", FragmentsAvailable.ABOUT_INSTEAD_OF_CHAT);
|
||||
changeCurrentFragment(FragmentsAvailable.ABOUT_INSTEAD_OF_CHAT, b);
|
||||
aboutChat.setSelected(true);
|
||||
} else if (id == R.id.about_settings) {
|
||||
Bundle b = new Bundle();
|
||||
b.putSerializable("About", FragmentsAvailable.ABOUT_INSTEAD_OF_SETTINGS);
|
||||
changeCurrentFragment(FragmentsAvailable.ABOUT_INSTEAD_OF_SETTINGS, b);
|
||||
aboutSettings.setSelected(true);
|
||||
dialer_selected.setVisibility(View.VISIBLE);
|
||||
} else if (id == R.id.chat) {
|
||||
changeCurrentFragment(FragmentsAvailable.CHATLIST, null);
|
||||
chat.setSelected(true);
|
||||
chat_selected.setVisibility(View.VISIBLE);
|
||||
}
|
||||
}
|
||||
|
||||
private void resetSelection() {
|
||||
history.setSelected(false);
|
||||
contacts.setSelected(false);
|
||||
dialer.setSelected(false);
|
||||
settings.setSelected(false);
|
||||
chat.setSelected(false);
|
||||
aboutChat.setSelected(false);
|
||||
aboutSettings.setSelected(false);
|
||||
history_selected.setVisibility(View.GONE);
|
||||
contacts_selected.setVisibility(View.GONE);
|
||||
dialer_selected.setVisibility(View.GONE);
|
||||
chat_selected.setVisibility(View.GONE);
|
||||
}
|
||||
|
||||
@SuppressWarnings("incomplete-switch")
|
||||
|
@ -726,29 +852,27 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
switch (menuToSelect) {
|
||||
case HISTORY:
|
||||
case HISTORY_DETAIL:
|
||||
history.setSelected(true);
|
||||
history_selected.setVisibility(View.VISIBLE);
|
||||
break;
|
||||
case CONTACTS:
|
||||
case CONTACT:
|
||||
case EDIT_CONTACT:
|
||||
contacts.setSelected(true);
|
||||
contacts_selected.setVisibility(View.VISIBLE);
|
||||
break;
|
||||
case DIALER:
|
||||
dialer.setSelected(true);
|
||||
dialer_selected.setVisibility(View.VISIBLE);
|
||||
break;
|
||||
case SETTINGS:
|
||||
case ACCOUNT_SETTINGS:
|
||||
settings.setSelected(true);
|
||||
//settings.setSelected(true);
|
||||
break;
|
||||
case ABOUT_INSTEAD_OF_CHAT:
|
||||
aboutChat.setSelected(true);
|
||||
break;
|
||||
case ABOUT_INSTEAD_OF_SETTINGS:
|
||||
aboutSettings.setSelected(true);
|
||||
break;
|
||||
case CHATLIST:
|
||||
case CHAT:
|
||||
chat.setSelected(true);
|
||||
chat_selected.setVisibility(View.VISIBLE);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -773,12 +897,12 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
}
|
||||
|
||||
public void updateStatusFragment(StatusFragment fragment) {
|
||||
statusFragment = fragment;
|
||||
//statusFragment = fragment;
|
||||
}
|
||||
|
||||
public void displaySettings() {
|
||||
changeCurrentFragment(FragmentsAvailable.SETTINGS, null);
|
||||
settings.setSelected(true);
|
||||
//settings.setSelected(true);
|
||||
}
|
||||
|
||||
public void applyConfigChangesIfNeeded() {
|
||||
|
@ -791,11 +915,12 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
Bundle bundle = new Bundle();
|
||||
bundle.putInt("Account", accountNumber);
|
||||
changeCurrentFragment(FragmentsAvailable.ACCOUNT_SETTINGS, bundle);
|
||||
settings.setSelected(true);
|
||||
//settings.setSelected(true);
|
||||
}
|
||||
|
||||
public StatusFragment getStatusFragment() {
|
||||
return statusFragment;
|
||||
//return statusFragment;
|
||||
return null;
|
||||
}
|
||||
|
||||
public List<String> getChatList() {
|
||||
|
@ -1244,11 +1369,11 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
}
|
||||
}
|
||||
}
|
||||
} else if (keyCode == KeyEvent.KEYCODE_MENU && statusFragment != null) {
|
||||
} /*else if (keyCode == KeyEvent.KEYCODE_MENU && statusFragment != null) {
|
||||
if (event.getRepeatCount() < 1) {
|
||||
statusFragment.openOrCloseStatusBar(true);
|
||||
}
|
||||
}
|
||||
}*/
|
||||
return super.onKeyDown(keyCode, event);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -63,9 +63,6 @@ public class StatusFragment extends Fragment {
|
|||
private Handler refreshHandler = new Handler();
|
||||
private TextView statusText, exit, voicemailCount;
|
||||
private ImageView statusLed, callQuality, encryption, background;
|
||||
private ListView sliderContentAccounts;
|
||||
private TableLayout callStats;
|
||||
private SlidingDrawer drawer;
|
||||
// private LinearLayout allAccountsLed;
|
||||
private Runnable mCallQualityUpdater;
|
||||
private boolean isInCall, isAttached = false;
|
||||
|
@ -84,17 +81,6 @@ public class StatusFragment extends Fragment {
|
|||
encryption = (ImageView) view.findViewById(R.id.encryption);
|
||||
background = (ImageView) view.findViewById(R.id.background);
|
||||
// allAccountsLed = (LinearLayout) view.findViewById(R.id.moreStatusLed);
|
||||
callStats = (TableLayout) view.findViewById(R.id.callStats);
|
||||
|
||||
drawer = (SlidingDrawer) view.findViewById(R.id.statusBar);
|
||||
drawer.setOnDrawerOpenListener(new OnDrawerOpenListener() {
|
||||
@Override
|
||||
public void onDrawerOpened() {
|
||||
populateSliderContent();
|
||||
}
|
||||
});
|
||||
|
||||
sliderContentAccounts = (ListView) view.findViewById(R.id.accounts);
|
||||
|
||||
voicemailCount = (TextView) view.findViewById(R.id.voicemailCount);
|
||||
|
||||
|
@ -134,8 +120,6 @@ public class StatusFragment extends Fragment {
|
|||
});
|
||||
}
|
||||
// setMiniLedsForEachAccount();
|
||||
populateSliderContent();
|
||||
sliderContentAccounts.invalidate();
|
||||
} catch (IllegalStateException ise) {}
|
||||
}
|
||||
|
||||
|
@ -203,41 +187,24 @@ public class StatusFragment extends Fragment {
|
|||
if (getResources().getBoolean(R.bool.lock_statusbar) && !force) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (getResources().getBoolean(R.bool.disable_animations)) {
|
||||
drawer.toggle();
|
||||
} else {
|
||||
drawer.animateToggle();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public void closeStatusBar() {
|
||||
if (getResources().getBoolean(R.bool.lock_statusbar)) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (getResources().getBoolean(R.bool.disable_animations)) {
|
||||
drawer.close();
|
||||
} else {
|
||||
drawer.animateClose();
|
||||
}
|
||||
}
|
||||
|
||||
private void populateSliderContent() {
|
||||
if (LinphoneManager.isInstanciated() && LinphoneManager.getLc() != null) {
|
||||
sliderContentAccounts.setVisibility(View.GONE);
|
||||
callStats.setVisibility(View.GONE);
|
||||
voicemailCount.setVisibility(View.GONE);
|
||||
|
||||
if (isInCall && isAttached && getResources().getBoolean(R.bool.display_call_stats)) {
|
||||
callStats.setVisibility(View.VISIBLE);
|
||||
LinphoneCall call = LinphoneManager.getLc().getCurrentCall();
|
||||
initCallStatsRefresher(call, callStats);
|
||||
//initCallStatsRefresher(call, callStats);
|
||||
} else if (!isInCall) {
|
||||
voicemailCount.setVisibility(View.VISIBLE);
|
||||
sliderContentAccounts.setVisibility(View.VISIBLE);
|
||||
AccountsListAdapter adapter = new AccountsListAdapter();
|
||||
sliderContentAccounts.setAdapter(adapter);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -378,12 +345,7 @@ public class StatusFragment extends Fragment {
|
|||
encryption.setVisibility(View.GONE);
|
||||
if (getResources().getBoolean(R.bool.exit_button_on_dialer))
|
||||
exit.setVisibility(View.VISIBLE);
|
||||
|
||||
if (drawer != null && getResources().getBoolean(R.bool.lock_statusbar)) {
|
||||
drawer.lock();
|
||||
} else if (drawer != null) {
|
||||
drawer.unlock();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue