Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions examples/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ <h3>Manipulating Buttons</h3>
message: function(dialog) {
var $content = $('<div><button class="btn btn-success">Revert button status right now.</button></div>');
var $footerButton = dialog.getButton('btn-1');
$content.find('button').click({$footerButton: $footerButton}, function(event) {
$content.find('button').on('click',{$footerButton: $footerButton}, function(event) {
event.data.$footerButton.enable();
event.data.$footerButton.stopSpin();
dialog.setClosable(true);
Expand Down Expand Up @@ -379,7 +379,7 @@ <h3>Button with identifier</h3>
});
dialog.realize();
var btn1 = dialog.getButton('btn-1');
btn1.click({'name': 'Apple'}, function(event){
btn1.on('click',{'name': 'Apple'}, function(event){
alert('Hi, ' + event.data.name);
});
dialog.open();
Expand Down
4 changes: 2 additions & 2 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
var gulp = require("gulp"),
eslint = require("gulp-eslint"),
less = require("gulp-less"),
minifyCSS = require("gulp-minify-css"),
cleanCSS = require("gulp-clean-css"),
path = require("path"),
notify = require("gulp-notify"),
clean = require("gulp-clean"),
Expand All @@ -27,7 +27,7 @@ gulp.task("less", function() {
.pipe(gulp.dest("dist/css"))
.pipe(gulp.dest("src/css"))
.pipe(rename("bootstrap-dialog.min.css"))
.pipe(minifyCSS())
.pipe(cleanCSS())
.pipe(gulp.dest("dist/css"));
});

Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,17 +24,17 @@
},
"homepage": "http://nakupanda.github.io/bootstrap3-dialog",
"devDependencies": {
"bootstrap": ">=3.1.0",
"bootstrap": "^3.3.7",
"eslint": ">=0.6.2",
"gulp": ">=3.8.1",
"gulp": "^3.9.1",
"gulp-clean": ">=0.3.0",
"gulp-clean-css": "^3.9.3",
"gulp-concat": "^2.5.2",
"gulp-eslint": ">=0.1.7",
"gulp-less": ">=1.2.3",
"gulp-minify-css": "^0.3.4",
"gulp-notify": ">=1.3.1",
"gulp-rename": ">=1.2.0",
"gulp-streamify": "0.0.5",
"gulp-streamify": "^1.0.2",
"gulp-uglify": ">=0.3.0",
"vinyl-source-stream": "^0.1.1"
}
Expand Down
4 changes: 2 additions & 2 deletions src/js/bootstrap-dialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@
}
});
if (lastDialogInstance !== null) {
lastDialogInstance.getModal().focus();
lastDialogInstance.getModal().trigger('focus');
}
};

Expand Down Expand Up @@ -1092,7 +1092,7 @@
var dialog = event.data.dialog;
if (typeof dialog.registeredButtonHotkeys[event.which] !== 'undefined') {
var $button = $(dialog.registeredButtonHotkeys[event.which]);
!$button.prop('disabled') && !$button.is(':focus') && $button.focus().trigger('click');
!$button.prop('disabled') && !$button.is(':focus') && $button.trigger('focus').trigger('click');
}
});

Expand Down