@@ -61,6 +61,7 @@ internal partial class ManagePackagesDialog : ExtendedTitleBarDialog
6161 Label errorMessageLabel ;
6262 Label loadingSpinnerLabel ;
6363 FrameBox noPackagesFoundFrame ;
64+ Label noPackagesFoundLabel ;
6465 ComboBox packageVersionComboBox ;
6566 HBox packageVersionsHBox ;
6667 Label packageVersionsLabel ;
@@ -94,9 +95,19 @@ void Build ()
9495 var topHBox = new HBox ( ) ;
9596 topHBox . Margin = new WidgetSpacing ( 8 , 5 , 6 , 5 ) ;
9697
98+ // HACK: VoiceOver does not work when using Accessible.Label so workaround this by using
99+ // Accessible.LabelWidget and hide the label since we do not need it.
100+ var packageSourceLabel = new Label ( ) ;
101+ packageSourceLabel . Text = GettextCatalog . GetString ( "Package source" ) ;
102+ packageSourceLabel . Visible = false ;
103+ topHBox . PackStart ( packageSourceLabel ) ;
104+
97105 packageSourceComboBox = new ComboBox ( ) ;
98106 packageSourceComboBox . Name = "packageSourceComboBox" ;
99107 packageSourceComboBox . MinWidth = 200 ;
108+ // Does not work:
109+ //packageSourceComboBox.Accessible.Label = GettextCatalog.GetString ("Package source");
110+ packageSourceComboBox . Accessible . LabelWidget = packageSourceLabel ;
100111 topHBox . PackStart ( packageSourceComboBox ) ;
101112
102113 int tabLabelMinWidth = 60 ;
@@ -137,6 +148,7 @@ void Build ()
137148 packageSearchEntry = new SearchTextEntry ( ) ;
138149 packageSearchEntry . Name = "managePackagesDialogSearchEntry" ;
139150 packageSearchEntry . WidthRequest = 187 ;
151+ packageSearchEntry . PlaceholderText = GettextCatalog . GetString ( "Search" ) ;
140152 packageSearchEntry . Accessible . Label = GettextCatalog . GetString ( "Package Search" ) ;
141153 topHBox . PackEnd ( packageSearchEntry ) ;
142154
@@ -179,6 +191,7 @@ void Build ()
179191 packagesListView = new ListView ( ) ;
180192 packagesListView . BorderVisible = false ;
181193 packagesListView . HeadersVisible = false ;
194+ packagesListView . Accessible . Label = GettextCatalog . GetString ( "Packages" ) ;
182195 packagesListVBox . PackStart ( packagesListView , true , true ) ;
183196
184197 // Loading spinner.
@@ -204,7 +217,7 @@ void Build ()
204217 var noPackagesFoundHBox = new HBox ( ) ;
205218 noPackagesFoundHBox . HorizontalPlacement = WidgetPlacement . Center ;
206219
207- var noPackagesFoundLabel = new Label ( ) ;
220+ noPackagesFoundLabel = new Label ( ) ;
208221 noPackagesFoundLabel . Text = GettextCatalog . GetString ( "No matching packages found." ) ;
209222 noPackagesFoundHBox . PackEnd ( noPackagesFoundLabel ) ;
210223
@@ -273,17 +286,19 @@ void Build ()
273286
274287 var packageIdLabel = new Label ( ) ;
275288 packageIdLabel . Font = packageInfoBoldFont ;
276- packageIdLabel . Text = GettextCatalog . GetString ( "Id " ) ;
289+ packageIdLabel . Text = GettextCatalog . GetString ( "ID " ) ;
277290 packageIdHBox . PackStart ( packageIdLabel ) ;
278291
279292 packageId = new Label ( ) ;
280293 packageId . Ellipsize = EllipsizeMode . End ;
281294 packageId . TextAlignment = Alignment . End ;
282295 packageId . Font = packageInfoSmallFont ;
296+ packageId . Accessible . LabelWidget = packageIdLabel ;
283297 packageIdLink = new LinkLabel ( ) ;
284298 packageIdLink . Ellipsize = EllipsizeMode . End ;
285299 packageIdLink . TextAlignment = Alignment . End ;
286300 packageIdLink . Font = packageInfoSmallFont ;
301+ packageIdLink . Accessible . LabelWidget = packageIdLabel ;
287302 packageIdHBox . PackEnd ( packageIdLink , true ) ;
288303 packageIdHBox . PackEnd ( packageId , true ) ;
289304
@@ -300,6 +315,7 @@ void Build ()
300315 packageAuthor . TextAlignment = Alignment . End ;
301316 packageAuthor . Ellipsize = EllipsizeMode . End ;
302317 packageAuthor . Font = packageInfoSmallFont ;
318+ packageAuthor . Accessible . LabelWidget = packageAuthorLabel ;
303319 packageAuthorHBox . PackEnd ( packageAuthor , true ) ;
304320
305321 // Package published
@@ -313,6 +329,7 @@ void Build ()
313329
314330 packagePublishedDate = new Label ( ) ;
315331 packagePublishedDate . Font = packageInfoSmallFont ;
332+ packagePublishedDate . Accessible . LabelWidget = packagePublishedLabel ;
316333 packagePublishedHBox . PackEnd ( packagePublishedDate ) ;
317334
318335 // Package downloads
@@ -326,6 +343,7 @@ void Build ()
326343
327344 packageDownloads = new Label ( ) ;
328345 packageDownloads . Font = packageInfoSmallFont ;
346+ packageDownloads . Accessible . LabelWidget = packageDownloadsLabel ;
329347 packageDownloadsHBox . PackEnd ( packageDownloads ) ;
330348
331349 // Package license.
@@ -354,6 +372,7 @@ void Build ()
354372 packageProjectPageLink = new LinkLabel ( ) ;
355373 packageProjectPageLink . Text = GettextCatalog . GetString ( "Visit Page" ) ;
356374 packageProjectPageLink . Font = packageInfoSmallFont ;
375+ packageProjectPageLink . Accessible . Label = GettextCatalog . GetString ( "Visit Project Page" ) ;
357376 packageProjectPageHBox . PackEnd ( packageProjectPageLink ) ;
358377
359378 // Package dependencies
@@ -368,6 +387,7 @@ void Build ()
368387 packageDependenciesNoneLabel = new Label ( ) ;
369388 packageDependenciesNoneLabel . Text = GettextCatalog . GetString ( "None" ) ;
370389 packageDependenciesNoneLabel . Font = packageInfoSmallFont ;
390+ packageDependenciesNoneLabel . Accessible . LabelWidget = packageDependenciesLabel ;
371391 packageDependenciesHBox . PackEnd ( packageDependenciesNoneLabel ) ;
372392
373393 // Package dependencies list.
@@ -379,6 +399,7 @@ void Build ()
379399 packageDependenciesList . Wrap = WrapMode . WordAndCharacter ;
380400 packageDependenciesList . Margin = new WidgetSpacing ( 5 ) ;
381401 packageDependenciesList . Font = packageInfoSmallFont ;
402+ packageDependenciesList . Accessible . LabelWidget = packageDependenciesLabel ;
382403 packageDependenciesListHBox . PackStart ( packageDependenciesList , true ) ;
383404
384405 // Current package version.
@@ -400,11 +421,13 @@ void Build ()
400421
401422 currentPackageVersion = new Label ( ) ;
402423 currentPackageVersion . Font = packageInfoSmallFont ;
424+ currentPackageVersion . Accessible . LabelWidget = currentPackageVersionLabel ;
403425 currentPackageVersionWithInfoPopoverHBox . PackStart ( currentPackageVersion ) ;
404426
405427 currentPackageVersionInfoPopoverWidget = new InformationPopoverWidget ( ) ;
406428 currentPackageVersionInfoPopoverWidget . Severity = Ide . Tasks . TaskSeverity . Information ;
407429 currentPackageVersionInfoPopoverWidget . Margin = new WidgetSpacing ( 5 , 0 , 0 , 2 ) ;
430+ currentPackageVersionInfoPopoverWidget . Accessible . LabelWidget = currentPackageVersionLabel ;
408431 currentPackageVersionWithInfoPopoverHBox . PackStart ( currentPackageVersionInfoPopoverWidget ) ;
409432
410433 currentPackageVersionHBox . PackStart ( currentPackageVersionWithInfoPopoverHBox ) ;
@@ -422,6 +445,7 @@ void Build ()
422445
423446 packageVersionComboBox = new ComboBox ( ) ;
424447 packageVersionComboBox . Name = "packageVersionComboBox" ;
448+ packageVersionComboBox . Accessible . LabelWidget = packageVersionsLabel ;
425449 packageVersionsHBox . Spacing = 15 ;
426450 packageVersionsHBox . PackStart ( packageVersionComboBox , true , true ) ;
427451
0 commit comments