Adding Notification and re-arranging packages

This commit is contained in:
z3r0c00l-2k 2019-05-19 18:18:26 +05:30
parent fde54da1e0
commit 4cb8333942
28 changed files with 420 additions and 6 deletions

View file

@ -3,6 +3,9 @@
xmlns:tools="http://schemas.android.com/tools"
package="io.github.z3r0c00l_2k.aquadroid">
<uses-permission android:name="android.permission.VIBRATE"/>
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/>
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
@ -23,6 +26,12 @@
<activity android:name=".MainActivity"
android:theme="@style/MainTheme">
</activity>
<receiver android:name=".recievers.NotifierReceiver"/>
<receiver android:name=".recievers.BootReceiver">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED"/>
</intent-filter>
</receiver>
</application>
</manifest>

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

View file

@ -11,6 +11,7 @@ import android.view.View
import android.view.inputmethod.InputMethodManager
import androidx.appcompat.app.AppCompatActivity
import com.google.android.material.snackbar.Snackbar
import io.github.z3r0c00l_2k.aquadroid.utils.AppUtils
import kotlinx.android.synthetic.main.activity_init_user_info.*
import java.math.RoundingMode
import java.text.DecimalFormat

View file

@ -5,6 +5,10 @@ import android.content.SharedPreferences
import android.os.Bundle
import androidx.appcompat.app.AppCompatActivity
import com.google.android.material.snackbar.Snackbar
import io.github.z3r0c00l_2k.aquadroid.fragments.BottomSheetFragment
import io.github.z3r0c00l_2k.aquadroid.helpers.AlarmHelper
import io.github.z3r0c00l_2k.aquadroid.helpers.SqliteHelper
import io.github.z3r0c00l_2k.aquadroid.utils.AppUtils
import kotlinx.android.synthetic.main.activity_main.*
@ -78,6 +82,11 @@ class MainActivity : AppCompatActivity() {
}
}
val alarm = AlarmHelper()
alarm.cancelAlarm(this)
alarm.setAlarm(this, sharedPref.getInt(AppUtils.NOTIFICATION_FREQUENCY_KEY, 30).toLong())
}
private fun setWaterLevel(inTook: Int, totalIntake: Int) {

View file

@ -6,6 +6,7 @@ import android.os.Bundle
import android.view.Window
import android.view.WindowManager
import androidx.appcompat.app.AppCompatActivity
import io.github.z3r0c00l_2k.aquadroid.utils.AppUtils
class SplashActivity : AppCompatActivity() {

View file

@ -1,4 +1,4 @@
package io.github.z3r0c00l_2k.aquadroid
package io.github.z3r0c00l_2k.aquadroid.fragments
import android.app.TimePickerDialog
import android.content.Context
@ -10,6 +10,8 @@ import android.view.View
import android.view.ViewGroup
import android.widget.Toast
import com.google.android.material.bottomsheet.BottomSheetDialogFragment
import io.github.z3r0c00l_2k.aquadroid.R
import io.github.z3r0c00l_2k.aquadroid.utils.AppUtils
import kotlinx.android.synthetic.main.bottom_sheet_fragment.*
import java.math.RoundingMode
import java.text.DecimalFormat

View file

@ -0,0 +1,75 @@
package io.github.z3r0c00l_2k.aquadroid.helpers
import android.app.AlarmManager
import android.app.PendingIntent
import android.content.ComponentName
import android.content.Context
import android.content.Intent
import android.content.pm.PackageManager
import android.util.Log
import io.github.z3r0c00l_2k.aquadroid.recievers.BootReceiver
import io.github.z3r0c00l_2k.aquadroid.recievers.NotifierReceiver
import java.util.concurrent.TimeUnit
class AlarmHelper {
private var alarmManager: AlarmManager? = null
private val ACTION_BD_NOTIFICATION = "io.github.z3r0c00l_2k.aquadroid.NOTIFICATION"
fun setAlarm(context: Context, notificationFrequency: Long) {
val notificationFrequencyMs = TimeUnit.MINUTES.toMillis(notificationFrequency)
alarmManager = context.getSystemService(Context.ALARM_SERVICE) as AlarmManager
val alarmIntent = Intent(context, NotifierReceiver::class.java)
alarmIntent.action = ACTION_BD_NOTIFICATION
val pendingAlarmIntent = PendingIntent.getBroadcast(
context,
0,
alarmIntent,
PendingIntent.FLAG_UPDATE_CURRENT
)
Log.i("AlarmHelper", "Setting Alarm Interval to: $notificationFrequency minutes")
alarmManager!!.setRepeating(
AlarmManager.RTC_WAKEUP,
System.currentTimeMillis(),
notificationFrequencyMs,
pendingAlarmIntent
)
/* Restart if rebooted */
val receiver = ComponentName(context, BootReceiver::class.java)
context.packageManager.setComponentEnabledSetting(
receiver,
PackageManager.COMPONENT_ENABLED_STATE_ENABLED,
PackageManager.DONT_KILL_APP
)
}
fun cancelAlarm(context: Context) {
alarmManager = context.getSystemService(Context.ALARM_SERVICE) as AlarmManager
val alarmIntent = Intent(context, NotifierReceiver::class.java)
alarmIntent.action = ACTION_BD_NOTIFICATION
val pendingAlarmIntent = PendingIntent.getBroadcast(
context,
0,
alarmIntent,
PendingIntent.FLAG_UPDATE_CURRENT
)
alarmManager!!.cancel(pendingAlarmIntent)
/* Alarm won't start again if device is rebooted */
val receiver = ComponentName(context, BootReceiver::class.java)
val pm = context.packageManager
pm.setComponentEnabledSetting(
receiver,
PackageManager.COMPONENT_ENABLED_STATE_DISABLED,
PackageManager.DONT_KILL_APP
)
}
}

View file

@ -0,0 +1,148 @@
package io.github.z3r0c00l_2k.aquadroid.helpers
import android.app.Notification
import android.app.NotificationChannel
import android.app.NotificationManager
import android.content.Context
import android.graphics.BitmapFactory
import android.graphics.Color
import android.media.AudioAttributes
import android.net.Uri
import android.os.Build
import android.preference.PreferenceManager
import android.util.Log
import io.github.z3r0c00l_2k.aquadroid.R
import io.github.z3r0c00l_2k.aquadroid.utils.AppUtils
import java.util.*
class NotificationHelper(val ctx: Context) {
private var notificationManager: NotificationManager? = null
private val CHANNEL_ONE_ID = "io.github.z3r0c00l_2k.aquadroid.CHANNELONE"
private val CHANNEL_ONE_NAME = "Channel One"
private fun createChannels() {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
val prefs = ctx.getSharedPreferences(AppUtils.USERS_SHARED_PREF, AppUtils.PRIVATE_MODE)
val notificationsNewMessageRingtone = prefs.getString("notifications_new_message_ringtone", "")
val notificationChannel = NotificationChannel(
CHANNEL_ONE_ID,
CHANNEL_ONE_NAME, NotificationManager.IMPORTANCE_HIGH
)
notificationChannel.enableLights(true)
notificationChannel.lightColor = Color.BLUE
notificationChannel.setShowBadge(true)
notificationChannel.lockscreenVisibility = Notification.VISIBILITY_PUBLIC
if (notificationsNewMessageRingtone!!.isNotEmpty()) {
val audioAttributes = AudioAttributes.Builder()
.setContentType(AudioAttributes.CONTENT_TYPE_MUSIC)
.setUsage(AudioAttributes.USAGE_NOTIFICATION)
.build()
notificationChannel.setSound(Uri.parse(notificationsNewMessageRingtone), audioAttributes)
}
getManager()!!.createNotificationChannel(notificationChannel)
}
}
fun getNotification(
title: String,
body: String
): Notification.Builder {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
return Notification.Builder(ctx.applicationContext, CHANNEL_ONE_ID)
.setContentTitle(title)
.setContentText(body)
.setColorized(true)
.setColor(Color.BLUE)
.setShowWhen(true)
.setLargeIcon(
BitmapFactory.decodeResource(
ctx.resources,
R.mipmap.ic_launcher
)
)
.setSmallIcon(R.drawable.ic_small_logo)
.setAutoCancel(true)
} else {
val prefs = PreferenceManager.getDefaultSharedPreferences(ctx)
val notificationsNewMessageRingtone = prefs.getString("notifications_new_message_ringtone", "")
val notification = Notification.Builder(ctx.applicationContext)
.setContentTitle(title)
.setContentText(body)
.setLargeIcon(
BitmapFactory.decodeResource(
ctx.resources,
R.mipmap.ic_launcher
)
)
.setSmallIcon(R.drawable.ic_small_logo)
.setAutoCancel(true)
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR1) {
notification.setShowWhen(true)
}
if (notificationsNewMessageRingtone!!.length > 0) {
notification.setSound(Uri.parse(notificationsNewMessageRingtone))
}
return notification
}
}
private fun shallNotify(): Boolean {
val prefs = ctx.getSharedPreferences(AppUtils.USERS_SHARED_PREF, AppUtils.PRIVATE_MODE)
val notificationsNewMessage = prefs.getBoolean("notifications_new_message", true)
var doNotDisturbOff = true
val startTimestamp = prefs.getLong("pref_notification_start", 0)
val stopTimestamp = prefs.getLong("pref_notification_stop", 0)
if (startTimestamp > 0 && stopTimestamp > 0) {
val now = Calendar.getInstance().time
val start = Date(startTimestamp)
val stop = Date(stopTimestamp)
doNotDisturbOff = compareTimes(now, start) >= 0 && compareTimes(now, stop) <= 0
}
return notificationsNewMessage && doNotDisturbOff
}
/* Thanks to:
* https://stackoverflow.com/questions/7676149/compare-only-the-time-portion-of-two-dates-ignoring-the-date-part
*/
private fun compareTimes(currentTime: Date, timeToRun: Date): Long {
val currentCal = Calendar.getInstance()
currentCal.time = currentTime
val runCal = Calendar.getInstance()
runCal.time = timeToRun
runCal.set(Calendar.DAY_OF_MONTH, currentCal.get(Calendar.DAY_OF_MONTH))
runCal.set(Calendar.MONTH, currentCal.get(Calendar.MONTH))
runCal.set(Calendar.YEAR, currentCal.get(Calendar.YEAR))
return currentCal.timeInMillis - runCal.timeInMillis
}
fun notify(id: Long, notification: Notification.Builder) {
if (shallNotify()) {
getManager()!!.notify(id.toInt(), notification.build())
} else {
Log.i("WateryDroid", "dnd period")
}
}
private fun getManager(): NotificationManager? {
if (notificationManager == null) {
notificationManager = ctx.getSystemService(Context.NOTIFICATION_SERVICE) as NotificationManager
}
return notificationManager
}
}

View file

@ -1,11 +1,15 @@
package io.github.z3r0c00l_2k.aquadroid
package io.github.z3r0c00l_2k.aquadroid.helpers
import android.content.ContentValues
import android.content.Context
import android.database.sqlite.SQLiteDatabase
import android.database.sqlite.SQLiteOpenHelper
class SqliteHelper(context: Context) : SQLiteOpenHelper(context, DATABASE_NAME, null, DATABASE_VERSION) {
class SqliteHelper(context: Context) : SQLiteOpenHelper(
context,
DATABASE_NAME, null,
DATABASE_VERSION
) {
companion object {
private val DATABASE_VERSION = 1

View file

@ -0,0 +1,25 @@
package io.github.z3r0c00l_2k.aquadroid.recievers
import android.content.BroadcastReceiver
import android.content.Context
import android.content.Intent
import io.github.z3r0c00l_2k.aquadroid.helpers.AlarmHelper
import io.github.z3r0c00l_2k.aquadroid.utils.AppUtils
class BootReceiver : BroadcastReceiver() {
private val alarm = AlarmHelper()
override fun onReceive(context: Context?, intent: Intent?) {
if (intent != null && intent.action != null) {
if (intent.action == "android.intent.action.BOOT_COMPLETED") {
val prefs = context!!.getSharedPreferences(AppUtils.USERS_SHARED_PREF, AppUtils.PRIVATE_MODE)
val notificationFrequency = prefs.getInt(AppUtils.NOTIFICATION_FREQUENCY_KEY, 60)
val notificationsNewMessage = prefs.getBoolean("notifications_new_message", true)
alarm.cancelAlarm(context)
if (notificationsNewMessage) {
alarm.setAlarm(context, notificationFrequency.toLong())
}
}
}
}
}

View file

@ -0,0 +1,30 @@
package io.github.z3r0c00l_2k.aquadroid.recievers
import android.annotation.SuppressLint
import android.content.BroadcastReceiver
import android.content.Context
import android.content.Intent
import io.github.z3r0c00l_2k.aquadroid.R
import io.github.z3r0c00l_2k.aquadroid.helpers.NotificationHelper
import io.github.z3r0c00l_2k.aquadroid.utils.AppUtils
class NotifierReceiver : BroadcastReceiver() {
override fun onReceive(context: Context, intent: Intent) {
val prefs = context.getSharedPreferences(AppUtils.USERS_SHARED_PREF, AppUtils.PRIVATE_MODE)
val title = context.resources.getString(R.string.app_name)
val messageToShow = prefs.getString(
"message_to_show",
context.resources.getString(R.string.pref_notification_message_value)
)
/* Notify */
val nHelper = NotificationHelper(context)
@SuppressLint("ResourceType") val nBuilder = nHelper
.getNotification(title, messageToShow)
nHelper.notify(1, nBuilder)
}
}

View file

@ -1,4 +1,4 @@
package io.github.z3r0c00l_2k.aquadroid
package io.github.z3r0c00l_2k.aquadroid.utils
import java.text.SimpleDateFormat
import java.util.*

View file

@ -0,0 +1,72 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="108dp"
android:height="108dp"
android:viewportWidth="1024"
android:viewportHeight="1024">
<group android:translateX="256"
android:translateY="256">
<path
android:pathData="M152.063,151.296l80.156,-104.204l48.094,0l80.157,104.204z"
android:fillColor="#BAF0FF"/>
<path
android:pathData="M232.219,47.092l-80.156,104.204l21.041,0l80.156,-104.204z"
android:fillColor="#8ADEFF"/>
<path
android:pathData="M219.887,63.123l12.332,-16.031l48.094,0l12.332,16.032z"
android:fillColor="#8ADEFF"/>
<path
android:pathData="M360.47,151.296l-208.407,0l12.334,-16.032l183.738,0z"
android:fillColor="#8ADEFF"/>
<path
android:pathData="M360.47,223.436v-72.141H152.062v72.141c0,17.708 14.355,32.063 32.063,32.063h-4.008c-15.494,0 -28.055,12.561 -28.055,28.055l0,0c0,15.494 12.561,28.055 28.055,28.055c-15.494,0 -28.055,12.561 -28.055,28.055l0,0c0,15.494 12.561,28.055 28.055,28.055h4.008c-17.708,0 -32.063,14.355 -32.063,32.063v64.125c0,17.708 14.355,32.063 32.063,32.063h42.929c5.651,4.985 13.068,8.016 21.196,8.016h16.031c8.128,0 15.544,-3.031 21.196,-8.016h42.929c17.708,0 32.063,-14.355 32.063,-32.063v-64.125c0,-17.708 -14.355,-32.063 -32.063,-32.063h4.008c15.494,0 28.055,-12.561 28.055,-28.055l0,0c0,-15.494 -12.561,-28.055 -28.055,-28.055c15.494,0 28.055,-12.561 28.055,-28.055l0,0c0,-15.494 -12.561,-28.055 -28.055,-28.055h-4.008C346.115,255.499 360.47,241.144 360.47,223.436z"
android:fillColor="#8ADEFF"/>
<path
android:pathData="M172.102,463.906v-64.125c0,-17.708 14.355,-32.063 32.063,-32.063h-4.008c-15.494,0 -28.055,-12.561 -28.055,-28.055c0,-15.494 12.561,-28.055 28.055,-28.055c-15.494,0 -28.055,-12.561 -28.055,-28.055c0,-15.494 12.561,-28.055 28.055,-28.055h4.008c-17.708,0 -32.063,-14.355 -32.063,-32.063v-72.141h-20.039v72.141c0,17.708 14.355,32.063 32.063,32.063h-4.008c-15.494,0 -28.055,12.561 -28.055,28.055c0,15.494 12.561,28.055 28.055,28.055c-15.494,0 -28.055,12.561 -28.055,28.055c0,15.494 12.561,28.055 28.055,28.055h4.008c-17.708,0 -32.063,14.355 -32.063,32.063v64.125c0,17.708 14.355,32.063 32.063,32.063h20.039C186.456,495.969 172.102,481.614 172.102,463.906z"
android:fillColor="#2FB6EB"/>
<path
android:pathData="M247.093,495.969h-20.039c5.651,4.985 13.068,8.016 21.196,8.016h16.031c0.673,0 1.341,-0.028 2.004,-0.069C258.945,503.461 252.276,500.541 247.093,495.969z"
android:fillColor="#2FB6EB"/>
<path
android:pathData="M328.407,367.718H184.125c-17.708,0 -32.063,14.355 -32.063,32.063v64.125c0,17.708 14.355,32.063 32.063,32.063h42.929c5.651,4.985 13.068,8.016 21.196,8.016h16.031c8.128,0 15.544,-3.031 21.196,-8.016h42.929c17.708,0 32.063,-14.355 32.063,-32.063v-64.125C360.47,382.073 346.115,367.718 328.407,367.718z"
android:fillColor="#2FB6EB"/>
<path
android:pathData="M332.415,311.609H180.117c-15.494,0 -28.055,-12.561 -28.055,-28.055l0,0c0,-15.494 12.561,-28.055 28.055,-28.055h152.297c15.494,0 28.055,12.561 28.055,28.055l0,0C360.47,299.048 347.909,311.609 332.415,311.609z"
android:fillColor="#2FB6EB"/>
<path
android:pathData="M172.102,463.906v-64.125c0,-17.708 14.355,-32.063 32.063,-32.063h-20.039c-17.708,0 -32.063,14.355 -32.063,32.063v64.125c0,17.708 14.355,32.063 32.063,32.063h20.039C186.456,495.969 172.102,481.614 172.102,463.906z"
android:fillColor="#0097C6"/>
<path
android:pathData="M247.093,495.969h-20.039c5.651,4.985 13.068,8.016 21.196,8.016h16.031c0.673,0 1.341,-0.028 2.004,-0.069C258.945,503.461 252.276,500.541 247.093,495.969z"
android:fillColor="#00A1D3"/>
<path
android:pathData="M172.102,283.554c0,-15.494 12.561,-28.055 28.055,-28.055h-20.039c-15.494,0 -28.055,12.561 -28.055,28.055c0,15.494 12.561,28.055 28.055,28.055h20.039C184.662,311.609 172.102,299.048 172.102,283.554z"
android:fillColor="#0097C6"/>
<path
android:pathData="M208.176,7.014h96.188v40.078h-96.188z"
android:fillColor="#FF6243"/>
<path
android:pathData="M208.176,7.014h16.031v40.078h-16.031z"
android:fillColor="#D80027"/>
<path
android:pathData="M208.176,31.061h96.188v16.031h-96.188z"
android:fillColor="#D80027"/>
<path
android:fillColor="#FF000000"
android:pathData="M367.859,339.663c0,-11.391 -5.325,-21.54 -13.68,-28.055c8.354,-6.515 13.774,-16.664 13.774,-28.055c0,-11.993 -6.207,-22.611 -15.328,-29.058c9.183,-7.254 14.858,-18.476 14.858,-31.06V148.74l-71.909,-93.632h15.8V0H200.156v55.108h16.801l-72.91,93.632v74.697c0,12.584 6.161,23.805 15.344,31.06c-9.121,6.447 -14.968,17.064 -14.968,29.058c0,11.391 5.451,21.54 13.805,28.055c-8.354,6.515 -13.711,16.664 -13.711,28.055c0,11.993 5.737,22.611 14.858,29.058c-9.183,7.254 -15.328,18.476 -15.328,31.06v64.125c0,21.823 18.256,40.078 40.078,40.078h40.078v-0.659c6.671,5.12 15.007,8.675 24.047,8.675h16.031c9.04,0 17.376,-3.554 24.047,-8.675v0.659h40.078c21.823,0 39.076,-18.256 39.076,-40.078v-64.125c0,-12.584 -5.66,-23.806 -14.843,-31.06C361.761,362.275 367.859,351.657 367.859,339.663zM215.186,40.078V15.029h81.159v25.049H215.186zM235.919,55.108h40.692l68.596,89.174H167.323M332.415,319.624c11.326,0 20.54,9.214 20.54,20.54c0,11.326 -9.214,20.54 -20.54,20.54h-20.039v15.029h16.031c13.536,0 24.047,10.511 24.047,24.047v64.125c0,13.536 -10.511,25.049 -24.047,25.049h-28.18c2.325,-6.012 3.632,-11.134 3.632,-17.033H288.83c0,13.536 -11.012,25.049 -24.548,25.049H248.25c-13.535,0 -24.548,-11.512 -24.548,-25.049h-15.029c0,5.9 1.308,11.022 3.632,17.033h-28.18c-13.535,0 -25.049,-11.512 -25.049,-25.049v-64.125c0,-13.536 11.513,-24.047 25.049,-24.047h80.157v-15.029h-84.164c-11.326,0 -20.54,-9.214 -20.54,-20.54c0,-11.326 9.214,-20.54 20.54,-20.54h84.164v-15.029h-84.164c-11.326,0 -20.54,-9.214 -20.54,-20.54c0,-11.326 9.214,-20.54 20.54,-20.54h84.164v-15.029h-80.157c-13.535,0 -25.049,-11.512 -25.049,-25.049v-64.125h193.378v64.125c0,13.536 -10.511,25.049 -24.047,25.049h-16.031v15.029h20.039c11.326,0 20.54,9.214 20.54,20.54c0,11.326 -9.214,20.54 -20.54,20.54h-20.039v15.029H332.415z"/>
<path
android:pathData="M200.16,111.718h16.031v15.029h-16.031z"
android:fillColor="#FFFFFF"/>
<path
android:pathData="M216.192,95.687h16.031v15.029h-16.031z"
android:fillColor="#FFFFFF"/>
<path
android:pathData="M280.317,304.094h16.031v15.029h-16.031z"
android:fillColor="#FFFFFF"/>
<path
android:pathData="M280.317,247.984h16.031v15.029h-16.031z"
android:fillColor="#FFFFFF"/>
<path
android:pathData="M280.317,360.204h16.031v15.029h-16.031z"
android:fillColor="#FFFFFF"/>
</group>
</vector>

View file

@ -0,0 +1,33 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:height="24dp"
android:viewportHeight="512" android:viewportWidth="512" android:width="24dp">
<path android:fillColor="#BAF0FF" android:pathData="M152.063,151.296l80.156,-104.204l48.094,0l80.157,104.204z"/>
<path android:fillColor="#8ADEFF" android:pathData="M232.219,47.092l-80.156,104.204l21.041,0l80.156,-104.204z"/>
<path android:fillColor="#8ADEFF" android:pathData="M219.887,63.123l12.332,-16.031l48.094,0l12.332,16.032z"/>
<path android:fillColor="#8ADEFF" android:pathData="M360.47,151.296l-208.407,0l12.334,-16.032l183.738,0z"/>
<path android:fillColor="#8ADEFF"
android:pathData="M360.47,223.436v-72.141H152.062v72.141c0,17.708 14.355,32.063 32.063,32.063h-4.008c-15.494,0 -28.055,12.561 -28.055,28.055l0,0c0,15.494 12.561,28.055 28.055,28.055c-15.494,0 -28.055,12.561 -28.055,28.055l0,0c0,15.494 12.561,28.055 28.055,28.055h4.008c-17.708,0 -32.063,14.355 -32.063,32.063v64.125c0,17.708 14.355,32.063 32.063,32.063h42.929c5.651,4.985 13.068,8.016 21.196,8.016h16.031c8.128,0 15.544,-3.031 21.196,-8.016h42.929c17.708,0 32.063,-14.355 32.063,-32.063v-64.125c0,-17.708 -14.355,-32.063 -32.063,-32.063h4.008c15.494,0 28.055,-12.561 28.055,-28.055l0,0c0,-15.494 -12.561,-28.055 -28.055,-28.055c15.494,0 28.055,-12.561 28.055,-28.055l0,0c0,-15.494 -12.561,-28.055 -28.055,-28.055h-4.008C346.115,255.499 360.47,241.144 360.47,223.436z"/>
<path android:fillColor="#2FB6EB"
android:pathData="M172.102,463.906v-64.125c0,-17.708 14.355,-32.063 32.063,-32.063h-4.008c-15.494,0 -28.055,-12.561 -28.055,-28.055c0,-15.494 12.561,-28.055 28.055,-28.055c-15.494,0 -28.055,-12.561 -28.055,-28.055c0,-15.494 12.561,-28.055 28.055,-28.055h4.008c-17.708,0 -32.063,-14.355 -32.063,-32.063v-72.141h-20.039v72.141c0,17.708 14.355,32.063 32.063,32.063h-4.008c-15.494,0 -28.055,12.561 -28.055,28.055c0,15.494 12.561,28.055 28.055,28.055c-15.494,0 -28.055,12.561 -28.055,28.055c0,15.494 12.561,28.055 28.055,28.055h4.008c-17.708,0 -32.063,14.355 -32.063,32.063v64.125c0,17.708 14.355,32.063 32.063,32.063h20.039C186.456,495.969 172.102,481.614 172.102,463.906z"/>
<path android:fillColor="#2FB6EB"
android:pathData="M247.093,495.969h-20.039c5.651,4.985 13.068,8.016 21.196,8.016h16.031c0.673,0 1.341,-0.028 2.004,-0.069C258.945,503.461 252.276,500.541 247.093,495.969z"/>
<path android:fillColor="#2FB6EB"
android:pathData="M328.407,367.718H184.125c-17.708,0 -32.063,14.355 -32.063,32.063v64.125c0,17.708 14.355,32.063 32.063,32.063h42.929c5.651,4.985 13.068,8.016 21.196,8.016h16.031c8.128,0 15.544,-3.031 21.196,-8.016h42.929c17.708,0 32.063,-14.355 32.063,-32.063v-64.125C360.47,382.073 346.115,367.718 328.407,367.718z"/>
<path android:fillColor="#2FB6EB"
android:pathData="M332.415,311.609H180.117c-15.494,0 -28.055,-12.561 -28.055,-28.055l0,0c0,-15.494 12.561,-28.055 28.055,-28.055h152.297c15.494,0 28.055,12.561 28.055,28.055l0,0C360.47,299.048 347.909,311.609 332.415,311.609z"/>
<path android:fillColor="#0097C6"
android:pathData="M172.102,463.906v-64.125c0,-17.708 14.355,-32.063 32.063,-32.063h-20.039c-17.708,0 -32.063,14.355 -32.063,32.063v64.125c0,17.708 14.355,32.063 32.063,32.063h20.039C186.456,495.969 172.102,481.614 172.102,463.906z"/>
<path android:fillColor="#00A1D3"
android:pathData="M247.093,495.969h-20.039c5.651,4.985 13.068,8.016 21.196,8.016h16.031c0.673,0 1.341,-0.028 2.004,-0.069C258.945,503.461 252.276,500.541 247.093,495.969z"/>
<path android:fillColor="#0097C6"
android:pathData="M172.102,283.554c0,-15.494 12.561,-28.055 28.055,-28.055h-20.039c-15.494,0 -28.055,12.561 -28.055,28.055c0,15.494 12.561,28.055 28.055,28.055h20.039C184.662,311.609 172.102,299.048 172.102,283.554z"/>
<path android:fillColor="#FF6243" android:pathData="M208.176,7.014h96.188v40.078h-96.188z"/>
<path android:fillColor="#D80027" android:pathData="M208.176,7.014h16.031v40.078h-16.031z"/>
<path android:fillColor="#D80027" android:pathData="M208.176,31.061h96.188v16.031h-96.188z"/>
<path android:fillColor="#FF000000"
android:pathData="M367.859,339.663c0,-11.391 -5.325,-21.54 -13.68,-28.055c8.354,-6.515 13.774,-16.664 13.774,-28.055c0,-11.993 -6.207,-22.611 -15.328,-29.058c9.183,-7.254 14.858,-18.476 14.858,-31.06V148.74l-71.909,-93.632h15.8V0H200.156v55.108h16.801l-72.91,93.632v74.697c0,12.584 6.161,23.805 15.344,31.06c-9.121,6.447 -14.968,17.064 -14.968,29.058c0,11.391 5.451,21.54 13.805,28.055c-8.354,6.515 -13.711,16.664 -13.711,28.055c0,11.993 5.737,22.611 14.858,29.058c-9.183,7.254 -15.328,18.476 -15.328,31.06v64.125c0,21.823 18.256,40.078 40.078,40.078h40.078v-0.659c6.671,5.12 15.007,8.675 24.047,8.675h16.031c9.04,0 17.376,-3.554 24.047,-8.675v0.659h40.078c21.823,0 39.076,-18.256 39.076,-40.078v-64.125c0,-12.584 -5.66,-23.806 -14.843,-31.06C361.761,362.275 367.859,351.657 367.859,339.663zM215.186,40.078V15.029h81.159v25.049H215.186zM235.919,55.108h40.692l68.596,89.174H167.323M332.415,319.624c11.326,0 20.54,9.214 20.54,20.54c0,11.326 -9.214,20.54 -20.54,20.54h-20.039v15.029h16.031c13.536,0 24.047,10.511 24.047,24.047v64.125c0,13.536 -10.511,25.049 -24.047,25.049h-28.18c2.325,-6.012 3.632,-11.134 3.632,-17.033H288.83c0,13.536 -11.012,25.049 -24.548,25.049H248.25c-13.535,0 -24.548,-11.512 -24.548,-25.049h-15.029c0,5.9 1.308,11.022 3.632,17.033h-28.18c-13.535,0 -25.049,-11.512 -25.049,-25.049v-64.125c0,-13.536 11.513,-24.047 25.049,-24.047h80.157v-15.029h-84.164c-11.326,0 -20.54,-9.214 -20.54,-20.54c0,-11.326 9.214,-20.54 20.54,-20.54h84.164v-15.029h-84.164c-11.326,0 -20.54,-9.214 -20.54,-20.54c0,-11.326 9.214,-20.54 20.54,-20.54h84.164v-15.029h-80.157c-13.535,0 -25.049,-11.512 -25.049,-25.049v-64.125h193.378v64.125c0,13.536 -10.511,25.049 -24.047,25.049h-16.031v15.029h20.039c11.326,0 20.54,9.214 20.54,20.54c0,11.326 -9.214,20.54 -20.54,20.54h-20.039v15.029H332.415z"/>
<path android:fillColor="#FFFFFF" android:pathData="M200.16,111.718h16.031v15.029h-16.031z"/>
<path android:fillColor="#FFFFFF" android:pathData="M216.192,95.687h16.031v15.029h-16.031z"/>
<path android:fillColor="#FFFFFF" android:pathData="M280.317,304.094h16.031v15.029h-16.031z"/>
<path android:fillColor="#FFFFFF" android:pathData="M280.317,247.984h16.031v15.029h-16.031z"/>
<path android:fillColor="#FFFFFF" android:pathData="M280.317,360.204h16.031v15.029h-16.031z"/>
</vector>

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@drawable/ic_launcher_background"/>
<background android:drawable="@color/ic_launcher_background"/>
<foreground android:drawable="@drawable/ic_launcher_foreground"/>
</adaptive-icon>

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@drawable/ic_launcher_background"/>
<background android:drawable="@color/ic_launcher_background"/>
<foreground android:drawable="@drawable/ic_launcher_foreground"/>
</adaptive-icon>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 KiB

After

Width:  |  Height:  |  Size: 2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.8 KiB

After

Width:  |  Height:  |  Size: 4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2 KiB

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.7 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.4 KiB

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.7 KiB

After

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.2 KiB

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 8.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.9 KiB

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 12 KiB

View file

@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="ic_launcher_background">#26A69A</color>
</resources>

View file

@ -1,3 +1,4 @@
<resources>
<string name="app_name">AquaDroid</string>
<string name="pref_notification_message_value">Hey... Lets drink some water....</string>
</resources>