Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5250eb2

Browse files
committed
Preventing content offset changes while the textStorage is editing (#76)
1 parent768ed66 commit5250eb2

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

‎SCXcodeMinimap/SCXcodeMinimapView.m

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -621,6 +621,10 @@ - (void)updateSearchResults
621621

622622
- (void)updateOffset
623623
{
624+
if(self.editorTextView.textStorage.editedMask) {
625+
return;
626+
}
627+
624628
[self.editorTextView.layoutManagerensureLayoutForTextContainer:self.editorTextView.textContainer];
625629

626630
CGFloat editorTextHeight =CGRectGetHeight([self.editorTextView.layoutManagerusedRectForTextContainer:self.editorTextView.textContainer]);
@@ -633,7 +637,7 @@ - (void)updateOffset
633637
[self.selectionViewsetFrame:selectionViewFrame];
634638
return;
635639
}
636-
640+
637641
CGFloat editorYOffset =CGRectGetMinY(self.editor.scrollView.contentView.bounds) +ABS(CGRectGetMinY(self.editorTextView.frame));
638642

639643
CGFloat ratio = (adjustedMinimapContentHeight / adjustedEditorContentHeight) * (1 / self.scrollView.magnification);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp