Skip to content

Commit

Permalink
actually activate the visual effect
Browse files Browse the repository at this point in the history
  • Loading branch information
shuang886 committed Nov 23, 2023
1 parent 6da939c commit 71750dd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -228,11 +228,11 @@ public class HorizontalCandidateController: CandidateController {
let effect = NSVisualEffectView(frame: NSRect(x: 0, y: 0, width: 0, height: 0))
effect.blendingMode = .behindWindow
if #available(macOS 10.14, *) {
effect.material = .contentBackground
effect.material = .popover
} else {
effect.material = .appearanceBased
}
effect.wantsLayer = true
effect.state = .active
effect.maskImage = .mask(withCornerRadius: 4)
panel.contentView = effect

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,11 @@ public class VerticalCandidateController: CandidateController {
let effect = NSVisualEffectView(frame: NSRect(x: 0, y: 0, width: 0, height: 0))
effect.blendingMode = .behindWindow
if #available(macOS 10.14, *) {
effect.material = .contentBackground
effect.material = .popover
} else {
effect.material = .appearanceBased
}
effect.wantsLayer = true
effect.state = .active
effect.maskImage = .mask(withCornerRadius: 4)
panel.contentView = effect

Expand Down

0 comments on commit 71750dd

Please sign in to comment.