C# Class SIL.FieldWorks.XWorks.FwXWindow

Summary description for FwXWindow.
Inheritance: XCore.XWindow, IFwMainWnd, ISettings, IRecordListOwner, IMainWindowDelegatedFunctions, IMainWindowDelegateCallbacks
Exibir arquivo Open project: sillsdev/FieldWorks Class Usage Examples

Protected Properties

Property Type Description
m_StyleSheet FwStyleSheet
m_app SIL.FieldWorks.Common.Framework.FwApp
m_configFile string
m_delegate SIL.FieldWorks.Common.Framework.MainWindowDelegate
m_fWindowIsCopy bool
m_installedVirtualHandlers List
m_startupLink FwLinkArgs
m_viewHelper SIL.FieldWorks.Common.RootSites.ActiveViewHelper
s_wm_kmselectlang uint

Public Methods

Method Description
ClearInvalidatedStoredData ( ) : void
CreateMilestoneProgressState ( XCore.Mediator mediator ) : SIL.FieldWorks.Common.Controls.ProgressState

factory method for getting a progress state which is already hooked up to the correct progress panel

CreateNewFileName ( string fullName, string oldString, string newString ) : string

CreatePredictiveProgressState ( XCore.Mediator mediator, string taskLabel ) : SIL.FieldWorks.Common.Controls.ProgressState

factory method for getting a progress state which is already hooked up to the correct progress panel

CreateSimpleProgressState ( XCore.Mediator mediator ) : SIL.FieldWorks.Common.Controls.ProgressState

factory method for getting a simple progress state which is already hooked up to the correct progress panel

EnableBulkLoadingDisableIdleProcessing ( bool fEnable ) : void

Either enable bulk loading and disable idle processing, or disable bulk loading and enable idle processing.

EnableWindow ( bool fEnable ) : void

Enable or disable this window.

FindRecordListUpdater ( string name ) : IRecordListUpdater

Retrieve the IRecordListUpdater object named by the argument.

Part of the IRecordListOwner interface.

FinishRefresh ( ) : bool

Called in FwXApp.OnMasterRefresh AFTER clearing the cache, to reset everything.

FwXWindow ( ) : System

Default c'tor

FwXWindow ( FwApp app, Form wndCopyFrom, Stream iconStream, Stream configStream ) : System

Construct a new form

FwXWindow ( FwApp app, Form wndCopyFrom, Stream iconStream, string configFile, FwLinkArgs startupLink, bool inAutomatedTest ) : System

Construct a new form

FwXWindow ( FwApp app, string configFile ) : System

C'tor for TESTING with MockFwXWindow

GetMainWindowCaption ( SIL.FieldWorks.FDO.FdoCache cache ) : string

Gets the string that will go in the caption of the main window.

GetMessageTargets ( ) : IxCoreColleague[]

return an array of all of the objects which should 1) be queried when looking for someone to deliver a message to 2) be potential recipients of a broadcast

GetProjectName ( SIL.FieldWorks.FDO.FdoCache cache ) : string

Returns the project name from the specified cache. If the connection is to a remote server, the string returned will include the server name, formatted in a form suitable for including in a window caption.

InitAndShowClient ( ) : void

Create the client windows and add corresponding stuff to the sidebar, View menu, etc.

OnArchiveWithRamp ( object command ) : bool

Handle click on Archive With RAMP menu item

OnChooseLangProject ( object command ) : bool

OnCreateShortcut ( object args ) : bool

Handle the Create Shortcut on Desktop menu/toolbar item.

OnDisplayArchiveWithRamp ( object command, XCore.UIItemDisplayProperties &display ) : bool

Handle whether to enable Archive With RAMP menu item (enabled iff properly installed)

OnDisplayEditCopy ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

This is very similar to OnUpdateEditCopy, but for xCore applications.

OnDisplayEditCut ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

This is very similar to OnUpdateEditCut, but for xCore applications.

OnDisplayEditPaste ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

This is very similar to OnUpdateEditPaste, but for xCore applications.

OnDisplayEditSelectAll ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

Enable the SelectAll command if appropriate

OnDisplayImportTranslatedLists ( object parameters, XCore.UIItemDisplayProperties &display ) : bool

Display this import command everywhere.

OnDisplayInsertLinkToFile ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

Enable the InsertLinkToFile command

OnDisplayPasteUrl ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

Enable the PasteUrl command

OnDisplaySaveLangProject ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

This is very similar to OnUpdateFileSave, but for xCore applications.

OnDisplayShowCharMap ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

This method enables the Character Map command if the exe exists in the system dir.

OnDisplayUtilities ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

OnDisplayWritingSystemProperties ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

This is very similar to OnUpdateEditCut, but for xCore applications.

OnEditCopy ( object arg ) : bool

OnEditCut ( object arg ) : bool

OnEditFind ( object args ) : bool

Handle the Find menu command.

OnEditPaste ( object arg ) : bool

OnEditReplace ( object args ) : bool

Handle the Find menu command.

OnEditSelectAll ( object arg ) : bool

Implement the SelectAll command (for the active view).

OnExitApplication ( object param ) : bool

Exits the application :)

OnFinishedInit ( ) : bool

Called when a window is finished being created and completely initialized.

OnIdle ( object sender ) : void

If a property requests it, do a db sync.

OnImportTranslatedLists ( object commandObject ) : bool

Import a file contained translated strings for one or more lists.

See FWR-1739.

OnInsertLinkToFile ( object arg ) : bool

Handle the InsertLinkToFile command

OnNewLangProject ( object command ) : bool

OnNewWindow ( object command ) : bool

OnPasteUrl ( object arg ) : bool

Paste what is in the clipboard as a URL

OnPropertyChanged ( string name ) : void

OnSaveLangProject ( object command ) : bool

OnShowCharMap ( object command ) : bool

Start the Character Map program (if it's found).

OnStylesRenamedOrDeleted ( ) : void

Called when styles are renamed or deleted.

OnUpdateArchiveWithRamp ( object args ) : bool

Update Archive With RAMP menu item

OnUtilities ( object command ) : bool

OnWritingSystemProperties ( object arg ) : bool

Display the project properties dialog, but starting with the WS page.

PopulateParaStyleListOverride ( ) : bool

Allows individual implementations to override the default behavior when populating the paragraph style list.

PreSynchronize ( SyncMsg sync ) : void

Called just before a window syncronizes it's views with DB changes (e.g. when an undo or redo command is issued).

PrepareToRefresh ( ) : void

Called in FwXApp.OnMasterRefresh BEFORE clearing the cache, typically to save any work in progress.

RefreshAllViews ( ) : void

JohnT: this might be a poorly named or obsolete message. Kept because there are some callers and I don't have time to analyze them all. Generally better to use RefreshDisplay().

RefreshDisplay ( ) : bool

Collect refreshable caches from every child which has one and refresh them (once each). Call RefreshDisplay for every child control (recursively) which implements it. returns true if all the children have been processed by this class.

SaveSettings ( ) : void
SaveSettingsNow ( ) : void

Save the persisted settings now.

ShowApplyStyleDialog ( string paraStyleName, string charStyleName, int maxStyleLevel ) : void

Shows the Format Apply Style dialog

ShowStylesDialog ( string paraStyleName, string charStyleName, Action setPropsToFactorySettings ) : bool

Required interface member to launch the style dialog.

Synchronize ( SyncMsg sync ) : bool

Called when a window syncronizes it's views with DB changes (e.g. when an undo or redo command is issued).

Protected Methods

Method Description
DiscardProperties ( ) : void

If we are discarding saved settings, we must not keep any saved sort sequences, as they may represent a filter we are not restoring (LT-11647)

Dispose ( bool disposing ) : void

Clean up any resources being used.

InitMediatorValues ( SIL.FieldWorks.FDO.FdoCache cache ) : void
OnActivated ( EventArgs e ) : void

This main window is now the active one handle any data changes made in other applications. (By analogy with FwMainWindow, may also need to do something about Find/Replace?? (JT)).

OnBackupThisProject ( object arg ) : bool

Handle the File/Backup and Restore menu command

OnClosed ( EventArgs e ) : void
OnDeleteProject ( object args ) : bool

Handle the File/"Project Management"/Delete... menu command

OnDisplayDeleteProject ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

Disables/enables the File/"Project Management"/Delete... menu item

OnDisplayFileProjectSharingLocation ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

Updates the enabled state of the File Project Sharing Location menu item

OnDisplayFormatApplyStyle ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

Enable the menu command for Format/Styles, if we can.

OnDisplayRedo ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

Disables/enables the Edit/Redo menu item

OnDisplayUndo ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool

Disables/enables the Edit/Undo menu item

OnFileProjectProperties ( object command ) : bool

Display the project properties dialog

OnFileProjectSharingLocation ( object arg ) : bool

Handle the File/Restore menu command

OnFormatApplyStyle ( object args ) : bool

Shows the apply style dialog

OnFormatStyle ( object args ) : bool

Shows the Styles dialog

OnHandleCreated ( EventArgs e ) : void
OnHelpAbout ( object args ) : bool

Show Help About dialog

OnHelpCheckForUpdates ( object args ) : bool

Check if any updates to FW are available

OnHelpMakeSuggestion ( object args ) : bool

Show dialog to report a bug in the system

OnHelpReportProblem ( object args ) : bool

Show dialog to report a bug in the system

OnRedo ( object args ) : bool

This function will redo the last changes undone to the project. This function is executed when the user clicks the redo menu item.

OnRestoreAProject ( object arg ) : bool

Handle the File/Backup and Restore menu command

OnStartLogging ( object args ) : bool

Start logging events.

OnUndo ( object args ) : bool

This function will undo the last changes done to the project. This function is executed when the user clicks the undo menu item.

RestoreProperties ( ) : void

FwXWindow also restores database-specific properties.

WndProc ( Message &m ) : void

Keyman's select language message must be forwarded to the focus window to take useful effect.

XWindow_Closing ( object sender, System e ) : void

Private Methods

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

Different active view, we need to update the combo box.

BasicInit ( FwApp app ) : void
CollectCachesToRefresh ( Control c, HashSet cacheCollector, HashSet clerkCollector ) : void

Collect refreshable caches from the specified control and its subcontrols. We currently handle controls that are rootsites, and check their own SDAs as well as any base SDAs that those SDAs wrap.

FindAllRootBoxes ( Control control ) : List

FocusControlHandlesMessage ( string methodName, object args ) : bool

See whether the focus control wants to handle the specified message. It is assumed that if the focus control has a public or non-public method of the given name, it takes the supplied arguments and returns boolean. Call it and return what it returns. Special case: if the focus control is 'this', that is, the recipient xWindow has focus, just return false. This is because this method is called from, say, the implementation of OnDisplayUndo, to see whether some (other) focus control wants to handle the message. Returning false allows the correct default implementation of OnDisplayUndo when no (other) focused control wants to do it. Calling OnDisplayUndo on the focus control, on the other hand, leads to a stack overflow, since the first thing this.OnDisplayUndo does is to call FocusControlHandlesMessage again!

GetFocusControl ( ) : Control
HandleUndoResult ( UndoResult ures, bool fPrivate ) : void
ImportTranslatedLists ( string filename ) : void
Init ( Stream iconStream, Form wndCopyFrom, SIL.FieldWorks.FDO.FdoCache cache ) : void

Common initializations

LaunchProjPropertiesDlg ( bool startOnWSPage ) : void

Launches the proj properties DLG.

OnMasterRefresh ( object sender ) : void
OnProjectPropertiesChanged ( object sender, EventArgs eventArgs ) : void
ReconstructViews ( Control control ) : void

Call RefreshDisplay on the passed in control if it has a public (no argument) method of that name. Recursively call ReconstructViews on each control that the given control contains.

ResyncRootboxStyles ( ) : void

Get all the rootboxes we know about and reinitialize their stylesheets.

ResyncStylesheet ( ) : void

We need to resync the windows StyleSheet object during a MasterRefresh and Synchronize() LT-7382.

WindowHandleInfo ( string eventMsg ) : string

Method Details

ClearInvalidatedStoredData() public method

public ClearInvalidatedStoredData ( ) : void
return void

CreateMilestoneProgressState() public static method

factory method for getting a progress state which is already hooked up to the correct progress panel
public static CreateMilestoneProgressState ( XCore.Mediator mediator ) : SIL.FieldWorks.Common.Controls.ProgressState
mediator XCore.Mediator
return SIL.FieldWorks.Common.Controls.ProgressState

CreateNewFileName() public static method

public static CreateNewFileName ( string fullName, string oldString, string newString ) : string
fullName string
oldString string
newString string
return string

CreatePredictiveProgressState() public static method

factory method for getting a progress state which is already hooked up to the correct progress panel
public static CreatePredictiveProgressState ( XCore.Mediator mediator, string taskLabel ) : SIL.FieldWorks.Common.Controls.ProgressState
mediator XCore.Mediator
taskLabel string
return SIL.FieldWorks.Common.Controls.ProgressState

CreateSimpleProgressState() public static method

factory method for getting a simple progress state which is already hooked up to the correct progress panel
public static CreateSimpleProgressState ( XCore.Mediator mediator ) : SIL.FieldWorks.Common.Controls.ProgressState
mediator XCore.Mediator
return SIL.FieldWorks.Common.Controls.ProgressState

DiscardProperties() protected method

If we are discarding saved settings, we must not keep any saved sort sequences, as they may represent a filter we are not restoring (LT-11647)
protected DiscardProperties ( ) : void
return void

Dispose() protected method

Clean up any resources being used.
protected Dispose ( bool disposing ) : void
disposing bool true to release both managed and unmanaged /// resources; false to release only unmanaged resources. ///
return void

EnableBulkLoadingDisableIdleProcessing() public method

Either enable bulk loading and disable idle processing, or disable bulk loading and enable idle processing.
public EnableBulkLoadingDisableIdleProcessing ( bool fEnable ) : void
fEnable bool
return void

EnableWindow() public method

Enable or disable this window.
public EnableWindow ( bool fEnable ) : void
fEnable bool Enable (true) or disable (false).
return void

FindRecordListUpdater() public method

Retrieve the IRecordListUpdater object named by the argument.
Part of the IRecordListOwner interface.
public FindRecordListUpdater ( string name ) : IRecordListUpdater
name string
return IRecordListUpdater

FinishRefresh() public method

Called in FwXApp.OnMasterRefresh AFTER clearing the cache, to reset everything.
public FinishRefresh ( ) : bool
return bool

FwXWindow() public method

Default c'tor
public FwXWindow ( ) : System
return System

FwXWindow() public method

Construct a new form
public FwXWindow ( FwApp app, Form wndCopyFrom, Stream iconStream, Stream configStream ) : System
app SIL.FieldWorks.Common.Framework.FwApp the app.
wndCopyFrom System.Windows.Forms.Form Source window to copy from.
iconStream Stream
configStream Stream
return System

FwXWindow() public method

Construct a new form
public FwXWindow ( FwApp app, Form wndCopyFrom, Stream iconStream, string configFile, FwLinkArgs startupLink, bool inAutomatedTest ) : System
app SIL.FieldWorks.Common.Framework.FwApp The app.
wndCopyFrom System.Windows.Forms.Form Source window to copy from
iconStream Stream The icon stream.
configFile string The config file.
startupLink FwLinkArgs The link to follow once the window is initialized.
inAutomatedTest bool if set to true, (well behaved) code will avoid /// bringing up dialogs that we cannot respond to (like confirmation and error dialogs) /// and it should cause the system to avoid saving the settings to a file (or at least /// saving them in some special way so as not to mess up the user.)
return System

FwXWindow() public method

C'tor for TESTING with MockFwXWindow
public FwXWindow ( FwApp app, string configFile ) : System
app SIL.FieldWorks.Common.Framework.FwApp
configFile string Only sets the member variable here, does NOT load UI.
return System

GetMainWindowCaption() public method

Gets the string that will go in the caption of the main window.
public GetMainWindowCaption ( SIL.FieldWorks.FDO.FdoCache cache ) : string
cache SIL.FieldWorks.FDO.FdoCache
return string

GetMessageTargets() public method

return an array of all of the objects which should 1) be queried when looking for someone to deliver a message to 2) be potential recipients of a broadcast
public GetMessageTargets ( ) : IxCoreColleague[]
return IxCoreColleague[]

GetProjectName() public method

Returns the project name from the specified cache. If the connection is to a remote server, the string returned will include the server name, formatted in a form suitable for including in a window caption.
public GetProjectName ( SIL.FieldWorks.FDO.FdoCache cache ) : string
cache SIL.FieldWorks.FDO.FdoCache The FDO cache
return string

InitAndShowClient() public method

Create the client windows and add corresponding stuff to the sidebar, View menu, etc.
public InitAndShowClient ( ) : void
return void

InitMediatorValues() protected method

protected InitMediatorValues ( SIL.FieldWorks.FDO.FdoCache cache ) : void
cache SIL.FieldWorks.FDO.FdoCache
return void

OnActivated() protected method

This main window is now the active one handle any data changes made in other applications. (By analogy with FwMainWindow, may also need to do something about Find/Replace?? (JT)).
protected OnActivated ( EventArgs e ) : void
e System.EventArgs
return void

OnArchiveWithRamp() public method

Handle click on Archive With RAMP menu item
public OnArchiveWithRamp ( object command ) : bool
command object Not used
return bool

OnBackupThisProject() protected method

Handle the File/Backup and Restore menu command
protected OnBackupThisProject ( object arg ) : bool
arg object
return bool

OnChooseLangProject() public method

public OnChooseLangProject ( object command ) : bool
command object
return bool

OnClosed() protected method

protected OnClosed ( EventArgs e ) : void
e System.EventArgs
return void

OnCreateShortcut() public method

Handle the Create Shortcut on Desktop menu/toolbar item.
public OnCreateShortcut ( object args ) : bool
args object
return bool

OnDeleteProject() protected method

Handle the File/"Project Management"/Delete... menu command
protected OnDeleteProject ( object args ) : bool
args object
return bool

OnDisplayArchiveWithRamp() public method

Handle whether to enable Archive With RAMP menu item (enabled iff properly installed)
public OnDisplayArchiveWithRamp ( object command, XCore.UIItemDisplayProperties &display ) : bool
command object Not used
display XCore.UIItemDisplayProperties Display properties
return bool

OnDisplayDeleteProject() protected method

Disables/enables the File/"Project Management"/Delete... menu item
protected OnDisplayDeleteProject ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayEditCopy() public method

This is very similar to OnUpdateEditCopy, but for xCore applications.
public OnDisplayEditCopy ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayEditCut() public method

This is very similar to OnUpdateEditCut, but for xCore applications.
public OnDisplayEditCut ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayEditPaste() public method

This is very similar to OnUpdateEditPaste, but for xCore applications.
public OnDisplayEditPaste ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayEditSelectAll() public method

Enable the SelectAll command if appropriate
public OnDisplayEditSelectAll ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayFileProjectSharingLocation() protected method

Updates the enabled state of the File Project Sharing Location menu item
protected OnDisplayFileProjectSharingLocation ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayFormatApplyStyle() protected method

Enable the menu command for Format/Styles, if we can.
protected OnDisplayFormatApplyStyle ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayImportTranslatedLists() public method

Display this import command everywhere.
public OnDisplayImportTranslatedLists ( object parameters, XCore.UIItemDisplayProperties &display ) : bool
parameters object
display XCore.UIItemDisplayProperties
return bool

OnDisplayInsertLinkToFile() public method

Enable the InsertLinkToFile command
public OnDisplayInsertLinkToFile ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayPasteUrl() public method

Enable the PasteUrl command
public OnDisplayPasteUrl ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayRedo() protected method

Disables/enables the Edit/Redo menu item
protected OnDisplayRedo ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplaySaveLangProject() public method

This is very similar to OnUpdateFileSave, but for xCore applications.
public OnDisplaySaveLangProject ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayShowCharMap() public method

This method enables the Character Map command if the exe exists in the system dir.
public OnDisplayShowCharMap ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayUndo() protected method

Disables/enables the Edit/Undo menu item
protected OnDisplayUndo ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayUtilities() public method

public OnDisplayUtilities ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnDisplayWritingSystemProperties() public method

This is very similar to OnUpdateEditCut, but for xCore applications.
public OnDisplayWritingSystemProperties ( object commandObject, XCore.UIItemDisplayProperties &display ) : bool
commandObject object
display XCore.UIItemDisplayProperties
return bool

OnEditCopy() public method

public OnEditCopy ( object arg ) : bool
arg object
return bool

OnEditCut() public method

public OnEditCut ( object arg ) : bool
arg object
return bool

OnEditFind() public method

Handle the Find menu command.
public OnEditFind ( object args ) : bool
args object Arguments
return bool

OnEditPaste() public method

public OnEditPaste ( object arg ) : bool
arg object
return bool

OnEditReplace() public method

Handle the Find menu command.
public OnEditReplace ( object args ) : bool
args object Arguments
return bool

OnEditSelectAll() public method

Implement the SelectAll command (for the active view).
public OnEditSelectAll ( object arg ) : bool
arg object
return bool

OnExitApplication() public method

Exits the application :)
public OnExitApplication ( object param ) : bool
param object
return bool

OnFileProjectProperties() protected method

Display the project properties dialog
protected OnFileProjectProperties ( object command ) : bool
command object
return bool

OnFileProjectSharingLocation() protected method

Handle the File/Restore menu command
protected OnFileProjectSharingLocation ( object arg ) : bool
arg object
return bool

OnFinishedInit() public method

Called when a window is finished being created and completely initialized.
public OnFinishedInit ( ) : bool
return bool

OnFormatApplyStyle() protected method

Shows the apply style dialog
protected OnFormatApplyStyle ( object args ) : bool
args object ignored
return bool

OnFormatStyle() protected method

Shows the Styles dialog
protected OnFormatStyle ( object args ) : bool
args object ignored
return bool

OnHandleCreated() protected method

protected OnHandleCreated ( EventArgs e ) : void
e System.EventArgs
return void

OnHelpAbout() protected method

Show Help About dialog
protected OnHelpAbout ( object args ) : bool
args object
return bool

OnHelpCheckForUpdates() protected method

Check if any updates to FW are available
protected OnHelpCheckForUpdates ( object args ) : bool
args object
return bool

OnHelpMakeSuggestion() protected method

Show dialog to report a bug in the system
protected OnHelpMakeSuggestion ( object args ) : bool
args object
return bool

OnHelpReportProblem() protected method

Show dialog to report a bug in the system
protected OnHelpReportProblem ( object args ) : bool
args object
return bool

OnIdle() public method

If a property requests it, do a db sync.
public OnIdle ( object sender ) : void
sender object
return void

OnImportTranslatedLists() public method

Import a file contained translated strings for one or more lists.
See FWR-1739.
public OnImportTranslatedLists ( object commandObject ) : bool
commandObject object
return bool

OnInsertLinkToFile() public method

Handle the InsertLinkToFile command
public OnInsertLinkToFile ( object arg ) : bool
arg object
return bool

OnNewLangProject() public method

public OnNewLangProject ( object command ) : bool
command object
return bool

OnNewWindow() public method

public OnNewWindow ( object command ) : bool
command object
return bool

OnPasteUrl() public method

Paste what is in the clipboard as a URL
public OnPasteUrl ( object arg ) : bool
arg object
return bool

OnPropertyChanged() public method

public OnPropertyChanged ( string name ) : void
name string
return void

OnRedo() protected method

This function will redo the last changes undone to the project. This function is executed when the user clicks the redo menu item.
protected OnRedo ( object args ) : bool
args object
return bool

OnRestoreAProject() protected method

Handle the File/Backup and Restore menu command
protected OnRestoreAProject ( object arg ) : bool
arg object
return bool

OnSaveLangProject() public method

public OnSaveLangProject ( object command ) : bool
command object
return bool

OnShowCharMap() public method

Start the Character Map program (if it's found).
public OnShowCharMap ( object command ) : bool
command object
return bool

OnStartLogging() protected method

Start logging events.
protected OnStartLogging ( object args ) : bool
args object
return bool

OnStylesRenamedOrDeleted() public method

Called when styles are renamed or deleted.
public OnStylesRenamedOrDeleted ( ) : void
return void

OnUndo() protected method

This function will undo the last changes done to the project. This function is executed when the user clicks the undo menu item.
protected OnUndo ( object args ) : bool
args object Unused
return bool

OnUpdateArchiveWithRamp() public method

Update Archive With RAMP menu item
public OnUpdateArchiveWithRamp ( object args ) : bool
args object the toolbar/menu item properties
return bool

OnUtilities() public method

public OnUtilities ( object command ) : bool
command object
return bool

OnWritingSystemProperties() public method

Display the project properties dialog, but starting with the WS page.
public OnWritingSystemProperties ( object arg ) : bool
arg object
return bool

PopulateParaStyleListOverride() public method

Allows individual implementations to override the default behavior when populating the paragraph style list.
public PopulateParaStyleListOverride ( ) : bool
return bool

PreSynchronize() public method

Called just before a window syncronizes it's views with DB changes (e.g. when an undo or redo command is issued).
public PreSynchronize ( SyncMsg sync ) : void
sync SyncMsg syncronization message
return void

PrepareToRefresh() public method

Called in FwXApp.OnMasterRefresh BEFORE clearing the cache, typically to save any work in progress.
public PrepareToRefresh ( ) : void
return void

RefreshAllViews() public method

JohnT: this might be a poorly named or obsolete message. Kept because there are some callers and I don't have time to analyze them all. Generally better to use RefreshDisplay().
public RefreshAllViews ( ) : void
return void

RefreshDisplay() public method

Collect refreshable caches from every child which has one and refresh them (once each). Call RefreshDisplay for every child control (recursively) which implements it. returns true if all the children have been processed by this class.
public RefreshDisplay ( ) : bool
return bool

RestoreProperties() protected method

FwXWindow also restores database-specific properties.
protected RestoreProperties ( ) : void
return void

SaveSettings() public method

public SaveSettings ( ) : void
return void

SaveSettingsNow() public method

Save the persisted settings now.
public SaveSettingsNow ( ) : void
return void

ShowApplyStyleDialog() public method

Shows the Format Apply Style dialog
public ShowApplyStyleDialog ( string paraStyleName, string charStyleName, int maxStyleLevel ) : void
paraStyleName string The currently-selected Paragraph style name
charStyleName string The currently-selected Character style name
maxStyleLevel int The maximum style level that will be shown in this /// dialog. (apps that do not use style levels in their stylesheets can pass 0)
return void

ShowStylesDialog() public method

Required interface member to launch the style dialog.
public ShowStylesDialog ( string paraStyleName, string charStyleName, Action setPropsToFactorySettings ) : bool
paraStyleName string Name of the initially selected paragraph style.
charStyleName string Name of the initially selected character style.
setPropsToFactorySettings Action Delegate to set style info properties back /// to the default facotry settings
return bool

Synchronize() public method

Called when a window syncronizes it's views with DB changes (e.g. when an undo or redo command is issued).
public Synchronize ( SyncMsg sync ) : bool
sync SyncMsg syncronization message
return bool

WndProc() protected method

Keyman's select language message must be forwarded to the focus window to take useful effect.
protected WndProc ( Message &m ) : void
m System.Windows.Forms.Message
return void

XWindow_Closing() protected method

protected XWindow_Closing ( object sender, System e ) : void
sender object
e System
return void

Property Details

m_StyleSheet protected_oe property

The stylesheet used for all views in this window.
protected FwStyleSheet m_StyleSheet
return FwStyleSheet

m_app protected_oe property

protected FwApp,SIL.FieldWorks.Common.Framework m_app
return SIL.FieldWorks.Common.Framework.FwApp

m_configFile protected_oe property

Configuration file pathname.
protected string m_configFile
return string

m_delegate protected_oe property

Shared functionality of FwXWindow and FwMainWnd may be delegated here.
protected MainWindowDelegate,SIL.FieldWorks.Common.Framework m_delegate
return SIL.FieldWorks.Common.Framework.MainWindowDelegate

m_fWindowIsCopy protected_oe property

Flag indicating whether or not this instance of MainWnd is a copy of another Wnd (i.e. created by choosing the "Window/New Window" menu).
protected bool m_fWindowIsCopy
return bool

m_installedVirtualHandlers protected_oe property

list of the virtual handlers we loaded.
protected List m_installedVirtualHandlers
return List

m_startupLink protected_oe property

Set by the owning application during startup when it has a url/link command line parameter
protected FwLinkArgs m_startupLink
return FwLinkArgs

m_viewHelper protected_oe property

protected ActiveViewHelper,SIL.FieldWorks.Common.RootSites m_viewHelper
return SIL.FieldWorks.Common.RootSites.ActiveViewHelper

s_wm_kmselectlang protected_oe static_oe property

Keyman select language message
protected static uint s_wm_kmselectlang
return uint