Browse Source

fixes #5478

svn changeset:14597/svn branch:6.4
tags/6.7.0.beta1
Matti Tahvonen 14 years ago
parent
commit
d3b7bcc4aa
1 changed files with 8 additions and 5 deletions
  1. 8
    5
      src/com/vaadin/terminal/gwt/client/ui/VScrollTable.java

+ 8
- 5
src/com/vaadin/terminal/gwt/client/ui/VScrollTable.java View File

@@ -278,6 +278,7 @@ public class VScrollTable extends FlowPanel implements Table, ScrollHandler,
private int dragmode;

private int multiselectmode;
private int tabIndex;

public VScrollTable() {
scrollBodyPanel.setStyleName(CLASSNAME + "-body-wrapper");
@@ -644,6 +645,9 @@ public class VScrollTable extends FlowPanel implements Table, ScrollHandler,
dragmode = uidl.hasAttribute("dragmode") ? uidl
.getIntAttribute("dragmode") : 0;

tabIndex = uidl.hasAttribute("tabindex") ? uidl
.getIntAttribute("tabindex") : 0;

multiselectmode = uidl.hasAttribute("multiselectmode") ? uidl
.getIntAttribute("multiselectmode") : MULTISELECT_MODE_DEFAULT;

@@ -4360,8 +4364,8 @@ public class VScrollTable extends FlowPanel implements Table, ScrollHandler,
}

/*
* setting width may affect wheter the component has scrollbars ->
* needs scrolling or not
* setting width may affect wheter the component has scrollbars -> needs
* scrolling or not
*/
setProperTabIndex();
}
@@ -5264,11 +5268,10 @@ public class VScrollTable extends FlowPanel implements Table, ScrollHandler,
*
*/
private void setProperTabIndex() {
if (!isFocusable()) {
if (tabIndex == 0 && !isFocusable()) {
scrollBodyPanel.getElement().setTabIndex(-1);
} else {
// TODO tabindex from UIDL
scrollBodyPanel.getElement().setTabIndex(0);
scrollBodyPanel.getElement().setTabIndex(tabIndex);
}
}
}

Loading…
Cancel
Save