Index: /CKEditor/trunk/_source/core/config.js
===================================================================
--- /CKEditor/trunk/_source/core/config.js	(revision 3169)
+++ /CKEditor/trunk/_source/core/config.js	(revision 3170)
@@ -148,5 +148,5 @@
 	 */
 
-	plugins : 'basicstyles,blockquote,button,clipboard,colorbutton,elementspath,find,flash,font,format,forms,horizontalrule,htmldataprocessor,image,indent,justify,keystrokes,link,list,newpage,pagebreak,pastefromword,pastetext,preview,print,removeformat,smiley,showblocks,sourcearea,stylescombo,table,specialchar,tab,templates,toolbar,undo,wysiwygarea,wsc',
+	plugins : 'basicstyles,blockquote,button,clipboard,colorbutton,contextmenu,elementspath,find,flash,font,format,forms,horizontalrule,htmldataprocessor,image,indent,justify,keystrokes,link,list,newpage,pagebreak,pastefromword,pastetext,preview,print,removeformat,smiley,showblocks,sourcearea,stylescombo,table,specialchar,tab,templates,toolbar,undo,wysiwygarea,wsc',
 
 	/**
Index: /CKEditor/trunk/_source/core/dom/document.js
===================================================================
--- /CKEditor/trunk/_source/core/dom/document.js	(revision 3169)
+++ /CKEditor/trunk/_source/core/dom/document.js	(revision 3170)
@@ -168,4 +168,16 @@
 		},
 
+		getDocumentElement : function()
+		{
+			var documentElement = new CKEDITOR.dom.element( this.$.documentElement );
+
+			return (
+			/** @ignore */
+			this.getDocumentElement = function()
+				{
+					return documentElement;
+				})();
+		},
+
 		/**
 		 * Gets the window object that holds this document.
Index: /CKEditor/trunk/_source/core/dom/element.js
===================================================================
--- /CKEditor/trunk/_source/core/dom/element.js	(revision 3169)
+++ /CKEditor/trunk/_source/core/dom/element.js	(revision 3170)
@@ -1053,5 +1053,5 @@
 		},
 
-		getDocumentPosition : function()
+		getDocumentPosition : function( refDocument )
 		{
 			var x = 0, y = 0, current = this, previous = null;
@@ -1075,4 +1075,18 @@
 				current = new CKEDITOR.dom.element( current.$.offsetParent );
 			}
+			
+			if ( refDocument )
+			{
+				var currentWindow = current.getWindow(),
+					refWindow = refDocument.getWindow();
+
+				if ( !currentWindow.equals( refWindow ) && currentWindow.$.frameElement )
+				{
+					var iframePosition = ( new CKEDITOR.dom.element( currentWindow.$.frameElement ) ).getDocumentPosition( refDocument );
+					
+					x += iframePosition.x;
+					y += iframePosition.y;
+				}
+			}
 
 			// document.body is a special case when it comes to offsetTop and offsetLeft
Index: /CKEditor/trunk/_source/core/dom/node.js
===================================================================
--- /CKEditor/trunk/_source/core/dom/node.js	(revision 3169)
+++ /CKEditor/trunk/_source/core/dom/node.js	(revision 3170)
@@ -443,13 +443,34 @@
 		getAscendant : function( name, includeSelf )
 		{
-			var node = this.$;
-			if ( includeSelf && node.nodeName.toLowerCase() == name )
-				return this;
-			while ( ( node = node.parentNode ) )
-			{
-				if ( node.nodeName && node.nodeName.toLowerCase() == name )
-					return new CKEDITOR.dom.node( node );
+			var $ = this.$;
+			
+			if ( !includeSelf )
+				$ = $.parentNode;
+		
+			while ( $ )
+			{
+				if ( $.nodeName && $.nodeName.toLowerCase() == name )
+					return new CKEDITOR.dom.node( $ );
+				
+				$ = $.parentNode;
 			}
 			return null;
+		},
+
+		hasAscendant : function( name, includeSelf )
+		{
+			var $ = this.$;
+
+			if ( !includeSelf )
+				$ = $.parentNode;
+
+			while ( $ )
+			{
+				if ( $.nodeName && $.nodeName.toLowerCase() == name )
+					return true;
+				
+				$ = $.parentNode;
+			}
+			return false;
 		},
 
Index: /CKEditor/trunk/_source/core/editor.js
===================================================================
--- /CKEditor/trunk/_source/core/editor.js	(revision 3169)
+++ /CKEditor/trunk/_source/core/editor.js	(revision 3170)
@@ -98,7 +98,11 @@
 		// Set config related properties.
 
+		var skin = editor.config.skin;
+
 		editor.skinPath = CKEDITOR.getUrl(
 			'_source/' +	// %REMOVE_LINE%
-			'skins/' + editor.config.skin + '/' );
+			'skins/' + skin + '/' );
+
+		editor.skinClass = 'cke_skin_' + skin;
 
 		// Fire the "configLoaded" event.
Index: /CKEditor/trunk/_source/lang/en.js
===================================================================
--- /CKEditor/trunk/_source/lang/en.js	(revision 3169)
+++ /CKEditor/trunk/_source/lang/en.js	(revision 3170)
@@ -100,4 +100,5 @@
 	{
 		toolbar		: 'Link\u200b',		// IE6 BUG: A title called "Link" in an <A> tag would invalidate its padding!!
+		menu		: 'Edit Link',
 		title		: 'Link',
 		info		: 'Link Info',
@@ -160,4 +161,5 @@
 	{
 		toolbar		: 'Anchor',
+		menu		: 'Edit Anchor',
 		title		: 'Anchor Properties',
 		name		: 'Anchor Name',
@@ -186,4 +188,6 @@
 		toolbar		: 'Table',
 		title		: 'Table Properties',
+		menu		: 'Table Properties',
+		deleteTable	: 'Delete Table',
 		rows		: 'Rows',
 		columns		: 'Columns',
@@ -213,5 +217,34 @@
 		invalidHeight	: 'Table height must be a number.',
 		invalidCellSpacing	: 'Cell spacing must be a number.',
-		invalidCellPadding	: 'Cell padding must be a number.'
+		invalidCellPadding	: 'Cell padding must be a number.',
+
+		cell :
+		{
+			menu			: 'Cell',
+			insertBefore	: 'Insert Cell Before',
+			insertAfter		: 'Insert Cell After',
+			deleteCell		: 'Delete Cells',
+			merge			: 'Merge Cells',
+			mergeRight		: 'Merge Right',
+			mergeDown		: 'Merge Down',
+			splitHorizontal	: 'Split Cell Horizontally',
+			splitVertical	: 'Split Cell Vertically'
+		},
+
+		row :
+		{
+			menu			: 'Row',
+			insertBefore	: 'Insert Row Before',
+			insertAfter		: 'Insert Row After',
+			deleteRow		: 'Delete Rows'
+		},
+
+		column :
+		{
+			menu			: 'Column',
+			insertBefore	: 'Insert Column Before',
+			insertAfter		: 'Insert Column After',
+			deleteColumn	: 'Delete Columns'
+		}
 	},
 
@@ -240,4 +273,5 @@
 	{
 		title		: 'Form Properties',
+		menu		: 'Form Properties',
 		action		: 'Action',
 		method		: 'Method',
@@ -305,4 +339,5 @@
 		title		: 'Image Properties',
 		titleButton	: 'Image Button Properties',
+		menu		: 'Image Properties',
 		infoTab	: 'Image Info',
 		btnUpload	: 'Send it to the Server',
Index: /CKEditor/trunk/_source/plugins/clipboard/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/clipboard/plugin.js	(revision 3169)
+++ /CKEditor/trunk/_source/plugins/clipboard/plugin.js	(revision 3170)
@@ -136,21 +136,47 @@
 			init : function( editor )
 			{
-				var addButtonCommand = function ( buttonName, commandName, command )
+				function addButtonCommand( buttonName, commandName, command, ctxMenuOrder )
 				{
+					var lang = editor.lang[ commandName ];
+
 					editor.addCommand( commandName, command );
 					editor.ui.addButton( buttonName,
 						{
-							label : editor.lang[ commandName ],
+							label : lang,
 							command : commandName
 						});
+
+					// If the "menu" plugin is loaded, register the menu item.
+					if ( editor.addMenuItems )
+					{
+						editor.addMenuItem( commandName,
+							{
+								label : lang,
+								command : commandName,
+								group : 'clipboard',
+								order : ctxMenuOrder
+							});
+					}
 				}
 
-				addButtonCommand( 'Cut', 'cut', new cutCopyCmd( 'cut' ) );
-				addButtonCommand( 'Copy', 'copy', new cutCopyCmd( 'copy' ) );
-				addButtonCommand( 'Paste', 'paste', pasteCmd );
+				addButtonCommand( 'Cut', 'cut', new cutCopyCmd( 'cut' ), 1 );
+				addButtonCommand( 'Copy', 'copy', new cutCopyCmd( 'copy' ), 4 );
+				addButtonCommand( 'Paste', 'paste', pasteCmd, 8 );
 
 				CKEDITOR.dialog.add( 'paste', CKEDITOR.getUrl( this.path + 'dialogs/paste.js' ) );
 
 				editor.on( 'key', onKey, editor );
+
+				// If the "contextmenu" plugin is loaded, register the listeners.
+				if ( editor.contextMenu )
+				{
+					editor.contextMenu.addListener( function()
+						{
+							return {
+								cut : CKEDITOR.TRISTATE_DISABLED ,
+								copy : CKEDITOR.TRISTATE_DISABLED, 
+								paste : CKEDITOR.TRISTATE_DISABLED };
+						});
+				}
 			}
 		});
Index: /CKEditor/trunk/_source/plugins/contextmenu/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/contextmenu/plugin.js	(revision 3170)
+++ /CKEditor/trunk/_source/plugins/contextmenu/plugin.js	(revision 3170)
@@ -0,0 +1,129 @@
+/*
+Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.html or http://ckeditor.com/license
+*/
+
+CKEDITOR.plugins.add( 'contextmenu',
+{
+	requires : [ 'menu' ],
+
+	beforeInit : function( editor )
+	{
+		editor.contextMenu = new CKEDITOR.plugins.contextMenu( editor );
+	}
+});
+
+CKEDITOR.plugins.contextMenu = CKEDITOR.tools.createClass(
+{
+	$ : function( editor )
+	{
+		this.id = 'cke_' + CKEDITOR.tools.getNextNumber();
+		this.editor = editor;
+		this._ =
+		{
+			listeners : [],
+
+			functionId : CKEDITOR.tools.addFunction( function( commandName )
+				{
+					this._.panel.hide();
+					editor.focus();
+					editor.execCommand( commandName );
+				},
+				this)
+		}
+	},
+
+	_ :
+	{
+		onMenu : function( domEvent )
+		{
+			// Cancel the browser context menu.
+			domEvent.preventDefault();
+
+			var menu = this._.menu,
+				editor = this.editor;
+
+			if ( menu )
+			{
+				menu.hide();
+				menu.removeAll();
+			}
+			else
+			{
+				menu = this._.menu = new CKEDITOR.menu( editor );
+				menu.onClick = function( item )
+				{
+					menu.hide();
+					editor.focus();
+
+					if ( item.onClick )
+						item.onClick();
+					else if ( item.command )
+						editor.execCommand( item.command );
+				};
+			}
+
+			var listeners = this._.listeners,
+				includedItems = [];
+
+			var selection = this.editor.getSelection(),
+				element = selection && selection.getStartElement();
+
+			// Call all listeners, filling the list of items to be displayed.
+			for ( var i = 0 ; i < listeners.length ; i++ )
+			{
+				var listenerItems = listeners[ i ]( element, selection );
+
+				if ( listenerItems )
+				{
+					for ( var itemName in listenerItems )
+					{
+						var item = this.editor.getMenuItem( itemName );
+
+						if ( item )
+						{
+							item.state = listenerItems[ itemName ];
+							menu.add( item );
+						}
+					}
+				}
+			}
+
+			menu.show( domEvent.getTarget().getDocument().getDocumentElement(), 1, domEvent.$.clientX, domEvent.$.clientY );
+		}
+	},
+
+	proto :
+	{
+		addTarget : function( element )
+		{
+			element.on( 'contextmenu', function( event )
+				{
+					return this._.onMenu( event.data );
+				},
+				this );
+		},
+
+		addListener : function( listenerFn )
+		{
+			this._.listeners.push( listenerFn );
+		}
+	}
+});
+
+// Fix the "contextmenu" event for DOM elements.
+// We may do this if we identify browsers that don't support the context meny
+// event on element directly. Leaving here for reference.
+//if ( <specific browsers> )
+//{
+//	CKEDITOR.dom.element.prototype.on = CKEDITOR.tools.override( CKEDITOR.dom.element.prototype.on, function( originalOn )
+//		{
+//			return function( eventName )
+//				{
+//					if ( eventName != 'contextmenu' )
+//						return originalOn.apply( this, arguments );
+//
+//					// TODO : Implement the fix.
+//				};
+//		});
+//}
Index: /CKEditor/trunk/_source/plugins/flash/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/flash/plugin.js	(revision 3169)
+++ /CKEditor/trunk/_source/plugins/flash/plugin.js	(revision 3170)
@@ -71,4 +71,28 @@
 				}
 			} );
+
+		// If the "menu" plugin is loaded, register the menu items.
+		if ( editor.addMenuItems )
+		{
+			editor.addMenuItems(
+				{
+					flash :
+					{
+						label : editor.lang.flash.properties,
+						command : 'flash',
+						group : 'flash'
+					}
+				});
+		}
+
+		// If the "contextmenu" plugin is loaded, register the listeners.
+		if ( editor.contextMenu )
+		{
+			editor.contextMenu.addListener( function( element, selection )
+				{
+					if ( element && element.is( 'img' ) && element.getAttribute( '_cke_real_element_type' ) == 'flash' )
+						return { flash : CKEDITOR.TRISTATE_OFF };
+				});
+		}
 	},
 
Index: /CKEditor/trunk/_source/plugins/floatpanel/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/floatpanel/plugin.js	(revision 3169)
+++ /CKEditor/trunk/_source/plugins/floatpanel/plugin.js	(revision 3170)
@@ -13,5 +13,5 @@
 	var panels = {};
 
-	function getPanel( doc, parentElement, definition )
+	function getPanel( doc, parentElement, definition, level )
 	{
 		// Generates the panel key: docId-eleId-CSSs
@@ -19,5 +19,6 @@
 			doc.getUniqueId() +
 			'-' + parentElement.getUniqueId() +
-			( ( definition.css && ( '-' + definition.css ) ) || '' );
+			( ( definition.css && ( '-' + definition.css ) ) || '' ) +
+			( ( level && ( '-' + level ) ) || '' );
 
 		var panel = panels[ key ];
@@ -40,21 +41,24 @@
 	CKEDITOR.ui.floatPanel = CKEDITOR.tools.createClass(
 	{
-		$ : function( parentElement, definition )
+		$ : function( parentElement, definition, level )
 		{
 			definition.forceIFrame = true;
 
 			var doc = parentElement.getDocument(),
-				panel = getPanel( doc, parentElement, definition ),
+				panel = getPanel( doc, parentElement, definition, level || 0 ),
 				element = panel.element,
 				iframe = element.getFirst();
 
 			this.element = element;
-
+			
 			this._ =
 			{
 				// The panel that will be floating.
 				panel : panel,
+				parentElement : parentElement,
+				definition : definition,
 				document : doc,
-				iframe : iframe
+				iframe : iframe,
+				children : []
 			}
 		},
@@ -72,4 +76,9 @@
 			},
 
+			getBlock : function( name )
+			{
+				return this._.panel.getBlock( name );
+			},
+
 			showBlock : function( name, offsetParent, corner, offsetX, offsetY )
 			{
@@ -79,5 +88,5 @@
 				var element = this.element,
 					iframe = this._.iframe,
-					position = offsetParent.getDocumentPosition();
+					position = offsetParent.getDocumentPosition( element.getDocument() );
 
 				var left	= position.x + ( offsetX || 0 ),
@@ -103,5 +112,5 @@
 						element.setStyle( 'height', block.element.$.scrollHeight + 'px' );
 					}
-					
+
 					if ( !CKEDITOR.env.gecko || panel.isLoaded )
 						setHeight();
@@ -118,5 +127,17 @@
 					var focused = CKEDITOR.env.ie ? iframe : new CKEDITOR.dom.window( iframe.$.contentWindow );
 
-					focused.on( 'blur', CKEDITOR.tools.bind( this.hide, this ) );
+					focused.on( 'blur', function()
+						{
+							if ( !this._.activeChild )
+								this.hide();
+						},
+						this );
+
+					focused.on( 'focus', function()
+						{
+							this._.focused = true;
+							this.hideChild();
+						},
+						this );
 
 					this._.blurSet = 1;
@@ -136,5 +157,43 @@
 			{
 				if ( !this.onHide || this.onHide.call( this ) !== true )
+				{
+					this.hideChild();
 					this.element.setStyle( 'display', 'none' );
+				}
+			},
+			
+			showAsChild : function( panel, blockName, offsetParent, corner, offsetX, offsetY )
+			{
+				this.hideChild();
+				
+				panel.onHide = CKEDITOR.tools.bind( function()
+					{
+						// Use a timeout, so we give time for this menu to get
+						// potentially focused.
+						CKEDITOR.tools.setTimeout( function()
+							{
+								if ( !this._.focused )
+									this.hide();
+							},
+							0, this );
+					},
+					this );
+				
+				this._.activeChild = panel;
+				this._.focused = false;
+				
+				panel.showBlock( blockName, offsetParent, corner, offsetX, offsetY );
+			},
+			
+			hideChild : function()
+			{
+				var activeChild = this._.activeChild;
+				
+				if ( activeChild )
+				{
+					delete activeChild.onHide;
+					delete this._.activeChild;
+					activeChild.hide();
+				}
 			}
 		}
Index: /CKEditor/trunk/_source/plugins/forms/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/forms/plugin.js	(revision 3169)
+++ /CKEditor/trunk/_source/plugins/forms/plugin.js	(revision 3170)
@@ -12,4 +12,6 @@
 	init : function( editor )
 	{
+		var lang = editor.lang;
+
 		editor.addCss(
 			'form' +
@@ -18,4 +20,5 @@
 				'padding: 2px;' +
 			'}' );
+
 		// All buttons use the same code to register. So, to avoid
 		// duplications, let's use this tool function.
@@ -26,5 +29,5 @@
 			editor.ui.addButton( buttonName,
 				{
-					label : editor.lang.common[ buttonName.charAt(0).toLowerCase() + buttonName.slice(1) ],
+					label : lang.common[ buttonName.charAt(0).toLowerCase() + buttonName.slice(1) ],
 					command : commandName
 				});
@@ -43,4 +46,120 @@
 		addButtonCommand( 'HiddenField',	'hiddenfield',	dialogPath + 'hiddenfield.js' );
 
+		// If the "menu" plugin is loaded, register the menu items.
+		if ( editor.addMenuItems )
+		{
+			editor.addMenuItems(
+				{
+					form :
+					{
+						label : lang.form.menu,
+						command : 'form',
+						group : 'form'
+					},
+
+					checkbox :
+					{
+						label : lang.checkboxAndRadio.checkboxTitle,
+						command : 'checkbox',
+						group : 'checkbox'
+					},
+
+					radio :
+					{
+						label : lang.checkboxAndRadio.radioTitle,
+						command : 'radio',
+						group : 'radio'
+					},
+
+					textfield :
+					{
+						label : lang.textfield.title,
+						command : 'textfield',
+						group : 'textfield'
+					},
+
+					hiddenfield :
+					{
+						label : lang.hidden.title,
+						command : 'hiddenfield',
+						group : 'hiddenfield'
+					},
+
+					imagebutton :
+					{
+						label : lang.image.titleButton,
+						command : 'imagebutton',
+						group : 'imagebutton'
+					},
+
+					button :
+					{
+						label : lang.button.title,
+						command : 'button',
+						group : 'button'
+					},
+
+					select :
+					{
+						label : lang.select.title,
+						command : 'select',
+						group : 'select'
+					},
+
+					textarea :
+					{
+						label : lang.textarea.title,
+						command : 'textarea',
+						group : 'textarea'
+					}
+				});
+		}
+
+		// If the "contextmenu" plugin is loaded, register the listeners.
+		if ( editor.contextMenu )
+		{
+			editor.contextMenu.addListener( function( element )
+				{
+					if ( element && element.hasAscendant( 'form' ) )
+						return { form : CKEDITOR.TRISTATE_OFF };
+				});
+
+			editor.contextMenu.addListener( function( element )
+				{
+					if ( element )
+					{
+						var name = element.getName();
+						
+						if ( name == 'select' )
+							return { select : CKEDITOR.TRISTATE_OFF };
+
+						if ( name == 'textarea' )
+							return { textarea : CKEDITOR.TRISTATE_OFF };
+						
+						if ( name == 'input' )
+						{
+							var type = element.getAttribute( 'type' );
+
+							if ( type == 'text' || type == 'password' )
+								return { textfield : CKEDITOR.TRISTATE_OFF };
+
+							if ( type == 'button' || type == 'submit' || type == 'reset' )
+								return { button : CKEDITOR.TRISTATE_OFF };
+
+							if ( type == 'checkbox' )
+								return { checkbox : CKEDITOR.TRISTATE_OFF };
+
+							if ( type == 'radio' )
+								return { radio : CKEDITOR.TRISTATE_OFF };
+
+							if ( type == 'image' )
+								return { imagebutton : CKEDITOR.TRISTATE_OFF };
+						}
+
+						if ( name == 'img' && element.getAttribute( '_cke_real_element_type' ) == 'hiddenfield' )
+							return { hiddenfield : CKEDITOR.TRISTATE_OFF };
+					}
+				});
+		}
 	},
 	requires : [ 'image' ]
Index: /CKEditor/trunk/_source/plugins/image/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/image/plugin.js	(revision 3169)
+++ /CKEditor/trunk/_source/plugins/image/plugin.js	(revision 3170)
@@ -26,4 +26,30 @@
 				command : pluginName
 			});
+
+		// If the "menu" plugin is loaded, register the menu items.
+		if ( editor.addMenuItems )
+		{
+			editor.addMenuItems(
+				{
+					image :
+					{
+						label : editor.lang.image.menu,
+						command : 'image',
+						group : 'image'
+					}
+				});
+		}
+
+		// If the "contextmenu" plugin is loaded, register the listeners.
+		if ( editor.contextMenu )
+		{
+			editor.contextMenu.addListener( function( element, selection )
+				{
+					if ( !element || !element.is( 'img' ) || element.getAttribute( '_cke_realelement' ) )
+						return;
+
+					return { image : CKEDITOR.TRISTATE_OFF };
+				});
+		}
 	}
 } );
Index: /CKEditor/trunk/_source/plugins/link/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/link/plugin.js	(revision 3169)
+++ /CKEditor/trunk/_source/plugins/link/plugin.js	(revision 3170)
@@ -81,5 +81,59 @@
 						anchor.addClass( 'cke_anchor' );
 				}
-			} );
+			});
+
+		// If the "menu" plugin is loaded, register the menu items.
+		if ( editor.addMenuItems )
+		{
+			editor.addMenuItems(
+				{
+					anchor :
+					{
+						label : editor.lang.anchor.menu,
+						command : 'anchor',
+						group : 'anchor'
+					},
+
+					link :
+					{
+						label : editor.lang.link.menu,
+						command : 'link',
+						group : 'link',
+						order : 1
+					},
+
+					unlink :
+					{
+						label : editor.lang.unlink,
+						command : 'unlink',
+						group : 'link',
+						order : 5
+					}
+				});
+		}
+
+		// If the "contextmenu" plugin is loaded, register the listeners.
+		if ( editor.contextMenu )
+		{
+			editor.contextMenu.addListener( function( element, selection )
+				{
+					if ( !element )
+						return;
+
+					var isAnchor = ( element.is( 'img' ) && element.getAttribute( '_cke_real_element_type' ) == 'anchor' );
+
+					if ( !isAnchor )
+					{
+						if ( !( element = element.getAscendant( 'a', true ) ) )
+							return;
+
+						isAnchor = ( element.getAttribute( 'name' ) && !element.getAttribute( 'href' ) );
+					}
+
+					return isAnchor ? 
+							{ anchor : CKEDITOR.TRISTATE_OFF } : 
+							{ link : CKEDITOR.TRISTATE_OFF, unlink : CKEDITOR.TRISTATE_OFF };
+				});
+		}
 	},
 
Index: /CKEditor/trunk/_source/plugins/menu/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/menu/plugin.js	(revision 3170)
+++ /CKEditor/trunk/_source/plugins/menu/plugin.js	(revision 3170)
@@ -0,0 +1,307 @@
+/*
+Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.html or http://ckeditor.com/license
+*/
+
+CKEDITOR.plugins.add( 'menu',
+{
+	beforeInit : function( editor )
+	{
+		var groups = editor.config.menu_groups.split( ',' ),
+			groupsOrder = {};
+
+		for ( var i = 0 ; i < groups.length ; i++ )
+			groupsOrder[ groups[ i ] ] = i + 1;
+
+		editor._.menuGroups = groupsOrder;
+		editor._.menuItems = {};
+	}
+});
+
+CKEDITOR.tools.extend( CKEDITOR.editor.prototype,
+{
+	addMenuItem : function( name, definition )
+	{
+		if ( this._.menuGroups[ definition.group ] )
+			this._.menuItems[ name ] = new CKEDITOR.menuItem( this, name, definition );
+	},
+
+	addMenuItems : function( definitions )
+	{
+		for ( var itemName in definitions )
+		{
+			this.addMenuItem( itemName, definitions[ itemName ] );
+		}
+	},
+
+	getMenuItem : function( name )
+	{
+		return this._.menuItems[ name ];
+	}
+});
+
+(function()
+{
+	CKEDITOR.menu = CKEDITOR.tools.createClass(
+	{
+		$ : function( editor, level )
+		{
+			this.id = 'cke_' + CKEDITOR.tools.getNextNumber();
+
+			this.editor = editor;
+			this.items = [];
+
+			this._ =
+			{
+				level : level || 1
+			};
+		},
+
+		_ :
+		{
+			showSubMenu : function( index )
+			{
+				var menu = this._.subMenu,
+					item = this.items[ index ],
+					subItems = item.getItems && item.getItems();
+
+				// If this item has no subitems, we just hide the submenu, if
+				// available, and return back.
+				if ( !subItems )
+				{
+					this._.panel.hideChild();
+					return;
+				}
+
+				// Create the submenu, if not available, or clean the existing
+				// one.
+				if ( menu )
+					menu.removeAll();
+				else
+				{
+					menu = this._.subMenu = new CKEDITOR.menu( this.editor, this._.level + 1 );
+					menu.parent = this;
+					menu.onClick = CKEDITOR.tools.bind( this.onClick, this );
+				}
+
+				// Add all submenu items to the menu.
+				for ( var itemName in subItems )
+				{
+					menu.add( this.editor.getMenuItem( itemName ) );
+				}
+
+				// Get the element representing the current item.
+				var element = this._.panel.getBlock( this.id ).element.getDocument().getById( this.id + String( index ) );
+
+				// Show the submenu.
+				menu.show( element, 2 );
+			}
+		},
+
+		proto :
+		{
+			add : function( item )
+			{
+				this.items.push( item );
+			},
+
+			removeAll : function()
+			{
+				this.items = [];
+			},
+
+			show : function( offsetParent, corner, offsetX, offsetY )
+			{
+				var items = this.items,
+					editor = this.editor,
+					panel = this._.panel,
+					element = this._.element;
+
+				// Create the floating panel for this menu.
+				if ( !panel )
+				{
+					panel = this._.panel = new CKEDITOR.ui.floatPanel( CKEDITOR.document.getBody(),
+						{
+							css : [ CKEDITOR.getUrl( editor.skinPath + 'editor.css' ) ],
+							level : this._.level - 1,
+							className : editor.skinClass + ' cke_contextmenu'
+						},
+						this._.level);
+
+					// Create an autosize block inside the panel.
+					var block = panel.addBlock( this.id );
+					block.autoSize = true;
+
+					element = this._.element = block.element;
+					element.addClass( editor.skinClass );
+					element.getDocument().getBody().setStyle( 'overflow', 'hidden' );
+
+					this._.itemOverFn = CKEDITOR.tools.addFunction( function( index )
+						{
+							clearTimeout( this._.showSubTimeout );
+							this._.showSubTimeout = CKEDITOR.tools.setTimeout( this._.showSubMenu, editor.config.menu_subMenuDelay, this, [ index ] );
+						},
+						this);
+
+					this._.itemOutFn = CKEDITOR.tools.addFunction( function( index )
+						{
+							clearTimeout( this._.showSubTimeout );
+						},
+						this);
+
+					this._.itemClickFn = CKEDITOR.tools.addFunction( function( index )
+						{
+							var item = this.items[ index ];
+
+							if ( item.getItems )
+								this._.showSubMenu( index );
+							else
+								this.onClick && this.onClick( item );
+						},
+						this);
+				}
+
+				// Put the items in the right order.
+				sortItems( items );
+
+				// Build the HTML that composes the menu and its items.
+				var output = [ '<div class="cke_menu">' ];
+
+				var length = items.length,
+					lastGroup = length && items[ 0 ].group;
+
+				for ( var i = 0 ; i < length ; i++ )
+				{
+					var item = items[ i ];
+					if ( lastGroup != item.group )
+					{
+						output.push( '<div class="cke_menuseparator"></div>' );
+						lastGroup = item.group;
+					}
+
+					item.render( this, i, output );
+				}
+
+				output.push( '</div>' );
+
+				// Inject the HTML inside the panel.
+				element.setHtml( output.join( '' ) );
+
+				// Show the panel.
+				if ( this.parent )
+					this.parent._.panel.showAsChild( panel, this.id, offsetParent, corner, offsetX, offsetY );
+				else
+					panel.showBlock( this.id, offsetParent, corner, offsetX, offsetY );
+			},
+
+			hide : function()
+			{
+				this._.panel && this._.panel.hide();
+			}
+		}
+	});
+
+	function sortItems( items )
+	{
+		items.sort( function( itemA, itemB )
+			{
+				if ( itemA.group < itemB.group )
+					return -1;
+				else if ( itemA.group > itemB.group )
+					return 1;
+
+				return itemA.order < itemB.order ? -1 :
+					itemA.order > itemB.order ? 1 :
+					0;
+			});
+	}
+})();
+
+CKEDITOR.menuItem = CKEDITOR.tools.createClass(
+{
+	$ : function( editor, name, definition )
+	{
+		CKEDITOR.tools.extend( this, definition,
+			// Defaults
+			{
+				order : 0,
+				className : 'cke_button_' + name
+			});
+
+		// Transform the group name into its order number.
+		this.group = editor._.menuGroups[ this.group ];
+
+		this.editor = editor;
+		this.name = name;
+	},
+
+	proto :
+	{
+		render : function( menu, index, output )
+		{
+			var id = menu.id + String( index ),
+				classes = 'cke_menuitem',
+				state = this.state || CKEDITOR.TRISTATE_OFF;
+
+			classes += ' cke_' + (
+				state == CKEDITOR.TRISTATE_ON ? 'on' :
+				state == CKEDITOR.TRISTATE_DISABLED ? 'disabled' :
+				'off' );
+
+			if ( this.className )
+				classes += ' ' + this.className;
+
+			output.push(
+				'<a id="', id, '"' +
+					' class="', classes, '" href="javascript:void(\'', ( this.label || '' ).replace( "'", '' ), '\')"' +
+					' title="', this.label, '"' +
+					' tabindex="-1"' +
+					' hidefocus="true"' );
+
+			// Some browsers don't cancel key events in the keydown but in the
+			// keypress.
+			// TODO: Check if really needed for Gecko+Mac.
+			if ( CKEDITOR.env.opera || ( CKEDITOR.env.gecko && CKEDITOR.env.mac ) )
+			{
+				output.push(
+					' onkeypress="return false;"' );
+			}
+
+			// With Firefox, we need to force the button to redraw, otherwise it
+			// will remain in the focus state.
+			if ( CKEDITOR.env.gecko )
+			{
+				output.push(
+					' onblur="this.style.cssText = this.style.cssText;"' );
+			}
+
+			output.push(
+//					' onkeydown="return CKEDITOR.ui.button._.keydown(', index, ', event);"' +
+					' onmouseover="CKEDITOR.tools.callFunction(', menu._.itemOverFn, ',', index, ');"' +
+					' onmouseout="CKEDITOR.tools.callFunction(', menu._.itemOutFn, ',', index, ');"' +
+					' onclick="CKEDITOR.tools.callFunction(', menu._.itemClickFn, ',', index, ');"' +
+					'>' +
+						'<span class="cke_icon"></span>' +
+						'<span class="cke_label">' );
+
+			if ( this.getItems )
+			{
+				output.push(
+							'<span class="cke_menuarrow"></span>' );
+			}
+
+			output.push(
+							this.label,
+						 '</span>' +
+				'</a>' );
+		}
+	}
+});
+
+CKEDITOR.config.menu_subMenuDelay = 400;
+CKEDITOR.config.menu_groups =
+	'clipboard,' +
+	'form,' +
+	/*'tablecell,tablerow,tablecolumn,*/'table,'+
+	'anchor,link,image,flash,' +
+	'checkbox,radio,textfield,hiddenfield,imagebutton,button,select,textarea';
Index: /CKEditor/trunk/_source/plugins/panel/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/panel/plugin.js	(revision 3169)
+++ /CKEditor/trunk/_source/plugins/panel/plugin.js	(revision 3170)
@@ -159,4 +159,9 @@
 	},
 
+	getBlock : function( name )
+	{
+		return this._.blocks[ name ];
+	},
+
 	showBlock : function( name )
 	{
Index: /CKEditor/trunk/_source/plugins/richcombo/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/richcombo/plugin.js	(revision 3169)
+++ /CKEditor/trunk/_source/plugins/richcombo/plugin.js	(revision 3170)
@@ -33,16 +33,19 @@
 
 		// We don't want the panel definition in this object.
+		var panelDefinition = this.panel || {};
 		delete this.panel;
 
 		this.id = CKEDITOR.tools.getNextNumber();
 
-		this.document = ( definition.panel
-							&& definition.panel.parent
-							&& definition.panel.parent.getDocument() )
+		this.document = ( panelDefinition
+							&& panelDefinition.parent
+							&& panelDefinition.parent.getDocument() )
 						|| CKEDITOR.document;
 
+		panelDefinition.className = ( panelDefinition.className || '' ) + ' cke_rcombopanel';
+
 		this._ =
 		{
-			panelDefinition : definition.panel,
+			panelDefinition : panelDefinition,
 			items : {}
 		};
@@ -165,5 +168,5 @@
 				return;
 
-			var panelDefinition = this._.panelDefinition || {},
+			var panelDefinition = this._.panelDefinition,
 				panelParentElement = panelDefinition.parent || CKEDITOR.document.getBody(),
 				panel = new CKEDITOR.ui.floatPanel( panelParentElement, panelDefinition ),
Index: /CKEditor/trunk/_source/plugins/stylescombo/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/stylescombo/plugin.js	(revision 3169)
+++ /CKEditor/trunk/_source/plugins/stylescombo/plugin.js	(revision 3170)
@@ -150,5 +150,5 @@
 						var selection = editor.getSelection();
 
-						if ( CKEDITOR.env.ie )
+						if ( CKEDITOR.env.ie && selection )
 						{
 							editor.focus();
Index: /CKEditor/trunk/_source/plugins/table/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/table/plugin.js	(revision 3169)
+++ /CKEditor/trunk/_source/plugins/table/plugin.js	(revision 3170)
@@ -8,5 +8,6 @@
 	init : function( editor )
 	{
-		var table = CKEDITOR.plugins.table;
+		var table = CKEDITOR.plugins.table,
+			lang = editor.lang.table;
 
 		editor.addCommand( 'table', new CKEDITOR.dialogCommand( 'table' ) );
@@ -14,5 +15,5 @@
 		editor.ui.addButton( 'Table',
 			{
-				label : editor.lang.table.toolbar,
+				label : lang.toolbar,
 				command : 'table'
 			});
@@ -20,4 +21,166 @@
 		CKEDITOR.dialog.add( 'table', this.path + 'dialogs/table.js' );
 		CKEDITOR.dialog.add( 'tableProperties', this.path + 'dialogs/table.js' );
+
+		// If the "menu" plugin is loaded, register the menu items.
+		if ( editor.addMenuItems )
+		{
+			editor.addMenuItems(
+				{
+					table :
+					{
+						label : lang.menu,
+						command : 'tableProperties',
+						group : 'table',
+						order : 5
+					},
+
+//					tabledelete :
+//					{
+//						label : lang.deleteTable,
+//						command : 'tableDelete',
+//						group : 'table',
+//						order : 1
+//					},
+
+					tablecell :
+					{
+						label : lang.cell.menu,
+						group : 'tablecell',
+						order : 1,
+						getItems : function()
+						{
+							return {
+								tablecell_insertBefore : CKEDITOR.TRISTATE_OFF,
+								tablecell_insertAfter : CKEDITOR.TRISTATE_OFF,
+								tablecell_delete : CKEDITOR.TRISTATE_OFF
+							};
+						}
+					},
+					
+					tablecell_insertBefore :
+					{
+						label : lang.cell.insertBefore,
+						group : 'tablecell',
+						order : 5
+					},
+
+					tablecell_insertAfter :
+					{
+						label : lang.cell.insertAfter,
+						group : 'tablecell',
+						order : 10
+					},
+
+					tablecell_delete :
+					{
+						label : lang.cell.deleteCell,
+						group : 'tablecell',
+						order : 15
+					},
+
+					tablerow :
+					{
+						label : lang.row.menu,
+						group : 'tablerow',
+						order : 1,
+						getItems : function()
+						{
+							return {
+								tablerow_insertBefore : CKEDITOR.TRISTATE_OFF,
+								tablerow_insertAfter : CKEDITOR.TRISTATE_OFF,
+								tablerow_delete : CKEDITOR.TRISTATE_OFF
+							};
+						}
+					},
+
+					tablerow_insertBefore :
+					{
+						label : lang.row.insertBefore,
+						group : 'tablerow',
+						order : 5
+					},
+
+					tablerow_insertAfter :
+					{
+						label : lang.row.insertAfter,
+						group : 'tablerow',
+						order : 10
+					},
+
+					tablerow_delete :
+					{
+						label : lang.row.deleteRow,
+						group : 'tablerow',
+						order : 15
+					},
+
+					tablecolumn :
+					{
+						label : lang.column.menu,
+						group : 'tablecolumn',
+						order : 1,
+						getItems : function()
+						{
+							return {
+								tablecolumn_insertBefore : CKEDITOR.TRISTATE_OFF,
+								tablecolumn_insertAfter : CKEDITOR.TRISTATE_OFF,
+								tablecolumn_delete : CKEDITOR.TRISTATE_OFF
+							};
+						}
+					},
+
+					tablecolumn_insertBefore :
+					{
+						label : lang.column.insertBefore,
+						group : 'tablecolumn',
+						order : 5
+					},
+
+					tablecolumn_insertAfter :
+					{
+						label : lang.column.insertAfter,
+						group : 'tablecolumn',
+						order : 10
+					},
+
+					tablecolumn_delete :
+					{
+						label : lang.column.deleteColumn,
+						group : 'tablecolumn',
+						order : 15
+					}
+				});
+		}
+
+		// If the "contextmenu" plugin is loaded, register the listeners.
+		if ( editor.contextMenu )
+		{
+			editor.contextMenu.addListener( function( element, selection )
+				{
+					if ( !element )
+						return;
+
+					var isTable	= element.is( 'table' ) ;
+					var isCell	= !isTable && element.hasAscendant( 'table' ) ;
+
+					if ( isTable || isCell )
+					{
+						var ret = isCell ? 
+							{ 
+								tablecell : CKEDITOR.TRISTATE_OFF,
+								tablerow : CKEDITOR.TRISTATE_OFF,
+								tablecolumn : CKEDITOR.TRISTATE_OFF 
+							}
+							: {};
+
+						ret.tabledelete = CKEDITOR.TRISTATE_OFF;
+						ret.table = CKEDITOR.TRISTATE_OFF;
+
+						return ret;
+					}
+					
+					return null;
+				});
+		}
 	}
 } );
Index: /CKEditor/trunk/_source/plugins/wysiwygarea/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/wysiwygarea/plugin.js	(revision 3169)
+++ /CKEditor/trunk/_source/plugins/wysiwygarea/plugin.js	(revision 3170)
@@ -295,4 +295,8 @@
 						editor.fire( 'contentDom' );
 
+						// Adds the document body as a context menu target.
+						if ( editor.contextMenu )
+							editor.contextMenu.addTarget( domDocument );
+
 						if ( fireMode )
 						{
Index: /CKEditor/trunk/_source/skins/default/editor.css
===================================================================
--- /CKEditor/trunk/_source/skins/default/editor.css	(revision 3169)
+++ /CKEditor/trunk/_source/skins/default/editor.css	(revision 3170)
@@ -6,8 +6,10 @@
 @import url("reset.css");
 @import url("mainui.css");
+@import url("panel.css");
 @import url("toolbar.css");
-@import url("panel.css");
+@import url("menu.css");
 @import url("richcombo.css");
 @import url("elementspath.css");
+@import url("icons.css");
 @import url("presets.css");
 
Index: /CKEditor/trunk/_source/skins/default/icons.css
===================================================================
--- /CKEditor/trunk/_source/skins/default/icons.css	(revision 3170)
+++ /CKEditor/trunk/_source/skins/default/icons.css	(revision 3170)
@@ -0,0 +1,281 @@
+/*
+Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.html or http://ckeditor.com/license
+*/
+
+.cke_skin_default a.cke_button_source .cke_icon
+{
+	background-position: 0 0;
+}
+
+.cke_skin_default a.cke_button_newpage .cke_icon
+{
+	background-position: 0 -48px;
+}
+
+.cke_skin_default a.cke_button_preview .cke_icon
+{
+	background-position: 0 -64px;
+}
+
+.cke_skin_default a.cke_button_cut .cke_icon
+{
+	background-position: 0 -96px;
+}
+
+.cke_skin_default a.cke_button_copy .cke_icon
+{
+	background-position: 0 -112px;
+}
+
+.cke_skin_default a.cke_button_paste .cke_icon
+{
+	background-position: 0 -128px;
+}
+
+.cke_skin_default a.cke_button_pastetext .cke_icon
+{
+	background-position: 0 -144px;
+}
+
+.cke_skin_default a.cke_button_find .cke_icon
+{
+	background-position: 0 -240px;
+}
+
+.cke_skin_default a.cke_button_replace .cke_icon
+{
+	background-position: 0 -256px;
+}
+
+.cke_skin_default a.cke_button_selectAll .cke_icon
+{
+	background-position: 0 -272px;
+}
+
+.cke_skin_default a.cke_button_removeFormat .cke_icon
+{
+	background-position: 0 -288px;
+}
+
+.cke_skin_default a.cke_button_bold .cke_icon
+{
+	background-position: 0 -304px;
+}
+
+.cke_skin_default a.cke_button_italic .cke_icon
+{
+	background-position: 0 -320px;
+}
+
+.cke_skin_default a.cke_button_underline .cke_icon
+{
+	background-position: 0 -336px;
+}
+
+.cke_skin_default a.cke_button_strike .cke_icon
+{
+	background-position: 0 -352px;
+}
+
+.cke_skin_default a.cke_button_subscript .cke_icon
+{
+	background-position: 0 -368px;
+}
+
+.cke_skin_default a.cke_button_superscript .cke_icon
+{
+	background-position: 0 -384px;
+}
+
+.cke_skin_default a.cke_button_table .cke_icon
+{
+	background-position: 0 -608px;
+}
+
+.cke_skin_default a.cke_button_horizontalrule .cke_icon
+{
+	background-position: 0 -624px;
+}
+
+.cke_skin_default a.cke_button_smiley .cke_icon
+{
+	background-position: 0 -640px;
+}
+
+.cke_skin_default a.cke_button_link .cke_icon
+{
+	background-position: 0 -528px;
+}
+
+.cke_skin_default a.cke_button_unlink .cke_icon
+{
+	background-position: 0 -544px;
+}
+
+.cke_skin_default a.cke_button_anchor .cke_icon
+{
+	background-position: 0 -560px;
+}
+
+.cke_skin_default a.cke_button_image .cke_icon
+{
+	background-position: 0 -576px;
+}
+
+.cke_skin_default a.cke_button_flash .cke_icon
+{
+	background-position: 0 -592px;
+}
+
+.cke_skin_default a.cke_button_specialchar .cke_icon
+{
+	background-position: 0 -656px;
+}
+
+.cke_skin_default a.cke_button_pagebreak .cke_icon
+{
+	background-position: 0 -672px;
+}
+
+.cke_skin_default a.cke_button_print .cke_icon
+{
+	background-position: 0 -176px;
+}
+
+.cke_skin_default a.cke_button_checkspell .cke_icon
+{
+	background-position: 0 -192px;
+}
+
+.cke_skin_default a.cke_button_pagebreak .cke_icon
+{
+	background-position: 0 -672px;
+}
+
+.cke_skin_default a.cke_button_textcolor .cke_icon
+{
+	background-position: 0 -704px;
+}
+
+.cke_skin_default a.cke_button_bgcolor .cke_icon
+{
+	background-position: 0 -720px;
+}
+
+.cke_skin_default a.cke_button_form .cke_icon
+{
+	background-position: 0 -752px;
+}
+
+.cke_skin_default a.cke_button_checkbox .cke_icon
+{
+	background-position: 0 -768px;
+}
+
+.cke_skin_default a.cke_button_radio .cke_icon
+{
+	background-position: 0 -784px;
+}
+
+.cke_skin_default a.cke_button_textfield .cke_icon
+{
+	background-position: 0 -800px;
+}
+
+.cke_skin_default a.cke_button_textarea .cke_icon
+{
+	background-position: 0 -816px;
+}
+.cke_skin_default a.cke_button_showblocks .cke_icon
+{
+	background-position: 0 -1136px;
+}
+
+.cke_skin_default a.cke_button_select .cke_icon
+{
+	background-position: 0 -832px;
+}
+
+.cke_skin_default a.cke_button_button .cke_icon
+{
+	background-position: 0 -848px;
+}
+
+.cke_skin_default a.cke_button_imagebutton .cke_icon
+{
+	background-position: 0 -864px;
+}
+
+.cke_skin_default a.cke_button_hiddenfield .cke_icon
+{
+	background-position: 0 -880px;
+}
+.cke_skin_default a.cke_button_undo .cke_icon
+{
+	background-position: 0 -208px;
+}
+.cke_skin_default a.cke_button_redo .cke_icon
+{
+	background-position: 0 -224px;
+}
+
+.cke_skin_default a.cke_button_templates .cke_icon
+{
+	background-position: 0 -80px;
+}
+
+.cke_skin_default a.cke_button_numberedlist .cke_icon
+{
+	background-position: 0 -400px;
+}
+
+.cke_skin_default a.cke_button_bulletedlist .cke_icon
+{
+	background-position: 0 -416px;
+}
+
+.cke_skin_default a.cke_button_outdent .cke_icon
+{
+	background-position: 0 -432px;
+}
+
+.cke_skin_default a.cke_button_indent .cke_icon
+{
+	background-position: 0 -448px;
+}
+
+.cke_skin_default a.cke_button_justifyleft .cke_icon
+{
+	background-position: 0 -464px;
+}
+
+.cke_skin_default a.cke_button_justifycenter .cke_icon
+{
+	background-position: 0 -480px;
+}
+
+.cke_skin_default a.cke_button_justifyright .cke_icon
+{
+	background-position: 0 -496px;
+}
+
+.cke_skin_default a.cke_button_justifyblock .cke_icon
+{
+	background-position: 0 -512px;
+}
+
+.cke_skin_default a.cke_button_blockquote .cke_icon
+{
+	background-position: 0 -1152px;
+}
+
+.cke_skin_default a.cke_button_flash .cke_icon
+{
+	background-position: 0 -592px;
+}
+
+.cke_skin_default a.cke_button_pastefromword .cke_icon
+{
+	background-position: 0 -160px;
+}
Index: /CKEditor/trunk/_source/skins/default/menu.css
===================================================================
--- /CKEditor/trunk/_source/skins/default/menu.css	(revision 3170)
+++ /CKEditor/trunk/_source/skins/default/menu.css	(revision 3170)
@@ -0,0 +1,86 @@
+/*
+Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.html or http://ckeditor.com/license
+*/
+
+.cke_skin_default.cke_contextmenu
+{
+    padding: 2px;
+}
+
+.cke_skin_default a.cke_menuitem
+{
+	display:block;
+}
+
+.cke_skin_default a:hover.cke_menuitem,
+.cke_skin_default a:focus.cke_menuitem
+{
+	background-color: #8f8f73;
+	display:block;
+}
+
+.cke_skin_default a.cke_menuitem.cke_disabled
+{
+	filter: alpha(opacity=30); /* IE */
+	opacity : 0.3; /* Safari, Opera and Mozilla */
+}
+
+.cke_skin_default a.cke_menuitem .cke_icon
+{
+	background-image: url(icons.gif);
+	background-position: 100px;
+	background-repeat:no-repeat;
+	background-color: #e3e3c7;
+	width: 16px;
+	height: 16px;
+	float: left;
+	border: solid 4px #e3e3c7;
+	filter: alpha(opacity=70); /* IE */
+	opacity: 0.70; /* Safari, Opera and Mozilla */
+}
+
+.cke_skin_default a:hover.cke_menuitem .cke_icon,
+.cke_skin_default a:focus.cke_menuitem .cke_icon
+{
+	background-color: #737357;
+	border: solid 4px #737357;
+	filter: alpha(opacity=100); /* IE */
+	opacity: 1; /* Safari, Opera and Mozilla */
+}
+
+.cke_skin_default a.cke_menuitem .cke_label
+{
+	display:block;
+    padding-right: 3px;
+    padding-top: 5px;
+    height:19px;
+    margin-left: 28px;
+    background-color: #fff;
+}
+
+.cke_skin_default a:hover.cke_menuitem .cke_label,
+.cke_skin_default a:focus.cke_menuitem .cke_label
+{
+	color: #fff;
+	background-color: #8f8f73;
+}
+
+.cke_skin_default .cke_menuseparator
+{
+	background-color: #e3e3c7;
+	height: 2px;
+	filter: alpha(opacity=70); /* IE */
+	opacity: 0.70; /* Safari, Opera and Mozilla */
+}
+
+.cke_skin_default .cke_menuarrow
+{
+	background-image: url(images/toolbar.arrowright.gif);
+	height: 7px;
+	width: 7px;
+	float: right;
+	margin-right: 2px;
+	margin-top: 3px;
+}
+
Index: /CKEditor/trunk/_source/skins/default/panel.css
===================================================================
--- /CKEditor/trunk/_source/skins/default/panel.css	(revision 3169)
+++ /CKEditor/trunk/_source/skins/default/panel.css	(revision 3170)
@@ -6,5 +6,5 @@
 .cke_skin_default.cke_panel
 {
-	border: 1px solid #316ac5;
+    border: 1px solid #8f8f73;
 	background-color: #fff;
 
@@ -14,144 +14,7 @@
 	overflow:hidden;
 
-	-moz-border-radius-bottomright: 3px;
-	-webkit-border-bottom-right-radius: 3px;
-	border-bottom-left-radius: 3px;
-	-moz-border-radius-bottomleft: 3px;
-	-webkit-border-bottom-left-radius: 3px;
-	border-bottom-left-radius: 3px;
-	-moz-border-radius-topright: 3px;
-	-webkit-border-top-right-radius: 3px;
-	border-top-right-radius: 3px;
-}
-
-/* Ideally we would use "inherit here"... but you know... IE :( */
-.cke_skin_default.cke_panel iframe
-{
-	width: 100%;
-	height: 100%;
-}
-
-/*
- * All the following styles are to be used inside the iframe that holds panel
- * contents. We don't use the cke_skin_default there to avoid the reset to be
- * active.
- * This is not an issue as we'll never have two skins running inside the same
- * panel iframe.
- */
-
-body.cke_panel_frame
-{
-	overflow: auto;
-	overflow-x: hidden;
-}
-
-ul.cke_panel_list
-{
-	list-style-type: none;
-	margin: 3px;
-	padding: 0px;
-    white-space: nowrap;
-}
-
-li.cke_panel_listItem
-{
-	margin: 0px;
-}
-
-.cke_panel_listItem a
-{
-	padding: 2px;
-	display: block;
-	border: 1px solid #fff;
-	color: inherit;
-	text-decoration: none;
-	overflow: hidden;
-    text-overflow: ellipsis;
-}
-
-/* IE6 */
-* html .cke_panel_listItem a
-{
-	width : 100%;
-
-	/* IE is not able to inherit the color, so we must force it to black */
-	color: #000;
-}
-
-/* IE7 */
-*:first-child+html .cke_panel_listItem a
-{
-	/* IE is not able to inherit the color, so we must force it to black */
-	color: #000;
-}
-
-.cke_panel_listItem.cke_selected a
-{
-	border: 1px solid #ccc;
-	background-color: #e9f5ff;
-}
-
-.cke_panel_listItem a:hover,
-.cke_panel_listItem a:focus,
-.cke_panel_listItem a:active
-{
-	border-color: #316ac5;
-	background-color: #dff1ff;
-}
-
-.cke_panel_grouptitle
-{
-    font-size: 11px;
-    font-family: 'Microsoft Sans Serif' , Tahoma, Arial, Verdana, Sans-Serif;
-	font-weight: bold;
-    white-space: nowrap;
-	background-color: #dcdcdc;
-	color: #000;
-	margin:0px;
-	padding:3px;
-}
-
-.cke_panel_listItem p,
-.cke_panel_listItem h1,
-.cke_panel_listItem h2,
-.cke_panel_listItem h3,
-.cke_panel_listItem h4,
-.cke_panel_listItem h5,
-.cke_panel_listItem h6,
-.cke_panel_listItem pre
-{
-	margin-top: 3px;
-	margin-bottom: 3px;
-}
-/*
-Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved.
-For licensing, see LICENSE.html or http://ckeditor.com/license
-*/
-
-.cke_skin_default.cke_panel
-{
-	border: 1px solid #316ac5;
-	background-color: #fff;
-
-	width: 120px;
-	height: 100px;
-
-	overflow:hidden;
-
-	-moz-border-radius-bottomright: 3px;
-	-webkit-border-bottom-right-radius: 3px;
-	border-bottom-left-radius: 3px;
-	-moz-border-radius-bottomleft: 3px;
-	-webkit-border-bottom-left-radius: 3px;
-	border-bottom-left-radius: 3px;
-	-moz-border-radius-topright: 3px;
-	-webkit-border-top-right-radius: 3px;
-	border-top-right-radius: 3px;
-}
-
-.cke_skin_default.cke_panel.cke_format
-{
-	width: 150px;
-	height: 170px;
+	-moz-border-radius: 3px;
+	-webkit-border-radius: 3px;
+	border-radius: 3px;
 }
 
Index: /CKEditor/trunk/_source/skins/default/presets.css
===================================================================
--- /CKEditor/trunk/_source/skins/default/presets.css	(revision 3169)
+++ /CKEditor/trunk/_source/skins/default/presets.css	(revision 3170)
@@ -3,4 +3,10 @@
 For licensing, see LICENSE.html or http://ckeditor.com/license
 */
+
+/* "Source" button label */
+.cke_skin_default a.cke_button_source .cke_label
+{
+	display: inline;
+}
 
 /* "Styles" panel size */
Index: /CKEditor/trunk/_source/skins/default/richcombo.css
===================================================================
--- /CKEditor/trunk/_source/skins/default/richcombo.css	(revision 3169)
+++ /CKEditor/trunk/_source/skins/default/richcombo.css	(revision 3170)
@@ -5,4 +5,12 @@
 	padding-right: 4px;
 	float: left;
+}
+
+.cke_skin_default.cke_rcombopanel
+{
+	border: 1px solid #316ac5;
+	-moz-border-radius-topleft: 0;
+	-webkit-border-top-left-radius: 0;
+	border-top-left-radius: 0;
 }
 
Index: /CKEditor/trunk/_source/skins/default/toolbar.css
===================================================================
--- /CKEditor/trunk/_source/skins/default/toolbar.css	(revision 3169)
+++ /CKEditor/trunk/_source/skins/default/toolbar.css	(revision 3170)
@@ -159,284 +159,2 @@
 	float: right;
 }
-
-.cke_skin_default a.cke_button_source .cke_icon
-{
-	background-position: 0 0;
-}
-
-.cke_skin_default a.cke_button_source .cke_label
-{
-	display: inline;
-}
-
-.cke_skin_default a.cke_button_newpage .cke_icon
-{
-	background-position: 0 -48px;
-}
-
-.cke_skin_default a.cke_button_preview .cke_icon
-{
-	background-position: 0 -64px;
-}
-
-.cke_skin_default a.cke_button_cut .cke_icon
-{
-	background-position: 0 -96px;
-}
-
-.cke_skin_default a.cke_button_copy .cke_icon
-{
-	background-position: 0 -112px;
-}
-
-.cke_skin_default a.cke_button_paste .cke_icon
-{
-	background-position: 0 -128px;
-}
-
-.cke_skin_default a.cke_button_pastetext .cke_icon
-{
-	background-position: 0 -144px;
-}
-
-.cke_skin_default a.cke_button_find .cke_icon
-{
-	background-position: 0 -240px;
-}
-
-.cke_skin_default a.cke_button_replace .cke_icon
-{
-	background-position: 0 -256px;
-}
-
-.cke_skin_default a.cke_button_selectAll .cke_icon
-{
-	background-position: 0 -272px;
-}
-
-.cke_skin_default a.cke_button_removeFormat .cke_icon
-{
-	background-position: 0 -288px;
-}
-
-.cke_skin_default a.cke_button_bold .cke_icon
-{
-	background-position: 0 -304px;
-}
-
-.cke_skin_default a.cke_button_italic .cke_icon
-{
-	background-position: 0 -320px;
-}
-
-.cke_skin_default a.cke_button_underline .cke_icon
-{
-	background-position: 0 -336px;
-}
-
-.cke_skin_default a.cke_button_strike .cke_icon
-{
-	background-position: 0 -352px;
-}
-
-.cke_skin_default a.cke_button_subscript .cke_icon
-{
-	background-position: 0 -368px;
-}
-
-.cke_skin_default a.cke_button_superscript .cke_icon
-{
-	background-position: 0 -384px;
-}
-
-.cke_skin_default a.cke_button_table .cke_icon
-{
-	background-position: 0 -608px;
-}
-
-.cke_skin_default a.cke_button_horizontalrule .cke_icon
-{
-	background-position: 0 -624px;
-}
-
-.cke_skin_default a.cke_button_smiley .cke_icon
-{
-	background-position: 0 -640px;
-}
-
-.cke_skin_default a.cke_button_link .cke_icon
-{
-	background-position: 0 -528px;
-}
-
-.cke_skin_default a.cke_button_unlink .cke_icon
-{
-	background-position: 0 -544px;
-}
-
-.cke_skin_default a.cke_button_anchor .cke_icon
-{
-	background-position: 0 -560px;
-}
-
-.cke_skin_default a.cke_button_image .cke_icon
-{
-	background-position: 0 -576px;
-}
-
-.cke_skin_default a.cke_button_flash .cke_icon
-{
-	background-position: 0 -592px;
-}
-
-.cke_skin_default a.cke_button_specialchar .cke_icon
-{
-	background-position: 0 -656px;
-}
-
-.cke_skin_default a.cke_button_pagebreak .cke_icon
-{
-	background-position: 0 -672px;
-}
-
-.cke_skin_default a.cke_button_print .cke_icon
-{
-	background-position: 0 -176px;
-}
-
-.cke_skin_default a.cke_button_checkspell .cke_icon
-{
-	background-position: 0 -192px;
-}
-
-.cke_skin_default a.cke_button_pagebreak .cke_icon
-{
-	background-position: 0 -672px;
-}
-
-.cke_skin_default a.cke_button_textcolor .cke_icon
-{
-	background-position: 0 -704px;
-}
-
-.cke_skin_default a.cke_button_bgcolor .cke_icon
-{
-	background-position: 0 -720px;
-}
-
-.cke_skin_default a.cke_button_form .cke_icon
-{
-	background-position: 0 -752px;
-}
-
-.cke_skin_default a.cke_button_checkbox .cke_icon
-{
-	background-position: 0 -768px;
-}
-
-.cke_skin_default a.cke_button_radio .cke_icon
-{
-	background-position: 0 -784px;
-}
-
-.cke_skin_default a.cke_button_textfield .cke_icon
-{
-	background-position: 0 -800px;
-}
-
-.cke_skin_default a.cke_button_textarea .cke_icon
-{
-	background-position: 0 -816px;
-}
-.cke_skin_default a.cke_button_showblocks .cke_icon
-{
-	background-position: 0 -1136px;
-}
-
-.cke_skin_default a.cke_button_select .cke_icon
-{
-	background-position: 0 -832px;
-}
-
-.cke_skin_default a.cke_button_button .cke_icon
-{
-	background-position: 0 -848px;
-}
-
-.cke_skin_default a.cke_button_imagebutton .cke_icon
-{
-	background-position: 0 -864px;
-}
-
-.cke_skin_default a.cke_button_hiddenfield .cke_icon
-{
-	background-position: 0 -880px;
-}
-.cke_skin_default a.cke_button_undo .cke_icon
-{
-	background-position: 0 -208px;
-}
-.cke_skin_default a.cke_button_redo .cke_icon
-{
-	background-position: 0 -224px;
-}
-
-.cke_skin_default a.cke_button_templates .cke_icon
-{
-	background-position: 0 -80px;
-}
-
-.cke_skin_default a.cke_button_numberedlist .cke_icon
-{
-	background-position: 0 -400px;
-}
-
-.cke_skin_default a.cke_button_bulletedlist .cke_icon
-{
-	background-position: 0 -416px;
-}
-
-.cke_skin_default a.cke_button_outdent .cke_icon
-{
-	background-position: 0 -432px;
-}
-
-.cke_skin_default a.cke_button_indent .cke_icon
-{
-	background-position: 0 -448px;
-}
-
-.cke_skin_default a.cke_button_justifyleft .cke_icon
-{
-	background-position: 0 -464px;
-}
-
-.cke_skin_default a.cke_button_justifycenter .cke_icon
-{
-	background-position: 0 -480px;
-}
-
-.cke_skin_default a.cke_button_justifyright .cke_icon
-{
-	background-position: 0 -496px;
-}
-
-.cke_skin_default a.cke_button_justifyblock .cke_icon
-{
-	background-position: 0 -512px;
-}
-
-.cke_skin_default a.cke_button_blockquote .cke_icon
-{
-	background-position: 0 -1152px;
-}
-
-.cke_skin_default a.cke_button_flash .cke_icon
-{
-	background-position: 0 -592px;
-}
-
-.cke_skin_default a.cke_button_pastefromword .cke_icon
-{
-	background-position: 0 -160px;
-}
Index: /CKEditor/trunk/_source/themes/default/theme.js
===================================================================
--- /CKEditor/trunk/_source/themes/default/theme.js	(revision 3169)
+++ /CKEditor/trunk/_source/themes/default/theme.js	(revision 3170)
@@ -57,5 +57,5 @@
 			// differently by the browsers ("semi-inline").
 			var container = CKEDITOR.dom.element.createFromHtml( [
-				'<span id="cke_', name, '" onmousedown="return false;" class="cke_container cke_skin_', editor.config.skin, ' ', browserCssClass,
+				'<span id="cke_', name, '" onmousedown="return false;" class="cke_container ', editor.skinClass, ' ', browserCssClass,
 					' cke_', editor.lang.dir, '" dir="', editor.lang.dir, '" title="', ( CKEDITOR.env.gecko ? ' ' : '' ), '">' +
 					'<table class="cke_editor" border="0" cellspacing="0" cellpadding="0" style="width:', width, ';height:', height, '"><tbody>' +
Index: /CKEditor/trunk/ckeditor.pack
===================================================================
--- /CKEditor/trunk/ckeditor.pack	(revision 3169)
+++ /CKEditor/trunk/ckeditor.pack	(revision 3170)
@@ -123,4 +123,5 @@
 					'_source/plugins/clipboard/plugin.js',
 					'_source/plugins/colorbutton/plugin.js',
+					'_source/plugins/contextmenu/plugin.js',
 					'_source/plugins/elementspath/plugin.js',
 					'_source/plugins/find/plugin.js',
@@ -155,8 +156,10 @@
 					'_source/plugins/undo/plugin.js',
 					'_source/plugins/wysiwygarea/plugin.js',
+					'_source/plugins/wsc/plugin.js',
 					'_source/plugins/styles/plugin.js',
 					'_source/plugins/domiterator/plugin.js',
 					'_source/plugins/panelbutton/plugin.js',
 					'_source/plugins/floatpanel/plugin.js',
+					'_source/plugins/menu/plugin.js',
 					'_source/plugins/selection/plugin.js',
 					'_source/plugins/fakeobjects/plugin.js',
