[keel,nostalgia/core/studio] Fix asset update notifications

This commit is contained in:
2023-07-15 17:30:26 -05:00
parent 9ceb1df49e
commit 4cf96878a9
4 changed files with 24 additions and 6 deletions

View File

@@ -145,9 +145,7 @@ void PaletteEditorImGui::draw(turbine::Context*) noexcept {
ox::Error PaletteEditorImGui::saveItem() noexcept {
const auto sctx = applicationData<studio::StudioContext>(*m_ctx);
oxReturnError(sctx->project->writeObj(m_itemPath, &m_pal));
oxReturnError(m_ctx->keelCtx.assetManager.setAsset(m_itemPath, m_pal));
return {};
return sctx->project->writeObj(m_itemPath, &m_pal);
}
}

View File

@@ -773,8 +773,7 @@ void TileSheetEditorModel::ackUpdate() noexcept {
ox::Error TileSheetEditorModel::saveFile() noexcept {
const auto sctx = applicationData<studio::StudioContext>(*m_ctx);
oxReturnError(sctx->project->writeObj(m_path, &m_img));
return m_ctx->keelCtx.assetManager.setAsset(m_path, m_img).error;
return sctx->project->writeObj(m_path, &m_img);
}
bool TileSheetEditorModel::pixelSelected(std::size_t idx) const noexcept {