[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-core-devel
Subject: kolibs: complation fixes for msvc
From: "Jaroslaw Staniek" <kexipl () gmail ! com>
Date: 2007-07-06 20:15:12
Message-ID: 56a746380707061315jf63facbt7b7eb424973624cd () mail ! gmail ! com
[Download RAW message or body]
Hello,
complation fixes for msvc (for reviewing and commiting)
tested: compiles on msvc and gcc
--
regards / pozdrawiam, Jaroslaw Staniek
Sponsored by OpenOffice Polska (http://www.openoffice.com.pl/en) to work on
Kexi & KOffice: http://www.kexi-project.org, http://www.koffice.org
KDE3 & KDE4 Libraries for MS Windows: http://kdelibs.com, http://www.kde.org
["libs.patch" (text/x-patch)]
Index: libs/flake/KoShapeGroup.cpp
===================================================================
--- libs/flake/KoShapeGroup.cpp (revision 684521)
+++ libs/flake/KoShapeGroup.cpp (working copy)
@@ -23,6 +23,8 @@
#include "KoShapeSavingContext.h"
#include "KoXmlWriter.h"
+#include <QPainter>
+
KoShapeGroup::KoShapeGroup()
: KoShapeContainer(new SimpleShapeContainerModel())
{
Index: libs/flake/KoPathPoint.cpp
===================================================================
--- libs/flake/KoPathPoint.cpp (revision 684521)
+++ libs/flake/KoPathPoint.cpp (working copy)
@@ -112,7 +112,7 @@
void KoPathPoint::setProperties( KoPointProperties properties )
{
- if( properties & HasControlPoint1 == 0 || properties & HasControlPoint2 == 0 )
+ if( (properties & HasControlPoint1) == 0 || (properties & HasControlPoint2) == 0 \
) {
// strip smooth and symmetric flags if points has not two control points
properties &= ~IsSmooth;
@@ -138,7 +138,7 @@
return;
break;
case HasControlPoint1:
- if( d->properties & CanHaveControlPoint1 == 0 )
+ if( (d->properties & CanHaveControlPoint1) == 0 )
return;
break;
case CanHaveControlPoint2:
@@ -146,16 +146,16 @@
return;
break;
case HasControlPoint2:
- if( d->properties & CanHaveControlPoint2 == 0 )
+ if( (d->properties & CanHaveControlPoint2) == 0 )
return;
break;
case IsSmooth:
- if( d->properties & HasControlPoint1 == 0 && d->properties & \
HasControlPoint2 == 0 ) + if( (d->properties & HasControlPoint1) == 0 && \
(d->properties & HasControlPoint2) == 0 ) return;
d->properties &= ~IsSymmetric;
break;
case IsSymmetric:
- if( d->properties & HasControlPoint1 == 0 && d->properties & \
HasControlPoint2 == 0 ) + if( (d->properties & HasControlPoint1) == 0 && \
(d->properties & HasControlPoint2) == 0 ) return;
d->properties &= ~IsSmooth;
break;
Index: libs/flake/flake_export.h
===================================================================
--- libs/flake/flake_export.h (revision 684521)
+++ libs/flake/flake_export.h (working copy)
@@ -23,40 +23,16 @@
/* needed for KDE_EXPORT and KDE_IMPORT macros */
#include <kdemacros.h>
-/* We use _WIN32/_WIN64 instead of Q_OS_WIN so that this header can be used from C \
files too */
-#if defined _WIN32 || defined _WIN64
-
#ifndef FLAKE_EXPORT
# if defined(MAKE_FLAKE_LIB)
/* We are building this library */
# define FLAKE_EXPORT KDE_EXPORT
+# define FLAKE_TEST_EXPORT KDE_EXPORT
# else
/* We are using this library */
# define FLAKE_EXPORT KDE_IMPORT
+# define FLAKE_TEST_EXPORT KDE_IMPORT
# endif
#endif
-#else /* UNIX */
-
-#define FLAKE_EXPORT KDE_EXPORT
-
#endif
-
-/* Now the same for FLAKE_TEST_EXPORT, if compiling with unit tests enabled */
-
-#ifdef COMPILING_TESTS
-#if defined _WIN32 || defined _WIN64
-# if defined( MAKE_FLAKE_LIB )
-# define FLAKE_TEST_EXPORT KDE_EXPORT
-# else
-# define FLAKE_TEST_EXPORT KDE_IMPORT
-# endif
-# else /* not windows */
-# define FLAKE_TEST_EXPORT KDE_EXPORT
-# endif
-#else /* not compiling tests */
-# define FLAKE_TEST_EXPORT
-#endif
-
-
-#endif
Index: libs/flake/KoShapeRegistry.h
===================================================================
--- libs/flake/KoShapeRegistry.h (revision 684521)
+++ libs/flake/KoShapeRegistry.h (working copy)
@@ -25,11 +25,11 @@
#include <KoGenericRegistry.h>
#include <KoXmlReader.h>
+#include <KoShapeFactory.h>
#include <flake_export.h>
class KoShape;
-class KoShapeFactory;
class KoShapeLoadingContext;
Index: libs/flake/KoLineBorder.cpp
===================================================================
--- libs/flake/KoLineBorder.cpp (revision 684521)
+++ libs/flake/KoLineBorder.cpp (working copy)
@@ -22,6 +22,7 @@
#include "KoLineBorder.h"
#include "KoViewConverter.h"
#include "KoShape.h"
+#include "KoShapeSavingContext.h"
#include <QPainterPath>
Index: libs/flake/KoPathTool.cpp
===================================================================
--- libs/flake/KoPathTool.cpp (revision 684521)
+++ libs/flake/KoPathTool.cpp (working copy)
@@ -385,7 +385,7 @@
{
if( event->button() & Qt::LeftButton )
{
- if( event->modifiers() & Qt::ControlModifier == 0 )
+ if( (event->modifiers() & Qt::ControlModifier) == 0 )
{
m_pointSelection.clear();
}
Index: libs/flake/KoInteractionStrategy.h
===================================================================
--- libs/flake/KoInteractionStrategy.h (revision 684521)
+++ libs/flake/KoInteractionStrategy.h (working copy)
@@ -23,10 +23,10 @@
#define KOINTERACTIONSTRATEGY_H
#include <QList>
+#include <QPainter>
#include <KoSelection.h>
-class QPainter;
class KoPointerEvent;
class QUndoCommand;
class KoCanvasBase;
Index: libs/flake/KoShape.cpp
===================================================================
--- libs/flake/KoShape.cpp (revision 684521)
+++ libs/flake/KoShape.cpp (working copy)
@@ -445,10 +445,10 @@
// check if the matrix has shearing mixed in
if( fabs( fabs(d->localMatrix.m12()) - fabs(d->localMatrix.m21()) ) > 1e-10 )
- return nan("");
+ return NAN;
// check if the matrix has scaling mixed in
if( fabs( d->localMatrix.m11() - d->localMatrix.m22() ) > 1e-10 )
- return nan("");
+ return NAN;
// calculate the angle from the matrix elements
double angle = atan2( d->localMatrix.m21(), d->localMatrix.m11() ) * 180.0 / \
M_PI;
Index: libs/main/KoFileDialog.cpp
===================================================================
--- libs/main/KoFileDialog.cpp (revision 684521)
+++ libs/main/KoFileDialog.cpp (working copy)
@@ -81,7 +81,8 @@
}
// Insert numSpecialEntries entries with native mimetypes, for the special \
entries.
- for ( int i=0; i<numSpecialEntries; ++i )
+ int i=0;
+ for ( ; i<numSpecialEntries; ++i )
mimeFilter.insert( 1, nativeFormat );
// Fill in filter combo
@@ -111,18 +112,18 @@
slotChangedfilter( filterWidget()->currentIndex() );
}
// [Mainly KWord] Tell MS Office users that they can save in RTF!
- int i = 0;
+ i = 0;
QString tmpString;
QString compatString;
foreach( tmpString, mimeFilter )
{
KMimeType::Ptr mime = KMimeType::mimeType( tmpString );
- if ( ! mime )
+ if ( ! mime )
mime = KMimeType::defaultMimeTypePtr();
compatString = mime->property ("X-KDE-CompatibleApplication").toString ();
if (!compatString.isEmpty ())
filterWidget()->setItemText( i, i18n ("%1 (%2 Compatible)", \
mime->comment (), compatString) );
- i++;
+ i++;
}
}
Index: libs/main/KoRTree.h
===================================================================
--- libs/main/KoRTree.h (revision 684521)
+++ libs/main/KoRTree.h (working copy)
@@ -40,7 +40,7 @@
* This class implements a R-tree as described in
* "R-TREES. A DYNAMIC INDEX STRUCTURE FOR SPATIAL SEARCHING" by Antomn Guttman
*
- * It only supports 2 dimentional bounding boxes which are repesented by a QRectF.
+ * It only supports 2 dimensional bounding boxes which are repesented by a QRectF.
* For node splitting the Quadratic-Cost Algorithm is used as descibed by Guttman.
*/
template <typename T>
@@ -480,7 +480,7 @@
#endif
template <typename T>
-QPair< typename KoRTree<T>::Node*, typename KoRTree<T>::Node* > \
KoRTree<T>::splitNode( KoRTree<T>::Node* node ) +QPair< typename KoRTree<T>::Node*, \
typename KoRTree<T>::Node* > KoRTree<T>::splitNode( typename KoRTree<T>::Node* node ) \
{ //qDebug() << "KoRTree::splitNode" << node;
Node * n1;
Index: libs/main/threadAction/KoJobsListPolicy.cpp
===================================================================
--- libs/main/threadAction/KoJobsListPolicy.cpp (revision 684521)
+++ libs/main/threadAction/KoJobsListPolicy.cpp (working copy)
@@ -17,7 +17,7 @@
* Boston, MA 02110-1301, USA.
*/
#include "KoJobsListPolicy.h"
-#include <Job.h>
+#include <threadweaver/Job.h>
using namespace ThreadWeaver;
Index: libs/main/threadAction/KoAction.cpp
===================================================================
--- libs/main/threadAction/KoAction.cpp (revision 684521)
+++ libs/main/threadAction/KoAction.cpp (working copy)
@@ -21,7 +21,7 @@
#include "KoExecutePolicy.h"
#include "ActionJob_p.h"
-#include <WeaverInterface.h>
+#include <threadweaver/WeaverInterface.h>
class KoAction::Private {
public:
Index: libs/main/threadAction/KoJobsListPolicy.h
===================================================================
--- libs/main/threadAction/KoJobsListPolicy.h (revision 684521)
+++ libs/main/threadAction/KoJobsListPolicy.h (working copy)
@@ -18,7 +18,7 @@
*/
#ifndef TW_JOBSLISTPOLICY_H
#define TW_JOBSLISTPOLICY_H
-#include <QueuePolicy.h>
+#include <threadweaver/QueuePolicy.h>
#include <QMutex>
#include <QList>
Index: libs/main/threadAction/ActionJob_p.h
===================================================================
--- libs/main/threadAction/ActionJob_p.h (revision 684521)
+++ libs/main/threadAction/ActionJob_p.h (working copy)
@@ -1,3 +1,4 @@
+
/*
* Copyright (C) 2006-2007 Thomas Zander <zander@kde.org>
*
@@ -18,7 +19,7 @@
*/
#ifndef TW_ACTIONJOB_H
#define TW_ACTIONJOB_H
-#include <Job.h>
+#include <threadweaver/Job.h>
#include <QSemaphore>
#include <QVariant>
Index: libs/main/threadAction/KoAction.h
===================================================================
--- libs/main/threadAction/KoAction.h (revision 684521)
+++ libs/main/threadAction/KoAction.h (working copy)
@@ -19,7 +19,7 @@
#ifndef KO_ACTION_H
#define KO_ACTION_H
-#include <ThreadWeaver.h>
+#include <threadweaver/ThreadWeaver.h>
#include "kofficecore_export.h"
Index: libs/main/threadAction/KoExecutePolicy.cpp
===================================================================
--- libs/main/threadAction/KoExecutePolicy.cpp (revision 684521)
+++ libs/main/threadAction/KoExecutePolicy.cpp (working copy)
@@ -23,7 +23,7 @@
#include "ActionJob_p.h"
#include "KoJobsListPolicy.h"
-#include <WeaverInterface.h>
+#include <threadweaver/WeaverInterface.h>
#include <KDebug>
using namespace ThreadWeaver;
Index: libs/main/KoDocument.cpp
===================================================================
--- libs/main/KoDocument.cpp (revision 684521)
+++ libs/main/KoDocument.cpp (working copy)
@@ -2868,7 +2868,7 @@
d->m_startUpWidget = 0;
}
-QWidget* KoDocument::createCustomDocumentWidget(QWidget */*parent*/) {
+QWidget* KoDocument::createCustomDocumentWidget(QWidget * /*parent*/) {
return 0;
}
Index: libs/main/KoFilterManager.h
===================================================================
--- libs/main/KoFilterManager.h (revision 684521)
+++ libs/main/KoFilterManager.h (working copy)
@@ -102,7 +102,7 @@
* information here.
* Optionally, @p extraNativeMimeTypes are added after the native mimetype.
*/
- KOMAIN_EXPORT static QStringList mimeFilter( const QByteArray& mimetype, \
Direction direction, + static QStringList mimeFilter( const QByteArray& mimetype, \
Direction direction,
const QStringList& \
extraNativeMimeTypes = QStringList() );
/**
Index: libs/main/tests/priorityqueue_test.cpp
===================================================================
--- libs/main/tests/priorityqueue_test.cpp (revision 684521)
+++ libs/main/tests/priorityqueue_test.cpp (working copy)
@@ -41,7 +41,7 @@
"six", "seven", "eight", "nine", "ten",
"eleven", "twelve", 0 };
-int main( int /*argc*/, char **/*argv*/ )
+int main( int /*argc*/, char ** /*argv*/ )
{
Q3PtrList<Node> list;
list.setAutoDelete( true );
Index: libs/main/kofficecore_export.h
===================================================================
--- libs/main/kofficecore_export.h (revision 684521)
+++ libs/main/kofficecore_export.h (working copy)
@@ -23,9 +23,6 @@
/* needed for KDE_EXPORT and KDE_IMPORT macros */
#include <kdemacros.h>
-/* We use _WIN32/_WIN64 instead of Q_OS_WIN so that this header can be used from C \
files too */
-#if defined _WIN32 || defined _WIN64
-
#ifndef KOMAIN_EXPORT
# if defined(MAKE_KOMAIN_LIB)
/* We are building this library */
@@ -36,10 +33,4 @@
# endif
#endif
-#else /* UNIX */
-
-#define KOMAIN_EXPORT KDE_EXPORT
-
#endif
-
-#endif
Index: libs/main/KoUnit.cpp
===================================================================
--- libs/main/KoUnit.cpp (revision 684521)
+++ libs/main/KoUnit.cpp (working copy)
@@ -43,7 +43,7 @@
uint KoUnit::indexInList(bool hidePixel)
{
- if(hidePixel and m_unit > Pixel)
+ if(hidePixel && m_unit > Pixel)
return m_unit-1;
else
return m_unit;
Index: libs/main/KoPicture.h
===================================================================
--- libs/main/KoPicture.h (revision 684521)
+++ libs/main/KoPicture.h (working copy)
@@ -63,6 +63,14 @@
*/
KoPicture& operator=(const KoPicture& other);
+ /**
+ * Comparison operator
+ */
+ bool operator==(const KoPicture& other) const { return m_key==other.m_key; }
+
+ /**
+ * Returns type of the picture.
+ */
KoPictureType::Type getType(void) const;
/**
Index: libs/main/KoGenericRegistry.h
===================================================================
--- libs/main/KoGenericRegistry.h (revision 684521)
+++ libs/main/KoGenericRegistry.h (working copy)
@@ -119,8 +119,10 @@
QList<KoID> listKeys() const
{
QList<KoID> answer;
- foreach(QString key, m_hash.keys())
- answer.append(KoID(key, value(key)->name()));
+ QList<QString> keys(m_hash.keys());
+ // we do not use foreach() here because of GCC 3.3.x bug
+ for (QList<QString>::const_iterator it(keys.constBegin()); \
it!=keys.constEnd(); ++it) + answer.append(KoID(*it, value(*it)->name()));
return answer;
}
Index: libs/main/KoDockFactory.h
===================================================================
--- libs/main/KoDockFactory.h (revision 684521)
+++ libs/main/KoDockFactory.h (working copy)
@@ -38,6 +38,10 @@
/// @return the id of the dock widget
virtual QString id() const = 0;
+ /// @return the name the dock widget (actually a null string);
+ /// needed only when used with KoGenericRegistry.
+ QString name() const { return QString(); }
+
/// @return the dock widget area the widget should appear in by default
virtual Qt::DockWidgetArea defaultDockWidgetArea() const = 0;
Index: libs/pigment/KoLcmsColorSpace.h
===================================================================
--- libs/pigment/KoLcmsColorSpace.h (revision 684521)
+++ libs/pigment/KoLcmsColorSpace.h (working copy)
@@ -219,7 +219,7 @@
virtual bool profileIsCompatible(KoColorProfile* profile) const
{
KoLcmsColorProfile* p = dynamic_cast<KoLcmsColorProfile*>(profile);
- return (p and p->colorSpaceSignature() == colorSpaceSignature());
+ return (p && p->colorSpaceSignature() == colorSpaceSignature());
}
virtual void fromQColor(const QColor& color, quint8 *dst, KoColorProfile * \
koprofile=0) const @@ -647,7 +647,7 @@
virtual bool profileIsCompatible(KoColorProfile* profile) const
{
KoLcmsColorProfile* p = dynamic_cast<KoLcmsColorProfile*>(profile);
- return p and p->colorSpaceSignature() == colorSpaceSignature();
+ return p && p->colorSpaceSignature() == colorSpaceSignature();
}
};
Index: libs/pigment/KoColorSpaceRegistry.cpp
===================================================================
--- libs/pigment/KoColorSpaceRegistry.cpp (revision 684521)
+++ libs/pigment/KoColorSpaceRegistry.cpp (working copy)
@@ -225,7 +225,7 @@
}
KoColorProfile *p = profileByName(profileName);
- if(not p and not profileName.isEmpty())
+ if(!p && !profileName.isEmpty())
{
kDebug() << "Profile not found : " << profileName << endl;
return 0;
Index: libs/pigment/KoColorSpace.h
===================================================================
--- libs/pigment/KoColorSpace.h (revision 684521)
+++ libs/pigment/KoColorSpace.h (working copy)
@@ -612,7 +612,7 @@
*/
QVector<quint8> * threadLocalConversionCache(quint32 size) const;
- class Private;
+ struct Private;
Private * const d;
};
Index: libs/pigment/KoColorSpaceRegistry.h
===================================================================
--- libs/pigment/KoColorSpaceRegistry.h (revision 684521)
+++ libs/pigment/KoColorSpaceRegistry.h (working copy)
@@ -171,7 +171,7 @@
void init();
private:
- class Private;
+ struct Private;
Private * const d;
};
Index: libs/pigment/colorspaces/KoAlphaColorSpace.cpp
===================================================================
--- libs/pigment/colorspaces/KoAlphaColorSpace.cpp (revision 684521)
+++ libs/pigment/colorspaces/KoAlphaColorSpace.cpp (working copy)
@@ -295,7 +295,7 @@
*alpha = *pixel;
}
-void KoAlphaColorSpace::toQColor(const quint8 */*src*/, QColor *c, KoColorProfile * \
/*profile*/) const +void KoAlphaColorSpace::toQColor(const quint8 * /*src*/, QColor \
*c, KoColorProfile * /*profile*/) const {
c->setRgb(255, 255, 255);
}
Index: libs/kwmf/qwmf.cc
===================================================================
--- libs/kwmf/qwmf.cc (revision 684521)
+++ libs/kwmf/qwmf.cc (working copy)
@@ -752,7 +752,7 @@
else
ptStr = (char*)&parm[ 4 ];
- Q3CString text( ptStr, parm[ 2 ] + 1 );
+ QByteArray text( ptStr, parm[ 2 ] + 1 );
QFontMetrics fm( mPainter.font() );
width = fm.width( text ) + fm.descent(); // because fm.width(text) isn't rigth \
with Italic text @@ -1141,8 +1141,8 @@
{
float aStart, aLength;
- aStart = atan2( yStart, xStart );
- aLength = atan2( yEnd, xEnd ) - aStart;
+ aStart = atan2( (double)yStart, (double)xStart );
+ aLength = atan2( (double)yEnd, (double)xEnd ) - aStart;
angleStart = (int)(aStart * 2880 / 3.14166);
angleLength = (int)(aLength * 2880 / 3.14166);
Index: libs/kwmf/kowmfreadprivate.cc
===================================================================
--- libs/kwmf/kowmfreadprivate.cc (revision 684521)
+++ libs/kwmf/kowmfreadprivate.cc (working copy)
@@ -1183,8 +1183,8 @@
{
double aStart, aLength;
- aStart = atan2( yStart, xStart );
- aLength = atan2( yEnd, xEnd ) - aStart;
+ aStart = atan2( (double)yStart, (double)xStart );
+ aLength = atan2( (double)yEnd, (double)xEnd ) - aStart;
angleStart = (int)((aStart * 2880) / 3.14166);
angleLength = (int)((aLength * 2880) / 3.14166);
Index: libs/guiutils/KoCharSelectDia.h
===================================================================
--- libs/guiutils/KoCharSelectDia.h (revision 684521)
+++ libs/guiutils/KoCharSelectDia.h (working copy)
@@ -49,7 +49,7 @@
* @param character will be filled when the user pressed Ok with the selected \
character.
* @param parent the parent widget this dialog will be associated with.
*/
- KOGUIUTILS_EXPORT static bool selectChar( QString &font, QChar &character, \
QWidget* parent = 0, const char* name = 0); + static bool selectChar( QString \
&font, QChar &character, QWidget* parent = 0, const char* name = 0);
signals:
/**
Index: libs/guiutils/KoTemplateChooseDia.h
===================================================================
--- libs/guiutils/KoTemplateChooseDia.h (revision 684521)
+++ libs/guiutils/KoTemplateChooseDia.h (working copy)
@@ -63,7 +63,7 @@
: QListWidgetItem ( parent )
{}
- explicit KoTCDIconViewItem(QListWidget *parent=0, const QString &text=0, const \
QPixmap &icon=0, + explicit KoTCDIconViewItem(QListWidget *parent, const QString \
&text=0, const QPixmap &icon=0, const QString &descr=0, const QString &fullname=0)
: QListWidgetItem(text, parent)
{
@@ -78,7 +78,6 @@
private :
QString m_descr;
QString m_full;
-
};
class KoTemplateChooseDiaPrivate;
Index: libs/guiutils/KoResourceChooser.h
===================================================================
--- libs/guiutils/KoResourceChooser.h (revision 684521)
+++ libs/guiutils/KoResourceChooser.h (working copy)
@@ -74,7 +74,7 @@
virtual bool viewportEvent(QEvent * e);
private:
- class Private;
+ struct Private;
Private* const d;
};
Index: libs/guiutils/KoDualColorButton.h
===================================================================
--- libs/guiutils/KoDualColorButton.h (revision 684521)
+++ libs/guiutils/KoDualColorButton.h (working copy)
@@ -61,15 +61,6 @@
};
/**
- * Constructs a new KoDualColorButton using the default black and white
- * colors.
- *
- * @param parent The parent widget of the KoDualColorButton.
- * @param dialogParent The parent widget of the color selection dialog.
- */
- explicit KoDualColorButton( QWidget *parent = 0, QWidget* dialogParent = 0 );
-
- /**
* Constructs a new KoDualColorButton with the supplied foreground and
* background colors.
*
Index: libs/kopageapp/kopageapp_export.h
===================================================================
--- libs/kopageapp/kopageapp_export.h (revision 684521)
+++ libs/kopageapp/kopageapp_export.h (working copy)
@@ -23,40 +23,16 @@
/* needed for KDE_EXPORT and KDE_IMPORT macros */
#include <kdemacros.h>
-/* We use _WIN32/_WIN64 instead of Q_OS_WIN so that this header can be used from C \
files too */
-#if defined _WIN32 || defined _WIN64
-
#ifndef KOPAGEAPP_EXPORT
# if defined(MAKE_KOPAGEAPP_LIB)
/* We are building this library */
# define KOPAGEAPP_EXPORT KDE_EXPORT
+# define KOPAGEAPP_TEST_EXPORT KDE_EXPORT
# else
/* We are using this library */
# define KOPAGEAPP_EXPORT KDE_IMPORT
+# define KOPAGEAPP_TEST_EXPORT KDE_IMPORT
# endif
#endif
-#else /* UNIX */
-
-#define KOPAGEAPP_EXPORT KDE_EXPORT
-
#endif
-
-/* Now the same for KOPAGEAPP_TEST_EXPORT, if compiling with unit tests enabled */
-
-#ifdef COMPILING_TESTS
-#if defined _WIN32 || defined _WIN64
-# if defined( MAKE_KOPAGEAPP_LIB )
-# define KOPAGEAPP_TEST_EXPORT KDE_EXPORT
-# else
-# define KOPAGEAPP_TEST_EXPORT KDE_IMPORT
-# endif
-# else /* not windows */
-# define KOPAGEAPP_TEST_EXPORT KDE_EXPORT
-# endif
-#else /* not compiling tests */
-# define KOPAGEAPP_TEST_EXPORT
-#endif
-
-
-#endif
Index: libs/kopageapp/KoPAPageBase.cpp
===================================================================
--- libs/kopageapp/KoPAPageBase.cpp (revision 684521)
+++ libs/kopageapp/KoPAPageBase.cpp (working copy)
@@ -22,6 +22,7 @@
#include "KoPAStyles.h"
#include <QDebug>
+#include <QPainter>
#include <KoShapeSavingContext.h>
#include <KoShapeLayer.h>
Index: libs/kopageapp/KoPAPageBase.h
===================================================================
--- libs/kopageapp/KoPAPageBase.h (revision 684521)
+++ libs/kopageapp/KoPAPageBase.h (working copy)
@@ -26,12 +26,12 @@
#include <KoShapeContainer.h>
#include <KoXmlReader.h>
+#include <KoPASavingContext.h>
#include "kopageapp_export.h"
-class KoPageLayout;
+struct KoPageLayout;
class KoOasisLoadingContext;
-class KoPASavingContext;
class KoGenStyle;
class KoShape;
Index: libs/resources/KoResource.h
===================================================================
--- libs/resources/KoResource.h (revision 684521)
+++ libs/resources/KoResource.h (working copy)
@@ -30,7 +30,7 @@
*
* This replaces the KisKrayon facility that used to be present in Krayon.
*/
-class KORESOURCE_EXPORT KoResource : public QObject {
+class KORESOURCES_EXPORT KoResource : public QObject {
typedef QObject super;
Q_OBJECT
Index: libs/resources/koresource_export.h
===================================================================
--- libs/resources/koresource_export.h (revision 684521)
+++ libs/resources/koresource_export.h (working copy)
@@ -17,29 +17,20 @@
Boston, MA 02110-1301, USA.
*/
-#ifndef KORESOURCE_EXPORT_H
-#define KORESOURCE_EXPORT_H
+#ifndef KORESOURCES_EXPORT_H
+#define KORESOURCES_EXPORT_H
/* needed for KDE_EXPORT and KDE_IMPORT macros */
#include <kdemacros.h>
-/* We use _WIN32/_WIN64 instead of Q_OS_WIN so that this header can be used from C \
files too */
-#if defined _WIN32 || defined _WIN64
-
-#ifndef KORESOURCE_EXPORT
-# if defined(MAKE_KORESOURCE_LIB)
+#ifndef KORESOURCES_EXPORT
+# if defined(MAKE_KORESOURCES_LIB)
/* We are building this library */
-# define KORESOURCE_EXPORT KDE_EXPORT
+# define KORESOURCES_EXPORT KDE_EXPORT
# else
/* We are using this library */
-# define KORESOURCE_EXPORT KDE_IMPORT
+# define KORESOURCES_EXPORT KDE_IMPORT
# endif
#endif
-#else /* UNIX */
-
-#define KORESOURCE_EXPORT KDE_EXPORT
-
#endif
-
-#endif
Index: libs/resources/KoColorSet.h
===================================================================
--- libs/resources/KoColorSet.h (revision 684521)
+++ libs/resources/KoColorSet.h (working copy)
@@ -42,7 +42,7 @@
* Open Gimp, Photoshop or RIFF palette files. This is a straight port
* from the Gimp.
*/
-class KORESOURCE_EXPORT KoColorSet : public KoResource {
+class KORESOURCES_EXPORT KoColorSet : public KoResource {
typedef KoResource super;
Q_OBJECT
Index: libs/kotext/KoTextEditingRegistry.h
===================================================================
--- libs/kotext/KoTextEditingRegistry.h (revision 684521)
+++ libs/kotext/KoTextEditingRegistry.h (working copy)
@@ -21,11 +21,9 @@
#define KOTEXTEDITINGREGISTRY_H
#include <KoGenericRegistry.h>
-#include <kotext_export.h>
+#include <KoTextEditingFactory.h>
#include <QObject>
-class KoTextEditingFactory;
-
/**
* This singleton class keeps a register of all available text editing plugins.
* The text editing plugins are all about handling user input while (s)he
Index: libs/kotext/KoTextAnchor.cpp
===================================================================
--- libs/kotext/KoTextAnchor.cpp (revision 684521)
+++ libs/kotext/KoTextAnchor.cpp (working copy)
@@ -25,6 +25,7 @@
#include <QTextInlineObject>
#include <QFontMetricsF>
+#include <QPainter>
#include <KDebug>
class KoTextAnchor::Private {
Index: libs/kotext/KoTextShapeContainerModel.cpp
===================================================================
--- libs/kotext/KoTextShapeContainerModel.cpp (revision 684521)
+++ libs/kotext/KoTextShapeContainerModel.cpp (working copy)
@@ -137,7 +137,7 @@
//relation->anchor->setOffset(offset);
} */
- if(qAbs(newPosition.y() < 10)) // TopOfFrame
+ if(qAbs(newPosition.y()) < 10.0) // TopOfFrame
{//kDebug() << " TopOfFrame\n";
relation->anchor->setAlignment(KoTextAnchor::TopOfFrame);
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic