Add ability to reset brush with session$resetBrush/Shiny.resetBrush

This commit is contained in:
Joe Cheng
2016-05-25 15:36:50 -07:00
parent 9588c36abb
commit 360c1d5953
10 changed files with 91 additions and 51 deletions

View File

@@ -1368,3 +1368,10 @@ imageutils.createBrush = function($el, opts, coordmap, expandPixels) {
stopResizing: stopResizing
};
};
exports.resetBrush = function(brushId) {
exports.onInputChange(brushId, null);
imageOutputBinding.find(document).trigger("shiny-internal:brushed", {
brushId: brushId, outputId: null
});
};