Skip to content
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

Singleton class in domain to manage configuration changes #1737

Closed
rt4914 opened this issue Aug 28, 2020 · 5 comments
Closed

Singleton class in domain to manage configuration changes #1737

rt4914 opened this issue Aug 28, 2020 · 5 comments
Labels
Priority: Essential This work item must be completed for its milestone. Type: Task A single task of work corresponding to a greater milestone. Generally corresponds to a single PR. Z-ibt Temporary label for Ben to keep track of issues he's triaged.

Comments

@rt4914
Copy link
Contributor

rt4914 commented Aug 28, 2020

Currently in exploration player and question player, on orientation change the application does not retain the user input answer in InputInteractions.
To manage this effectively, we should introduce a singleton class in domain layer which will be linked to pending answer such that we can save information to this singleton class as soon as the input answer changes and again we can fetch this information back on configuration change.

@rt4914 rt4914 added Priority: Essential This work item must be completed for its milestone. Status: Not started Type: Task A single task of work corresponding to a greater milestone. Generally corresponds to a single PR. labels Aug 28, 2020
@rt4914 rt4914 added this to the Beta milestone Aug 28, 2020
@BenHenning
Copy link
Member

NB: we should keep this solution specific to interactions now rather than developing a general-purpose replacement to savedInstanceState (since it's not clear that we actually want that yet).

@FareesHussain
Copy link
Contributor

@rt4914 I would like to work on this, Is there any similar implementation for reference

@rt4914
Copy link
Contributor Author

rt4914 commented Dec 29, 2020

@rt4914 I would like to work on this, Is there any similar implementation for reference

@FareesHussain No we don't have any similar implementation.

@FareesHussain
Copy link
Contributor

@BenHenning I've tried to understand working of StatePlayerRecyclerViewAssembler

Here in this issue we need to solve the following issues based on addInteractionSupport in StatePlayerRecyclerViewAssembler

  • text and error message in [FractionInteractionView.kt]
  • list of selected checkboxes in [SelectionInteractionView.kt]
  • text(integer) and error msg for [NumericInputInteractionView.kt]
  • text and error message for [RatioInputInteractionView.kt]
  • text for [TextInputInteractionView.kt]
  • list for drag & drop [DragDropSortInteractionView.kt]
  • list for drag & drop with merging [DragDropSortInteractionView.kt]
  • selected image in the [ImageRegionSelectionInteractionView.kt]

So for this issue i need to save and restore the above infomation using onSavedInstance in the StateFragmentPresenter and StateFragment

but how will i know the which type of InputInteraction is used in a particular StateFragment

@BenHenning BenHenning reopened this Jul 28, 2022
@BenHenning
Copy link
Member

I think we want to close this as 'Not planned' since it's being replaced by #4470 (which is a different solution) @vrajdesai78.

@BenHenning BenHenning closed this as not planned Won't fix, can't repro, duplicate, stale Jul 28, 2022
@BenHenning BenHenning added the Z-ibt Temporary label for Ben to keep track of issues he's triaged. label Sep 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority: Essential This work item must be completed for its milestone. Type: Task A single task of work corresponding to a greater milestone. Generally corresponds to a single PR. Z-ibt Temporary label for Ben to keep track of issues he's triaged.
4 participants