From 84ef3e9fda248031f936502d06bad92c4dac3ebf Mon Sep 17 00:00:00 2001 From: "S. Razi Alavizadeh" Date: Tue, 25 Feb 2014 22:06:13 +0330 Subject: [PATCH] Fixed, renamed QupZilla class to BrowserWindow everywhere --- src/lib/app/browserwindow.cpp | 14 +++++++------- src/lib/app/mainapplication.cpp | 2 +- src/lib/other/macmenureceiver.cpp | 4 +--- 3 files changed, 9 insertions(+), 11 deletions(-) diff --git a/src/lib/app/browserwindow.cpp b/src/lib/app/browserwindow.cpp index e586e014b..7930ea512 100644 --- a/src/lib/app/browserwindow.cpp +++ b/src/lib/app/browserwindow.cpp @@ -722,7 +722,7 @@ QKeySequence BrowserWindow::actionShortcut(QKeySequence shortcut, QKeySequence f } #ifdef Q_OS_MAC -void QupZilla::setupMacMenu() +void BrowserWindow::setupMacMenu() { // menus m_menuFile = menuBar()->actions().at(0)->menu(); @@ -760,7 +760,7 @@ void QupZilla::setupMacMenu() m_actionPrivateBrowsing = m_menuTools->actions().at(9); } -void QupZilla::refreshStateOfAllActions() +void BrowserWindow::refreshStateOfAllActions() { mApp->macMenuReceiver()->aboutToShowFileMenu(m_menuFile); mApp->macMenuReceiver()->aboutToShowHistoryMenu(m_menuHistory); @@ -2351,10 +2351,10 @@ void BrowserWindow::moveToVirtualDesktop(int desktopId) #ifdef Q_OS_WIN #if (QT_VERSION < 0x050000) -bool QupZilla::winEvent(MSG* message, long* result) +bool BrowserWindow::winEvent(MSG* message, long* result) { #else -bool QupZilla::nativeEvent(const QByteArray &eventType, void* _message, long* result) +bool BrowserWindow::nativeEvent(const QByteArray &eventType, void* _message, long* result) { Q_UNUSED(eventType) MSG* message = static_cast(_message); @@ -2406,7 +2406,7 @@ bool QupZilla::nativeEvent(const QByteArray &eventType, void* _message, long* re #endif } -void QupZilla::paintEvent(QPaintEvent* event) +void BrowserWindow::paintEvent(QPaintEvent* event) { if (isTransparentBackgroundAllowed()) { QPainter p(this); @@ -2417,7 +2417,7 @@ void QupZilla::paintEvent(QPaintEvent* event) QMainWindow::paintEvent(event); } -void QupZilla::applyBlurToMainWindow(bool force) +void BrowserWindow::applyBlurToMainWindow(bool force) { if (isClosing() || m_isStarting) { return; @@ -2462,7 +2462,7 @@ void QupZilla::applyBlurToMainWindow(bool force) QtWin::extendFrameIntoClientArea(this, leftMargin, topMargin, rightMargin, bottomMargin); } -bool QupZilla::eventFilter(QObject* object, QEvent* event) +bool BrowserWindow::eventFilter(QObject* object, QEvent* event) { switch (event->type()) { case QEvent::Hide: diff --git a/src/lib/app/mainapplication.cpp b/src/lib/app/mainapplication.cpp index 81f60411f..33fbd3f7d 100644 --- a/src/lib/app/mainapplication.cpp +++ b/src/lib/app/mainapplication.cpp @@ -1269,7 +1269,7 @@ bool MainApplication::restoreStateSlot(BrowserWindow* window, RestoreData recove foreach (const RestoreManager::WindowData &data, recoveryData) { BrowserWindow* window = makeNewWindow(Qz::BW_OtherRestoredWindow); window->restoreWindowState(data); - // for correct geometry calculation in QupZilla::setupUi() + // for correct geometry calculation in BrowserWindow::setupUi() mApp->processEvents(); } diff --git a/src/lib/other/macmenureceiver.cpp b/src/lib/other/macmenureceiver.cpp index e4c8ae6c2..e8f64bec7 100644 --- a/src/lib/other/macmenureceiver.cpp +++ b/src/lib/other/macmenureceiver.cpp @@ -76,8 +76,6 @@ void MacMenuReceiver::setDisabledSelectedMenuActions(QMenu* menu, const QListgetWindow(); if (!qzWindow) { if (!makeIfNoWindow) { @@ -92,7 +90,7 @@ bool MacMenuReceiver::callSlot(const char* member, bool makeIfNoWindow, QGeneric bool success = QMetaObject::invokeMethod(qzWindow, member, val0, val1); if (!success) { - qCritical("Warning: try to invoke \'QupZilla::%s()\' with incorrect parameter(s) or no such slot.", member); + qCritical("Warning: try to invoke \'BrowserWindow::%s()\' with incorrect parameter(s) or no such slot.", member); // this should never happen, for now: // we just ignore it! }