Kill trailing whitespaces in javascript files

This commit is contained in:
小太
2013-03-19 23:09:22 +11:00
parent 35f1304157
commit c107f96cec
25 changed files with 128 additions and 128 deletions

View File

@@ -1,6 +1,6 @@
(function() {
Danbooru.PostModeMenu = {};
Danbooru.PostModeMenu.initialize = function() {
if ($("#c-posts").length || $("#c-favorites").length || $("#c-pools").length) {
this.initialize_selector();
@@ -9,7 +9,7 @@
Danbooru.PostModeMenu.change();
}
}
Danbooru.PostModeMenu.initialize_selector = function() {
if (Danbooru.Cookie.get("mode") === "") {
Danbooru.Cookie.put("mode", "view");
@@ -20,18 +20,18 @@
$("#mode-box select").change(Danbooru.PostModeMenu.change);
}
Danbooru.PostModeMenu.initialize_preview_link = function() {
$(".post-preview a").click(Danbooru.PostModeMenu.click);
}
Danbooru.PostModeMenu.initialize_edit_form = function() {
$("#quick-edit-div").hide();
$("#quick-edit-form input[value=Cancel]").click(function(e) {
$("#quick-edit-div").slideUp("fast");
e.preventDefault();
});
$("#quick-edit-form").submit(function(e) {
$.ajax({
type: "put",
@@ -47,11 +47,11 @@
Danbooru.notice("Post #" + data.id + " updated");
}
});
e.preventDefault();
});
}
Danbooru.PostModeMenu.change = function(e) {
$("#quick-edit-div").slideUp("fast");
var s = $("#mode-box select").val();
@@ -62,11 +62,11 @@
$body.removeClass();
$body.addClass("mode-" + s);
Danbooru.Cookie.put("mode", s, 1);
if (s === "edit-tag-script") {
var script = Danbooru.Cookie.get("tag-script");
script = prompt("Enter a tag script", script);
if (script) {
Danbooru.Cookie.put("tag-script", script);
$("#mode-box select").val("apply-tag-script");
@@ -77,18 +77,18 @@
Danbooru.PostModeMenu.change(e);
}
}
Danbooru.PostModeMenu.open_edit = function(post_id) {
var $post = $("#post_" + post_id);
$("#quick-edit-div").slideDown("fast");
$("#quick-edit-form").attr("action", "/posts/" + post_id + ".json");
$("#post_tag_string").val($post.data("tags")).focus();
}
Danbooru.PostModeMenu.click = function(e) {
var s = $("#mode-box select").val();
var post_id = $(e.target).closest("article").data("id");
if (s === "add-fav") {
Danbooru.Favorite.create(post_id);
} else if (s === "remove-fav") {
@@ -117,7 +117,7 @@
} else {
return;
}
e.preventDefault();
}
})();