Created
April 29, 2021 15:23
-
-
Save jtmuller5/e1cc7264e74f32efe24c51ee335ad2a9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GestureDetector( | |
onTap: () { | |
model.setInteraction(false); | |
}, | |
behavior: HitTestBehavior.deferToChild, | |
child: InteractiveViewer( | |
panEnabled: false, | |
boundaryMargin: EdgeInsets.all(80), | |
onInteractionStart: (details) { | |
model.setInteraction(true); | |
}, | |
onInteractionEnd: (details) { | |
model.setInteraction(false); | |
}, | |
minScale: 0.5, | |
maxScale: 4, | |
child: Transform.scale( | |
scale: .85, | |
child: Stack( | |
children: [ | |
Center( | |
child: Container( | |
height: systemService.screenHeight(context) - 16, | |
width: systemService.screenWidth(context) - 32, | |
child: IgnorePointer(ignoring: model.interacting, child: BodyCanvas()), | |
), | |
), | |
], | |
), | |
), | |
), | |
), |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment