Update Time documentation

This commit is contained in:
Aaron Franke 2021-10-28 10:16:47 -05:00
parent f7d852b532
commit 2dabdda36a
No known key found for this signature in database
GPG key ID: 40A1750B977E56BF
8 changed files with 32 additions and 28 deletions

View file

@ -160,10 +160,10 @@ double OS_Unix::get_unix_time() const {
return (double)tv_now.tv_sec + double(tv_now.tv_usec) / 1000000;
};
OS::Date OS_Unix::get_date(bool utc) const {
OS::Date OS_Unix::get_date(bool p_utc) const {
time_t t = time(nullptr);
struct tm lt;
if (utc) {
if (p_utc) {
gmtime_r(&t, &lt);
} else {
localtime_r(&t, &lt);
@ -181,10 +181,10 @@ OS::Date OS_Unix::get_date(bool utc) const {
return ret;
}
OS::Time OS_Unix::get_time(bool utc) const {
OS::Time OS_Unix::get_time(bool p_utc) const {
time_t t = time(nullptr);
struct tm lt;
if (utc) {
if (p_utc) {
gmtime_r(&t, &lt);
} else {
localtime_r(&t, &lt);