PHP Класс Prado\Web\UI\ActiveControls\TActiveDropDownList
The active control counter part to drop down list control.
The {@link setAutoPostBack AutoPostBack} property is set to true by default.
Thus, when the drop down list selection is changed the {@link onCallback OnCallback} event is
raised after {@link OnSelectedIndexChanged} event.
With {@link TBaseActiveControl::setEnableUpdate() ActiveControl.EnableUpdate}
set to true (default is true), changes to the selection,
after OnLoad event has
been raised, will be updated.
on the client side.
List items can be changed dynamically during a callback request.
Показать файл
Открыть проект
Примеры использования класса
Открытые методы
Метод |
Описание |
|
__construct ( ) |
Creates a new callback control, sets the adapter to
TActiveListControlAdapter. If you override this class, be sure to set the
adapter appropriately by, for example, by calling this constructor. |
|
getActiveControl ( ) : TBaseActiveCallbackControl |
|
|
getClientSide ( ) : TCallbackClientSide |
|
|
onCallback ( $param ) |
This method is invoked when a callback is requested. The method raises
'OnCallback' event to fire up the event handlers. If you override this
method, be sure to call the parent implementation so that the event
handler can be invoked. |
|
onPreRender ( $param ) |
Updates the client-side options if the item list has changed after the OnLoad event. |
|
raiseCallbackEvent ( $param ) |
Raises the callback event. This method is required by {@link
ICallbackEventHandler} interface. |
|
Защищенные методы
Метод |
Описание |
|
addAttributesToRender ( $writer ) |
Ensure that the ID attribute is rendered and registers the javascript code
for initializing the active control. |
|
createListItemCollection ( ) : TActiveListItemCollection |
Creates a collection object to hold list items. A specialized
TActiveListItemCollection is created to allow the drop down list options
to be added. |
|
getClientClassName ( ) : null |
No client class for this control. |
|
renderClientControlScript ( $writer ) |
Override parent implementation, no javascript is rendered here instead
the javascript required for active control is registered in {@link addAttributesToRender}. |
|
Описание методов
__construct()
публичный Метод
Creates a new callback control, sets the adapter to
TActiveListControlAdapter. If you override this class, be sure to set the
adapter appropriately by, for example, by calling this constructor.
addAttributesToRender()
защищенный Метод
Ensure that the ID attribute is rendered and registers the javascript code
for initializing the active control.
createListItemCollection()
защищенный Метод
This method may be overriden to create a customized collection.
protected createListItemCollection ( ) : TActiveListItemCollection |
Результат |
TActiveListItemCollection |
the collection object |
getActiveControl()
публичный Метод
public getActiveControl ( ) : TBaseActiveCallbackControl |
Результат |
TBaseActiveCallbackControl |
standard callback control options. |
getClientClassName()
защищенный Метод
This method overrides the parent implementation.
getClientSide()
публичный Метод
public getClientSide ( ) : TCallbackClientSide |
Результат |
TCallbackClientSide |
client side request options. |
onCallback()
публичный Метод
This method is invoked when a callback is requested. The method raises
'OnCallback' event to fire up the event handlers. If you override this
method, be sure to call the parent implementation so that the event
handler can be invoked.
onPreRender()
публичный Метод
Updates the client-side options if the item list has changed after the OnLoad event.
raiseCallbackEvent()
публичный Метод
This method is mainly used by framework and control developers.
renderClientControlScript()
защищенный Метод
Override parent implementation, no javascript is rendered here instead
the javascript required for active control is registered in {@link addAttributesToRender}.