diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/citra_qt/debugger/graphics_cmdlists.cpp | 26 |
1 files changed, 14 insertions, 12 deletions
diff --git a/src/citra_qt/debugger/graphics_cmdlists.cpp b/src/citra_qt/debugger/graphics_cmdlists.cpp index de10bce1f..425e127e8 100644 --- a/src/citra_qt/debugger/graphics_cmdlists.cpp +++ b/src/citra_qt/debugger/graphics_cmdlists.cpp | |||
| @@ -174,7 +174,7 @@ int GPUCommandListModel::rowCount(const QModelIndex& parent) const { | |||
| 174 | } | 174 | } |
| 175 | 175 | ||
| 176 | int GPUCommandListModel::columnCount(const QModelIndex& parent) const { | 176 | int GPUCommandListModel::columnCount(const QModelIndex& parent) const { |
| 177 | return 2; | 177 | return 3; |
| 178 | } | 178 | } |
| 179 | 179 | ||
| 180 | QVariant GPUCommandListModel::data(const QModelIndex& index, int role) const { | 180 | QVariant GPUCommandListModel::data(const QModelIndex& index, int role) const { |
| @@ -187,14 +187,13 @@ QVariant GPUCommandListModel::data(const QModelIndex& index, int role) const { | |||
| 187 | 187 | ||
| 188 | if (role == Qt::DisplayRole) { | 188 | if (role == Qt::DisplayRole) { |
| 189 | QString content; | 189 | QString content; |
| 190 | if (index.column() == 0) { | 190 | switch ( index.column() ) { |
| 191 | QString content = QString::fromLatin1(Pica::Regs::GetCommandName(cmd.cmd_id).c_str()); | 191 | case 0: |
| 192 | content.append(" "); | 192 | return QString::fromLatin1(Pica::Regs::GetCommandName(cmd.cmd_id).c_str()); |
| 193 | return content; | 193 | case 1: |
| 194 | } else if (index.column() == 1) { | 194 | return QString("%1").arg(cmd.cmd_id, 3, 16, QLatin1Char('0')); |
| 195 | QString content = QString("%1 ").arg(cmd.hex, 8, 16, QLatin1Char('0')); | 195 | case 2: |
| 196 | content.append(QString("%1 ").arg(val, 8, 16, QLatin1Char('0'))); | 196 | return QString("%1").arg(val, 8, 16, QLatin1Char('0')); |
| 197 | return content; | ||
| 198 | } | 197 | } |
| 199 | } else if (role == CommandIdRole) { | 198 | } else if (role == CommandIdRole) { |
| 200 | return QVariant::fromValue<int>(cmd.cmd_id.Value()); | 199 | return QVariant::fromValue<int>(cmd.cmd_id.Value()); |
| @@ -207,10 +206,13 @@ QVariant GPUCommandListModel::headerData(int section, Qt::Orientation orientatio | |||
| 207 | switch(role) { | 206 | switch(role) { |
| 208 | case Qt::DisplayRole: | 207 | case Qt::DisplayRole: |
| 209 | { | 208 | { |
| 210 | if (section == 0) { | 209 | switch (section) { |
| 210 | case 0: | ||
| 211 | return tr("Command Name"); | 211 | return tr("Command Name"); |
| 212 | } else if (section == 1) { | 212 | case 1: |
| 213 | return tr("Data"); | 213 | return tr("Register"); |
| 214 | case 2: | ||
| 215 | return tr("New Value"); | ||
| 214 | } | 216 | } |
| 215 | 217 | ||
| 216 | break; | 218 | break; |