Minor UI fix for generic SIP login + added scrolling to side menu
This commit is contained in:
parent
804bf6dc64
commit
78e66d4cf2
2 changed files with 131 additions and 125 deletions
|
@ -74,11 +74,12 @@ class GenericLoginViewModel(private val accountCreator: AccountCreator) : ViewMo
|
||||||
) {
|
) {
|
||||||
if (cfg == proxyConfigToCheck) {
|
if (cfg == proxyConfigToCheck) {
|
||||||
Log.i("[Assistant] [Generic Login] Registration state is $state: $message")
|
Log.i("[Assistant] [Generic Login] Registration state is $state: $message")
|
||||||
waitForServerAnswer.value = false
|
|
||||||
if (state == RegistrationState.Ok) {
|
if (state == RegistrationState.Ok) {
|
||||||
|
waitForServerAnswer.value = false
|
||||||
leaveAssistantEvent.value = Event(true)
|
leaveAssistantEvent.value = Event(true)
|
||||||
core.removeListener(this)
|
core.removeListener(this)
|
||||||
} else if (state == RegistrationState.Failed) {
|
} else if (state == RegistrationState.Failed) {
|
||||||
|
waitForServerAnswer.value = false
|
||||||
invalidCredentialsEvent.value = Event(true)
|
invalidCredentialsEvent.value = Event(true)
|
||||||
core.removeListener(this)
|
core.removeListener(this)
|
||||||
}
|
}
|
||||||
|
|
|
@ -118,22 +118,25 @@
|
||||||
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
|
<androidx.core.widget.NestedScrollView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_below="@id/main_account"
|
||||||
|
android:layout_above="@id/side_menu_quit">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:visibility="@{viewModel.showAccounts ? View.VISIBLE : View.GONE}"
|
android:visibility="@{viewModel.showAccounts ? View.VISIBLE : View.GONE}"
|
||||||
android:id="@+id/additional_accounts"
|
|
||||||
android:layout_below="@id/main_account"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
app:entries="@{viewModel.accounts}"
|
app:entries="@{viewModel.accounts}"
|
||||||
app:layout="@{@layout/side_menu_account_cell}"/>
|
app:layout="@{@layout/side_menu_account_cell}"/>
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_below="@id/additional_accounts"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="vertical">
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:onClick="@{assistantClickListener}"
|
android:onClick="@{assistantClickListener}"
|
||||||
android:visibility="@{viewModel.showAssistant ? View.VISIBLE : View.GONE}"
|
android:visibility="@{viewModel.showAssistant ? View.VISIBLE : View.GONE}"
|
||||||
|
@ -252,6 +255,8 @@
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
</androidx.core.widget.NestedScrollView>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/side_menu_quit"
|
android:id="@+id/side_menu_quit"
|
||||||
android:onClick="@{quitClickListener}"
|
android:onClick="@{quitClickListener}"
|
||||||
|
|
Loading…
Reference in a new issue