Package com.github.gwtbootstrap.client.ui

Examples of com.github.gwtbootstrap.client.ui.CheckBox


            public void onClick( ClickEvent event ) {
                hide();
            }
        } );

        CheckBox chkOnlyDisplayDSLConditions = new CheckBox();
        chkOnlyDisplayDSLConditions.setText( GuidedRuleEditorResources.CONSTANTS.OnlyDisplayDSLActions() );
        chkOnlyDisplayDSLConditions.setValue( bOnlyShowDSLConditions );
        chkOnlyDisplayDSLConditions.addValueChangeHandler( new ValueChangeHandler<Boolean>() {

            public void onValueChange( ValueChangeEvent<Boolean> event ) {
                bOnlyShowDSLConditions = event.getValue();
                choicesPanel.setWidget( makeChoicesListBox() );
            }
View Full Code Here


            public void onClick( ClickEvent event ) {
                hide();
            }
        } );

        CheckBox chkOnlyDisplayDSLConditions = new CheckBox();
        chkOnlyDisplayDSLConditions.setText( GuidedRuleEditorResources.CONSTANTS.OnlyDisplayDSLConditions() );
        chkOnlyDisplayDSLConditions.setValue( bOnlyShowDSLConditions );
        chkOnlyDisplayDSLConditions.addValueChangeHandler( new ValueChangeHandler<Boolean>() {

            public void onValueChange( ValueChangeEvent<Boolean> event ) {
                bOnlyShowDSLConditions = event.getValue();
                choicesPanel.setWidget( makeChoicesListBox() );
            }
View Full Code Here

            }
        } );

        //DSL might be prohibited (e.g. editing a DRL file. Only DSLR files can contain DSL)
        if ( ruleModeller.isDSLEnabled() ) {
            CheckBox chkOnlyDisplayDSLConditions = new CheckBox();
            chkOnlyDisplayDSLConditions.setText( GuidedRuleEditorResources.CONSTANTS.OnlyDisplayDSLConditions() );
            chkOnlyDisplayDSLConditions.setValue( onlyShowDSLStatements );
            chkOnlyDisplayDSLConditions.addValueChangeHandler( new ValueChangeHandler<Boolean>() {

                public void onValueChange( ValueChangeEvent<Boolean> event ) {
                    onlyShowDSLStatements = event.getValue();
                    choicesPanel.setWidget( makeChoicesListBox() );
                }
View Full Code Here

        return horiz;
    }

    private Widget checkBoxEditor( final RuleAttribute at,
                                   final boolean isReadOnly ) {
        final CheckBox box = new CheckBox();
        box.setEnabled( !isReadOnly );
        if ( at.getValue() == null || at.getValue().isEmpty() ) {
            box.setValue( false );
            at.setValue( FALSE_VALUE );
        } else {
            box.setValue( ( at.getValue().equals( TRUE_VALUE ) ) );
        }

        box.addClickHandler( new ClickHandler() {
            public void onClick( ClickEvent event ) {
                at.setValue( ( box.getValue() ) ? TRUE_VALUE : FALSE_VALUE );
            }
        } );
        return box;
    }
View Full Code Here

            }
        } );

        //DSL might be prohibited (e.g. editing a DRL file. Only DSLR files can contain DSL)
        if ( ruleModeller.isDSLEnabled() ) {
            CheckBox chkOnlyDisplayDSLConditions = new CheckBox();
            chkOnlyDisplayDSLConditions.setText( GuidedRuleEditorResources.CONSTANTS.OnlyDisplayDSLActions() );
            chkOnlyDisplayDSLConditions.setValue( onlyShowDSLStatements );
            chkOnlyDisplayDSLConditions.addValueChangeHandler( new ValueChangeHandler<Boolean>() {

                public void onValueChange( ValueChangeEvent<Boolean> event ) {
                    onlyShowDSLStatements = event.getValue();
                    choicesPanel.setWidget( makeChoicesListBox() );
                }
View Full Code Here

    }

    private Widget doInsertLogical() {
        HorizontalPanel hp = new HorizontalPanel();

        final CheckBox cb = new CheckBox();
        cb.setValue( editingCol.isInsertLogical() );
        cb.setText( "" );
        cb.setEnabled( !isReadOnly );
        if ( !isReadOnly ) {
            cb.addClickHandler( new ClickHandler() {
                public void onClick( ClickEvent arg0 ) {
                    if ( oracle.isGlobalVariable( editingCol.getBoundName() ) ) {
                        cb.setEnabled( false );
                        editingCol.setInsertLogical( false );
                    } else {
                        editingCol.setInsertLogical( cb.getValue() );
                    }
                }
            } );
        }
        hp.add( cb );
View Full Code Here

    }

    private Widget doUpdate() {
        HorizontalPanel hp = new HorizontalPanel();

        final CheckBox cb = new CheckBox();
        cb.setValue( editingCol.isUpdate() );
        cb.setText( "" );
        cb.setEnabled( !isReadOnly );
        if ( !isReadOnly ) {
            cb.addClickHandler( new ClickHandler() {
                public void onClick( ClickEvent arg0 ) {
                    if ( oracle.isGlobalVariable( editingCol.getBoundName() ) ) {
                        cb.setEnabled( false );
                        editingCol.setUpdate( false );
                    } else {
                        editingCol.setUpdate( cb.getValue() );
                    }
                }
            } );
        }
        hp.add( cb );
View Full Code Here

    }

    private Widget doUpdate() {
        HorizontalPanel hp = new HorizontalPanel();

        final CheckBox cb = new CheckBox();
        cb.setValue( editingCol.isUpdate() );
        cb.setText( "" );
        cb.setEnabled( !isReadOnly );
        if ( !isReadOnly ) {
            cb.addClickHandler( new ClickHandler() {
                public void onClick( ClickEvent arg0 ) {
                    if ( oracle.isGlobalVariable( editingCol.getBoundName() ) ) {
                        cb.setEnabled( false );
                        editingCol.setUpdate( false );
                    } else {
                        editingCol.setUpdate( cb.getValue() );
                    }
                }
            } );
        }
        hp.add( cb );
View Full Code Here

    }

    private Widget doInsertLogical() {
        HorizontalPanel hp = new HorizontalPanel();

        final CheckBox cb = new CheckBox();
        cb.setValue( editingCol.isInsertLogical() );
        cb.setText( "" );
        cb.setEnabled( !isReadOnly );
        if ( !isReadOnly ) {
            cb.addClickHandler( new ClickHandler() {
                public void onClick( ClickEvent arg0 ) {
                    if ( oracle.isGlobalVariable( editingCol.getBoundName() ) ) {
                        cb.setEnabled( false );
                        editingCol.setInsertLogical( false );
                    } else {
                        editingCol.setInsertLogical( cb.getValue() );
                    }
                }
            } );
        }
        hp.add( cb );
View Full Code Here

        } else if ( attributeName.equals( RuleAttributeWidget.NO_LOOP_ATTR )
                || attributeName.equals( RuleAttributeWidget.LOCK_ON_ACTIVE_ATTR )
                || attributeName.equals( RuleAttributeWidget.AUTO_FOCUS_ATTR )
                || attributeName.equals( RuleAttributeWidget.ENABLED_ATTR )
                || attributeName.equals( GuidedDecisionTable52.NEGATE_RULE_ATTR ) ) {
            final CheckBox cb = new CheckBox();
            if ( ac.getDefaultValue() == null ) {
                ac.setDefaultValue( new DTCellValue52( Boolean.FALSE ) );
            } else {
                assertBooleanDefaultValue( ac.getDefaultValue() );
            }
            final DTCellValue52 defaultValue = ac.getDefaultValue();
            final Boolean booleanValue = defaultValue.getBooleanValue();
            cb.setEnabled( !isReadOnly );
            if ( booleanValue == null ) {
                cb.setValue( false );
                defaultValue.setBooleanValue( Boolean.FALSE );
            } else {
                cb.setValue( booleanValue );
            }

            cb.addClickHandler( new ClickHandler() {
                public void onClick( ClickEvent event ) {
                    defaultValue.setBooleanValue( cb.getValue() );
                }
            } );
            editor = cb;

        } else if ( attributeName.equals( RuleAttributeWidget.DATE_EFFECTIVE_ATTR )
View Full Code Here

TOP

Related Classes of com.github.gwtbootstrap.client.ui.CheckBox

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.