This repository has been archived on 2019-03-08. You can view files and clone it, but cannot push or open issues or pull requests.
MillionHopes/dock.js

187 lines
5.7 KiB
JavaScript

const { app, Menu } = require('electron');
const ipc = require('electron').ipcMain;
const options = {userAgent: 'Mozilla/5.0 (Linux; Android 7.1.1; Nexus 6 Build/N6F27E) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.83 Mobile Safari/537.36'};
module.exports.navitemplate = function(win){
const template = [
{
label: "Main",
submenu: [
{
label: "My Page",
click(){ win.loadURL("http://imas.gree-apps.net/app/index.php/mypage",options)}
},
{
label: "Eigyo",click() {win.loadURL("http://imas.gree-apps.net/app/index.php/eigyo?from=mypage_main_button",options) }
},
{
label: "Lesson",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/lesson",options)}
},
{
label: "Gasha",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/gasha",options)}
},
{
label: "Event",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/event",options)}
},
{
label: "Live Battle",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/livebattle",options)}
},
{
label: "Theater",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/theater",options)}
}
]
},
{
label: "Card",
submenu: [
{
label: "Deck",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/deck",options)}
},
{
label: "Card Inventory",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/cardinventory",options)}
},
{
label: "Card Folder",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/cardfolder",options)}
},
{
label: "Potential Skill",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/potential_skill",options)}
},
{
label: "Bazaar",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/bazaar",options)}
},
{
label: "Trade",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/trade",options)}
}
]
},
{
label: "Idol",
submenu: [
{
label: "Unit",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/unit",options)}
},
{
label: "Idol List",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/idol",options)}
},
{
label: "Album",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/album",options)}
},
{
label: "Ranking",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/ranking",options)}
},
{
label: "Voice Drama",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/voice_drama/top",options)}
},
{
label: "Audio Room",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/audio_room",options)}
}
]
},
{
label: "Item",
submenu:
[
{
label: "Shop",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/shop",options)}
},
{
label: "Item",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/item",options)}
},
{
label: "Present Box",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/present",options)}
},
{
label: "Exchange",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/exchange",options)}
}
]
},
{
label: "Friend",
submenu: [
{
label: "Friend List",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/friend",options)}
},
{
label: "Lounge",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/lounge",options)}
},
{
label: "Producer Title",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/title",options)}
},
{
label: "Convention Center",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/convention_center",options)}
},
{
label: "Invite",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/invite",options)}
},
{
label: "Wishlist",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/wantlist",options)}
}
]
},
{
label: "Other",
submenu:
[
{
label: "Memories",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/memories",options)}
},
{
label: "Drama Theater",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/short_story",options)}
},
{
label: "My Data",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/mypage/mydata",options)}
},
{
label: "Million Live! Settings",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/config",options)}
},
{
label: "Help",
click() { win.loadURL("http://imas.gree-apps.net/app/index.php/help",options)}
},
{
label: "Return to Splash Page",
click() { win.loadURL("http://pf.gree.net/58737",options)}
}
]
}
]
return template;
}
module.exports.setdock = function(win) {
const dockMenu = Menu.buildFromTemplate(module.exports.navitemplate(win))
app.dock.setMenu(dockMenu);
}