Search in sources :

Example 1 with SearchControl

use of org.opennms.features.vaadin.nodemaps.internal.gwt.client.ui.controls.search.SearchControl in project opennms by OpenNMS.

the class NodeMapWidget method addSearchControl.

private void addSearchControl() {
    LOG.info("NodeMapWidget.addSearchControl()");
    m_searchControl = new SearchControl(m_markerContainer, this, m_eventManager, m_componentTracker);
    final String id = m_searchControl.getElement().getId();
    if (id == null || "".equals(id)) {
        m_searchControl.getElement().setId("search-control");
    } else {
        LOG.info("NodeMapWidget.addSearchControl(): id = " + id);
    }
    final HTMLPanel mapParent = HTMLPanel.wrap(m_mapPanel.getParent().getElement());
    final Style searchStyle = m_searchControl.getElement().getStyle();
    searchStyle.setPosition(Position.ABSOLUTE);
    searchStyle.setTop(5, Unit.PX);
    searchStyle.setLeft(5, Unit.PX);
    searchStyle.setZIndex(1000);
    mapParent.add(m_searchControl);
}
Also used : Style(com.google.gwt.dom.client.Style) SearchControl(org.opennms.features.vaadin.nodemaps.internal.gwt.client.ui.controls.search.SearchControl) HTMLPanel(com.google.gwt.user.client.ui.HTMLPanel)

Aggregations

Style (com.google.gwt.dom.client.Style)1 HTMLPanel (com.google.gwt.user.client.ui.HTMLPanel)1 SearchControl (org.opennms.features.vaadin.nodemaps.internal.gwt.client.ui.controls.search.SearchControl)1