Skip to content

stephenh/tessell

Repository files navigation

Join the chat at https://gitter.im/stephenh/tessell

See tessell.org.

Eclipse Setup

After checking Tessell out of git, there are two main projects, tessell-user and tessell-dev.

tessell-user uses annotation processing to generate some event classes, which is unfortunately kind of janky to setup in Eclipse.

  1. Install the Gradle Eclipse plugin
  • This is not strictly required, but the checked-in .classpath/.factorypath files assume this setup
  1. Go to Window / Preferences / Java / Build Path / Classpath Variables
  • Add GRADLE_REPO has /yourHomeDir/.gradle/caches/modules-2
  1. Import tessell-user and tessell-dev into Eclipse
  • Gradle should download all the dependencies and put them onto the Gradle classpath container
  • However, Eclipse needs to be "kicked" to see the annotation processor jar is now available
  1. Close tessell-user
  2. Open tessell-user
  3. Clean tessell-user
  4. Hopefully you have no build errors

Todo

  • Add @Place annotation
    • Take name of presenter
    • Any constructor parameters--how to denote application-level vs. request-level?
  • Figure out cross-presenter transitions
    • Event bus doesn't make sense--these aren't global things
    • Have Slot listen to presenter events?
  • Support 2nd generation Presenter interfaces via event hook hints in ui.xml file
  • form disable on ServerCall
  • indicator on ServerCall
  • Pre-fill the handler (optional);
  • doLogin.call(user, pass);
  • HasDispatchAsync to ServerCall cstr
  • Out-of-the-box local storage integration (probably via changes to dtonator, use AutoBeans)
  • PropertyGroup copies are not deep

Notes

  • ResourcesGenerator assumes a global namespace of image/CSS files, even if you use subdirectories. It also assumes all image/CSS files are below the packageName you pass to it.

Binder DSL Ideas

  • SetActions

    binder.when(...).is(true).set(//
      textOf(...).toOrElse("", ""), // toOrElse returns SetAction
      styleOf(...).to(bz.active())); // to returns SetAction
    
    binder.on(keyPressOf(...)).then(execute(command));
    binder.on(clickOf(...)).then(toggle(button));
    binder.on(clickOf(...)).set(SetAction...);
    binder.on(blurOf(...)).set(SetAction...);
    
    // or, for more unique static imports
    binder.on(blurOf(...), thenSet(textOf(...).to(asdf)));
    
    // string actions
    binder.when(condition, action1, action2);
    // e.g.
    binder.when(value, is(true), show(this), hide(that));
    
  • Non-trivial omponents, e.g.

    <foo:Form>
      <fields>
        <foo:TextLine />
      </fields>
      <blah>
        <foo:Bar />
      </blah>
    </foo:Form>
    

    Goes to:

    form.addField(textLine1);
    form.setBlah(...);
    

    Any HTML implicitly becomes an HTMLPanel, e.g.:

    <foo:Form>
      <blah>
        <p>
          <foo:Bar />
        </p>
      </blah>
    </foo:Form>
    

    Goes to:

    form.setBlah(htmlPanel, List<Bar> bars);
    

About

GWT model, presenter, view framework

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages