summaryrefslogtreecommitdiff
path: root/src/plugins/git
Commit message (Collapse)AuthorAgeFilesLines
* Utils: Unify CheckableMessageBox and make it look more nativeMarcus Tillmanns2023-05-171-8/+10
| | | | | | Change-Id: I5690c16f38cfd2058e01441283bec28d44cadf75 Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Git: Cache author and encoding for instant blameAndre Hartmann2023-05-171-6/+21
| | | | | | | | | | Querying both may be expensive and is only necessary when the repository is changed. Fixes: QTCREATORBUG-29151 Change-Id: I1d37f8b8708c02a8c3dc2d89fe7e331f0f416818 Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Git: Fix missing instant blame with line foldingAndre Hartmann2023-05-171-1/+1
| | | | | | | | | | | | When lines are folded (e.g. the license header), the editors lineCount() is smaller than its blockCount(). That resulted in missing blame marks for the last document lines. E.g. if 10 lines were folded, the last 10 lines did not have blame marks. Change-Id: I502afb09697fd3d6a062d3ae2321357a3e565a0e Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
* Vcs: Use PagedSettings for all plugin settingshjk2023-05-153-59/+46
| | | | | | | | | Hopefully the last structural change for a while. Settings lifetime is again tied to the plugin private. Change-Id: I221e8b8baa69422306191b48a9f034ef5b1a0dc2 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Git: Also use the latest settings setup approachhjk2023-05-1510-63/+63
| | | | | Change-Id: I34a210575d02d18927c1e0f6d8ea6cb9924c563d Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* All: Use the shorter access to aspect values in a few placeshjk2023-05-122-4/+4
| | | | | Change-Id: Ie0ff0e4e1cf4c2750897ea733dfccb743f44fa93 Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
* TaskTree: Prepare for de-utils-ization - part 2Jarek Kobus2023-05-125-11/+8
| | | | | | | | | Move TaskTree into Tasking namespace. Move Tasking namespace out of Utils namespace. Change-Id: Ib4c1d7f54f1808517e54768dfa27209c33517b61 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: hjk <hjk@qt.io>
* Utils: Centralize style-related property names as constantsAlessandro Portale2023-05-101-3/+4
| | | | | | | | | | This introduces string constants in Utils::StyleHelper. They are used by code all over in Qt Creator to tell ManhattanStyle how to paint certain widgets. Change-Id: Iecca36103f80084cd5fe93fcb6b18b8fbb3a32bb Reviewed-by: Christian Stenger <christian.stenger@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Remove ineffective resize() callsAlessandro Portale2023-05-101-2/+0
| | | | | | | | | | | This removes apparently unnecessary resize() calls on QWidgets based forms which get anyways added to layouts and resized. Most of these size values looked "accidental", i.e. neither divisible by 2 nor by 5, in most cases a remnant from the ui inlining. Change-Id: I95da3b93f2915ef955b5235e5c2ecc94b51f813a Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: hjk <hjk@qt.io>
* Tasking::Tree: Rename Tree into TaskTreeTaskJarek Kobus2023-05-101-1/+1
| | | | | | | Task-number: QTCREATORBUG-29102 Change-Id: I70073bcb44a712c427c8c5aea42c48dbc30eebe0 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: hjk <hjk@qt.io>
* Process: Rename QtcProcessPrivate -> ProcessPrivateJarek Kobus2023-05-101-1/+1
| | | | | | | | | | Rename the logging category for Process. Fix inline comments accordingly. Adapt warning/debug messages accordingly. Change-Id: I2b1f0f558701def3afa3c1b04adf629833dba9e7 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: hjk <hjk@qt.io>
* FileSearch: Get rid of FileSearchResultJarek Kobus2023-05-092-14/+13
| | | | | | | | | Use SearchResultItem instead. This change should reduce the remaining freeze described in a9eb732ce6763e22badd92fc8523cebe84b09a84 even more. Change-Id: I102b82ed5677360ccd9e425dd0bdd941d87116f0 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Git: Use LayoutBuilder in Gerrit options pagehjk2023-05-084-84/+78
| | | | | | | | Move towards using aspects and away from IOptionPage's QObject base. Change-Id: I07850a6b8e9fa7d2591efc6f76a23f249dfc164f Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Git: Small simplification to Gerrit "plugin" setuphjk2023-05-083-14/+13
| | | | | | | | The indirection is not needed. It's not really stand-alone, and not touched before GitPlugin::initialize(). Change-Id: If8552dc69ff9efa18a3f1d6d998a8f28ab65e501 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Utils: Move SearchResultItem/Color into UtilsJarek Kobus2023-05-081-3/+8
| | | | | | | | | It's going to be reused inside FileSearch. Change-Id: I8993d7158ff31c311c2283d32bc43465a8946a52 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Git: Change default shortcuts for "Current Project" to RepositoryOrgad Shaneh2023-05-081-6/+6
| | | | | | | | | | Current Project is misleading. Current Repository refers to the repository of the current file, which is much more expected for "everything around" actions (Diff, Log). Task-number: QTCREATORBUG-10170 Change-Id: I252f40cd3dfd9de184a889355b59f91bb64983dd Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Utils: Rename qtcprocess.{cpp,h} -> process.{cpp,h}Jarek Kobus2023-05-048-8/+8
| | | | | | | | Follows QtcProcess -> Process rename. Change-Id: I97235a9a40cb7fd52944515b7ab878d96528f919 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Utils: Rename QtcProcess -> ProcessJarek Kobus2023-05-0410-54/+54
| | | | | | | | Task-number: QTCREATORBUG-29102 Change-Id: Ibc264f9db6a32206e4097766ee3f7d0b35225a5c Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: hjk <hjk@qt.io>
* Layouting: Handle attach types via setterhjk2023-05-031-1/+2
| | | | | | Change-Id: I862f5cd109db3582b4f029787ec0cded2da39ce6 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
* Utils: Rename asynctask.{cpp,h} -> async.{cpp,h}Jarek Kobus2023-05-034-4/+4
| | | | | | | Follows AsyncTask -> Async rename. Change-Id: I37f18368ab826c9960a24087b52f6691bb33f225 Reviewed-by: hjk <hjk@qt.io>
* Tasking::Process: Rename Process into ProcessTaskJarek Kobus2023-05-034-15/+15
| | | | | | | | Rename QtcProcessAdapter into ProcessTaskAdapter. Task-number: QTCREATORBUG-29102 Change-Id: I1902c7176da75db60d70125f505084a2ea5ba774 Reviewed-by: hjk <hjk@qt.io>
* Fix compiler warningsEike Ziller2023-05-021-2/+2
| | | | | | | | Change-Id: I9b0b4a60d1152142f62bf3f76885cf8019714623 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Sivert Krøvel <sivert.krovel@qt.io> Reviewed-by: Christian Stenger <christian.stenger@qt.io> Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
* FutureSynchronizer: Change the default value of cancelOnWait to trueJarek Kobus2023-04-261-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The "false" default wasn't really useful. This changes the default value to the following usages: 1. AndroidDeployQtStep Introduced in 91f136ef3ab75471cabcaed9dc16dad9f504add8 The synchronizer was used to cancel the running tasks inside the doCancel(), so the similar behavior should be expected when destructing the AndroidDeployQtStep. 2. GitClient Introduced in f3106ebafe9a02904e822e9698c8b4cbb6c7e0f5 Is used only inside the last line of GitSubmitEditor::updateFileModel(). The running function (CommitDataFetchResult::fetch) doesn't take QPromise<>, so it can't detect if the future was canceled or not. In this case this change is no-op. 3. ExtraCompiler Introduced in c99ce1f455189864de9a2043730f704d7b024abf The intention was to make it cancellable and finish early on cancel. 4. PluginManager global future synchronizer Introduced in 72bddf9f51fedd064f551bcb4ced5feeb46fdfc1 The intention was to make it cancellable and finish early on cancel. The relevant places in code are marked explicitly for points: 1, 2 and 3. Change-Id: I1a52deb8d1f81d355950c8772bbaa6d0a202fd7e Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Utils: Make Layouting a top level namespacehjk2023-04-253-3/+3
| | | | | | | | | | The whole machinery is now almost only layoutbuilder.{h,cpp}, mostly independent of the rest of Utils. Idea is to finish the separation to make it stand-alone usable also outside creator. Change-Id: I958aa667d17ae26b21209f22412309c5307a579c Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
* Git: Use IOptionPage::setWidgetCreator() for gerrit settingshjk2023-04-202-128/+78
| | | | | Change-Id: I7402f3342bb11726ec7383c807fa98052cb38bd8 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* RunExtensions: Move onResultReady and onFinished into asynctask.hJarek Kobus2023-04-172-2/+1
| | | | | | | Change-Id: I96dbf5b0253251224ae678172cd5fca12b34326a Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Git: Fix crash when menu is closed before fast-forward check resultOrgad Shaneh2023-03-301-4/+6
| | | | | | Fixes: QTCREATORBUG-28958 Change-Id: Ic3bfde2f355fdb3d44b0614e9ba176ff550d97c8 Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
* Git: Fix explanation in GerritPushDialogRobert Löhning2023-03-271-1/+1
| | | | | | | Change-Id: I527414dc3948a009099ec993c0f71d3501394ecd Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
* VcsBase: Use QtConcurrent invocation for async runJarek Kobus2023-03-092-9/+10
| | | | | | | Change-Id: Ia4e461c1a2e71d4c959f582e9ed464d4713b672a Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Merge remote-tracking branch 'origin/10.0'Eike Ziller2023-02-221-1/+2
|\ | | | | | | Change-Id: I8a53e2e8216fab7e45c3a1b8a3d2dc6656dfa7e2
| * Git: Fix soft asserts on failing instant blameAndre Hartmann2023-02-191-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | When git blame returns no output, silently avoid creating annotations instead flooding soft asserts. This situation can easily happen when navigating to a header file that is not under version control. Fixes: QTCREATORBUG-28768 Change-Id: I8d2f443dec98575221995a9016bd2f8442c682cf Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* | TaskTree: Add TreeStorage::operator*()Jarek Kobus2023-02-211-3/+3
| | | | | | | | | | | | | | | | Reuse it in some places. Change-Id: I335f38fa0384ea17bd8e981d743f835c3f05b731 Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: hjk <hjk@qt.io>
* | Merge remote-tracking branch 'origin/10.0'Eike Ziller2023-02-162-2/+2
|\ \ | |/ | | | | | | | | | | Conflicts: src/plugins/clangcodemodel/clangcodemodelplugin.cpp Change-Id: Idb3d6e8fdfd278979f6180dc3795a2138bc2e61d
| * Some fixes in translated stringsEike Ziller2023-02-152-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | - doesn't make sense to translate "%1" - showPreprocessedFile: "reason" contains full stop, put at the end - add missing closing > - remove whitespace at the end of translated string - added missing quotes and full stops - Remove some control text from tr Change-Id: I5537c3d12d038e25e2209af1198129fbf959b43c Reviewed-by: Alessandro Portale <alessandro.portale@qt.io> Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* | Git: Reduce sync processesOrgad Shaneh2023-02-146-75/+151
|/ | | | | | Change-Id: I5d83636d4a018464ba6f248aa818fb8f840df9fc Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* Git: Filter out tags on command executionOrgad Shaneh2023-02-141-2/+6
| | | | | | | | | | For a repo with ~50K tags, this reduces the time of for-each-ref from ~1s to ~270ms. Change-Id: I00f735bba62307cc9419619ebe5aa71a800368ea Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: André Hartmann <aha_1980@gmx.de>
* Git: Call updateUpstreamStatus for all branches in a single placeOrgad Shaneh2023-02-141-1/+14
| | | | | | | | | * Calling it for each parsed line mixes unrelated logic. * I consider adding a cache later, but that will require data for all the remotes before this call. Change-Id: Ic3ee975fc6172f2a8848bc8d0a6620d4ccbf9cd2 Reviewed-by: André Hartmann <aha_1980@gmx.de>
* Git: Do *not* use ctrlc stub for rev-listOrgad Shaneh2023-02-131-1/+0
| | | | | | | | | | It's a very short command, so the time penalty for spawning another process doesn't worth the additional termination protection. Amends commit 371e674967af97cf28e2425a0b98b80a87159f09. Change-Id: I151f0bc1838cd9ddbdf822cbe5cf8923da6a9499 Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* Git: Reduce PATH searches for executableOrgad Shaneh2023-02-132-5/+14
| | | | | | | | | This reduces executions in BranchModel::updateUpstreamStatus (which is called for each local branch with a tracking branch) from 3s to ~700ms on Windows. Change-Id: I92651ba8f37987bef49a80b46963964ae8cacb3c Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* Translations: Change translation context prefix from "::" to "QtC::"Alessandro Portale2023-02-102-8/+8
| | | | | | | lupdate would be confused by translation contexts starting with :: Change-Id: Ie95e73436fd3cafc80a8e89f908efadc747e644c Reviewed-by: hjk <hjk@qt.io>
* Proliferate Tr::tr in various placesAlessandro Portale2023-02-101-14/+16
| | | | | | | | | | This changes several tr() calls which were either missed during Tr::tr- ization or were added later. Found with regular expression: (?<!(Tr::)|([\w]))tr\( Change-Id: I1c0c03589e941614a7a8449ecfebc7d2cad396c3 Reviewed-by: hjk <hjk@qt.io>
* Translations: Remove stray Q_DECLARE_TR_FUNCTIONS(...)Alessandro Portale2023-02-101-2/+0
| | | | | | | | And handle the consequences in qmakebuildconfiguration.cpp. Change-Id: Ic24d99927254e8d16decea49b880a2446bf322e6 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Translations: Remove header includes of *tr.h in .h filesAlessandro Portale2023-02-081-2/+3
| | | | | | | | | The wrong Tr::tr could be executed by code indirectly including a *tr.h file from another module. To Translate in a header file, use QCoreApplication::tr(). Change-Id: I30e67245991d2c2f0eeb01ab356555bdb9841af0 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Translations: Fix stray QApplication::translate() callsAlessandro Portale2023-02-081-4/+2
| | | | | | | | | For references to the module-own context, use Tr::tr(). For references to other modules, use the right context name (with "::" prefix). Change-Id: I6dce8f1ceccb23c44d93f1826402cd3be8e98e5a Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Git: Avoid passing strings to resolve text encodingsAndre Hartmann2023-01-304-30/+33
| | | | | | | | Therefore, merge the code of codecFor() and encoding() to avoid further mis-usage. Change-Id: I086e4ace6c791d16f43f14c423b6529ad199c456 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Git: Fix instant blame text encodingAndre Hartmann2023-01-301-1/+2
| | | | | | | | Fixes: QTCREATORBUG-28728 Change-Id: I875488badc84b664eaa1223b37657dcb417157de Reviewed-by: David Schulz <david.schulz@qt.io> Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* TaskTree: Merge DynamicSetup with OnGroupSetupJarek Kobus2023-01-231-1/+1
| | | | | | | | | Don't define 2 separate group setup items. Make OnGroupSetup be able to handle also dynamic setup - like it's done with CustomTask's setup handler. Change-Id: I43e135f268ea96419b44ef5a4325707a124b4921 Reviewed-by: hjk <hjk@qt.io>
* Git: Some more FilePath proliferationhjk2023-01-233-40/+35
| | | | | Change-Id: I8d3d97d0c7979d741a7da333f922ce93359afef8 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* TaskTree: Remove GroupConfig / GroupActionJarek Kobus2023-01-201-2/+2
| | | | | | | | | | | Use TaskAction for dynamic group setup. Get rid of possibility of selecting group's children to be started inside group setup. Use dynamic children's setup instead, so that each individual child may decide itself whether it wants to be started or not. Change-Id: Ie31f707791db0dc26be92663ca6238b8e49c3b98 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* VcsBase: Proliferate use of FilePathhjk2023-01-209-58/+56
| | | | | | | ... and update user code. Change-Id: I52c08e9e07238536d31fc72f97312ac582a1e32f Reviewed-by: Orgad Shaneh <orgads@gmail.com>