Advanced UI/src/com/samples/toolkit/ui/component/BitmapSliderField.java
/**
     * Cuts up the background image and margins you provide
     * to make the left, center, and right bitmaps
     */
Cuts up the background image and margins you provide
to make the left, center, and right bitmaps
Cuts up the background image and margins you provide to make the left center and right bitmaps
public void initBitmaps()
    {
        int height = _imageSlider.getHeight();
        _imageSliderLeft = new Bitmap( _xLeftBackMargin, height );
        _imageSliderCenter = new Bitmap( _imageSlider.getWidth() - _xRightBackMargin - _xLeftBackMargin, height);
        _imageSliderRight = new Bitmap( _xRightBackMargin, height );
        copy( _imageSlider, 0, 0, _xLeftBackMargin, height, _imageSliderLeft );
        copy( _imageSlider, _xLeftBackMargin, 0, _imageSlider.getWidth() - _xRightBackMargin - _xLeftBackMargin, height, _imageSliderCenter);
        copy( _imageSlider, _imageSlider.getWidth() - _xRightBackMargin, 0, _xRightBackMargin, height, _imageSliderRight);
        _imageSliderFocusLeft = new Bitmap( _xLeftBackMargin, height );
        _imageSliderFocusCenter = new Bitmap( _imageSlider.getWidth() - _xRightBackMargin - _xLeftBackMargin, height);
        _imageSliderFocusRight = new Bitmap( _xRightBackMargin, height );
        copy( _imageSliderFocus, 0, 0, _xLeftBackMargin, height, _imageSliderFocusLeft );
        copy( _imageSliderFocus, _xLeftBackMargin, 0, _imageSlider.getWidth() - _xRightBackMargin - _xLeftBackMargin, height, _imageSliderFocusCenter);
        copy( _imageSliderFocus, _imageSlider.getWidth() - _xRightBackMargin, 0, _xRightBackMargin, height, _imageSliderFocusRight);
    }
public void initBitmaps ( ) { int height = _imageSlider . getHeight ( ) ; _imageSliderLeft = new Bitmap ( _xLeftBackMargin , height ) ; _imageSliderCenter = new Bitmap ( _imageSlider . getWidth ( ) - _xRightBackMargin - _xLeftBackMargin , height ) ; _imageSliderRight = new Bitmap ( _xRightBackMargin , height ) ; copy ( _imageSlider , 0 , 0 , _xLeftBackMargin , height , _imageSliderLeft ) ; copy ( _imageSlider , _xLeftBackMargin , 0 , _imageSlider . getWidth ( ) - _xRightBackMargin - _xLeftBackMargin , height , _imageSliderCenter ) ; copy ( _imageSlider , _imageSlider . getWidth ( ) - _xRightBackMargin , 0 , _xRightBackMargin , height , _imageSliderRight ) ; _imageSliderFocusLeft = new Bitmap ( _xLeftBackMargin , height ) ; _imageSliderFocusCenter = new Bitmap ( _imageSlider . getWidth ( ) - _xRightBackMargin - _xLeftBackMargin , height ) ; _imageSliderFocusRight = new Bitmap ( _xRightBackMargin , height ) ; copy ( _imageSliderFocus , 0 , 0 , _xLeftBackMargin , height , _imageSliderFocusLeft ) ; copy ( _imageSliderFocus , _xLeftBackMargin , 0 , _imageSlider . getWidth ( ) - _xRightBackMargin - _xLeftBackMargin , height , _imageSliderFocusCenter ) ; copy ( _imageSliderFocus , _imageSlider . getWidth ( ) - _xRightBackMargin , 0 , _xRightBackMargin , height , _imageSliderFocusRight ) ; }
Cuts up the background image and margins you provide
 to make the left, center, and right bitmaps
Cuts up the background image and margins you provide to make the left center and right bitmaps