1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-08-09 16:41:14 +02:00

Registry passed to Visit can be const

This commit is contained in:
Paul Licameli 2020-02-14 22:02:54 -05:00
parent 46f958f376
commit 4cfbf07227
2 changed files with 5 additions and 5 deletions

View File

@ -929,12 +929,12 @@ auto CollectedItems::MergeItems(
void VisitItem(
Registry::Visitor &visitor, CollectedItems &collection,
Path &path, BaseItem *pItem,
GroupItem *pToMerge, const OrderingHint &hint,
const GroupItem *pToMerge, const OrderingHint &hint,
bool &doFlush );
void VisitItems(
Registry::Visitor &visitor, CollectedItems &collection,
Path &path, GroupItem *pGroup,
GroupItem *pToMerge, const OrderingHint &hint,
const GroupItem *pToMerge, const OrderingHint &hint,
bool &doFlush )
{
// Make a NEW collection for this subtree, sharing the memo cache
@ -981,7 +981,7 @@ void VisitItems(
void VisitItem(
Registry::Visitor &visitor, CollectedItems &collection,
Path &path, BaseItem *pItem,
GroupItem *pToMerge, const OrderingHint &hint,
const GroupItem *pToMerge, const OrderingHint &hint,
bool &doFlush )
{
if (!pItem)
@ -1009,7 +1009,7 @@ void VisitItem(
namespace Registry {
void Visit( Visitor &visitor, BaseItem *pTopItem, GroupItem *pRegistry )
void Visit( Visitor &visitor, BaseItem *pTopItem, const GroupItem *pRegistry )
{
std::vector< BaseItemSharedPtr > computedItems;
bool doFlush = false;

View File

@ -641,7 +641,7 @@ namespace Registry {
void Visit(
Visitor &visitor,
BaseItem *pTopItem,
GroupItem *pRegistry = nullptr );
const GroupItem *pRegistry = nullptr );
// Typically a static object. Constructor initializes certain preferences
// if they are not present. These preferences determine an extrinsic