public void ShowConfiguration(IWatchItem item) { try { if (!_Pebble.EventListeners.ContainsKey("showConfiguration")) { return; } var jsfunction = _Pebble.EventListeners["showConfiguration"]; System.Func <Jint.Native.JsValue, Jint.Native.JsValue[], Jint.Native.JsValue> _func = jsfunction as System.Func <Jint.Native.JsValue, Jint.Native.JsValue[], Jint.Native.JsValue>; Jint.Native.JsValue A = new JsValue(1); Jint.Native.JsValue[] B = new Jint.Native.JsValue[1]; Jint.Native.Json.JsonParser _jsp = new Jint.Native.Json.JsonParser(_JintEngine); B[0] = _jsp.Parse("{}"); Jint.Native.JsValue C = _func.Invoke(A, B); } catch (Jint.Runtime.JavaScriptException exp) { String Exception = String.Format("{0}" + Environment.NewLine + "Line: {1}" + Environment.NewLine + "Source: {2}", exp.Message, exp.LineNumber, _JavascriptLines[exp.LineNumber - 1]); throw new System.Exception(Exception); } catch (Exception exp) { throw exp; } }
private void PebbleJS_OpenURL(object sender, EventArgs e) { PebbleKitJS.URLEventArgs _uea = (PebbleKitJS.URLEventArgs)e; _WatchAppConfig = _uea.WatchItem; ConfigWebView.Navigate(new Uri(_uea.URL)); ConfigWebView.Visibility = Visibility.Visible; }
public Pebble(IWatchItem _ParentItem) { ParentItem = _ParentItem; }
public PebbleKitJS(IWatchItem ParentItem) { _ParentItem = ParentItem; _Pebble = new Pebble(_ParentItem); }
public LocalStorage(IWatchItem ParentItem) { StorageContainer = new Dictionary <Guid, Dictionary <string, string> >(); _ParentItem = ParentItem; }