changeset 1540:7fe83fb6c034 2.2.6-b10

Automated merge with ssh://jfxsrc.us.oracle.com//javafx/2.2.6/MASTER/jfx/rt
author kcr
date Tue, 15 Jan 2013 15:20:55 -0800
parents 1eaddabaeb19 24393db87162
children b538db422824 b6ca58b147da
files
diffstat 3 files changed, 19 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/javafx-ui-charts/src/javafx/scene/chart/PieChart.java	Mon Jan 14 11:05:36 2013 -0800
+++ b/javafx-ui-charts/src/javafx/scene/chart/PieChart.java	Tue Jan 15 15:20:55 2013 -0800
@@ -309,6 +309,12 @@
     }
 
     // -------------- METHODS --------------------------------------------------
+
+    @Override public void requestLayout() {
+        super.requestLayout();
+        // RT-22986 PieChart legend resize issue
+        if (legend != null) legend.requestLayout();
+    }
     
     private void dataNameChanged(Data item) {
 
--- a/javafx-ui-controls/src/com/sun/javafx/scene/control/skin/TableColumnHeader.java	Mon Jan 14 11:05:36 2013 -0800
+++ b/javafx-ui-controls/src/com/sun/javafx/scene/control/skin/TableColumnHeader.java	Tue Jan 15 15:20:55 2013 -0800
@@ -254,6 +254,7 @@
     private boolean isSortColumn;
     
     private boolean isSizeDirty = false;
+    private boolean sortOrderDotsDirty = false;
     
     boolean isLastVisibleColumn = false;
     private int columnIndex = -1;
@@ -437,6 +438,7 @@
                 sortArrowGrid.add(sortOrderDots, 1, dotsRow);
 
                 updateSortOrderDots(sortPos);
+                sortOrderDotsDirty = true;
             } else {
                 // only show the arrow
                 sortArrowGrid.add(arrow, 1, 1);
@@ -634,6 +636,9 @@
         if (isSizeDirty) {
             resize(getTableColumn().getWidth(), getHeight());
             isSizeDirty = false;
+        } else if (sortOrderDotsDirty) {
+            updateSortOrderDots(sortPos);
+            sortOrderDotsDirty = false;
         }
         
         double sortWidth = 0;
--- a/javafx-ui-controls/src/javafx/scene/control/TableView.java	Mon Jan 14 11:05:36 2013 -0800
+++ b/javafx-ui-controls/src/javafx/scene/control/TableView.java	Tue Jan 15 15:20:55 2013 -0800
@@ -759,16 +759,21 @@
             
             // Fix for RT-15194: Need to remove removed columns from the 
             // sortOrder list.
+            List<TableColumn> toRemove = new ArrayList<TableColumn>();
             while (c.next()) {
                 removeColumnsListener(c.getRemoved(), weakColumnsObserver);
                 addColumnsListener(c.getAddedSubList(), weakColumnsObserver);
                 
                 if (c.wasRemoved()) {
-                    for (int i = 0; i < c.getRemovedSize(); i++) {
-                        getSortOrder().remove(c.getRemoved().get(i));
-                    }
+                    toRemove.addAll(c.getRemoved());
+                }
+                
+                if (c.wasAdded()) {
+                    toRemove.removeAll(c.getAddedSubList());
                 }
             }
+            
+            sortOrder.removeAll(toRemove);
         }
     };