Merge pull request #14964 from amerhifi/feature/quest

fixing compile errors
This commit is contained in:
Bradley Austin Davis 2019-02-19 16:17:18 -08:00 committed by GitHub
commit c912f2f7d7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 6 deletions

View file

@ -81,6 +81,7 @@ public class InterfaceActivity extends QtActivity implements WebViewFragment.OnW
private boolean nativeEnterBackgroundCallEnqueued = false; private boolean nativeEnterBackgroundCallEnqueued = false;
private SlidingDrawer mWebSlidingDrawer; private SlidingDrawer mWebSlidingDrawer;
private boolean mStartInDomain; private boolean mStartInDomain;
private boolean isLoading;
// private GvrApi gvrApi; // private GvrApi gvrApi;
// Opaque native pointer to the Application C++ object. // Opaque native pointer to the Application C++ object.
// This object is owned by the InterfaceActivity instance and passed to the native methods. // This object is owned by the InterfaceActivity instance and passed to the native methods.
@ -94,7 +95,7 @@ public class InterfaceActivity extends QtActivity implements WebViewFragment.OnW
@Override @Override
public void onCreate(Bundle savedInstanceState) { public void onCreate(Bundle savedInstanceState) {
super.isLoading = true; isLoading = true;
Intent intent = getIntent(); Intent intent = getIntent();
if (intent.hasExtra(DOMAIN_URL) && !TextUtils.isEmpty(intent.getStringExtra(DOMAIN_URL))) { if (intent.hasExtra(DOMAIN_URL) && !TextUtils.isEmpty(intent.getStringExtra(DOMAIN_URL))) {
intent.putExtra("applicationArguments", "--url " + intent.getStringExtra(DOMAIN_URL)); intent.putExtra("applicationArguments", "--url " + intent.getStringExtra(DOMAIN_URL));
@ -145,7 +146,7 @@ public class InterfaceActivity extends QtActivity implements WebViewFragment.OnW
@Override @Override
protected void onPause() { protected void onPause() {
super.onPause(); super.onPause();
if (super.isLoading) { if (isLoading) {
nativeEnterBackgroundCallEnqueued = true; nativeEnterBackgroundCallEnqueued = true;
} else { } else {
nativeEnterBackground(); nativeEnterBackground();
@ -172,7 +173,6 @@ public class InterfaceActivity extends QtActivity implements WebViewFragment.OnW
super.onResume(); super.onResume();
nativeEnterForeground(); nativeEnterForeground();
surfacesWorkaround(); surfacesWorkaround();
keepInterfaceRunning = false;
registerReceiver(headsetStateReceiver, new IntentFilter(Intent.ACTION_HEADSET_PLUG)); registerReceiver(headsetStateReceiver, new IntentFilter(Intent.ACTION_HEADSET_PLUG));
//gvrApi.resumeTracking(); //gvrApi.resumeTracking();
} }
@ -382,7 +382,7 @@ public class InterfaceActivity extends QtActivity implements WebViewFragment.OnW
} }
public void onAppLoadedComplete() { public void onAppLoadedComplete() {
super.isLoading = false; isLoading = false;
if (nativeEnterBackgroundCallEnqueued) { if (nativeEnterBackgroundCallEnqueued) {
nativeEnterBackground(); nativeEnterBackground();
} }
@ -413,7 +413,6 @@ public class InterfaceActivity extends QtActivity implements WebViewFragment.OnW
@Override @Override
public void onExpand() { public void onExpand() {
keepInterfaceRunning = true;
} }
@Override @Override

View file

@ -167,7 +167,7 @@ TransformObject getTransformObject() {
vec4 eyeClipEdge[2]= vec4[2](vec4(-1,0,0,1), vec4(1,0,0,1)); vec4 eyeClipEdge[2]= vec4[2](vec4(-1,0,0,1), vec4(1,0,0,1));
vec2 eyeOffsetScale = vec2(-0.5, +0.5); vec2 eyeOffsetScale = vec2(-0.5, +0.5);
uint eyeIndex = uint(_stereoSide); uint eyeIndex = uint(_stereoSide);
#if !defined(GPU_GLES) || !defined(VULKAN) #if !defined(GPU_GLES) || (defined(HAVE_EXT_clip_cull_distance) && !defined(VULKAN))
gl_ClipDistance[0] = dot(<$clipPos$>, eyeClipEdge[eyeIndex]); gl_ClipDistance[0] = dot(<$clipPos$>, eyeClipEdge[eyeIndex]);
#endif #endif
float newClipPosX = <$clipPos$>.x * 0.5 + eyeOffsetScale[eyeIndex] * <$clipPos$>.w; float newClipPosX = <$clipPos$>.x * 0.5 + eyeOffsetScale[eyeIndex] * <$clipPos$>.w;