Ignore:
Timestamp:
Feb 11, 2010, 11:19:06 PM (15 years ago)
Author:
Dmitry A. Kuminov
Message:

trunk: Merged in qt 4.6.1 sources.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/src/scripttools/debugging/qscriptdebuggerscriptedconsolecommand.cpp

    r2 r561  
    22**
    33** 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)
    56**
    67** This file is part of the QtSCriptTools module of the Qt Toolkit.
     
    2122** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
    2223**
    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.
    2727**
    2828** GNU General Public License Usage
     
    3434** met: http://www.gnu.org/copyleft/gpl.html.
    3535**
    36 ** If you are unsure which license is appropriate for your use, please
    37 ** 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.
    3838** $QT_END_LICENSE$
    3939**
     
    368368{
    369369public:
    370     QScriptDebuggerScriptedConsoleCommandJobPrivate() {}
     370    QScriptDebuggerScriptedConsoleCommandJobPrivate() : command(0), commandCount(0) {}
    371371    ~QScriptDebuggerScriptedConsoleCommandJobPrivate() {}
    372372
     
    411411        args.append(QScriptValue(engine, d->arguments.at(i)));
    412412    QScriptDebuggerConsoleGlobalObject *global;
    413 #if QT_VERSION >= 0x040500
    414413    global = qobject_cast<QScriptDebuggerConsoleGlobalObject*>(engine->globalObject().toQObject());
    415 #else
    416     global = qobject_cast<QScriptDebuggerConsoleGlobalObject*>(engine->globalObject().scope().toQObject());
    417 #endif
    418414    Q_ASSERT(global != 0);
    419415    global->setScheduler(this);
     
    445441    args.append(QScriptValue(engine, commandId));
    446442    QScriptDebuggerConsoleGlobalObject *global;
    447 #if QT_VERSION >= 0x040500
    448443    global = qobject_cast<QScriptDebuggerConsoleGlobalObject*>(engine->globalObject().toQObject());
    449 #else
    450     global = qobject_cast<QScriptDebuggerConsoleGlobalObject*>(engine->globalObject().scope().toQObject());
    451 #endif
    452444    Q_ASSERT(global != 0);
    453445    global->setScheduler(this);
     
    469461
    470462/*!
    471   \reimp
     463  \internal
    472464*/
    473465QString QScriptDebuggerScriptedConsoleCommand::name() const
     
    478470
    479471/*!
    480   \reimp
     472  \internal
    481473*/
    482474QString QScriptDebuggerScriptedConsoleCommand::group() const
     
    487479
    488480/*!
    489   \reimp
     481  \internal
    490482*/
    491483QString QScriptDebuggerScriptedConsoleCommand::shortDescription() const
     
    496488
    497489/*!
    498   \reimp
     490  \internal
    499491*/
    500492QString QScriptDebuggerScriptedConsoleCommand::longDescription() const
     
    505497
    506498/*!
    507   \reimp
     499  \internal
    508500*/
    509501QStringList QScriptDebuggerScriptedConsoleCommand::aliases() const
     
    514506
    515507/*!
    516   \reimp
     508  \internal
    517509*/
    518510QStringList QScriptDebuggerScriptedConsoleCommand::seeAlso() const
     
    523515
    524516/*!
    525   \reimp
     517  \internal
    526518*/
    527519QStringList QScriptDebuggerScriptedConsoleCommand::argumentTypes() const
     
    532524
    533525/*!
    534   \reimp
     526  \internal
    535527*/
    536528QStringList QScriptDebuggerScriptedConsoleCommand::subCommands() const
     
    541533
    542534/*!
    543   \reimp
     535  \internal
    544536*/
    545537QScriptDebuggerConsoleCommandJob *QScriptDebuggerScriptedConsoleCommand::createJob(
     
    567559    QScriptValue global = engine->newQObject(cppGlobal,
    568560                                             QScriptEngine::ScriptOwnership,
    569 #if QT_VERSION >= 0x040500
    570561                                             QScriptEngine::ExcludeSuperClassContents);
    571 #else
    572                                              QScriptEngine::ExcludeSuperClassMethods
    573                                              | QScriptEngine::ExcludeSuperClassProperties);
    574 #endif
    575562    {
    576563        QScriptValueIterator it(engine->globalObject());
     
    580567        }
    581568    }
    582 #if QT_VERSION >= 0x040500
    583569    engine->setGlobalObject(global);
    584 #else
    585     engine->globalObject().setScope(global);
    586     global = engine->globalObject();
    587 #endif
    588570
    589571    cppGlobal->setMessageHandler(messageHandler);
Note: See TracChangeset for help on using the changeset viewer.