Fix some older deprecations from previous Fragment versions
This commit is contained in:
parent
9591f14551
commit
e4885e3c52
|
@ -23,13 +23,9 @@ public class ImportConfirmationDialog extends DialogFragment {
|
|||
|
||||
public static void show(@NonNull final Fragment fragment,
|
||||
@NonNull final Intent resultServiceIntent) {
|
||||
if (fragment.getFragmentManager() == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
final ImportConfirmationDialog confirmationDialog = new ImportConfirmationDialog();
|
||||
confirmationDialog.setResultServiceIntent(resultServiceIntent);
|
||||
confirmationDialog.show(fragment.getFragmentManager(), null);
|
||||
confirmationDialog.show(fragment.getParentFragmentManager(), null);
|
||||
}
|
||||
|
||||
public void setResultServiceIntent(final Intent resultServiceIntent) {
|
||||
|
|
|
@ -198,7 +198,7 @@ class SubscriptionFragment : BaseStateFragment<SubscriptionState>() {
|
|||
}
|
||||
|
||||
private fun openReorderDialog() {
|
||||
FeedGroupReorderDialog().show(requireFragmentManager(), null)
|
||||
FeedGroupReorderDialog().show(parentFragmentManager, null)
|
||||
}
|
||||
|
||||
override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
|
||||
|
|
|
@ -192,13 +192,13 @@ public class ChooseTabsFragment extends Fragment {
|
|||
final SelectKioskFragment selectKioskFragment = new SelectKioskFragment();
|
||||
selectKioskFragment.setOnSelectedListener((serviceId, kioskId, kioskName) ->
|
||||
addTab(new Tab.KioskTab(serviceId, kioskId)));
|
||||
selectKioskFragment.show(requireFragmentManager(), "select_kiosk");
|
||||
selectKioskFragment.show(getParentFragmentManager(), "select_kiosk");
|
||||
return;
|
||||
case CHANNEL:
|
||||
final SelectChannelFragment selectChannelFragment = new SelectChannelFragment();
|
||||
selectChannelFragment.setOnSelectedListener((serviceId, url, name) ->
|
||||
addTab(new Tab.ChannelTab(serviceId, url, name)));
|
||||
selectChannelFragment.show(requireFragmentManager(), "select_channel");
|
||||
selectChannelFragment.show(getParentFragmentManager(), "select_channel");
|
||||
return;
|
||||
case PLAYLIST:
|
||||
final SelectPlaylistFragment selectPlaylistFragment = new SelectPlaylistFragment();
|
||||
|
@ -215,7 +215,7 @@ public class ChooseTabsFragment extends Fragment {
|
|||
addTab(new Tab.PlaylistTab(serviceId, url, name));
|
||||
}
|
||||
});
|
||||
selectPlaylistFragment.show(requireFragmentManager(), "select_playlist");
|
||||
selectPlaylistFragment.show(getParentFragmentManager(), "select_playlist");
|
||||
return;
|
||||
default:
|
||||
addTab(type.getTab());
|
||||
|
|
|
@ -66,16 +66,14 @@ public enum StreamDialogEntry {
|
|||
}), // has to be set manually
|
||||
|
||||
append_playlist(R.string.append_playlist, (fragment, item) -> {
|
||||
if (fragment.getFragmentManager() != null) {
|
||||
final PlaylistAppendDialog d = PlaylistAppendDialog
|
||||
.fromStreamInfoItems(Collections.singletonList(item));
|
||||
|
||||
PlaylistAppendDialog.onPlaylistFound(fragment.getContext(),
|
||||
() -> d.show(fragment.getFragmentManager(), "StreamDialogEntry@append_playlist"),
|
||||
() -> d.show(fragment.getParentFragmentManager(), "StreamDialogEntry@append_playlist"),
|
||||
() -> PlaylistCreationDialog.newInstance(d)
|
||||
.show(fragment.getFragmentManager(), "StreamDialogEntry@create_playlist")
|
||||
.show(fragment.getParentFragmentManager(), "StreamDialogEntry@create_playlist")
|
||||
);
|
||||
}
|
||||
}),
|
||||
|
||||
play_with_kodi(R.string.play_with_kodi_title, (fragment, item) -> {
|
||||
|
|
Loading…
Reference in New Issue