From 6ce25c6e5db5a90e272fb5ca1c665c65310c1b9f Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Tue, 8 Nov 2011 12:42:45 +0100 Subject: Remove postLaunch calls This will help a lot in having a clean/easy startup, also a bit less fast. Let's see if this helps stability... PS: To the bug reporter. I pushed a "NoPostLaunch" in rekonq git repo. Can you please try compiling and testing if this fixes your troubles on startup?? Many thanks for any help. Andrea. CCBUG:284356 --- src/mainview.cpp | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) (limited to 'src/mainview.cpp') diff --git a/src/mainview.cpp b/src/mainview.cpp index 2b5a8202..80457252 100644 --- a/src/mainview.cpp +++ b/src/mainview.cpp @@ -62,7 +62,6 @@ QString temporaryUglyHackString = ""; MainView::MainView(MainWindow *parent) : KTabWidget(parent) , m_widgetBar(new StackedUrlBar(this)) - , m_originalWidthHint(0) , m_addTabButton(0) , m_currentTabIndex(0) , m_parentWindow(parent) @@ -72,6 +71,7 @@ MainView::MainView(MainWindow *parent) m_addTabButton = new QToolButton(this); setTabBar(tabBar); + tabBar->show(); // set mouse tracking for tab previews setMouseTracking(true); @@ -96,12 +96,6 @@ MainView::MainView(MainWindow *parent) connect(this, SIGNAL(currentChanged(int)), this, SLOT(currentChanged(int))); connect(this, SIGNAL(currentChanged(int)), rApp->sessionManager(), SLOT(saveSession())); - QTimer::singleShot(0, this, SLOT(postLaunch())); -} - - -void MainView::postLaunch() -{ QList list = rApp->sessionManager()->closedSites(); Q_FOREACH(const TabHistory & tab, list) { @@ -110,12 +104,15 @@ void MainView::postLaunch() m_recentlyClosedTabs.removeAll(tab); m_recentlyClosedTabs.prepend(tab); } +} + +void MainView::addNewTabButton() +{ m_addTabButton->setDefaultAction(m_parentWindow->actionByName("new_tab")); m_addTabButton->setAutoRaise(true); m_addTabButton->setToolButtonStyle(Qt::ToolButtonIconOnly); - m_originalWidthHint = sizeHint().width(); } -- cgit v1.2.1