Changeset 561 for trunk/demos/browser/tabwidget.cpp
- Timestamp:
- Feb 11, 2010, 11:19:06 PM (15 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
-
Property svn:mergeinfo
set to (toggle deleted branches)
/branches/vendor/nokia/qt/4.6.1 merged eligible /branches/vendor/nokia/qt/current merged eligible /branches/vendor/trolltech/qt/current 3-149
-
Property svn:mergeinfo
set to (toggle deleted branches)
-
trunk/demos/browser/tabwidget.cpp
r2 r561 2 2 ** 3 3 ** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). 4 ** Contact: Qt Software Information (qt-info@nokia.com) 4 ** All rights reserved. 5 ** Contact: Nokia Corporation (qt-info@nokia.com) 5 6 ** 6 7 ** This file is part of the demonstration applications of the Qt Toolkit. … … 21 22 ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. 22 23 ** 23 ** In addition, as a special exception, Nokia gives you certain 24 ** additional rights. These rights are described in the Nokia Qt LGPL 25 ** Exception version 1.0, included in the file LGPL_EXCEPTION.txt in this 26 ** package. 24 ** In addition, as a special exception, Nokia gives you certain additional 25 ** rights. These rights are described in the Nokia Qt LGPL Exception 26 ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. 27 27 ** 28 28 ** GNU General Public License Usage … … 34 34 ** met: http://www.gnu.org/copyleft/gpl.html. 35 35 ** 36 ** If you are unsure which license is appropriate for your use, please37 ** contact the sales department at qt-sales@nokia.com.36 ** If you have questions regarding the use of this file, please contact 37 ** Nokia at qt-info@nokia.com. 38 38 ** $QT_END_LICENSE$ 39 39 ** … … 65 65 setContextMenuPolicy(Qt::CustomContextMenu); 66 66 setAcceptDrops(true); 67 connect(this, SIGNAL(customContextMenuRequested( const QPoint &)),68 this, SLOT(contextMenuRequested( const QPoint &)));67 connect(this, SIGNAL(customContextMenuRequested(QPoint)), 68 this, SLOT(contextMenuRequested(QPoint))); 69 69 70 70 QString alt = QLatin1String("Alt+%1"); … … 222 222 connect(m_tabBar, SIGNAL(reloadTab(int)), this, SLOT(reloadTab(int))); 223 223 connect(m_tabBar, SIGNAL(reloadAllTabs()), this, SLOT(reloadAllTabs())); 224 connect(m_tabBar, SIGNAL(tabMoved(int, int)), this, SLOT(moveTab(int,int)));224 connect(m_tabBar, SIGNAL(tabMoved(int,int)), this, SLOT(moveTab(int,int))); 225 225 setTabBar(m_tabBar); 226 226 setDocumentMode(true); … … 258 258 connect(m_recentlyClosedTabsMenu, SIGNAL(aboutToShow()), 259 259 this, SLOT(aboutToShowRecentTabsMenu())); 260 connect(m_recentlyClosedTabsMenu, SIGNAL(triggered(QAction 261 this, SLOT(aboutToShowRecentTriggeredAction(QAction 260 connect(m_recentlyClosedTabsMenu, SIGNAL(triggered(QAction*)), 261 this, SLOT(aboutToShowRecentTriggeredAction(QAction*))); 262 262 m_recentlyClosedTabsAction = new QAction(tr("Recently Closed Tabs"), this); 263 263 m_recentlyClosedTabsAction->setMenu(m_recentlyClosedTabsMenu); … … 305 305 WebView *oldWebView = this->webView(m_lineEdits->currentIndex()); 306 306 if (oldWebView) { 307 disconnect(oldWebView, SIGNAL(statusBarMessage( const QString&)),308 this, SIGNAL(showStatusBarMessage( const QString&)));309 disconnect(oldWebView->page(), SIGNAL(linkHovered( const QString&, const QString&, const QString&)),310 this, SIGNAL(linkHovered( const QString&)));307 disconnect(oldWebView, SIGNAL(statusBarMessage(QString)), 308 this, SIGNAL(showStatusBarMessage(QString))); 309 disconnect(oldWebView->page(), SIGNAL(linkHovered(QString,QString,QString)), 310 this, SIGNAL(linkHovered(QString))); 311 311 disconnect(oldWebView, SIGNAL(loadProgress(int)), 312 312 this, SIGNAL(loadProgress(int))); 313 313 } 314 314 315 connect(webView, SIGNAL(statusBarMessage( const QString&)),316 this, SIGNAL(showStatusBarMessage( const QString&)));317 connect(webView->page(), SIGNAL(linkHovered( const QString&, const QString&, const QString&)),318 this, SIGNAL(linkHovered( const QString&)));315 connect(webView, SIGNAL(statusBarMessage(QString)), 316 this, SIGNAL(showStatusBarMessage(QString))); 317 connect(webView->page(), SIGNAL(linkHovered(QString,QString,QString)), 318 this, SIGNAL(linkHovered(QString))); 319 319 connect(webView, SIGNAL(loadProgress(int)), 320 320 this, SIGNAL(loadProgress(int))); … … 451 451 connect(webView, SIGNAL(iconChanged()), 452 452 this, SLOT(webViewIconChanged())); 453 connect(webView, SIGNAL(titleChanged( const QString &)),454 this, SLOT(webViewTitleChanged( const QString &)));455 connect(webView, SIGNAL(urlChanged( const QUrl &)),456 this, SLOT(webViewUrlChanged( const QUrl &)));453 connect(webView, SIGNAL(titleChanged(QString)), 454 this, SLOT(webViewTitleChanged(QString))); 455 connect(webView, SIGNAL(urlChanged(QUrl)), 456 this, SLOT(webViewUrlChanged(QUrl))); 457 457 connect(webView->page(), SIGNAL(windowCloseRequested()), 458 458 this, SLOT(windowCloseRequested())); 459 connect(webView->page(), SIGNAL(geometryChangeRequested( const QRect &)),460 this, SIGNAL(geometryChangeRequested( const QRect &)));461 connect(webView->page(), SIGNAL(printRequested(QWebFrame 462 this, SIGNAL(printRequested(QWebFrame 459 connect(webView->page(), SIGNAL(geometryChangeRequested(QRect)), 460 this, SIGNAL(geometryChangeRequested(QRect))); 461 connect(webView->page(), SIGNAL(printRequested(QWebFrame*)), 462 this, SIGNAL(printRequested(QWebFrame*))); 463 463 connect(webView->page(), SIGNAL(menuBarVisibilityChangeRequested(bool)), 464 464 this, SIGNAL(menuBarVisibilityChangeRequested(bool))); … … 561 561 hasFocus = tab->hasFocus(); 562 562 563 m_recentlyClosedTabsAction->setEnabled(true); 564 m_recentlyClosedTabs.prepend(tab->url()); 565 if (m_recentlyClosedTabs.size() >= TabWidget::m_recentlyClosedTabsSize) 566 m_recentlyClosedTabs.removeLast(); 563 QWebSettings *globalSettings = QWebSettings::globalSettings(); 564 if (!globalSettings->testAttribute(QWebSettings::PrivateBrowsingEnabled)) { 565 m_recentlyClosedTabsAction->setEnabled(true); 566 m_recentlyClosedTabs.prepend(tab->url()); 567 if (m_recentlyClosedTabs.size() >= TabWidget::m_recentlyClosedTabsSize) 568 m_recentlyClosedTabs.removeLast(); 569 } 567 570 } 568 571 QWidget *lineEdit = m_lineEdits->widget(index); … … 762 765 return; 763 766 connect(m_root, SIGNAL(triggered()), this, SLOT(rootTriggered())); 764 connect(root, SIGNAL(destroyed(QObject 767 connect(root, SIGNAL(destroyed(QObject*)), this, SLOT(rootDestroyed())); 765 768 root->setEnabled(false); 766 769 } … … 811 814 { 812 815 if (m_currentParent) 813 disconnect(m_currentParent, SIGNAL(destroyed(QObject 816 disconnect(m_currentParent, SIGNAL(destroyed(QObject*)), 814 817 this, SLOT(currentDestroyed())); 815 818 … … 825 828 m_root->setChecked(source->isChecked()); 826 829 m_root->setEnabled(source->isEnabled()); 827 connect(m_currentParent, SIGNAL(destroyed(QObject 830 connect(m_currentParent, SIGNAL(destroyed(QObject*)), 828 831 this, SLOT(currentDestroyed())); 829 832 }
Note:
See TracChangeset
for help on using the changeset viewer.