From 9a02397822d7ef3dea95bc8821f14fb35d201b7b Mon Sep 17 00:00:00 2001
From: Kevin Smith <git@kismith.co.uk>
Date: Tue, 15 Sep 2009 22:49:41 +0100
Subject: Bring the tabs to front when a tabbed widget requests activation.


diff --git a/Swift/QtUI/QtChatTabs.cpp b/Swift/QtUI/QtChatTabs.cpp
index 8e6bea2..3d66e0a 100644
--- a/Swift/QtUI/QtChatTabs.cpp
+++ b/Swift/QtUI/QtChatTabs.cpp
@@ -57,8 +57,10 @@ void QtChatTabs::handleWantsToActivate() {
 	Q_ASSERT(widget);
 	Q_ASSERT(tabs_->indexOf(widget) >= 0);
 	//Un-minimize and bring to front.
-	setWindowState((windowState() & ~Qt::WindowMinimized) | Qt::WindowActive);
+	setWindowState(windowState() & ~Qt::WindowMinimized);
+	setWindowState(windowState() | Qt::WindowActive);
 	tabs_->setCurrentWidget(widget);
+	activateWindow();
 }
 
 void QtChatTabs::handleTabClosing() {
-- 
cgit v0.10.2-6-g49f6