Merge branch 'master' into feature/positioned-lambdas

feature/positioned-lambdas
Alan Mackenzie 2024-03-25 11:34:48 +00:00
commit 2dea559e5e
3 changed files with 23 additions and 6 deletions

View File

@ -46,9 +46,11 @@ import android.view.KeyEvent;
import android.view.inputmethod.CursorAnchorInfo;
import android.view.inputmethod.ExtractedText;
import android.app.AlarmManager;
import android.app.Notification;
import android.app.NotificationManager;
import android.app.NotificationChannel;
import android.app.NotificationManager;
import android.app.PendingIntent;
import android.app.Service;
import android.content.ClipboardManager;
@ -724,11 +726,29 @@ public final class EmacsService extends Service
restartEmacs ()
{
Intent intent;
PendingIntent pending;
AlarmManager manager;
intent = new Intent (this, EmacsActivity.class);
intent.addFlags (Intent.FLAG_ACTIVITY_NEW_TASK
| Intent.FLAG_ACTIVITY_CLEAR_TASK);
startActivity (intent);
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT)
startActivity (intent);
else
{
/* Experimentation has established that Android 4.3 and earlier
versions do not attempt to recreate a process when it crashes
immediately after requesting that an intent for itself be
started. Schedule an intent to start some time after Emacs
exits instead. */
pending = PendingIntent.getActivity (this, 0, intent, 0);
manager = (AlarmManager) getSystemService (Context.ALARM_SERVICE);
manager.set (AlarmManager.RTC, System.currentTimeMillis () + 100,
pending);
}
System.exit (0);
}

View File

@ -482,9 +482,6 @@ There can be multiple entries for the same NAME if it has several aliases.")
(push name byte-optimize--dynamic-vars)
`(,fn ,name . ,optimized-rest)))
(`(,(pred byte-code-function-p) . ,exps)
(cons fn (mapcar #'byte-optimize-form exps)))
((guard (when for-effect
(if-let ((tmp (byte-opt--fget fn 'side-effect-free)))
(or byte-compile-delete-errors

View File

@ -1619,7 +1619,7 @@ modified lines of the diff."
nil)))
(when (eq diff-buffer-type 'git)
(setq diff-outline-regexp
(concat "\\(^diff --git.*\n\\|" diff-hunk-header-re "\\)")))
(concat "\\(^diff --git.*\\|" diff-hunk-header-re "\\)")))
(setq-local outline-level #'diff--outline-level)
(setq-local outline-regexp diff-outline-regexp))