Rename assets
This commit is contained in:
parent
343bbed681
commit
f2f12e1bdb
8 changed files with 104 additions and 88 deletions
|
@ -5,6 +5,34 @@
|
|||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/top_bar"
|
||||
android:background="@color/colorF"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="60dp"
|
||||
android:visibility="visible"
|
||||
android:layout_alignParentTop="true">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/menu_name"
|
||||
android:text="@string/about"
|
||||
style="@style/font1"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_centerInParent="true"
|
||||
android:gravity="center_vertical"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/cancel"
|
||||
android:src="@drawable/dialer_back"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="15dp"
|
||||
android:layout_centerInParent="true"
|
||||
android:layout_alignParentRight="true"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/linphone_orange"
|
||||
android:layout_width="wrap_content"
|
||||
|
|
|
@ -32,6 +32,7 @@
|
|||
|
||||
<TextView
|
||||
android:id="@+id/menu_name"
|
||||
android:text="@string/settings"
|
||||
style="@style/font1"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
|
@ -41,8 +42,7 @@
|
|||
<ImageView
|
||||
android:id="@+id/cancel"
|
||||
android:src="@drawable/dialer_back"
|
||||
android:contentDescription="@string/content_description_dialer"
|
||||
android:layout_width="70dp"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="15dp"
|
||||
android:layout_centerInParent="true"
|
||||
|
@ -86,28 +86,26 @@
|
|||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/footer_history"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="35dp"
|
||||
android:layout_centerInParent="true"
|
||||
android:contentDescription="@string/content_description_history"
|
||||
android:src="@drawable/footer_history"
|
||||
android:id="@+id/imageView"/>
|
||||
android:layout_centerInParent="true"/>
|
||||
|
||||
<RelativeLayout
|
||||
<View
|
||||
android:id="@+id/history_select"
|
||||
android:background="@color/colorA"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:visibility="gone" />
|
||||
android:visibility="gone"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/missedCalls"
|
||||
android:id="@+id/missed_calls"
|
||||
android:background="@drawable/history_chat_indicator"
|
||||
style="@style/font18"
|
||||
android:layout_width="25dp"
|
||||
android:layout_height="25dp"
|
||||
android:layout_margin="12dp"
|
||||
android:background="@drawable/history_chat_indicator"
|
||||
android:gravity="center"
|
||||
android:visibility="gone"/>
|
||||
|
||||
|
@ -118,42 +116,37 @@
|
|||
android:background="@drawable/footer_button"
|
||||
android:layout_weight="1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:adjustViewBounds="true">
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/footer_contacts"
|
||||
android:contentDescription="@string/content_description_contacts"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="35dp"
|
||||
android:layout_centerInParent="true" />
|
||||
android:layout_centerInParent="true"/>
|
||||
|
||||
<RelativeLayout
|
||||
<View
|
||||
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" />
|
||||
android:visibility="gone"/>
|
||||
</RelativeLayout>
|
||||
|
||||
|
||||
<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">
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/footer_dialer"
|
||||
android:contentDescription="@string/content_description_dialer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="35dp"
|
||||
android:layout_centerInParent="true"/>
|
||||
|
||||
<RelativeLayout
|
||||
<View
|
||||
android:id="@+id/dialer_select"
|
||||
android:background="@color/colorA"
|
||||
android:layout_width="match_parent"
|
||||
|
@ -171,12 +164,11 @@
|
|||
|
||||
<ImageView
|
||||
android:src="@drawable/footer_chat"
|
||||
android:contentDescription="@string/content_description_chat"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="35dp"
|
||||
android:layout_centerInParent="true" />
|
||||
|
||||
<RelativeLayout
|
||||
<View
|
||||
android:id="@+id/chat_select"
|
||||
android:background="@color/colorA"
|
||||
android:layout_width="match_parent"
|
||||
|
@ -185,34 +177,33 @@
|
|||
android:visibility="gone"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/missedChats"
|
||||
android:id="@+id/missed_chats"
|
||||
android:background="@drawable/history_chat_indicator"
|
||||
style="@style/font18"
|
||||
android:layout_width="25dp"
|
||||
android:layout_height="25dp"
|
||||
android:layout_margin="12dp"
|
||||
android:background="@drawable/history_chat_indicator"
|
||||
android:gravity="center"
|
||||
android:visibility="gone" />
|
||||
|
||||
</RelativeLayout>
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/fragmentContainer2"
|
||||
android:visibility="gone"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:id="@+id/fragmentContainer2"
|
||||
android:visibility="gone"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
</LinearLayout>
|
||||
</RelativeLayout>
|
||||
|
||||
<!-- Side Menu -->
|
||||
<RelativeLayout
|
||||
android:id="@+id/side_menu_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:id="@+id/side_menu_content"
|
||||
android:layout_gravity="left">
|
||||
|
||||
<LinearLayout
|
||||
|
@ -220,42 +211,44 @@
|
|||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<include layout="@layout/side_menu_default_account"/>
|
||||
<include layout="@layout/side_menu_main_account"/>
|
||||
|
||||
<ListView android:id="@+id/accounts_list"
|
||||
<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"
|
||||
android:background="@color/colorB"/>
|
||||
android:dividerHeight="0dp"/>
|
||||
|
||||
<ListView android:id="@+id/item_list"
|
||||
<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"
|
||||
android:background="@color/colorH"/>
|
||||
android:dividerHeight="1dp"/>
|
||||
</LinearLayout>
|
||||
|
||||
<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:background="@color/colorA">
|
||||
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:layout_alignParentLeft="true"
|
||||
android:padding="5dp"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_centerVertical="true" />
|
||||
|
||||
<TextView
|
||||
|
|
|
@ -1,12 +1,13 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
<RelativeLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:background="@color/colorG"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:gravity="center">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/address"
|
||||
android:id="@+id/account_address"
|
||||
style="@style/font13"
|
||||
android:paddingLeft="10dp"
|
||||
android:gravity="center_vertical"
|
||||
|
@ -14,7 +15,7 @@
|
|||
android:layout_height="match_parent"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/status_led"
|
||||
android:id="@+id/account_status"
|
||||
android:src="@drawable/status_available"
|
||||
android:layout_width="25dp"
|
||||
android:layout_height="25dp"
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@android:id/text1"
|
||||
android:id="@+id/item_name"
|
||||
style="@style/font6"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
|
@ -6,7 +6,7 @@
|
|||
android:layout_height="80dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/icon"
|
||||
android:id="@+id/main_account_avatar"
|
||||
android:src="@drawable/avatar"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
|
@ -19,30 +19,28 @@
|
|||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:layout_toRightOf="@+id/icon"
|
||||
android:layout_toRightOf="@+id/main_account_avatar"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/display_name"
|
||||
android:id="@+id/main_account_display_name"
|
||||
style="@style/font7"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:editable="false"/>
|
||||
android:layout_height="wrap_content"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/address"
|
||||
android:id="@+id/main_account_address"
|
||||
style="@style/font3"
|
||||
android:editable="false"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/status_led"
|
||||
android:id="@+id/main_account_status"
|
||||
android:src="@drawable/status_available"
|
||||
android:layout_width="25dp"
|
||||
android:layout_height="25dp"
|
||||
android:src="@drawable/status_available"
|
||||
android:padding="5dp"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:layout_alignParentRight="true"
|
|
@ -23,6 +23,7 @@
|
|||
<string name="outgoing">outgoing</string>
|
||||
<string name="incoming">incoming</string>
|
||||
<string name="missed">missed</string>
|
||||
<string name="settings">Settings</string>
|
||||
|
||||
<!-- splashscreen -->
|
||||
<string name="app_description">free SIP VOIP client</string>
|
||||
|
@ -293,7 +294,6 @@
|
|||
<string name="pref_audio">Audio</string>
|
||||
<string name="pref_prefix">Prefix</string>
|
||||
<string name="pref_advanced">Advanced</string>
|
||||
<string name="menu_settings">Settings</string>
|
||||
<string name="pref_proxy">Proxy</string>
|
||||
<string name="pref_domain">Domain*</string>
|
||||
<string name="pref_passwd">Password*</string>
|
||||
|
|
|
@ -29,6 +29,7 @@ import android.view.View;
|
|||
import android.view.View.OnClickListener;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.RelativeLayout;
|
||||
import android.widget.TextView;
|
||||
|
||||
/**
|
||||
|
@ -37,6 +38,7 @@ import android.widget.TextView;
|
|||
public class AboutFragment extends Fragment implements OnClickListener {
|
||||
View sendLogButton = null;
|
||||
View resetLogButton = null;
|
||||
ImageView cancel;
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
|
||||
|
@ -49,6 +51,9 @@ public class AboutFragment extends Fragment implements OnClickListener {
|
|||
Log.e(e, "cannot get version name");
|
||||
}
|
||||
|
||||
cancel = (ImageView) view.findViewById(R.id.cancel);
|
||||
cancel.setOnClickListener(this);
|
||||
|
||||
sendLogButton = view.findViewById(R.id.send_log);
|
||||
sendLogButton.setOnClickListener(this);
|
||||
sendLogButton.setVisibility(org.linphone.LinphonePreferences.instance().isDebugEnabled() ? View.VISIBLE : View.GONE);
|
||||
|
@ -66,7 +71,6 @@ public class AboutFragment extends Fragment implements OnClickListener {
|
|||
|
||||
if (org.linphone.LinphoneActivity.isInstanciated()) {
|
||||
LinphoneActivity.instance().hideTabBar(true);
|
||||
LinphoneActivity.instance().displayTopBar(true,"About");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -82,6 +86,8 @@ public class AboutFragment extends Fragment implements OnClickListener {
|
|||
if (lc != null) {
|
||||
lc.resetLogCollection();
|
||||
}
|
||||
} else if (v == cancel) {
|
||||
getFragmentManager().popBackStackImmediate();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -99,7 +99,7 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
private StatusFragment statusFragment;
|
||||
private TextView missedCalls, missedChats;
|
||||
private RelativeLayout contacts, history, dialer, chat;
|
||||
private RelativeLayout contacts_selected, history_selected, dialer_selected, chat_selected;
|
||||
private View contacts_selected, history_selected, dialer_selected, chat_selected;
|
||||
private RelativeLayout mTopBar;
|
||||
private ImageView cancel;
|
||||
private FragmentsAvailable currentFragment, nextFragment;
|
||||
|
@ -294,13 +294,13 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
chat = (RelativeLayout) findViewById(R.id.chat);
|
||||
chat.setOnClickListener(this);
|
||||
|
||||
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);
|
||||
history_selected = findViewById(R.id.history_select);
|
||||
contacts_selected = findViewById(R.id.contacts_select);
|
||||
dialer_selected = findViewById(R.id.dialer_select);
|
||||
chat_selected = findViewById(R.id.chat_select);
|
||||
|
||||
missedCalls = (TextView) findViewById(R.id.missedCalls);
|
||||
missedChats = (TextView) findViewById(R.id.missedChats);
|
||||
missedCalls = (TextView) findViewById(R.id.missed_calls);
|
||||
missedChats = (TextView) findViewById(R.id.missed_chats);
|
||||
}
|
||||
|
||||
private boolean isTablet() {
|
||||
|
@ -694,9 +694,9 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
} else if (id == R.id.chat) {
|
||||
changeCurrentFragment(FragmentsAvailable.CHAT_LIST, null);
|
||||
chat_selected.setVisibility(View.VISIBLE);
|
||||
} else if (id == R.id.cancel) {
|
||||
displayTopBar(false,"");
|
||||
} else if (id == R.id.cancel){
|
||||
getFragmentManager().popBackStackImmediate();
|
||||
mTopBar.setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -715,17 +715,6 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
}
|
||||
}
|
||||
|
||||
public void displayTopBar(Boolean display, String name) {
|
||||
TextView menuName = (TextView) findViewById(R.id.menu_name);
|
||||
if(display){
|
||||
menuName.setText(name);
|
||||
mTopBar.setVisibility(View.VISIBLE);
|
||||
} else {
|
||||
menuName.setText("");
|
||||
mTopBar.setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressWarnings("incomplete-switch")
|
||||
public void selectMenu(FragmentsAvailable menuToSelect) {
|
||||
currentFragment = menuToSelect;
|
||||
|
@ -746,7 +735,8 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
break;
|
||||
case SETTINGS:
|
||||
case ACCOUNT_SETTINGS:
|
||||
displayTopBar(true,"settings");
|
||||
hideTabBar(true);
|
||||
mTopBar.setVisibility(View.VISIBLE);
|
||||
break;
|
||||
case CHAT_LIST:
|
||||
case CHAT:
|
||||
|
@ -1264,7 +1254,7 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
sideMenuItemList = (ListView)findViewById(R.id.item_list);
|
||||
menu = (ImageView) findViewById(R.id.side_menu_button);
|
||||
|
||||
sideMenuItemList.setAdapter(new ArrayAdapter<String>(this, R.layout.side_menu_item, sideMenuItems));
|
||||
sideMenuItemList.setAdapter(new ArrayAdapter<String>(this, R.layout.side_menu_item_cell, sideMenuItems));
|
||||
sideMenuItemList.setOnItemClickListener(new AdapterView.OnItemClickListener() {
|
||||
@Override
|
||||
public void onItemClick(AdapterView<?> adapterView, View view, int i, long l) {
|
||||
|
@ -1323,9 +1313,9 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
|
||||
private void displayMainAccount(){
|
||||
defaultAccount.setVisibility(View.VISIBLE);
|
||||
ImageView status = (ImageView) defaultAccount.findViewById(R.id.status_led);
|
||||
TextView address = (TextView) defaultAccount.findViewById(R.id.address);
|
||||
TextView displayName = (TextView) defaultAccount.findViewById(R.id.display_name);
|
||||
ImageView status = (ImageView) defaultAccount.findViewById(R.id.main_account_status);
|
||||
TextView address = (TextView) defaultAccount.findViewById(R.id.main_account_address);
|
||||
TextView displayName = (TextView) defaultAccount.findViewById(R.id.main_account_display_name);
|
||||
|
||||
|
||||
LinphoneProxyConfig proxy = LinphoneManager.getLc().getDefaultProxyConfig();
|
||||
|
@ -1422,11 +1412,11 @@ public class LinphoneActivity extends Activity implements OnClickListener, Conta
|
|||
if (convertView != null) {
|
||||
view = convertView;
|
||||
} else {
|
||||
view = getLayoutInflater().inflate(R.layout.accounts, parent, false);
|
||||
view = getLayoutInflater().inflate(R.layout.side_menu_account_cell, parent, false);
|
||||
}
|
||||
|
||||
ImageView status = (ImageView) view.findViewById(R.id.status_led);
|
||||
TextView address = (TextView) view.findViewById(R.id.address);
|
||||
ImageView status = (ImageView) view.findViewById(R.id.account_status);
|
||||
TextView address = (TextView) view.findViewById(R.id.account_address);
|
||||
String sipAddress = lpc.getAddress().asStringUriOnly();
|
||||
|
||||
address.setText(sipAddress);
|
||||
|
|
Loading…
Reference in a new issue