mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Fix #2186 (Remove eMail button does not work)
This commit is contained in:
parent
0fbd15a76d
commit
51fa4e639e
@ -263,7 +263,7 @@ class EmailAccounts(QAbstractTableModel):
|
||||
|
||||
def remove(self, index):
|
||||
if index.isValid():
|
||||
row = self.index.row()
|
||||
row = index.row()
|
||||
account = self.account_order[row]
|
||||
self.accounts.pop(account)
|
||||
self.account_order = sorted(self.accounts.keys())
|
||||
@ -425,6 +425,8 @@ class ConfigDialog(QDialog, Ui_Dialog):
|
||||
self.email_view.resizeColumnsToContents()
|
||||
self.connect(self.test_email_button, SIGNAL('clicked(bool)'),
|
||||
self.test_email)
|
||||
self.connect(self.email_remove, SIGNAL('clicked()'),
|
||||
self.remove_email_account)
|
||||
|
||||
def add_email_account(self, checked):
|
||||
index = self._email_accounts.add()
|
||||
@ -432,6 +434,10 @@ class ConfigDialog(QDialog, Ui_Dialog):
|
||||
self.email_view.resizeColumnsToContents()
|
||||
self.email_view.edit(index)
|
||||
|
||||
def remove_email_account(self, *args):
|
||||
idx = self.email_view.currentIndex()
|
||||
self._email_accounts.remove(idx)
|
||||
|
||||
def create_gmail_relay(self, *args):
|
||||
self.relay_username.setText('@gmail.com')
|
||||
self.relay_password.setText('')
|
||||
|
@ -26,7 +26,8 @@ def initview(request):
|
||||
5. The feeds for the site (ids)
|
||||
"""
|
||||
|
||||
site_id, cachekey = fjlib.getcurrentsite(request.META['HTTP_HOST'], \
|
||||
site_id, cachekey = fjlib.getcurrentsite(request.META.get('HTTP_HOST',
|
||||
'planet.calibre-ebook.com'), \
|
||||
request.META.get('REQUEST_URI', request.META.get('PATH_INFO', '/')), \
|
||||
request.META['QUERY_STRING'])
|
||||
response = fjcache.cache_get(site_id, cachekey)
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/bin/sh
|
||||
|
||||
ssh divok "cd /usr/local/calibre && bzr pull"
|
||||
ssh divok "cd /usr/local/calibre && bzr up"
|
||||
ssh divok /etc/init.d/apache2 graceful
|
||||
|
@ -667,9 +667,16 @@ class stage3(OptionlessCommand):
|
||||
def misc(cls):
|
||||
check_call('ssh divok rm -f %s/calibre-\*.tar.gz'%DOWNLOADS, shell=True)
|
||||
check_call('scp dist/calibre-*.tar.gz divok:%s/'%DOWNLOADS, shell=True)
|
||||
check_call('gpg --armor --detach-sign dist/calibre-*.tar.gz',
|
||||
shell=True)
|
||||
check_call('scp dist/calibre-*.tar.gz.asc divok:%s/signatures/'%DOWNLOADS,
|
||||
shell=True)
|
||||
check_call('''rm -rf dist/* build/*''', shell=True)
|
||||
check_call('ssh divok bzr update /var/www/calibre.kovidgoyal.net/calibre/',
|
||||
shell=True)
|
||||
check_call('ssh divok bzr update /usr/local/calibre',
|
||||
shell=True)
|
||||
|
||||
|
||||
def run(self):
|
||||
OptionlessCommand.run(self)
|
||||
|
Loading…
x
Reference in New Issue
Block a user