Review Request 118225: Minimal support for exported QML components

Commit Hook null at kde.org
Tue May 20 17:36:58 UTC 2014


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/118225/#review58202
-----------------------------------------------------------


This review has been submitted with commit fa3f518dc50e608350335fc846dd5981ab852032 by Denis Steckelmacher to branch master.

- Commit Hook


On May 20, 2014, 4:57 p.m., Denis Steckelmacher wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/118225/
> -----------------------------------------------------------
> 
> (Updated May 20, 2014, 4:57 p.m.)
> 
> 
> Review request for KDevelop.
> 
> 
> Repository: kdev-qmljs
> 
> 
> Description
> -------
> 
> In plugin.qmltypes files, QML components have "C++-ish" names, like "QQmlRectangle". The real QML name can be found in the "exports" property of select components. An export is a string like "QtQuick/Rectangle 1.0". Each component therefore has a namespace, a name and a version.
> 
> This patch adds support for exported component names. The namespace and the version are currently ignored, by they may be used in the future in order to tell the user that a component requires an import statement with a greater version number than provided.
> 
> Regarding the code quality, I'm not quite happy with the nested if and for loops that I had to add, but the QMLJS parser is again unable to provide a nice "ArrayEntry" node that would have made everything simpler. I'm obliged to iterate over a ElementList node and to cast its expression to a string literal.
> 
> 
> Diffs
> -----
> 
>   tests/files/plugins.qml 7544a8f 
>   duchain/declarationbuilder.cpp 01ebb15 
>   duchain/declarationbuilder.h aad8e2b 
> 
> Diff: https://git.reviewboard.kde.org/r/118225/diff/
> 
> 
> Testing
> -------
> 
> A test suite has been added. It ensures that a component like this:
> 
> Component {
>     name: "QAbstractItemModel"
>     prototype: "QObject"
>     exports: ["QtQuick/AbstractItemModel 1.0"]
> }
> 
> Is displayed in the outline as "QAbstractItemModel" and "AsbtractItemModel".
> 
> 
> Thanks,
> 
> Denis Steckelmacher
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20140520/f2377da4/attachment.html>


More information about the KDevelop-devel mailing list