mirror of
https://github.com/onionshare/onionshare.git
synced 2025-08-11 07:40:26 -04:00
merge from develop and fix conflicts, update poetry
This commit is contained in:
commit
80cc1f43e8
96 changed files with 3838 additions and 2291 deletions
|
@ -21,7 +21,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
from __future__ import division
|
||||
import os
|
||||
import sys
|
||||
import platform
|
||||
import argparse
|
||||
import signal
|
||||
import json
|
||||
|
|
|
@ -353,6 +353,10 @@ class GuiCommon:
|
|||
color: #666666;
|
||||
font-size: 11px;
|
||||
}""",
|
||||
"receive_message_button": """
|
||||
QPushButton {
|
||||
padding: 5px 10px;
|
||||
}""",
|
||||
# Settings dialog
|
||||
"settings_version": """
|
||||
QLabel {
|
||||
|
|
BIN
desktop/src/onionshare/resources/images/open_message.png
Normal file
BIN
desktop/src/onionshare/resources/images/open_message.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 5.3 KiB |
|
@ -276,7 +276,7 @@
|
|||
"gui_receive_flatpak_data_dir": "যেহেতু অনিওনশেয়ার ফ্ল্যাটপ্যাক দিয়ে ইন্সটল করেছো, তাই তোমাকে ~/OnionShare এ ফাইল সংরক্ষণ করতে হবে।",
|
||||
"gui_rendezvous_cleanup": "তোমার ফাইলগুলি সফলভাবে স্থানান্তরিত হয়েছে তা নিশ্চিত হয়ে টর সার্কিট বন্ধের অপেক্ষা করা হচ্ছে।\n\nএটি কয়েক মিনিট সময় নিতে পারে।",
|
||||
"gui_open_folder_error": "xdg-open দিয়ে ফোল্ডার খুলতে ব্যর্থ হয়েছে। ফাইলটি এখানে: {}",
|
||||
"gui_chat_url_description": "এই পেঁয়াজশেয়ার ঠিকানা দিয়ে <b>যে কেউ</b> <b>টর ব্রাউজার</b>: <img src='{}' /> ব্যবহার করে এই <b>চ্যাট রুমটিতে যোগ দিতে পারে</b>",
|
||||
"gui_chat_url_description": "এই অনিওনশেয়ার ঠিকানা দিয়ে <b>যে কেউ</b> <b>টর ব্রাউজার</b>: <img src='{}' /> ব্যবহার করে এই <b>চ্যাট রুমটিতে যোগ দিতে পারে</b>",
|
||||
"error_port_not_available": "অনিয়নশায়ার পোর্ট নেই",
|
||||
"gui_rendezvous_cleanup_quit_early": "তাড়াতাড়ি বন্ধ করো",
|
||||
"gui_main_page_chat_button": "চ্যাটিং শুরু করো",
|
||||
|
|
|
@ -175,6 +175,8 @@
|
|||
"mode_settings_share_autostop_sharing_checkbox": "Stop sharing after files have been sent (uncheck to allow downloading individual files)",
|
||||
"mode_settings_receive_data_dir_label": "Save files to",
|
||||
"mode_settings_receive_data_dir_browse_button": "Browse",
|
||||
"mode_settings_receive_disable_text_checkbox": "Disable submitting text",
|
||||
"mode_settings_receive_disable_files_checkbox": "Disable uploading files",
|
||||
"mode_settings_receive_webhook_url_checkbox": "Use notification webhook",
|
||||
"mode_settings_website_disable_csp_checkbox": "Don't send Content Security Policy header (allows your website to use third-party resources)",
|
||||
"gui_all_modes_transfer_finished_range": "Transferred {} - {}",
|
||||
|
@ -193,5 +195,7 @@
|
|||
"settings_error_bundled_tor_broken": "OnionShare could not connect to Tor:\n{}",
|
||||
"gui_rendezvous_cleanup": "Waiting for Tor circuits to close to be sure your files have successfully transferred.\n\nThis might take a few minutes.",
|
||||
"gui_rendezvous_cleanup_quit_early": "Quit Early",
|
||||
"error_port_not_available": "OnionShare port not available"
|
||||
"error_port_not_available": "OnionShare port not available",
|
||||
"history_receive_read_message_button": "Read Message",
|
||||
"error_tor_protocol_error": "There was an error with Tor: {}"
|
||||
}
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
"not_a_readable_file": "{0:s} bukan berkas yang bisa dibaca.",
|
||||
"no_available_port": "Tidak dapat menemukan porta yang tersedia untuk memulai layanan onion",
|
||||
"other_page_loaded": "Alamat dimuat",
|
||||
"close_on_autostop_timer": "",
|
||||
"close_on_autostop_timer": "Berhenti karena timer berhenti otomatis habis",
|
||||
"closing_automatically": "Terhenti karena transfer telah tuntas",
|
||||
"timeout_download_still_running": "",
|
||||
"large_filesize": "Peringatan: Mengirim dalam jumlah besar dapat memakan waktu berjam-jam",
|
||||
|
@ -31,7 +31,7 @@
|
|||
"help_verbose": "Catat kesalahan OnionShare ke stdout, dan kesalahan web ke disk",
|
||||
"help_filename": "Daftar berkas atau folder untuk dibagikan",
|
||||
"help_config": "",
|
||||
"gui_drag_and_drop": "Seret dan lepas berkas dan folder\nuntuk mulai berbagi",
|
||||
"gui_drag_and_drop": "Seret dan lepas berkas dan folder untuk mulai berbagi",
|
||||
"gui_add": "Tambahkan",
|
||||
"gui_delete": "Hapus",
|
||||
"gui_choose_items": "Pilih",
|
||||
|
@ -59,7 +59,7 @@
|
|||
"gui_receive_quit_warning": "Anda sedang dalam proses menerima berkas. Apakah Anda yakin ingin menghentikan OnionShare?",
|
||||
"gui_quit_warning_quit": "Keluar",
|
||||
"gui_quit_warning_dont_quit": "Batal",
|
||||
"error_rate_limit": "",
|
||||
"error_rate_limit": "Seseorang berusaha berulang kali untuk menebak kata sandi Anda, jadi OnionShare telah menghentikan server. Mulailah berbagi lagi dan kirim penerima alamat baru untuk dibagikan.",
|
||||
"zip_progress_bar_format": "Mengompresi: %p%",
|
||||
"error_stealth_not_supported": "Untuk menggunakan otorisasi klien, Anda perlu setidaknya Tor 0.2.9.1-alpha (atau Tor Browser 6.5) dan python3-stem 1.5.0.",
|
||||
"error_ephemeral_not_supported": "OnionShare memerlukan setidaknya Tor 0.2.7.1 dan python3-stem 1.4.0.",
|
||||
|
@ -75,10 +75,10 @@
|
|||
"gui_settings_sharing_label": "Pengaturan berbagi",
|
||||
"gui_settings_close_after_first_download_option": "Berhenti berbagi setelah berkas telah terkirim",
|
||||
"gui_settings_connection_type_label": "Bagaimana seharusnya OnionShare terhubung ke Tor?",
|
||||
"gui_settings_connection_type_bundled_option": "",
|
||||
"gui_settings_connection_type_bundled_option": "Gunakan versi Tor yang terintegrasi dengan OnionShare",
|
||||
"gui_settings_connection_type_automatic_option": "Mencoba konfigurasi otomatis dengan Tor Browser",
|
||||
"gui_settings_connection_type_control_port_option": "Menghubungkan menggunakan porta kontrol",
|
||||
"gui_settings_connection_type_socket_file_option": "",
|
||||
"gui_settings_connection_type_socket_file_option": "Hubungkan menggunakan file socket",
|
||||
"gui_settings_connection_type_test_button": "Menguji sambungan ke Tor",
|
||||
"gui_settings_control_port_label": "Port kontrol",
|
||||
"gui_settings_socket_file_label": "Berkas soket",
|
||||
|
@ -87,49 +87,49 @@
|
|||
"gui_settings_authenticate_no_auth_option": "Tidak ada otentikasi, atau otentikasi kuki",
|
||||
"gui_settings_authenticate_password_option": "Sandi",
|
||||
"gui_settings_password_label": "Sandi",
|
||||
"gui_settings_tor_bridges": "",
|
||||
"gui_settings_tor_bridges_no_bridges_radio_option": "",
|
||||
"gui_settings_tor_bridges_obfs4_radio_option": "",
|
||||
"gui_settings_tor_bridges_obfs4_radio_option_no_obfs4proxy": "",
|
||||
"gui_settings_tor_bridges_meek_lite_azure_radio_option": "",
|
||||
"gui_settings_tor_bridges_meek_lite_azure_radio_option_no_obfs4proxy": "",
|
||||
"gui_settings_meek_lite_expensive_warning": "",
|
||||
"gui_settings_tor_bridges_custom_radio_option": "",
|
||||
"gui_settings_tor_bridges_custom_label": "",
|
||||
"gui_settings_tor_bridges_invalid": "",
|
||||
"gui_settings_tor_bridges": "Dukungan Tor bridge",
|
||||
"gui_settings_tor_bridges_no_bridges_radio_option": "Jangan gunakan bridges",
|
||||
"gui_settings_tor_bridges_obfs4_radio_option": "Gunakan obfs4 pluggable transports bawaan",
|
||||
"gui_settings_tor_bridges_obfs4_radio_option_no_obfs4proxy": "Gunakan obfs4 pluggable transports bawaan (memerlukan obfs4proxy)",
|
||||
"gui_settings_tor_bridges_meek_lite_azure_radio_option": "Gunakan meek_lite (Azure) pluggable transports bawaan",
|
||||
"gui_settings_tor_bridges_meek_lite_azure_radio_option_no_obfs4proxy": "Gunakan meek_lite (Azure) pluggable transports bawaan (memerlukan obfs4proxy)",
|
||||
"gui_settings_meek_lite_expensive_warning": "Peringatan: meek_lite sangat mahal untuk dijalankan oleh Tor Project. <br><br>Gunakan hanya jika tidak dapat terhubung ke Tor secara langsung, melalui obfs4 transports,, atau bridge normal lainnya.",
|
||||
"gui_settings_tor_bridges_custom_radio_option": "Gunakan bridge kustom",
|
||||
"gui_settings_tor_bridges_custom_label": "Anda bisa mendapatkan bridge dari <a href=\"https://bridges.torproject.org/options\"> https://bridges.torproject.org </a>",
|
||||
"gui_settings_tor_bridges_invalid": "Tak satu pun dari bridge yang Anda tambahkan bekerja.\nPeriksa kembali atau tambahkan yang lain.",
|
||||
"gui_settings_button_save": "Simpan",
|
||||
"gui_settings_button_cancel": "Batal",
|
||||
"gui_settings_button_help": "",
|
||||
"gui_settings_button_help": "Bantuan",
|
||||
"gui_settings_autostop_timer_checkbox": "",
|
||||
"gui_settings_autostop_timer": "",
|
||||
"settings_error_unknown": "",
|
||||
"settings_error_automatic": "",
|
||||
"settings_error_socket_port": "",
|
||||
"settings_error_socket_file": "",
|
||||
"settings_error_auth": "",
|
||||
"settings_error_missing_password": "",
|
||||
"settings_error_unreadable_cookie_file": "",
|
||||
"settings_error_unknown": "Tidak dapat tersambung ke pengontrol Tor karena pengaturan Anda tidak masuk akal.",
|
||||
"settings_error_automatic": "Tidak dapat terhubung ke pengontrol Tor. Apakah Tor Browser (unduh di torproject.org) berjalan di latar belakang?",
|
||||
"settings_error_socket_port": "Tidak dapat tersambung ke pengontrol Tor di {}:{}.",
|
||||
"settings_error_socket_file": "Tidak dapat tersambung ke pengontrol Tor menggunakan file soket {}.",
|
||||
"settings_error_auth": "Tersambung ke {}:{}, tetapi tidak bisa mengautentikasi. Mungkin ini bukan pengontrol Tor?",
|
||||
"settings_error_missing_password": "Terhubung ke pengontrol Tor, tetapi memerlukan kata sandi untuk mengotentikasi.",
|
||||
"settings_error_unreadable_cookie_file": "Terhubung ke pengontrol Tor, tetapi kata sandi mungkin salah, atau pengguna Anda tidak diizinkan untuk membaca file kuki.",
|
||||
"settings_error_bundled_tor_not_supported": "",
|
||||
"settings_error_bundled_tor_timeout": "",
|
||||
"settings_error_bundled_tor_broken": "",
|
||||
"settings_test_success": "",
|
||||
"settings_test_success": "Terhubung ke pengontrol Tor.\n\nVersi tor: {}\nMendukung layanan ephemeral onion: {}.\nMendukung otentikasi klien: {}.\nMendukung alamat .onion generasi berikutnya: {}.",
|
||||
"error_tor_protocol_error": "",
|
||||
"error_tor_protocol_error_unknown": "",
|
||||
"error_invalid_private_key": "",
|
||||
"connecting_to_tor": "",
|
||||
"update_available": "",
|
||||
"update_error_check_error": "",
|
||||
"update_error_invalid_latest_version": "",
|
||||
"update_not_available": "",
|
||||
"gui_tor_connection_ask": "",
|
||||
"connecting_to_tor": "Menghubungkan ke jaringan Tor",
|
||||
"update_available": "OnionShare Baru tersedia. <a href='{}'>klik di sini</a> untuk mendapatkannya. <br><br>Anda menggunakan {} dan yang terbaru adalah {}.",
|
||||
"update_error_check_error": "Tidak dapat memeriksa versi baru: Mungkin Anda tidak terhubung ke Tor, atau situs web OnionShare sedang down?",
|
||||
"update_error_invalid_latest_version": "Tidak dapat memeriksa versi baru: Situs web OnionShare mengatakan bahwa versi terbaru adalah '{}' yang tidak dapat dikenali…",
|
||||
"update_not_available": "Anda menjalankan OnionShare terbaru.",
|
||||
"gui_tor_connection_ask": "Buka pengaturan untuk memilah koneksi ke Tor?",
|
||||
"gui_tor_connection_ask_open_settings": "Ya",
|
||||
"gui_tor_connection_ask_quit": "Keluar",
|
||||
"gui_tor_connection_error_settings": "",
|
||||
"gui_tor_connection_canceled": "",
|
||||
"gui_tor_connection_lost": "",
|
||||
"gui_tor_connection_error_settings": "Coba ubah cara OnionShare terhubung ke jaringan Tor di pengaturan.",
|
||||
"gui_tor_connection_canceled": "Tidak dapat terhubung ke Tor.\n\nPastikan Anda terhubung ke Internet, kemudian buka kembali OnionShare dan atur koneksinya ke Tor.",
|
||||
"gui_tor_connection_lost": "Terputus dari Tor.",
|
||||
"gui_server_started_after_autostop_timer": "",
|
||||
"gui_server_autostop_timer_expired": "",
|
||||
"share_via_onionshare": "",
|
||||
"share_via_onionshare": "Bagikan via OnionShare",
|
||||
"gui_use_legacy_v2_onions_checkbox": "",
|
||||
"gui_save_private_key_checkbox": "",
|
||||
"gui_share_url_description": "",
|
||||
|
@ -138,16 +138,16 @@
|
|||
"gui_url_label_stay_open": "",
|
||||
"gui_url_label_onetime": "",
|
||||
"gui_url_label_onetime_and_persistent": "",
|
||||
"gui_status_indicator_share_stopped": "",
|
||||
"gui_status_indicator_share_working": "",
|
||||
"gui_status_indicator_share_started": "",
|
||||
"gui_status_indicator_receive_stopped": "",
|
||||
"gui_status_indicator_receive_working": "",
|
||||
"gui_status_indicator_receive_started": "",
|
||||
"gui_file_info": "",
|
||||
"gui_file_info_single": "",
|
||||
"history_in_progress_tooltip": "",
|
||||
"history_completed_tooltip": "",
|
||||
"gui_status_indicator_share_stopped": "Siap untuk berbagi",
|
||||
"gui_status_indicator_share_working": "Memulai…",
|
||||
"gui_status_indicator_share_started": "Berbagi",
|
||||
"gui_status_indicator_receive_stopped": "Siap untuk menerima",
|
||||
"gui_status_indicator_receive_working": "Memulai…",
|
||||
"gui_status_indicator_receive_started": "Menerima",
|
||||
"gui_file_info": "{} file, {}",
|
||||
"gui_file_info_single": "{} file, {}",
|
||||
"history_in_progress_tooltip": "{} sedang berlangsung",
|
||||
"history_completed_tooltip": "{} selesai",
|
||||
"info_in_progress_uploads_tooltip": "",
|
||||
"info_completed_uploads_tooltip": "",
|
||||
"error_cannot_create_downloads_dir": "",
|
||||
|
@ -165,7 +165,7 @@
|
|||
"gui_settings_public_mode_checkbox": "",
|
||||
"systray_close_server_title": "",
|
||||
"systray_close_server_message": "",
|
||||
"systray_page_loaded_title": "",
|
||||
"systray_page_loaded_title": "Halaman dimuat",
|
||||
"systray_download_page_loaded_message": "",
|
||||
"systray_upload_page_loaded_message": "",
|
||||
"gui_uploads": "",
|
||||
|
@ -176,13 +176,85 @@
|
|||
"gui_upload_finished": "",
|
||||
"gui_download_in_progress": "",
|
||||
"gui_open_folder_error_nautilus": "",
|
||||
"gui_settings_language_label": "",
|
||||
"gui_settings_language_changed_notice": "",
|
||||
"gui_settings_language_label": "Bahasa",
|
||||
"gui_settings_language_changed_notice": "Mulai ulang OnionShare untuk menerapkan bahasa baru.",
|
||||
"gui_add_files": "Tambahkan berkas",
|
||||
"gui_add_folder": "Tambahkan Folder",
|
||||
"gui_settings_onion_label": "Pengaturan Onion",
|
||||
"incorrect_password": "Password salah",
|
||||
"gui_waiting_to_start": "Dijadwalkan akan dimulai pada {}. Klik untuk membatalkan.",
|
||||
"gui_start_server_autostart_timer_tooltip": "Timer mulai otomatis berakhir pada {}",
|
||||
"gui_stop_server_autostop_timer_tooltip": "Timer berhenti otomatis berakhir pada {}"
|
||||
"gui_stop_server_autostop_timer_tooltip": "Timer berhenti otomatis berakhir pada {}",
|
||||
"gui_new_tab_chat_button": "Mengobrol secara Anonim",
|
||||
"gui_new_tab_website_button": "Host sebuah situs web",
|
||||
"gui_main_page_share_button": "Mulai Berbagi",
|
||||
"gui_main_page_website_button": "Mulai Hosting",
|
||||
"gui_main_page_receive_button": "Mulai Menerima",
|
||||
"gui_close_tab_warning_cancel": "Batal",
|
||||
"gui_close_tab_warning_title": "Anda yakin?",
|
||||
"gui_tab_name_chat": "Obrolan",
|
||||
"gui_tab_name_website": "Situs web",
|
||||
"gui_tab_name_receive": "Menerima",
|
||||
"gui_tab_name_share": "Berbagi",
|
||||
"gui_main_page_chat_button": "Mulai Obrolan",
|
||||
"gui_quit_warning_title": "Anda yakin?",
|
||||
"gui_receive_flatpak_data_dir": "Karena Anda menginstal OnionShare menggunakan Flatpak, Anda harus menyimpan file ke folder di ~/OnionShare.",
|
||||
"mode_settings_website_disable_csp_checkbox": "Jangan kirim header Kebijakan Keamanan Konten (memungkinkan situs web Anda menggunakan sumber daya pihak ketiga)",
|
||||
"gui_open_folder_error": "Gagal membuka folder dengan xdg-open. File ada di sini: {}",
|
||||
"gui_status_indicator_share_scheduled": "Dijadwalkan…",
|
||||
"error_cannot_create_data_dir": "Tidak dapat membuat folder data OnionShare: {}",
|
||||
"history_requests_tooltip": "{} permintaan web",
|
||||
"gui_status_indicator_receive_scheduled": "Dijadwalkan…",
|
||||
"systray_page_loaded_message": "Alamat OnionShare dimuat",
|
||||
"gui_all_modes_transfer_canceled": "Dibatalkan {}",
|
||||
"gui_all_modes_transfer_canceled_range": "Dibatalkan {} - {}",
|
||||
"gui_all_modes_transfer_finished": "Ditransfer {}",
|
||||
"gui_all_modes_transfer_finished_range": "Ditransfer {} - {}",
|
||||
"mode_settings_receive_data_dir_browse_button": "Telusur",
|
||||
"mode_settings_receive_data_dir_label": "Simpan file ke",
|
||||
"mode_settings_share_autostop_sharing_checkbox": "Berhenti berbagi setelah file dikirim (hapus centang untuk memperbolehkan mengunduh file individual)",
|
||||
"mode_settings_client_auth_checkbox": "Gunakan otorisasi klien",
|
||||
"mode_settings_legacy_checkbox": "Gunakan alamat legacy (layanan onion v2, tidak disarankan)",
|
||||
"mode_settings_autostop_timer_checkbox": "Hentikan layanan onion pada waktu yang dijadwalkan",
|
||||
"mode_settings_autostart_timer_checkbox": "Mulai layanan onion pada waktu yang dijadwalkan",
|
||||
"mode_settings_public_checkbox": "Jangan gunakan kata sandi",
|
||||
"mode_settings_persistent_checkbox": "Simpan tab ini, dan secara otomatis membukanya saat saya membuka OnionShare",
|
||||
"mode_settings_advanced_toggle_hide": "Sembunyikan pengaturan lanjut",
|
||||
"mode_settings_advanced_toggle_show": "Tampilkan pengaturan lanjut",
|
||||
"gui_quit_warning_cancel": "Batal",
|
||||
"gui_new_tab_receive_button": "Terima File",
|
||||
"gui_new_tab_share_button": "Bagikan file",
|
||||
"gui_new_tab_tooltip": "Buka tab baru",
|
||||
"gui_new_tab": "Tab Baru",
|
||||
"seconds_first_letter": "d",
|
||||
"minutes_first_letter": "m",
|
||||
"hours_first_letter": "j",
|
||||
"days_first_letter": "h",
|
||||
"gui_receive_mode_autostop_timer_waiting": "Menunggu untuk menyelesaikan penerimaan",
|
||||
"gui_receive_mode_no_files": "Belum Ada File yang Diterima",
|
||||
"gui_website_mode_no_files": "Belum Ada Situs Web yang Dibagikan",
|
||||
"gui_share_mode_autostop_timer_waiting": "Menunggu untuk menyelesaikan pengiriman",
|
||||
"gui_share_mode_no_files": "Belum Ada File yang Dikirim",
|
||||
"gui_all_modes_progress_eta": "{0:s}, ETA: {1:s}, %p%",
|
||||
"gui_all_modes_progress_starting": "{0:s}, %p% (menghitung)",
|
||||
"gui_all_modes_progress_complete": "%p%, {0:s} berlalu.",
|
||||
"gui_all_modes_transfer_started": "Dimulai {}",
|
||||
"gui_all_modes_clear_history": "Bersihkan Semua",
|
||||
"gui_all_modes_history": "Riwayat",
|
||||
"systray_receive_started_message": "Seseorang mengirim file kepada Anda",
|
||||
"systray_receive_started_title": "Menerima Dimulai",
|
||||
"systray_share_canceled_message": "Seseorang membatalkan menerima file Anda",
|
||||
"systray_share_canceled_title": "Berbagi Dibatalkan",
|
||||
"systray_share_completed_message": "Selesai mengirim file",
|
||||
"systray_share_completed_title": "Berbagi Selesai",
|
||||
"systray_share_started_message": "Mulai mengirim file ke seseorang",
|
||||
"systray_share_started_title": "Berbagi dimulai",
|
||||
"gui_color_mode_changed_notice": "Mulai ulang OnionShare agar mode warna baru diterapkan.",
|
||||
"gui_qr_code_dialog_title": "Kode QR OnionShare",
|
||||
"gui_show_url_qr_code": "Tampilkan kode QR",
|
||||
"error_port_not_available": "Port OnionShare tidak tersedia",
|
||||
"gui_chat_stop_server": "Hentikan server obrolan",
|
||||
"gui_chat_start_server": "Mulai server obrolan",
|
||||
"gui_file_selection_remove_all": "Hapus Semua",
|
||||
"gui_remove": "Hapus"
|
||||
}
|
||||
|
|
|
@ -18,7 +18,7 @@ You should have received a copy of the GNU General Public License
|
|||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
"""
|
||||
|
||||
from PySide2 import QtCore, QtWidgets, QtGui
|
||||
from PySide2 import QtCore, QtWidgets
|
||||
|
||||
from onionshare_cli.common import AutoStopTimer
|
||||
|
||||
|
@ -387,10 +387,10 @@ class Mode(QtWidgets.QWidget):
|
|||
if self.server_status.status != ServerStatus.STATUS_STOPPED:
|
||||
try:
|
||||
self.web.stop(self.app.port)
|
||||
except:
|
||||
except Exception:
|
||||
# Probably we had no port to begin with (Onion service didn't start)
|
||||
pass
|
||||
self.app.cleanup()
|
||||
self.web.cleanup()
|
||||
|
||||
self.stop_server_custom()
|
||||
|
||||
|
@ -455,12 +455,24 @@ class Mode(QtWidgets.QWidget):
|
|||
"""
|
||||
pass
|
||||
|
||||
def handle_request_upload_includes_message(self, event):
|
||||
"""
|
||||
Handle REQUEST_UPLOAD_INCLUDES_MESSAGE event.
|
||||
"""
|
||||
pass
|
||||
|
||||
def handle_request_upload_file_renamed(self, event):
|
||||
"""
|
||||
Handle REQUEST_UPLOAD_FILE_RENAMED event.
|
||||
"""
|
||||
pass
|
||||
|
||||
def handle_request_upload_message(self, event):
|
||||
"""
|
||||
Handle REQUEST_UPLOAD_MESSAGE event.
|
||||
"""
|
||||
pass
|
||||
|
||||
def handle_request_upload_set_dir(self, event):
|
||||
"""
|
||||
Handle REQUEST_UPLOAD_SET_DIR event.
|
||||
|
|
|
@ -18,14 +18,8 @@ You should have received a copy of the GNU General Public License
|
|||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
"""
|
||||
|
||||
import os
|
||||
import random
|
||||
import string
|
||||
|
||||
from PySide2 import QtCore, QtWidgets, QtGui
|
||||
|
||||
from onionshare_cli.onion import *
|
||||
from onionshare_cli.common import Common
|
||||
from onionshare_cli.web import Web
|
||||
|
||||
from .. import Mode
|
||||
|
|
|
@ -253,7 +253,7 @@ class ReceiveHistoryItemFile(QtWidgets.QWidget):
|
|||
try:
|
||||
# If nautilus is available, open it
|
||||
subprocess.Popen(["xdg-open", self.dir])
|
||||
except:
|
||||
except Exception:
|
||||
Alert(
|
||||
self.common,
|
||||
strings._("gui_open_folder_error").format(abs_filename),
|
||||
|
@ -268,6 +268,60 @@ class ReceiveHistoryItemFile(QtWidgets.QWidget):
|
|||
subprocess.Popen(["explorer", f"/select,{abs_filename}"])
|
||||
|
||||
|
||||
class ReceiveHistoryItemMessage(QtWidgets.QWidget):
|
||||
def __init__(
|
||||
self,
|
||||
common,
|
||||
):
|
||||
super(ReceiveHistoryItemMessage, self).__init__()
|
||||
self.common = common
|
||||
self.filename = None
|
||||
|
||||
# Read message button
|
||||
message_pixmap = QtGui.QPixmap.fromImage(
|
||||
QtGui.QImage(GuiCommon.get_resource_path("images/open_message.png"))
|
||||
)
|
||||
message_icon = QtGui.QIcon(message_pixmap)
|
||||
self.message_button = QtWidgets.QPushButton(
|
||||
strings._("history_receive_read_message_button")
|
||||
)
|
||||
self.message_button.setStyleSheet(self.common.gui.css["receive_message_button"])
|
||||
self.message_button.clicked.connect(self.open_message)
|
||||
self.message_button.setIcon(message_icon)
|
||||
self.message_button.setIconSize(message_pixmap.rect().size())
|
||||
|
||||
# Layouts
|
||||
layout = QtWidgets.QHBoxLayout()
|
||||
layout.addWidget(self.message_button)
|
||||
layout.addStretch()
|
||||
self.setLayout(layout)
|
||||
|
||||
self.hide()
|
||||
|
||||
def set_filename(self, new_filename):
|
||||
self.filename = new_filename
|
||||
self.show()
|
||||
|
||||
def open_message(self):
|
||||
"""
|
||||
Open the message in the operating system's default text editor
|
||||
"""
|
||||
self.common.log("ReceiveHistoryItemMessage", "open_message", self.filename)
|
||||
|
||||
# Linux
|
||||
if self.common.platform == "Linux" or self.common.platform == "BSD":
|
||||
# If nautilus is available, open it
|
||||
subprocess.Popen(["xdg-open", self.filename])
|
||||
|
||||
# macOS
|
||||
elif self.common.platform == "Darwin":
|
||||
subprocess.call(["open", self.filename])
|
||||
|
||||
# Windows
|
||||
elif self.common.platform == "Windows":
|
||||
subprocess.Popen(["notepad", self.filename])
|
||||
|
||||
|
||||
class ReceiveHistoryItem(HistoryItem):
|
||||
def __init__(self, common, id, content_length):
|
||||
super(ReceiveHistoryItem, self).__init__()
|
||||
|
@ -277,6 +331,12 @@ class ReceiveHistoryItem(HistoryItem):
|
|||
self.started = datetime.now()
|
||||
self.status = HistoryItem.STATUS_STARTED
|
||||
|
||||
self.common.log(
|
||||
"ReceiveHistoryItem",
|
||||
"__init__",
|
||||
f"id={self.id} content_length={self.content_length}",
|
||||
)
|
||||
|
||||
# Label
|
||||
self.label = QtWidgets.QLabel(
|
||||
strings._("gui_all_modes_transfer_started").format(
|
||||
|
@ -295,6 +355,9 @@ class ReceiveHistoryItem(HistoryItem):
|
|||
self.common.gui.css["downloads_uploads_progress_bar"]
|
||||
)
|
||||
|
||||
# The message widget, if a message was included
|
||||
self.message = ReceiveHistoryItemMessage(self.common)
|
||||
|
||||
# This layout contains file widgets
|
||||
self.files_layout = QtWidgets.QVBoxLayout()
|
||||
self.files_layout.setContentsMargins(0, 0, 0, 0)
|
||||
|
@ -305,6 +368,7 @@ class ReceiveHistoryItem(HistoryItem):
|
|||
# Layout
|
||||
layout = QtWidgets.QVBoxLayout()
|
||||
layout.addWidget(self.label)
|
||||
layout.addWidget(self.message)
|
||||
layout.addWidget(self.progress_bar)
|
||||
layout.addWidget(files_widget)
|
||||
layout.addStretch()
|
||||
|
@ -313,6 +377,9 @@ class ReceiveHistoryItem(HistoryItem):
|
|||
# We're also making a dictionary of file widgets, to make them easier to access
|
||||
self.files = {}
|
||||
|
||||
def includes_message(self, message_filename):
|
||||
self.message.set_filename(message_filename)
|
||||
|
||||
def update(self, data):
|
||||
"""
|
||||
Using the progress from Web, update the progress bar and file size labels
|
||||
|
@ -560,6 +627,13 @@ class HistoryItemList(QtWidgets.QScrollArea):
|
|||
if id in self.items:
|
||||
self.items[id].cancel()
|
||||
|
||||
def includes_message(self, id, message_filename):
|
||||
"""
|
||||
Show message button for receive mode
|
||||
"""
|
||||
if id in self.items:
|
||||
self.items[id].includes_message(message_filename)
|
||||
|
||||
def reset(self):
|
||||
"""
|
||||
Reset all items, emptying the list. Override this method.
|
||||
|
@ -653,7 +727,7 @@ class History(QtWidgets.QWidget):
|
|||
"""
|
||||
Add a new item.
|
||||
"""
|
||||
self.common.log("History", "add", f"id: {id}, item: {item}")
|
||||
self.common.log("History", "add", f"id: {id}")
|
||||
|
||||
# Hide empty, show not empty
|
||||
self.empty.hide()
|
||||
|
@ -674,6 +748,12 @@ class History(QtWidgets.QWidget):
|
|||
"""
|
||||
self.item_list.cancel(id)
|
||||
|
||||
def includes_message(self, id, message_filename):
|
||||
"""
|
||||
Show the message button
|
||||
"""
|
||||
self.item_list.includes_message(id, message_filename)
|
||||
|
||||
def reset(self):
|
||||
"""
|
||||
Reset all items.
|
||||
|
|
|
@ -201,7 +201,7 @@ class ModeSettingsWidget(QtWidgets.QWidget):
|
|||
self.tab.change_title.emit(
|
||||
self.tab.tab_id, strings._("gui_tab_name_chat")
|
||||
)
|
||||
elif self.tab_mode == None:
|
||||
elif self.tab_mode is None:
|
||||
pass
|
||||
else:
|
||||
title = self.title_lineedit.text()
|
||||
|
|
|
@ -78,6 +78,25 @@ class ReceiveMode(Mode):
|
|||
data_dir_layout.addWidget(data_dir_button)
|
||||
self.mode_settings_widget.mode_specific_layout.addLayout(data_dir_layout)
|
||||
|
||||
# Disable text or files
|
||||
self.disable_text_checkbox = self.settings.get("receive", "disable_files")
|
||||
self.disable_text_checkbox = QtWidgets.QCheckBox()
|
||||
self.disable_text_checkbox.clicked.connect(self.disable_text_checkbox_clicked)
|
||||
self.disable_text_checkbox.setText(
|
||||
strings._("mode_settings_receive_disable_text_checkbox")
|
||||
)
|
||||
self.disable_files_checkbox = self.settings.get("receive", "disable_files")
|
||||
self.disable_files_checkbox = QtWidgets.QCheckBox()
|
||||
self.disable_files_checkbox.clicked.connect(self.disable_files_checkbox_clicked)
|
||||
self.disable_files_checkbox.setText(
|
||||
strings._("mode_settings_receive_disable_files_checkbox")
|
||||
)
|
||||
disable_layout = QtWidgets.QHBoxLayout()
|
||||
disable_layout.addWidget(self.disable_text_checkbox)
|
||||
disable_layout.addWidget(self.disable_files_checkbox)
|
||||
disable_layout.addStretch()
|
||||
self.mode_settings_widget.mode_specific_layout.addLayout(disable_layout)
|
||||
|
||||
# Webhook URL
|
||||
webhook_url = self.settings.get("receive", "webhook_url")
|
||||
self.webhook_url_checkbox = QtWidgets.QCheckBox()
|
||||
|
@ -217,6 +236,16 @@ class ReceiveMode(Mode):
|
|||
self.data_dir_lineedit.setText(selected_dir)
|
||||
self.settings.set("receive", "data_dir", selected_dir)
|
||||
|
||||
def disable_text_checkbox_clicked(self):
|
||||
self.settings.set(
|
||||
"receive", "disable_text", self.disable_text_checkbox.isChecked()
|
||||
)
|
||||
|
||||
def disable_files_checkbox_clicked(self):
|
||||
self.settings.set(
|
||||
"receive", "disable_files", self.disable_files_checkbox.isChecked()
|
||||
)
|
||||
|
||||
def webhook_url_checkbox_clicked(self):
|
||||
if self.webhook_url_checkbox.isChecked():
|
||||
if self.settings.get("receive", "webhook_url"):
|
||||
|
@ -312,8 +341,11 @@ class ReceiveMode(Mode):
|
|||
Handle REQUEST_STARTED event.
|
||||
"""
|
||||
item = ReceiveHistoryItem(
|
||||
self.common, event["data"]["id"], event["data"]["content_length"]
|
||||
self.common,
|
||||
event["data"]["id"],
|
||||
event["data"]["content_length"],
|
||||
)
|
||||
|
||||
self.history.add(event["data"]["id"], item)
|
||||
self.toggle_history.update_indicator(True)
|
||||
self.history.in_progress_count += 1
|
||||
|
@ -333,6 +365,12 @@ class ReceiveMode(Mode):
|
|||
{"action": "progress", "progress": event["data"]["progress"]},
|
||||
)
|
||||
|
||||
def handle_request_upload_includes_message(self, event):
|
||||
"""
|
||||
Handle REQUEST_UPLOAD_INCLUDES_MESSAGE event.
|
||||
"""
|
||||
self.history.includes_message(event["data"]["id"], event["data"]["filename"])
|
||||
|
||||
def handle_request_upload_file_renamed(self, event):
|
||||
"""
|
||||
Handle REQUEST_UPLOAD_FILE_RENAMED event.
|
||||
|
|
|
@ -21,7 +21,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
import os
|
||||
from PySide2 import QtCore, QtWidgets, QtGui
|
||||
|
||||
from onionshare_cli.onion import *
|
||||
from onionshare_cli.common import Common
|
||||
from onionshare_cli.web import Web
|
||||
|
||||
|
@ -30,7 +29,7 @@ from .. import Mode
|
|||
from ..file_selection import FileSelection
|
||||
from ..history import History, ToggleHistory, ShareHistoryItem
|
||||
from .... import strings
|
||||
from ....widgets import Alert, MinimumWidthWidget
|
||||
from ....widgets import MinimumWidthWidget
|
||||
from ....gui_common import GuiCommon
|
||||
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@ class CompressThread(QtCore.QThread):
|
|||
|
||||
# prepare files to share
|
||||
def set_processed_size(self, x):
|
||||
if self.mode._zip_progress_bar != None:
|
||||
if self.mode._zip_progress_bar is not None:
|
||||
self.mode._zip_progress_bar.update_processed_size_signal.emit(x)
|
||||
|
||||
def run(self):
|
||||
|
@ -47,9 +47,6 @@ class CompressThread(QtCore.QThread):
|
|||
self.mode.filenames, processed_size_callback=self.set_processed_size
|
||||
)
|
||||
self.success.emit()
|
||||
self.mode.app.cleanup_filenames += (
|
||||
self.mode.web.share_mode.cleanup_filenames
|
||||
)
|
||||
except OSError as e:
|
||||
self.error.emit(e.strerror)
|
||||
|
||||
|
|
|
@ -19,12 +19,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
"""
|
||||
|
||||
import os
|
||||
import random
|
||||
import string
|
||||
|
||||
from PySide2 import QtCore, QtWidgets, QtGui
|
||||
|
||||
from onionshare_cli.onion import *
|
||||
from onionshare_cli.common import Common
|
||||
from onionshare_cli.web import Web
|
||||
|
||||
|
@ -32,7 +29,7 @@ from .. import Mode
|
|||
from ..file_selection import FileSelection
|
||||
from ..history import History, ToggleHistory
|
||||
from .... import strings
|
||||
from ....widgets import Alert, MinimumWidthWidget
|
||||
from ....widgets import MinimumWidthWidget
|
||||
from ....gui_common import GuiCommon
|
||||
|
||||
|
||||
|
|
|
@ -161,7 +161,7 @@ class ServerStatus(QtWidgets.QWidget):
|
|||
self.url.setText(wrapped_onion_url)
|
||||
else:
|
||||
self.url.setText(self.get_url())
|
||||
except:
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
def show_url(self):
|
||||
|
|
|
@ -540,6 +540,9 @@ class Tab(QtWidgets.QWidget):
|
|||
elif event["type"] == Web.REQUEST_CANCELED:
|
||||
mode.handle_request_canceled(event)
|
||||
|
||||
elif event["type"] == Web.REQUEST_UPLOAD_INCLUDES_MESSAGE:
|
||||
mode.handle_request_upload_includes_message(event)
|
||||
|
||||
elif event["type"] == Web.REQUEST_UPLOAD_FILE_RENAMED:
|
||||
mode.handle_request_upload_file_renamed(event)
|
||||
|
||||
|
@ -665,7 +668,7 @@ class Tab(QtWidgets.QWidget):
|
|||
if self.close_dialog.clickedButton() == self.close_dialog.accept_button:
|
||||
self.common.log("Tab", "close_tab", "close, closing tab")
|
||||
self.get_mode().stop_server()
|
||||
self.app.cleanup()
|
||||
self.get_mode().web.cleanup()
|
||||
return True
|
||||
# Cancel
|
||||
else:
|
||||
|
@ -678,4 +681,4 @@ class Tab(QtWidgets.QWidget):
|
|||
self.get_mode().web.stop(self.get_mode().app.port)
|
||||
self.get_mode().web_thread.quit()
|
||||
self.get_mode().web_thread.wait()
|
||||
self.app.cleanup()
|
||||
self.get_mode().web.cleanup()
|
||||
|
|
|
@ -252,7 +252,7 @@ class EventHandlerThread(QtCore.QThread):
|
|||
"EventHandler", "run", f"invalid event type: {obj}"
|
||||
)
|
||||
|
||||
except:
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
if self.should_quit:
|
||||
|
|
|
@ -166,7 +166,7 @@ class TorConnectionThread(QtCore.QThread):
|
|||
else:
|
||||
self.canceled_connecting_to_tor.emit()
|
||||
|
||||
except BundledTorCanceled as e:
|
||||
except BundledTorCanceled:
|
||||
self.common.log(
|
||||
"TorConnectionThread", "run", "caught exception: BundledTorCanceled"
|
||||
)
|
||||
|
|
|
@ -19,7 +19,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
"""
|
||||
|
||||
from PySide2 import QtCore
|
||||
import datetime, re
|
||||
import datetime
|
||||
import re
|
||||
import socks
|
||||
from distutils.version import LooseVersion as Version
|
||||
|
||||
|
|
|
@ -24,6 +24,6 @@
|
|||
<update_contact>micah@micahflee.com</update_contact>
|
||||
<content_rating type="oars-1.1" />
|
||||
<releases>
|
||||
<release type="development" date="2021-02-22" version="2.3.1" />
|
||||
<release type="development" date="2021-05-04" version="2.3.2" />
|
||||
</releases>
|
||||
</component>
|
||||
|
|
|
@ -25,7 +25,12 @@ version = "2.3.1"
|
|||
setuptools.setup(
|
||||
name="onionshare",
|
||||
version=version,
|
||||
description="OnionShare lets you securely and anonymously send and receive files. It works by starting a web server, making it accessible as a Tor onion service, and generating an unguessable web address so others can download files from you, or upload files to you. It does _not_ require setting up a separate server or using a third party file-sharing service.",
|
||||
description=(
|
||||
"OnionShare lets you securely and anonymously send and receive files. It works by starting a web "
|
||||
"server, making it accessible as a Tor onion service, and generating an unguessable web address so "
|
||||
"others can download files from you, or upload files to you. It does _not_ require setting up a "
|
||||
"separate server or using a third party file-sharing service."
|
||||
),
|
||||
author="Micah Lee",
|
||||
author_email="micah@micahflee.com",
|
||||
maintainer="Micah Lee",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue