mirror of
https://github.com/ankitects/anki.git
synced 2025-11-11 07:07:13 -05:00
stop audio in deck browser, card layout and overview
This commit is contained in:
parent
e9ea56f931
commit
fe8d28c3eb
3 changed files with 5 additions and 0 deletions
|
|
@ -282,6 +282,7 @@ Enter deck to place new %s cards in, or leave blank:""") %
|
|||
self.reject()
|
||||
|
||||
def reject(self):
|
||||
clearAudioQueue()
|
||||
if self.addMode:
|
||||
self.mw.col.db.execute("delete from notes where id = ?",
|
||||
self.note.id)
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ from anki.utils import isMac
|
|||
import anki.js
|
||||
from anki.errors import DeckRenameError
|
||||
import aqt
|
||||
from anki.sound import clearAudioQueue
|
||||
|
||||
class DeckBrowser(object):
|
||||
|
||||
|
|
@ -17,6 +18,7 @@ class DeckBrowser(object):
|
|||
self.bottom = aqt.toolbar.BottomBar(mw, mw.bottomWeb)
|
||||
|
||||
def show(self):
|
||||
clearAudioQueue()
|
||||
self.web.setLinkHandler(self._linkHandler)
|
||||
self.web.setKeyHandler(None)
|
||||
self.mw.keyHandler = None
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@ from anki.hooks import addHook
|
|||
from aqt.utils import showInfo, openLink
|
||||
from anki.utils import isMac
|
||||
import aqt
|
||||
from anki.sound import clearAudioQueue
|
||||
|
||||
class Overview(object):
|
||||
"Deck overview."
|
||||
|
|
@ -19,6 +20,7 @@ class Overview(object):
|
|||
self.bottom = aqt.toolbar.BottomBar(mw, mw.bottomWeb)
|
||||
|
||||
def show(self):
|
||||
clearAudioQueue()
|
||||
self.web.setLinkHandler(self._linkHandler)
|
||||
self.web.setKeyHandler(None)
|
||||
self.mw.keyHandler = None
|
||||
|
|
|
|||
Loading…
Reference in a new issue