Updated on 2026-08-14
This commit is contained in:
parent
ebd194dcc8
commit
c64fb378ea
5 changed files with 35 additions and 18 deletions
BIN
.idea/caches/build_file_checksums.ser
generated
BIN
.idea/caches/build_file_checksums.ser
generated
Binary file not shown.
|
|
@ -2,6 +2,26 @@ apply plugin: 'com.android.application'
|
||||||
apply plugin: 'kotlin-android'
|
apply plugin: 'kotlin-android'
|
||||||
apply plugin: 'kotlin-android-extensions'
|
apply plugin: 'kotlin-android-extensions'
|
||||||
|
|
||||||
|
//ext {
|
||||||
|
// git = org.ajoberstar.grgit.Grgit.open()
|
||||||
|
// gitVersionCode = git.tag.list().size()
|
||||||
|
// gitVersionName = "${git.describe()}"
|
||||||
|
//}
|
||||||
|
|
||||||
|
def getVersionCode = { ->
|
||||||
|
try {
|
||||||
|
def code = new ByteArrayOutputStream()
|
||||||
|
exec {
|
||||||
|
commandLine 'git', 'tag', '--list'
|
||||||
|
standardOutput = code
|
||||||
|
}
|
||||||
|
return code.toString().split("\n").size()
|
||||||
|
}
|
||||||
|
catch (ignored) {
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdkVersion 27
|
compileSdkVersion 27
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
|
|
@ -9,7 +29,7 @@ android {
|
||||||
minSdkVersion 21
|
minSdkVersion 21
|
||||||
targetSdkVersion 27
|
targetSdkVersion 27
|
||||||
versionCode 26
|
versionCode 26
|
||||||
versionName "0.85.5.831"
|
versionName "0.85.5.831 " + getVersionCode
|
||||||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -17,12 +17,10 @@ import com.tangem.wallet.R;
|
||||||
public class LogoActivity extends AppCompatActivity {
|
public class LogoActivity extends AppCompatActivity {
|
||||||
public static final String TAG = LogoActivity.class.getSimpleName();
|
public static final String TAG = LogoActivity.class.getSimpleName();
|
||||||
|
|
||||||
private final Runnable mHideRunnable = new Runnable() {
|
public static final String EXTRA_AUTO_HIDE = "extra_auto_hide";
|
||||||
@Override
|
public static final int MILLIS_AUTO_HIDE = 1000;
|
||||||
public void run() {
|
|
||||||
hide();
|
private final Runnable mHideRunnable = this::hide;
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
private ImageView imgLogo;
|
private ImageView imgLogo;
|
||||||
|
|
||||||
|
|
@ -50,9 +48,9 @@ public class LogoActivity extends AppCompatActivity {
|
||||||
else
|
else
|
||||||
AppVersion.setText("BETA v." + BuildConfig.VERSION_NAME);
|
AppVersion.setText("BETA v." + BuildConfig.VERSION_NAME);
|
||||||
|
|
||||||
if (!getIntent().getBooleanExtra("skipAutoHide", false)) {
|
|
||||||
delayedHide(1000);
|
if (getIntent().getBooleanExtra(EXTRA_AUTO_HIDE, true))
|
||||||
}
|
delayedHide();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void hide() {
|
private void hide() {
|
||||||
|
|
@ -61,12 +59,9 @@ public class LogoActivity extends AppCompatActivity {
|
||||||
finish();
|
finish();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
private void delayedHide() {
|
||||||
* Schedules a call to hide() in [delay] milliseconds, canceling any
|
// imgLogo.removeCallbacks(mHideRunnable);
|
||||||
* previously scheduled calls.
|
imgLogo.postDelayed(mHideRunnable, MILLIS_AUTO_HIDE);
|
||||||
*/
|
|
||||||
private void delayedHide(int delayMillis) {
|
|
||||||
//imgLogo.removeCallbacks(mHideRunnable);
|
|
||||||
imgLogo.postDelayed(mHideRunnable, delayMillis);
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
}
|
||||||
|
|
@ -332,6 +332,7 @@ public class MainActivity extends AppCompatActivity implements PopupMenu.OnMenuI
|
||||||
private void showLogoActivity() {
|
private void showLogoActivity() {
|
||||||
Intent intent = new Intent(getBaseContext(), LogoActivity.class);
|
Intent intent = new Intent(getBaseContext(), LogoActivity.class);
|
||||||
intent.putExtra(LogoActivity.TAG, true);
|
intent.putExtra(LogoActivity.TAG, true);
|
||||||
|
intent.putExtra(LogoActivity.EXTRA_AUTO_HIDE, false);
|
||||||
startActivity(intent);
|
startActivity(intent);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
buildscript {
|
buildscript {
|
||||||
|
|
||||||
ext.kotlin_version = '1.2.41'
|
ext.kotlin_version = '1.2.41'
|
||||||
repositories {
|
repositories {
|
||||||
google()
|
google()
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue