Skip to content

Commit

Permalink
nothing important.
Browse files Browse the repository at this point in the history
  • Loading branch information
queuejw committed Feb 11, 2025
1 parent 5824eb8 commit ce6eff3
Show file tree
Hide file tree
Showing 40 changed files with 28 additions and 1,264 deletions.
2 changes: 0 additions & 2 deletions .idea/gradle.xml

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

11 changes: 6 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

MetroPhoneLauncher (MPL, MPLauncher) is an Android launcher designed to resemble Windows Phone 8. 🌟

This is MPL version 8.0. It is lightweight, but contains far fewer features and customization options. Use it on older devices.

MPL is still in development, but it already includes a range of features you might enjoy. Here’s what’s available so far:

Expand Down Expand Up @@ -37,11 +38,11 @@ And many more smaller features!

# 📸 Screenshots:
<div>
<img src='/screenshots/tiles.jpg' width='250' alt="Tiles">
<img src='/screenshots/allapps.jpg' width='250' alt="All Apps">
<img src='/screenshots/tiles_lawnicons.jpg' width='250' alt="Tiles with Lawnicons">
<img src='/screenshots/settings.jpg' width='250' alt="Settings">
<img src='/screenshots/settings_theme.jpg' width='250' alt="Theme settings">
<img src='/screenshots/tiles.png' width='250' alt="Tiles">
<img src='/screenshots/allapps.png' width='250' alt="All Apps">
<img src='/screenshots/tiles2.png' width='250' alt="Tiles 2">
<img src='/screenshots/settings.png' width='250' alt="Settings">
<img src='/screenshots/settings_theme.png' width='250' alt="Theme settings">
<img src='/screenshots/oobe.jpg' width='250' alt="OOBE">
</div>

Expand Down
1 change: 0 additions & 1 deletion app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ dependencies {
implementation 'androidx.core:core-splashscreen:1.1.0-rc01'

implementation project(path: ':SpannedGridLayoutManager')
implementation project(path: ':liboverscroll')

implementation 'com.github.shadowalker77:wp7progressbar:1.1.0'
implementation 'io.coil-kt.coil3:coil:3.1.0'
Expand Down
17 changes: 3 additions & 14 deletions app/src/main/java/ru/queuejw/mpl/Application.kt
Original file line number Diff line number Diff line change
Expand Up @@ -14,19 +14,13 @@ import ru.queuejw.mpl.helpers.utils.Utils
class Application : Application() {

override fun onCreate() {
if (applicationContext == null) {
super.onCreate()
return
}
BsodDetector.setContext(applicationContext)
Thread.setDefaultUncaughtExceptionHandler(BsodDetector())
PREFS = Prefs(applicationContext)
if (PREFS.accentColor == 21 && DynamicColors.isDynamicColorAvailable()) DynamicColors.applyToActivitiesIfAvailable(
this
)
setupCustomFont()
setupCustomLightFont()
setupCustomBoldFont()
setupFonts()
super.onCreate()
registerActivityLifecycleCallbacks(object : ActivityLifecycleCallbacks {
@SuppressLint("SourceLockedOrientationActivity")
Expand Down Expand Up @@ -63,16 +57,11 @@ class Application : Application() {
var customLightFont: Typeface? = null
var customBoldFont: Typeface? = null

fun setupCustomFont() {
fun setupFonts() {
customFont = Utils.getCustomFont()
}

fun setupCustomLightFont() {
customLightFont = Utils.getCustomLightFont()
}

fun setupCustomBoldFont() {
customBoldFont = Utils.getCustomBoldFont()
}

}
}
12 changes: 0 additions & 12 deletions app/src/main/java/ru/queuejw/mpl/content/AllApps.kt
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@ import kotlinx.coroutines.cancel
import kotlinx.coroutines.delay
import kotlinx.coroutines.launch
import kotlinx.coroutines.withContext
import me.everything.android.ui.overscroll.IOverScrollDecor
import me.everything.android.ui.overscroll.OverScrollDecoratorHelper
import ru.queuejw.mpl.Application.Companion.PREFS
import ru.queuejw.mpl.Application.Companion.customFont
import ru.queuejw.mpl.Application.Companion.customLightFont
Expand Down Expand Up @@ -88,13 +86,6 @@ class AllApps : Fragment() {
)
)
}
private val scrollDecor: IOverScrollDecor by lazy {
OverScrollDecoratorHelper.setUpOverScroll(
binding.appList,
OverScrollDecoratorHelper.ORIENTATION_VERTICAL
)
}


override fun onCreateView(
inflater: LayoutInflater,
Expand Down Expand Up @@ -135,7 +126,6 @@ class AllApps : Fragment() {
binding.appList.apply {
layoutManager = recyclerViewLM
addItemDecoration(bottomDecor)
scrollDecor.attach()
}
}
}
Expand Down Expand Up @@ -279,7 +269,6 @@ class AllApps : Fragment() {
if (!isSearching) return
isSearching = false
binding.noResults.visibility = View.GONE
scrollDecor.attach()
binding.apply {
hideKeyboard(search.editText as? AutoCompleteTextView)
(search.editText as? AutoCompleteTextView)?.apply {
Expand Down Expand Up @@ -309,7 +298,6 @@ class AllApps : Fragment() {
if (isSearching) return
appAdapter ?: return
isSearching = true
scrollDecor.detach()
binding.apply {
searchLayout.apply {
visibility = View.VISIBLE
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import androidx.collection.SparseArrayCompat
import androidx.core.content.edit
import androidx.fragment.app.Fragment
import androidx.lifecycle.lifecycleScope
import androidx.recyclerview.widget.LinearLayoutManager
Expand All @@ -28,7 +29,6 @@ import ru.queuejw.mpl.helpers.utils.Utils
import ru.queuejw.mpl.helpers.utils.Utils.Companion.generatePlaceholder
import ru.queuejw.mpl.helpers.utils.Utils.Companion.setUpApps
import kotlin.random.Random
import androidx.core.content.edit

class AppsFragment : Fragment() {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package ru.queuejw.mpl.content.settings

import android.os.Bundle
import android.view.animation.DecelerateInterpolator
import android.view.animation.LinearInterpolator
import androidx.activity.OnBackPressedCallback
import androidx.appcompat.app.AppCompatActivity
import androidx.appcompat.app.AppCompatDelegate
Expand Down Expand Up @@ -37,6 +36,10 @@ class SettingsActivity : AppCompatActivity() {
setContentView(binding.root)
WindowCompat.setDecorFitsSystemWindows(window, false)
Utils.applyWindowInsets(binding.root)
}

override fun onStart() {
super.onStart()
setupBackPressedDispatcher()
supportFragmentManager.commit {
replace(binding.fragmentContainerView.id, MainSettingsFragment())
Expand All @@ -45,10 +48,6 @@ class SettingsActivity : AppCompatActivity() {
PREFS.prefs.edit { putBoolean("themeChanged", false) }
changeFragment(ThemeSettingsFragment(), "theme")
}
}

override fun onStart() {
super.onStart()
prepareTip()
}

Expand Down Expand Up @@ -91,17 +90,17 @@ class SettingsActivity : AppCompatActivity() {
if(!PREFS.isTransitionAnimEnabled) {
supportFragmentManager.popBackStackImmediate()
} else {
binding.root.animate().rotationY(90f).alpha(0.1f).translationX(-100f).setDuration(200).setInterpolator(
binding.root.animate().rotationY(90f).alpha(0.75f).translationX(-100f).setDuration(150).setInterpolator(
DecelerateInterpolator()
).withEndAction {
supportFragmentManager.popBackStack()
binding.root.apply {
rotationY = -90f
rotationY = -45f
alpha = 0f
}
lifecycleScope.launch {
delay(25)
binding.root.animate().rotationY(0f).alpha(1f).translationX(0f).setDuration(200).setInterpolator(
binding.root.animate().rotationY(0f).alpha(1f).translationX(0f).setDuration(150).setInterpolator(
DecelerateInterpolator()
).start()
}.start()
Expand All @@ -122,7 +121,7 @@ class SettingsActivity : AppCompatActivity() {
if(PREFS.isTransitionAnimEnabled) {
lifecycleScope.launch {
animateFragmentEnter()
delay(200)
delay(80)
changeFragmentFunction(fragment, name)
}
} else {
Expand All @@ -136,13 +135,16 @@ class SettingsActivity : AppCompatActivity() {
}
}
private fun animateFragmentEnter() {
binding.root.animate().rotationY(-90f).alpha(0.1f).translationX(-100f).setDuration(200)
binding.root.animate().rotationY(-45f).alpha(0.75f).translationX(-500f).setDuration(75)
.setInterpolator(
DecelerateInterpolator()
).withEndAction {
binding.root.alpha = 0f
binding.root.rotationY = 90f
lifecycleScope.launch {
delay(25)
binding.root.animate().rotationY(0f).alpha(1f).translationX(0f).setDuration(200)
delay(50)
binding.root.alpha = 0.5f
binding.root.animate().rotationY(0f).alpha(1f).translationX(0f).setDuration(150)
.setInterpolator(
DecelerateInterpolator()
).start()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,7 @@ import ru.queuejw.mpl.Application.Companion.PREFS
import ru.queuejw.mpl.Application.Companion.customBoldFont
import ru.queuejw.mpl.Application.Companion.customFont
import ru.queuejw.mpl.Application.Companion.customLightFont
import ru.queuejw.mpl.Application.Companion.setupCustomBoldFont
import ru.queuejw.mpl.Application.Companion.setupCustomFont
import ru.queuejw.mpl.Application.Companion.setupCustomLightFont
import ru.queuejw.mpl.Application.Companion.setupFonts
import ru.queuejw.mpl.R
import ru.queuejw.mpl.content.data.bsod.BSOD
import ru.queuejw.mpl.content.settings.SettingsActivity
Expand Down Expand Up @@ -149,9 +147,7 @@ class FontSettingsFragment : Fragment() {
}

private fun activateNewFont() {
setupCustomFont()
setupCustomLightFont()
setupCustomBoldFont()
setupFonts()
setUi()
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@ import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import androidx.fragment.app.Fragment
import androidx.lifecycle.lifecycleScope
import kotlinx.coroutines.delay
import kotlinx.coroutines.launch
import leakcanary.LeakCanary
import ru.queuejw.mpl.Application.Companion.PREFS
import ru.queuejw.mpl.R
Expand All @@ -20,8 +17,6 @@ class MainSettingsFragment : Fragment() {
private var _binding: SettingsListBinding? = null
private val binding get() = _binding!!

private var fragmentActive = true

override fun onCreateView(
inflater: LayoutInflater, container: ViewGroup?,
savedInstanceState: Bundle?
Expand Down Expand Up @@ -79,31 +74,15 @@ class MainSettingsFragment : Fragment() {

private fun setClickListener(view: View, fragment: Fragment, name: String) {
view.setOnClickListener {
if(PREFS.isTransitionAnimEnabled) {
lifecycleScope.launch {
animateSettings(false)
delay(100)
fragmentActive = false
(requireActivity() as SettingsActivity).changeFragment(fragment, name)
}
} else {
(requireActivity() as SettingsActivity).changeFragment(fragment, name)
}
(requireActivity() as SettingsActivity).changeFragment(fragment, name)
}
}

override fun onResume() {
if(fragmentActive) {
animateSettings(true)
}
fragmentActive = true
super.onResume()

}

private fun animateSettings(resumeAnimation: Boolean) {
}

override fun onPause() {
super.onPause()
}
Expand Down
1 change: 1 addition & 0 deletions app/src/main/res/layout/settings_list.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<ScrollView
android:id="@+id/scroll"
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"
Expand Down
1 change: 0 additions & 1 deletion liboverscroll/.gitignore

This file was deleted.

33 changes: 0 additions & 33 deletions liboverscroll/build.gradle

This file was deleted.

3 changes: 0 additions & 3 deletions liboverscroll/src/main/AndroidManifest.xml

This file was deleted.

Loading

0 comments on commit ce6eff3

Please sign in to comment.