/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.rjconsultores.ventaboletos.web.utilerias;

import org.zkoss.zk.ui.WrongValueException;
import org.zkoss.zk.ui.event.InputEvent;
import org.zkoss.zul.Intbox;
import org.zkoss.zul.Textbox;

/**
 *
 * @author Administrador
 */
public class MyTextboxCaracterEspecial extends Intbox {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	public MyTextboxCaracterEspecial() {
		this.setStyle("text-transform:uppercase;");
	}

	@Override
	public Integer getValue() throws WrongValueException {
		return super.getValue();
	}

	@Override
	public void setValue(Integer value) throws WrongValueException {
		if (value == null) {
            super.setValue(value);
        } else {
            super.setValue(value);
        }
	}

	@Override
	public String getText() throws WrongValueException {

		return super.getText();
	}

	@Override
	public void setText(String value) throws WrongValueException {
		if (value == null) {
			super.setText(value);
		} else {
			super.setText(value);
		}
	}

//	public void onChanging(InputEvent event) {
//		this.setText((String) event.getValue().replace("-", "").replace(".", ""));// verificar se pode espacos e letras
//	}
}
