コード例 #1
0
        public void LoadPreferences()
        {
            XmlPreferenceReader         xmlReader           = new XmlPreferenceReader(this);
            Dictionary <string, string> workstationPrefsMap = xmlReader.GetWorkstationPreferencesFromFile();

            _workstationPreferences.LoadSearchPreferences(workstationPrefsMap);
        }
コード例 #2
0
        private void LoadPreferences()
        {
            XmlPreferenceReader         xmlReader   = new XmlPreferenceReader(this);
            Dictionary <string, string> preferences = xmlReader.GetPreferences();

            if (preferences != null)
            {
                bool parseSuccessful = bool.TryParse(preferences["SearchEntireDirectory"], out searchEntireDirectory);
                if (!parseSuccessful)
                {
                    searchEntireDirectory = true;
                }
                string groups = preferences["Groups"];
                if (string.IsNullOrEmpty(groups))
                {
                    return;
                }
                else
                {
                    ParseGroupsString(groups);
                }
            }
            else
            {
                searchEntireDirectory = true;
            }
        }