Skip to content

Instantly share code, notes, and snippets.

@jasonlemay
Created November 3, 2015 16:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jasonlemay/9ee0009e1bdea24f2a53 to your computer and use it in GitHub Desktop.
Save jasonlemay/9ee0009e1bdea24f2a53 to your computer and use it in GitHub Desktop.
Chosen Styling - HomeView.java
package com.arcbees.chosenstyling.client.application.home;
// Some imports
public class HomeView extends ViewImpl implements HomePresenter.MyView {
// Some code
private static final ChosenDarkResources CHOSEN_RESOURCES_DARK = GWT.create(ChosenDarkResources.class);
@UiField(provided = true)
ChosenListBox singleChosenDark;
@UiField(provided = true)
MultipleChosenValueListBox<Choices> multipleValuesDark;
@Inject
HomeView(Binder uiBinder) {
ChosenOptions chosenOptionsDark = new ChosenOptions();
chosenOptionsDark.setResources(CHOSEN_RESOURCES_DARK);
// If your widget is a single Chosen widget
singleChosenDark = new ChosenListBox(chosenOptionsDark);
// Or if it's a multiple Chosen widget
multipleValuesDark = new MultipleChosenValueListBox<>(new ChoiceRenderer(), chosenOptionsDark);
initWidget(uiBinder.createAndBindUi(this));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment