From: Christophe Rhodes Date: Tue, 23 Apr 2013 11:37:04 +0000 (+0100) Subject: support emacs 24 X-Git-Tag: v0.1~13 X-Git-Url: http://christophe.rhodes.io/gitweb/?p=iplayer-el.git;a=commitdiff_plain;h=fdc7d7e30e72d78e91285f0a1b0cfe3d2032daf8;hp=fdc7d7e30e72d78e91285f0a1b0cfe3d2032daf8 support emacs 24 Well this is horrible. Now that execute-extended-command is in Lisp, using completing read, (this-command-keys-vector) ends up returing [13] for a function executed using M-x iplayer RET (rather than the more useful whole extended command key sequence). This means that storing the key sequence for the last command and trying to execute it later mostly has the effect of adding linebreaks. (The old code works if the command was invoked through a key sequence rather than through extended command; I think this suggests that execute-extended-command should be modified to update the various key variables/functions specially, like it already has been for this-command, but that is not helpful right now). So, as well, store the function name and funcall that. Oh, but wait, some of the functions dispatch on the key sequence used to invoke them (presets). So we need to pass the key sequence we were invoked with back. That means we need to have a common signature for iplayer-functions. This is all so horrible. But at least now it works with emacs24. *sigh*. ---