https://bugs.kde.org/show_bug.cgi?id=468595

Igor Kushnir <igor...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Version Fixed In|                            |5.13.231200
         Resolution|---                         |FIXED
             Status|ASSIGNED                    |RESOLVED
      Latest Commit|                            |https://invent.kde.org/kdev
                   |                            |elop/kdevelop/-/commit/b3f6
                   |                            |51be72550196659ce46b5414efb
                   |                            |0484f8e4c

--- Comment #6 from Igor Kushnir <igor...@gmail.com> ---
Git commit b3f651be72550196659ce46b5414efb0484f8e4c by Igor Kushnir.
Committed on 15/09/2023 at 13:41.
Pushed by igorkushnir into branch 'master'.

problemreporter: handle text document URL changes

A text document's URL can be changed when:
1) a new Untitled document is saved;
2) an open document is saved under a different name (File=>Save As...).

ProblemReporterPlugin does not listen to
IDocumentController::documentUrlChanged signal, and therefore keeps
referencing text documents by stale URLs. So when a document is renamed,
then another document is created or opened at its previous URL, the
assertion Q_ASSERT(!m_visualizers.contains(documentUrl)) in
ProblemReporterPlugin::textDocumentCreated() fails. Another consequence
is that inline problem notes never appear in the renamed document.

Replace the URL key of the renamed document's visualizer and remove the
obsolete URL from m_reHighlightNeeded set.

When the default problem scope "Current Document" is selected, an active
document is not highlighted right after it is renamed. The user has to
activate another document, then go back to the renamed one for the
highlighting to appear. This is a consequence of another missing
connection to the documentUrlChanged signal in ProblemModel. Will be
addressed in a subsequent commit.
FIXED-IN: 5.13.231200

M  +5    -0    plugins/problemreporter/problemhighlighter.h
M  +36   -0    plugins/problemreporter/problemreporterplugin.cpp
M  +1    -0    plugins/problemreporter/problemreporterplugin.h

https://invent.kde.org/kdevelop/kdevelop/-/commit/b3f651be72550196659ce46b5414efb0484f8e4c

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to