Commit e9931cef authored by m-spi's avatar m-spi

Exo6

parent b8559ef1
tp2/pubspec.lock */pubspec.lock
*/build/
*/.dart_tool/
// Flutter web plugin registrant file.
//
// Generated file. Do not edit.
//
// @dart = 2.13
// ignore_for_file: type=lint
import 'package:camera_web/camera_web.dart';
import 'package:flutter_web_plugins/flutter_web_plugins.dart';
void registerPlugins([final Registrar? pluginRegistrar]) {
final Registrar registrar = pluginRegistrar ?? webPluginRegistrar;
CameraPlugin.registerWith(registrar);
registrar.registerMessageHandler();
}
Extension Discovery Cache
=========================
This folder is used by `package:extension_discovery` to cache lists of
packages that contains extensions for other packages.
DO NOT USE THIS FOLDER
----------------------
* Do not read (or rely) the contents of this folder.
* Do write to this folder.
If you're interested in the lists of extensions stored in this folder use the
API offered by package `extension_discovery` to get this information.
If this package doesn't work for your use-case, then don't try to read the
contents of this folder. It may change, and will not remain stable.
Use package `extension_discovery`
---------------------------------
If you want to access information from this folder.
Feel free to delete this folder
-------------------------------
Files in this folder act as a cache, and the cache is discarded if the files
are older than the modification time of `.dart_tool/package_config.json`.
Hence, it should never be necessary to clear this cache manually, if you find a
need to do please file a bug.
{"version":2,"entries":[{"package":"tp2","rootUri":"../","packageUri":"lib/"}]}
\ No newline at end of file
{
"configVersion": 2,
"packages": [
{
"name": "async",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/async-2.11.0",
"packageUri": "lib/",
"languageVersion": "2.18"
},
{
"name": "boolean_selector",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/boolean_selector-2.1.1",
"packageUri": "lib/",
"languageVersion": "2.17"
},
{
"name": "camera",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/camera-0.9.8+1",
"packageUri": "lib/",
"languageVersion": "2.14"
},
{
"name": "camera_android",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_android-0.9.8+3",
"packageUri": "lib/",
"languageVersion": "2.14"
},
{
"name": "camera_avfoundation",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_avfoundation-0.9.14",
"packageUri": "lib/",
"languageVersion": "3.2"
},
{
"name": "camera_platform_interface",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_platform_interface-2.7.3",
"packageUri": "lib/",
"languageVersion": "3.0"
},
{
"name": "camera_web",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_web-0.2.1+6",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "characters",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/characters-1.3.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "clock",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/clock-1.1.1",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "collection",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/collection-1.18.0",
"packageUri": "lib/",
"languageVersion": "2.18"
},
{
"name": "cross_file",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/cross_file-0.3.3+8",
"packageUri": "lib/",
"languageVersion": "3.2"
},
{
"name": "cupertino_icons",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/cupertino_icons-1.0.6",
"packageUri": "lib/",
"languageVersion": "2.19"
},
{
"name": "fake_async",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/fake_async-1.3.1",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "flutter",
"rootUri": "file:///home/spinelli/IMT/M1/AMSE/flutter/packages/flutter",
"packageUri": "lib/",
"languageVersion": "3.3"
},
{
"name": "flutter_lints",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/flutter_lints-3.0.1",
"packageUri": "lib/",
"languageVersion": "3.0"
},
{
"name": "flutter_plugin_android_lifecycle",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.17",
"packageUri": "lib/",
"languageVersion": "2.19"
},
{
"name": "flutter_test",
"rootUri": "file:///home/spinelli/IMT/M1/AMSE/flutter/packages/flutter_test",
"packageUri": "lib/",
"languageVersion": "3.2"
},
{
"name": "flutter_web_plugins",
"rootUri": "file:///home/spinelli/IMT/M1/AMSE/flutter/packages/flutter_web_plugins",
"packageUri": "lib/",
"languageVersion": "3.2"
},
{
"name": "leak_tracker",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/leak_tracker-10.0.4",
"packageUri": "lib/",
"languageVersion": "3.2"
},
{
"name": "leak_tracker_flutter_testing",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/leak_tracker_flutter_testing-3.0.3",
"packageUri": "lib/",
"languageVersion": "3.2"
},
{
"name": "leak_tracker_testing",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/leak_tracker_testing-3.0.1",
"packageUri": "lib/",
"languageVersion": "3.2"
},
{
"name": "lints",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/lints-3.0.0",
"packageUri": "lib/",
"languageVersion": "3.0"
},
{
"name": "matcher",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/matcher-0.12.16+1",
"packageUri": "lib/",
"languageVersion": "3.0"
},
{
"name": "material_color_utilities",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/material_color_utilities-0.8.0",
"packageUri": "lib/",
"languageVersion": "2.17"
},
{
"name": "meta",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/meta-1.12.0",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "path",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/path-1.9.0",
"packageUri": "lib/",
"languageVersion": "3.0"
},
{
"name": "plugin_platform_interface",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/plugin_platform_interface-2.1.8",
"packageUri": "lib/",
"languageVersion": "3.0"
},
{
"name": "quiver",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/quiver-3.2.1",
"packageUri": "lib/",
"languageVersion": "2.17"
},
{
"name": "sky_engine",
"rootUri": "file:///home/spinelli/IMT/M1/AMSE/flutter/bin/cache/pkg/sky_engine",
"packageUri": "lib/",
"languageVersion": "3.2"
},
{
"name": "source_span",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/source_span-1.10.0",
"packageUri": "lib/",
"languageVersion": "2.18"
},
{
"name": "stack_trace",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/stack_trace-1.11.1",
"packageUri": "lib/",
"languageVersion": "2.18"
},
{
"name": "stream_channel",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/stream_channel-2.1.2",
"packageUri": "lib/",
"languageVersion": "2.19"
},
{
"name": "stream_transform",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/stream_transform-2.1.0",
"packageUri": "lib/",
"languageVersion": "2.14"
},
{
"name": "string_scanner",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/string_scanner-1.2.0",
"packageUri": "lib/",
"languageVersion": "2.18"
},
{
"name": "term_glyph",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/term_glyph-1.2.1",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{
"name": "test_api",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/test_api-0.7.0",
"packageUri": "lib/",
"languageVersion": "3.0"
},
{
"name": "vector_math",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/vector_math-2.1.4",
"packageUri": "lib/",
"languageVersion": "2.14"
},
{
"name": "vm_service",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/vm_service-14.0.0",
"packageUri": "lib/",
"languageVersion": "3.0"
},
{
"name": "web",
"rootUri": "file:///home/spinelli/.pub-cache/hosted/pub.dev/web-0.4.2",
"packageUri": "lib/",
"languageVersion": "3.2"
},
{
"name": "tp2",
"rootUri": "../",
"packageUri": "lib/",
"languageVersion": "3.4"
}
],
"generated": "2024-02-19T16:46:16.470500Z",
"generator": "pub",
"generatorVersion": "3.4.0-154.0.dev"
}
async
2.18
file:///home/spinelli/.pub-cache/hosted/pub.dev/async-2.11.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/async-2.11.0/lib/
boolean_selector
2.17
file:///home/spinelli/.pub-cache/hosted/pub.dev/boolean_selector-2.1.1/
file:///home/spinelli/.pub-cache/hosted/pub.dev/boolean_selector-2.1.1/lib/
camera
2.14
file:///home/spinelli/.pub-cache/hosted/pub.dev/camera-0.9.8+1/
file:///home/spinelli/.pub-cache/hosted/pub.dev/camera-0.9.8+1/lib/
camera_android
2.14
file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_android-0.9.8+3/
file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_android-0.9.8+3/lib/
camera_avfoundation
3.2
file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_avfoundation-0.9.14/
file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_avfoundation-0.9.14/lib/
camera_platform_interface
3.0
file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_platform_interface-2.7.3/
file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_platform_interface-2.7.3/lib/
camera_web
2.12
file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_web-0.2.1+6/
file:///home/spinelli/.pub-cache/hosted/pub.dev/camera_web-0.2.1+6/lib/
characters
2.12
file:///home/spinelli/.pub-cache/hosted/pub.dev/characters-1.3.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/characters-1.3.0/lib/
clock
2.12
file:///home/spinelli/.pub-cache/hosted/pub.dev/clock-1.1.1/
file:///home/spinelli/.pub-cache/hosted/pub.dev/clock-1.1.1/lib/
collection
2.18
file:///home/spinelli/.pub-cache/hosted/pub.dev/collection-1.18.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/collection-1.18.0/lib/
cross_file
3.2
file:///home/spinelli/.pub-cache/hosted/pub.dev/cross_file-0.3.3+8/
file:///home/spinelli/.pub-cache/hosted/pub.dev/cross_file-0.3.3+8/lib/
cupertino_icons
2.19
file:///home/spinelli/.pub-cache/hosted/pub.dev/cupertino_icons-1.0.6/
file:///home/spinelli/.pub-cache/hosted/pub.dev/cupertino_icons-1.0.6/lib/
fake_async
2.12
file:///home/spinelli/.pub-cache/hosted/pub.dev/fake_async-1.3.1/
file:///home/spinelli/.pub-cache/hosted/pub.dev/fake_async-1.3.1/lib/
flutter_lints
3.0
file:///home/spinelli/.pub-cache/hosted/pub.dev/flutter_lints-3.0.1/
file:///home/spinelli/.pub-cache/hosted/pub.dev/flutter_lints-3.0.1/lib/
flutter_plugin_android_lifecycle
2.19
file:///home/spinelli/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.17/
file:///home/spinelli/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.17/lib/
leak_tracker
3.2
file:///home/spinelli/.pub-cache/hosted/pub.dev/leak_tracker-10.0.4/
file:///home/spinelli/.pub-cache/hosted/pub.dev/leak_tracker-10.0.4/lib/
leak_tracker_flutter_testing
3.2
file:///home/spinelli/.pub-cache/hosted/pub.dev/leak_tracker_flutter_testing-3.0.3/
file:///home/spinelli/.pub-cache/hosted/pub.dev/leak_tracker_flutter_testing-3.0.3/lib/
leak_tracker_testing
3.2
file:///home/spinelli/.pub-cache/hosted/pub.dev/leak_tracker_testing-3.0.1/
file:///home/spinelli/.pub-cache/hosted/pub.dev/leak_tracker_testing-3.0.1/lib/
lints
3.0
file:///home/spinelli/.pub-cache/hosted/pub.dev/lints-3.0.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/lints-3.0.0/lib/
matcher
3.0
file:///home/spinelli/.pub-cache/hosted/pub.dev/matcher-0.12.16+1/
file:///home/spinelli/.pub-cache/hosted/pub.dev/matcher-0.12.16+1/lib/
material_color_utilities
2.17
file:///home/spinelli/.pub-cache/hosted/pub.dev/material_color_utilities-0.8.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/material_color_utilities-0.8.0/lib/
meta
2.12
file:///home/spinelli/.pub-cache/hosted/pub.dev/meta-1.12.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/meta-1.12.0/lib/
path
3.0
file:///home/spinelli/.pub-cache/hosted/pub.dev/path-1.9.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/path-1.9.0/lib/
plugin_platform_interface
3.0
file:///home/spinelli/.pub-cache/hosted/pub.dev/plugin_platform_interface-2.1.8/
file:///home/spinelli/.pub-cache/hosted/pub.dev/plugin_platform_interface-2.1.8/lib/
quiver
2.17
file:///home/spinelli/.pub-cache/hosted/pub.dev/quiver-3.2.1/
file:///home/spinelli/.pub-cache/hosted/pub.dev/quiver-3.2.1/lib/
source_span
2.18
file:///home/spinelli/.pub-cache/hosted/pub.dev/source_span-1.10.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/source_span-1.10.0/lib/
stack_trace
2.18
file:///home/spinelli/.pub-cache/hosted/pub.dev/stack_trace-1.11.1/
file:///home/spinelli/.pub-cache/hosted/pub.dev/stack_trace-1.11.1/lib/
stream_channel
2.19
file:///home/spinelli/.pub-cache/hosted/pub.dev/stream_channel-2.1.2/
file:///home/spinelli/.pub-cache/hosted/pub.dev/stream_channel-2.1.2/lib/
stream_transform
2.14
file:///home/spinelli/.pub-cache/hosted/pub.dev/stream_transform-2.1.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/stream_transform-2.1.0/lib/
string_scanner
2.18
file:///home/spinelli/.pub-cache/hosted/pub.dev/string_scanner-1.2.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/string_scanner-1.2.0/lib/
term_glyph
2.12
file:///home/spinelli/.pub-cache/hosted/pub.dev/term_glyph-1.2.1/
file:///home/spinelli/.pub-cache/hosted/pub.dev/term_glyph-1.2.1/lib/
test_api
3.0
file:///home/spinelli/.pub-cache/hosted/pub.dev/test_api-0.7.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/test_api-0.7.0/lib/
vector_math
2.14
file:///home/spinelli/.pub-cache/hosted/pub.dev/vector_math-2.1.4/
file:///home/spinelli/.pub-cache/hosted/pub.dev/vector_math-2.1.4/lib/
vm_service
3.0
file:///home/spinelli/.pub-cache/hosted/pub.dev/vm_service-14.0.0/
file:///home/spinelli/.pub-cache/hosted/pub.dev/vm_service-14.0.0/lib/
web
3.2
file:///home/spinelli/.pub-cache/hosted/pub.dev/web-0.4.2/
file:///home/spinelli/.pub-cache/hosted/pub.dev/web-0.4.2/lib/
tp2
3.4
file:///home/spinelli/IMT/M1/AMSE/amse/tp2/
file:///home/spinelli/IMT/M1/AMSE/amse/tp2/lib/
sky_engine
3.2
file:///home/spinelli/IMT/M1/AMSE/flutter/bin/cache/pkg/sky_engine/
file:///home/spinelli/IMT/M1/AMSE/flutter/bin/cache/pkg/sky_engine/lib/
flutter
3.3
file:///home/spinelli/IMT/M1/AMSE/flutter/packages/flutter/
file:///home/spinelli/IMT/M1/AMSE/flutter/packages/flutter/lib/
flutter_test
3.2
file:///home/spinelli/IMT/M1/AMSE/flutter/packages/flutter_test/
file:///home/spinelli/IMT/M1/AMSE/flutter/packages/flutter_test/lib/
flutter_web_plugins
3.2
file:///home/spinelli/IMT/M1/AMSE/flutter/packages/flutter_web_plugins/
file:///home/spinelli/IMT/M1/AMSE/flutter/packages/flutter_web_plugins/lib/
2
3.20.0-10.0.pre.44
\ No newline at end of file
{"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"camera_avfoundation","path":"/home/spinelli/.pub-cache/hosted/pub.dev/camera_avfoundation-0.9.14/","native_build":true,"dependencies":[]}],"android":[{"name":"camera_android","path":"/home/spinelli/.pub-cache/hosted/pub.dev/camera_android-0.9.8+3/","native_build":true,"dependencies":["flutter_plugin_android_lifecycle"]},{"name":"flutter_plugin_android_lifecycle","path":"/home/spinelli/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.17/","native_build":true,"dependencies":[]}],"macos":[],"linux":[],"windows":[],"web":[{"name":"camera_web","path":"/home/spinelli/.pub-cache/hosted/pub.dev/camera_web-0.2.1+6/","dependencies":[]}]},"dependencyGraph":[{"name":"camera","dependencies":["camera_android","camera_avfoundation","camera_web","flutter_plugin_android_lifecycle"]},{"name":"camera_android","dependencies":["flutter_plugin_android_lifecycle"]},{"name":"camera_avfoundation","dependencies":[]},{"name":"camera_web","dependencies":[]},{"name":"flutter_plugin_android_lifecycle","dependencies":[]}],"date_created":"2024-02-19 17:46:16.677970","version":"3.20.0-10.0.pre.44"} {"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"camera_avfoundation","path":"/home/spinelli/.pub-cache/hosted/pub.dev/camera_avfoundation-0.9.14/","native_build":true,"dependencies":[]}],"android":[{"name":"camera_android","path":"/home/spinelli/.pub-cache/hosted/pub.dev/camera_android-0.9.8+3/","native_build":true,"dependencies":["flutter_plugin_android_lifecycle"]},{"name":"flutter_plugin_android_lifecycle","path":"/home/spinelli/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.17/","native_build":true,"dependencies":[]}],"macos":[],"linux":[],"windows":[],"web":[{"name":"camera_web","path":"/home/spinelli/.pub-cache/hosted/pub.dev/camera_web-0.2.1+6/","dependencies":[]}]},"dependencyGraph":[{"name":"camera","dependencies":["camera_android","camera_avfoundation","camera_web","flutter_plugin_android_lifecycle"]},{"name":"camera_android","dependencies":["flutter_plugin_android_lifecycle"]},{"name":"camera_avfoundation","dependencies":[]},{"name":"camera_web","dependencies":[]},{"name":"flutter_plugin_android_lifecycle","dependencies":[]}],"date_created":"2024-02-25 13:30:45.172170","version":"3.20.0-13.0.pre.28"}
\ No newline at end of file \ No newline at end of file
This diff is collapsed.
...@@ -44,51 +44,66 @@ class _Exo6 extends State<Exo6> { ...@@ -44,51 +44,66 @@ class _Exo6 extends State<Exo6> {
super.initState(); super.initState();
image = Image.network('https://picsum.photos/512'); image = Image.network('https://picsum.photos/512');
tiles = buildImage();
}
List<Widget> buildImage(){
int imageCount = 0;
List<Widget> res = <Widget>[];
int index = 0;
emptyTileIndex = math.Random().nextInt(colNb * colNb); emptyTileIndex = math.Random().nextInt(colNb * colNb);
for(int i = 0; i < colNb; i++){ for(int i = 0; i < colNb; i++){
for(int j = 0; j < colNb; j++){ for(int j = 0; j < colNb; j++){
int indexcopy = index; int indexcopy = imageCount;
if(index == emptyTileIndex){ Tile tile = Tile(image: image, alignment:
tiles.add( Alignment(-1 + 2 * j.toDouble() / (colNb.toDouble() - 1),
Flexible(child: Container(margin: EdgeInsets.all(10.0 / colNb))) -1 + 2 * i.toDouble() / (colNb.toDouble() - 1))
); );
}else{
Tile tile = Tile(image: image, alignment: Key k = UniqueKey();
Alignment(-1 + 2 * j.toDouble() / (colNb.toDouble() - 1),
-1 + 2 * i.toDouble() / (colNb.toDouble() - 1)) res.add(
); Flexible(key: k, child: Container(
margin: EdgeInsets.all(2),
Key k = UniqueKey(); child: InkWell(
child: tile.croppedImageTile(1 / colNb),
tiles.add( onTap: () {
Flexible(key: k, child: Container( setState(() {
margin: EdgeInsets.all(10.0 / colNb), swapTiles(k);
child: InkWell( });
child: tile.croppedImageTile(1 / colNb), }
onTap: () { )
setState(() { ))
swapTiles(k); );
});
} imageCount++;
)
))
);
}
index++;
} }
} }
res.shuffle();
res[emptyTileIndex] = Flexible(child: Container(margin: EdgeInsets.all(2)));
return res;
} }
void swapTiles(Key k){ void swapTiles(Key k){
var t = tiles.singleWhere((element) => element.key == k); Widget t = tiles.singleWhere((element) => element.key == k);
tiles[emptyTileIndex] = t; int i = tiles.indexOf(t);
tiles[tiles.indexOf(t)] = Flexible(child: Container(margin: EdgeInsets.all(10.0 / colNb)));
emptyTileIndex = tiles.indexOf(t); // If tile is neighbor of empty tile => move
if(
i+1 == emptyTileIndex && i%colNb != colNb-1 ||
i-1 == emptyTileIndex && i%colNb != 0 ||
i-colNb == emptyTileIndex ||
i+colNb == emptyTileIndex
){
tiles[emptyTileIndex] = t;
tiles[i] = Flexible(child: Container(margin: EdgeInsets.all(2)));
emptyTileIndex = i;
}
} }
@override @override
...@@ -120,9 +135,12 @@ class _Exo6 extends State<Exo6> { ...@@ -120,9 +135,12 @@ class _Exo6 extends State<Exo6> {
min: 2, min: 2,
max: 6, max: 6,
onChanged: (double value) { onChanged: (double value) {
setState(() { if(value.toInt() != colNb){
colNb = value.toInt(); setState(() {
}); colNb = value.toInt();
tiles = buildImage();
});
}
} }
), ),
]), ]),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment