Skip to content
This repository has been archived by the owner on Feb 19, 2020. It is now read-only.

Fix/fix disabling feedback #390

Merged
merged 5 commits into from
Jan 12, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 8 additions & 15 deletions Classes/BITFeedbackManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,11 @@ typedef NS_ENUM(NSInteger, BITFeedbackObservationMode) {
/**
* Triggers when the user taps with three fingers on the screen. Captures a screenshot and attaches it to the composer.
*/
BITFeedbackObservationModeThreeFingerTap = 2
BITFeedbackObservationModeThreeFingerTap = 2,
/**
* Allows both BITFeedbackObservationModeOnScreenshot and BITFeedbackObservationModeThreeFingerTap at the same time.
*/
BITFeedbackObservationModeAll = 3
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is not a problem in this specific case but generally I would advise for this to be some other, very high number, 99 or so for example. But since it's unlikely we'll add any more options here, this should be fine 🙂

};


Expand Down Expand Up @@ -219,25 +223,14 @@ typedef NS_ENUM(NSInteger, BITFeedbackObservationMode) {
This will grab the latest image from the camera roll. Requires iOS 7 or later! It also requires to add a NSPhotoLibraryUsageDescription to your app's Info.plist.
- `BITFeedbackObservationModeThreeFingerTap`: Triggers when the user taps on the screen with three fingers. Takes a screenshot and attaches it to the composer. It also requires to add a NSPhotoLibraryUsageDescription to your app's Info.plist.

Default is `BITFeedbackObservationNone`
Default is `BITFeedbackObservationNone`.
If BITFeedbackManger was disabled, setting a new value will be ignored.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A test for this case might be nice 😊

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is done ;)

@see `[BITHockeyManager disableFeedbackManager]`

@see showFeedbackComposeViewWithGeneratedScreenshot
*/
@property (nonatomic, readwrite) BITFeedbackObservationMode feedbackObservationMode;

/**
Prefill feedback compose message user interface with the items given.

All NSString-Content in the array will be concatenated and result in the message,
while all UIImage and NSData-instances will be turned into attachments.

@deprecated This property is deprecated in favor of `BITFeedbackManagerDelegate preparedItemsForFeedbackManager:`.

@see `[BITFeedbackComposeViewController prepareWithItems:]`
*/
@property (nonatomic, copy, nullable) NSArray *feedbackComposerPreparedItems DEPRECATED_MSG_ATTRIBUTE("Use -preparedItemsForFeedbackManager: delegate method instead.");


/**
Don't show the option to add images from the photo library

Expand Down
Loading