use of games.rednblack.editor.event.CheckBoxChangeListener in project HyperLap2D by rednblackgames.
the class UIFilterMenu method addFilter.
public void addFilter(IAbstractResourceFilter filter) {
VisCheckBox checkBox = StandardWidgetsFactory.createCheckBox(filter.name);
checkBox.setChecked(filter.isActive());
checkBox.addListener(new CheckBoxChangeListener(UIResourcesTabMediator.CHANGE_ACTIVE_FILTER, filter.id));
add(checkBox).padTop(2).padBottom(2).row();
pack();
}
use of games.rednblack.editor.event.CheckBoxChangeListener in project HyperLap2D by rednblackgames.
the class UIGridBox method init.
private void init() {
addSeparator(true).padRight(13).padLeft(13);
lockLinesCheckBox = StandardWidgetsFactory.createCheckBox("Lock lines");
lockLinesCheckBox.addListener(new CheckBoxChangeListener(LOCK_LINES_CHECKBOX_FIELD_UPDATED));
add(lockLinesCheckBox);
addSeparator(true).padRight(13).padLeft(13);
VisLabel lbl = new VisLabel("Grid Size:");
add(lbl).padRight(4);
gridSizeTextField = StandardWidgetsFactory.createValidableTextField("light", new Validators.GreaterThanValidator(0));
gridSizeTextField.addListener(new KeyboardListener(GRID_SIZE_TEXT_FIELD_UPDATED));
gridSizeTextField.setAlignment(Align.center);
add(gridSizeTextField).width(30);
}
use of games.rednblack.editor.event.CheckBoxChangeListener in project HyperLap2D by rednblackgames.
the class UISceneProperties method setListeners.
private void setListeners() {
physicsEnabledCheckBox.addListener(new CheckBoxChangeListener(getUpdateEventName()));
gravityXTextField.addListener(new KeyboardListener(getUpdateEventName()));
gravityYTextField.addListener(new KeyboardListener(getUpdateEventName()));
sleepVelocityTextField.addListener(new KeyboardListener(getUpdateEventName()));
enableLightsCheckBox.addListener(new CheckBoxChangeListener(getUpdateEventName()));
enablePseudo3DLightsCheckBox.addListener(new CheckBoxChangeListener(getUpdateEventName()));
blurNumTextField.addListener(new KeyboardListener(getUpdateEventName()));
directionalRays.addListener(new NumberSelectorOverlapListener(getUpdateEventName()));
directionalDegreeTextField.addListener(new KeyboardListener(getUpdateEventName()));
directionalHeightTextField.addListener(new KeyboardListener(getUpdateEventName()));
lightTypeBox.addListener(new SelectBoxChangeListener(getUpdateEventName()));
lightTypeBox.addListener(new ChangeListener() {
@Override
public void changed(ChangeEvent event, Actor actor) {
updateDisabled();
}
});
ambientColorComponent.addListener(new ClickListener() {
public void touchUp(InputEvent event, float x, float y, int pointer, int button) {
super.touchUp(event, x, y, pointer, button);
facade.sendNotification(AMBIENT_COLOR_BUTTON_CLICKED, ambientColorComponent.getColorValue(), null);
}
});
directionalLightColor.addListener(new ClickListener() {
public void touchUp(InputEvent event, float x, float y, int pointer, int button) {
super.touchUp(event, x, y, pointer, button);
if (lightTypeBox.getSelected().equals("DIRECTIONAL"))
facade.sendNotification(DIRECTIONAL_COLOR_BUTTON_CLICKED, directionalLightColor.getColorValue(), null);
}
});
}
use of games.rednblack.editor.event.CheckBoxChangeListener in project HyperLap2D by rednblackgames.
the class UISensorProperties method initListeners.
private void initListeners() {
sensorBottom.addListener(new CheckBoxChangeListener(getUpdateEventName()));
sensorLeft.addListener(new CheckBoxChangeListener(getUpdateEventName()));
sensorRight.addListener(new CheckBoxChangeListener(getUpdateEventName()));
sensorTop.addListener(new CheckBoxChangeListener(getUpdateEventName()));
sensorSpanPercentBottom.addListener(new KeyboardListener(getUpdateEventName()));
sensorSpanPercentLeft.addListener(new KeyboardListener(getUpdateEventName()));
sensorSpanPercentRight.addListener(new KeyboardListener(getUpdateEventName()));
sensorSpanPercentTop.addListener(new KeyboardListener(getUpdateEventName()));
}
use of games.rednblack.editor.event.CheckBoxChangeListener in project HyperLap2D by rednblackgames.
the class UILightItemProperties method setListeners.
private void setListeners() {
isStaticCheckBox.addListener(new CheckBoxChangeListener(getUpdateEventName()));
isXRayCheckBox.addListener(new CheckBoxChangeListener(getUpdateEventName()));
rayCountSelector.addListener(new NumberSelectorOverlapListener(getUpdateEventName()));
pointLightRadiusField.addListener(new KeyboardListener(getUpdateEventName()));
coneInnerAngleField.addListener(new KeyboardListener(getUpdateEventName()));
coneDistanceField.addListener(new KeyboardListener(getUpdateEventName()));
softnessLengthField.addListener(new KeyboardListener(getUpdateEventName()));
heightField.addListener(new KeyboardListener(getUpdateEventName()));
intensityField.addListener(new KeyboardListener(getUpdateEventName()));
coneDirectionField.addListener(new KeyboardListener(getUpdateEventName()));
isSoftCheckBox.addListener(new CheckBoxChangeListener(getUpdateEventName()));
isActiveCheckBox.addListener(new CheckBoxChangeListener(getUpdateEventName()));
}
Aggregations