From c0d625252e6d5c8b93bf029b7c1ef87d349c420f Mon Sep 17 00:00:00 2001 From: Philipp Auersperg-Castell Date: Mon, 3 Jun 2019 22:59:28 +0200 Subject: [PATCH] disable orientation and window option for service_only bootstrap --- buildozer/targets/android.py | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/buildozer/targets/android.py b/buildozer/targets/android.py index 28d2453..d85dc9c 100644 --- a/buildozer/targets/android.py +++ b/buildozer/targets/android.py @@ -981,16 +981,17 @@ class TargetAndroid(Target): build_cmd += [("--ouya-icon", join(self.buildozer.root_dir, ouya_icon))] - # add orientation - orientation = config.getdefault('app', 'orientation', 'landscape') - if orientation == 'all': - orientation = 'sensor' - build_cmd += [("--orientation", orientation)] + if config.getdefault('app','p4a.bootstrap','sdl2') != 'service_only': + # add orientation + orientation = config.getdefault('app', 'orientation', 'landscape') + if orientation == 'all': + orientation = 'sensor' + build_cmd += [("--orientation", orientation)] - # fullscreen ? - fullscreen = config.getbooldefault('app', 'fullscreen', True) - if not fullscreen: - build_cmd += [("--window", )] + # fullscreen ? + fullscreen = config.getbooldefault('app', 'fullscreen', True) + if not fullscreen: + build_cmd += [("--window", )] # wakelock ? wakelock = config.getbooldefault('app', 'android.wakelock', False)