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

Allow manually displayPreferenceDialog #106

Merged
merged 3 commits into from
Nov 23, 2017
Merged

Conversation

Mygod
Copy link
Contributor

@Mygod Mygod commented Nov 9, 2017

No description provided.

@gregkorossy
Copy link
Owner

What's the use case of this? Also the Bundle b variable is unused in displayPreferenceDialog(...).

if (fragment != null) {
fragment.setArguments(b);
if (fragment instanceof DialogFragment) {
fragment.setTargetFragment(this, 0);
Copy link

@zhanghai zhanghai Nov 9, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this is going to be merged, can you move fragment.setTargetFragment(this, 0) out of the instanceof DialogFragment if so that all fragments get a reference to the preference fragment? See #87 (comment) .

@gregkorossy gregkorossy added this to the v27.0.1.1 milestone Nov 13, 2017
@gregkorossy gregkorossy merged commit 5700aa5 into gregkorossy:master Nov 23, 2017
@gregkorossy
Copy link
Owner

Merged (added some annotations to the method and removed some non-null checks). Will be released in v27.0.1.1.

@gregkorossy gregkorossy self-assigned this Nov 23, 2017
@Mygod
Copy link
Contributor Author

Mygod commented Nov 23, 2017

Yay. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants