From 7690cc3519c160c9532b5c0f0b7640b87a344720 Mon Sep 17 00:00:00 2001
From: Tobias Markmann <tm@ayena.de>
Date: Wed, 14 Jan 2015 21:59:13 +0100
Subject: Fix --no-tabs mode broken

Trellis changes introduced a bug for the --no-tabs mode.

Test-Information:

Tested on Mac OS X 10.9.5.

Change-Id: Ic918a38cda00a64f8eca496ede0190fbef6b6602

diff --git a/Swift/QtUI/QtUIFactory.cpp b/Swift/QtUI/QtUIFactory.cpp
index df68ed6..2fac36a 100644
--- a/Swift/QtUI/QtUIFactory.cpp
+++ b/Swift/QtUI/QtUIFactory.cpp
@@ -82,7 +82,9 @@ FileTransferListWidget* QtUIFactory::createFileTransferListWidget() {
 
 MainWindow* QtUIFactory::createMainWindow(UIEventStream* eventStream) {
 	lastMainWindow  = new QtMainWindow(settings, eventStream, loginWindow->getMenus(), statusCache, emoticonsExist_, enableAdHocCommandOnJID_);
-	tabs->setViewMenu(lastMainWindow->getMenus()[0]);
+	if (tabs) {
+		tabs->setViewMenu(lastMainWindow->getMenus()[0]);
+	}
 	return lastMainWindow;
 }
 
-- 
cgit v0.10.2-6-g49f6