##// END OF EJS Templates
fix sticky warning....
Matthias Bussonnier -
Show More
@@ -99,19 +99,22 b' define(['
99 99 }, timeout);
100 100 }
101 101
102 // bind the click callback if it is given
103 if (click_callback !== undefined) {
102 // if no click callback assume we will just dismiss the notification
103 if (click_callback === undefined) {
104 click_callback = function(){return true};
105 }
106 // on click, remove widget if click callback say so
107 // and unbind click event.
104 108 this.element.click(function () {
105 109 if (click_callback() !== false) {
106 110 that.element.fadeOut(100, function () {that.inner.text('');});
107 }
108 111 that.element.unbind('click');
112 }
109 113 if (that.timeout !== null) {
110 114 clearTimeout(that.timeout);
111 115 that.timeout = null;
112 116 }
113 117 });
114 }
115 118 };
116 119
117 120 /**
General Comments 0
You need to be logged in to leave comments. Login now