summaryrefslogtreecommitdiffstats
path: root/k9author/k9chapteredit.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-05-27 23:37:00 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-05-27 23:37:00 +0000
commitb0e912c8b3d02a518fedda28c3180eb4794a7520 (patch)
tree07d344862562fab58cbe2df39d13d16f2e4d2bea /k9author/k9chapteredit.cpp
parent4d695ec81fe4d4335ee82c7a9346ad9c9e144ecc (diff)
downloadk9copy-b0e912c8b3d02a518fedda28c3180eb4794a7520.tar.gz
k9copy-b0e912c8b3d02a518fedda28c3180eb4794a7520.zip
TQt4 convert k9copy
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/k9copy@1233843 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'k9author/k9chapteredit.cpp')
-rw-r--r--k9author/k9chapteredit.cpp48
1 files changed, 24 insertions, 24 deletions
diff --git a/k9author/k9chapteredit.cpp b/k9author/k9chapteredit.cpp
index e199477..ff22b8d 100644
--- a/k9author/k9chapteredit.cpp
+++ b/k9author/k9chapteredit.cpp
@@ -14,24 +14,24 @@
#include "k9chapteredit.h"
#include "k9drawimage.h"
#include <ktimewidget.h>
-#include <qlabel.h>
-#include <qpixmap.h>
-#include <qslider.h>
-#include <qlayout.h>
+#include <tqlabel.h>
+#include <tqpixmap.h>
+#include <tqslider.h>
+#include <tqlayout.h>
#include <kurlrequester.h>
-#include <qcheckbox.h>
+#include <tqcheckbox.h>
#include "k9title.h"
#include <kpushbutton.h>
#include <kiconloader.h>
-k9ChapterEdit::k9ChapterEdit(QWidget* parent, const char* name, WFlags fl)
-: chapterEdit(parent,name,fl)
+k9ChapterEdit::k9ChapterEdit(TQWidget* tqparent, const char* name, WFlags fl)
+: chapterEdit(tqparent,name,fl)
{
m_wimage=new k9DrawImage(image,0);
- QGridLayout *l=new QGridLayout(image,1,1);
+ TQGridLayout *l=new TQGridLayout(image,1,1);
l->addWidget(m_wimage,0,0);
- m_wimage->setPaletteBackgroundColor(Qt::black);
- connect(&m_aviDecode,SIGNAL(drawFrame(QImage*)),this,SLOT(drawImage(QImage*)));
+ m_wimage->setPaletteBackgroundColor(TQt::black);
+ connect(&m_aviDecode,TQT_SIGNAL(drawFrame(TQImage*)),this,TQT_SLOT(drawImage(TQImage*)));
bTitleButton->setIconSet (SmallIcon("frame_image"));
}
@@ -50,14 +50,14 @@ void k9ChapterEdit::sliderChanged() {
if (m_aviDecode.opened()) {
//m_aviDecode.seek((double)slider->value() / 100);
m_aviDecode.readFrame((double)slider->value() / 1000);
- QTime t;
+ TQTime t;
t=t.addMSecs((double)slider->value());
lPosition->setText(t.toString("hh:mm:ss"));
}
}
-void k9ChapterEdit::urlSelected(const QString& _fileName) {
+void k9ChapterEdit::urlSelected(const TQString& _fileName) {
m_aviDecode.open(_fileName);
if (!m_noUpdate) {
if (_fileName !=m_aviFile->getFileName()) {
@@ -69,7 +69,7 @@ void k9ChapterEdit::urlSelected(const QString& _fileName) {
m_aviFile->setFileName(_fileName);
}
- QTime t;
+ TQTime t;
int sec=t.msecsTo(m_aviFile->getStart());
slider->setMaxValue((int)(m_aviDecode.getDuration()*1000));
@@ -77,22 +77,22 @@ void k9ChapterEdit::urlSelected(const QString& _fileName) {
}
-void k9ChapterEdit::drawImage(QImage * _image) {
- //QPixmap p(*_image);
+void k9ChapterEdit::drawImage(TQImage * _image) {
+ //TQPixmap p(*_image);
//image->setPixmap(p);
m_wimage->setImage(*_image);
m_image=*_image;
}
void k9ChapterEdit::bStartClick() {
- QTime t;
+ TQTime t;
int secs=slider->value()/1000;
t=t.addSecs(secs);
twstart->setTime(t);
}
void k9ChapterEdit::bEndClick() {
- QTime t;
+ TQTime t;
int secs=slider->value()/1000;
t=t.addSecs(secs);
twend->setTime(t);
@@ -138,9 +138,9 @@ void k9ChapterEdit::setAviFile(k9AviFile *_aviFile) {
}
-void k9ChapterEdit::startChanged(const QTime& _time) {
+void k9ChapterEdit::startChanged(const TQTime& _time) {
if (!m_noUpdate) {
- QTime t=_time;
+ TQTime t=_time;
if (t > m_maxTime )
t=m_maxTime;
else if (t < m_minTime)
@@ -153,15 +153,15 @@ void k9ChapterEdit::startChanged(const QTime& _time) {
if (!m_aviFile->getBreakPrevious() && m_aviFile->getPrevious()!=NULL) {
m_aviFile->getPrevious()->setEnd(t);
}
- QTime t2;
+ TQTime t2;
slider->setValue(t2.msecsTo(t));
m_aviFile->setImage(m_image);
}
}
-void k9ChapterEdit::endChanged(const QTime& _time) {
+void k9ChapterEdit::endChanged(const TQTime& _time) {
if (!m_noUpdate) {
- QTime t=_time;
+ TQTime t=_time;
if (t > m_maxTime )
t=m_maxTime;
else if (t < m_minTime)
@@ -171,9 +171,9 @@ void k9ChapterEdit::endChanged(const QTime& _time) {
if (t!=_time)
twend->setTime(t);
m_aviFile->setEnd(t);
- QTime t2;
+ TQTime t2;
if (!m_aviFile->getBreakNext() && m_aviFile->getNext()!=NULL) {
- QImage i=m_image;
+ TQImage i=m_image;
m_aviDecode.readFrame((double)t2.msecsTo(t)/1000.0);
m_aviFile->getNext()->setImage(m_image);
m_image=i;