Hi,
From what I can tell from many hours, the new 2.2.2 build does not allow an outer DIV around your gameCanvas. If you do use one, the inner DIV created at game start-up (id=“Cocos2dGameContainer” ) is not getting the updated information when the browser window is made larger - only when it is made smaller. This seems to be something to investigate.
It seems like the Cocos2dGameContainer margins on the left and right “eat up” all space when the browser is made bigger again. So instead of the game getting that space back it is taken by the margin.
The net effect is that the game will scale down, but not back up. You can test and prove this error easily by wrapping an empty DIV around your Hello World example.
This was using:
cc.ContainerStrategy.PROPORTION_TO_FRAME,cc.ContentStrategy.SHOW_ALL
Additional note: :
cc.ContainerStrategy.EQUAL_TO_FRAME,cc.ContentStrategy.SHOW_ALL
It seems like the above will scale back up after scaling down, but this is not a good choice because when it scales down it shows a scroll bar and the game seems to float downward.
If this is an implementation issue, perhaps the solution is to post more examples of how to implement the new container strategy. The Hello World example shows when there is nothing on the page except the game, and truthfully this is an unrealistic example for many. I believe an example case where the game is wrapped in div on a Web page is a far more common one.
I look forward to any insight provided.
Thank you,
Sean