Started activity and icon
1
app/.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
/build
|
30
app/build.gradle
Normal file
@ -0,0 +1,30 @@
|
||||
apply plugin: 'com.android.application'
|
||||
|
||||
android {
|
||||
compileSdkVersion 25
|
||||
buildToolsVersion "25.0.1"
|
||||
defaultConfig {
|
||||
applicationId "leszcz_team.wulkanowy"
|
||||
minSdkVersion 14
|
||||
targetSdkVersion 25
|
||||
versionCode 1
|
||||
versionName "1.0"
|
||||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compile fileTree(dir: 'libs', include: ['*.jar'])
|
||||
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
|
||||
exclude group: 'com.android.support', module: 'support-annotations'
|
||||
})
|
||||
compile 'com.android.support:appcompat-v7:25.1.1'
|
||||
compile 'com.android.support.constraint:constraint-layout:1.0.2'
|
||||
testCompile 'junit:junit:4.12'
|
||||
}
|
25
app/proguard-rules.pro
vendored
Normal file
@ -0,0 +1,25 @@
|
||||
# Add project specific ProGuard rules here.
|
||||
# By default, the flags in this file are appended to flags specified
|
||||
# in C:\Users\RicomenPL\AppData\Local\Android\Sdk/tools/proguard/proguard-android.txt
|
||||
# You can edit the include path and order by changing the proguardFiles
|
||||
# directive in build.gradle.
|
||||
#
|
||||
# For more details, see
|
||||
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||
|
||||
# Add any project specific keep options here:
|
||||
|
||||
# If your project uses WebView with JS, uncomment the following
|
||||
# and specify the fully qualified class name to the JavaScript interface
|
||||
# class:
|
||||
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||
# public *;
|
||||
#}
|
||||
|
||||
# Uncomment this to preserve the line number information for
|
||||
# debugging stack traces.
|
||||
#-keepattributes SourceFile,LineNumberTable
|
||||
|
||||
# If you keep the line number information, uncomment this to
|
||||
# hide the original source file name.
|
||||
#-renamesourcefileattribute SourceFile
|
@ -0,0 +1,26 @@
|
||||
package leszcz_team.wulkanowy;
|
||||
|
||||
import android.content.Context;
|
||||
import android.support.test.InstrumentationRegistry;
|
||||
import android.support.test.runner.AndroidJUnit4;
|
||||
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
|
||||
import static org.junit.Assert.*;
|
||||
|
||||
/**
|
||||
* Instrumentation test, which will execute on an Android device.
|
||||
*
|
||||
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||
*/
|
||||
@RunWith(AndroidJUnit4.class)
|
||||
public class ExampleInstrumentedTest {
|
||||
@Test
|
||||
public void useAppContext() throws Exception {
|
||||
// Context of the app under test.
|
||||
Context appContext = InstrumentationRegistry.getTargetContext();
|
||||
|
||||
assertEquals("leszcz_team.wulkanowy", appContext.getPackageName());
|
||||
}
|
||||
}
|
22
app/src/main/AndroidManifest.xml
Normal file
@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="leszcz_team.wulkanowy">
|
||||
|
||||
<application
|
||||
android:allowBackup="true"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:label="@string/app_name"
|
||||
android:roundIcon="@mipmap/ic_launcher_round"
|
||||
android:supportsRtl="true"
|
||||
android:theme="@android:style/Theme.DeviceDefault.NoActionBar.Fullscreen">
|
||||
<activity android:name=".activity.started.StartedActivity">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
</intent-filter>
|
||||
</activity>
|
||||
<activity android:name=".activity.main.MainActivity"></activity>
|
||||
</application>
|
||||
|
||||
</manifest>
|
BIN
app/src/main/ic_launcher-web.png
Normal file
After Width: | Height: | Size: 69 KiB |
@ -0,0 +1,15 @@
|
||||
package leszcz_team.wulkanowy.activity.main;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.os.Bundle;
|
||||
|
||||
import leszcz_team.wulkanowy.R;
|
||||
|
||||
public class MainActivity extends Activity {
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.activity_main);
|
||||
}
|
||||
}
|
@ -0,0 +1,35 @@
|
||||
package leszcz_team.wulkanowy.activity.started;
|
||||
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.os.AsyncTask;
|
||||
|
||||
import leszcz_team.wulkanowy.activity.main.MainActivity;
|
||||
|
||||
public class LoadingTask extends AsyncTask<Void, Void, Void> {
|
||||
|
||||
Context activity;
|
||||
|
||||
LoadingTask(Context main) {
|
||||
activity = main;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Void doInBackground(Void... voids) {
|
||||
try {
|
||||
Thread.sleep(5000);
|
||||
} catch (InterruptedException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
protected void onPostExecute(Void result) {
|
||||
|
||||
Intent intent = new Intent(activity,MainActivity.class);
|
||||
activity.startActivity(intent);
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,22 @@
|
||||
package leszcz_team.wulkanowy.activity.started;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.os.Bundle;
|
||||
|
||||
import leszcz_team.wulkanowy.R;
|
||||
|
||||
public class StartedActivity extends Activity {
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.activity_started);
|
||||
Task();
|
||||
}
|
||||
|
||||
public void Task(){
|
||||
|
||||
new LoadingTask(this).execute();
|
||||
|
||||
}
|
||||
}
|
BIN
app/src/main/res/drawable-hdpi/logo_image.png
Normal file
After Width: | Height: | Size: 94 KiB |
BIN
app/src/main/res/drawable-mdpi/logo_image.png
Normal file
After Width: | Height: | Size: 47 KiB |
BIN
app/src/main/res/drawable-xhdpi/logo_image.png
Normal file
After Width: | Height: | Size: 150 KiB |
BIN
app/src/main/res/drawable-xxhdpi/logo_image.png
Normal file
After Width: | Height: | Size: 327 KiB |
BIN
app/src/main/res/drawable-xxxhdpi/logo_image.png
Normal file
After Width: | Height: | Size: 542 KiB |
9
app/src/main/res/layout/activity_main.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context="leszcz_team.wulkanowy.activity.main.MainActivity">
|
||||
|
||||
</android.support.constraint.ConstraintLayout>
|
53
app/src/main/res/layout/activity_started.xml
Normal file
@ -0,0 +1,53 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<android.support.constraint.ConstraintLayout
|
||||
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context="leszcz_team.wulkanowy.activity.started.StartedActivity"
|
||||
tools:layout_editor_absoluteY="0dp"
|
||||
tools:layout_editor_absoluteX="0dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/nameApp"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/app_name"
|
||||
android:textSize="40dp"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
tools:layout_constraintRight_creator="1"
|
||||
tools:layout_constraintBottom_creator="1"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
tools:layout_constraintLeft_creator="1"
|
||||
android:layout_marginBottom="185dp" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/logoImage"
|
||||
android:layout_width="201dp"
|
||||
android:layout_height="176dp"
|
||||
app:srcCompat="@drawable/logo_image"
|
||||
tools:layout_constraintRight_creator="1"
|
||||
tools:layout_constraintBottom_creator="1"
|
||||
app:layout_constraintBottom_toTopOf="@+id/nameApp"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
tools:layout_constraintLeft_creator="1"
|
||||
android:layout_marginBottom="29dp"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.502" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/rawText"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/under_logo"
|
||||
tools:layout_constraintTop_creator="1"
|
||||
tools:layout_constraintRight_creator="1"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:layout_marginTop="57dp"
|
||||
app:layout_constraintTop_toBottomOf="@+id/nameApp"
|
||||
tools:layout_constraintLeft_creator="1"
|
||||
app:layout_constraintLeft_toLeftOf="parent" />
|
||||
</android.support.constraint.ConstraintLayout>
|
BIN
app/src/main/res/mipmap-hdpi/ic_launcher.png
Normal file
After Width: | Height: | Size: 3.1 KiB |
BIN
app/src/main/res/mipmap-hdpi/ic_launcher_round.png
Normal file
After Width: | Height: | Size: 4.1 KiB |
BIN
app/src/main/res/mipmap-mdpi/ic_launcher.png
Normal file
After Width: | Height: | Size: 1.9 KiB |
BIN
app/src/main/res/mipmap-mdpi/ic_launcher_round.png
Normal file
After Width: | Height: | Size: 2.5 KiB |
BIN
app/src/main/res/mipmap-xhdpi/ic_launcher.png
Normal file
After Width: | Height: | Size: 4.7 KiB |
BIN
app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
Normal file
After Width: | Height: | Size: 6.0 KiB |
BIN
app/src/main/res/mipmap-xxhdpi/ic_launcher.png
Normal file
After Width: | Height: | Size: 8.6 KiB |
BIN
app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
Normal file
After Width: | Height: | Size: 9.8 KiB |
BIN
app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
Normal file
After Width: | Height: | Size: 14 KiB |
BIN
app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
Normal file
After Width: | Height: | Size: 14 KiB |
5
app/src/main/res/values-pl/strings.xml
Normal file
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="app_name">Wulkanowy</string>
|
||||
<string name="under_logo">Surowa wersja</string>
|
||||
</resources>
|
6
app/src/main/res/values/colors.xml
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<color name="colorPrimary">#3F51B5</color>
|
||||
<color name="colorPrimaryDark">#303F9F</color>
|
||||
<color name="colorAccent">#FF4081</color>
|
||||
</resources>
|
4
app/src/main/res/values/strings.xml
Normal file
@ -0,0 +1,4 @@
|
||||
<resources>
|
||||
<string name="app_name">Wulkanowy</string>
|
||||
<string name="under_logo">Raw version</string>
|
||||
</resources>
|
11
app/src/main/res/values/styles.xml
Normal file
@ -0,0 +1,11 @@
|
||||
<resources>
|
||||
|
||||
<!-- Base application theme. -->
|
||||
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
|
||||
<!-- Customize your theme here. -->
|
||||
<item name="colorPrimary">@color/colorPrimary</item>
|
||||
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
|
||||
<item name="colorAccent">@color/colorAccent</item>
|
||||
</style>
|
||||
|
||||
</resources>
|
17
app/src/test/java/leszcz_team/wulkanowy/ExampleUnitTest.java
Normal file
@ -0,0 +1,17 @@
|
||||
package leszcz_team.wulkanowy;
|
||||
|
||||
import org.junit.Test;
|
||||
|
||||
import static org.junit.Assert.*;
|
||||
|
||||
/**
|
||||
* Example local unit test, which will execute on the development machine (host).
|
||||
*
|
||||
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||
*/
|
||||
public class ExampleUnitTest {
|
||||
@Test
|
||||
public void addition_isCorrect() throws Exception {
|
||||
assertEquals(4, 2 + 2);
|
||||
}
|
||||
}
|