diff --git a/Classes/BWQuincyManager.h b/Classes/BWQuincyManager.h index 2a12243b43..f2d917a749 100644 --- a/Classes/BWQuincyManager.h +++ b/Classes/BWQuincyManager.h @@ -28,6 +28,7 @@ */ #import +#import "BWQuincyManagerDelegate.h" #define BWQuincyLog(fmt, ...) do { if([BWQuincyManager sharedQuincyManager].isLoggingEnabled) { NSLog((@"[QuincyLib] %s/%d " fmt), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__); }} while(0) @@ -116,43 +117,6 @@ typedef enum CrashReportStatus { CrashReportStatusAvailable = 3, } CrashReportStatus; -// This protocol is used to send the image updates -@protocol BWQuincyManagerDelegate - -@optional - -// Return the userid the crashreport should contain, empty by default --(NSString *) crashReportUserID; - -// Return the contact value (e.g. email) the crashreport should contain, empty by default --(NSString *) crashReportContact; - -// Return the description the crashreport should contain, empty by default. The string will automatically be wrapped into <[DATA[ ]]>, so make sure you don't do that in your string. --(NSString *) crashReportDescription; - -// Invoked when the internet connection is started, to let the app enable the activity indicator --(void) connectionOpened; - -// Invoked when the internet connection is closed, to let the app disable the activity indicator --(void) connectionClosed; - -// Invoked before the user is asked to send a crash report, so you can do additional actions. E.g. to make sure not to ask the user for an app rating :) --(void) willShowSubmitCrashReportAlert; - -// Invoked after the user did choose to send crashes always in the alert --(void) userDidChooseSendAlways; - -// Invoked right before sending crash reports to the server succeeded --(void) sendingCrashReportsDidStart; - -// Invoked after sending crash reports to the server failed --(void) sendingCrashReportsDidFailWithError:(NSError *)error; - -// Invoked after sending crash reports to the server succeeded --(void) sendingCrashReportsDidFinish; - -@end - @interface BWQuincyManager : NSObject { NSString *_submissionURL; diff --git a/Classes/BWQuincyManagerDelegate.h b/Classes/BWQuincyManagerDelegate.h new file mode 100644 index 0000000000..7ce424a8d1 --- /dev/null +++ b/Classes/BWQuincyManagerDelegate.h @@ -0,0 +1,46 @@ +// +// CNSCrashReportManagerDelegate.h +// HockeySDK +// +// Created by Andreas Linde on 29.03.12. +// Copyright (c) 2012 __MyCompanyName__. All rights reserved. +// + +#import + +// This protocol is used to send the image updates +@protocol BWQuincyManagerDelegate + +@optional + +// Return the userid the crashreport should contain, empty by default +-(NSString *) crashReportUserID; + +// Return the contact value (e.g. email) the crashreport should contain, empty by default +-(NSString *) crashReportContact; + +// Return the description the crashreport should contain, empty by default. The string will automatically be wrapped into <[DATA[ ]]>, so make sure you don't do that in your string. +-(NSString *) crashReportDescription; + +// Invoked when the internet connection is started, to let the app enable the activity indicator +-(void) connectionOpened; + +// Invoked when the internet connection is closed, to let the app disable the activity indicator +-(void) connectionClosed; + +// Invoked before the user is asked to send a crash report, so you can do additional actions. E.g. to make sure not to ask the user for an app rating :) +-(void) willShowSubmitCrashReportAlert; + +// Invoked after the user did choose to send crashes always in the alert +-(void) userDidChooseSendAlways; + +// Invoked right before sending crash reports to the server succeeded +-(void) sendingCrashReportsDidStart; + +// Invoked after sending crash reports to the server failed +-(void) sendingCrashReportsDidFailWithError:(NSError *)error; + +// Invoked after sending crash reports to the server succeeded +-(void) sendingCrashReportsDidFinish; + +@end \ No newline at end of file diff --git a/Support/HockeySDK.xcodeproj/project.pbxproj b/Support/HockeySDK.xcodeproj/project.pbxproj index 8769b148cf..349923f893 100644 --- a/Support/HockeySDK.xcodeproj/project.pbxproj +++ b/Support/HockeySDK.xcodeproj/project.pbxproj @@ -8,6 +8,7 @@ /* Begin PBXBuildFile section */ 1E322DAD148FCE2100077977 /* CNSFixCategoryBug.h in Headers */ = {isa = PBXBuildFile; fileRef = 1E322DAC148FCE2100077977 /* CNSFixCategoryBug.h */; }; + 1E40BCB515A3487500BD64D9 /* BWQuincyManagerDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = 1E40BCB415A3487500BD64D9 /* BWQuincyManagerDelegate.h */; }; E400561E148D79B500EB22B9 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E400561D148D79B500EB22B9 /* Foundation.framework */; }; E41EB471148D7BF50015DEDC /* BWApp.h in Headers */ = {isa = PBXBuildFile; fileRef = E41EB459148D7BF50015DEDC /* BWApp.h */; }; E41EB472148D7BF50015DEDC /* BWApp.m in Sources */ = {isa = PBXBuildFile; fileRef = E41EB45A148D7BF50015DEDC /* BWApp.m */; }; @@ -38,6 +39,7 @@ /* Begin PBXFileReference section */ 1E322DAC148FCE2100077977 /* CNSFixCategoryBug.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CNSFixCategoryBug.h; sourceTree = ""; }; + 1E40BCB415A3487500BD64D9 /* BWQuincyManagerDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BWQuincyManagerDelegate.h; sourceTree = ""; }; E400561A148D79B500EB22B9 /* libHockeySDK.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libHockeySDK.a; sourceTree = BUILT_PRODUCTS_DIR; }; E400561D148D79B500EB22B9 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; E400562B148D79B500EB22B9 /* SenTestingKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SenTestingKit.framework; path = Library/Frameworks/SenTestingKit.framework; sourceTree = DEVELOPER_DIR; }; @@ -143,6 +145,7 @@ E41EB462148D7BF50015DEDC /* BWHockeyViewController.m */, E41EB463148D7BF50015DEDC /* BWQuincyManager.h */, E41EB464148D7BF50015DEDC /* BWQuincyManager.m */, + 1E40BCB415A3487500BD64D9 /* BWQuincyManagerDelegate.h */, E41EB465148D7BF50015DEDC /* CNSHockeyManager.h */, E41EB466148D7BF50015DEDC /* CNSHockeyManager.m */, ); @@ -196,6 +199,7 @@ E41EB485148D7BF50015DEDC /* PSWebTableViewCell.h in Headers */, E41EB487148D7BF50015DEDC /* UIImage+HockeyAdditions.h in Headers */, 1E322DAD148FCE2100077977 /* CNSFixCategoryBug.h in Headers */, + 1E40BCB515A3487500BD64D9 /* BWQuincyManagerDelegate.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; };