Package bm.ui.def.view.listBrowser

Examples of bm.ui.def.view.listBrowser.SpeedOptionDef


            }
            final Vector speedOptions = viewDef.getSpeedOptions();
            final int speedOptionCount = speedOptions.size();
            for( int i = 0; i < speedOptionCount; i++ )
            {
                final SpeedOptionDef option = (SpeedOptionDef)
                        speedOptions.elementAt( i );
                final String optionText = option.getText();
                final int code = option.getCode();

                boolean active = true;
                if( option.getOnlyIf() != null  )
                {
                    active = ViewFactory.hasFlag( option.getOnlyIf() );
                }
                else if( option.getUnless() != null )
                {
                    active = !ViewFactory.hasFlag( option.getUnless() );
                }
                if( active )
                {
                    if( browser instanceof ListBrowserView )
                    {
                        browser.addSpeedOption(
                                optionText,
                                code
                        );
                    }
                    else
                    {
                        ViewFactory.loadIconStore( option.getIconSet() );
                        if( option.getIconSet() != null )
                        {
                            browser.addSpeedOption(
                                    code,
                                    option.getIconSet(),
                                    option.getIcon() != null ?
                                        option.getIcon().intValue() :
                                        i,
                                    option.getHelp()
                            );
                        }
                        else
                        {
                            browser.addSpeedOption(
                                    code,
                                    optionText,
                                    option.getHelp()
                            );
                        }
                    }
                }
            }
View Full Code Here

TOP

Related Classes of bm.ui.def.view.listBrowser.SpeedOptionDef

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.