src/main/java/org/acra/ErrorReporter.java
/**
     * This method looks for pending reports and does the action required
     * depending on the interaction mode set.
     */
This method looks for pending reports and does the action required
depending on the interaction mode set.
This method looks for pending reports and does the action required depending on the interaction mode set .
private void checkReportsOnApplicationStart() {
        final CrashReportFinder reportFinder = new CrashReportFinder(mContext);
        final String[] filesList = reportFinder.getCrashReportFiles();
        if (filesList != null && filesList.length > 0) {
            final boolean onlySilentOrApprovedReports = containsOnlySilentOrApprovedReports(filesList);
            ReportingInteractionMode reportingInteractionMode = ACRA.getConfig().mode();
            if (reportingInteractionMode == ReportingInteractionMode.SILENT
                    || reportingInteractionMode == ReportingInteractionMode.TOAST
                    || (onlySilentOrApprovedReports && (reportingInteractionMode == ReportingInteractionMode.NOTIFICATION || reportingInteractionMode == ReportingInteractionMode.DIALOG))) {
                if (reportingInteractionMode == ReportingInteractionMode.TOAST && !onlySilentOrApprovedReports) {
                    ToastSender.sendToast(mContext, ACRA.getConfig().resToastText(), Toast.LENGTH_LONG);
                }
                Log.v(ACRA.LOG_TAG, "About to start ReportSenderWorker from #checkReportOnApplicationStart");
                startSendingReports(false, false);
            } else if (ACRA.getConfig().deleteUnapprovedReportsOnApplicationStart()) {
                deletePendingNonApprovedReports();
            } else {
                if (ACRA.getConfig().mode() == ReportingInteractionMode.NOTIFICATION) {
                    notifySendReport(getLatestNonSilentReport(filesList));
                } else if (ACRA.getConfig().mode() == ReportingInteractionMode.DIALOG) {
                    notifyDialog(getLatestNonSilentReport(filesList));
                }
            }
        }
    }
private void checkReportsOnApplicationStart ( ) { final CrashReportFinder reportFinder = new CrashReportFinder ( mContext ) ; final String [ ] filesList = reportFinder . getCrashReportFiles ( ) ; if ( filesList != null && filesList . length > 0 ) { final boolean onlySilentOrApprovedReports = containsOnlySilentOrApprovedReports ( filesList ) ; ReportingInteractionMode reportingInteractionMode = ACRA . getConfig ( ) . mode ( ) ; if ( reportingInteractionMode == ReportingInteractionMode . SILENT || reportingInteractionMode == ReportingInteractionMode . TOAST || ( onlySilentOrApprovedReports && ( reportingInteractionMode == ReportingInteractionMode . NOTIFICATION || reportingInteractionMode == ReportingInteractionMode . DIALOG ) ) ) { if ( reportingInteractionMode == ReportingInteractionMode . TOAST && ! onlySilentOrApprovedReports ) { ToastSender . sendToast ( mContext , ACRA . getConfig ( ) . resToastText ( ) , Toast . LENGTH_LONG ) ; } Log . v ( ACRA . LOG_TAG , "About to start ReportSenderWorker from #checkReportOnApplicationStart" ) ; startSendingReports ( false , false ) ; } else if ( ACRA . getConfig ( ) . deleteUnapprovedReportsOnApplicationStart ( ) ) { deletePendingNonApprovedReports ( ) ; } else { if ( ACRA . getConfig ( ) . mode ( ) == ReportingInteractionMode . NOTIFICATION ) { notifySendReport ( getLatestNonSilentReport ( filesList ) ) ; } else if ( ACRA . getConfig ( ) . mode ( ) == ReportingInteractionMode . DIALOG ) { notifyDialog ( getLatestNonSilentReport ( filesList ) ) ; } } } }
This method looks for pending reports and does the action required
 depending on the interaction mode set.
This method looks for pending reports and does the action required depending on the interaction mode set .
// Immediately send reports for SILENT and TOAST modes.
 // Immediately send reports in NOTIFICATION mode only if they are
 // all silent or approved.
 // Display the Toast in TOAST mode only if there are
 // non-silent reports.
 // NOTIFICATION mode, and there are unapproved reports to send
 // (latest notification has been ignored: neither accepted nor
 // refused). The application developer has decided that these
 // reports should not be renotified ==> destroy them.
 // NOTIFICATION mode there are unapproved reports to send
 // (latest notification has been ignored: neither accepted
 // nor refused).
 // Display the notification.
 // The user comment will be associated to the latest report
