remove shift & tap enable multiselect (#9625)
Signed-off-by: 21pages <sunboeasy@gmail.com>
This commit is contained in:
parent
cde7620eda
commit
29b01e9cef
@ -62,7 +62,7 @@ class _PeerCardState extends State<_PeerCard>
|
|||||||
final PeerTabModel peerTabModel = Provider.of(context);
|
final PeerTabModel peerTabModel = Provider.of(context);
|
||||||
final peer = super.widget.peer;
|
final peer = super.widget.peer;
|
||||||
return GestureDetector(
|
return GestureDetector(
|
||||||
onDoubleTap: peerTabModel.multiSelectionMode || peerTabModel.isShiftDown
|
onDoubleTap: peerTabModel.multiSelectionMode
|
||||||
? null
|
? null
|
||||||
: () => widget.connect(context, peer.id),
|
: () => widget.connect(context, peer.id),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
|
@ -152,7 +152,7 @@ class PeerTabModel with ChangeNotifier {
|
|||||||
// https://github.com/flutter/flutter/issues/101275#issuecomment-1604541700
|
// https://github.com/flutter/flutter/issues/101275#issuecomment-1604541700
|
||||||
// After onTap, the shift key should be pressed for a while when not in multiselection mode,
|
// After onTap, the shift key should be pressed for a while when not in multiselection mode,
|
||||||
// because onTap is delayed when onDoubleTap is not null
|
// because onTap is delayed when onDoubleTap is not null
|
||||||
if ((isDesktop || isWebDesktop) && !_isShiftDown) return;
|
if (isDesktop || isWebDesktop) return;
|
||||||
_multiSelectionMode = true;
|
_multiSelectionMode = true;
|
||||||
}
|
}
|
||||||
final cached = _currentTabCachedPeers.map((e) => e.id).toList();
|
final cached = _currentTabCachedPeers.map((e) => e.id).toList();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user