We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 80eb628 + 0225563 commit 4bc1a18Copy full SHA for 4bc1a18
src/DockContainerWidget.cpp
@@ -1319,9 +1319,9 @@ void CDockContainerWidget::removeDockArea(CDockAreaWidget* area)
1319
internal::hideEmptyParentSplitters(Splitter);
1320
1321
// Remove this area from cached areas
1322
- const auto& cache = d->LastAddedAreaCache;
1323
- if (auto p = std::find(cache, cache+sizeof(cache)/sizeof(cache[0]), area)) {
1324
- d->LastAddedAreaCache[std::distance(cache, p)] = nullptr;
+ auto p = std::find(std::begin(d->LastAddedAreaCache), std::end(d->LastAddedAreaCache), area);
+ if (p != std::end(d->LastAddedAreaCache)) {
+ *p = nullptr;
1325
}
1326
1327
// If splitter has more than 1 widgets, we are finished and can leave
0 commit comments