Search in sources :

Example 1 with SwitchingAlbumsView

use of org.karnak.frontend.kheops.SwitchingAlbumsView in project karnak by OsiriX-Foundation.

the class FormSTOW method init.

public void init(Binder<DestinationEntity> binder, ButtonSaveDeleteCancel buttonSaveDeleteCancel) {
    setSizeFull();
    this.binder = binder;
    this.deIdentificationComponent.init(this.binder);
    this.filterBySOPClassesForm.init(this.binder);
    this.destinationCondition.init(binder);
    notificationComponent.init(binder);
    transferSyntaxComponent.init(this.binder);
    transcodeOnlyUncompressedComponent.init(this.binder);
    this.description = new TextField("Description");
    this.url = new TextField("URL");
    this.urlCredentials = new TextField("URL credentials");
    this.headers = new TextArea("Headers");
    this.switchingAlbumsView = new SwitchingAlbumsView();
    this.activate = new Checkbox("Enable destination");
    // Define layout
    VerticalLayout destinationLayout = new VerticalLayout(UIS.setWidthFull(new HorizontalLayout(description)), destinationCondition, UIS.setWidthFull(new HorizontalLayout(url, urlCredentials)), UIS.setWidthFull(headers));
    VerticalLayout transferLayout = new VerticalLayout(new HorizontalLayout(transferSyntaxComponent, transcodeOnlyUncompressedComponent));
    VerticalLayout activateLayout = new VerticalLayout(activate);
    VerticalLayout switchingLayout = new VerticalLayout(switchingAlbumsView);
    // Set padding
    transferLayout.setPadding(true);
    destinationLayout.setPadding(true);
    activateLayout.setPadding(true);
    activateLayout.setPadding(true);
    // Add components
    add(UIS.setWidthFull(new BoxShadowComponent(UIS.setWidthFull(destinationLayout))));
    add(UIS.setWidthFull(new BoxShadowComponent(UIS.setWidthFull(transferLayout))));
    add(UIS.setWidthFull(new BoxShadowComponent(UIS.setWidthFull(notificationComponent))));
    add(UIS.setWidthFull(new BoxShadowComponent(UIS.setWidthFull(deIdentificationComponent))));
    add(UIS.setWidthFull(new BoxShadowComponent(UIS.setWidthFull(filterBySOPClassesForm))));
    add(UIS.setWidthFull(new BoxShadowComponent(UIS.setWidthFull(switchingLayout))));
    add(UIS.setWidthFull(new BoxShadowComponent(UIS.setWidthFull(activateLayout))));
    add(UIS.setWidthFull(buttonSaveDeleteCancel));
    setElements();
    setBinder();
}
Also used : TextArea(com.vaadin.flow.component.textfield.TextArea) Checkbox(com.vaadin.flow.component.checkbox.Checkbox) TextField(com.vaadin.flow.component.textfield.TextField) VerticalLayout(com.vaadin.flow.component.orderedlayout.VerticalLayout) BoxShadowComponent(org.karnak.frontend.component.BoxShadowComponent) SwitchingAlbumsView(org.karnak.frontend.kheops.SwitchingAlbumsView) HorizontalLayout(com.vaadin.flow.component.orderedlayout.HorizontalLayout)

Aggregations

Checkbox (com.vaadin.flow.component.checkbox.Checkbox)1 HorizontalLayout (com.vaadin.flow.component.orderedlayout.HorizontalLayout)1 VerticalLayout (com.vaadin.flow.component.orderedlayout.VerticalLayout)1 TextArea (com.vaadin.flow.component.textfield.TextArea)1 TextField (com.vaadin.flow.component.textfield.TextField)1 BoxShadowComponent (org.karnak.frontend.component.BoxShadowComponent)1 SwitchingAlbumsView (org.karnak.frontend.kheops.SwitchingAlbumsView)1