Closed
Bug 379640
Opened 17 years ago
Closed 17 years ago
[10.3] render to given CGContextRef in nsITheme DrawButton
Categories
(Core :: Widget: Cocoa, defect)
Tracking
()
RESOLVED
FIXED
Future
People
(Reporter: jaas, Assigned: jaas)
Details
We can't use the following call because it is 10.4+: [NSGraphicsContext graphicsContextWithGraphicsPort:cgContext flipped:YES] Because of that we are always rendering to the current context and not the given context. We need to fix that without breaking 10.3.
Comment 1•17 years ago
|
||
It seems we're unable to use NSImage, then. Asking a number of people, they've said that there's no "quick" way. Assuming we want to keep our NSImage drawing code, we should: -Do all our drawing with NSImage -Convert from the image's NSBitmapImageRep to a CGImage -Draw that into the CGContext. I'm not sure if there's an easy way to blit one context to another (I didn't find one) but if there is, we could |lockFocus| on the NSView and then do [[NSGraphicsContext getGraphicsContext] graphicsPort] to get a CGContext out of it.
Updated•17 years ago
|
Assignee: joshmoz → cbarrett
Updated•17 years ago
|
Target Milestone: --- → mozilla1.9alpha5
Adding 10.3 to the summary since this is really only a problem on 10.3. It works fine on 10.4 but we had to comment out the code because 10.3 can't handle it.
Summary: render to given CGContextRef in nsITheme DrawButton → [10.3] render to given CGContextRef in nsITheme DrawButton
Updated•17 years ago
|
Target Milestone: mozilla1.9alpha5 → mozilla1.9alpha6
Since we don't support 10.3 on the trunk any more and using a 10.4 SDK config fixes this, this is no longer a blocker. It will be fixed when we check in new configure files for tinderboxes.
Flags: blocking1.9+ → blocking1.9-
Updated•17 years ago
|
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Comment 5•17 years ago
|
||
Fixed by bug 385221
Status: NEW → RESOLVED
Closed: 17 years ago → 17 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•