C# Class BaconFeedback.FeedbackPresenter

Mostra file Open project: Revelations/BaconApp Class Usage Examples

Public Methods

Method Description
ConfirmDelete ( bool folder ) : bool

Confirms the deletion of files/folders or notifies of the fact that none are selected.

ConstructPrintDocument ( object sender, System.Drawing.Printing.PrintPageEventArgs e ) : void

Invokes the print handler to create a print document.

CopySelectedText ( ) : void

Copies the selected text from one of the textboxes on the form to the clipboard.

CreateFeedbackList ( ) : List

Gets data from all selected feedback and creates a list of feedback data for passing to other classes.

DeleteFiles ( ) : void

Deletes all selected files from both the file view and file system.

DeleteFolder ( string folder ) : void

Deletes a single folder from the folder view and file system.

DisplayFeedbackFile ( ) : void

Loads the contents of a feedback file into the text fields in the view.

DownloadSync ( ) : void
ExportSelected ( ) : void
FeedbackPresenter ( FeedbackMainForm view ) : Common.System

Constructor accepting a single argument.

FileViewAddFolder ( string folder ) : void

Adds the feedback files from a given directory into the file view. Will not clear out files already present in the view.

FileViewRemoveFolder ( string folder ) : void

Removes the feedback files from a given directory from the file view.

InitPrintHandler ( ) : void

Initialises the print handler with a list of files to be printed/previewed.

ListViewClear ( ListView listView ) : void

Clears and refreshes the contents of the file view.

PopulateFolderView ( ) : void

Populates the folder view with subdirectories of the main feedback directory. First clears and refreshes the view to remove any existing items.

ShowErrorMessage ( string message ) : void

Helper method that shows a messagebox with a given error message.

UploadSyncExit ( ) : void

Private Methods

Method Description
DisplayFeedbackFile ( System.Windows.Forms.ListViewItem item ) : void
GetScannedList ( string input ) : List
GetScannedString ( string input ) : string

Method Details

ConfirmDelete() public method

Confirms the deletion of files/folders or notifies of the fact that none are selected.
public ConfirmDelete ( bool folder ) : bool
folder bool Set this to true if confirming deletion of a folder, false if a file.
return bool

ConstructPrintDocument() public method

Invokes the print handler to create a print document.
public ConstructPrintDocument ( object sender, System.Drawing.Printing.PrintPageEventArgs e ) : void
sender object
e System.Drawing.Printing.PrintPageEventArgs
return void

CopySelectedText() public method

Copies the selected text from one of the textboxes on the form to the clipboard.
public CopySelectedText ( ) : void
return void

CreateFeedbackList() public method

Gets data from all selected feedback and creates a list of feedback data for passing to other classes.
public CreateFeedbackList ( ) : List
return List

DeleteFiles() public method

Deletes all selected files from both the file view and file system.
public DeleteFiles ( ) : void
return void

DeleteFolder() public method

Deletes a single folder from the folder view and file system.
public DeleteFolder ( string folder ) : void
folder string Path of the folder to delete.
return void

DisplayFeedbackFile() public method

Loads the contents of a feedback file into the text fields in the view.
public DisplayFeedbackFile ( ) : void
return void

DownloadSync() public method

public DownloadSync ( ) : void
return void

ExportSelected() public method

public ExportSelected ( ) : void
return void

FeedbackPresenter() public method

Constructor accepting a single argument.
public FeedbackPresenter ( FeedbackMainForm view ) : Common.System
view FeedbackMainForm The form that this will control presentation for.
return Common.System

FileViewAddFolder() public method

Adds the feedback files from a given directory into the file view. Will not clear out files already present in the view.
public FileViewAddFolder ( string folder ) : void
folder string The directory to add files from.
return void

FileViewRemoveFolder() public method

Removes the feedback files from a given directory from the file view.
public FileViewRemoveFolder ( string folder ) : void
folder string The directory being excluded from the file view.
return void

InitPrintHandler() public method

Initialises the print handler with a list of files to be printed/previewed.
public InitPrintHandler ( ) : void
return void

ListViewClear() public method

Clears and refreshes the contents of the file view.
public ListViewClear ( ListView listView ) : void
listView System.Windows.Forms.ListView
return void

PopulateFolderView() public method

Populates the folder view with subdirectories of the main feedback directory. First clears and refreshes the view to remove any existing items.
public PopulateFolderView ( ) : void
return void

ShowErrorMessage() public method

Helper method that shows a messagebox with a given error message.
public ShowErrorMessage ( string message ) : void
message string The error message to display.
return void

UploadSyncExit() public method

public UploadSyncExit ( ) : void
return void