File indexing completed on 2024-06-23 05:49:08

0001 /*
0002     This file is part of the Okteta Kasten module, made within the KDE community.
0003 
0004     SPDX-FileCopyrightText: 2010, 2012-2013 Friedrich W. H. Kossebau <kossebau@kde.org>
0005 
0006     SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
0007 */
0008 
0009 #ifndef KASTEN_VIEWPROFILEEDITDIALOG_HPP
0010 #define KASTEN_VIEWPROFILEEDITDIALOG_HPP
0011 
0012 // Qt
0013 #include <QDialog>
0014 
0015 class QPushButton;
0016 
0017 namespace Kasten {
0018 class ViewProfileEdit;
0019 class ByteArrayViewProfile;
0020 
0021 class ViewProfileEditDialog : public QDialog
0022 {
0023     Q_OBJECT
0024 
0025 public:
0026     explicit ViewProfileEditDialog(QWidget* parent = nullptr);
0027 
0028     ~ViewProfileEditDialog() override;
0029 
0030 public:
0031     ByteArrayViewProfile viewProfile() const;
0032 
0033 public:
0034     void setViewProfile(const ByteArrayViewProfile& viewProfile);
0035 
0036 Q_SIGNALS:
0037     void viewProfileAccepted(const Kasten::ByteArrayViewProfile& viewProfile);
0038 
0039 private Q_SLOTS:
0040     void onProfileTitleChanged(const QString& title);
0041     void onFinished(int result);
0042 
0043 private:
0044     ViewProfileEdit* mViewProfileEdit;
0045     QString mId;
0046     QPushButton* mOkButton;
0047 };
0048 
0049 }
0050 
0051 #endif