Instead of letting the launcher decide to raise something when
started (and only then) leave it to the RunControl to trigger
(and for now also to implement) as response to the application
launcher start (or possibly now, in other circumstances).
Change-Id: I0ac8f1e633981f7bf316c88e83c208765886d9a1
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
android app in mixed mode debugging sometimes keeps waiting for the
qml engine connection.
Task-number: QTCREATORBUG-17718
Change-Id: Iee87cd0a6d67babaf08e62a6e106ec22fda430cd
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
If the engine is running and no specific context is selected, then it's
the global QML context. The same holds if the engine is running, but
the server doesn't support contextual evaluation. If the engine is
stopped, then it's a frame in the stack trace. Otherwise we don't have
a context and clear the label.
Change-Id: I5a322098f3297895e07bcc96ee4a5f351423c206
Reviewed-by: hjk <hjk@qt.io>
As we can have a context again now, we should be able to show it.
This reverts commit 8679a7caa6.
Task-number: QTCREATORBUG-17177
Change-Id: I221628dc91af839be867cc1bf8dfe5d5163fd321
Reviewed-by: hjk <hjk@qt.io>
Newer V4 debug servers will accept a "context" parameter which
specifies the ID of an object which is then used to look up a QML
context to inject when evaluating expressions.
Change-Id: I9d2a2226559380550308cacfe559e079291c14b5
Task-number: QTCREATORBUG-17177
Reviewed-by: hjk <hjk@qt.io>
If the list of partial expressions is empty we need to tell the watch
handler that we are only updating the locals view, not e.g. the
inspector view.
Change-Id: Iedc74ffc66a8435faa272d053849b831f6b8cbbe
Task-number: QTCREATORBUG-16692
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: hjk <hjk@qt.io>
This allows us to sort the locals by name immediately when the action
is triggered.
Task-number: QTCREATORBUG-16645
Change-Id: Ifd24f49e66523af5e988065c9a33aae00e7fb290
Reviewed-by: hjk <hjk@qt.io>
Will be triggered in handleScope()/insertSubItems() anyway.
Change-Id: Id5e236c231558c819398b38a13fb06def9ae39a6
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: hjk <hjk@qt.io>
There is no point in trying to "gracefully" shutdown by waiting for the
application to hit the next line of JavaScript. The application might
never execute any more JavaScript.
Change-Id: Id531a2b23ce9aa12462e308f29106f8cefa67092
Task-number: QTCREATORBUG-16709
Reviewed-by: hjk <hjk@qt.io>
There is no reason to clear all the other views, too. The inspector
view stays valid across interruptions and the C++ views have nothing
to do with this at all.
Change-Id: I7a0bfe160a6b3c0134d592abef9c10f95fcfcd3f
Task-number: QTCREATORBUG-16692
Reviewed-by: hjk <hjk@qt.io>
After sending the interrupt request the application will continue to
the next line of JavaScript and only interrupt then. There is no way
to interrupt the application via the JS debugger as long as no JS
engine is active.
The downside of this is that the pause/continue/stop icons are disabled
until the application actually interrupts. The user might not
understand this.
Change-Id: I355de52f65898d6bdcd437675adba368662f3c13
Task-number: QTCREATORBUG-16646
Reviewed-by: hjk <hjk@qt.io>
A socket error is not the only possible reason for a connection failure
and exposing socket error codes to the upper layers is unnecessary.
Change-Id: I27e9f21160ecea5b0d811b83b7ab0ab9071cacff
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
The main idea is to start using ProjectExplorer::Connection later.
Change-Id: Ie91eacdfb0e93ae142fec7ce32bcf554a5282122
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
For better typesafety on the user side (and optional) for items with uniformly
typed children. Use it for UniformTreeModels, and consequently WatchModel
to get rid of some of the static_casts there.
Change-Id: Ic20e507036e180c24997b236230f0f71b285202c
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
With QT_RESTRICTED_CAST_FROM_ASCII making GdbMi etc operate on
QString is feasible again. Take this as opportunity to move
debugger encoding handling closer to a 'conversion on input and
output if needed, storage in QString only' scheme.
Change-Id: I2f10c9fa8a6c62c44f4e6682efe3769e9fba30f7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
You can now interact with QML objects selected with the "select" tool
again, when unpausedEvaluate is off.
Change-Id: If6b4a55193a8949b2e3048fe78443c5df6710885
Task-number: QTCREATORBUG-16300
Reviewed-by: Jonathan Liu <net147@gmail.com>
Reviewed-by: hjk <hjk@theqtcompany.com>
This solves the ambiguity between 0 and -1 being the "invalid" port.
Change-Id: I3bac11dd4117bb1820fbd58186699925b73df1c5
Reviewed-by: hjk <hjk@theqtcompany.com>
Multiple copies of lookup requests may accumulate when stepping
too quickly, outsmarting the 'all updates done' logic, keeping
Locals&Expressions in the grey 'update ongoing' state.
Change-Id: Icec24ce1af8d273c3439ee91800ed1f4381ee19a
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
(cherry picked from commit c1de315d6c)
This avoids accumulating lookup requests when stepping quickly.
They won't produce usable output anymore.
Change-Id: I9e29ca1778019e3eab37d122386d3faf0e07edbf
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
This was display only, with no impact on the console operation.
Change-Id: I1c6cab13a86b574d3912ea7fca2e0f14147b828c
Task-number: QTCREATORBUG-15831
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
The sender()/qobject_cast construct is ugly, unnecessary and it doesn't
work if the method is called directly, rather than through a signal.
Change-Id: I0ac09ad04b956fb4cac38a89162a9dc0055d1831
Reviewed-by: hjk <hjk@theqtcompany.com>
Displaying live contents uses nowadays a feature of Qt 5.7. The previous
display was not using the correct context. For Qt < 5.7, access is now
only possible when the context is clear (e.g. because a breakpoint
was hit). This patch adjusts the error message in the other case.
Task-number: QTCREATORBUG-15831
Change-Id: Ic25a3f6bca05523b16063f3e7daed6817c0002e7
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
This is a mechanical replacement for the former executable, processArgs,
inferiorEnvironment and workingDirectory members.
Change-Id: I4160e01427ed801df9b729f1f31d0a2ca48159b5
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
Newer versions of Qt can evaluate expressions without pausing the
QML engine. We can take advantage of that. At the same time we can
remove the crutch of using QQmlEngineDebugService for this. The
latter produces inconsistent and generally worse results than the V4
debug service.
Task-number: QTCREATORBUG-14931
Change-Id: Ic78d08a0b00cf7de3911b7b672ce229c6d779363
Reviewed-by: hjk <hjk@theqtcompany.com>
Don't instantiate repeating boilerplate item data in some
cases (such as large arrays).
This makes it necessary to access parent WatchItems in
a lot more cases than before and needs another separation of
WatchItem/WatchModel code to keep the dumper autotests
in a functional state.
For a plain std::vector<int> with 1 mio items this reduces
extraction time from more than 2 minutes to about 3 seconds.
Change-Id: I175c5f6ee90434a6e85342d8bb71bd10a04dd271
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
Debugger and stub run locally, the debugged process not necessarily.
Change-Id: Ibf6aec3dcaec60069866ec0765ec2178ca0a26d6
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
Now it is closer to its only user and possibly reusable for no-QML uses
there. We also drop the QML/JS syntax checker. The application being
debugged can already tell us about syntax errors. There is no need to
duplicate that functionality.
Change-Id: I2ba151f9f4c854c6119ba5462c21be40bddcebf9
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
Reviewed-by: hjk <hjk@theqtcompany.com>
The debugger log is not very accessible and people may want to see this
message.
Change-Id: Id5e5a6d84f3576df3756d1fabc9f5801dcebac6e
Reviewed-by: hjk <hjk@theqtcompany.com>
The message window can do that by itself and in other places we may
want to print the whole message in one line.
Change-Id: I5f0891c7b81717182d17b83f5a62ab06ad168801
Reviewed-by: hjk <hjk@theqtcompany.com>
Just like with the QML-only engine we might not get the output for a
variety of reasons. As we've specified the port on the command line,
it's likely that the application will start listening at some point,
though.
Change-Id: Ifda69ba15c659cf95e708d35bed34cfb9b3c40ec
Task-number: QTCREATORBUG-15409
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
There is no point in sending two signals for every state change and
error. Also, the signals only reflect events in the socket, not in the
logical connection.
Change-Id: I617a925c69164aa1a02a7781b9da7dca55daa304
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
This is to adopt the naming to the code in src/qmldebug in
qtdeclarative. Once we can require a version of Qt that has qmldebug
for building QtCreator we can then remove our own version of this code.
Change-Id: I573f0703871b5812789c5c7a6287567d5c2875e6
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>