summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2011-04-28 21:29:30 (GMT)
committerRemko Tronçon <git@el-tramo.be>2011-04-28 21:29:30 (GMT)
commitc1be1e5e41225929bc79ca9364c0de57da4f586e (patch)
treea406cdcef0072eb279c71b7023e93a53ae6f29a0 /Swift/QtUI/QtChatTabs.cpp
parent478d09da8c5c94cfa13a274a3b26e51601f4405d (diff)
downloadswift-contrib-c1be1e5e41225929bc79ca9364c0de57da4f586e.zip
swift-contrib-c1be1e5e41225929bc79ca9364c0de57da4f586e.tar.bz2
Temporarily reverting widget hiding patch.
It is causing some strange side effects.
Diffstat (limited to 'Swift/QtUI/QtChatTabs.cpp')
-rw-r--r--Swift/QtUI/QtChatTabs.cpp26
1 files changed, 0 insertions, 26 deletions
diff --git a/Swift/QtUI/QtChatTabs.cpp b/Swift/QtUI/QtChatTabs.cpp
index 9063001..249080b 100644
--- a/Swift/QtUI/QtChatTabs.cpp
+++ b/Swift/QtUI/QtChatTabs.cpp
@@ -39,8 +39,6 @@ QtChatTabs::QtChatTabs() : QWidget() {
#else
#warning Qt 4.5 or later is needed. Trying anyway, some things will be disabled.
#endif
- connect(tabs_, SIGNAL(currentChanged(int)), this, SLOT(handleTabChange(int)), Qt::UniqueConnection);
-
QVBoxLayout *layout = new QVBoxLayout;
layout->setSpacing(0);
layout->setContentsMargins(0, 3, 0, 0);
@@ -66,13 +64,6 @@ void QtChatTabs::addTab(QtTabbable* tab) {
QSizePolicy policy = sizePolicy();
/* Chat windows like to grow - don't let them */
setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);
-
- /* Hide previous opened QtChatWindow, so it doesn't receive further QPaint events. */
- QWidget* old = tabs_->currentWidget();
- if (old) {
- old->hide();
- }
-
tabs_->addTab(tab, tab->windowTitle());
connect(tab, SIGNAL(titleUpdated()), this, SLOT(handleTabTitleUpdated()), Qt::UniqueConnection);
connect(tab, SIGNAL(countUpdated()), this, SLOT(handleTabTitleUpdated()), Qt::UniqueConnection);
@@ -261,11 +252,6 @@ void QtChatTabs::handleTabTitleUpdated(QWidget* widget) {
std::string current(Q2PSTRING(qobject_cast<QtTabbable*>(tabs_->currentWidget())->windowTitle()));
ChatMessageSummarizer summary;
setWindowTitle(summary.getSummary(current, unreads).c_str());
-
- /* hide() QtChatWindow again, so it won't receive Paint events. */
- if (widget != tabs_->currentWidget()) {
- widget->hide();
- }
}
void QtChatTabs::flash() {
@@ -274,18 +260,6 @@ void QtChatTabs::flash() {
#endif
}
-void QtChatTabs::handleTabChange(int index) {
- if (index == -1) {
- return;
- }
- /* hide() old tab, show() new tab */
- QWidget* old_tab = tabs_->currentWidget();
- old_tab->hide();
-
- QWidget* new_tab = tabs_->widget(index);
- new_tab->show();
-}
-
void QtChatTabs::resizeEvent(QResizeEvent*) {
emit geometryChanged();
}