Compare commits

...

3 Commits

5 changed files with 17 additions and 12 deletions

View File

@ -36,8 +36,8 @@ class AutocompleteEmojisController: ViewController {
.removeDuplicates() .removeDuplicates()
.sink { [unowned self] query in .sink { [unowned self] query in
self.searchTask?.cancel() self.searchTask?.cancel()
self.searchTask = Task { self.searchTask = Task { [weak self] in
await self.queryChanged(query) await self?.queryChanged(query)
} }
} }
} }

View File

@ -34,8 +34,8 @@ class AutocompleteHashtagsController: ViewController {
.debounce(for: .milliseconds(250), scheduler: DispatchQueue.main) .debounce(for: .milliseconds(250), scheduler: DispatchQueue.main)
.sink { [unowned self] query in .sink { [unowned self] query in
self.searchTask?.cancel() self.searchTask?.cancel()
self.searchTask = Task { self.searchTask = Task { [weak self] in
await self.queryChanged(query) await self?.queryChanged(query)
} }
} }
} }

View File

@ -36,8 +36,9 @@ class AutocompleteMentionsController: ViewController {
.debounce(for: .milliseconds(250), scheduler: DispatchQueue.main) .debounce(for: .milliseconds(250), scheduler: DispatchQueue.main)
.sink { [unowned self] query in .sink { [unowned self] query in
self.searchTask?.cancel() self.searchTask?.cancel()
self.searchTask = Task { // weak in case the autocomplete controller is dealloc'd racing with the task starting
await self.queryChanged(query) self.searchTask = Task { [weak self] in
await self?.queryChanged(query)
} }
} }
} }

View File

@ -2398,7 +2398,7 @@
CODE_SIGN_ENTITLEMENTS = Tusker/Tusker.entitlements; CODE_SIGN_ENTITLEMENTS = Tusker/Tusker.entitlements;
CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_IDENTITY = "iPhone Developer";
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 100; CURRENT_PROJECT_VERSION = 101;
INFOPLIST_FILE = Tusker/Info.plist; INFOPLIST_FILE = Tusker/Info.plist;
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.social-networking"; INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.social-networking";
IPHONEOS_DEPLOYMENT_TARGET = 15.0; IPHONEOS_DEPLOYMENT_TARGET = 15.0;
@ -2406,7 +2406,7 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 2023.6; MARKETING_VERSION = 2023.7;
OTHER_CODE_SIGN_FLAGS = ""; OTHER_CODE_SIGN_FLAGS = "";
PRODUCT_BUNDLE_IDENTIFIER = "$(BUNDLE_ID_PREFIX).Tusker"; PRODUCT_BUNDLE_IDENTIFIER = "$(BUNDLE_ID_PREFIX).Tusker";
PRODUCT_NAME = "$(TARGET_NAME)"; PRODUCT_NAME = "$(TARGET_NAME)";
@ -2703,7 +2703,7 @@
CODE_SIGN_ENTITLEMENTS = Tusker/Tusker.entitlements; CODE_SIGN_ENTITLEMENTS = Tusker/Tusker.entitlements;
CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_IDENTITY = "iPhone Developer";
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 100; CURRENT_PROJECT_VERSION = 101;
INFOPLIST_FILE = Tusker/Info.plist; INFOPLIST_FILE = Tusker/Info.plist;
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.social-networking"; INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.social-networking";
IPHONEOS_DEPLOYMENT_TARGET = 15.0; IPHONEOS_DEPLOYMENT_TARGET = 15.0;
@ -2711,7 +2711,7 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 2023.6; MARKETING_VERSION = 2023.7;
OTHER_CODE_SIGN_FLAGS = ""; OTHER_CODE_SIGN_FLAGS = "";
OTHER_LDFLAGS = ""; OTHER_LDFLAGS = "";
PRODUCT_BUNDLE_IDENTIFIER = "$(BUNDLE_ID_PREFIX).Tusker"; PRODUCT_BUNDLE_IDENTIFIER = "$(BUNDLE_ID_PREFIX).Tusker";
@ -2734,7 +2734,7 @@
CODE_SIGN_ENTITLEMENTS = Tusker/Tusker.entitlements; CODE_SIGN_ENTITLEMENTS = Tusker/Tusker.entitlements;
CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_IDENTITY = "iPhone Developer";
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 100; CURRENT_PROJECT_VERSION = 101;
INFOPLIST_FILE = Tusker/Info.plist; INFOPLIST_FILE = Tusker/Info.plist;
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.social-networking"; INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.social-networking";
IPHONEOS_DEPLOYMENT_TARGET = 15.0; IPHONEOS_DEPLOYMENT_TARGET = 15.0;
@ -2742,7 +2742,7 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 2023.6; MARKETING_VERSION = 2023.7;
OTHER_CODE_SIGN_FLAGS = ""; OTHER_CODE_SIGN_FLAGS = "";
PRODUCT_BUNDLE_IDENTIFIER = "$(BUNDLE_ID_PREFIX).Tusker"; PRODUCT_BUNDLE_IDENTIFIER = "$(BUNDLE_ID_PREFIX).Tusker";
PRODUCT_NAME = "$(TARGET_NAME)"; PRODUCT_NAME = "$(TARGET_NAME)";

View File

@ -198,7 +198,11 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
} }
} }
@available(iOS, obsoleted: 17.0)
private func swizzlePresentationController() { private func swizzlePresentationController() {
guard #unavailable(iOS 17.0) else {
return
}
var originalIMP: IMP? var originalIMP: IMP?
let imp = imp_implementationWithBlock({ (self: UIPresentationController) in let imp = imp_implementationWithBlock({ (self: UIPresentationController) in
let new = UITraitCollection(pureBlackDarkMode: self.presentingViewController.traitCollection.pureBlackDarkMode) let new = UITraitCollection(pureBlackDarkMode: self.presentingViewController.traitCollection.pureBlackDarkMode)