From cf4c1b11af56052e31625351187b841aea313759 Mon Sep 17 00:00:00 2001 From: tim Hoogstrate Date: Wed, 28 May 2025 08:52:54 +0200 Subject: [PATCH 1/2] Fixed iOS deprecation warnings --- .../ios/Runner.xcodeproj/project.pbxproj | 31 ++++++++++++++++--- .../xcshareddata/xcschemes/Runner.xcscheme | 3 +- geocoding_ios/example/lib/main.dart | 14 ++++----- .../lib/plugin_example/geocode_page.dart | 2 +- .../example/lib/template/info_page.dart | 2 +- geocoding_ios/pubspec.yaml | 2 +- 6 files changed, 38 insertions(+), 16 deletions(-) diff --git a/geocoding_ios/example/ios/Runner.xcodeproj/project.pbxproj b/geocoding_ios/example/ios/Runner.xcodeproj/project.pbxproj index 70d7845..cca6995 100644 --- a/geocoding_ios/example/ios/Runner.xcodeproj/project.pbxproj +++ b/geocoding_ios/example/ios/Runner.xcodeproj/project.pbxproj @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 50; + objectVersion = 54; objects = { /* Begin PBXBuildFile section */ @@ -149,6 +149,7 @@ 97C146EC1CF9000F007C117D /* Resources */, 9705A1C41CF9048500538489 /* Embed Frameworks */, 3B06AD1E1E4923F5004D2608 /* Thin Binary */, + AD45FF7066E03502A9EA61B3 /* [CP] Copy Pods Resources */, ); buildRules = ( ); @@ -165,7 +166,7 @@ 97C146E61CF9000F007C117D /* Project object */ = { isa = PBXProject; attributes = { - LastUpgradeCheck = 1020; + LastUpgradeCheck = 1510; ORGANIZATIONNAME = ""; TargetAttributes = { 97C146ED1CF9000F007C117D = { @@ -208,10 +209,12 @@ /* Begin PBXShellScriptBuildPhase section */ 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { isa = PBXShellScriptBuildPhase; + alwaysOutOfDate = 1; buildActionMask = 2147483647; files = ( ); inputPaths = ( + "${TARGET_BUILD_DIR}/${INFOPLIST_PATH}", ); name = "Thin Binary"; outputPaths = ( @@ -244,6 +247,7 @@ }; 9740EEB61CF901F6004384FC /* Run Script */ = { isa = PBXShellScriptBuildPhase; + alwaysOutOfDate = 1; buildActionMask = 2147483647; files = ( ); @@ -256,6 +260,23 @@ shellPath = /bin/sh; shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; }; + AD45FF7066E03502A9EA61B3 /* [CP] Copy Pods Resources */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources-${CONFIGURATION}-input-files.xcfilelist", + ); + name = "[CP] Copy Pods Resources"; + outputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources-${CONFIGURATION}-output-files.xcfilelist", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources.sh\"\n"; + showEnvVarsInLog = 0; + }; /* End PBXShellScriptBuildPhase section */ /* Begin PBXSourcesBuildPhase section */ @@ -332,7 +353,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; + IPHONEOS_DEPLOYMENT_TARGET = 12.0; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = iphoneos; SUPPORTED_PLATFORMS = iphoneos; @@ -414,7 +435,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; + IPHONEOS_DEPLOYMENT_TARGET = 12.0; MTL_ENABLE_DEBUG_INFO = YES; ONLY_ACTIVE_ARCH = YES; SDKROOT = iphoneos; @@ -463,7 +484,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; + IPHONEOS_DEPLOYMENT_TARGET = 12.0; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = iphoneos; SUPPORTED_PLATFORMS = iphoneos; diff --git a/geocoding_ios/example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/geocoding_ios/example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme index a28140c..4f74653 100644 --- a/geocoding_ios/example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme +++ b/geocoding_ios/example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme @@ -1,6 +1,6 @@ diff --git a/geocoding_ios/example/lib/main.dart b/geocoding_ios/example/lib/main.dart index db90df3..fdb3997 100644 --- a/geocoding_ios/example/lib/main.dart +++ b/geocoding_ios/example/lib/main.dart @@ -13,7 +13,7 @@ class BaseflowPluginExample extends StatelessWidget { createMaterialColor(const Color.fromRGBO(48, 49, 60, 1)); /// Constructs the [BaseflowPluginExample] class - BaseflowPluginExample({Key? key}) : super(key: key); + BaseflowPluginExample({super.key}); @override Widget build(BuildContext context) { @@ -68,7 +68,7 @@ class BaseflowPluginExample extends StatelessWidget { static MaterialColor createMaterialColor(Color color) { final strengths = [.05]; final swatch = {}; - final r = color.red, g = color.green, b = color.blue; + final r = color.r, g = color.g, b = color.b; for (var i = 1; i < 10; i++) { strengths.add(0.1 * i); @@ -76,20 +76,20 @@ class BaseflowPluginExample extends StatelessWidget { for (var strength in strengths) { final ds = 0.5 - strength; swatch[(strength * 1000).round()] = Color.fromRGBO( - r + ((ds < 0 ? r : (255 - r)) * ds).round(), - g + ((ds < 0 ? g : (255 - g)) * ds).round(), - b + ((ds < 0 ? b : (255 - b)) * ds).round(), + (r + ((ds < 0 ? r : (1.0 - r)) * ds) * 255).round(), + (g + ((ds < 0 ? g : (1.0 - g)) * ds) * 255).round(), + (b + ((ds < 0 ? b : (1.0 - b)) * ds) * 255).round(), 1, ); } - return MaterialColor(color.value, swatch); + return MaterialColor(color.toARGB32(), swatch); } } /// A Flutter example demonstrating how the [pluginName] plugin could be used class AppHome extends StatefulWidget { /// Constructs the [AppHome] class - const AppHome({Key? key, required this.title}) : super(key: key); + const AppHome({super.key, required this.title}); /// The [title] of the application, which is shown in the application's /// title bar. diff --git a/geocoding_ios/example/lib/plugin_example/geocode_page.dart b/geocoding_ios/example/lib/plugin_example/geocode_page.dart index 138a0f4..c934c43 100644 --- a/geocoding_ios/example/lib/plugin_example/geocode_page.dart +++ b/geocoding_ios/example/lib/plugin_example/geocode_page.dart @@ -6,7 +6,7 @@ import '../template/globals.dart'; /// Example [Widget] showing the use of the Geocode plugin class GeocodeWidget extends StatefulWidget { /// Constructs the [GeocodeWidget] class - const GeocodeWidget({Key? key}) : super(key: key); + const GeocodeWidget({super.key}); @override State createState() => _GeocodeWidgetState(); diff --git a/geocoding_ios/example/lib/template/info_page.dart b/geocoding_ios/example/lib/template/info_page.dart index 0df0faa..e664649 100644 --- a/geocoding_ios/example/lib/template/info_page.dart +++ b/geocoding_ios/example/lib/template/info_page.dart @@ -6,7 +6,7 @@ import 'globals.dart'; /// [StatelessWidget] displaying information about Baseflow class InfoPage extends StatelessWidget { /// Constructs the [InfoPage] class - const InfoPage({Key? key}) : super(key: key); + const InfoPage({super.key}); @override Widget build(BuildContext context) { diff --git a/geocoding_ios/pubspec.yaml b/geocoding_ios/pubspec.yaml index fc0cb41..0ced92a 100644 --- a/geocoding_ios/pubspec.yaml +++ b/geocoding_ios/pubspec.yaml @@ -1,6 +1,6 @@ name: geocoding_ios description: A Flutter Geocoding plugin which provides easy geocoding and reverse-geocoding features. -version: 3.0.1 +version: 3.0.2 repository: https://github.com/baseflow/flutter-geocoding/tree/main/geocoding_ios issue_tracker: https://github.com/Baseflow/flutter-geocoding/issues From 56d22ba2a50f86d986a0863c981f0b34e99861b2 Mon Sep 17 00:00:00 2001 From: tim Hoogstrate Date: Wed, 28 May 2025 10:51:57 +0200 Subject: [PATCH 2/2] added changelog --- geocoding_ios/CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/geocoding_ios/CHANGELOG.md b/geocoding_ios/CHANGELOG.md index ffaa32c..3e5ea30 100644 --- a/geocoding_ios/CHANGELOG.md +++ b/geocoding_ios/CHANGELOG.md @@ -1,3 +1,7 @@ +## 3.0.2 + +* Fixed deprecation warnings. + ## 3.0.1 * Adds privacy manifest.