C# Класс SIL.FieldWorks.Common.FwUtils.FwRegistryHelper

Helper class for accessing FieldWorks-specific registry settings
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
Paratext7orLaterInstalled ( ) : bool

Determines the installation or absence of the Paratext program by checking for the existence of the registry key that that application uses to store its program files directory in the local machine settings. This is 'HKLM\Software\ScrChecks\1.0\Program_Files_Directory_Ptw(7,8,9)' NOTE: This key is not opened for write access because it will fail on non-administrator logins.

SetValueAsAdmin ( this key, string name, string value ) : void

Extension method to write a registry key to somewhere in HKLM hopfully with eleverating privileges. This method can cause the UAC dialog to be shown to the user (on Vista or later). Can throw SecurityException on permissions problems.

UpgradeUserSettingsIfNeeded ( ) : void

E.g. the first time the user runs FW8, we need to copy a bunch of registry keys from HKCU/Software/SIL/FieldWorks/7.0 -> FieldWorks/8.

Приватные методы

Метод Описание
CopyAllValuesToNewSubKey ( RegistryKey srcSubKey, RegistryKey destSubKey ) : void
CopySubKeyTree ( RegistryKey srcSubKey, RegistryKey destSubKey ) : void
CopyValueToNewKey ( string valueName, RegistryKey oldSubKey, RegistryKey newSubKey ) : void
MigrateVersion7ValueIfNeeded ( ) : void

Описание методов

Paratext7orLaterInstalled() публичный статический Метод

Determines the installation or absence of the Paratext program by checking for the existence of the registry key that that application uses to store its program files directory in the local machine settings. This is 'HKLM\Software\ScrChecks\1.0\Program_Files_Directory_Ptw(7,8,9)' NOTE: This key is not opened for write access because it will fail on non-administrator logins.
public static Paratext7orLaterInstalled ( ) : bool
Результат bool

SetValueAsAdmin() публичный статический Метод

Extension method to write a registry key to somewhere in HKLM hopfully with eleverating privileges. This method can cause the UAC dialog to be shown to the user (on Vista or later). Can throw SecurityException on permissions problems.
public static SetValueAsAdmin ( this key, string name, string value ) : void
key this
name string
value string
Результат void

UpgradeUserSettingsIfNeeded() публичный статический Метод

E.g. the first time the user runs FW8, we need to copy a bunch of registry keys from HKCU/Software/SIL/FieldWorks/7.0 -> FieldWorks/8.
public static UpgradeUserSettingsIfNeeded ( ) : void
Результат void