title: PrimeFaces TabView - index of closing tab inside confirm dialog
body: <p>Is it possible in PrimeFaces 3.5 to open confirm dialog while closing tab, which was dynamically genereted? And while closing this tab the dialog should say which particular tab i want to close.</p>
  
  <p>I've tried to use<br /><code>&lt;p:ajax event="onTabClose" listener="#{myBean.closeTab}" /&gt;</code> - with this expression I can get the closing tab inside my listener and also I can open dialog using <code>onstart=myDialog.show()</code> inside that expression but always when I click 'x' on tab it will close regardless the confirm dialog.</p>
  
  <p>So I've found <code>&lt;p:tabView onTabClose=""&gt;</code> - here I can do what I want using <code>return confirm('Are you sure?')</code> (Can I create my own dialog here that will return 'true/false' and waiting for clicking 'yes/no'?).</p>
  
  <p>But the problem is that I can't get the closing tab index regardless which metod I choose to show dialog.</p>
  
  <p>When I use (tabList is a <code>List&lt;Integer&gt;</code>):</p>
  
  <pre><code>&lt;p:tabView var="tab" value="#{myBean.tabList}" 
      onTabClose="return confirm('You are closing tab number #{tab}')" /&gt;
  
      &lt;p:tab title="#{tab}" closable="true"&gt;
          &lt;h:outputText value="#{Tab number #{tab}}" /&gt;
      &lt;/p:tab&gt;
  
  &lt;/p:tabView&gt;
  </code></pre>
  
  <p>everything are working correctly without dialog. It always show tab number 1!</p>
  
  <p>So... is it possible to fix that? Or is there any other solution for this issue?</p>