Changeset 75467 in webkit


Ignore:
Timestamp:
Jan 10, 2011 6:50:44 PM (13 years ago)
Author:
Laszlo Gombos
Message:

2011-01-10 Laszlo Gombos <Laszlo Gombos>

Reviewed by Csaba Osztrogonác.

[Qt] Baseline qt_minimal configuration
https://bugs.webkit.org/show_bug.cgi?id=51313

  • WebKit.pri: List the supported QT_NO_FEATURE flags under qt_minimal configuration.

2011-01-10 Laszlo Gombos <Laszlo Gombos>

Reviewed by Csaba Osztrogonác.

[Qt] Baseline qt_minimal configuration
https://bugs.webkit.org/show_bug.cgi?id=51313

No new tests as there is no new functionality.

  • platform/graphics/qt/GraphicsLayerQt.cpp: Fix the location of the QT_NO_ANIMATION guard.
  • platform/qt/WheelEventQt.cpp: (WebCore::PlatformWheelEvent::applyDelta): Fix the location of the QT_NO_WHEELEVENT guard.

2011-01-10 Laszlo Gombos <Laszlo Gombos>

Reviewed by Csaba Osztrogonác.

[Qt] Baseline qt_minimal configuration
https://bugs.webkit.org/show_bug.cgi?id=51313

  • DumpRenderTree/qt/DumpRenderTreeQt.cpp: (WebCore::DumpRenderTree::resetToConsistentStateBeforeTesting): Add QT_NO_UNDOSTACK guard.
  • QtTestBrowser/launcherwindow.cpp: (LauncherWindow::createChrome): Add QT_NO_SHORTCUT and QT_NO_PRINTER guards. (LauncherWindow::applyZoom): Add QT_NO_ANIMATION guard. (LauncherWindow::screenshot): Add QT_NO_FILEDIALOG guard. (LauncherWindow::selectElements): Add QT_NO_INPUTDIALOG guard. (LauncherWindow::showUserAgentDialog): Add QT_NO_COMBOBOX guard.
  • QtTestBrowser/launcherwindow.h:
  • QtTestBrowser/locationedit.cpp: Add QT_NO_INPUTDIALOG guard.
  • QtTestBrowser/locationedit.h: Ditto.
  • QtTestBrowser/mainwindow.cpp: (MainWindow::buildUI): Add QT_NO_INPUTDIALOG, QT_NO_SHORTCUT and QT_NO_UNDOSTACK guards. (MainWindow::setAddressUrl): Add QT_NO_INPUTDIALOG guard. (MainWindow::changeLocation): Ditto. (MainWindow::openFile): Add QT_NO_FILEDIALOG guard. (MainWindow::openLocation): Add QT_NO_INPUTDIALOG guard.
  • QtTestBrowser/webpage.cpp: (WebPage::openUrlInDefaultBrowser): Add QT_NO_DESKTOPSERVICES guard. (WebPage::authenticationRequired): Add QT_NO_LINEEDIT guard.
  • QtTestBrowser/webview.cpp: (WebViewGraphicsBased::animatedFlip): Add QT_NO_ANIMATION guard. (WebViewGraphicsBased::animatedYFlip): Ditto.

2011-01-10 Laszlo Gombos <Laszlo Gombos>

Reviewed by Csaba Osztrogonác.

[Qt] Baseline qt_minimal configuration
https://bugs.webkit.org/show_bug.cgi?id=51313

  • WebCoreSupport/PopupMenuQt.cpp: (WebCore::PopupMenuQt::show): Add QT_NO_COMBOBOX guard.
  • WebCoreSupport/QtFallbackWebPopup.cpp: (WebCore::QtFallbackWebPopup::populate): Add QT_NO_TOOLTIP guard.
  • tests/qwebframe/tst_qwebframe.cpp: Add QT_NO_COMBOBOX guard.
  • tests/qwebpage/tst_qwebpage.cpp: (PluginPage::createPlugin): Add QT_NO_INPUTDIALOG guard.
Location:
trunk
Files:
20 edited

Legend:

Unmodified
Added
Removed
  • trunk/ChangeLog

    r75403 r75467  
     12011-01-10  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
     2
     3        Reviewed by Csaba Osztrogonác.
     4
     5        [Qt] Baseline qt_minimal configuration
     6        https://bugs.webkit.org/show_bug.cgi?id=51313
     7
     8        * WebKit.pri: List the supported QT_NO_FEATURE flags
     9        under qt_minimal configuration.
     10
    1112011-01-10  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
    212
  • trunk/Source/WebCore/ChangeLog

    r75461 r75467  
     12011-01-10  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
     2
     3        Reviewed by Csaba Osztrogonác.
     4
     5        [Qt] Baseline qt_minimal configuration
     6        https://bugs.webkit.org/show_bug.cgi?id=51313
     7
     8        No new tests as there is no new functionality.
     9
     10        * platform/graphics/qt/GraphicsLayerQt.cpp: Fix the location of the
     11        QT_NO_ANIMATION guard.
     12
     13        * platform/qt/WheelEventQt.cpp:
     14        (WebCore::PlatformWheelEvent::applyDelta): Fix the location of the
     15        QT_NO_WHEELEVENT guard.
     16
    1172011-01-10  Joe Mason  <jmason@rim.com>
    218
  • trunk/Source/WebCore/platform/graphics/qt/GraphicsLayerQt.cpp

    r73380 r75467  
    13761376// Helper functions to safely get a value out of WebCore's AnimationValue*.
    13771377
     1378#ifndef QT_NO_ANIMATION
    13781379static void webkitAnimationToQtAnimationValue(const AnimationValue* animationValue, TransformOperations& transformOperations)
    13791380{
     
    13911392}
    13921393
    1393 #ifndef QT_NO_ANIMATION
    13941394// We put a bit of the functionality in a base class to allow casting and to save some code size.
    13951395
  • trunk/Source/WebCore/platform/network/qt/NetworkStateNotifierQt.cpp

    r64965 r75467  
    9292} // namespace WebCore
    9393
     94#include "moc_NetworkStateNotifierPrivate.cpp"
     95
    9496#endif
    95 
    96 #include "moc_NetworkStateNotifierPrivate.cpp"
  • trunk/Source/WebCore/platform/qt/WheelEventQt.cpp

    r61075 r75467  
    4949    m_wheelTicksY = m_deltaY;
    5050
     51#ifndef QT_NO_WHEELEVENT
    5152    // Use the same single scroll step as QTextEdit
    5253    // (in QTextEditPrivate::init [h,v]bar->setSingleStep)
    5354    static const float cDefaultQtScrollStep = 20.f;
    54 #ifndef QT_NO_WHEELEVENT
    5555    m_deltaX *= (fullTick) ? QApplication::wheelScrollLines() * cDefaultQtScrollStep : 1;
    5656    m_deltaY *= (fullTick) ? QApplication::wheelScrollLines() * cDefaultQtScrollStep : 1;
  • trunk/Tools/ChangeLog

    r75464 r75467  
     12011-01-10  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
     2
     3        Reviewed by Csaba Osztrogonác.
     4
     5        [Qt] Baseline qt_minimal configuration
     6        https://bugs.webkit.org/show_bug.cgi?id=51313
     7
     8        * DumpRenderTree/qt/DumpRenderTreeQt.cpp:
     9        (WebCore::DumpRenderTree::resetToConsistentStateBeforeTesting): Add
     10        QT_NO_UNDOSTACK guard.
     11
     12        * QtTestBrowser/launcherwindow.cpp:
     13        (LauncherWindow::createChrome): Add QT_NO_SHORTCUT and QT_NO_PRINTER
     14        guards.
     15        (LauncherWindow::applyZoom): Add QT_NO_ANIMATION guard.
     16        (LauncherWindow::screenshot): Add QT_NO_FILEDIALOG guard.
     17        (LauncherWindow::selectElements): Add QT_NO_INPUTDIALOG guard.
     18        (LauncherWindow::showUserAgentDialog): Add QT_NO_COMBOBOX guard.
     19
     20        * QtTestBrowser/launcherwindow.h:
     21        * QtTestBrowser/locationedit.cpp: Add QT_NO_INPUTDIALOG guard.
     22        * QtTestBrowser/locationedit.h: Ditto.
     23
     24        * QtTestBrowser/mainwindow.cpp:
     25        (MainWindow::buildUI): Add QT_NO_INPUTDIALOG, QT_NO_SHORTCUT and
     26        QT_NO_UNDOSTACK guards.
     27        (MainWindow::setAddressUrl): Add QT_NO_INPUTDIALOG guard.
     28        (MainWindow::changeLocation): Ditto.
     29        (MainWindow::openFile): Add QT_NO_FILEDIALOG guard.
     30        (MainWindow::openLocation): Add QT_NO_INPUTDIALOG guard.
     31
     32        * QtTestBrowser/webpage.cpp:
     33        (WebPage::openUrlInDefaultBrowser): Add QT_NO_DESKTOPSERVICES guard.
     34        (WebPage::authenticationRequired): Add QT_NO_LINEEDIT guard.
     35
     36        * QtTestBrowser/webview.cpp:
     37        (WebViewGraphicsBased::animatedFlip): Add QT_NO_ANIMATION guard.
     38        (WebViewGraphicsBased::animatedYFlip): Ditto.
     39
    1402011-01-10  Sam Weinig  <sam@webkit.org>
    241
  • trunk/Tools/DumpRenderTree/qt/DumpRenderTreeQt.cpp

    r74301 r75467  
    541541
    542542    m_page->resetSettings();
     543#ifndef QT_NO_UNDOSTACK
    543544    m_page->undoStack()->clear();
     545#endif
    544546    m_page->mainFrame()->setZoomFactor(1.0);
    545547    clearHistory(m_page);
  • trunk/Tools/QtTestBrowser/launcherwindow.cpp

    r73712 r75467  
    164164void LauncherWindow::createChrome()
    165165{
     166#ifndef QT_NO_SHORTCUT
    166167    QMenu* fileMenu = menuBar()->addMenu("&File");
    167168    fileMenu->addAction("New Window", this, SLOT(newWindow()), QKeySequence::New);
     
    171172    fileMenu->addSeparator();
    172173    fileMenu->addAction("Take Screen Shot...", this, SLOT(screenshot()));
     174#ifndef QT_NO_PRINTER
    173175    fileMenu->addAction(tr("Print..."), this, SLOT(print()), QKeySequence::Print);
     176#endif
    174177    fileMenu->addSeparator();
    175178    fileMenu->addAction("Quit", QApplication::instance(), SLOT(closeAllWindows()), QKeySequence(Qt::CTRL | Qt::Key_Q));
     
    369372    showFPS->connect(toggleGraphicsView, SIGNAL(toggled(bool)), SLOT(setEnabled(bool)));
    370373    showFPS->setChecked(m_windowOptions.showFrameRate);
     374#endif
    371375}
    372376
     
    548552void LauncherWindow::applyZoom()
    549553{
     554#ifndef QT_NO_ANIMATION
    550555    if (isGraphicsBased() && page()->settings()->testAttribute(QWebSettings::TiledBackingStoreEnabled)) {
    551556        QGraphicsWebView* view = static_cast<WebViewGraphicsBased*>(m_view)->graphicsWebView();
     
    565570        return;
    566571    }
     572#endif
    567573    page()->mainFrame()->setZoomFactor(qreal(m_currentZoom) / 100.0);
    568574}
     
    621627#endif
    622628
     629#ifndef QT_NO_FILEDIALOG
    623630    QString fileName = QFileDialog::getSaveFileName(label, "Screenshot");
    624631    if (!fileName.isEmpty()) {
     
    627634            label->setWindowTitle(QString("Screenshot - Saved at %1").arg(fileName));
    628635    }
     636#endif
    629637
    630638#if defined(QT_CONFIGURED_WITH_OPENGL)
     
    658666void LauncherWindow::selectElements()
    659667{
     668#ifndef QT_NO_INPUTDIALOG
    660669    bool ok;
    661670    QString str = QInputDialog::getText(this, "Select elements", "Choose elements",
     
    670679#endif
    671680    }
     681#endif
    672682}
    673683
     
    822832    dialog->setLayout(layout);
    823833
     834#ifndef QT_NO_COMBOBOX
    824835    QComboBox* combo = new QComboBox(dialog);
    825836    combo->setSizeAdjustPolicy(QComboBox::AdjustToMinimumContentsLength);
     
    830841    int index = combo->findText(page()->userAgentForUrl(QUrl()));
    831842    combo->setCurrentIndex(index);
     843#endif
    832844
    833845    QDialogButtonBox* buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok
     
    837849    layout->addWidget(buttonBox);
    838850
     851#ifndef QT_NO_COMBOBOX
    839852    if (dialog->exec() && !combo->currentText().isEmpty()) {
    840853        page()->setUserAgent(combo->currentText());
     
    842855            settings.setValue("CustomUserAgent", combo->currentText());
    843856    }
     857#endif
    844858
    845859    delete dialog;
  • trunk/Tools/QtTestBrowser/launcherwindow.h

    r73712 r75467  
    7676#endif
    7777
     78class QPropertyAnimation;
     79
    7880class WindowOptions {
    7981public:
  • trunk/Tools/QtTestBrowser/locationedit.cpp

    r54074 r75467  
    2727
    2828#include "locationedit.h"
     29
     30#ifndef QT_NO_INPUTDIALOG
    2931
    3032LocationEdit::LocationEdit(QWidget* parent)
     
    7981#endif
    8082}
     83
     84#endif
  • trunk/Tools/QtTestBrowser/locationedit.h

    r54074 r75467  
    2929#define locationedit_h
    3030
     31#ifndef QT_NO_INPUTDIALOG
    3132#include <QtGui>
    3233
     
    5354
    5455#endif
     56#endif
  • trunk/Tools/QtTestBrowser/mainwindow.cpp

    r74941 r75467  
    6767    m_toolBar->addAction(page()->action(QWebPage::Stop));
    6868
     69#ifndef QT_NO_INPUTDIALOG
    6970    urlEdit = new LocationEdit(m_toolBar);
    7071    urlEdit->setSizePolicy(QSizePolicy::Expanding, urlEdit->sizePolicy().verticalPolicy());
     
    8081#endif
    8182
    82     connect(page()->mainFrame(), SIGNAL(titleChanged(const QString&)),
    83             this, SLOT(setWindowTitle(const QString&)));
    8483    connect(page()->mainFrame(), SIGNAL(urlChanged(QUrl)), this, SLOT(setAddressUrl(QUrl)));
    8584    connect(page(), SIGNAL(loadProgress(int)), urlEdit, SLOT(setProgress(int)));
     85#endif
     86
     87    connect(page()->mainFrame(), SIGNAL(titleChanged(const QString&)),
     88                this, SLOT(setWindowTitle(const QString&)));
    8689    connect(page(), SIGNAL(windowCloseRequested()), this, SLOT(close()));
    8790
     91#ifndef QT_NO_SHORTCUT
    8892    // short-cuts
    8993    page()->action(QWebPage::Back)->setShortcut(QKeySequence::Back);
     
    9195    page()->action(QWebPage::Forward)->setShortcut(QKeySequence::Forward);
    9296    page()->action(QWebPage::Reload)->setShortcut(QKeySequence::Refresh);
     97#ifndef QT_NO_UNDOSTACK
    9398    page()->action(QWebPage::Undo)->setShortcut(QKeySequence::Undo);
    9499    page()->action(QWebPage::Redo)->setShortcut(QKeySequence::Redo);
     100#endif
    95101    page()->action(QWebPage::Cut)->setShortcut(QKeySequence::Cut);
    96102    page()->action(QWebPage::Copy)->setShortcut(QKeySequence::Copy);
     
    101107    page()->action(QWebPage::ToggleItalic)->setShortcut(QKeySequence(Qt::CTRL | Qt::Key_I));
    102108    page()->action(QWebPage::ToggleUnderline)->setShortcut(QKeySequence(Qt::CTRL | Qt::Key_U));
     109#endif
    103110}
    104111
     
    126133void MainWindow::setAddressUrl(const QString& url)
    127134{
     135#ifndef QT_NO_INPUTDIALOG
    128136    if (!url.contains("about:"))
    129137        urlEdit->setText(url);
     138#endif
    130139}
    131140
     
    165174void MainWindow::changeLocation()
    166175{
     176#ifndef QT_NO_INPUTDIALOG
    167177    QString string = urlEdit->text();
    168178    QUrl mainFrameURL = page()->mainFrame()->url();
     
    174184
    175185    load(string);
     186#endif
    176187}
    177188
    178189void MainWindow::openFile()
    179190{
     191#ifndef QT_NO_FILEDIALOG
    180192    static const QString filter("HTML Files (*.htm *.html);;Text Files (*.txt);;Image Files (*.gif *.jpg *.png);;All Files (*)");
    181193
     
    190202            load(QUrl::fromLocalFile(selectedFile));
    191203    }
     204#endif
    192205}
    193206
    194207void MainWindow::openLocation()
    195208{
     209#ifndef QT_NO_INPUTDIALOG
    196210    urlEdit->selectAll();
    197211    urlEdit->setFocus();
    198 }
     212#endif
     213}
  • trunk/Tools/QtTestBrowser/webpage.cpp

    r75340 r75467  
    108108void WebPage::openUrlInDefaultBrowser(const QUrl& url)
    109109{
     110#ifndef QT_NO_DESKTOPSERVICES
    110111    if (QAction* action = qobject_cast<QAction*>(sender()))
    111112        QDesktopServices::openUrl(action->data().toUrl());
    112113    else
    113114        QDesktopServices::openUrl(url);
     115#endif
    114116}
    115117
     
    166168    layout->addWidget(messageLabel, 0, 1);
    167169
     170#ifndef QT_NO_LINEEDIT
    168171    QLabel* userLabel = new QLabel("Username:", dialog);
    169172    layout->addWidget(userLabel, 1, 0);
     
    176179    passInput->setEchoMode(QLineEdit::Password);
    177180    layout->addWidget(passInput, 2, 1);
     181#endif
    178182
    179183    QDialogButtonBox* buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok
     
    184188
    185189    if (dialog->exec() == QDialog::Accepted) {
     190#ifndef QT_NO_LINEEDIT
    186191        authenticator->setUser(userInput->text());
    187192        authenticator->setPassword(passInput->text());
     193#endif
    188194    }
    189195
  • trunk/Tools/QtTestBrowser/webview.cpp

    r72712 r75467  
    170170void WebViewGraphicsBased::animatedFlip()
    171171{
     172#ifndef QT_NO_ANIMATION
    172173    QSizeF center = graphicsWebView()->boundingRect().size() / 2;
    173174    QPointF centerPoint = QPointF(center.width(), center.height());
     
    183184
    184185    animation->start(QAbstractAnimation::DeleteWhenStopped);
     186#endif
    185187}
    186188
    187189void WebViewGraphicsBased::animatedYFlip()
    188190{
     191#ifndef QT_NO_ANIMATION
    189192    if (!m_machine) {
    190193        m_machine = new QStateMachine(this);
     
    218221
    219222    m_machine->start();
     223#endif
    220224}
    221225
  • trunk/WebKit.pri

    r75313 r75467  
    110110win32-msvc*|wince*: QMAKE_CXXFLAGS += -wd4291 -wd4344 -wd4396 -wd4503 -wd4800 -wd4819 -wd4996
    111111
     112CONFIG(qt_minimal) {
     113    DEFINES *= QT_NO_ANIMATION
     114    DEFINES *= QT_NO_BEARERMANAGEMENT
     115    DEFINES *= QT_NO_CLIPBOARD
     116    DEFINES *= QT_NO_COMBOBOX
     117    DEFINES *= QT_NO_CRASHHANDLER
     118    DEFINES *= QT_NO_CURSOR
     119    DEFINES *= QT_NO_DESKTOPSERVICES
     120    DEFINES *= QT_NO_FILEDIALOG
     121    DEFINES *= QT_NO_GRAPHICSEFFECT
     122    DEFINES *= QT_NO_IM
     123    DEFINES *= QT_NO_INPUTDIALOG
     124    DEFINES *= QT_NO_LINEEDIT
     125    DEFINES *= QT_NO_MESSAGEBOX
     126    DEFINES *= QT_NO_OPENSSL
     127    DEFINES *= QT_NO_PRINTER
     128    DEFINES *= QT_NO_QUUID_STRING
     129    DEFINES *= QT_NO_SHORTCUT
     130    DEFINES *= QT_NO_STYLE_STYLESHEET
     131    DEFINES *= QT_NO_SYSTEMTRAYICON
     132    DEFINES *= QT_NO_TEMPORARYFILE
     133    DEFINES *= QT_NO_TOOLTIP
     134    DEFINES *= QT_NO_UITOOLS
     135    DEFINES *= QT_NO_UNDOCOMMAND
     136    DEFINES *= QT_NO_UNDOSTACK
     137    DEFINES *= QT_NO_XRENDER
     138}
  • trunk/WebKit/qt/ChangeLog

    r75455 r75467  
     12011-01-10  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
     2
     3        Reviewed by Csaba Osztrogonác.
     4
     5        [Qt] Baseline qt_minimal configuration
     6        https://bugs.webkit.org/show_bug.cgi?id=51313
     7
     8        * WebCoreSupport/PopupMenuQt.cpp:
     9        (WebCore::PopupMenuQt::show): Add QT_NO_COMBOBOX guard.
     10
     11        * WebCoreSupport/QtFallbackWebPopup.cpp:
     12        (WebCore::QtFallbackWebPopup::populate): Add QT_NO_TOOLTIP guard.
     13
     14        * tests/qwebframe/tst_qwebframe.cpp: Add QT_NO_COMBOBOX guard.
     15        * tests/qwebpage/tst_qwebpage.cpp:
     16        (PluginPage::createPlugin): Add QT_NO_INPUTDIALOG guard.
     17
    1182011-01-10  Adam Barth  <abarth@webkit.org>
    219
  • trunk/WebKit/qt/WebCoreSupport/PopupMenuQt.cpp

    r70134 r75467  
    9898void PopupMenuQt::show(const IntRect& rect, FrameView* view, int index)
    9999{
     100#ifndef QT_NO_COMBOBOX
    100101    if (!m_popupClient)
    101102        return;
     
    118119    m_selectData = new SelectData(m_popupClient);
    119120    m_popup->show(*m_selectData);
     121#endif
    120122}
    121123
  • trunk/WebKit/qt/WebCoreSupport/QtFallbackWebPopup.cpp

    r67453 r75467  
    233233            m_combo->insertItem(i, data.itemText(i));
    234234            model->item(i)->setEnabled(data.itemIsEnabled(i));
     235#ifndef QT_NO_TOOLTIP
    235236            model->item(i)->setToolTip(data.itemToolTip(i));
     237#endif
    236238            if (data.itemIsSelected(i))
    237239                currentIndex = i;
  • trunk/WebKit/qt/tests/qwebframe/tst_qwebframe.cpp

    r74220 r75467  
    604604    void ipv6HostEncoding();
    605605    void metaData();
    606 #if !defined(Q_WS_MAEMO_5) && !defined(Q_OS_SYMBIAN)
     606#if !defined(Q_WS_MAEMO_5) && !defined(Q_OS_SYMBIAN) && !defined(QT_NO_COMBOBOX)
    607607    // as maemo 5 && symbian do not use QComboBoxes to implement the popups
    608608    // this test does not make sense for it.
     
    25912591}
    25922592
    2593 #if !defined(Q_WS_MAEMO_5) && !defined(Q_OS_SYMBIAN)
     2593#if !defined(Q_WS_MAEMO_5) && !defined(Q_OS_SYMBIAN) && !defined(QT_NO_COMBOBOX)
    25942594void tst_QWebFrame::popupFocus()
    25952595{
  • trunk/WebKit/qt/tests/qwebpage/tst_qwebpage.cpp

    r75411 r75467  
    590590        if (classid == "pushbutton")
    591591            result = new QPushButton();
     592#ifndef QT_NO_INPUTDIALOG
    592593        else if (classid == "lineedit")
    593594            result = new QLineEdit();
     595#endif
    594596        else if (classid == "graphicswidget")
    595597            result = new QGraphicsWidget();
Note: See TracChangeset for help on using the changeset viewer.