C++ testing API: Intreoduce the ElementHandle

This commit is contained in:
Olivier Goffart 2024-04-19 18:18:35 +02:00
parent 13fe59cc2e
commit 475ced0a62
15 changed files with 225 additions and 25 deletions

View file

@ -24,8 +24,10 @@ pub fn with_platform<R>(
i_slint_core::with_platform(|| Err(i_slint_core::platform::PlatformError::NoPlatform), f)
}
/// One need to make sure something from the crate is exported,
/// otherwise its symbols are not going to be in the final binary
// One need to make sure something from the crate is exported,
// otherwise its symbols are not going to be in the final binary
#[cfg(feature = "testing")]
pub use i_slint_backend_testing;
#[cfg(feature = "slint-interpreter")]
pub use slint_interpreter;
@ -138,12 +140,6 @@ pub unsafe extern "C" fn slint_register_bitmap_font(
window_adapter.renderer().register_bitmap_font(font_data);
}
#[cfg(feature = "internal-testing")]
#[no_mangle]
pub unsafe extern "C" fn slint_testing_init_backend() {
i_slint_backend_testing::init_no_event_loop();
}
#[cfg(not(feature = "std"))]
mod allocator {
use core::alloc::Layout;