diff options
Diffstat (limited to 'src/yuzu')
| -rw-r--r-- | src/yuzu/configuration/config.cpp | 2 | ||||
| -rw-r--r-- | src/yuzu/configuration/configure_input_simple.cpp | 19 | ||||
| -rw-r--r-- | src/yuzu/configuration/configure_per_general.cpp | 14 | ||||
| -rw-r--r-- | src/yuzu/debugger/wait_tree.cpp | 9 | 
4 files changed, 22 insertions, 22 deletions
| diff --git a/src/yuzu/configuration/config.cpp b/src/yuzu/configuration/config.cpp index c4349ccc8..c6079acb8 100644 --- a/src/yuzu/configuration/config.cpp +++ b/src/yuzu/configuration/config.cpp @@ -680,7 +680,7 @@ void Config::SaveValues() {          qt_config->setValue("title_id", QVariant::fromValue<u64>(elem.first));          qt_config->beginWriteArray("disabled");          for (std::size_t j = 0; j < elem.second.size(); ++j) { -            qt_config->setArrayIndex(j); +            qt_config->setArrayIndex(static_cast<int>(j));              qt_config->setValue("d", QString::fromStdString(elem.second[j]));          }          qt_config->endArray(); diff --git a/src/yuzu/configuration/configure_input_simple.cpp b/src/yuzu/configuration/configure_input_simple.cpp index b4f3724bd..07d71e9d1 100644 --- a/src/yuzu/configuration/configure_input_simple.cpp +++ b/src/yuzu/configuration/configure_input_simple.cpp @@ -3,12 +3,8 @@  // Refer to the license.txt file included.  #include <array> -#include <cstring> -#include <functional>  #include <tuple> -#include <QDialog> -  #include "ui_configure_input_simple.h"  #include "yuzu/configuration/configure_input.h"  #include "yuzu/configuration/configure_input_player.h" @@ -73,20 +69,18 @@ void DualJoyconsDockedOnProfileSelect() {  // Name, OnProfileSelect (called when selected in drop down), OnConfigure (called when configure  // is clicked) -using InputProfile = -    std::tuple<QString, std::function<void()>, std::function<void(ConfigureInputSimple*)>>; +using InputProfile = std::tuple<const char*, void (*)(), void (*)(ConfigureInputSimple*)>; -const std::array<InputProfile, 3> INPUT_PROFILES{{ -    {ConfigureInputSimple::tr("Single Player - Handheld - Undocked"), HandheldOnProfileSelect, +constexpr std::array<InputProfile, 3> INPUT_PROFILES{{ +    {QT_TR_NOOP("Single Player - Handheld - Undocked"), HandheldOnProfileSelect,       [](ConfigureInputSimple* caller) {           CallConfigureDialog<ConfigureInputPlayer>(caller, HANDHELD_INDEX, false);       }}, -    {ConfigureInputSimple::tr("Single Player - Dual Joycons - Docked"), -     DualJoyconsDockedOnProfileSelect, +    {QT_TR_NOOP("Single Player - Dual Joycons - Docked"), DualJoyconsDockedOnProfileSelect,       [](ConfigureInputSimple* caller) {           CallConfigureDialog<ConfigureInputPlayer>(caller, 1, false);       }}, -    {ConfigureInputSimple::tr("Custom"), [] {}, CallConfigureDialog<ConfigureInput>}, +    {QT_TR_NOOP("Custom"), [] {}, CallConfigureDialog<ConfigureInput>},  }};  } // namespace @@ -101,7 +95,8 @@ ConfigureInputSimple::ConfigureInputSimple(QWidget* parent)      ui->setupUi(this);      for (const auto& profile : INPUT_PROFILES) { -        ui->profile_combobox->addItem(std::get<0>(profile), std::get<0>(profile)); +        const QString label = tr(std::get<0>(profile)); +        ui->profile_combobox->addItem(label, label);      }      connect(ui->profile_combobox, QOverload<int>::of(&QComboBox::currentIndexChanged), this, diff --git a/src/yuzu/configuration/configure_per_general.cpp b/src/yuzu/configuration/configure_per_general.cpp index 80109b434..e13d2eac8 100644 --- a/src/yuzu/configuration/configure_per_general.cpp +++ b/src/yuzu/configuration/configure_per_general.cpp @@ -47,8 +47,8 @@ ConfigurePerGameGeneral::ConfigurePerGameGeneral(QWidget* parent, u64 title_id)      tree_view->setContextMenuPolicy(Qt::NoContextMenu);      item_model->insertColumns(0, 2); -    item_model->setHeaderData(0, Qt::Horizontal, "Patch Name"); -    item_model->setHeaderData(1, Qt::Horizontal, "Version"); +    item_model->setHeaderData(0, Qt::Horizontal, tr("Patch Name")); +    item_model->setHeaderData(1, Qt::Horizontal, tr("Version"));      // We must register all custom types with the Qt Automoc system so that we are able to use it      // with signals/slots. In this case, QList falls under the umbrells of custom types. @@ -108,9 +108,9 @@ void ConfigurePerGameGeneral::loadConfiguration() {          if (loader->ReadTitle(title) == Loader::ResultStatus::Success)              ui->display_name->setText(QString::fromStdString(title)); -        std::string developer; -        if (loader->ReadDeveloper(developer) == Loader::ResultStatus::Success) -            ui->display_developer->setText(QString::fromStdString(developer)); +        FileSys::NACP nacp; +        if (loader->ReadControlData(nacp) == Loader::ResultStatus::Success) +            ui->display_developer->setText(QString::fromStdString(nacp.GetDeveloperName()));          ui->display_version->setText(QStringLiteral("1.0.0"));      } @@ -120,7 +120,7 @@ void ConfigurePerGameGeneral::loadConfiguration() {          QPixmap map;          const auto bytes = control.second->ReadAllBytes(); -        map.loadFromData(bytes.data(), bytes.size()); +        map.loadFromData(bytes.data(), static_cast<u32>(bytes.size()));          scene->addPixmap(map.scaled(ui->icon_view->width(), ui->icon_view->height(),                                      Qt::IgnoreAspectRatio, Qt::SmoothTransformation)); @@ -130,7 +130,7 @@ void ConfigurePerGameGeneral::loadConfiguration() {              scene->clear();              QPixmap map; -            map.loadFromData(bytes.data(), bytes.size()); +            map.loadFromData(bytes.data(), static_cast<u32>(bytes.size()));              scene->addPixmap(map.scaled(ui->icon_view->width(), ui->icon_view->height(),                                          Qt::IgnoreAspectRatio, Qt::SmoothTransformation)); diff --git a/src/yuzu/debugger/wait_tree.cpp b/src/yuzu/debugger/wait_tree.cpp index 6b3a757e0..df6eeb9a6 100644 --- a/src/yuzu/debugger/wait_tree.cpp +++ b/src/yuzu/debugger/wait_tree.cpp @@ -221,6 +221,9 @@ QString WaitTreeThread::GetText() const {      case Kernel::ThreadStatus::Ready:          status = tr("ready");          break; +    case Kernel::ThreadStatus::Paused: +        status = tr("paused"); +        break;      case Kernel::ThreadStatus::WaitHLEEvent:          status = tr("waiting for HLE return");          break; @@ -262,6 +265,8 @@ QColor WaitTreeThread::GetColor() const {          return QColor(Qt::GlobalColor::darkGreen);      case Kernel::ThreadStatus::Ready:          return QColor(Qt::GlobalColor::darkBlue); +    case Kernel::ThreadStatus::Paused: +        return QColor(Qt::GlobalColor::lightGray);      case Kernel::ThreadStatus::WaitHLEEvent:      case Kernel::ThreadStatus::WaitIPC:          return QColor(Qt::GlobalColor::darkRed); @@ -288,8 +293,8 @@ std::vector<std::unique_ptr<WaitTreeItem>> WaitTreeThread::GetChildren() const {      QString processor;      switch (thread.GetProcessorID()) { -    case Kernel::ThreadProcessorId::THREADPROCESSORID_DEFAULT: -        processor = tr("default"); +    case Kernel::ThreadProcessorId::THREADPROCESSORID_IDEAL: +        processor = tr("ideal");          break;      case Kernel::ThreadProcessorId::THREADPROCESSORID_0:      case Kernel::ThreadProcessorId::THREADPROCESSORID_1: | 
