Skip to content

Commit

Permalink
Examples: enabled supportHighResolutions flag on Starling so that the…
Browse files Browse the repository at this point in the history
…y don't look pixelated on Mac Retina when testing in ADL (has no effect when running on mobile), and cleaned up some of the Starling flags that were being set to values that were already default.
  • Loading branch information
joshtynjala committed Apr 10, 2015
1 parent d49b026 commit f63f250
Show file tree
Hide file tree
Showing 23 changed files with 23 additions and 67 deletions.
6 changes: 1 addition & 5 deletions examples/ComponentsExplorer/source/ComponentsExplorer.as
Expand Up @@ -112,12 +112,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage, null, null, Context3DRenderMode.AUTO, Context3DProfile.BASELINE);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
this._starling.supportHighResolutions = true;
this._starling.start();
if(this._launchImage)
{
Expand Down Expand Up @@ -152,7 +149,6 @@ package
this._starling.viewPort = viewPort;
}
catch(error:Error) {}
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
}

private function stage_deactivateHandler(event:Event):void
Expand Down
5 changes: 1 addition & 4 deletions examples/ComponentsExplorer/source/ComponentsExplorerWeb.as
Expand Up @@ -41,13 +41,10 @@ package
this.gotoAndStop(2);
this.graphics.clear();

Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
var MainType:Class = getDefinitionByName("feathers.examples.componentsExplorer.Main") as Class;
this._starling = new Starling(MainType, this.stage);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
this._starling.supportHighResolutions = true;
this._starling.start();
}

Expand Down
Expand Up @@ -112,11 +112,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage, null, null, Context3DRenderMode.AUTO, Context3DProfile.BASELINE);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
this._starling.supportHighResolutions = true;
this._starling.start();
if(this._launchImage)
{
Expand Down
Expand Up @@ -41,10 +41,10 @@ package
this.gotoAndStop(2);
this.graphics.clear();

Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
var MainType:Class = getDefinitionByName("feathers.examples.displayObjects.Main") as Class;
this._starling = new Starling(MainType, this.stage);
this._starling.supportHighResolutions = true;
this._starling.start();
}

Expand Down
5 changes: 1 addition & 4 deletions examples/DragAndDrop/source/DragAndDrop.as
Expand Up @@ -28,11 +28,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
this._starling.supportHighResolutions = true;
this._starling.start();

this.stage.addEventListener(Event.RESIZE, stage_resizeHandler, false, int.MAX_VALUE, true);
Expand All @@ -52,7 +50,6 @@ package
this._starling.viewPort = viewPort;
}
catch(error:Error) {}
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
}

private function stage_deactivateHandler(event:Event):void
Expand Down
6 changes: 1 addition & 5 deletions examples/DrawersExplorer/source/DrawersExplorer.as
Expand Up @@ -112,12 +112,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage, null, null, Context3DRenderMode.AUTO, Context3DProfile.BASELINE);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
this._starling.supportHighResolutions = true;
this._starling.start();
if(this._launchImage)
{
Expand Down Expand Up @@ -152,7 +149,6 @@ package
this._starling.viewPort = viewPort;
}
catch(error:Error) {}
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
}

private function stage_deactivateHandler(event:Event):void
Expand Down
5 changes: 1 addition & 4 deletions examples/DrawersExplorer/source/DrawersExplorerWeb.as
Expand Up @@ -41,13 +41,10 @@ package
this.gotoAndStop(2);
this.graphics.clear();

Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
var MainType:Class = getDefinitionByName("feathers.examples.drawersExplorer.Main") as Class;
this._starling = new Starling(MainType, this.stage);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
this._starling.supportHighResolutions = true;
this._starling.start();
}

Expand Down
4 changes: 1 addition & 3 deletions examples/Gallery/source/Gallery.as
Expand Up @@ -112,11 +112,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage, null, null, Context3DRenderMode.AUTO, Context3DProfile.BASELINE);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
this._starling.supportHighResolutions = true;
this._starling.start();
if(this._launchImage)
{
Expand Down
2 changes: 1 addition & 1 deletion examples/Gallery/source/GalleryWeb.as
Expand Up @@ -43,10 +43,10 @@ package
this.gotoAndStop(2);
this.graphics.clear();

Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
var MainType:Class = getDefinitionByName("feathers.examples.gallery.Main") as Class;
this._starling = new Starling(MainType, this.stage);
this._starling.supportHighResolutions = true;
this._starling.start();

this.stage.addEventListener(Event.RESIZE, stage_resizeHandler, false, int.MAX_VALUE, true);
Expand Down
3 changes: 1 addition & 2 deletions examples/HelloWorld/source/HelloWorld.as
Expand Up @@ -112,10 +112,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage, null, null, Context3DRenderMode.AUTO, Context3DProfile.BASELINE);
this._starling.enableErrorChecking = false;
this._starling.supportHighResolutions = true;
this._starling.start();
if(this._launchImage)
{
Expand Down
2 changes: 1 addition & 1 deletion examples/HelloWorld/source/HelloWorldWeb.as
Expand Up @@ -41,10 +41,10 @@ package
this.gotoAndStop(2);
this.graphics.clear();

Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
var MainType:Class = getDefinitionByName("feathers.examples.helloWorld.Main") as Class;
this._starling = new Starling(MainType, this.stage);
this._starling.supportHighResolutions = true;
this._starling.start();
}

Expand Down
4 changes: 1 addition & 3 deletions examples/LayoutExplorer/source/LayoutExplorer.as
Expand Up @@ -112,11 +112,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage, null, null, Context3DRenderMode.AUTO, Context3DProfile.BASELINE);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
this._starling.supportHighResolutions = true;
this._starling.start();
if(this._launchImage)
{
Expand Down
2 changes: 1 addition & 1 deletion examples/LayoutExplorer/source/LayoutExplorerWeb.as
Expand Up @@ -41,10 +41,10 @@ package
this.gotoAndStop(2);
this.graphics.clear();

Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
var MainType:Class = getDefinitionByName("feathers.examples.layoutExplorer.Main") as Class;
this._starling = new Starling(MainType, this.stage);
this._starling.supportHighResolutions = true;
this._starling.start();
}

Expand Down
4 changes: 1 addition & 3 deletions examples/TileList/source/TileList.as
Expand Up @@ -112,11 +112,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage, null, null, Context3DRenderMode.AUTO, Context3DProfile.BASELINE);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
this._starling.supportHighResolutions = true;
this._starling.start();
if(this._launchImage)
{
Expand Down
2 changes: 1 addition & 1 deletion examples/TileList/source/TileListWeb.as
Expand Up @@ -42,10 +42,10 @@ package
this.gotoAndStop(2);
this.graphics.clear();

Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
var MainType:Class = getDefinitionByName("feathers.examples.tileList.Main") as Class;
this._starling = new Starling(MainType, this.stage);
this._starling.supportHighResolutions = true;
this._starling.start();
}

Expand Down
6 changes: 1 addition & 5 deletions examples/Todos/source/Todos.as
Expand Up @@ -112,12 +112,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage, null, null, Context3DRenderMode.AUTO, Context3DProfile.BASELINE);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
this._starling.supportHighResolutions = true;
this._starling.start();
if(this._launchImage)
{
Expand Down Expand Up @@ -152,7 +149,6 @@ package
this._starling.viewPort = viewPort;
}
catch(error:Error) {}
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
}

private function stage_deactivateHandler(event:Event):void
Expand Down
3 changes: 1 addition & 2 deletions examples/Todos/source/TodosWeb.as
Expand Up @@ -41,11 +41,10 @@ package
this.gotoAndStop(2);
this.graphics.clear();

Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
var MainType:Class = getDefinitionByName("feathers.examples.todos.Main") as Class;
this._starling = new Starling(MainType, this.stage);
this._starling.enableErrorChecking = false;
this._starling.supportHighResolutions = true;
this._starling.start();
}

Expand Down
3 changes: 1 addition & 2 deletions examples/TrainTimes/source/TrainTimes.as
Expand Up @@ -113,10 +113,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage, null, null, Context3DRenderMode.AUTO, Context3DProfile.BASELINE);
this._starling.enableErrorChecking = false;
this._starling.supportHighResolutions = true;
this._starling.start();
if(this._launchImage)
{
Expand Down
3 changes: 1 addition & 2 deletions examples/TrainTimes/source/TrainTimesWeb.as
Expand Up @@ -41,11 +41,10 @@ package
this.gotoAndStop(2);
this.graphics.clear();

Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
var MainType:Class = getDefinitionByName("feathers.examples.trainTimes.Main") as Class;
this._starling = new Starling(MainType, this.stage);
this._starling.enableErrorChecking = false;
this._starling.supportHighResolutions = true;
this._starling.start();
}

Expand Down
6 changes: 1 addition & 5 deletions examples/TransitionsExplorer/source/TransitionsExplorer.as
Expand Up @@ -108,12 +108,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage, null, null, Context3DRenderMode.AUTO, Context3DProfile.BASELINE);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
this._starling.supportHighResolutions = true;
this._starling.start();
if(this._launchImage)
{
Expand Down Expand Up @@ -147,7 +144,6 @@ package
this._starling.viewPort = viewPort;
}
catch(error:Error) {}
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
}

private function stage_deactivateHandler(event:Event):void
Expand Down
Expand Up @@ -41,13 +41,10 @@ package
this.gotoAndStop(2);
this.graphics.clear();

Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
var MainType:Class = getDefinitionByName("feathers.examples.transitionsExplorer.Main") as Class;
this._starling = new Starling(MainType, this.stage);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
this._starling.supportHighResolutions = true;
this._starling.start();
}

Expand Down
5 changes: 1 addition & 4 deletions examples/YouTubeFeeds/source/YouTubeFeeds.as
Expand Up @@ -112,11 +112,9 @@ package

private function loaderInfo_completeHandler(event:Event):void
{
Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
this._starling = new Starling(Main, this.stage, null, null, Context3DRenderMode.AUTO, Context3DProfile.BASELINE);
this._starling.enableErrorChecking = false;
//this._starling.showStats = true;
this._starling.supportHighResolutions = true;
this._starling.start();
if(this._launchImage)
{
Expand Down Expand Up @@ -151,7 +149,6 @@ package
this._starling.viewPort = viewPort;
}
catch(error:Error) {}
//this._starling.showStatsAt(HAlign.LEFT, VAlign.BOTTOM);
}

private function stage_deactivateHandler(event:Event):void
Expand Down
3 changes: 1 addition & 2 deletions examples/YouTubeFeeds/source/YouTubeFeedsWeb.as
Expand Up @@ -41,11 +41,10 @@ package
this.gotoAndStop(2);
this.graphics.clear();

Starling.handleLostContext = true;
Starling.multitouchEnabled = true;
var MainType:Class = getDefinitionByName("feathers.examples.youtube.Main") as Class;
this._starling = new Starling(MainType, this.stage);
this._starling.enableErrorChecking = false;
this._starling.supportHighResolutions = true;
this._starling.start();
}

Expand Down

0 comments on commit f63f250

Please sign in to comment.