/*
 * $Id: LibraryApplicationBorder.java 5838 2006-05-24 20:44:49 +0000 (Wed, 24
 * May 2006) joco01 $ $Revision$ $Date: 2006-05-24 20:44:49 +0000 (Wed,
 * 24 May 2006) $
 * 
 * ==================================================================== Licensed
 * under the Apache License, Version 2.0 (the "License"); you may not use this
 * file except in compliance with the License. You may obtain a copy of the
 * License at
 * 
 * http://www.apache.org/licenses/LICENSE-2.0
 * 
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
 * License for the specific language governing permissions and limitations under
 * the License.
 */
package wicket.examples.library;

import wicket.MarkupContainer;
import wicket.markup.IAlternateParentProvider;
import wicket.markup.html.border.Border;
import wicket.markup.html.border.BoxBorder;

/**
 * Border component.
 * 
 * @author Jonathan Locke
 */
public class LibraryApplicationBorder extends Border implements IAlternateParentProvider
{
	private Border boxBorder;
	
	/**
	 * Constructor
	 * 
	 * @param parent
	 *            The parent
	 * @param id
	 *            The id of this component
	 */
	public LibraryApplicationBorder(MarkupContainer parent, final String id)
	{
		super(parent, id);
		
		this.boxBorder = new BoxBorder(this, "boxBorder");
	}

	/**
	 * @see wicket.markup.IAlternateParentProvider#getAlternateParent(java.lang.Class, java.lang.String)
	 */
	public MarkupContainer getAlternateParent(Class childClass, String childId)
	{
		return ((this.boxBorder == null) || "mainNavigation".equals(childId) ? this : this.boxBorder);
	}
}

@@ -1149,42 +1149,13 @@
 r%0A%7B%0A
-%09private Border boxBorder;%0A%09%0A
 %09/**%0A
+
 %09 * 
@@ -1377,21 +1377,23 @@
 );%0A%09%09%0A%09%09
-this.
+Border 
 boxBorde
@@ -1430,16 +1430,53 @@
 rder%22);%0A
+%09%09newBorderBodyContainer(boxBorder);%0A
 %09%7D%0A%0A%09/**
@@ -1677,36 +1677,39 @@
 rn (
-(this.boxBorder =
+getBodyContainer() !
 = null
-) %7C%7C 
+ && !
 %22mai
@@ -1741,31 +1741,40 @@
 Id) 
-? this : this.boxBorder
+%0A%09%09%09%09? getBodyContainer() : this
 );%0A%09

Change required due to latest change on Borders in core