From 29faf148b91464aa9923b565602b4b25e0045900 Mon Sep 17 00:00:00 2001 From: Thomas Heck Date: Fri, 3 Aug 2012 10:34:14 +0200 Subject: [PATCH] =?utf8?q?JS-Menu:=20Bei=20Mittel-Klick=20Link=20im=20neue?= =?utf8?q?n=20Fenster=20=C3=B6ffnen(Ticket=20#1921)?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- css/kivitendo/dhtmlsuite/menu-item.css | 7 ++++++- css/lx-office-erp/dhtmlsuite/menu-item.css | 7 ++++++- js/dhtmlsuite/menu-for-applications.js | 14 ++++++++++++-- 3 files changed, 24 insertions(+), 4 deletions(-) diff --git a/css/kivitendo/dhtmlsuite/menu-item.css b/css/kivitendo/dhtmlsuite/menu-item.css index 604b730cc..5f753121a 100644 --- a/css/kivitendo/dhtmlsuite/menu-item.css +++ b/css/kivitendo/dhtmlsuite/menu-item.css @@ -155,4 +155,9 @@ background-color:#D1D1D1; } - +.DHTMLSuite_menuItem_textContent +{ + border-bottom-style: none !important; + background-color: inherit !important; + color: inherit !important; +} diff --git a/css/lx-office-erp/dhtmlsuite/menu-item.css b/css/lx-office-erp/dhtmlsuite/menu-item.css index b50805da4..992a60d3a 100644 --- a/css/lx-office-erp/dhtmlsuite/menu-item.css +++ b/css/lx-office-erp/dhtmlsuite/menu-item.css @@ -181,4 +181,9 @@ background-color:#6A8CCB; /* background color for the separator - blue */ } - +.DHTMLSuite_menuItem_textContent +{ + border-bottom-style: none !important; + background-color: inherit !important; + color: inherit !important; +} diff --git a/js/dhtmlsuite/menu-for-applications.js b/js/dhtmlsuite/menu-for-applications.js index 7a7d76e10..48d030336 100644 --- a/js/dhtmlsuite/menu-for-applications.js +++ b/js/dhtmlsuite/menu-for-applications.js @@ -1187,7 +1187,7 @@ DHTMLSuite.menuItem.prototype = }else{ /* Add events */ var tmpVar = this.objectIndex/1; - this.divElement.onclick = function(e) { DHTMLSuite.variableStorage.arrayOfDhtmlSuiteObjects[tmpVar].__navigate(e); } + //this.divElement.onclick = function(e) { DHTMLSuite.variableStorage.arrayOfDhtmlSuiteObjects[tmpVar].__navigate(e); } this.divElement.onmousedown = this.__clickMenuItem; // on mouse down effect this.divElement.onmouseup = this.__rolloverMenuItem; // on mouse up effect this.divElement.onmouseover = this.__rolloverMenuItem; // mouse over effect @@ -1264,7 +1264,17 @@ DHTMLSuite.menuItem.prototype = parentEl.style.backgroundPosition = 'left center'; } if(this.modelItemRef.itemText){ - var div = document.createElement('DIV'); + var div; + if( this.modelItemRef.url ) + { + div = document.createElement('a'); + div.href = this.modelItemRef.url; + div.target = this.modelItemRef.frameTarget; + div.style.display = 'block'; + } + else + div = document.createElement('div'); + div.className = 'DHTMLSuite_textContent'; div.innerHTML = this.modelItemRef.itemText; div.className = this.cssPrefix + 'menuItem_textContent'; -- 2.20.1