Merge pull request #38 from eagleoflqj/macos

enable on macOS non-ssh
This commit is contained in:
依云 2025-12-28 08:52:03 +08:00 committed by GitHub
commit 3c9a71b892
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -5,7 +5,7 @@ scriptencoding utf-8
" URL: https://www.vim.org/scripts/script.php?script_id=3764
" ---------------------------------------------------------------------
" Load Once:
if &cp || exists("g:loaded_fcitx") || (!exists('$DISPLAY') && !exists('$WAYLAND_DISPLAY'))
if &cp || exists("g:loaded_fcitx") || (!exists('$DISPLAY') && !exists('$WAYLAND_DISPLAY') && !(has('mac') && !exists('$SSH_TTY')))
finish
endif
let s:keepcpo = &cpo
@ -33,7 +33,7 @@ function s:setup_cmd()
let g:loaded_fcitx = 1
endfunction
" If g:fcitx5_remote is set (to the path to `fcitx5-remove`), use it to toggle IME state.
" If g:fcitx5_remote is set (to the path to `fcitx5-remote`), use it to toggle IME state.
if exists("g:fcitx5_remote")
call s:setup_cmd()