Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id 46865E0090E; Tue, 16 Feb 2016 03:16:53 -0800 (PST) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on yocto-www.yoctoproject.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -5.0 RCVD_IN_DNSWL_HI RBL: Sender listed at http://www.dnswl.org/, high * trust * [192.55.52.88 listed in list.dnswl.org] * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id C03F3E008F1 for ; Tue, 16 Feb 2016 03:16:52 -0800 (PST) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga101.fm.intel.com with ESMTP; 16 Feb 2016 03:16:53 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.22,455,1449561600"; d="scan'208";a="747184207" Received: from mykaukab-mobl.ger.corp.intel.com (HELO bbarrosp-mac03.local.com) ([10.252.17.169]) by orsmga003.jf.intel.com with ESMTP; 16 Feb 2016 03:16:51 -0800 From: Belen Barros Pena To: toaster@yoctoproject.org Date: Tue, 16 Feb 2016 12:16:41 +0100 Message-Id: <1455621401-16614-1-git-send-email-belen.barros.pena@linux.intel.com> X-Mailer: git-send-email 2.5.4 (Apple Git-61) Subject: [PATCH] toaster: disable add layer button on click X-BeenThere: toaster@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Web based interface for BitBake List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Feb 2016 11:16:53 -0000 From: Belen Barros Pena The 'add layer' button in the project configuration page remains enabled after you add a layer. If you click it again, the same layer you just added is added again. This patch disables the 'add layer' button on click, to avoid this bit of weirdness. [YOCTO #8905] Signed-off-by: Belen Barros Pena --- bitbake/lib/toaster/toastergui/static/js/projectpage.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bitbake/lib/toaster/toastergui/static/js/projectpage.js b/bitbake/lib/toaster/toastergui/static/js/projectpage.js index 4a482d7..0666bde 100644 --- a/bitbake/lib/toaster/toastergui/static/js/projectpage.js +++ b/bitbake/lib/toaster/toastergui/static/js/projectpage.js @@ -116,6 +116,8 @@ function projectPageInit(ctx) { addRmLayer(layerObj, true); /* Reset the text input */ layerAddInput.val(""); + /* Disable the add layer button*/ + layerAddBtn.attr("disabled", "disabled"); }); function addRmLayer(layerObj, add){ -- 2.5.4 (Apple Git-61)