public static void ColdBootInit() { #if UNITY_EDITOR var defaultPrivkey = GetDefaultStoredKey(); if (!string.IsNullOrEmpty(defaultPrivkey)) { IpcInteraction.Stage(() => new AddKeypair(defaultPrivkey), (s, p) => { Initialized = true; }); } else { PylonsService.instance.RegisterProfile("", (s, p) => { Initialized = true; }); } #endif }
private static void RetrieveKeyInfo(KeyEvent evt) { // We purposefully don't expose ExportKeys to PylonsService, so we have to do this the ll way IpcInteraction.Stage(() => new ExportKeys(), (s, e) => { evt.Invoke(((KeyResponse)e).Name, ((KeyResponse)e).Address, ((KeyResponse)e).PrivateKey, ((KeyResponse)e).PublicKey); }); }
public void WalletUiTest(string input, WalletServiceTestEvent evt) => IpcInteraction.Stage(() => new WalletUiTest(input), (s, e) => { evt.Invoke(s, ((TestResponse)e).Output); });
// outside of debug environments, we'll need to use a helper function to make the appropriate iap call // for the number of pylons given, get arguments for one of the iap-based backend calls, and then call that // here instead. // it may make more sense to do all iap on the wallet side so we can offload this logic, in which case a // separate GoogleIapGetPylons IPC call does not need to exist. public void GetRecipes(RecipeEvent evt) => IpcInteraction.Stage(() => new GetRecipes(), (s, e) => { evt.Invoke(s, ((RecipeResponse)e).Recipes); });
public void GetProfile(string id, ProfileEvent evt) => IpcInteraction.Stage(() => new GetProfile(id), (s, e) => { evt.Invoke(s, ((ProfileResponse)e).Profiles.GetFirst()); });
public void GetPendingExecutions(ExecutionEvent evt) => IpcInteraction.Stage(() => new GetPendingExecutions(), (s, e) => { evt.Invoke(s, ((ExecutionResponse)e).Executions); });
public void GetCookbooks(CookbookEvent evt) => IpcInteraction.Stage(() => new GetCookbooks(), (s, e) => { evt.Invoke(s, ((CookbookResponse)e).Cookbooks); });
public void TxEventMessageHandler(Func <IpcMessage> msg, TxEvent evt) => IpcInteraction.Stage(msg, (s, e) => { evt.Invoke(s, ((TxResponse)e).Transactions); });