Fix #35393: Sculpt Shortcuts are bananas.

Issue was introduced by self in svn rev56815.
Brushes list was simply not fully traversing
due to mistake in termination condition.
This commit is contained in:
Sergey Sharybin
2013-05-17 11:08:50 +00:00
parent 79fc2ac845
commit a4e9edb674

View File

@@ -271,16 +271,16 @@ static Brush *brush_tool_cycle(Main *bmain, Brush *brush_orig, const int tool, c
}
/* get the next brush with the active tool */
for (brush = first_brush;
brush != brush_orig;
brush = brush->id.next ? brush->id.next : bmain->brush.first)
{
brush = first_brush;
do {
if ((brush->ob_mode & ob_mode) &&
(brush_tool(brush, tool_offset) == tool))
{
return brush;
}
}
brush = brush->id.next ? brush->id.next : bmain->brush.first;
} while (brush != first_brush);
return NULL;
}