1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 04:37:34 +00:00

ThemeEditor: Update theme path on theme load

Prior to this change, the 'Save' action was saving a file to the startup
path (or just showed a File Picker dialog) if a file has been opened
by the Open action or by drag-n-dropping a file to the program.
This commit is contained in:
Karol Kosek 2021-09-11 21:53:00 +02:00 committed by Andreas Kling
parent be7ae76829
commit 4e1a794abe
3 changed files with 8 additions and 0 deletions

View file

@ -105,6 +105,8 @@ void PreviewWidget::set_theme_from_file(String const& path, int fd)
m_preview_palette = Gfx::Palette(Gfx::PaletteImpl::create_with_anonymous_buffer(theme));
set_preview_palette(m_preview_palette);
if (on_theme_load_from_file)
on_theme_load_from_file(path);
}
void PreviewWidget::paint_event(GUI::PaintEvent& event)