Revert "solve API 30 deprecation with getSystemWindowInsetTop"
This reverts commit 851dd55d43
.
This commit is contained in:
parent
17db928149
commit
993923ff92
@ -6,7 +6,6 @@ import android.content.Intent;
|
|||||||
import android.content.res.ColorStateList;
|
import android.content.res.ColorStateList;
|
||||||
import android.graphics.Color;
|
import android.graphics.Color;
|
||||||
import android.net.Uri;
|
import android.net.Uri;
|
||||||
import android.os.Build;
|
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.util.Log;
|
import android.util.Log;
|
||||||
import android.view.Gravity;
|
import android.view.Gravity;
|
||||||
@ -165,10 +164,7 @@ public class PdfViewer extends AppCompatActivity implements LoaderManager.Loader
|
|||||||
}
|
}
|
||||||
|
|
||||||
mWebView.setOnApplyWindowInsetsListener((view, insets) -> {
|
mWebView.setOnApplyWindowInsetsListener((view, insets) -> {
|
||||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R)
|
windowInsetTop = insets.getSystemWindowInsetTop();
|
||||||
insets.getInsets(windowInsetTop);
|
|
||||||
else
|
|
||||||
windowInsetTop = insets.getSystemWindowInsetTop();
|
|
||||||
mWebView.evaluateJavascript("updateInset()", null);
|
mWebView.evaluateJavascript("updateInset()", null);
|
||||||
return insets;
|
return insets;
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user