Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qohosoperationstatus.cpp
Go to the documentation of this file.
1// Copyright (C) 2026 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
7
8namespace QtOhosAppKit {
9
10using namespace Private;
11
12/*!
13 \class QtOhosAppKit::OperationStatus
14 \inmodule QtOhosAppKit
15 \since 5.12.12
16
17 \brief The OperationStatus class provides interface to get an opertaion status.
18
19 An instance of this class is created internally by QtOhosAppKit module. Developer cannot
20 create an instance - it is for checking operation status only.
21*/
22
23namespace {
24
25class QOhosOperationStatusImpl : public OperationStatus
26{
27public:
28 QOhosOperationStatusImpl(bool success)
29 : OperationStatus()
30 , m_success(success)
31 {}
32
33 /*!
34 \fn bool QtOhosAppKit::OperationStatus::success() const
35
36 Returns operations status.
37
38 \return true on success, false otherwise
39 */
40 bool success() const override
41 {
42 return m_success;
43 }
44
45private:
46 bool m_success;
47};
48
49}
50
53
55{
56 return std::make_shared<QOhosOperationStatusImpl>(status);
57}
58
59}
60
61QT_END_NAMESPACE
Combined button and popup list for selecting options.
std::shared_ptr< OperationStatus > createOperationStatus(bool status)