Added $publicclassregexp variable to sync.profile

$publicclassregexp specifies the prefix for Qt classes in a qt5 module. For example
in QtJsonDb all classes have "JsonDb" prefix and forward include headers were
not generated properly - e.g. "jsondb-client.h" was generated in the include
folder, but "JsonDbClient" (which matches class name) was not.

Change-Id: I6b57a799d926254e2ab3fd00fa6e38f95b8eb96c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
Reviewed-by: Prasanth Ullattil <prasanth.ullattil@nokia.com>
This commit is contained in:
Denis Dzyubenko 2012-01-04 14:34:39 +01:00 committed by Qt by Nokia
parent e1149349c1
commit 6b46741876

View File

@ -304,11 +304,16 @@ sub classNames {
push @symbols, "QMutable" . $1 . "Iterator";
}
our $publicclassregexp;
foreach my $symbol (@symbols) {
$symbol = (join("::", @namespaces) . "::" . $symbol) if (scalar @namespaces);
push @ret, $symbol
if ($symbol =~ /^Q[^:]*$/ # no-namespace, starting with Q
|| $symbol =~ /^Phonon::/); # or in the Phonon namespace
if ($symbol =~ /^Q[^:]*$/ # no-namespace, starting with Q
|| $symbol =~ /^Phonon::/) { # or in the Phonon namespace
push @ret, $symbol;
} elsif (defined($publicclassregexp)) {
push @ret, $symbol if ($symbol =~ $publicclassregexp);
}
}
}
}