mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-02-25 09:04:53 +00:00
TextEditor: Show "Untitled" when there's no current document path
This commit is contained in:
@@ -540,7 +540,10 @@ void TextEditorWidget::set_path(const LexicalPath& lexical_path)
|
||||
void TextEditorWidget::update_title()
|
||||
{
|
||||
StringBuilder builder;
|
||||
builder.append(m_path);
|
||||
if (m_path.is_empty())
|
||||
builder.append("Untitled");
|
||||
else
|
||||
builder.append(m_path);
|
||||
if (m_document_dirty)
|
||||
builder.append(" (*)");
|
||||
builder.append(" - Text Editor");
|
||||
|
||||
Reference in New Issue
Block a user