Skip to content

Commit

Permalink
update portrait
Browse files Browse the repository at this point in the history
  • Loading branch information
imndx committed Apr 14, 2019
1 parent 88df200 commit 2ac7dc4
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ private void init() {

conversationListViewModel.connectionStatusLiveData().observe(this, status -> {
switch (status) {
case ConnectionStatus.ConnectionStatusConnectiong:
case ConnectionStatus.ConnectionStatusConnecting:
showNotification(ConnectionNotification.class, "正在连接...");
break;
case ConnectionStatus.ConnectionStatusConnected:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,14 @@ void alias() {

@OnClick(R.id.portraitImageView)
void portrait() {
if (userInfo.uid.equals(userViewModel.getUserId())) {
updatePortrait();
} else {
// TODO show big portrait
}
}

private void updatePortrait() {
ImagePicker.picker().pick(this, REQUEST_CODE_PICK_IMAGE);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ public interface ConnectionStatus {
int ConnectionStatusRejected = -3;
int ConnectionStatusLogout = -2;
int ConnectionStatusUnconnected = -1;
int ConnectionStatusConnectiong = 0;
int ConnectionStatusConnecting = 0;
int ConnectionStatusConnected = 1;
int ConnectionStatusReceiveing = 2;
}

0 comments on commit 2ac7dc4

Please sign in to comment.