]> code.delx.au - gnu-emacs/blobdiff - lisp/net/xesam.el
Move fix for cygw32 icon issue from emacs-24 branch to trunk as Stefan Monnier requests
[gnu-emacs] / lisp / net / xesam.el
index 279ea54e4ccb3e4f7600abf89c5135040d19fcc5..585e5eed52d73bcd4d340ad891cb9ac4e5161ca6 100644 (file)
@@ -1,6 +1,6 @@
 ;;; xesam.el --- Xesam interface to search engines.
 
-;; Copyright (C) 2008-2011 Free Software Foundation, Inc.
+;; Copyright (C) 2008-2012 Free Software Foundation, Inc.
 
 ;; Author: Michael Albinus <michael.albinus@gmx.de>
 ;; Keywords: tools, hypermedia
 
 ;;; Code:
 
-;; D-Bus support in the Emacs core can be disabled with configuration
-;; option "--without-dbus".  Declare used subroutines and variables.
-(declare-function dbus-call-method "dbusbind.c")
-(declare-function dbus-register-signal "dbusbind.c")
-
 (require 'dbus)
 
-;; Pacify byte compiler.
-(eval-when-compile
-  (require 'cl))
-
 ;; Widgets are used to highlight the search results.
 (require 'widget)
 (require 'wid-edit)
 
 (defface xesam-highlight '((t :inherit match))
   "Face to highlight query entries.
-It will be overlayed by `widget-documentation-face', so it shall
+It will be overlaid by `widget-documentation-face', so it shall
 be different at least in one face property not set in that face."
   :group 'xesam)
 
@@ -414,24 +405,24 @@ If there is no registered search engine at all, the function returns `nil'."
        ;; That is not the case now, so we set it ourselves.
        ;; Hopefully, this will change later.
        (setq hit-fields
-             (case (intern vendor-id)
-               (Beagle
+             (pcase (intern vendor-id)
+               (`Beagle
                 '("xesam:mimeType" "xesam:url"))
-               (Strigi
+               (`Strigi
                 '("xesam:author" "xesam:cc" "xesam:charset"
                   "xesam:contentType" "xesam:fileExtension"
                   "xesam:id" "xesam:lineCount" "xesam:links"
                   "xesam:mimeType" "xesam:name" "xesam:size"
                   "xesam:sourceModified" "xesam:subject" "xesam:to"
                   "xesam:url"))
-               (TrackerXesamSession
+               (`TrackerXesamSession
                 '("xesam:relevancyRating" "xesam:url"))
-               (Debbugs
+               (`Debbugs
                 '("xesam:keyword" "xesam:owner" "xesam:title"
                   "xesam:url" "xesam:sourceModified" "xesam:mimeType"
                   "debbugs:key"))
                ;; xesam-tools yahoo service.
-               (t '("xesam:contentModified" "xesam:mimeType" "xesam:summary"
+               (_ '("xesam:contentModified" "xesam:mimeType" "xesam:summary"
                     "xesam:title" "xesam:url" "yahoo:displayUrl"))))
 
        (xesam-set-property engine "hit.fields" hit-fields)
@@ -449,7 +440,7 @@ If there is no registered search engine at all, the function returns `nil'."
 
 (defvar xesam-mode-map
   (let ((map (copy-keymap special-mode-map)))
-    (set-keymap-parent xesam-mode-map widget-keymap)
+    (set-keymap-parent map widget-keymap)
     map))
 
 (define-derived-mode xesam-mode special-mode "Xesam"