This commit is contained in:
Observer KRypt0n_ 2023-05-06 15:26:08 +02:00
commit 1d7d50e85c
No known key found for this signature in database
GPG key ID: 844DA47BA25FE1E2
42 changed files with 634 additions and 183 deletions

View file

@ -7,9 +7,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased]
## [1.0.0]
🚀 Initial release
<br>
[unreleased]: https://github.com/an-anime-team/the-honkers-railway-launcher/compare/1.0.0...next
[3.0.0]: https://github.com/an-anime-team/the-honkers-railway-launcher/releases/tag/1.0.0
[1.0.0]: https://github.com/an-anime-team/the-honkers-railway-launcher/releases/tag/1.0.0

12
Cargo.lock generated
View file

@ -65,8 +65,8 @@ dependencies = [
[[package]]
name = "anime-launcher-sdk"
version = "1.1.4"
source = "git+https://github.com/an-anime-team/anime-launcher-sdk?tag=1.1.4#cba4a7bbde348c1b0c123517025fbb37aecfbcb4"
version = "1.2.1"
source = "git+https://github.com/an-anime-team/anime-launcher-sdk?tag=1.2.1#f7bddd1d2fde4dcc7d04bda9e4d9160a5bc88218"
dependencies = [
"anime-game-core",
"anyhow",
@ -2065,9 +2065,9 @@ checksum = "456c603be3e8d448b072f410900c09faf164fbce2d480456f50eea6e25f9c848"
[[package]]
name = "relm4"
version = "0.6.0-alpha.2"
version = "0.6.0-beta.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7acc5e3ddd682eeb0ca33da36b821fc907017c6d7758b09ce280247b0b0ea8cd"
checksum = "f169f698ce2e487eed2306898fcf262224a287d0e81480db4190e74cfec412cf"
dependencies = [
"async-trait",
"flume",
@ -2083,9 +2083,9 @@ dependencies = [
[[package]]
name = "relm4-macros"
version = "0.6.0-alpha.2"
version = "0.6.0-beta.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c8525ce12dcd7d2a9e9070d84b8b885600eccd0a143df6712ce34a87d001a8b7"
checksum = "7fa06febb3685960e7c1c44e21e44a3829325940b31d1e91391a43c32020c201"
dependencies = [
"proc-macro2",
"quote",

View file

@ -17,13 +17,13 @@ glib-build-tools = "0.17"
[dependencies.anime-launcher-sdk]
git = "https://github.com/an-anime-team/anime-launcher-sdk"
tag = "1.1.4"
tag = "1.2.1"
features = ["all", "star-rail"]
# path = "../anime-launcher-sdk" # ! for dev purposes only
[dependencies]
relm4 = { version = "0.6.0-alpha.2", features = ["macros", "libadwaita"] }
relm4 = { version = "0.6.0-beta.1", features = ["macros", "libadwaita"] }
gtk = { package = "gtk4", version = "0.6", features = ["v4_8"] }
adw = { package = "libadwaita", version = "0.3", features = ["v1_2"] }

View file

@ -56,6 +56,8 @@ instead of the actual name of the game, to avoid search engine parsing.
To see the installation guides, please visit the wiki page [here](https://github.com/an-anime-team/the-honkers-railway-launcher/wiki/Installation)
Lutris integration described [here](https://github.com/an-anime-team/an-anime-game-launcher/wiki/Installation#-lutris)
## Chinese version support
This should be automatically enabled if you're using zh_cn (Chinese) as your system language. If you're not using it - you can change the game edition in the launcher settings

View file

@ -19,5 +19,5 @@ ru-ru = Русский
de-de = Deutsch
es-es = Español
fr-fr = Français
tr-tr = Türk
tr-tr = Türkçe
zh-cn = 简体中文

View file

@ -45,3 +45,11 @@ game-patching-error = Spiel konnte nicht gepatcht werden
# Sandbox
documentation-url-open-failed = Dokumentations-URL kann nicht geöffnet werden
# Game
game-session-add-failed = Spielsitzung konnte nicht hinzugefügt werden
game-session-update-failed = Spielsitzung konnte nicht aktualisiert werden
game-session-remove-failed = Spielsitzung konnte nicht entfernt werden
game-session-set-current-failed = Aktuelle Spielsitzung konnte nicht eingestellt werden
game-session-apply-failed = Spielsitzung konnte nicht angewendet werden

View file

@ -21,7 +21,7 @@ tos-violation-warning-message =
Sollte dies der Fall sein, würde Ihr Konto gegen die TOS verstoßen, {company-name}/{company-alter-name} sind frei zu tun, was sie wollen. Inklusive Ban.
Wenn Sie sich des Risikos bewusst sind, das mit dem Versuch, das Spiel inoffiziell zu spielen, verbunden ist, drücken Sie auf OK und lassen Sie uns die Welt von Teyvat erforschen!
Wenn Sie sich über das Risiko bewusst sind das mit dem versuchen des Spiels spielen in inoffizieller Weise verbunden ist dann drücken Sie OK um fortzufahren.
tos-dialog-title = Sind Sie sicher, dass Sie verstehen, was wir sagen?
tos-dialog-message =

View file

@ -0,0 +1,7 @@
game-sessions = Spielsitzungen
active-sessions = Aktive Sitzung
active-session-description = Derzeit ausgewählte Spielsitzung. Aktualisiert nach jedem Spielstart
update-session = Sitzung mit aktuellen Wine prefix Registrierungswerten aktualisieren
delete-session = Sitzung löschen

View file

@ -45,3 +45,11 @@ game-patching-error = Failed to patch game
# Sandbox
documentation-url-open-failed = Failed to open documentation URL
# Game
game-session-add-failed = Failed to add game session
game-session-update-failed = Failed to update game session
game-session-remove-failed = Failed to remove game session
game-session-set-current-failed = Failed to set current game session
game-session-apply-failed = Failed to apply game session

View file

@ -21,7 +21,7 @@ tos-violation-warning-message =
If this happens, as your account would be disobeying TOS, {company-name}/{company-alter-name} are free to do what they want. Including banning.
If you understand the risk of trying to play the game in an unofficial capacity, press OK and let's go researching the world of Teyvat!
If you understand the risk of trying to play the game in an unofficial capacity, press OK to continue
tos-dialog-title = Are you sure you understand what we want to say?
tos-dialog-message =

View file

@ -0,0 +1,7 @@
game-sessions = Game sessions
active-sessions = Active session
active-session-description = Currently selected game session. Updates after each game launch
update-session = Update session using current wine prefix registry values
delete-session = Delete session

View file

@ -45,3 +45,11 @@ game-patching-error = Fallo al parchear el juego
# Sandbox
documentation-url-open-failed = Failed to open documentation URL
# Game
game-session-add-failed = Fallo al añadir sesión de juego
game-session-update-failed = Fallo al actualizar sesión de juego
game-session-remove-failed = Fallo al eliminar sesión de juego
game-session-set-current-failed = Fallo al establecer sesión de juego actual
game-session-apply-failed = Fallo al aplicar sesión de juego

View file

@ -23,6 +23,11 @@ tos-violation-warning-message =
Si entiendes los riesgos de intentar jugar el juego de manera extraoficial, presiona OK y ¡exploremos el vasto mundo de Teyvat!
tos-dialog-title = ¿Estás seguro de entender lo que queremos decir?
tos-dialog-message =
1. No publiques información sobre este proyecto
2. No abuses de él usando clientes modificados o cosas similares
3. Haz preguntas exclusivamente en nuestro canal de Discord o de Matrix
dependencies = Dependencias
missing-dependencies-title = ¡Te faltan algunas dependencias!

View file

@ -0,0 +1,7 @@
game-sessions = Sesiones de juego
active-sessions = Sesión activa
active-session-description = La sesión de juego actualmente seleccionada. Se actualiza cada vez que se lanza el juego.
update-session = Actualizar la sesión con los valores actuales del registro del prefijo de Wine
delete-session = Eliminar sesión

View file

@ -22,6 +22,7 @@ continue = Continuar
exit = Salir
check = Comprobar
restart = Reiniciar
agree = Aceptar
loading-data = Cargando datos

View file

@ -45,3 +45,11 @@ game-patching-error = Le patch du jeu a échoué
# Sandbox
documentation-url-open-failed = Failed to open documentation URL
# Game
game-session-add-failed = Imposible d'ajouter la session de jeu
game-session-update-failed = Imposible de mettre à jour la session de jeu
game-session-remove-failed = Imposible de supprimer la session de jeu
game-session-set-current-failed = Imposible de sélectionner la session de jeu par défaut
game-session-apply-failed = Imposible d'appliquer la session de jeu

View file

@ -23,6 +23,11 @@ tos-violation-warning-message =
Si vous comprenez ces risques, appuyez sur "Continuer" pour venir explorer le monde de Teyvat !
tos-dialog-title = Are you sure you understand what we want to say?
tos-dialog-message =
1. Don't publish any information about this project
2. Don't abuse it by using some modded clients and so
3. Ask questions exceptionally in our discord or matrix server
dependencies = Dépendances
missing-dependencies-title = Il vous manque des dépendances !

View file

@ -0,0 +1,7 @@
game-sessions = Sessions de jeu
active-sessions = Session active
active-session-description = Session actuellement sélectionnée en jeu. Mis à jour à chaque lancement du jeu
update-session = Mettre à jour la session depuis les valeurs du registre du préfixe wine
delete-session = Supprimer la session

View file

@ -22,6 +22,7 @@ continue = Continuer
exit = Quitter
check = Vérifier
restart = Redémarer
agree = Agree
loading-data = Chargement des données

View file

@ -45,3 +45,11 @@ game-patching-error = Не удалось установить патч игры
# Sandbox
documentation-url-open-failed = Не удалось открыть ссылку с документацией
# Game
game-session-add-failed = Не удалось добавить игровую сессию
game-session-update-failed = Не удалось обновить игровую сессию
game-session-remove-failed = Не удалось удалить игровую сессию
game-session-set-current-failed = Не удалось выбрать игровую сессию
game-session-apply-failed = Не удалось применить игровую сессию

View file

@ -23,8 +23,13 @@ tos-violation-warning-message =
Если это произойдёт - поскольку ваша учетная запись будет нарушать правила, {company-name}/{company-alter-name} будут свободы делать то, что захотят, включая блокировку вашего аккаунта.
Если вы осознаёте риск использования неофициальных средств игры - нажмите "Продолжить" и отправляйтесь исследовать мир Тейвата!
Если вы осознаёте риск использования неофициальных средств игры - нажмите "Продолжить"
tos-dialog-title = Вы точно уверены что понимаете что мы хотим сказать?
tos-dialog-message =
1. Не публикуйте никакой информации о проекте
2. Не используйте его совместно с модифицированными клиентами и тому подобным
3. Задавайте вопросы исключительно на нашем discord или matrix сервере
dependencies = Зависимости
missing-dependencies-title = У вас не установлены некоторые компоненты!

View file

@ -0,0 +1,7 @@
game-sessions = Игровые сессии
active-sessions = Активная сессия
active-session-description = Выбранная игровая сессия. Обновляется после каждого запуска игры
update-session = Обновить сессию используя значения реестра из префикса Wine
delete-session = Удалить сессию

View file

@ -22,6 +22,7 @@ continue = Продолжить
exit = Выйти
check = Проверить
restart = Перезапустить
agree = Подтвердить
loading-data = Загрузка данных

View file

@ -1,13 +1,13 @@
wine = Wine
synchronization = Senkronizasyon
wine-sync-description = içerde dönen Wine eventleri senkronize etmek için kullanılan teknoloji
wine-sync-description = Arkaplanda gerçekleşen Wine olaylarını senkronize etmek için kullanılan teknoloji
language = dil
wine-lang-description = Wine için kullanılan dil klavye sorunlarını çözmek için kullanılabilir
language = Dil
wine-lang-description = Wine için kullanılan dil, klavye sorunlarını çözmek için kullanılabilir
system = Sistem
borderless-window = Köşesiz pencere
borderless-window = Köşesiz Pencere
virtual-desktop = Sanal Masaüstü
game = Oyun
@ -15,30 +15,30 @@ game = Oyun
hud = HUD
fsr = FSR
fsr-description = Oyunu mönitör boyutunuza büyütür daha düşük bir çözünürlük seçmek için oyun içinde alt + enter tuşlarına basın
fsr-description = Oyunu monitör boyutunuza büyütür. Daha düşük bir çözünürlük seçmek için oyun içinde alt + enter tuşlarına basın
ultra-quality = Ultra kalite
quality = Kalite
balanced = Dengeli
performance = Performans
gamemode = Oyunmodu
gamemode-description = Oyunu diğer işlemlerden daha öne koyarak performansı arttırır
gamemode = Oyun modu
gamemode-description = Oyunun işlem önceliğini arttırarak performansı arttırır
gamescope = Gamescope
gamescope-description = Gamescope Valve tarafından geliştirilmiş bir araçtır oyunları izole edilmiş bir Xwayland içinde açmanıza yarar
gamescope-description = Gamescope, oyunları izole edilmiş bir Xwayland içinde açmanıza yarayan Valve tarafından geliştirilmiş araçtır.
discord-rpc = Discord RPC
discord-rpc-description = Discord RPC Discorda şuanda oyun oynadığınızın bilgisini vermenize yarar bu sayede arkadaşlarınıza şuanda oyun oynadığınızı gösterebilirsiniz
discord-rpc-description = Discord RPC, Discord'a şu anda oyun oynadığınızı bildirmenizi sağlar. Bu sayede arkadaşlarınıza şu anda oyun oynadığınızı gösterebilirsiniz
title = Başlık
description = Açıklama
fps-unlocker = FPS kilidi açıcı
enabled = Açık
fps-unlocker-description = kare renderlama limitasyonunu kaldırır fakat oyunun anti hile sistemi tarafından tespit edilebilir
fps-unlocker-description = Kare işleme sınırlamasını kaldırır, fakat oyunun anti-hile sistemi tarafından tespit edilebilir
power-saving = Güç tasarrufu
power-saving-description = Alt tab attığınızda oyunun fps limitini 10 a çeker ve oyuna verilen işlem önceliğini azaltır
power-saving-description = Pencere değiştirdiğinizde oyunun kare sınırını 10'a indirir ve oyuna verilen işlem önceliğini azaltır
monitor = Monitör
monitor-description = Oyunu çalıştırmak istediğiniz monitör sayısı

View file

@ -1,12 +1,12 @@
launcher-folder-opening-error = Failed to open launcher folder
launcher-folder-opening-error = İstemci dosyasını açma başarısız oldu
game-folder-opening-error = Oyun dosyasını açma başarısız oldu
config-file-opening-error = Config dosyasını açma başarısız oldu
debug-file-opening-error = Debug dosyasını açma başarısız oldu
wish-url-search-failed = Dilekler urlsi bulunamadı
wish-url-opening-error = Dilekler urlsi açılamadı
wish-url-search-failed = Dileklerin URL'si bulunamadı
wish-url-opening-error = Dileklerin URL'si açılamadı
wine-run-error = Failed to run {$executable} executable using wine
wine-run-error = Wine kullanarak {$executable} programı çalıştırılamadı
game-launching-failed = Oyunu açma başarısız oldu
failed-get-selected-wine = Seçilen Wine versiyonunu alma başarısız oldu
@ -19,18 +19,18 @@ integrity-files-getting-error = Dosyaların bütünlüğü kontrol edilemedi
background-downloading-failed = Arkaplan fotoğrafını indirme başarısız oldu
components-index-sync-failed = Bileşenler dizini senkronizasyonu başarısız oldu
components-index-verify-failed = Bileşenler dizini doğrulanamadı
config-update-error = Configi kaydetme başarısız oldu
config-update-error = Config'i kaydetme başarısız oldu
wine-prefix-update-failed = Wine prefixini güncelleme başarısız oldu
dxvk-install-failed = DXVK indirilemedi
voice-package-deletion-error = Ses dosyasını silme başarısız oldu
game-diff-finding-error = Oyun diffini bulma başarısız oldu
game-diff-finding-error = Oyun diff'ini bulma başarısız oldu
patch-info-fetching-error = Yama bilgilerini toplama başarısız oldu
launcher-state-updating-error = İstemci durumunu güncelleme başarısız oldu
package-not-available = Paket mevcut değil: {$package}
wine-download-error = Wine indirme başarısız oldu
wine-unpack-errror = Wine dosyadan çıkarmak başarısız oldu
wine-unpack-errror = Wine dosyadan çıkarma başarısız oldu
wine-install-failed = Wine kurma başarısız oldu
dxvk-download-error = DXVK indirilemedi
dxvk-unpack-error = DXVK paketten çıkarılamadı
@ -44,4 +44,12 @@ game-patching-error = Yamayı uygulamada sorun çıktı
# Sandbox
documentation-url-open-failed = Failed to open documentation URL
documentation-url-open-failed = Belgelemenin URL'si açılamadı
# Game
game-session-add-failed = Oyun oturumu eklenemedi
game-session-update-failed = Oyun oturumu güncellenemedi
game-session-remove-failed = Oyun oturumu kaldırılamadı
game-session-set-current-failed = Oyun oturumu seçilemedi
game-session-apply-failed = Oyun oturumu uygulanamadı

View file

@ -1,31 +1,36 @@
welcome = Merhaba
welcome-page-message =
Merhaba bir anime oyunu istemcisine hoş geldiniz
Merhaba, bir anime oyunu istemcisine hoş geldiniz
Oyunu çalıştırmadan önce bazı şeyler hazırlamamız ve varsayılan bileşenleri indirmemiz gerekiyor.
Oyunu çalıştırmadan önce bazı şeyleri hazırlamamız ve varsayılan bileşenleri indirmemiz gerekiyor.
tos-violation-warning = Kullanım şartlarının ihlali uyarısı
tos-violation-warning-message =
Bu başlatıcı, resmi olmayan bir araçtır ve hiçbir şekilde {company-name} veya {company-alter-name} ile ilgili değildir.
Bu başlatıcı, resmi olmayan bir araçtır ve hiçbir şekilde {company-name} veya {company-alter-name} ile ilgili değildir.
Bu araç, Linux'ta {game-name} oynamayı kolaylaştırmak için tasarlanmıştır ve yalnızca oyunu daha az güçlükle yüklemek ve çalıştırmak amacıyla oluşturulmuştur.
Bu araç, Linux'ta {game-name} oynamayı kolaylaştırmak için tasarlanmıştır ve yalnızca oyunu daha az güçlükle yüklemek ve çalıştırmak amacıyla oluşturulmuştur.
Bunu, mevcut bileşenleri kullanarak ve deneyimi kullanıcı için basit hale getirerek yapar.
Bunu, mevcut bileşenleri kullanarak ve deneyimi kullanıcı için basit hale getirerek yapar.
Ancak burada kullanılan bazı bileşenler, {game-name} için {company-name} Hizmet Şartlarını ihlal ediyor olabilir.
Ancak burada kullanılan bazı bileşenler, {game-name} için {company-name} Hizmet Şartlarını ihlal ediyor olabilir.
Bu başlatıcıyı kullanıyorsanız, {game-name} hesabınız {company-name}/{company-alter-name} tarafından TOS uyumlu değil olarak tanımlanacaktır.
Bu başlatıcıyı kullanıyorsanız, {game-name} hesabınız {company-name}/{company-alter-name} tarafından TOS uyumlu değil olarak tanımlanacaktır.
Böyle bir durumda, hesabınız Hizmet Koşullarına uymayacağından, {company-name}/{company-alter-name} istediğini yapmakta özgürdür. Banlamak dahil.
Böyle bir durumda, hesabınız Hizmet Koşullarına uymayacağından, {company-name}/{company-alter-name} istediğini yapmakta özgürdür. Banlamak dahil.
Oyunu gayri resmi bir sıfatla oynamaya çalışmanın riskini anlıyorsanız, Tamam'a basın ve Haydi Teyvat dünyasını araştırmaya başlayalım!
Eğer oyunu illegal yollarla oynamanın riskini anlıyorsanız, Tamam'a tıklayın
tos-dialog-title = Ne demek istediğimizi anlayabildiniz mi?
tos-dialog-message =
1. Bu proje hakkında herhangi bir bilgi paylaşmayın.
2. Modlanmış istemciler vb. ile suistimal etmeyin.
3. Sorularınızı sadece Discord veya Matrix sunucumuzda sorun.
dependencies = Bağlılıklar
missing-dependencies-title = Bazı bağlılıklar bulunamadı!
dependencies = Bağımlılıklar
missing-dependencies-title = Bazı bağımlılıklar bulunamadı!
missing-dependencies-message = Kurulum işlemine devam etmeden önce bazı paketleri sisteminize kurmalısınız.
@ -34,24 +39,24 @@ choose-default-paths = Varsayılan yolları seç
show-all-folders = Ne yaptığımı biliyorum
show-all-folders-subtitle = Ek yol seçimi ayarlarını göster. Dediğimi yap...
runners-folder = Başlatıcılar(Runnerlar) klasörü
dxvks-folder = DXVKnın klasörü
wine-prefix-folder = Wine prefixnin klasörü
global-game-installation-folder = Global game version installation folder
chinese-game-installation-folder = Chinese game version installation folder
fps-unlocker-folder = FPS Unlocker folder
dxvks-folder = DXVK'nin klasörü
wine-prefix-folder = Wine prefix'inin klasörü
global-game-installation-folder = Evrensel oyun sürümünü yükleme klasörü
chinese-game-installation-folder = Oyun'un Çin sürümünü yükleme klasörü
fps-unlocker-folder = FPS Unlocker klasörü
components-index = Bileşenlerin dizini
patch-folder = Yama klasörü
temp-folder = "Geçici" klasörü
migrate = Migrate
migrate = Aktarma
select-voice-packages = Ses paketlerini seç
download-components = Bileşenleri indir
download-dxvk = DXVKyı İndir
apply-dxvk = DXVKyı uygula
download-dxvk = DXVK'yi İndir
apply-dxvk = DXVK'yi uygula
finish = Bitir

View file

@ -0,0 +1,7 @@
game-sessions = Oyun oturumları
active-sessions = Geçerli oturum
active-session-description = Şu anda geçerli oyun oturumu. Oyunu her açtığınızda güncellenir
update-session = Oturumu, geçerli wine prefix'inin girdi değerleriyle güncelleyin
delete-session = Oturumu kaldır

View file

@ -10,4 +10,4 @@ nis-description = DLSS teknolojisine düşük maliyetli bir alternatif olarak Nv
other-settings = Diğer ayarlar
framerate-limit = Kare hızı limiti
unfocused-framerate-limit = Odakta değilken ki Kare hızı limiti
unfocused-framerate-limit = Odakta değilken kare hızı limiti

View file

@ -5,43 +5,43 @@ update-background = Arkaplan imajını güncelle
update-background-description = İstemci için resmi arka plan resmini indirin. Bunun yerine özel resminizi kullanmak için devre dışı bırakabilirsiniz.
launcher-language = İstemci dili
launcher-language-description = Restart attıktan sonra uygulanır
launcher-language-description = Yeniden başlattıktan sonra uygulanır
game-edition = Game edition
global = Global
china = China
game-edition = Oyun Sürümü
global = Evrensel
china = Çin
game-environment = Game environment
game-environment-description = Get specific features like additional payment methods
game-environment = Oyun ortamı
game-environment-description = Ek ödeme yöntemleri gibi özelliklere erişin
game-voiceovers = Oyun içi sesler
game-voiceovers-description = List of downloaded game voiceovers. You can select them in the game settings
game-voiceovers-description = İndirilmiş oyun seslendirmeleri listesi. Oyun içi ayarlardan seçebilirsiniz
english = İngilizce
japanese = Japonca
korean = Korece
chinese = Çince
migrate-installation = Migrate installation
migrate-installation-description = Open special window where you can change your game installation folder
migrate-installation = Yüklemeyi aktar
migrate-installation-description = Oyun yükleme yerini değiştirebileceğiniz özel pencereyi açın
repair-game = Oyunu tamir et
status = Durum
game-version = Oyun versiyonu
game-not-installed = inik değil
game-not-installed = Yüklü değil
game-predownload-available = Güncelleme önceden indirilebilir: {$old} -> {$new}
game-update-available = Güncelleme mevcut: {$old} -> {$new}
game-outdated = Oyun çok eski bu yüzden güncellenemez. En son sürüm: {$latest}
game-outdated = Oyun çok eski, bu yüzden güncellenemez. En son sürüm: {$latest}
player-patch-version = Ana yama versiyonu
player-patch-version-description = Oyunu linuxda oynamanıza izin veren ana yama
player-patch-version-description = Oyunu Linux'ta oynamanıza izin veren ana yama
xlua-patch-version = Xlua yama versiyonu
xlua-patch-version-description = Eski bilgisayarlarda performansı arttıran ve bir kaç sorunu düzelten ekstra yama
xlua-patch-version-description = Eski bilgisayarlarda performansı arttıran ve birkaç sorunu düzelten ekstra yama
patch-not-available = Mevcut değil
patch-not-available-tooltip = Yama sunucularına erişelemiyor
patch-not-available-tooltip = Yama sunucularına erişilemiyor
patch-outdated = zamanı geçmiş ({$current})
patch-outdated-tooltip = Yamanın zamanı geçmiş: {$current} -> {$latest}
@ -55,7 +55,7 @@ patch-not-applied-tooltip = Yama uygulanmamış
apply-xlua-patch = Xlua yamasını uygula
ask-superuser-permissions = Yönetici izinlerini sor
ask-superuser-permissions-description = İstemci yöneticini iznini hostunuzun dosyalarını güncellemek için otomatik olarak kullanıcaktır. Buna flatpak versiyonunda gerek yoktur
ask-superuser-permissions-description = İstemci yönetici iznini hostunuzun dosyalarını güncellemek için otomatik olarak kullanacaktır. Buna flatpak versiyonunda gerek yoktur
selected-version = Seçilmiş versiyon
recommended-only = Sadece önerilenler
@ -63,14 +63,14 @@ recommended-only = Sadece önerilenler
wine-version = Wine versiyonu
wine-recommended-description = Sadece önerilen wine versiyonlarını göster
wine-tools = Wine tools
command-line = Command line
registry-editor = Registry editor
explorer = Explorer
task-manager = Task manager
configuration = Configuration
debugger = Debugger
wine-tools = Wine araçları
command-line = Komut istemi
registry-editor = Girdi düzenleyicisi
explorer = Dosya gezgini
task-manager = Görev yöneticisi
configuration = Konfigürasyon
debugger = Debug aracı
dxvk-version = DXVK versiyonu
dxvk-selection-disabled = DXVK özelliği Wine grup tercihleriniz yüzünden devre dışı
dxvk-selection-disabled = DXVK özelliği Wine grup tercihlerinizden dolayı devre dışı
dxvk-recommended-description = Sadece önerilen dxvk versiyonlarını göster

View file

@ -4,13 +4,13 @@ default = Varsayılan
details = Detaylar
width = Genişlik
height = Uzunlul
height = Uzunluk
# Menu items
launcher-folder = İstemci dosyası
game-folder = Oyun dosyası
config-file = Config dosyaso
config-file = Config dosyası
debug-file = Debug dosyası
wish-url = Dilekleri aç
about = Hakkında
@ -22,16 +22,17 @@ continue = Devam et
exit = Çıkış yap
check = Kontrol et
restart = Tekrardan başlat
agree = Onayla
loading-data = Bilgiler yükleniyor
downloading-background-picture = Arkaplan dosyasi indiriliyor
downloading-background-picture = Arkaplan dosyası indiriliyor
updating-components-index = Bileşenlerin dizini güncelleniyor
loading-game-version = Oyun sürümü yükleniyor
loading-patch-status = Yama durumu yükleniyor
loading-launcher-state = İstemci durumu yükleniyor
loading-launcher-state--game = Loading launcher state: oyun versiyonu doğrulanıyor
loading-launcher-state--voice = Loading launcher state: {$locale} dublaj doğrulanıyor
loading-launcher-state--voice = Loading launcher state: {$locale} seslendirme doğrulanıyor
loading-launcher-state--patch = Loading launcher state: indirilmiş yamanın durumu yükleniyor
@ -40,17 +41,17 @@ downloading = İndiriliyor
unpacking = Paketten çıkartılıyor
verifying-files = Dosyalar Doğrulanıyor
repairing-files = Dosyalar tamir ediliyor
migrating-folders = Migrating folders
applying-hdiff = Applying hdiff patches
removing-outdated = Removing outdated files
migrating-folders = Dosyalar aktarılıyor
applying-hdiff = Hdiff yamaları uygulanıyor
removing-outdated = Eskimiş dosyalar kaldırılıyor
components-index-updated = Components index was updated
components-index-updated = Bileşenlerin dizini güncellendi
launch = Çalıştır
migrate-folders = Migrate folders
migrate-folders-tooltip = Update game folders structure
migrate-folders = Dosyaları aktar
migrate-folders-tooltip = Oyun dosyaları yapısını güncelle
apply-patch = Yamayı uygula
download-wine = Wine indir
create-prefix = Prefix oluştur

View file

@ -1,28 +1,28 @@
sandbox = Sandbox
sandbox-description = Run the game in isolated environment, preventing it from accessing your personal data
sandbox = Sanallaştırma
sandbox-description = Oyunu kişisel verilerinize erişemeyeceği, izole bir ortamda çalıştırın
enable-sandboxing = Enable sandboxing
enable-sandboxing-description = Run the game in read-only copy of your root filesystem
enable-sandboxing = Sanallaştırmayı aktifleştir
enable-sandboxing-description = Oyunu root dosya sisteminizin salt-okunur kopyasında çalıştırın
hide-home-directory = Hide home directory
hide-home-directory-description = Isolate your /home, /var/home/$USER, and $HOME folders from the game
hide-home-directory = Home dizinini gizle
hide-home-directory-description = /home, /var/home/$USER, ve $HOME klasörlerini oyundan gizle
hostname = Hostname
additional-arguments = Additional arguments
hostname = Host adı
additional-arguments = Ek argümanlar
private-directories = Private directories
private-directories-description = These folders will be replaced by an empty virtual filesystem (tmpfs), and their original content will not be available to sandboxed game
private-directories = Özel dizinler
private-directories-description = Bu klasörler boş bir sanal dosya sistemiyle değiştirilecektir (tmpfs), ve orijinal içeriklerine sanallaştırılmış oyun erişemeyecektir
path = Path
path = Yol
shared-directories = Shared directories
shared-directories-description = These directories will be symlinked to directories in your host system
shared-directories = Paylaşılmış dizinler
shared-directories-description = Bu dizinlerden host sisteminizin dizinlerine kısayol oluşturulacaktır
original-path = Original path
new-path = New path
original-path = Orijinal yol
new-path = Yeni yol
read-only = Read-only
read-only-description = Forbid game to write any data to this directory
read-only = Salt-okunur
read-only-description = Oyunun bu dizinde veri oluşturmasını yasakla
symlinks = Symlinks
symlinks-description = Symlink original path to the new one inside of your sandbox
symlinks = Kısayollar
symlinks-description = Orijinal yoldan sanal ortamın içindeki yenisine kısayol oluştur

View file

@ -45,3 +45,11 @@ game-patching-error = 应用游戏补丁失败
# Sandbox
documentation-url-open-failed = Failed to open documentation URL
# Game
game-session-add-failed = Failed to add game session
game-session-update-failed = Failed to update game session
game-session-remove-failed = Failed to remove game session
game-session-set-current-failed = Failed to set current game session
game-session-apply-failed = Failed to apply game session

View file

@ -23,6 +23,11 @@ tos-violation-warning-message =
如果你了解并接受通过非官方许可方式玩这款游戏所带来的风险,请单击“确定”。让我们一直抢过提瓦特大陆吧!
tos-dialog-title = Are you sure you understand what we want to say?
tos-dialog-message =
1. Don't publish any information about this project
2. Don't abuse it by using some modded clients and so
3. Ask questions exceptionally in our discord or matrix server
dependencies = 依赖
missing-dependencies-title = 你缺少某些依赖组件

View file

@ -0,0 +1,7 @@
game-sessions = Game sessions
active-sessions = Active session
active-session-description = Currently selected game session. Updates after each game launch
update-session = Update session using current wine prefix registry values
delete-session = Delete session

View file

@ -22,6 +22,7 @@ continue = 继续
exit = 退出
check = 检查
restart = 重启
agree = Agree
loading-data = 正在加载数据

View file

@ -64,7 +64,8 @@ impl SimpleComponent for AboutDialog {
"Deutsch — @Marie https://github.com/Mar0xy",
"Español — Lautaro Garavano https://github.com/Rattlehead15",
"Français — @zeGolem https://github.com/zeGolem",
"Türk — @Kaozix https://github.com/Kaozix1776",
"Türkçe — @Kaozix https://github.com/Kaozix1776",
"Türkçe — Kayra Nachfolger https://github.com/kayranachfolger",
"简体中文 — Caibin Chen https://github.com/tigersoldier"
].join("\n"),
@ -83,13 +84,25 @@ impl SimpleComponent for AboutDialog {
"<p>Added</p>",
"<ul>",
"<li>Added arguments and symlinks editor to sandbox settings</li>",
"<li>Added rules approving dialog to the first run window</li>",
"<li>Added game settings section</li>",
"<li>Added game sessions manager</li>",
"<li>Added `LAUNCHER_FOLDER` variable support</li>",
"<li>Added patch repository mirror</li>",
"</ul>",
"<p>Changed</p>",
"<ul>",
"<li>Improved launcher logo rendering quality</li>",
"<li>Reworked entry rows in the settings</li>",
"</ul>",
"<p>Fixed</p>",
"<ul>",
"<li>Fixed game running issue if you have spaces in paths</li>",
"<li>Fixed wine tools running using proton builds</li>",
"<li>Fixed sandboxed game running (sounds are broken for now)</li>",
"</ul>",
].join("\n"),*/

View file

@ -213,6 +213,8 @@ impl SimpleComponent for App {
set_visible: model.loading.is_none(),
add = &adw::PreferencesGroup {
set_margin_top: 48,
#[watch]
set_visible: model.style == LauncherStyle::Modern,
@ -521,11 +523,11 @@ impl SimpleComponent for App {
.detach());
}
let group = RelmActionGroup::<WindowActionGroup>::new();
let mut group = RelmActionGroup::<WindowActionGroup>::new();
// TODO: reduce code somehow
group.add_action::<LauncherFolder>(&RelmAction::new_stateless(clone!(@strong sender => move |_| {
group.add_action::<LauncherFolder>(RelmAction::new_stateless(clone!(@strong sender => move |_| {
if let Err(err) = open::that(LAUNCHER_FOLDER.as_path()) {
sender.input(AppMsg::Toast {
title: tr("launcher-folder-opening-error"),
@ -536,7 +538,7 @@ impl SimpleComponent for App {
}
})));
group.add_action::<GameFolder>(&RelmAction::new_stateless(clone!(@strong sender => move |_| {
group.add_action::<GameFolder>(RelmAction::new_stateless(clone!(@strong sender => move |_| {
let path = match Config::get() {
Ok(config) => config.game.path.for_edition(config.launcher.edition).to_path_buf(),
Err(_) => CONFIG.game.path.for_edition(CONFIG.launcher.edition).to_path_buf()
@ -552,7 +554,7 @@ impl SimpleComponent for App {
}
})));
group.add_action::<ConfigFile>(&RelmAction::new_stateless(clone!(@strong sender => move |_| {
group.add_action::<ConfigFile>(RelmAction::new_stateless(clone!(@strong sender => move |_| {
if let Ok(file) = config_file() {
if let Err(err) = open::that(file) {
sender.input(AppMsg::Toast {
@ -565,7 +567,7 @@ impl SimpleComponent for App {
}
})));
group.add_action::<DebugFile>(&RelmAction::new_stateless(clone!(@strong sender => move |_| {
group.add_action::<DebugFile>(RelmAction::new_stateless(clone!(@strong sender => move |_| {
if let Err(err) = open::that(crate::DEBUG_FILE.as_os_str()) {
sender.input(AppMsg::Toast {
title: tr("debug-file-opening-error"),
@ -576,7 +578,7 @@ impl SimpleComponent for App {
}
})));
group.add_action::<WishUrl>(&RelmAction::new_stateless(clone!(@strong sender => move |_| {
group.add_action::<WishUrl>(RelmAction::new_stateless(clone!(@strong sender => move |_| {
std::thread::spawn(clone!(@strong sender => move || {
let config = Config::get().unwrap_or_else(|_| CONFIG.clone());
@ -636,7 +638,7 @@ impl SimpleComponent for App {
}));
})));
group.add_action::<About>(&RelmAction::new_stateless(move |_| {
group.add_action::<About>(RelmAction::new_stateless(move |_| {
about_dialog_broker.send(AboutDialogMsg::Show);
}));
@ -683,10 +685,8 @@ impl SimpleComponent for App {
description: if changes.is_empty() {
None
} else {
let max_len = changes.iter().map(|line| line.len()).max().unwrap_or(80);
Some(changes.into_iter()
.map(|line| format!("- {line}{}", " ".repeat(max_len - line.len())))
.map(|line| format!("- {line}"))
.collect::<Vec<_>>()
.join("\n"))
}

View file

@ -16,10 +16,10 @@ struct Variable {
#[relm4::factory(async)]
impl AsyncFactoryComponent for Variable {
type Init = (String, String);
type Input = EnvironmentMsg;
type Output = EnvironmentMsg;
type Input = EnvironmentAppMsg;
type Output = EnvironmentAppMsg;
type CommandOutput = ();
type ParentInput = EnvironmentMsg;
type ParentInput = EnvironmentAppMsg;
type ParentWidget = adw::PreferencesGroup;
view! {
@ -33,16 +33,12 @@ impl AsyncFactoryComponent for Variable {
set_valign: gtk::Align::Center,
connect_clicked[sender, index] => move |_| {
sender.input(EnvironmentMsg::Remove(index.clone()));
sender.output(EnvironmentAppMsg::Remove(index.clone()));
}
}
}
}
fn output_to_parent_input(output: Self::Output) -> Option<Self::ParentInput> {
Some(output)
}
async fn init_model(
init: Self::Init,
_index: &DynamicIndex,
@ -54,8 +50,8 @@ impl AsyncFactoryComponent for Variable {
}
}
async fn update(&mut self, msg: Self::Input, sender: AsyncFactorySender<Self>) {
sender.output(msg);
fn forward_to_parent(output: Self::Output) -> Option<Self::ParentInput> {
Some(output)
}
}
@ -67,7 +63,7 @@ pub struct EnvironmentApp {
}
#[derive(Debug, Clone)]
pub enum EnvironmentMsg {
pub enum EnvironmentAppMsg {
Add,
Remove(DynamicIndex)
}
@ -75,7 +71,7 @@ pub enum EnvironmentMsg {
#[relm4::component(async, pub)]
impl SimpleAsyncComponent for EnvironmentApp {
type Init = ();
type Input = EnvironmentMsg;
type Input = EnvironmentAppMsg;
type Output = ();
view! {
@ -110,6 +106,20 @@ impl SimpleAsyncComponent for EnvironmentApp {
add = &adw::PreferencesGroup {
set_title: &tr("new-variable"),
#[wrap(Some)]
set_header_suffix = &gtk::Button {
add_css_class: "flat",
set_valign: gtk::Align::Center,
adw::ButtonContent {
set_icon_name: "list-add-symbolic",
set_label: &tr("add")
},
connect_clicked => EnvironmentAppMsg::Add
},
#[local_ref]
name_entry -> adw::EntryRow {
set_title: &tr("name")
@ -118,16 +128,6 @@ impl SimpleAsyncComponent for EnvironmentApp {
#[local_ref]
value_entry -> adw::EntryRow {
set_title: &tr("value")
},
gtk::Button {
set_label: &tr("add"),
add_css_class: "pill",
set_margin_top: 8,
set_halign: gtk::Align::Start,
connect_clicked => EnvironmentMsg::Add
}
},
@ -166,12 +166,12 @@ impl SimpleAsyncComponent for EnvironmentApp {
async fn update(&mut self, msg: Self::Input, _sender: AsyncComponentSender<Self>) {
match msg {
EnvironmentMsg::Add => {
if let Ok(mut config) = Config::get() {
let name = self.name_entry.text().trim().to_string();
let value = self.value_entry.text().trim().to_string();
EnvironmentAppMsg::Add => {
let name = self.name_entry.text().trim().to_string();
let value = self.value_entry.text().trim().to_string();
if !name.is_empty() && !value.is_empty() {
if !name.is_empty() && !value.is_empty() {
if let Ok(mut config) = Config::get() {
self.name_entry.set_text("");
self.value_entry.set_text("");
@ -184,7 +184,7 @@ impl SimpleAsyncComponent for EnvironmentApp {
}
}
EnvironmentMsg::Remove(index) => {
EnvironmentAppMsg::Remove(index) => {
if let Ok(mut config) = Config::get() {
if let Some(var) = self.variables.guard().get(index.current_index()) {
config.game.environment.remove(&var.key);

285
src/ui/preferences/game.rs Normal file
View file

@ -0,0 +1,285 @@
use relm4::prelude::*;
use relm4::component::*;
use relm4::factory::*;
use adw::prelude::*;
use anime_launcher_sdk::sessions::SessionsExt;
use anime_launcher_sdk::genshin::sessions::Sessions;
use super::main::PreferencesAppMsg;
use crate::i18n::tr;
use crate::*;
#[derive(Debug)]
struct GameSession {
name: String,
description: Option<String>
}
#[relm4::factory(async)]
impl AsyncFactoryComponent for GameSession {
type Init = GameSession;
type Input = GameAppMsg;
type Output = GameAppMsg;
type CommandOutput = ();
type ParentInput = GameAppMsg;
type ParentWidget = adw::PreferencesGroup;
view! {
root = adw::ActionRow {
set_title: &self.name,
set_subtitle: match &self.description {
Some(description) => description.as_str(),
None => ""
},
add_suffix = &gtk::Button {
set_icon_name: "view-refresh-symbolic-symbolic",
add_css_class: "flat",
set_tooltip_text: Some(&tr("update-session")),
set_valign: gtk::Align::Center,
connect_clicked[sender, index] => move |_| {
sender.output(GameAppMsg::UpdateSession(index.clone()));
}
},
add_suffix = &gtk::Button {
set_icon_name: "user-trash-symbolic",
add_css_class: "flat",
set_tooltip_text: Some(&tr("delete-session")),
set_valign: gtk::Align::Center,
connect_clicked[sender, index] => move |_| {
sender.output(GameAppMsg::RemoveSession(index.clone()));
}
}
}
}
async fn init_model(
init: Self::Init,
_index: &DynamicIndex,
_sender: AsyncFactorySender<Self>,
) -> Self {
init
}
fn forward_to_parent(output: Self::Output) -> Option<Self::ParentInput> {
Some(output)
}
}
pub struct GameApp {
sessions: AsyncFactoryVecDeque<GameSession>,
sessions_names: Vec<String>,
sessions_combo: adw::ComboRow,
session_name_entry: adw::EntryRow
}
#[derive(Debug, Clone)]
pub enum GameAppMsg {
AddSession,
UpdateSession(DynamicIndex),
RemoveSession(DynamicIndex),
SetCurrent(u32),
UpdateCombo
}
#[relm4::component(async, pub)]
impl SimpleAsyncComponent for GameApp {
type Init = ();
type Input = GameAppMsg;
type Output = PreferencesAppMsg;
view! {
adw::PreferencesPage {
set_title: &tr("game"),
set_icon_name: Some("applications-games-symbolic"),
add = &adw::PreferencesGroup {
set_title: &tr("game-sessions"),
#[local_ref]
sessions_combo -> adw::ComboRow {
set_title: &tr("active-sessions"),
set_subtitle: &tr("active-session-description"),
connect_selected_notify[sender] => move |row| sender.input(GameAppMsg::SetCurrent(row.selected()))
}
},
add = &adw::PreferencesGroup {
#[local_ref]
session_name_entry -> adw::EntryRow {
set_title: &tr("name"),
add_suffix = &gtk::Button {
set_icon_name: "list-add-symbolic",
add_css_class: "flat",
set_valign: gtk::Align::Center,
connect_clicked => GameAppMsg::AddSession
}
}
},
#[local_ref]
add = sessions -> adw::PreferencesGroup {},
}
}
async fn init(
_init: Self::Init,
root: Self::Root,
sender: AsyncComponentSender<Self>,
) -> AsyncComponentParts<Self> {
tracing::info!("Initializing game settings");
let mut model = Self {
sessions: AsyncFactoryVecDeque::new(adw::PreferencesGroup::new(), sender.input_sender()),
sessions_names: Vec::new(),
sessions_combo: adw::ComboRow::new(),
session_name_entry: adw::EntryRow::new()
};
for (name, _) in Sessions::list().unwrap_or_default() {
model.sessions.guard().push_back(GameSession {
name: name.clone(),
description: None
});
}
let sessions = model.sessions.widget();
let sessions_combo = &model.sessions_combo;
let session_name_entry = &model.session_name_entry;
let widgets = view_output!();
sender.input(GameAppMsg::UpdateCombo);
AsyncComponentParts { model, widgets }
}
async fn update(&mut self, msg: Self::Input, sender: AsyncComponentSender<Self>) {
match msg {
GameAppMsg::AddSession => {
let name = self.session_name_entry.text().trim().to_string();
if !name.is_empty() {
if let Ok(config) = Config::get() {
self.session_name_entry.set_text("");
match Sessions::update(name.clone(), config.get_wine_prefix_path()) {
Ok(()) => {
self.sessions.guard().push_back(GameSession {
name,
description: None
});
sender.input(GameAppMsg::UpdateCombo);
}
#[allow(unused_must_use)]
Err(err) => {
sender.output(PreferencesAppMsg::Toast {
title: tr("game-session-add-failed"),
description: Some(err.to_string())
});
}
}
}
}
}
GameAppMsg::UpdateSession(index) => {
if let Some(session) = self.sessions.guard().get(index.current_index()) {
if let Ok(config) = Config::get() {
#[allow(unused_must_use)]
if let Err(err) = Sessions::update(session.name.clone(), config.get_wine_prefix_path()) {
sender.output(PreferencesAppMsg::Toast {
title: tr("game-session-update-failed"),
description: Some(err.to_string())
});
}
}
}
}
GameAppMsg::RemoveSession(index) => {
if let Some(session) = self.sessions.guard().get(index.current_index()) {
match Sessions::remove(&session.name) {
Ok(()) => sender.input(GameAppMsg::UpdateCombo),
#[allow(unused_must_use)]
Err(err) => {
sender.output(PreferencesAppMsg::Toast {
title: tr("game-session-remove-failed"),
description: Some(err.to_string())
});
return;
}
}
}
self.sessions.guard().remove(index.current_index());
}
GameAppMsg::SetCurrent(id) => {
if let Some(name) = self.sessions_names.get(id as usize) {
if let Ok(config) = Config::get() {
#[allow(unused_must_use)]
if let Err(err) = Sessions::set_current(name.to_owned()) {
sender.output(PreferencesAppMsg::Toast {
title: tr("game-session-set-current-failed"),
description: Some(err.to_string())
});
// Prevent session applying
return;
}
#[allow(unused_must_use)]
if let Err(err) = Sessions::apply(name.to_owned(), config.get_wine_prefix_path()) {
sender.output(PreferencesAppMsg::Toast {
title: tr("game-session-apply-failed"),
description: Some(err.to_string())
});
}
}
}
}
GameAppMsg::UpdateCombo => {
let sessions = Sessions::get_sessions().unwrap_or_default();
self.sessions_names = sessions.sessions.into_keys().collect::<Vec<String>>();
let mut selected = 0;
for (i, name) in self.sessions_names.iter().enumerate() {
if sessions.current.as_ref() == Some(name) {
selected = i as u32;
}
}
self.sessions_combo.set_model(Some(&gtk::StringList::new(&self.sessions_names.iter().map(|name: &String| name.as_str()).collect::<Vec<&str>>())));
self.sessions_combo.set_selected(selected);
}
}
}
}

View file

@ -15,6 +15,7 @@ use crate::i18n::tr;
use super::general::*;
use super::enhancements::*;
use super::game::*;
use super::sandbox::*;
use super::environment::*;
@ -23,6 +24,7 @@ pub static mut PREFERENCES_WINDOW: Option<adw::PreferencesWindow> = None;
pub struct PreferencesApp {
general: AsyncController<GeneralApp>,
enhancements: AsyncController<EnhancementsApp>,
game: AsyncController<GameApp>,
sandbox: AsyncController<SandboxApp>,
environment: AsyncController<EnvironmentApp>
}
@ -64,6 +66,7 @@ impl SimpleAsyncComponent for PreferencesApp {
add = model.general.widget(),
add = model.enhancements.widget(),
add = model.game.widget(),
add = model.sandbox.widget(),
add = model.environment.widget(),
@ -96,6 +99,10 @@ impl SimpleAsyncComponent for PreferencesApp {
.launch(())
.detach(),
game: GameApp::builder()
.launch(())
.detach(),
sandbox: SandboxApp::builder()
.launch(())
.forward(sender.input_sender(), std::convert::identity),

View file

@ -1,6 +1,7 @@
pub mod main;
pub mod general;
pub mod enhancements;
pub mod game;
pub mod sandbox;
pub mod environment;
pub mod gamescope;

View file

@ -7,6 +7,7 @@ use adw::prelude::*;
use anime_launcher_sdk::is_available;
use super::main::PreferencesAppMsg;
use crate::i18n::tr;
use crate::*;
@ -41,16 +42,12 @@ macro_rules! impl_directory {
set_valign: gtk::Align::Center,
connect_clicked[sender, index] => move |_| {
sender.input($msg(index.clone()));
sender.output($msg(index.clone()));
}
}
}
}
fn output_to_parent_input(output: Self::Output) -> Option<Self::ParentInput> {
Some(output)
}
async fn init_model(
init: Self::Init,
_index: &DynamicIndex,
@ -62,8 +59,8 @@ macro_rules! impl_directory {
}
}
async fn update(&mut self, msg: Self::Input, sender: AsyncFactorySender<Self>) {
sender.output(msg);
fn forward_to_parent(output: Self::Output) -> Option<Self::ParentInput> {
Some(output)
}
}
}
@ -197,8 +194,10 @@ impl SimpleAsyncComponent for SandboxApp {
},
add_suffix = &gtk::Button {
set_valign: gtk::Align::Center,
set_icon_name: "dialog-information-symbolic",
add_css_class: "flat",
set_valign: gtk::Align::Center,
connect_clicked[sender] => move |_| {
if let Err(err) = open::that("https://man.archlinux.org/man/bwrap.1") {
@ -218,17 +217,16 @@ impl SimpleAsyncComponent for SandboxApp {
#[local_ref]
private_path_entry -> adw::EntryRow {
set_title: &tr("path")
},
set_title: &tr("path"),
gtk::Button {
set_label: &tr("add"),
add_css_class: "pill",
add_suffix = &gtk::Button {
set_icon_name: "list-add-symbolic",
add_css_class: "flat",
set_margin_top: 8,
set_halign: gtk::Align::Start,
set_valign: gtk::Align::Center,
connect_clicked => SandboxAppMsg::AddPrivate
connect_clicked => SandboxAppMsg::AddPrivate
}
}
},
@ -239,6 +237,20 @@ impl SimpleAsyncComponent for SandboxApp {
set_title: &tr("shared-directories"),
set_description: Some(&tr("shared-directories-description")),
#[wrap(Some)]
set_header_suffix = &gtk::Button {
add_css_class: "flat",
set_valign: gtk::Align::Center,
adw::ButtonContent {
set_icon_name: "list-add-symbolic",
set_label: &tr("add")
},
connect_clicked => SandboxAppMsg::AddShared
},
#[local_ref]
shared_path_from_entry -> adw::EntryRow {
set_title: &tr("original-path")
@ -257,16 +269,6 @@ impl SimpleAsyncComponent for SandboxApp {
add_suffix = read_only_switch -> gtk::Switch {
set_valign: gtk::Align::Center
}
},
gtk::Button {
set_label: &tr("add"),
add_css_class: "pill",
set_margin_top: 8,
set_halign: gtk::Align::Start,
connect_clicked => SandboxAppMsg::AddShared
}
},
@ -277,6 +279,20 @@ impl SimpleAsyncComponent for SandboxApp {
set_title: &tr("symlinks"),
set_description: Some(&tr("symlinks-description")),
#[wrap(Some)]
set_header_suffix = &gtk::Button {
add_css_class: "flat",
set_valign: gtk::Align::Center,
adw::ButtonContent {
set_icon_name: "list-add-symbolic",
set_label: &tr("add")
},
connect_clicked => SandboxAppMsg::AddSymlink
},
#[local_ref]
symlink_path_from_entry -> adw::EntryRow {
set_title: &tr("original-path")
@ -285,16 +301,6 @@ impl SimpleAsyncComponent for SandboxApp {
#[local_ref]
symlink_path_to_entry -> adw::EntryRow {
set_title: &tr("new-path")
},
gtk::Button {
set_label: &tr("add"),
add_css_class: "pill",
set_margin_top: 8,
set_halign: gtk::Align::Start,
connect_clicked => SandboxAppMsg::AddSymlink
}
},