|
|
@ -119,17 +119,14 @@ public class AutoPermissionRequester { |
|
|
|
if (fragment == null) { |
|
|
|
if (fragment == null) { |
|
|
|
fragment = AutoPermissionFragment.newInstance(); |
|
|
|
fragment = AutoPermissionFragment.newInstance(); |
|
|
|
|
|
|
|
|
|
|
|
mPermissionRequester = new PermissionRequester(ActFragWrapper.create(fragment), mPermissionCallback, mAskAgain, mShowTips, mPermissionUIProvider); |
|
|
|
|
|
|
|
fragment.setRequester(getCallback()); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
supportFragmentManager.beginTransaction() |
|
|
|
supportFragmentManager.beginTransaction() |
|
|
|
.add(fragment, AutoPermissionFragment.class.getName()) |
|
|
|
.add(fragment, AutoPermissionFragment.class.getName()) |
|
|
|
.commitNowAllowingStateLoss(); |
|
|
|
.commitNowAllowingStateLoss(); |
|
|
|
|
|
|
|
|
|
|
|
} else { |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
fragment.setRequester(getCallback()); |
|
|
|
fragment.setRequester(getCallback()); |
|
|
|
mPermissionRequester = new PermissionRequester(ActFragWrapper.create(fragment), mPermissionCallback, mAskAgain, mShowTips, mPermissionUIProvider); |
|
|
|
mPermissionRequester = new PermissionRequester(ActFragWrapper.create(fragment), mPermissionCallback, mAskAgain, mShowTips, mPermissionUIProvider); |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
fragment.startRequest(); |
|
|
|
fragment.startRequest(); |
|
|
|
} |
|
|
|
} |
|
|
|