[Igarden-commit] Garden/source/PlanTool ActiveMaterial.cpp, 1.45.2.4, 1.45.2.5
Status: Beta
Brought to you by:
jlbedell
|
From: Jeffrey B. <jlb...@us...> - 2006-11-29 12:31:38
|
Update of /cvsroot/igarden/Garden/source/PlanTool In directory sc8-pr-cvs2.sourceforge.net:/tmp/cvs-serv17668 Modified Files: Tag: Release_branch_v1 ActiveMaterial.cpp Log Message: Correct problem where ActiveMaterial palette doesn't clear when changed to a type which has no elements Index: ActiveMaterial.cpp =================================================================== RCS file: /cvsroot/igarden/Garden/source/PlanTool/ActiveMaterial.cpp,v retrieving revision 1.45.2.4 retrieving revision 1.45.2.5 diff -C2 -d -r1.45.2.4 -r1.45.2.5 *** ActiveMaterial.cpp 26 Nov 2006 01:25:40 -0000 1.45.2.4 --- ActiveMaterial.cpp 29 Nov 2006 12:31:36 -0000 1.45.2.5 *************** *** 58,62 **** const long kMaterialNameText = 102; const long kMaterialImage = 104; ! const long kMaterialErrText = 102; const long kPaletteSelectMenu = 106; const long kCategorySelectMenu = 107; --- 58,62 ---- const long kMaterialNameText = 102; const long kMaterialImage = 104; ! const long kMaterialErrText = 105; const long kPaletteSelectMenu = 106; const long kCategorySelectMenu = 107; *************** *** 385,389 **** --- 385,391 ---- if(_drawing->SetMaterial(material, ptr, _topDocument)) { + _message->HideView(); _drawing->Activate(); + _drawing->ShowView(); _image->HideView(); } *************** *** 410,413 **** --- 412,416 ---- } _drawing->Deactivate(); + _drawing->HideView(); if(_image->SetSource(fileSpec) == noErr) { *************** *** 590,599 **** _categoryPopup->Insert(i,palette->GetName().c_str(), rebuildMenu); } ! return DoPopValue(kCategorySelectMenu, NULL); } UpdateMaterialPaletteMenu(); if(GetNumMaterials() > 0) PickMaterial(0); ! result = 0; break; --- 593,615 ---- _categoryPopup->Insert(i,palette->GetName().c_str(), rebuildMenu); } ! _categoryPopup->UpdateView(); ! _categoryPopup->SetValue(_paletteIndex); } UpdateMaterialPaletteMenu(); if(GetNumMaterials() > 0) PickMaterial(0); ! else ! { ! DisplayName(""); ! _message->SetTitle("Nothing Loaded"); ! _message->ShowView(); ! _message->EnableView(); ! _drawing->HideView(); ! _drawing->Deactivate(); ! _image->ShowView(); ! _image->ClearSource(); ! _image->InvalView(); ! } ! result = 0; break; |