Fix loading on pre-Emacs 24.

Fixes issue #48 and #49 thanks to @mamciek.
This commit is contained in:
Greg Pfeil 2012-03-16 15:57:35 -06:00
parent 35de4c7395
commit 193d29ae89
3 changed files with 4 additions and 8 deletions

View File

@ -2,6 +2,4 @@
(locate-file "solarized-definitions.el" custom-theme-load-path
'("c" "")))
(load-into-load-path)
(create-solarized-theme dark)

View File

@ -460,9 +460,9 @@ the \"Gen RGB\" column in solarized-definitions.el to improve them further."
(apply 'custom-theme-set-faces ',theme-name ',theme-faces)
(provide-theme ',theme-name))))
(defun load-into-load-path ()
(when load-file-name
(add-to-list 'custom-theme-load-path
(file-name-as-directory (file-name-directory load-file-name)))))
;;;###autoload
(when (boundp 'custom-theme-load-path)
(add-to-list 'custom-theme-load-path
(file-name-as-directory (file-name-directory load-file-name))))
(provide 'solarized-definitions)

View File

@ -2,6 +2,4 @@
(locate-file "solarized-definitions.el" custom-theme-load-path
'("c" "")))
(load-into-load-path)
(create-solarized-theme light)