Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found
Select Git revision
  • 0.9.1-beta
  • 0.9.2-rc1
  • 1.0.0
  • 1.1
  • 1.2
  • 1.2.90
  • 1.3
  • 1.3.0
  • 1.3.0-beta
  • 1.3.1
  • 2.0
  • 2.0.0
  • 2.0.0-beta
  • 2.0.1
  • 2.1
  • 2.1.0
  • 2.2
  • 2.3
  • 2.4
  • 2.5
  • 2.6
  • 2.7
  • 2.8
  • 3.0
  • 3.1
  • 3.2
  • 3.3
  • 3.4
  • 3.5
  • 3.6
  • 4.0
  • 4.1
  • 4.2
  • 4.3
  • 4.4
  • 4.5
  • at-3.4
  • at-3.5
  • at-3.6
  • at-master
  • csa-3.3
  • csa-3.4
  • csa-3.5
  • csa-3.6
  • csa-master
  • master
  • qp-2.8
  • qp-3.0
  • qp-3.1
  • qp-3.2
  • qp-3.3
  • qp-3.4
  • qp-3.5
  • qp-3.6
  • qp-master
  • wip/boostbuildprojectmanager
  • wip/clang-query
  • wip/vcproj
  • at-v3.4.0
  • at-v3.4.0-beta1
  • at-v3.4.0-rc1
  • at-v3.4.1
  • at-v3.4.2
  • at-v3.5.0
  • at-v3.5.0-beta1
  • at-v3.5.0-rc1
  • at-v3.5.1
  • at-v3.6.0
  • at-v3.6.0-beta1
  • at-v3.6.0-rc1
  • csa-v3.3.0
  • csa-v3.3.0-beta1
  • csa-v3.3.0-rc1
  • csa-v3.3.1
  • csa-v3.3.2
  • csa-v3.4.0
  • csa-v3.4.0-beta1
  • csa-v3.4.0-rc1
  • csa-v3.4.1
  • csa-v3.4.2
  • csa-v3.5.0
  • csa-v3.5.0-beta1
  • csa-v3.5.0-rc1
  • csa-v3.5.1
  • csa-v3.6.0
  • csa-v3.6.0-beta1
  • csa-v3.6.0-rc1
  • qp-v3.1.0
  • qp-v3.1.0-beta1
  • qp-v3.2.0
  • qp-v3.2.0-beta1
  • qp-v3.2.1
  • qp-v3.2.2
  • qp-v3.3.0
  • qp-v3.3.0-beta1
  • qp-v3.3.0-rc1
  • qp-v3.3.1
  • qp-v3.3.2
  • qp-v3.4.0
  • qp-v3.4.0-rc1
  • qp-v3.4.1
  • qp-v3.4.2
  • qp-v3.5.0
  • qp-v3.5.0-beta1
  • qp-v3.5.0-rc1
  • qp-v3.5.1
  • qp-v3.6.0
  • qp-v3.6.0-beta1
  • qp-v3.6.0-rc1
  • tqtc/v2.6.0
  • tqtc/v2.6.0-rc
  • tqtc/v2.6.1
  • tqtc/v2.7.0
  • tqtc/v2.7.0-rc
  • tqtc/v2.7.2
  • tqtc/v2.8.0
  • tqtc/v2.8.0-beta
  • v1.0.0
  • v1.1.0
  • v1.1.0-rc1
  • v1.1.1
  • v1.2.0
  • v1.2.1
  • v1.2.90
  • v1.3.0
  • v1.3.0-beta
  • v1.3.0-rc1
  • v1.3.1
  • v2.0.0
  • v2.0.0-alpha
  • v2.0.0-beta
  • v2.0.0-rc1
  • v2.0.1
  • v2.1.0
  • v2.1.0-beta
  • v2.1.0-beta2
  • v2.1.0-rc1
  • v2.2.0
  • v2.2.0-beta
  • v2.2.0-rc1
  • v2.2.1
  • v2.3.0
  • v2.3.0-beta
  • v2.3.0-rc
  • v2.3.1
  • v2.4.0
  • v2.4.0-beta
  • v2.4.0-rc
  • v2.4.1
  • v2.5.0
  • v2.5.0-beta
  • v2.5.0-rc
  • v2.5.1
  • v2.5.2
  • v2.6.0
  • v2.6.0-beta
  • v2.6.0-rc
  • v2.6.1
158 results

Target

Select target project
  • tohunger/qt-creator
1 result
Select Git revision
  • 0.9.1-beta
  • 0.9.2-rc1
  • 1.0.0
  • 1.1
  • 1.2
  • 1.2.90
  • 1.3
  • 1.3.0
  • 1.3.0-beta
  • 1.3.1
  • 2.0
  • 2.0.0
  • 2.0.0-beta
  • 2.0.1
  • 2.1
  • 2.1.0
  • 2.2
  • 2.3
  • 2.4
  • 2.5
  • 2.6
  • 2.7
  • 2.8
  • 3.0
  • 3.1
  • 3.2
  • 3.3
  • 3.4
  • 3.5
  • 3.6
  • 4.0
  • 4.1
  • 4.2
  • 4.3
  • 4.4
  • 4.5
  • at-3.4
  • at-3.5
  • at-3.6
  • at-master
  • csa-3.3
  • csa-3.4
  • csa-3.5
  • csa-3.6
  • csa-master
  • master
  • qp-2.8
  • qp-3.0
  • qp-3.1
  • qp-3.2
  • qp-3.3
  • qp-3.4
  • qp-3.5
  • qp-3.6
  • qp-master
  • wip/boostbuildprojectmanager
  • wip/clang-query
  • wip/vcproj
  • at-v3.4.0
  • at-v3.4.0-beta1
  • at-v3.4.0-rc1
  • at-v3.4.1
  • at-v3.4.2
  • at-v3.5.0
  • at-v3.5.0-beta1
  • at-v3.5.0-rc1
  • at-v3.5.1
  • at-v3.6.0
  • at-v3.6.0-beta1
  • at-v3.6.0-rc1
  • csa-v3.3.0
  • csa-v3.3.0-beta1
  • csa-v3.3.0-rc1
  • csa-v3.3.1
  • csa-v3.3.2
  • csa-v3.4.0
  • csa-v3.4.0-beta1
  • csa-v3.4.0-rc1
  • csa-v3.4.1
  • csa-v3.4.2
  • csa-v3.5.0
  • csa-v3.5.0-beta1
  • csa-v3.5.0-rc1
  • csa-v3.5.1
  • csa-v3.6.0
  • csa-v3.6.0-beta1
  • csa-v3.6.0-rc1
  • qp-v3.1.0
  • qp-v3.1.0-beta1
  • qp-v3.2.0
  • qp-v3.2.0-beta1
  • qp-v3.2.1
  • qp-v3.2.2
  • qp-v3.3.0
  • qp-v3.3.0-beta1
  • qp-v3.3.0-rc1
  • qp-v3.3.1
  • qp-v3.3.2
  • qp-v3.4.0
  • qp-v3.4.0-rc1
  • qp-v3.4.1
  • qp-v3.4.2
  • qp-v3.5.0
  • qp-v3.5.0-beta1
  • qp-v3.5.0-rc1
  • qp-v3.5.1
  • qp-v3.6.0
  • qp-v3.6.0-beta1
  • qp-v3.6.0-rc1
  • tqtc/v2.6.0
  • tqtc/v2.6.0-rc
  • tqtc/v2.6.1
  • tqtc/v2.7.0
  • tqtc/v2.7.0-rc
  • tqtc/v2.7.2
  • tqtc/v2.8.0
  • tqtc/v2.8.0-beta
  • v1.0.0
  • v1.1.0
  • v1.1.0-rc1
  • v1.1.1
  • v1.2.0
  • v1.2.1
  • v1.2.90
  • v1.3.0
  • v1.3.0-beta
  • v1.3.0-rc1
  • v1.3.1
  • v2.0.0
  • v2.0.0-alpha
  • v2.0.0-beta
  • v2.0.0-rc1
  • v2.0.1
  • v2.1.0
  • v2.1.0-beta
  • v2.1.0-beta2
  • v2.1.0-rc1
  • v2.2.0
  • v2.2.0-beta
  • v2.2.0-rc1
  • v2.2.1
  • v2.3.0
  • v2.3.0-beta
  • v2.3.0-rc
  • v2.3.1
  • v2.4.0
  • v2.4.0-beta
  • v2.4.0-rc
  • v2.4.1
  • v2.5.0
  • v2.5.0-beta
  • v2.5.0-rc
  • v2.5.1
  • v2.5.2
  • v2.6.0
  • v2.6.0-beta
  • v2.6.0-rc
  • v2.6.1
158 results
Show changes
Showing
with 141 additions and 101 deletions
......@@ -474,6 +474,12 @@ void ManhattanStyle::drawPrimitive(PrimitiveElement element, const QStyleOption
case PE_PanelLineEdit:
{
painter->save();
// Fill the line edit background
QRect filledRect = option->rect.adjusted(1, 1, -1, -1);
painter->setBrushOrigin(filledRect.topLeft());
painter->fillRect(filledRect, option->palette.base());
if (option->state & State_Enabled)
drawCornerImage(d->lineeditImage, painter, option->rect, 2, 2, 2, 2);
else
......
......@@ -176,8 +176,8 @@ void NavigationWidget::resizeEvent(QResizeEvent *re)
NavigationSubWidget *NavigationWidget::insertSubItem(int position)
{
NavigationSubWidget *nsw = new NavigationSubWidget(this);
connect(nsw, SIGNAL(split()), this, SLOT(split()));
connect(nsw, SIGNAL(close()), this, SLOT(close()));
connect(nsw, SIGNAL(splitMe()), this, SLOT(splitSubWidget()));
connect(nsw, SIGNAL(closeMe()), this, SLOT(closeSubWidget()));
insertWidget(position, nsw);
m_subWidgets.insert(position, nsw);
return nsw;
......@@ -199,7 +199,7 @@ void NavigationWidget::activateSubWidget()
m_subWidgets.first()->setFocusWidget();
}
void NavigationWidget::split()
void NavigationWidget::splitSubWidget()
{
NavigationSubWidget *original = qobject_cast<NavigationSubWidget *>(sender());
int pos = indexOf(original) + 1;
......@@ -207,7 +207,7 @@ void NavigationWidget::split()
newnsw->setFactory(original->factory());
}
void NavigationWidget::close()
void NavigationWidget::closeSubWidget()
{
if (m_subWidgets.count() != 1) {
NavigationSubWidget *subWidget = qobject_cast<NavigationSubWidget *>(sender());
......@@ -389,8 +389,8 @@ NavigationSubWidget::NavigationSubWidget(NavigationWidget *parentWidget)
setLayout(lay);
lay->addWidget(m_toolBar);
connect(splitAction, SIGNAL(clicked()), this, SIGNAL(split()));
connect(close, SIGNAL(clicked()), this, SIGNAL(close()));
connect(splitAction, SIGNAL(clicked()), this, SIGNAL(splitMe()));
connect(close, SIGNAL(clicked()), this, SIGNAL(closeMe()));
connect(m_navigationComboBox, SIGNAL(currentIndexChanged(int)),
this, SLOT(setCurrentIndex(int)));
......
......@@ -103,8 +103,8 @@ protected:
private slots:
void objectAdded(QObject*);
void activateSubWidget();
void split();
void close();
void splitSubWidget();
void closeSubWidget();
private:
NavigationSubWidget *insertSubItem(int position);
......@@ -136,8 +136,8 @@ public:
Core::Command *command(const QString &title) const;
signals:
void split();
void close();
void splitMe();
void closeMe();
private slots:
void objectAdded(QObject*);
......
......@@ -46,10 +46,6 @@
#include <QtGui/QToolBar>
#include <QtGui/QStatusBar>
namespace {
enum { debugQWorkbenchWrappers = 0 };
}
// Script function template to pop up a message box
// with a certain icon and buttons.
template <int MsgBoxIcon, int MsgBoxButtons>
......@@ -178,14 +174,9 @@ namespace Core {
namespace Internal {
ScriptManagerPrivate::ScriptManagerPrivate(QObject *parent)
: ScriptManager(parent), m_initialized(false)
{
}
QScriptEngine &ScriptManagerPrivate::scriptEngine()
: ScriptManager(parent),
m_engine(0)
{
ensureEngineInitialized();
return m_engine;
}
// Split a backtrace of the form:
......@@ -225,25 +216,26 @@ bool ScriptManagerPrivate::runScript(const QString &script, QString *errorMessag
ensureEngineInitialized();
stack->clear();
m_engine.pushContext();
m_engine.evaluate(script);
m_engine->pushContext();
m_engine->evaluate(script);
const bool failed = m_engine.hasUncaughtException ();
const bool failed = m_engine->hasUncaughtException ();
if (failed) {
const int errorLineNumber = m_engine.uncaughtExceptionLineNumber();
const QStringList backTrace = m_engine.uncaughtExceptionBacktrace();
const int errorLineNumber = m_engine->uncaughtExceptionLineNumber();
const QStringList backTrace = m_engine->uncaughtExceptionBacktrace();
parseBackTrace(backTrace, *stack);
const QString backtrace = backTrace.join(QString(QLatin1Char('\n')));
*errorMessage = ScriptManager::tr("Exception at line %1: %2\n%3").arg(errorLineNumber).arg(engineError(m_engine)).arg(backtrace);
}
m_engine.popContext();
m_engine->popContext();
return !failed;
}
void ScriptManagerPrivate::ensureEngineInitialized()
{
if (m_initialized)
if (m_engine)
return;
m_engine = new QScriptEngine(this);
// register QObjects that occur as properties
SharedTools::registerQObject<QMainWindow>(m_engine);
SharedTools::registerQObject<QStatusBar>(m_engine);
......@@ -252,52 +244,51 @@ void ScriptManagerPrivate::ensureEngineInitialized()
// SharedTools::registerQObjectInterface<Core::MessageManager, MessageManagerPrototype>(m_engine);
// SharedTools::registerQObjectInterface<Core::IFile, FilePrototype>(m_engine);
// qScriptRegisterSequenceMetaType<QList<Core::IFile *> >(&m_engine);
// qScriptRegisterSequenceMetaType<QList<Core::IFile *> >(m_engine);
// SharedTools::registerQObjectInterface<Core::FileManager, FileManagerPrototype>(m_engine);
// SharedTools::registerQObjectInterface<Core::IEditor, EditorPrototype>(m_engine);
qScriptRegisterSequenceMetaType<QList<Core::IEditor *> >(&m_engine);
qScriptRegisterSequenceMetaType<QList<Core::IEditor *> >(m_engine);
// SharedTools::registerQObjectInterface<Core::EditorGroup, EditorGroupPrototype>(m_engine);
qScriptRegisterSequenceMetaType<QList<Core::EditorGroup *> >(&m_engine);
qScriptRegisterSequenceMetaType<QList<Core::EditorGroup *> >(m_engine);
SharedTools::registerQObjectInterface<Core::EditorManager, EditorManagerPrototype>(m_engine);
// SharedTools::registerQObjectInterface<Core::ICore, CorePrototype>(m_engine);
// Make "core" available
m_engine.globalObject().setProperty(QLatin1String("core"), qScriptValueFromValue(&m_engine, Core::ICore::instance()));
m_engine->globalObject().setProperty(QLatin1String("core"), qScriptValueFromValue(m_engine, Core::ICore::instance()));
// CLASSIC: registerInterfaceWithDefaultPrototype<Core::MessageManager, MessageManagerPrototype>(m_engine);
// Message box conveniences
m_engine.globalObject().setProperty(QLatin1String("critical"),
m_engine.newFunction(messageBox<QMessageBox::Critical, QMessageBox::Ok>, 3));
m_engine.globalObject().setProperty(QLatin1String("warning"),
m_engine.newFunction(messageBox<QMessageBox::Warning, QMessageBox::Ok>, 3));
m_engine.globalObject().setProperty(QLatin1String("information"),
m_engine.newFunction(messageBox<QMessageBox::Information, QMessageBox::Ok>, 3));
m_engine->globalObject().setProperty(QLatin1String("critical"),
m_engine->newFunction(messageBox<QMessageBox::Critical, QMessageBox::Ok>, 3));
m_engine->globalObject().setProperty(QLatin1String("warning"),
m_engine->newFunction(messageBox<QMessageBox::Warning, QMessageBox::Ok>, 3));
m_engine->globalObject().setProperty(QLatin1String("information"),
m_engine->newFunction(messageBox<QMessageBox::Information, QMessageBox::Ok>, 3));
// StandardButtons has overloaded operator '|' - grrr.
enum { MsgBoxYesNo = 0x00014000 };
m_engine.globalObject().setProperty(QLatin1String("yesNoQuestion"),
m_engine.newFunction(messageBox<QMessageBox::Question, MsgBoxYesNo>, 3));
m_engine->globalObject().setProperty(QLatin1String("yesNoQuestion"),
m_engine->newFunction(messageBox<QMessageBox::Question, MsgBoxYesNo>, 3));
m_engine.globalObject().setProperty(QLatin1String("getText"), m_engine.newFunction(inputDialogGetText, 3));
m_engine.globalObject().setProperty(QLatin1String("getInteger"), m_engine.newFunction(inputDialogGetInteger, 3));
m_engine.globalObject().setProperty(QLatin1String("getDouble"), m_engine.newFunction(inputDialogGetDouble, 3));
m_engine.globalObject().setProperty(QLatin1String("getItem"), m_engine.newFunction(inputDialogGetItem, 3));
m_engine->globalObject().setProperty(QLatin1String("getText"), m_engine->newFunction(inputDialogGetText, 3));
m_engine->globalObject().setProperty(QLatin1String("getInteger"), m_engine->newFunction(inputDialogGetInteger, 3));
m_engine->globalObject().setProperty(QLatin1String("getDouble"), m_engine->newFunction(inputDialogGetDouble, 3));
m_engine->globalObject().setProperty(QLatin1String("getItem"), m_engine->newFunction(inputDialogGetItem, 3));
// file box
m_engine.globalObject().setProperty(QLatin1String("getOpenFileNames"), m_engine.newFunction(fileBox<QFileDialog::AcceptOpen, QFileDialog::ExistingFiles> , 2));
m_engine.globalObject().setProperty(QLatin1String("getOpenFileName"), m_engine.newFunction(fileBox<QFileDialog::AcceptOpen, QFileDialog::ExistingFile> , 2));
m_engine.globalObject().setProperty(QLatin1String("getSaveFileName"), m_engine.newFunction(fileBox<QFileDialog::AcceptSave, QFileDialog::AnyFile> , 2));
m_engine.globalObject().setProperty(QLatin1String("getExistingDirectory"), m_engine.newFunction(fileBox<QFileDialog::AcceptSave, QFileDialog::DirectoryOnly> , 2));
m_initialized = true;
m_engine->globalObject().setProperty(QLatin1String("getOpenFileNames"), m_engine->newFunction(fileBox<QFileDialog::AcceptOpen, QFileDialog::ExistingFiles> , 2));
m_engine->globalObject().setProperty(QLatin1String("getOpenFileName"), m_engine->newFunction(fileBox<QFileDialog::AcceptOpen, QFileDialog::ExistingFile> , 2));
m_engine->globalObject().setProperty(QLatin1String("getSaveFileName"), m_engine->newFunction(fileBox<QFileDialog::AcceptSave, QFileDialog::AnyFile> , 2));
m_engine->globalObject().setProperty(QLatin1String("getExistingDirectory"), m_engine->newFunction(fileBox<QFileDialog::AcceptSave, QFileDialog::DirectoryOnly> , 2));
}
QString ScriptManagerPrivate::engineError(QScriptEngine &scriptEngine)
QString ScriptManagerPrivate::engineError(QScriptEngine *scriptEngine)
{
QScriptValue error = scriptEngine.evaluate(QLatin1String("Error"));
QScriptValue error = scriptEngine->evaluate(QLatin1String("Error"));
if (error.isValid())
return error.toString();
return ScriptManager::tr("Unknown error");
......
......@@ -59,9 +59,6 @@ public:
ScriptManager(QObject *parent = 0) : QObject(parent) {}
virtual ~ScriptManager() { }
// Access the engine (for plugins to wrap additional interfaces).
virtual QScriptEngine &scriptEngine() = 0;
// Run a script
virtual bool runScript(const QString &script, QString *errorMessage, Stack *errorStack) = 0;
virtual bool runScript(const QString &script, QString *errorMessage) = 0;
......
......@@ -45,17 +45,15 @@ class ScriptManagerPrivate : public Core::ScriptManager
public:
explicit ScriptManagerPrivate(QObject *parent);
QScriptEngine &scriptEngine();
bool runScript(const QString &script, QString *errorMessage, Stack *stack);
bool runScript(const QString &script, QString *errorMessage);
static QString engineError(QScriptEngine &scriptEngine);
static QString engineError(QScriptEngine *scriptEngine);
private:
void ensureEngineInitialized();
QScriptEngine m_engine;
bool m_initialized;
QScriptEngine *m_engine;
};
} // namespace Internal
......
......@@ -101,8 +101,8 @@ SideBarItem *SideBar::item(const QString &title)
SideBarWidget *SideBar::insertSideBarWidget(int position, const QString &title)
{
SideBarWidget *item = new SideBarWidget(this, title);
connect(item, SIGNAL(split()), this, SLOT(split()));
connect(item, SIGNAL(close()), this, SLOT(close()));
connect(item, SIGNAL(splitMe()), this, SLOT(splitSubWidget()));
connect(item, SIGNAL(closeMe()), this, SLOT(closeSubWidget()));
connect(item, SIGNAL(currentWidgetChanged()), this, SLOT(updateWidgets()));
insertWidget(position, item);
m_widgets.insert(position, item);
......@@ -118,7 +118,7 @@ void SideBar::removeSideBarWidget(SideBarWidget *widget)
widget->deleteLater();
}
void SideBar::split()
void SideBar::splitSubWidget()
{
SideBarWidget *original = qobject_cast<SideBarWidget*>(sender());
int pos = indexOf(original) + 1;
......@@ -126,7 +126,7 @@ void SideBar::split()
updateWidgets();
}
void SideBar::close()
void SideBar::closeSubWidget()
{
if (m_widgets.count() != 1) {
SideBarWidget *widget = qobject_cast<SideBarWidget*>(sender());
......@@ -239,13 +239,13 @@ SideBarWidget::SideBarWidget(SideBar *sideBar, const QString &title)
m_splitButton = new QToolButton;
m_splitButton->setIcon(QIcon(":/core/images/splitbutton_horizontal.png"));
m_splitButton->setToolTip(tr("Split"));
connect(m_splitButton, SIGNAL(clicked(bool)), this, SIGNAL(split()));
connect(m_splitButton, SIGNAL(clicked(bool)), this, SIGNAL(splitMe()));
m_closeButton = new QToolButton;
m_closeButton->setIcon(QIcon(":/core/images/closebutton.png"));
m_closeButton->setToolTip(tr("Close"));
connect(m_closeButton, SIGNAL(clicked(bool)), this, SIGNAL(close()));
connect(m_closeButton, SIGNAL(clicked(bool)), this, SIGNAL(closeMe()));
QWidget *spacerItem = new QWidget(this);
spacerItem->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Minimum);
......
......@@ -111,8 +111,8 @@ public:
QMap<QString, Core::Command*> shortcutMap() const;
private slots:
void split();
void close();
void splitSubWidget();
void closeSubWidget();
void updateWidgets();
private:
......@@ -146,8 +146,8 @@ public:
Core::Command *command(const QString &title) const;
signals:
void split();
void close();
void splitMe();
void closeMe();
void currentWidgetChanged();
private slots:
......
<plugin name="CodePaster" version="1.2.80" compatVersion="1.2.80">
<plugin name="CodePaster" version="1.2.90" compatVersion="1.2.90">
<vendor>Nokia Corporation</vendor>
<copyright>(C) 2008-2009 Nokia Corporation</copyright>
<license>
......@@ -19,8 +19,8 @@ will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.</license>
<description>Codepaster plugin for pushing/fetching diff from server</description>
<url>http://qt.nokia.com</url>
<dependencyList>
<dependency name="TextEditor" version="1.2.80"/>
<dependency name="ProjectExplorer" version="1.2.80"/>
<dependency name="Core" version="1.2.80"/>
<dependency name="TextEditor" version="1.2.90"/>
<dependency name="ProjectExplorer" version="1.2.90"/>
<dependency name="Core" version="1.2.90"/>
</dependencyList>
</plugin>
<plugin name="CppEditor" version="1.2.80" compatVersion="1.2.80">
<plugin name="CppEditor" version="1.2.90" compatVersion="1.2.90">
<vendor>Nokia Corporation</vendor>
<copyright>(C) 2008-2009 Nokia Corporation</copyright>
<license>
......@@ -19,8 +19,8 @@ will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.</license>
<description>C/C++ editor component.</description>
<url>http://qt.nokia.com</url>
<dependencyList>
<dependency name="Core" version="1.2.80"/>
<dependency name="TextEditor" version="1.2.80"/>
<dependency name="CppTools" version="1.2.80"/>
<dependency name="Core" version="1.2.90"/>
<dependency name="TextEditor" version="1.2.90"/>
<dependency name="CppTools" version="1.2.90"/>
</dependencyList>
</plugin>
<plugin name="CppTools" version="1.2.80" compatVersion="1.2.80">
<plugin name="CppTools" version="1.2.90" compatVersion="1.2.90">
<vendor>Nokia Corporation</vendor>
<copyright>(C) 2008-2009 Nokia Corporation</copyright>
<license>
......@@ -19,8 +19,8 @@ will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.</license>
<description>Tools for analyzing C/C++ code.</description>
<url>http://qt.nokia.com</url>
<dependencyList>
<dependency name="TextEditor" version="1.2.80"/>
<dependency name="ProjectExplorer" version="1.2.80"/>
<dependency name="QuickOpen" version="1.2.80"/>
<dependency name="TextEditor" version="1.2.90"/>
<dependency name="ProjectExplorer" version="1.2.90"/>
<dependency name="QuickOpen" version="1.2.90"/>
</dependencyList>
</plugin>
......@@ -1099,6 +1099,9 @@ void CppModelManager::updateIncludesInPaths(QFutureInterface<void> &future,
QStringList suffixes)
{
QMap<QString, QStringList> entriesInPaths;
typedef QPair<QString, QString> SymLink;
typedef QList<SymLink> SymLinks;
SymLinks symlinks;
int processed = 0;
future.setProgressRange(0, paths.size());
......@@ -1111,6 +1114,11 @@ void CppModelManager::updateIncludesInPaths(QFutureInterface<void> &future,
break;
const QString path = paths.takeFirst();
// Skip already scanned paths
if (entriesInPaths.contains(path))
continue;
QStringList entries;
QDirIterator i(path, QDir::Files | QDir::Dirs | QDir::NoDotAndDotDot);
......@@ -1119,17 +1127,24 @@ void CppModelManager::updateIncludesInPaths(QFutureInterface<void> &future,
const QFileInfo fileInfo = i.fileInfo();
const QString suffix = fileInfo.suffix();
if (suffix.isEmpty() || suffixes.contains(suffix)) {
QString text = fileName.mid(path.length() + 1);
QString text = fileInfo.fileName();
if (fileInfo.isDir()) {
text += QLatin1Char('/');
// Also scan subdirectory, but avoid endless recursion with symbolic links
if (fileInfo.isSymLink()) {
QMap<QString, QStringList>::const_iterator result = entriesInPaths.find(fileInfo.canonicalFilePath());
QString target = fileInfo.symLinkTarget();
// Don't add broken symlinks
if (!QFileInfo(target).exists())
continue;
QMap<QString, QStringList>::const_iterator result = entriesInPaths.find(target);
if (result != entriesInPaths.constEnd()) {
entriesInPaths.insert(fileName, result.value());
} else {
paths.append(fileName);
paths.append(target);
symlinks.append(SymLink(fileName, target));
}
} else {
paths.append(fileName);
......@@ -1145,6 +1160,14 @@ void CppModelManager::updateIncludesInPaths(QFutureInterface<void> &future,
future.setProgressRange(0, processed + paths.size());
future.setProgressValue(processed);
}
// link symlinks
QListIterator<SymLink> it(symlinks);
it.toBack();
while (it.hasPrevious()) {
SymLink v = it.previous();
QMap<QString, QStringList>::const_iterator result = entriesInPaths.find(v.second);
entriesInPaths.insert(v.first, result.value());
}
manager->setIncludesInPaths(entriesInPaths);
......
<plugin name="CVS" version="1.2.80" compatVersion="1.2.80">
<plugin name="CVS" version="1.2.90" compatVersion="1.2.90">
<vendor>Nokia Corporation</vendor>
<copyright>(C) 2008-2009 Nokia Corporation</copyright>
<license>
......@@ -19,9 +19,9 @@ will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.</license>
<description>CVS integration.</description>
<url>http://qt.nokia.com</url>
<dependencyList>
<dependency name="TextEditor" version="1.2.80"/>
<dependency name="ProjectExplorer" version="1.2.80"/>
<dependency name="Core" version="1.2.80"/>
<dependency name="VCSBase" version="1.2.80"/>
<dependency name="TextEditor" version="1.2.90"/>
<dependency name="ProjectExplorer" version="1.2.90"/>
<dependency name="Core" version="1.2.90"/>
<dependency name="VCSBase" version="1.2.90"/>
</dependencyList>
</plugin>
......@@ -1034,7 +1034,7 @@ static inline QString msgExecutionLogEntry(const QString &workingDir, const QStr
const QString args = arguments.join(QString(QLatin1Char(' ')));
if (workingDir.isEmpty())
return CVSPlugin::tr("Executing: %1 %2\n").arg(executable, args);
return CVSPlugin::tr("Executing in %1: %2 %2\n").arg(workingDir, executable, args);
return CVSPlugin::tr("Executing in %1: %2 %3\n").arg(workingDir, executable, args);
}
// Figure out a working directory for the process,
......
<plugin name="Debugger" version="1.2.80" compatVersion="1.2.80">
<plugin name="Debugger" version="1.2.90" compatVersion="1.2.90">
<vendor>Nokia Corporation</vendor>
<copyright>(C) 2008-2009 Nokia Corporation</copyright>
<license>
......@@ -19,10 +19,10 @@ will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.</license>
<description>Debugger integration.</description>
<url>http://qt.nokia.com</url>
<dependencyList>
<dependency name="CppEditor" version="1.2.80"/><!-- Debugger plugin adds items to the editor's context menu -->
<dependency name="ProjectExplorer" version="1.2.80"/>
<dependency name="Core" version="1.2.80"/>
<dependency name="Find" version="1.2.80"/>
<dependency name="CppEditor" version="1.2.90"/><!-- Debugger plugin adds items to the editor's context menu -->
<dependency name="ProjectExplorer" version="1.2.90"/>
<dependency name="Core" version="1.2.90"/>
<dependency name="Find" version="1.2.90"/>
</dependencyList>
<argumentList>
<argument name="-disable-cdb">Disable Cdb debugger engine</argument>
......
......@@ -196,13 +196,14 @@ void BreakWindow::contextMenuEvent(QContextMenuEvent *ev)
menu.addAction(deleteAllAction);
menu.addAction(deleteByFileAction);
menu.addSeparator();
menu.addAction(adjustColumnAction);
menu.addAction(alwaysAdjustAction);
menu.addAction(synchronizeAction);
menu.addSeparator();
menu.addAction(breakAtFunctionAction);
menu.addAction(breakAtMainAction);
menu.addSeparator();
menu.addAction(adjustColumnAction);
menu.addAction(alwaysAdjustAction);
menu.addSeparator();
menu.addAction(theDebuggerAction(SettingsDialog));
QAction *act = menu.exec(ev->globalPos());
......
......@@ -400,7 +400,7 @@ bool CdbDebugEnginePrivate::setCodeLevel()
}
if (debugCDB)
qDebug() << Q_FUNC_INFO << "\nSetting code level to " << codeLevelName(codeLevel) << " (was" << codeLevelName(currentCodeLevel) << ')';
if (currentCodeLevel == currentCodeLevel)
if (currentCodeLevel == codeLevel)
return false;
hr = m_cif.debugControl->SetCodeLevel(codeLevel);
if (FAILED(hr)) {
......@@ -1337,6 +1337,23 @@ void CdbDebugEngine::fetchDisassembler(DisassemblerViewAgent *agent,
}
}
void CdbDebugEngine::fetchMemory(MemoryViewAgent *agent, quint64 addr, quint64 length)
{
if (!m_d->m_hDebuggeeProcess && !length)
return;
ULONG received;
QByteArray data(length, '\0');
const HRESULT hr = m_d->m_cif.debugDataSpaces->ReadVirtual(addr, data.data(), length, &received);
if (FAILED(hr)) {
warning(tr("Unable to retrieve %1 bytes of memory at 0x%2: %3").
arg(length).arg(addr, 0, 16).arg(msgComFailed("ReadVirtual", hr)));
return;
}
if (received < length)
data.truncate(received);
agent->addLazyData(addr, data);
}
void CdbDebugEngine::reloadModules()
{
}
......
......@@ -89,6 +89,7 @@ public:
virtual void fetchDisassembler(DisassemblerViewAgent *agent,
const StackFrame &frame);
virtual void fetchMemory(MemoryViewAgent *, quint64 addr, quint64 length);
virtual void reloadModules();
virtual void loadSymbols(const QString &moduleName);
......
......@@ -709,8 +709,9 @@ int CdbSymbolGroupContext::dumpQString(CIDebugDataSpaces *ds, WatchData *wd)
if (truncated)
size = maxLength;
const QChar doubleQuote = QLatin1Char('"');
QString value(doubleQuote);
if (size) {
QString value;
if (size > 0) {
value += doubleQuote;
// Should this ever be a remote debugger, need to check byte order.
unsigned short *buf = new unsigned short[size + 1];
unsigned long bytesRead;
......@@ -724,8 +725,13 @@ int CdbSymbolGroupContext::dumpQString(CIDebugDataSpaces *ds, WatchData *wd)
delete [] buf;
if (truncated)
value += QLatin1String("...");
}
value += doubleQuote;
} else if (size == 0) {
value = QString(doubleQuote) + doubleQuote;
} else {
value = "Invalid QString";
}
wd->setValue(value);
wd->setHasChildren(false);
return 0;
......