1

There are 1 answers

2
m123 On

Navigating

Navigating to a new Page is easy

Navigator.push(
    context,
    MaterialPageRoute(builder: (context) => SecondRoute()),
  );

"SecoundRoute" is the Widget you will open in a new Window. More information about this here.

Swipe gesture

This is a bit more complicated. There is a widget called "Dismissible" but like the name say its to dismiss something from a List. There is an issue which suggests to make it possible to avoid deleting the entry from the ListView directly. However, this is inactive. I don't know whether this feature is there or where it is on the priority list.

dismissible

If you use a prebuild and static list of widgets you can maybe get around it, by navigating to the naw page in the onDismissed: callback and using pushReplacement in the rout back. This will case your main page to get Rebuild. Because your Widgets are static I think they will be their again.

Navigator.pushReplacement(
  context,
  MaterialPageRoute(
    builder: (context) => Page1(),
  ),
);

flutter_slidable

There is a plugin called flutter_slidable perhaps a solution can be found with this plugin.

flutter_slidable