@@ -25,7 +25,7 @@ import { ConfigurationTarget } from 'vs/platform/configuration/common/configurat
2525import { IContextKey } from 'vs/platform/contextkey/common/contextkey' ;
2626import { IContextMenuService , IContextViewService } from 'vs/platform/contextview/browser/contextView' ;
2727import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation' ;
28- import { activeContrastBorder , badgeBackground , badgeForeground , contrastBorder , errorForeground , focusBorder } from 'vs/platform/theme/common/colorRegistry' ;
28+ import { activeContrastBorder , badgeBackground , badgeForeground , contrastBorder , focusBorder } from 'vs/platform/theme/common/colorRegistry' ;
2929import { attachInputBoxStyler , attachStylerCallback } from 'vs/platform/theme/common/styler' ;
3030import { ICssStyleCollector , ITheme , IThemeService , registerThemingParticipant } from 'vs/platform/theme/common/themeService' ;
3131import { IWorkspaceContextService , IWorkspaceFolder , WorkbenchState } from 'vs/platform/workspace/common/workspace' ;
@@ -614,7 +614,8 @@ export class SearchWidget extends Widget {
614614 this . countElement . style . borderStyle = border ? 'solid' : null ;
615615 this . countElement . style . borderColor = border ;
616616
617- this . styleCountElementForeground ( ) ;
617+ const color = this . themeService . getTheme ( ) . getColor ( badgeForeground ) ;
618+ this . countElement . style . color = color ? color . toString ( ) : null ;
618619 } ) ) ;
619620 }
620621
@@ -650,18 +651,10 @@ export class SearchWidget extends Widget {
650651 if ( this . countElement && message !== this . countElement . textContent ) {
651652 this . countElement . textContent = message ;
652653 this . inputBox . inputElement . setAttribute ( 'aria-label' , message ) ;
653- DOM . toggleClass ( this . countElement , 'no-results' , count === 0 ) ;
654654 this . inputBox . inputElement . style . paddingRight = this . getControlsWidth ( ) + 'px' ;
655- this . styleCountElementForeground ( ) ;
656655 }
657656 }
658657
659- private styleCountElementForeground ( ) {
660- const colorId = DOM . hasClass ( this . countElement , 'no-results' ) ? errorForeground : badgeForeground ;
661- const color = this . themeService . getTheme ( ) . getColor ( colorId ) ;
662- this . countElement . style . color = color ? color . toString ( ) : null ;
663- }
664-
665658 public layout ( dimension : DOM . Dimension ) {
666659 if ( dimension . width < 400 ) {
667660 if ( this . countElement ) {
0 commit comments