Skip to content

Commit

Permalink
don't cause X errors by operating on a dead window
Browse files Browse the repository at this point in the history
  • Loading branch information
dk committed Sep 21, 2024
1 parent 3bea0bf commit 87ed448
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions unix/window.c
Original file line number Diff line number Diff line change
Expand Up @@ -1609,8 +1609,11 @@ apc_window_execute( Handle self, Handle insert_before)
while ( prima_one_loop_round( WAIT_IF_NONE, true) && XX-> flags.modal)
;

if ( toplevel) XSetTransientForHint( DISP, X_WINDOW, None);
if ( X_WINDOW) NETWM_SET_MODAL( X_WINDOW, XX-> flags.modal);
if ( PObject(self)->stage == csNormal ) {
if ( toplevel) XSetTransientForHint( DISP, X_WINDOW, None);
if ( X_WINDOW) NETWM_SET_MODAL( X_WINDOW, XX-> flags.modal);
}

unprotect_object( self);
return true;
}
Expand Down

0 comments on commit 87ed448

Please sign in to comment.