refactor: make TrackableObject::weak_map_id() constexpr (#47092)

* refactor: make TrackableObject::weak_map_id() constexpr

refactor: make BaseWindow::GetID() inline and constexpr

* refactor: make NativeWindow::window_id() constexpr too
This commit is contained in:
Charles Kerr
2025-05-15 16:10:33 -05:00
committed by GitHub
parent e2bcd8f0aa
commit d720aea700
4 changed files with 3 additions and 7 deletions

View File

@@ -261,7 +261,7 @@ class BaseWindow : public gin_helper::TrackableObject<BaseWindow>,
void SetTitleBarOverlay(const gin_helper::Dictionary& options,
gin_helper::Arguments* args);
#endif
int32_t GetID() const;
[[nodiscard]] constexpr int32_t GetID() const { return weak_map_id(); }
private:
// Helpers.