Package com.google.gwt.search.client

Examples of com.google.gwt.search.client.SearchControlOptions


      }
    });
  }

  public void onApiLoad() {
    SearchControlOptions options = new SearchControlOptions();

    // We can use custom subclasses
    options.add(new GoogleCodeWebSearch(), ExpandMode.OPEN);

    // Or configure inline
    WebSearch ws = new WebSearch();
    ws.setSiteRestriction("ajaxian.com");
    ws.setUserDefinedLabel("Ajaxian");
    ws.setResultSetSize(ResultSetSize.SMALL);
    options.add(ws);
    options.add(new BookSearch());
    options.add(new NewsSearch());
    options.add(new VideoSearch(), ExpandMode.CLOSED);
    options.add(new ImageSearch());
    options.setKeepLabel(KeepLabel.SAVE);
    options.setLinkTarget(LinkTarget.BLANK);

    SearchControl searchControl = new SearchControl(options);
    searchControl.addKeepHandler(this);
    searchControl.addSearchResultsHandler(this);
    searchControl.addSearchStartingHandler(this);
View Full Code Here

TOP

Related Classes of com.google.gwt.search.client.SearchControlOptions

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.