summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorning.zhang2012-08-09 05:03:07 (EDT)
committer dgao2012-08-09 05:03:07 (EDT)
commit4c742001c67fa91b9d65216592fec55067b36187 (patch)
tree3ed9b49c17917d8112304fa235209425c959887f
parent6dc0339fff8d63efdae67f8f19bbbdf46816d29f (diff)
downloadorg.eclipse.birt-4c742001c67fa91b9d65216592fec55067b36187.zip
org.eclipse.birt-4c742001c67fa91b9d65216592fec55067b36187.tar.gz
org.eclipse.birt-4c742001c67fa91b9d65216592fec55067b36187.tar.bz2
Description of Issue: after changing the control's style from SWT.SINGLE to SWT.WRAP, the traverse function will be directed to the control itself and never traverse out.
Description of Resolution: added a traverseListener and tab key will traverse out. Since this is a url location, missing the tab character will not affect the functionality.
-rw-r--r--UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/ui/dialogs/HyperlinkBuilder.java12
1 files changed, 12 insertions, 0 deletions
diff --git a/UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/ui/dialogs/HyperlinkBuilder.java b/UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/ui/dialogs/HyperlinkBuilder.java
index 79e85a8..2b70868 100644
--- a/UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/ui/dialogs/HyperlinkBuilder.java
+++ b/UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/ui/dialogs/HyperlinkBuilder.java
@@ -94,6 +94,8 @@ import org.eclipse.swt.events.MouseEvent;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
+import org.eclipse.swt.events.TraverseEvent;
+import org.eclipse.swt.events.TraverseListener;
import org.eclipse.swt.graphics.Image;
import org.eclipse.swt.graphics.Point;
import org.eclipse.swt.layout.GridData;
@@ -687,6 +689,16 @@ public class HyperlinkBuilder extends BaseDialog
updateButtons( );
}
} );
+
+ locationEditor.addTraverseListener(new TraverseListener() {
+ public void keyTraversed(TraverseEvent e) {
+ if (e.detail == SWT.TRAVERSE_TAB_NEXT
+ || e.detail == SWT.TRAVERSE_TAB_PREVIOUS) {
+ e.doit = true;
+ }
+ }
+ });
+
Composite buttonArea = new Composite( displayArea, SWT.NONE );
buttonArea.setLayout( UIUtil.createGridLayoutWithoutMargin( 2, false ) );
buttonArea.setLayoutData( new GridData( ) );