HexEditor: Change name for unsaved files to 'Untitled'
This commit is contained in:
parent
b246221eac
commit
7a87e920f2
Notes:
sideshowbarker
2024-07-18 11:37:47 +09:00
Author: https://github.com/gunnarbeutner Commit: https://github.com/SerenityOS/serenity/commit/7a87e920f2d Pull-request: https://github.com/SerenityOS/serenity/pull/8216
1 changed files with 4 additions and 1 deletions
|
@ -322,7 +322,10 @@ void HexEditorWidget::set_path(const LexicalPath& lexical_path)
|
|||
void HexEditorWidget::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(" - Hex Editor");
|
||||
|
|
Loading…
Add table
Reference in a new issue