mirror of
https://github.com/moparisthebest/Yaaic
synced 2025-01-10 05:08:18 -05:00
Fixed staying in channel when conversation is closed.
This commit is contained in:
parent
64dde2de90
commit
661cae9f53
@ -10,4 +10,4 @@
|
|||||||
# Indicates whether an apk should be generated for each density.
|
# Indicates whether an apk should be generated for each density.
|
||||||
split.density=false
|
split.density=false
|
||||||
# Project target.
|
# Project target.
|
||||||
target=android-3
|
target=android-7
|
||||||
|
@ -241,6 +241,10 @@ public class ConversationActivity extends Activity implements ServiceConnection,
|
|||||||
break;
|
break;
|
||||||
case R.id.close:
|
case R.id.close:
|
||||||
Conversation conversationToClose = deckAdapter.getItem(deck.getSelectedItemPosition());
|
Conversation conversationToClose = deckAdapter.getItem(deck.getSelectedItemPosition());
|
||||||
|
// Make sure we part a channel when closing the channel conversation
|
||||||
|
if(conversationToClose.getType() == Conversation.TYPE_CHANNEL) {
|
||||||
|
binder.getService().getConnection(serverId).partChannel(conversationToClose.getName());
|
||||||
|
}
|
||||||
if (conversationToClose.getType() != Conversation.TYPE_SERVER) {
|
if (conversationToClose.getType() != Conversation.TYPE_SERVER) {
|
||||||
onRemoveConversation(conversationToClose.getName());
|
onRemoveConversation(conversationToClose.getName());
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user