diff --git a/apps/common/main/lib/component/Button.js b/apps/common/main/lib/component/Button.js index 511922a420..1faefe2f15 100644 --- a/apps/common/main/lib/component/Button.js +++ b/apps/common/main/lib/component/Button.js @@ -779,10 +779,11 @@ define([ if (/svgicon/.test(this.iconCls)) { var icon = /svgicon\s(\S+)/.exec(this.iconCls); svgIcon.attr('xlink:href', icon && icon.length > 1 ? '#' + icon[1] : ''); - } else if (svgIcon.length) { - var icon = /btn-[^\s]+/.exec(this.iconCls); - svgIcon.attr('href', icon ? '#' + icon[0]: ''); } else { + if (svgIcon.length) { + var icon = /btn-[^\s]+/.exec(this.iconCls); + svgIcon.attr('href', icon ? '#' + icon[0]: ''); + } btnIconEl.removeClass(oldCls); btnIconEl.addClass(cls || ''); if (this.options.scaling === false) {