WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED DUPLICATE of
bug 121504
112857
AXObjectCache::postNotification should use an enum instead of a bool
https://bugs.webkit.org/show_bug.cgi?id=112857
Summary
AXObjectCache::postNotification should use an enum instead of a bool
Eric Seidel (no email)
Reported
2013-03-20 16:49:31 PDT
AXObjectCache::postNotification should use an enum instead of a bool (since it's a multi-argument function) I'm slowly trying to rid WebKit of this pattern, as it leads to very difficult to understand callsites: axObjectCache()->postNotification(node(), AXObjectCache::AXValueChanged, true); At least: axObjectCache()->postNotification(node(), AXObjectCache::AXValueChanged, PostToElement); would be clearer. Although it's not yet clear to me what the "postToElement" bool is supposed to do. :) Once I figure out what postToElement means, I can come up with nice names for a replacement enum. Any suggestions would be most welcome. :)
Attachments
Add attachment
proposed patch, testcase, etc.
Samuel White
Comment 1
2013-09-26 11:22:28 PDT
(In reply to
comment #0
)
> AXObjectCache::postNotification should use an enum instead of a bool (since it's a multi-argument function) > > I'm slowly trying to rid WebKit of this pattern, as it leads to very difficult to understand callsites: > axObjectCache()->postNotification(node(), AXObjectCache::AXValueChanged, true); > > At least: > axObjectCache()->postNotification(node(), AXObjectCache::AXValueChanged, PostToElement); > > would be clearer. Although it's not yet clear to me what the "postToElement" bool is supposed to do. :) > > Once I figure out what postToElement means, I can come up with nice names for a replacement enum. Any suggestions would be most welcome. :)
I was given this same feedback (we should not use a bool) in response to another patch that I landed. I fixed this issue under:
https://bugs.webkit.org/show_bug.cgi?id=121504
before I saw this bug. Apologies. Marking as dupe, but note that this bug was filed first. Not sure if there's a better way to indicate that. Thanks! *** This bug has been marked as a duplicate of
bug 121504
***
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug