Improve readability of updateWidget by converting bool parameter to an enum
Created attachment 80891 [details] Patch
Comment on attachment 80891 [details] Patch OK. I hope that someone actually refactors this code one day, so that we don't pass plugin creation option in HTMLMediaElement::updateWidget(), and that HTMLPlugInImageElement::updateWidgetIfNecessary() doesn't know about types of plug-ins!
Comment on attachment 80891 [details] Patch Yes. This code is pretty goofy.
Comment on attachment 80891 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=80891&action=review > Source/WebCore/html/HTMLPlugInImageElement.h:33 > + CreateAllWidgetTypes, CreateAnyPluginType is better, I think.
> CreateAnyPluginType is better, I think. Maybe "CreateAnyWidgeType" ? This function can create more than just plugins.
I think that to make these two changes a definitive win, you could also add a proper FIXME comment to the original spot, perhaps something like "FIXME: Why do we have a special case for some plug-in types here?"
Created attachment 80892 [details] Patch for landing
Thanks Adam!
Comment on attachment 80892 [details] Patch for landing Clearing flags on attachment: 80892 Committed r77366: <http://trac.webkit.org/changeset/77366>
All reviewed patches have been landed. Closing bug.