-
Notifications
You must be signed in to change notification settings - Fork 528
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix #156 & #157: Continue/End Exploration player buttons- low-fi #222
Conversation
@veena14cs @nikitamarysolomanpvt This PR is not yet finished, but it can be help you if you get stuck somewhere. |
@BenHenning @veena14cs @nikitamarysolomanpvt |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left some feedback about the overall approach. Will follow up with another deep dive once you have a chance to iterate on my comments.
app/src/main/java/org/oppia/app/player/state/StateFragmentPresenter.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/org/oppia/app/player/state/StateFragmentPresenter.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/org/oppia/app/player/state/StateFragmentPresenter.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/org/oppia/app/player/state/StateFragmentPresenter.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/org/oppia/app/player/state/StateFragmentPresenter.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/org/oppia/app/player/state/StateFragmentPresenter.kt
Outdated
Show resolved
Hide resolved
// XX -> Numeric Input | ||
val stateNumericInputAnswer = 121 | ||
|
||
when (resultEphemeralState.get()!!.state.interaction.id) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similar to above--we need to generalize this. We should have a way to retrieve the current InteractionObject from the active interaction view, then pipe that to the controller.
private fun subscribeToAnswerOutcome(answerOutcomeResultLiveData: LiveData<AsyncResult<AnswerOutcome>>) { | ||
val answerOutcomeLiveData = getAnswerOutcome(answerOutcomeResultLiveData) | ||
answerOutcomeLiveData.observe(fragment, Observer<AnswerOutcome> { | ||
explorationProgressController.moveToNextState() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this right? From the mocks it seems like some interactions submit upon selecting an answer (e.g. multiple choice), and others the 'submit' button changes to 'continue' once the answer is submitted. Either way, submitting the answer and progressing to the next card always seem to be distinct user actions (except for continue since there is no explicit answer submission).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check revised implementation TODO comment.
I have created one method onOptionSelected(isOptionSelected: Boolean)
, which will control the visibility of the submit-button.
But for now I have kept this true
because, currently we don't have functionality of MultipleChoiceInput
and ItemSelectionInput
.
Assign once the new approach is implemented. |
This implementation has been changed and therefore closing this PR for now. |
Explanation
This fixes #156 and #157 and introduces following buttons which will be used in state:
Reference Design Doc: https://docs.google.com/document/d/1iD4sY_hWmWRu4eC8jGoolKQ5hsqpIV5sG1NA4YB2HL4/edit?usp=sharing
This PR was earlier on #185
Checklist