/*!	\brief			Clears interface of previously selected Calendar Module prefs
 *	\details		Used in destructor and in move from one Calendar Module to another.
 */
void 			CalendarModulePreferencesView::ClearOldInterface()
{
	BGroupLayout* layout = ( BGroupLayout* )( BView::GetLayout() );
	BBox*		 tempBBox = NULL;
	BMenuField*	 tempMenuField = NULL;

	// Clean up old interface items if they existed
	if ( ( tempBBox = ( BBox* )this->FindView( "Weekend selector" ) ) != NULL )
	{
		layout->RemoveView( tempBBox );
		tempBBox->RemoveSelf();
		delete tempBBox;
	}
	
	if ( ( tempBBox = ( BBox* )this->FindView( "Color selector" ) ) != NULL )
	{
		layout->RemoveView( tempBBox );
		tempBBox->RemoveSelf();
		delete tempBBox;
	}
	
	if ( ( tempMenuField = ( BMenuField* )this->FindView( "First day of week chooser" ) ) != NULL )
	{
		layout->RemoveView( tempMenuField );
		tempMenuField->RemoveSelf();
		delete tempMenuField;
	}
	
	if ( ( tempMenuField = ( BMenuField* )this->FindView( "Day-Month-Year order chooser" ) ) != NULL )
	{
		layout->RemoveView( tempMenuField );
		tempMenuField->RemoveSelf();
		delete tempMenuField;
	}
	
}	// <-- end of function CalendarModulePreferencesView::ClearOldInterface()