Index: CKEditor/branches/features/adobeair/_samples/adobeair/application.xml
===================================================================
--- CKEditor/branches/features/adobeair/_samples/adobeair/application.xml	(revision 6101)
+++ CKEditor/branches/features/adobeair/_samples/adobeair/application.xml	(revision 6131)
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="utf-8" ?>
 <application xmlns="http://ns.adobe.com/air/application/1.0">
-	<id>com.ckeditor.air.samples</id>
-	<name>CKEditor Sample Application 1.0</name>
+	<id>com.ckeditor.air.sample</id>
+	<name>CKEditor - Adobe AIR Sample Application</name>
 	<version>1.0</version>
 	<filename>CKEditor AIR Samples</filename>
@@ -8,6 +8,6 @@
 	<copyright>Copyright (C) 2003-2010 Frederico Caldeira Knabben</copyright>
 	<initialWindow>
-		<content>_samples/adobeair/index.html</content>
-		<title>CKEditor AIR Samples</title>
+		<content>_samples/adobeair/sample.html</content>
+		<title>CKEditor - Adobe AIR Sample</title>
 		<systemChrome>standard</systemChrome>
 		<transparent>false</transparent>
@@ -18,10 +18,10 @@
 		<x>100</x>
 		<y>80</y>
-		<width>1024</width>
-		<height>768</height>
-		<minSize>800 600</minSize>
+		<width>950</width>
+		<height>700</height>
+		<minSize>900 600</minSize>
 	</initialWindow>
-	<installFolder>CKEditor/AIR Samples</installFolder>
-	<programMenuFolder>CKEditor/AIR Samples</programMenuFolder>
+	<installFolder>CKEditor/Sample AIR Application</installFolder>
+	<programMenuFolder>CKEditor/Sample AIR Application</programMenuFolder>
 <!--
 	<icon>
Index: CKEditor/branches/features/adobeair/_samples/adobeair/index.html
===================================================================
--- CKEditor/branches/features/adobeair/_samples/adobeair/index.html	(revision 6101)
+++ 	(revision )
@@ -1,2 +1,0 @@
-<input id="back" type="button" value="Back" onclick="document.getElementById( 'sample_frame' ).src = '../index.html' ">
-<iframe id="sample_frame" src='../index.html' style="width : 100%; height : 100%;"></iframe>		
Index: CKEditor/branches/features/adobeair/_samples/adobeair/package.bat
===================================================================
--- CKEditor/branches/features/adobeair/_samples/adobeair/package.bat	(revision 6101)
+++ CKEditor/branches/features/adobeair/_samples/adobeair/package.bat	(revision 6131)
@@ -1,26 +1,7 @@
 @ECHO OFF
-
 ::
-:: FCKeditor - The text editor for Internet - http://www.fckeditor.net
-:: Copyright (C) 2003-2009 Frederico Caldeira Knabben
-::
-:: == BEGIN LICENSE ==
-::
-:: Licensed under the terms of any of the following licenses at your
-:: choice:
-::
-::  - GNU General Public License Version 2 or later (the "GPL")
-::    http://www.gnu.org/licenses/gpl.html
-::
-::  - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
-::    http://www.gnu.org/licenses/lgpl.html
-::
-::  - Mozilla Public License Version 1.1 or later (the "MPL")
-::    http://www.mozilla.org/MPL/MPL-1.1.html
-::
-:: == END LICENSE ==
+:: Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.
+:: For licensing, see LICENSE.html or http://ckeditor.com/license
 ::
 
-:: adt -package SIGNING_OPTIONS air_file app_xml [file_or_dir | -C dir file_or_dir | -e file dir ...] ...
-
 adt -package -storetype pkcs12 -keystore cert.pfx -storepass 123abc CKEditor.air application.xml -C ../../ .
Index: CKEditor/branches/features/adobeair/_samples/adobeair/run.bat
===================================================================
--- CKEditor/branches/features/adobeair/_samples/adobeair/run.bat	(revision 6101)
+++ CKEditor/branches/features/adobeair/_samples/adobeair/run.bat	(revision 6131)
@@ -1,26 +1,12 @@
 @ECHO OFF
-
 ::
-:: FCKeditor - The text editor for Internet - http://www.fckeditor.net
-:: Copyright (C) 2003-2009 Frederico Caldeira Knabben
+:: Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.
+:: For licensing, see LICENSE.html or http://ckeditor.com/license
 ::
-:: == BEGIN LICENSE ==
+:: Use this file to quickly run the sample in a Windows environment.
 ::
-:: Licensed under the terms of any of the following licenses at your
-:: choice:
-::
-::  - GNU General Public License Version 2 or later (the "GPL")
-::    http://www.gnu.org/licenses/gpl.html
-::
-::  - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
-::    http://www.gnu.org/licenses/lgpl.html
-::
-::  - Mozilla Public License Version 1.1 or later (the "MPL")
-::    http://www.mozilla.org/MPL/MPL-1.1.html
-::
-:: == END LICENSE ==
+:: Be sure to change the following directory path so it matches your AIR SDK
+:: installation path.
 ::
 
-:: adl [-runtime runtime-directory] [-pubId publisher-id] [-nodebug] application.xml [rootdirectory] [-- arguments]
-
-adl application.xml ../../
+C:/AdobeAIRSDK/bin/adl application.xml ../../
Index: CKEditor/branches/features/adobeair/_samples/adobeair/sample.html
===================================================================
--- CKEditor/branches/features/adobeair/_samples/adobeair/sample.html	(revision 6131)
+++ CKEditor/branches/features/adobeair/_samples/adobeair/sample.html	(revision 6131)
@@ -0,0 +1,49 @@
+﻿<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!--
+Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.html or http://ckeditor.com/license
+-->
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+	<title>Replace Textarea by Code - CKEditor Sample</title>
+	<meta content="text/html; charset=utf-8" http-equiv="content-type" />
+	<!-- CKReleaser %REMOVE_LINE%
+	<script type="text/javascript" src="../../ckeditor.js"></script>
+	CKReleaser %REMOVE_START% -->
+	<script type="text/javascript" src="../../ckeditor_source.js"></script>
+	<!-- CKReleaser %REMOVE_END% -->
+	<link href="../sample.css" rel="stylesheet" type="text/css" />
+	<style type="text/css">
+		body { margin: 10px ; }
+	</style></head>
+<body>
+	<h1>
+		CKEditor - Adobe AIR Sample
+	</h1>
+	<p>
+		This is a sample HTML/JavaScript Adobe AIR application with CKEditor with default features.
+	</p>
+	<p>
+		<textarea cols="80" id="editor1" name="editor1" rows="10">&lt;p&gt;This is some &lt;strong&gt;sample text&lt;/strong&gt;. You are using &lt;a href="http://ckeditor.com/"&gt;CKEditor&lt;/a&gt;.&lt;/p&gt;</textarea>
+		<script type="text/javascript">
+		//<![CDATA[
+
+			// Replace the <textarea id="editor"> with an CKEditor
+			// instance, using default configurations.
+			CKEDITOR.replace( 'editor1' );
+
+		//]]>
+		</script>
+	</p>
+	<div id="footer" style="position:absolute;bottom:0;left:0;right:0;width:100%;padding-bottom:10px;">
+		<hr />
+		<p>
+			CKEditor - The text editor for Internet - <a href="#" onclick="window.runtime.flash.net.navigateToURL(new window.runtime.flash.net.URLRequest('http://ckeditor.com/'));return false;">http://ckeditor.com</a>
+		</p>
+		<p id="copy">
+			Copyright &copy; 2003-2010, <a href="#" onclick="window.runtime.flash.net.navigateToURL(new window.runtime.flash.net.URLRequest('http://cksource.com/'));return false;">CKSource</a> - Frederico
+			Knabben. All rights reserved.
+		</p>
+	</div>
+</body>
+</html>
Index: CKEditor/branches/features/adobeair/_samples/replacebyclass.html
===================================================================
--- CKEditor/branches/features/adobeair/_samples/replacebyclass.html	(revision 6101)
+++ CKEditor/branches/features/adobeair/_samples/replacebyclass.html	(revision 6131)
@@ -11,6 +11,4 @@
 	<script type="text/javascript" src="../ckeditor.js"></script>
 	CKReleaser %REMOVE_START% -->
-	<script type="text/javascript" src="../_dev/adobeair/AIRIntrospector.js"></script>
-	<script type="text/javascript" src="../_dev/adobeair/AIRAliases.js"></script>
 	<script type="text/javascript" src="../ckeditor_source.js"></script>
 	<!-- CKReleaser %REMOVE_END% -->
Index: CKEditor/branches/features/adobeair/_samples/replacebycode.html
===================================================================
--- CKEditor/branches/features/adobeair/_samples/replacebycode.html	(revision 6101)
+++ CKEditor/branches/features/adobeair/_samples/replacebycode.html	(revision 6131)
@@ -52,5 +52,5 @@
 			<label for="editor2">
 				Editor 2:</label><br />
-			<textarea cols="80" id="editor2" name="editor2" rows="10">second</textarea>
+			<textarea cols="80" id="editor2" name="editor2" rows="10">&lt;p&gt;This is some &lt;strong&gt;sample text&lt;/strong&gt;. You are using &lt;a href="http://ckeditor.com/"&gt;CKEditor&lt;/a&gt;.&lt;/p&gt;</textarea>
 			<script type="text/javascript">
 			//<![CDATA[
Index: CKEditor/branches/features/adobeair/_source/core/config.js
===================================================================
--- CKEditor/branches/features/adobeair/_source/core/config.js	(revision 6101)
+++ CKEditor/branches/features/adobeair/_source/core/config.js	(revision 6131)
@@ -271,5 +271,4 @@
 	plugins :
 		'about,' +
-		'adobeair,' +
 		'a11yhelp,' +
 		'basicstyles,' +
Index: CKEditor/branches/features/adobeair/_source/core/editor.js
===================================================================
--- CKEditor/branches/features/adobeair/_source/core/editor.js	(revision 6101)
+++ CKEditor/branches/features/adobeair/_source/core/editor.js	(revision 6131)
@@ -228,4 +228,7 @@
 		}
 
+		// Load the Adobe AIR plugin conditionally.
+		CKEDITOR.env.air && ( plugins += ',adobeair' );
+
 		// Load all plugins defined in the "plugins" setting.
 		CKEDITOR.plugins.load( plugins.split( ',' ), function( plugins )
Index: CKEditor/branches/features/adobeair/_source/core/env.js
===================================================================
--- CKEditor/branches/features/adobeair/_source/core/env.js	(revision 6101)
+++ CKEditor/branches/features/adobeair/_source/core/env.js	(revision 6131)
@@ -242,5 +242,5 @@
 				env.gecko ? 'gecko' :
 				env.opera ? 'opera' :
-				env.air ? 'air' :
+				env.air ? 'air cke_browser_webkit' :
 				env.webkit ? 'webkit' :
 				'unknown' );
Index: CKEditor/branches/features/adobeair/_source/core/plugins.js
===================================================================
--- CKEditor/branches/features/adobeair/_source/core/plugins.js	(revision 6101)
+++ CKEditor/branches/features/adobeair/_source/core/plugins.js	(revision 6131)
@@ -54,7 +54,7 @@
 						{
 							var methods = [ 'beforeLoad', 'onLoad', 'afterLoad' ];
-							for ( var i = 0; i < methods.length; i++ )
+							for ( i = 0; i < methods.length; i++ )
 							{
-								// Call the "onLoad" function for all plugins.
+								// Call the events for all plugins.
 								for ( pluginName in allPlugins )
 								{
@@ -67,4 +67,5 @@
 								}
 							}
+
 							// Call the callback.
 							if ( callback )
Index: CKEditor/branches/features/adobeair/_source/plugins/adobeair/plugin.js
===================================================================
--- CKEditor/branches/features/adobeair/_source/plugins/adobeair/plugin.js	(revision 6101)
+++ CKEditor/branches/features/adobeair/_source/plugins/adobeair/plugin.js	(revision 6131)
@@ -1,8 +1,8 @@
 /*
-Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved.
+Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.
 For licensing, see LICENSE.html or http://ckeditor.com/license
 */
 
-( function()
+(function()
 {
 	var eventNameList = [ 'click', 'keydown', 'mousedown', 'keypress' ];
@@ -20,12 +20,12 @@
 			child = children.getItem( i );
 
-			( function( node )
+			(function( node )
 			{
 				for ( var j = 0; j < eventNameList.length; j++ )
 				{
-					( function( eventName )
+					(function( eventName )
 					{
 
-						if( node.hasAttribute( 'on' + eventName ) )
+						if ( node.hasAttribute( 'on' + eventName ) )
 						{
 							node.on( eventName, function( evt )
@@ -57,5 +57,5 @@
 										if ( argName.match( /\d+/ ) )
 										{
-											callFuncArgs[ i ] = parseInt( argName );
+											callFuncArgs[ i ] = parseInt( argName, 10 );
 											continue;
 										}
@@ -79,12 +79,11 @@
 								}
 
-								if( preventDefault )
+								if ( preventDefault )
 									evt.data.preventDefault();
-							} );
+							});
 						}
-					} )( eventNameList[ j ] );
+					})( eventNameList[ j ] );
 				}
-
-			} )( child );
+			})( child );
 		}
 	}
@@ -105,10 +104,10 @@
 
 			editor.on( 'uiReady', function()
-			{
-				convertInlineHandlers( editor.container );
-				editor.sharedtop && convertInlineHandlers( editor.sharedtop );
-				editor.sharedbottom && convertInlineHandlers( editor.sharedbottom );
-				editor.on( 'elementsPathUpdate', function( evt ) { convertInlineHandlers( evt.data ); } );
-			} );
+				{
+					convertInlineHandlers( editor.container );
+					editor.sharedtop && convertInlineHandlers( editor.sharedtop );
+					editor.sharedbottom && convertInlineHandlers( editor.sharedbottom );
+					editor.on( 'elementsPathUpdate', function( evt ) { convertInlineHandlers( evt.data ); } );
+				});
 
 		},
@@ -139,5 +138,4 @@
 					convertInlineHandlers( holder );
 				})();
-
 			}
 
@@ -146,10 +144,8 @@
 			menu && menu.on( 'uiReady', onPanelUIReady );
 			dialog && dialog.on( 'uiReady', function ( evt )
-			{
-				convertInlineHandlers( evt.data._.element );
-			} );
+				{
+					convertInlineHandlers( evt.data._.element );
+				});
 		}
-	} );
-
-} )();
-
+	});
+})();
Index: CKEditor/branches/features/adobeair/_source/plugins/scayt/plugin.js
===================================================================
--- CKEditor/branches/features/adobeair/_source/plugins/scayt/plugin.js	(revision 6101)
+++ CKEditor/branches/features/adobeair/_source/plugins/scayt/plugin.js	(revision 6131)
@@ -358,11 +358,7 @@
 		loadEngine : function( editor )
 		{
-			// SCAYT doesn't work with Adobe AIR, Firefox2, Opera.
-			if ( CKEDITOR.env.air
-				|| CKEDITOR.env.gecko && CKEDITOR.env.version < 10900
-				|| CKEDITOR.env.opera )
-			{
+			// SCAYT doesn't work with Firefox2, Opera and AIR.
+			if ( CKEDITOR.env.gecko && CKEDITOR.env.version < 10900 || CKEDITOR.env.opera || CKEDITOR.env.air )
 				return editor.fire( 'showScaytState' );
-			}
 
 			if ( this.engineLoaded === true )
Index: CKEditor/branches/features/adobeair/_source/plugins/wysiwygarea/plugin.js
===================================================================
--- CKEditor/branches/features/adobeair/_source/plugins/wysiwygarea/plugin.js	(revision 6101)
+++ CKEditor/branches/features/adobeair/_source/plugins/wysiwygarea/plugin.js	(revision 6131)
@@ -415,5 +415,4 @@
 							'document.close();';
 
-
 						iframe = CKEDITOR.dom.element.createFromHtml( '<iframe' +
   							' style="width:100%;height:100%"' +
@@ -424,5 +423,5 @@
 							// trigger iframe's 'load' event.
   							' src="' + ( CKEDITOR.env.air ? editor._.air_bootstrap_frame_url : CKEDITOR.env.ie ? 'javascript:void(function(){' + encodeURIComponent( srcScript ) + '}())' : '' ) + '"' +
-						  	' tabIndex="' + ( CKEDITOR.env.webkit? -1 : editor.tabIndex ) + '"' +
+							' tabIndex="' + ( CKEDITOR.env.webkit? -1 : editor.tabIndex ) + '"' +
   							' allowTransparency="true"' +
   							'></iframe>' );
@@ -500,7 +499,6 @@
 						frameLoaded = 0;
 
-
 						editor.fire( 'ariaWidget', iframe );
-						
+
 						var domDocument = domWindow.document,
 							body = domDocument.body;
@@ -508,5 +506,5 @@
 						// Remove this script from the DOM.
 						var script = domDocument.getElementById( "cke_actscrpt" );
-							script.parentNode.removeChild( script );
+						script.parentNode.removeChild( script );
 
 						body.spellcheck = !editor.config.disableNativeSpellChecker;
@@ -610,6 +608,5 @@
 						}
 
-
-						if( CKEDITOR.env.air )
+						if ( CKEDITOR.env.air )
 						{
 							// Hyperlinks is enabled in Adobe AIR wysiwyg mode.   
@@ -960,4 +957,6 @@
 							focus : function()
 							{
+								var win = editor.window;
+
 								if ( isLoadingData )
 									isPendingFocus = true;
@@ -967,5 +966,5 @@
 									// Required for Opera when switching focus
 									// from another iframe, e.g. panels. (#6444)
-									var iframe = editor.window.$.frameElement;
+									var iframe = win.$.frameElement;
 									iframe.blur(), iframe.focus();
 									editor.document.getBody().focus();
@@ -973,9 +972,8 @@
 									editor.selectionChange();
 								}
-								else if ( !CKEDITOR.env.opera && editor.window )
-								{
-									var win = editor.window;
+								else if ( !CKEDITOR.env.opera && win )
+								{
 									// AIR need a while when focus was switching previously  from a link.
-									CKEDITOR.env.air? setTimeout( function () { win.focus(); }, 0 ) : win.focus();
+									CKEDITOR.env.air ? setTimeout( function () { win.focus(); }, 0 ) : win.focus();
 									editor.selectionChange();
 								}
@@ -1017,5 +1015,6 @@
 			function blinkCursor( retry )
 			{
-				CKEDITOR.tools.tryThese( function ()
+				CKEDITOR.tools.tryThese(
+					function()
 					{
 						editor.document.$.designMode = 'on';
@@ -1026,5 +1025,6 @@
 								editor.document.getBody().focus();
 						}, 50 );
-				}, function ()
+					},
+					function()
 					{
 						// The above call is known to fail when parent DOM
@@ -1037,5 +1037,5 @@
 						// Try it again once..
 						!retry && blinkCursor( 1 );
-				})
+					});
 			}
 
Index: CKEditor/branches/features/adobeair/_source/skins/kama/mainui.css
===================================================================
--- CKEditor/branches/features/adobeair/_source/skins/kama/mainui.css	(revision 6101)
+++ CKEditor/branches/features/adobeair/_source/skins/kama/mainui.css	(revision 6131)
@@ -20,6 +20,5 @@
 
 .cke_skin_kama span.cke_browser_webkit,
-.cke_skin_kama span.cke_browser_gecko18,
-.cke_skin_kama span.cke_browser_air
+.cke_skin_kama span.cke_browser_gecko18
 {
 	display: block;
Index: CKEditor/branches/features/adobeair/_source/skins/office2003/mainui.css
===================================================================
--- CKEditor/branches/features/adobeair/_source/skins/office2003/mainui.css	(revision 6101)
+++ CKEditor/branches/features/adobeair/_source/skins/office2003/mainui.css	(revision 6131)
@@ -14,6 +14,5 @@
 
 .cke_skin_office2003 span.cke_browser_webkit,
-.cke_skin_office2003 span.cke_browser_gecko18,
-.cke_skin_office2003 span.cke_browser_air
+.cke_skin_office2003 span.cke_browser_gecko18
 {
 	display: block;
Index: CKEditor/branches/features/adobeair/_source/skins/v2/mainui.css
===================================================================
--- CKEditor/branches/features/adobeair/_source/skins/v2/mainui.css	(revision 6101)
+++ CKEditor/branches/features/adobeair/_source/skins/v2/mainui.css	(revision 6131)
@@ -19,6 +19,5 @@
 
 .cke_skin_v2 span.cke_browser_webkit,
-.cke_skin_v2 span.cke_browser_gecko18,
-.cke_skin_v2 span.cke_browser_air
+.cke_skin_v2 span.cke_browser_gecko18
 {
 	display: block;
Index: CKEditor/branches/features/adobeair/ckeditor.pack
===================================================================
--- CKEditor/branches/features/adobeair/ckeditor.pack	(revision 6101)
+++ CKEditor/branches/features/adobeair/ckeditor.pack	(revision 6131)
@@ -135,5 +135,4 @@
 //					'_source/lang/en.js',
 					'_source/plugins/about/plugin.js',
-					'_source/plugins/adobeair/plugin.js',
 					'_source/plugins/a11yhelp/plugin.js',
 					'_source/plugins/basicstyles/plugin.js',
Index: CKEditor/branches/features/adobeair/config.js
===================================================================
--- CKEditor/branches/features/adobeair/config.js	(revision 6101)
+++ CKEditor/branches/features/adobeair/config.js	(revision 6131)
@@ -9,4 +9,3 @@
 	// config.language = 'fr';
 	// config.uiColor = '#AADC6E';
-	config.scayt_autoStartup = false;
 };
