diff options
| author | Lars Ingebrigtsen | 2018-04-14 20:32:05 +0200 |
|---|---|---|
| committer | Lars Ingebrigtsen | 2018-04-14 20:32:05 +0200 |
| commit | 5b535761f616f01277111cfbb9c635e7a417afad (patch) | |
| tree | 54f56d0e1aefaa66e69ad14f5a329e7e59498dbf | |
| parent | cdefc045893a7fed57856ac385ab41c71f61c09f (diff) | |
| download | emacs-5b535761f616f01277111cfbb9c635e7a417afad.tar.gz emacs-5b535761f616f01277111cfbb9c635e7a417afad.zip | |
Rename url-button-google-url
* lisp/erc/erc-button.el (erc-button-search-url): Renamed from
url-button-google-url (bug#25717). Suggested by Andrew Robbins.
(erc-button-alist): Use it.
| -rw-r--r-- | etc/NEWS | 6 | ||||
| -rw-r--r-- | lisp/erc/erc-button.el | 8 |
2 files changed, 12 insertions, 2 deletions
| @@ -210,6 +210,12 @@ concept index in the Gnus manual for the `match-list' entry. | |||
| 210 | +++ | 210 | +++ |
| 211 | *** nil is no longer an allowed value for `mm-text-html-renderer'. | 211 | *** nil is no longer an allowed value for `mm-text-html-renderer'. |
| 212 | 212 | ||
| 213 | ** erc | ||
| 214 | |||
| 215 | --- | ||
| 216 | *** `erc-button-google-url' has been renamed `erc-button-search-url' | ||
| 217 | and its value has been changed to Duck Duck Go. | ||
| 218 | |||
| 213 | ** eww/shr | 219 | ** eww/shr |
| 214 | 220 | ||
| 215 | *** When opening external links in eww/shr (typically with the | 221 | *** When opening external links in eww/shr (typically with the |
diff --git a/lisp/erc/erc-button.el b/lisp/erc/erc-button.el index 8269e5c1634..8e1be30f352 100644 --- a/lisp/erc/erc-button.el +++ b/lisp/erc/erc-button.el | |||
| @@ -121,12 +121,16 @@ longer than `erc-fill-column'." | |||
| 121 | :group 'erc-button | 121 | :group 'erc-button |
| 122 | :type 'string) | 122 | :type 'string) |
| 123 | 123 | ||
| 124 | (defcustom erc-button-google-url "http://www.google.com/search?q=%s" | 124 | (defcustom erc-button-search-url "http://duckduckgo.com/?q=%s" |
| 125 | "URL used to browse Google search references. | 125 | "URL used to browse Google search references. |
| 126 | %s is replaced by the search string." | 126 | %s is replaced by the search string." |
| 127 | :version "27.1" | ||
| 127 | :group 'erc-button | 128 | :group 'erc-button |
| 128 | :type 'string) | 129 | :type 'string) |
| 129 | 130 | ||
| 131 | (define-obsolete-variable-alias 'erc-button-google-url | ||
| 132 | 'erc-button-search-url "27.1") | ||
| 133 | |||
| 130 | (defcustom erc-button-alist | 134 | (defcustom erc-button-alist |
| 131 | ;; Since the callback is only executed when the user is clicking on | 135 | ;; Since the callback is only executed when the user is clicking on |
| 132 | ;; a button, it makes no sense to optimize performance by | 136 | ;; a button, it makes no sense to optimize performance by |
| @@ -148,7 +152,7 @@ longer than `erc-fill-column'." | |||
| 148 | ("Lisp:\\([a-zA-Z.+-]+\\)" 0 t erc-browse-emacswiki-lisp 1) | 152 | ("Lisp:\\([a-zA-Z.+-]+\\)" 0 t erc-browse-emacswiki-lisp 1) |
| 149 | ("\\bGoogle:\\([^ \t\n\r\f]+\\)" | 153 | ("\\bGoogle:\\([^ \t\n\r\f]+\\)" |
| 150 | 0 t (lambda (keywords) | 154 | 0 t (lambda (keywords) |
| 151 | (browse-url (format erc-button-google-url keywords))) | 155 | (browse-url (format erc-button-search-url keywords))) |
| 152 | 1) | 156 | 1) |
| 153 | ("\\brfc[#: ]?\\([0-9]+\\)" | 157 | ("\\brfc[#: ]?\\([0-9]+\\)" |
| 154 | 0 t (lambda (num) | 158 | 0 t (lambda (num) |