home *** CD-ROM | disk | FTP | other *** search
/ Maximum CD 2011 January / maximum-cd-2011-01.iso / DiscContents / calibre-0.7.26.msi / file_1168 (.txt) < prev    next >
Encoding:
Python Compiled Bytecode  |  2010-10-31  |  1.3 KB  |  26 lines

  1. # Source Generated with Decompyle++
  2. # File: in.pyc (Python 2.6)
  3.  
  4. __license__ = 'GPL v3'
  5. __copyright__ = '2010, Kovid Goyal <kovid@kovidgoyal.net>'
  6. __docformat__ = 'restructuredtext en'
  7. from calibre.gui2.actions import InterfaceAction
  8.  
  9. class OpenFolderAction(InterfaceAction):
  10.     name = 'Open Folder'
  11.     action_spec = (_('Open containing folder'), 'document_open.png', None, _('O'))
  12.     dont_add_to = frozenset([
  13.         'toolbar-device',
  14.         'context-menu-device'])
  15.     action_type = 'current'
  16.     
  17.     def genesis(self):
  18.         self.qaction.triggered.connect(self.gui.iactions['View'].view_folder)
  19.  
  20.     
  21.     def location_selected(self, loc):
  22.         enabled = loc == 'library'
  23.         self.qaction.setEnabled(enabled)
  24.  
  25.  
  26.