Skip to content
Browse files

adds possibility to prevent autohide on close btn visible

  • Loading branch information...
1 parent 7dbafdc commit 9b3cc817d52b3c90f68a7d58fcb3f91db134ac97 Stephan committed
Showing with 4 additions and 4 deletions.
  1. +4 −4 jquery.notifyBar.js
View
8 jquery.notifyBar.js
@@ -43,8 +43,8 @@ jQuery.notifyBar = function(settings) {
//close button if injected as true the delay is not needed until the hideDelayedOnCloseBtnVisible is set to true
notifyBarNS.close = settings.close || false;
- //hide the bar even if close btn option is set to true
- notifyBarNS.hideDelayedOnCloseBtnVisible = settings.hideDelayedOnCloseBtnVisible || false;
+ //hide the bar even if close btn option is set to true
+ notifyBarNS.respectHideDelay = settings.respectHideDelay == undefined ? true : settings.respectHideDelay;
if( notifyBarNS.jqObject) {
bar = notifyBarNS.jqObject;
@@ -102,8 +102,8 @@ jQuery.notifyBar = function(settings) {
$(this).slideUp(asTime);
})
- // check if we have to autoHide depending on close btn visbil and hideDelayedOnCloseBtnVisible
- if (!notifyBarNS.close || (notifyBarNS.close && notifyBarNS.hideDelayedOnCloseBtnVisible)) {
+ // If taken from DOM dot not remove just hide
+ if (!notifyBarNS.close || (notifyBarNS.close && notifyBarNS.respectHideDelay)) {
// If taken from DOM dot not remove just hide
if( bar.attr("id") == "__notifyBar") {
setTimeout("jQuery('#" + id + "').stop().slideUp(" + asTime +", function() {jQuery('#" + id + "').remove()});", notifyBarNS.delay + asTime);

0 comments on commit 9b3cc81

Please sign in to comment.
Something went wrong with that request. Please try again.