Skip to content

Commit 5e838f8

Browse files
Merge pull request #40 from vineetchoudhary/development
Release 0.9.9
2 parents 4c74920 + e5428e6 commit 5e838f8

271 files changed

Lines changed: 25505 additions & 907 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

AFNetworking.framework/AFNetworking

Lines changed: 0 additions & 1 deletion
This file was deleted.
-344 KB
Binary file not shown.

AFNetworking.framework/Versions/A/Headers/AFNetworking.h

Lines changed: 0 additions & 66 deletions
This file was deleted.

AFNetworking.framework/Versions/A/Modules/module.modulemap

Lines changed: 0 additions & 5 deletions
This file was deleted.

AFNetworking.framework/Versions/A/Resources/Info.plist

Lines changed: 0 additions & 49 deletions
This file was deleted.

AppBox.xcodeproj/project.pbxproj

Lines changed: 218 additions & 40 deletions
Large diffs are not rendered by default.

AppBox.xcworkspace/contents.xcworkspacedata

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

AppBox/AppBoxPrefixHeader.pch

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,20 +10,30 @@
1010
#define AppBoxPrefixHeader_pch
1111

1212

13+
#import <ZipArchive.h>
1314
#import <DropboxOSX/DropboxOSX.h>
14-
#import <ZipArchive/ZipArchive.h>
1515
#import <AFNetworking/AFNetworking.h>
16+
#import <Fabric/Fabric.h>
17+
#import <Crashlytics/Crashlytics.h>
18+
1619

1720
#import "Tiny.h"
1821
#import "GooglURLShortenerService.h"
1922

20-
#import "Common.h"
2123
#import "UserData.h"
22-
#import "Constants.h"
2324
#import "XCProject.h"
2425
#import "AppDelegate.h"
26+
27+
#import "Constants.h"
28+
29+
#import "Common.h"
30+
#import "MacHandler.h"
31+
#import "MailHandler.h"
32+
#import "UpdateHandler.h"
2533
#import "NetworkHandler.h"
34+
#import "KeychainHandler.h"
2635
#import "NSApplication+MenuHandler.h"
2736

2837

38+
2939
#endif /* AppBoxPrefixHeader_pch */

AppBox/AppDelegate.m

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ - (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
2121
[center setDelegate:self];
2222
self.sessionLog = [[NSMutableString alloc] init];
2323

24+
//Init Crashlytics
25+
[[NSUserDefaults standardUserDefaults] registerDefaults:@{ @"NSApplicationCrashOnExceptions": @YES }];
26+
[Fabric with:@[[Crashlytics class], [Answers class]]];
27+
2428
//Start monitoring internet connection
2529
[[AFNetworkReachabilityManager sharedManager] setReachabilityStatusChangeBlock:^(AFNetworkReachabilityStatus status) {
2630
if (status == AFNetworkReachabilityStatusNotReachable){
@@ -29,8 +33,11 @@ - (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
2933
}];
3034
[[AFNetworkReachabilityManager sharedManager] startMonitoring];
3135

36+
//Handle URL Scheme
37+
[[NSAppleEventManager sharedAppleEventManager] setEventHandler:self andSelector:@selector(handleGetURLWithEvent:andReply:) forEventClass:kInternetEventClass andEventID:kAEGetURL];
38+
3239
//Check for update
33-
[Common isNewVersionAvailableCompletion:^(bool available, NSURL *url) {
40+
[UpdateHandler isNewVersionAvailableCompletion:^(bool available, NSURL *url) {
3441
if (available){
3542
NSAlert *alert = [[NSAlert alloc] init];
3643
[alert setMessageText: @"New Version Available"];
@@ -39,7 +46,7 @@ - (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
3946
[alert addButtonWithTitle:@"YES"];
4047
[alert addButtonWithTitle:@"NO"];
4148
if ([alert runModal] == NSAlertFirstButtonReturn){
42-
[[NSWorkspace sharedWorkspace] openURL:[NSURL URLWithString:abDefaultLatestDownloadURL]];
49+
[[NSWorkspace sharedWorkspace] openURL:url];
4350
}
4451
}
4552
}];
@@ -66,6 +73,15 @@ -(void)addSessionLog:(NSString *)sessionLog{
6673
[[NSNotificationCenter defaultCenter] postNotificationName:abSessionLogUpdated object:nil];
6774
}
6875

76+
//URISchem URL Handler
77+
-(void)handleGetURLWithEvent:(NSAppleEventDescriptor *)event andReply:(NSAppleEventDescriptor *)reply{
78+
NSString *urlString = [[event paramDescriptorForKeyword:keyDirectObject] stringValue];
79+
[self addSessionLog:[NSString stringWithFormat:@"Handling URL = %@",urlString]];
80+
if (urlString != nil){
81+
NSURL *url = [NSURL URLWithString:urlString];
82+
}
83+
}
84+
6985
#pragma mark - Notification Center Delegate
7086
-(void)userNotificationCenter:(NSUserNotificationCenter *)center didActivateNotification:(NSUserNotification *)notification {
7187
[center removeDeliveredNotification:notification];

0 commit comments

Comments
 (0)