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

Commit 77d679cf authored by vincent's avatar vincent
Browse files

replace channel creation in OperationManagerService onCreate

parent 580bda3c
Loading
Loading
Loading
Loading
Loading
+0 −10
Original line number Diff line number Diff line
buildscript {
    /*repositories {
        maven { url 'https://maven.fabric.io/public' }
    }

    dependencies {
        classpath 'io.fabric.tools:gradle:1.+'
    }*/
}
import java.text.SimpleDateFormat;
apply plugin: 'com.android.application'
//apply plugin: 'io.fabric'
def versionMajor = 1

def buildTime() {
@@ -24,7 +15,6 @@ android {
    defaultConfig {
        applicationId "io.eelo.drive"
        minSdkVersion 26
        targetSdkVersion 26
        versionCode 1
        //versionName "1.0"
        versionName "alpha-${versionMajor}-build-${buildTime()}"
+0 −5
Original line number Diff line number Diff line
@@ -289,11 +289,6 @@ public class InitializerService extends Service implements OnRemoteOperationList
                .apply();

        //all folder have been created
        JobUtils.scheduleScannerJob(this, 120000);
        NotificationManager nM = (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);

        nM.createNotificationChannel(new NotificationChannel(AppConstants.notificationChannelID, AppConstants.notificationChannelName, NotificationManager.IMPORTANCE_DEFAULT));

        //JobUtils.stopScheduledJob(appContext, JobUtils.InitializerJobId);
        stopSelf();

+6 −0
Original line number Diff line number Diff line
@@ -48,6 +48,7 @@ import io.eelo.drive.operations.UploadFileOperation;
import io.eelo.drive.utils.AppConstants;
import io.eelo.drive.utils.CommonUtils;
import io.eelo.drive.utils.IGetOCClient;
import io.eelo.drive.utils.JobUtils;

/**
 * @author Vincent Bourgmayer
@@ -106,6 +107,11 @@ public class OperationManagerService extends Service implements OnRemoteOperatio
        this.mStartedOperations = new Hashtable<RemoteOperation, Integer>();
        this.lockedfilePath = new ArrayList<String>();

        JobUtils.scheduleScannerJob(this, 120000);
        NotificationManager nM = (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);

        nM.createNotificationChannel(new NotificationChannel(AppConstants.notificationChannelID, AppConstants.notificationChannelName, NotificationManager.IMPORTANCE_DEFAULT));

        //Get Account name and type then ask for OwnCloudClient.
        //The following step is the method "onOCClientReceived(...)".
        SharedPreferences prefs = this.getSharedPreferences(AppConstants.SHARED_PREFERENCE_NAME, Context.MODE_PRIVATE);