Commit Graph

10 Commits

Author SHA1 Message Date
Marcus Tillmanns
f2d62c6d91 Copilot: Add support for proxy settings
For easier testing a docker file is added. You can start
"buildandrun.sh" in copilot/tests/proxy to get a simple
proxy server up and running. The argument "PWDMODE" in
buildandrun.sh can be set to "with" and "without" to get
a proxy server that needs a password or not. The username
and password are user/1234.

Fixes: QTCREATORBUG-29485
Change-Id: I3859c9ad04ebd4f9349e25665ba710e23fb64dea
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2023-08-16 06:54:54 +00:00
Marcus Tillmanns
bdb31d4348 Copilot: Allow user to disable Copilot
Fixes: QTCREATORBUG-29179
Change-Id: I274de1f13f773fb61b376643b61056b6f14dabaf
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2023-05-26 12:55:57 +00:00
David Schulz
0b8a0f8f59 Copilot: remove unused function and member
Change-Id: I77bc6533f658dbd6c3b58f603f384e6c516974df
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-05-11 05:50:19 +00:00
David Schulz
6ab923c39f Copilot: add copilot suggestion tooltips
These tooltips allow to switch the currently visible suggestion as well
as applying it using
the mouse.

Change-Id: I30b9a76ae57c66887f4e1b1311e1a7248ed0f194
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-03-29 07:43:28 +00:00
David Schulz
48cd81b015 Copilot: fixup compression timer cleanup
Unfortunately the timer gets deleted to early when the temporary object
that gets copied into the hash gets deleted. Delete the timer only if
the editor widget or client gets destructed.

Amends e6e895d6be

Change-Id: Ifee0dce337e7fc69ffeaeb82901135bd23ea8d81
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-03-24 14:12:36 +00:00
David Schulz
e6e895d6be Copilot: correctly cleanup compression timer
fixes a leak and a crash if the timer triggers after the widget was
deleted.

Change-Id: I57794009186d4c5e4dee0b0c0746ffc5468000b7
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-03-24 12:00:50 +00:00
David Schulz
23513bb714 Copilot: remove unused client instance function
Change-Id: I84c3d674bae1011a7b0bff070c2d3d5d89675147
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-03-16 11:55:50 +00:00
David Schulz
301a3cb34f Copilot: improve client handling
- centralize starting client
 - allow to start copilot with alternative settings
 - do not reset the client on finished.

A finish might be followed by a restart attempt, so untracking the
client in the plugin can result in having multiple running clients. Use
a QPointer instead to safely reset once the client is deleted.

Change-Id: Ifab8b04287d84bbdd4a0e936f4684b8d4391da2b
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-03-13 08:00:01 +00:00
David Schulz
9feef11b5d Copilot: robustify request logic
Change-Id: Ifa46bc05f0bab8e3c7fc40d855a35e940f0628da
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-03-03 13:34:40 +00:00
Marcus Tillmanns
625f0ef726 Copilot: Add LSP plugin for Copilot
Fixes: QTCREATORBUG-27771
Change-Id: I1249b9a4492427208a70b3e21bf20ac668fc3c50
Reviewed-by: hjk <hjk@qt.io>
2023-02-21 10:26:12 +00:00