Pre Merge pull request !85 from ShikiSuen/upd/1.9.3sp2
This commit is contained in:
commit
ac66d93baa
|
@ -83,12 +83,9 @@ public class ctlCandidateIMK: IMKCandidates, ctlCandidateProtocol {
|
||||||
}
|
}
|
||||||
|
|
||||||
public func reloadData() {
|
public func reloadData() {
|
||||||
guard let delegate = delegate else { return }
|
// guard let delegate = delegate else { return } // 下文無效,所以這句沒用。
|
||||||
let candidates = delegate.candidatesForController(self).map { theCandidate -> String in
|
// 既然下述函式無效,那中間這段沒用的也都砍了。
|
||||||
let theConverted = IME.kanjiConversionIfRequired(theCandidate.1)
|
// setCandidateData(candidates) // 該函式無效。
|
||||||
return (theCandidate.1 == theConverted) ? theCandidate.1 : "\(theConverted)(\(theCandidate.1))"
|
|
||||||
}
|
|
||||||
setCandidateData(candidates)
|
|
||||||
keyCount = selectionKeys().count
|
keyCount = selectionKeys().count
|
||||||
selectedCandidateIndex = 0
|
selectedCandidateIndex = 0
|
||||||
update()
|
update()
|
||||||
|
|
|
@ -88,8 +88,8 @@ private class vwrCandidateUniversal: NSView {
|
||||||
calculatedWindowWidth = rctCandidate.size.width + cellPadding * 2
|
calculatedWindowWidth = rctCandidate.size.width + cellPadding * 2
|
||||||
}
|
}
|
||||||
case false:
|
case false:
|
||||||
if cellWidth < cellHeight * 1.35 {
|
if cellWidth < cellHeight * 1.4 {
|
||||||
cellWidth = cellHeight * 1.35
|
cellWidth = cellHeight * 1.4
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
newWidths.append(round(cellWidth))
|
newWidths.append(round(cellWidth))
|
||||||
|
|
Loading…
Reference in New Issue