Changeset 2127 for GTP/trunk/Lib/Geom/shared/GeoTool/src/GeoMeshViewUI.cpp
- Timestamp:
- 02/19/07 09:16:59 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/Lib/Geom/shared/GeoTool/src/GeoMeshViewUI.cpp
r2103 r2127 653 653 -> 654 654 cb_menuRenderTextures_i(o,v); 655 } 656 657 //------------------------------------------------------------------------- 658 // Bounding Box callback 659 //------------------------------------------------------------------------- 660 inline void GeoMeshViewUI::cb_menuRenderBoundingBox_i(fltk::Item *item, 661 void *v) 662 { 663 // If the item is activated. 664 if (item->value()) 665 { 666 geoMeshView->activeBoundingBox(); 667 } 668 else 669 { 670 geoMeshView->deactiveBoundingBox(); 671 } 672 673 // Repaint the main window. 674 mMainWindow->redraw(); 675 } 676 677 void GeoMeshViewUI::cb_menuRenderBoundingBox(fltk::Item* o, void* v) 678 { 679 ((GeoMeshViewUI*) (o->parent()->parent()->parent()->user_data())) 680 -> 681 cb_menuRenderBoundingBox_i(o,v); 682 } 683 684 //------------------------------------------------------------------------- 685 // Axes callback 686 //------------------------------------------------------------------------- 687 inline void GeoMeshViewUI::cb_menuRenderAxes_i(fltk::Item *item, 688 void *v) 689 { 690 // If the item is activated. 691 if (item->value()) 692 { 693 geoMeshView->activeAxes(); 694 } 695 else 696 { 697 geoMeshView->deactiveAxes(); 698 } 699 700 // Repaint the main window. 701 mMainWindow->redraw(); 702 } 703 704 void GeoMeshViewUI::cb_menuRenderAxes(fltk::Item* o, void* v) 705 { 706 ((GeoMeshViewUI*) (o->parent()->parent()->parent()->user_data())) 707 -> 708 cb_menuRenderAxes_i(o,v); 655 709 } 656 710 … … 2468 2522 static char title[256]; 2469 2523 2470 fcho = new fltk::FileChooser("", "*.{mesh,obj}", fltk::FileChooser::CREATE, "Open a mesh"); 2524 fcho = new fltk::FileChooser("", 2525 "*.{mesh,obj}", 2526 fltk::FileChooser::CREATE, 2527 "Open a mesh"); 2471 2528 2472 2529 fcho->exec(); … … 2560 2617 } 2561 2618 } 2619 2562 2620 // Free memory. 2563 2621 delete fcho; … … 2993 3051 2994 3052 { 2995 fltk::Item* o = menuRenderTextures =new fltk::Item("Texture mapping");3053 fltk::Item* o = new fltk::Item("Texture mapping"); 2996 3054 o->type(fltk::Item::RADIO); 2997 3055 o->set_value(); 2998 3056 o->callback((fltk::Callback*)cb_menuRenderTextures); 3057 } 3058 3059 new fltk::Divider(); 3060 3061 { 3062 fltk::Item* o = new fltk::Item("Axis"); 3063 o->type(fltk::Item::RADIO); 3064 o->set_value(); 3065 o->callback((fltk::Callback*)cb_menuRenderAxes); 3066 } 3067 3068 { 3069 fltk::Item* o = new fltk::Item("Bounding Box"); 3070 o->type(fltk::Item::RADIO); 3071 o->set_value(); 3072 o->callback((fltk::Callback*)cb_menuRenderBoundingBox); 2999 3073 } 3000 3074 … … 3141 3215 GeoMeshViewUI::~GeoMeshViewUI() 3142 3216 { 3143 delete geoMeshLoader;3217 //delete geoMeshLoader; 3144 3218 mMainWindow->destroy(); 3145 3219 }
Note: See TracChangeset
for help on using the changeset viewer.