From e628ce67a063ba55b62ddf686b6a006015151370 Mon Sep 17 00:00:00 2001 From: Gary Talent Date: Fri, 30 May 2025 23:14:45 -0500 Subject: [PATCH] [keel] Add isUuidUrl function --- .../gfx/src/studio/tilesheeteditor/tilesheeteditormodel.cpp | 1 + src/olympic/keel/include/keel/media.hpp | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/src/nostalgia/modules/gfx/src/studio/tilesheeteditor/tilesheeteditormodel.cpp b/src/nostalgia/modules/gfx/src/studio/tilesheeteditor/tilesheeteditormodel.cpp index 5f4f99ad..62314665 100644 --- a/src/nostalgia/modules/gfx/src/studio/tilesheeteditor/tilesheeteditormodel.cpp +++ b/src/nostalgia/modules/gfx/src/studio/tilesheeteditor/tilesheeteditormodel.cpp @@ -231,6 +231,7 @@ void TileSheetEditorModel::setActiveSubsheet(TileSheet::SubSheetIdx const&idx) n m_activeSubsSheetIdx = idx; this->activeSubsheetChanged.emit(m_activeSubsSheetIdx); clearSelection(); + m_lastDrawUpdatePt = {-1, -1}; } void TileSheetEditorModel::fill(ox::Point const&pt, int const palIdx) noexcept { diff --git a/src/olympic/keel/include/keel/media.hpp b/src/olympic/keel/include/keel/media.hpp index cc725388..4f6fd200 100644 --- a/src/olympic/keel/include/keel/media.hpp +++ b/src/olympic/keel/include/keel/media.hpp @@ -60,6 +60,11 @@ ox::Result uuidToPath(Context &ctx, ox::StringViewCR uuid) noex ox::Result uuidToPath(Context &ctx, ox::UUID const&uuid) noexcept; +[[nodiscard]] +constexpr bool isUuidUrl(ox::StringViewCR path) noexcept { + return ox::beginsWith(path, "uuid://"); +} + #ifndef OX_BARE_METAL namespace detail {