Skip to content

Commit

Permalink
Update 1.1_r1.
Browse files Browse the repository at this point in the history
  • Loading branch information
D4rK7355608 committed Jul 26, 2022
1 parent 0f42f59 commit d1c3f2d
Show file tree
Hide file tree
Showing 87 changed files with 517 additions and 218 deletions.
25 changes: 23 additions & 2 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
# Version 1.1_r1:
- Minor tweaks;
- Fixed minor & major bugs;
- Fixed Text Box lesson;
- Added alert dialog lesson;
- Under the hood improvements.

# Version 1.0_r2:
- Updated policy and terms of service;
- Added SoftInputMode for TextBox;
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@
![GitHub Pull Requests](https://img.shields.io/github/issues-pr/D4rK7355608/com.d4rk.androidtutorials?style=for-the-badge&logo=github)
![GitHub License](https://img.shields.io/github/license/D4rK7355608/com.d4rk.androidtutorials?style=for-the-badge&logo=github)

## 📱Android Studio Tutorials📱
## 📱 Android Studio Tutorials 📱

- ╔╦╦╦═╦╗╔═╦═╦══╦═╗
- ║║║║╩╣╚╣═╣║║║║║╩╣
- ╚══╩═╩═╩═╩═╩╩╩╩═╝

## Learn how to make simple apps in Android Studio. 📱

Start learning Android Studio!
Start learning Android Studio! 📱

Android Studio Tutorials app is a guide on developing Android apps using Android Studio IDE. Tutorials helps you building your first Android app. In the app, you can also learn the basic concepts of android app development using Android Studio. It also contains examples with complete source codes.

Expand Down
8 changes: 4 additions & 4 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ plugins {
}
android {
compileSdk 32
def tagName = '1.0_r2'
def tagName = '1.1_r1'
defaultConfig {
applicationId "com.d4rk.androidtutorials"
minSdk 26
targetSdk 32
versionCode 5
versionCode 7
versionName tagName
archivesBaseName = "com.d4rk.androidtutorials-v${versionName}"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
Expand Down Expand Up @@ -47,14 +47,13 @@ android {
}
}
dependencies {
implementation platform('com.google.firebase:firebase-bom:30.2.0')
implementation platform('com.google.firebase:firebase-bom:30.3.0')
implementation 'com.google.firebase:firebase-crashlytics-ktx:18.2.11'
implementation 'com.google.firebase:firebase-analytics-ktx:21.1.0'
implementation 'com.google.firebase:firebase-perf:20.1.0'
implementation 'com.google.android.material:material:1.6.1'
implementation 'com.google.android.gms:play-services-oss-licenses:17.0.0'
implementation 'com.google.android.play:review-ktx:2.0.0'
implementation 'androidx.palette:palette:1.0.0'
implementation 'androidx.core:core-ktx:1.8.0'
implementation 'androidx.appcompat:appcompat:1.4.2'
implementation 'androidx.viewpager2:viewpager2:1.0.0'
Expand All @@ -67,6 +66,7 @@ dependencies {
implementation 'androidx.preference:preference-ktx:1.2.0'
implementation 'com.airbnb.android:lottie:5.2.0'
implementation 'com.github.KieronQuinn:MonetCompat:0.4.1'
implementation 'me.zhanghai.android.fastscroll:library:1.1.8'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
Expand Down
33 changes: 30 additions & 3 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.d4rk.androidtutorials">
<uses-permission android:name="android.permission.INTERNET"/>
<queries>
Expand All @@ -21,12 +22,14 @@
android:supportsRtl="true"
android:theme="@style/AppThemeActionBar">
<activity
android:name=".ui.settings.LanguageActivity"
android:name=".ui.language.LanguageActivity"
android:label="@string/language"
android:exported="false">
android:screenOrientation="portrait"
android:exported="false"
tools:ignore="LockedOrientationActivity">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value=".ui.settings.LanguageActivity"/>
android:value=".ui.language.LanguageActivity"/>
</activity>
<activity
android:name=".ui.android.toggle.ToggleCodeActivity"
Expand All @@ -45,6 +48,30 @@
android:name="android.support.PARENT_ACTIVITY"
android:value=".ui.android.textbox.TextboxActivity"/>
</activity>
<activity
android:name=".ui.android.textbox.TextboxCodeActivity"
android:exported="false"
android:label="@string/textbox">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value=".ui.android.textbox.TextboxCodeActivity"/>
</activity>
<activity
android:name=".ui.android.alertdialog.AlertDialogActivity"
android:exported="false"
android:label="@string/alert_dialog">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value=".ui.android.alertdialog.AlertDialogActivity"/>
</activity>
<activity
android:name=".ui.android.alertdialog.AlertDialogCodeActivity"
android:exported="false"
android:label="@string/alert_dialog">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value=".ui.android.alertdialog.AlertDialogCodeActivity"/>
</activity>
<activity
android:name=".ui.permissions.PermissionsActivity"
android:exported="false"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,14 @@ import android.os.Bundle
import android.text.method.LinkMovementMethod
import androidx.appcompat.app.AppCompatActivity
import com.d4rk.androidtutorials.databinding.ActivityAndroidStartProjectBinding
import me.zhanghai.android.fastscroll.FastScrollerBuilder
class AndroidStartProjectActivity : AppCompatActivity() {
private lateinit var binding : ActivityAndroidStartProjectBinding
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
binding = ActivityAndroidStartProjectBinding.inflate(layoutInflater)
setContentView(binding.root)
FastScrollerBuilder(binding.startProjectScroll).useMd2Style().build()
binding.step3Sum.movementMethod = LinkMovementMethod.getInstance()
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
package com.d4rk.androidtutorials.ui.android.alertdialog
import android.content.Intent
import android.os.Bundle
import androidx.appcompat.app.AlertDialog
import androidx.appcompat.app.AppCompatActivity
import com.d4rk.androidtutorials.R
import com.d4rk.androidtutorials.databinding.ActivityAlertDialogBinding
class AlertDialogActivity : AppCompatActivity() {
private lateinit var binding : ActivityAlertDialogBinding
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
binding = ActivityAlertDialogBinding.inflate(layoutInflater)
setContentView(binding.root)
binding.button.setOnClickListener {
val alertDialog: AlertDialog.Builder = AlertDialog.Builder(this)
alertDialog.setTitle(R.string.alert_dialog_title)
alertDialog.setMessage(R.string.alert_dialog_message)
alertDialog.create()
alertDialog.setPositiveButton(R.string.alert_dialog_button_positive, null)
alertDialog.setNegativeButton(R.string.alert_dialog_button_negative, null)
alertDialog.show()
}
binding.showButtonCodeSyntax.setOnClickListener {
val intent = Intent(this, AlertDialogCodeActivity::class.java)
startActivity(intent)
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
@file:Suppress("DEPRECATION")
package com.d4rk.androidtutorials.ui.android.alertdialog
import android.os.Bundle
import androidx.appcompat.app.AppCompatActivity
import androidx.fragment.app.Fragment
import androidx.fragment.app.FragmentManager
import androidx.fragment.app.FragmentPagerAdapter
import androidx.viewpager.widget.ViewPager
import com.d4rk.androidtutorials.R
import com.d4rk.androidtutorials.ui.android.alertdialog.tabs.AlertDialogTabCodeFragment
import com.d4rk.androidtutorials.ui.android.alertdialog.tabs.AlertDialogTabLayoutFragment
import com.google.android.material.tabs.TabLayout
class AlertDialogCodeActivity: AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_tab_layout)
val tabs : TabLayout = findViewById(R.id.tabs)
val viewpager : ViewPager = findViewById(R.id.viewpager)
setupViewPager(viewpager)
tabs.setupWithViewPager(viewpager)
}
private fun setupViewPager(viewPager: ViewPager) {
val adapter = ViewPagerAdapter(supportFragmentManager)
adapter.addFragment(AlertDialogTabCodeFragment(), getString(R.string.code_kotlin))
adapter.addFragment(AlertDialogTabLayoutFragment(), getString(R.string.layout_xml))
viewPager.adapter = adapter
}
internal inner class ViewPagerAdapter(manager: FragmentManager) : FragmentPagerAdapter(manager) {
private val mFragmentList = ArrayList<Fragment>()
private val mFragmentTitleList = ArrayList<String>()
override fun getItem(position: Int): Fragment {
return mFragmentList[position]
}
override fun getCount(): Int {
return mFragmentList.size
}
fun addFragment(fragment: Fragment, title: String) {
mFragmentList.add(fragment)
mFragmentTitleList.add(title)
}
override fun getPageTitle(position: Int): CharSequence {
return mFragmentTitleList[position]
}
}
}
Loading

0 comments on commit d1c3f2d

Please sign in to comment.