From 14b714b0042fa376b321d5ef3cb996f10c3fbc3e Mon Sep 17 00:00:00 2001 From: Pino Toscano Date: Fri, 2 Sep 2005 18:46:34 +0000 Subject: [PATCH] A nice thing and a bad thing. Good: I've moved the tests under a tests subdir, a.l.a. kdelibs. To compile them: $ cd tests $ unsermake check In this way, less code is compiled and installed as default Bad: I've commented with #if 0 a pair of constructors that don't compile here, and I don't know how to fix, sorry :( CCMAIL: kstars@30doradus.org svn path=/trunk/KDE/kdeedu/libkdeedu/; revision=456393 --- extdate/Makefile.am | 11 +---------- extdate/extdatetimeedit.cpp | 4 ++++ extdate/extdatetimeedit.h | 4 ++++ extdate/tests/Makefile.am | 12 ++++++++++++ extdate/{ => tests}/main.cpp | 0 extdate/{ => tests}/test_extdate.cc | 0 extdate/{ => tests}/testwidget.cpp | 0 extdate/{ => tests}/testwidget.h | 0 8 files changed, 21 insertions(+), 10 deletions(-) create mode 100644 extdate/tests/Makefile.am rename extdate/{ => tests}/main.cpp (100%) rename extdate/{ => tests}/test_extdate.cc (100%) rename extdate/{ => tests}/testwidget.cpp (100%) rename extdate/{ => tests}/testwidget.h (100%) diff --git a/extdate/Makefile.am b/extdate/Makefile.am index fa0b080..e2234d1 100644 --- a/extdate/Makefile.am +++ b/extdate/Makefile.am @@ -1,4 +1,4 @@ -bin_PROGRAMS = test_extdate test_extdatepicker +SUBDIRS = . tests INCLUDES= $(all_includes) @@ -9,13 +9,4 @@ libextdate_la_SOURCES = extdatetime.cpp extcalendarsystem.cpp extcalendarsystemg libextdate_la_LDFLAGS = $(all_libraries) -no-undefined -version-info 3:0:2 libextdate_la_LIBADD = $(LIB_KDEUI) -test_extdate_SOURCES = test_extdate.cc -test_extdate_LDADD = libextdate.la -test_extdate_LDFLAGS = $(all_libraries) $(KDE_RPATH) - -test_extdatepicker_SOURCES = testwidget.cpp main.cpp -test_extdatepicker_LDADD = libextdate.la -test_extdatepicker_LDFLAGS = $(all_libraries) $(KDE_RPATH) - METASOURCES = AUTO - diff --git a/extdate/extdatetimeedit.cpp b/extdate/extdatetimeedit.cpp index e625fd6..673a54c 100644 --- a/extdate/extdatetimeedit.cpp +++ b/extdate/extdatetimeedit.cpp @@ -34,9 +34,11 @@ ExtDateEdit::ExtDateEdit( const ExtDate &d, QWidget *parent ) m_DateFormat.replace( "y", "Y" ); } +#if 0 ExtDateEdit::ExtDateEdit( int jd, QWidget *parent ) { ExtDateEdit( ExtDate(jd), parent ); } +#endif ExtDateEdit::~ExtDateEdit() { } @@ -100,9 +102,11 @@ ExtDateTimeEdit::ExtDateTimeEdit( const ExtDateTime &dt, QWidget *parent ) hlay->addWidget( m_TimeEdit ); } +#if 0 ExtDateTimeEdit::ExtDateTimeEdit( const ExtDate &d, const QTime &t, QWidget *parent ) { ExtDateTimeEdit( ExtDateTime( d, t ), parent ); } +#endif ExtDateTimeEdit::~ExtDateTimeEdit() { } diff --git a/extdate/extdatetimeedit.h b/extdate/extdatetimeedit.h index 56e46f9..de94e7d 100644 --- a/extdate/extdatetimeedit.h +++ b/extdate/extdatetimeedit.h @@ -59,7 +59,9 @@ class ExtDateEdit : public QSpinBox { public: ExtDateEdit( const ExtDate &d = ExtDate::currentDate(), QWidget *parent = 0 ); +#if 0 ExtDateEdit( int jd, QWidget *parent = 0 ); +#endif ~ExtDateEdit(); void stepBy( int steps ); @@ -90,7 +92,9 @@ class ExtDateTimeEdit : public QWidget { public: ExtDateTimeEdit( const ExtDateTime &dt = ExtDateTime::currentDateTime(), QWidget *p=0 ); +#if 0 ExtDateTimeEdit( const ExtDate &d, const QTime &t, QWidget *p=0 ); +#endif ~ExtDateTimeEdit(); private: diff --git a/extdate/tests/Makefile.am b/extdate/tests/Makefile.am new file mode 100644 index 0000000..7a5163d --- /dev/null +++ b/extdate/tests/Makefile.am @@ -0,0 +1,12 @@ +INCLUDES = -I$(top_srcdir)/libkdeedu/extdate $(all_includes) + +LDADD = ../libextdate.la + +AM_LDFLAGS = $(QT_LDFLAGS) $(X_LDFLAGS) $(KDE_RPATH) + +check_PROGRAMS = test_extdate test_extdatepicker + +test_extdate_SOURCES = test_extdate.cc +test_extdatepicker_SOURCES = testwidget.cpp main.cpp + +METASOURCES = AUTO diff --git a/extdate/main.cpp b/extdate/tests/main.cpp similarity index 100% rename from extdate/main.cpp rename to extdate/tests/main.cpp diff --git a/extdate/test_extdate.cc b/extdate/tests/test_extdate.cc similarity index 100% rename from extdate/test_extdate.cc rename to extdate/tests/test_extdate.cc diff --git a/extdate/testwidget.cpp b/extdate/tests/testwidget.cpp similarity index 100% rename from extdate/testwidget.cpp rename to extdate/tests/testwidget.cpp diff --git a/extdate/testwidget.h b/extdate/tests/testwidget.h similarity index 100% rename from extdate/testwidget.h rename to extdate/tests/testwidget.h -- 2.47.3