ChartAdapter.notifyUpdateApply( );
	public void widgetSelected( SelectionEvent e )	{		// Indicates whether need to update chart model		boolean needUpdateModel = false;		Object oSelected = e.getSource( );		if ( oSelected.getClass( ).equals( Button.class ) )		{			needUpdateModel = true;			if ( oSelected.equals( cbOrientation ) )			{				if ( cbOrientation.getSelection( ) )				{					this.orientation = Orientation.HORIZONTAL_LITERAL;				}				else				{					this.orientation = Orientation.VERTICAL_LITERAL;				}				createAndDisplayTypesSheet( sType );				setDefaultSubtypeSelection( );			}			else			{				Button btn = (Button) e.getSource( );				if ( btn.getSelection( ) )				{					if ( this.sSubType != null							&& !getSubtypeFromButton( btn ).equals( sSubType ) )					{						int iTypeIndex = vSubTypeNames.indexOf( sSubType );						if ( iTypeIndex >= 0 )						{							( (Button) cmpTypeButtons.getChildren( )[iTypeIndex] ).setSelection( false );							cmpTypeButtons.redraw( );						}					}					sSubType = getSubtypeFromButton( btn );					ChartCacheManager.getInstance( ).cacheSubtype( sType,							sSubType );				}				else				{					if ( this.sSubType != null							&& getSubtypeFromButton( btn ).equals( sSubType ) )					{						// Clicking on the same button should not cause it to be						// unselected						btn.setSelection( true );						needUpdateModel = false;					}				}			}		}		else if ( oSelected.getClass( ).equals( Table.class ) )		{			sType = ( (String) ( (TableItem) e.item ).getData( ) ).trim( );			if ( !chartModel.getType( ).equals( sType ) )			{				sSubType = null;				createAndDisplayTypesSheet( sType );				setDefaultSubtypeSelection( );				// Pack to display enough space for different chart				container.packWizard( );				cmpMisc.layout( );				needUpdateModel = true;			}		}		else if ( oSelected.equals( cbMultipleY ) )		{			needUpdateModel = true;			lblSeriesType.setEnabled( isTwoAxesEnabled( ) );			cbSeriesType.setEnabled( isTwoAxesEnabled( ) );			( (ChartWizardContext) getContext( ) ).setMoreAxesSupported( cbMultipleY.getSelectionIndex( ) == 2 );			if ( chartModel instanceof ChartWithoutAxes )			{				throw new IllegalArgumentException( Messages.getString( "TaskSelectType.Exception.CannotSupportAxes" ) ); //$NON-NLS-1$			}			// Prevent notifications rendering preview			ChartAdapter.changeChartWithoutNotification( new IChangeWithoutNotification( ) {				public Object run( )				{					int iAxisNumber = ChartUIUtil.getOrthogonalAxisNumber( chartModel );					if ( cbMultipleY.getSelectionIndex( ) == 0 )					{						// Keeps one axis						if ( iAxisNumber > 1 )						{							ChartUIUtil.removeLastAxes( (ChartWithAxes) chartModel,									iAxisNumber - 1 );						}					}					else if ( cbMultipleY.getSelectionIndex( ) == 1 )					{						// Keeps two axes						if ( iAxisNumber == 1 )						{							ChartUIUtil.addAxis( (ChartWithAxes) chartModel );						}						else if ( iAxisNumber > 2 )						{							ChartUIUtil.removeLastAxes( (ChartWithAxes) chartModel,									iAxisNumber - 2 );						}					}					return null;				}			} );			// Update dimension combo and related sub-types			if ( updateDimensionCombo( sType ) )			{				createAndDisplayTypesSheet( this.sType );				setDefaultSubtypeSelection( );			}			// Pack to display enough space for combo			cmpMisc.layout( );		}		else if ( oSelected.equals( cbDimension ) )		{			String newDimension = cbDimension.getItem( cbDimension.getSelectionIndex( ) );			if ( !newDimension.equals( sDimension ) )			{				sDimension = newDimension;				createAndDisplayTypesSheet( this.sType );				setDefaultSubtypeSelection( );				needUpdateModel = true;			}		}		else if ( oSelected.equals( cbSeriesType ) )		{			String oldSeriesName = ( (SeriesDefinition) ChartUIUtil.getOrthogonalSeriesDefinitions( chartModel,					1 )					.get( 0 ) ).getDesignTimeSeries( ).getDisplayName( );			if ( !cbSeriesType.getText( ).equals( oldSeriesName ) )			{				needUpdateModel = true;				changeOverlaySeriesType( );			}		}		else if ( oSelected.equals( cbOutput ) )		{			( (ChartWizardContext) getContext( ) ).setOutputFormat( cbOutput.getText( ) );		}		// Following operations need new model		if ( needUpdateModel )		{			// Update chart model			refreshChart( );			if ( oSelected.getClass( ).equals( Table.class ) )			{				// Ensure populate list after chart model generated				populateSeriesTypesList( );			}			else if ( oSelected.equals( cbMultipleY ) && isTwoAxesEnabled( ) )			{				if ( chartModel != null && chartModel instanceof ChartWithAxes )				{					if ( ChartUIUtil.getOrthogonalAxisNumber( chartModel ) > 1 )					{						Axis overlayAxis = ChartUIUtil.getAxisYForProcessing( (ChartWithAxes) chartModel,								1 );						String sDisplayName = PluginSettings.instance( )								.getSeriesDisplayName( ( (SeriesDefinition) overlayAxis.getSeriesDefinitions( )										.get( 0 ) ).getDesignTimeSeries( )										.getClass( )										.getName( ) );						cbSeriesType.select( cbSeriesType.indexOf( sDisplayName ) );					}				}			}		}	}