diff --git a/ScreenPlaySysInfo/src/ram.h b/ScreenPlaySysInfo/src/ram.h index f4430532..e3778d8f 100644 --- a/ScreenPlaySysInfo/src/ram.h +++ b/ScreenPlaySysInfo/src/ram.h @@ -11,18 +11,18 @@ #include #endif -#define DWORDLONG unsigned long long +#define DWORDLONG quint64 class RAM : public QObject { Q_OBJECT Q_PROPERTY(float usage READ usage NOTIFY usageChanged) - Q_PROPERTY(unsigned long long usedPhysicalMemory READ usedPhysicalMemory NOTIFY usedPhysicalMemoryChanged) - Q_PROPERTY(unsigned long long totalPhysicalMemory READ totalPhysicalMemory NOTIFY totalPhysicalMemoryChanged) - Q_PROPERTY(unsigned long long usedVirtualMemory READ usedVirtualMemory NOTIFY usedVirtualMemoryChanged) - Q_PROPERTY(unsigned long long totalVirtualMemory READ totalVirtualMemory NOTIFY totalVirtualMemoryChanged) - Q_PROPERTY(unsigned long long usedPagingMemory READ usedPagingMemory NOTIFY usedPagingMemoryChanged) - Q_PROPERTY(unsigned long long totalPagingMemory READ totalPagingMemory NOTIFY totalPagingMemoryChanged) + Q_PROPERTY(quint64 usedPhysicalMemory READ usedPhysicalMemory NOTIFY usedPhysicalMemoryChanged) + Q_PROPERTY(quint64 totalPhysicalMemory READ totalPhysicalMemory NOTIFY totalPhysicalMemoryChanged) + Q_PROPERTY(quint64 usedVirtualMemory READ usedVirtualMemory NOTIFY usedVirtualMemoryChanged) + Q_PROPERTY(quint64 totalVirtualMemory READ totalVirtualMemory NOTIFY totalVirtualMemoryChanged) + Q_PROPERTY(quint64 usedPagingMemory READ usedPagingMemory NOTIFY usedPagingMemoryChanged) + Q_PROPERTY(quint64 totalPagingMemory READ totalPagingMemory NOTIFY totalPagingMemoryChanged) QML_ELEMENT public: diff --git a/ScreenPlayWidget/src/widgetwindow.cpp b/ScreenPlayWidget/src/widgetwindow.cpp index 5952904f..f1d62cb5 100644 --- a/ScreenPlayWidget/src/widgetwindow.cpp +++ b/ScreenPlayWidget/src/widgetwindow.cpp @@ -148,7 +148,7 @@ void WidgetWindow::setWidgetSize(const int with, const int height) } #ifdef Q_OS_WIN -void WidgetWindow::setWindowBlur(unsigned int style) +void WidgetWindow::setWindowBlur(quint64 style) { const HINSTANCE hModule = LoadLibrary(TEXT("user32.dll")); diff --git a/ScreenPlayWidget/src/widgetwindow.h b/ScreenPlayWidget/src/widgetwindow.h index 48b13d85..48ed7547 100644 --- a/ScreenPlayWidget/src/widgetwindow.h +++ b/ScreenPlayWidget/src/widgetwindow.h @@ -91,7 +91,7 @@ public slots: QPointF cursorPos() { return QCursor::pos(); } #ifdef Q_OS_WIN - void setWindowBlur(unsigned int style = 3); + void setWindowBlur(quint64 style = 3); #endif void setPosition(QPoint position) diff --git a/ScreenPlayWorkshop/src/installedlistmodel.cpp b/ScreenPlayWorkshop/src/installedlistmodel.cpp index 0c75086f..63148899 100644 --- a/ScreenPlayWorkshop/src/installedlistmodel.cpp +++ b/ScreenPlayWorkshop/src/installedlistmodel.cpp @@ -141,11 +141,6 @@ QVariantMap InstalledListModel::get(QString folderName) return map; } -int InstalledListModel::getAmountItemLoaded() -{ - return m_screenPlayFiles.count(); -} - void InstalledListModel::reset() { beginResetModel(); diff --git a/ScreenPlayWorkshop/src/installedlistmodel.h b/ScreenPlayWorkshop/src/installedlistmodel.h index 1d463016..b6807f72 100644 --- a/ScreenPlayWorkshop/src/installedlistmodel.h +++ b/ScreenPlayWorkshop/src/installedlistmodel.h @@ -77,7 +77,6 @@ public slots: m_absoluteStoragePath = absoluteStoragePath; emit absoluteStoragePathChanged(m_absoluteStoragePath); } - int getAmountItemLoaded(); void reset(); signals: diff --git a/ScreenPlayWorkshop/src/steamworkshop.h b/ScreenPlayWorkshop/src/steamworkshop.h index abeb9bb5..18d6c977 100644 --- a/ScreenPlayWorkshop/src/steamworkshop.h +++ b/ScreenPlayWorkshop/src/steamworkshop.h @@ -33,8 +33,8 @@ struct SteamItemUpdate { } QString absoluteStoragePath; UGCUpdateHandle_t steamUGCUpdateHandle = 0; - unsigned long long itemProcessed = 0; - unsigned long long bytesTotal = 0; + quint64 itemProcessed = 0; + quint64 bytesTotal = 0; }; class SteamWorkshop : public QObject { @@ -43,9 +43,9 @@ class SteamWorkshop : public QObject { Q_PROPERTY(bool online READ online WRITE setOnline NOTIFY onlineChanged) Q_PROPERTY(bool queryActive READ queryActive WRITE setQueryActive NOTIFY queryActiveChanged) - Q_PROPERTY(unsigned long long itemProcessed READ itemProcessed WRITE setItemProcessed NOTIFY itemProcessedChanged) - Q_PROPERTY(unsigned long long bytesTotal READ bytesTotal WRITE setBytesTotal NOTIFY bytesTotalChanged) - Q_PROPERTY(unsigned int appID READ appID) + Q_PROPERTY(quint64 itemProcessed READ itemProcessed WRITE setItemProcessed NOTIFY itemProcessedChanged) + Q_PROPERTY(quint64 bytesTotal READ bytesTotal WRITE setBytesTotal NOTIFY bytesTotalChanged) + Q_PROPERTY(quint64 appID READ appID) Q_PROPERTY(SteamWorkshopListModel* workshopListModel READ workshopListModel WRITE setWorkshopListModel NOTIFY workshopListModelChanged) Q_PROPERTY(SteamWorkshopListModel* workshopProfileListModel READ workshopProfileListModel WRITE setWorkshopProfileListModel NOTIFY workshopProfileListModelChanged) Q_PROPERTY(UploadListModel* uploadListModel READ uploadListModel NOTIFY uploadListModelChanged) @@ -64,9 +64,9 @@ public: bool online() const { return m_online; } bool queryActive() const { return m_queryActive; } - unsigned long long itemProcessed() const { return m_itemProcessed; } - unsigned int appID() const { return m_appID; } - unsigned long long bytesTotal() const { return m_bytesTotal; } + quint64 itemProcessed() const { return m_itemProcessed; } + quint64 appID() const { return m_appID; } + quint64 bytesTotal() const { return m_bytesTotal; } UploadListModel* uploadListModel() const { return m_uploadListModel.get(); } SteamAccount* steamAccount() const { return m_steamAccount.get(); } SteamWorkshopListModel* workshopListModel() const { return m_workshopListModel.get(); } @@ -103,7 +103,7 @@ public slots: return m_queryActive; } - void setItemProcessed(unsigned long long itemProcessed) + void setItemProcessed(quint64 itemProcessed) { if (m_itemProcessed == itemProcessed) return; @@ -112,7 +112,7 @@ public slots: emit itemProcessedChanged(m_itemProcessed); } - void setBytesTotal(unsigned long long bytesTotal) + void setBytesTotal(quint64 bytesTotal) { if (m_bytesTotal == bytesTotal) return; @@ -237,9 +237,9 @@ private: bool m_steamErrorRestart = false; bool m_steamErrorAPIInit = false; - unsigned long long m_itemProcessed = 0; - unsigned long long m_bytesTotal = 0; - const unsigned int m_appID = 672870; + quint64 m_itemProcessed = 0; + quint64 m_bytesTotal = 0; + const quint64 m_appID = 672870; bool m_online = false; bool m_queryActive = false; diff --git a/ScreenPlayWorkshop/src/steamworkshopitem.cpp b/ScreenPlayWorkshop/src/steamworkshopitem.cpp index 0df69dd4..10cf4c93 100644 --- a/ScreenPlayWorkshop/src/steamworkshopitem.cpp +++ b/ScreenPlayWorkshop/src/steamworkshopitem.cpp @@ -4,7 +4,7 @@ #include namespace ScreenPlayWorkshop { -SteamWorkshopItem::SteamWorkshopItem(const QString& name, const QUrl& absolutePath, const unsigned int appID) +SteamWorkshopItem::SteamWorkshopItem(const QString& name, const QUrl& absolutePath, const quint64 appID) : QObject() , m_name { name } , m_absolutePath { absolutePath } @@ -22,8 +22,8 @@ void SteamWorkshopItem::createWorkshopItem() void SteamWorkshopItem::checkUploadProgress() { - unsigned long long _itemProcessed = 0; - unsigned long long _bytesTotoal = 0; + quint64 _itemProcessed = 0; + quint64 _bytesTotoal = 0; EItemUpdateStatus status = SteamUGC()->GetItemUpdateProgress(m_UGCUpdateHandle, &_itemProcessed, &_bytesTotoal); qInfo() << absolutePath() << absolutePreviewImagePath() << name() << uploadProgress() << "% - " << _itemProcessed << _bytesTotoal << status; diff --git a/ScreenPlayWorkshop/src/steamworkshopitem.h b/ScreenPlayWorkshop/src/steamworkshopitem.h index 56fb39f3..8500fcf1 100644 --- a/ScreenPlayWorkshop/src/steamworkshopitem.h +++ b/ScreenPlayWorkshop/src/steamworkshopitem.h @@ -39,7 +39,7 @@ public: SteamWorkshopItem( const QString& name, const QUrl& absolutePath, - const unsigned int appID); + const quint64 appID); QString name() const { return m_name; } QUrl absolutePath() const { return m_absolutePath; } @@ -133,7 +133,7 @@ private: QString m_name; QUrl m_absolutePath; QUrl m_absolutePreviewImagePath; - unsigned int m_appID { 0 }; + quint64 m_appID { 0 }; const int m_updateTimerInterval { 500 }; int m_uploadProgress { 0 }; // 0 - 100 ScreenPlayWorkshopSteamEnums::EResult m_status { ScreenPlayWorkshopSteamEnums::EResult::K_EResultNone }; diff --git a/ScreenPlayWorkshop/src/steamworkshoplistmodel.h b/ScreenPlayWorkshop/src/steamworkshoplistmodel.h index 01fc11dc..e8a05846 100644 --- a/ScreenPlayWorkshop/src/steamworkshoplistmodel.h +++ b/ScreenPlayWorkshop/src/steamworkshoplistmodel.h @@ -66,7 +66,7 @@ public slots: { return m_workshopItemList.empty() ? QVariant {} : m_workshopItemList.at(0).m_publishedFileID; } - unsigned int getBannerAmountSubscriber() + quint64 getBannerAmountSubscriber() { return m_workshopItemList.empty() ? int {} : m_workshopItemList.at(0).m_subscriptionCount; } @@ -95,7 +95,7 @@ private: UGCQueryHandle_t m_UGCSearchHandle = 0; QVector m_workshopItemList; - const unsigned int m_appID = 0; + const quint64 m_appID = 0; int m_pages = 1; int m_currentPage = 1; }; diff --git a/ScreenPlayWorkshop/src/uploadlistmodel.h b/ScreenPlayWorkshop/src/uploadlistmodel.h index c6b5c4e1..e05a4946 100644 --- a/ScreenPlayWorkshop/src/uploadlistmodel.h +++ b/ScreenPlayWorkshop/src/uploadlistmodel.h @@ -95,7 +95,7 @@ public slots: endResetModel(); } - void append(const QString& name, const QString& path, const unsigned int appID) + void append(const QString& name, const QString& path, const quint64 appID) { auto item = std::make_unique(name, path, appID); QObject::connect(item.get(), &SteamWorkshopItem::userNeedsToAcceptWorkshopLegalAgreement, this, &UploadListModel::userNeedsToAcceptWorkshopLegalAgreement);