1
0
mirror of https://github.com/wbbaddons/Tims-Chat.git synced 2025-01-09 00:20:08 +00:00

Adding onSubmit-event-skeleton and correct icon-urls

This commit is contained in:
Tim Düsterhus 2011-12-11 13:27:39 +01:00
parent 670e04768e
commit 96f468b3ca

View File

@ -37,6 +37,10 @@ if (typeof TimWolla.WCF == 'undefined') TimWolla.WCF = {};
event.preventDefault(); event.preventDefault();
this.toggleUserMenu($(event.target)); this.toggleUserMenu($(event.target));
}, this)); }, this));
$('#chatForm').submit($.proxy(function (event) {
event.preventDefault();
$(event.target).find('input[type=image]').attr('src', WCF.Icon.get('wcf.icon.loading'));
}, this));
}, },
changeRoom: function (target) { changeRoom: function (target) {
window.history.replaceState({}, '', target.attr('href')); window.history.replaceState({}, '', target.attr('href'));
@ -97,7 +101,7 @@ if (typeof TimWolla.WCF == 'undefined') TimWolla.WCF = {};
'overflow': 'hidden' 'overflow': 'hidden'
}) })
.parent() .parent()
.append('<img class="ajaxLoad" src="' + RELATIVE_WCF_DIR + 'icon/spinner1.svg" alt="" />') .append('<img class="ajaxLoad" src="' + WCF.Icon.get('wcf.icon.loading') + '" alt="" />')
.css({'marginTop' : function (index) {return (target.parent().height() / 2) - ($(this).height() / 2);}}); .css({'marginTop' : function (index) {return (target.parent().height() / 2) - ($(this).height() / 2);}});
}, this) }, this)
}); });