[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] 47/52: Don't call post-completion methods and hook in continue-fa
From: |
Dmitry Gutov |
Subject: |
[elpa] 47/52: Don't call post-completion methods and hook in continue-failed case |
Date: |
Tue, 01 Jul 2014 11:53:33 +0000 |
dgutov pushed a commit to branch master
in repository elpa.
commit f61b8c41714d1e41c2be36e60feedec0ac1ce512
Author: Dmitry Gutov <address@hidden>
Date: Fri Jun 27 06:44:45 2014 +0300
Don't call post-completion methods and hook in continue-failed case
Possibly related to #145.
---
company.el | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/company.el b/company.el
index 485df72..23b2317 100644
--- a/company.el
+++ b/company.el
@@ -1336,8 +1336,10 @@ from the rest of the back-ends in the group, if any,
will be left at the end."
(message "Matching input is required")
company-candidates)
((equal company-prefix (car company-candidates))
- ;; last input was actually success
- (company-cancel company-prefix))
+ ;; Last input was a success,
+ ;; but we're treating it as an abort + input anyway,
+ ;; like the `unique' case below.
+ (company-cancel 'non-unique))
(t (company-cancel)))))
(defun company--good-prefix-p (prefix)
@@ -1365,7 +1367,8 @@ from the rest of the back-ends in the group, if any, will
be left at the end."
((eq c t)
;; t means complete/unique.
;; Handle it like completion was aborted, to differentiate from user
- ;; calling one of Company's commands to insert the candidate.
+ ;; calling one of Company's commands to insert the candidate,
+ ;; not to trigger template expansion, etc.
(company-cancel 'unique))
((consp c)
;; incremental match
@@ -1468,7 +1471,7 @@ from the rest of the back-ends in the group, if any, will
be left at the end."
(defun company-abort ()
(interactive)
- (company-cancel t))
+ (company-cancel 'abort))
(defun company-finish (result)
(company--insert-candidate result)
- [elpa] 36/52: company-css-property-alist: remove reference to font-variant in value for font, (continued)
- [elpa] 36/52: company-css-property-alist: remove reference to font-variant in value for font, Dmitry Gutov, 2014/07/01
- [elpa] 34/52: company-gtags: add arguments insertion, Dmitry Gutov, 2014/07/01
- [elpa] 38/52: Indicate current candidate's backend when it's in a group, Dmitry Gutov, 2014/07/01
- [elpa] 39/52: company-update-group-lighter: privatize, Dmitry Gutov, 2014/07/01
- [elpa] 41/52: Improve comment wording, Dmitry Gutov, 2014/07/01
- [elpa] 37/52: company-pseudo-tooltip-edit: update company-width, Dmitry Gutov, 2014/07/01
- [elpa] 44/52: company-keywords-alist: ass js-mode -> javascript-mode alias, Dmitry Gutov, 2014/07/01
- [elpa] 43/52: company--should-idle-begin: use a more careful check, Dmitry Gutov, 2014/07/01
- [elpa] 42/52: Don't assign to company-point in company-abort and company-finish, Dmitry Gutov, 2014/07/01
- [elpa] 46/52: Never delete the "added newline" twice, Dmitry Gutov, 2014/07/01
- [elpa] 47/52: Don't call post-completion methods and hook in continue-failed case,
Dmitry Gutov <=
- [elpa] 45/52: Bring back this-command check when company-idle-delay is t, Dmitry Gutov, 2014/07/01
- [elpa] 40/52: Define company-sort-by-backend-importance, Dmitry Gutov, 2014/07/01
- [elpa] 49/52: company-backends: add better introduction, Dmitry Gutov, 2014/07/01
- [elpa] 48/52: Avoid requiring match is certain circumstances, Dmitry Gutov, 2014/07/01
- [elpa] 35/52: company-css: Add HTML5 tags and more CSS3 properties, Dmitry Gutov, 2014/07/01
- [elpa] 51/52: Release 0.8.1, Dmitry Gutov, 2014/07/01
- [elpa] 52/52: Merge commit '7c14dedc79bf0c6eaad5bf50b80ea80dd721afdc' from company, Dmitry Gutov, 2014/07/01
- [elpa] 50/52: company-capf.el: Don't ignore things like semantic-capf, Dmitry Gutov, 2014/07/01