From 35713ac2d945988b9a1f2a62bb8156611afe7e70 Mon Sep 17 00:00:00 2001 From: Miguel Beltran Date: Tue, 8 Mar 2022 02:08:53 +0100 Subject: [PATCH] rename constants (#1047) --- animations/lib/main.dart | 12 ++++++------ desktop_photo_search/fluent_ui/lib/main.dart | 6 +++--- desktop_photo_search/material/lib/main.dart | 6 +++--- form_app/lib/main.dart | 12 ++++++------ infinite_list/lib/main.dart | 12 ++++++------ isolate_example/lib/main.dart | 6 +++--- jsonexample/lib/main.dart | 6 +++--- null_safety/null_safe_app/lib/main.dart | 6 +++--- provider_shopper/lib/main.dart | 12 ++++++------ 9 files changed, 39 insertions(+), 39 deletions(-) diff --git a/animations/lib/main.dart b/animations/lib/main.dart index 28c5b3ed5..c30dbad21 100644 --- a/animations/lib/main.dart +++ b/animations/lib/main.dart @@ -33,20 +33,20 @@ void main() { runApp(const AnimationSamples()); } -const double kWindowWidth = 480; -const double kWindowHeight = 854; +const double windowWidth = 480; +const double windowHeight = 854; void setupWindow() { if (!kIsWeb && (Platform.isWindows || Platform.isLinux || Platform.isMacOS)) { WidgetsFlutterBinding.ensureInitialized(); setWindowTitle('Animation Samples'); - setWindowMinSize(const Size(kWindowWidth, kWindowHeight)); - setWindowMaxSize(const Size(kWindowWidth, kWindowHeight)); + setWindowMinSize(const Size(windowWidth, windowHeight)); + setWindowMaxSize(const Size(windowWidth, windowHeight)); getCurrentScreen().then((screen) { setWindowFrame(Rect.fromCenter( center: screen!.frame.center, - width: kWindowWidth, - height: kWindowHeight, + width: windowWidth, + height: windowHeight, )); }); } diff --git a/desktop_photo_search/fluent_ui/lib/main.dart b/desktop_photo_search/fluent_ui/lib/main.dart index e9351c09a..e33bbbf33 100644 --- a/desktop_photo_search/fluent_ui/lib/main.dart +++ b/desktop_photo_search/fluent_ui/lib/main.dart @@ -44,13 +44,13 @@ void main() { ); } -const double kWindowWidth = 1024; -const double kWindowHeight = 800; +const double windowWidth = 1024; +const double windowHeight = 800; void setupWindow() { if (!kIsWeb && (Platform.isWindows || Platform.isLinux || Platform.isMacOS)) { WidgetsFlutterBinding.ensureInitialized(); - setWindowMinSize(const Size(kWindowWidth, kWindowHeight)); + setWindowMinSize(const Size(windowWidth, windowHeight)); } } diff --git a/desktop_photo_search/material/lib/main.dart b/desktop_photo_search/material/lib/main.dart index 1669e895b..4213d92d4 100644 --- a/desktop_photo_search/material/lib/main.dart +++ b/desktop_photo_search/material/lib/main.dart @@ -44,13 +44,13 @@ void main() { ); } -const double kWindowWidth = 1024; -const double kWindowHeight = 800; +const double windowWidth = 1024; +const double windowHeight = 800; void setupWindow() { if (!kIsWeb && (Platform.isWindows || Platform.isLinux || Platform.isMacOS)) { WidgetsFlutterBinding.ensureInitialized(); - setWindowMinSize(const Size(kWindowWidth, kWindowHeight)); + setWindowMinSize(const Size(windowWidth, windowHeight)); } } diff --git a/form_app/lib/main.dart b/form_app/lib/main.dart index 5c2af9da0..a0ebda026 100644 --- a/form_app/lib/main.dart +++ b/form_app/lib/main.dart @@ -19,20 +19,20 @@ void main() { runApp(const FormApp()); } -const double kWindowWidth = 480; -const double kWindowHeight = 854; +const double windowWidth = 480; +const double windowHeight = 854; void setupWindow() { if (!kIsWeb && (Platform.isWindows || Platform.isLinux || Platform.isMacOS)) { WidgetsFlutterBinding.ensureInitialized(); setWindowTitle('Form Samples'); - setWindowMinSize(const Size(kWindowWidth, kWindowHeight)); - setWindowMaxSize(const Size(kWindowWidth, kWindowHeight)); + setWindowMinSize(const Size(windowWidth, windowHeight)); + setWindowMaxSize(const Size(windowWidth, windowHeight)); getCurrentScreen().then((screen) { setWindowFrame(Rect.fromCenter( center: screen!.frame.center, - width: kWindowWidth, - height: kWindowHeight, + width: windowWidth, + height: windowHeight, )); }); } diff --git a/infinite_list/lib/main.dart b/infinite_list/lib/main.dart index 5017431b5..957765d97 100644 --- a/infinite_list/lib/main.dart +++ b/infinite_list/lib/main.dart @@ -17,20 +17,20 @@ void main() { runApp(const MyApp()); } -const double kWindowWidth = 480; -const double kWindowHeight = 854; +const double windowWidth = 480; +const double windowHeight = 854; void setupWindow() { if (!kIsWeb && (Platform.isWindows || Platform.isLinux || Platform.isMacOS)) { WidgetsFlutterBinding.ensureInitialized(); setWindowTitle('Infinite List'); - setWindowMinSize(const Size(kWindowWidth, kWindowHeight)); - setWindowMaxSize(const Size(kWindowWidth, kWindowHeight)); + setWindowMinSize(const Size(windowWidth, windowHeight)); + setWindowMaxSize(const Size(windowWidth, windowHeight)); getCurrentScreen().then((screen) { setWindowFrame(Rect.fromCenter( center: screen!.frame.center, - width: kWindowWidth, - height: kWindowHeight, + width: windowWidth, + height: windowHeight, )); }); } diff --git a/isolate_example/lib/main.dart b/isolate_example/lib/main.dart index e10c8c2d7..ea8c155eb 100644 --- a/isolate_example/lib/main.dart +++ b/isolate_example/lib/main.dart @@ -31,14 +31,14 @@ void main() { ); } -const double kWindowWidth = 1024; -const double kWindowHeight = 800; +const double windowWidth = 1024; +const double windowHeight = 800; void setupWindow() { if (!kIsWeb && (Platform.isWindows || Platform.isLinux || Platform.isMacOS)) { WidgetsFlutterBinding.ensureInitialized(); setWindowTitle('Isolate Example'); - setWindowMinSize(const Size(kWindowWidth, kWindowHeight)); + setWindowMinSize(const Size(windowWidth, windowHeight)); } } diff --git a/jsonexample/lib/main.dart b/jsonexample/lib/main.dart index f7a7865eb..325b01507 100644 --- a/jsonexample/lib/main.dart +++ b/jsonexample/lib/main.dart @@ -14,14 +14,14 @@ void main() { runApp(const MyApp()); } -const double kWindowWidth = 1200; -const double kWindowHeight = 800; +const double windowWidth = 1200; +const double windowHeight = 800; void setupWindow() { if (!kIsWeb && (Platform.isWindows || Platform.isLinux || Platform.isMacOS)) { WidgetsFlutterBinding.ensureInitialized(); setWindowTitle('JSON Sample'); - setWindowMinSize(const Size(kWindowWidth, kWindowHeight)); + setWindowMinSize(const Size(windowWidth, windowHeight)); } } diff --git a/null_safety/null_safe_app/lib/main.dart b/null_safety/null_safe_app/lib/main.dart index ca84d2486..a0bed71e1 100644 --- a/null_safety/null_safe_app/lib/main.dart +++ b/null_safety/null_safe_app/lib/main.dart @@ -15,13 +15,13 @@ void main() { runApp(const GoodMyApp()); } -const double kWindowWidth = 400; -const double kWindowHeight = 400; +const double windowWidth = 400; +const double windowHeight = 400; void setupWindow() { if (!kIsWeb && (Platform.isWindows || Platform.isLinux || Platform.isMacOS)) { WidgetsFlutterBinding.ensureInitialized(); setWindowTitle('Weather'); - setWindowMinSize(const Size(kWindowWidth, kWindowHeight)); + setWindowMinSize(const Size(windowWidth, windowHeight)); } } diff --git a/provider_shopper/lib/main.dart b/provider_shopper/lib/main.dart index 44e938dea..e7c97447c 100644 --- a/provider_shopper/lib/main.dart +++ b/provider_shopper/lib/main.dart @@ -20,20 +20,20 @@ void main() { runApp(const MyApp()); } -const double kWindowWidth = 400; -const double kWindowHeight = 800; +const double windowWidth = 400; +const double windowHeight = 800; void setupWindow() { if (!kIsWeb && (Platform.isWindows || Platform.isLinux || Platform.isMacOS)) { WidgetsFlutterBinding.ensureInitialized(); setWindowTitle('Provider Demo'); - setWindowMinSize(const Size(kWindowWidth, kWindowHeight)); - setWindowMaxSize(const Size(kWindowWidth, kWindowHeight)); + setWindowMinSize(const Size(windowWidth, windowHeight)); + setWindowMaxSize(const Size(windowWidth, windowHeight)); getCurrentScreen().then((screen) { setWindowFrame(Rect.fromCenter( center: screen!.frame.center, - width: kWindowWidth, - height: kWindowHeight, + width: windowWidth, + height: windowHeight, )); }); }