silence spurious getParcelable deprecation warning

This commit is contained in:
Daniel Micay 2022-12-28 12:15:34 -05:00
parent fd510a3c19
commit 48910db7c6

View File

@ -386,7 +386,9 @@ public class PdfViewer extends AppCompatActivity implements LoaderManager.Loader
if (savedInstanceState != null) {
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.TIRAMISU) {
mUri = savedInstanceState.getParcelable(STATE_URI);
@SuppressWarnings("deprecation")
final Uri uri = savedInstanceState.getParcelable(STATE_URI);
mUri = uri;
} else {
mUri = savedInstanceState.getParcelable(STATE_URI, Uri.class);
}