From 5481587167421cdfac1b98f4c0bd4beddc2e9449 Mon Sep 17 00:00:00 2001 From: "NGnius (Graham)" Date: Sun, 29 Jan 2023 11:09:42 -0500 Subject: [PATCH] Fix missing translation for Defaults button --- backend/Cargo.lock | 2 +- backend/Cargo.toml | 2 +- backend/src/settings/steam_deck/util.rs | 10 ++++++++++ package.json | 2 +- src/index.tsx | 2 +- translations/es-ES.mo | Bin 2450 -> 2523 bytes translations/es-ES.po | 5 +++++ translations/fr-CA.mo | Bin 2620 -> 2689 bytes translations/fr-CA.po | 5 +++++ translations/pt.pot | 5 +++++ 10 files changed, 29 insertions(+), 4 deletions(-) diff --git a/backend/Cargo.lock b/backend/Cargo.lock index dac5d74..9416cdc 100644 --- a/backend/Cargo.lock +++ b/backend/Cargo.lock @@ -826,7 +826,7 @@ dependencies = [ [[package]] name = "powertools-rs" -version = "1.1.0-beta4" +version = "1.1.0-beta5" dependencies = [ "async-trait", "limits_core", diff --git a/backend/Cargo.toml b/backend/Cargo.toml index edd666a..4d4db5e 100644 --- a/backend/Cargo.toml +++ b/backend/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "powertools-rs" -version = "1.1.0-beta4" +version = "1.1.0-beta5" edition = "2021" authors = ["NGnius (Graham) "] description = "Backend (superuser) functionality for PowerTools" diff --git a/backend/src/settings/steam_deck/util.rs b/backend/src/settings/steam_deck/util.rs index 1d89d1c..def76e9 100644 --- a/backend/src/settings/steam_deck/util.rs +++ b/backend/src/settings/steam_deck/util.rs @@ -1,4 +1,5 @@ //! Rough Rust port of some BatCtrl functionality +//! Original: /usr/share/jupiter_controller_fw_updater/RA_bootloader_updater/linux_host_tools/BatCtrl //! I do not have access to the source code, so this is my own interpretation of what it does. //! //! But also Quanta is based in a place with some questionable copyright practices, so... @@ -95,11 +96,20 @@ pub fn set(setting: Setting, mode: u8) -> Result { #[derive(Copy, Clone)] #[repr(u8)] pub enum Setting { + CycleCount = 0x32, + ControlBoard = 0x6C, Charge = 0xA6, ChargeMode = 0x76, LEDStatus = 199, } +#[derive(Copy, Clone, Debug)] +#[repr(u8)] +pub enum ControlBoard { + Enable = 0xAA, + Disable = 0xAB, +} + #[derive(Copy, Clone, Debug)] #[repr(u8)] pub enum ChargeMode { diff --git a/package.json b/package.json index 847547a..1fad640 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "PowerTools", - "version": "1.1.0-beta4", + "version": "1.1.0-beta5", "description": "Power tweaks for power users", "scripts": { "build": "shx rm -rf dist && rollup -c", diff --git a/src/index.tsx b/src/index.tsx index 04cd538..8dd8cd1 100755 --- a/src/index.tsx +++ b/src/index.tsx @@ -263,7 +263,7 @@ const Content: VFC<{ serverAPI: ServerAPI }> = ({}) => { ); }} > - Defaults + {tr("Defaults")} diff --git a/translations/es-ES.mo b/translations/es-ES.mo index 40ddd41615c4c8e89364cbc1524361c36b4d4bb2..ea096f8ec30ae58b4c3e12e03bc29b8d6d651413 100644 GIT binary patch delta 975 zcmZwGKS*0q6vy$C#G1tZu^Q7<`^RYNpNK@dw4#U|q(i3)qJx7C>HlHBSTH#1xjA z<*l2GY6hNS9ABU&n!$Vc&i%fOVfve>33iYi_7gSnAzs5HypI1|KSXx*qs|2KlRd;z z^4lXW^k7$U!0Z`nLA_XpFHs3!qjvNbm3R*8v4DF1E9$uo)CTrZ_y5Lns(ON2sE@%` zEW;4_?J*ac@ClY<4=QmVw&M_L=Znb4miUU{7mVOKD&a2bC=Rd%|GM!6Ss&1E!#MV# z=9|L&EiUq0XaNhT#Gg<*`iv^ws_TDq{Vi0&Jya=wA!liS@CKf`zMm{g97f%rLM^ZZ zb^r4)^;hBn29h|4D)lU?L<^_~H=H|2C5u&1sn0_%t`?%rRM2W@s-!{*6`Dt(m-7xS zp^na9Z?(=bslE#>f?UN_R=F`%M!UHz*ziT@NEF(bs-dH5pef=sRrWTG*TI^!a{bfp z)0$~|<11+@dtG5H@IL4br>90Ib8BaT=|HSMJvyHCa`B0*m+>aO?AXYwbY?ua_9j^4 F{|{JFPRjrQ delta 914 zcmZA0KP+TX6vy$y41*an%wWy>H;jKPLPa*4Z4}B$XjBu4e-VwCh8V>(=rn_ZY$Qk& zB2i33qL8h2yX^#t3hjnQCGq_|w-7h)ywAID?!0sFx$oV^^0C}q)W2=CZlaM$7nu#< zuVPNL1)o_NX0Qdb7{FcRumeuDc!WW`z)t*w8uuSd@CB>z6-zPfH;bF)td@%eH~LWz z7{Mk?zYnl1meb!tJzx)chMl4&R=^NmU?u)_{VUhMcRnMBHycf$gjt2iZy_#pBaY0- z5?FyhPzi@oD;Yy29>+GEL?vEB{V$JNzzJ&n8Ahn)C2FGoNYabfsD3GfeB`$X7ZHr1 z5-0IH_MuijiyW5W6vJgyq778(cd!Rf-TfPEr~ilv43bUH>BTx6L@gwRIVBwBLMut5 zN;v2GORm3)N|;BLa1T|nLk#1w>z|_%U!ul8peFd_eh)AUB@W{^jFwY>mG~z&RGJj( zk6GtBQbF(KY{0LC9;l=VLX%fZ64iuWP&M*-&D(FTv|U)%n!A=ywn`gtnrY(95dr>m)S!DDkoBtJ11fF;&O=u!g1=C+4SSrZ@L}YlVLQ Lim&iH5HEfM4$eRS diff --git a/translations/es-ES.po b/translations/es-ES.po index aef82f0..9477cf9 100644 --- a/translations/es-ES.po +++ b/translations/es-ES.po @@ -39,6 +39,11 @@ msgstr "Guardar perfil y cargarlo la próxima vez" msgid "Profile" msgstr "Perfil" +#: index.tsx:266 +# (Button to reset everything to system defaults) +msgid "Defaults" +msgstr "Valores predeterminados" + # -- components/battery.tsx -- #: components/battery.tsx:42 diff --git a/translations/fr-CA.mo b/translations/fr-CA.mo index caf046af18732111b5fb34f23bd28698dbff11fa..3303e114c921b5f55ebca2c2f90115b49838ca86 100644 GIT binary patch delta 971 zcmZY8&r8#B9LMpuo4RRBOR1Sg1C+`e2W3xMt=5%OBna?3|8<8{zARiRd3dSG1NE-Y{To= zXqLALDi^qM2R(d<8mNGmaMeBEz$V%|r~&qoIqW-X;0lKD7|-H~YX_NK?XWYBJhBmN zWPTf?qK@O$8)lQJ1>M7De1w|t32H|xsEJ=3*fyda5b!?whS_H3Ruk$WyASXD6~O^#!=|w zyhw?wq4U>Qt#cey+l9`XwN!Vh6)TwAE>~-(FWPM_v>}Bus$=Y;Bq$1xqD<=8l(BxT zT>rEl$^b=QyfUEl_pUwmzY1h#(~H@KT=Ad(v%h0Hoy{!H=e)V}yf;&R&!dInr$E8? EACQJkyZ`_I delta 914 zcmZA0%PT}-7{~F48JA(kb;flt?g}Y|vO+0K601qMZG}SF49Y*?l9Ed-ETqJ2EGF3@ zYuU((jg4YqHRby|&O+YKb3W%iopavjdES}TP$C$6De!I^qlpL;(G;@|+)L%enDv-t z;v81tGG^c|a@aAa5T0N*Ca?kTP|tl}8h&FQCNUjzyk@0lF$-}K;YJ(k1A|zB(ccGb z8GX#RP#-uzzG3I6#Nz131P1WlojL7_7Qrm+MlINn zs$>+k@EF$M1Zv@R)O#DK0?ts+U*Ry_ym9A2ZZ>m2j7od}J*;m-T&VRUn1l1E?N~() zJLRMfTw)0(PzgU`3qHI0_^J}<#CGh%MqI!`+(&KI1*(u+jOm33F4Vdw*EdvUU+!G1 zJ9~y|VF)S8%CHC{$fMSUo!Eow;1ULL4aw1VP>CF(o{RhFe*qWo+-SulDxqfH)^Ew=RFJx-#FdP;HlY32-f5^34RWwzqFR%G zL+z|5RFx{JB=lp=B^n4NuY&##ZLQj^4%QLQAFFq2aeQWSdTR5?vmS5rUVGvxnJcM3 DGG#%9 diff --git a/translations/fr-CA.po b/translations/fr-CA.po index 9c38d83..cbc62df 100644 --- a/translations/fr-CA.po +++ b/translations/fr-CA.po @@ -39,6 +39,11 @@ msgstr "Sauvegarder le profile et le charger la prochaine fois" msgid "Profile" msgstr "Profile" +# (Button to reset everything to system defaults) +#: index.tsx:266 +msgid "Defaults" +msgstr "Valeurs par défaut" + # -- components/battery.tsx -- # (Battery section title) #: components/battery.tsx:42 diff --git a/translations/pt.pot b/translations/pt.pot index 44e2e02..be9b1ee 100644 --- a/translations/pt.pot +++ b/translations/pt.pot @@ -37,6 +37,11 @@ msgstr "" msgid "Profile" msgstr "" +#: index.tsx:266 +# (Button to reset everything to system defaults) +msgid "Defaults" +msgstr "" + # -- components/battery.tsx -- #: components/battery.tsx:42