Unified naming and comments for settings.

This commit is contained in:
dbuechel 2019-09-10 11:53:30 +02:00
parent 1dd65e1bda
commit dda48396b3
14 changed files with 45 additions and 45 deletions

View file

@ -42,7 +42,7 @@ namespace SafeExamBrowser.Browser
private BrowserWindowSettings WindowSettings
{
get { return isMainInstance ? settings.MainWindowSettings : settings.AdditionalWindowSettings; }
get { return isMainInstance ? settings.MainWindow : settings.AdditionalWindow; }
}
public InstanceIdentifier Id { get; private set; }

View file

@ -19,7 +19,7 @@ namespace SafeExamBrowser.Configuration.ConfigurationData
{
if (value is bool allow)
{
settings.Browser.MainWindowSettings.AllowAddressBar = allow;
settings.Browser.MainWindow.AllowAddressBar = allow;
}
}
@ -27,7 +27,7 @@ namespace SafeExamBrowser.Configuration.ConfigurationData
{
if (value is bool allow)
{
settings.Browser.AdditionalWindowSettings.AllowAddressBar = allow;
settings.Browser.AdditionalWindow.AllowAddressBar = allow;
}
}
@ -43,8 +43,8 @@ namespace SafeExamBrowser.Configuration.ConfigurationData
{
if (value is bool allow)
{
settings.Browser.MainWindowSettings.AllowDeveloperConsole = allow;
settings.Browser.AdditionalWindowSettings.AllowDeveloperConsole = allow;
settings.Browser.MainWindow.AllowDeveloperConsole = allow;
settings.Browser.AdditionalWindow.AllowDeveloperConsole = allow;
}
}
@ -60,8 +60,8 @@ namespace SafeExamBrowser.Configuration.ConfigurationData
{
if (value is bool allow)
{
settings.Browser.MainWindowSettings.AllowBackwardNavigation = allow;
settings.Browser.MainWindowSettings.AllowForwardNavigation = allow;
settings.Browser.MainWindow.AllowBackwardNavigation = allow;
settings.Browser.MainWindow.AllowForwardNavigation = allow;
}
}
@ -69,8 +69,8 @@ namespace SafeExamBrowser.Configuration.ConfigurationData
{
if (value is bool allow)
{
settings.Browser.AdditionalWindowSettings.AllowBackwardNavigation = allow;
settings.Browser.AdditionalWindowSettings.AllowForwardNavigation = allow;
settings.Browser.AdditionalWindow.AllowBackwardNavigation = allow;
settings.Browser.AdditionalWindow.AllowForwardNavigation = allow;
}
}
@ -94,7 +94,7 @@ namespace SafeExamBrowser.Configuration.ConfigurationData
{
if (value is bool allow)
{
settings.Browser.MainWindowSettings.AllowReloading = allow;
settings.Browser.MainWindow.AllowReloading = allow;
}
}
@ -102,7 +102,7 @@ namespace SafeExamBrowser.Configuration.ConfigurationData
{
if (value is bool allow)
{
settings.Browser.AdditionalWindowSettings.AllowReloading = allow;
settings.Browser.AdditionalWindow.AllowReloading = allow;
}
}
@ -164,7 +164,7 @@ namespace SafeExamBrowser.Configuration.ConfigurationData
if (value is int mode)
{
settings.Browser.MainWindowSettings.FullScreenMode = mode == FULLSCREEN;
settings.Browser.MainWindow.FullScreenMode = mode == FULLSCREEN;
}
}
@ -172,7 +172,7 @@ namespace SafeExamBrowser.Configuration.ConfigurationData
{
if (value is bool show)
{
settings.Browser.MainWindowSettings.ShowReloadWarning = show;
settings.Browser.MainWindow.ShowReloadWarning = show;
}
}
@ -180,7 +180,7 @@ namespace SafeExamBrowser.Configuration.ConfigurationData
{
if (value is bool show)
{
settings.Browser.AdditionalWindowSettings.ShowReloadWarning = show;
settings.Browser.AdditionalWindow.ShowReloadWarning = show;
}
}

View file

@ -115,20 +115,20 @@ namespace SafeExamBrowser.Configuration.ConfigurationData
settings.Browser.AllowDownloads = true;
settings.Browser.AllowPageZoom = true;
settings.Browser.AllowPopups = true;
settings.Browser.AdditionalWindowSettings.AllowAddressBar = false;
settings.Browser.AdditionalWindowSettings.AllowBackwardNavigation = true;
settings.Browser.AdditionalWindowSettings.AllowDeveloperConsole = false;
settings.Browser.AdditionalWindowSettings.AllowForwardNavigation = true;
settings.Browser.AdditionalWindowSettings.AllowReloading = true;
settings.Browser.AdditionalWindowSettings.FullScreenMode = false;
settings.Browser.AdditionalWindowSettings.ShowReloadWarning = false;
settings.Browser.MainWindowSettings.AllowAddressBar = false;
settings.Browser.MainWindowSettings.AllowBackwardNavigation = false;
settings.Browser.MainWindowSettings.AllowDeveloperConsole = false;
settings.Browser.MainWindowSettings.AllowForwardNavigation = false;
settings.Browser.MainWindowSettings.AllowReloading = true;
settings.Browser.MainWindowSettings.FullScreenMode = false;
settings.Browser.MainWindowSettings.ShowReloadWarning = true;
settings.Browser.AdditionalWindow.AllowAddressBar = false;
settings.Browser.AdditionalWindow.AllowBackwardNavigation = true;
settings.Browser.AdditionalWindow.AllowDeveloperConsole = false;
settings.Browser.AdditionalWindow.AllowForwardNavigation = true;
settings.Browser.AdditionalWindow.AllowReloading = true;
settings.Browser.AdditionalWindow.FullScreenMode = false;
settings.Browser.AdditionalWindow.ShowReloadWarning = false;
settings.Browser.MainWindow.AllowAddressBar = false;
settings.Browser.MainWindow.AllowBackwardNavigation = false;
settings.Browser.MainWindow.AllowDeveloperConsole = false;
settings.Browser.MainWindow.AllowForwardNavigation = false;
settings.Browser.MainWindow.AllowReloading = true;
settings.Browser.MainWindow.FullScreenMode = false;
settings.Browser.MainWindow.ShowReloadWarning = true;
settings.Keyboard.AllowAltEsc = false;
settings.Keyboard.AllowAltF4 = false;

View file

@ -12,7 +12,7 @@ using System.Collections.Generic;
namespace SafeExamBrowser.Settings.Browser
{
/// <summary>
/// Defines all configuration options for the request filter of the browser.
/// Defines all settings for the request filter of the browser.
/// </summary>
[Serializable]
public class BrowserFilterSettings

View file

@ -11,15 +11,15 @@ using System;
namespace SafeExamBrowser.Settings.Browser
{
/// <summary>
/// Defines all configuration options for the browser engine of the application.
/// Defines all settings for the browser engine of the application.
/// </summary>
[Serializable]
public class BrowserSettings
{
/// <summary>
/// The configuration to be used for additional browser windows.
/// The settings to be used for additional browser windows.
/// </summary>
public BrowserWindowSettings AdditionalWindowSettings { get; set; }
public BrowserWindowSettings AdditionalWindow { get; set; }
/// <summary>
/// Determines whether the user will be allowed to download configuration files.
@ -52,9 +52,9 @@ namespace SafeExamBrowser.Settings.Browser
public BrowserFilterSettings Filter { get; set; }
/// <summary>
/// The configuration to be used for the main browser window.
/// The settings to be used for the main browser window.
/// </summary>
public BrowserWindowSettings MainWindowSettings { get; set; }
public BrowserWindowSettings MainWindow { get; set; }
/// <summary>
/// The URL with which the main browser window will be loaded.
@ -68,9 +68,9 @@ namespace SafeExamBrowser.Settings.Browser
public BrowserSettings()
{
AdditionalWindowSettings = new BrowserWindowSettings();
AdditionalWindow = new BrowserWindowSettings();
Filter = new BrowserFilterSettings();
MainWindowSettings = new BrowserWindowSettings();
MainWindow = new BrowserWindowSettings();
}
}
}

View file

@ -11,7 +11,7 @@ using System;
namespace SafeExamBrowser.Settings.Browser
{
/// <summary>
/// Defines all configuration options for a window of the browser engine.
/// Defines all settings for a window of the browser engine.
/// </summary>
[Serializable]
public class BrowserWindowSettings

View file

@ -11,7 +11,7 @@ using System;
namespace SafeExamBrowser.Settings.Monitoring
{
/// <summary>
/// Defines all configuration options for monitoring keyboard input.
/// Defines all settings for monitoring keyboard input.
/// </summary>
[Serializable]
public class KeyboardSettings

View file

@ -11,7 +11,7 @@ using System;
namespace SafeExamBrowser.Settings.Monitoring
{
/// <summary>
/// Defines all configuration options for monitoring mouse input.
/// Defines all settings for monitoring mouse input.
/// </summary>
[Serializable]
public class MouseSettings

View file

@ -9,7 +9,7 @@
namespace SafeExamBrowser.Settings.Service
{
/// <summary>
/// Defines all configuration options for the service application component.
/// Defines all settings for the service application component.
/// </summary>
public class ServiceSettings
{

View file

@ -11,7 +11,7 @@ using System;
namespace SafeExamBrowser.Settings.SystemComponents
{
/// <summary>
/// Defines all configuration options for the audio device of the computer.
/// Defines all settings for the audio device of the computer.
/// </summary>
[Serializable]
public class AudioSettings

View file

@ -11,7 +11,7 @@ using System;
namespace SafeExamBrowser.Settings.UserInterface
{
/// <summary>
/// Defines all configuration options for the action center.
/// Defines all settings for the action center.
/// </summary>
[Serializable]
public class ActionCenterSettings

View file

@ -11,7 +11,7 @@ using System;
namespace SafeExamBrowser.Settings.UserInterface
{
/// <summary>
/// Defines all configuration options for the taskbar.
/// Defines all settings for the taskbar.
/// </summary>
[Serializable]
public class TaskbarSettings

View file

@ -35,7 +35,7 @@ namespace SafeExamBrowser.UserInterface.Desktop
private BrowserWindowSettings WindowSettings
{
get { return isMainWindow ? settings.MainWindowSettings : settings.AdditionalWindowSettings; }
get { return isMainWindow ? settings.MainWindow : settings.AdditionalWindow; }
}
public bool CanNavigateBackwards { set => Dispatcher.Invoke(() => BackwardButton.IsEnabled = value); }

View file

@ -35,7 +35,7 @@ namespace SafeExamBrowser.UserInterface.Mobile
private BrowserWindowSettings WindowSettings
{
get { return isMainWindow ? settings.MainWindowSettings : settings.AdditionalWindowSettings; }
get { return isMainWindow ? settings.MainWindow : settings.AdditionalWindow; }
}
public bool CanNavigateBackwards { set => Dispatcher.Invoke(() => BackwardButton.IsEnabled = value); }