aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorNeil Hodgson <nyamatongwe@gmail.com>2015-08-23 12:05:12 +1000
committerNeil Hodgson <nyamatongwe@gmail.com>2015-08-23 12:05:12 +1000
commite6871279bd799686ae2d107076c59742623657c4 (patch)
tree25214f6d95bc7423c9b5f4ef9cbdaf10c958720a
parent4e8b2664875fbb809f6429bee5f2ad6906d5641d (diff)
downloadscintilla-mirror-e6871279bd799686ae2d107076c59742623657c4.tar.gz
Potential fix for bug [#1751]. Remove setting of current graphics context.
-rw-r--r--cocoa/ScintillaCocoa.mm8
1 files changed, 0 insertions, 8 deletions
diff --git a/cocoa/ScintillaCocoa.mm b/cocoa/ScintillaCocoa.mm
index e4117eb15..dd7afe120 100644
--- a/cocoa/ScintillaCocoa.mm
+++ b/cocoa/ScintillaCocoa.mm
@@ -1421,13 +1421,7 @@ void ScintillaCocoa::StartDrag()
paintState = painting;
sw->InitPixMap(static_cast<int>(client.Width()), static_cast<int>(client.Height()), NULL, NULL);
paintingAllText = true;
- // Have to create a new context and make current as text drawing goes
- // to the current context, not a passed context.
CGContextRef gcsw = sw->GetContext();
- NSGraphicsContext *nsgc = [NSGraphicsContext graphicsContextWithGraphicsPort: gcsw
- flipped: YES];
- [NSGraphicsContext saveGraphicsState];
- [NSGraphicsContext setCurrentContext:nsgc];
CGContextTranslateCTM(gcsw, -client.left, -client.top);
Paint(sw, client);
paintState = notPainting;
@@ -1445,8 +1439,6 @@ void ScintillaCocoa::StartDrag()
// XXX TODO: overwrite any part of the image that is not part of the
// selection to make it transparent. right now we just use
// the full rectangle which may include non-selected text.
-
- [NSGraphicsContext restoreGraphicsState];
}
sw->Release();
delete sw;