summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Wood <michael.g.wood@intel.com>2015-08-06 19:23:47 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-08-06 16:04:49 -0500
commit5194f0401ec038359397fd22654f46b3612fc3a6 (patch)
tree9c3c86b9dc97076ed3928fa087260a5bb69d3be9
parentc1993d08ccf64f158c346d1cc0a42f2e2b3d60bc (diff)
downloadpoky-5194f0401ec038359397fd22654f46b3612fc3a6.zip
poky-5194f0401ec038359397fd22654f46b3612fc3a6.tar.gz
poky-5194f0401ec038359397fd22654f46b3612fc3a6.tar.bz2
bitbake: toastergui: Move click disabled check after table ready event
We were attaching this handler before the elements were fully ready in the dom. Which allowed these links although disabled to take users to the change machine page. (Bitbake rev: 8245a7d679914ca7d4548ab7e83b5047ff8a1ff5) Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--bitbake/lib/toaster/toastergui/static/js/layerdetails.js10
1 files changed, 6 insertions, 4 deletions
diff --git a/bitbake/lib/toaster/toastergui/static/js/layerdetails.js b/bitbake/lib/toaster/toastergui/static/js/layerdetails.js
index 96372f0..d9ba687 100644
--- a/bitbake/lib/toaster/toastergui/static/js/layerdetails.js
+++ b/bitbake/lib/toaster/toastergui/static/js/layerdetails.js
@@ -202,6 +202,12 @@ function layerDetailsPageInit (ctx) {
/* re run the machinesTabShow to update the text */
machinesTabShow();
}
+
+ $(".select-machine-btn").click(function(e){
+ if ($(this).attr("disabled") === "disabled")
+ e.preventDefault();
+ });
+
});
$("#targets-tab").on('show', targetsTabShow);
@@ -385,10 +391,6 @@ function layerDetailsPageInit (ctx) {
$(this).parents("form").submit();
});
- $(".select-machine-btn").click(function(e){
- if ($(this).attr("disabled") === "disabled")
- e.preventDefault();
- });
layerDepsList.find(".icon-trash").click(layerDepRemoveClick);
layerDepsList.find("a").tooltip();