File indexing completed on 2024-03-24 05:01:00
0001 /* This file is part of the KDE project 0002 SPDX-FileCopyrightText: 2000 Alexander Neundorf <neundorf@kde.org> 0003 0004 SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #ifndef KSHELLCMDDIALOG_H 0008 #define KSHELLCMDDIALOG_H 0009 0010 #include <QDialog> 0011 0012 class KShellCommandExecutor; 0013 class QPushButton; 0014 0015 class KShellCommandDialog: public QDialog 0016 { 0017 Q_OBJECT 0018 public: 0019 KShellCommandDialog(const QString &title, const QString &command, QWidget *parent = nullptr, bool modal = false); 0020 ~KShellCommandDialog() override; 0021 //blocking 0022 int executeCommand(); 0023 protected: 0024 0025 KShellCommandExecutor *m_shell; 0026 QPushButton *cancelButton; 0027 QPushButton *closeButton; 0028 protected Q_SLOTS: 0029 void disableStopButton(); 0030 void slotClose(); 0031 }; 0032 0033 #endif // KSHELLCMDDIALOG_H