ratpoison-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [RP] Closing window timer


From: Shawn Betts
Subject: Re: [RP] Closing window timer
Date: Tue, 29 May 2007 12:23:23 +0300



On 5/26/07, Stephen Lavelle <address@hidden> wrote:
Hi guys, I was hping that someone might be able to help me out with my
paranoia;

I would like to not be able to close the contents of a frame for the
first, say, two seconds after it appears at the front;  that is to say, I
sometimes get a little paranoid when I'm going to close a window that say
a msn chat thing pops up in the time between me deciding I want to close
the window and my actually hitting the correct sequence of keys.
 
Hi Stephen,
 
You should be able to hack this together using some hooks and rebinding the the C-t k binding. you can create new window slots with define-win-attr (or something like that) which creates get/setf functions for the specified slot name. The manual has a bit about it. Next, add a function to the map-window-hook (iirc there is one), which sets the slot's value to, perhaps, the time after which a window can be killed. finally write a command (plenty of examples in user.lisp) that checks the new slot and only kills the window after its been mapped for N seconds. Good luck!

-Shawn

reply via email to

[Prev in Thread] Current Thread [Next in Thread]