SAIFWarp async-refresh initialization¶
This operation runs during the Init phase of the ASP.NET page lifecycle for a SAIFWarp control. Both the focus-restoration script registration and the panel's initialization event wiring occur only when Not DesignMode and ControlsFocus is True; when ControlsFocus is False, neither occurs during Init.
| Field | Value |
|---|---|
| Operation ID | OP-SAIFWARP-INIT |
| Trigger | ASP.NET Init event of SAIFWarp |
| Inputs | ControlsFocus property, Page context |
| Outputs | Registered client script blocks, ClientSideEvents wiring |
| Primary components | SAIFWarp.SAIFWarp_Init |
| Entry point | SAIF.Presentation.Web.Controls.Infragistics103\SAIFWarp.vb |
Steps¶
- If
DesignModeis true, no script registration occurs at all (design-time no-op branch); processing stops here. - If
Not DesignModeandControlsFocusisTrue: a. Check whether theFOCUS_SCRIPT_NAMEclient script block is already registered.- If not registered: register the
FOCUS_SCRIPTblock, which definesSAIFWARP_RefreshComplete— a function that looks up a hidden field{PanelID}_FOCUSand calls.focus()on the referenced control three times — and setClientSideEvents.RefreshComplete = "SAIFWARP_RefreshComplete". b. SetClientSideEvents.InitializePanel = INIT_SCRIPT_NAME.
- If not registered: register the
- If
Not DesignModeandControlsFocusisFalse: neither the focus-restoration script registration nor theClientSideEvents.InitializePanelwiring occurs —Initperforms no action for this control.
Process flow¶
The following diagram visualizes this operation's control flow.
flowchart TD
Start([Init event fires]) --> Design{DesignMode?}
Design -->|Yes| EndNoOp([No script registered, no InitializePanel wiring])
Design -->|No| Focus{ControlsFocus = True?}
Focus -->|No| EndNoOp2([No script registered, no InitializePanel wiring])
Focus -->|Yes| Check{FOCUS_SCRIPT_NAME already registered?}
Check -->|No| Register[Register FOCUS_SCRIPT block<br>Wire RefreshComplete event]
Check -->|Yes| SetInit
Register --> SetInit[Set ClientSideEvents.InitializePanel]
SetInit --> EndOk([Init complete])
Failure and edge-case behavior¶
- At design time (
DesignMode = True), no script registration occurs — this is a normal no-op branch, not an error. - When
ControlsFocusisFalse, neither the focus-restoration script norClientSideEvents.InitializePanelis wired duringInit— this is a normal branch, not an error, but it meansInitializePanel(and therefore the progress-indicator init script wiring) is skipped entirely for this instance. - If the focus script is already registered (e.g., multiple
SAIFWarpinstances on one page), registration is skipped to avoid duplicate script blocks, butInitializePanelwiring still occurs for each instance whoseControlsFocusisTrue.
Related documentation¶
Sources¶
- SAIF.Presentation.Web.Controls.Infragistics103\SAIFWarp.vb