X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/641204dfbdb9fc870cdd2e7f9e3169a44693e7bf..1ed49c21260edc5b40aa2d0d4b8486bc1928f21b:/projects/stargazer/user.h?ds=sidebyside diff --git a/projects/stargazer/user.h b/projects/stargazer/user.h index 7a9896bf..496baa72 100644 --- a/projects/stargazer/user.h +++ b/projects/stargazer/user.h @@ -144,9 +144,7 @@ public: void ResetPassiveTime() { passiveTime = 0; } void SetPassiveTimeAsNewUser(); - void ResetDetailStat(); - int SwapDetailStat(); - int WriteDetailStat(); + int WriteDetailStat(bool hard = false); const TARIFF * GetTariff() const { return tariff; } void ResetNextTariff() { nextTariff = ""; } @@ -205,7 +203,6 @@ private: int SaveMonthStat(int month, int year); int SendMessage(const STG_MSG & msg); - int RemoveMessage(uint64_t) { return 0; } int ScanMessage(); time_t lastScanMessages; @@ -235,10 +232,8 @@ private: const TARIFFS * tariffs; const TARIFF * tariff; - map traffStatInternal[2]; - map * traffStat; - map * traffStatToWrite; - int traffStatInUse; + TRAFF_STAT traffStat; + std::pair traffStatSaved; const SETTINGS * settings; @@ -246,11 +241,12 @@ private: const map * ipIndex; + list messages; + bool deleted; time_t lastWriteStat; // ÷ÒÅÍÑ ÐÏÓÌÅÄÎÅÊ ÚÁÐÉÓÉ ÓÔÁÔÉÓÔÉËÉ time_t lastWriteDeatiledStat; // ÷ÒÅÍÑ ÐÏÓÌÅÄÎÅÊ ÚÁÐÉÓÉ ÄÅÔÁÌØÎÏÊ ÓÔÁÔÉÓÔÉËÉ - time_t lastSwapDeatiledStat; // ÷ÒÅÍÑ ÐÏÓÌÅÄÎÅÊ ÚÁÐÉÓÉ ÄÅÔÁÌØÎÏÊ ÓÔÁÔÉÓÔÉËÉ bool writeFreeMbTraffCost;