use of androidx.fragment.app.DialogFragment in project EhViewer by seven332.
the class HostsActivity method onItemClick.
@Override
public boolean onItemClick(EasyRecyclerView easyRecyclerView, View view, int position, long id) {
Pair<String, String> pair = data.get(position);
Bundle args = new Bundle();
args.putString(KEY_HOST, pair.first);
args.putString(KEY_IP, pair.second);
DialogFragment fragment = new EditHostDialogFragment();
fragment.setArguments(args);
fragment.show(getSupportFragmentManager(), DIALOG_TAG_EDIT_HOST);
return true;
}
use of androidx.fragment.app.DialogFragment in project Slide by ccrama.
the class FolderChooserDialogCreate method show.
public void show(final FragmentManager fragmentManager) {
final String tag = getBuilder().tag;
final Fragment frag = fragmentManager.findFragmentByTag(tag);
if (frag != null) {
((DialogFragment) frag).dismiss();
fragmentManager.beginTransaction().remove(frag).commit();
}
show(fragmentManager, tag);
}
use of androidx.fragment.app.DialogFragment in project Signal-Android by signalapp.
the class CorrectedPreferenceFragment method onDisplayPreferenceDialog.
@Override
public void onDisplayPreferenceDialog(Preference preference) {
DialogFragment dialogFragment = null;
if (preference instanceof ColorPickerPreference) {
dialogFragment = ColorPickerPreferenceDialogFragmentCompat.newInstance(preference.getKey());
} else if (preference instanceof CustomDefaultPreference) {
dialogFragment = CustomDefaultPreference.CustomDefaultPreferenceDialogFragmentCompat.newInstance(preference.getKey());
}
if (dialogFragment != null) {
dialogFragment.setTargetFragment(this, 0);
dialogFragment.show(getFragmentManager(), "android.support.v7.preference.PreferenceFragment.DIALOG");
} else {
super.onDisplayPreferenceDialog(preference);
}
}
use of androidx.fragment.app.DialogFragment in project Signal-Android by signalapp.
the class ReactWithAnyEmojiBottomSheetDialogFragment method createForAboutSelection.
public static DialogFragment createForAboutSelection() {
DialogFragment fragment = new ReactWithAnyEmojiBottomSheetDialogFragment();
Bundle args = new Bundle();
args.putLong(ARG_MESSAGE_ID, -1);
args.putBoolean(ARG_IS_MMS, false);
args.putInt(ARG_START_PAGE, -1);
args.putString(ARG_RECENT_KEY, ABOUT_STORAGE_KEY);
fragment.setArguments(args);
return fragment;
}
use of androidx.fragment.app.DialogFragment in project Signal-Android by signalapp.
the class LongMessageFragment method create.
public static DialogFragment create(long messageId, boolean isMms) {
DialogFragment fragment = new LongMessageFragment();
Bundle args = new Bundle();
args.putLong(KEY_MESSAGE_ID, messageId);
args.putBoolean(KEY_IS_MMS, isMms);
fragment.setArguments(args);
return fragment;
}
Aggregations