Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implements Wikimedia and Scribe Page #54

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -65,28 +65,28 @@ android {
}

dependencies {
kapt 'androidx.room:room-compiler:2.3.0'
implementation 'androidx.room:room-runtime:2.3.0'
annotationProcessor 'androidx.room:room-compiler:2.3.0'
kapt 'androidx.room:room-compiler:2.6.1'
implementation 'androidx.room:room-runtime:2.6.1'
annotationProcessor 'androidx.room:room-compiler:2.6.1'
// Commons dependencies
implementation 'com.andrognito.patternlockview:patternlockview:1.0.0'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'androidx.constraintlayout:constraintlayout:2.1.2'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation 'androidx.documentfile:documentfile:1.0.1'
implementation 'androidx.swiperefreshlayout:swiperefreshlayout:1.1.0'
implementation "androidx.exifinterface:exifinterface:1.3.3"
implementation "androidx.biometric:biometric-ktx:1.2.0-alpha03"
implementation "androidx.exifinterface:exifinterface:1.3.7"
implementation "androidx.biometric:biometric-ktx:1.2.0-alpha05"
implementation 'com.google.android.material:material:1.12.0'
implementation 'androidx.recyclerview:recyclerview:1.3.2'
implementation 'androidx.cardview:cardview:1.0.0'

api 'joda-time:joda-time:2.10.13'
api 'com.github.tibbi:RecyclerView-FastScroller:e7d3e150c4'
api 'com.github.tibbi:reprint:2cb206415d'
api 'androidx.core:core-ktx:1.6.0'
api 'androidx.appcompat:appcompat:1.3.1'
api 'com.google.android.material:material:1.4.0'
api 'com.google.code.gson:gson:2.8.8'
api 'androidx.core:core-ktx:1.13.1'
api 'androidx.appcompat:appcompat:1.7.0'
api 'com.google.android.material:material:1.12.0'
api 'com.google.code.gson:gson:2.10.1'
api 'com.duolingo.open:rtl-viewpager:1.0.3'

api 'com.github.bumptech.glide:glide:4.12.0'
Expand Down
7 changes: 5 additions & 2 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,8 +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"
android:installLocation="auto"
package="be.scri">
android:installLocation="auto">

<uses-permission
android:name="android.permission.USE_FINGERPRINT"
Expand Down Expand Up @@ -150,6 +149,10 @@
android:name="be.scri.activities.AboutActivity"
android:label="@string/about"
android:parentActivityName=".activities.MainActivity" />
<activity
android:name="be.scri.activities.WikimediaScribeActivity"
android:label="@string/wikimedia_and_scribe"
android:parentActivityName=".activities.MainActivity" />

<activity-alias
android:name=".activities.SplashActivity.Orange"
Expand Down
4 changes: 3 additions & 1 deletion app/src/main/kotlin/be/scri/activities/AboutActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -130,12 +130,14 @@ class AboutActivity : BaseSimpleActivity(), GestureDetector.OnGestureListener{
"Wikimedia and Scribe",
image2 = R.drawable.right_arrow,
url = null,
activity = null,
activity = WikimediaScribeActivity::class.java,
action = null
))
return data
}



private fun getSecondRecyclerViewData(): List<ItemsViewModel> {
val data2 = ArrayList<ItemsViewModel>()
data2.add(ItemsViewModel(
Expand Down
49 changes: 49 additions & 0 deletions app/src/main/kotlin/be/scri/activities/WikimediaScribeActivity.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
package be.scri.activities

import android.content.Intent
import android.os.Bundle
import androidx.activity.enableEdgeToEdge
import be.scri.R
import be.scri.helpers.APP_ICON_IDS
import be.scri.helpers.APP_LAUNCHER_NAME
import com.google.android.material.bottomnavigation.BottomNavigationView


class WikimediaScribeActivity : BaseSimpleActivity(){
override fun getAppIconIDs() = intent.getIntegerArrayListExtra(APP_ICON_IDS) ?: ArrayList()

override fun getAppLauncherName() = intent.getStringExtra(APP_LAUNCHER_NAME) ?: ""

override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_wikimedia_scribe)
enableEdgeToEdge()
val bottomNavigationView = findViewById<BottomNavigationView>(R.id.bottom_navigation)

bottomNavigationView.selectedItemId = R.id.info

bottomNavigationView.setOnNavigationItemSelectedListener(BottomNavigationView.OnNavigationItemSelectedListener { item ->
when (item.itemId) {
R.id.settings -> {
startActivity(Intent(applicationContext, SettingsActivity::class.java))
overridePendingTransition(0, 0)
return@OnNavigationItemSelectedListener true
}

R.id.about -> {
return@OnNavigationItemSelectedListener true }
R.id.installation -> {
startActivity(Intent(applicationContext, MainActivity::class.java))
overridePendingTransition(0, 0)
return@OnNavigationItemSelectedListener true
}
}
false
})
bottomNavigationView.selectedItemId = R.id.about
}

}



9 changes: 9 additions & 0 deletions app/src/main/res/drawable/corner_polygon.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="220dp"
android:height="221dp"
android:viewportWidth="220"
android:viewportHeight="221">
<path
android:pathData="M181,1C202.58,1.14 220,18.67 220,40.25L220,42L220,220.75L-0,0.75L181,1Z"
android:fillColor="@color/corner_polygon_color"/>
</vector>
22 changes: 22 additions & 0 deletions app/src/main/res/drawable/wikidata_logo.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="550dp"
android:height="389dp"
android:viewportWidth="550"
android:viewportHeight="389">
<path
android:pathData="M62.41,283.8H77.66V22.5H62.41V283.8ZM93.91,283.8H140.65V22.5H93.91V283.8ZM155.9,22.5V283.79H202.64V22.5H155.9Z"
android:fillColor="@color/icon_color"
android:fillAlpha="0.9"/>
<path
android:pathData="M438.48,283.82H453.72V22.5H438.48V283.82ZM469.98,22.5V283.82H485.23V22.5H469.98ZM218.38,283.82H233.63V22.5H218.38V283.82ZM249.89,22.5V283.81H265.13V22.5H249.89Z"
android:fillColor="@color/icon_color"
android:fillAlpha="0.9"/>
<path
android:pathData="M280.88,283.82H327.62V22.5H280.88V283.82ZM342.86,283.82H359.11V22.5H342.86V283.82ZM374.36,22.5V283.81H421.1V22.5H374.36Z"
android:fillColor="@color/icon_color"
android:fillAlpha="0.9"/>
<path
android:pathData="M462,312.58L486.05,366.77H471.55L467.08,356.06H442.84L438.81,366.77H424.49L446.33,312.58H462ZM463.09,346.6L454.36,325.54L446.41,346.6H463.09ZM431.59,312.58V322.51H411.96V366.77H398.47V322.51H378.84V312.58H431.59ZM361.77,312.58L385.82,366.77H371.31L366.85,356.06H342.61L338.58,366.77H324.26L346.1,312.58H361.77ZM362.86,346.6L354.13,325.54L346.18,346.6H362.86ZM270.58,312.58H294.47C303.7,312.58 311,315.12 316.35,320.18C321.73,325.23 324.42,331.76 324.42,339.77C324.42,348.18 321.69,354.78 316.23,359.59C310.8,364.38 303.04,366.77 292.96,366.77H270.58V312.58ZM284.08,322.51V356.84H292.88C298.6,356.84 302.97,355.28 305.99,352.15C309.02,348.99 310.53,344.84 310.53,339.7C310.53,334.37 308.99,330.18 305.92,327.13C302.86,324.05 298.47,322.51 292.73,322.51H284.08ZM258.09,312.58V366.77H244.59V312.58H258.09ZM232.53,312.58L214.88,338.03L238.81,366.77H221.9L200.45,341.36V366.77H186.95V312.58H200.45V336.98L217.67,312.58H232.53ZM174.46,312.58V366.77H160.96V312.58H174.46ZM107.97,332.13L91.22,367.47H85.4L61.58,312.58H75.89L88.66,342.53L102.58,312.58H113.44L127.37,342.53L140.05,312.58H154.37L130.63,367.47H124.81L107.97,332.13Z"
android:fillColor="@color/icon_color"
android:fillAlpha="0.9"/>
</vector>
Loading