Skip to content

Commit e38d6c1

Browse files
committed
New function on SliderGallery to create current interface bitmapData
1 parent ec8a2cb commit e38d6c1

1 file changed

Lines changed: 13 additions & 1 deletion

File tree

appManager/displayContent/SliderGallery.as

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
//appManager.displayContent.SliderGallery
33
{
44

5+
import flash.display.BitmapData;
56
import flash.display.MovieClip;
67
import flash.display.Sprite;
78
import flash.events.Event;
@@ -579,6 +580,10 @@
579580
switchToNext = false ;
580581
imagesList = images ;
581582
_totalImages = imagesList.length ;
583+
if(_totalImages==0)
584+
{
585+
return ;
586+
}
582587
imageIndex = (plusPages-(plusPages%_totalImages))+currentIndex ;
583588
getImageUp().load(currentImage(),0,true);
584589

@@ -692,6 +697,13 @@
692697
//getImageDown().load(imagesList[sliderElementIndex],sliderElementIndex);
693698
}
694699

695-
700+
/**Creating a bitmap data from the current display*/
701+
public function getBitmapData():flash.display.BitmapData
702+
{
703+
var currentDisplayingObject:SliderGalleryElements = getImageUp() ;
704+
var bitmapData:BitmapData = new BitmapData(currentDisplayingObject.width,currentDisplayingObject.height,false,0xffffff);
705+
bitmapData.draw(currentDisplayingObject);
706+
return bitmapData;
707+
}
696708
}
697709
}

0 commit comments

Comments
 (0)