mirror of
https://bitbucket.org/smil3y/kde-extraapps.git
synced 2025-02-23 10:22:52 +00:00
partitionmanager: remove clashing ExternalCommand::exitCode() method
QProcess has such method, its value defaults to zero tho Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
7b7b6eb826
commit
1bfc437dfb
2 changed files with 0 additions and 13 deletions
|
@ -33,7 +33,6 @@
|
|||
*/
|
||||
ExternalCommand::ExternalCommand(const QString& cmd, const QStringList& args) :
|
||||
m_Report(NULL),
|
||||
m_ExitCode(-1),
|
||||
m_Output()
|
||||
{
|
||||
m_Command = cmd;
|
||||
|
@ -48,7 +47,6 @@ ExternalCommand::ExternalCommand(const QString& cmd, const QStringList& args) :
|
|||
*/
|
||||
ExternalCommand::ExternalCommand(Report& report, const QString& cmd, const QStringList& args) :
|
||||
m_Report(report.newChild()),
|
||||
m_ExitCode(-1),
|
||||
m_Output()
|
||||
{
|
||||
m_Command = cmd;
|
||||
|
@ -66,7 +64,6 @@ void ExternalCommand::setup()
|
|||
setProcessChannelMode(QProcess::MergedChannels);
|
||||
|
||||
connect(this, SIGNAL(readyReadStandardOutput()), this, SLOT(onReadOutput()));
|
||||
connect(this, SIGNAL(finished(int, QProcess::ExitStatus)), this, SLOT(onFinished(int)));
|
||||
}
|
||||
|
||||
/** Starts the external commands.
|
||||
|
@ -130,8 +127,3 @@ void ExternalCommand::onReadOutput()
|
|||
if (report())
|
||||
*report() << s;
|
||||
}
|
||||
|
||||
void ExternalCommand::onFinished(int exitCode)
|
||||
{
|
||||
setExitCode(exitCode);
|
||||
}
|
||||
|
|
|
@ -51,8 +51,6 @@ class LIBPARTITIONMANAGERPRIVATE_EXPORT ExternalCommand : public QProcess
|
|||
bool waitFor(int timeout = 30000);
|
||||
bool run(int timeout = 30000);
|
||||
|
||||
int exitCode() const { return m_ExitCode; } /**< @return the exit code */
|
||||
|
||||
const QString& output() const { return m_Output; } /**< @return the command output */
|
||||
|
||||
Report* report() { return m_Report; } /**< @return pointer to the Report or NULL */
|
||||
|
@ -60,18 +58,15 @@ class LIBPARTITIONMANAGERPRIVATE_EXPORT ExternalCommand : public QProcess
|
|||
QStringList args() { return m_Args; } /**< @return the arguments */
|
||||
|
||||
protected:
|
||||
void setExitCode(int i) { m_ExitCode = i; }
|
||||
void setup();
|
||||
|
||||
protected slots:
|
||||
void onFinished(int exitCode);
|
||||
void onReadOutput();
|
||||
|
||||
private:
|
||||
Report *m_Report;
|
||||
QString m_Command;
|
||||
QStringList m_Args;
|
||||
int m_ExitCode;
|
||||
QString m_Output;
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue