mirror of
https://git.proxmox.com/git/pve-manager
synced 2025-07-24 18:36:50 +00:00
gui: qemu/HardwareView: prepare Hardwareview for font-awesome icons
we want to be able to use fontawesome icons directly instead of having to use extracted png in css classes this patch makes it possible to use 'iconCls' with the font-awesome icon name Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
parent
71798b4b02
commit
6a040799f4
@ -250,6 +250,14 @@
|
||||
padding-left: 20px;
|
||||
}
|
||||
|
||||
.pve-itype-fa > .x-grid-cell-inner{
|
||||
padding-left: 3px;
|
||||
}
|
||||
|
||||
.pve-grid-fa {
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
.pve-itype-icon-qemu,
|
||||
.x-tree-node-computer,
|
||||
.x-grid-tree-node-expanded .x-tree-node-computer
|
||||
|
@ -8,6 +8,9 @@ Ext.define('PVE.qemu.HardwareView', {
|
||||
var me = this;
|
||||
var rows = me.rows;
|
||||
var rowdef = rows[key] || {};
|
||||
var iconCls = rowdef.iconCls;
|
||||
var icon = '';
|
||||
var txt = (rowdef.header || key);
|
||||
|
||||
metaData.tdAttr = "valign=middle";
|
||||
|
||||
@ -26,8 +29,11 @@ Ext.define('PVE.qemu.HardwareView', {
|
||||
return rowdef.cdheader;
|
||||
}
|
||||
}
|
||||
} else if (iconCls) {
|
||||
icon = "<i class='pve-grid-fa fa fa-fw fa-" + iconCls + "'></i>";
|
||||
metaData.tdCls += " pve-itype-fa";
|
||||
}
|
||||
return rowdef.header || key;
|
||||
return icon + txt;
|
||||
},
|
||||
|
||||
initComponent : function() {
|
||||
|
Loading…
Reference in New Issue
Block a user