Table dinamic and Listener

Hello:

I created a table and have created multiple instances of that table, the contents of each table is made dynamically.

And I need each of these instances MyTable Listener one from

I write the following:


Table MyTable extends Table
 ...........................
             private Prncipal app;
              public MyTable (main app)
               addListener ((ValueChangeListener) app);
 .............................

and Principal


   .....
    MyTable table_1=MyTable();
    MyTable table_2=MyTable();
   .....................
      TabSheet contenerTable =TabSheet();
   ............................. 

                                  contenerTable.addTab(table1,this.mensaje())
                                  contenerTable.addTab(table1,this.mensaje())
           ..................................
	public void valueChange(ValueChangeEvent event) {

		Property property = event.getProperty();
		if (property == myTable) {
			Item item = myTable.getItem(myTable.getValue());
			if (item != myFrom.getItemDataSource()) {
				myFrom.setItemDataSource(item);
			}
		}
		
         ..............

when I add the tab, only the latest instance of the table listening?

eg

    contenerTable.addTab(table1,this.mensaje())
    contenerTable.addTab(table2,this.mensaje())

TabSheet


   Table_1                       Table_2

  selected click table_1  not work
  selected click table_2  yes work

  close Tab table_2()

  Table_1
  selected click table_1 yes work

the question can have multiple instances in vaadin and each listen to the same application or do I pass the form instance to the table
to work?

in advance thank you very much