forked from HackPlan/quark-shell-mac
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
100 lines (98 loc) · 2.44 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
<!DOCTYPE html>
<html>
<head>
<title>Menubar WebKit</title>
<style>
html {
height: 100%;
width: 100%;
overflow: hidden;
background-color: white;
}
body {
height: 100%;
width: 100%;
margin: 0;
overflow: auto;
font-family: "Helvetica Neue";
}
h1 {
background-color: rgb(237, 237, 237);
text-align: center;
font-weight: normal;
color: #333;
margin: 0;
padding: 12px 0 10px 0;
font-size: 16px;
border-bottom: 1px solid #ccc;
}
#app-version,
#app-bundle-version {
color: #777;
font-size: 13px;
}
.button {
text-align: center;
margin-top: 16px;
}
.button p {
margin: 11px 0;
}
button {
width: 90px;
margin: 3px;
padding: 5px 0;
font-family: "Helvetica Neue";
background-color: #eee;
border-radius: 2px;
border: 1px solid #ccc;
}
button:hover {
background-color: #f2f2f2;
}
button:active {
background-color: #e8e8e8;
}
canvas {
display: none;
}
</style>
</head>
<body>
<h1>
Menubar WebKit
<span id="app-version"></span>
<span id="app-bundle-version"></span>
</h1>
<audio src="audio.aac"></audio>
<div class="button">
<p>
<button onclick="mw.notify({title: 'Menubar WebKit', content: 'Hello World', popupOnClick: true})">Notify</button>
<button onclick="mw.closePopup()">Close Popup</button>
<button onclick="mw.newWindow({url: 'about.html', width: 600, height: 400, x: 'center', y: 'center'})">New Window</button>
</p>
<p>
<button onclick="mw.openPreferences()">Preferences</button>
<button onclick="mw.openURL('https://github.com/xhacker')">Open URL</button>
<button onclick="mw.checkUpdate('https://rawgit.com/HackPlan/menubar-webkit/master/updater/SampleAppcast.xml')">Check Update</button>
</p>
<p>
<button onclick="setIcon()">Set Icon</button>
<button id="show-menu">Show Menu</button>
<button id="toggle-pin">Pin</button>
</p>
<p>
<button onclick="$('audio')[0].play()">Audio</button>
<button onclick="alert('menubar-webkit')">Alert</button>
<button onclick="confirm('menubar-webkit?')">Confirm</button>
</p>
<p>
<button onclick="mw.quit()">Quit</button>
</p>
</div>
<canvas id="icon"></canvas>
<canvas id="highlighted-icon"></canvas>
<script type="text/javascript" src="jquery-2.1.0.min.js"></script>
<script type="text/javascript" src="index.js"></script>
</body>
</html>