mirror of
https://github.com/oxen-io/session-android.git
synced 2024-11-25 11:05:25 +00:00
Compilation errors after merge
This commit is contained in:
parent
677cd6a7cf
commit
6ab4ff2e28
@ -113,6 +113,7 @@ import javax.inject.Inject;
|
|||||||
|
|
||||||
import dagger.hilt.EntryPoints;
|
import dagger.hilt.EntryPoints;
|
||||||
import dagger.hilt.android.HiltAndroidApp;
|
import dagger.hilt.android.HiltAndroidApp;
|
||||||
|
import kotlin.Unit;
|
||||||
import network.loki.messenger.BuildConfig;
|
import network.loki.messenger.BuildConfig;
|
||||||
import network.loki.messenger.R;
|
import network.loki.messenger.R;
|
||||||
|
|
||||||
|
@ -898,8 +898,6 @@ class ConversationActivityV2 : PassphraseRequiredActionBarActivity(), InputBarDe
|
|||||||
if (!isFinishing) {
|
if (!isFinishing) {
|
||||||
finish()
|
finish()
|
||||||
}
|
}
|
||||||
|
|
||||||
binding.inputBar.isGone = uiState.hideInputBar
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -908,7 +906,7 @@ class ConversationActivityV2 : PassphraseRequiredActionBarActivity(), InputBarDe
|
|||||||
lifecycleScope.launch {
|
lifecycleScope.launch {
|
||||||
repeatOnLifecycle(Lifecycle.State.STARTED) {
|
repeatOnLifecycle(Lifecycle.State.STARTED) {
|
||||||
viewModel.uiState.collect { state ->
|
viewModel.uiState.collect { state ->
|
||||||
binding?.inputBar?.run {
|
binding.inputBar.run {
|
||||||
isVisible = state.showInput
|
isVisible = state.showInput
|
||||||
showMediaControls = state.enableInputMediaControls
|
showMediaControls = state.enableInputMediaControls
|
||||||
}
|
}
|
||||||
|
@ -89,8 +89,6 @@ class ConversationViewModel(
|
|||||||
return repository.getInvitingAdmin(threadId)
|
return repository.getInvitingAdmin(threadId)
|
||||||
}
|
}
|
||||||
|
|
||||||
private var communityWriteAccessJob: Job? = null
|
|
||||||
|
|
||||||
private var _openGroup: RetrieveOnce<OpenGroup> = RetrieveOnce {
|
private var _openGroup: RetrieveOnce<OpenGroup> = RetrieveOnce {
|
||||||
storage.getOpenGroup(threadId)
|
storage.getOpenGroup(threadId)
|
||||||
}
|
}
|
||||||
@ -150,27 +148,6 @@ class ConversationViewModel(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// listen to community write access updates from this point
|
|
||||||
communityWriteAccessJob?.cancel()
|
|
||||||
communityWriteAccessJob = viewModelScope.launch {
|
|
||||||
OpenGroupManager.getCommunitiesWriteAccessFlow()
|
|
||||||
.map {
|
|
||||||
if(openGroup?.groupId != null)
|
|
||||||
it[openGroup?.groupId]
|
|
||||||
else null
|
|
||||||
}
|
|
||||||
.filterNotNull()
|
|
||||||
.collect{
|
|
||||||
// update our community object
|
|
||||||
_openGroup.updateTo(openGroup?.copy(canWrite = it))
|
|
||||||
// when we get an update on the write access of a community
|
|
||||||
// we need to update the input text accordingly
|
|
||||||
_uiState.update { state ->
|
|
||||||
state.copy(hideInputBar = shouldHideInputBar())
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -29,6 +29,7 @@ import org.session.libsession.messaging.groups.GroupManagerV2
|
|||||||
import org.session.libsession.messaging.sending_receiving.MessageSender
|
import org.session.libsession.messaging.sending_receiving.MessageSender
|
||||||
import org.session.libsession.messaging.sending_receiving.leave
|
import org.session.libsession.messaging.sending_receiving.leave
|
||||||
import org.session.libsession.utilities.GroupUtil.doubleDecodeGroupID
|
import org.session.libsession.utilities.GroupUtil.doubleDecodeGroupID
|
||||||
|
import org.session.libsession.utilities.StringSubstitutionConstants.APP_NAME_KEY
|
||||||
import org.session.libsession.utilities.StringSubstitutionConstants.GROUP_NAME_KEY
|
import org.session.libsession.utilities.StringSubstitutionConstants.GROUP_NAME_KEY
|
||||||
import org.session.libsession.utilities.TextSecurePreferences
|
import org.session.libsession.utilities.TextSecurePreferences
|
||||||
import org.session.libsession.utilities.recipients.Recipient
|
import org.session.libsession.utilities.recipients.Recipient
|
||||||
|
Loading…
Reference in New Issue
Block a user