C# Class Nexus.Client.ApplicationInitializationForm

The view displaying the progress of the application initialization.
This view may actually be invisible, and simple act as the UI form that displays the views the application initialization requests shown.
Inheritance: Nexus.Client.UI.ManagedFontForm
显示文件 Open project: NexusMods/NexusModManager-4.5 Class Usage Examples

Private Properties

Property Type Description
ConfirmItemOverwrite OverwriteResult
ConfirmMakeWritable bool
GenerateGreyscale Image
HandleChangedProperty void
InitializeComponent void
ShowMessage object
ShowView object
Task_PropertyChanged void
Task_TaskEnded void
ViewModel_TaskStarted void
m_tmrGlow_Tick void

Public Methods

Method Description
ApplicationInitializationForm ( ApplicationInitializer p_iniApplicationInitializer ) : System

A simple constructor that initializes the object with the given values.

Protected Methods

Method Description
Dispose ( bool disposing ) : void

Clean up any resources being used.

Login ( Nexus.Client.LoginFormVM p_vmlViewModel ) : bool

Logins the user into the current mod repository.

OnClosing ( CancelEventArgs e ) : void

Raises the Form.Closing event.

This prevents the form from closing until the task has completed.

OnShown ( EventArgs e ) : void

Raises the Form.Shown event.

This immediately closes the form if the task has already completed.

Private Methods

Method Description
ConfirmItemOverwrite ( string p_strItemMessage, bool p_booAllowPerGroupChoice, bool p_booAllowPerModChoice ) : OverwriteResult

This asks the user to confirm the overwriting of the specified item.

ConfirmMakeWritable ( IEnvironmentInfo p_eifEnvironmentInfo, string p_strFileSystemItemPath, bool &p_booRememberSelection ) : bool

Confirms whether a file system item should be made writable.

GenerateGreyscale ( Image p_imgImage ) : Image

Generates a greyscale image from the given image.

HandleChangedProperty ( string p_strPropertyName ) : void

Updates the form to display the changed property.

InitializeComponent ( ) : void

Required method for Designer support - do not modify the contents of this method with the code editor.

ShowMessage ( ViewMessage p_vwmMessage ) : object

Displays a message.

ShowView ( IView p_ivwView, bool p_booModal ) : object

Displays a view.

Task_PropertyChanged ( object sender, PropertyChangedEventArgs e ) : void

Handles the INotifyPropertyChanged.PropertyChanged event of the task.

This updates the progress bars and messages.

Task_TaskEnded ( object sender, TaskEndedEventArgs e ) : void

Handles the IBackgroundTask.TaskEnded event of the task.

This sets the Form.DialogResult, dependant upon whether or not the task was cancelled.

ViewModel_TaskStarted ( object sender, EventArgs e ) : void

Handles the ApplicationInitializer.TaskStarted event of the view model.

This display a progress window for the started task.

m_tmrGlow_Tick ( object sender, EventArgs e ) : void

Handles the System.Windows.Forms.Timer.Tick event of the glow effect timer.

This updates the progress image, and renders the moving glow effect.

Method Details

ApplicationInitializationForm() public method

A simple constructor that initializes the object with the given values.
public ApplicationInitializationForm ( ApplicationInitializer p_iniApplicationInitializer ) : System
p_iniApplicationInitializer ApplicationInitializer The application initializer.
return System

Dispose() protected method

Clean up any resources being used.
protected Dispose ( bool disposing ) : void
disposing bool true if managed resources should be disposed; otherwise, false.
return void

Login() protected method

Logins the user into the current mod repository.
protected Login ( Nexus.Client.LoginFormVM p_vmlViewModel ) : bool
p_vmlViewModel Nexus.Client.LoginFormVM The view model that provides the data and operations for this view.
return bool

OnClosing() protected method

Raises the Form.Closing event.
This prevents the form from closing until the task has completed.
protected OnClosing ( CancelEventArgs e ) : void
e CancelEventArgs A describing the event arguments.
return void

OnShown() protected method

Raises the Form.Shown event.
This immediately closes the form if the task has already completed.
protected OnShown ( EventArgs e ) : void
e System.EventArgs An describing the event arguments.
return void