use GajimPluginConfig for file sharing plugin

This commit is contained in:
Yann Leboulanger
2012-10-28 19:47:32 +01:00
parent f9271e9809
commit 91b7beea71
3 changed files with 8 additions and 33 deletions

View File

@@ -27,6 +27,7 @@ class FileSharePlugin(GajimPlugin):
self.description = _('This plugin allows you to share folders'+
' with a peer using jingle file transfer.')
self.config_dialog = None
self.config_default_values = {'incoming_dir': ('/home/', '')}
# Create one protocol handler per account
accounts = gajim.contacts.get_accounts()
for account in gajim.contacts.get_accounts():
@@ -133,7 +134,7 @@ class FileSharePlugin(GajimPlugin):
def __get_fsw_instance(self, account):
# Makes sure we only have one instance of the window per account
if account not in FileSharePlugin.filesharewindow:
FileSharePlugin.filesharewindow[account] = fsw = FileShareWindow()
FileSharePlugin.filesharewindow[account] = fsw = FileShareWindow(self)
FileSharePlugin.prohandler[account].set_window(fsw)
return FileSharePlugin.filesharewindow[account]