anchor.diff:                  {exception, Exception} ->
                       log:log(error,"Error: exception ~p during handling of ~p in module ~p~n",
                                 [Exception, Message, Module]),
  -                    loop(Module, State, {Options, Slowest});
  +                    loop(Module, On, State, ComponentState);
                   unknown_event ->
                       {NewState, NewComponentState} =
                           handle_unknown_event(Message, State,
                            {Options, Slowest},Module),
  -                    loop(Module, NewState, NewComponentState);
  +                    loop(Module, On, NewState, NewComponentState);
                   kill ->
                       ok;
  +                {'$gen_component', Config, NewState} ->
  +                    {value, {on_handler, NewHandler}} =
  +                        lists:keysearch(on_handler, 1, Config),
  +                    loop(Module, NewHandler, NewState, ComponentState);
                   NewState ->
                       %Stop = erlang:now(),
                       %Span = timer:now_diff(Stop, Start),
  
positive.code:                     ok;
                  _ -> cs_send:send_local(Pid , Msg)
              end,
              loop(Module, State, _ComponentState);
          Message ->
              %Start = erlang:now(),
              case (try Module:on(Message, State) catch
                                                      throw:Term -> {exception, Term};
                                                      exit:Reason -> {exception,Reason};
                                                      error:Reason -> {exception, {Reason,
  
negative.code:             ?DEBUG_REGISTER(list_to_atom(lists:flatten(io_lib:format("~p_~p",[Module,randoms:getRandomId()]))),self()),
  	    Supervisor ! {started, self()};
  	false ->
              case lists:keysearch(register_native, 1, Options) of
              {value, {register_native,Name}} ->
                  register(Name, self()),
                  Supervisor ! {started, self()};
              false ->
  