Skip to content

Commit

Permalink
Added delegate, Update pod
Browse files Browse the repository at this point in the history
  • Loading branch information
Tobias Tiemerding committed Oct 15, 2014
1 parent 1c33380 commit c97783d
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
6 changes: 3 additions & 3 deletions TTOpenInAppActivity.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'TTOpenInAppActivity'
s.version = '1.0.1'
s.version = '1.1'
s.license = 'MIT'
s.summary = 'TTOpenInAppActivity is a UIActivity subclass that provides an "Open In ..." action to a UIActivityViewController.'
s.description = <<-DESC
Expand All @@ -10,11 +10,11 @@ Pod::Spec.new do |s|
DESC
s.homepage = 'https://github.com/honkmaster/TTOpenInAppActivity'
s.authors = { 'Tobias Tiemerding' => 'http://www.tiemerding.com' }
s.source = { :git => 'https://github.com/honkmaster/TTOpenInAppActivity.git', :tag => '1.0' }
s.source = { :git => 'https://github.com/honkmaster/TTOpenInAppActivity.git', :tag => '1.1' }
s.source_files = 'TTOpenInAppActivity/*.{h,m}'
s.resources = 'TTOpenInAppActivity/*.png'
s.resource_bundles = { 'TTOpenInAppActivity' => ['bundles/*.lproj'] }
s.frameworks = 'UIKit', 'MobileCoreServices'
s.frameworks = 'UIKit', 'MobileCoreServices', 'Coregraphics', 'ImageIO', 'Foundation'
s.requires_arc = true
s.platform = :ios, '6.0'
end
1 change: 1 addition & 0 deletions TTOpenInAppActivity/TTOpenInAppActivity.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
@optional
- (void)openInAppActivityWillPresentDocumentInteractionController:(TTOpenInAppActivity*)activity;
- (void)openInAppActivityDidDismissDocumentInteractionController:(TTOpenInAppActivity*)activity;
- (void)openInAppActivityDidEndSendingToApplication:(TTOpenInAppActivity*)activity;
@end

@interface TTOpenInAppActivity : UIActivity <UIDocumentInteractionControllerDelegate>
Expand Down
5 changes: 5 additions & 0 deletions TTOpenInAppActivity/TTOpenInAppActivity.m
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,11 @@ - (void) documentInteractionControllerDidDismissOpenInMenu: (UIDocumentInteracti

- (void) documentInteractionController:(UIDocumentInteractionController *)controller didEndSendingToApplication:(NSString *)application
{
// Inform delegate
if([self.delegate respondsToSelector:@selector(openInAppActivityDidEndSendingToApplication:)]) {
[self.delegate openInAppActivityDidDismissDocumentInteractionController:self];
}

// Inform app that the activity has finished
[self activityDidFinish:YES];
}
Expand Down

0 comments on commit c97783d

Please sign in to comment.