We are no longer offering accounts on this server. Consider https://gitlab.freedesktop.org/ as a place to host projects.

Commit cecc2576 authored by Brion Vibber's avatar Brion Vibber

Fixes for direct message form for JS changes to the main form

parent e74590d4
......@@ -104,7 +104,7 @@ var SN = { // StatusNet
SN.U.Counter(form);
NDT = form.find('[name=status_textarea]');
NDT = form.find('.notice_data-text:first');
NDT.bind('keyup', function(e) {
SN.U.Counter(form);
......@@ -183,7 +183,7 @@ var SN = { // StatusNet
* @return number of chars
*/
CharacterCount: function(form) {
return form.find('[name=status_textarea]').val().length;
return form.find('.notice_data-text:first').val().length;
},
/**
......@@ -327,7 +327,7 @@ var SN = { // StatusNet
dataType: 'xml',
timeout: '60000',
beforeSend: function(formData) {
if (form.find('[name=status_textarea]').val() == '') {
if (form.find('.notice_data-text:first').val() == '') {
form.addClass(SN.C.S.Warning);
return false;
}
......
This diff is collapsed.
......@@ -96,7 +96,7 @@ class MessageForm extends Form
function formClass()
{
return 'form_notice';
return 'form_notice ajax-notice';
}
/**
......@@ -153,7 +153,7 @@ class MessageForm extends Form
$this->out->dropdown('to', _('To'), $mutual, null, false,
($this->to) ? $this->to->id : null);
$this->out->element('textarea', array('id' => 'notice_data-text',
$this->out->element('textarea', array('class' => 'notice_data-text',
'cols' => 35,
'rows' => 4,
'name' => 'content'),
......
......@@ -170,7 +170,7 @@ class NoticeForm extends Form
// TRANS: Title for notice label. %s is the user's nickname.
sprintf(_('What\'s up, %s?'), $this->user->nickname));
// XXX: vary by defined max size
$this->out->element('textarea', array('id' => 'notice_data-text',
$this->out->element('textarea', array('class' => 'notice_data-text',
'cols' => 35,
'rows' => 4,
'name' => 'status_textarea'),
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment