Made the calculation of the number of available style modules more robust

This commit is contained in:
Maxime Curioni
2009-04-08 20:19:20 +00:00
parent 997624c7dd
commit 8c8579d911

View File

@@ -227,6 +227,9 @@ extern "C" {
int displayed_layer_count( SceneRenderLayer* srl ) {
int count = 0;
if( panelConfig->layers.find(srl) == panelConfig->layers.end() )
return 0;
for( StyleModuleConf* module_conf = (StyleModuleConf *)panelConfig->modules[srl]->first; module_conf; module_conf = module_conf->next ) {
if( module_conf->is_displayed )