Files
qt-creator/share/qtcreator/templates/wizards/projects/cpplibrary/lib.cpp
Eike Ziller cb63706f83 Move C++ Library wizard to JSON
And add build system option (QMake & CMake)

Task-number: QTCREATORBUG-17308
Fixes: QTCREATORBUG-14605
Change-Id: Ibfadc4bffeabd7ec11271647460a21b6400625c7
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-04-17 10:53:21 +00:00

18 lines
444 B
C++

%{Cpp:LicenseTemplate}\
#include "%{HdrFileName}"
%{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}')}\