From e9320a812252b05a6367462fea698d35f9585eae Mon Sep 17 00:00:00 2001 From: Eike Ziller Date: Wed, 18 Jan 2023 11:03:36 +0100 Subject: [PATCH 1/7] Fix tab order in "file deleted" dialog on Windows/Linux For some reason it doesn't like it if the order of adding the buttons is different, though that works on macOS. Fixes: QTCREATORBUG-28676 Change-Id: Iea7c595216140dd242cac0aa528699866c4bb1c7 Reviewed-by: Reviewed-by: David Schulz --- src/libs/utils/reloadpromptutils.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/libs/utils/reloadpromptutils.cpp b/src/libs/utils/reloadpromptutils.cpp index 4489908724e..4a890a04513 100644 --- a/src/libs/utils/reloadpromptutils.cpp +++ b/src/libs/utils/reloadpromptutils.cpp @@ -100,15 +100,15 @@ QTCREATOR_UTILS_EXPORT FileDeletedPromptAnswer "Do you want to save it under a different name, or close " "the editor?").arg(QDir::toNativeSeparators(fileName)); QMessageBox box(QMessageBox::Question, title, msg, QMessageBox::NoButton, parent); + QPushButton *saveas = + box.addButton(QCoreApplication::translate("Utils::fileDeletedPrompt", "Save &as..."), + QMessageBox::ActionRole); QPushButton *close = box.addButton(QCoreApplication::translate("Utils::fileDeletedPrompt", "&Close"), QMessageBox::RejectRole); QPushButton *closeAll = box.addButton(QCoreApplication::translate("Utils::fileDeletedPrompt", "C&lose All"), QMessageBox::RejectRole); - QPushButton *saveas = - box.addButton(QCoreApplication::translate("Utils::fileDeletedPrompt", "Save &as..."), - QMessageBox::ActionRole); QPushButton *save = box.addButton(QCoreApplication::translate("Utils::fileDeletedPrompt", "&Save"), QMessageBox::AcceptRole); From 2d491591e2e7b757ffa5cfcb597eb34960885042 Mon Sep 17 00:00:00 2001 From: Marcus Tillmanns Date: Thu, 12 Jan 2023 13:08:23 +0100 Subject: [PATCH 2/7] Utils: Add FilePath.hasFileAccess() FilePath::hasFileAccess allows a user to test if a specific device can access files. This is faster than calling "exists()" as it does not have to actually check anything on the device. cherry picked from commit 21ef25a0f5aa957857528861a960aeb1f2bb9180 Task-number: QTCREATORBUG-28531 Change-Id: I363ca634d921464fe4ec68397c09fba49dccee25 Reviewed-by: Eike Ziller Reviewed-by: --- src/libs/utils/filepath.cpp | 6 ++++++ src/libs/utils/filepath.h | 1 + src/libs/utils/fsengine/fsengine.cpp | 3 ++- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/libs/utils/filepath.cpp b/src/libs/utils/filepath.cpp index a5b3381acc6..f2b3f2a19a9 100644 --- a/src/libs/utils/filepath.cpp +++ b/src/libs/utils/filepath.cpp @@ -826,6 +826,12 @@ DeviceFileAccess *FilePath::fileAccess() const return access; } +bool FilePath::hasFileAccess() const +{ + DeviceFileAccess *access = s_deviceHooks.fileAccess(*this); + return access; +} + /// Constructs a FilePath from \a filePath. The \a defaultExtension is appended /// to \a filename if that does not have an extension already. /// \a filePath is not checked for validity. diff --git a/src/libs/utils/filepath.h b/src/libs/utils/filepath.h index d0fb810e465..eb043effe30 100644 --- a/src/libs/utils/filepath.h +++ b/src/libs/utils/filepath.h @@ -207,6 +207,7 @@ public: // There are usually other means available. E.g. distinguishing based // on FilePath::osType(). bool needsDevice() const; + bool hasFileAccess() const; bool isSameDevice(const FilePath &other) const; bool isSameFile(const FilePath &other) const; diff --git a/src/libs/utils/fsengine/fsengine.cpp b/src/libs/utils/fsengine/fsengine.cpp index 6a9665f6d05..e7150493111 100644 --- a/src/libs/utils/fsengine/fsengine.cpp +++ b/src/libs/utils/fsengine/fsengine.cpp @@ -36,7 +36,8 @@ FilePaths FSEngine::registeredDeviceRoots() void FSEngine::addDevice(const FilePath &deviceRoot) { - deviceRoots().append(deviceRoot); + if (deviceRoot.hasFileAccess()) + deviceRoots().append(deviceRoot); } void FSEngine::removeDevice(const FilePath &deviceRoot) From 0c9d5903eff1f9c1dd20e076602e2826ec10031b Mon Sep 17 00:00:00 2001 From: Marcus Tillmanns Date: Fri, 20 Jan 2023 14:54:13 +0100 Subject: [PATCH 3/7] Utils: Fix crash in fsengine test Change-Id: I6a28dfc907d34f1a6e20bc92f5cc506b308f1c0b Reviewed-by: Eike Ziller Reviewed-by: Qt CI Bot --- src/libs/utils/filepath.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/libs/utils/filepath.cpp b/src/libs/utils/filepath.cpp index f2b3f2a19a9..4bdf44f0361 100644 --- a/src/libs/utils/filepath.cpp +++ b/src/libs/utils/filepath.cpp @@ -828,6 +828,10 @@ DeviceFileAccess *FilePath::fileAccess() const bool FilePath::hasFileAccess() const { + // Happens during startup and in tst_fsengine + if (!s_deviceHooks.fileAccess) + return false; + DeviceFileAccess *access = s_deviceHooks.fileAccess(*this); return access; } From f15cae2bacba3616936a12b0e8f7bea0e660fce0 Mon Sep 17 00:00:00 2001 From: David Schulz Date: Mon, 23 Jan 2023 08:21:24 +0100 Subject: [PATCH 4/7] TextEditor: fix endless loop on adding cursor for selection Since the find of QTextDocument is line based, it is not possible to find selections spanning multiple lines in the editor. Triggering a find on a search term containing a paragraph separator returnes an invalid QTextCursor which always result in searching from the beginning of the document in the add cursor for selection logic. Prevent that by checking the selected text beforehand and add a safety net in the loop to verify that we do not start over again on an invalid TextCursor. Fixes: QTCREATORBUG-28709 Change-Id: I8c1b9d16e707fefbba6dc0a0a9ef21b8c82ebe19 Reviewed-by: Marcus Tillmanns --- src/plugins/texteditor/texteditor.cpp | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/plugins/texteditor/texteditor.cpp b/src/plugins/texteditor/texteditor.cpp index d6bce9d5a0b..3b8f5505d64 100644 --- a/src/plugins/texteditor/texteditor.cpp +++ b/src/plugins/texteditor/texteditor.cpp @@ -7055,12 +7055,13 @@ void TextEditorWidgetPrivate::addSelectionNextFindMatch() return; const QTextCursor &firstCursor = cursors.first(); - QTextDocumentFragment selection = firstCursor.selection(); + const QString selection = firstCursor.selectedText(); + if (selection.contains(QChar::ParagraphSeparator)) + return; QTextDocument *document = firstCursor.document(); - if (Utils::anyOf(cursors, [&firstCursor](const QTextCursor &c) { - return c.selection().toPlainText().toCaseFolded() - != firstCursor.selection().toPlainText().toCaseFolded(); + if (Utils::anyOf(cursors, [selection = selection.toCaseFolded()](const QTextCursor &c) { + return c.selectedText().toCaseFolded() != selection; })) { return; } @@ -7069,8 +7070,9 @@ void TextEditorWidgetPrivate::addSelectionNextFindMatch() int searchFrom = cursors.last().selectionEnd(); while (true) { - QTextCursor next = document->find(selection.toPlainText(), searchFrom, findFlags); + QTextCursor next = document->find(selection, searchFrom, findFlags); if (next.isNull()) { + QTC_ASSERT(searchFrom != 0, return); searchFrom = 0; continue; } From 270c0ffa3a42c8cb0e5fa93ccb3eaadf607e5047 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20L=C3=B6hning?= Date: Thu, 19 Jan 2023 12:08:38 +0100 Subject: [PATCH 5/7] Squish: Use consistent permissions Change-Id: Id2849d4aaa2da181df0e674a971abd89c3083662 Reviewed-by: Christian Stenger --- tests/system/suite_CCOM/suite.conf | 0 tests/system/suite_HELP/envvars | 0 tests/system/suite_HELP/suite.conf | 0 3 files changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 tests/system/suite_CCOM/suite.conf mode change 100755 => 100644 tests/system/suite_HELP/envvars mode change 100755 => 100644 tests/system/suite_HELP/suite.conf diff --git a/tests/system/suite_CCOM/suite.conf b/tests/system/suite_CCOM/suite.conf old mode 100755 new mode 100644 diff --git a/tests/system/suite_HELP/envvars b/tests/system/suite_HELP/envvars old mode 100755 new mode 100644 diff --git a/tests/system/suite_HELP/suite.conf b/tests/system/suite_HELP/suite.conf old mode 100755 new mode 100644 From 2746b410d067c15d86489eb2fb65cf7edaebdc1e Mon Sep 17 00:00:00 2001 From: Eike Ziller Date: Fri, 13 Jan 2023 15:40:22 +0100 Subject: [PATCH 6/7] German translation: Git MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I9ed345f452c72ac588a4df0d71ff2d92f117c8eb Reviewed-by: Reviewed-by: Robert Löhning --- share/qtcreator/translations/qtcreator_de.ts | 120 ++++++++++--------- 1 file changed, 61 insertions(+), 59 deletions(-) diff --git a/share/qtcreator/translations/qtcreator_de.ts b/share/qtcreator/translations/qtcreator_de.ts index efdfa0d648d..9fffad0d0d9 100644 --- a/share/qtcreator/translations/qtcreator_de.ts +++ b/share/qtcreator/translations/qtcreator_de.ts @@ -7294,11 +7294,11 @@ Möchten Sie den Branch "%1" im entfernten Repository erzeugen und ihn Stash && &Pop - + Stash && &Pop &Discard - + &Verwerfen Discard (reset) local changes and execute %1. @@ -7330,15 +7330,15 @@ Möchten Sie den Branch "%1" im entfernten Repository erzeugen und ihn Di&ff Against %1 - Mit %1 &vergleichen + Di&ff gegen %1 Di&ff %1 - + Di&ff für %1 Diff &Against Saved %1 - Mit gespeichertem %1 &vergleichen + Di&ff gegen gespeicherten %1 &Save for Diff @@ -7456,23 +7456,23 @@ Jetzt Commit ausführen? <None> - <Kein> + <Kein> <resolving> - + <bestimme> Filter commits by message or content. - + Commits nach Nachricht oder Inhalt filtern. Show Date - + Datum anzeigen Show date instead of sequence. - + Datum statt Abfolge anzeigen. Reset @@ -7489,9 +7489,11 @@ Jetzt Commit ausführen? Cannot commit %n files - - - + + Commit schlug für eine Datei fehl + + Commit schlug für %n Dateien fehl + @@ -7540,31 +7542,31 @@ Jetzt Commit ausführen? Cherr&y-Pick %1 - + Cherr&y-Pick %1 Re&vert %1 - + %1 rückgängig machen (Re&vert) C&heckout %1 - + %1 ausc&hecken &Interactive Rebase from %1... - + &Interaktives Rebase von %1... &Log for %1 - + &Log für %1 Sh&ow file "%1" on revision %2 - + Datei "%1" in Revisi&on %2 anzeigen Add &Tag for %1... - + &Tag für %1 hinzufügen... <No repository> @@ -7600,7 +7602,7 @@ Jetzt Commit ausführen? <a href="head">Show HEAD</a> - + <a href="head">HEAD anzeigen</a> Commit Information @@ -8437,27 +8439,27 @@ Nicht markiert - Die Änderung ist kein Entwurf. Filter by message - + Nach Nachricht filtern Filter log entries by text in the commit message. - + Log-Einträge nach Nachrichtentext filtern. Filter by content - + Nach Inhalt filtern Filter log entries by added or removed string. - + Log-Einträge nach hinzugefügtem oder entferntem Text filtern. Filter by author - + Nach Autor filtern Filter log entries by author. - + Log-Einträge nach Autor filtern. &Blame %1 @@ -8564,7 +8566,7 @@ Leer lassen, um das Dateisystem zu durchsuchen. Remove &Stale Branches - + &Veraltete Branches entfernen (Prune) Manage &Remotes... @@ -8592,7 +8594,7 @@ Leer lassen, um das Dateisystem zu durchsuchen. Reflo&g - + Reflo&g Re&set @@ -8600,19 +8602,19 @@ Leer lassen, um das Dateisystem zu durchsuchen. &Merge "%1" into "%2" (Fast-Forward) - + &Merge "%1" in "%2" (Fast-Forward) Merge "%1" into "%2" (No &Fast-Forward) - + Merge "%1" in "%2" (Kein &Fast-Forward) &Merge "%1" into "%2" - + &Merge "%1" in "%2" &Rebase "%1" on "%2" - + &Rebase "%1" auf "%2" &Track @@ -8644,7 +8646,7 @@ Leer lassen, um das Dateisystem zu durchsuchen. Reset branch "%1" to "%2"? - + Branch "%1" auf "%2" zurücksetzen? Git Branches @@ -8672,11 +8674,11 @@ Leer lassen, um das Dateisystem zu durchsuchen. &Copy "%1" - "%1" &Kopieren + "%1" &kopieren &Describe Change %1 - Änderung %1 &beschreiben + %1 beschreiben (&Describe) Git Settings @@ -8684,7 +8686,7 @@ Leer lassen, um das Dateisystem zu durchsuchen. Triggers a Git version control operation. - + Führt eine Aktion des Git-Versionskontrollsystems aus. &Git @@ -8881,107 +8883,107 @@ Leer lassen, um das Dateisystem zu durchsuchen. Diff Current File Avoid translating "Diff" - + Diff für aktuelle Datei Diff of "%1" Avoid translating "Diff" - Diff für "%1" + Diff für "%1" Log Current File Avoid translating "Log" - + Log für aktuelle Datei Log of "%1" Avoid translating "Log" - Log für "%1" + Log für "%1" Blame Current File Avoid translating "Blame" - Blame für Datei + Blame für aktuelle Datei Blame for "%1" Avoid translating "Blame" - Blame für "%1" + Blame für "%1" Diff Current Project Avoid translating "Diff" - Diff für Projekt + Diff für aktuelles Projekt Diff Project "%1" Avoid translating "Diff" - Diff für Projekt "%1" + Diff für Projekt "%1" Log Project Avoid translating "Log" - Log für Projekt + Log für Projekt Log Project "%1" Avoid translating "Log" - Log für Projekt "%1" + Log für Projekt "%1" Clean Project... Avoid translating "Clean" - Projekt bereinigen... + Projekt bereinigen... Clean Project "%1"... Avoid translating "Clean" - Projekt "%1" bereinigen... + Projekt "%1" bereinigen... Amend Last Commit... Avoid translating "Commit" - Letzten Commit ändern... + Letzten Commit ändern (Amend)... Fixup Previous Commit... Avoid translating "Commit" - Vorangehenden Commit verbessern... + Vorangehenden Commit verbessern (Fixup)... Interactive Rebase... Avoid translating "Rebase" - Interaktives Rebase... + Interaktives Rebase... Abort Merge Avoid translating "Merge" - Merge abbrechen + Merge abbrechen Abort Rebase Avoid translating "Rebase" - Rebase abbrechen + Rebase abbrechen Abort Cherry Pick Avoid translating "Cherry Pick" - Cherry-Pick abbrechen + Cherry-Pick abbrechen Abort Revert Avoid translating "Revert" - Revert abbrechen + Revert abbrechen Stash Unstaged Files Avoid translating "Stash" - Stash nicht bereitgestellter Dateien (unstaged) + Stash nicht bereitgestellter Dateien (unstaged) Stash Pop Avoid translating "Stash" - Stash Pop + Stash Pop Git &Tools @@ -17786,7 +17788,7 @@ Aktivieren Sie dies, wenn Sie 32bit-x86-Binärdateien erstellen wollen, ohne ein &Describe Change %1 - Änderung %1 &beschreiben + %1 beschreiben (&Describe) Send to CodePaster... From 455f9f691197fce65db4d472865f8f09fa6ef3c6 Mon Sep 17 00:00:00 2001 From: Christian Kandeler Date: Tue, 24 Jan 2023 16:47:12 +0100 Subject: [PATCH 7/7] Update qbs submodule to HEAD of 1.24 branch Change-Id: I38933e0ca016d31a0702b368c9b7ccd72741d3f1 Reviewed-by: Qt CI Bot Reviewed-by: Reviewed-by: Eike Ziller --- src/shared/qbs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/qbs b/src/shared/qbs index ee7524998d6..106316f632e 160000 --- a/src/shared/qbs +++ b/src/shared/qbs @@ -1 +1 @@ -Subproject commit ee7524998d6110d9b0cbe5fdf5fa960c8f0f33fc +Subproject commit 106316f632e9aa5673932ea78cbc6ed5b5fe19d0