File tree Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -577,8 +577,12 @@ const MenuItemFactory = {
577577 } ,
578578
579579 _onActivate ( _item , event ) {
580+ const timestamp = event . get_time ( ) ;
581+ if ( timestamp && this . _dbusClient . indicator )
582+ this . _dbusClient . indicator . provideActivationToken ( timestamp ) ;
583+
580584 this . _dbusItem . handleEvent ( 'clicked' , GLib . Variant . new ( 'i' , 0 ) ,
581- event . get_time ( ) ) ;
585+ timestamp ) ;
582586 } ,
583587
584588 _onPropertyChanged ( dbusItem , prop , _value ) {
@@ -728,12 +732,13 @@ const MenuUtils = {
728732 */
729733var Client = class AppIndicatorsClient {
730734
731- constructor ( busName , path ) {
735+ constructor ( busName , path , indicator ) {
732736 this . _busName = busName ;
733737 this . _busPath = path ;
734738 this . _client = new DBusClient ( busName , path ) ;
735739 this . _rootMenu = null ; // the shell menu
736740 this . _rootItem = null ; // the DbusMenuItem for the root
741+ this . indicator = indicator ;
737742 }
738743
739744 get isReady ( ) {
@@ -825,6 +830,7 @@ var Client = class AppIndicatorsClient {
825830 this . _client = null ;
826831 this . _rootItem = null ;
827832 this . _rootMenu = null ;
833+ this . indicator = null ;
828834 }
829835} ;
830836Signals . addSignalMethods ( Client . prototype ) ;
Original file line number Diff line number Diff line change @@ -265,7 +265,7 @@ class AppIndicatorsIndicatorStatusIcon extends BaseStatusIcon {
265265
266266 if ( this . _indicator . menuPath ) {
267267 this . _menuClient = new DBusMenu . Client ( this . _indicator . busName ,
268- this . _indicator . menuPath ) ;
268+ this . _indicator . menuPath , this . _indicator ) ;
269269 this . _menuClient . attachToMenu ( this . menu ) ;
270270 }
271271 }
You can’t perform that action at this time.
0 commit comments