package com.example.todocloud.receiver;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;

import com.example.todocloud.app.AppController;
import com.example.todocloud.data.Todo;
import com.example.todocloud.service.ReminderService;

public class ReminderSetter extends BroadcastReceiver {

  /**
   * BOOT_COMPLETED-re reagálva meghívja az ReminderService-t, ami élesíti a még aktuális
   * emlékeztetőket.
   */
  @Override
  public void onReceive(Context context, Intent intent) {
    Intent service = new Intent(context, ReminderService.class);
    service.setAction(ReminderService.CREATE);
    context.startService(service);
  }

  public static void createReminderService(Todo todo) {
    Context applicationContext = AppController.getAppContext();
    Intent reminderService = new Intent(applicationContext, ReminderService.class);
    reminderService.putExtra("todo", todo);
    reminderService.setAction(ReminderService.CREATE);
    applicationContext.startService(reminderService);
  }

  public static void cancelReminderService(Todo todo) {
    Context applicationContext = AppController.getAppContext();
    Intent reminderService = new Intent(applicationContext, ReminderService.class);
    reminderService.putExtra("todo", todo);
    reminderService.setAction(ReminderService.CANCEL);
    applicationContext.startService(reminderService);
  }

}

@@ -816,39 +816,38 @@
  Intent reminder
-Service
+Intent
  = new Intent(ap
@@ -892,39 +892,38 @@
 s);%0A    reminder
-Service
+Intent
 .putExtra(%22todo%22
@@ -935,39 +935,38 @@
 o);%0A    reminder
-Service
+Intent
 .setAction(Remin
@@ -1021,39 +1021,38 @@
 Service(reminder
-Service
+Intent
 );%0A  %7D%0A%0A  public
@@ -1182,23 +1182,22 @@
 reminder
-Service
+Intent
  = new I
@@ -1258,23 +1258,22 @@
 reminder
-Service
+Intent
 .putExtr
@@ -1301,23 +1301,22 @@
 reminder
-Service
+Intent
 .setActi
@@ -1387,23 +1387,22 @@
 reminder
-Service
+Intent
 );%0A  %7D%0A%0A

Fix naming convention