Bug 195951 Focus for PNG does not work [13]
Description: Focus for PNG does not work. Build number: 2.2.0.v20070710-1223 Steps to reproduce: 1. New a Chart, set Output Format as PNG, in "Format Chart" tab, add interactivity for Value Series, Event: Focus, Action: Hyperlink or invoke script. 2. Preview, focus in Value Series. Expected result: Interactivity works. Actual result: It does not work. Error log: N/A
chart/org.eclipse.birt.chart.device.extension/src/org/eclipse/birt/chart/device/image/JavaxImageIOWriter.java
}
		if ( ac.getType( ).getValue( ) == ActionType.URL_REDIRECT )
		{
			URLValue uv = (URLValue) ac.getValue( );
			if ( uv.getBaseUrl( ).startsWith( "javascript:" ) ) 
			{
				return uv.getBaseUrl( );
			}
			if ( uv.getBaseUrl( ).startsWith( "#" ) ) 
			{
				return "window.location='" + uv.getBaseUrl( ) + "'"; 
			}
			return "window.open('" 
					+ uv.getBaseUrl( ) + "','" + uv.getTarget( ) + "')"; 
		}
		return ""; 
	}
	private String wrapJSMethod( String functionName, String functionContent )
	{
		return "<Script>" 
				+ "function " + functionName + "(categoryData, valueData, seriesValueName){" 
				+ eval2JS( functionContent ) + "}</Script>"; 
	}
	
	private String getJSMethodName( TriggerCondition tc )
	{
		
		return "userCallBack_" + tc.getLiteral( ) + TIMESTAMP; 
	}
}