aboutsummaryrefslogtreecommitdiffhomepage
path: root/Firebase/Database
diff options
context:
space:
mode:
authorGravatar Paul Beusterien <paulbeusterien@google.com>2018-01-03 12:12:22 -0800
committerGravatar GitHub <noreply@github.com>2018-01-03 12:12:22 -0800
commitf08b5044d64197a3227017ad44235a2bd7421691 (patch)
tree0ea97726a39d1746acf260f42ef35c18f363f4e2 /Firebase/Database
parent9179dd86bfa507ede505c788a513e3824ad01856 (diff)
Add Community Supported tvOS (#590)
Add Community Supported tvOS for Core, Auth, Database and Storage. Add tvOS unit tests Add tvOS sample app Update README.md Add tvOS to travis testing
Diffstat (limited to 'Firebase/Database')
-rw-r--r--Firebase/Database/Core/FPersistentConnection.m2
-rw-r--r--Firebase/Database/Core/FRepo.m4
-rw-r--r--Firebase/Database/Persistence/FLevelDBStorageEngine.m2
-rw-r--r--Firebase/Database/Realtime/FWebSocketConnection.m4
-rw-r--r--Firebase/Database/third_party/SocketRocket/FSRWebSocket.m4
5 files changed, 8 insertions, 8 deletions
diff --git a/Firebase/Database/Core/FPersistentConnection.m b/Firebase/Database/Core/FPersistentConnection.m
index 6f71d8b..870727c 100644
--- a/Firebase/Database/Core/FPersistentConnection.m
+++ b/Firebase/Database/Core/FPersistentConnection.m
@@ -925,7 +925,7 @@ static void reachabilityCallback(SCNetworkReachabilityRef ref, SCNetworkReachabi
- (void) sendConnectStats {
NSMutableDictionary *stats = [NSMutableDictionary dictionary];
- #if TARGET_OS_IOS
+ #if TARGET_OS_IOS || TARGET_OS_TV
if (self.config.persistenceEnabled) {
stats[@"persistence.ios.enabled"] = @1;
}
diff --git a/Firebase/Database/Core/FRepo.m b/Firebase/Database/Core/FRepo.m
index 0935b44..1c4b956 100644
--- a/Firebase/Database/Core/FRepo.m
+++ b/Firebase/Database/Core/FRepo.m
@@ -53,7 +53,7 @@
#import "FValueEventRegistration.h"
#import "FEmptyNode.h"
-#if TARGET_OS_IOS
+#if TARGET_OS_IOS || TARGET_OS_TV
#import <UIKit/UIKit.h>
#endif
@@ -546,7 +546,7 @@
return;
// Targetted compilation is ONLY for testing. UIKit is weak-linked in actual release build.
- #if TARGET_OS_IOS
+ #if TARGET_OS_IOS || TARGET_OS_TV
// The idea is to wait until any outstanding sets get written to disk. Since the sets might still be in our
// dispatch queue, we wait for the dispatch queue to catch up and for persistence to catch up.
// This may be undesirable though. The dispatch queue might just be processing a bunch of incoming data or
diff --git a/Firebase/Database/Persistence/FLevelDBStorageEngine.m b/Firebase/Database/Persistence/FLevelDBStorageEngine.m
index 490fb6c..7de9ebf 100644
--- a/Firebase/Database/Persistence/FLevelDBStorageEngine.m
+++ b/Firebase/Database/Persistence/FLevelDBStorageEngine.m
@@ -211,7 +211,7 @@ static NSString* trackedQueryKeysKey(NSUInteger trackedQueryId, NSString *key) {
}
+ (NSString *) firebaseDir {
- #if TARGET_OS_IOS
+ #if TARGET_OS_IOS || TARGET_OS_TV
NSArray *dirPaths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
NSString *documentsDir = [dirPaths objectAtIndex:0];
return [documentsDir stringByAppendingPathComponent:@"firebase"];
diff --git a/Firebase/Database/Realtime/FWebSocketConnection.m b/Firebase/Database/Realtime/FWebSocketConnection.m
index 0fd07e5..49d6bd8 100644
--- a/Firebase/Database/Realtime/FWebSocketConnection.m
+++ b/Firebase/Database/Realtime/FWebSocketConnection.m
@@ -25,7 +25,7 @@
#import "FStringUtilities.h"
#import "FIRDatabase_Private.h"
-#if TARGET_OS_IOS
+#if TARGET_OS_IOS || TARGET_OS_TV
#import <UIKit/UIKit.h>
#endif
@@ -85,7 +85,7 @@
BOOL hasUiDeviceClass = NO;
// Targetted compilation is ONLY for testing. UIKit is weak-linked in actual release build.
- #if TARGET_OS_IOS
+ #if TARGET_OS_IOS || TARGET_OS_TV
Class uiDeviceClass = NSClassFromString(@"UIDevice");
if (uiDeviceClass) {
systemVersion = [uiDeviceClass currentDevice].systemVersion;
diff --git a/Firebase/Database/third_party/SocketRocket/FSRWebSocket.m b/Firebase/Database/third_party/SocketRocket/FSRWebSocket.m
index a2c857b..c80dbb0 100644
--- a/Firebase/Database/third_party/SocketRocket/FSRWebSocket.m
+++ b/Firebase/Database/third_party/SocketRocket/FSRWebSocket.m
@@ -18,7 +18,7 @@
#import "FSRWebSocket.h"
-#if TARGET_OS_IOS
+#if TARGET_OS_IOS || TARGET_OS_TV
#define HAS_ICU
#endif
@@ -28,7 +28,7 @@
#import <unicode/utf8.h>
#endif
-#if TARGET_OS_IOS
+#if TARGET_OS_IOS || TARGET_OS_TV
#import <Endian.h>
#elif TARGET_OS_OSX
#import <CoreServices/CoreServices.h>