tabs fix !??!?!??? what ? 😳
This commit is contained in:
parent
bcddf7fbcc
commit
8fa4c05999
|
@ -141,13 +141,19 @@ function getSanitizedProtocolPath(url_) {
|
||||||
|
|
||||||
|
|
||||||
const WEBAPP_PATH = settings.get('WEBAPP_PATH', `/app?_=${Date.now()}`);
|
const WEBAPP_PATH = settings.get('WEBAPP_PATH', `/app?_=${Date.now()}`);
|
||||||
const URL_TO_LOAD = `${WEBAPP_ENDPOINT}${WEBAPP_PATH}`;
|
let URL_TO_LOAD = `${WEBAPP_ENDPOINT}${WEBAPP_PATH}`;
|
||||||
|
if(WEBAPP_ENDPOINT.startsWith("file://")){
|
||||||
|
URL_TO_LOAD = `${WEBAPP_ENDPOINT}?path=${encodeURIComponent(WEBAPP_PATH)}`;
|
||||||
|
}
|
||||||
const MIN_WIDTH = settings.get('MIN_WIDTH', 940);
|
const MIN_WIDTH = settings.get('MIN_WIDTH', 940);
|
||||||
const MIN_HEIGHT = settings.get('MIN_HEIGHT', 500);
|
const MIN_HEIGHT = settings.get('MIN_HEIGHT', 500);
|
||||||
const DEFAULT_WIDTH = 1280;
|
const DEFAULT_WIDTH = 1280;
|
||||||
const DEFAULT_HEIGHT = 720; // TODO: document this var's purpose
|
const DEFAULT_HEIGHT = 720; // TODO: document this var's purpose
|
||||||
|
|
||||||
const MIN_VISIBLE_ON_SCREEN = 32;
|
const MIN_VISIBLE_ON_SCREEN = 32;
|
||||||
|
/**
|
||||||
|
* @type {Electron.BrowserWindow}
|
||||||
|
*/
|
||||||
let mainWindow = null;
|
let mainWindow = null;
|
||||||
let mainWindowId = _Constants.DEFAULT_MAIN_WINDOW_ID;
|
let mainWindowId = _Constants.DEFAULT_MAIN_WINDOW_ID;
|
||||||
let mainWindowInitialPath = null;
|
let mainWindowInitialPath = null;
|
||||||
|
@ -418,6 +424,9 @@ function launchMainAppWindow(isVisible) {
|
||||||
mainWindow.destroy();
|
mainWindow.destroy();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @type {Electron.BrowserWindowConstructorOptions}
|
||||||
|
*/
|
||||||
const mainWindowOptions = {
|
const mainWindowOptions = {
|
||||||
title: 'Lightcord',
|
title: 'Lightcord',
|
||||||
width: DEFAULT_WIDTH,
|
width: DEFAULT_WIDTH,
|
||||||
|
@ -462,6 +471,7 @@ function launchMainAppWindow(isVisible) {
|
||||||
mainWindow = new BrowserWindow(mainWindowOptions);
|
mainWindow = new BrowserWindow(mainWindowOptions);
|
||||||
mainWindowId = mainWindow.id;
|
mainWindowId = mainWindow.id;
|
||||||
global.mainWindowId = mainWindowId;
|
global.mainWindowId = mainWindowId;
|
||||||
|
mainWindow.webContents.openDevTools()
|
||||||
|
|
||||||
if(useGlasstron)setDefaultBlur()
|
if(useGlasstron)setDefaultBlur()
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "lightcord",
|
"name": "lightcord",
|
||||||
"version": "0.1.4",
|
"version": "0.1.5",
|
||||||
"description": "A simple - customizable - Discord Client.",
|
"description": "A simple - customizable - Discord Client.",
|
||||||
"main": "dist/index.js",
|
"main": "dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|
Loading…
Reference in New Issue