implemented debounce/throttle as discussed
(https://bugs.dojotoolkit.org/ticket/17615)