mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Add make_current to libsimpleservo
This commit is contained in:
parent
e8af185a3d
commit
02983ef39a
3 changed files with 17 additions and 0 deletions
|
@ -28,6 +28,7 @@ fn call<F>(f: F) where F: Fn(&mut ServoGlue) -> Result<(), &'static str> {
|
|||
#[repr(C)]
|
||||
pub struct CHostCallbacks {
|
||||
pub flush: extern fn(),
|
||||
pub make_current: extern fn(),
|
||||
pub on_load_started: extern fn(),
|
||||
pub on_load_ended: extern fn(),
|
||||
pub on_title_changed: extern fn(title: *const c_char),
|
||||
|
@ -223,6 +224,11 @@ impl HostTrait for HostCallbacks {
|
|||
(self.0.flush)();
|
||||
}
|
||||
|
||||
fn make_current(&self) {
|
||||
debug!("make_current");
|
||||
(self.0.make_current)();
|
||||
}
|
||||
|
||||
fn on_load_started(&self) {
|
||||
debug!("on_load_ended");
|
||||
(self.0.on_load_started)();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue