Skip to content

Commit

Permalink
Fix #164 [skip ci]
Browse files Browse the repository at this point in the history
  • Loading branch information
hmiguim committed Sep 11, 2019
1 parent 68681d6 commit 8014fe1
Showing 1 changed file with 8 additions and 33 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,6 @@
import com.databasepreservation.main.common.shared.client.tools.ViewerStringUtils;
import com.databasepreservation.main.common.shared.client.widgets.wcag.AccessibleFocusPanel;
import com.google.gwt.core.client.GWT;
import com.google.gwt.event.dom.client.ChangeEvent;
import com.google.gwt.event.dom.client.ChangeHandler;
import com.google.gwt.event.dom.client.ClickEvent;
import com.google.gwt.event.dom.client.ClickHandler;
import com.google.gwt.event.dom.client.KeyUpEvent;
import com.google.gwt.event.dom.client.KeyUpHandler;
import com.google.gwt.uibinder.client.UiBinder;
import com.google.gwt.uibinder.client.UiField;
import com.google.gwt.user.client.ui.Composite;
Expand Down Expand Up @@ -91,13 +85,11 @@ private void init(ViewerMetadata viewerMetadata) {

FlowPanel tablesItems = new FlowPanel();
for (ViewerTable table : schema.getTables()) {
if (!table.getName().startsWith("VIEW_")) {
SidebarHyperlink sidebarHyperlink = new SidebarHyperlink(table.getName(),
HistoryManager.linkToCreateSIARD(HistoryManager.ROUTE_WIZARD_TABLES_COLUMNS, TABLE_LINK, schema.getUUID(), table.getUUID()));
sidebarHyperlink.addIcon(FontAwesomeIconManager.TABLE).setH6().setIndent3();
list.put(table.getName(), sidebarHyperlink);
tablesItems.add(sidebarHyperlink);
}
SidebarHyperlink sidebarHyperlink = new SidebarHyperlink(table.getName(), HistoryManager.linkToCreateSIARD(
HistoryManager.ROUTE_WIZARD_TABLES_COLUMNS, TABLE_LINK, schema.getUUID(), table.getUUID()));
sidebarHyperlink.addIcon(FontAwesomeIconManager.TABLE).setH6().setIndent3();
list.put(table.getName(), sidebarHyperlink);
tablesItems.add(sidebarHyperlink);
}
createSubItem(tables, tablesItems);

Expand Down Expand Up @@ -149,26 +141,11 @@ public void selectNone() {
private void searchInit() {
searchInputBox.getElement().setPropertyString("placeholder", messages.menusidebar_filterSidebar());

searchInputBox.addChangeHandler(new ChangeHandler() {
@Override
public void onChange(ChangeEvent event) {
doSearch();
}
});
searchInputBox.addChangeHandler(event -> doSearch());

searchInputBox.addKeyUpHandler(new KeyUpHandler() {
@Override
public void onKeyUp(KeyUpEvent event) {
doSearch();
}
});
searchInputBox.addKeyUpHandler(event -> doSearch());

searchInputButton.addClickHandler(new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
doSearch();
}
});
searchInputButton.addClickHandler(event -> doSearch());
}

private void doSearch() {
Expand Down Expand Up @@ -210,9 +187,7 @@ private void doSearch() {
sb.setVisible(false);
disclosurePanel.setVisible(false);
}

}

} else {
widget.setVisible(true);
}
Expand Down

0 comments on commit 8014fe1

Please sign in to comment.