BALL
1.4.1
|
00001 // 00002 // -*- Mode: C++; tab-width: 2; -*- 00003 // vi: set ts=2: 00004 // 00005 00006 #ifndef BALL_VIEW_DIALOGS_DOCKRESULTDIALOG_H 00007 #define BALL_VIEW_DIALOGS_DOCKRESULTDIALOG_H 00008 00009 #ifndef BALL_COMMON_GLOBAL_H 00010 # include <BALL/COMMON/global.h> 00011 #endif 00012 00013 #ifndef BALL_WIDGETS_DOCKINGCONTROLLER_H 00014 # include <BALL/VIEW/WIDGETS/dockingController.h> 00015 #endif 00016 00017 #include <BALL/VIEW/UIC/ui_dockResultDialog.h> 00018 00019 namespace BALL 00020 { 00021 class DockResult; 00022 00023 namespace VIEW 00024 { 00028 class BALL_VIEW_EXPORT DockResultDialog : 00029 public QDialog, 00030 public Ui_DockResultDialogData 00031 { 00032 Q_OBJECT 00033 00034 public: 00035 00039 00046 DockResultDialog(QWidget* parent = 0, const char* name = "DockResultDialog"); 00047 00050 virtual ~DockResultDialog(); 00052 00056 00059 const DockResultDialog& operator =(const DockResultDialog& res_dialog); 00061 00065 00069 void setDockResult(DockResult* dock_res); 00070 00074 void setDockedSystem(System* system); 00075 00081 void addScoringFunction(const QString& name, DockingController::ScoringFunction score_func, QDialog* dialog=0); 00083 00084 public slots: 00085 00089 void show(); 00090 00094 void showSnapshot(); 00095 00100 void sortTable(int column); 00101 00105 void showDockingOptions(); 00106 00110 void upwardClicked(); 00111 00115 void downwardClicked(); 00116 00121 void scoringFuncChosen(); 00122 00126 void advancedClicked(); 00127 00132 void scoringClicked(); 00133 00137 void closeClicked(); 00138 00139 00140 protected slots: 00141 00142 void selectionChanged_(); 00143 00147 void deleteColumn_(); 00148 00153 void showScoringOptions_(); 00154 00159 void redock_(); 00160 00161 00162 protected: 00163 00169 class Compare_ 00170 { 00171 public: 00172 00175 Compare_(); 00176 00179 Compare_(Position index); 00180 00183 ~Compare_(); 00184 00187 bool operator() (const vector<float>& a, const vector<float>& b) const; 00188 00191 Position index_; 00192 }; 00193 00194 private: 00195 00200 DockResultDialog(const DockResultDialog& dock_res_dialog); 00201 00205 DockResult* dock_res_; 00206 00209 System* docked_system_; 00210 00213 System* redock_partner1_, * redock_partner2_; 00214 00217 HashMap<int, QDialog*> scoring_dialogs_; 00218 }; 00219 00220 } } // Namespaces 00221 #endif