Skip to content
This repository has been archived by the owner on Jul 28, 2021. It is now read-only.

Commit

Permalink
Update app
Browse files Browse the repository at this point in the history
  • Loading branch information
brunto committed Sep 19, 2017
1 parent b303c8a commit ced5c37
Show file tree
Hide file tree
Showing 17 changed files with 697 additions and 46 deletions.
1 change: 0 additions & 1 deletion .gitignore
@@ -1,3 +1,2 @@
node_modules
package.json
release-builds
673 changes: 673 additions & 0 deletions LICENSE

Large diffs are not rendered by default.

File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
21 changes: 6 additions & 15 deletions main.js
Expand Up @@ -15,10 +15,10 @@ let mainWindow
function createWindow () {
// Create the browser window.
mainWindow = new BrowserWindow({
alwaysOnTop: true,
alwaysOnTop: false,
fullscreen: false,
kiosk: false,
icon: path.join(__dirname, 'icons/png/64x64.png'),
icon: path.join(__dirname, 'icons/default/icon.png'),
webPreferences: {
nodeIntegration: false, plugins: true
}
Expand All @@ -42,19 +42,10 @@ function createWindow () {
mainWindow = null
})

// forbid any attempt to download a file
const {session} = require('electron')
session.defaultSession.on('will-download', (event, item, webContents) => {
event.preventDefault();
})

const sc_reload = globalShortcut.register('CommandOrControl+R', () => {
mainWindow.reload()
})

const sc_quit = globalShortcut.register('CommandOrControl+Alt+Shift+D', () => {
mainWindow.close()
})
mainWindow.webContents.on('new-window', function(e, url) {
e.preventDefault();
require('electron').shell.openExternal(url);
});
}

// This method will be called when Electron has finished
Expand Down
18 changes: 18 additions & 0 deletions package.json
@@ -0,0 +1,18 @@
{
"name": "PIA",
"version": "0.0.4",
"description": "PIA application",
"main": "main.js",
"scripts": {
"start": "./node_modules/.bin/electron .",
"package-mac": "electron-packager . --electron-version='1.6.11' --overwrite --prune=true --asar=true --platform=darwin --arch=x64 --icon=icons/mac/icon.icns --out=release-builds",
"package-win": "electron-packager . --electron-version='1.6.11' --overwrite --prune=true --asar=true --platform=win32 --arch=x64 --icon=icons/win/icon.ico --out=release-builds",
"package-linux": "electron-packager . --electron-version='1.6.11' --overwrite --prune=true --asar=true --platform=linux --arch=x64 --out=release-builds"
},
"repository": "https://github.com/atnos/pia-app",
"keywords": [
"Electron",
"PIA"
],
"author": "ATNOS"
}
18 changes: 0 additions & 18 deletions package_dev.json

This file was deleted.

12 changes: 0 additions & 12 deletions package_distribution.json

This file was deleted.

0 comments on commit ced5c37

Please sign in to comment.