mirror of
https://github.com/leonboe1/QuickDrop.git
synced 2026-11-22 06:15:59 +00:00
Refactoring
This commit is contained in:
1 parent
80b81ae228
commit
9a488a2ae2
2 files changed
+8
-8
No files matched your search
@@ -46,8 +46,8 @@ public class NearbyConnectionManager: NSObject, NetServiceDelegate, InboundNearb
|
|||||||
private static let customDeviceNameKey = "com.leonboettger.quickdrop.deviceName"
|
private static let customDeviceNameKey = "com.leonboettger.quickdrop.deviceName"
|
||||||
private var defaultPort: NWEndpoint.Port = 50362
|
private var defaultPort: NWEndpoint.Port = 50362
|
||||||
private let txtKeyEndpointInfo = "n"
|
private let txtKeyEndpointInfo = "n"
|
||||||
private let txtKeyNotificationSyncCapabilities = "qd_caps"
|
private let txtQuickDropCapabilities = "qd_caps"
|
||||||
private let txtKeyNotificationSyncKeyFingerprint = "qd_kid"
|
private let txtQuickDropDeviceKeyFingerprint = "qd_kid"
|
||||||
private let notificationSyncCapabilityToken = "nsync1"
|
private let notificationSyncCapabilityToken = "nsync1"
|
||||||
private let unnamedAndroidFallbackDeviceName = "AndroidDevice".localized()
|
private let unnamedAndroidFallbackDeviceName = "AndroidDevice".localized()
|
||||||
|
|
||||||
@@ -316,9 +316,9 @@ public class NearbyConnectionManager: NSObject, NetServiceDelegate, InboundNearb
|
|||||||
txtKeyEndpointInfo: deviceInfo.serialize().urlSafeBase64EncodedString().data(using: .utf8)!,
|
txtKeyEndpointInfo: deviceInfo.serialize().urlSafeBase64EncodedString().data(using: .utf8)!,
|
||||||
]
|
]
|
||||||
#if os(macOS)
|
#if os(macOS)
|
||||||
txtRecord[txtKeyNotificationSyncCapabilities] = Data(notificationSyncCapabilityToken.utf8)
|
txtRecord[txtQuickDropCapabilities] = Data(notificationSyncCapabilityToken.utf8)
|
||||||
if let keyFingerprint = notificationSyncKeyFingerprintHex() {
|
if let keyFingerprint = notificationSyncKeyFingerprintHex() {
|
||||||
txtRecord[txtKeyNotificationSyncKeyFingerprint] = Data(keyFingerprint.utf8)
|
txtRecord[txtQuickDropDeviceKeyFingerprint] = Data(keyFingerprint.utf8)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
service.setTXTRecord(NetService.data(fromTXTRecord: txtRecord))
|
service.setTXTRecord(NetService.data(fromTXTRecord: txtRecord))
|
||||||
|
|||||||
@@ -1773,8 +1773,8 @@
|
|||||||
MTL_FAST_MATH = YES;
|
MTL_FAST_MATH = YES;
|
||||||
ONLY_ACTIVE_ARCH = YES;
|
ONLY_ACTIVE_ARCH = YES;
|
||||||
SDKROOT = macosx;
|
SDKROOT = macosx;
|
||||||
SHARED_BUILD = 138;
|
SHARED_BUILD = 139;
|
||||||
SHARED_VERSION = 3.0;
|
SHARED_VERSION = 3.0.1;
|
||||||
STRING_CATALOG_GENERATE_SYMBOLS = YES;
|
STRING_CATALOG_GENERATE_SYMBOLS = YES;
|
||||||
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
|
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
|
||||||
SWIFT_EMIT_LOC_STRINGS = YES;
|
SWIFT_EMIT_LOC_STRINGS = YES;
|
||||||
@@ -1836,8 +1836,8 @@
|
|||||||
MTL_ENABLE_DEBUG_INFO = NO;
|
MTL_ENABLE_DEBUG_INFO = NO;
|
||||||
MTL_FAST_MATH = YES;
|
MTL_FAST_MATH = YES;
|
||||||
SDKROOT = macosx;
|
SDKROOT = macosx;
|
||||||
SHARED_BUILD = 138;
|
SHARED_BUILD = 139;
|
||||||
SHARED_VERSION = 3.0;
|
SHARED_VERSION = 3.0.1;
|
||||||
STRING_CATALOG_GENERATE_SYMBOLS = YES;
|
STRING_CATALOG_GENERATE_SYMBOLS = YES;
|
||||||
SWIFT_COMPILATION_MODE = wholemodule;
|
SWIFT_COMPILATION_MODE = wholemodule;
|
||||||
SWIFT_EMIT_LOC_STRINGS = YES;
|
SWIFT_EMIT_LOC_STRINGS = YES;
|
||||||
|
|||||||
Reference in new issue
Block a user