public bool Init(bool isResetMaster = false, ProductParamResponse res = null) { PaymentManager.MyDebug.PushMessage("PaymentManager.Init"); this.isSetupOK = false; if (isResetMaster) { if (res != null) { this.ProductMasters = res.products; } else { this.ProductMasters.Clear(); } } if (!this.isInitialized) { PaymentKit.set_EventListener((IPaymentListener)this); Client.set_Listener((IGacctListener)this); if (MonoSingleton <DebugManager> .Instance.IsWebViewEnable()) { Client.SetUserAgent(gu3.Device.System.GetUserAgent()); } else { Client.SetUserAgent("Mozilla/5.0 (Linux; U; Android 4.3; ja-jp; Nexus 7 Build/JSS15Q) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30"); } PaymentKit.InitAndroid(this.googlePublicKey); this.isInitialized = true; } DebugUtility.LogWarning("PaymentManager:isSetupOK=>" + this.isSetupOK.ToString()); return(true); }
public bool InitOnlyProductMaster(bool isResetMaster = false, ProductParamResponse res = null) { if (isResetMaster) { if (res != null) { this.ProductMasters = res.products; } else { this.ProductMasters.Clear(); } } return(true); }