[webkit-qt] A general rule for naming our files (and classes)

Jesus Sanchez-Palencia jesus at webkit.org
Thu Oct 13 06:32:32 PDT 2011


>
> What about using the following guide to name our files?
>

+1 for all that.

In addition, it's not naming related but following this
"let's-keep-things-aligned" wave I would also suggest that we keep only
publicly exposed classes in UIProcess/API/qt. Everything else should be
moved to UIProcess/qt as it was done already with qweberror (soon to be
named QtWebError). I guess the remaining one there is qwebkittypes, but this
is another discussion.

Cheers
jesus


>
> - Public API follow Qt conventions: qsomething.cpp qsomething.h and are
> named
> - Private classes for public API classes follow Qt conventions:
> qsomething_p.h qsomething_p.cpp (if needed)
> - Subclasses and Qt-specific implementations of WebKit/WebCore classes
> use Qt suffix: FrameLoaderClientQt.cpp
> - Other classes created for using in our port use Qt prefix:
> QtFileDownloader, QtViewInterface
>
> This is the best convention I could extract from existing practices.
> If we agree on this rule,
> I'll write it down in the http://trac.webkit.org/wiki/QtWebKitHacking
> page and the
> following files/classes would be renamed or have the file names adjusted:
>
> * UIProcess/qt:
>
> PolicyInterface -> QtPolicyInterface
> qdesktopwebpageproxy -> QtDesktopWebPageProxy
> qtouchwebpageproxy -> QtTouchWebPageProxy
> qweberror -> QtWebError
> SGTileNode -> QtSGTileNode
> SGUpdateQueue -> QtSGUpdateQueue
> TouchViewInterface -> QtTouchViewInterface
> ViewInterface -> QtViewInterface
> ViewportInteractionEngine -> QtViewportInteractionEngine
> WebUndoCommandQt -> QtWebUndoCommand
>
> qwk* files remain as is and will be renamed next time someone work with
> them.
>
>
> * WebProcess/WebCoreSupport/qt:
>
> WebFrameNetworkingContext -> WebFrameNetworkingContextQt
> (Web prefix here to differentiate from WK1 file)
>
>
> Cheers,
>
> --
> Caio Marcelo de Oliveira Filho
> OpenBossa - INdT
> _______________________________________________
> webkit-qt mailing list
> webkit-qt at lists.webkit.org
> http://lists.webkit.org/mailman/listinfo.cgi/webkit-qt
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-qt/attachments/20111013/e6fe80e6/attachment.html>


More information about the webkit-qt mailing list