Improved code related to top bar in some views

This commit is contained in:
Sylvain Berfini 2018-11-23 18:09:34 +01:00
parent f7c2f01a31
commit 92b33ef71c
8 changed files with 1035 additions and 1059 deletions

View file

@ -136,7 +136,8 @@ public class LinphoneActivity extends LinphoneGenericActivity implements OnClick
private TextView missedCalls, missedChats; private TextView missedCalls, missedChats;
private RelativeLayout contacts, history, dialer, chat; private RelativeLayout contacts, history, dialer, chat;
private View contacts_selected, history_selected, dialer_selected, chat_selected; private View contacts_selected, history_selected, dialer_selected, chat_selected;
private RelativeLayout mTopBar; private LinearLayout mTopBar;
private TextView mTopBarTitle;
private ImageView cancel; private ImageView cancel;
private FragmentsAvailable pendingFragmentTransaction, currentFragment, leftFragment; private FragmentsAvailable pendingFragmentTransaction, currentFragment, leftFragment;
private Fragment fragment; private Fragment fragment;
@ -303,6 +304,7 @@ public class LinphoneActivity extends LinphoneGenericActivity implements OnClick
private void initButtons() { private void initButtons() {
mTabBar = findViewById(R.id.footer); mTabBar = findViewById(R.id.footer);
mTopBar = findViewById(R.id.top_bar); mTopBar = findViewById(R.id.top_bar);
mTopBarTitle = findViewById(R.id.top_bar_title);
cancel = findViewById(R.id.cancel); cancel = findViewById(R.id.cancel);
cancel.setOnClickListener(this); cancel.setOnClickListener(this);
@ -847,6 +849,16 @@ public class LinphoneActivity extends LinphoneGenericActivity implements OnClick
public void hideTopBar() { public void hideTopBar() {
mTopBar.setVisibility(View.GONE); mTopBar.setVisibility(View.GONE);
mTopBarTitle.setText("");
}
public void showTopBar() {
mTopBar.setVisibility(View.VISIBLE);
}
public void showTopBarWithTitle(String title) {
showTopBar();
mTopBarTitle.setText(title);
} }
@SuppressWarnings("incomplete-switch") @SuppressWarnings("incomplete-switch")
@ -880,9 +892,10 @@ public class LinphoneActivity extends LinphoneGenericActivity implements OnClick
case SETTINGS: case SETTINGS:
case ACCOUNT_SETTINGS: case ACCOUNT_SETTINGS:
hideTabBar(hideBottomBar); hideTabBar(hideBottomBar);
mTopBar.setVisibility(View.VISIBLE); showTopBarWithTitle(getString(R.string.settings));
break; break;
case ABOUT: case ABOUT:
showTopBarWithTitle(getString(R.string.about));
hideTabBar(hideBottomBar); hideTabBar(hideBottomBar);
break; break;
case CHAT_LIST: case CHAT_LIST:

View file

@ -48,7 +48,6 @@ import org.linphone.mediastream.Log;
public class AboutFragment extends Fragment implements OnClickListener { public class AboutFragment extends Fragment implements OnClickListener {
View sendLogButton = null; View sendLogButton = null;
View resetLogButton = null; View resetLogButton = null;
ImageView cancel;
CoreListenerStub mListener; CoreListenerStub mListener;
private ProgressDialog progress; private ProgressDialog progress;
private boolean uploadInProgress; private boolean uploadInProgress;
@ -62,9 +61,6 @@ public class AboutFragment extends Fragment implements OnClickListener {
aboutLiblinphoneVersion.setText(String.format(getString(R.string.about_liblinphone_version), LinphoneManager.getLc().getVersion())); aboutLiblinphoneVersion.setText(String.format(getString(R.string.about_liblinphone_version), LinphoneManager.getLc().getVersion()));
aboutVersion.setText(String.format(getString(R.string.about_version), BuildConfig.VERSION_NAME)); aboutVersion.setText(String.format(getString(R.string.about_version), BuildConfig.VERSION_NAME));
cancel = view.findViewById(R.id.cancel);
cancel.setOnClickListener(this);
sendLogButton = view.findViewById(R.id.send_log); sendLogButton = view.findViewById(R.id.send_log);
sendLogButton.setOnClickListener(this); sendLogButton.setOnClickListener(this);
sendLogButton.setVisibility(LinphonePreferences.instance().isDebugEnabled() ? View.VISIBLE : View.GONE); sendLogButton.setVisibility(LinphonePreferences.instance().isDebugEnabled() ? View.VISIBLE : View.GONE);
@ -162,8 +158,6 @@ public class AboutFragment extends Fragment implements OnClickListener {
if (lc != null) { if (lc != null) {
lc.resetLogCollection(); lc.resetLogCollection();
} }
} else if (v == cancel) {
LinphoneActivity.instance().goToDialerFragment();
} }
} }
} }

View file

@ -1,42 +1,8 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:orientation="vertical"> android:orientation="vertical">
<LinearLayout
android:id="@+id/top_bar"
android:orientation="horizontal"
android:background="@color/colorF"
android:layout_width="match_parent"
android:layout_height="60dp">
<View
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"/>
<TextView
android:id="@+id/menu_name"
android:text="@string/about"
style="@style/font1"
android:maxLines="1"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.4"
android:gravity="center"
android:padding="15dp"/>
<ImageView
android:id="@+id/cancel"
android:src="@drawable/dialer_back"
android:background="@drawable/toolbar_button"
android:contentDescription="@string/content_description_dialer_back"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"
android:padding="15dp"/>
</LinearLayout>
<LinearLayout <LinearLayout
android:baselineAligned="false" android:baselineAligned="false"

View file

@ -1,292 +1,301 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<RelativeLayout <RelativeLayout
xmlns:tools="http://schemas.android.com/tools" xmlns:tools="http://schemas.android.com/tools"
xmlns:android="http://schemas.android.com/apk/res/android" xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<fragment <fragment
android:id="@+id/status" android:id="@+id/status"
android:name="org.linphone.fragments.StatusFragment" android:name="org.linphone.fragments.StatusFragment"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="35dp" android:layout_height="35dp"
tools:layout="@layout/status" /> tools:layout="@layout/status" />
<android.support.v4.widget.DrawerLayout <android.support.v4.widget.DrawerLayout
android:id="@+id/side_menu" android:id="@+id/side_menu"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_below="@id/status"> android:layout_below="@id/status">
<RelativeLayout <RelativeLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<RelativeLayout <LinearLayout
android:id="@+id/top_bar" android:id="@+id/top_bar"
android:background="@color/colorF" android:visibility="gone"
android:layout_width="match_parent" android:orientation="horizontal"
android:layout_height="60dp" android:background="@color/colorF"
android:visibility="gone" android:layout_width="match_parent"
android:layout_alignParentTop="true"> android:layout_height="60dp">
<TextView <ImageView
android:id="@+id/menu_name" android:id="@+id/cancel"
android:text="@string/settings" android:src="@drawable/back"
style="@style/font1" android:background="@drawable/toolbar_button"
android:layout_width="wrap_content" android:contentDescription="@string/content_description_dialer_back"
android:layout_height="match_parent" android:layout_width="0dp"
android:layout_centerInParent="true" android:layout_height="match_parent"
android:gravity="center_vertical"/> android:layout_weight="0.2"
android:padding="15dp"/>
<ImageView <TextView
android:id="@+id/cancel" android:id="@+id/top_bar_title"
android:src="@drawable/dialer_back" style="@style/font1"
android:contentDescription="@string/content_description_dialer_back" android:maxLines="1"
android:layout_width="wrap_content" android:layout_width="0dp"
android:layout_height="match_parent" android:layout_height="match_parent"
android:padding="15dp" android:layout_weight="0.4"
android:layout_centerInParent="true" android:gravity="center"
android:layout_alignParentRight="true"/> android:padding="15dp"/>
</RelativeLayout> <View
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"/>
<LinearLayout </LinearLayout>
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:layout_below="@id/top_bar"
android:layout_toRightOf="@+id/footer">
<FrameLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_alignParentTop="true"> android:orientation="vertical"
android:layout_below="@id/top_bar"
android:layout_toRightOf="@+id/footer">
<LinearLayout <FrameLayout
android:id="@+id/fragmentContainer" android:layout_width="match_parent"
android:layout_width="match_parent" android:layout_height="match_parent"
android:layout_height="match_parent" android:layout_alignParentTop="true">
android:orientation="horizontal" />
</FrameLayout>
</LinearLayout> <LinearLayout
android:id="@+id/fragmentContainer"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal" />
</FrameLayout>
<LinearLayout </LinearLayout>
android:id="@+id/footer"
android:layout_width="60dp"
android:layout_height="match_parent"
android:layout_alignParentBottom="true"
android:orientation="vertical">
<RelativeLayout <LinearLayout
android:id="@+id/history" android:id="@+id/footer"
android:background="@drawable/footer_button" android:layout_width="60dp"
android:layout_weight="1" android:layout_height="match_parent"
android:layout_width="60dp" android:layout_alignParentBottom="true"
android:layout_height="0dp"> android:orientation="vertical">
<ImageView <RelativeLayout
android:src="@drawable/footer_history" android:id="@+id/history"
android:contentDescription="@string/content_description_history" android:background="@drawable/footer_button"
android:layout_width="wrap_content" android:layout_weight="1"
android:layout_height="wrap_content" android:layout_width="60dp"
android:padding="15dp" android:layout_height="0dp">
android:layout_centerInParent="true"/>
<View <ImageView
android:id="@+id/history_select" android:src="@drawable/footer_history"
android:background="@color/colorA" android:contentDescription="@string/content_description_history"
android:layout_width="5dp" android:layout_width="wrap_content"
android:layout_height="match_parent" android:layout_height="wrap_content"
android:layout_alignParentLeft="true" android:padding="15dp"
android:visibility="gone"/> android:layout_centerInParent="true"/>
<TextView <View
android:id="@+id/missed_calls" android:id="@+id/history_select"
android:background="@drawable/unread_message_count_bg" android:background="@color/colorA"
style="@style/font18" android:layout_width="5dp"
android:layout_width="wrap_content" android:layout_height="match_parent"
android:layout_height="wrap_content" android:layout_alignParentLeft="true"
android:gravity="center" android:visibility="gone"/>
android:visibility="gone"
android:layout_marginTop="15dp"
android:layout_marginRight="5dp"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"/>
</RelativeLayout> <TextView
android:id="@+id/missed_calls"
android:background="@drawable/unread_message_count_bg"
style="@style/font18"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center"
android:visibility="gone"
android:layout_marginTop="15dp"
android:layout_marginRight="5dp"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"/>
<RelativeLayout </RelativeLayout>
android:id="@+id/contacts"
android:background="@drawable/footer_button"
android:layout_weight="1"
android:layout_width="60dp"
android:layout_height="0dp">
<ImageView <RelativeLayout
android:src="@drawable/footer_contacts" android:id="@+id/contacts"
android:contentDescription="@string/content_description_contacts" android:background="@drawable/footer_button"
android:layout_width="match_parent" android:layout_weight="1"
android:layout_height="wrap_content" android:layout_width="60dp"
android:padding="15dp" android:layout_height="0dp">
android:layout_centerInParent="true"/>
<View <ImageView
android:id="@+id/contacts_select" android:src="@drawable/footer_contacts"
android:background="@color/colorA" android:contentDescription="@string/content_description_contacts"
android:layout_width="5dp" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="wrap_content"
android:layout_alignParentLeft="true" android:padding="15dp"
android:visibility="gone"/> android:layout_centerInParent="true"/>
</RelativeLayout>
<RelativeLayout <View
android:id="@+id/dialer" android:id="@+id/contacts_select"
android:background="@drawable/footer_button" android:background="@color/colorA"
android:layout_weight="1" android:layout_width="5dp"
android:layout_width="60dp" android:layout_height="match_parent"
android:layout_height="0dp"> android:layout_alignParentLeft="true"
android:visibility="gone"/>
</RelativeLayout>
<ImageView <RelativeLayout
android:src="@drawable/footer_dialer" android:id="@+id/dialer"
android:contentDescription="@string/content_description_dialer" android:background="@drawable/footer_button"
android:layout_width="match_parent" android:layout_weight="1"
android:layout_height="wrap_content" android:layout_width="60dp"
android:padding="15dp" android:layout_height="0dp">
android:layout_centerInParent="true"/>
<View <ImageView
android:id="@+id/dialer_select" android:src="@drawable/footer_dialer"
android:background="@color/colorA" android:contentDescription="@string/content_description_dialer"
android:layout_width="5dp" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="wrap_content"
android:layout_alignParentLeft="true"/> android:padding="15dp"
android:layout_centerInParent="true"/>
</RelativeLayout> <View
android:id="@+id/dialer_select"
android:background="@color/colorA"
android:layout_width="5dp"
android:layout_height="match_parent"
android:layout_alignParentLeft="true"/>
<RelativeLayout </RelativeLayout>
android:id="@+id/chat"
android:background="@drawable/footer_button"
android:layout_weight="1"
android:layout_width="60dp"
android:layout_height="0dp">
<ImageView <RelativeLayout
android:src="@drawable/footer_chat" android:id="@+id/chat"
android:contentDescription="@string/content_description_chat_button" android:background="@drawable/footer_button"
android:layout_width="match_parent" android:layout_weight="1"
android:layout_height="wrap_content" android:layout_width="60dp"
android:padding="15dp" android:layout_height="0dp">
android:layout_centerInParent="true" />
<View <ImageView
android:id="@+id/chat_select" android:src="@drawable/footer_chat"
android:background="@color/colorA" android:contentDescription="@string/content_description_chat_button"
android:visibility="gone" android:layout_width="match_parent"
android:layout_width="5dp" android:layout_height="wrap_content"
android:layout_height="match_parent" android:padding="15dp"
android:layout_alignParentLeft="true"/> android:layout_centerInParent="true" />
<TextView <View
android:id="@+id/missed_chats" android:id="@+id/chat_select"
android:background="@drawable/unread_message_count_bg" android:background="@color/colorA"
style="@style/font18" android:visibility="gone"
android:layout_width="wrap_content" android:layout_width="5dp"
android:layout_height="wrap_content" android:layout_height="match_parent"
android:gravity="center" android:layout_alignParentLeft="true"/>
android:visibility="gone"
android:layout_marginTop="15dp"
android:layout_marginRight="5dp"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"/>
</RelativeLayout> <TextView
</LinearLayout> android:id="@+id/missed_chats"
android:background="@drawable/unread_message_count_bg"
style="@style/font18"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center"
android:visibility="gone"
android:layout_marginTop="15dp"
android:layout_marginRight="5dp"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"/>
<LinearLayout </RelativeLayout>
android:id="@+id/fragmentContainer2"
android:visibility="gone"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
</LinearLayout> </LinearLayout>
</RelativeLayout>
<!-- Side Menu --> <LinearLayout
<RelativeLayout android:id="@+id/fragmentContainer2"
android:id="@+id/side_menu_content" android:visibility="gone"
android:layout_width="match_parent" android:layout_width="wrap_content"
android:layout_height="match_parent" android:layout_height="wrap_content"
android:layout_gravity="left"> android:orientation="vertical">
<RelativeLayout </LinearLayout>
android:id="@+id/side_menu_quit"
android:background="@color/colorA"
android:gravity="bottom"
android:layout_alignParentBottom="true"
android:layout_width="match_parent"
android:layout_height="50dp">
<ImageView </RelativeLayout>
android:id="@+id/quit_button"
android:src="@drawable/quit"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<TextView <!-- Side Menu -->
android:id="@+id/quit" <RelativeLayout
android:text="@string/quit" android:id="@+id/side_menu_content"
style="@style/font14" android:layout_width="match_parent"
android:layout_width="wrap_content" android:layout_height="match_parent"
android:layout_height="wrap_content" android:layout_gravity="left">
android:layout_toRightOf="@id/quit_button"
android:gravity="center_vertical"
android:layout_centerInParent="true"/>
</RelativeLayout>
<LinearLayout <RelativeLayout
android:layout_width="match_parent" android:id="@+id/side_menu_quit"
android:layout_height="match_parent" android:background="@color/colorA"
android:background="@color/colorH" android:gravity="bottom"
android:layout_above="@id/side_menu_quit" android:layout_alignParentBottom="true"
android:orientation="vertical"> android:layout_width="match_parent"
android:layout_height="50dp">
<include layout="@layout/side_menu_main_account"/> <ImageView
android:id="@+id/quit_button"
android:src="@drawable/quit"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<ListView <TextView
android:id="@+id/accounts_list" android:id="@+id/quit"
android:background="@color/colorH" android:text="@string/quit"
android:layout_width="match_parent" style="@style/font14"
android:layout_height="wrap_content" android:layout_width="wrap_content"
android:choiceMode="singleChoice" android:layout_height="wrap_content"
android:cacheColorHint="@color/transparent" android:layout_toRightOf="@id/quit_button"
android:divider="@android:color/transparent" android:gravity="center_vertical"
android:dividerHeight="0dp"/> android:layout_centerInParent="true"/>
</RelativeLayout>
<ListView <LinearLayout
android:id="@+id/item_list" android:layout_width="match_parent"
android:background="@color/colorH" android:layout_height="match_parent"
android:layout_width="match_parent" android:background="@color/colorH"
android:layout_height="wrap_content" android:layout_above="@id/side_menu_quit"
android:choiceMode="singleChoice" android:orientation="vertical">
android:divider="@color/colorE"
android:listSelector="@color/colorH"
android:footerDividersEnabled="true"
android:dividerHeight="1dp"/>
<View <include layout="@layout/side_menu_main_account"/>
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="@color/colorE"/>
</LinearLayout> <ListView
</RelativeLayout> android:id="@+id/accounts_list"
android:background="@color/colorH"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:choiceMode="singleChoice"
android:cacheColorHint="@color/transparent"
android:divider="@android:color/transparent"
android:dividerHeight="0dp"/>
</android.support.v4.widget.DrawerLayout> <ListView
android:id="@+id/item_list"
android:background="@color/colorH"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:choiceMode="singleChoice"
android:divider="@color/colorE"
android:listSelector="@color/colorH"
android:footerDividersEnabled="true"
android:dividerHeight="1dp"/>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="@color/colorE"/>
</LinearLayout>
</RelativeLayout>
</android.support.v4.widget.DrawerLayout>
</RelativeLayout> </RelativeLayout>

View file

@ -1,297 +1,306 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<RelativeLayout <RelativeLayout
xmlns:tools="http://schemas.android.com/tools" xmlns:tools="http://schemas.android.com/tools"
xmlns:android="http://schemas.android.com/apk/res/android" xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<fragment <fragment
android:id="@+id/status" android:id="@+id/status"
android:name="org.linphone.fragments.StatusFragment" android:name="org.linphone.fragments.StatusFragment"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="35dp" android:layout_height="35dp"
tools:layout="@layout/status" /> tools:layout="@layout/status" />
<android.support.v4.widget.DrawerLayout <android.support.v4.widget.DrawerLayout
android:id="@+id/side_menu" android:id="@+id/side_menu"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_below="@id/status"> android:layout_below="@id/status">
<RelativeLayout <RelativeLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<RelativeLayout <LinearLayout
android:id="@+id/top_bar" android:id="@+id/top_bar"
android:background="@color/colorF" android:visibility="gone"
android:layout_width="match_parent" android:orientation="horizontal"
android:layout_height="60dp" android:background="@color/colorF"
android:visibility="gone" android:layout_width="match_parent"
android:layout_alignParentTop="true"> android:layout_height="60dp">
<TextView <ImageView
android:id="@+id/menu_name" android:id="@+id/cancel"
android:text="@string/settings" android:src="@drawable/back"
style="@style/font1" android:background="@drawable/toolbar_button"
android:layout_width="wrap_content" android:contentDescription="@string/content_description_dialer_back"
android:layout_height="match_parent" android:layout_width="0dp"
android:layout_centerInParent="true" android:layout_height="match_parent"
android:gravity="center_vertical"/> android:layout_weight="0.2"
android:padding="15dp"/>
<ImageView <TextView
android:id="@+id/cancel" android:id="@+id/top_bar_title"
android:src="@drawable/dialer_back" style="@style/font1"
android:contentDescription="@string/content_description_dialer_back" android:maxLines="1"
android:layout_width="wrap_content" android:layout_width="0dp"
android:layout_height="match_parent" android:layout_height="match_parent"
android:padding="15dp" android:layout_weight="0.4"
android:layout_centerInParent="true" android:gravity="center"
android:layout_alignParentRight="true"/> android:padding="15dp"/>
</RelativeLayout> <View
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"/>
<LinearLayout </LinearLayout>
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:layout_below="@id/top_bar" android:layout_toRightOf="@+id/footer"
android:layout_toEndOf="@+id/footer">
<FrameLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent"
android:orientation="vertical"
android:layout_below="@id/top_bar" android:layout_toRightOf="@+id/footer"
android:layout_toEndOf="@+id/footer">
<LinearLayout <FrameLayout
android:baselineAligned="false" android:layout_width="match_parent"
android:layout_width="match_parent" android:layout_height="match_parent">
android:layout_height="match_parent"
android:orientation="horizontal">
<LinearLayout <LinearLayout
android:id="@+id/fragmentContainer" android:baselineAligned="false"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_weight="1" android:orientation="horizontal">
android:orientation="horizontal" />
<LinearLayout <LinearLayout
android:id="@+id/fragmentContainer2" android:id="@+id/fragmentContainer"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_weight="1" android:layout_weight="1"
android:orientation="horizontal"> android:orientation="horizontal" />
<View <LinearLayout
android:background="@color/colorE" android:id="@+id/fragmentContainer2"
android:layout_width="1dp" android:layout_width="match_parent"
android:layout_height="match_parent"/> android:layout_height="match_parent"
</LinearLayout> android:layout_weight="1"
android:orientation="horizontal">
</LinearLayout> <View
</FrameLayout> android:background="@color/colorE"
android:layout_width="1dp"
android:layout_height="match_parent"/>
</LinearLayout>
</LinearLayout> </LinearLayout>
<LinearLayout </FrameLayout>
android:id="@+id/footer"
android:layout_width="60dp"
android:layout_height="match_parent"
android:layout_alignParentBottom="true"
android:orientation="vertical">
<RelativeLayout </LinearLayout>
android:id="@+id/history"
android:background="@drawable/footer_button"
android:layout_weight="1"
android:layout_width="60dp"
android:layout_height="0dp">
<ImageView <LinearLayout
android:src="@drawable/footer_history" android:id="@+id/footer"
android:contentDescription="@string/content_description_history" android:layout_width="60dp"
android:layout_width="wrap_content" android:layout_height="match_parent"
android:layout_height="wrap_content" android:layout_alignParentBottom="true"
android:padding="15dp" android:orientation="vertical">
android:layout_centerInParent="true"/>
<View <RelativeLayout
android:id="@+id/history_select" android:id="@+id/history"
android:background="@color/colorA" android:background="@drawable/footer_button"
android:layout_width="5dp" android:layout_weight="1"
android:layout_height="match_parent" android:layout_width="60dp"
android:layout_alignParentLeft="true" android:layout_height="0dp">
android:visibility="gone"/>
<TextView <ImageView
android:id="@+id/missed_calls" android:src="@drawable/footer_history"
android:background="@drawable/unread_message_count_bg" android:contentDescription="@string/content_description_history"
style="@style/font18" android:layout_width="wrap_content"
android:layout_width="wrap_content" android:layout_height="wrap_content"
android:layout_height="wrap_content" android:padding="15dp"
android:gravity="center" android:layout_centerInParent="true"/>
android:layout_marginRight="5dp"
android:visibility="gone"
android:layout_centerVertical="true"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"/>
</RelativeLayout> <View
android:id="@+id/history_select"
android:background="@color/colorA"
android:layout_width="5dp"
android:layout_height="match_parent"
android:layout_alignParentLeft="true"
android:visibility="gone"/>
<RelativeLayout <TextView
android:id="@+id/contacts" android:id="@+id/missed_calls"
android:background="@drawable/footer_button" android:background="@drawable/unread_message_count_bg"
android:layout_weight="1" style="@style/font18"
android:layout_width="60dp" android:layout_width="wrap_content"
android:layout_height="0dp"> android:layout_height="wrap_content"
android:gravity="center"
android:layout_marginRight="5dp"
android:visibility="gone"
android:layout_centerVertical="true"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"/>
<ImageView </RelativeLayout>
android:src="@drawable/footer_contacts"
android:contentDescription="@string/content_description_contacts"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="15dp"
android:layout_centerInParent="true"/>
<View <RelativeLayout
android:id="@+id/contacts_select" android:id="@+id/contacts"
android:background="@color/colorA" android:background="@drawable/footer_button"
android:layout_width="5dp" android:layout_weight="1"
android:layout_height="match_parent" android:layout_width="60dp"
android:layout_alignParentLeft="true" android:layout_height="0dp">
android:visibility="gone"/>
</RelativeLayout>
<RelativeLayout <ImageView
android:id="@+id/dialer" android:src="@drawable/footer_contacts"
android:background="@drawable/footer_button" android:contentDescription="@string/content_description_contacts"
android:layout_weight="1" android:layout_width="match_parent"
android:layout_width="60dp" android:layout_height="wrap_content"
android:layout_height="0dp"> android:padding="15dp"
android:layout_centerInParent="true"/>
<ImageView <View
android:src="@drawable/footer_dialer" android:id="@+id/contacts_select"
android:contentDescription="@string/content_description_dialer" android:background="@color/colorA"
android:layout_width="match_parent" android:layout_width="5dp"
android:layout_height="wrap_content" android:layout_height="match_parent"
android:padding="15dp" android:layout_alignParentLeft="true"
android:layout_centerInParent="true"/> android:visibility="gone"/>
</RelativeLayout>
<View <RelativeLayout
android:id="@+id/dialer_select" android:id="@+id/dialer"
android:background="@color/colorA" android:background="@drawable/footer_button"
android:layout_width="5dp" android:layout_weight="1"
android:layout_height="match_parent" android:layout_width="60dp"
android:layout_alignParentLeft="true"/> android:layout_height="0dp">
</RelativeLayout> <ImageView
android:src="@drawable/footer_dialer"
android:contentDescription="@string/content_description_dialer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="15dp"
android:layout_centerInParent="true"/>
<RelativeLayout <View
android:id="@+id/chat" android:id="@+id/dialer_select"
android:background="@drawable/footer_button" android:background="@color/colorA"
android:layout_weight="1" android:layout_width="5dp"
android:layout_width="60dp" android:layout_height="match_parent"
android:layout_height="0dp"> android:layout_alignParentLeft="true"/>
<ImageView </RelativeLayout>
android:src="@drawable/footer_chat"
android:contentDescription="@string/content_description_chat_button"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="15dp"
android:layout_centerInParent="true" />
<View <RelativeLayout
android:id="@+id/chat_select" android:id="@+id/chat"
android:background="@color/colorA" android:background="@drawable/footer_button"
android:visibility="gone" android:layout_weight="1"
android:layout_width="5dp" android:layout_width="60dp"
android:layout_height="match_parent" android:layout_height="0dp">
android:layout_alignParentLeft="true"/>
<TextView <ImageView
android:id="@+id/missed_chats" android:src="@drawable/footer_chat"
android:background="@drawable/unread_message_count_bg" android:contentDescription="@string/content_description_chat_button"
style="@style/font18" android:layout_width="match_parent"
android:layout_width="wrap_content" android:layout_height="wrap_content"
android:layout_height="wrap_content" android:padding="15dp"
android:gravity="center" android:layout_centerInParent="true" />
android:layout_marginRight="5dp"
android:visibility="gone"
android:layout_centerVertical="true"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"/>
</RelativeLayout> <View
</LinearLayout> android:id="@+id/chat_select"
</RelativeLayout> android:background="@color/colorA"
android:visibility="gone"
android:layout_width="5dp"
android:layout_height="match_parent"
android:layout_alignParentLeft="true"/>
<!-- Side Menu --> <TextView
<RelativeLayout android:id="@+id/missed_chats"
android:id="@+id/side_menu_content" android:background="@drawable/unread_message_count_bg"
android:layout_width="400dp" style="@style/font18"
android:layout_height="match_parent" android:layout_width="wrap_content"
android:layout_gravity="left"> android:layout_height="wrap_content"
android:gravity="center"
android:layout_marginRight="5dp"
android:visibility="gone"
android:layout_centerVertical="true"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"/>
<LinearLayout </RelativeLayout>
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<include layout="@layout/side_menu_main_account"/> </LinearLayout>
<ListView </RelativeLayout>
android:id="@+id/accounts_list"
android:background="@color/colorB"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:choiceMode="singleChoice"
android:cacheColorHint="@color/transparent"
android:divider="@android:color/transparent"
android:dividerHeight="0dp"/>
<ListView <!-- Side Menu -->
android:id="@+id/item_list" <RelativeLayout
android:background="@color/colorH" android:id="@+id/side_menu_content"
android:layout_width="match_parent" android:layout_width="400dp"
android:layout_height="match_parent" android:layout_height="match_parent"
android:choiceMode="singleChoice" android:layout_gravity="left">
android:divider="@color/colorE"
android:listSelector="@color/colorH"
android:dividerHeight="1dp"/>
</LinearLayout>
<RelativeLayout <LinearLayout
android:id="@+id/side_menu_quit" android:layout_width="match_parent"
android:background="@color/colorA" android:layout_height="match_parent"
android:gravity="bottom" android:orientation="vertical">
android:layout_alignParentBottom="true"
android:layout_width="match_parent"
android:layout_height="50dp">
<ImageView <include layout="@layout/side_menu_main_account"/>
android:id="@+id/quit_button"
android:src="@drawable/quit"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<TextView <ListView
android:id="@+id/quit" android:id="@+id/accounts_list"
android:text="@string/quit" android:background="@color/colorB"
style="@style/font14" android:layout_width="wrap_content"
android:layout_width="wrap_content" android:layout_height="wrap_content"
android:layout_height="wrap_content" android:choiceMode="singleChoice"
android:layout_toRightOf="@id/quit_button" android:cacheColorHint="@color/transparent"
android:gravity="center_vertical" android:divider="@android:color/transparent"
android:layout_centerInParent="true"/> android:dividerHeight="0dp"/>
</RelativeLayout> <ListView
android:id="@+id/item_list"
android:background="@color/colorH"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:choiceMode="singleChoice"
android:divider="@color/colorE"
android:listSelector="@color/colorH"
android:dividerHeight="1dp"/>
</LinearLayout>
</RelativeLayout> <RelativeLayout
android:id="@+id/side_menu_quit"
android:background="@color/colorA"
android:gravity="bottom"
android:layout_alignParentBottom="true"
android:layout_width="match_parent"
android:layout_height="50dp">
</android.support.v4.widget.DrawerLayout> <ImageView
android:id="@+id/quit_button"
android:src="@drawable/quit"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<TextView
android:id="@+id/quit"
android:text="@string/quit"
style="@style/font14"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_toRightOf="@id/quit_button"
android:gravity="center_vertical"
android:layout_centerInParent="true"/>
</RelativeLayout>
</RelativeLayout>
</android.support.v4.widget.DrawerLayout>
</RelativeLayout> </RelativeLayout>

View file

@ -1,296 +1,306 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<RelativeLayout <RelativeLayout
xmlns:tools="http://schemas.android.com/tools" xmlns:tools="http://schemas.android.com/tools"
xmlns:android="http://schemas.android.com/apk/res/android" xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<fragment <fragment
android:id="@+id/status" android:id="@+id/status"
android:name="org.linphone.fragments.StatusFragment" android:name="org.linphone.fragments.StatusFragment"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="40dp" android:layout_height="40dp"
tools:layout="@layout/status" /> tools:layout="@layout/status" />
<android.support.v4.widget.DrawerLayout <android.support.v4.widget.DrawerLayout
android:id="@+id/side_menu" android:id="@+id/side_menu"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_below="@id/status"> android:layout_below="@id/status">
<RelativeLayout <RelativeLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<RelativeLayout <LinearLayout
android:id="@+id/top_bar" android:id="@+id/top_bar"
android:background="@color/colorF" android:visibility="gone"
android:layout_width="match_parent" android:orientation="horizontal"
android:layout_height="60dp" android:background="@color/colorF"
android:visibility="gone" android:layout_width="match_parent"
android:layout_alignParentTop="true"> android:layout_height="60dp">
<TextView <ImageView
android:id="@+id/menu_name" android:id="@+id/cancel"
android:text="@string/settings" android:src="@drawable/back"
style="@style/font1" android:background="@drawable/toolbar_button"
android:layout_width="wrap_content" android:contentDescription="@string/content_description_dialer_back"
android:layout_height="match_parent" android:layout_width="0dp"
android:layout_centerInParent="true" android:layout_height="match_parent"
android:gravity="center_vertical"/> android:layout_weight="0.2"
android:padding="15dp"/>
<ImageView <TextView
android:id="@+id/cancel" android:id="@+id/top_bar_title"
android:src="@drawable/dialer_back" style="@style/font1"
android:contentDescription="@string/content_description_dialer_back" android:maxLines="1"
android:layout_width="wrap_content" android:layout_width="0dp"
android:layout_height="match_parent" android:layout_height="match_parent"
android:padding="15dp" android:layout_weight="0.4"
android:layout_centerInParent="true" android:gravity="center"
android:layout_alignParentRight="true"/> android:padding="15dp"/>
</RelativeLayout> <View
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"/>
<LinearLayout </LinearLayout>
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:layout_below="@id/top_bar"
android:layout_above="@id/footer">
<FrameLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent"
android:orientation="vertical"
android:layout_below="@id/top_bar"
android:layout_above="@id/footer">
<LinearLayout <FrameLayout
android:baselineAligned="false" android:layout_width="match_parent"
android:layout_width="match_parent" android:layout_height="match_parent">
android:layout_height="match_parent"
android:orientation="horizontal">
<LinearLayout <LinearLayout
android:id="@+id/fragmentContainer" android:baselineAligned="false"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_weight="1" android:orientation="horizontal">
android:orientation="horizontal" />
<LinearLayout <LinearLayout
android:id="@+id/fragmentContainer2" android:id="@+id/fragmentContainer"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_weight="1" android:layout_weight="1"
android:orientation="horizontal"> android:orientation="horizontal" />
<View <LinearLayout
android:background="@color/colorE" android:id="@+id/fragmentContainer2"
android:layout_width="1dp" android:layout_width="match_parent"
android:layout_height="match_parent"/> android:layout_height="match_parent"
android:layout_weight="1"
android:orientation="horizontal">
</LinearLayout> <View
</LinearLayout> android:background="@color/colorE"
</FrameLayout> android:layout_width="1dp"
android:layout_height="match_parent"/>
</LinearLayout> </LinearLayout>
<LinearLayout </LinearLayout>
android:id="@+id/footer"
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_alignParentBottom="true"
android:orientation="horizontal">
<RelativeLayout </FrameLayout>
android:id="@+id/history"
android:background="@drawable/footer_button"
android:layout_weight="1"
android:layout_width="0dp"
android:layout_height="match_parent">
<ImageView </LinearLayout>
android:id="@+id/footer_history"
android:src="@drawable/footer_history"
android:contentDescription="@string/content_description_history"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="15dp"
android:layout_centerInParent="true"/>
<View <LinearLayout
android:id="@+id/history_select" android:id="@+id/footer"
android:background="@color/colorA" android:layout_width="match_parent"
android:layout_width="match_parent" android:layout_height="60dp"
android:layout_height="5dp" android:layout_alignParentBottom="true"
android:layout_alignParentBottom="true" android:orientation="horizontal">
android:visibility="gone"/>
<TextView <RelativeLayout
android:id="@+id/missed_calls" android:id="@+id/history"
android:background="@drawable/unread_message_count_bg" android:background="@drawable/footer_button"
style="@style/font18" android:layout_weight="1"
android:layout_width="wrap_content" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="match_parent">
android:gravity="center"
android:layout_margin="20dp"
android:layout_alignParentTop="true"
android:layout_alignParentRight="true"
android:visibility="visible"/>
</RelativeLayout> <ImageView
android:id="@+id/footer_history"
android:src="@drawable/footer_history"
android:contentDescription="@string/content_description_history"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="15dp"
android:layout_centerInParent="true"/>
<RelativeLayout <View
android:id="@+id/contacts" android:id="@+id/history_select"
android:background="@drawable/footer_button" android:background="@color/colorA"
android:layout_weight="1" android:layout_width="match_parent"
android:layout_width="0dp" android:layout_height="5dp"
android:layout_height="match_parent"> android:layout_alignParentBottom="true"
android:visibility="gone"/>
<ImageView <TextView
android:src="@drawable/footer_contacts" android:id="@+id/missed_calls"
android:contentDescription="@string/content_description_contacts" android:background="@drawable/unread_message_count_bg"
android:layout_width="match_parent" style="@style/font18"
android:layout_height="wrap_content" android:layout_width="wrap_content"
android:padding="15dp" android:layout_height="wrap_content"
android:layout_centerInParent="true"/> android:gravity="center"
android:layout_margin="20dp"
android:layout_alignParentTop="true"
android:layout_alignParentRight="true"
android:visibility="visible"/>
<View </RelativeLayout>
android:id="@+id/contacts_select"
android:background="@color/colorA"
android:layout_width="match_parent"
android:layout_height="5dp"
android:layout_alignParentBottom="true"
android:visibility="gone"/>
</RelativeLayout>
<RelativeLayout <RelativeLayout
android:id="@+id/dialer" android:id="@+id/contacts"
android:background="@drawable/footer_button" android:background="@drawable/footer_button"
android:layout_weight="1" android:layout_weight="1"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="match_parent"> android:layout_height="match_parent">
<ImageView <ImageView
android:src="@drawable/footer_dialer" android:src="@drawable/footer_contacts"
android:contentDescription="@string/content_description_dialer" android:contentDescription="@string/content_description_contacts"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:padding="15dp" android:padding="15dp"
android:layout_centerInParent="true"/> android:layout_centerInParent="true"/>
<View <View
android:id="@+id/dialer_select" android:id="@+id/contacts_select"
android:background="@color/colorA" android:background="@color/colorA"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="5dp" android:layout_height="5dp"
android:layout_alignParentBottom="true"/> android:layout_alignParentBottom="true"
android:visibility="gone"/>
</RelativeLayout>
</RelativeLayout> <RelativeLayout
android:id="@+id/dialer"
android:background="@drawable/footer_button"
android:layout_weight="1"
android:layout_width="0dp"
android:layout_height="match_parent">
<RelativeLayout <ImageView
android:id="@+id/chat" android:src="@drawable/footer_dialer"
android:background="@drawable/footer_button" android:contentDescription="@string/content_description_dialer"
android:layout_weight="1" android:layout_width="match_parent"
android:layout_width="0dp" android:layout_height="wrap_content"
android:layout_height="match_parent"> android:padding="15dp"
android:layout_centerInParent="true"/>
<ImageView <View
android:src="@drawable/footer_chat" android:id="@+id/dialer_select"
android:contentDescription="@string/content_description_chat" android:background="@color/colorA"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="5dp"
android:padding="15dp" android:layout_alignParentBottom="true"/>
android:layout_centerInParent="true" />
<View </RelativeLayout>
android:id="@+id/chat_select"
android:background="@color/colorA"
android:layout_width="match_parent"
android:layout_height="5dp"
android:layout_alignParentBottom="true"
android:visibility="gone"/>
<TextView <RelativeLayout
android:id="@+id/missed_chats" android:id="@+id/chat"
android:background="@drawable/unread_message_count_bg" android:background="@drawable/footer_button"
style="@style/font18" android:layout_weight="1"
android:layout_width="wrap_content" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="match_parent">
android:layout_margin="20dp"
android:gravity="center"
android:layout_alignParentTop="true"
android:layout_alignParentRight="true"
android:visibility="gone"/>
</RelativeLayout> <ImageView
</LinearLayout> android:src="@drawable/footer_chat"
</RelativeLayout> android:contentDescription="@string/content_description_chat"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="15dp"
android:layout_centerInParent="true" />
<!-- Side Menu --> <View
<RelativeLayout android:id="@+id/chat_select"
android:id="@+id/side_menu_content" android:background="@color/colorA"
android:layout_width="400dp" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="5dp"
android:layout_gravity="left"> android:layout_alignParentBottom="true"
android:visibility="gone"/>
<LinearLayout <TextView
android:layout_width="match_parent" android:id="@+id/missed_chats"
android:layout_height="match_parent" android:background="@drawable/unread_message_count_bg"
android:orientation="vertical"> style="@style/font18"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="20dp"
android:gravity="center"
android:layout_alignParentTop="true"
android:layout_alignParentRight="true"
android:visibility="gone"/>
<include layout="@layout/side_menu_main_account"/> </RelativeLayout>
<ListView </LinearLayout>
android:id="@+id/accounts_list"
android:background="@color/colorB"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:choiceMode="singleChoice"
android:cacheColorHint="@color/transparent"
android:divider="@android:color/transparent"
android:dividerHeight="0dp"/>
<ListView </RelativeLayout>
android:id="@+id/item_list"
android:background="@color/colorH"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:choiceMode="singleChoice"
android:divider="@color/colorE"
android:listSelector="@color/colorH"
android:dividerHeight="1dp"/>
</LinearLayout>
<RelativeLayout <!-- Side Menu -->
android:id="@+id/side_menu_quit" <RelativeLayout
android:background="@color/colorA" android:id="@+id/side_menu_content"
android:gravity="bottom" android:layout_width="400dp"
android:layout_alignParentBottom="true" android:layout_height="match_parent"
android:layout_width="match_parent" android:layout_gravity="left">
android:layout_height="50dp">
<ImageView <LinearLayout
android:id="@+id/quit_button" android:layout_width="match_parent"
android:src="@drawable/quit" android:layout_height="match_parent"
android:layout_width="wrap_content" android:orientation="vertical">
android:layout_height="wrap_content"
android:padding="5dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<TextView <include layout="@layout/side_menu_main_account"/>
android:id="@+id/quit"
android:text="@string/quit"
style="@style/font14"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_toRightOf="@id/quit_button"
android:gravity="center_vertical"
android:layout_centerInParent="true"/>
</RelativeLayout> <ListView
android:id="@+id/accounts_list"
android:background="@color/colorB"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:choiceMode="singleChoice"
android:cacheColorHint="@color/transparent"
android:divider="@android:color/transparent"
android:dividerHeight="0dp"/>
</RelativeLayout> <ListView
android:id="@+id/item_list"
android:background="@color/colorH"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:choiceMode="singleChoice"
android:divider="@color/colorE"
android:listSelector="@color/colorH"
android:dividerHeight="1dp"/>
</LinearLayout>
</android.support.v4.widget.DrawerLayout> <RelativeLayout
android:id="@+id/side_menu_quit"
android:background="@color/colorA"
android:gravity="bottom"
android:layout_alignParentBottom="true"
android:layout_width="match_parent"
android:layout_height="50dp">
<ImageView
android:id="@+id/quit_button"
android:src="@drawable/quit"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<TextView
android:id="@+id/quit"
android:text="@string/quit"
style="@style/font14"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_toRightOf="@id/quit_button"
android:gravity="center_vertical"
android:layout_centerInParent="true"/>
</RelativeLayout>
</RelativeLayout>
</android.support.v4.widget.DrawerLayout>
</RelativeLayout> </RelativeLayout>

View file

@ -5,40 +5,6 @@
android:layout_height="match_parent" android:layout_height="match_parent"
android:orientation="vertical"> android:orientation="vertical">
<LinearLayout
android:id="@+id/top_bar"
android:orientation="horizontal"
android:background="@color/colorF"
android:layout_width="match_parent"
android:layout_height="60dp">
<View
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"/>
<TextView
android:id="@+id/menu_name"
android:text="@string/about"
style="@style/font1"
android:maxLines="1"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.4"
android:gravity="center"
android:padding="15dp"/>
<ImageView
android:id="@+id/cancel"
android:src="@drawable/dialer_back"
android:background="@drawable/toolbar_button"
android:contentDescription="@string/content_description_dialer_back"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"
android:padding="15dp"/>
</LinearLayout>
<LinearLayout <LinearLayout
android:background="@color/colorC" android:background="@color/colorC"
android:orientation="vertical" android:orientation="vertical"

View file

@ -5,282 +5,291 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<fragment <fragment
android:id="@+id/status" android:id="@+id/status"
android:name="org.linphone.fragments.StatusFragment" android:name="org.linphone.fragments.StatusFragment"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="40dp" android:layout_height="40dp"
tools:layout="@layout/status" /> tools:layout="@layout/status" />
<android.support.v4.widget.DrawerLayout <android.support.v4.widget.DrawerLayout
android:id="@+id/side_menu" android:id="@+id/side_menu"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_below="@id/status"> android:layout_below="@id/status">
<RelativeLayout <RelativeLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<RelativeLayout <LinearLayout
android:id="@+id/top_bar" android:id="@+id/top_bar"
android:background="@color/colorF" android:visibility="gone"
android:layout_width="match_parent" android:orientation="horizontal"
android:layout_height="60dp" android:background="@color/colorF"
android:visibility="gone" android:layout_width="match_parent"
android:layout_alignParentTop="true"> android:layout_height="60dp">
<TextView <ImageView
android:id="@+id/menu_name" android:id="@+id/cancel"
android:text="@string/settings" android:src="@drawable/back"
style="@style/font1" android:background="@drawable/toolbar_button"
android:layout_width="wrap_content" android:contentDescription="@string/content_description_dialer_back"
android:layout_height="match_parent" android:layout_width="0dp"
android:layout_centerInParent="true" android:layout_height="match_parent"
android:gravity="center_vertical"/> android:layout_weight="0.2"
android:padding="15dp"/>
<ImageView <TextView
android:id="@+id/cancel" android:id="@+id/top_bar_title"
android:src="@drawable/dialer_back" style="@style/font1"
android:contentDescription="@string/content_description_dialer_back" android:maxLines="1"
android:layout_width="wrap_content" android:layout_width="0dp"
android:layout_height="match_parent" android:layout_height="match_parent"
android:padding="15dp" android:layout_weight="0.4"
android:layout_centerInParent="true" android:gravity="center"
android:layout_alignParentRight="true"/> android:padding="15dp"/>
</RelativeLayout> <View
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="0.2"/>
<LinearLayout </LinearLayout>
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:layout_above="@id/footer"
android:layout_below="@id/top_bar">
<FrameLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_alignParentTop="true"> android:orientation="vertical"
android:layout_above="@id/footer"
android:layout_below="@id/top_bar">
<LinearLayout <FrameLayout
android:id="@+id/fragmentContainer" android:layout_width="match_parent"
android:layout_width="match_parent" android:layout_height="match_parent"
android:layout_height="match_parent" android:layout_alignParentTop="true">
android:orientation="horizontal" />
</FrameLayout>
</LinearLayout> <LinearLayout
android:id="@+id/fragmentContainer"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal" />
</FrameLayout>
<LinearLayout </LinearLayout>
android:id="@+id/footer"
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_alignParentBottom="true"
android:orientation="horizontal">
<RelativeLayout <LinearLayout
android:id="@+id/history" android:id="@+id/footer"
android:background="@drawable/footer_button" android:layout_width="match_parent"
android:layout_weight="1" android:layout_height="60dp"
android:layout_width="0dp" android:layout_alignParentBottom="true"
android:layout_height="match_parent"> android:orientation="horizontal">
<ImageView <RelativeLayout
android:src="@drawable/footer_history" android:id="@+id/history"
android:layout_width="match_parent" android:background="@drawable/footer_button"
android:layout_height="wrap_content" android:layout_weight="1"
android:contentDescription="@string/content_description_history" android:layout_width="0dp"
android:padding="15dp" android:layout_height="match_parent">
android:layout_centerInParent="true"/>
<View <ImageView
android:id="@+id/history_select" android:src="@drawable/footer_history"
android:background="@color/colorA" android:layout_width="match_parent"
android:layout_width="match_parent" android:layout_height="wrap_content"
android:layout_height="5dp" android:contentDescription="@string/content_description_history"
android:layout_alignParentBottom="true" android:padding="15dp"
android:visibility="gone"/> android:layout_centerInParent="true"/>
<TextView <View
android:id="@+id/missed_calls" android:id="@+id/history_select"
android:background="@drawable/unread_message_count_bg" android:background="@color/colorA"
style="@style/font18" android:layout_width="match_parent"
android:layout_width="wrap_content" android:layout_height="5dp"
android:layout_height="wrap_content" android:layout_alignParentBottom="true"
android:layout_margin="15dp" android:visibility="gone"/>
android:gravity="center"
android:visibility="gone"/>
</RelativeLayout> <TextView
android:id="@+id/missed_calls"
android:background="@drawable/unread_message_count_bg"
style="@style/font18"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="15dp"
android:gravity="center"
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">
<ImageView <RelativeLayout
android:src="@drawable/footer_contacts" android:id="@+id/contacts"
android:contentDescription="@string/content_description_contacts" android:background="@drawable/footer_button"
android:layout_width="match_parent" android:layout_weight="1"
android:layout_height="wrap_content" android:layout_width="0dp"
android:padding="15dp" android:layout_height="match_parent">
android:layout_centerInParent="true"/>
<View <ImageView
android:id="@+id/contacts_select" android:src="@drawable/footer_contacts"
android:background="@color/colorA" android:contentDescription="@string/content_description_contacts"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="5dp" android:layout_height="wrap_content"
android:layout_alignParentBottom="true" android:padding="15dp"
android:visibility="gone"/> android:layout_centerInParent="true"/>
</RelativeLayout>
<RelativeLayout <View
android:id="@+id/dialer" android:id="@+id/contacts_select"
android:background="@drawable/footer_button" android:background="@color/colorA"
android:layout_weight="1" android:layout_width="match_parent"
android:layout_width="0dp" android:layout_height="5dp"
android:layout_height="match_parent"> android:layout_alignParentBottom="true"
android:visibility="gone"/>
</RelativeLayout>
<ImageView <RelativeLayout
android:src="@drawable/footer_dialer" android:id="@+id/dialer"
android:contentDescription="@string/content_description_dialer" android:background="@drawable/footer_button"
android:layout_width="match_parent" android:layout_weight="1"
android:layout_height="wrap_content" android:layout_width="0dp"
android:padding="15dp" android:layout_height="match_parent">
android:layout_centerInParent="true"/>
<View <ImageView
android:id="@+id/dialer_select" android:src="@drawable/footer_dialer"
android:background="@color/colorA" android:contentDescription="@string/content_description_dialer"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="5dp" android:layout_height="wrap_content"
android:layout_alignParentBottom="true"/> android:padding="15dp"
android:layout_centerInParent="true"/>
</RelativeLayout> <View
android:id="@+id/dialer_select"
android:background="@color/colorA"
android:layout_width="match_parent"
android:layout_height="5dp"
android:layout_alignParentBottom="true"/>
<RelativeLayout </RelativeLayout>
android:id="@+id/chat"
android:background="@drawable/footer_button"
android:layout_weight="1"
android:layout_width="0dp"
android:layout_height="match_parent">
<ImageView <RelativeLayout
android:src="@drawable/footer_chat" android:id="@+id/chat"
android:contentDescription="@string/content_description_chat_button" android:background="@drawable/footer_button"
android:layout_width="match_parent" android:layout_weight="1"
android:layout_height="wrap_content" android:layout_width="0dp"
android:padding="15dp" android:layout_height="match_parent">
android:layout_centerInParent="true" />
<View <ImageView
android:id="@+id/chat_select" android:src="@drawable/footer_chat"
android:background="@color/colorA" android:contentDescription="@string/content_description_chat_button"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="5dp" android:layout_height="wrap_content"
android:layout_alignParentBottom="true" android:padding="15dp"
android:visibility="gone"/> android:layout_centerInParent="true" />
<TextView <View
android:id="@+id/missed_chats" android:id="@+id/chat_select"
android:background="@drawable/unread_message_count_bg" android:background="@color/colorA"
style="@style/font18" android:layout_width="match_parent"
android:layout_width="wrap_content" android:layout_height="5dp"
android:layout_height="wrap_content" android:layout_alignParentBottom="true"
android:layout_margin="15dp" android:visibility="gone"/>
android:gravity="center"
android:visibility="gone"/>
</RelativeLayout> <TextView
</LinearLayout> android:id="@+id/missed_chats"
android:background="@drawable/unread_message_count_bg"
style="@style/font18"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="15dp"
android:gravity="center"
android:visibility="gone"/>
<LinearLayout </RelativeLayout>
android:id="@+id/fragmentContainer2"
android:visibility="gone"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
</LinearLayout> </LinearLayout>
</RelativeLayout>
<!-- Side Menu --> <LinearLayout
<RelativeLayout android:id="@+id/fragmentContainer2"
android:id="@+id/side_menu_content" android:visibility="gone"
android:layout_width="match_parent" android:layout_width="wrap_content"
android:layout_height="match_parent" android:layout_height="wrap_content"
android:layout_gravity="left"> android:orientation="vertical">
<RelativeLayout </LinearLayout>
android:id="@+id/side_menu_quit"
android:background="@color/colorA"
android:gravity="bottom"
android:layout_alignParentBottom="true"
android:layout_width="match_parent"
android:layout_height="50dp">
<ImageView </RelativeLayout>
android:id="@+id/quit_button"
android:src="@drawable/quit"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<TextView <!-- Side Menu -->
android:id="@+id/quit" <RelativeLayout
android:text="@string/quit" android:id="@+id/side_menu_content"
style="@style/font14" android:layout_width="match_parent"
android:layout_width="wrap_content" android:layout_height="match_parent"
android:layout_height="wrap_content" android:layout_gravity="left">
android:layout_toRightOf="@id/quit_button"
android:gravity="center_vertical"
android:layout_centerInParent="true"/>
</RelativeLayout>
<LinearLayout <RelativeLayout
android:layout_width="match_parent" android:id="@+id/side_menu_quit"
android:layout_height="match_parent" android:background="@color/colorA"
android:background="@color/colorH" android:gravity="bottom"
android:layout_above="@id/side_menu_quit" android:layout_alignParentBottom="true"
android:orientation="vertical"> android:layout_width="match_parent"
android:layout_height="50dp">
<include layout="@layout/side_menu_main_account"/> <ImageView
android:id="@+id/quit_button"
android:src="@drawable/quit"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="5dp"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true" />
<ListView <TextView
android:id="@+id/accounts_list" android:id="@+id/quit"
android:background="@color/colorH" android:text="@string/quit"
android:layout_width="match_parent" style="@style/font14"
android:layout_height="wrap_content" android:layout_width="wrap_content"
android:choiceMode="singleChoice" android:layout_height="wrap_content"
android:cacheColorHint="@color/transparent" android:layout_toRightOf="@id/quit_button"
android:divider="@android:color/transparent" android:gravity="center_vertical"
android:dividerHeight="0dp"/> android:layout_centerInParent="true"/>
</RelativeLayout>
<ListView <LinearLayout
android:id="@+id/item_list" android:layout_width="match_parent"
android:background="@color/colorH" android:layout_height="match_parent"
android:layout_width="match_parent" android:background="@color/colorH"
android:layout_height="wrap_content" android:layout_above="@id/side_menu_quit"
android:choiceMode="singleChoice" android:orientation="vertical">
android:divider="@color/colorE"
android:listSelector="@color/colorH"
android:footerDividersEnabled="true"
android:dividerHeight="1dp"/>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="@color/colorE"/>
</LinearLayout> <include layout="@layout/side_menu_main_account"/>
</RelativeLayout>
</android.support.v4.widget.DrawerLayout> <ListView
android:id="@+id/accounts_list"
android:background="@color/colorH"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:choiceMode="singleChoice"
android:cacheColorHint="@color/transparent"
android:divider="@android:color/transparent"
android:dividerHeight="0dp"/>
<ListView
android:id="@+id/item_list"
android:background="@color/colorH"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:choiceMode="singleChoice"
android:divider="@color/colorE"
android:listSelector="@color/colorH"
android:footerDividersEnabled="true"
android:dividerHeight="1dp"/>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="@color/colorE"/>
</LinearLayout>
</RelativeLayout>
</android.support.v4.widget.DrawerLayout>
</RelativeLayout> </RelativeLayout>