mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-10-29 02:10:08 +00:00
tweaking and cleanup...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
82886db092
commit
1ff105bcfc
@ -43,14 +43,14 @@ function createWindow() {
|
||||
|
||||
// and load the index.html of the app.
|
||||
win.loadURL(url.format({
|
||||
// XXX for some reason the system is loaded twice...
|
||||
// XXX unify this with index.html
|
||||
pathname: path.join(__dirname, 'electron.html'),
|
||||
protocol: 'file:',
|
||||
slashes: true
|
||||
}))
|
||||
|
||||
// Open the DevTools.
|
||||
win.webContents.openDevTools()
|
||||
//win.webContents.openDevTools()
|
||||
|
||||
// Emitted when the window is closed.
|
||||
win.on('closed', () => {
|
||||
|
||||
@ -85,7 +85,7 @@ if(window.require && window.nw){
|
||||
<script>
|
||||
|
||||
require('./cfg/requirejs')
|
||||
requirejs('./ui')
|
||||
requirejs('ui')
|
||||
|
||||
</script>
|
||||
|
||||
|
||||
@ -10,8 +10,14 @@
|
||||
|
||||
require('./cfg/requirejs')
|
||||
|
||||
var _require = require
|
||||
require = requirejs
|
||||
nodeRequire =
|
||||
global.nodeRequire =
|
||||
require
|
||||
|
||||
require =
|
||||
requirejs =
|
||||
global.requirejs =
|
||||
require('requirejs')
|
||||
|
||||
|
||||
|
||||
|
||||
@ -19,12 +19,6 @@ if((typeof(process) != 'undefined' ? process : {}).__nwjs){
|
||||
// Setup requirejs if we are in node/nw...
|
||||
//
|
||||
// NOTE: no need to do this in browser...
|
||||
//
|
||||
// XXX this will create a second requirejs instance with node
|
||||
// compatibility...
|
||||
// ...would be nice if we could avoid this...
|
||||
// XXX setting nodeRequire on existing requirejs will change how
|
||||
// everything is loaded...
|
||||
if(typeof(process) != 'undefined'){
|
||||
requirejs =
|
||||
global.requirejs =
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user