global: rename StatisticsActivity to LongTermStatisticsActivity

Make way for a future ShortTermStatisticsActivity.
This commit is contained in:
2026-06-18 14:35:13 +02:00
parent ddcc2fc492
commit 4f8209b793
3 changed files with 5 additions and 5 deletions

View File

@@ -31,7 +31,7 @@
android:label="@string/settings_title" android:label="@string/settings_title"
android:theme="@style/Theme.LunaTracker"/> android:theme="@style/Theme.LunaTracker"/>
<activity <activity
android:name=".StatisticsActivity" android:name=".LongTermStatisticsActivity"
android:label="@string/statistics_title" android:label="@string/statistics_title"
android:theme="@style/Theme.LunaTracker"/> android:theme="@style/Theme.LunaTracker"/>
</application> </application>

View File

@@ -35,7 +35,7 @@ import java.util.Locale
import kotlin.math.max import kotlin.math.max
import kotlin.math.min import kotlin.math.min
class StatisticsActivity : AppCompatActivity() { class LongTermStatisticsActivity : AppCompatActivity() {
var lastToastShown = 0L var lastToastShown = 0L
lateinit var barChart: BarChart lateinit var barChart: BarChart
@@ -767,7 +767,7 @@ class StatisticsActivity : AppCompatActivity() {
override fun onItemSelected(parent: AdapterView<*>?, view: View?, pos: Int, id: Long) { override fun onItemSelected(parent: AdapterView<*>?, view: View?, pos: Int, id: Long) {
if (pos >= arrayValues.size) { if (pos >= arrayValues.size) {
Toast.makeText( Toast.makeText(
this@StatisticsActivity, this@LongTermStatisticsActivity,
"pos out of bounds: $arrayValues", Toast.LENGTH_SHORT "pos out of bounds: $arrayValues", Toast.LENGTH_SHORT
).show() ).show()
return return
@@ -784,7 +784,7 @@ class StatisticsActivity : AppCompatActivity() {
} }
companion object { companion object {
const val TAG = "StatisticsActivity" const val TAG = "LongTermStatisticsActivity"
// 15 min steps // 15 min steps
const val SLEEP_PATTERN_GRANULARITY = 15 * 60 const val SLEEP_PATTERN_GRANULARITY = 15 * 60

View File

@@ -1359,7 +1359,7 @@ class MainActivity : AppCompatActivity() {
// Add statistics (hard coded) // Add statistics (hard coded)
contentView.findViewById<View>(R.id.button_statistics).setOnClickListener { contentView.findViewById<View>(R.id.button_statistics).setOnClickListener {
if (logbook != null && !pauseLogbookUpdate) { if (logbook != null && !pauseLogbookUpdate) {
val i = Intent(applicationContext, StatisticsActivity::class.java) val i = Intent(applicationContext, LongTermStatisticsActivity::class.java)
i.putExtra("LOOGBOOK_NAME", logbook!!.name) i.putExtra("LOOGBOOK_NAME", logbook!!.name)
startActivity(i) startActivity(i)
} else { } else {