Fix date format in finish
fix some crash
This commit is contained in:
parent
6a2449f3b6
commit
acb734823c
4 changed files with 25 additions and 24 deletions
|
@ -9,11 +9,6 @@
|
|||
<string name="notification_registered">Rekisteröity kohteeseen %s</string>
|
||||
<string name="notification_register_failure">Epäonnistui rekisteröidä kohteeseen %s</string>
|
||||
<string name="sync_account_name">linphone yhteystiedot</string>
|
||||
<string name="history_date_format">VVV, p KKK esim. Maanantai, 1 Tam</string>
|
||||
<string name="history_detail_date_format">vvvv/KK/dd - TT:mm - esim 2012/11/22 - 12:34</string>
|
||||
<string name="messages_date_format">pp/KK, TT:mm esim 22/11, 12:34</string>
|
||||
<string name="messages_list_date_format">pp/KK esim 22/11</string>
|
||||
<string name="today_date_format">TT:mm esim. 11:11</string>
|
||||
<string name="picture_name_format">linphone-mms-%s.jpg</string>
|
||||
<string name="tunnel_host"></string>
|
||||
<!--Common-->
|
||||
|
|
|
@ -479,8 +479,10 @@ public class ChatFragment extends Fragment implements OnClickListener, LinphoneC
|
|||
|
||||
public void dispayMessageList() {
|
||||
messagesList.setChoiceMode(AbsListView.CHOICE_MODE_MULTIPLE);
|
||||
adapter = new ChatMessageAdapter(getActivity(), chatRoom.getHistory());
|
||||
messagesList.setAdapter(adapter);
|
||||
if(chatRoom != null) {
|
||||
adapter = new ChatMessageAdapter(getActivity(), chatRoom.getHistory());
|
||||
messagesList.setAdapter(adapter);
|
||||
}
|
||||
}
|
||||
|
||||
private void displayChatHeader(LinphoneAddress address) {
|
||||
|
@ -1049,9 +1051,11 @@ public class ChatFragment extends Fragment implements OnClickListener, LinphoneC
|
|||
|
||||
public List<ContactAddress>getContactsList(){
|
||||
List<ContactAddress> list = new ArrayList<ContactAddress>();
|
||||
for(Contact con: ContactsManager.getInstance().getAllContacts()){
|
||||
for(String numberOrAddress : con.getNumbersOrAddresses()){
|
||||
list.add(new ContactAddress(con, numberOrAddress));
|
||||
if(ContactsManager.getInstance().getAllContacts() != null) {
|
||||
for (Contact con : ContactsManager.getInstance().getAllContacts()) {
|
||||
for (String numberOrAddress : con.getNumbersOrAddresses()) {
|
||||
list.add(new ContactAddress(con, numberOrAddress));
|
||||
}
|
||||
}
|
||||
}
|
||||
return list;
|
||||
|
|
|
@ -316,19 +316,21 @@ public class StatusFragment extends Fragment {
|
|||
super.onResume();
|
||||
|
||||
LinphoneCore lc = LinphoneManager.getLcIfManagerNotDestroyedOrNull();
|
||||
LinphoneCall call = lc.getCurrentCall();
|
||||
if (isInCall && (call != null || lc.getConferenceSize() > 1 || lc.getCallsNb() > 0)) {
|
||||
if (call != null) {
|
||||
startCallQuality();
|
||||
refreshStatusItems(call, call.getCurrentParamsCopy().getVideoEnabled());
|
||||
if(lc != null) {
|
||||
LinphoneCall call = lc.getCurrentCall();
|
||||
if (isInCall && (call != null || lc.getConferenceSize() > 1 || lc.getCallsNb() > 0)) {
|
||||
if (call != null) {
|
||||
startCallQuality();
|
||||
refreshStatusItems(call, call.getCurrentParamsCopy().getVideoEnabled());
|
||||
}
|
||||
menu.setVisibility(View.INVISIBLE);
|
||||
encryption.setVisibility(View.VISIBLE);
|
||||
callQuality.setVisibility(View.VISIBLE);
|
||||
|
||||
// We are obviously connected
|
||||
statusLed.setImageResource(R.drawable.led_connected);
|
||||
statusText.setText(getString(R.string.status_connected));
|
||||
}
|
||||
menu.setVisibility(View.INVISIBLE);
|
||||
encryption.setVisibility(View.VISIBLE);
|
||||
callQuality.setVisibility(View.VISIBLE);
|
||||
|
||||
// We are obviously connected
|
||||
statusLed.setImageResource(R.drawable.led_connected);
|
||||
statusText.setText(getString(R.string.status_connected));
|
||||
} else {
|
||||
statusText.setVisibility(View.VISIBLE);
|
||||
encryption.setVisibility(View.GONE);
|
||||
|
|
|
@ -96,7 +96,7 @@ public class AssistantActivity extends Activity implements OnClickListener {
|
|||
@Override
|
||||
public void registrationState(LinphoneCore lc, LinphoneProxyConfig cfg, LinphoneCore.RegistrationState state, String smessage) {
|
||||
if(accountCreated && !newAccount){
|
||||
if(address != null && address.asString().equals(cfg.getIdentity()) ) {
|
||||
if(address != null && address.asString().equals(cfg.getAddress().asString()) ) {
|
||||
if (state == RegistrationState.RegistrationOk) {
|
||||
if(progress != null)
|
||||
progress.dismiss();
|
||||
|
@ -341,7 +341,7 @@ public class AssistantActivity extends Activity implements OnClickListener {
|
|||
e.printStackTrace();
|
||||
}
|
||||
|
||||
if(displayName != null && !displayName.equals("")){
|
||||
if(address != null && displayName != null && !displayName.equals("")){
|
||||
address.setDisplayName(displayName);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue