Compare commits
	
		
			8 Commits
		
	
	
		
			Final
			...
			fc6ff2e5cc
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| fc6ff2e5cc | |||
| 4cd8641ec2 | |||
| 15ff7fa1cf | |||
| a3fe0d4a2e | |||
| f055efed02 | |||
| 9446f427c3 | |||
| c57cdd0a35 | |||
| 058e854606 | 
@@ -1,3 +1,9 @@
 | 
				
			|||||||
# android-infinite-timer
 | 
					# Infinite Timer
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Timer which loops over the specified interval, playing your default notification sound each time it hits 0.
 | 
					Timer which loops over the specified interval, playing your default notification sound each time it hits 0.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					## Update Notes
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					### 2025-07-11
 | 
				
			||||||
 | 
					(This article)[https://sijus.medium.com/resurrecting-a-5-year-old-android-app-a-developers-journey-59d8f5689e5b]
 | 
				
			||||||
 | 
					 was very helpful in getting this app updated from SDK 25 to 36.
 | 
				
			||||||
@@ -1,14 +1,14 @@
 | 
				
			|||||||
apply plugin: 'com.android.application'
 | 
					apply plugin: 'com.android.application'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
android {
 | 
					android {
 | 
				
			||||||
    compileSdkVersion 28
 | 
					    namespace "com.hyperling.apps.infinitetimer"
 | 
				
			||||||
    buildToolsVersion '28.0.3'
 | 
					    compileSdkVersion 35
 | 
				
			||||||
    defaultConfig {
 | 
					    defaultConfig {
 | 
				
			||||||
        applicationId "com.hyperling.apps.infinitetimer"
 | 
					        applicationId "com.hyperling.apps.infinitetimer"
 | 
				
			||||||
        minSdkVersion 15
 | 
					        minSdkVersion 15
 | 
				
			||||||
        targetSdkVersion 28
 | 
					        targetSdkVersion 35
 | 
				
			||||||
        versionCode 7
 | 
					        versionCode 8
 | 
				
			||||||
        versionName "1.06"
 | 
					        versionName "1.1.0"
 | 
				
			||||||
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
 | 
					        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    buildTypes {
 | 
					    buildTypes {
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,26 +0,0 @@
 | 
				
			|||||||
package com.hyperling.apps.infinitetimer.deleteme;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
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("infinitetimer.apps.hyperling.com.infinitetimer", appContext.getPackageName());
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@@ -1,6 +1,5 @@
 | 
				
			|||||||
<?xml version="1.0" encoding="utf-8"?>
 | 
					<?xml version="1.0" encoding="utf-8"?>
 | 
				
			||||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
 | 
					<manifest xmlns:android="http://schemas.android.com/apk/res/android">
 | 
				
			||||||
    package="com.hyperling.apps.infinitetimer">
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    <application
 | 
					    <application
 | 
				
			||||||
        android:allowBackup="true"
 | 
					        android:allowBackup="true"
 | 
				
			||||||
@@ -9,10 +8,9 @@
 | 
				
			|||||||
        android:supportsRtl="true"
 | 
					        android:supportsRtl="true"
 | 
				
			||||||
        android:theme="@style/InfiniteTimer"
 | 
					        android:theme="@style/InfiniteTimer"
 | 
				
			||||||
        android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize">
 | 
					        android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize">
 | 
				
			||||||
        <activity android:name=".MainActivity">
 | 
					        <activity android:name=".MainActivity" android:exported="true">
 | 
				
			||||||
            <intent-filter>
 | 
					            <intent-filter>
 | 
				
			||||||
                <action android:name="android.intent.action.MAIN" />
 | 
					                <action android:name="android.intent.action.MAIN" />
 | 
				
			||||||
 | 
					 | 
				
			||||||
                <category android:name="android.intent.category.LAUNCHER" />
 | 
					                <category android:name="android.intent.category.LAUNCHER" />
 | 
				
			||||||
            </intent-filter>
 | 
					            </intent-filter>
 | 
				
			||||||
        </activity>
 | 
					        </activity>
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -8,6 +8,7 @@ import android.net.Uri;
 | 
				
			|||||||
import android.os.Bundle;
 | 
					import android.os.Bundle;
 | 
				
			||||||
import android.os.Handler;
 | 
					import android.os.Handler;
 | 
				
			||||||
import android.os.Message;
 | 
					import android.os.Message;
 | 
				
			||||||
 | 
					import android.support.v7.app.ActionBar;
 | 
				
			||||||
import android.support.v7.app.AppCompatActivity;
 | 
					import android.support.v7.app.AppCompatActivity;
 | 
				
			||||||
import android.util.Log;
 | 
					import android.util.Log;
 | 
				
			||||||
import android.view.View;
 | 
					import android.view.View;
 | 
				
			||||||
@@ -493,6 +494,9 @@ public class MainActivity extends AppCompatActivity {
 | 
				
			|||||||
        sharedPreferences.edit().putBoolean(keyServiceRunning, false).apply();
 | 
					        sharedPreferences.edit().putBoolean(keyServiceRunning, false).apply();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        recoverScreen();
 | 
					        recoverScreen();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        ActionBar actionBar = getSupportActionBar();
 | 
				
			||||||
 | 
					        actionBar.hide();
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    private void flipInputTexts() {
 | 
					    private void flipInputTexts() {
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -10,11 +10,23 @@
 | 
				
			|||||||
    android:paddingTop="@dimen/activity_vertical_margin"
 | 
					    android:paddingTop="@dimen/activity_vertical_margin"
 | 
				
			||||||
    tools:context="com.hyperling.apps.infinitetimer.MainActivity">
 | 
					    tools:context="com.hyperling.apps.infinitetimer.MainActivity">
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    <TextView
 | 
				
			||||||
 | 
					        android:id="@+id/tvAppName"
 | 
				
			||||||
 | 
					        android:layout_width="match_parent"
 | 
				
			||||||
 | 
					        android:layout_height="wrap_content"
 | 
				
			||||||
 | 
					        android:text="@string/appName"
 | 
				
			||||||
 | 
					        android:layout_alignParentTop="true"
 | 
				
			||||||
 | 
					        android:background="@color/colorPrimaryDark"
 | 
				
			||||||
 | 
					        android:layout_marginTop="10dp"
 | 
				
			||||||
 | 
					        android:padding="8dp"
 | 
				
			||||||
 | 
					        android:textSize="32sp"
 | 
				
			||||||
 | 
					        android:textStyle="bold"/>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    <TextView
 | 
					    <TextView
 | 
				
			||||||
        android:id="@+id/tvUpperLabel"
 | 
					        android:id="@+id/tvUpperLabel"
 | 
				
			||||||
        android:layout_width="wrap_content"
 | 
					        android:layout_width="wrap_content"
 | 
				
			||||||
        android:layout_height="wrap_content"
 | 
					        android:layout_height="wrap_content"
 | 
				
			||||||
        android:layout_alignParentTop="true"
 | 
					        android:layout_below="@+id/tvAppName"
 | 
				
			||||||
        android:layout_centerHorizontal="true"
 | 
					        android:layout_centerHorizontal="true"
 | 
				
			||||||
        android:layout_margin="4dp"
 | 
					        android:layout_margin="4dp"
 | 
				
			||||||
        android:textSize="18sp"
 | 
					        android:textSize="18sp"
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -5,20 +5,18 @@
 | 
				
			|||||||
        android:id="@+id/action_milis"
 | 
					        android:id="@+id/action_milis"
 | 
				
			||||||
        android:orderInCategory="100"
 | 
					        android:orderInCategory="100"
 | 
				
			||||||
        android:title="@string/action_millis"
 | 
					        android:title="@string/action_millis"
 | 
				
			||||||
        app:showAsAction="never"
 | 
					 | 
				
			||||||
        android:checkable="true" />
 | 
					        android:checkable="true" />
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    <item
 | 
					    <item
 | 
				
			||||||
        android:id="@+id/action_enable_ads"
 | 
					        android:id="@+id/action_enable_ads"
 | 
				
			||||||
        android:orderInCategory="150"
 | 
					        android:orderInCategory="150"
 | 
				
			||||||
        android:title="@string/action_enable_ads"
 | 
					        android:title="@string/action_enable_ads"
 | 
				
			||||||
        app:showAsAction="never"
 | 
					 | 
				
			||||||
        android:checkable="true" />
 | 
					        android:checkable="true" />
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    <item
 | 
					    <item
 | 
				
			||||||
        android:id="@+id/action_exit"
 | 
					        android:id="@+id/action_exit"
 | 
				
			||||||
        android:orderInCategory="500"
 | 
					        android:orderInCategory="500"
 | 
				
			||||||
        android:title="@string/action_exit"
 | 
					        android:title="@string/action_exit"
 | 
				
			||||||
        app:showAsAction="never" />
 | 
					        />
 | 
				
			||||||
 | 
					
 | 
				
			||||||
</menu>
 | 
					</menu>
 | 
				
			||||||
@@ -1,7 +1,7 @@
 | 
				
			|||||||
<resources>
 | 
					<resources>
 | 
				
			||||||
    <!-- App details -->
 | 
					    <!-- App details -->
 | 
				
			||||||
    <string name="appName">Infinite Timer</string>
 | 
					    <string name="appName">Infinite Timer</string>
 | 
				
			||||||
    <string name="appVersion">Test v201610291024</string>
 | 
					    <string name="appVersion">Test v20250711</string>
 | 
				
			||||||
    <string name="TAG">com.hyperling.apps.infinitetimer</string>
 | 
					    <string name="TAG">com.hyperling.apps.infinitetimer</string>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    <!-- Keys -->
 | 
					    <!-- Keys -->
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,17 +0,0 @@
 | 
				
			|||||||
package com.hyperling.apps.infinitetimer.deleteme;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
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);
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@@ -2,7 +2,10 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
buildscript {
 | 
					buildscript {
 | 
				
			||||||
    repositories {
 | 
					    repositories {
 | 
				
			||||||
        jcenter()
 | 
					        mavenCentral()
 | 
				
			||||||
 | 
					        maven {
 | 
				
			||||||
 | 
					            url 'https://jitpack.io'
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
        google()
 | 
					        google()
 | 
				
			||||||
        maven {
 | 
					        maven {
 | 
				
			||||||
            url 'https://maven.google.com/'
 | 
					            url 'https://maven.google.com/'
 | 
				
			||||||
@@ -10,7 +13,7 @@ buildscript {
 | 
				
			|||||||
        }
 | 
					        }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    dependencies {
 | 
					    dependencies {
 | 
				
			||||||
        classpath 'com.android.tools.build:gradle:3.2.1'
 | 
					        classpath 'com.android.tools.build:gradle:8.11.1'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        // NOTE: Do not place your application dependencies here; they belong
 | 
					        // NOTE: Do not place your application dependencies here; they belong
 | 
				
			||||||
        // in the individual module build.gradle files
 | 
					        // in the individual module build.gradle files
 | 
				
			||||||
@@ -19,7 +22,7 @@ buildscript {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
allprojects {
 | 
					allprojects {
 | 
				
			||||||
    repositories {
 | 
					    repositories {
 | 
				
			||||||
        jcenter()
 | 
					        mavenCentral()
 | 
				
			||||||
        google()
 | 
					        google()
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										4
									
								
								gradle/wrapper/gradle-wrapper.properties
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										4
									
								
								gradle/wrapper/gradle-wrapper.properties
									
									
									
									
										vendored
									
									
								
							@@ -1,6 +1,6 @@
 | 
				
			|||||||
#Thu Jan 10 06:37:42 CST 2019
 | 
					#Fri Jul 11 12:55:34 MST 2025
 | 
				
			||||||
distributionBase=GRADLE_USER_HOME
 | 
					distributionBase=GRADLE_USER_HOME
 | 
				
			||||||
distributionPath=wrapper/dists
 | 
					distributionPath=wrapper/dists
 | 
				
			||||||
 | 
					distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
 | 
				
			||||||
zipStoreBase=GRADLE_USER_HOME
 | 
					zipStoreBase=GRADLE_USER_HOME
 | 
				
			||||||
zipStorePath=wrapper/dists
 | 
					zipStorePath=wrapper/dists
 | 
				
			||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip
 | 
					 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user