mirror of
https://github.com/Hofknecht/SystemTrayMenu.git
synced 2024-06-02 18:44:56 +12:00
Reordered methods to avoid compiler warnings
This commit is contained in:
parent
713ae57f70
commit
f2c20c5a5e
|
@ -154,6 +154,24 @@ namespace SystemTrayMenu.Properties
|
|||
SaveValuesToFile();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates an empty user.config file...looks like the one MS creates.
|
||||
/// This could be overkill a simple key/value pairing would probably do.
|
||||
/// </summary>
|
||||
private static void CreateEmptyConfig()
|
||||
{
|
||||
var doc = new XDocument();
|
||||
var declaration = new XDeclaration("1.0", "utf-8", "true");
|
||||
var config = new XElement(Config);
|
||||
var userSettings = new XElement(UserSettings);
|
||||
var group = new XElement(typeof(Properties.Settings).FullName);
|
||||
userSettings.Add(group);
|
||||
config.Add(userSettings);
|
||||
doc.Add(config);
|
||||
doc.Declaration = declaration;
|
||||
doc.Save(UserConfigPath);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Loads the values of the file into memory.
|
||||
/// </summary>
|
||||
|
@ -185,24 +203,6 @@ namespace SystemTrayMenu.Properties
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates an empty user.config file...looks like the one MS creates.
|
||||
/// This could be overkill a simple key/value pairing would probably do.
|
||||
/// </summary>
|
||||
private void CreateEmptyConfig()
|
||||
{
|
||||
var doc = new XDocument();
|
||||
var declaration = new XDeclaration("1.0", "utf-8", "true");
|
||||
var config = new XElement(Config);
|
||||
var userSettings = new XElement(UserSettings);
|
||||
var group = new XElement(typeof(Properties.Settings).FullName);
|
||||
userSettings.Add(group);
|
||||
config.Add(userSettings);
|
||||
doc.Add(config);
|
||||
doc.Declaration = declaration;
|
||||
doc.Save(UserConfigPath);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Saves the in memory dictionary to the user config file.
|
||||
/// </summary>
|
||||
|
|
Loading…
Reference in a new issue