C# Class Habanero.Faces.Base.FormController

Provides a controller for forms that keeps a reference to all open forms so that a user can switch between them. The specific advantage of using a controller is that the state of the window can be maintained and the form regeneration time is saved. This controller can be used to populate a "Window" menu item with open forms.
Exibir arquivo Open project: Chillisoft/habanero.faces

Public Methods

Method Description
SetCurrentControl ( String heading ) : IFormControl

Sets the current control to the one with the specified heading

Protected Methods

Method Description
FormController ( IFormHabanero parentForm, IControlFactory controlFactory ) : System

Constructor to initialise a new controller

GetControl ( string heading ) : IControlHabanero

Returns the control with the heading specified

GetFormControl ( string heading ) : IFormControl

Returns the form control with the heading specified

Private Methods

Method Description
MdiFormClosed ( object sender, EventArgs e ) : void

Handles the event of a form being closed

Method Details

FormController() protected method

Constructor to initialise a new controller
protected FormController ( IFormHabanero parentForm, IControlFactory controlFactory ) : System
parentForm IFormHabanero The parent form
controlFactory IControlFactory
return System

GetControl() protected method

Returns the control with the heading specified
protected GetControl ( string heading ) : IControlHabanero
heading string The heading
return IControlHabanero

GetFormControl() protected abstract method

Returns the form control with the heading specified
protected abstract GetFormControl ( string heading ) : IFormControl
heading string The heading
return IFormControl

SetCurrentControl() public method

Sets the current control to the one with the specified heading
public SetCurrentControl ( String heading ) : IFormControl
heading String The heading
return IFormControl