[various] Update Pigeon in Swift plugins (#4461)

Updates `pigeon` in all of our Swift plugins, to ensure that they have the fix for https://github.com/flutter/flutter/issues/129283

Fixes https://github.com/flutter/flutter/issues/129536
This commit is contained in:
stuartmorgan
2023-07-13 19:21:17 -04:00
committed by GitHub
parent d70eed039a
commit 808d790d8f
19 changed files with 86 additions and 66 deletions

View File

@ -1,3 +1,7 @@
## 0.9.3+1
* Updates to the latest version of `pigeon`.
## 0.9.3 ## 0.9.3
* Adds `getSaveLocation` and deprecates `getSavePath`. * Adds `getSaveLocation` and deprecates `getSavePath`.

View File

@ -1,7 +1,7 @@
// Copyright 2013 The Flutter Authors. All rights reserved. // Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
// Autogenerated from Pigeon (v9.2.4), do not edit directly. // Autogenerated from Pigeon (v10.1.3), do not edit directly.
// See also: https://pub.dev/packages/pigeon // See also: https://pub.dev/packages/pigeon
// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name, unnecessary_import // ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name, unnecessary_import

View File

@ -1,7 +1,7 @@
// Copyright 2013 The Flutter Authors. All rights reserved. // Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
// Autogenerated from Pigeon (v9.2.4), do not edit directly. // Autogenerated from Pigeon (v10.1.3), do not edit directly.
// See also: https://pub.dev/packages/pigeon // See also: https://pub.dev/packages/pigeon
import Foundation import Foundation
@ -35,7 +35,7 @@ private func wrapError(_ error: Any) -> [Any?] {
private func nilOrValue<T>(_ value: Any?) -> T? { private func nilOrValue<T>(_ value: Any?) -> T? {
if value is NSNull { return nil } if value is NSNull { return nil }
return (value as Any) as! T? return value as! T?
} }
/// A Pigeon representation of the macOS portion of an `XTypeGroup`. /// A Pigeon representation of the macOS portion of an `XTypeGroup`.
@ -46,7 +46,7 @@ struct AllowedTypes {
var mimeTypes: [String?] var mimeTypes: [String?]
var utis: [String?] var utis: [String?]
static func fromList(_ list: [Any]) -> AllowedTypes? { static func fromList(_ list: [Any?]) -> AllowedTypes? {
let extensions = list[0] as! [String?] let extensions = list[0] as! [String?]
let mimeTypes = list[1] as! [String?] let mimeTypes = list[1] as! [String?]
let utis = list[2] as! [String?] let utis = list[2] as! [String?]
@ -78,9 +78,9 @@ struct SavePanelOptions {
var nameFieldStringValue: String? = nil var nameFieldStringValue: String? = nil
var prompt: String? = nil var prompt: String? = nil
static func fromList(_ list: [Any]) -> SavePanelOptions? { static func fromList(_ list: [Any?]) -> SavePanelOptions? {
var allowedFileTypes: AllowedTypes? = nil var allowedFileTypes: AllowedTypes? = nil
if let allowedFileTypesList = list[0] as! [Any]? { if let allowedFileTypesList: [Any?] = nilOrValue(list[0]) {
allowedFileTypes = AllowedTypes.fromList(allowedFileTypesList) allowedFileTypes = AllowedTypes.fromList(allowedFileTypesList)
} }
let directoryPath: String? = nilOrValue(list[1]) let directoryPath: String? = nilOrValue(list[1])
@ -115,11 +115,11 @@ struct OpenPanelOptions {
var canChooseFiles: Bool var canChooseFiles: Bool
var baseOptions: SavePanelOptions var baseOptions: SavePanelOptions
static func fromList(_ list: [Any]) -> OpenPanelOptions? { static func fromList(_ list: [Any?]) -> OpenPanelOptions? {
let allowsMultipleSelection = list[0] as! Bool let allowsMultipleSelection = list[0] as! Bool
let canChooseDirectories = list[1] as! Bool let canChooseDirectories = list[1] as! Bool
let canChooseFiles = list[2] as! Bool let canChooseFiles = list[2] as! Bool
let baseOptions = SavePanelOptions.fromList(list[3] as! [Any])! let baseOptions = SavePanelOptions.fromList(list[3] as! [Any?])!
return OpenPanelOptions( return OpenPanelOptions(
allowsMultipleSelection: allowsMultipleSelection, allowsMultipleSelection: allowsMultipleSelection,
@ -142,11 +142,11 @@ private class FileSelectorApiCodecReader: FlutterStandardReader {
override func readValue(ofType type: UInt8) -> Any? { override func readValue(ofType type: UInt8) -> Any? {
switch type { switch type {
case 128: case 128:
return AllowedTypes.fromList(self.readValue() as! [Any]) return AllowedTypes.fromList(self.readValue() as! [Any?])
case 129: case 129:
return OpenPanelOptions.fromList(self.readValue() as! [Any]) return OpenPanelOptions.fromList(self.readValue() as! [Any?])
case 130: case 130:
return SavePanelOptions.fromList(self.readValue() as! [Any]) return SavePanelOptions.fromList(self.readValue() as! [Any?])
default: default:
return super.readValue(ofType: type) return super.readValue(ofType: type)
} }
@ -214,7 +214,7 @@ class FileSelectorApiSetup {
codec: codec) codec: codec)
if let api = api { if let api = api {
displayOpenPanelChannel.setMessageHandler { message, reply in displayOpenPanelChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let optionsArg = args[0] as! OpenPanelOptions let optionsArg = args[0] as! OpenPanelOptions
api.displayOpenPanel(options: optionsArg) { result in api.displayOpenPanel(options: optionsArg) { result in
switch result { switch result {
@ -236,7 +236,7 @@ class FileSelectorApiSetup {
codec: codec) codec: codec)
if let api = api { if let api = api {
displaySavePanelChannel.setMessageHandler { message, reply in displaySavePanelChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let optionsArg = args[0] as! SavePanelOptions let optionsArg = args[0] as! SavePanelOptions
api.displaySavePanel(options: optionsArg) { result in api.displaySavePanel(options: optionsArg) { result in
switch result { switch result {

View File

@ -2,7 +2,7 @@ name: file_selector_macos
description: macOS implementation of the file_selector plugin. description: macOS implementation of the file_selector plugin.
repository: https://github.com/flutter/packages/tree/main/packages/file_selector/file_selector_macos repository: https://github.com/flutter/packages/tree/main/packages/file_selector/file_selector_macos
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+file_selector%22 issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+file_selector%22
version: 0.9.3 version: 0.9.3+1
environment: environment:
sdk: ">=2.18.0 <4.0.0" sdk: ">=2.18.0 <4.0.0"
@ -27,4 +27,4 @@ dev_dependencies:
flutter_test: flutter_test:
sdk: flutter sdk: flutter
mockito: 5.4.1 mockito: 5.4.1
pigeon: ^9.2.4 pigeon: ^10.1.3

View File

@ -1,7 +1,7 @@
// Copyright 2013 The Flutter Authors. All rights reserved. // Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
// Autogenerated from Pigeon (v9.2.4), do not edit directly. // Autogenerated from Pigeon (v10.1.3), do not edit directly.
// See also: https://pub.dev/packages/pigeon // See also: https://pub.dev/packages/pigeon
// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, unnecessary_import // ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, unnecessary_import
// ignore_for_file: avoid_relative_lib_imports // ignore_for_file: avoid_relative_lib_imports

View File

@ -1,5 +1,6 @@
## NEXT ## 2.2.4
* Updates to the latest version of `pigeon`.
* Updates minimum supported macOS version to 10.14. * Updates minimum supported macOS version to 10.14.
## 2.2.3 ## 2.2.3

View File

@ -1,16 +1,17 @@
// Copyright 2013 The Flutter Authors. All rights reserved. // Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
// Autogenerated from Pigeon (v9.2.4), do not edit directly. // Autogenerated from Pigeon (v10.1.3), do not edit directly.
// See also: https://pub.dev/packages/pigeon // See also: https://pub.dev/packages/pigeon
import Foundation import Foundation
#if os(iOS) #if os(iOS)
import Flutter import Flutter
#elseif os(macOS) #elseif os(macOS)
import FlutterMacOS import FlutterMacOS
#else #else
#error("Unsupported platform.") #error("Unsupported platform.")
#endif #endif
private func wrapResult(_ result: Any?) -> [Any?] { private func wrapResult(_ result: Any?) -> [Any?] {
@ -22,19 +23,19 @@ private func wrapError(_ error: Any) -> [Any?] {
return [ return [
flutterError.code, flutterError.code,
flutterError.message, flutterError.message,
flutterError.details flutterError.details,
] ]
} }
return [ return [
"\(error)", "\(error)",
"\(type(of: error))", "\(type(of: error))",
"Stacktrace: \(Thread.callStackSymbols)" "Stacktrace: \(Thread.callStackSymbols)",
] ]
} }
private func nilOrValue<T>(_ value: Any?) -> T? { private func nilOrValue<T>(_ value: Any?) -> T? {
if value is NSNull { return nil } if value is NSNull { return nil }
return (value as Any) as! T? return value as! T?
} }
enum DirectoryType: Int { enum DirectoryType: Int {
@ -55,10 +56,11 @@ class PathProviderApiSetup {
/// The codec used by PathProviderApi. /// The codec used by PathProviderApi.
/// Sets up an instance of `PathProviderApi` to handle messages through the `binaryMessenger`. /// Sets up an instance of `PathProviderApi` to handle messages through the `binaryMessenger`.
static func setUp(binaryMessenger: FlutterBinaryMessenger, api: PathProviderApi?) { static func setUp(binaryMessenger: FlutterBinaryMessenger, api: PathProviderApi?) {
let getDirectoryPathChannel = FlutterBasicMessageChannel(name: "dev.flutter.pigeon.PathProviderApi.getDirectoryPath", binaryMessenger: binaryMessenger) let getDirectoryPathChannel = FlutterBasicMessageChannel(
name: "dev.flutter.pigeon.PathProviderApi.getDirectoryPath", binaryMessenger: binaryMessenger)
if let api = api { if let api = api {
getDirectoryPathChannel.setMessageHandler { message, reply in getDirectoryPathChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let typeArg = DirectoryType(rawValue: args[0] as! Int)! let typeArg = DirectoryType(rawValue: args[0] as! Int)!
do { do {
let result = try api.getDirectoryPath(type: typeArg) let result = try api.getDirectoryPath(type: typeArg)
@ -70,10 +72,11 @@ class PathProviderApiSetup {
} else { } else {
getDirectoryPathChannel.setMessageHandler(nil) getDirectoryPathChannel.setMessageHandler(nil)
} }
let getContainerPathChannel = FlutterBasicMessageChannel(name: "dev.flutter.pigeon.PathProviderApi.getContainerPath", binaryMessenger: binaryMessenger) let getContainerPathChannel = FlutterBasicMessageChannel(
name: "dev.flutter.pigeon.PathProviderApi.getContainerPath", binaryMessenger: binaryMessenger)
if let api = api { if let api = api {
getContainerPathChannel.setMessageHandler { message, reply in getContainerPathChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let appGroupIdentifierArg = args[0] as! String let appGroupIdentifierArg = args[0] as! String
do { do {
let result = try api.getContainerPath(appGroupIdentifier: appGroupIdentifierArg) let result = try api.getContainerPath(appGroupIdentifier: appGroupIdentifierArg)

View File

@ -1,7 +1,7 @@
// Copyright 2013 The Flutter Authors. All rights reserved. // Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
// Autogenerated from Pigeon (v9.2.4), do not edit directly. // Autogenerated from Pigeon (v10.1.3), do not edit directly.
// See also: https://pub.dev/packages/pigeon // See also: https://pub.dev/packages/pigeon
// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name, unnecessary_import // ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name, unnecessary_import

View File

@ -2,7 +2,7 @@ name: path_provider_foundation
description: iOS and macOS implementation of the path_provider plugin description: iOS and macOS implementation of the path_provider plugin
repository: https://github.com/flutter/packages/tree/main/packages/path_provider/path_provider_foundation repository: https://github.com/flutter/packages/tree/main/packages/path_provider/path_provider_foundation
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+path_provider%22 issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+path_provider%22
version: 2.2.3 version: 2.2.4
environment: environment:
sdk: ">=2.18.0 <4.0.0" sdk: ">=2.18.0 <4.0.0"
@ -32,4 +32,4 @@ dev_dependencies:
sdk: flutter sdk: flutter
mockito: 5.4.1 mockito: 5.4.1
path: ^1.8.0 path: ^1.8.0
pigeon: ^9.2.4 pigeon: ^10.1.3

View File

@ -1,7 +1,7 @@
// Copyright 2013 The Flutter Authors. All rights reserved. // Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
// Autogenerated from Pigeon (v9.2.4), do not edit directly. // Autogenerated from Pigeon (v10.1.3), do not edit directly.
// See also: https://pub.dev/packages/pigeon // See also: https://pub.dev/packages/pigeon
// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, unnecessary_import // ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, unnecessary_import
// ignore_for_file: avoid_relative_lib_imports // ignore_for_file: avoid_relative_lib_imports

View File

@ -1,3 +1,7 @@
## 2.3.2
* Updates to the latest version of `pigeon`.
## 2.3.1 ## 2.3.1
* Fixes variable binding bug on older versions of Xcode. * Fixes variable binding bug on older versions of Xcode.

View File

@ -1,16 +1,17 @@
// Copyright 2013 The Flutter Authors. All rights reserved. // Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
// Autogenerated from Pigeon (v9.2.5), do not edit directly. // Autogenerated from Pigeon (v10.1.3), do not edit directly.
// See also: https://pub.dev/packages/pigeon // See also: https://pub.dev/packages/pigeon
import Foundation import Foundation
#if os(iOS) #if os(iOS)
import Flutter import Flutter
#elseif os(macOS) #elseif os(macOS)
import FlutterMacOS import FlutterMacOS
#else #else
#error("Unsupported platform.") #error("Unsupported platform.")
#endif #endif
private func wrapResult(_ result: Any?) -> [Any?] { private func wrapResult(_ result: Any?) -> [Any?] {
@ -22,19 +23,19 @@ private func wrapError(_ error: Any) -> [Any?] {
return [ return [
flutterError.code, flutterError.code,
flutterError.message, flutterError.message,
flutterError.details flutterError.details,
] ]
} }
return [ return [
"\(error)", "\(error)",
"\(type(of: error))", "\(type(of: error))",
"Stacktrace: \(Thread.callStackSymbols)" "Stacktrace: \(Thread.callStackSymbols)",
] ]
} }
private func nilOrValue<T>(_ value: Any?) -> T? { private func nilOrValue<T>(_ value: Any?) -> T? {
if value is NSNull { return nil } if value is NSNull { return nil }
return (value as Any) as! T? return value as! T?
} }
/// Generated protocol from Pigeon that represents a handler of messages from Flutter. /// Generated protocol from Pigeon that represents a handler of messages from Flutter.
protocol UserDefaultsApi { protocol UserDefaultsApi {
@ -51,10 +52,11 @@ class UserDefaultsApiSetup {
/// The codec used by UserDefaultsApi. /// The codec used by UserDefaultsApi.
/// Sets up an instance of `UserDefaultsApi` to handle messages through the `binaryMessenger`. /// Sets up an instance of `UserDefaultsApi` to handle messages through the `binaryMessenger`.
static func setUp(binaryMessenger: FlutterBinaryMessenger, api: UserDefaultsApi?) { static func setUp(binaryMessenger: FlutterBinaryMessenger, api: UserDefaultsApi?) {
let removeChannel = FlutterBasicMessageChannel(name: "dev.flutter.pigeon.UserDefaultsApi.remove", binaryMessenger: binaryMessenger) let removeChannel = FlutterBasicMessageChannel(
name: "dev.flutter.pigeon.UserDefaultsApi.remove", binaryMessenger: binaryMessenger)
if let api = api { if let api = api {
removeChannel.setMessageHandler { message, reply in removeChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let keyArg = args[0] as! String let keyArg = args[0] as! String
do { do {
try api.remove(key: keyArg) try api.remove(key: keyArg)
@ -66,10 +68,11 @@ class UserDefaultsApiSetup {
} else { } else {
removeChannel.setMessageHandler(nil) removeChannel.setMessageHandler(nil)
} }
let setBoolChannel = FlutterBasicMessageChannel(name: "dev.flutter.pigeon.UserDefaultsApi.setBool", binaryMessenger: binaryMessenger) let setBoolChannel = FlutterBasicMessageChannel(
name: "dev.flutter.pigeon.UserDefaultsApi.setBool", binaryMessenger: binaryMessenger)
if let api = api { if let api = api {
setBoolChannel.setMessageHandler { message, reply in setBoolChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let keyArg = args[0] as! String let keyArg = args[0] as! String
let valueArg = args[1] as! Bool let valueArg = args[1] as! Bool
do { do {
@ -82,10 +85,11 @@ class UserDefaultsApiSetup {
} else { } else {
setBoolChannel.setMessageHandler(nil) setBoolChannel.setMessageHandler(nil)
} }
let setDoubleChannel = FlutterBasicMessageChannel(name: "dev.flutter.pigeon.UserDefaultsApi.setDouble", binaryMessenger: binaryMessenger) let setDoubleChannel = FlutterBasicMessageChannel(
name: "dev.flutter.pigeon.UserDefaultsApi.setDouble", binaryMessenger: binaryMessenger)
if let api = api { if let api = api {
setDoubleChannel.setMessageHandler { message, reply in setDoubleChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let keyArg = args[0] as! String let keyArg = args[0] as! String
let valueArg = args[1] as! Double let valueArg = args[1] as! Double
do { do {
@ -98,12 +102,13 @@ class UserDefaultsApiSetup {
} else { } else {
setDoubleChannel.setMessageHandler(nil) setDoubleChannel.setMessageHandler(nil)
} }
let setValueChannel = FlutterBasicMessageChannel(name: "dev.flutter.pigeon.UserDefaultsApi.setValue", binaryMessenger: binaryMessenger) let setValueChannel = FlutterBasicMessageChannel(
name: "dev.flutter.pigeon.UserDefaultsApi.setValue", binaryMessenger: binaryMessenger)
if let api = api { if let api = api {
setValueChannel.setMessageHandler { message, reply in setValueChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let keyArg = args[0] as! String let keyArg = args[0] as! String
let valueArg = args[1] let valueArg = args[1]!
do { do {
try api.setValue(key: keyArg, value: valueArg) try api.setValue(key: keyArg, value: valueArg)
reply(wrapResult(nil)) reply(wrapResult(nil))
@ -114,10 +119,11 @@ class UserDefaultsApiSetup {
} else { } else {
setValueChannel.setMessageHandler(nil) setValueChannel.setMessageHandler(nil)
} }
let getAllChannel = FlutterBasicMessageChannel(name: "dev.flutter.pigeon.UserDefaultsApi.getAll", binaryMessenger: binaryMessenger) let getAllChannel = FlutterBasicMessageChannel(
name: "dev.flutter.pigeon.UserDefaultsApi.getAll", binaryMessenger: binaryMessenger)
if let api = api { if let api = api {
getAllChannel.setMessageHandler { message, reply in getAllChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let prefixArg = args[0] as! String let prefixArg = args[0] as! String
let allowListArg: [String]? = nilOrValue(args[1]) let allowListArg: [String]? = nilOrValue(args[1])
do { do {
@ -130,10 +136,11 @@ class UserDefaultsApiSetup {
} else { } else {
getAllChannel.setMessageHandler(nil) getAllChannel.setMessageHandler(nil)
} }
let clearChannel = FlutterBasicMessageChannel(name: "dev.flutter.pigeon.UserDefaultsApi.clear", binaryMessenger: binaryMessenger) let clearChannel = FlutterBasicMessageChannel(
name: "dev.flutter.pigeon.UserDefaultsApi.clear", binaryMessenger: binaryMessenger)
if let api = api { if let api = api {
clearChannel.setMessageHandler { message, reply in clearChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let prefixArg = args[0] as! String let prefixArg = args[0] as! String
let allowListArg: [String]? = nilOrValue(args[1]) let allowListArg: [String]? = nilOrValue(args[1])
do { do {

View File

@ -1,7 +1,7 @@
// Copyright 2013 The Flutter Authors. All rights reserved. // Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
// Autogenerated from Pigeon (v9.2.5), do not edit directly. // Autogenerated from Pigeon (v10.1.3), do not edit directly.
// See also: https://pub.dev/packages/pigeon // See also: https://pub.dev/packages/pigeon
// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name, unnecessary_import // ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name, unnecessary_import

View File

@ -2,7 +2,7 @@ name: shared_preferences_foundation
description: iOS and macOS implementation of the shared_preferences plugin. description: iOS and macOS implementation of the shared_preferences plugin.
repository: https://github.com/flutter/packages/tree/main/packages/shared_preferences/shared_preferences_foundation repository: https://github.com/flutter/packages/tree/main/packages/shared_preferences/shared_preferences_foundation
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+shared_preferences%22 issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+shared_preferences%22
version: 2.3.1 version: 2.3.2
environment: environment:
sdk: ">=2.18.0 <4.0.0" sdk: ">=2.18.0 <4.0.0"
@ -29,4 +29,4 @@ dependencies:
dev_dependencies: dev_dependencies:
flutter_test: flutter_test:
sdk: flutter sdk: flutter
pigeon: ^9.2.4 pigeon: ^10.1.3

View File

@ -1,7 +1,7 @@
// Copyright 2013 The Flutter Authors. All rights reserved. // Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
// Autogenerated from Pigeon (v9.2.5), do not edit directly. // Autogenerated from Pigeon (v10.1.3), do not edit directly.
// See also: https://pub.dev/packages/pigeon // See also: https://pub.dev/packages/pigeon
// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, unnecessary_import // ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, unnecessary_import
// ignore_for_file: avoid_relative_lib_imports // ignore_for_file: avoid_relative_lib_imports

View File

@ -1,5 +1,6 @@
## NEXT ## 3.0.6
* Updates to the latest version of `pigeon`.
* Updates minimum supported macOS version to 10.14. * Updates minimum supported macOS version to 10.14.
* Updates minimum supported SDK version to Flutter 3.3/Dart 2.18. * Updates minimum supported SDK version to Flutter 3.3/Dart 2.18.

View File

@ -1,7 +1,7 @@
// Copyright 2013 The Flutter Authors. All rights reserved. // Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
// Autogenerated from Pigeon (v9.2.4), do not edit directly. // Autogenerated from Pigeon (v10.1.3), do not edit directly.
// See also: https://pub.dev/packages/pigeon // See also: https://pub.dev/packages/pigeon
// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name, unnecessary_import // ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name, unnecessary_import

View File

@ -1,7 +1,7 @@
// Copyright 2013 The Flutter Authors. All rights reserved. // Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
// Autogenerated from Pigeon (v9.2.4), do not edit directly. // Autogenerated from Pigeon (v10.1.3), do not edit directly.
// See also: https://pub.dev/packages/pigeon // See also: https://pub.dev/packages/pigeon
import Foundation import Foundation
@ -35,7 +35,7 @@ private func wrapError(_ error: Any) -> [Any?] {
private func nilOrValue<T>(_ value: Any?) -> T? { private func nilOrValue<T>(_ value: Any?) -> T? {
if value is NSNull { return nil } if value is NSNull { return nil }
return (value as Any) as! T? return value as! T?
} }
/// Possible error conditions for [UrlLauncherApi] calls. /// Possible error conditions for [UrlLauncherApi] calls.
@ -51,7 +51,7 @@ struct UrlLauncherBoolResult {
var value: Bool var value: Bool
var error: UrlLauncherError? = nil var error: UrlLauncherError? = nil
static func fromList(_ list: [Any]) -> UrlLauncherBoolResult? { static func fromList(_ list: [Any?]) -> UrlLauncherBoolResult? {
let value = list[0] as! Bool let value = list[0] as! Bool
var error: UrlLauncherError? = nil var error: UrlLauncherError? = nil
let errorEnumVal: Int? = nilOrValue(list[1]) let errorEnumVal: Int? = nilOrValue(list[1])
@ -75,7 +75,7 @@ private class UrlLauncherApiCodecReader: FlutterStandardReader {
override func readValue(ofType type: UInt8) -> Any? { override func readValue(ofType type: UInt8) -> Any? {
switch type { switch type {
case 128: case 128:
return UrlLauncherBoolResult.fromList(self.readValue() as! [Any]) return UrlLauncherBoolResult.fromList(self.readValue() as! [Any?])
default: default:
return super.readValue(ofType: type) return super.readValue(ofType: type)
} }
@ -127,7 +127,7 @@ class UrlLauncherApiSetup {
codec: codec) codec: codec)
if let api = api { if let api = api {
canLaunchUrlChannel.setMessageHandler { message, reply in canLaunchUrlChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let urlArg = args[0] as! String let urlArg = args[0] as! String
do { do {
let result = try api.canLaunch(url: urlArg) let result = try api.canLaunch(url: urlArg)
@ -145,7 +145,7 @@ class UrlLauncherApiSetup {
codec: codec) codec: codec)
if let api = api { if let api = api {
launchUrlChannel.setMessageHandler { message, reply in launchUrlChannel.setMessageHandler { message, reply in
let args = message as! [Any] let args = message as! [Any?]
let urlArg = args[0] as! String let urlArg = args[0] as! String
do { do {
let result = try api.launch(url: urlArg) let result = try api.launch(url: urlArg)

View File

@ -2,7 +2,7 @@ name: url_launcher_macos
description: macOS implementation of the url_launcher plugin. description: macOS implementation of the url_launcher plugin.
repository: https://github.com/flutter/packages/tree/main/packages/url_launcher/url_launcher_macos repository: https://github.com/flutter/packages/tree/main/packages/url_launcher/url_launcher_macos
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+url_launcher%22 issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+url_launcher%22
version: 3.0.5 version: 3.0.6
environment: environment:
sdk: ">=2.18.0 <4.0.0" sdk: ">=2.18.0 <4.0.0"
@ -25,5 +25,5 @@ dependencies:
dev_dependencies: dev_dependencies:
flutter_test: flutter_test:
sdk: flutter sdk: flutter
pigeon: ^9.2.4 pigeon: ^10.1.3
test: ^1.16.3 test: ^1.16.3