From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Richard Lewis Newsgroups: gmane.emacs.help Subject: Advising appt-mode Date: Fri, 13 Nov 2009 13:19:58 +0000 Organization: A noiseless patient Spider Message-ID: <878wea5zpd.wl%richard.lewis@gold.ac.uk> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII X-Trace: ger.gmane.org 1258238456 15700 80.91.229.12 (14 Nov 2009 22:40:56 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 14 Nov 2009 22:40:56 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Nov 14 23:40:49 2009 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1N9RIW-0007vH-N5 for geh-help-gnu-emacs@m.gmane.org; Sat, 14 Nov 2009 23:40:48 +0100 Original-Received: from localhost ([127.0.0.1]:51108 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1N9RIW-0006KK-9F for geh-help-gnu-emacs@m.gmane.org; Sat, 14 Nov 2009 17:40:48 -0500 Original-Path: news.stanford.edu!usenet.stanford.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsfeed.straub-nv.de!feeder.eternal-september.org!eternal-september.org!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 31 Original-X-Trace: news.eternal-september.org U2FsdGVkX1/K0xC8asjhqQH1TbZ7FXKVjp07pLAGwIoXe2VZaNyTyvvpPy75+Pa+707/LcQMo4NE2xlMzvazJUNhxQDZne0U2MhVKuHIFIZn3vbgud2yoeXe/bVMXSPFAc02uL3tyEZPs7VSJFBUXjnE8TDcMm4S Original-X-Complaints-To: abuse@eternal-september.org Original-NNTP-Posting-Date: Fri, 13 Nov 2009 13:20:05 +0000 (UTC) User-Agent: Wanderlust/2.15.6 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.7 Emacs/23.1 (i486-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO) X-Auth-Sender: U2FsdGVkX18e0wVFB5PUTZv/f2hZkZsQlu4BuXpx23zbHKc436KLLQ== Cancel-Lock: sha1:SVT50o5MzQDwhrzdZgu7xuCXQBI= Original-Xref: news.stanford.edu gnu.emacs.help:174640 X-Mailman-Approved-At: Sat, 14 Nov 2009 17:31:55 -0500 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:69738 Archived-At: Hi there, I'm trying to make appt-mode display popup messages on my desktop (using a small wrapper function for libnotify) by advising the appt-check function like this: (defadvice appt-check (after appt-notify) (when (and appt-issue-message appt-time-msg-list) (when (and (<= min-to-app appt-message-warning-time) (>= min-to-app 0)) (rjl/notify (format "%s in %d minutes" (cadr (car appt-time-msg-list)) min-to-app) "Appointment")))) I've not tried using defadvice before and this attempt isn't working. It doesn't even work if I remove both the (when) conditions and leave just the (rjl/notify) call. (BTW, (rjl/notify) works fine in all other contexts.) Any ideas? -- -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Richard Lewis ISMS, Computing Goldsmiths, University of London JID: ironchicken@jabber.earth.li http://www.richard-lewis.me.uk/ -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- +-------------------------------------------------------+ |Please avoid sending me Word or PowerPoint attachments.| |http://www.gnu.org/philosophy/no-word-attachments.html | +-------------------------------------------------------+