2014-10-31 18:17:05 +00:00
|
|
|
// Copyright (c) 2013 GitHub, Inc.
|
2014-04-25 09:49:37 +00:00
|
|
|
// Use of this source code is governed by the MIT license that can be
|
2013-05-02 12:09:19 +00:00
|
|
|
// found in the LICENSE file.
|
|
|
|
|
|
|
|
#import "base/mac/scoped_sending_event.h"
|
2016-05-04 18:28:49 +00:00
|
|
|
#import "base/mac/scoped_nsobject.h"
|
2013-05-02 12:09:19 +00:00
|
|
|
|
|
|
|
@interface AtomApplication : NSApplication<CrAppProtocol,
|
2017-06-26 19:14:44 +00:00
|
|
|
CrAppControlProtocol,
|
|
|
|
NSUserActivityDelegate> {
|
2013-05-02 12:09:19 +00:00
|
|
|
@private
|
|
|
|
BOOL handlingSendEvent_;
|
2016-05-04 18:28:49 +00:00
|
|
|
base::scoped_nsobject<NSUserActivity> currentActivity_;
|
2017-08-09 15:09:47 +00:00
|
|
|
NSCondition *handoffLock_;
|
|
|
|
BOOL updateReceived_;
|
2013-05-02 12:09:19 +00:00
|
|
|
}
|
|
|
|
|
2013-05-30 08:03:10 +00:00
|
|
|
+ (AtomApplication*)sharedApplication;
|
|
|
|
|
2013-05-02 12:09:19 +00:00
|
|
|
// CrAppProtocol:
|
|
|
|
- (BOOL)isHandlingSendEvent;
|
|
|
|
|
|
|
|
// CrAppControlProtocol:
|
|
|
|
- (void)setHandlingSendEvent:(BOOL)handlingSendEvent;
|
|
|
|
|
2016-05-03 21:57:16 +00:00
|
|
|
- (NSUserActivity*)getCurrentActivity;
|
2016-05-23 15:49:46 +00:00
|
|
|
- (void)setCurrentActivity:(NSString*)type
|
|
|
|
withUserInfo:(NSDictionary*)userInfo
|
|
|
|
withWebpageURL:(NSURL*)webpageURL;
|
2017-06-26 19:14:44 +00:00
|
|
|
- (void)invalidateCurrentActivity;
|
|
|
|
- (void)updateCurrentActivity:(NSString *)type
|
|
|
|
withUserInfo:(NSDictionary*)userInfo;
|
2016-05-03 21:57:16 +00:00
|
|
|
|
2013-05-02 12:09:19 +00:00
|
|
|
@end
|