(svn r19788) -Codechange: make FOR_EACH_SET_BIT not change the value of the passed bit variable, i.e. allow expressions as parameter

This commit is contained in:
rubidium
2010-05-11 20:48:06 +00:00
parent 862321c62a
commit ee02599bbf
5 changed files with 12 additions and 14 deletions

View File

@@ -567,7 +567,7 @@ public:
FOR_EACH_SET_BIT(i, this->facilities) {
this->RaiseWidget(i + SLW_TRAIN);
}
SetBit(this->facilities, widget - SLW_TRAIN);
this->facilities = 1 << (widget - SLW_TRAIN);
this->LowerWidget(widget);
}
this->stations.ForceRebuild();