servoshell: Remove duplicate egl bindings on android/ohos (#34716)

- The default value for SwapInterval is 1,
  so setting it to 1 changes nothing
- We don't clear the screen immediately anymore, which was the only
  useage of the egl bindings

this saves us from duplicated EGL bindings.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
This commit is contained in:
Jonathan Schwender 2024-12-20 16:08:09 +01:00 committed by GitHub
parent 65c65c9a6a
commit 0dd8798148
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
10 changed files with 6 additions and 110 deletions

View file

@ -21,7 +21,6 @@ use simpleservo::{
PromptResult, SERVO,
};
use super::gl_glue;
use super::host_trait::HostTrait;
use super::servo_glue::{Coordinates, ServoGlue};
@ -142,9 +141,7 @@ pub extern "C" fn Java_org_servo_servoview_JNIServo_init<'local>(
let wakeup = Box::new(WakeupCallback::new(callbacks_ref.clone(), &env));
let callbacks = Box::new(HostCallbacks::new(callbacks_ref, &env));
if let Err(err) = gl_glue::init()
.and_then(|egl_init| simpleservo::init(opts, egl_init.gl_wrapper, wakeup, callbacks))
{
if let Err(err) = simpleservo::init(opts, wakeup, callbacks) {
throw(&mut env, err)
};
}