mirror of
https://github.com/Palakis/obs-websocket.git
synced 2024-08-30 18:12:16 +00:00
SettingsDialog: Fix datetime shit
This commit is contained in:
parent
53e773b1a2
commit
3d43bd525b
@ -2,6 +2,7 @@
|
||||
#include <obs-frontend-api.h>
|
||||
#include <QtWidgets/QMessageBox>
|
||||
#include <QClipboard>
|
||||
#include <QDateTime>
|
||||
#include <QTime>
|
||||
|
||||
#include "SettingsDialog.h"
|
||||
@ -77,7 +78,7 @@ void SettingsDialog::FillSessionTable()
|
||||
QTableWidgetItem *addressItem = new QTableWidgetItem(QString::fromStdString(session.remoteAddress));
|
||||
ui->websocketSessionTable->setItem(i, 0, addressItem);
|
||||
|
||||
uint64_t sessionDuration = QDateTime::toTime_t() - session.connectedAt;
|
||||
uint64_t sessionDuration = QDateTime::currentSecsSinceEpoch() - session.connectedAt;
|
||||
QTableWidgetItem *durationItem = new QTableWidgetItem(QTime(0, 0, sessionDuration).toString("hh:mm:ss"));
|
||||
ui->websocketSessionTable->setItem(i, 1, durationItem);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user