Permalink
Browse files

chat_input -> chat-input

  • Loading branch information...
1 parent 27f54b2 commit 338763929d49e4d2e7a41e1f2dd6bbd4f0d9b44b @akavlie akavlie committed Jan 20, 2012
Showing with 6 additions and 6 deletions.
  1. +5 −5 assets/js/views/chat.js
  2. +1 −1 views/templates.jade
View
@@ -23,12 +23,12 @@ var ChatView = Backbone.View.extend({
$('#chat-contents').scrollTop($('#chat-contents').get(0).scrollHeight-$('#chat-contents').height());
this.updateTitle();
this.handleInput();
- $('#chat_input').focus();
+ $('#chat-input').focus();
return this;
},
handleInput: function() {
- $('#chat_input').bind({
+ $('#chat-input').bind({
// Enable button if there's any input
change: function() {
if ($(this).val().length) {
@@ -62,7 +62,7 @@ var ChatView = Backbone.View.extend({
} else if (event.keyCode == 9) {
var channel = irc.chatWindows.getActive();
// Tab completion of user names
- var sentence = $('#chat_input').val().split(' ');
+ var sentence = $('#chat-input').val().split(' ');
var partialMatch = sentence.pop();
// TODO: Make this work (copy-paste from old code; it doesn't work)
// All the below code is busted until this is resolved.
@@ -72,9 +72,9 @@ var ChatView = Backbone.View.extend({
if (partialMatch.length > 0 && user.search(partialMatch) === 0) {
sentence.push(user);
if (sentence.length === 1) {
- $('#chat_input').val(sentence.join(' ') + ":");
+ $('#chat-input').val(sentence.join(' ') + ":");
} else {
- $('#chat_input').val(sentence.join(' '));
+ $('#chat-input').val(sentence.join(' '));
}
}
}
View
@@ -53,7 +53,7 @@ script(id="chat", type="text/html")
#chat-contents
#input-container
.input
- input(id="chat_input")
+ input(id="chat-input")
a(id="chat_button", class="btn disabled") Send
#user-window
#user-bar

0 comments on commit 3387639

Please sign in to comment.