Add support for older macOS versions
This commit is contained in:
parent
c825ccebb9
commit
7d80bb7da7
@ -12,7 +12,7 @@ import PackageDescription
|
||||
let package = Package(
|
||||
name: "Adwaita",
|
||||
platforms: [
|
||||
.macOS(.v13)
|
||||
.macOS(.v10_15)
|
||||
],
|
||||
products: [
|
||||
.library(
|
||||
|
||||
@ -74,7 +74,7 @@ struct Class: ClassLike, Decodable {
|
||||
// \(widgetName).swift
|
||||
// Adwaita
|
||||
//
|
||||
// Created by auto-generation on \(dateFormatter.string(from: .now)).
|
||||
// Created by auto-generation on \(dateFormatter.string(from: .init())).
|
||||
//
|
||||
|
||||
import CAdw
|
||||
|
||||
@ -74,7 +74,7 @@ struct Generation {
|
||||
func getGtkDefinitions(path: String) -> GIR? {
|
||||
var path = path
|
||||
let girDir = getGtkGirDir()
|
||||
path.replace(GenerationConfiguration.gtkIncludeDir, with: girDir)
|
||||
path = path.replacingOccurrences(of: GenerationConfiguration.gtkIncludeDir, with: girDir)
|
||||
let data = (try? Data(contentsOf: .init(fileURLWithPath: path))) ?? .init()
|
||||
return try? GIR.decodeGIR(data)
|
||||
}
|
||||
@ -85,7 +85,7 @@ struct Generation {
|
||||
func getAdwDefinitions(path: String) -> GIR? {
|
||||
var path = path
|
||||
let girDir = getAdwGirDir()
|
||||
path.replace(GenerationConfiguration.adwIncludeDir, with: girDir)
|
||||
path = path.replacingOccurrences(of: GenerationConfiguration.adwIncludeDir, with: girDir)
|
||||
let data = (try? Data(contentsOf: .init(fileURLWithPath: path))) ?? .init()
|
||||
return try? GIR.decodeGIR(data)
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user