Skip to content

Commit

Permalink
Merge pull request #220 from jcs-PR/fix/compile
Browse files Browse the repository at this point in the history
  • Loading branch information
jcs090218 committed May 20, 2024
2 parents 1e1c94d + ec84418 commit 1f52e81
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
8 changes: 4 additions & 4 deletions lsp-dart-flutter-fringe-colors.el
Original file line number Diff line number Diff line change
Expand Up @@ -75,23 +75,23 @@
(if-let ((color (-> (match-string 1)
(assoc lsp-dart-flutter-colors)
cdr)))
(lsp-dart-flutter-fringe--add-color (concat "#" color) buffer (point-at-bol))))
(lsp-dart-flutter-fringe--add-color (concat "#" color) buffer (line-beginning-position))))
(goto-char (point-min))
(while (re-search-forward lsp-dart-flutter-fringe-color-hex-pattern nil t)
(let ((color (concat "#" (substring (match-string 1) 2))))
(lsp-dart-flutter-fringe--add-color color buffer (point-at-bol))))
(lsp-dart-flutter-fringe--add-color color buffer (line-beginning-position))))
(goto-char (point-min))
(while (re-search-forward lsp-dart-flutter-fringe-color-argb-pattern nil t)
(let ((color (lsp-dart-flutter-fringe--rgb-to-hex (match-string 2)
(match-string 3)
(match-string 4))))
(lsp-dart-flutter-fringe--add-color color buffer (point-at-bol))))
(lsp-dart-flutter-fringe--add-color color buffer (line-beginning-position))))
(goto-char (point-min))
(while (re-search-forward lsp-dart-flutter-fringe-color-rgbo-pattern nil t)
(let ((color (lsp-dart-flutter-fringe--rgb-to-hex (match-string 1)
(match-string 2)
(match-string 3))))
(lsp-dart-flutter-fringe--add-color color buffer (point-at-bol)))))))
(lsp-dart-flutter-fringe--add-color color buffer (line-beginning-position)))))))

(define-minor-mode lsp-dart-flutter-fringe-colors-mode
"Mode for displaying colors in fringe."
Expand Down
4 changes: 2 additions & 2 deletions lsp-dart-utils.el
Original file line number Diff line number Diff line change
Expand Up @@ -206,8 +206,8 @@ FLUTTER_ROOT environment variable."
(-some
(lambda (strategy)
(cl-case strategy
('lsp-root (lsp-workspace-root))
('closest-pubspec (-some-> default-directory
(`lsp-root (lsp-workspace-root))
(`closest-pubspec (-some-> default-directory
(locate-dominating-file "pubspec.yaml")
file-truename))))
lsp-dart-project-root-discovery-strategies))
Expand Down
2 changes: 2 additions & 0 deletions lsp-dart.el
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@
(require 'lsp-dart-flutter-widget-guide)
(require 'lsp-dart-commands)

(declare-function yas-minor-mode "ext:yasnippet.el")

(defgroup lsp-dart nil
"LSP support for Dart, using dart analysis server."
:prefix "lsp-dart-"
Expand Down

0 comments on commit 1f52e81

Please sign in to comment.