@@ -172,6 +172,9 @@ impl From<CaptureBackend> for input_capture::Backend {
172172
173173#[ derive( Clone , Copy , Debug , Deserialize , Eq , PartialEq , Serialize , ValueEnum ) ]
174174pub enum EmulationBackend {
175+ #[ cfg( all( target_os = "linux" , feature = "evdev_emulation" ) ) ]
176+ #[ serde( rename = "evdev" ) ]
177+ Evdev ,
175178 #[ cfg( all( unix, feature = "wlroots_emulation" , not( target_os = "macos" ) ) ) ]
176179 #[ serde( rename = "wlroots" ) ]
177180 Wlroots ,
@@ -197,6 +200,8 @@ pub enum EmulationBackend {
197200impl From < EmulationBackend > for input_emulation:: Backend {
198201 fn from ( backend : EmulationBackend ) -> Self {
199202 match backend {
203+ #[ cfg( all( target_os = "linux" , feature = "evdev_emulation" ) ) ]
204+ EmulationBackend :: Evdev => Self :: Evdev ,
200205 #[ cfg( all( unix, feature = "wlroots_emulation" , not( target_os = "macos" ) ) ) ]
201206 EmulationBackend :: Wlroots => Self :: Wlroots ,
202207 #[ cfg( all( unix, feature = "libei_emulation" , not( target_os = "macos" ) ) ) ]
@@ -217,6 +222,8 @@ impl From<EmulationBackend> for input_emulation::Backend {
217222impl Display for EmulationBackend {
218223 fn fmt ( & self , f : & mut std:: fmt:: Formatter < ' _ > ) -> std:: fmt:: Result {
219224 match self {
225+ #[ cfg( all( target_os = "linux" , feature = "evdev_emulation" ) ) ]
226+ EmulationBackend :: Evdev => write ! ( f, "evdev" ) ,
220227 #[ cfg( all( unix, feature = "wlroots_emulation" , not( target_os = "macos" ) ) ) ]
221228 EmulationBackend :: Wlroots => write ! ( f, "wlroots" ) ,
222229 #[ cfg( all( unix, feature = "libei_emulation" , not( target_os = "macos" ) ) ) ]
0 commit comments