MMCT TEAM
Server IP : 111.118.215.189  /  Your IP : 18.117.158.174
Web Server : Apache
System : Linux md-in-83.webhostbox.net 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64
User : a1673wkz ( 2475)
PHP Version : 8.2.25
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0755) :  /usr/share/emacs/24.3/lisp/org/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : //usr/share/emacs/24.3/lisp/org/org-timer.elc
;ELC
;;; Compiled by mockbuild@buildfarm06-new.corp.cloudlinux.com on Fri Oct 11 10:08:06 2024
;;; from file /builddir/build/BUILD/emacs-24.3/lisp/org/org-timer.el
;;; in Emacs version 24.3.1
;;; with all optimizations.

;;; This file uses dynamic docstrings, first added in Emacs 19.29.

;;; This file does not contain utf-8 non-ASCII characters,
;;; and so can be loaded in Emacs versions earlier than 23.

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;


(require 'org)
#@28 t=0 for the running timer.
(defvar org-timer-start-time nil (#$ . 571))
#@33 Time when the timer was paused.
(defvar org-timer-pause-time nil (#$ . 649))
#@48 Regular expression used to match timer stamps.
(defconst org-timer-re "\\([-+]?[0-9]+\\):\\([0-9]\\{2\\}\\):\\([0-9]\\{2\\}\\)" (#$ . 732))
(byte-code "\300\301\302\303\304\305\306\307&\210\300\310\311\312\304\305\313\314\306\315&	\210\300\316\317\320\304\305\306\321&\207" [custom-declare-variable org-timer-format "%s " "The format to insert the time of the timer.\nThis format must contain one instance of \"%s\" which will be replaced by\nthe value of the relative timer." :group org-time :type string org-timer-default-timer 0 "The default timer when a timer is set.\nWhen 0, the user is prompted for a value." :version "24.1" number org-timer-display 'mode-line "When a timer is running, org-mode can display it in the mode\nline and/or frame title.\nAllowed values are:\n\nboth         displays in both mode line and frame title\nmode-line    displays only in mode line (default)\nframe-title  displays only in frame title\nnil          current timer is not displayed" (choice (const :tag "Mode line" mode-line) (const :tag "Frame title" frame-title) (const :tag "Both" both) (const :tag "None" nil))] 10)
#@43 Hook run after relative timer is started.
(defvar org-timer-start-hook nil (#$ . 1853))
#@44 Hook run before relative timer is stopped.
(defvar org-timer-stop-hook nil (#$ . 1947))
#@43 Hook run before relative timer is paused.
(defvar org-timer-pause-hook nil (#$ . 2041))
#@45 Hook run after relative timer is continued.
(defvar org-timer-continue-hook nil (#$ . 2135))
#@40 Hook run after countdown timer is set.
(defvar org-timer-set-hook nil (#$ . 2234))
#@46 Hook run after countdown timer reaches zero.
(defvar org-timer-done-hook nil (#$ . 2323))
#@46 Hook run before countdown timer is canceled.
(defvar org-timer-cancel-hook nil (#$ . 2419))
#@516 Set the starting time for the relative timer to now.
When called with prefix argument OFFSET, prompt the user for an offset time,
with the default taken from a timer stamp at point, if any.
If OFFSET is a string or an integer, it is directly taken to be the offset
without user interaction.
When called with a double prefix arg, all timer strings in the active
region will be shifted by a specific amount.  You will be prompted for
the amount, with the default to make the first timer string in
the region 0:00:00.
(defalias 'org-timer-start #[(&optional offset) "\306\232\203\n\307\310!\207\311\211\211\204\312 \202[\250\203$\202T;\2030\313!\202T\314
!\203<\315\316!\202=\317\320\321\322\n\"!\323\324	\"\204N\n\313\325	!!\326\327 Z!\330\331!\210\332\333\334\335\f\"\336\206k\316!#\210\337\340!+\207" [offset s def delta org-timer-start-time org-timer-re (16) call-interactively org-timer-change-times-in-region nil current-time org-timer-hms-to-secs org-in-regexp match-string 0 "0:00:00" read-string format "Restart timer with offset [%s]: " string-match "\\S-" org-timer-fix-incomplete seconds-to-time org-float-time org-timer-set-mode-line on message "Timer start time set to %s, current value is %s" format-time-string "%T" org-timer-secs-to-hms run-hooks org-timer-start-hook] 5 (#$ . 2518) "P"])
#@79 Pause or continue the relative timer.
With prefix arg STOP, stop it entirely.
(defalias 'org-timer-pause-or-continue #[(&optional stop) "\203\303 \207	\204\304\305!\207\n\2030\306\307 \307\n!\307	!ZZ!\310\311\312!\210\313\314!\210\315\316\317 \"\207\313\320!\210\321 \311\322!\210\315\323\317 \"\207" [stop org-timer-start-time org-timer-pause-time org-timer-stop error "No timer is running" seconds-to-time org-float-time nil org-timer-set-mode-line on run-hooks org-timer-continue-hook message "Timer continues at %s" org-timer-value-string org-timer-pause-hook current-time pause "Timer paused at %s"] 5 (#$ . 3858) "P"])
#@26 Stop the relative timer.
(defalias 'org-timer-stop #[nil "\302\303!\210\304\211\305\306!\210\307\310!\207" [org-timer-start-time org-timer-pause-time run-hooks org-timer-stop-hook nil org-timer-set-mode-line off message "Timer stopped"] 3 (#$ . 4498) nil])
#@486 Insert a H:MM:SS string from the timer into the buffer.
The first time this command is used, the timer is started.  When used with
a \[universal-argument] prefix, force restarting the timer.
When used with a double prefix argument \[universal-argument], change all the timer string
in the region by a fixed amount.  This can be used to recalibrate a timer
that was not started at the correct moment.

If NO-INSERT-P is non-nil, return the string instead of inserting
it in the buffer.
(defalias 'org-timer #[(&optional restart no-insert-p) "\303\232\204\n	\204
\304 \210\n\203\305 \207\305 c\207" [restart org-timer-start-time no-insert-p (4) org-timer-start org-timer-value-string] 2 (#$ . 4764) "P"])
(defalias 'org-timer-value-string #[nil "\301\302\303\304 !!\"\207" [org-timer-format format org-timer-secs-to-hms floor org-timer-seconds] 5])
(defvar org-timer-timer-is-countdown nil)
(defalias 'org-timer-seconds #[nil "\203
\303	!\303\304 !Z\207\303\n\206\304 !\303	!Z\207" [org-timer-timer-is-countdown org-timer-start-time org-timer-pause-time org-float-time current-time] 3])
#@47 Change all h:mm:ss time in region by a DELTA.
(defalias 'org-timer-change-times-in-region #[(beg end delta) "\306\307\310\311\n\"\2040\212b\210\312	\f\313#\203/\314\315!\316\n!\317\232\203+\n\320\307O\202/\321\nP)\322\323\n!!\211\315U\203@\324\325!\210\212\fb\210\326	\313#\205h`\327\330 \331\216\332\322\314\315!!\n\\!*\313\211#\210b\210\202D+\207" [p re delta beg end save-match-data-internal "[-+]?[0-9]+:[0-9]\\{2\\}:[0-9]\\{2\\}" nil string-match "\\S-" re-search-forward t match-string 0 string-to-char 45 1 "-" org-timer-hms-to-secs org-timer-fix-incomplete error "No change" re-search-backward replace-match match-data ((byte-code "\301\302\"\207" [save-match-data-internal set-match-data evaporate] 3)) org-timer-secs-to-hms] 6 (#$ . 5865) "r\nsEnter time difference like \"-1:08:26\".  Default is first time to zero: "])
#@62 Insert a description-type item with the current timer value.
(defalias 'org-timer-item #[(&optional arg) "\306 `\211\203@	b\203@\307 \203@\310 \311\n!\312\f\205 \313\314\"\315P\316\n\317
%\320\n\321\n!\"\210\322!\210\323\225b+\202`	\203Mb\210\324\325!\202`\326 \210\327 \210\330c\210\312\f\205\\\331!\210\315c*\207" [pos itemp struct prevs arg s org-in-item-p org-at-item-timer-p org-list-struct org-list-prevs-alist org-timer (4) t ":: " org-list-insert-item nil org-list-write-struct org-list-parents-alist looking-at 0 error "This is not a timer list" beginning-of-line org-indent-line "- " (4) org-list-full-item-re] 7 (#$ . 6721) "P"])
#@74 If hms is a H:MM:SS string with missing hour or hour and minute, fix it.
(defalias 'org-timer-fix-incomplete #[(hms) "\301\302\"\2034\303\304\305\306\225\203\307\310\306\"!\202\311\312\225\203'\307\310\312\"!\202(\311\307\310\313\"!$\314\211$\207\315\316\"\207" [hms string-match "\\(?:\\([0-9]+:\\)?\\([0-9]+:\\)\\)?\\([0-9]+\\)" replace-match format "%d:%02d:%02d" 1 string-to-number match-string 0 2 3 t error "Cannot parse HMS string \"%s\""] 9 (#$ . 7387)])
#@114 Convert h:mm:ss string to an integer time.
If the string starts with a minus sign, the integer will be negative.
(defalias 'org-timer-hms-to-secs #[(hms) "\305\306\"\204	\307\207\310\311\312\"!\310\311\313\"!\310\311\314\"!\311\312\"\307\312O\315\232\316	!\f\2034\317\2025\312\n	\320_\\\320_\\_,\207" [hms h m s sign string-match "\\([-+]?[0-9]+\\):\\([0-9]\\{2\\}\\):\\([0-9]\\{2\\}\\)" 0 string-to-number match-string 1 2 3 "-" abs -1 60] 5 (#$ . 7870)])
#@93 Convert integer S into h:mm:ss.
If the integer is negative, the string will start with "-".
(defalias 'org-timer-secs-to-hms #[(s) "\304\211\211\305W\203\306\202\307\310!\211\311\245	\311_Z	\311\245	\311_Z\312\313\n	%+\207" [h m sign s nil 0 "-" "" abs 60 format "%s%d:%02d:%02d"] 7 (#$ . 8347)])
(defvar org-timer-mode-line-timer nil)
(defvar org-timer-mode-line-string nil)
#@88 Set the mode-line display of the relative timer.
VALUE can be `on', `off', or `pause'.
(defalias 'org-timer-set-mode-line #[(value) "\305=\204\f\306=\203	\204\307\310	>\204\311	\312\"\313=\204)\306=\2034\310\n>\2044\311\n\314\"\315\232\203i\f\203D\316\f!\210\317\305=\204P\306=\203U\320\310	\"\313=\204a\306=\203f\320\310\n\"\321 \207\322\232\203{\f\205\315\316\f!\210\317\211\207\323\232\205\315\305=\204\215\306=\203\236	\204\223\324\310	>\204\236\311	\325\"\313=\204\252\306=\203\265\310\n>\204\265\311\n\326\"\327 \210\f\203\302\316\f!\210\317\205\315\330\331\211\327#\211\207" [org-timer-display global-mode-string frame-title-format value org-timer-mode-line-timer mode-line both (#1="") org-timer-mode-line-string append (org-timer-mode-line-string) frame-title (org-timer-mode-line-string) off cancel-timer nil delq force-mode-line-update pause on (#1#) (org-timer-mode-line-string) (org-timer-mode-line-string) org-timer-update-mode-line run-with-timer 1] 4 (#$ . 8748)])
#@41 Update the timer time in the mode line.
(defalias 'org-timer-update-mode-line #[nil "?\205\302\303 \304\305O\306Q\307 \207" [org-timer-pause-time org-timer-mode-line-string " <" org-timer-value-string 0 -1 ">" force-mode-line-update] 4 (#$ . 9791)])
(defvar org-timer-current-timer nil)
#@27 Cancel the current timer.
(defalias 'org-timer-cancel-timer #[nil "\302!\203\303\304!\210\305!\210\306\211\307\310!\210\311\312!\207" [org-timer-current-timer org-timer-timer-is-countdown eval run-hooks org-timer-cancel-hook cancel-timer nil org-timer-set-mode-line off message "Last timer canceled"] 3 (#$ . 10088) nil])
#@51 Display the remaining time before the timer ends.
(defalias 'org-timer-show-remaining-time #[nil "\304\305!\210\204\f\306\307!\207\310\311\312!\313 \"!\211@	A@\306\314\n#+\207" [org-timer-current-timer rtime rsecs rmins require time message "No timer set" decode-time time-subtract timer--time current-time "%d minute(s) %d seconds left before next time out"] 5 (#$ . 10422) nil])
#@569 Prompt for a duration and set a timer.

If `org-timer-default-timer' is not zero, suggest this value as
the default duration for the timer.  If a timer is already set,
prompt the user if she wants to replace it.

Called with a numeric prefix argument, use this numeric value as
the duration of the timer.

Called with a `C-u' prefix arguments, use `org-timer-default-timer'
without prompting the user for a duration.

With two `C-u' prefix arguments, use `org-timer-default-timer'
without prompting the user for a duration and automatically
replace any running timer.
(defalias 'org-timer-set-timer #[(&optional opt) "\247\203\306!\206'<\203\203\306	!\206'\307\310	\311=?\205&\306	!\"\312\313\n\"\2044\314 \202\365\315\316\311\n\"!\211\317_\312\320\321 \"\203\200\322`\323\"\206P\324 \322`\325\"\206Y
=\326
!>r\327
!q\210~\210>b\210\330 \210\331\332\333\217\206|\334\335\336 !P,\202\231\337\340!\203\226\331\341\342\217\206\231\334\335\336 !P\202\231\343\344!?\331@A\203\257\345\232\204\264\346\347!\204\264A\204\361\350\351!\210A\203\302\352A!\210\353\f\331\354\331\355\356\357\360?\"\361BB\362BBBB#A\363\364!\210\365B\366\367 \370\317_!\"C\371\372!\202\364\373\374!,)\207" [opt org-timer-default-timer minutes mins secs marker number-to-string read-from-minibuffer "How many minutes left? " 0 string-match "[0-9]+" org-timer-show-remaining-time string-to-number match-string 60 "Org Agenda" buffer-name get-text-property org-marker org-agenda-error org-hd-marker marker-position marker-buffer org-show-entry nil (org-get-heading) ((error)) "File:" file-name-nondirectory buffer-file-name derived-mode-p org-mode (org-get-heading) ((error)) error "Not in an Org buffer" (16) y-or-n-p "Replace current timer? " require org-clock cancel-timer run-with-timer lambda (setq org-timer-current-timer nil) org-notify format "%s: time out" (t) ((setq org-timer-timer-is-countdown nil) (org-timer-set-mode-line 'off) (run-hooks 'org-timer-done-hook)) run-hooks org-timer-set-hook t time-add current-time seconds-to-time org-timer-set-mode-line on message "No timer set" hdmarker pos hl timer-set org-timer-current-timer org-timer-timer-is-countdown org-timer-start-time] 11 (#$ . 10817) "P"])
(provide 'org-timer)

MMCT - 2023