1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
//! Custom Event Dispatching System
//!
//! Provides a type-safe, extensible event system for user-defined events.
//!
//! # Features
//!
//! - Custom event type registration
//! - Type-safe event dispatching
//! - Event bubbling/capturing support
//! - Event metadata (timestamp, source)
//! - Event cancellation
//! - Priority levels
//!
//! # Example
//!
//! ```rust,ignore
//! use revue::event::custom::*;
//!
//! // Define a custom event
//! struct ChatMessage {
//! user: String,
//! text: String,
//! }
//!
//! impl CustomEvent for ChatMessage {
//! fn event_type() -> &'static str { "chat_message" }
//! }
//!
//! // Create dispatcher and register handler
//! let mut dispatcher = EventDispatcher::new();
//!
//! dispatcher.on::<ChatMessage>(|event, ctx| {
//! println!("{}: {}", event.user, event.text);
//! EventResponse::Handled
//! });
//!
//! // Dispatch event
//! dispatcher.dispatch(ChatMessage {
//! user: "Alice".to_string(),
//! text: "Hello!".to_string(),
//! });
//! ```
// Re-exports
pub use ;
pub use EventDispatcher;
pub use ;
pub use ;
pub use EventResponse;
pub use DispatchResult;
pub use ;