mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Allow right clicking on Virtual Library tabs to edit/delete the virtual library. Fixes #1568306 [[Enhancement] Edit a Virtual Library from individual tab](https://bugs.launchpad.net/calibre/+bug/1568306)
This commit is contained in:
parent
52a24def08
commit
023717c2cd
@ -433,6 +433,13 @@ class VLTabs(QTabBar): # {{{
|
||||
for x in hidden:
|
||||
s.addAction(x, partial(self.restore, x))
|
||||
m.addAction(_('Hide virtual library tabs'), self.disable_bar)
|
||||
i = self.tabAt(ev.pos())
|
||||
if i > -1:
|
||||
vl = unicode(self.tabData(i) or '')
|
||||
if vl:
|
||||
m.addSeparator()
|
||||
m.addAction(_('Edit "%s"') % vl, partial(self.gui.do_create_edit, name=vl))
|
||||
m.addAction(_('Delete "%s"') % vl, partial(self.gui.remove_vl_triggered, name=vl))
|
||||
m.exec_(ev.globalPos())
|
||||
|
||||
def sort_alphabetically(self):
|
||||
|
Loading…
x
Reference in New Issue
Block a user