Closed
Description
From @HansMuller on March 8, 2016 17:31
Say I have this:
Widget build(BuildContext context) {
return new Scaffold(
body: new GestureDetector(
onTap: () { startResize(); },
child: new Center(
child: new Container(
width: 200.0,
height: 300.0,
decoration: new BoxDecoration(backgroundColor: const Color(0xFF00FF00))
)
)
)
);
}
And I want to move the GestureDetector "down" so that it wraps its Container descendant.
Widget build(BuildContext context) {
return new Scaffold(
body: new Center(
child: new GestureDetector(
onTap: () { startResize(); },
child: new Container(
width: 200.0,
height: 300.0,
decoration: new BoxDecoration(backgroundColor: const Color(0xFF00FF00))
)
)
)
);
}
Currently this is a pretty tedious manual process, particularly when the tree the widget is within is relatively complex.
Changes like this are very common in Flutter application building.
I wish Widget tree operations like this were relatively trivial. For example if there was a graphical view of the corresponding tree, then one could just drag and drop nodes.
Copied from original issue: flutter/flutter#2486