SearchingWidget.cpp
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #include "Qt.h"
00024 #include "SearchingWidget.h"
00025
00026 using UIs::Searching::SearchingWidget;
00027
00028 SearchingWidget::SearchingWidget (QWidget * parent) : QTabWidget (parent)
00029 {
00030 QToolButton *searchCloseButton = new QToolButton(this);
00031 searchCloseButton->setAutoRaise(true);
00032 searchCloseButton->setIcon(QIcon("Icons/closetab.png"));
00033 setCornerWidget(searchCloseButton);
00034
00035 connect (searchCloseButton, SIGNAL (clicked()),
00036 this, SLOT (closeTabButtonPressed()));
00037 }
00038
00039 SearchingWidget::~SearchingWidget()
00040 {
00041
00042 }
00043
00044 void SearchingWidget::closeTabButtonPressed()
00045 {
00046 int currenttab = currentIndex();
00047 if (currenttab != -1) {
00048
00049 emit (stopSearch());
00050 removeTab (currenttab);
00051 }
00053 }