INNER CODE UNIT · Rust

update_locales

denialwm/denial · compositor/flutter-engine/src/lib.rs:682

    pub fn update_locales(&self, locales: &[EngineLocale]) -> Result<(), EngineError> {
        let flutter_locales = locales
            .iter()
            .map(EngineLocale::as_flutter_locale)
            .collect::<Vec<_>>();
        let mut locale_pointers = flutter_locales
            .iter()
            .map(std::ptr::from_ref)
            .collect::<Vec<_>>();
        let function = self
            .library
            .table
            .UpdateLocales
            .expect("validated Flutter proc table");
        // SAFETY: Flutter reads the locale structs and their NUL-terminated
        // strings synchronously and does not retain any supplied pointer.
        check_result("UpdateLocales", unsafe {
            function(

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…