Followed Marcus' suggestion and made fHeight mutable - not nice, but cleaner

than casting away the const.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14614 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler
2005-11-01 13:19:00 +00:00
parent 1ce9b0cb59
commit 297cd250fa
2 changed files with 5 additions and 4 deletions
+3 -2
View File
@@ -1026,8 +1026,9 @@ BFont::GetHeight(font_height *_height) const
|| code != SERVER_TRUE)
return;
// who put that "const" to this method? :-)
link.Read<font_height>(const_cast<font_height *>(&fHeight));
// Who put that "const" to this method? :-)
// We made fHeight mutable for this, but we should drop the "const" when we can
link.Read<font_height>(&fHeight);
}
*_height = fHeight;