示例#1
0
        public void GetTicketInfo()
        {
            InAppPurchaseDialog.CommandArguments commandArguments;
            commandArguments.Command   = InAppPurchaseCommand.GetTicketInfo;
            commandArguments.Arguments = null;
            int errorCode = InAppPurchaseDialog.OpenNative(257, this.handle, ref commandArguments);

            if (errorCode != 0)
            {
                Error.ThrowNativeException(errorCode);
            }
            this.command    = commandArguments.Command;
            this.arguments  = null;
            this.busyStatus = true;
        }
示例#2
0
        public void GetProductInfo(string[] labels)
        {
            InAppPurchaseDialog.CommandArguments commandArguments;
            commandArguments.Command   = InAppPurchaseCommand.GetProductInfo;
            commandArguments.Arguments = ((labels == null) ? this.AllIndices() : this.FindLabels(labels));
            int errorCode = InAppPurchaseDialog.OpenNative(257, this.handle, ref commandArguments);

            if (errorCode != 0)
            {
                Error.ThrowNativeException(errorCode);
            }
            this.command    = commandArguments.Command;
            this.arguments  = labels;
            this.busyStatus = true;
        }
示例#3
0
        public void Consume(string label)
        {
            string[] labels = new string[]
            {
                label
            };
            InAppPurchaseDialog.CommandArguments commandArguments;
            commandArguments.Command   = InAppPurchaseCommand.Consume;
            commandArguments.Arguments = this.FindLabels(labels);
            int errorCode = InAppPurchaseDialog.OpenNative(257, this.handle, ref commandArguments);

            if (errorCode != 0)
            {
                Error.ThrowNativeException(errorCode);
            }
            this.command    = commandArguments.Command;
            this.arguments  = labels;
            this.busyStatus = true;
        }