Skip to content

Commit 6f605a2

Browse files
committed
Move to styleMinimapView
1 parent c688bcb commit 6f605a2

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

Sources/CodeEditSourceEditor/Controller/TextViewController+LoadView.swift

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@ extension TextViewController {
2929
)
3030

3131
minimapView = MinimapView(textView: textView, theme: theme)
32-
minimapView.postsFrameChangedNotifications = true
33-
minimapView.isHidden = !showMinimap
3432
scrollView.addFloatingSubview(minimapView, for: .vertical)
3533

3634
let findViewController = FindViewController(target: self, childView: scrollView)
@@ -47,6 +45,7 @@ extension TextViewController {
4745
styleTextView()
4846
styleScrollView()
4947
styleGutterView()
48+
styleMinimapView()
5049
setUpHighlighter()
5150
setUpTextFormation()
5251

Sources/CodeEditSourceEditor/Controller/TextViewController+StyleViews.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,11 @@ extension TextViewController {
6767
scrollView.scrollerStyle = .overlay
6868
}
6969

70+
package func styleMinimapView() {
71+
minimapView.postsFrameChangedNotifications = true
72+
minimapView.isHidden = !showMinimap
73+
}
74+
7075
/// Updates all relevant content insets including the find panel, scroll view, minimap and gutter position.
7176
package func updateContentInsets() {
7277
updateTextInsets()

0 commit comments

Comments
 (0)