Zeile 17 | Zeile 17 |
---|
$('[name="allbox"]').each(function(key, value) { var allbox = this; var checked = $(this).is(':checked');
|
$('[name="allbox"]').each(function(key, value) { var allbox = this; var checked = $(this).is(':checked');
|
var checkboxes = $(this).closest('form').find(':checkbox');
| var checkboxes = $(this).closest('form').find(':checkbox').not('[name="allbox"]');
|
checkboxes.change(function() { if(checked && !$(this).prop('checked')) { checked = false;
|
checkboxes.change(function() { if(checked && !$(this).prop('checked')) { checked = false;
|
$(allbox).prop('checked', checked); } }); $(this).change(function() { checked = $(this).is(':checked'); checkboxes.prop('checked', checked);
| $(allbox).trigger('change', ['item']); } });
$(this).on('change', function(event, origin) { checked = $(this).is(':checked');
if(typeof(origin) == "undefined") { checkboxes.each(function() { if(checked != $(this).is(':checked')) { $(this).prop('checked', checked).change(); } }); }
|
}); });
// Initialise "initial focus" field if we have one var initialfocus = $(".initial_focus"); if(initialfocus.length)
|
}); });
// Initialise "initial focus" field if we have one var initialfocus = $(".initial_focus"); if(initialfocus.length)
|
{
| {
|
initialfocus.focus(); }
| initialfocus.focus(); }
|
Zeile 55 | Zeile 66 |
---|
if(element.attr("title")) { element.attr("title", element.attr("title") + " - ");
|
if(element.attr("title")) { element.attr("title", element.attr("title") + " - ");
|
}
| }
|
element.attr("title", element.attr("title") + lang.click_mark_read); }); }
| element.attr("title", element.attr("title") + lang.click_mark_read); }); }
|
Zeile 72 | Zeile 83 |
---|
$(document).on($.modal.CLOSE, function(event, modal) { $("body").css("overflow", "auto");
|
$(document).on($.modal.CLOSE, function(event, modal) { $("body").css("overflow", "auto");
|
}); } },
| }); }
$("a.referralLink").click(MyBB.showReferrals);
if($('.author_avatar').length) { $(".author_avatar img").on('error', function () { $(this).unbind("error").closest('.author_avatar').remove(); }); } },
|
popupWindow: function(url, options, root) { if(!options) options = { fadeDuration: 250, zIndex: (typeof modal_zindex !== 'undefined' ? modal_zindex : 9999) }
| popupWindow: function(url, options, root) { if(!options) options = { fadeDuration: 250, zIndex: (typeof modal_zindex !== 'undefined' ? modal_zindex : 9999) }
|
Zeile 86 | Zeile 106 |
---|
{ $(html).appendTo('body').modal(options); });
|
{ $(html).appendTo('body').modal(options); });
|
| },
prompt: function(message, options) { var defaults = { fadeDuration: 250, zIndex: (typeof modal_zindex !== 'undefined' ? modal_zindex : 9999) }; var buttonsText = '';
for (var i in options.buttons) { buttonsText += templates.modal_button.replace('__title__', options.buttons[i].title); }
var html = templates.modal.replace('__buttons__', buttonsText).replace('__message__', message); var modal = $(html); modal.modal($.extend(defaults, options)); var buttons = modal.find('.modal_buttons > .button'); buttons.click(function(e) { e.preventDefault(); var index = $(this).index(); if (options.submit(e, options.buttons[index].value) == false) return;
$.modal.close(); });
if (buttons[0]) { modal.on($.modal.OPEN, function() { buttons[0].focus(); }); }
return modal;
|
},
deleteEvent: function(eid) {
|
},
deleteEvent: function(eid) {
|
$.prompt(deleteevent_confirm, {
| MyBB.prompt(deleteevent_confirm, {
|
buttons:[ {title: yes_confirm, value: true}, {title: no_confirm, value: false}
| buttons:[ {title: yes_confirm, value: true}, {title: no_confirm, value: false}
|
Zeile 130 | Zeile 185 |
---|
$("<input />", { name: "eid",
|
$("<input />", { name: "eid",
|
type: "hidden",
| type: "hidden",
|
value: eid }) );
| value: eid }) );
|
Zeile 159 | Zeile 214 |
---|
}
MyBB.popupWindow("/reputation.php?action=add&uid="+uid+"&pid="+pid+"&modal=1");
|
}
MyBB.popupWindow("/reputation.php?action=add&uid="+uid+"&pid="+pid+"&modal=1");
|
},
| },
|
viewNotes: function(uid) { MyBB.popupWindow("/member.php?action=viewnotes&uid="+uid+"&modal=1");
|
viewNotes: function(uid) { MyBB.popupWindow("/member.php?action=viewnotes&uid="+uid+"&modal=1");
|
},
| },
|
getIP: function(pid) { MyBB.popupWindow("/moderation.php?action=getip&pid="+pid+"&modal=1");
| getIP: function(pid) { MyBB.popupWindow("/moderation.php?action=getip&pid="+pid+"&modal=1");
|
Zeile 177 | Zeile 232 |
---|
},
deleteReputation: function(uid, rid)
|
},
deleteReputation: function(uid, rid)
|
{ $.prompt(delete_reputation_confirm, { buttons:[ {title: yes_confirm, value: true}, {title: no_confirm, value: false} ], submit: function(e,v,m,f){ if(v == true) {
| { MyBB.prompt(delete_reputation_confirm, { buttons:[ {title: yes_confirm, value: true}, {title: no_confirm, value: false} ], submit: function(e,v,m,f){ if(v == true) {
|
var form = $("<form />", { method: "post", action: "reputation.php?action=delete", style: "display: none;" });
|
var form = $("<form />", { method: "post", action: "reputation.php?action=delete", style: "display: none;" });
|
|
|
form.append( $("<input />", { name: "rid", type: "hidden", value: rid
|
form.append( $("<input />", { name: "rid", type: "hidden", value: rid
|
})
| })
|
);
if(my_post_key)
| );
if(my_post_key)
|
Zeile 239 | Zeile 294 |
---|
if(typeof sortby === "undefined") { sortby = "";
|
if(typeof sortby === "undefined") { sortby = "";
|
}
| }
|
if(sortby == "username") {
| if(sortby == "username") {
|
Zeile 348 | Zeile 403 |
---|
return false; } form.submit();
|
return false; } form.submit();
|
},
| },
|
detectDSTChange: function(timezone_with_dst) {
| detectDSTChange: function(timezone_with_dst) {
|
Zeile 444 | Zeile 499 |
---|
deleteAnnouncement: function(data) {
|
deleteAnnouncement: function(data) {
|
$.prompt(announcement_quickdelete_confirm, {
| MyBB.prompt(announcement_quickdelete_confirm, {
|
buttons:[ {title: yes_confirm, value: true}, {title: no_confirm, value: false}
| buttons:[ {title: yes_confirm, value: true}, {title: no_confirm, value: false}
|
Zeile 458 | Zeile 513 |
---|
});
return false;
|
});
return false;
|
| },
showReferrals: function(e) { var idPieces, uid;
e.preventDefault(); if(typeof this.id == "undefined") { return false; }
idPieces = this.id.split("_"); uid = parseInt(idPieces[idPieces.length - 1], 10);
if(uid <= 0) { return false; }
MyBB.popupWindow("/xmlhttp.php?action=get_referrals&uid="+uid);
|
},
// Fixes https://github.com/mybb/mybb/issues/1232
| },
// Fixes https://github.com/mybb/mybb/issues/1232
|