[web-remote] better spot for qr code

This commit is contained in:
child_duckling 2022-01-21 23:27:48 -08:00
parent 96b3a78876
commit d4e27be261

View file

@ -424,21 +424,16 @@ export class Win {
} }
//QR Code //QR Code
electron.ipcMain.handle('setRemoteQR', async (event , _) => { electron.ipcMain.handle('showQR', async (event , _) => {
let url = await qrcode2.toDataURL(`http://${getIp()}:${this.remotePort}`) let url = `http://${getIp()}:${this.remotePort}`;
return url; electron.shell.openExternal(`https://cider.sh/pair-remote?url=${btoa(encodeURI(url))}`);
/*
* Doing this because we can give them the link and let them send it via Pocket or another in-browser tool -q
/
}) })
//Remote URL
electron.ipcMain.handle('setRemoteURL', async (event , _) => {
let url = `http://${getIp()}:${this.remotePort}`
return await url;
})
/* ********************************************************************************************* /* *********************************************************************************************
* Window Events * Window Events
* **********************************************************************************************/ * **********************************************************************************************/
if (process.platform === "win32") { if (process.platform === "win32") {
let WND_STATE = { let WND_STATE = {
MINIMIZED: 0, MINIMIZED: 0,