Skip to content
This repository has been archived by the owner on Jul 20, 2023. It is now read-only.

Commit

Permalink
small fixes on translations and code formatting.
Browse files Browse the repository at this point in the history
  • Loading branch information
fiatjaf committed Dec 8, 2022
1 parent d0f8d23 commit ff6a08c
Show file tree
Hide file tree
Showing 10 changed files with 35 additions and 35 deletions.
2 changes: 1 addition & 1 deletion app/src/main/res/values-es/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@

<string name="popup_prior_chain_balance"><![CDATA[<b>anterior&#160;saldo</b>&#160;%1$s]]></string>
<string name="popup_ln_fee"><![CDATA[<b>tarifa</b>&#160;%1$s&#160;(%2$s)]]></string>
<string name="popup_fiat"><![CDATA[<b>fiat&#160;valor</b>&#160;%1$s&#160;(%2$s)]]></string>
<string name="popup_fiat"><![CDATA[<b>valor&#160;fiat</b>&#160;%1$s&#160;(%2$s)]]></string>
<string name="popup_chain_fee"><![CDATA[<b>cadena&#160;tarifa</b>&#160;%1$s]]></string>
<string name="popup_hash"><![CDATA[<b>hash</b>&#160;%1$s]]></string>

Expand Down
36 changes: 18 additions & 18 deletions app/src/main/res/values-pt/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -236,20 +236,20 @@
<string name="settings_hw_zpub_tip">Carteira de hardware ou zpub</string>

<string name="settings_chain_wallets">Gerenciar carteiras chain</string>
<string name="settings_chain_legacy">Carteira legacy</string>
<string name="settings_chain_legacy">Carteira antiga</string>
<string name="settings_chain_modern">Carteira moderna</string>

<string name="settings_use_auth">Use PIN authentication</string>
<string name="settings_use_auth">Bloquear com PIN</string>
<string name="settings_ensure_tor">Aplicar conexão Tor</string>

<string name="ln_fee_expensive_omitted">O pagamento falhou porque as rotas mais caras foram descartadas. Gostaria de tentar novamente pagando mais em taxas?</string>
<string name="ln_sync_not_complete">A sincronização de canais ainda não terminou, por favor agüarde um pouco mais com o aplicativo aberto.</string>
<string name="ln_payee_likely_offline">Parece que o recipiente deste pagamento está offline agora</string>

<string name="settings_btc_unit">Unidade de bitcoin</string>
<string name="settings_fiat_currency">Moeda fiduciária</string>
<string name="settings_btc_unit">Unidade de Bitcoin</string>
<string name="settings_fiat_currency">Moeda governamental</string>
<string name="settings_custom_electrum_host_port">host:port</string>
<string name="settings_custom_electrum_disabled">Node Electrum personalizado</string>
<string name="settings_custom_electrum_disabled">Servidor Electrum personalizado</string>
<string name="settings_custom_electrum_enabled">Usando node Electrum personalizado</string>
<string name="settings_custom_electrum_disabled_tip">Usando nodes aleatórios no momento</string>
<string name="settings_custom_electrum_restart_notice">Reinicie para aplicar as alterações</string>
Expand All @@ -261,23 +261,23 @@
<!-- /Settings activity -->

<array name="parts_in_flight">
<item>preparing</item>
<item>%1$d part in-flight</item>
<item>%1$d parts in-flight</item>
<item>preparando</item>
<item>%1$d parte pendente</item>
<item>%1$d partes pendentes</item>
</array>

<array name="pct_collected">
<item>waiting</item>
<item>%1$d\%% collected</item>
<item>%1$d\%% collected</item>
<item>finalizing</item>
<item>esperando</item>
<item>%1$d\%% recebido</item>
<item>%1$d\%% recebido</item>
<item>finalizando</item>
</array>

<array name="in_blocks">
<item>waiting</item>
<item>%1$d block</item>
<item>%1$d blocks</item>
<item>%1$d+ blocks</item>
<item>esperando</item>
<item>%1$d bloco</item>
<item>%1$d blocos</item>
<item>%1$d+ blocos</item>
</array>

<array name="expires_in_blocks">
Expand All @@ -297,8 +297,8 @@
<string name="dialog_lnurl_sending"><![CDATA[Enviando %1$s<br><br><b>%2$s</b>]]></string>
<string name="dialog_lnurl_from_vendor"><![CDATA[Resposta do fornecedor%1$s]]></string>

<string name="popup_hold">Hold up to %1$s minutes</string>
<string name="popup_identity">Attach wallet identity</string>
<string name="popup_hold">Segurar por até %1$s minutos</string>
<string name="popup_identity">Incluir identificação</string>

<!-- lnurl-auth -->

Expand Down
2 changes: 1 addition & 1 deletion app/src/main/res/values-ru/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@
<string name="dialog_lnurl_from_vendor"><![CDATA[Ответ от продавца%1$s]]></string>

<string name="popup_hold">Держать до %1$s минут</string>
<string name="popup_identity">Attach wallet identity</string>
<string name="popup_identity">Attach identity</string>

<!-- lnurl-auth -->
<string name="lnurl_auth_login">Логин</string>
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@
<string name="dialog_lnurl_from_vendor"><![CDATA[Response from vendor%1$s]]></string>

<string name="popup_hold">Hold up to %1$s minutes</string>
<string name="popup_identity">Attach wallet identity</string>
<string name="popup_identity">Attach identity</string>

<!-- lnurl-auth -->
<string name="lnurl_auth_login">Login</string>
Expand Down
8 changes: 4 additions & 4 deletions app/src/main/scala/BaseActivity.scala
Original file line number Diff line number Diff line change
Expand Up @@ -1108,10 +1108,10 @@ trait BaseActivity extends AppCompatActivity { self =>
getString(R.string.dialog_up_to).format(canSendHuman).html
)

manager.inputAmount addTextChangedListener onTextChange { _ =>
manager.inputAmount.addTextChangedListener(onTextChange { _ =>
updatePopupButton(getNeutralButton(alert), isNeutralEnabled)
updatePopupButton(getPositiveButton(alert), isPayEnabled)
}
})

def neutral(alert: AlertDialog): Unit
def send(alert: AlertDialog): Unit
Expand Down Expand Up @@ -1241,14 +1241,14 @@ trait BaseActivity extends AppCompatActivity { self =>
)
}

manager.inputAmount addTextChangedListener onTextChange { _ =>
manager.inputAmount.addTextChangedListener(onTextChange { _ =>
val withinBounds =
finalMinReceivable <= manager.resultMsat && finalMaxReceivable >= manager.resultMsat
updatePopupButton(
button = getPositiveButton(alert),
isEnabled = withinBounds
)
}
})

manager.hintFiatDenom.setText(
getString(R.string.dialog_up_to).format(canReceiveFiatHuman).html
Expand Down
5 changes: 3 additions & 2 deletions app/src/main/scala/HubActivity.scala
Original file line number Diff line number Diff line change
Expand Up @@ -1202,6 +1202,7 @@ class HubActivity
// .parsedWithSign(info.balanceSnapshot),
// R.drawable.border_white
// )

if (info.isIncoming && info.status == PaymentStatus.PENDING)
addFlowChip(
extraInfo,
Expand Down Expand Up @@ -2746,7 +2747,7 @@ class HubActivity

def proceed(alert: AlertDialog): Unit = runAnd(alert.dismiss) {
runInFutureProcessOnUI(
InputParser recordValue extraInput.getText.toString,
InputParser.recordValue(extraInput.getText.toString),
onFail
) { _ =>
def attemptProcessInput(): Unit =
Expand Down Expand Up @@ -3355,7 +3356,7 @@ class HubActivity
override val alert: AlertDialog = {
val text = getString(R.string.dialog_lnurl_pay).format(
data.callbackUrl.hostOption.get.value,
s"<br><br>${data.meta.textShort}"
s"<br><br>${data.meta.textShort.getOrElse("")}"
)
val title = titleBodyAsViewBuilder(
text.asColoredView(R.color.ourPurple),
Expand Down
4 changes: 2 additions & 2 deletions app/src/main/scala/RemotePeerActivity.scala
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ object RemotePeerActivity {
def implantNewChannel(cs: Commitments, freshChannel: Channel): Unit = {
// Make an immediate channel backup if anything goes wrong next
// At this point channel has saved itself in the database
WalletApp.immediatelySaveBackup()
WalletApp.immediatelySaveBackup

LNParams.cm.pf.process(PathFinder.CMDStartPeriodicResync)
LNParams.cm.all += Tuple2(cs.channelId, freshChannel)
Expand Down Expand Up @@ -397,7 +397,7 @@ class RemotePeerActivity
feeOpt = Some(res.fee.toMilliSatoshi),
showIssue = false
)
case Failure(exc) =>
case Failure(_) =>
update(
feeOpt = None,
showIssue =
Expand Down
5 changes: 2 additions & 3 deletions app/src/main/scala/SettingsActivity.scala
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package wtf.nbd.obw

import scala.util.Success
import android.content.Intent
import android.os.Bundle
import android.view.{View, ViewGroup}
Expand All @@ -22,8 +23,6 @@ import immortan.crypto.Tools._
import immortan.utils.{BtcDenomination, SatDenomination}
import immortan.{ChannelMaster, LNParams}

import scala.util.Success

abstract class SettingsHolder(host: BaseActivity) {
lazy val view: RelativeLayout = host.getLayoutInflater
.inflate(R.layout.frag_switch, null, false)
Expand Down Expand Up @@ -94,7 +93,7 @@ class SettingsActivity
def updateView(): Unit = {
val backupAllowed = LocalBackup.isAllowed(context = WalletApp.app)
if (backupAllowed && LNParams.cm.all.nonEmpty)
WalletApp.immediatelySaveBackup()
WalletApp.immediatelySaveBackup
val title =
if (backupAllowed) R.string.settings_backup_enabled
else R.string.settings_backup_disabled
Expand Down
4 changes: 2 additions & 2 deletions app/src/main/scala/SetupActivity.scala
Original file line number Diff line number Diff line change
Expand Up @@ -128,9 +128,9 @@ class SetupActivity extends BaseActivity {
WalletApp.saveBackup(())
proceedWithMnemonics(mnemonics)

case Failure(exception) =>
case Failure(exc) =>
val msg = getString(R.string.error_could_not_decrypt)
onFail(msg format exception.getMessage)
onFail(msg.format(exc.getMessage))
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/scala/WalletApp.scala
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ object WalletApp {
catch none
}
})
val saveBackup = debounce[Unit](_ => immediatelySaveBackup(), 4.seconds)
val saveBackup = debounce[Unit](_ => immediatelySaveBackup, 4.seconds)

final val FIAT_CODE = "fiatCode"
final val BTC_DENOM = "btcDenom"
Expand Down

0 comments on commit ff6a08c

Please sign in to comment.