コード例 #1
0
 /// <summary>
 /// Send a query to the Storefront API.
 /// </summary>
 /// <param name="query">Query that will be sent to the Storefront API</param>
 /// <param name="callback">callback that receives a response</param>
 override public void Load(string query, LoaderResponseHandler callback)
 {
     GlobalGameObject.AddComponent <LoaderComponent>()
     .SetURL("https://" + Domain + "/api/graphql.json")
     .SetHeaders(_Headers)
     .Load(query, callback);
 }
コード例 #2
0
        public static void Start(float duration, Action callback)
        {
            if (component == null)
            {
                component = GlobalGameObject.AddComponent <TimeoutComponent>();
            }

            component.StartTimeout(duration, callback);
        }
コード例 #3
0
        protected void SetupWebCheckoutMessageReceiver(CheckoutSuccessCallback success, CheckoutCancelCallback cancelled, CheckoutFailureCallback failure)
        {
            if (_messageReceiver == null)
            {
                _messageReceiver = GlobalGameObject.AddComponent <WebCheckoutMessageReceiver>();
            }

            _messageReceiver.Init(Client, Cart.CurrentCheckout, success, cancelled, failure);
        }