diff --git a/source/Irrlicht/CGUIFont.cpp b/source/Irrlicht/CGUIFont.cpp index 08579244..0fa82981 100644 --- a/source/Irrlicht/CGUIFont.cpp +++ b/source/Irrlicht/CGUIFont.cpp @@ -203,17 +203,15 @@ void CGUIFont::setMaxHeight() return; MaxHeight = 0; - s32 t; core::array< core::rect >& p = SpriteBank->getPositions(); for (u32 i=0; iMaxHeight) MaxHeight = t; } - } void CGUIFont::pushTextureCreationFlags(bool(&flags)[3]) diff --git a/source/Irrlicht/CGUITreeView.cpp b/source/Irrlicht/CGUITreeView.cpp index 2614cadc..b348a791 100644 --- a/source/Irrlicht/CGUITreeView.cpp +++ b/source/Irrlicht/CGUITreeView.cpp @@ -754,10 +754,7 @@ bool CGUITreeView::OnEvent( const SEvent &event ) void CGUITreeView::mouseAction( s32 xpos, s32 ypos, bool onlyHover /*= false*/ ) { IGUITreeViewNode* oldSelected = Selected; - IGUITreeViewNode* hitNode = 0; s32 selIdx=-1; - s32 n; - IGUITreeViewNode* node; SEvent event; event.EventType = EET_GUI_EVENT; @@ -774,9 +771,9 @@ void CGUITreeView::mouseAction( s32 xpos, s32 ypos, bool onlyHover /*= false*/ ) selIdx = ( ( ypos - 1 ) + scrollBarVPos ) / ItemHeight; } - hitNode = 0; - node = Root->getFirstChild(); - n = 0; + IGUITreeViewNode* hitNode = 0; + IGUITreeViewNode* node = Root->getFirstChild(); + s32 n = 0; while( node ) { if( selIdx == n ) @@ -1024,7 +1021,7 @@ void CGUITreeView::draw() iconWidth += ImageList->getImageSize().Width + 3; textRect.UpperLeftCorner.X += ImageList->getImageSize().Width + 3; } - else if( ( IconFont && reinterpret_cast( node )->Icon.size() ) + else if( ( IconFont && static_cast( node )->Icon.size() ) && ( ( ImageLeftOfIcon && n == 1 ) || ( !ImageLeftOfIcon && n == 0 ) ) ) {