fcf.module({
  name: "fcfControls:templates/radio.wrapper.js",
  dependencies: ["fcfControls:templates/view.wrapper.js"],
  module: function(Wrapper){
    return class WrapperEx extends Wrapper{
      constructor(a_initializeOptions){
        super(a_initializeOptions);
      }

      setArg(a_value) {
        super.setArg(a_value);
        this.getActionDomElement().checked = !!a_value ? "checked" : false;
      }

      getActionDomElement(){
        return fcf.select(this.getDomElement(), "input")[0];
      }

      onClick(a_event){
        this.setArg("data", !!this.getActionDomElement().checked);
      }
    };
  }
});
