2014-06-08 30 views
0

我有問題爲我正在開發的應用程序設置舞臺高度和寬度。Flash Pro cc爲什麼我手機上的舞臺寬度和高度設置爲Flash Pro內的舞臺寬度和高度?

我需要爲它所在設備的屏幕設置高度和寬度。所以我做stage.fullScreenHeight和stage.fullScreenWidth。

但我只是意識到,fullScreenHeight和它設置的寬度是flash pro pro在屬性(舞臺尺寸)下的舞臺尺寸。

而且我不能根據手機的尺寸製作舞臺的寬度和高度。即使我做Capabilities.screenResolutionX;或stage.stageHeight。所有這些都設置爲圖像的大小,或flash專業版中的舞臺,但沒有一個是根據設備。

編輯:

E.g. var button = Button = new Button(); 
button.width = stage.stageWidth; 
button.height = Button.width/stage.stageWidth * Button.height; 

回答

1

嘗試在Stage.scaleMode = StageScaleMode.NO_SCALE時

在空中設置

或取消選中 「全屏幕」 複選框

+0

是否有可能,如果我設置的(例如一個按鈕)沒有規模?例如。 button.scaleMode = StageScaleMode.No_SCALE? – Benyaman

+1

據我所知你不能。但是也許.scaleX和.scaleY屬性會幫助你。例如。 button.scaleX = 1.5 –

相關問題