@@ -541,12 +541,7 @@ const RuleRow = GObject.registerClass({
541541
542542 const frame = new Gtk . Frame ( ) ;
543543 frame . set_child ( box ) ;
544- const cssProvider = new Gtk . CssProvider ( ) ;
545- cssProvider . load_from_data (
546- "frame { border-style: dashed; }" ) ;
547- frame . get_style_context ( ) . add_provider ( cssProvider ,
548- Gtk . STYLE_PROVIDER_PRIORITY_APPLICATION ) ;
549-
544+ PrefsWidgets . updateStyle ( frame , 'frame { border-style: dashed; }' ) ;
550545 parentWidget . append ( frame ) ;
551546 }
552547
@@ -788,11 +783,7 @@ const RuleRowByApp = GObject.registerClass({
788783 } ) ;
789784 label . set_tooltip_text ( displayName ) ;
790785 if ( ! appInfo ) {
791- const cssProvider = new Gtk . CssProvider ( ) ;
792- cssProvider . load_from_data (
793- "label { color: red; }" ) ;
794- label . get_style_context ( ) . add_provider ( cssProvider ,
795- Gtk . STYLE_PROVIDER_PRIORITY_APPLICATION ) ;
786+ PrefsWidgets . updateStyle ( label , 'label { color: red; }' ) ;
796787 }
797788 this . boxLeft . insert_child_after ( label , icon ) ;
798789
@@ -880,10 +871,6 @@ const RuleRowByKeyword = GObject.registerClass({
880871 _init ( ruleDetail ) {
881872 super . _init ( ruleDetail ) ;
882873
883- const icon = new Gtk . Image ( {
884- gicon : IconFinder . find ( 'empty-symbolic.svg' ) ,
885- pixel_size : 32 ,
886- } ) ;
887874 const compareWithDropDown = this . _newCompareWithDropDown ( ) ;
888875 const methodDropDown = this . _newMethodDropDown ( ) ;
889876 const pickableEntry = new PrefsWindowPickableEntry . WindowPickableEntry ( {
@@ -898,8 +885,7 @@ const RuleRowByKeyword = GObject.registerClass({
898885 this . _compareWithDropDown = compareWithDropDown ;
899886 this . _methodDropDown = methodDropDown ;
900887
901- this . boxLeft . insert_child_after ( icon , this . _enabledCheckButton ) ;
902- this . boxLeft . insert_child_after ( compareWithDropDown , icon ) ;
888+ this . boxLeft . insert_child_after ( compareWithDropDown , this . _enabledCheckButton ) ;
903889 this . boxLeft . insert_child_after ( methodDropDown , compareWithDropDown ) ;
904890 this . boxLeft . insert_child_after ( pickableEntry , methodDropDown ) ;
905891
0 commit comments