/** * Raises the callback event. This method is overrides the parent implementation. * If {@link setAutoPostBack AutoPostBack} is enabled it will raise * {@link onTextChanged OnTextChanged} event event and then the * {@link onCallback OnCallback} event. The {@link onSuggest OnSuggest} event is * raise if the request is to find sugggestions, the {@link onTextChanged OnTextChanged} * and {@link onCallback OnCallback} events are <b>NOT</b> raised. * This method is mainly used by framework and control developers. * @param TCallbackEventParameter the event parameter */ public function raiseCallbackEvent($param) { $token = $param->getCallbackParameter(); if (is_array($token) && count($token) == 2) { if ($token[1] === '__TAutoComplete_onSuggest__') { $parameter = new TAutoCompleteEventParameter($this->getResponse(), $token[0]); $this->onSuggest($parameter); } else { if ($token[1] === '__TAutoComplete_onSuggestionSelected__') { $parameter = new TAutoCompleteEventParameter($this->getResponse(), null, $token[0]); $this->onSuggestionSelected($parameter); } } } else { if ($this->getAutoPostBack()) { parent::raiseCallbackEvent($param); } } }