Skip to content
Snippets Groups Projects

Finalizing Connection transitions

Merged ankitgusai19 requested to merge finalizing-basic-transitions into main

-optimized transition animations into single av_* drawables. -Moved back toolbar from MainActivity to ConnectFragment as the progressbar is only heavily used in ConnectFragment. -ConnectFragmentViewModel optimized, made it reactive with StateFlow, and solved animation discrepancy in case of stopping and resuming activity

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
91 ConnectionState.INIT -> {
92 binding.tvConnectActionBtn.setBackgroundResource(R.drawable.av_green_to_purple)
93 binding.tvConnectActionBtn.setText(R.string.frag_connect_connect)
94 binding.ivConnectBtnOverlay.visibility = View.GONE
95 }
96 ConnectionState.CONNECTING -> {
97 if (vpnState.animate) {
98 idleToConnectingTransition()
82 private fun setUIState(vpnState: ConnectionState) {
83 if (::currentVpnState.isInitialized && currentVpnState == vpnState) {
84 return
85 }
86
87 when (vpnState) {
88 ConnectionState.INIT -> {}
89 ConnectionState.CONNECTING -> idleToConnectingTransition()
  • deducing the last state is maybe too opinionated and might be error prone.

    I would prefer if we either compare the last state so that we can for example make sure idleToConnectingTransition is the right transition between the last and the current state. Alternatively the transitions need to be double checked how generic they are, so that they animate correctly between different last states to the current one. Did you do that already?

    Edited by cyberta
  • hm, on a first glance the transition methods take either particular last states deliberately into account or are not dependend on them at all. So maybe just the method naming confuses me.

  • ankitgusai19 changed this line in version 5 of the diff

    changed this line in version 5 of the diff

  • Please register or sign in to reply
  • cyberta mentioned in issue #39 (closed)

    mentioned in issue #39 (closed)

  • @cyberta I will fix this one. I have also worked on the guide/error/connected stats screen.

  • ankitgusai19 added 1 commit

    added 1 commit

    Compare with previous version

  • Btw, @cyberta This commit also has the custom switch that you can use in the configuration part.

    I should be able to wrap this MR by the end of this week :), which more or less completes pre-alpha design for connect.

    Edited by ankitgusai19
  • cyberta
  • ankitgusai19 added 1 commit

    added 1 commit

    • a262b8ee - -BottomNAvigationBar style completed

    Compare with previous version

  • ankitgusai19 marked this merge request as ready

    marked this merge request as ready

  • ankitgusai19 changed title from Draft: finalizing Connection transitions to Finalizing Connection transitions

    changed title from Draft: finalizing Connection transitions to Finalizing Connection transitions

  • @cyberta This seems ready to merge.

  • cyberta
  • cyberta
  • cyberta
  • Nice work! I would like to request only some minor changes.

  • ankitgusai19 added 1 commit

    added 1 commit

    • 107bf521 - -Transition methods names changed

    Compare with previous version

  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading