Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qquickdialogimplfactory.cpp
Go to the documentation of this file.
1// Copyright (C) 2021 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
5
6#include <QtCore/qloggingcategory.h>
7
8#include <QtQuick/private/qtquickglobal_p.h>
9#if QT_CONFIG(quick_listview)
13#endif
16
18
25Q_LOGGING_CATEGORY(lcQuickDialogImplFactory, "qt.quick.dialogs.quickdialogimplfactory")
26
27std::unique_ptr<QPlatformDialogHelper> QQuickDialogImplFactory::createPlatformDialogHelper(QQuickDialogType type, QObject *parent)
28{
29 std::unique_ptr<QPlatformDialogHelper> dialogHelper;
30 switch (type) {
32 dialogHelper.reset(new QQuickPlatformColorDialog(parent));
33 break;
34 }
35#if QT_CONFIG(quick_listview)
37 dialogHelper.reset(new QQuickPlatformFileDialog(parent));
38 break;
39 }
41 dialogHelper.reset(new QQuickPlatformFolderDialog(parent));
42 break;
43 }
45 dialogHelper.reset(new QQuickPlatformFontDialog(parent));
46 break;
47 }
48#endif
50 dialogHelper.reset(new QQuickPlatformMessageDialog(parent));
51 break;
52 }
53 default:
54 break;
55 }
56
57 return dialogHelper;
58}
59
\inmodule QtCore
Definition qobject.h:103
The QPlatformDialogHelper class allows for platform-specific customization of dialogs.
Combined button and popup list for selecting options.
#define Q_LOGGING_CATEGORY(name,...)
GLenum type
QQuickDialogType