Update of /cvsroot/freevo/freevo/src/plugins
In directory sc8-pr-cvs1:/tmp/cvs-serv23693/src/plugins

Modified Files:
        base.py 
Log Message:
make it possible to bypass confirmation of shutdown

Index: base.py
===================================================================
RCS file: /cvsroot/freevo/freevo/src/plugins/base.py,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** base.py     29 Oct 2003 03:37:46 -0000      1.8
--- base.py     29 Oct 2003 20:47:44 -0000      1.9
***************
*** 10,13 ****
--- 10,16 ----
  # -----------------------------------------------------------------------
  # $Log$
+ # Revision 1.9  2003/10/29 20:47:44  dischi
+ # make it possible to bypass confirmation of shutdown
+ #
  # Revision 1.8  2003/10/29 03:37:46  krister
  # Added confirmation of shutdown. Do we need an option to disable this?
***************
*** 69,78 ****
      Item for shutdown
      """
      def actions(self):
          """
          return a list of actions for this item
          """
!         items = [ (self.confirm_freevo, _('Shutdown Freevo') ),
!                   (self.confirm_system, _('Shutdown system') ) ]
          if config.ENABLE_SHUTDOWN_SYS:
              items.reverse()
--- 72,87 ----
      Item for shutdown
      """
+     menuw = None
+ 
      def actions(self):
          """
          return a list of actions for this item
          """
!         if config.CONFIRM_SHUTDOWN:
!             items = [ (self.confirm_freevo, _('Shutdown Freevo') ),
!                       (self.confirm_system, _('Shutdown system') ) ]
!         else:
!             items = [ (self.shutdown_freevo, _('Shutdown Freevo') ),
!                       (self.shutdown_system, _('Shutdown system') ) ]
          if config.ENABLE_SHUTDOWN_SYS:
              items.reverse()
***************
*** 98,114 ****
          
  
!     def shutdown_freevo(self):
          """
          shutdown freevo, don't shutdown the system
          """
          import main
          main.shutdown(menuw=self.menuw, arg=False)
  
          
!     def shutdown_system(self):
          """
          shutdown the complete system
          """
          import main
          main.shutdown(menuw=self.menuw, arg=True)
          
--- 107,127 ----
          
  
!     def shutdown_freevo(self, arg=None, menuw=None):
          """
          shutdown freevo, don't shutdown the system
          """
          import main
+         if not self.menuw:
+             self.menuw = menuw
          main.shutdown(menuw=self.menuw, arg=False)
  
          
!     def shutdown_system(self, arg=None, menuw=None):
          """
          shutdown the complete system
          """
          import main
+         if not self.menuw:
+             self.menuw = menuw
          main.shutdown(menuw=self.menuw, arg=True)
          




-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?   SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
_______________________________________________
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog

Reply via email to