refactor: make SurfaceMessage handling opt in
This commit is contained in:
parent
63f249a395
commit
31d676a4f2
4 changed files with 16 additions and 7 deletions
|
|
@ -388,7 +388,7 @@ impl Core {
|
|||
id
|
||||
}
|
||||
|
||||
#[cfg(feature = "wayland")]
|
||||
#[cfg(feature = "surface-message")]
|
||||
/// # Panics
|
||||
///
|
||||
/// Will panic if the menu bar collapses without tracking the size
|
||||
|
|
|
|||
|
|
@ -7,6 +7,13 @@ pub enum MessageWrapper<M> {
|
|||
Message(M),
|
||||
}
|
||||
|
||||
#[cfg(not(feature = "surface-message"))]
|
||||
impl<M> From<M> for MessageWrapper<M> {
|
||||
fn from(value: M) -> Self {
|
||||
MessageWrapper::Message(value)
|
||||
}
|
||||
}
|
||||
|
||||
/// Ignore this message in your application. It will be intercepted.
|
||||
#[derive(Clone)]
|
||||
pub enum SurfaceMessage {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue