buildTooltipContent static method

Widget buildTooltipContent({
  1. required ValueChanged<int> onSelect,
})

Implementation

static Widget buildTooltipContent({required ValueChanged<int> onSelect}) {
  return Padding(
    padding: const EdgeInsets.symmetric(vertical: 8),
    child: Row(
      mainAxisSize: MainAxisSize.min,
      children: [
        GestureDetector(
          onTap: () {
            debugPrint("");
            onSelect.call(0);
          },
          child: const Column(
            mainAxisSize: MainAxisSize.min,
            children: [
              Icon(Icons.copy, color: Colors.white),
              SizedBox(height: 4),
              Text('复制', style: TextStyle(color: Colors.white, fontSize: 12)),
            ],
          ),
        ),
        const SizedBox(width: 16),
        GestureDetector(
          onTap: () {
            debugPrint("");
            onSelect.call(1);
          },
          child: const Column(
            mainAxisSize: MainAxisSize.min,
            children: [
              Icon(Icons.delete, color: Colors.white),
              SizedBox(height: 4),
              Text('删除', style: TextStyle(color: Colors.white, fontSize: 12)),
            ],
          ),
        ),
        const SizedBox(width: 16),
        GestureDetector(
          onTap: () {
            debugPrint("");
            onSelect.call(2);
          },
          child: const Column(
            mainAxisSize: MainAxisSize.min,
            children: [
              Icon(Icons.undo, color: Colors.white),
              SizedBox(height: 4),
              Text('撤回', style: TextStyle(color: Colors.white, fontSize: 12)),
            ],
          ),
        )
      ],
    ),
  );
}