File tree Expand file tree Collapse file tree 6 files changed +5
-9
lines changed
src/main/java/com/example/chattutorial
src/main/java/com/example/chattutorial Expand file tree Collapse file tree 6 files changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -30,7 +30,7 @@ android {
3030
3131dependencies {
3232 // Add new dependencies
33- implementation " io.getstream:stream-chat-android-ui-components:4.17.2 "
33+ implementation " io.getstream:stream-chat-android-ui-components:4.18.0 "
3434 implementation ' io.coil-kt:coil:1.3.2'
3535
3636 implementation ' androidx.appcompat:appcompat:1.3.1'
Original file line number Diff line number Diff line change @@ -124,7 +124,7 @@ public void handleOnBackPressed() {
124124 } else {
125125 List <String > userNames = new LinkedList <>();
126126 for (User user : typingState .getUsers ()) {
127- userNames .add (( String ) user .getExtraData (). get ( "name" ));
127+ userNames .add (user .getName ( ));
128128 }
129129 String typing = "typing: " + TextUtils .join (", " , userNames );
130130 typingHeaderView .setText (typing );
Original file line number Diff line number Diff line change @@ -122,12 +122,10 @@ public void handleOnBackPressed() {
122122 event -> {
123123 if (event instanceof TypingStartEvent ) {
124124 User user = ((TypingStartEvent ) event ).getUser ();
125- String name = (String ) user .getExtraData ().get ("name" );
126- currentlyTyping .add (name );
125+ currentlyTyping .add (user .getName ());
127126 } else if (event instanceof TypingStopEvent ) {
128127 User user = ((TypingStopEvent ) event ).getUser ();
129- String name = (String ) user .getExtraData ().get ("name" );
130- currentlyTyping .remove (name );
128+ currentlyTyping .remove (user .getName ());
131129 }
132130
133131 String typing = "nobody is typing" ;
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ android {
3131
3232dependencies {
3333 // Add new dependencies
34- implementation " io.getstream:stream-chat-android-ui-components:4.17.2 "
34+ implementation " io.getstream:stream-chat-android-ui-components:4.18.0 "
3535 implementation ' io.coil-kt:coil:1.3.2'
3636 implementation " androidx.activity:activity-ktx:1.3.1"
3737
Original file line number Diff line number Diff line change @@ -13,7 +13,6 @@ import com.getstream.sdk.chat.viewmodel.messages.MessageListViewModel.Mode.Norma
1313import com.getstream.sdk.chat.viewmodel.messages.MessageListViewModel.Mode.Thread
1414import com.getstream.sdk.chat.viewmodel.messages.MessageListViewModel.State.NavigateUp
1515import io.getstream.chat.android.client.models.Channel
16- import io.getstream.chat.android.client.models.name
1716import io.getstream.chat.android.livedata.ChatDomain
1817import io.getstream.chat.android.ui.message.input.viewmodel.bindView
1918import io.getstream.chat.android.ui.message.list.header.viewmodel.MessageListHeaderViewModel
Original file line number Diff line number Diff line change @@ -17,7 +17,6 @@ import io.getstream.chat.android.client.channel.subscribeFor
1717import io.getstream.chat.android.client.events.TypingStartEvent
1818import io.getstream.chat.android.client.events.TypingStopEvent
1919import io.getstream.chat.android.client.models.Channel
20- import io.getstream.chat.android.client.models.name
2120import io.getstream.chat.android.ui.message.input.viewmodel.bindView
2221import io.getstream.chat.android.ui.message.list.header.viewmodel.MessageListHeaderViewModel
2322import io.getstream.chat.android.ui.message.list.header.viewmodel.bindView
You can’t perform that action at this time.
0 commit comments