mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-10-30 17:40:47 +03:00
Work around ICE on MSVC
See https://developercommunity.visualstudio.com/t/Internal-compile-error-while-compiling-c/1227337 for details...
This commit is contained in:
parent
631a5a11b3
commit
f48c696baf
1 changed files with 14 additions and 8 deletions
|
@ -225,10 +225,13 @@ GridImagePackModel::data(const QModelIndex &index, int role) const
|
||||||
auto endOffset = std::min((offset + 1) * columns, pack.images.size());
|
auto endOffset = std::min((offset + 1) * columns, pack.images.size());
|
||||||
for (std::size_t img = offset * columns; img < endOffset; img++) {
|
for (std::size_t img = offset * columns; img < endOffset; img++) {
|
||||||
const auto &data = pack.images.at(img);
|
const auto &data = pack.images.at(img);
|
||||||
imgs.push_back({.url = QString::fromStdString(data.first.url),
|
// See
|
||||||
.shortcode = data.second,
|
// https://developercommunity.visualstudio.com/t/Internal-compile-error-while-compiling-c/1227337
|
||||||
.body = QString::fromStdString(data.first.body),
|
imgs.push_back({/*.url =*/QString::fromStdString(data.first.url),
|
||||||
.descriptor_ = std::vector{
|
/*.shortcode =*/data.second,
|
||||||
|
/*.body =*/QString::fromStdString(data.first.body),
|
||||||
|
/*.descriptor_=*/
|
||||||
|
std::vector{
|
||||||
pack.room_id,
|
pack.room_id,
|
||||||
pack.state_key,
|
pack.state_key,
|
||||||
data.second.toStdString(),
|
data.second.toStdString(),
|
||||||
|
@ -265,10 +268,13 @@ GridImagePackModel::data(const QModelIndex &index, int role) const
|
||||||
currentSearchResult[img].first == firstEntry.first;
|
currentSearchResult[img].first == firstEntry.first;
|
||||||
img++) {
|
img++) {
|
||||||
const auto &data = pack.images.at(currentSearchResult[img].second);
|
const auto &data = pack.images.at(currentSearchResult[img].second);
|
||||||
imgs.push_back({.url = QString::fromStdString(data.first.url),
|
// See
|
||||||
.shortcode = data.second,
|
// https://developercommunity.visualstudio.com/t/Internal-compile-error-while-compiling-c/1227337
|
||||||
.body = QString::fromStdString(data.first.body),
|
imgs.push_back({/*.url = */ QString::fromStdString(data.first.url),
|
||||||
.descriptor_ = std::vector{
|
/*.shortcode = */ data.second,
|
||||||
|
/*.body = */ QString::fromStdString(data.first.body),
|
||||||
|
/*.descriptor_ = */
|
||||||
|
std::vector{
|
||||||
pack.room_id,
|
pack.room_id,
|
||||||
pack.state_key,
|
pack.state_key,
|
||||||
data.second.toStdString(),
|
data.second.toStdString(),
|
||||||
|
|
Loading…
Reference in a new issue