@@ -490,26 +490,22 @@ const WorkspaceSettingsWidget = new GObject.Class({
490490
491491 /* INSENSITIVE MESSAGE TRAY */
492492
493- let insensitiveMessageTray = new Gtk . Box ( { orientation :Gtk . Orientation . VERTICAL , homogeneous :false ,
494- margin_top :10 , margin_right :10 , margin_bottom :0 , margin_left :10 } ) ;
495-
496- let insensitiveMessageTrayLabel = new Gtk . Label ( { label : _ ( "Make message tray not be shown on mouse-over. Used in bottom dock placement." ) ,
497- hexpand : true , halign : Gtk . Align . START } ) ;
498-
499- insensitiveMessageTray . add ( insensitiveMessageTrayLabel ) ;
500-
501- let insensitiveTick = new Gtk . CheckButton ( { label : _ ( "Insensitive On" ) , hexpand :true } ) ;
502- insensitiveTick . set_active ( this . settings . get_boolean ( 'insensitive-message-tray' ) ) ;
503- insensitiveTick . connect ( 'toggled' , Lang . bind ( this , function ( check ) {
504- this . settings . set_boolean ( 'insensitive-message-tray' , check . get_active ( ) ) ;
505- } ) ) ;
506- indentWidget ( insensitiveTick ) ;
507-
508- insensitiveMessageTray . add ( insensitiveTick ) ;
493+ let insensitiveMessageTrayControl = new Gtk . Box ( { margin_left :10 , margin_top :10 , margin_bottom :5 , margin_right :10 } ) ;
509494
510- this . settings . bind ( 'customize-click' , clickMain , 'sensitive' , Gio . SettingsBindFlags . DEFAULT ) ;
495+ let insensitiveMessageTrayLabel = new Gtk . Label ( { label : _ ( "Make message tray insensitive to mouse events" ) ,
496+ xalign : 0 , hexpand :true } ) ;
497+ let insensitiveMessageTray = new Gtk . Switch ( { halign :Gtk . Align . END } ) ;
498+ insensitiveMessageTray . set_active ( this . settings . get_boolean ( 'insensitive-message-tray' ) ) ;
499+ insensitiveMessageTray . connect ( 'notify::active' , Lang . bind ( this , function ( check ) {
500+ this . settings . set_boolean ( 'insensitive-message-tray' , check . get_active ( ) ) ;
501+ } ) ) ;
502+
503+ indentWidget ( insensitiveMessageTray ) ;
504+
505+ insensitiveMessageTrayControl . add ( insensitiveMessageTrayLabel ) ;
506+ insensitiveMessageTrayControl . add ( insensitiveMessageTray ) ;
511507
512- customization . add ( insensitiveMessageTray ) ;
508+ customization . add ( insensitiveMessageTrayControl ) ;
513509
514510 notebook . append_page ( customization , customizationTitle ) ;
515511
0 commit comments