Course is being scaled larger than the window

The Issue

In some cases, a brain 3 course can display a bad behavior whereby the typical content resizing code backfires, creating a situation where the content is scaled larger than the size of the window.

An example of a course working properly:

And the same course exhibiting this bad behavior:

Note how the course content and interface is scaled to fit the entire window, and the top of the interface and the entire control bar are outside the bounds of the window.

What am I looking at?

This issue can be a bit hard to diagnose and break down. Essentially, the window that is opening from the LMS is smaller than the size of the interface's stage, while the interface has content that extends beyond the stage size, AND, the load.swf file is smaller than the entire width and height of the interface (including the content off-stage). Essentially, the interface's resize code is tricked into thinking that the course is too small to fit in the window, and enters scaling mode, but because there is content outside the boundaries of the interface stage, it can never figure out that the window is actually large enough to fit the content.

The Cause(s)

This is a complex issue that relies on two problems within the course package, and a third factor in the LMS. If any one of these factors is removed, the issue will not present itself, but, the issues should all be resolved for good measure.

Course Factors:

Content Outside of the stage in the Interface.

All of the content in an interface that you want to fit on the users screen should be contained within the area of the stage. If not, and the course gets resized, the content that is off of the stage could end up outside of the window boundaries. Exceptions here apply to any content that _should_ extend beyond the stage, like a non-scaling background, or content whose scale changes with the window, like a scaling background.

Load SWF Size is smaller than the interface stage size.

The load.swf dimensions MUST ALWAYS be equal to or larger than the stage size inside the interface.swf file. It MUST also be the same aspect ratio (4:3, 16:9, etc.) as the stage in the interface. The easiest way to ensure this is to match the load.swf and interface stage dimensions exactly. If the load.swf is too small, the scaling of the content can behave badly. If it is too large, the alignment of the content can behave badly when the aspect ratio differs from the interface stage aspect ratio.

LMS Factors:

LMS opens the course in a window smaller than the size of the content (including content off stage).

In a normal course, where the previous two factors are not present, this is normally not an issue, because the load.swf matches the interface stage size, and thus the interface stage is set to the same size as the load.swf, and everything is within the interface stage, so everything is visible and proper scaling is maintained. The flash content can tell when the window is larger than the content would normally be, and when the content exceeds that size, the scaling is turned back off.

Where this becomes an issue is when the content is off-stage inside the interface file. Because the interface is scaled to fit it's stage into the load.swf file, but there is additional content off-screen, when the window is re-sized the interface is scaled in such a way that the content off-stage is also always outside of the window, meaning that the course can never see that the window has been resized to such a point that the interface content fits within it.

The Fix

Just make sure that:

1) Everything but the background fits within the stage size of your interface.

2) The load.swf matches the dimensions of the stage inside the interface.