title: ExtJS 4 - how to call function from a certain controller in different views
body: <p>I have a function which is described in one of my controllers. The function takes care of creating a form that I need to use in different cases, from different views. Is it possible and what is the way to call this function from the views that I need without adding the same code in each controller.</p>
  
  <p>Here is the code of the controller where I try to use a method from other controller:</p>
  
  <pre><code>Ext.define('MY.controller.EventsController', {
      extend: 'Ext.app.Controller',
      models: [
          'EventsRecord'],
  
      stores: [
          'Events'],
  
      views: [
          'EventsGrid'],
      refs: [{
          ref: 'EventsGrid',
          selector: 'CalendarEvent'
      }],
  
      init: function () {
          this.control({
              'CalendarEvent': {
                  afterEditFinish: this.askForNotify,
                  deleteEvent: this.deleteEvent,
                  calendarEditFunc: this.calendarEditFunc,
                  addCalendarEvent: this.addCalendarEvent,
                  itemclick: this.onSelectEnableBtn
              }
          })
  
      },
  </code></pre>
  
  <p>Here I try to use something like <code>var contr = Ext.getController('SomeController');</code>and..nothing..</p>
  
  <pre><code>askForNotify: function(editor, e) {...
  </code></pre>