diff --git a/core/modules/widgets/checkbox.js b/core/modules/widgets/checkbox.js index 9fa1c4889..1edf0bee0 100644 --- a/core/modules/widgets/checkbox.js +++ b/core/modules/widgets/checkbox.js @@ -156,6 +156,9 @@ CheckboxWidget.prototype.handleChangeEvent = function(event) { if(this.checkboxActions) { this.invokeActionString(this.checkboxActions,this,event); } + if(this.checkboxCheckActions && checked) { + this.invokeActionString(this.checkboxCheckActions,this,event); + } if(this.checkboxUncheckActions && !checked) { this.invokeActionString(this.checkboxUncheckActions,this,event); } @@ -167,6 +170,7 @@ Compute the internal state of the widget CheckboxWidget.prototype.execute = function() { // Get the parameters from the attributes this.checkboxActions = this.getAttribute("actions"); + this.checkboxCheckActions = this.getAttribute("checkactions"); this.checkboxUncheckActions = this.getAttribute("uncheckactions"); this.checkboxTitle = this.getAttribute("tiddler",this.getVariable("currentTiddler")); this.checkboxTag = this.getAttribute("tag"); diff --git a/editions/tw5.com/tiddlers/widgets/CheckboxWidget.tid b/editions/tw5.com/tiddlers/widgets/CheckboxWidget.tid index 60f1b389b..87ef7b936 100644 --- a/editions/tw5.com/tiddlers/widgets/CheckboxWidget.tid +++ b/editions/tw5.com/tiddlers/widgets/CheckboxWidget.tid @@ -1,6 +1,6 @@ caption: checkbox created: 20131024141900000 -modified: 20161221202816730 +modified: 20190714134002652 tags: Widgets title: CheckboxWidget type: text/vnd.tiddlywiki @@ -26,8 +26,9 @@ The content of the `<$checkbox>` widget is displayed within an HTML `