diff options
Diffstat (limited to 'src/frontend/searchdialog/cmoduleresultview.h')
-rw-r--r-- | src/frontend/searchdialog/cmoduleresultview.h | 186 |
1 files changed, 94 insertions, 92 deletions
diff --git a/src/frontend/searchdialog/cmoduleresultview.h b/src/frontend/searchdialog/cmoduleresultview.h index c23d254..4295f82 100644 --- a/src/frontend/searchdialog/cmoduleresultview.h +++ b/src/frontend/searchdialog/cmoduleresultview.h @@ -36,98 +36,100 @@ namespace Search { class CModuleResultView : public QTreeWidget { - Q_OBJECT -public: - CModuleResultView(QWidget* parent); - ~CModuleResultView(); - - /** - * Setups the tree using the given list of modules. - */ - void setupTree( QList<CSwordModuleInfo*> modules, const QString& searchedText ); - /** - * Returns the currently active module. - */ - CSwordModuleInfo* activeModule(); - - virtual QSize sizeHint() {return m_size;} - -protected: - /** - * Initializes this widget. - */ - void initView(); - /** - * Initializes the connections of this widget - */ - void initConnections(); - - - void setupStrongsResults(CSwordModuleInfo* module, QTreeWidgetItem* parent, const QString& searchedText); - -protected slots: - /** - * Is executed when an item was selected in the list. - */ - void executed(QTreeWidgetItem*, QTreeWidgetItem*); - /** - * Copies the whole search result with the text into the clipboard. - */ - void copyResultWithText(); - /** - * Copies the whole search result into the clipboard. - */ - void copyResult(); - /** - * This event handler (reimplemented from QWidget) opens the popup menu at the given position. - */ - void contextMenuEvent( QContextMenuEvent * event ); - /** - * Appends the whole search result to the printer queue. - */ - void printResult(); - /** - * Saves the search result with it's text. - */ - void saveResultWithText(); - /** - * Saves the search result keys. - */ - void saveResult(); - -signals: - void moduleSelected(CSwordModuleInfo*); - void moduleChanged(); - void strongsSelected(CSwordModuleInfo*, QStringList*); - -private: - struct { - QMenu* saveMenu; - struct { - QAction* result; - QAction* resultWithText; - } - save; - - QMenu* printMenu; - struct { - QAction* result; - } - print; - - QMenu* copyMenu; - struct { - QAction* result; - QAction* resultWithText; - } - copy; - - } m_actions; - - QMenu* m_popup; - - StrongsResultClass* strongsResults; - QSize m_size; + Q_OBJECT + public: + CModuleResultView(QWidget* parent); + ~CModuleResultView(); + + /** + * Setups the tree using the given list of modules. + */ + void setupTree( QList<CSwordModuleInfo*> modules, const QString& searchedText ); + /** + * Returns the currently active module. + */ + CSwordModuleInfo* activeModule(); + + virtual QSize sizeHint() { + return m_size; + } + + protected: + /** + * Initializes this widget. + */ + void initView(); + /** + * Initializes the connections of this widget + */ + void initConnections(); + + + void setupStrongsResults(CSwordModuleInfo* module, QTreeWidgetItem* parent, const QString& searchedText); + + protected slots: + /** + * Is executed when an item was selected in the list. + */ + void executed(QTreeWidgetItem*, QTreeWidgetItem*); + /** + * Copies the whole search result with the text into the clipboard. + */ + void copyResultWithText(); + /** + * Copies the whole search result into the clipboard. + */ + void copyResult(); + /** + * This event handler (reimplemented from QWidget) opens the popup menu at the given position. + */ + void contextMenuEvent( QContextMenuEvent * event ); + /** + * Appends the whole search result to the printer queue. + */ + void printResult(); + /** + * Saves the search result with it's text. + */ + void saveResultWithText(); + /** + * Saves the search result keys. + */ + void saveResult(); + + signals: + void moduleSelected(CSwordModuleInfo*); + void moduleChanged(); + void strongsSelected(CSwordModuleInfo*, QStringList*); + + private: + struct { + QMenu* saveMenu; + struct { + QAction* result; + QAction* resultWithText; + } + save; + + QMenu* printMenu; + struct { + QAction* result; + } + print; + + QMenu* copyMenu; + struct { + QAction* result; + QAction* resultWithText; + } + copy; + + } m_actions; + + QMenu* m_popup; + + StrongsResultClass* strongsResults; + QSize m_size; }; |