public static async Task <NativeImage> CreateFromBuffer(byte[] buffer) { var proxy = new NativeImage(); if (scriptProxy != null) { proxy.ScriptObjectProxy = scriptProxy; } scriptProxy = await proxy.Initialize("createFromBuffer", buffer); return(proxy); }
public static async Task <NativeImage> CreateFromDataURL(string dataURL) { var proxy = new NativeImage(); if (scriptProxy != null) { proxy.ScriptObjectProxy = scriptProxy; } scriptProxy = await proxy.Initialize("createFromDataURL", dataURL); return(proxy); }
public static async Task <NativeImage> CreateEmpty() { var proxy = new NativeImage(); if (scriptProxy != null) { proxy.ScriptObjectProxy = scriptProxy; } scriptProxy = await proxy.Initialize("createEmpty"); return(proxy); }
public static async Task <NativeImage> CreateFromPath(string path) { var proxy = new NativeImage(); if (scriptProxy != null) { proxy.ScriptObjectProxy = scriptProxy; } scriptProxy = await proxy.Initialize(new object[] { "createFromPath", path }); return(proxy); }
public static async Task <Tray> Create(NativeImage icon) { var proxy = new Tray(); if (scriptProxy != null) { proxy.ScriptObjectProxy = scriptProxy; } scriptProxy = await proxy.Initialize(icon); return(proxy); }
public async Task SetIcon(NativeImage icon) { await Invoke <object>("setIcon", icon); }
public async Task SetOverlayIcon(NativeImage overlay, string description) { await Invoke <object>("setOverlayIcon", overlay, description ?? string.Empty); }
public async Task <object> SetIcon(NativeImage icon) { return(await Invoke <object>("setIcon", icon)); }
public async Task <object> SetOverlayIcon(NativeImage overlay, string description) { return(await Invoke <object>("setOverlayIcon", overlay, description)); }
public async Task <object> WriteImage(NativeImage image, ClipboardType type = ClipboardType.None) { return(await Invoke <object>("writeImage", image, type == ClipboardType.Selection? "selection" : string.Empty)); }
public async Task SetPressedImage(NativeImage image) { await Invoke <object>("setPressedImage", image); }