Fix some includes and warnings

This commit is contained in:
Megamouse 2023-01-10 20:30:03 +01:00
parent cf1e68fb0e
commit 6bcb5ae66b
6 changed files with 11 additions and 7 deletions

View file

@ -1,6 +1,7 @@
#pragma once
#include <QMap>
#include <vector>
// Node location
using cfg_location = std::vector<const char*>;

View file

@ -3,9 +3,9 @@
#include "log_viewer.h"
#include "gui_settings.h"
#include "syntax_highlighter.h"
#include "find_dialog.h"
#include "config_checker.h"
#include <QActionGroup>
#include <QApplication>
#include <QMenu>
#include <QFile>

View file

@ -1,5 +1,7 @@
#pragma once
#include "find_dialog.h"
#include <QPlainTextEdit>
#include <QDropEvent>
@ -8,7 +10,6 @@
class LogHighlighter;
class gui_settings;
class find_dialog;
class log_viewer : public QWidget
{

View file

@ -288,7 +288,9 @@ void patch_manager_dialog::populate_tree()
const QString q_description = QString::fromStdString(description);
QString visible_description = q_description;
const auto match_criteria = QList<QPair<int, QVariant>>() << QPair(description_role, q_description) << QPair(persistance_role, true);
const QList<QPair<int, QVariant>> match_criteria = QList<QPair<int, QVariant>>()
<< QPair<int, QVariant>(description_role, q_description)
<< QPair<int, QVariant>(persistance_role, true);
// Add counter to leafs if the name already exists due to different hashes of the same game (PPU, SPU, PRX, OVL)
if (const auto matches = gui::utils::find_children_by_data(serial_level_item, match_criteria, false); matches.count() > 0)
@ -322,7 +324,8 @@ void patch_manager_dialog::populate_tree()
}
}
const auto match_criteria = QList<QPair<int, QVariant>>() << QPair(persistance_role, true);
const QList<QPair<int, QVariant>> match_criteria = QList<QPair<int, QVariant>>()
<< QPair<int, QVariant>(persistance_role, true);
for (int i = ui->patch_tree->topLevelItemCount() - 1; i >= 0; i--)
{

View file

@ -606,7 +606,7 @@ bool update_manager::handle_rpcs3(const QByteArray& data, bool auto_accept)
update_log.error("Failed to create new AppImage file: %s (%s)", replace_path, fs::g_tls_error);
return false;
}
if (new_appimage.write(data.data(), data.size()) != data.size() + 0u)
if (new_appimage.write(data.data(), data.size()) != data.size() + 0ull)
{
update_log.error("Failed to write new AppImage file: %s", replace_path);
return false;

View file

@ -1,12 +1,11 @@
#pragma once
#include "util/types.hpp"
#include <vector>
#ifdef _WIN32
#include <pdh.h>
#include <pdhmsg.h>
#elif __linux__
#include <vector>
#endif
namespace utils