QFontDialog: optimize allocation of QFontDialogOptions

Use QSharedPointer::create(), to fuse control block and
payload into a single memory allocation.

Change-Id: I8d87c73566c3be960e957ec0b5419a77da2fc8c9
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
This commit is contained in:
Marc Mutz 2016-01-06 10:02:04 +01:00
parent caee8f6107
commit 14a5a175ae

View File

@ -103,7 +103,8 @@ static const Qt::WindowFlags DefaultWindowFlags =
Qt::Dialog | Qt::WindowSystemMenuHint;
QFontDialogPrivate::QFontDialogPrivate()
: writingSystem(QFontDatabase::Any), options(new QFontDialogOptions)
: writingSystem(QFontDatabase::Any),
options(QSharedPointer<QFontDialogOptions>::create())
{
}