throttleWithTimeout method

void throttleWithTimeout()

Implementation

void throttleWithTimeout() {
  String key = hashCode.toString();
  bool enable = _funcThrottle[key] ?? true;
  if (enable) {
    _funcThrottle[key] = false;
    Timer(Duration(milliseconds: timeout), () {
      _funcThrottle.remove(key);
    });
    target?.call();
  }
}