fix, sciter, dpi awareness
Signed-off-by: fufesou <shuanglongchen@yeah.net>
This commit is contained in:
parent
2e5eb86c97
commit
b1368fb97e
@ -27,6 +27,10 @@ fn main() {
|
|||||||
if !common::global_init() {
|
if !common::global_init() {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
#[cfg(all(windows, not(feature = "inline")))]
|
||||||
|
unsafe {
|
||||||
|
winapi::um::shellscalingapi::SetProcessDpiAwareness(2);
|
||||||
|
}
|
||||||
if let Some(args) = crate::core_main::core_main().as_mut() {
|
if let Some(args) = crate::core_main::core_main().as_mut() {
|
||||||
ui::start(args);
|
ui::start(args);
|
||||||
}
|
}
|
||||||
|
@ -72,10 +72,6 @@ pub fn start(args: &mut [String]) {
|
|||||||
allow_err!(sciter::set_options(sciter::RuntimeOptions::GfxLayer(
|
allow_err!(sciter::set_options(sciter::RuntimeOptions::GfxLayer(
|
||||||
sciter::GFX_LAYER::WARP
|
sciter::GFX_LAYER::WARP
|
||||||
)));
|
)));
|
||||||
#[cfg(all(windows, not(feature = "inline")))]
|
|
||||||
unsafe {
|
|
||||||
winapi::um::shellscalingapi::SetProcessDpiAwareness(2);
|
|
||||||
}
|
|
||||||
use sciter::SCRIPT_RUNTIME_FEATURES::*;
|
use sciter::SCRIPT_RUNTIME_FEATURES::*;
|
||||||
allow_err!(sciter::set_options(sciter::RuntimeOptions::ScriptFeatures(
|
allow_err!(sciter::set_options(sciter::RuntimeOptions::ScriptFeatures(
|
||||||
ALLOW_FILE_IO as u8 | ALLOW_SOCKET_IO as u8 | ALLOW_EVAL as u8 | ALLOW_SYSINFO as u8
|
ALLOW_FILE_IO as u8 | ALLOW_SOCKET_IO as u8 | ALLOW_EVAL as u8 | ALLOW_SYSINFO as u8
|
||||||
|
Loading…
x
Reference in New Issue
Block a user