Remove use of KDE_IS_VERSION

Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
(cherry picked from commit 8927ed0007)
r14.1.x
Michele Calgaro 3 weeks ago
parent 49cb4c367e
commit 3ee759a4be
Signed by: MicheleC
GPG Key ID: 2A75B7CA8ADED5CF

@ -85,21 +85,15 @@ void DBFlagsEditor::slotOk()
TQDateTime ttime;
ttime.setDate(widget->fCreationDate->date());
#if KDE_IS_VERSION(3,1,9)
ttime.setTime(widget->fCreationTime->time());
#endif
dbi->createDate=ttime.toTime_t();
ttime.setDate(widget->fModificationDate->date());
#if KDE_IS_VERSION(3,1,9)
ttime.setTime(widget->fModificationTime->time());
#endif
dbi->modifyDate=ttime.toTime_t();
ttime.setDate(widget->fBackupDate->date());
#if KDE_IS_VERSION(3,1,9)
ttime.setTime(widget->fBackupTime->time());
#endif
dbi->backupDate=ttime.toTime_t();
KDialogBase::slotOk();
@ -136,21 +130,15 @@ void DBFlagsEditor::fillWidgets()
TQDateTime ttime;
ttime.setTime_t(dbi->createDate);
widget->fCreationDate->setDate(ttime.date());
#if KDE_IS_VERSION(3,1,9)
widget->fCreationTime->setTime(ttime.time());
#endif
ttime.setTime_t(dbi->modifyDate);
widget->fModificationDate->setDate(ttime.date());
#if KDE_IS_VERSION(3,1,9)
widget->fModificationTime->setTime(ttime.time());
#endif
ttime.setTime_t(dbi->backupDate);
widget->fBackupDate->setDate(ttime.date());
#if KDE_IS_VERSION(3,1,9)
widget->fBackupTime->setTime(ttime.time());
#endif
}

@ -371,6 +371,7 @@
<includes>
<include location="local" impldecl="in implementation">dbFlagsEditor_base.ui.h</include>
<include location="system" impldecl="in implementation">kdatewidget.h</include>
<include location="system" impldecl="in implementation">ktimewidget.h</include>
</includes>
<layoutdefaults spacing="6" margin="11"/>
</UI>

@ -1,24 +0,0 @@
/****************************************************************************
** ui.h extension file, included from the uic-generated form implementation.
**
** If you wish to add, delete or rename functions or slots use
** TQt Designer which will update this file, preserving your code. Create an
** init() function in place of a constructor, and a destroy() function in
** place of a destructor.
*****************************************************************************/
#ifndef TDE_VERSION
#include <tdeversion.h>
#endif
#if KDE_IS_VERSION(3,1,90)
#include <ktimewidget.h>
#else
#warning "Workaround for KTimeWidget in KDE 3.1"
class KTimeWidget : public TQWidget
{
public:
KTimeWidget(TQWidget *p, const char *n) : TQWidget(p,n) {};
} ;
#endif

@ -119,11 +119,7 @@ void FileInstaller::deleteFiles(const TQStringList &files)
srcName.setPath(s);
KURL destDir(fDirName + CSL1("/") + srcName.fileName());
#if KDE_IS_VERSION(3,1,9)
return TDEIO::NetAccess::copy(srcName, destDir, w);
#else
return TDEIO::NetAccess::copy(srcName,destDir);
#endif
}

@ -119,12 +119,6 @@ LogWidget::LogWidget(TQWidget * parent) :
initialText.append(i18n("<qt><b>HotSync Log</b></qt>"));
initialText.append(CSL1(TE_EOL));
#if KDE_IS_VERSION(3,3,0)
#else
initialText.append(CSL1(TE_EOL "<qt><b>KDE 3.2 is no longer supported. Please update to KDE 3.3 or later.</b></qt>" TE_EOL));
initialText.append(CSL1(TE_EOL "<qt><b>You may be unable to do conflict resolution.</b></qt>" TE_EOL));
#endif
fLog->setText(initialText);
fLog->scrollToBottom();

@ -44,14 +44,6 @@
#include <tdeversion.h>
#include <tdelocale.h>
#if !(KDE_IS_VERSION(3,4,0))
#error "This is KPilot for (really) KDE 3.5 and won't compile with KDE < 3.4.0"
#endif
#if !(KDE_IS_VERSION(3,5,0))
#warning "This is KPilot for KDE 3.5 and might not compile with KDE < 3.5.0"
#endif
#include "pilotLinkVersion.h"
#include <iostream>

@ -327,7 +327,6 @@ int SyncAction::questionYesNo(const TQString & text,
startTickle(timeout);
}
#if KDE_IS_VERSION(3,3,0)
r = (KMessageBox::ButtonCode) KMessageBox::createKMessageBox(dialog,
TQMessageBox::Question,
text,
@ -336,50 +335,6 @@ int SyncAction::questionYesNo(const TQString & text,
&checkboxReturn,
0);
#else
// The following code is taken from KDialogBase.cpp,
// part of the KDE 2.2 libraries. Copyright 2001
// by Waldo Bastian.
//
//
TQVBox *topcontents = new TQVBox(dialog);
topcontents->setSpacing(KDialog::spacingHint() * 2);
topcontents->setMargin(KDialog::marginHint() * 2);
TQWidget *contents = new TQWidget(topcontents);
TQHBoxLayout *lay = new TQHBoxLayout(contents);
lay->setSpacing(KDialog::spacingHint() * 2);
lay->addStretch(1);
TQLabel *label1 = new TQLabel( contents);
label1->setPixmap(TQMessageBox::standardIcon(TQMessageBox::Information));
lay->add( label1 );
TQLabel *label2 = new TQLabel( text, contents);
label2->setMinimumSize(label2->sizeHint());
lay->add(label2);
lay->addStretch(1);
TQSize extraSize = TQSize(50, 30);
TQCheckBox *checkbox = 0L;
if (!key.isEmpty())
{
checkbox = new TQCheckBox(i18n("Do not ask again"),topcontents);
extraSize = TQSize(50,0);
}
dialog->setMainWidget(topcontents);
dialog->enableButtonSeparator(false);
dialog->incInitialSize(extraSize);
r = dialog->exec();
if (checkbox)
{
checkboxReturn = checkbox->isChecked();
}
#endif
switch(r)
{
@ -440,7 +395,6 @@ int SyncAction::questionYesNoCancel(const TQString & text,
startTickle(timeout);
}
#if KDE_IS_VERSION(3,3,0)
r = KMessageBox::createKMessageBox(dialog,
TQMessageBox::Question,
text,
@ -448,50 +402,6 @@ int SyncAction::questionYesNoCancel(const TQString & text,
(key.isEmpty() ? TQString() : i18n("&Do not ask again")),
&checkboxReturn,
0);
#else
// The following code is taken from KDialogBase.cpp,
// part of the KDE 2.2 libraries. Copyright 2001
// by Waldo Bastian.
//
//
TQVBox *topcontents = new TQVBox(dialog);
topcontents->setSpacing(KDialog::spacingHint() * 2);
topcontents->setMargin(KDialog::marginHint() * 2);
TQWidget *contents = new TQWidget(topcontents);
TQHBoxLayout *lay = new TQHBoxLayout(contents);
lay->setSpacing(KDialog::spacingHint() * 2);
lay->addStretch(1);
TQLabel *label1 = new TQLabel( contents);
label1->setPixmap(TQMessageBox::standardIcon(TQMessageBox::Information));
lay->add( label1 );
TQLabel *label2 = new TQLabel( text, contents);
label2->setMinimumSize(label2->sizeHint());
lay->add(label2);
lay->addStretch(1);
TQSize extraSize = TQSize(50, 30);
TQCheckBox *checkbox = 0L;
if (!key.isEmpty())
{
checkbox = new TQCheckBox(i18n("Do not ask again"),topcontents);
extraSize = TQSize(50,0);
}
dialog->setMainWidget(topcontents);
dialog->enableButtonSeparator(false);
dialog->incInitialSize(extraSize);
r = dialog->exec();
if (checkbox)
{
checkboxReturn = checkbox->isChecked();
}
#endif
switch(r)
{

Loading…
Cancel
Save