Jazz2::UI::Menu::LevelPackDetailSection class

Menu section of one installed level pack.

Shows the preview and the details of a pack and lists its episodes and levels, any of them can be started. The pack can be removed from here too.

Base classes

class MenuSection
Base class of a menu section.

Constructors, destructors, conversion operators

LevelPackDetailSection(std::shared_ptr<const LevelPacks::LevelPackManifest> pack, EpisodeSelectMode mode, bool privateServer)
Creates a new instance.

Public functions

auto GetClipRectangle(const Recti& contentBounds) -> Recti override
Allows to override clip rectangle of the middle layer.
void OnShow(IMenuContainer* root) override
Called when the section is shown.
void OnUpdate(float timeMult) override
Called when the section should be updated.
void OnDraw(Canvas* canvas) override
Called when the section should be drawn — the bottom background layer.
void OnDrawClipped(Canvas* canvas) override
Called when the section should be drawn — the middle clipped layer.
void OnTouchEvent(const TouchEvent& event, Vector2i viewSize) override
Called when a touch event is triggered.

Function documentation

Jazz2::UI::Menu::LevelPackDetailSection::LevelPackDetailSection(std::shared_ptr<const LevelPacks::LevelPackManifest> pack, EpisodeSelectMode mode, bool privateServer)

Creates a new instance.

Parameters
pack The pack
mode How a level of the pack is started
privateServer Whether a hosted online server should be private