From d2ed2aaddb88f39f8b2ced18a4ea7f06a63237d3 Mon Sep 17 00:00:00 2001 From: zautrix Date: Sat, 19 Feb 2005 10:19:59 +0000 Subject: duration fix --- (limited to 'libkcal/incidencebase.cpp') diff --git a/libkcal/incidencebase.cpp b/libkcal/incidencebase.cpp index 51f2e9d..1e99082 100644 --- a/libkcal/incidencebase.cpp +++ b/libkcal/incidencebase.cpp @@ -106,13 +106,20 @@ bool KCal::operator==( const IncidenceBase& i1, const IncidenceBase& i2 ) qDebug("6 %d ",i1.organizer() == i2.organizer() ); #endif + if ( i1.hasDuration() == i2.hasDuration() ) { + if ( i1.hasDuration() ) { + if ( i1.duration() != i2.duration() ) + return false; + } + } else { + return false; + } + return ( i1.organizer() == i2.organizer() && // i1.uid() == i2.uid() && // Don't compare lastModified, otherwise the operator is not // of much use. We are not comparing for identity, after all. i1.doesFloat() == i2.doesFloat() && - i1.duration() == i2.duration() && - i1.hasDuration() == i2.hasDuration() && i1.pilotId() == i2.pilotId() );// && i1.syncStatus() == i2.syncStatus() ); // no need to compare mObserver } -- cgit v0.9.0.2