small fixes for kwaylandScanner

* fix initializer type -- was hardcoded, seems like an oversight
* add semicolons after class declarations -- one less thing to fix in the
  resulting code

REVIEW:125110
This commit is contained in:
Sebastian Kügler 2015-09-09 17:52:43 +02:00
parent 423f4e7c2f
commit 28df14c441

View file

@ -672,7 +672,7 @@ void Generator::generateServerGlobalClass(const Interface &interface)
" explicit %1(Display *display, QObject *parent = nullptr);\n" " explicit %1(Display *display, QObject *parent = nullptr);\n"
" friend class Display;\n" " friend class Display;\n"
" class Private;\n" " class Private;\n"
"}\n" "};\n"
"\n"); "\n");
*m_stream.localData() << templateString.arg(interface.kwaylandServerName()); *m_stream.localData() << templateString.arg(interface.kwaylandServerName());
} }
@ -692,7 +692,7 @@ void Generator::generateServerResourceClass(const Interface &interface)
"\n" "\n"
" class Private;\n" " class Private;\n"
" Private *d_func() const;\n" " Private *d_func() const;\n"
"}\n" "};\n"
"\n"); "\n");
*m_stream.localData() << templateString.arg(interface.kwaylandServerName()).arg(interface.factory()->kwaylandServerName()); *m_stream.localData() << templateString.arg(interface.kwaylandServerName()).arg(interface.factory()->kwaylandServerName());
} }
@ -779,7 +779,7 @@ void Generator::generateServerPrivateGlobalCtorBindClass(const Interface &interf
{ {
QString templateString = QStringLiteral( QString templateString = QStringLiteral(
"%1::Private::Private(%1 *q, Display *d)\n" "%1::Private::Private(%1 *q, Display *d)\n"
" : Global::Private(d, &org_kde_kwin_blur_manager_interface, s_version)\n" " : Global::Private(d, &%2_interface, s_version)\n"
" , q(q)\n" " , q(q)\n"
"{\n" "{\n"
"}\n" "}\n"
@ -825,7 +825,7 @@ void Generator::generateServerPrivateResourceClass(const Interface &interface)
" }\n" " }\n"
"\n" "\n"
" static const struct %2_interface s_interface;\n" " static const struct %2_interface s_interface;\n"
"}\n" "};\n"
"\n"); "\n");
*m_stream.localData() << templateString.arg(interface.kwaylandServerName()).arg(interface.name()); *m_stream.localData() << templateString.arg(interface.kwaylandServerName()).arg(interface.name());