Function: speedbar-check-obj-this-line
speedbar-check-obj-this-line is a byte-compiled function defined in
speedbar.el.gz.
Signature
(speedbar-check-obj-this-line DEPTH)
Documentation
Return t if the file on this line has an associated object.
Parameter DEPTH is a string with the current depth of indentation of the file being checked.
Source Code
;; Defined in /usr/src/emacs/lisp/speedbar.el.gz
(defun speedbar-check-obj-this-line (depth)
"Return t if the file on this line has an associated object.
Parameter DEPTH is a string with the current depth of indentation of
the file being checked."
(let* ((d (string-to-number depth))
(f (speedbar-line-directory d))
(fn (buffer-substring-no-properties
;; Skip-chars: thanks ptype@dra.hmg.gb
(point) (progn
(skip-chars-forward "^ " (line-end-position))
(point))))
(fulln (concat f fn)))
(if (<= 2 speedbar-verbosity-level)
(dframe-message "Speedbar obj check...%s" fulln))
(let ((oa speedbar-obj-alist))
(while (and oa (not (string-match (car (car oa)) fulln)))
(setq oa (cdr oa)))
(if (not (and oa (file-exists-p (concat (file-name-sans-extension fulln)
(cdr (car oa))))))
nil
;; Find out if the object is out of date or not.
(let ((date1 (file-attribute-modification-time
(file-attributes fulln)))
(date2 (file-attribute-modification-time
(file-attributes (concat
(file-name-sans-extension fulln)
(cdr (car oa)))))))
(if (time-less-p date1 date2)
(car speedbar-obj-indicator)
(cdr speedbar-obj-indicator)))))))