Loading app/build.gradle +1 −1 Original line number Diff line number Diff line Loading @@ -5,7 +5,7 @@ android { buildToolsVersion "27.0.3" defaultConfig { applicationId "org.lineageos.recorder" minSdkVersion 26 minSdkVersion 24 targetSdkVersion 27 versionCode 1 versionName "1.1" Loading app/src/main/AndroidManifest.xml +1 −1 Original line number Diff line number Diff line Loading @@ -27,7 +27,7 @@ <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /> <!-- This is needed for aosp build env --> <uses-sdk android:minSdkVersion='25' <uses-sdk android:minSdkVersion='24' tools:ignore="GradleOverrides" /> <application Loading app/src/main/java/org/lineageos/recorder/screen/OverlayService.java +8 −0 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ import android.app.NotificationManager; import android.app.PendingIntent; import android.app.Service; import android.content.Intent; import android.os.Build; import android.os.IBinder; import android.support.v4.app.NotificationCompat; Loading Loading @@ -82,6 +83,13 @@ public class OverlayService extends Service { super.onCreate(); NotificationManager notificationManager = getSystemService(NotificationManager.class); if (Build.VERSION.SDK_INT < Build.VERSION_CODES.O || notificationManager == null || notificationManager .getNotificationChannel(SCREENCAST_OVERLAY_NOTIFICATION_CHANNEL) != null) { return; } CharSequence name = getString(R.string.screen_overlay_channel_title); String description = getString(R.string.screen_overlay_channel_desc); NotificationChannel notificationChannel = Loading app/src/main/java/org/lineageos/recorder/screen/ScreencastService.java +13 −5 Original line number Diff line number Diff line Loading @@ -27,6 +27,7 @@ import android.content.IntentFilter; import android.graphics.Point; import android.hardware.display.DisplayManager; import android.hardware.display.VirtualDisplay; import android.os.Build; import android.os.Environment; import android.os.IBinder; import android.os.StatFs; Loading Loading @@ -113,7 +114,19 @@ public class ScreencastService extends Service { public void onCreate() { super.onCreate(); IntentFilter filter = new IntentFilter(); filter.addAction(Intent.ACTION_USER_BACKGROUND); filter.addAction(Intent.ACTION_SHUTDOWN); registerReceiver(mBroadcastReceiver, filter); mNotificationManager = getSystemService(NotificationManager.class); if (Build.VERSION.SDK_INT < Build.VERSION_CODES.O || mNotificationManager == null || mNotificationManager.getNotificationChannel( SCREENCAST_NOTIFICATION_CHANNEL) != null) { return; } CharSequence name = getString(R.string.screen_channel_title); String description = getString(R.string.screen_channel_desc); NotificationChannel notificationChannel = Loading @@ -121,11 +134,6 @@ public class ScreencastService extends Service { name, NotificationManager.IMPORTANCE_LOW); notificationChannel.setDescription(description); mNotificationManager.createNotificationChannel(notificationChannel); IntentFilter filter = new IntentFilter(); filter.addAction(Intent.ACTION_USER_BACKGROUND); filter.addAction(Intent.ACTION_SHUTDOWN); registerReceiver(mBroadcastReceiver, filter); } @Override Loading app/src/main/java/org/lineageos/recorder/sounds/SoundRecorderService.java +10 −2 Original line number Diff line number Diff line Loading @@ -27,6 +27,7 @@ import android.content.IntentFilter; import android.media.AudioFormat; import android.media.AudioRecord; import android.media.MediaRecorder; import android.os.Build; import android.os.Environment; import android.os.IBinder; import android.support.v4.app.NotificationCompat; Loading Loading @@ -111,7 +112,16 @@ public class SoundRecorderService extends Service { public void onCreate() { super.onCreate(); registerReceiver(mShutdownReceiver, new IntentFilter(Intent.ACTION_SHUTDOWN)); mNotificationManager = getSystemService(NotificationManager.class); if (Build.VERSION.SDK_INT < Build.VERSION_CODES.O || mNotificationManager == null || mNotificationManager.getNotificationChannel( SOUNDRECORDER_NOTIFICATION_CHANNEL) != null) { return; } CharSequence name = getString(R.string.sound_channel_title); String description = getString(R.string.sound_channel_desc); NotificationChannel notificationChannel = Loading @@ -119,8 +129,6 @@ public class SoundRecorderService extends Service { name, NotificationManager.IMPORTANCE_LOW); notificationChannel.setDescription(description); mNotificationManager.createNotificationChannel(notificationChannel); registerReceiver(mShutdownReceiver, new IntentFilter(Intent.ACTION_SHUTDOWN)); } @Override Loading Loading
app/build.gradle +1 −1 Original line number Diff line number Diff line Loading @@ -5,7 +5,7 @@ android { buildToolsVersion "27.0.3" defaultConfig { applicationId "org.lineageos.recorder" minSdkVersion 26 minSdkVersion 24 targetSdkVersion 27 versionCode 1 versionName "1.1" Loading
app/src/main/AndroidManifest.xml +1 −1 Original line number Diff line number Diff line Loading @@ -27,7 +27,7 @@ <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /> <!-- This is needed for aosp build env --> <uses-sdk android:minSdkVersion='25' <uses-sdk android:minSdkVersion='24' tools:ignore="GradleOverrides" /> <application Loading
app/src/main/java/org/lineageos/recorder/screen/OverlayService.java +8 −0 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ import android.app.NotificationManager; import android.app.PendingIntent; import android.app.Service; import android.content.Intent; import android.os.Build; import android.os.IBinder; import android.support.v4.app.NotificationCompat; Loading Loading @@ -82,6 +83,13 @@ public class OverlayService extends Service { super.onCreate(); NotificationManager notificationManager = getSystemService(NotificationManager.class); if (Build.VERSION.SDK_INT < Build.VERSION_CODES.O || notificationManager == null || notificationManager .getNotificationChannel(SCREENCAST_OVERLAY_NOTIFICATION_CHANNEL) != null) { return; } CharSequence name = getString(R.string.screen_overlay_channel_title); String description = getString(R.string.screen_overlay_channel_desc); NotificationChannel notificationChannel = Loading
app/src/main/java/org/lineageos/recorder/screen/ScreencastService.java +13 −5 Original line number Diff line number Diff line Loading @@ -27,6 +27,7 @@ import android.content.IntentFilter; import android.graphics.Point; import android.hardware.display.DisplayManager; import android.hardware.display.VirtualDisplay; import android.os.Build; import android.os.Environment; import android.os.IBinder; import android.os.StatFs; Loading Loading @@ -113,7 +114,19 @@ public class ScreencastService extends Service { public void onCreate() { super.onCreate(); IntentFilter filter = new IntentFilter(); filter.addAction(Intent.ACTION_USER_BACKGROUND); filter.addAction(Intent.ACTION_SHUTDOWN); registerReceiver(mBroadcastReceiver, filter); mNotificationManager = getSystemService(NotificationManager.class); if (Build.VERSION.SDK_INT < Build.VERSION_CODES.O || mNotificationManager == null || mNotificationManager.getNotificationChannel( SCREENCAST_NOTIFICATION_CHANNEL) != null) { return; } CharSequence name = getString(R.string.screen_channel_title); String description = getString(R.string.screen_channel_desc); NotificationChannel notificationChannel = Loading @@ -121,11 +134,6 @@ public class ScreencastService extends Service { name, NotificationManager.IMPORTANCE_LOW); notificationChannel.setDescription(description); mNotificationManager.createNotificationChannel(notificationChannel); IntentFilter filter = new IntentFilter(); filter.addAction(Intent.ACTION_USER_BACKGROUND); filter.addAction(Intent.ACTION_SHUTDOWN); registerReceiver(mBroadcastReceiver, filter); } @Override Loading
app/src/main/java/org/lineageos/recorder/sounds/SoundRecorderService.java +10 −2 Original line number Diff line number Diff line Loading @@ -27,6 +27,7 @@ import android.content.IntentFilter; import android.media.AudioFormat; import android.media.AudioRecord; import android.media.MediaRecorder; import android.os.Build; import android.os.Environment; import android.os.IBinder; import android.support.v4.app.NotificationCompat; Loading Loading @@ -111,7 +112,16 @@ public class SoundRecorderService extends Service { public void onCreate() { super.onCreate(); registerReceiver(mShutdownReceiver, new IntentFilter(Intent.ACTION_SHUTDOWN)); mNotificationManager = getSystemService(NotificationManager.class); if (Build.VERSION.SDK_INT < Build.VERSION_CODES.O || mNotificationManager == null || mNotificationManager.getNotificationChannel( SOUNDRECORDER_NOTIFICATION_CHANNEL) != null) { return; } CharSequence name = getString(R.string.sound_channel_title); String description = getString(R.string.sound_channel_desc); NotificationChannel notificationChannel = Loading @@ -119,8 +129,6 @@ public class SoundRecorderService extends Service { name, NotificationManager.IMPORTANCE_LOW); notificationChannel.setDescription(description); mNotificationManager.createNotificationChannel(notificationChannel); registerReceiver(mShutdownReceiver, new IntentFilter(Intent.ACTION_SHUTDOWN)); } @Override Loading