Repo // isAssociatedPhrasesMode -> isAssociatedPhrasesState.
This commit is contained in:
parent
43609bd899
commit
8fd2f96163
|
@ -52,7 +52,7 @@ extension ctlInputMethod: KeyHandlerDelegate {
|
||||||
// MARK: - Candidate Controller Delegate
|
// MARK: - Candidate Controller Delegate
|
||||||
|
|
||||||
extension ctlInputMethod: ctlCandidateDelegate {
|
extension ctlInputMethod: ctlCandidateDelegate {
|
||||||
var isAssociatedPhrasesMode: Bool { state is InputState.AssociatedPhrases }
|
var isAssociatedPhrasesState: Bool { state is InputState.AssociatedPhrases }
|
||||||
|
|
||||||
/// 完成 handle() 函式本該完成的內容,但去掉了與 IMK 選字窗有關的判斷語句。
|
/// 完成 handle() 函式本該完成的內容,但去掉了與 IMK 選字窗有關的判斷語句。
|
||||||
/// 這樣分開處理很有必要,不然 handle() 函式會陷入無限迴圈。
|
/// 這樣分開處理很有必要,不然 handle() 函式會陷入無限迴圈。
|
||||||
|
|
|
@ -27,7 +27,7 @@ public class CandidateKeyLabel: NSObject {
|
||||||
}
|
}
|
||||||
|
|
||||||
public protocol ctlCandidateDelegate: AnyObject {
|
public protocol ctlCandidateDelegate: AnyObject {
|
||||||
var isAssociatedPhrasesMode: Bool { get }
|
var isAssociatedPhrasesState: Bool { get }
|
||||||
func sharedEventHandler(_ event: NSEvent!) -> Bool
|
func sharedEventHandler(_ event: NSEvent!) -> Bool
|
||||||
func candidateCountForController(_ controller: ctlCandidateProtocol) -> Int
|
func candidateCountForController(_ controller: ctlCandidateProtocol) -> Int
|
||||||
func candidatesForController(_ controller: ctlCandidateProtocol) -> [(String, String)]
|
func candidatesForController(_ controller: ctlCandidateProtocol) -> [(String, String)]
|
||||||
|
|
|
@ -310,7 +310,7 @@ public class ctlCandidateIMK: IMKCandidates, ctlCandidateProtocol {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if delegate.isAssociatedPhrasesMode,
|
if delegate.isAssociatedPhrasesState,
|
||||||
!input.isPageUp, !input.isPageDown, !input.isCursorForward, !input.isCursorBackward,
|
!input.isPageUp, !input.isPageDown, !input.isCursorForward, !input.isCursorBackward,
|
||||||
!input.isCursorClockLeft, !input.isCursorClockRight, !input.isSpace,
|
!input.isCursorClockLeft, !input.isCursorClockRight, !input.isSpace,
|
||||||
!input.isEnter || !mgrPrefs.alsoConfirmAssociatedCandidatesByEnter
|
!input.isEnter || !mgrPrefs.alsoConfirmAssociatedCandidatesByEnter
|
||||||
|
|
Loading…
Reference in New Issue