Skip to content
This repository was archived by the owner on Aug 14, 2021. It is now read-only.

Commit 1fb1d0c

Browse files
committed
build 1.2.3
1 parent 3638096 commit 1fb1d0c

File tree

6 files changed

+45
-37
lines changed

6 files changed

+45
-37
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
# 1.2.3 / 2013-10-19
2+
3+
* [CHANGE] Detection of separators compliant with UI Menu 1.10
4+
* [BUGFIX] Fixed setEntry for entries that don't have icons and handlemissing `cmd` option.
5+
16
# 1.2.2 / 2013-07-28
27

38
* [CHANGE] Added ThemeRoller switcher to demo page.

jquery.ui-contextmenu.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -256,6 +256,7 @@
256256
var e = jQuery.Event("contextmenu", {target: target.get(0)});
257257
return this.element.trigger(e);
258258
},
259+
/** Replace the menu altogether. */
259260
replaceMenu: function(data){
260261
this._createUiMenu(data);
261262
},

jquery.ui-contextmenu.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "ui-contextmenu",
3-
"version": "1.2.2",
3+
"version": "1.2.3",
44

55
"title": "jQuery UI context menu plugin",
66
"description": "Turn a jQuery UI Menu widget into a contextmenu.",

test/issue-33.html

Lines changed: 35 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@
55

66
<style type="text/css">
77
.hasmenu {
8-
border: 1px solid #008;
9-
margin: 3px;
10-
padding: 5px;
11-
width: 30px;
8+
border: 1px solid #008;
9+
margin: 3px;
10+
padding: 5px;
11+
width: 30px;
1212
}
1313
.ui-widget{
14-
font-size: .8em;
14+
font-size: .8em;
1515
}
1616
table, td {
1717
border: 1px solid dimgray;
@@ -21,42 +21,44 @@
2121
<script type="text/javascript">
2222
$(document).ready(function () {
2323

24-
function action (event, ui) {
25-
console.log(ui.target);
26-
};
24+
function action (event, ui) {
25+
console.log(ui.target);
26+
};
2727

28-
$("#details").contextmenu({
29-
delegate: ".hasmenu",
30-
menu: [
31-
{title: "Option 1 title", cmd: 'opt1', action: action},
32-
{title: "-" },
33-
{title: "Option 2 title", cmd: 'opt2', action: action}
34-
],
35-
beforeOpen: function(event, ui) {
36-
var titleText = 'record ' + ui.target.parent().attr('record');
37-
$("#details").contextmenu("setEntry", "opt1", {title: titleText});
38-
$("#details").contextmenu("setEntry", "opt2", titleText);
39-
}
40-
});
28+
$("#details").contextmenu({
29+
delegate: ".hasmenu",
30+
menu: [
31+
{title: "Option 1 title", cmd: 'opt1', action: action},
32+
{title: "-" },
33+
{title: "Option 2 title", cmd: 'opt2', action: action}
34+
],
35+
beforeOpen: function(event, ui) {
36+
var titleText = 'record ' + ui.target.parent().attr('record');
37+
$("#details").contextmenu("setEntry", "opt1", {title: titleText});
38+
$("#details").contextmenu("setEntry", "opt2", {uiIcon: "ui-icon-closethick"});
39+
$("#details").contextmenu("getMenu");
40+
// $("#details").contextmenu("setEntry", "opt2", titleText);
41+
}
42+
});
4143

4244
});
4345
</script>
4446

4547
<table id="details" class="table">
4648
<thead>
47-
<tr>
48-
<th>Id</th>
49-
<th>File Name</th>
50-
<tr />
49+
<tr>
50+
<th>Id</th>
51+
<th>File Name</th>
52+
<tr />
5153
</thead>
5254
<tbody>
53-
<tr record="1" class="hasmenu">
54-
<td>1</td>
55-
<td>Record 1</td>
56-
</tr>
57-
<tr record="2" class="hasmenu">
58-
<td>2</td>
59-
<td>Record 2</td>
60-
</tr>
55+
<tr record="1" class="hasmenu">
56+
<td>1</td>
57+
<td>Record 1</td>
58+
</tr>
59+
<tr record="2" class="hasmenu">
60+
<td>2</td>
61+
<td>Record 2</td>
62+
</tr>
6163
</tbody>
6264
</table>

ui-contextmenu.jquery.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "ui-contextmenu",
3-
"version": "1.2.2",
3+
"version": "1.2.3",
44

55
"title": "jQuery UI context menu plugin",
66
"description": "Turn a jQuery UI Menu widget into a contextmenu.",

0 commit comments

Comments
 (0)