Presentation plugin again

This commit is contained in:
Tim Bentley 2009-08-15 20:10:59 +01:00
parent 48bca4155d
commit 297c4ab4c3
3 changed files with 12 additions and 4 deletions

View File

@ -58,6 +58,8 @@ class PluginForm(QtGui.QDialog):
""" """
Load the plugin details into the screen Load the plugin details into the screen
""" """
#self.PluginViewList.clear()
self.PluginViewList.setRowCount(0)
for plugin in self.parent.plugin_manager.plugins: for plugin in self.parent.plugin_manager.plugins:
row = self.PluginViewList.rowCount() row = self.PluginViewList.rowCount()
self.PluginViewList.setRowCount(row + 1) self.PluginViewList.setRowCount(row + 1)

View File

@ -93,4 +93,3 @@ class PresentationTab(SettingsTab):
def save(self): def save(self):
self.config.set_config(u'Powerpoint', unicode(self.PowerpointCheckBox.checkState())) self.config.set_config(u'Powerpoint', unicode(self.PowerpointCheckBox.checkState()))
self.config.set_config(u'Impress', unicode(self.ImpressCheckBox.checkState())) self.config.set_config(u'Impress', unicode(self.ImpressCheckBox.checkState()))
print self.PowerpointCheckBox.checkState(), unicode(self.PowerpointCheckBox.checkState())

View File

@ -67,12 +67,12 @@ class PresentationPlugin(Plugin):
""" """
log.debug('check_pre_conditions') log.debug('check_pre_conditions')
if int(self.config.get_config(u'Powerpoint', 0)) == 2: if int(self.config.get_config(u'Impress', 0)) == 2:
try: try:
#Check to see if we have uno installed #Check to see if we have uno installed
import uno import uno
#openoffice = impressController() openoffice = impressController()
self.registerControllers(u'Impress', None) self.registerControllers(u'Impress', openoffice)
except: except:
pass pass
#If we have no controllers disable plugin #If we have no controllers disable plugin
@ -80,3 +80,10 @@ class PresentationPlugin(Plugin):
return True return True
else: else:
return False return False
def finalise(self):
log.debug(u'Finalise')
print self.controllers
for controller in self.controllers:
print controller
self.controllers[controller].kill()