mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Spell check: Fix replacing a word and then replacing the new word again not working without doing a refresh in between
This commit is contained in:
parent
1d4a0cd24b
commit
7af2683b7d
@ -701,6 +701,8 @@ class WordsModel(QAbstractTableModel):
|
|||||||
self.update_word(w)
|
self.update_word(w)
|
||||||
|
|
||||||
def replace_word(self, w, new_word):
|
def replace_word(self, w, new_word):
|
||||||
|
for location in self.words[w]:
|
||||||
|
location.original_word = new_word
|
||||||
if w[0] == new_word:
|
if w[0] == new_word:
|
||||||
return w
|
return w
|
||||||
new_key = (new_word, w[1])
|
new_key = (new_word, w[1])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user