custom_long_tap

A GestureDetector with custom duration


License
MIT

Documentation

long_press_widget

A GestureDetector where you can set the Duration for LongPress callback

Getting Started

Installing:

Add this to pubspec.yaml

dependencies:

custom_long_tap: ^0.0.1

Import this:

import 'package:custom_long_tap/custom_long_tap.dart';

Example:

CustomLongTap(

    widget: Container(
    
      child: Text('Press ME!'),
      
    ),
    
    duration: Duration(seconds: 5),
    
    onShortTap: () {
    
      // do something on normal press
      
    },
    
    onLongTap: () {
    
      // do something on long press
      
    },
    
  ),