Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 59fa1f1

Browse files
Smart Alarm
1 parent 99ac985 commit 59fa1f1

File tree

3 files changed

+37
-0
lines changed

3 files changed

+37
-0
lines changed

‎app/src/main/AndroidManifest.xml‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@
1212
android:supportsRtl="true"
1313
android:theme="@style/Theme.SmartAlarm"
1414
tools:targetApi="31">
15+
<activity
16+
android:name=".EditAlarm"
17+
android:exported="false" />
1518
<activity
1619
android:name=".MainActivity"
1720
android:exported="true">
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
package it.ezzie.smartalarm;
2+
3+
import android.os.Bundle;
4+
5+
import androidx.activity.EdgeToEdge;
6+
import androidx.appcompat.app.AppCompatActivity;
7+
import androidx.core.graphics.Insets;
8+
import androidx.core.view.ViewCompat;
9+
import androidx.core.view.WindowInsetsCompat;
10+
11+
public class EditAlarm extends AppCompatActivity {
12+
13+
@Override
14+
protected void onCreate(Bundle savedInstanceState) {
15+
super.onCreate(savedInstanceState);
16+
EdgeToEdge.enable(this);
17+
setContentView(R.layout.activity_edit_alarm);
18+
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main), (v, insets) -> {
19+
Insets systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars());
20+
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom);
21+
return insets;
22+
});
23+
}
24+
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
3+
xmlns:app="http://schemas.android.com/apk/res-auto"
4+
xmlns:tools="http://schemas.android.com/tools"
5+
android:id="@+id/main"
6+
android:layout_width="match_parent"
7+
android:layout_height="match_parent"
8+
tools:context=".EditAlarm">
9+
10+
</androidx.constraintlayout.widget.ConstraintLayout>

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /