From patchwork Tue Nov 29 09:37:20 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zygmunt Krynicki X-Patchwork-Id: 5353 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id D672423E17 for ; Tue, 29 Nov 2011 09:37:27 +0000 (UTC) Received: from mail-lpp01m010-f52.google.com (mail-lpp01m010-f52.google.com [209.85.215.52]) by fiordland.canonical.com (Postfix) with ESMTP id BBA2CA18066 for ; Tue, 29 Nov 2011 09:37:27 +0000 (UTC) Received: by mail-lpp01m010-f52.google.com with SMTP id h2so1233385laa.11 for ; Tue, 29 Nov 2011 01:37:27 -0800 (PST) Received: by 10.152.105.226 with SMTP id gp2mr30638556lab.28.1322559447414; Tue, 29 Nov 2011 01:37:27 -0800 (PST) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.152.41.198 with SMTP id h6cs32676lal; Tue, 29 Nov 2011 01:37:27 -0800 (PST) Received: by 10.180.103.170 with SMTP id fx10mr47686708wib.56.1322559440694; Tue, 29 Nov 2011 01:37:20 -0800 (PST) Received: from indium.canonical.com (indium.canonical.com. [91.189.90.7]) by mx.google.com with ESMTPS id es13si1863654wbb.126.2011.11.29.01.37.20 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 29 Nov 2011 01:37:20 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.7 as permitted sender) client-ip=91.189.90.7; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.7 as permitted sender) smtp.mail=bounces@canonical.com Received: from ackee.canonical.com ([91.189.89.26]) by indium.canonical.com with esmtp (Exim 4.71 #1 (Debian)) id 1RVK7s-0007Ku-8Y for ; Tue, 29 Nov 2011 09:37:20 +0000 Received: from ackee.canonical.com (localhost [127.0.0.1]) by ackee.canonical.com (Postfix) with ESMTP id 37B33E0435 for ; Tue, 29 Nov 2011 09:37:20 +0000 (UTC) MIME-Version: 1.0 X-Launchpad-Project: lava-server X-Launchpad-Branch: ~linaro-validation/lava-server/trunk X-Launchpad-Message-Rationale: Subscriber X-Launchpad-Branch-Revision-Number: 321 X-Launchpad-Notification-Type: branch-revision To: Linaro Patch Tracker From: noreply@launchpad.net Subject: [Branch ~linaro-validation/lava-server/trunk] Rev 321: Disable javascript logging for menu Message-Id: <20111129093720.13982.97073.launchpad@ackee.canonical.com> Date: Tue, 29 Nov 2011 09:37:20 -0000 Reply-To: noreply@launchpad.net Sender: bounces@canonical.com Errors-To: bounces@canonical.com Precedence: bulk X-Generated-By: Launchpad (canonical.com); Revision="14399"; Instance="launchpad-lazr.conf" X-Launchpad-Hash: 4f648005edc2019824d3f6062e584e6c6c173473 ------------------------------------------------------------ revno: 321 committer: Zygmunt Krynicki branch nick: lava-server timestamp: Tue 2011-11-22 21:56:07 +0100 message: Disable javascript logging for menu modified: lava_server/templates/layouts/content.html --- lp:lava-server https://code.launchpad.net/~linaro-validation/lava-server/trunk You are subscribed to branch lp:lava-server. To unsubscribe from this branch go to https://code.launchpad.net/~linaro-validation/lava-server/trunk/+edit-subscription === modified file 'lava_server/templates/layouts/content.html' --- lava_server/templates/layouts/content.html 2011-11-22 20:38:52 +0000 +++ lava_server/templates/layouts/content.html 2011-11-22 20:56:07 +0000 @@ -99,12 +99,12 @@ function close_current_menu() { if (current_menu) { - console.log("--- closing current menu ---"); + //console.log("--- closing current menu ---"); current_menu.removeClass("active"); current_menu = null; } if (current_sub_menu) { - console.log("--- closing current sub menu ---"); + //console.log("--- closing current sub menu ---"); current_sub_menu.offset({top: -1000, left: 0}); current_sub_menu = null; } @@ -132,7 +132,7 @@ $('.lava-panel-element.has-menu') .click(function(event) { - console.log("----------------------"); + //console.log("----------------------"); // Enter hover-mode menu_should_open = true; @@ -161,45 +161,45 @@ // The left absolute position of the menu. // defaults to the offset of the indicator span var _left = current_menu.offset().left; - console.log("_left is ", _left); + //console.log("_left is ", _left); // Same with the right menu, the right margin var _menu_width = current_menu.width(); - console.log("_menu_width is ", _menu_width); + //console.log("_menu_width is ", _menu_width); // Same with the right menu, the right margin var _sub_menu_width = current_sub_menu.width(); - console.log("_sub_menu_width is ", _sub_menu_width); + //console.log("_sub_menu_width is ", _sub_menu_width); // Adjust the width to consider the border of the pop-up menu. var _sub_menu_width_adj = current_sub_menu.outerWidth() - current_sub_menu.width(); - console.log("_sub_menu_width_adj is ", _sub_menu_width_adj); + //console.log("_sub_menu_width_adj is ", _sub_menu_width_adj); // Check how much space we have left var _space_left = $("#lava-panel").width() - _left - current_sub_menu.outerWidth(true); - console.log("_space left is ", _space_left); + //console.log("_space left is ", _space_left); // If we ran out of space then let's move the whole thing to the left // This is only needed for the user indicator. if (_space_left < 0) { _left += _space_left; _sub_menu_width += _sub_menu_width_adj; - console.log( - "sub-menu would go off-screen", - " _left changes to ", _left, - " _sub_menu_width changes to ", _sub_menu_width - ); + //console.log( + // "sub-menu would go off-screen", + // " _left changes to ", _left, + // " _sub_menu_width changes to ", _sub_menu_width + //); } // Don't set the width if it would make the menu too narrow. if (_sub_menu_width < _menu_width) { _sub_menu_width = _menu_width - _sub_menu_width_adj; - console.log("sub-menu is too narrow, _sub_menu_width changes to ", _menu_width); + //console.log("sub-menu is too narrow, _sub_menu_width changes to ", _menu_width); } // Place & resize the sub menu - console.log("Setting position to ", {top: _top, left: _left}); - console.log("Setting width to ", _sub_menu_width); + // console.log("Setting position to ", {top: _top, left: _left}); + // console.log("Setting width to ", _sub_menu_width); current_sub_menu .width(_sub_menu_width) .offset({left: _left, top: _top})