Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7b0d96d7 authored by Amit Kumar's avatar Amit Kumar
Browse files

Support for oreo and few improvements

1. Fix weather widget margin
2. Improve app loading by using parallel stream
3. Prevent enable location dialog on every restart
parent c94e1130
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -47,11 +47,10 @@ dependencies {
    implementation 'me.relex:circleindicator:1.2.2@aar'
    implementation 'uk.co.chrisjenx:calligraphy:2.3.0'

    implementation 'org.cyanogenmod:platform.sdk:6.0'
    implementation files('libs/lineage-sdk.jar')

    debugImplementation 'com.crashlytics.sdk.android:crashlytics:2.9.5'
    debugImplementation 'com.google.firebase:firebase-core:16.0.4'

    implementation 'org.greenrobot:eventbus:3.1.1'

    // Support Libs
+2 −2
Original line number Diff line number Diff line
@@ -15,8 +15,8 @@
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>

    <uses-permission android:name="cyanogenmod.permission.ACCESS_WEATHER_MANAGER"/>
    <uses-permission android:name="cyanogenmod.permission.READ_WEATHER"/>
    <uses-permission android:name="lineageos.permission.ACCESS_WEATHER_MANAGER"/>
    <uses-permission android:name="lineageos.permission.READ_WEATHER"/>

    <application
        android:name=".BlissLauncher"
+5 −17
Original line number Diff line number Diff line
package org.indin.blisslaunchero;

import org.indin.blisslaunchero.features.launcher.AppProvider;
import org.indin.blisslaunchero.features.weather.DeviceStatusService;
import org.indin.blisslaunchero.features.weather.WeatherSourceListenerService;
import org.indin.blisslaunchero.features.weather.WeatherUpdateService;
import org.indin.blisslaunchero.features.weather.WeatherUtils;
import org.indin.blisslaunchero.framework.DeviceProfile;
import org.indin.blisslaunchero.framework.IconsHandler;

import android.app.Application;
import android.content.ComponentName;
import android.content.Context;
import android.content.Intent;
import android.content.ServiceConnection;
import android.os.IBinder;
import android.util.Log;

import org.indin.blisslaunchero.features.launcher.AppProvider;
import org.indin.blisslaunchero.framework.DeviceProfile;
import org.indin.blisslaunchero.framework.IconsHandler;

import uk.co.chrisjenx.calligraphy.CalligraphyConfig;

public class BlissLauncher extends Application {
@@ -32,14 +28,6 @@ public class BlissLauncher extends Application {
                .setDefaultFontPath("Roboto-Regular.ttf")
                .setFontAttrId(R.attr.fontPath)
                .build());

        if (WeatherUtils.isWeatherServiceAvailable(this)) {
            Log.i(TAG, "onCreate: weather avail ");
            startService(new Intent(this, WeatherSourceListenerService.class));
            startService(new Intent(this, DeviceStatusService.class));
            WeatherUpdateService.scheduleNextUpdate(this, true);
        }

    }

    public static BlissLauncher getApplication(Context context) {
+138 −190

File changed.

Preview size limit exceeded, changes collapsed.

+2 −8
Original line number Diff line number Diff line
package org.indin.blisslaunchero.features.notification;

import org.indin.blisslaunchero.framework.utils.ListUtil;

import android.service.notification.NotificationListenerService;
import android.service.notification.StatusBarNotification;
import android.util.Log;

import org.indin.blisslaunchero.framework.utils.ListUtil;

/**
 * Created by falcon on 14/3/18.
@@ -14,8 +13,6 @@ public class NotificationService extends NotificationListenerService {

    NotificationRepository mNotificationRepository;

    private static final String TAG = "NotificationService";

    @Override
    public void onCreate() {
        super.onCreate();
@@ -29,19 +26,16 @@ public class NotificationService extends NotificationListenerService {

    @Override
    public void onListenerConnected() {
        Log.d(TAG, "onListenerConnected() called");
        mNotificationRepository.updateNotification(ListUtil.asSafeList(getActiveNotifications()));
    }

    @Override
    public void onNotificationPosted(StatusBarNotification sbn) {
        Log.d(TAG, "onNotificationPosted() called with: sbn = [" + sbn + "]");
        mNotificationRepository.updateNotification(ListUtil.asSafeList(getActiveNotifications()));
    }

    @Override
    public void onNotificationRemoved(StatusBarNotification sbn) {
        Log.d(TAG, "onNotificationRemoved() called with: sbn = [" + sbn + "]");
        mNotificationRepository.updateNotification(ListUtil.asSafeList(getActiveNotifications()));
    }
}
Loading