This repository has been archived by the owner on Apr 21, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 11
/
test.html
106 lines (92 loc) · 2.83 KB
/
test.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
101
102
103
104
105
106
<!DOCTYPE html>
<html>
<head>
<script type="text/javascript" src="contextmenu.js"></script>
<link rel='stylesheet' href="contextmenu.css" type="text/css" media="all" />
</head>
<body style="background: white">
<menu type="context" id="mymenu">
<menuitem label="New Folder" onclick=""></menuitem>
<hr />
<menuitem label="Get Info"></menuitem>
<hr />
<menuitem label="Change Desktop Background…"></menuitem>
<menuitem label="Clean Up" onclick="alert('source');"></menuitem>
<menu label="Clean Up By">
<menuitem label="Name"></menuitem>
<menuitem label="Kind"></menuitem>
<menuitem label="Date Modified"></menuitem>
</menu>
<menu label="Sort By">
<menuitem label="Name"></menuitem>
<menuitem label="Kind"></menuitem>
<menuitem label="Date Modified"></menuitem>
</menu>
<menuitem label="Show View Options"></menuitem>
</menu>
<menu label="Share Sheet" id="sharesheet">
<menuitem label="Twitter" icon="/images/twitter_icon.gif" onclick="goTo('//twitter.com/intent/tweet?text=' + document.title + ': ' + window.location.href);"></menuitem>
<menuitem label="Facebook" icon="/images/facebook_icon16x16.gif" onclick="goTo('//facebook.com/sharer/sharer.php?u=' + window.location.href);"></menuitem>
</menu>
<menu type="context" id="win">
<menu label="View">
<menuitem label="Large icons"></menuitem>
<menuitem label="Medium icons"></menuitem>
<menuitem label="Small icons"></menuitem>
<hr />
<menuitem label="Auto arrange icons"></menuitem>
<menuitem label="Align icons to grid"></menuitem>
<hr />
<menuitem label="Show desktop icons"></menuitem>
<menuitem label="Show desktop gadgets"></menuitem>
</menu>
<menu label="Sort by">
</menu>
<menuitem label="Refresh"></menuitem>
<hr />
<menuitem label="Paste"></menuitem>
<menuitem label="Paste shortcut"></menuitem>
<hr />
<menu label="New">
</menu>
<hr />
<menuitem label="Screen gesolution"></menuitem>
<menuitem label="Gadgets"></menuitem>
</menu>
<div style="padding:64px">
<select>
<option>First Item</option>
<option>Second Item</option>
</select>
<section contextmenu="mymenu">
Sample text.
</section>
<section contextmenu="win">
Windows test.
</section>
<input type="button" value="Alert" onclick="alert('hi')" />
<input type="button" contextmenu="sharesheet" value="Share..." />
</div>
<code>
var menu = contextmenu(
[
{
label: "First Item",
onclick: function() {
}
},
{
label: "Second Item",
children: [
{
label: "Sub Item"
}
]
}
]
);
</code>
<br />
<img src="../img.png" contextmenu="mymenu">
</body>
</html>