Commit 89758fd9 authored by cfabio's avatar cfabio

Fix a bug in Add Custom Coin page

parent b45faaae
......@@ -7,8 +7,8 @@ android {
applicationId "eu.uwot.fabio.altcoinprices"
minSdkVersion 14
targetSdkVersion 28
versionCode 74
versionName '1.6.18'
versionCode 75
versionName '1.6.19'
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
......
[{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":74,"versionName":"1.6.18","enabled":true,"outputFile":"AltcoinPrices-fdroid-release.apk","fullName":"fdroidRelease","baseName":"fdroid-release"},"path":"AltcoinPrices-fdroid-release.apk","properties":{}}]
\ No newline at end of file
[{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":75,"versionName":"1.6.19","enabled":true,"outputFile":"AltcoinPrices-fdroid-release.apk","fullName":"fdroidRelease","baseName":"fdroid-release"},"path":"AltcoinPrices-fdroid-release.apk","properties":{}}]
\ No newline at end of file
[{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":74,"versionName":"1.6.18","enabled":true,"outputFile":"AltcoinPrices-googlePlayStore-release.apk","fullName":"googlePlayStoreRelease","baseName":"googlePlayStore-release"},"path":"AltcoinPrices-googlePlayStore-release.apk","properties":{}}]
\ No newline at end of file
[{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":75,"versionName":"1.6.19","enabled":true,"outputFile":"AltcoinPrices-googlePlayStore-release.apk","fullName":"googlePlayStoreRelease","baseName":"googlePlayStore-release"},"path":"AltcoinPrices-googlePlayStore-release.apk","properties":{}}]
\ No newline at end of file
......@@ -6,6 +6,7 @@ import android.content.SharedPreferences;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.text.InputFilter;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
......
......@@ -5,6 +5,7 @@ import android.content.SharedPreferences;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.text.InputFilter;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
......@@ -56,6 +57,8 @@ public class EditCustomCoinActivity extends AppCompatActivity {
altcoinSymbol_text = findViewById(R.id.altcoinSymbol_text);
altcoinSymbol_text.setFilters(new InputFilter[] {new InputFilter.AllCaps()});
altcoinSymbol_text.setText(altcoinSymbol);
altcoinSymbol_text.setTextColor(R.color.colorTextSeconday);
altcoinSymbol_text.setEnabled(false);
tradingviewExchangeName_text = findViewById(R.id.tradingviewExchangeName_text);
tradingviewExchangeName_text.setText(tradingviewExchangeName);
tradingviewTradingPair_text = findViewById(R.id.tradingviewTradingPair_text);
......@@ -78,13 +81,9 @@ public class EditCustomCoinActivity extends AppCompatActivity {
public void run() {
getCoinData();
if ((noErrors) && (!altcoinSymbol.equals(altcoinSymbolInitial))) {
if (noErrors) {
editCustomCoin();
startActivity(new Intent(getApplicationContext(), ManageCustomCoinsActivity.class));
} else if (!noErrors) {
Toast.makeText(getApplicationContext(), R.string.errorCoinNotFound, Toast.LENGTH_SHORT).show();
} else {
startActivity(new Intent(getApplicationContext(), ManageCustomCoinsActivity.class));
}
}
};
......@@ -191,6 +190,11 @@ public class EditCustomCoinActivity extends AppCompatActivity {
tradingviewTradingPair = "na";
}
Log.d("DEBUG", "altcoinSymbol: " + altcoinSymbol);
Log.d("DEBUG", "altcoinDescription: " + altcoinDescription);
Log.d("DEBUG", "tradingviewExchangeName: " + tradingviewExchangeName);
Log.d("DEBUG", "tradingviewTradingPair: " + tradingviewTradingPair);
// Create new coin JSON array
try {
newCustomCoin.put("altcoinSymbol", altcoinSymbol);
......
......@@ -45,11 +45,11 @@
android:id="@+id/altcoinSymbol_text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="8dp"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp"
android:layout_marginStart="8dp"
android:layout_marginLeft="8dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="8dp"
android:layout_marginRight="8dp"
android:hint="@string/altcoinSymbol_text"
android:inputType="text"
android:minWidth="@dimen/user_input_text_fields_min_width"
......
# CHANGELOG
### Version 1.6.19
* Fix a bug in Add Custom Coin page
### Version 1.6.18
* Add ability to enter a custom CryptoCompare API key in settings
......
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