1
- #[ cfg( not ( any( target_os = "stax " , target_os = "flex" , target_os = "apex_p" ) ) ) ]
1
+ #[ cfg( any( target_os = "nanosplus " , target_os = "nanox" ) ) ]
2
2
use ledger_secure_sdk_sys:: buttons:: { get_button_event, ButtonEvent , ButtonsState } ;
3
3
use ledger_secure_sdk_sys:: seph as sys_seph;
4
4
use ledger_secure_sdk_sys:: * ;
@@ -106,7 +106,7 @@ pub enum Event<T> {
106
106
/// APDU event
107
107
Command ( T ) ,
108
108
/// Button press or release event
109
- #[ cfg( not ( any( target_os = "stax " , target_os = "flex" , target_os = "apex_p" ) ) ) ]
109
+ #[ cfg( any( target_os = "nanosplus " , target_os = "nanox" ) ) ]
110
110
Button ( ButtonEvent ) ,
111
111
#[ cfg( any( target_os = "stax" , target_os = "flex" , target_os = "apex_p" ) ) ]
112
112
TouchEvent ,
@@ -121,7 +121,7 @@ pub struct Comm {
121
121
pub rx : usize ,
122
122
pub tx : usize ,
123
123
pub event_pending : bool ,
124
- #[ cfg( not ( any( target_os = "stax " , target_os = "flex" , target_os = "apex_p" ) ) ) ]
124
+ #[ cfg( any( target_os = "nanosplus " , target_os = "nanox" ) ) ]
125
125
buttons : ButtonsState ,
126
126
/// Expected value for the APDU CLA byte.
127
127
/// If defined, [`Comm`] will automatically reply with [`StatusWords::BadCla`] when an APDU
@@ -162,7 +162,7 @@ impl Comm {
162
162
rx : 0 ,
163
163
tx : 0 ,
164
164
event_pending : false ,
165
- #[ cfg( not ( any( target_os = "stax " , target_os = "flex" , target_os = "apex_p" ) ) ) ]
165
+ #[ cfg( any( target_os = "nanosplus " , target_os = "nanox" ) ) ]
166
166
buttons : ButtonsState :: new ( ) ,
167
167
expected_cla : None ,
168
168
apdu_type : seph:: PacketTypes :: PacketTypeNone as u8 ,
@@ -358,7 +358,7 @@ impl Comm {
358
358
359
359
match seph:: Events :: from ( tag) {
360
360
// BUTTON PUSH EVENT
361
- #[ cfg( not ( any( target_os = "stax " , target_os = "flex" , target_os = "apex_p" ) ) ) ]
361
+ #[ cfg( any( target_os = "nanosplus " , target_os = "nanox" ) ) ]
362
362
seph:: Events :: ButtonPushEvent => {
363
363
#[ cfg( feature = "nano_nbgl" ) ]
364
364
unsafe {
0 commit comments