7054 elif period in [2, 3, 4]: |
7054 elif period in [2, 3, 4]: |
7055 lastCheck = Preferences.Prefs.settings.value( |
7055 lastCheck = Preferences.Prefs.settings.value( |
7056 "Updates/LastCheckDate", QDate(1970, 1, 1)) |
7056 "Updates/LastCheckDate", QDate(1970, 1, 1)) |
7057 if lastCheck.isValid(): |
7057 if lastCheck.isValid(): |
7058 now = QDate.currentDate() |
7058 now = QDate.currentDate() |
7059 if period == 2 and lastCheck.day() == now.day(): |
7059 if ( |
7060 # daily |
7060 (period == 2 and lastCheck.day() == now.day()) or |
7061 return |
7061 (period == 3 and lastCheck.daysTo(now) < 7) or |
7062 elif period == 3 and lastCheck.daysTo(now) < 7: |
7062 (period == 4 and (lastCheck.daysTo(now) < |
7063 # weekly |
7063 lastCheck.daysInMonth())) |
7064 return |
7064 ): |
7065 elif period == 4 and (lastCheck.daysTo(now) < |
7065 # daily, weekly, monthly |
7066 lastCheck.daysInMonth()): |
|
7067 # monthly |
|
7068 return |
7066 return |
7069 |
7067 |
7070 self.__inVersionCheck = True |
7068 self.__inVersionCheck = True |
7071 self.manualUpdatesCheck = manual |
7069 self.manualUpdatesCheck = manual |
7072 self.showAvailableVersions = showVersions |
7070 self.showAvailableVersions = showVersions |