/* ZssCharts.java

{{IS_NOTE
	Purpose:
		
	Description:
		
	History:
		2014/10/30 , Created by jerrychen
}}IS_NOTE

Copyright (C) 2014 Potix Corporation. All Rights Reserved.

{{IS_RIGHT
}}IS_RIGHT
*/
package org.zkoss.zssex.ui;

import java.io.IOException;

import org.zkoss.chart.Charts;
import org.zkoss.chart.options3D.Options3D;
import org.zkoss.zk.ui.sys.ContentRenderer;

/**
 * A wrapper for ZK charts.
 * @author Jerry
 *
 */
public class ZssCharts extends Charts{
	private static final long serialVersionUID = -2579649069848968509L;
	private String sclass; 
	
	public void setSclass(String sclass) {
		this.sclass = sclass;
	}
	
	public void setThreeD(boolean enabled) {
		Options3D option = getOptions3D();
		option.setEnabled(enabled);
		setOptions3D(option);
	}
	
	public boolean isThreeD() {
		return getOptions3D().isEnabled();
	}

	@Override
	protected void renderProperties(ContentRenderer renderer)
			throws IOException {
		super.renderProperties(renderer);
		render(renderer, "sclass", sclass);
	}
}
