Implement screen reseeding
This commit is contained in:
parent
e848c8894c
commit
87f9e2de01
@ -112,8 +112,7 @@ public class LoriePreferences extends AppCompatActivity implements SharedPrefere
|
|||||||
} else e.printStackTrace();
|
} else e.printStackTrace();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}return true;
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -236,7 +236,7 @@ public class LorieService extends Service {
|
|||||||
@SuppressWarnings("SameParameterValue")
|
@SuppressWarnings("SameParameterValue")
|
||||||
private static class ServiceEventListener implements SurfaceHolder.Callback, View.OnTouchListener, View.OnKeyListener, View.OnHoverListener, View.OnGenericMotionListener, TouchParser.OnTouchParseListener {
|
private static class ServiceEventListener implements SurfaceHolder.Callback, View.OnTouchListener, View.OnKeyListener, View.OnHoverListener, View.OnGenericMotionListener, TouchParser.OnTouchParseListener {
|
||||||
LorieService svc;
|
LorieService svc;
|
||||||
|
|
||||||
private void setAsListenerTo(SurfaceView view) {
|
private void setAsListenerTo(SurfaceView view) {
|
||||||
view.getHolder().addCallback(this);
|
view.getHolder().addCallback(this);
|
||||||
view.setOnTouchListener(this);
|
view.setOnTouchListener(this);
|
||||||
|
@ -100,6 +100,11 @@ public class MainActivity extends AppCompatActivity {
|
|||||||
window.clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
|
window.clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
|
||||||
decorView.setSystemUiVisibility(0);
|
decorView.setSystemUiVisibility(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (preferences.getBoolean("Reseed", true))
|
||||||
|
{
|
||||||
|
window.setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_ADJUST_RESIZE);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -18,4 +18,10 @@
|
|||||||
android:defaultValue="false"
|
android:defaultValue="false"
|
||||||
android:key="showIMEWhileExternalConnected"
|
android:key="showIMEWhileExternalConnected"
|
||||||
android:summary="Show software keyboard while hardware keyboard is connected" />
|
android:summary="Show software keyboard while hardware keyboard is connected" />
|
||||||
|
<CheckBoxPreference
|
||||||
|
android:title="Reseed Screen While Soft Keybourd is open"
|
||||||
|
android:defaultValue="false"
|
||||||
|
android:key="Reseed"
|
||||||
|
android:summary="The screen size will be adjusted while Soft Keybourd is open" />
|
||||||
|
|
||||||
</PreferenceScreen>
|
</PreferenceScreen>
|
||||||
|
Loading…
Reference in New Issue
Block a user