VoucherRevealViewController

@interface VoucherRevealViewController : UIViewController

VoucherRevealViewController is the default reveal view controller for showing the contents of a Voucher. The reaveal view controller can be used for previewing, contributing and claiming a Voucher.

  • The delegate for the VoucherRevealViewController.

    Declaration

    Objective-C

    @property (readwrite, nonatomic) id<VoucherRevealViewControllerDelegate>
        delegate;

    Swift

    weak var delegate: VoucherRevealViewControllerDelegate! { get set }
  • Default initializer for the VoucherRevealViewController.

    Declaration

    Objective-C

    + (instancetype)
    viewControllerWithRevealManager:(VoucherRevealManager *)revealManager
                         revealMode:(RevealMode)revealMode
                    backgroundColor:(UIColor *)backgroundColor
                       gameDelegate:(id<VoucherGameDelegate>)gameDelegate;

    Parameters

    revealManager

    - the VoucherRevealManager that provides information and other managers to the VoucherRevealViewController.

    revealMode

    - the mode the VoucherRevealViewController should be in.

    backgroundColor

    - the background color of the VoucherRevealViewController.

    gameDelegate

    - game delegate for showing a custom game instead of a default.

    Return Value

    instance of VoucherRevealViewController.

  • If called before viewWillAppear, the envelope animation will be skipped and the contents of the Voucher will be displayed immediately.

    Declaration

    Objective-C

    - (void)skipEnvelopeOpeningAnimation;

    Swift

    func skipEnvelopeOpeningAnimation()