-EventListener* Node::getInlineEventListener(const AtomicString&
eventType) const
+EventListener* Node::getAttributeEventListener(const AtomicString&
eventType) const
I think that per our coding style guidelines, this function should
be named attributeEventListener():
6. Precede setters with the word "set". Use bare words for getters.
Setter and getter names should match the names of the variables
being set/gotten.
I see where you're coming from. I don't think this is a clear-cut case
if guideline #6, though.
getAttributeEventListener is not a getter for a variable -- it's a
lookup function for a family of variables, which takes a parameter
specifying what to look up. I'm concerned that naming it as if it were
a getter for a variable would be misleading.
We use the "get" prefix in other cases of lookup. For example, we have
*Hash*::get, ByteArray::get, Structure::get, JSValuePtr::get,
DOMObjectWrapperMap::get, getHashTableForGlobalData,
getCachedDOMObjectWrapper, getCachedDOMNodeWrapper,
getCachedDOMStructure, getCachedDOMConstructor, etc. I think this case
is more similar to those lookup functions than it is to a variable
getter.
Geoff
_______________________________________________
webkit-dev mailing list
webkit-dev@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev