есть реализация класса *.cpp
#include <QtGui>
#include "gotocelldialog.h"
#include <unistd.h>
GoToCellDialog::GoToCellDialog(QWidget *parent)
:QDialog(parent)
{
setupUi(this);
QRegExp regExp("[/~][0-9A-Za-z/.]{5,}");
lineEdit->setValidator(new QRegExpValidator(regExp, this));
connect(okButton, SIGNAL(clicked()), this, SLOT(accept()));
connect(okButton, SIGNAL(clicked()), this, SLOT(startMencoder()));
connect(cancelButton, SIGNAL(clicked()), this, SLOT(reject()));
}
void GoToCellDialog ::on_lineEdit_textChanged()
{
okButton->setEnabled(lineEdit->hasAcceptableInput());
}
void GoToCellDialog ::startMencoder()
{
int result;
char param1[]="/home/saibogo/programs/test/test1.avi";
result=execlp("/home/saibogo/scripts/mencoderscript.sh","mencoderscript.sh",(li neEdit->text()),param1,NULL);
//result=execlp("/usr/bin/mencoder","mencoder","-ofps 22 -vf-add scale=320:240 -vf-add expand=320:240:-1:-1:1 -srate 44100 -ovc xvid -xvidencopts bitrate=500:max_bframes=0:quant_type=h263:me_quality=4 -oac lavc -lavcopts acodec=mp2:abitrate=128",argv[1],"-o",argv[2],NULL);
}
есть собственно сам класс *.h
#include <QtGui>
#include "gotocelldialog.h"
#include <unistd.h>
GoToCellDialog::GoToCellDialog(QWidget *parent)
:QDialog(parent)
{
setupUi(this);
QRegExp regExp("[/~][0-9A-Za-z/.]{5,}");
lineEdit->setValidator(new QRegExpValidator(regExp, this));
connect(okButton, SIGNAL(clicked()), this, SLOT(accept()));
connect(okButton, SIGNAL(clicked()), this, SLOT(startMencoder()));
connect(cancelButton, SIGNAL(clicked()), this, SLOT(reject()));
}
void GoToCellDialog ::on_lineEdit_textChanged()
{
okButton->setEnabled(lineEdit->hasAcceptableInput());
}
void GoToCellDialog ::startMencoder()
{
int result;
char param1[]="/home/saibogo/programs/test/test1.avi";
result=execlp("/home/saibogo/scripts/mencoderscript.sh","mencoderscript.sh",(li neEdit->text()),param1,NULL);
//result=execlp("/usr/bin/mencoder","mencoder","-ofps 22 -vf-add scale=320:240 -vf-add expand=320:240:-1:-1:1 -srate 44100 -ovc xvid -xvidencopts bitrate=500:max_bframes=0:quant_type=h263:me_quality=4 -oac lavc -lavcopts acodec=mp2:abitrate=128",argv[1],"-o",argv[2],NULL);
}
подскажите как правильно передать значение поля ввода lineEdit в слот-функцию startMencoder()? Заранее спасибо