1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-26 09:28:13 +00:00

core: show total number of words during device recovery

This commit is contained in:
ciny 2019-07-09 14:05:51 +02:00
parent d53d6f82cb
commit 11b9f1c4e8

View File

@ -10,7 +10,6 @@ from trezor.ui.mnemonic_bip39 import Bip39Keyboard
from trezor.ui.mnemonic_slip39 import Slip39Keyboard from trezor.ui.mnemonic_slip39 import Slip39Keyboard
from trezor.ui.text import Text from trezor.ui.text import Text
from trezor.ui.word_select import WordSelector from trezor.ui.word_select import WordSelector
from trezor.utils import format_ordinal
from apps.common import mnemonic, storage from apps.common import mnemonic, storage
from apps.common.confirm import require_confirm from apps.common.confirm import require_confirm
@ -140,9 +139,9 @@ async def request_mnemonic(ctx: wire.Context, count: int, slip39: bool) -> str:
words = [] words = []
for i in range(count): for i in range(count):
if slip39: if slip39:
keyboard = Slip39Keyboard("Type the %s word:" % format_ordinal(i + 1)) keyboard = Slip39Keyboard("Type word %s of %s:" % (i + 1, count))
else: else:
keyboard = Bip39Keyboard("Type the %s word:" % format_ordinal(i + 1)) keyboard = Bip39Keyboard("Type word %s of %s:" % (i + 1, count))
if __debug__: if __debug__:
word = await ctx.wait(keyboard, input_signal) word = await ctx.wait(keyboard, input_signal)
else: else: