Code Duplication    Length = 12-12 lines in 2 locations

api/js/dhtmlxMenu/sources/dhtmlxmenu.js 1 location

@@ 350-361 (lines=12) @@
347
			}
348
			*/
349
			// pos
350
			if (openType == "bottom") {
351
				if (this._rtl) {
352
					x = srcX + (srcW!=null?srcW:0) - w;
353
				} else {
354
					if (this._align == "right") {
355
						x = srcX + srcW - w;
356
					} else {
357
						x = srcX - 1 + (openType==this.dirTopLevel?this._topLevelRightMargin:0);
358
					}
359
				}
360
				y = srcY - 1 + srcH + this._topLevelBottomMargin;
361
			}
362
			if (openType == "right") { x = srcX + srcW - 1; y = srcY + 2; }
363
			if (openType == "left") { x = srcX - this.idPull[pId].offsetWidth + 2; y = srcY + 2; }
364
			if (openType == "top") { x = srcX - 1; y = srcY - h + 2; }

api/js/egw_action/test/js/dhtmlxmenu.js 1 location

@@ 337-348 (lines=12) @@
334
			}
335
			*/
336
			// pos
337
			if (openType == "bottom") {
338
				if (this._rtl) {
339
					x = srcX + (srcW!=null?srcW:0) - w;
340
				} else {
341
					if (this._align == "right") {
342
						x = srcX + srcW - w;
343
					} else {
344
						x = srcX - 1 + (openType==this.dirTopLevel?this._topLevelRightMargin:0);
345
					}
346
				}
347
				y = srcY - 1 + srcH - arrUpH - arrDownH + this._topLevelBottomMargin;
348
			}
349
			if (openType == "right") { x = srcX + srcW - 1; y = srcY + 2; }
350
			if (openType == "left") { x = srcX - this.idPull[pId].offsetWidth + 2; y = srcY + 2; }
351
			if (openType == "top") { x = srcX - 1; y = srcY - h + 2; }