diff options
author | Neil Hodgson <nyamatongwe@gmail.com> | 2023-02-24 10:43:05 +1100 |
---|---|---|
committer | Neil Hodgson <nyamatongwe@gmail.com> | 2023-02-24 10:43:05 +1100 |
commit | a00f308a11b90a0edb1bd9a71a78612e0463fe83 (patch) | |
tree | c97e63f5fb0c24833e81b7d634e0dc315d3ad822 /cocoa/ScintillaView.mm | |
parent | 778dc10b3ee2f621d8548b1d074429c44bd3ae62 (diff) | |
download | scintilla-mirror-a00f308a11b90a0edb1bd9a71a78612e0463fe83.tar.gz |
Replace deprecated graphicsPort API with current CGContext.
Diffstat (limited to 'cocoa/ScintillaView.mm')
-rw-r--r-- | cocoa/ScintillaView.mm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cocoa/ScintillaView.mm b/cocoa/ScintillaView.mm index ad074b496..6e113b523 100644 --- a/cocoa/ScintillaView.mm +++ b/cocoa/ScintillaView.mm @@ -373,7 +373,7 @@ static NSCursor *cursorFromEnum(Window::Cursor cursor) { * Gets called by the runtime when the view needs repainting. */ - (void) drawRect: (NSRect) rect { - CGContextRef context = (CGContextRef) [NSGraphicsContext currentContext].graphicsPort; + CGContextRef context = CGContextCurrent(); if (!mOwner.backend->Draw(rect, context)) { dispatch_async(dispatch_get_main_queue(), ^ { |