C# Class Notpod.MainForm

Inheritance: System.Windows.Forms.Form
Datei anzeigen Open project: notpod/Notpod-1.x Class Usage Examples

Public Properties

Property Type Description
DATA_PATH string

Public Methods

Method Description
CheckIfiTunesLibrary ( string drive ) : bool

Check if device drive may be iTunes library folder. This could happen in case the user misconfigure the device and this check should help prevent loss of data.

CreateITunesInstance ( ) : bool

Creates connection to iTunes.

MainForm ( ) : System

Create a new instance of MainForm.

PerformSynchronize ( ) : void
SetITunesInstance ( ) : void
SetStatusMessage ( string title, string message, ToolTipIcon icon ) : void

Set the status message in the main window.

Protected Methods

Method Description
Dispose ( bool disposing ) : void

Clean up any resources being used.

OnClosing ( CancelEventArgs e ) : void

Overriding OnClosing to remove playlists for devices.

OniTunesQuitEvent ( ) : void

Event handler for iTunes quit events.

WndProc ( Message &m ) : void

WndProc override to enable minimize to tray.

Private Methods

Method Description
CheckIfSystemDrive ( string drive ) : bool

Check the provided path against the list of potential system drives

CreateMyDevicesFolder ( ) : void

Check if the My Devices folder exists, if not create it.

GetMusicLocationConfirmation ( string path ) : bool
InitializeComponent ( ) : void

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

LoadSyncPatterns ( ) : void
MainForm_Load ( object sender, EventArgs e ) : void

Event handler for the form load event.

OnDeviceConnected ( object sender, CDMEventArgs args ) : void

Event handler for connected devices.

OnDeviceDisconnect ( object sender, string driveName, CDMEventArgs args ) : void

Event handler for disconnected devices.

OnSynchronizeCancelled ( object sender ) : void
OnSynchronizeComplete ( object sender ) : void
OnSynchronizeError ( object sender, Notpod.SyncErrorArgs args ) : void
PerformDeviceCheck ( ) : bool

Perform a simple check of the devices. Warn the user if a device is associated with a drive which may be a system drive.

PlaylistExists ( Notpod.Configuration12.Device device ) : IITPlaylist

Checks if an iTunes playlist exists.

SetEventHandlers ( ) : void

Set event handlers for iTunes events.

ctxTrayAbout_Click ( object sender, EventArgs e ) : void

Event handler for the tray context menu "About Notpod..."

ctxTrayExit_Click ( object sender, EventArgs e ) : void
ctxTrayHelp_Click ( object sender, EventArgs e ) : void

Event handler for the tray context menu "Online help..."

ctxTrayPreferences_Click ( object sender, EventArgs e ) : void

Event handler for the tray context menu "Preferences..."

ctxTrayReportBug_Click ( object sender, EventArgs e ) : void
ctxTraySynchronize_Click ( object sender, EventArgs e ) : void
linkJaranweb_LinkClicked ( object sender, System.Windows.Forms.LinkLabelLinkClickedEventArgs e ) : void
menuAgentConfigure_Click ( object sender, EventArgs e ) : void
menuAgentExit_Click ( object sender, EventArgs e ) : void

Event handler for the exit menu item.

menuAgentFormat_Click ( object sender, EventArgs e ) : void
menuHelpAbout_Click ( object sender, EventArgs e ) : void

Event handler for Help->About

menuHelpOnlineDoc_Click ( object sender, EventArgs e ) : void

Event handler for the Help->Online documentation menu item.

timerDriveListUpdate_Tick ( object sender, EventArgs e ) : void

Event handler for ticks on the DriveListUpdate timer.

Method Details

CheckIfiTunesLibrary() public method

Check if device drive may be iTunes library folder. This could happen in case the user misconfigure the device and this check should help prevent loss of data.
public CheckIfiTunesLibrary ( string drive ) : bool
drive string
return bool

CreateITunesInstance() public method

Creates connection to iTunes.
public CreateITunesInstance ( ) : bool
return bool

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

MainForm() public method

Create a new instance of MainForm.
public MainForm ( ) : System
return System

OnClosing() protected method

Overriding OnClosing to remove playlists for devices.
protected OnClosing ( CancelEventArgs e ) : void
e CancelEventArgs
return void

OniTunesQuitEvent() protected method

Event handler for iTunes quit events.
protected OniTunesQuitEvent ( ) : void
return void

PerformSynchronize() public method

public PerformSynchronize ( ) : void
return void

SetITunesInstance() public method

public SetITunesInstance ( ) : void
return void

SetStatusMessage() public method

Set the status message in the main window.
public SetStatusMessage ( string title, string message, ToolTipIcon icon ) : void
title string
message string Status message to set.
icon ToolTipIcon The type of icon to use on the baloon.
return void

WndProc() protected method

WndProc override to enable minimize to tray.
protected WndProc ( Message &m ) : void
m System.Windows.Forms.Message
return void

Property Details

DATA_PATH public_oe static_oe property

The path where the configuration is stored.
public static string DATA_PATH
return string