Skip to content
This repository has been archived by the owner on Jan 9, 2019. It is now read-only.

Commit

Permalink
update example
Browse files Browse the repository at this point in the history
  • Loading branch information
alexstep committed Dec 13, 2017
1 parent 8ae23c2 commit 333c9ef
Show file tree
Hide file tree
Showing 4 changed files with 57 additions and 1 deletion.
2 changes: 1 addition & 1 deletion DApps/dicedapp_v2/lib/DC.js

Large diffs are not rendered by default.

Binary file modified DApps/example.zip
Binary file not shown.
28 changes: 28 additions & 0 deletions public/index.electron.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ const {
app,
BrowserWindow,
Menu,
MenuItem,
Tray,
shell
} = require('electron')
Expand Down Expand Up @@ -48,6 +49,8 @@ if (shouldQuit) {

function createWindow () {
mainWindow = new BrowserWindow({
title: 'Bankroller',

// resizable: false,
width: 670, height: 530,

Expand Down Expand Up @@ -83,6 +86,31 @@ function createWindow () {



const DEV_item = {
label: 'DEV',
submenu: [{
label: 'Open DevTools',
accelerator: process.platform === 'darwin' ? 'Alt+Command+I' : 'Ctrl+Shift+I',
click:() => {
mainWindow.webContents.openDevTools()
}
},{
label: 'Docs',
click:() => {
shell.openExternal('https://github.com/DaoCasino/DCLib')
}
}]
}

const mainmenu = Menu.getApplicationMenu()
if (mainmenu) {
mainmenu.append(new MenuItem(DEV_item))
Menu.setApplicationMenu( mainmenu )
} else {
Menu.setApplicationMenu( Menu.buildFromTemplate([DEV_item]) )
}


// minimize to tray
const trayIcon = new Tray(path.join(__dirname, 'static/icons/icon-38.png'))
trayIcon.setToolTip('Dao.Casino')
Expand Down
28 changes: 28 additions & 0 deletions src/index.electron.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ const {
app,
BrowserWindow,
Menu,
MenuItem,
Tray,
shell
} = require('electron')
Expand Down Expand Up @@ -48,6 +49,8 @@ if (shouldQuit) {

function createWindow () {
mainWindow = new BrowserWindow({
title: 'Bankroller',

// resizable: false,
width: 670, height: 530,

Expand Down Expand Up @@ -83,6 +86,31 @@ function createWindow () {



const DEV_item = {
label: 'DEV',
submenu: [{
label: 'Open DevTools',
accelerator: process.platform === 'darwin' ? 'Alt+Command+I' : 'Ctrl+Shift+I',
click:() => {
mainWindow.webContents.openDevTools()
}
},{
label: 'Docs',
click:() => {
shell.openExternal('https://github.com/DaoCasino/DCLib')
}
}]
}

const mainmenu = Menu.getApplicationMenu()
if (mainmenu) {
mainmenu.append(new MenuItem(DEV_item))
Menu.setApplicationMenu( mainmenu )
} else {
Menu.setApplicationMenu( Menu.buildFromTemplate([DEV_item]) )
}


// minimize to tray
const trayIcon = new Tray(path.join(__dirname, 'static/icons/icon-38.png'))
trayIcon.setToolTip('Dao.Casino')
Expand Down

0 comments on commit 333c9ef

Please sign in to comment.