Files
bevy_cef/src/lib.rs
elm 5be6380474 Fix message loop handling and improve BrowserProcessHandler (#15)
* add: implement MessagePumpChecker for message loop management

* update: refactor message loop handling and improve MessagePumpChecker

* update: refactor message loop handling to use MessageLoopTimer and improve BrowserProcessHandler

* update: reorganize imports and enhance browser process handler integration

* update: support Bevy 0.18 and improve message loop handling

* update: remove unused FpsOverlayPlugin and clean up dependencies

* update: simplify cef and cef-dll-sys version specifications in Cargo.toml

---------

Co-authored-by: not-elm <elmgameinfo@gmail.com>
2026-02-01 12:00:56 +09:00

48 lines
1.2 KiB
Rust

#![allow(clippy::type_complexity)]
mod common;
mod cursor_icon;
mod keyboard;
mod mute;
mod navigation;
mod system_param;
mod webview;
mod zoom;
use crate::common::{LocalHostPlugin, MessageLoopPlugin, WebviewCoreComponentsPlugin};
use crate::cursor_icon::SystemCursorIconPlugin;
use crate::keyboard::KeyboardPlugin;
use crate::mute::AudioMutePlugin;
use crate::prelude::{IpcPlugin, NavigationPlugin, WebviewPlugin};
use crate::zoom::ZoomPlugin;
use bevy::prelude::*;
use bevy_remote::RemotePlugin;
pub mod prelude {
pub use crate::{CefPlugin, RunOnMainThread, common::*, navigation::*, webview::prelude::*};
}
pub struct RunOnMainThread;
pub struct CefPlugin;
impl Plugin for CefPlugin {
fn build(&self, app: &mut App) {
app.add_plugins((
LocalHostPlugin,
MessageLoopPlugin,
WebviewCoreComponentsPlugin,
WebviewPlugin,
IpcPlugin,
KeyboardPlugin,
SystemCursorIconPlugin,
NavigationPlugin,
ZoomPlugin,
AudioMutePlugin,
));
if !app.is_plugin_added::<RemotePlugin>() {
app.add_plugins(RemotePlugin::default());
}
}
}