edit_styles_dlg_.cpp
上传用户:yhdzpy8989
上传日期:2007-06-13
资源大小:13604k
文件大小:3k
源码类别:

生物技术

开发平台:

C/C++

  1. /*
  2.  * ===========================================================================
  3.  * PRODUCTION $Log: edit_styles_dlg_.cpp,v $
  4.  * PRODUCTION Revision 1000.1  2004/06/01 20:45:42  gouriano
  5.  * PRODUCTION PRODUCTION: UPGRADED [GCC34_MSVC7] Dev-tree R1.5
  6.  * PRODUCTION
  7.  * ===========================================================================
  8.  */
  9. // generated by Fast Light User Interface Designer (fluid) version 1.0105
  10. /* $Id: edit_styles_dlg_.cpp,v 1000.1 2004/06/01 20:45:42 gouriano Exp $ */
  11. #include <ncbi_pch.hpp>
  12. inline void CEditStylesDlg::cb_m_StyleBrowser_i(Fl_Browser*, void*) {
  13.   x_UpdateSetBtns();
  14. }
  15. void CEditStylesDlg::cb_m_StyleBrowser(Fl_Browser* o, void* v) {
  16.   ((CEditStylesDlg*)(o->parent()->user_data()))->cb_m_StyleBrowser_i(o,v);
  17. }
  18. inline void CEditStylesDlg::cb_Add_i(Fl_Button*, void*) {
  19.   x_OnAdd();
  20. }
  21. void CEditStylesDlg::cb_Add(Fl_Button* o, void* v) {
  22.   ((CEditStylesDlg*)(o->parent()->parent()->user_data()))->cb_Add_i(o,v);
  23. }
  24. inline void CEditStylesDlg::cb_Copy_i(Fl_Button*, void*) {
  25.   x_OnCopy();
  26. }
  27. void CEditStylesDlg::cb_Copy(Fl_Button* o, void* v) {
  28.   ((CEditStylesDlg*)(o->parent()->parent()->user_data()))->cb_Copy_i(o,v);
  29. }
  30. inline void CEditStylesDlg::cb_m_RenameBtn_i(Fl_Button*, void*) {
  31.   x_OnRename();
  32. }
  33. void CEditStylesDlg::cb_m_RenameBtn(Fl_Button* o, void* v) {
  34.   ((CEditStylesDlg*)(o->parent()->parent()->user_data()))->cb_m_RenameBtn_i(o,v);
  35. }
  36. inline void CEditStylesDlg::cb_m_DeleteBtn_i(Fl_Button*, void*) {
  37.   x_OnDelete();
  38. }
  39. void CEditStylesDlg::cb_m_DeleteBtn(Fl_Button* o, void* v) {
  40.   ((CEditStylesDlg*)(o->parent()->parent()->user_data()))->cb_m_DeleteBtn_i(o,v);
  41. }
  42. inline void CEditStylesDlg::cb_Done_i(Fl_Return_Button*, void*) {
  43.   x_OnOK();
  44. }
  45. void CEditStylesDlg::cb_Done(Fl_Return_Button* o, void* v) {
  46.   ((CEditStylesDlg*)(o->parent()->parent()->user_data()))->cb_Done_i(o,v);
  47. }
  48. Fl_Window* CEditStylesDlg::x_CreateWindow() {
  49.   Fl_Window* w;
  50.   { Fl_Window* o = new Fl_Window(245, 310, "Preferences");
  51.     w = o;
  52.     o->user_data((void*)(this));
  53.     new Fl_Box(10, 5, 225, 25, "Saved Styles");
  54.     { Fl_Browser* o = m_StyleBrowser = new Fl_Browser(10, 35, 150, 265);
  55.       o->type(2);
  56.       o->callback((Fl_Callback*)cb_m_StyleBrowser);
  57.       o->align(FL_ALIGN_TOP);
  58.       Fl_Group::current()->resizable(o);
  59.     }
  60.     { Fl_Group* o = m_SetBtnGroup = new Fl_Group(165, 35, 70, 265, "set buttons");
  61.       o->labeltype(FL_NO_LABEL);
  62.       { Fl_Button* o = new Fl_Button(165, 35, 70, 25, "Add");
  63.         o->callback((Fl_Callback*)cb_Add);
  64.       }
  65.       { Fl_Button* o = new Fl_Button(165, 65, 70, 25, "Copy");
  66.         o->callback((Fl_Callback*)cb_Copy);
  67.       }
  68.       { Fl_Button* o = m_RenameBtn = new Fl_Button(165, 95, 70, 25, "Rename");
  69.         o->callback((Fl_Callback*)cb_m_RenameBtn);
  70.       }
  71.       { Fl_Button* o = m_DeleteBtn = new Fl_Button(165, 125, 70, 25, "Delete");
  72.         o->callback((Fl_Callback*)cb_m_DeleteBtn);
  73.       }
  74.       { Fl_Box* o = new Fl_Box(165, 155, 70, 79, "resizable");
  75.         o->labeltype(FL_NO_LABEL);
  76.         o->hide();
  77.         o->deactivate();
  78.         Fl_Group::current()->resizable(o);
  79.       }
  80.       { Fl_Return_Button* o = new Fl_Return_Button(165, 275, 70, 25, "Done");
  81.         o->callback((Fl_Callback*)cb_Done);
  82.       }
  83.       o->end();
  84.     }
  85.     o->set_modal();
  86.     o->end();
  87.   }
  88.   return w;
  89. }