Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id A4E78E006E9; Mon, 23 Feb 2015 08:33:18 -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=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low * trust * [209.85.212.180 listed in list.dnswl.org] * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] Received: from mail-wi0-f180.google.com (mail-wi0-f180.google.com [209.85.212.180]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id 3287FE006E9 for ; Mon, 23 Feb 2015 08:33:15 -0800 (PST) Received: by mail-wi0-f180.google.com with SMTP id h11so18760118wiw.1 for ; Mon, 23 Feb 2015 08:33:14 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=oyn67HTYjw9w5Gkm+VLBQLWegnkxeveoSIuq4DgglCI=; b=LutBKA329MNA9HZgGELIRjc3kXnEIBKnP+SMVyD0teNK0jk2B44rTO5/1JYx3mlIpY D0PjofQ4/1CQ+6X2tdk6p+FnPcn/nP7s2HzGnBUtuw5T4flriq9TVCnkNo/NavzSsi2p fWEDcBfuRJd84YXO2/9B8SEJKSO212fJMwTqUHUK05yZajsXuULemTiJa3Mhtx4E743a M1NdA4N1Rex3ORMIixR55qf3UtDJdkjp3ZPqetGecJOFcsD/1XJQ9svs11OlhODsesWN K/rXe5DRAylI7ghxx5FPFOcmaQCV5w2poMNKOoLVrkxPefTJk9k8yKZREgCaSVAxs+ax VrsA== X-Gm-Message-State: ALoCoQm03YGr61NDvHD5wqzhoDcjfyqAn3JFQd7uw2nm2YjWoPyS1bHbJEJoJjV0019pjc5dVc72 X-Received: by 10.194.185.9 with SMTP id ey9mr24251906wjc.135.1424709194389; Mon, 23 Feb 2015 08:33:14 -0800 (PST) Received: from draco.icx.intel.com ([83.217.123.106]) by mx.google.com with ESMTPSA id hv5sm56270967wjb.16.2015.02.23.08.33.13 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 23 Feb 2015 08:33:13 -0800 (PST) From: Michael Wood To: toaster@yoctoproject.org Date: Mon, 23 Feb 2015 16:33:11 +0000 Message-Id: <1424709191-17125-1-git-send-email-michael.g.wood@intel.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1424701718-10992-1-git-send-email-michael.g.wood@intel.com> References: <1424701718-10992-1-git-send-email-michael.g.wood@intel.com> Subject: [PATCH V2] bitbake: toaster: Add machine selection notification 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: Mon, 23 Feb 2015 16:33:18 -0000 This adds a notification to the project page to notify users of the change in project configuration. Signed-off-by: Michael Wood --- bitbake/lib/toaster/toastergui/static/css/default.css | 6 ++++++ bitbake/lib/toaster/toastergui/static/js/layerdetails.js | 2 +- bitbake/lib/toaster/toastergui/static/js/machines.js | 3 +-- bitbake/lib/toaster/toastergui/static/js/projectapp.js | 9 +++++++++ 4 files changed, 17 insertions(+), 3 deletions(-) diff --git a/bitbake/lib/toaster/toastergui/static/css/default.css b/bitbake/lib/toaster/toastergui/static/css/default.css index 86cf67a..2c9b1aa 100644 --- a/bitbake/lib/toaster/toastergui/static/css/default.css +++ b/bitbake/lib/toaster/toastergui/static/css/default.css @@ -236,4 +236,10 @@ div.add-deps { margin-top: 15px; } .animate-repeat.ng-enter.ng-enter-active { opacity:1; } + +@keyframes machines-fade { 0% { background-color: #D9EDF7; } 25% { background-color: #D9EDF7; } 100% { background-color: white; } } +@-webkit-keyframes machines-fade { 0% { background-color: #D9EDF7; } 25% { background-color: #D9EDF7; } 100% { background-color: white; } } + +.machines-highlight { -webkit-animation: machines-fade 7s 1; -moz-animation: machines-fade 7s 1; animation: machines-fade 7s 1; } + .tab-pane table { margin-top: 10px; } diff --git a/bitbake/lib/toaster/toastergui/static/js/layerdetails.js b/bitbake/lib/toaster/toastergui/static/js/layerdetails.js index 2e713d5..22c40d9 100644 --- a/bitbake/lib/toaster/toastergui/static/js/layerdetails.js +++ b/bitbake/lib/toaster/toastergui/static/js/layerdetails.js @@ -133,7 +133,7 @@ function layerDetailsPageInit (ctx) { var data = { machineName : $(this).data('machine-name') }; libtoaster.editProject(ctx.xhrEditProjectUrl, ctx.projectId, data, function (){ - window.location.replace(ctx.projectPageUrl); + window.location.replace(ctx.projectPageUrl+"#/machineselected"); }, null); }); diff --git a/bitbake/lib/toaster/toastergui/static/js/machines.js b/bitbake/lib/toaster/toastergui/static/js/machines.js index ee8c980..973a037 100644 --- a/bitbake/lib/toaster/toastergui/static/js/machines.js +++ b/bitbake/lib/toaster/toastergui/static/js/machines.js @@ -77,7 +77,6 @@ function machinesPageInit (ctx) { show_layer_deps_modal(ctx.projectId, layer, data.list, null, null, true, function () { /* Success add deps and layer */ setLayerInCurrentPrj(btn, data.list); - console.log ("TODO SUCCESS"); }); } }, null); @@ -87,7 +86,7 @@ function machinesPageInit (ctx) { var data = { machineName : $(this).data('machine-name') }; libtoaster.editProject(ctx.xhrEditProjectUrl, ctx.projectId, data, function (){ - window.location.replace(ctx.projectPageUrl); + window.location.replace(ctx.projectPageUrl+"#/machineselected"); }, null); }); diff --git a/bitbake/lib/toaster/toastergui/static/js/projectapp.js b/bitbake/lib/toaster/toastergui/static/js/projectapp.js index 4d00f40..df811fb 100644 --- a/bitbake/lib/toaster/toastergui/static/js/projectapp.js +++ b/bitbake/lib/toaster/toastergui/static/js/projectapp.js @@ -665,6 +665,15 @@ projectApp.controller('prjCtrl', function($scope, $modal, $http, $interval, $loc "\">select targets you want to build.", "alert-success"); }); + _cmdExecuteWithParam("/machineselected", function () { + $scope.displayAlert($scope.zone2alerts, "You have changed the machine to: " + $scope.machine.name + "", "alert-info"); + var machineDistro = angular.element("#machine-distro"); + + angular.element("html, body").animate({ scrollTop: machineDistro.position().top }, 700).promise().done(function() { + $animate.addClass(machineDistro, "machines-highlight"); + }); + }); + _cmdExecuteWithParam("/layerimported", function (layer) { var imported = $cookieStore.get("layer-imported-alert"); var text; -- 2.1.0