Commit ed035c4c authored by pokkst's avatar pokkst

Reformat code

parent da5ee001
......@@ -2,12 +2,11 @@ package app.crescentcash.src.activity
import android.content.Intent
import android.os.Bundle
import android.provider.ContactsContract
import android.text.Editable
import android.text.TextUtils
import android.text.TextWatcher
import android.view.View
import android.widget.*
import android.widget.Button
import android.widget.EditText
import android.widget.Switch
import androidx.appcompat.app.AppCompatActivity
import app.crescentcash.src.R
import app.crescentcash.src.manager.UIManager
......
......@@ -7,7 +7,9 @@ import android.text.TextUtils
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import android.widget.*
import android.widget.ImageView
import android.widget.SimpleAdapter
import android.widget.TextView
import androidx.appcompat.app.AppCompatActivity
import androidx.swiperefreshlayout.widget.SwipeRefreshLayout
import app.crescentcash.src.R
......
......@@ -7,7 +7,6 @@ import android.text.TextUtils
import android.view.View
import android.widget.*
import androidx.appcompat.app.AppCompatActivity
import androidx.lifecycle.Observer
import androidx.localbroadcastmanager.content.LocalBroadcastManager
import app.crescentcash.src.R
import app.crescentcash.src.listener.RecipientTextListener
......
......@@ -231,7 +231,7 @@ class SettingsActivity : AppCompatActivity() {
override fun onTextChanged(s: CharSequence?, start: Int, before: Int, count: Int) {}
override fun afterTextChanged(s: Editable?) {
if(autoSendAmount.text.toString().isEmpty()) {
if (autoSendAmount.text.toString().isEmpty()) {
WalletManager.maximumAutomaticSend = 0.0f
PrefsUtil.prefs.edit().putFloat("maximumAutomaticSend", WalletManager.maximumAutomaticSend).apply()
} else {
......
......@@ -3,7 +3,9 @@ package app.crescentcash.src.activity
import android.content.Intent
import android.os.Bundle
import android.text.TextUtils
import android.widget.*
import android.widget.Button
import android.widget.EditText
import android.widget.ImageView
import androidx.appcompat.app.AppCompatActivity
import app.crescentcash.src.R
import app.crescentcash.src.manager.UIManager
......
......@@ -48,7 +48,7 @@ class AsyncTaskVerifyWallet(val activity: MainActivity, val tempWallet: Wallet,
val isAddressMine = result!!
if (isAddressMine) {
WalletManager.setupSLPWallet(activity, seedStr, true)
WalletManager.setupWalletKit(activity as MainActivity, seed, cashAcctName, true)
WalletManager.setupWalletKit(activity, seed, cashAcctName, true)
val pref = PrefsUtil.prefs.edit()
pref.putString("cashAccount", cashAcctName)
pref.putString("cashEmoji", cashAcctEmoji)
......
......@@ -550,7 +550,6 @@ class NetManager {
}
private fun getEntropy(random: SecureRandom): ByteArray {
val seed = ByteArray(DeterministicSeed.DEFAULT_SEED_ENTROPY_BITS / 8)
random.nextBytes(seed)
......
......@@ -3,8 +3,8 @@ package app.crescentcash.src.manager
import android.app.Activity
import android.content.Context
import android.content.Intent
import android.graphics.Color
import android.media.MediaPlayer
import android.os.Build
import android.text.method.LinkMovementMethod
import android.view.View
import android.widget.TextView
......@@ -15,9 +15,6 @@ import app.crescentcash.src.qr.QRHelper
import java.text.DecimalFormat
import java.text.DecimalFormatSymbols
import java.util.*
import android.view.WindowManager
import android.view.WindowManager.LayoutParams.FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS
import android.os.Build
class UIManager {
companion object {
......@@ -57,7 +54,7 @@ class UIManager {
val decorView = activity.window.decorView
val window = activity.window
if(this.nightModeEnabled) {
if (this.nightModeEnabled) {
var flags = decorView.systemUiVisibility
flags = flags and View.SYSTEM_UI_FLAG_LIGHT_STATUS_BAR.inv()
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment