B2G/gaia/apps/sms/js/thread_ui.js
// Initialize Recipients list and Recipients.View (DOM)
Initialize Recipients list and Recipients.View (DOM)
Initialize Recipients list and Recipients . View ( DOM )
function thui_initRecipients() {
    function recipientsChanged(count) {
      var message = count ?
        (count > 1 ? 'recipient[many]' : 'recipient[one]') :
        'newMessage';
      this.headerText.textContent = navigator.mozL10n.get(message, {
        n: count
      });
      this.enableSend();
      this.container.textContent = '';
    }
    if (this.recipients) {
      this.recipients.length = 0;
      this.recipients.visible('singleline');
      this.recipients.focus();
    } else {
      this.recipients = new Recipients({
        outer: 'messages-to-field',
        inner: 'messages-recipients-list',
        template: this.tmpl.recipient
      });
      this.recipients.on('add', recipientsChanged.bind(this));
      this.recipients.on('remove', recipientsChanged.bind(this));
    }
    this.container.textContent = '';
  }
function thui_initRecipients ( ) { function recipientsChanged ( count ) { var message = count ? ( count > 1 ? 'recipient[many]' : 'recipient[one]' ) : 'newMessage' ; this . headerText . textContent = navigator . mozL10n . get ( message , { n : count } ) ; this . enableSend ( ) ; this . container . textContent = '' ; } if ( this . recipients ) { this . recipients . length = 0 ; this . recipients . visible ( 'singleline' ) ; this . recipients . focus ( ) ; } else { this . recipients = new Recipients ( { outer : 'messages-to-field' , inner : 'messages-recipients-list' , template : this . tmpl . recipient } ) ; this . recipients . on ( 'add' , recipientsChanged . bind ( this ) ) ; this . recipients . on ( 'remove' , recipientsChanged . bind ( this ) ) ; } this . container . textContent = '' ; }
Initialize Recipients list and Recipients.View (DOM)
Initialize Recipients list and Recipients . View ( DOM )
// check for enable send whenever recipients change // Clean search result after recipient count change.