Merge remote-tracking branch 'origin/4.0'
Conflicts: qtcreator.pri qtcreator.qbs Change-Id: I0cbc9d335073e3234f472aa43f462eef9a9178aa
|
Before Width: | Height: | Size: 56 KiB After Width: | Height: | Size: 34 KiB |
|
Before Width: | Height: | Size: 5.7 KiB After Width: | Height: | Size: 4.4 KiB |
|
Before Width: | Height: | Size: 6.0 KiB After Width: | Height: | Size: 6.1 KiB |
BIN
doc/images/qtcreator-debugger-cdb-paths.png
Normal file
|
After Width: | Height: | Size: 8.8 KiB |
|
Before Width: | Height: | Size: 14 KiB After Width: | Height: | Size: 10 KiB |
|
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 5.1 KiB |
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 7.1 KiB After Width: | Height: | Size: 8.5 KiB |
|
Before Width: | Height: | Size: 6.0 KiB After Width: | Height: | Size: 5.0 KiB |
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 34 KiB |
@@ -55,7 +55,8 @@
|
||||
\li Select \uicontrol Debug > \uicontrol {Start Debugging} >
|
||||
\uicontrol {Start Debugging} or press \key F5.
|
||||
|
||||
\li To view the breakpoint, click the \uicontrol Breakpoints tab.
|
||||
\li To view information about the breakpoint, go to the
|
||||
\uicontrol Breakpoints view.
|
||||
|
||||
\image qtcreator-setting-breakpoint2.png
|
||||
|
||||
|
||||
@@ -62,8 +62,7 @@
|
||||
|
||||
\note To use the debugging tools for Windows, you must install them and add
|
||||
the Symbol Server provided by Microsoft to the symbol search path of the
|
||||
debugger. For more information, see \l{Setting the Symbol Server in
|
||||
Windows}.
|
||||
debugger. For more information, see \l{Setting CDB Paths on Windows}.
|
||||
|
||||
\note To use the Free Software Foundation (FSF) version of GDB on OS X, you
|
||||
must sign it and modify your \l{glossary-buildandrun-kit}{kit} settings.
|
||||
@@ -209,7 +208,7 @@
|
||||
Symbol Server provides you with debugging informaton for the
|
||||
operating system libraries for debugging Windows applications.
|
||||
For more information, see
|
||||
\l{Setting the Symbol Server in Windows}.
|
||||
\l{Setting CDB Paths on Windows}.
|
||||
|
||||
\row
|
||||
\li Debugging tools for OS X
|
||||
@@ -252,7 +251,7 @@
|
||||
|
||||
\endlist
|
||||
|
||||
\section1 Setting the Symbol Server in Windows
|
||||
\section1 Setting CDB Paths on Windows
|
||||
|
||||
To obtain debugging information for the operating system libraries for
|
||||
debugging Windows applications, add the Symbol Server provided by Microsoft
|
||||
@@ -261,24 +260,27 @@
|
||||
\list 1
|
||||
|
||||
\li Select \uicontrol Tools > \uicontrol Options > \uicontrol Debugger >
|
||||
\uicontrol CDB.
|
||||
\uicontrol {CDB Paths}.
|
||||
|
||||
\li In the \uicontrol {Symbol paths} field, open the \uicontrol Insert
|
||||
menu and select \uicontrol{Symbol Server}.
|
||||
\image qtcreator-debugger-cdb-paths.png
|
||||
|
||||
\li Select a directory where you want to store the cached information
|
||||
and click \uicontrol OK.
|
||||
\li In the \uicontrol {Symbol Paths} group, select \uicontrol Insert.
|
||||
|
||||
\li Select the directory where you want to store the cached information.
|
||||
|
||||
Use a subfolder in a temporary directory, such as
|
||||
\c {C:\temp\symbolcache}.
|
||||
|
||||
\li Select \uicontrol OK.
|
||||
|
||||
\endlist
|
||||
|
||||
\note Populating the cache might take a long time on a slow network
|
||||
connection.
|
||||
|
||||
\note The first time you start debugging by using the Debugging tools for
|
||||
Windows, \QC prompts you to add the Symbol Server.
|
||||
To use the Source Server infrastructure for fetching missing source files
|
||||
directly from version control or the web, enter the following string in
|
||||
the \uicontrol {Source Paths} field: \c srv*.
|
||||
|
||||
\section1 Setting up FSF GDB for OS X
|
||||
|
||||
|
||||
@@ -684,7 +684,7 @@
|
||||
\li \b{Note:}
|
||||
|
||||
\row
|
||||
\li GDB and LLDB, and therefore \QC's debugger, work for optimized
|
||||
\li GDB and LLDB, and therefore \QC's debugger, also work for optimized
|
||||
builds on Linux and OS X. Optimization can lead to re-ordering
|
||||
of instructions or removal of some local variables, causing the
|
||||
\uicontrol {Locals and Expressions} view to show unexpected
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
|
||||
\section1 Adding CMake Tools
|
||||
|
||||
\QC supports CMake version 2.9, or later.
|
||||
\QC supports CMake version 3.0, or later.
|
||||
|
||||
To specify paths to CMake executables and to add them to kits:
|
||||
|
||||
|
||||
@@ -1040,13 +1040,13 @@ class Dumper(DumperBase):
|
||||
# Works:
|
||||
#item = self.currentThread().GetSelectedFrame().EvaluateExpression(
|
||||
# "(%s*)0x%x" % (type, addr)).Dereference()
|
||||
# Works:
|
||||
item = value.CreateValueFromExpression(None,
|
||||
"(%s*)0x%x" % (type, addr), lldb.SBExpressionOptions()).Dereference()
|
||||
# Does not work on lldb-350.0.21.3:
|
||||
#item = value.CreateValueFromExpression(None,
|
||||
# "(%s*)0x%x" % (type, addr), lldb.SBExpressionOptions()).Dereference()
|
||||
# Does not work:
|
||||
#item = value.CreateValueFromAddress(None, addr, type)
|
||||
# Does not work:
|
||||
#item = value.Cast(type.GetPointerType()).Dereference()
|
||||
# Works:
|
||||
item = value.Cast(type.GetPointerType()).Dereference()
|
||||
#warn("TOOO: %s" % item)
|
||||
self.putItem(item)
|
||||
self.putBetterType(value.GetTypeName())
|
||||
|
||||
@@ -2192,6 +2192,13 @@ def qdump__QVariant(d, value):
|
||||
|
||||
return innert
|
||||
|
||||
# Do not handle user types. The workaround below works, sometimes
|
||||
# for inialized data, but can force loading all debug information
|
||||
# and trigger parse errors "error: need to add support for
|
||||
# DW_TAG_base_type 'auto' encoded with DW_ATE = 0x0, bit_size = 0"
|
||||
# (LLDB 3.7/Linux)
|
||||
if d.isLldb and platform.system() == "Linux":
|
||||
return None
|
||||
|
||||
# User types.
|
||||
d_ptr = value["d"]
|
||||
|
||||
@@ -1050,7 +1050,7 @@ InformationChangedCommand NodeInstanceServer::createAllInformationChangedCommand
|
||||
static bool supportedVariantType(int type)
|
||||
{
|
||||
return type < int(QVariant::UserType) && type != QMetaType::QObjectStar
|
||||
&& type != QMetaType::QModelIndex;
|
||||
&& type != QMetaType::QModelIndex && type != QMetaType::VoidStar;
|
||||
}
|
||||
|
||||
ValuesChangedCommand NodeInstanceServer::createValuesChangedCommand(const QList<ServerNodeInstance> &instanceList) const
|
||||
|
||||
@@ -53,6 +53,7 @@
|
||||
|
||||
|
||||
#include <designersupportdelegate.h>
|
||||
#include <cstring>
|
||||
|
||||
namespace QmlDesigner {
|
||||
|
||||
@@ -199,7 +200,7 @@ static void allSubObject(QObject *object, QObjectList &objectList)
|
||||
if (metaProperty.isReadable()
|
||||
&& metaProperty.isWritable()
|
||||
&& QQmlMetaType::isQObject(metaProperty.userType())) {
|
||||
if (metaProperty.name() != "parent") {
|
||||
if (strcmp(metaProperty.name(), "parent") != 0) {
|
||||
QObject *propertyObject = QQmlMetaType::toQObject(metaProperty.read(object));
|
||||
allSubObject(propertyObject, objectList);
|
||||
}
|
||||
|
||||
@@ -58,9 +58,12 @@ IconsWarningToolBarColor=ffe0b716
|
||||
IconsErrorColor=ffd84044
|
||||
IconsErrorToolBarColor=ffd84044
|
||||
IconsRunColor=ff7fc341
|
||||
IconsRunToolBarColor=ff7fc341
|
||||
IconsStopColor=ffe7353b
|
||||
IconsDebugColor=ffb8c6ff
|
||||
IconsStopToolBarColor=ffe7353b
|
||||
IconsInterruptColor=ff7488db
|
||||
IconsInterruptToolBarColor=ff7488db
|
||||
IconsDebugColor=ffb8c6ff
|
||||
IconsNavigationArrowsColor=ffebc322
|
||||
IconsBuildHammerHandleColor=ffdd7710
|
||||
IconsBuildHammerHeadColor=ff989898
|
||||
|
||||
@@ -51,10 +51,13 @@ IconsWarningColor=ffecbc1c
|
||||
IconsWarningToolBarColor=fff2d76e
|
||||
IconsErrorColor=ffdf4f4f
|
||||
IconsErrorToolBarColor=ffdb6f71
|
||||
IconsRunColor=ffa4d576
|
||||
IconsStopColor=ffff8c8c
|
||||
IconsRunColor=ff6da838
|
||||
IconsRunToolBarColor=ffa4d576
|
||||
IconsStopColor=ffee6969
|
||||
IconsStopToolBarColor=ffff8c8c
|
||||
IconsInterruptColor=ff587ff7
|
||||
IconsInterruptToolBarColor=ff8f9dda
|
||||
IconsDebugColor=ffdcdcdc
|
||||
IconsInterruptColor=ff8f9dda
|
||||
IconsNavigationArrowsColor=ffebc322
|
||||
IconsBuildHammerHandleColor=ffdd7710
|
||||
IconsBuildHammerHeadColor=ff989898
|
||||
|
||||
@@ -61,10 +61,13 @@ IconsWarningColor=ffecbc1c
|
||||
IconsWarningToolBarColor=fff2d76e
|
||||
IconsErrorColor=ffdf4f4f
|
||||
IconsErrorToolBarColor=ffdb6f71
|
||||
IconsRunColor=ff93be6c
|
||||
IconsStopColor=ffe27f7f
|
||||
IconsRunColor=ff6da838
|
||||
IconsRunToolBarColor=ff93be6c
|
||||
IconsStopColor=ffee6969
|
||||
IconsStopToolBarColor=ffe27f7f
|
||||
IconsInterruptColor=ff587ff7
|
||||
IconsInterruptToolBarColor=ff6a7bc3
|
||||
IconsDebugColor=toolBarItem
|
||||
IconsInterruptColor=ff6a7bc3
|
||||
IconsNavigationArrowsColor=ffebc322
|
||||
IconsBuildHammerHandleColor=ffc26b14
|
||||
IconsBuildHammerHeadColor=ff868687
|
||||
|
||||
65
src/libs/3rdparty/cplusplus/Parser.cpp
vendored
@@ -162,13 +162,25 @@ class Parser::ASTCache
|
||||
|
||||
public:
|
||||
enum ASTKind {
|
||||
Declaration,
|
||||
Expression,
|
||||
ExpressionList,
|
||||
MemberSpecification,
|
||||
ParameterDeclarationClause,
|
||||
TemplateId,
|
||||
TypeId
|
||||
};
|
||||
|
||||
struct CacheKey {
|
||||
CacheKey(unsigned initialCursor, ASTKind astKind)
|
||||
: initialCursor(initialCursor)
|
||||
, astKind(astKind)
|
||||
{}
|
||||
|
||||
const unsigned initialCursor;
|
||||
const ASTKind astKind;
|
||||
};
|
||||
|
||||
public:
|
||||
ASTCache() {}
|
||||
|
||||
@@ -255,6 +267,17 @@ inline void debugPrintCheckCache(bool) {}
|
||||
} \
|
||||
} while (0)
|
||||
|
||||
#define CACHE_AND_RETURN(cacheKey, expression) \
|
||||
do { \
|
||||
const bool result = expression; \
|
||||
_astCache->insert(cacheKey.astKind, \
|
||||
cacheKey.initialCursor, \
|
||||
result ? node : 0, \
|
||||
cursor(), \
|
||||
result); \
|
||||
return result; \
|
||||
} while (0)
|
||||
|
||||
#define PARSE_EXPRESSION_WITH_OPERATOR_PRECEDENCE(node, minPrecedence) { \
|
||||
if (LA() == T_THROW) { \
|
||||
if (!parseThrowExpression(node)) \
|
||||
@@ -2480,6 +2503,9 @@ bool Parser::parseQtInterfaces(DeclarationAST *&node)
|
||||
bool Parser::parseMemberSpecification(DeclarationAST *&node, ClassSpecifierAST *declaringClass)
|
||||
{
|
||||
DEBUG_THIS_RULE();
|
||||
const ASTCache::CacheKey cacheKey(cursor(), ASTCache::MemberSpecification);
|
||||
CHECK_CACHE(cacheKey.astKind, DeclarationAST);
|
||||
|
||||
switch (LA()) {
|
||||
case T_Q_OBJECT:
|
||||
case T_Q_GADGET:
|
||||
@@ -2487,7 +2513,7 @@ bool Parser::parseMemberSpecification(DeclarationAST *&node, ClassSpecifierAST *
|
||||
QtObjectTagAST *ast = new (_pool) QtObjectTagAST;
|
||||
ast->q_object_token = consumeToken();
|
||||
node = ast;
|
||||
return true;
|
||||
CACHE_AND_RETURN(cacheKey, true);
|
||||
}
|
||||
|
||||
case T_Q_PRIVATE_SLOT:
|
||||
@@ -2505,44 +2531,44 @@ bool Parser::parseMemberSpecification(DeclarationAST *&node, ClassSpecifierAST *
|
||||
parseDeclarator(ast->declarator, ast->type_specifier_list);
|
||||
match(T_RPAREN, &ast->rparen_token);
|
||||
node = ast;
|
||||
} return true;
|
||||
} CACHE_AND_RETURN(cacheKey, true);
|
||||
|
||||
case T_SEMICOLON:
|
||||
return parseEmptyDeclaration(node);
|
||||
CACHE_AND_RETURN(cacheKey, parseEmptyDeclaration(node));
|
||||
|
||||
case T_USING:
|
||||
return parseUsing(node);
|
||||
CACHE_AND_RETURN(cacheKey, parseUsing(node));
|
||||
|
||||
case T_TEMPLATE:
|
||||
return parseTemplateDeclaration(node);
|
||||
CACHE_AND_RETURN(cacheKey, parseTemplateDeclaration(node));
|
||||
|
||||
case T_Q_SIGNALS:
|
||||
case T_PUBLIC:
|
||||
case T_PROTECTED:
|
||||
case T_PRIVATE:
|
||||
case T_Q_SLOTS:
|
||||
return parseAccessDeclaration(node);
|
||||
CACHE_AND_RETURN(cacheKey, parseAccessDeclaration(node));
|
||||
|
||||
case T_Q_PROPERTY:
|
||||
case T_Q_PRIVATE_PROPERTY:
|
||||
return parseQtPropertyDeclaration(node);
|
||||
CACHE_AND_RETURN(cacheKey, parseQtPropertyDeclaration(node));
|
||||
|
||||
case T_Q_ENUMS:
|
||||
return parseQtEnumDeclaration(node);
|
||||
CACHE_AND_RETURN(cacheKey, parseQtEnumDeclaration(node));
|
||||
|
||||
case T_Q_FLAGS:
|
||||
return parseQtFlags(node);
|
||||
CACHE_AND_RETURN(cacheKey, parseQtFlags(node));
|
||||
|
||||
case T_Q_INTERFACES:
|
||||
return parseQtInterfaces(node);
|
||||
CACHE_AND_RETURN(cacheKey, parseQtInterfaces(node));
|
||||
|
||||
case T_STATIC_ASSERT:
|
||||
if (_languageFeatures.cxx11Enabled)
|
||||
return parseStaticAssertDeclaration(node);
|
||||
CACHE_AND_RETURN(cacheKey, parseStaticAssertDeclaration(node));
|
||||
// fall-through
|
||||
|
||||
default:
|
||||
return parseSimpleDeclaration(node, declaringClass);
|
||||
CACHE_AND_RETURN(cacheKey, parseSimpleDeclaration(node, declaringClass));
|
||||
} // switch
|
||||
}
|
||||
|
||||
@@ -4074,6 +4100,9 @@ bool Parser::parseBuiltinTypeSpecifier(SpecifierListAST *&node)
|
||||
bool Parser::parseSimpleDeclaration(DeclarationAST *&node, ClassSpecifierAST *declaringClass)
|
||||
{
|
||||
DEBUG_THIS_RULE();
|
||||
const ASTCache::CacheKey cacheKey(cursor(), ASTCache::Declaration);
|
||||
CHECK_CACHE(cacheKey.astKind, DeclarationAST);
|
||||
|
||||
unsigned qt_invokable_token = 0;
|
||||
if (declaringClass && (LA() == T_Q_SIGNAL || LA() == T_Q_SLOT || LA() == T_Q_INVOKABLE))
|
||||
qt_invokable_token = consumeToken();
|
||||
@@ -4188,7 +4217,7 @@ bool Parser::parseSimpleDeclaration(DeclarationAST *&node, ClassSpecifierAST *de
|
||||
}
|
||||
}
|
||||
if (! parseInitDeclarator(declarator, decl_specifier_seq, declaringClass))
|
||||
return false;
|
||||
CACHE_AND_RETURN(cacheKey, false);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4196,7 +4225,7 @@ bool Parser::parseSimpleDeclaration(DeclarationAST *&node, ClassSpecifierAST *de
|
||||
// and it doesn't look like a fwd or a class declaration
|
||||
// then it's not a declarations
|
||||
if (! declarator && ! maybeForwardOrClassDeclaration(decl_specifier_seq))
|
||||
return false;
|
||||
CACHE_AND_RETURN(cacheKey, false);
|
||||
|
||||
DeclaratorAST *firstDeclarator = declarator;
|
||||
|
||||
@@ -4223,7 +4252,7 @@ bool Parser::parseSimpleDeclaration(DeclarationAST *&node, ClassSpecifierAST *de
|
||||
ast->declarator_list = declarator_list;
|
||||
match(T_SEMICOLON, &ast->semicolon_token);
|
||||
node = ast;
|
||||
return true;
|
||||
CACHE_AND_RETURN(cacheKey, true);
|
||||
} else if (! _inFunctionBody && declarator && (LA() == T_COLON || LA() == T_LBRACE || LA() == T_TRY)) {
|
||||
if (LA() == T_TRY) {
|
||||
FunctionDefinitionAST *ast = new (_pool) FunctionDefinitionAST;
|
||||
@@ -4232,7 +4261,7 @@ bool Parser::parseSimpleDeclaration(DeclarationAST *&node, ClassSpecifierAST *de
|
||||
ast->declarator = firstDeclarator;
|
||||
parseTryBlockStatement(ast->function_body, &ast->ctor_initializer);
|
||||
node = ast;
|
||||
return true; // recognized a function definition.
|
||||
CACHE_AND_RETURN(cacheKey, true); // recognized a function definition.
|
||||
} else {
|
||||
CtorInitializerAST *ctor_initializer = 0;
|
||||
bool hasCtorInitializer = false;
|
||||
@@ -4263,13 +4292,13 @@ bool Parser::parseSimpleDeclaration(DeclarationAST *&node, ClassSpecifierAST *de
|
||||
ast->ctor_initializer = ctor_initializer;
|
||||
parseFunctionBody(ast->function_body);
|
||||
node = ast;
|
||||
return true; // recognized a function definition.
|
||||
CACHE_AND_RETURN(cacheKey, true); // recognized a function definition.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
error(cursor(), "unexpected token `%s'", tok().spell());
|
||||
return false;
|
||||
CACHE_AND_RETURN(cacheKey, false);
|
||||
}
|
||||
|
||||
bool Parser::maybeForwardOrClassDeclaration(SpecifierListAST *decl_specifier_seq) const
|
||||
|
||||
@@ -91,7 +91,7 @@ static const QIcon &icon(IconIndex icon)
|
||||
case OkIcon: {
|
||||
static const QIcon ok =
|
||||
Icon({{QLatin1String(":/extensionsystem/images/ok.png"),
|
||||
Theme::IconsRunColor}}, Icon::Tint).icon();
|
||||
Theme::IconsRunToolBarColor}}, Icon::Tint).icon();
|
||||
return ok;
|
||||
}
|
||||
case ErrorIcon: {
|
||||
|
||||
@@ -183,12 +183,15 @@ QIcon Icon::icon() const
|
||||
return QIcon(combinedPlainPixmaps(*this));
|
||||
} else {
|
||||
QIcon result;
|
||||
const MasksAndColors masks = masksAndColors(*this, qRound(qApp->devicePixelRatio()));
|
||||
const int maxDpr = qRound(qApp->devicePixelRatio());
|
||||
for (int dpr = 1; dpr <= maxDpr; dpr++) {
|
||||
const MasksAndColors masks = masksAndColors(*this, dpr);
|
||||
const QPixmap combinedMask = Utils::combinedMask(masks, m_style);
|
||||
result.addPixmap(masksToIcon(masks, combinedMask, m_style));
|
||||
|
||||
const QColor disabledColor = creatorTheme()->color(Theme::IconsDisabledColor);
|
||||
result.addPixmap(maskToColorAndAlpha(combinedMask, disabledColor), QIcon::Disabled);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -51,7 +51,8 @@ public:
|
||||
DropShadow = 2,
|
||||
PunchEdges = 4,
|
||||
|
||||
ToolBarStyle = Tint | DropShadow | PunchEdges
|
||||
ToolBarStyle = Tint | DropShadow | PunchEdges,
|
||||
MenuTintedStyle = Tint | PunchEdges
|
||||
};
|
||||
|
||||
Q_DECLARE_FLAGS(IconStyleOptions, IconStyleOption)
|
||||
|
||||
@@ -136,8 +136,11 @@ public:
|
||||
IconsErrorColor,
|
||||
IconsErrorToolBarColor,
|
||||
IconsRunColor,
|
||||
IconsRunToolBarColor,
|
||||
IconsStopColor,
|
||||
IconsStopToolBarColor,
|
||||
IconsInterruptColor,
|
||||
IconsInterruptToolBarColor,
|
||||
IconsDebugColor,
|
||||
IconsNavigationArrowsColor,
|
||||
IconsBuildHammerHandleColor,
|
||||
|
||||
@@ -44,7 +44,7 @@ AndroidRunControl::AndroidRunControl(AndroidRunConfiguration *rc)
|
||||
, m_running(false)
|
||||
{
|
||||
setRunnable(m_runner->runnable());
|
||||
setIcon(Core::Icons::RUN_SMALL);
|
||||
setIcon(Core::Icons::RUN_SMALL_TOOLBAR);
|
||||
}
|
||||
|
||||
AndroidRunControl::~AndroidRunControl()
|
||||
|
||||
@@ -288,6 +288,9 @@ static QString testClass(const CppTools::CppModelManager *modelManager, const QS
|
||||
{
|
||||
const QByteArray &fileContent = getFileContent(fileName);
|
||||
CPlusPlus::Document::Ptr document = modelManager->document(fileName);
|
||||
if (document.isNull())
|
||||
return QString();
|
||||
|
||||
const QList<CPlusPlus::Document::MacroUse> macros = document->macroUses();
|
||||
|
||||
foreach (const CPlusPlus::Document::MacroUse ¯o, macros) {
|
||||
@@ -604,6 +607,8 @@ static void performParse(QFutureInterface<TestParseResult> &futureInterface,
|
||||
QmlJS::Snapshot qmlSnapshot = QmlJSTools::Internal::ModelManager::instance()->snapshot();
|
||||
|
||||
foreach (const QString &file, list) {
|
||||
if (futureInterface.isCanceled())
|
||||
return;
|
||||
if (file.endsWith(QLatin1String(".qml"))) {
|
||||
checkQmlDocumentForTestCode(futureInterface, qmlSnapshot.document(file));
|
||||
} else if (snapshot.contains(file)) {
|
||||
@@ -693,6 +698,7 @@ bool TestCodeParser::postponed(const QStringList &fileList)
|
||||
m_partialUpdatePostponed = false;
|
||||
m_postponedFiles.clear();
|
||||
m_fullUpdatePostponed = true;
|
||||
Core::ProgressManager::instance()->cancelTasks(Constants::TASK_PARSE);
|
||||
} else {
|
||||
// partial parse triggered, but full parse is postponed already, ignoring this
|
||||
if (m_fullUpdatePostponed)
|
||||
|
||||
@@ -158,13 +158,13 @@ void TestResultsPane::createToolButtons()
|
||||
});
|
||||
|
||||
m_runAll = new QToolButton(m_treeView);
|
||||
m_runAll->setIcon(Core::Icons::RUN_SMALL.icon());
|
||||
m_runAll->setIcon(Core::Icons::RUN_SMALL_TOOLBAR.icon());
|
||||
m_runAll->setToolTip(tr("Run All Tests"));
|
||||
m_runAll->setEnabled(false);
|
||||
connect(m_runAll, &QToolButton::clicked, this, &TestResultsPane::onRunAllTriggered);
|
||||
|
||||
m_runSelected = new QToolButton(m_treeView);
|
||||
Utils::Icon runSelectedIcon = Core::Icons::RUN_SMALL;
|
||||
Utils::Icon runSelectedIcon = Core::Icons::RUN_SMALL_TOOLBAR;
|
||||
foreach (const Utils::IconMaskAndColor &maskAndColor, Icons::RUN_SELECTED_OVERLAY)
|
||||
runSelectedIcon.append(maskAndColor);
|
||||
m_runSelected->setIcon(runSelectedIcon.icon());
|
||||
@@ -173,7 +173,7 @@ void TestResultsPane::createToolButtons()
|
||||
connect(m_runSelected, &QToolButton::clicked, this, &TestResultsPane::onRunSelectedTriggered);
|
||||
|
||||
m_stopTestRun = new QToolButton(m_treeView);
|
||||
m_stopTestRun->setIcon(Core::Icons::STOP_SMALL.icon());
|
||||
m_stopTestRun->setIcon(Core::Icons::STOP_SMALL_TOOLBAR.icon());
|
||||
m_stopTestRun->setToolTip(tr("Stop Test Run"));
|
||||
m_stopTestRun->setEnabled(false);
|
||||
connect(m_stopTestRun, &QToolButton::clicked, TestRunner::instance(), &TestRunner::requestStopTestRun);
|
||||
|
||||
@@ -101,6 +101,7 @@ ClangCompletionContextAnalyzer::analyzeFunctionCall(int endOfOperator) const
|
||||
|
||||
ExpressionUnderCursor euc(m_languageFeatures);
|
||||
index = euc.startOfFunctionCall(textCursor);
|
||||
index = ActivationSequenceContextProcessor::skipPrecedingWhitespace(m_interface, index);
|
||||
const int functionNameStart = ActivationSequenceContextProcessor::findStartOfName(m_interface,
|
||||
index);
|
||||
|
||||
@@ -159,9 +160,14 @@ void ClangCompletionContextAnalyzer::handleFunctionCall(int afterOperatorPositio
|
||||
setActionAndClangPosition(PassThroughToLibClang, afterOperatorPosition);
|
||||
} else {
|
||||
const FunctionInfo functionInfo = analyzeFunctionCall(afterOperatorPosition);
|
||||
if (functionInfo.isValid()) {
|
||||
m_functionName = functionInfo.functionName;
|
||||
setActionAndClangPosition(PassThroughToLibClangAfterLeftParen,
|
||||
functionInfo.functionNamePosition);
|
||||
} else {
|
||||
m_positionForProposal = afterOperatorPosition;
|
||||
setActionAndClangPosition(PassThroughToLibClang, afterOperatorPosition);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -63,7 +63,12 @@ public:
|
||||
private:
|
||||
ClangCompletionContextAnalyzer();
|
||||
|
||||
struct FunctionInfo { int functionNamePosition; QString functionName; };
|
||||
struct FunctionInfo {
|
||||
bool isValid() const { return functionNamePosition != -1 && !functionName.isEmpty(); }
|
||||
|
||||
int functionNamePosition = -1;
|
||||
QString functionName;
|
||||
};
|
||||
FunctionInfo analyzeFunctionCall(int endOfExpression) const;
|
||||
|
||||
void setActionAndClangPosition(CompletionAction action, int position);
|
||||
|
||||
@@ -75,6 +75,7 @@ ClangStaticAnalyzerRunControl::ClangStaticAnalyzerRunControl(
|
||||
, m_filesAnalyzed(0)
|
||||
, m_filesNotAnalyzed(0)
|
||||
{
|
||||
setDisplayName(tr("Clang Static Analyzer"));
|
||||
Target *target = runConfiguration->target();
|
||||
BuildConfiguration *buildConfiguration = target->activeBuildConfiguration();
|
||||
QTC_ASSERT(buildConfiguration, return);
|
||||
@@ -82,7 +83,7 @@ ClangStaticAnalyzerRunControl::ClangStaticAnalyzerRunControl(
|
||||
|
||||
ToolChain *toolChain = ToolChainKitInformation::toolChain(target->kit());
|
||||
QTC_ASSERT(toolChain, return);
|
||||
m_extraToolChainInfo.wordWidth = runConfiguration->abi().wordWidth();
|
||||
m_extraToolChainInfo.wordWidth = toolChain->targetAbi().wordWidth();
|
||||
m_extraToolChainInfo.targetTriple = toolChain->originalTargetTriple();
|
||||
}
|
||||
|
||||
|
||||
@@ -60,6 +60,22 @@ using namespace Utils;
|
||||
namespace ClangStaticAnalyzer {
|
||||
namespace Internal {
|
||||
|
||||
class DummyRunConfiguration : public RunConfiguration
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DummyRunConfiguration(Target *parent)
|
||||
: RunConfiguration(parent, "ClangStaticAnalyzer.DummyRunConfig")
|
||||
{
|
||||
setDefaultDisplayName(tr("Clang Static Analyzer"));
|
||||
addExtraAspects();
|
||||
}
|
||||
|
||||
private:
|
||||
QWidget *createConfigurationWidget() override { return 0; }
|
||||
};
|
||||
|
||||
ClangStaticAnalyzerTool::ClangStaticAnalyzerTool(QObject *parent)
|
||||
: QObject(parent)
|
||||
, m_diagnosticModel(0)
|
||||
@@ -107,7 +123,7 @@ ClangStaticAnalyzerTool::ClangStaticAnalyzerTool(QObject *parent)
|
||||
// Go to previous diagnostic
|
||||
auto action = new QAction(this);
|
||||
action->setDisabled(true);
|
||||
action->setIcon(Core::Icons::PREV.icon());
|
||||
action->setIcon(Core::Icons::PREV_TOOLBAR.icon());
|
||||
action->setToolTip(tr("Go to previous bug."));
|
||||
connect(action, &QAction::triggered, m_diagnosticView, &DetailedErrorView::goBack);
|
||||
m_goBack = action;
|
||||
@@ -115,7 +131,7 @@ ClangStaticAnalyzerTool::ClangStaticAnalyzerTool(QObject *parent)
|
||||
// Go to next diagnostic
|
||||
action = new QAction(this);
|
||||
action->setDisabled(true);
|
||||
action->setIcon(Core::Icons::NEXT.icon());
|
||||
action->setIcon(Core::Icons::NEXT_TOOLBAR.icon());
|
||||
action->setToolTip(tr("Go to next bug."));
|
||||
connect(action, &QAction::triggered, m_diagnosticView, &DetailedErrorView::goNext);
|
||||
m_goNext = action;
|
||||
@@ -137,7 +153,8 @@ ClangStaticAnalyzerTool::ClangStaticAnalyzerTool(QObject *parent)
|
||||
return createRunControl(runConfiguration, runMode);
|
||||
});
|
||||
desc.setCustomToolStarter([this](RunConfiguration *runConfiguration) {
|
||||
startTool(runConfiguration);
|
||||
Q_UNUSED(runConfiguration);
|
||||
startTool();
|
||||
});
|
||||
desc.setMenuGroup(Debugger::Constants::G_ANALYZER_TOOLS);
|
||||
Debugger::registerAction(ClangStaticAnalyzerActionId, desc, m_startAction);
|
||||
@@ -220,7 +237,7 @@ static bool dontStartAfterHintForDebugMode(Project *project)
|
||||
return false;
|
||||
}
|
||||
|
||||
void ClangStaticAnalyzerTool::startTool(ProjectExplorer::RunConfiguration *runConfiguration)
|
||||
void ClangStaticAnalyzerTool::startTool()
|
||||
{
|
||||
Project *project = SessionManager::startupProject();
|
||||
QTC_ASSERT(project, emit finished(false); return);
|
||||
@@ -236,8 +253,21 @@ void ClangStaticAnalyzerTool::startTool(ProjectExplorer::RunConfiguration *runCo
|
||||
m_running = true;
|
||||
handleStateUpdate();
|
||||
|
||||
ProjectExplorerPlugin::runRunConfiguration(runConfiguration,
|
||||
Constants::CLANGSTATICANALYZER_RUN_MODE);
|
||||
Target * const target = project->activeTarget();
|
||||
QTC_ASSERT(target, return);
|
||||
DummyRunConfiguration *& rc = m_runConfigs[target];
|
||||
if (!rc) {
|
||||
rc = new DummyRunConfiguration(target);
|
||||
connect(project, &Project::aboutToRemoveTarget, this,
|
||||
[this](Target *t) { m_runConfigs.remove(t); });
|
||||
const auto onProjectRemoved = [this](Project *p) {
|
||||
foreach (Target * const t, p->targets())
|
||||
m_runConfigs.remove(t);
|
||||
};
|
||||
connect(SessionManager::instance(), &SessionManager::aboutToRemoveProject, this,
|
||||
onProjectRemoved, Qt::UniqueConnection);
|
||||
}
|
||||
ProjectExplorerPlugin::runRunConfiguration(rc, Constants::CLANGSTATICANALYZER_RUN_MODE);
|
||||
}
|
||||
|
||||
CppTools::ProjectInfo ClangStaticAnalyzerTool::projectInfoBeforeBuild() const
|
||||
@@ -325,3 +355,5 @@ void ClangStaticAnalyzerTool::handleStateUpdate()
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace ClangStaticAnalyzer
|
||||
|
||||
#include "clangstaticanalyzertool.moc"
|
||||
|
||||
@@ -37,6 +37,7 @@ class ClangStaticAnalyzerDiagnosticFilterModel;
|
||||
class ClangStaticAnalyzerDiagnosticModel;
|
||||
class ClangStaticAnalyzerDiagnosticView;
|
||||
class Diagnostic;
|
||||
class DummyRunConfiguration;
|
||||
|
||||
const char ClangStaticAnalyzerPerspectiveId[] = "ClangStaticAnalyzer.Perspective";
|
||||
const char ClangStaticAnalyzerActionId[] = "ClangStaticAnalyzer.Action";
|
||||
@@ -57,7 +58,7 @@ public:
|
||||
|
||||
Debugger::AnalyzerRunControl *createRunControl(ProjectExplorer::RunConfiguration *runConfiguration,
|
||||
Core::Id runMode);
|
||||
void startTool(ProjectExplorer::RunConfiguration *rc);
|
||||
void startTool();
|
||||
|
||||
signals:
|
||||
void finished(bool success); // For testing.
|
||||
@@ -82,6 +83,7 @@ private:
|
||||
QAction *m_stopAction = 0;
|
||||
QAction *m_goBack;
|
||||
QAction *m_goNext;
|
||||
QHash<ProjectExplorer::Target *, DummyRunConfiguration *> m_runConfigs;
|
||||
bool m_running;
|
||||
bool m_toolBusy = false;
|
||||
};
|
||||
|
||||
@@ -107,6 +107,11 @@ void ClangStaticAnalyzerUnitTests::testProject_data()
|
||||
QTest::newRow("simple qmake project")
|
||||
<< QString(m_tmpDir->absolutePath("simple/simple.pro")) << 1;
|
||||
|
||||
QTest::newRow("simple qbs library project")
|
||||
<< QString(m_tmpDir->absolutePath("simple-library/simple-library.qbs")) << 0;
|
||||
QTest::newRow("simple qmake library project")
|
||||
<< QString(m_tmpDir->absolutePath("simple-library/simple-library.pro")) << 0;
|
||||
|
||||
QTest::newRow("qt-widgets-app qbs project")
|
||||
<< QString(m_tmpDir->absolutePath("qt-widgets-app/qt-widgets-app.qbs")) << 0;
|
||||
QTest::newRow("qt-widgets-app qmake project")
|
||||
|
||||
@@ -12,5 +12,9 @@
|
||||
<file>unit-tests/qt-essential-includes/main.cpp</file>
|
||||
<file>unit-tests/qt-essential-includes/qt-essential-includes.pro</file>
|
||||
<file>unit-tests/qt-essential-includes/qt-essential-includes.qbs</file>
|
||||
<file>unit-tests/simple-library/simple-library.cpp</file>
|
||||
<file>unit-tests/simple-library/simple-library.h</file>
|
||||
<file>unit-tests/simple-library/simple-library.pro</file>
|
||||
<file>unit-tests/simple-library/simple-library.qbs</file>
|
||||
</qresource>
|
||||
</RCC>
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
#include "simple-library.h"
|
||||
|
||||
void foo()
|
||||
{
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
#ifndef SIMPLELIBRARY_H
|
||||
#define SIMPLELIBRARY_H
|
||||
|
||||
void foo();
|
||||
|
||||
#endif // SIMPLELIBRARY_H
|
||||
@@ -0,0 +1,5 @@
|
||||
CONFIG -= QT
|
||||
TEMPLATE = lib
|
||||
|
||||
SOURCES += simple-library.cpp
|
||||
HEADERS += simple-library.h
|
||||
@@ -0,0 +1,13 @@
|
||||
import qbs 1.0
|
||||
|
||||
DynamicLibrary {
|
||||
name: "Simple Library"
|
||||
|
||||
Depends { name: 'cpp' }
|
||||
|
||||
files: [
|
||||
"simple-library.cpp",
|
||||
"simple-library.h",
|
||||
]
|
||||
}
|
||||
|
||||
@@ -84,8 +84,12 @@ const Icon MINUS({
|
||||
const Icon PLUS({
|
||||
{QLatin1String(":/core/images/plus.png"), Theme::IconsBaseColor}});
|
||||
const Icon NEXT({
|
||||
{QLatin1String(":/core/images/next.png"), Theme::IconsWarningColor}}, Icon::MenuTintedStyle);
|
||||
const Icon NEXT_TOOLBAR({
|
||||
{QLatin1String(":/core/images/next.png"), Theme::IconsNavigationArrowsColor}});
|
||||
const Icon PREV({
|
||||
{QLatin1String(":/core/images/prev.png"), Theme::IconsWarningColor}}, Icon::MenuTintedStyle);
|
||||
const Icon PREV_TOOLBAR({
|
||||
{QLatin1String(":/core/images/prev.png"), Theme::IconsNavigationArrowsColor}});
|
||||
const Icon MAGNIFIER({
|
||||
{QLatin1String(":/core/images/magnifier.png"), Theme::PanelTextColorMid}}, Icon::Tint);
|
||||
@@ -94,6 +98,8 @@ const Icon CLEAN_PANE({
|
||||
const Icon RELOAD({
|
||||
{QLatin1String(":/core/images/reload_gray.png"), Theme::IconsBaseColor}});
|
||||
const Icon TOGGLE_SIDEBAR({
|
||||
{QLatin1String(":/core/images/sidebaricon.png"), Theme::PanelTextColorMid}}, Icon::MenuTintedStyle);
|
||||
const Icon TOGGLE_SIDEBAR_TOOLBAR({
|
||||
{QLatin1String(":/core/images/sidebaricon.png"), Theme::IconsBaseColor}});
|
||||
const Icon CLOSE_TOOLBAR({
|
||||
{QLatin1String(":/core/images/close.png"), Theme::IconsBaseColor}});
|
||||
@@ -102,8 +108,12 @@ const Icon CLOSE_FOREGROUND({
|
||||
const Icon CLOSE_BACKGROUND({
|
||||
{QLatin1String(":/core/images/close.png"), Theme::PanelTextColorLight}}, Icon::Tint);
|
||||
const Icon SPLIT_HORIZONTAL({
|
||||
{QLatin1String(":/core/images/splitbutton_horizontal.png"), Theme::PanelTextColorMid}}, Icon::MenuTintedStyle);
|
||||
const Icon SPLIT_HORIZONTAL_TOOLBAR({
|
||||
{QLatin1String(":/core/images/splitbutton_horizontal.png"), Theme::IconsBaseColor}});
|
||||
const Icon SPLIT_VERTICAL({
|
||||
{QLatin1String(":/core/images/splitbutton_vertical.png"), Theme::PanelTextColorMid}}, Icon::MenuTintedStyle);
|
||||
const Icon SPLIT_VERTICAL_TOOLBAR({
|
||||
{QLatin1String(":/core/images/splitbutton_vertical.png"), Theme::IconsBaseColor}});
|
||||
const Icon CLOSE_SPLIT_TOP({
|
||||
{QLatin1String(":/core/images/splitbutton_closetop.png"), Theme::IconsBaseColor}});
|
||||
@@ -143,11 +153,17 @@ const Icon ZOOM_TOOLBAR({
|
||||
const Icon TOOLBAR_EXTENSION({
|
||||
{QLatin1String(":/core/images/extension.png"), Theme::IconsBaseColor}});
|
||||
const Utils::Icon RUN_SMALL({
|
||||
{QLatin1String(":/core/images/run_small.png"), Utils::Theme::IconsRunColor}});
|
||||
{QLatin1String(":/core/images/run_small.png"), Utils::Theme::IconsRunColor}}, Utils::Icon::MenuTintedStyle);
|
||||
const Utils::Icon RUN_SMALL_TOOLBAR({
|
||||
{QLatin1String(":/core/images/run_small.png"), Utils::Theme::IconsRunToolBarColor}});
|
||||
const Utils::Icon STOP_SMALL({
|
||||
{QLatin1String(":/core/images/stop_small.png"), Utils::Theme::IconsStopColor}});
|
||||
{QLatin1String(":/core/images/stop_small.png"), Utils::Theme::IconsStopColor}}, Utils::Icon::MenuTintedStyle);
|
||||
const Utils::Icon STOP_SMALL_TOOLBAR({
|
||||
{QLatin1String(":/core/images/stop_small.png"), Utils::Theme::IconsStopToolBarColor}});
|
||||
const Utils::Icon INTERRUPT_SMALL({
|
||||
{QLatin1String(":/core/images/interrupt_small.png"), Utils::Theme::IconsInterruptColor}});
|
||||
{QLatin1String(":/core/images/interrupt_small.png"), Utils::Theme::IconsInterruptColor}}, Utils::Icon::MenuTintedStyle);
|
||||
const Utils::Icon INTERRUPT_SMALL_TOOLBAR({
|
||||
{QLatin1String(":/core/images/interrupt_small.png"), Utils::Theme::IconsInterruptToolBarColor}});
|
||||
const Icon BOUNDING_RECT({
|
||||
{QLatin1String(":/core/images/boundingrect.png"), Theme::IconsBaseColor}});
|
||||
const Icon EYE_OPEN_TOOLBAR({
|
||||
|
||||
@@ -60,16 +60,21 @@ CORE_EXPORT extern const Utils::Icon ARROW_DOWN;
|
||||
CORE_EXPORT extern const Utils::Icon MINUS;
|
||||
CORE_EXPORT extern const Utils::Icon PLUS;
|
||||
CORE_EXPORT extern const Utils::Icon NEXT;
|
||||
CORE_EXPORT extern const Utils::Icon NEXT_TOOLBAR;
|
||||
CORE_EXPORT extern const Utils::Icon PREV;
|
||||
CORE_EXPORT extern const Utils::Icon PREV_TOOLBAR;
|
||||
CORE_EXPORT extern const Utils::Icon MAGNIFIER;
|
||||
CORE_EXPORT extern const Utils::Icon CLEAN_PANE;
|
||||
CORE_EXPORT extern const Utils::Icon RELOAD;
|
||||
CORE_EXPORT extern const Utils::Icon TOGGLE_SIDEBAR;
|
||||
CORE_EXPORT extern const Utils::Icon TOGGLE_SIDEBAR_TOOLBAR;
|
||||
CORE_EXPORT extern const Utils::Icon CLOSE_TOOLBAR;
|
||||
CORE_EXPORT extern const Utils::Icon CLOSE_FOREGROUND;
|
||||
CORE_EXPORT extern const Utils::Icon CLOSE_BACKGROUND;
|
||||
CORE_EXPORT extern const Utils::Icon SPLIT_HORIZONTAL;
|
||||
CORE_EXPORT extern const Utils::Icon SPLIT_HORIZONTAL_TOOLBAR;
|
||||
CORE_EXPORT extern const Utils::Icon SPLIT_VERTICAL;
|
||||
CORE_EXPORT extern const Utils::Icon SPLIT_VERTICAL_TOOLBAR;
|
||||
CORE_EXPORT extern const Utils::Icon CLOSE_SPLIT_TOP;
|
||||
CORE_EXPORT extern const Utils::Icon CLOSE_SPLIT_BOTTOM;
|
||||
CORE_EXPORT extern const Utils::Icon CLOSE_SPLIT_LEFT;
|
||||
@@ -88,8 +93,11 @@ CORE_EXPORT extern const Utils::Icon ZOOM;
|
||||
CORE_EXPORT extern const Utils::Icon ZOOM_TOOLBAR;
|
||||
CORE_EXPORT extern const Utils::Icon TOOLBAR_EXTENSION;
|
||||
CORE_EXPORT extern const Utils::Icon RUN_SMALL;
|
||||
CORE_EXPORT extern const Utils::Icon RUN_SMALL_TOOLBAR;
|
||||
CORE_EXPORT extern const Utils::Icon STOP_SMALL;
|
||||
CORE_EXPORT extern const Utils::Icon STOP_SMALL_TOOLBAR;
|
||||
CORE_EXPORT extern const Utils::Icon INTERRUPT_SMALL;
|
||||
CORE_EXPORT extern const Utils::Icon INTERRUPT_SMALL_TOOLBAR;
|
||||
CORE_EXPORT extern const Utils::Icon BOUNDING_RECT;
|
||||
CORE_EXPORT extern const Utils::Icon EYE_OPEN_TOOLBAR;
|
||||
CORE_EXPORT extern const Utils::Icon EYE_CLOSED_TOOLBAR;
|
||||
|
||||
@@ -208,8 +208,8 @@ EditorManagerPrivate::EditorManagerPrivate(QObject *parent) :
|
||||
m_closeAllEditorsExceptVisibleAction(new QAction(EditorManager::tr("Close All Except Visible"), this)),
|
||||
m_gotoNextDocHistoryAction(new QAction(EditorManager::tr("Next Open Document in History"), this)),
|
||||
m_gotoPreviousDocHistoryAction(new QAction(EditorManager::tr("Previous Open Document in History"), this)),
|
||||
m_goBackAction(new QAction(Icons::PREV.icon(), EditorManager::tr("Go Back"), this)),
|
||||
m_goForwardAction(new QAction(Icons::NEXT.icon(), EditorManager::tr("Go Forward"), this)),
|
||||
m_goBackAction(new QAction(Icons::PREV_TOOLBAR.icon(), EditorManager::tr("Go Back"), this)),
|
||||
m_goForwardAction(new QAction(Icons::NEXT_TOOLBAR.icon(), EditorManager::tr("Go Forward"), this)),
|
||||
m_copyFilePathContextAction(new QAction(EditorManager::tr("Copy Full Path"), this)),
|
||||
m_copyLocationContextAction(new QAction(EditorManager::tr("Copy Path and Line Number"), this)),
|
||||
m_copyFileNameContextAction(new QAction(EditorManager::tr("Copy File Name"), this)),
|
||||
|
||||
@@ -94,13 +94,13 @@ EditorToolBarPrivate::EditorToolBarPrivate(QWidget *parent, EditorToolBar *q) :
|
||||
m_lockButton(new QToolButton(q)),
|
||||
m_dragHandle(new QToolButton(q)),
|
||||
m_dragHandleMenu(0),
|
||||
m_goBackAction(new QAction(Icons::PREV.icon(), EditorManager::tr("Go Back"), parent)),
|
||||
m_goForwardAction(new QAction(Icons::NEXT.icon(), EditorManager::tr("Go Forward"), parent)),
|
||||
m_goBackAction(new QAction(Icons::PREV_TOOLBAR.icon(), EditorManager::tr("Go Back"), parent)),
|
||||
m_goForwardAction(new QAction(Icons::NEXT_TOOLBAR.icon(), EditorManager::tr("Go Forward"), parent)),
|
||||
m_backButton(new QToolButton(q)),
|
||||
m_forwardButton(new QToolButton(q)),
|
||||
m_splitButton(new QToolButton(q)),
|
||||
m_horizontalSplitAction(new QAction(Icons::SPLIT_HORIZONTAL.icon(), EditorManager::tr("Split"), parent)),
|
||||
m_verticalSplitAction(new QAction(Icons::SPLIT_VERTICAL.icon(), EditorManager::tr("Split Side by Side"), parent)),
|
||||
m_horizontalSplitAction(new QAction(Icons::SPLIT_HORIZONTAL_TOOLBAR.icon(), EditorManager::tr("Split"), parent)),
|
||||
m_verticalSplitAction(new QAction(Icons::SPLIT_VERTICAL_TOOLBAR.icon(), EditorManager::tr("Split Side by Side"), parent)),
|
||||
m_splitNewWindowAction(new QAction(EditorManager::tr("Open in New Window"), parent)),
|
||||
m_closeSplitButton(new QToolButton(q)),
|
||||
m_activeToolBar(0),
|
||||
@@ -163,7 +163,7 @@ EditorToolBar::EditorToolBar(QWidget *parent) :
|
||||
d->m_splitNewWindowAction->setIconVisibleInMenu(false);
|
||||
}
|
||||
|
||||
d->m_splitButton->setIcon(Icons::SPLIT_HORIZONTAL.icon());
|
||||
d->m_splitButton->setIcon(Icons::SPLIT_HORIZONTAL_TOOLBAR.icon());
|
||||
d->m_splitButton->setToolTip(tr("Split"));
|
||||
d->m_splitButton->setPopupMode(QToolButton::InstantPopup);
|
||||
d->m_splitButton->setProperty("noArrow", true);
|
||||
|
||||
@@ -962,9 +962,9 @@ void FindToolBar::setLightColoredIcon(bool lightColored)
|
||||
m_ui.findPreviousButton->setArrowType(Qt::LeftArrow);
|
||||
m_ui.close->setIcon(Icons::CLOSE_FOREGROUND.icon());
|
||||
} else {
|
||||
m_ui.findNextButton->setIcon(Icons::NEXT.icon());
|
||||
m_ui.findNextButton->setIcon(Icons::NEXT_TOOLBAR.icon());
|
||||
m_ui.findNextButton->setArrowType(Qt::NoArrow);
|
||||
m_ui.findPreviousButton->setIcon(Icons::PREV.icon());
|
||||
m_ui.findPreviousButton->setIcon(Icons::PREV_TOOLBAR.icon());
|
||||
m_ui.findPreviousButton->setArrowType(Qt::NoArrow);
|
||||
m_ui.close->setIcon(Icons::CLOSE_TOOLBAR.icon());
|
||||
}
|
||||
|
||||
@@ -27,9 +27,8 @@
|
||||
#include "locatorfiltersfilter.h"
|
||||
#include "locatorwidget.h"
|
||||
|
||||
#include <utils/icon.h>
|
||||
#include <coreplugin/coreicons.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/theme/theme.h>
|
||||
|
||||
using namespace Core;
|
||||
using namespace Core::Internal;
|
||||
@@ -40,8 +39,7 @@ LocatorFiltersFilter::LocatorFiltersFilter(Locator *plugin,
|
||||
LocatorWidget *locatorWidget):
|
||||
m_plugin(plugin),
|
||||
m_locatorWidget(locatorWidget),
|
||||
m_icon(Utils::Icon({{QLatin1String(":/core/images/next.png"), Utils::Theme::IconsWarningColor}},
|
||||
Utils::Icon::Tint).pixmap())
|
||||
m_icon(Icons::NEXT.icon())
|
||||
{
|
||||
setId("FiltersFilter");
|
||||
setDisplayName(tr("Available filters"));
|
||||
|
||||
@@ -691,7 +691,7 @@ void MainWindow::registerDefaultActions()
|
||||
}
|
||||
|
||||
// Show Sidebar Action
|
||||
m_toggleSideBarAction = new QAction(Icons::TOGGLE_SIDEBAR.icon(),
|
||||
m_toggleSideBarAction = new QAction(Icons::TOGGLE_SIDEBAR_TOOLBAR.icon(),
|
||||
QCoreApplication::translate("Core", Constants::TR_SHOW_SIDEBAR),
|
||||
this);
|
||||
m_toggleSideBarAction->setCheckable(true);
|
||||
|
||||
@@ -194,6 +194,9 @@ int ManhattanStyle::pixelMetric(PixelMetric metric, const QStyleOption *option,
|
||||
if (panelWidget(widget))
|
||||
retval = 16;
|
||||
break;
|
||||
case PM_SmallIconSize:
|
||||
retval = 16;
|
||||
break;
|
||||
case PM_DockWidgetHandleExtent:
|
||||
case PM_DockWidgetSeparatorExtent:
|
||||
return 1;
|
||||
|
||||
@@ -69,7 +69,7 @@ NavigationSubWidget::NavigationSubWidget(NavigationWidget *parentWidget, int pos
|
||||
toolBarLayout->addWidget(m_navigationComboBox);
|
||||
|
||||
QToolButton *splitAction = new QToolButton();
|
||||
splitAction->setIcon(Icons::SPLIT_HORIZONTAL.icon());
|
||||
splitAction->setIcon(Icons::SPLIT_HORIZONTAL_TOOLBAR.icon());
|
||||
splitAction->setToolTip(tr("Split"));
|
||||
splitAction->setPopupMode(QToolButton::InstantPopup);
|
||||
splitAction->setProperty("noArrow", true);
|
||||
|
||||
@@ -145,12 +145,12 @@ OutputPaneManager::OutputPaneManager(QWidget *parent) :
|
||||
connect(m_clearAction, &QAction::triggered, this, &OutputPaneManager::clearPage);
|
||||
|
||||
m_nextAction = new QAction(this);
|
||||
m_nextAction->setIcon(Icons::NEXT.icon());
|
||||
m_nextAction->setIcon(Icons::NEXT_TOOLBAR.icon());
|
||||
m_nextAction->setText(tr("Next Item"));
|
||||
connect(m_nextAction, &QAction::triggered, this, &OutputPaneManager::slotNext);
|
||||
|
||||
m_prevAction = new QAction(this);
|
||||
m_prevAction->setIcon(Icons::PREV.icon());
|
||||
m_prevAction->setIcon(Icons::PREV_TOOLBAR.icon());
|
||||
m_prevAction->setText(tr("Previous Item"));
|
||||
connect(m_prevAction, &QAction::triggered, this, &OutputPaneManager::slotPrev);
|
||||
|
||||
|
||||
@@ -72,7 +72,7 @@ SideBarWidget::SideBarWidget(SideBar *sideBar, const QString &id)
|
||||
|
||||
m_splitAction = new QAction(tr("Split"), m_toolbar);
|
||||
m_splitAction->setToolTip(tr("Split"));
|
||||
m_splitAction->setIcon(Icons::SPLIT_HORIZONTAL.icon());
|
||||
m_splitAction->setIcon(Icons::SPLIT_HORIZONTAL_TOOLBAR.icon());
|
||||
connect(m_splitAction, &QAction::triggered, this, &SideBarWidget::splitMe);
|
||||
m_toolbar->addAction(m_splitAction);
|
||||
|
||||
|
||||
@@ -88,6 +88,7 @@ public:
|
||||
addMimeType(CppTools::Constants::CPP_SOURCE_MIMETYPE);
|
||||
addMimeType(CppTools::Constants::CPP_HEADER_MIMETYPE);
|
||||
addMimeType(CppTools::Constants::QDOC_MIMETYPE);
|
||||
addMimeType(CppTools::Constants::MOC_MIMETYPE);
|
||||
|
||||
setDocumentCreator([]() { return new CppEditorDocument; });
|
||||
setEditorWidgetCreator([]() { return new CppEditorWidget; });
|
||||
|
||||
@@ -64,6 +64,10 @@ ProjectFile::Kind ProjectFile::classify(const QString &file)
|
||||
return ObjCSource;
|
||||
if (mt == QLatin1String(CppTools::Constants::OBJECTIVE_CPP_SOURCE_MIMETYPE))
|
||||
return ObjCXXSource;
|
||||
if (mt == QLatin1String(CppTools::Constants::QDOC_MIMETYPE))
|
||||
return CXXSource;
|
||||
if (mt == QLatin1String(CppTools::Constants::MOC_MIMETYPE))
|
||||
return CXXSource;
|
||||
return Unclassified;
|
||||
}
|
||||
|
||||
|
||||
@@ -42,6 +42,7 @@ const char OBJECTIVE_C_SOURCE_MIMETYPE[] = "text/x-objcsrc";
|
||||
const char OBJECTIVE_CPP_SOURCE_MIMETYPE[] = "text/x-objc++src";
|
||||
const char CPP_HEADER_MIMETYPE[] = "text/x-c++hdr";
|
||||
const char QDOC_MIMETYPE[] = "text/x-qdoc";
|
||||
const char MOC_MIMETYPE[] = "text/x-moc";
|
||||
|
||||
// QSettings keys for use by the "New Class" wizards.
|
||||
const char CPPTOOLS_SETTINGSGROUP[] = "CppTools";
|
||||
|
||||
@@ -281,18 +281,6 @@ QString targetTriple(ProjectExplorer::Project *project, const Core::Id &toolchai
|
||||
return QString();
|
||||
}
|
||||
|
||||
bool projectHasMsvc2015Toolchain(ProjectExplorer::Project *project)
|
||||
{
|
||||
if (project) {
|
||||
if (ProjectExplorer::Target *target = project->activeTarget()) {
|
||||
if (ProjectExplorer::RunConfiguration *runConfig = target->activeRunConfiguration())
|
||||
return runConfig->abi().osFlavor() == ProjectExplorer::Abi::WindowsMsvc2015Flavor;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/*!
|
||||
@@ -355,7 +343,8 @@ void ProjectPartBuilder::evaluateProjectPartToolchain(
|
||||
|
||||
projectPart->toolchainDefines = toolChain->predefinedMacros(commandLineFlags);
|
||||
projectPart->toolchainType = toolChain->typeId();
|
||||
projectPart->isMsvc2015Toolchain = projectHasMsvc2015Toolchain(projectPart->project);
|
||||
projectPart->isMsvc2015Toolchain
|
||||
= toolChain->targetAbi().osFlavor() == ProjectExplorer::Abi::WindowsMsvc2015Flavor;
|
||||
projectPart->targetTriple = targetTriple(projectPart->project, toolChain->typeId());
|
||||
projectPart->updateLanguageFeatures();
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@ namespace Debugger {
|
||||
namespace Icons {
|
||||
|
||||
const Utils::Icon ANALYZER_CONTROL_START({
|
||||
{QLatin1String(":/core/images/run_small.png"), Utils::Theme::IconsRunColor},
|
||||
{QLatin1String(":/core/images/run_small.png"), Utils::Theme::IconsRunToolBarColor},
|
||||
{QLatin1String(":/images/analyzer_overlay_small.png"), Utils::Theme::IconsBaseColor}});
|
||||
const Utils::Icon MODE_ANALYZE_CLASSIC(
|
||||
QLatin1String(":/images/mode_analyze.png"));
|
||||
|
||||
@@ -820,6 +820,7 @@ void Breakpoint::setEnabled(bool on) const
|
||||
return;
|
||||
b->m_params.enabled = on;
|
||||
b->updateMarkerIcon();
|
||||
b->update();
|
||||
if (b->m_engine) {
|
||||
b->m_state = BreakpointChangeRequested;
|
||||
b->scheduleSynchronization();
|
||||
|
||||
@@ -1839,8 +1839,11 @@ void DebuggerEngine::validateExecutable(DebuggerRunParameters *sp)
|
||||
return;
|
||||
if (sp->languages == QmlLanguage)
|
||||
return;
|
||||
QString binary = sp->inferior.executable;
|
||||
if (binary.isEmpty())
|
||||
|
||||
QString symbolFile = sp->symbolFile;
|
||||
if (symbolFile.isEmpty())
|
||||
symbolFile = sp->inferior.executable;
|
||||
if (symbolFile.isEmpty())
|
||||
return;
|
||||
|
||||
const bool warnOnRelease = boolSetting(WarnOnReleaseBuilds);
|
||||
@@ -1856,11 +1859,11 @@ void DebuggerEngine::validateExecutable(DebuggerRunParameters *sp)
|
||||
"experience for this binary format.");
|
||||
return;
|
||||
} else if (warnOnRelease) {
|
||||
if (!binary.endsWith(QLatin1String(".exe"), Qt::CaseInsensitive))
|
||||
binary.append(QLatin1String(".exe"));
|
||||
if (!symbolFile.endsWith(QLatin1String(".exe"), Qt::CaseInsensitive))
|
||||
symbolFile.append(QLatin1String(".exe"));
|
||||
QString errorMessage;
|
||||
QStringList rc;
|
||||
if (getPDBFiles(binary, &rc, &errorMessage) && !rc.isEmpty())
|
||||
if (getPDBFiles(symbolFile, &rc, &errorMessage) && !rc.isEmpty())
|
||||
return;
|
||||
if (!errorMessage.isEmpty()) {
|
||||
detailedWarning.append(QLatin1Char('\n'));
|
||||
@@ -1881,11 +1884,11 @@ void DebuggerEngine::validateExecutable(DebuggerRunParameters *sp)
|
||||
return;
|
||||
}
|
||||
|
||||
Utils::ElfReader reader(binary);
|
||||
Utils::ElfReader reader(symbolFile);
|
||||
Utils::ElfData elfData = reader.readHeaders();
|
||||
QString error = reader.errorString();
|
||||
|
||||
Internal::showMessage(_("EXAMINING ") + binary, LogDebug);
|
||||
Internal::showMessage(_("EXAMINING ") + symbolFile, LogDebug);
|
||||
QByteArray msg = "ELF SECTIONS: ";
|
||||
|
||||
static QList<QByteArray> interesting;
|
||||
|
||||
@@ -47,23 +47,33 @@ const Utils::Icon TRACEPOINT({
|
||||
const Utils::Icon CONTINUE(
|
||||
QLatin1String(":/debugger/images/debugger_continue.png"));
|
||||
const Utils::Icon CONTINUE_FLAT({
|
||||
{QLatin1String(":/debugger/images/debugger_continue_1_mask.png"), Utils::Theme::IconsInterruptColor},
|
||||
{QLatin1String(":/debugger/images/debugger_continue_2_mask.png"), Utils::Theme::IconsRunColor},
|
||||
{QLatin1String(":/debugger/images/debugger_continue_1_mask.png"), Utils::Theme::IconsInterruptToolBarColor},
|
||||
{QLatin1String(":/debugger/images/debugger_continue_2_mask.png"), Utils::Theme::IconsRunToolBarColor},
|
||||
{QLatin1String(":/projectexplorer/images/debugger_beetle_mask.png"), Utils::Theme::IconsDebugColor}});
|
||||
const Utils::Icon DEBUG_CONTINUE_SMALL({
|
||||
{QLatin1String(":/projectexplorer/images/continue_1_small.png"), Utils::Theme::IconsInterruptColor},
|
||||
{QLatin1String(":/projectexplorer/images/continue_2_small.png"), Utils::Theme::IconsRunColor},
|
||||
{QLatin1String(":/projectexplorer/images/debugger_overlay_small.png"), Utils::Theme::PanelTextColorMid}}, Utils::Icon::MenuTintedStyle);
|
||||
const Utils::Icon DEBUG_CONTINUE_SMALL_TOOLBAR({
|
||||
{QLatin1String(":/projectexplorer/images/continue_1_small.png"), Utils::Theme::IconsInterruptToolBarColor},
|
||||
{QLatin1String(":/projectexplorer/images/continue_2_small.png"), Utils::Theme::IconsRunToolBarColor},
|
||||
{QLatin1String(":/projectexplorer/images/debugger_overlay_small.png"), Utils::Theme::IconsDebugColor}});
|
||||
const Utils::Icon INTERRUPT(
|
||||
QLatin1String(":/debugger/images/debugger_interrupt.png"));
|
||||
const Utils::Icon INTERRUPT_FLAT({
|
||||
{QLatin1String(":/debugger/images/debugger_interrupt_mask.png"), Utils::Theme::IconsInterruptColor},
|
||||
{QLatin1String(":/debugger/images/debugger_interrupt_mask.png"), Utils::Theme::IconsInterruptToolBarColor},
|
||||
{QLatin1String(":/projectexplorer/images/debugger_beetle_mask.png"), Utils::Theme::IconsDebugColor}});
|
||||
const Utils::Icon DEBUG_INTERRUPT_SMALL({
|
||||
{QLatin1String(":/core/images/interrupt_small.png"), Utils::Theme::IconsInterruptColor},
|
||||
{QLatin1String(":/projectexplorer/images/debugger_overlay_small.png"), Utils::Theme::PanelTextColorMid}}, Utils::Icon::MenuTintedStyle);
|
||||
const Utils::Icon DEBUG_INTERRUPT_SMALL_TOOLBAR({
|
||||
{QLatin1String(":/core/images/interrupt_small.png"), Utils::Theme::IconsInterruptToolBarColor},
|
||||
{QLatin1String(":/projectexplorer/images/debugger_overlay_small.png"), Utils::Theme::IconsDebugColor}});
|
||||
const Utils::Icon DEBUG_EXIT_SMALL({
|
||||
{QLatin1String(":/core/images/stop_small.png"), Utils::Theme::IconsStopColor},
|
||||
{QLatin1String(":/projectexplorer/images/debugger_overlay_small.png"), Utils::Theme::PanelTextColorMid}}, Utils::Icon::MenuTintedStyle);
|
||||
const Utils::Icon DEBUG_EXIT_SMALL_TOOLBAR({
|
||||
{QLatin1String(":/core/images/stop_small.png"), Utils::Theme::IconsStopToolBarColor},
|
||||
{QLatin1String(":/projectexplorer/images/debugger_overlay_small.png"), Utils::Theme::IconsDebugColor}});
|
||||
const Utils::Icon LOCATION({
|
||||
{QLatin1String(":/debugger/images/location_background.png"), Utils::Theme::IconsCodeModelOverlayForegroundColor},
|
||||
@@ -85,15 +95,21 @@ const Utils::Icon RECORD_OFF({
|
||||
{QLatin1String(":/debugger/images/recordoutline.png"), Utils::Theme::IconsBaseColor}}, Utils::Icon::Tint | Utils::Icon::DropShadow);
|
||||
|
||||
const Utils::Icon STEP_OVER({
|
||||
{QLatin1String(":/debugger/images/debugger_stepover_small.png"), Utils::Theme::PanelTextColorMid}}, Utils::Icon::MenuTintedStyle);
|
||||
const Utils::Icon STEP_OVER_TOOLBAR({
|
||||
{QLatin1String(":/debugger/images/debugger_stepover_small.png"), Utils::Theme::IconsBaseColor}});
|
||||
const Utils::Icon STEP_OVER_TOOLBUTTON({
|
||||
{QLatin1String(":/debugger/images/debugger_stepover_small.png"), Utils::Theme::TextColorNormal}}, Utils::Icon::Tint);
|
||||
const Utils::Icon STEP_INTO({
|
||||
{QLatin1String(":/debugger/images/debugger_stepinto_small.png"), Utils::Theme::PanelTextColorMid}}, Utils::Icon::MenuTintedStyle);
|
||||
const Utils::Icon STEP_INTO_TOOLBAR({
|
||||
{QLatin1String(":/debugger/images/debugger_stepinto_small.png"), Utils::Theme::IconsBaseColor}});
|
||||
const Utils::Icon STEP_OUT({
|
||||
{QLatin1String(":/debugger/images/debugger_stepout_small.png"), Utils::Theme::PanelTextColorMid}}, Utils::Icon::MenuTintedStyle);
|
||||
const Utils::Icon STEP_OUT_TOOLBAR({
|
||||
{QLatin1String(":/debugger/images/debugger_stepout_small.png"), Utils::Theme::IconsBaseColor}});
|
||||
const Utils::Icon RESTART({
|
||||
{QLatin1String(":/debugger/images/debugger_restart_small.png"), Utils::Theme::IconsRunColor}});
|
||||
{QLatin1String(":/debugger/images/debugger_restart_small.png"), Utils::Theme::PanelTextColorMid}}, Utils::Icon::MenuTintedStyle);
|
||||
const Utils::Icon RESTART_TOOLBAR({
|
||||
{QLatin1String(":/debugger/images/debugger_restart_small.png"), Utils::Theme::IconsRunToolBarColor}});
|
||||
const Utils::Icon SINGLE_INSTRUCTION_MODE({
|
||||
{QLatin1String(":/debugger/images/debugger_singleinstructionmode.png"), Utils::Theme::IconsBaseColor}});
|
||||
|
||||
|
||||
@@ -655,6 +655,9 @@ public:
|
||||
|
||||
void updateWatchersHeader(int section, int, int newSize)
|
||||
{
|
||||
if (m_shuttingDown)
|
||||
return;
|
||||
|
||||
m_watchersView->header()->resizeSection(section, newSize);
|
||||
m_returnView->header()->resizeSection(section, newSize);
|
||||
}
|
||||
@@ -1004,7 +1007,7 @@ public:
|
||||
|
||||
SnapshotHandler *m_snapshotHandler = 0;
|
||||
bool m_shuttingDown = false;
|
||||
DebuggerEngine *m_currentEngine = 0;
|
||||
QPointer<DebuggerEngine> m_currentEngine;
|
||||
DebuggerSettings *m_debuggerSettings = 0;
|
||||
QStringList m_arguments;
|
||||
DebuggerToolTipManager m_toolTipManager;
|
||||
@@ -1346,14 +1349,14 @@ bool DebuggerPluginPrivate::initialize(const QStringList &arguments,
|
||||
this, &DebuggerPluginPrivate::updateWatchersHeader, Qt::QueuedConnection);
|
||||
|
||||
auto act = m_continueAction = new QAction(tr("Continue"), this);
|
||||
act->setIcon(Icon::combinedIcon({Icons::DEBUG_CONTINUE_SMALL.icon(), continueSideBarIcon}));
|
||||
act->setIcon(Icon::combinedIcon({Icons::DEBUG_CONTINUE_SMALL_TOOLBAR.icon(), continueSideBarIcon}));
|
||||
connect(act, &QAction::triggered, this, &DebuggerPluginPrivate::handleExecContinue);
|
||||
|
||||
act = m_exitAction = new QAction(tr("Stop Debugger"), this);
|
||||
act->setIcon(Icons::DEBUG_EXIT_SMALL.icon());
|
||||
act->setIcon(Icons::DEBUG_EXIT_SMALL_TOOLBAR.icon());
|
||||
connect(act, &QAction::triggered, this, &DebuggerPluginPrivate::handleExecExit);
|
||||
|
||||
auto interruptIcon = Icon::combinedIcon({Icons::DEBUG_INTERRUPT_SMALL.icon(), interruptSideBarIcon});
|
||||
auto interruptIcon = Icon::combinedIcon({Icons::DEBUG_INTERRUPT_SMALL_TOOLBAR.icon(), interruptSideBarIcon});
|
||||
act = m_interruptAction = new QAction(tr("Interrupt"), this);
|
||||
act->setIcon(interruptIcon);
|
||||
connect(act, &QAction::triggered, this, &DebuggerPluginPrivate::handleExecInterrupt);
|
||||
@@ -1370,19 +1373,19 @@ bool DebuggerPluginPrivate::initialize(const QStringList &arguments,
|
||||
|
||||
act = m_resetAction = new QAction(tr("Restart Debugging"),this);
|
||||
act->setToolTip(tr("Restart the debugging session."));
|
||||
act->setIcon(Icons::RESTART.icon());
|
||||
act->setIcon(Icons::RESTART_TOOLBAR.icon());
|
||||
connect(act, &QAction::triggered, this, &DebuggerPluginPrivate::handleReset);
|
||||
|
||||
act = m_nextAction = new QAction(tr("Step Over"), this);
|
||||
act->setIcon(Icons::STEP_OVER.icon());
|
||||
act->setIcon(Icons::STEP_OVER_TOOLBAR.icon());
|
||||
connect(act, &QAction::triggered, this, &DebuggerPluginPrivate::handleExecNext);
|
||||
|
||||
act = m_stepAction = new QAction(tr("Step Into"), this);
|
||||
act->setIcon(Icons::STEP_INTO.icon());
|
||||
act->setIcon(Icons::STEP_INTO_TOOLBAR.icon());
|
||||
connect(act, &QAction::triggered, this, &DebuggerPluginPrivate::handleExecStep);
|
||||
|
||||
act = m_stepOutAction = new QAction(tr("Step Out"), this);
|
||||
act->setIcon(Icons::STEP_OUT.icon());
|
||||
act->setIcon(Icons::STEP_OUT_TOOLBAR.icon());
|
||||
connect(act, &QAction::triggered, this, &DebuggerPluginPrivate::handleExecStepOut);
|
||||
|
||||
act = m_runToLineAction = new QAction(tr("Run to Line"), this);
|
||||
@@ -1440,7 +1443,7 @@ bool DebuggerPluginPrivate::initialize(const QStringList &arguments,
|
||||
act = m_startAction = new QAction(this);
|
||||
const QIcon sideBarIcon =
|
||||
Icon::sideBarIcon(ProjectExplorer::Icons::DEBUG_START, ProjectExplorer::Icons::DEBUG_START_FLAT);
|
||||
const QIcon debuggerIcon = Icon::combinedIcon({ProjectExplorer::Icons::DEBUG_START_SMALL.icon(), sideBarIcon});
|
||||
const QIcon debuggerIcon = Icon::combinedIcon({ProjectExplorer::Icons::DEBUG_START_SMALL_TOOLBAR.icon(), sideBarIcon});
|
||||
act->setIcon(debuggerIcon);
|
||||
act->setText(tr("Start Debugging"));
|
||||
connect(act, &QAction::triggered, [] { ProjectExplorerPlugin::runStartupProject(ProjectExplorer::Constants::DEBUG_RUN_MODE); });
|
||||
@@ -1775,12 +1778,12 @@ bool DebuggerPluginPrivate::initialize(const QStringList &arguments,
|
||||
// Toolbar
|
||||
ToolbarDescription toolbar;
|
||||
toolbar.addAction(m_visibleStartAction);
|
||||
toolbar.addAction(m_exitAction);
|
||||
toolbar.addAction(m_nextAction);
|
||||
toolbar.addAction(m_stepAction);
|
||||
toolbar.addAction(m_stepOutAction);
|
||||
toolbar.addAction(m_resetAction);
|
||||
toolbar.addAction(m_operateByInstructionAction);
|
||||
toolbar.addAction(ActionManager::command(Constants::STOP)->action());
|
||||
toolbar.addAction(ActionManager::command(Constants::NEXT)->action());
|
||||
toolbar.addAction(ActionManager::command(Constants::STEP)->action());
|
||||
toolbar.addAction(ActionManager::command(Constants::STEPOUT)->action());
|
||||
toolbar.addAction(ActionManager::command(Constants::RESET)->action());
|
||||
toolbar.addAction(ActionManager::command(Constants::OPERATE_BY_INSTRUCTION)->action());
|
||||
|
||||
if (isReverseDebuggingEnabled()) {
|
||||
m_reverseToolButton = new QToolButton;
|
||||
@@ -2359,6 +2362,9 @@ void DebuggerPluginPrivate::connectEngine(DebuggerEngine *engine)
|
||||
if (m_currentEngine == engine)
|
||||
return;
|
||||
|
||||
if (m_shuttingDown)
|
||||
return;
|
||||
|
||||
if (m_currentEngine)
|
||||
m_currentEngine->resetLocation();
|
||||
m_currentEngine = engine;
|
||||
@@ -2742,6 +2748,8 @@ void DebuggerPluginPrivate::aboutToSaveSession()
|
||||
|
||||
void DebuggerPluginPrivate::showStatusMessage(const QString &msg0, int timeout)
|
||||
{
|
||||
if (m_shuttingDown)
|
||||
return;
|
||||
showMessage(msg0, LogStatus);
|
||||
QString msg = msg0;
|
||||
msg.replace(QChar::LineFeed, QLatin1String("; "));
|
||||
@@ -2751,6 +2759,12 @@ void DebuggerPluginPrivate::showStatusMessage(const QString &msg0, int timeout)
|
||||
void DebuggerPluginPrivate::coreShutdown()
|
||||
{
|
||||
m_shuttingDown = true;
|
||||
if (currentEngine()) {
|
||||
if (currentEngine()->state() != Debugger::DebuggerNotReady) {
|
||||
currentEngine()->setTargetState(Debugger::DebuggerFinished);
|
||||
currentEngine()->abortDebugger();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
const CPlusPlus::Snapshot &cppCodeModelSnapshot()
|
||||
@@ -2887,6 +2901,8 @@ void DebuggerPluginPrivate::runControlStarted(DebuggerEngine *engine)
|
||||
|
||||
void DebuggerPluginPrivate::runControlFinished(DebuggerEngine *engine)
|
||||
{
|
||||
if (m_shuttingDown)
|
||||
return;
|
||||
showStatusMessage(tr("Debugger finished."));
|
||||
m_snapshotHandler->removeSnapshot(engine);
|
||||
if (m_snapshotHandler->size() == 0) {
|
||||
@@ -3535,7 +3551,7 @@ QAction *createStartAction()
|
||||
QAction *createStopAction()
|
||||
{
|
||||
auto action = new QAction(DebuggerMainWindow::tr("Stop"), DebuggerPlugin::instance());
|
||||
action->setIcon(Core::Icons::STOP_SMALL.icon());
|
||||
action->setIcon(Core::Icons::STOP_SMALL_TOOLBAR.icon());
|
||||
action->setEnabled(true);
|
||||
return action;
|
||||
}
|
||||
@@ -3672,7 +3688,8 @@ void DebuggerUnitTests::testStateMachine()
|
||||
QTestEventLoop::instance().exitLoop();
|
||||
});
|
||||
|
||||
// QTestEventLoop::instance().enterLoop(20);
|
||||
QTestEventLoop::instance().enterLoop(5);
|
||||
EditorManager::closeAllEditors(false);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -79,6 +79,7 @@ public:
|
||||
QString remoteChannel;
|
||||
QSsh::SshConnectionParameters connParams;
|
||||
bool remoteSetupNeeded = false;
|
||||
QString symbolFile;
|
||||
|
||||
// Used by Mer plugin (3rd party)
|
||||
QMap<QString, QString> sourcePathMap;
|
||||
@@ -92,7 +93,6 @@ public:
|
||||
QVector<QByteArray> expectedSignals;
|
||||
|
||||
// For QNX debugging
|
||||
QString remoteExecutable;
|
||||
bool useCtrlCStub = false;
|
||||
|
||||
// Used by Android to avoid false positives on warnOnRelease
|
||||
|
||||
@@ -164,10 +164,10 @@ void GdbRemoteServerEngine::setupInferior()
|
||||
QTC_ASSERT(state() == InferiorSetupRequested, qDebug() << state());
|
||||
setLinuxOsAbi();
|
||||
const DebuggerRunParameters &rp = runParameters();
|
||||
QString executableFileName;
|
||||
if (!rp.inferior.executable.isEmpty()) {
|
||||
QFileInfo fi(rp.inferior.executable);
|
||||
executableFileName = fi.absoluteFilePath();
|
||||
QString symbolFile;
|
||||
if (!rp.symbolFile.isEmpty()) {
|
||||
QFileInfo fi(rp.symbolFile);
|
||||
symbolFile = fi.absoluteFilePath();
|
||||
}
|
||||
|
||||
//const QByteArray sysroot = sp.sysroot.toLocal8Bit();
|
||||
@@ -208,14 +208,14 @@ void GdbRemoteServerEngine::setupInferior()
|
||||
if (boolSetting(TargetAsync))
|
||||
runCommand({"set target-async on", NoFlags, CB(handleSetTargetAsync)});
|
||||
|
||||
if (executableFileName.isEmpty()) {
|
||||
if (symbolFile.isEmpty()) {
|
||||
showMessage(tr("No symbol file given."), StatusBar);
|
||||
callTargetRemote();
|
||||
return;
|
||||
}
|
||||
|
||||
if (!executableFileName.isEmpty()) {
|
||||
runCommand({"-file-exec-and-symbols \"" + executableFileName.toLocal8Bit() + '"',
|
||||
if (!symbolFile.isEmpty()) {
|
||||
runCommand({"-file-exec-and-symbols \"" + symbolFile.toLocal8Bit() + '"',
|
||||
NoFlags, CB(handleFileExecAndSymbols)});
|
||||
}
|
||||
}
|
||||
@@ -310,7 +310,7 @@ void GdbRemoteServerEngine::handleTargetExtendedRemote(const DebuggerResponse &r
|
||||
runCommand({"attach " + QByteArray::number(runParameters().attachPID),
|
||||
NoFlags, CB(handleTargetExtendedAttach)});
|
||||
} else {
|
||||
runCommand({"-gdb-set remote exec-file " + runParameters().remoteExecutable.toLatin1(),
|
||||
runCommand({"-gdb-set remote exec-file " + runParameters().inferior.executable.toLatin1(),
|
||||
NoFlags, CB(handleTargetExtendedAttach)});
|
||||
}
|
||||
} else {
|
||||
@@ -342,8 +342,9 @@ void GdbRemoteServerEngine::handleTargetQnx(const DebuggerResponse &response)
|
||||
showMessage(_("INFERIOR STARTED"));
|
||||
showMessage(msgAttachedToStoppedInferior(), StatusBar);
|
||||
|
||||
const qint64 pid = isMasterEngine() ? runParameters().attachPID : masterEngine()->runParameters().attachPID;
|
||||
const QString remoteExecutable = isMasterEngine() ? runParameters().remoteExecutable : masterEngine()->runParameters().remoteExecutable;
|
||||
const DebuggerRunParameters &rp = isMasterEngine() ? runParameters() : masterEngine()->runParameters();
|
||||
const qint64 pid = rp.attachPID;
|
||||
const QString remoteExecutable = rp.inferior.executable;
|
||||
if (pid > -1)
|
||||
runCommand({"attach " + QByteArray::number(pid), NoFlags, CB(handleAttach)});
|
||||
else if (!remoteExecutable.isEmpty())
|
||||
@@ -403,12 +404,11 @@ void GdbRemoteServerEngine::runEngine()
|
||||
{
|
||||
QTC_ASSERT(state() == EngineRunRequested, qDebug() << state());
|
||||
|
||||
const QString remoteExecutable = runParameters().remoteExecutable;
|
||||
if (!remoteExecutable.isEmpty()) {
|
||||
runCommand({"-exec-run", RunRequest, CB(handleExecRun)});
|
||||
} else {
|
||||
if (runParameters().useContinueInsteadOfRun) {
|
||||
notifyEngineRunAndInferiorStopOk();
|
||||
continueInferiorInternal();
|
||||
} else {
|
||||
runCommand({"-exec-run", RunRequest, CB(handleExecRun)});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -374,7 +374,7 @@ LogWindow::LogWindow(QWidget *parent)
|
||||
m_commandEdit->setHistoryCompleter(QLatin1String("DebuggerInput"));
|
||||
|
||||
auto repeatButton = new QToolButton(this);
|
||||
repeatButton->setIcon(Icons::STEP_OVER_TOOLBUTTON.icon());
|
||||
repeatButton->setIcon(Icons::STEP_OVER.icon());
|
||||
repeatButton->setFixedSize(QSize(18, 18));
|
||||
repeatButton->setToolTip(tr("Repeat last command for debug reasons."));
|
||||
|
||||
|
||||
@@ -1256,6 +1256,7 @@ void WatchHandler::cleanup()
|
||||
saveWatchers();
|
||||
m_model->reinitialize();
|
||||
emit m_model->updateFinished();
|
||||
if (Internal::mainWindow())
|
||||
m_model->m_separatedView->hide();
|
||||
}
|
||||
|
||||
|
||||
@@ -128,7 +128,7 @@ HelpWidget::HelpWidget(const Core::Context &context, WidgetStyle style, QWidget
|
||||
setAttribute(Qt::WA_QuitOnClose, false); // don't prevent Qt Creator from closing
|
||||
}
|
||||
if (style != SideBarWidget) {
|
||||
m_toggleSideBarAction = new QAction(Core::Icons::TOGGLE_SIDEBAR.icon(),
|
||||
m_toggleSideBarAction = new QAction(Core::Icons::TOGGLE_SIDEBAR_TOOLBAR.icon(),
|
||||
QCoreApplication::translate("Core", Core::Constants::TR_SHOW_SIDEBAR),
|
||||
toolBar);
|
||||
m_toggleSideBarAction->setCheckable(true);
|
||||
@@ -164,7 +164,7 @@ HelpWidget::HelpWidget(const Core::Context &context, WidgetStyle style, QWidget
|
||||
connect(m_homeAction, &QAction::triggered, this, &HelpWidget::goHome);
|
||||
layout->addWidget(Core::Command::toolButtonWithAppendedShortcut(m_homeAction, cmd));
|
||||
|
||||
m_backAction = new QAction(Core::Icons::PREV.icon(), tr("Back"), toolBar);
|
||||
m_backAction = new QAction(Core::Icons::PREV_TOOLBAR.icon(), tr("Back"), toolBar);
|
||||
connect(m_backAction, &QAction::triggered, this, &HelpWidget::backward);
|
||||
m_backMenu = new QMenu(toolBar);
|
||||
connect(m_backMenu, &QMenu::aboutToShow, this, &HelpWidget::updateBackMenu);
|
||||
@@ -175,7 +175,7 @@ HelpWidget::HelpWidget(const Core::Context &context, WidgetStyle style, QWidget
|
||||
button->setPopupMode(QToolButton::DelayedPopup);
|
||||
layout->addWidget(button);
|
||||
|
||||
m_forwardAction = new QAction(Core::Icons::NEXT.icon(), tr("Forward"), toolBar);
|
||||
m_forwardAction = new QAction(Core::Icons::NEXT_TOOLBAR.icon(), tr("Forward"), toolBar);
|
||||
connect(m_forwardAction, &QAction::triggered, this, &HelpWidget::forward);
|
||||
m_forwardMenu = new QMenu(toolBar);
|
||||
connect(m_forwardMenu, &QMenu::aboutToShow, this, &HelpWidget::updateForwardMenu);
|
||||
|
||||
@@ -260,10 +260,10 @@ void ImageViewer::updatePauseAction()
|
||||
bool isMovie = d->file->type() == ImageViewerFile::TypeMovie;
|
||||
if (isMovie && !d->file->isPaused()) {
|
||||
d->ui_toolbar.toolButtonPlayPause->setToolTipBase(tr("Pause Animation"));
|
||||
d->ui_toolbar.toolButtonPlayPause->setIcon(Core::Icons::INTERRUPT_SMALL.icon());
|
||||
d->ui_toolbar.toolButtonPlayPause->setIcon(Core::Icons::INTERRUPT_SMALL_TOOLBAR.icon());
|
||||
} else {
|
||||
d->ui_toolbar.toolButtonPlayPause->setToolTipBase(tr("Play Animation"));
|
||||
d->ui_toolbar.toolButtonPlayPause->setIcon(Core::Icons::RUN_SMALL.icon());
|
||||
d->ui_toolbar.toolButtonPlayPause->setIcon(Core::Icons::RUN_SMALL_TOOLBAR.icon());
|
||||
d->ui_toolbar.toolButtonPlayPause->setEnabled(isMovie);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -42,7 +42,7 @@ IosRunControl::IosRunControl(IosRunConfiguration *rc)
|
||||
, m_runner(new IosRunner(this, rc, false, QmlDebug::NoQmlDebugServices))
|
||||
, m_running(false)
|
||||
{
|
||||
setIcon(Core::Icons::RUN_SMALL);
|
||||
setIcon(Core::Icons::RUN_SMALL_TOOLBAR);
|
||||
}
|
||||
|
||||
IosRunControl::~IosRunControl()
|
||||
|
||||
@@ -157,7 +157,7 @@ AppOutputPane::AppOutputPane() :
|
||||
setObjectName(QLatin1String("AppOutputPane")); // Used in valgrind engine
|
||||
|
||||
// Rerun
|
||||
m_reRunButton->setIcon(Core::Icons::RUN_SMALL.icon());
|
||||
m_reRunButton->setIcon(Core::Icons::RUN_SMALL_TOOLBAR.icon());
|
||||
m_reRunButton->setToolTip(tr("Re-run this run-configuration"));
|
||||
m_reRunButton->setAutoRaise(true);
|
||||
m_reRunButton->setEnabled(false);
|
||||
@@ -165,7 +165,7 @@ AppOutputPane::AppOutputPane() :
|
||||
this, &AppOutputPane::reRunRunControl);
|
||||
|
||||
// Stop
|
||||
m_stopAction->setIcon(Core::Icons::STOP_SMALL.icon());
|
||||
m_stopAction->setIcon(Core::Icons::STOP_SMALL_TOOLBAR.icon());
|
||||
m_stopAction->setToolTip(tr("Stop"));
|
||||
m_stopAction->setEnabled(false);
|
||||
|
||||
@@ -643,7 +643,7 @@ void AppOutputPane::enableButtons(const RunControl *rc, bool isRunning)
|
||||
m_zoomOutButton->setEnabled(true);
|
||||
} else {
|
||||
m_reRunButton->setEnabled(false);
|
||||
m_reRunButton->setIcon(Core::Icons::RUN_SMALL.icon());
|
||||
m_reRunButton->setIcon(Core::Icons::RUN_SMALL_TOOLBAR.icon());
|
||||
m_attachButton->setEnabled(false);
|
||||
m_attachButton->setToolTip(msgAttachDebuggerTooltip());
|
||||
m_stopAction->setEnabled(false);
|
||||
|
||||
@@ -63,7 +63,7 @@ LocalApplicationRunControl::LocalApplicationRunControl(RunConfiguration *rc, Cor
|
||||
: RunControl(rc, mode)
|
||||
{
|
||||
setRunnable(rc->runnable());
|
||||
setIcon(Core::Icons::RUN_SMALL);
|
||||
setIcon(Core::Icons::RUN_SMALL_TOOLBAR);
|
||||
connect(&m_applicationLauncher, &ApplicationLauncher::appendMessage,
|
||||
this, static_cast<void(RunControl::*)(const QString &, Utils::OutputFormat)>(&RunControl::appendMessage));
|
||||
connect(&m_applicationLauncher, &ApplicationLauncher::processStarted,
|
||||
|
||||
@@ -686,7 +686,7 @@ bool ProjectExplorerPlugin::initialize(const QStringList &arguments, QString *er
|
||||
ActionContainer *runMenu = ActionManager::createMenu(Constants::RUNMENUCONTEXTMENU);
|
||||
runMenu->setOnAllDisabledBehavior(ActionContainer::Hide);
|
||||
QIcon runIcon = Utils::Icon::sideBarIcon(Icons::RUN, Icons::RUN_FLAT);
|
||||
runIcon.addPixmap(Core::Icons::RUN_SMALL.pixmap());
|
||||
runIcon.addPixmap(Core::Icons::RUN_SMALL_TOOLBAR.pixmap());
|
||||
runMenu->menu()->setIcon(runIcon);
|
||||
runMenu->menu()->setTitle(tr("Run"));
|
||||
msubProjectContextMenu->addMenu(runMenu, ProjectExplorer::Constants::G_PROJECT_RUN);
|
||||
@@ -884,7 +884,7 @@ bool ProjectExplorerPlugin::initialize(const QStringList &arguments, QString *er
|
||||
mbuild->addAction(cmd, Constants::G_BUILD_CLEAN);
|
||||
|
||||
// cancel build action
|
||||
dd->m_cancelBuildAction = new QAction(Core::Icons::STOP_SMALL.icon(), tr("Cancel Build"), this);
|
||||
dd->m_cancelBuildAction = new QAction(Core::Icons::STOP_SMALL_TOOLBAR.icon(), tr("Cancel Build"), this);
|
||||
cmd = ActionManager::registerAction(dd->m_cancelBuildAction, Constants::CANCELBUILD);
|
||||
mbuild->addAction(cmd, Constants::G_BUILD_CANCEL);
|
||||
|
||||
|
||||
@@ -45,17 +45,20 @@ const Utils::Icon REBUILD({
|
||||
const Utils::Icon RUN(
|
||||
QLatin1String(":/projectexplorer/images/run.png"));
|
||||
const Utils::Icon RUN_FLAT({
|
||||
{QLatin1String(":/projectexplorer/images/run_mask.png"), Utils::Theme::IconsRunColor}});
|
||||
{QLatin1String(":/projectexplorer/images/run_mask.png"), Utils::Theme::IconsRunToolBarColor}});
|
||||
const Utils::Icon WINDOW(
|
||||
QLatin1String(":/projectexplorer/images/window.png"));
|
||||
const Utils::Icon DEBUG_START(
|
||||
QLatin1String(":/projectexplorer/images/debugger_start.png"));
|
||||
|
||||
const Utils::Icon DEBUG_START_FLAT({
|
||||
{QLatin1String(":/projectexplorer/images/run_mask.png"), Utils::Theme::IconsRunColor},
|
||||
{QLatin1String(":/projectexplorer/images/run_mask.png"), Utils::Theme::IconsRunToolBarColor},
|
||||
{QLatin1String(":/projectexplorer/images/debugger_beetle_mask.png"), Utils::Theme::IconsDebugColor}});
|
||||
const Utils::Icon DEBUG_START_SMALL({
|
||||
{QLatin1String(":/core/images/run_small.png"), Utils::Theme::IconsRunColor},
|
||||
{QLatin1String(":/projectexplorer/images/debugger_overlay_small.png"), Utils::Theme::PanelTextColorMid}}, Utils::Icon::MenuTintedStyle);
|
||||
const Utils::Icon DEBUG_START_SMALL_TOOLBAR({
|
||||
{QLatin1String(":/core/images/run_small.png"), Utils::Theme::IconsRunToolBarColor},
|
||||
{QLatin1String(":/projectexplorer/images/debugger_overlay_small.png"), Utils::Theme::IconsDebugColor}});
|
||||
|
||||
const Utils::Icon BUILDSTEP_MOVEUP({
|
||||
|
||||
@@ -1059,7 +1059,7 @@ RunControl *PythonRunControlFactory::create(RunConfiguration *runConfiguration,
|
||||
PythonRunControl::PythonRunControl(PythonRunConfiguration *rc, Core::Id mode)
|
||||
: RunControl(rc, mode), m_running(false)
|
||||
{
|
||||
setIcon(Core::Icons::RUN_SMALL);
|
||||
setIcon(Core::Icons::RUN_SMALL_TOOLBAR);
|
||||
|
||||
m_interpreter = rc->interpreter();
|
||||
m_mainScript = rc->mainScript();
|
||||
|
||||
@@ -385,4 +385,17 @@ MetaInfo {
|
||||
}
|
||||
|
||||
|
||||
Type {
|
||||
name: "QtQuick.Controls.TreeView"
|
||||
icon: ":/componentsplugin/images/window16.png"
|
||||
|
||||
ItemLibraryEntry {
|
||||
name: "TreeView"
|
||||
category: "Qt Quick - Controls"
|
||||
libraryIcon: ":/componentsplugin/images/window.png"
|
||||
version: "1.4"
|
||||
requiredImport: "QtQuick.Controls"
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -67,6 +67,7 @@ Runnable QmlProjectRunConfiguration::runnable() const
|
||||
r.executable = executable();
|
||||
r.commandLineArguments = commandLineArguments();
|
||||
r.runMode = ApplicationLauncher::Gui;
|
||||
r.environment = extraAspect<QmlProjectEnvironmentAspect>()->environment();
|
||||
r.workingDirectory = canonicalCapsPath(target()->project()->projectFilePath()
|
||||
.toFileInfo().absolutePath());
|
||||
return r;
|
||||
|
||||
@@ -65,8 +65,8 @@ static DebuggerStartParameters createDebuggerStartParameters(QnxRunConfiguration
|
||||
|
||||
params.startMode = AttachToRemoteServer;
|
||||
params.useCtrlCStub = true;
|
||||
params.inferior.executable = runConfig->localExecutableFilePath();
|
||||
params.remoteExecutable = runConfig->remoteExecutableFilePath();
|
||||
params.inferior.executable = runConfig->remoteExecutableFilePath();
|
||||
params.symbolFile = runConfig->localExecutableFilePath();
|
||||
params.remoteChannel = device->sshParameters().host + QLatin1String(":-1");
|
||||
params.remoteSetupNeeded = true;
|
||||
params.closeMode = KillAtClose;
|
||||
|
||||
@@ -43,7 +43,7 @@ public:
|
||||
RemoteLinuxRunControl::RemoteLinuxRunControl(RunConfiguration *rc)
|
||||
: RunControl(rc, ProjectExplorer::Constants::NORMAL_RUN_MODE), d(new RemoteLinuxRunControlPrivate)
|
||||
{
|
||||
setIcon(Core::Icons::RUN_SMALL);
|
||||
setIcon(Core::Icons::RUN_SMALL_TOOLBAR);
|
||||
setRunnable(rc->runnable());
|
||||
|
||||
d->running = false;
|
||||
|
||||
@@ -101,10 +101,10 @@ RunControl *RemoteLinuxRunControlFactory::create(RunConfiguration *runConfig, Co
|
||||
return 0;
|
||||
}
|
||||
|
||||
QString localExecutable;
|
||||
QString symbolFile;
|
||||
if (auto rlrc = qobject_cast<RemoteLinuxRunConfiguration *>(runConfig))
|
||||
localExecutable = rlrc->localExecutableFilePath();
|
||||
if (localExecutable.isEmpty()) {
|
||||
symbolFile = rlrc->localExecutableFilePath();
|
||||
if (symbolFile.isEmpty()) {
|
||||
*errorMessage = tr("Cannot debug: Local executable is not set.");
|
||||
return 0;
|
||||
}
|
||||
@@ -120,14 +120,14 @@ RunControl *RemoteLinuxRunControlFactory::create(RunConfiguration *runConfig, Co
|
||||
}
|
||||
if (aspect->useCppDebugger()) {
|
||||
aspect->setUseMultiProcess(true);
|
||||
params.inferior.executable = stdRunnable.executable;
|
||||
params.inferior.commandLineArguments = stdRunnable.commandLineArguments;
|
||||
if (aspect->useQmlDebugger()) {
|
||||
params.inferior.commandLineArguments.prepend(QLatin1Char(' '));
|
||||
params.inferior.commandLineArguments.prepend(QmlDebug::qmlDebugTcpArguments(QmlDebug::QmlDebuggerServices));
|
||||
}
|
||||
params.inferior.commandLineArguments = localExecutable;
|
||||
params.remoteChannel = dev->sshParameters().host + QLatin1String(":-1");
|
||||
params.remoteExecutable = stdRunnable.executable;
|
||||
params.symbolFile = symbolFile;
|
||||
}
|
||||
|
||||
DebuggerRunControl * const runControl = createDebuggerRunControl(params, runConfig, errorMessage, mode);
|
||||
|
||||
@@ -370,7 +370,7 @@ CallgrindTool::CallgrindTool(QObject *parent)
|
||||
// pause action
|
||||
m_pauseAction = action = new QAction(this);
|
||||
action->setCheckable(true);
|
||||
action->setIcon(Core::Icons::INTERRUPT_SMALL.icon());
|
||||
action->setIcon(Core::Icons::INTERRUPT_SMALL_TOOLBAR.icon());
|
||||
//action->setText(tr("Ignore"));
|
||||
action->setToolTip(tr("Pause event logging. No events are counted which will speed up program execution during profiling."));
|
||||
connect(action, &QAction::toggled, this, &CallgrindTool::pauseToggled);
|
||||
@@ -379,14 +379,14 @@ CallgrindTool::CallgrindTool(QObject *parent)
|
||||
// go back
|
||||
m_goBack = action = new QAction(this);
|
||||
action->setDisabled(true);
|
||||
action->setIcon(Core::Icons::PREV.icon());
|
||||
action->setIcon(Core::Icons::PREV_TOOLBAR.icon());
|
||||
action->setToolTip(tr("Go back one step in history. This will select the previously selected item."));
|
||||
connect(action, &QAction::triggered, &m_stackBrowser, &StackBrowser::goBack);
|
||||
|
||||
// go forward
|
||||
m_goNext = action = new QAction(this);
|
||||
action->setDisabled(true);
|
||||
action->setIcon(Core::Icons::NEXT.icon());
|
||||
action->setIcon(Core::Icons::NEXT_TOOLBAR.icon());
|
||||
action->setToolTip(tr("Go forward one step in history."));
|
||||
connect(action, &QAction::triggered, &m_stackBrowser, &StackBrowser::goNext);
|
||||
|
||||
|
||||
@@ -355,7 +355,7 @@ MemcheckTool::MemcheckTool(QObject *parent)
|
||||
// Go to previous leak.
|
||||
action = new QAction(this);
|
||||
action->setDisabled(true);
|
||||
action->setIcon(Core::Icons::PREV.icon());
|
||||
action->setIcon(Core::Icons::PREV_TOOLBAR.icon());
|
||||
action->setToolTip(tr("Go to previous leak."));
|
||||
connect(action, &QAction::triggered, m_errorView, &MemcheckErrorView::goBack);
|
||||
m_goBack = action;
|
||||
@@ -363,7 +363,7 @@ MemcheckTool::MemcheckTool(QObject *parent)
|
||||
// Go to next leak.
|
||||
action = new QAction(this);
|
||||
action->setDisabled(true);
|
||||
action->setIcon(Core::Icons::NEXT.icon());
|
||||
action->setIcon(Core::Icons::NEXT_TOOLBAR.icon());
|
||||
action->setToolTip(tr("Go to next leak."));
|
||||
connect(action, &QAction::triggered, m_errorView, &MemcheckErrorView::goNext);
|
||||
m_goNext = action;
|
||||
|
||||
@@ -56,7 +56,7 @@ WinRtRunControl::WinRtRunControl(WinRtRunConfiguration *runConfiguration, Core::
|
||||
, m_state(StoppedState)
|
||||
, m_runner(0)
|
||||
{
|
||||
setIcon(Core::Icons::RUN_SMALL);
|
||||
setIcon(Core::Icons::RUN_SMALL_TOOLBAR);
|
||||
}
|
||||
|
||||
void WinRtRunControl::start()
|
||||
|
||||
@@ -5,6 +5,6 @@ HEADERS += $$PWD/registryaccess.h
|
||||
|
||||
LIBS *= -lpsapi
|
||||
# PS API and registry functions
|
||||
win32-msvc* {
|
||||
msvc {
|
||||
LIBS *= -ladvapi32
|
||||
}
|
||||
|
||||
@@ -258,6 +258,20 @@ TEST_F(ClangCompletionContextAnalyzer, ParameteTwoWithSpaceAtCall)
|
||||
ASSERT_THAT(analyzer, HasResult(CCA::PassThroughToLibClangAfterLeftParen, -5, -3, positionInText));
|
||||
}
|
||||
|
||||
TEST_F(ClangCompletionContextAnalyzer, WhitespaceAfterFunctionName)
|
||||
{
|
||||
auto analyzer = runAnalyzer("foo (@");
|
||||
|
||||
ASSERT_THAT(analyzer, HasResult(CCA::PassThroughToLibClangAfterLeftParen, -5, 0, positionInText));
|
||||
}
|
||||
|
||||
TEST_F(ClangCompletionContextAnalyzer, AfterOpeningParenthesis)
|
||||
{
|
||||
auto analyzer = runAnalyzer("(@");
|
||||
|
||||
ASSERT_THAT(analyzer, HasResult(CCA::PassThroughToLibClang, 0, 0, positionInText));
|
||||
}
|
||||
|
||||
TEST_F(ClangCompletionContextAnalyzer, ParameteOneAtSignal)
|
||||
{
|
||||
auto analyzer = runAnalyzer("SIGNAL(@");
|
||||
|
||||