[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    koffice/kplato
From:       Dag Andersen <danders () get2net ! dk>
Date:       2006-03-03 7:53:57
Message-ID: 1141372437.667253.20510.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 515236 by danders:

A resource isn't available if units==0

 M  +6 -0      kptresource.cc  


--- trunk/koffice/kplato/kptresource.cc #515235:515236
@@ -575,6 +575,9 @@
 
 DateTime Resource::availableAfter(const DateTime &time, const DateTime limit, bool checkAppointments) const {
     DateTime t;
+    if (m_units == 0) {
+        return t;
+    }
     DateTime lmt = m_availableUntil;
     if (limit.isValid() && limit < lmt) {
         lmt = limit;
@@ -602,6 +605,9 @@
 
 DateTime Resource::availableBefore(const DateTime &time, const DateTime limit, bool checkAppointments) const {
     DateTime t;
+    if (m_units == 0) {
+        return t;
+    }
     DateTime lmt = m_availableFrom;
     if (limit.isValid() && limit > lmt) {
         lmt = limit;
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic