Package com.google.gwt.sample.contacts.client.presenter

Examples of com.google.gwt.sample.contacts.client.presenter.Presenter


  }

  private void doEditContact(String id) {

    History.newItem("edit", false);
    Presenter presenter = new EditContactPresenter(rpcService, eventBus, new EditContactView(), id);
    presenter.go(container);
  }
View Full Code Here


  private void doShowAddress(Contact contact) {

    History.newItem("address");

    Presenter presenter = new ContactAddressPresenter(rpcService, eventBus, new ContactAddressView(), contact);
    presenter.go(container);
  }
View Full Code Here

  public void onValueChange(ValueChangeEvent<String> event) {

    String token = event.getValue();

    if (token != null) {
      Presenter presenter = null;

      if (token.equals("list")) {
        presenter = new ContactsPresenter(rpcService, eventBus, new ContactsView());
      } else if (token.equals("add")) {
        presenter = new EditContactPresenter(rpcService, eventBus, new EditContactView());
      } else if (token.equals("edit")) {
        presenter = new EditContactPresenter(rpcService, eventBus, new EditContactView());
      } else if (token.equals("address")) {
        // presenter = new EditContactPresenter(rpcService, eventBus, new EditContactView());
      }

      if (presenter != null) {
        presenter.go(container);
      }
    }
  }
View Full Code Here

    History.newItem("add");
  }
 
  private void doEditContact(String id) {
    History.newItem("edit", false);
    Presenter presenter = new EditContactPresenter(rpcService, eventBus, new EditContactView(), id);
    presenter.go(container);
  }
View Full Code Here

  public void onValueChange(ValueChangeEvent<String> event) {
    String token = event.getValue();
   
    if (token != null) {
      Presenter presenter = null;

      if (token.equals("list")) {
        presenter = new ContactsPresenter(rpcService, eventBus, new ContactsView());
      }
      else if (token.equals("add")) {
        presenter = new EditContactPresenter(rpcService, eventBus, new EditContactView());
      }
      else if (token.equals("edit")) {
        presenter = new EditContactPresenter(rpcService, eventBus, new EditContactView());
      }
     
      if (presenter != null) {
        presenter.go(container);
      }
    }
  }
View Full Code Here

TOP

Related Classes of com.google.gwt.sample.contacts.client.presenter.Presenter

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.