Lot of little fix
This commit is contained in:
parent
58da65b26e
commit
56bf83129f
6 changed files with 15 additions and 5 deletions
|
@ -1344,6 +1344,7 @@ public class ChatFragment extends Fragment implements OnClickListener, LinphoneC
|
||||||
}
|
}
|
||||||
|
|
||||||
public void refreshHistory() {
|
public void refreshHistory() {
|
||||||
|
if (history == null || chatRoom == null) return;
|
||||||
history.clear();
|
history.clear();
|
||||||
LinphoneChatMessage[] messages = chatRoom.getHistory();
|
LinphoneChatMessage[] messages = chatRoom.getHistory();
|
||||||
history.addAll(Arrays.asList(messages));
|
history.addAll(Arrays.asList(messages));
|
||||||
|
|
|
@ -427,6 +427,8 @@ public class HistoryListFragment extends Fragment implements OnClickListener, On
|
||||||
view.setTag(holder);
|
view.setTag(holder);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (mLogs == null || mLogs.size() < position) return view;
|
||||||
|
|
||||||
final LinphoneCallLog log = mLogs.get(position);
|
final LinphoneCallLog log = mLogs.get(position);
|
||||||
long timestamp = log.getTimestamp();
|
long timestamp = log.getTimestamp();
|
||||||
LinphoneAddress address;
|
LinphoneAddress address;
|
||||||
|
|
|
@ -1683,7 +1683,8 @@ public class LinphoneActivity extends LinphoneGenericActivity implements OnClick
|
||||||
}
|
}
|
||||||
|
|
||||||
public void refreshAccounts(){
|
public void refreshAccounts(){
|
||||||
if (LinphoneManager.getLc().getProxyConfigList().length > 1) {
|
if (LinphoneManager.getLc().getProxyConfigList() != null &&
|
||||||
|
LinphoneManager.getLc().getProxyConfigList().length > 1) {
|
||||||
accountsList.setVisibility(View.VISIBLE);
|
accountsList.setVisibility(View.VISIBLE);
|
||||||
accountsList.setAdapter(new AccountsListAdapter());
|
accountsList.setAdapter(new AccountsListAdapter());
|
||||||
accountsList.setOnItemClickListener(new AdapterView.OnItemClickListener() {
|
accountsList.setOnItemClickListener(new AdapterView.OnItemClickListener() {
|
||||||
|
|
|
@ -476,6 +476,10 @@ public class LinphonePreferences {
|
||||||
LinphoneAuthInfo old_info = getAuthInfo(n);
|
LinphoneAuthInfo old_info = getAuthInfo(n);
|
||||||
try {
|
try {
|
||||||
LinphoneProxyConfig prxCfg = getProxyConfig(n);
|
LinphoneProxyConfig prxCfg = getProxyConfig(n);
|
||||||
|
if (prxCfg == null) {
|
||||||
|
Log.e("Error, no proxy config at index " + n);
|
||||||
|
return;
|
||||||
|
}
|
||||||
prxCfg.edit();
|
prxCfg.edit();
|
||||||
prxCfg.setIdentity(identity);
|
prxCfg.setIdentity(identity);
|
||||||
prxCfg.enableRegister(true);
|
prxCfg.enableRegister(true);
|
||||||
|
|
|
@ -279,7 +279,7 @@ public final class LinphoneUtils {
|
||||||
try {
|
try {
|
||||||
bm = MediaStore.Images.Media.getBitmap(c.getContentResolver(),tUri);
|
bm = MediaStore.Images.Media.getBitmap(c.getContentResolver(),tUri);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LinphoneActivity.instance().displayCustomToast("Something wrong happened", Toast.LENGTH_LONG);
|
Log.e("Error in setThumbnailPictureFromUri: " + e);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (bm != null) {
|
if (bm != null) {
|
||||||
|
|
|
@ -1351,9 +1351,11 @@ public class SettingsFragment extends PreferencesListFragment {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onPause() {
|
public void onPause() {
|
||||||
if (LinphoneManager.getInstance().getEchoTesterStatus())
|
if (LinphoneActivity.isInstanciated() && LinphoneManager.isInstanciated()) {
|
||||||
stopEchoTester();
|
if (LinphoneManager.getInstance().getEchoTesterStatus())
|
||||||
LinphoneActivity.instance().hideTopBar();
|
stopEchoTester();
|
||||||
|
LinphoneActivity.instance().hideTopBar();
|
||||||
|
}
|
||||||
super.onPause();
|
super.onPause();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue