mirror of
https://github.com/onionshare/onionshare.git
synced 2024-12-29 01:06:16 -05:00
Make the quit warning work in receive mode, and use a different warning string
This commit is contained in:
parent
1a4aaa70fa
commit
2a7f6e0d5a
@ -461,11 +461,18 @@ class OnionShareGui(QtWidgets.QMainWindow):
|
||||
def closeEvent(self, e):
|
||||
self.common.log('OnionShareGui', 'closeEvent')
|
||||
try:
|
||||
if self.server_status.status != self.server_status.STATUS_STOPPED:
|
||||
if self.mode == OnionShareGui.MODE_SHARE:
|
||||
server_status = self.share_mode.server_status
|
||||
else:
|
||||
server_status = self.receive_mode.server_status
|
||||
if server_status.status != server_status.STATUS_STOPPED:
|
||||
self.common.log('OnionShareGui', 'closeEvent, opening warning dialog')
|
||||
dialog = QtWidgets.QMessageBox()
|
||||
dialog.setWindowTitle(strings._('gui_quit_title', True))
|
||||
dialog.setText(strings._('gui_quit_warning', True))
|
||||
if self.mode == OnionShareGui.MODE_SHARE:
|
||||
dialog.setText(strings._('gui_share_quit_warning', True))
|
||||
else:
|
||||
dialog.setText(strings._('gui_receive_quit_warning', True))
|
||||
dialog.setIcon(QtWidgets.QMessageBox.Critical)
|
||||
quit_button = dialog.addButton(strings._('gui_quit_warning_quit', True), QtWidgets.QMessageBox.YesRole)
|
||||
dont_quit_button = dialog.addButton(strings._('gui_quit_warning_dont_quit', True), QtWidgets.QMessageBox.NoRole)
|
||||
|
@ -43,7 +43,7 @@
|
||||
"gui_download_progress_starting": "{0:s}, %p% (Computing ETA)",
|
||||
"gui_download_progress_eta": "{0:s}, ETA: {1:s}, %p%",
|
||||
"version_string": "Onionshare {0:s} | https://onionshare.org/",
|
||||
"gui_quit_warning": "Jste si jistí, že chcete odejít?\nURL, kterou sdílíte poté nebude existovat.",
|
||||
"gui_share_quit_warning": "Jste si jistí, že chcete odejít?\nURL, kterou sdílíte poté nebude existovat.",
|
||||
"gui_quit_warning_quit": "Zavřít",
|
||||
"gui_quit_warning_dont_quit": "Zůstat",
|
||||
"error_rate_limit": "Útočník možná zkouší uhodnout vaši URL. Abychom tomu předešli, OnionShare automaticky zastavil server. Pro sdílení souborů ho musíte spustit znovu a sdílet novou URL.",
|
||||
|
@ -56,7 +56,7 @@
|
||||
"gui_download_progress_starting": "{0:s}, %p% (udregner anslået ankomsttid)",
|
||||
"gui_download_progress_eta": "{0:s}, anslået ankomsttid: {1:s}, %p%",
|
||||
"version_string": "Onionshare {0:s} | https://onionshare.org/",
|
||||
"gui_quit_warning": "Er du sikker på, at du vil afslutte?\nURL'en som du deler vil ikke eksistere længere.",
|
||||
"gui_share_quit_warning": "Er du sikker på, at du vil afslutte?\nURL'en som du deler vil ikke eksistere længere.",
|
||||
"gui_quit_warning_quit": "Afslut",
|
||||
"gui_quit_warning_dont_quit": "Afslut ikke",
|
||||
"error_rate_limit": "En angriber forsøger måske at gætte din URL. For at forhindre det, har OnionShare automatisk stoppet serveren. For at dele filerne skal du starte den igen og dele den nye URL.",
|
||||
|
@ -70,7 +70,8 @@
|
||||
"gui_download_progress_eta": "{0:s}, ETA: {1:s}, %p%",
|
||||
"version_string": "OnionShare {0:s} | https://onionshare.org/",
|
||||
"gui_quit_title": "Transfer in Progress",
|
||||
"gui_quit_warning": "You're in the process of sending files. Are you sure you want to quit OnionShare?",
|
||||
"gui_share_quit_warning": "You're in the process of sending files. Are you sure you want to quit OnionShare?",
|
||||
"gui_receive_quit_warning": "You're in the process of receiving files. Are you sure you want to quit OnionShare?",
|
||||
"gui_quit_warning_quit": "Quit",
|
||||
"gui_quit_warning_dont_quit": "Cancel",
|
||||
"error_rate_limit": "An attacker might be trying to guess your address. To prevent this, OnionShare has automatically stopped the server. To share the files you must start it again and share the new address.",
|
||||
|
@ -43,7 +43,7 @@
|
||||
"gui_download_progress_starting": "{0:s}, %p% (Computing ETA)",
|
||||
"gui_download_progress_eta": "{0:s}, ETA: {1:s}, %p%",
|
||||
"version_string": "Onionshare {0:s} | https://onionshare.org/",
|
||||
"gui_quit_warning": "Ĉu vi certas ke vi volas foriri?\nLa URL, kiun vi kundividas ne plu ekzistos.",
|
||||
"gui_share_quit_warning": "Ĉu vi certas ke vi volas foriri?\nLa URL, kiun vi kundividas ne plu ekzistos.",
|
||||
"gui_quit_warning_quit": "Foriri",
|
||||
"gui_quit_warning_dont_quit": "Ne foriri",
|
||||
"error_rate_limit": "Iu atankanto povas provi diveni vian URL. Por eviti tion, OnionShare aŭtomate haltis la servilon. Por kundividi la dosierojn vi devas starti ĝin denove kaj kundividi la novan URL.",
|
||||
|
@ -54,7 +54,7 @@
|
||||
"gui_download_progress_starting": "{0:s}, %p% (ETA berekenen)",
|
||||
"gui_download_progress_eta": "{0:s}, ETA: {1:s}, %p%",
|
||||
"version_string": "Onionshare {0:s} | https://onionshare.org/",
|
||||
"gui_quit_warning": "Weet je zeker dat je wilt afsluiten?\nDe URL die je aan het delen bent zal niet meer bestaan.",
|
||||
"gui_share_quit_warning": "Weet je zeker dat je wilt afsluiten?\nDe URL die je aan het delen bent zal niet meer bestaan.",
|
||||
"gui_quit_warning_quit": "Afsluiten",
|
||||
"gui_quit_warning_dont_quit": "Niet afsluiten",
|
||||
"error_rate_limit": "Een aanvaller probeert misschien je URL te gokken. Om dit te voorkomen heeft OnionShare de server automatisch gestopt. Om de bestanden te delen moet je de server opnieuw starten en de nieuwe URL delen.",
|
||||
|
Loading…
Reference in New Issue
Block a user