Support Help plugin

... and some other plugins that add an entry to the taskmenu
pull/5742/merge
Aleksander Machniak 7 years ago
parent f359144423
commit 32759e2fcf

@ -156,6 +156,16 @@ ul.listing {
content: @fa-var-key;
}
a.help:before {
content: @fa-var-life-bouy;
}
a.about:before {
content: @fa-var-question-circle-o;
}
a.license:before {
content: @fa-var-shield;
}
/* autocomplete popup */
& > i:before {
&:extend(.font-icon-class);

@ -33,8 +33,8 @@
&:before {
&:extend(.font-icon-class);
font-size: 1.5em;
margin-bottom: 0.1em;
font-size: 1.5rem;
margin-bottom: 0.25rem;
}
&.mail:before {
@ -64,6 +64,18 @@
&.compose:before {
content: @fa-var-edit;
}
&.calendar:before {
content: @fa-var-calendar;
}
&.tasklist:before {
content: @fa-var-tasks;
}
&.files:before {
content: @fa-var-folder;
}
&.notes:before {
content: @fa-var-sticky-note;
}
}
.special-buttons {

@ -174,6 +174,32 @@ function rcube_elastic_ui()
$('#dragmessage-menu,#dragcontact-menu').each(function() {
rcmail.gui_object('dragmenu', this.id);
});
// Taskmenu items added by plugins do not have elastic classes (e.g help plugin)
// it's for larry skin compat. We'll assign 'button' and icon-specific class.
$('#taskmenu > a').each(function() {
if (/button-([a-z]+)/.test(this.className)) {
var button = this, id = button.id, name = RegExp.$1;
$.each(rcmail.buttons, function(i, v) {
$.each(v, function(j, data) {
if (data.id == id) {
if (data.sel) {
data.sel += ' button ' + name;
}
if (data.act) {
data.act += ' button ' + name;
}
rcmail.buttons[i][j] = data;
rcmail.init_button(i, data);
$(button).addClass('button ' + name);
$('.button-inner', button).addClass('inner');
}
});
});
}
});
};
/**

Loading…
Cancel
Save