DroidKaigi / conference-app-2020

The Official Conference App for DroidKaigi 2020 Tokyo
https://droidkaigi.jp/2020/en/
Apache License 2.0
774 stars 327 forks source link

Use property 'shouldScroll' #581

Closed numa08 closed 4 years ago

numa08 commented 4 years ago

Issue

Overview (Required)

SessionsList.currentSessionIndex had returned 0 in spite of the session dose not started.

Screenshot

Before After

before|after

takahirom commented 4 years ago

👀

takahirom commented 4 years ago

Thank you for finding bug cause!!! Probably we can fix in SessionList like this 👍

    val currentSessionIndex by lazy {
        val lastFinished = indexOfLast { it.isFinished }
        if (lastFinished == -1) {
            // if session does not started we don't use it
            -1
        } else if (size - 1 == lastFinished) {
            // if it is last we don't use it
            -1
        } else {
            lastFinished + 1
        }
    }
numa08 commented 4 years ago

Thanks ! I'll try it !!

jmatsu-bot commented 4 years ago

Your apk has been deployed to https://deploygate.com/distributions/6fb863fe3df511e51c4b1cb0183bc077fde282c3. Anyone can try your changes via the link.

Generated by :no_entry_sign: Danger

jmatsu-bot commented 4 years ago

No issue was reported. Cool!

Generated by :no_entry_sign: Danger

takahirom commented 4 years ago

Thanks! LGTM!