Added functionality to update the main window's title with the name of
the currently opened file in the text editor. This change improves user
experience by providing a clear indication of the file being viewed or
edited.
Introduced a fileNameChanged signal in TextEdit to notify changes in the
active file. Connected the signal to a new slot in MainWindow to update
the window title dynamically.
Adjusted FindFileDialog and TextEdit::setContents to emit the signal
when a new file is opened. This enhancement addresses user feedback
regarding better context visibility in the application.
Task-number: QTBUG-118728
Change-Id: Ib951592388943fcbc40efd7d41a6fc0452fc9b40
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 4a8adf743789dbc5b8e07b763898ddeeb631383f)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>