Пример #1
0
        private static void OpenOption(string keyName, string valueName, bool open)
        {
            Int32 value = GetInt32Value(keyName, valueName, 0);

            IntUtil.TriggleBits(ref value, 0x00000001, open);

            Registry.SetValue(keyName, valueName, value, RegistryValueKind.DWord);
        }
Пример #2
0
        private static Int32 GetNoDrivesValue(SortedDictionary <string, bool> driveVisibilityDict)
        {
            Int32 value = 0;

            foreach (var item in driveVisibilityDict)
            {
                if (noDrivesDict.ContainsKey(item.Key))
                {
                    IntUtil.TriggleBits(ref value, noDrivesDict[item.Key], !item.Value);
                }
            }

            return(value);
        }
Пример #3
0
        private static bool IsOptionOpened(string keyName, string valueName)
        {
            Int32 value = GetInt32Value(keyName, valueName, 0);

            return(IntUtil.IsBitsSet(value, 0x00000001));
        }