forked from vitrine/wmaker
Move wApplicationClearUrgentBounceTimer into Rust.
This commit is contained in:
@@ -55,15 +55,6 @@ struct WApplication {
|
||||
} flags;
|
||||
};
|
||||
|
||||
/******** Accessors/mutators ********/
|
||||
|
||||
void wApplicationClearUrgentBounceTimer(WApplication *wapp) {
|
||||
if (wapp->urgent_bounce_timer) {
|
||||
WMDeleteTimerHandler(wapp->urgent_bounce_timer);
|
||||
wapp->urgent_bounce_timer = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
/******** Construction/destruction ********/
|
||||
static WWindow *makeMainWindow(WScreen * scr, Window window)
|
||||
{
|
||||
|
||||
@@ -109,6 +109,21 @@ pub mod ffi {
|
||||
}
|
||||
}
|
||||
|
||||
unsafe extern "C" {
|
||||
fn WMDeleteTimerHandler(timer: *mut c_void);
|
||||
}
|
||||
|
||||
#[unsafe(no_mangle)]
|
||||
pub unsafe extern "C" fn wApplicationClearUrgentBounceTimer(app: *mut Application) {
|
||||
unsafe {
|
||||
if (*app).urgent_bounce_timer.is_null() {
|
||||
return;
|
||||
}
|
||||
WMDeleteTimerHandler((*app).urgent_bounce_timer);
|
||||
(*app).urgent_bounce_timer = ptr::null_mut();
|
||||
}
|
||||
}
|
||||
|
||||
#[unsafe(no_mangle)]
|
||||
pub unsafe extern "C" fn wApplicationSetUrgentBounceTimer(app: *mut Application, timer: *mut c_void) {
|
||||
unsafe {
|
||||
|
||||
Reference in New Issue
Block a user