--- a/src/com/beem/project/beem/service/XmppConnectionAdapter.java Mon Sep 05 18:01:49 2011 +0200
+++ b/src/com/beem/project/beem/service/XmppConnectionAdapter.java Mon Sep 05 18:10:16 2011 +0200
@@ -417,7 +417,7 @@
/**
* Get the user informations.
*
- * @return the user infos
+ * @return the user infos or null if not logged
*/
public UserInfo getUserInfo() {
return mUserInfo;
--- a/src/com/beem/project/beem/service/aidl/IXmppFacade.aidl Mon Sep 05 18:01:49 2011 +0200
+++ b/src/com/beem/project/beem/service/aidl/IXmppFacade.aidl Mon Sep 05 18:10:16 2011 +0200
@@ -103,6 +103,10 @@
void disableAvatarPublishing();
+ /**
+ * Get the user informations.
+ * @return null if not connected
+ */
UserInfo getUserInfo();
IPrivacyListManager getPrivacyListManager();
--- a/src/com/beem/project/beem/ui/ChangeStatus.java Mon Sep 05 18:01:49 2011 +0200
+++ b/src/com/beem/project/beem/ui/ChangeStatus.java Mon Sep 05 18:10:16 2011 +0200
@@ -355,8 +355,10 @@
private void displayCurrentAvatar() {
try {
UserInfo ui = mXmppFacade.getUserInfo();
+ if (ui == null)
+ return;
String avatarId = ui.getAvatarId();
- Log.d(TAG, "User info ; avatar id " + avatarId);
+ Log.d(TAG, "User info : avatar id " + avatarId);
if (avatarId != null) {
Uri uri = AvatarProvider.CONTENT_URI.buildUpon().appendPath(avatarId).build();
mAvatar.setImageURI(uri);