fix build flutter
Signed-off-by: fufesou <shuanglongchen@yeah.net>
This commit is contained in:
parent
22155616e4
commit
c2648b4871
@ -46,6 +46,12 @@ lazy_static::lazy_static! {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[cfg(feature = "flutter")]
|
||||||
|
pub fn set_cur_session(session: Session<FlutterHandler>) {
|
||||||
|
*CUR_SESSION.lock().unwrap() = Some(session);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(not(feature = "flutter"))]
|
||||||
pub fn set_cur_session(session: Session<SciterHandler>) {
|
pub fn set_cur_session(session: Session<SciterHandler>) {
|
||||||
*CUR_SESSION.lock().unwrap() = Some(session);
|
*CUR_SESSION.lock().unwrap() = Some(session);
|
||||||
}
|
}
|
||||||
|
@ -130,8 +130,9 @@ pub fn start(args: &mut [String]) {
|
|||||||
pass.clone(),
|
pass.clone(),
|
||||||
args.clone(),
|
args.clone(),
|
||||||
);
|
);
|
||||||
let inner = handler.inner();
|
#[cfg(not(feature = "flutter"))]
|
||||||
crate::keyboard::set_cur_session(inner);
|
crate::keyboard::set_cur_session(handler.inner());
|
||||||
|
|
||||||
Box::new(handler)
|
Box::new(handler)
|
||||||
});
|
});
|
||||||
page = "remote.html";
|
page = "remote.html";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user