Rewrote idle and input handlers using WMBag to avoid a functional problem of