;ELC ;;; Compiled by heimdall@baldur on Fri Feb 1 18:34:55 2008 ;;; from file /home/heimdall/repos/emms/emms-playing-time.el ;;; in Emacs version 23.0.60.1 ;;; with all optimizations. ;;; This file uses dynamic docstrings, first added in Emacs 19.29. (if (and (boundp 'emacs-version) (< (aref emacs-version (1- (length emacs-version))) ?A) (or (and (boundp 'epoch::version) epoch::version) (string-lessp emacs-version "19.29"))) (error "`emms-playing-time.el' was compiled for Emacs 19.29 or later")) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (byte-code "\300\301!\210\300\302!\210\303\304\305\306\307\310%\207" [require emms-info emms-player-simple custom-declare-group emms-playing-time nil "Playing-time module for EMMS." :group emms] 6) #@85 Non-nil will only display elapsed time. e.g., display 02:37 instead of 02:37/05:49. (custom-declare-variable 'emms-playing-time-display-short-p 'nil '(#$ . 795) :type 'boolean :group 'emms-playing-time) #@42 Format used for displaying playing time. (custom-declare-variable 'emms-playing-time-display-format '" %s " '(#$ . 1004) :type 'string :group 'emms-playing-time) #@112 Style used for displaying playing time. Valid styles are `time' (e.g., 01:30/4:20) and `bar' (e.g., [===> ]). (custom-declare-variable 'emms-playing-time-style ''time '(#$ . 1173) :type 'symbol :group 'emms-playing-time) #@53 Whether to display playing time on mode line or not (defvar emms-playing-time-display-p nil (#$ . 1401)) #@32 Time elapsed in current track. (defvar emms-playing-time 0 (#$ . 1512)) (byte-code "\301B\302\301!\204\303\301\304\"\210\305B\302\305!\204\303\305\306\"\210\306\207" [current-load-list emms-playing-time-string default-boundp set-default "" emms-playing-time-display-timer nil] 3) #@52 Whether emms-playing-time module is enabled or not (defvar emms-playing-time-p nil (#$ . 1806)) #@37 Get ready for display playing time. (defalias 'emms-playing-time-start #[nil "\302 ?\205\303\304\305\306#\211\207" [emms-playing-time emms-playing-time-display-timer 0 run-at-time t 1 emms-playing-time-display] 4 (#$ . 1908)]) #@39 Remove playing time on the mode line. (defalias 'emms-playing-time-stop #[nil "\203 \203 \304\305 \210\306 !\210\307\211\207" [emms-player-paused-p emms-player-stopped-p emms-playing-time-string emms-playing-time-display-timer "" force-mode-line-update emms-cancel-timer nil] 2 (#$ . 2145)]) #@21 Pause playing time. (defalias 'emms-playing-time-pause #[nil "\203\302 \207 ?\205\303\304\305\306#\211\207" [emms-player-paused-p emms-playing-time-display-timer emms-playing-time-stop run-at-time t 1 emms-playing-time-display] 4 (#$ . 2449)]) #@44 Seek forward or backward SEC playing time. (defalias 'emms-playing-time-seek #[(sec) " \\\211\302W\205 \302\211\207" [emms-playing-time sec 0] 3 (#$ . 2705)]) #@30 Set the playing time to SEC. (defalias 'emms-playing-time-set #[(sec) "\211\302W\205 \302\211\207" [sec emms-playing-time 0] 3 (#$ . 2874)]) #@390 Turn on emms playing time if ARG is positive, off otherwise. Note: `(emms-playing-time -1)' will disable emms-playing-time module completely, and is not recommended. (since some other emms modules may rely on it, such as `emms-lastfm.el') Instead, to toggle displaying playing time on mode line, one could call `emms-playing-time-enable-display' and `emms-playing-time-disable-display'. (defalias 'emms-playing-time #[(arg) "\203/\303V\203/\304\211\305 \210\306\307\310\"\210\306\311\312\"\210\306\313\312\"\210\306\314\315\"\210\306\316\317\"\210\306\320\321\"\207\322\211\312 \210\323 \210\324\307\310\"\210\324\311\312\"\210\324\313\312\"\210\324\314\315\"\210\324\316\317\"\210\324\320\321\"\207" [arg emms-playing-time-p emms-playing-time-display-p 0 t emms-playing-time-mode-line add-hook emms-player-started-hook emms-playing-time-start emms-player-stopped-hook emms-playing-time-stop emms-player-finished-hook emms-player-paused-hook emms-playing-time-pause emms-player-seeked-functions emms-playing-time-seek emms-player-time-set-functions emms-playing-time-set nil emms-playing-time-restore-mode-line remove-hook] 4 (#$ . 3026)]) #@36 Display playing time on mode line. (defalias 'emms-playing-time-enable-display #[nil "\301\211\207" [emms-playing-time-display-p t] 2 (#$ . 4182) nil]) #@37 Remove playing time from mode line. (defalias 'emms-playing-time-disable-display #[nil "\301\211\207" [emms-playing-time-display-p nil] 2 (#$ . 4341) nil]) #@40 Display playing time on the mode line. (defalias 'emms-playing-time-display #[nil "T\306\n\203\274\307\245\307\246\310\311 \312\"\206\313\211\307\245 \307\246\314\315\"\203\224\316 !\2038\317\202\265\320\321_ \245 \313!\"!\"W\203` \322P !T\211!\202K* \323P \321Z\313!#!#W\203\207 \324P !T\211!\202r* \325P\211 *\202\265\326\324\327$\204\242 \313=\203\252\330\331 \f#\202\263\330\332 \f%#\330% \"-\333 \207" [emms-playing-time emms-playing-time-string emms-playing-time-display-p min sec total-playing-time "" 60 emms-track-get emms-playlist-current-selected-track info-playing-time 0 memql (bar) zerop "[==>........]" "[" 10 "=" ">" " " "]" emms-replace-regexp-in-string "0" format "%2d:%2d" "%2d:%2d/%2s:%2s" force-mode-line-update total-min-only total-sec-only emms-playing-time-style percent progress i #1=#:--cl-dotimes-temp-- #2=#:--cl-dotimes-temp-- emms-playing-time-display-short-p emms-playing-time-display-format] 10 (#$ . 4504)]) #@36 Add playing time to the mode line. (defalias 'emms-playing-time-mode-line #[nil "\204\301\302\235?\205\303\304\"\211\207" [global-mode-string ("") emms-playing-time-string append (emms-playing-time-string)] 3 (#$ . 5517)]) #@24 Restore the mode line. (defalias 'emms-playing-time-restore-mode-line #[nil "\301\302\"\303 \207" [global-mode-string remove emms-playing-time-string force-mode-line-update] 3 (#$ . 5755)]) (provide 'emms-playing-time)