Fix InstantiationException on fragment
Since we overrided the empty constructor, it can't find a empty constructor when Fragment tries to instantiate a fragment in framework. So, we can't override this constructor, and then just use newInstance() to initialize and setup a new Fragment. Test: robotest Change-Id: Ifcd1c1771bc69d947caeee5c5bc055c4f94365c2 Fixes: 115676209
This commit is contained in:
@@ -113,7 +113,7 @@ public class ProxySelector extends InstrumentedFragment implements DialogCreatab
|
||||
if (mDialogFragment != null) {
|
||||
Log.e(TAG, "Old dialog fragment not null!");
|
||||
}
|
||||
mDialogFragment = new SettingsDialogFragment(this, dialogId);
|
||||
mDialogFragment = SettingsDialogFragment.newInstance(this, dialogId);
|
||||
mDialogFragment.show(getActivity().getSupportFragmentManager(), Integer.toString(dialogId));
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user