mirror of
https://github.com/tachiyomiorg/tachiyomi.git
synced 2024-12-23 02:21:47 +01:00
Different approach for #214
This commit is contained in:
parent
f49577bc77
commit
5b75818fc5
@ -1,7 +1,6 @@
|
|||||||
package eu.kanade.tachiyomi.ui.reader;
|
package eu.kanade.tachiyomi.ui.reader;
|
||||||
|
|
||||||
import android.app.Dialog;
|
import android.app.Dialog;
|
||||||
import android.content.Context;
|
|
||||||
import android.content.res.Configuration;
|
import android.content.res.Configuration;
|
||||||
import android.support.v7.widget.Toolbar;
|
import android.support.v7.widget.Toolbar;
|
||||||
import android.view.Gravity;
|
import android.view.Gravity;
|
||||||
@ -9,7 +8,6 @@ import android.view.Menu;
|
|||||||
import android.view.MenuItem;
|
import android.view.MenuItem;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
import android.view.WindowManager;
|
|
||||||
import android.view.WindowManager.LayoutParams;
|
import android.view.WindowManager.LayoutParams;
|
||||||
import android.view.animation.Animation;
|
import android.view.animation.Animation;
|
||||||
import android.view.animation.AnimationUtils;
|
import android.view.animation.AnimationUtils;
|
||||||
@ -266,14 +264,11 @@ public class ReaderMenu {
|
|||||||
|
|
||||||
private void showImmersiveDialog(Dialog dialog) {
|
private void showImmersiveDialog(Dialog dialog) {
|
||||||
// Hack to not leave immersive mode
|
// Hack to not leave immersive mode
|
||||||
dialog.getWindow().setFlags(LayoutParams.FLAG_NOT_FOCUSABLE,
|
dialog.getWindow().setFlags(LayoutParams.FLAG_NOT_FOCUSABLE, LayoutParams.FLAG_NOT_FOCUSABLE);
|
||||||
LayoutParams.FLAG_NOT_FOCUSABLE);
|
dialog.show();
|
||||||
dialog.getWindow().getDecorView().setSystemUiVisibility(
|
dialog.getWindow().getDecorView().setSystemUiVisibility(
|
||||||
activity.getWindow().getDecorView().getSystemUiVisibility());
|
activity.getWindow().getDecorView().getSystemUiVisibility());
|
||||||
dialog.show();
|
|
||||||
dialog.getWindow().clearFlags(LayoutParams.FLAG_NOT_FOCUSABLE);
|
dialog.getWindow().clearFlags(LayoutParams.FLAG_NOT_FOCUSABLE);
|
||||||
WindowManager wm = (WindowManager) activity.getSystemService(Context.WINDOW_SERVICE);
|
|
||||||
wm.updateViewLayout(activity.getWindow().getDecorView(), activity.getWindow().getAttributes());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
class SettingsPopupWindow extends PopupWindow {
|
class SettingsPopupWindow extends PopupWindow {
|
||||||
|
Loading…
Reference in New Issue
Block a user