SessionCtl // Implement updatePopupDisplayWithCursor().

This commit is contained in:
ShikiSuen 2023-03-11 16:59:56 +08:00
parent 5a03fcc510
commit 0423ce727c
1 changed files with 7 additions and 2 deletions

View File

@ -87,11 +87,16 @@ public extension SessionCtl {
showCandidates()
}
//
if newState.hasComposition, clientMitigationLevel >= 2 {
updatePopupDisplayWithCursor()
}
///
func updatePopupDisplayWithCursor() {
if state.hasComposition, clientMitigationLevel >= 2 {
updateVerticalTypingStatus()
popupCompositionBuffer.isTypingDirectionVertical = isVerticalTyping
popupCompositionBuffer.show(
state: newState, at: lineHeightRect(zeroCursor: true).origin
state: state, at: lineHeightRect(zeroCursor: true).origin
)
} else {
popupCompositionBuffer.hide()