Package bm.db

Examples of bm.db.ScrollSet


        final ProgressEvent pe = this.pe;

        onBeforeFillPage();

        list.deleteAll();
        final ScrollSet set = this.set;
        if( set != null )
        {
            try
            {
                set.openSource();
                final int speed = speedOptionsAction.size();
                for( int i = 0; i < speed; i++ )
                {
                    list.append(
                            ResourceManager.getResource( (String)
                                    speedOptionsText.elementAt( i )
                            ),
                            null
                    );
                }
                if( page > 0 )
                {
                    list.append(
                            ResourceManager.getResource( "listBrowserView.prevPage" ),
                            null
                    );
                }
                final int pageSize = this.pageSize;
                int count = 0;
                int index = page * pageSize;
                pe.setValue( new Integer( 0 ) );
                pe.dispatch();
                //noinspection MethodCallInLoopCondition
                while( count < pageSize && index < size )
                {
                    final String label = buildLabel( set.getRowAt( index ) );
                    if( label != null )
                    {
                        list.append( label, null );
                        count++;
                    }
                    index++;
                    pe.increment();
                    pe.dispatch();
                }
                if( page < (pageCount -1) )
                {
                    list.append(
                            ResourceManager.getResource( "listBrowserView.nextPage" ),
                            null
                    );
                }
                if( !DeviceInfo.getDeviceInfo().hasListFontBug() )
                {
                    final int itemCount = list.size();
                    for( int i = 0; i < itemCount; i++ )
                    {
                        list.setFont( i, Util.SMALL_FONT );
                    }
                }
            }
            finally
            {
                set.closeSource();
            }
        }
        onAfterFillPage();
        show();
    }
View Full Code Here


    public Row getSelected()
            throws DBException,
                   RecordStoreFullException,
                   RSException
    {
        final ScrollSet scrollSet = this.set;
        if( scrollSet != null )
        {
            return scrollSet.getRowAt( getSelectedIndex() );
        }
        else
        {
            return null;
        }
View Full Code Here

TOP

Related Classes of bm.db.ScrollSet

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.