Index: /CKEditor/branches/prototype/_source/plugins/dialog/plugin.js
===================================================================
--- /CKEditor/branches/prototype/_source/plugins/dialog/plugin.js	(revision 2440)
+++ /CKEditor/branches/prototype/_source/plugins/dialog/plugin.js	(revision 2441)
@@ -131,6 +131,7 @@
 			'title' : [1,1,0],
 			'tabs' : [1,1,1],
-			'contents' : [1,1,2],
-			'buttons' : [1,1,3]
+			'bridge' : [1,1,2],
+			'contents' : [1,1,3],
+			'buttons' : [1,1,4]
 		};
 		for ( var i in this._.parts )
@@ -146,5 +147,4 @@
 		for ( var i = 0 ; i < definition.contents.length ; i++ )
 			this.addPage( definition.contents[i] );
-		this.selectPage( definition.contents[0].id );
 
 		var classRegex = /cke_dialog_tab(\s|$|_)/;
@@ -245,4 +245,7 @@
 		var viewSize = CKEDITOR.document.getWindow().getViewPaneSize();
 		this.move( ( viewSize.width - this._.size.width ) / 2, ( viewSize.height - this._.size.height ) / 2 );
+		
+		// Select the first tab by default.
+		this.selectPage( this._.definition.contents[0].id );
 	},
 
@@ -277,14 +280,12 @@
 	selectPage : function( id )
 	{
+		var bridge = this._.parts.bridge;
+
+		// Hide the non-selected tabs and pages.
 		for ( var i in this._.tabs )
 		{
 			var tab = this._.tabs[i][0],
 				page = this._.tabs[i][1];
-			if ( i == id )
-			{
-				tab.addClass( 'cke_dialog_tab_selected');
-				page.show();
-			}
-			else
+			if ( i != id )
 			{
 				tab.removeClass( 'cke_dialog_tab_selected' );
@@ -292,4 +293,15 @@
 			}
 		}
+
+		var selected = this._.tabs[id];
+		selected[0].addClass( 'cke_dialog_tab_selected' );
+		// Place the bridge just under the selected tab. Count 1px left and right
+		// of the tab as border space.
+		bridge.setStyles(
+				{
+					left : ( selected[0].getFirst().$.offsetLeft + 17 || 0 ) + 'px',
+					width : ( selected[0].getFirst().$.offsetWidth - 2 || 0 ) + 'px'
+				});
+		selected[1].show();
 	}
 };
Index: /CKEditor/branches/prototype/_source/skins/default/dialog.css
===================================================================
--- /CKEditor/branches/prototype/_source/skins/default/dialog.css	(revision 2440)
+++ /CKEditor/branches/prototype/_source/skins/default/dialog.css	(revision 2441)
@@ -170,5 +170,4 @@
 	clear: both;
 	padding-left: 10px;
-	z-index: 1;
 	/*
 	 * IE6 and IE7+ quirks mode do not support CSS right and bottom attributes
@@ -188,6 +187,8 @@
 	right: 16px;
 	border: #d5d59d 1px solid;
-	_width: expression(this.offsetParent.offsetWidth - 34);		/* 16px left cell + 16px right cell + 1px left border + 1px right border */
-	_height: expression(this.offsetParent.offsetHeight - 107);	/* 16px top cell + 51px bottom cell + 1px top border + 1px bottom border */
+	#width: expression(this.offsetParent.offsetWidth - 34);		/* 16px left cell + 16px right cell + 1px left border + 1px right border */
+	#height: expression(this.offsetParent.offsetHeight - 107);	/* 16px top cell + 51px bottom cell + 1px top border + 1px bottom border */
+	#bottom: default;
+	#right: default;
 }
 
@@ -250,4 +251,14 @@
 	background-color: #f1f1e3;
 	font-weight: bold;
-	padding: 5px 5px 3px 5px;
-}
+}
+
+.cke_skin_default .cke_dialog_tabs_bridge
+{
+	background-color: #f1f1e3;
+	height: 1px;
+	position: absolute;
+	top: 54px;
+	left: 0px;
+	width: 0px;
+	z-index: 1;
+}
Index: /CKEditor/branches/prototype/_source/themes/default/theme.js
===================================================================
--- /CKEditor/branches/prototype/_source/themes/default/theme.js	(revision 2440)
+++ /CKEditor/branches/prototype/_source/themes/default/theme.js	(revision 2441)
@@ -116,4 +116,5 @@
 							'<div id="cke_dialog_title_%d" class="cke_dialog_title"></div>',
 							'<div id="cke_dialog_tabs_%d" class="cke_dialog_tabs"></div>',
+							'<div id="cke_dialog_tabs_bridge_%d" class="cke_dialog_tabs_bridge"></div>',
 							'<div id="cke_dialog_contents_%d" class="cke_dialog_contents"></div>',
 							'<div id="cke_dialog_buttons_%d" class="cke_dialog_buttons"></div>',
