Skip to content

Commit f565c00

Browse files
committed
Darkbox for iOS
1 parent 9671eb7 commit f565c00

2 files changed

Lines changed: 5 additions & 3 deletions

File tree

contents/Config.as

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,8 @@
8383
/**You can repose the stage items by this rectangle. the x and y values shows how much you should move your item on the stage*/
8484
public function get stageMovedRect():Rectangle
8585
{
86-
return new Rectangle((_stageRect.width-_stageOrgiginalRect.width)/-2,(_stageRect.height-_stageOrgiginalRect.height)/-2,_stageRect.width,_stageRect.height);
86+
trace("_stageRect.y : "+_stageRect.y);
87+
return new Rectangle((_stageRect.width-_stageOrgiginalRect.width)/-2,(_stageRect.height-_stageOrgiginalRect.height)/-2+_stageRect.y,_stageRect.width,_stageRect.height);
8788
}
8889

8990
public function set stageRect(value:Rectangle):void

darkBox/DarkBox.as

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
{
3434

3535

36-
private static var ME:DarkBox ;
36+
public static var ME:DarkBox ;
3737

3838
private static var noNetTitle:String,
3939
noImageTitle:String;
@@ -109,6 +109,7 @@
109109
/**Initialize the DarkBox area*/
110110
public static function setUp(newSize:Rectangle,noNetHintText:String='No Internet Connection Available',noImageHereText:String='',downloadFunction:Function=null,titleInFullLine:Boolean=false,RightToLeft:Boolean=true,activateAutoSize:Boolean=true):void
111111
{
112+
trace("Update darkbox stage area : "+newSize);
112113
rtf = RightToLeft ;
113114
showTitleInFullLine = titleInFullLine ;
114115
saveButtonFunction = downloadFunction ;
@@ -128,7 +129,7 @@
128129
{
129130
ME.setUp(StageManager.stageRect);
130131
ME.x = StageManager.stageDelta.width/-2;
131-
ME.y = StageManager.stageDelta.height/-2;
132+
ME.y = StageManager.stageDelta.height/-2+StageManager.stageDelta.y;
132133
}
133134

134135
public static function show(Images:Vector.<ImageFile>,currentIndex:uint=0,onClosed:Function=null):void

0 commit comments

Comments
 (0)