Files
qt-creator/share/qtcreator/templates/wizards/projects/cpplibrary/lib.cpp
Christian Kandeler a296b84dc4 Wizards: Fix include statements
The header file must be referenced relative to the location of the
source file.

Task-number: QTCREATORBUG-15599
Change-Id: Ib7d4aa5a62a94541cbe32cd340a8a1e7d6ef35e5
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2019-04-30 10:47:44 +00:00

18 lines
531 B
C++

%{Cpp:LicenseTemplate}\
#include "%{JS: Util.relativeFilePath('%{Path}/%{HdrFileName}', '%{Path}' + '/' + Util.path('%{SrcFileName}'))}"
%{JS: Cpp.openNamespaces('%{Class}')}\
@if ! %{IsQtPlugin}
%{CN}::%{CN}()
{
}
@else
%{CN}::%{CN}(QObject *parent)
: %{BaseClassName}(parent)
{
}
%{JS: '%{PluginMethods}'.split('|').map(s => '\n' + s.replace(/([a-zA-Z0-9]+\()/, '%{CN}::$1') + '\n\u007B\n static_assert(false, "You need to implement this function");\n\u007D').join('\n')}\
@endif
%{JS: Cpp.closeNamespaces('%{Class}')}\