Fixed some build errors
This commit is contained in:
parent
7bb7a8e994
commit
0be22b6428
2 changed files with 13 additions and 21 deletions
|
@ -1,5 +1,5 @@
|
||||||
/// <reference path="../../ConnectionHandler.ts" />
|
/// <reference path="../../ConnectionHandler.ts" />
|
||||||
/// <reference path="../../../../vendor/bbcode/xbbcode.ts" />
|
/// <reference path="../../../../vendor/xbbcode/src/parser.ts" />
|
||||||
|
|
||||||
abstract class InfoManagerBase {
|
abstract class InfoManagerBase {
|
||||||
private timers: NodeJS.Timer[] = [];
|
private timers: NodeJS.Timer[] = [];
|
||||||
|
|
|
@ -353,18 +353,16 @@ namespace unused {
|
||||||
if(event.isDefaultPrevented()) return;
|
if(event.isDefaultPrevented()) return;
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
|
|
||||||
let entries: ContextMenuEntry[] = [];
|
let entries: contextmenu.MenuEntry[] = [];
|
||||||
if(tag_permission.hasClass("value-unset")) {
|
if(tag_permission.hasClass("value-unset")) {
|
||||||
entries.push({
|
entries.push({
|
||||||
type: MenuEntryType.ENTRY,
|
type: contextmenu.MenuEntryType.ENTRY,
|
||||||
icon: "",
|
|
||||||
name: tr("Add permission"),
|
name: tr("Add permission"),
|
||||||
callback: () => tag_permission.trigger('dblclick')
|
callback: () => tag_permission.trigger('dblclick')
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
entries.push({
|
entries.push({
|
||||||
type: MenuEntryType.ENTRY,
|
type: contextmenu.MenuEntryType.ENTRY,
|
||||||
icon: "",
|
|
||||||
name: tr("Remove permission"),
|
name: tr("Remove permission"),
|
||||||
callback: () => {
|
callback: () => {
|
||||||
this.listener_change(permission, {
|
this.listener_change(permission, {
|
||||||
|
@ -394,37 +392,32 @@ namespace unused {
|
||||||
|
|
||||||
if(tag_permission.hasClass("grant-unset")) {
|
if(tag_permission.hasClass("grant-unset")) {
|
||||||
entries.push({
|
entries.push({
|
||||||
type: MenuEntryType.ENTRY,
|
type: contextmenu.MenuEntryType.ENTRY,
|
||||||
icon: "",
|
|
||||||
name: tr("Add grant permission"),
|
name: tr("Add grant permission"),
|
||||||
callback: () => tag_permission.find(".column-granted").trigger('dblclick')
|
callback: () => tag_permission.find(".column-granted").trigger('dblclick')
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
entries.push({
|
entries.push({
|
||||||
type: MenuEntryType.ENTRY,
|
type: contextmenu.MenuEntryType.ENTRY,
|
||||||
icon: "",
|
|
||||||
name: tr("Remove grant permission"),
|
name: tr("Remove grant permission"),
|
||||||
callback: () =>
|
callback: () =>
|
||||||
tag_granted.val('').trigger('focusout') /* empty values are handled within focus out */
|
tag_granted.val('').trigger('focusout') /* empty values are handled within focus out */
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
entries.push(MenuEntry.HR());
|
entries.push(contextmenu.Entry.HR());
|
||||||
entries.push({
|
entries.push({
|
||||||
type: MenuEntryType.ENTRY,
|
type: contextmenu.MenuEntryType.ENTRY,
|
||||||
icon: "",
|
|
||||||
name: tr("Expend all"),
|
name: tr("Expend all"),
|
||||||
callback: () => update_collapse_status(true, true)
|
callback: () => update_collapse_status(true, true)
|
||||||
});
|
});
|
||||||
entries.push({
|
entries.push({
|
||||||
type: MenuEntryType.ENTRY,
|
type: contextmenu.MenuEntryType.ENTRY,
|
||||||
icon: "",
|
|
||||||
name: tr("Collapse all"),
|
name: tr("Collapse all"),
|
||||||
callback: () => update_collapse_status(false, true)
|
callback: () => update_collapse_status(false, true)
|
||||||
});
|
});
|
||||||
entries.push(MenuEntry.HR());
|
entries.push(contextmenu.Entry.HR());
|
||||||
entries.push({
|
entries.push({
|
||||||
type: MenuEntryType.ENTRY,
|
type: contextmenu.MenuEntryType.ENTRY,
|
||||||
icon: "",
|
|
||||||
name: tr("Show permission description"),
|
name: tr("Show permission description"),
|
||||||
callback: () => {
|
callback: () => {
|
||||||
createInfoModal(
|
createInfoModal(
|
||||||
|
@ -434,15 +427,14 @@ namespace unused {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
entries.push({
|
entries.push({
|
||||||
type: MenuEntryType.ENTRY,
|
type: contextmenu.MenuEntryType.ENTRY,
|
||||||
icon: "",
|
|
||||||
name: tr("Copy permission name"),
|
name: tr("Copy permission name"),
|
||||||
callback: () => {
|
callback: () => {
|
||||||
copy_to_clipboard(permission.name);
|
copy_to_clipboard(permission.name);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
spawn_context_menu(event.pageX, event.pageY, ...entries);
|
contextmenu.spawn_context_menu(event.pageX, event.pageY, ...entries);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue