summaryrefslogtreecommitdiffstats
path: root/bundles
diff options
context:
space:
mode:
authorSilenio Quarti <silenio>2005-04-29 20:38:57 +0000
committerSilenio Quarti <silenio>2005-04-29 20:38:57 +0000
commit93fc2f9583c0679730fc2c5e8b77194a0019d64d (patch)
treeeeb7edac9df2bb276e8ecef6cba2bc1993504c44 /bundles
parentc339f8c3bab9d0a1964d6d0a173b2dc4ae20e913 (diff)
downloadeclipse.platform.swt-93fc2f9583c0679730fc2c5e8b77194a0019d64d.tar.gz
eclipse.platform.swt-93fc2f9583c0679730fc2c5e8b77194a0019d64d.tar.xz
eclipse.platform.swt-93fc2f9583c0679730fc2c5e8b77194a0019d64d.zip
84632
Diffstat (limited to 'bundles')
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Table.java8
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Tree.java8
2 files changed, 12 insertions, 4 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Table.java b/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Table.java
index b3da20aecf..d3f9ecbb7f 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Table.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Table.java
@@ -2111,8 +2111,12 @@ void setFontStyle (Font font) {
*/
public void setHeaderVisible (boolean show) {
checkWidget ();
- int height = show ? headerHeight : 0;
- OS.SetDataBrowserListViewHeaderBtnHeight (handle, (short)height);
+ short [] height = new short [1];
+ OS.GetDataBrowserListViewHeaderBtnHeight (handle, height);
+ if ((height [0] != 0) != show) {
+ OS.SetDataBrowserListViewHeaderBtnHeight (handle, (short) (show ? headerHeight : 0));
+ resetVisibleRegion (handle);
+ }
}
/**
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Tree.java b/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Tree.java
index 5eaac5f552..2543881041 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Tree.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Tree.java
@@ -1710,8 +1710,12 @@ void setFontStyle (Font font) {
*/
public void setHeaderVisible (boolean show) {
checkWidget ();
- int height = show ? headerHeight : 0;
- OS.SetDataBrowserListViewHeaderBtnHeight (handle, (short)height);
+ short [] height = new short [1];
+ OS.GetDataBrowserListViewHeaderBtnHeight (handle, height);
+ if ((height [0] != 0) != show) {
+ OS.SetDataBrowserListViewHeaderBtnHeight (handle, (short) (show ? headerHeight : 0));
+ //resetVisibleRegion (handle);
+ }
}
void setItemHeight (Image image) {