Improve UX part framework
[lgpl/argeo-commons.git] / swt / org.argeo.cms.swt / src / org / argeo / cms / swt / widgets / SwtTableView.java
index b136f36e16c73cb03ba615160a453f5c4fa14ff3..a58a5a47856aebe5350b47f9879227b3f1255103 100644 (file)
@@ -22,10 +22,10 @@ public class SwtTableView<INPUT, T> extends AbstractSwtView<INPUT, T> {
        private CmsSwtTheme theme;
 
        public SwtTableView(Composite parent, int style, TabularPart<INPUT, T> tabularPart) {
-               super(parent, style, tabularPart);
+               super(parent, tabularPart);
                theme = CmsSwtUtils.getCmsTheme(parent);
 
-               table = new Table(this, SWT.VIRTUAL | SWT.BORDER);
+               table = new Table(this, SWT.VIRTUAL | style);
                table.setLinesVisible(true);
                table.setLayoutData(CmsSwtUtils.fillAll());
 
@@ -75,6 +75,11 @@ public class SwtTableView<INPUT, T> extends AbstractSwtView<INPUT, T> {
                }
        }
 
+       @Override
+       public void notifyItemCountChange() {
+               table.setItemCount(tabularPart.getItemCount());
+       }
+
        protected Table getTable() {
                return table;
        }