diff --git a/lisp/desktop.el b/lisp/desktop.el index b82a9dc9626..21a742c9aad 100644 --- a/lisp/desktop.el +++ b/lisp/desktop.el @@ -775,7 +775,7 @@ if different)." ;; Don't delete daemon's initial frame, or ;; we'll never be able to close the last ;; client's frame (Bug#26912). - (if (daemonp) (not (frame-parameter frame 'client))) + (and (daemonp) (eq frame terminal-frame)) (frame-parameter frame 'desktop-dont-clear)) (delete-frame frame)) (error @@ -1255,7 +1255,7 @@ This function also sets `desktop-dirname' to nil." (and desktop-restore-frames desktop-saved-frameset ;; Don't restore frames when the selected frame is the daemon's ;; initial frame. - (not (and (daemonp) (not (frame-parameter nil 'client)))) + (not (and (daemonp) (eq (selected-frame) terminal-frame))) t)) (defun desktop-restore-frameset () diff --git a/lisp/display-fill-column-indicator.el b/lisp/display-fill-column-indicator.el index dbd067f5f3d..4598b659341 100644 --- a/lisp/display-fill-column-indicator.el +++ b/lisp/display-fill-column-indicator.el @@ -102,7 +102,7 @@ See Info node `Displaying Boundaries' for details." (defun display-fill-column-indicator--turn-on () "Turn on `display-fill-column-indicator-mode'." (unless (or (minibufferp) - (and (daemonp) (null (frame-parameter nil 'client)))) + (and (daemonp) (eq (selected-frame) terminal-frame))) (display-fill-column-indicator-mode))) ;;;###autoload diff --git a/lisp/frame.el b/lisp/frame.el index b6641ca716a..6e18ba65d9a 100644 --- a/lisp/frame.el +++ b/lisp/frame.el @@ -493,7 +493,7 @@ there (in decreasing order of priority)." (setq parms (append initial-frame-alist window-system-frame-alist default-frame-alist parms nil)) ;; Don't enable tab-bar in daemon's initial frame. - (when (and (daemonp) (not (frame-parameter nil 'client))) + (when (and (daemonp) (eq (selected-frame) terminal-frame)) (setq parms (delq (assq 'tab-bar-lines parms) parms))) parms)) (if (null initial-window-system) ;; MS-DOS does this differently in pc-win.el diff --git a/lisp/obsolete/linum.el b/lisp/obsolete/linum.el index e0782258716..75cb1199927 100644 --- a/lisp/obsolete/linum.el +++ b/lisp/obsolete/linum.el @@ -129,7 +129,7 @@ Linum mode is a buffer-local minor mode." ;; Note that nowadays, this actually doesn't show line ;; numbers in client frames at all, because we visit the ;; file before creating the client frame. See bug#35726. - (and (daemonp) (null (frame-parameter nil 'client)))) + (and (daemonp) (eq (selected-frame) terminal-frame))) (linum-mode 1))) (defun linum-delete-overlays () diff --git a/lisp/progmodes/flymake.el b/lisp/progmodes/flymake.el index 7af4ea334d6..60a6bacf640 100644 --- a/lisp/progmodes/flymake.el +++ b/lisp/progmodes/flymake.el @@ -1390,7 +1390,7 @@ Interactively, with a prefix arg, FORCE is t." (cl-labels ((visible-buffer-window () (and (or (not (daemonp)) - (not (null (frame-parameter nil 'client)))) + (not (eq (selected-frame) terminal-frame))) (get-buffer-window (current-buffer)))) (start-post-command () (remove-hook 'post-command-hook #'start-post-command diff --git a/lisp/tab-bar.el b/lisp/tab-bar.el index db16775d884..6653d12f634 100644 --- a/lisp/tab-bar.el +++ b/lisp/tab-bar.el @@ -282,7 +282,7 @@ a list of frames to update." (and (eq auto-resize-tab-bars 'grow-only) (> (frame-parameter frame 'tab-bar-lines) 1)) ;; Don't enable tab-bar in daemon's initial frame. - (and (daemonp) (not (frame-parameter frame 'client)))) + (and (daemonp) (eq frame terminal-frame))) (set-frame-parameter frame 'tab-bar-lines (tab-bar--tab-bar-lines-for-frame frame))))) ;; Update `default-frame-alist'