Closed Bug 1292642 Opened 8 years ago Closed 8 years ago

CoreGraphics can still be the backend somehow

Categories

(Core :: Graphics, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla51
Tracking Status
firefox51 --- fixed

People

(Reporter: mchang, Assigned: mchang)

Details

Attachments

(1 file, 1 obsolete file)

STR:

1) Change the backend to 'cairo'
2) Restart Firefox
3) Somehow, quartz is chosen as the backend.
Assignee: nobody → mchang
The problem was we were defaulting to CG if we had an invalid preference for the content backend. This fixes it so we default to skia.
Attachment #8779030 - Flags: review?(milan)
Comment on attachment 8779030 [details] [diff] [review]
Default to skia if we have an invalid pref for a backend

Review of attachment 8779030 [details] [diff] [review]:
-----------------------------------------------------------------

Not sure this is going far enough.

::: gfx/thebes/gfxPlatformMac.cpp
@@ +73,5 @@
>  {
>      DisableFontActivation();
>      mFontAntiAliasingThreshold = ReadAntiAliasingThreshold();
>  
> +    uint32_t canvasMask = BackendTypeBit(BackendType::SKIA) |

Is this enough?  This looks like we're setting Skia as the default, disallowing Cairo, but still allowing CG for content and canvas.  If I set the content pref to cairo,cg, and run with this change, I assert in mozilla::gfx::BorrowedCGContext::BorrowCGContextFromDrawTarget
Attachment #8779030 - Flags: review?(milan)
(In reply to Milan Sreckovic [:milan] from comment #2)
> Comment on attachment 8779030 [details] [diff] [review]
> Default to skia if we have an invalid pref for a backend
> 
> Review of attachment 8779030 [details] [diff] [review]:
> -----------------------------------------------------------------
> 
> Not sure this is going far enough.
> 
> ::: gfx/thebes/gfxPlatformMac.cpp
> @@ +73,5 @@
> >  {
> >      DisableFontActivation();
> >      mFontAntiAliasingThreshold = ReadAntiAliasingThreshold();
> >  
> > +    uint32_t canvasMask = BackendTypeBit(BackendType::SKIA) |
> 
> Is this enough?  This looks like we're setting Skia as the default,
> disallowing Cairo, but still allowing CG for content and canvas.  If I set
> the content pref to cairo,cg, and run with this change, I assert in
> mozilla::gfx::BorrowedCGContext::BorrowCGContextFromDrawTarget

I added the code back from ESR 45 on borrowing a CG Context from DrawTargetCG. Some things are still broken, but content works. We're only keeping CG around for Jeff to test if he needs to, so it's ok if not everything works.
Attachment #8779030 - Attachment is obsolete: true
Attachment #8779487 - Flags: review?(milan)
Comment on attachment 8779487 [details] [diff] [review]
Default to skia if we have an invalid pref for a backend

Review of attachment 8779487 [details] [diff] [review]:
-----------------------------------------------------------------

I shouldn't be the one reviewing the DrawTargetSkia changes, but since those changes are to the backend we don't support anymore, looks good to me.
Attachment #8779487 - Flags: review?(milan) → review+
Pushed by mchang@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/03b9c5797a8b
Default to skia if we have an invalid pref for a backend on OS X. r=milan
https://hg.mozilla.org/mozilla-central/rev/03b9c5797a8b
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla51
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: