title: How to save multi selection after left/right click in primefaces's datatable?
body: <p>I look at this <a href="http://www.primefaces.org/showcase/ui/datatableRowSelectionMultiple.jsf" rel="nofollow">example</a> and dont understand how to save selection after user click on one of already selected rows. So for example when user select 3 rows and make a click on one of this it will be show information about only one selected rows.</p>
  
  <p>Now I have DataTable with lazy loading and context menu like this:</p>
  
  <pre><code>                &lt;p:dataTable id="al_table" value="#{alarmTable.alarms}"
                      selection="#{alarmTable.selectedAlarm}" selectionMode="multiple"
                      var="alarm" resizableColumns="true" paginator="true" rows="50"
                      sortBy="#{alarm.alarmTimestamp}" sortOrder="descending"
                      paginatorTemplate="{CurrentPageReport}  {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown}"
                      rowsPerPageTemplate="25, 50, 75, 100" lazy="true"
                      style="table-layout: auto"&gt;
  
                      &lt;p:ajax event="rowDblselect" update=":form:display"
                          oncomplete="alarmDialog.show()" /&gt;
  </code></pre>
  
  <p>And all work very well except selection. With this behavior like now i can't do any action with multi rows at the same time, because it always lose selection. How to resolve this?</p>