added accessibility labels to UI controls
This commit is contained in:
parent
9d5792c7ec
commit
8a19b205de
5 changed files with 37 additions and 3 deletions
|
@ -24,13 +24,19 @@ namespace SafeExamBrowser.I18n.Contracts
|
||||||
Browser_LoadErrorTitle,
|
Browser_LoadErrorTitle,
|
||||||
Browser_Name,
|
Browser_Name,
|
||||||
Browser_Tooltip,
|
Browser_Tooltip,
|
||||||
|
BrowserWindow_BackwardButton,
|
||||||
BrowserWindow_DeveloperConsoleMenuItem,
|
BrowserWindow_DeveloperConsoleMenuItem,
|
||||||
BrowserWindow_Downloading,
|
BrowserWindow_Downloading,
|
||||||
BrowserWindow_DownloadCancelled,
|
BrowserWindow_DownloadCancelled,
|
||||||
BrowserWindow_DownloadComplete,
|
BrowserWindow_DownloadComplete,
|
||||||
|
BrowserWindow_DownloadsButton,
|
||||||
BrowserWindow_FindCaseSensitive,
|
BrowserWindow_FindCaseSensitive,
|
||||||
BrowserWindow_FindMenuItem,
|
BrowserWindow_FindMenuItem,
|
||||||
|
BrowserWindow_ForwardButton,
|
||||||
|
BrowserWindow_HomeButton,
|
||||||
|
BrowserWindow_MenuButton,
|
||||||
BrowserWindow_ReloadButton,
|
BrowserWindow_ReloadButton,
|
||||||
|
BrowserWindow_UrlTextBox,
|
||||||
BrowserWindow_ZoomMenuItem,
|
BrowserWindow_ZoomMenuItem,
|
||||||
Build,
|
Build,
|
||||||
ExamSelectionDialog_Cancel,
|
ExamSelectionDialog_Cancel,
|
||||||
|
|
|
@ -49,7 +49,25 @@
|
||||||
Search page...
|
Search page...
|
||||||
</Entry>
|
</Entry>
|
||||||
<Entry key="BrowserWindow_ReloadButton">
|
<Entry key="BrowserWindow_ReloadButton">
|
||||||
Reload button
|
Reload
|
||||||
|
</Entry>
|
||||||
|
<Entry key="BrowserWindow_BackwardButton">
|
||||||
|
Backward
|
||||||
|
</Entry>
|
||||||
|
<Entry key="BrowserWindow_ForwardButton">
|
||||||
|
Forward
|
||||||
|
</Entry>
|
||||||
|
<Entry key="BrowserWindow_DownloadsButton">
|
||||||
|
Download
|
||||||
|
</Entry>
|
||||||
|
<Entry key="BrowserWindow_HomeButton">
|
||||||
|
Home
|
||||||
|
</Entry>
|
||||||
|
<Entry key="BrowserWindow_MenuButton">
|
||||||
|
Menu
|
||||||
|
</Entry>
|
||||||
|
<Entry key="BrowserWindow_UrlTextBox">
|
||||||
|
Enter URL
|
||||||
</Entry>
|
</Entry>
|
||||||
<Entry key="BrowserWindow_ZoomMenuItem">
|
<Entry key="BrowserWindow_ZoomMenuItem">
|
||||||
Page Zoom
|
Page Zoom
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||||
xmlns:local="clr-namespace:SafeExamBrowser.UserInterface.Desktop.Controls"
|
xmlns:local="clr-namespace:SafeExamBrowser.UserInterface.Desktop.Controls"
|
||||||
|
x:Name="root"
|
||||||
mc:Ignorable="d" d:DesignHeight="40" d:DesignWidth="40">
|
mc:Ignorable="d" d:DesignHeight="40" d:DesignWidth="40">
|
||||||
<UserControl.Resources>
|
<UserControl.Resources>
|
||||||
<ResourceDictionary>
|
<ResourceDictionary>
|
||||||
|
@ -15,6 +16,7 @@
|
||||||
</UserControl.Resources>
|
</UserControl.Resources>
|
||||||
<Grid>
|
<Grid>
|
||||||
<Button x:Name="Button" Click="Button_Click" Background="{StaticResource BackgroundBrush}" HorizontalAlignment="Stretch"
|
<Button x:Name="Button" Click="Button_Click" Background="{StaticResource BackgroundBrush}" HorizontalAlignment="Stretch"
|
||||||
Template="{StaticResource TaskbarButton}" VerticalAlignment="Stretch" />
|
Template="{StaticResource TaskbarButton}" VerticalAlignment="Stretch"
|
||||||
|
AutomationProperties.Name="{Binding Path=(AutomationProperties.Name), ElementName=root}"/>
|
||||||
</Grid>
|
</Grid>
|
||||||
</UserControl>
|
</UserControl>
|
||||||
|
|
|
@ -578,6 +578,12 @@ if (typeof __SEB_focusElement === 'undefined') {
|
||||||
FindMenuText.Text = text.Get(TextKey.BrowserWindow_FindMenuItem);
|
FindMenuText.Text = text.Get(TextKey.BrowserWindow_FindMenuItem);
|
||||||
ZoomText.Text = text.Get(TextKey.BrowserWindow_ZoomMenuItem);
|
ZoomText.Text = text.Get(TextKey.BrowserWindow_ZoomMenuItem);
|
||||||
ReloadButton.SetValue(System.Windows.Automation.AutomationProperties.NameProperty, text.Get(TextKey.BrowserWindow_ReloadButton));
|
ReloadButton.SetValue(System.Windows.Automation.AutomationProperties.NameProperty, text.Get(TextKey.BrowserWindow_ReloadButton));
|
||||||
|
BackwardButton.SetValue(System.Windows.Automation.AutomationProperties.NameProperty, text.Get(TextKey.BrowserWindow_BackwardButton));
|
||||||
|
ForwardButton.SetValue(System.Windows.Automation.AutomationProperties.NameProperty, text.Get(TextKey.BrowserWindow_ForwardButton));
|
||||||
|
DownloadsButton.SetValue(System.Windows.Automation.AutomationProperties.NameProperty, text.Get(TextKey.BrowserWindow_DownloadsButton));
|
||||||
|
HomeButton.SetValue(System.Windows.Automation.AutomationProperties.NameProperty, text.Get(TextKey.BrowserWindow_HomeButton));
|
||||||
|
MenuButton.SetValue(System.Windows.Automation.AutomationProperties.NameProperty, text.Get(TextKey.BrowserWindow_MenuButton));
|
||||||
|
UrlTextBox.SetValue(System.Windows.Automation.AutomationProperties.NameProperty, text.Get(TextKey.BrowserWindow_UrlTextBox));
|
||||||
}
|
}
|
||||||
|
|
||||||
public void FocusToolbar(bool forward)
|
public void FocusToolbar(bool forward)
|
||||||
|
|
|
@ -125,7 +125,9 @@ namespace SafeExamBrowser.UserInterface.Desktop.Windows
|
||||||
{
|
{
|
||||||
Dispatcher.Invoke(() =>
|
Dispatcher.Invoke(() =>
|
||||||
{
|
{
|
||||||
QuitButton.ToolTip = text.Get(TextKey.Shell_QuitButton);
|
var txt = text.Get(TextKey.Shell_QuitButton);
|
||||||
|
QuitButton.ToolTip = txt;
|
||||||
|
QuitButton.SetValue(System.Windows.Automation.AutomationProperties.NameProperty, txt);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue