diff options
author | 2014-03-10 14:35:16 +0100 | |
---|---|---|
committer | 2014-03-10 14:35:16 +0100 | |
commit | d997af05ff2b042fcb418dc8dfc1ed73b917c7a3 (patch) | |
tree | 314b98f325bd3e6a6dbd3ead397e601926fff850 /src/objc | |
parent | 3ccaad6f0219ca7da49306eed9661575b61dc120 (diff) |
Cancel all operations
Diffstat (limited to 'src/objc')
-rwxr-xr-x | src/objc/imap/MCOIMAPSession.h | 5 | ||||
-rwxr-xr-x | src/objc/imap/MCOIMAPSession.mm | 5 |
2 files changed, 10 insertions, 0 deletions
diff --git a/src/objc/imap/MCOIMAPSession.h b/src/objc/imap/MCOIMAPSession.h index 20c0f874..0a9f147f 100755 --- a/src/objc/imap/MCOIMAPSession.h +++ b/src/objc/imap/MCOIMAPSession.h @@ -138,6 +138,11 @@ */ @property (nonatomic, copy) MCOOperationQueueRunningChangeBlock operationQueueRunningChangeBlock; +/** + Cancel all operations + */ +- (void)cancelAllOperation; + /** @name Folder Operations */ /** diff --git a/src/objc/imap/MCOIMAPSession.mm b/src/objc/imap/MCOIMAPSession.mm index 0b0c638a..d4b1dbfe 100755 --- a/src/objc/imap/MCOIMAPSession.mm +++ b/src/objc/imap/MCOIMAPSession.mm @@ -168,6 +168,11 @@ MCO_OBJC_SYNTHESIZE_SCALAR(dispatch_queue_t, dispatch_queue_t, setDispatchQueue, return _operationQueueRunningChangeBlock; } +- (void)cancelAllOperation +{ + MCO_NATIVE_INSTANCE->cancelAllOperations(); +} + #pragma mark - Operations #define MCO_TO_OBJC_OP(op) [self _objcOperationFromNativeOp:op]; |