From 8817139d57b9a916933a2b210cd2135a90d0ebef Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Wed, 9 Nov 2016 10:27:33 +0100 Subject: [PATCH] =?utf8?q?ActionBar:=20Unterst=C3=BCtzung=20f=C3=BCr=20Too?= =?utf8?q?ltips=20f=C3=BCr=20deaktivierte=20Actions?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- SL/Layout/ActionBar/Action.pm | 2 +- js/kivi.ActionBar.js | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/SL/Layout/ActionBar/Action.pm b/SL/Layout/ActionBar/Action.pm index 1ee9a3e95..5d03b7c05 100644 --- a/SL/Layout/ActionBar/Action.pm +++ b/SL/Layout/ActionBar/Action.pm @@ -78,7 +78,7 @@ on click submit the form specified by form-selector with the additional params on click call the specified function (is this a special case of checks?) -- disabled => true/false (done) +- disabled => true/false/tooltip explaning why disabled (done) TODO: diff --git a/js/kivi.ActionBar.js b/js/kivi.ActionBar.js index 597b48528..4d5fb54c4 100644 --- a/js/kivi.ActionBar.js +++ b/js/kivi.ActionBar.js @@ -103,6 +103,8 @@ namespace('kivi', function(k){ if (data.disabled) { $(e).addClass(CLASSES.disabled); + if (!data.tooltip && (data.disabled != '1')) + data.tooltip = data.disabled; } if (data.accesskey) { -- 2.20.1