openMSX
|
#include <ImGuiMedia.hh>
Classes | |
struct | CartridgeMediaInfo |
struct | CassetteMediaInfo |
struct | DiskMediaInfo |
struct | ExtensionInfo |
struct | ItemGroup |
struct | MediaItem |
Public Types | |
enum class | SelectDiskType : int { IMAGE , DIR_AS_DISK , RAMDISK , EMPTY , NUM } |
enum class | SelectCartridgeType : int { IMAGE , EXTENSION , EMPTY , NUM } |
Public Member Functions | |
zstring_view | iniName () const override |
void | save (ImGuiTextBuffer &buf) override |
void | loadLine (std::string_view name, zstring_view value) override |
void | showMenu (MSXMotherBoard *motherBoard) override |
void | paint (MSXMotherBoard *motherBoard) override |
std::string | displayNameForExtension (std::string_view config) |
std::string | displayNameForRom (const std::string &filename, bool compact=false) |
std::string | displayNameForHardwareConfig (const HardwareConfig &config, bool compact=false) |
std::string | displayNameForSlotContent (const CartridgeSlotManager &slotManager, unsigned slotNr, bool compact=false) |
std::string | slotAndNameForHardwareConfig (const CartridgeSlotManager &slotManager, const HardwareConfig &config) |
std::string | displayNameForDriveContent (unsigned drive, bool compact=false) |
std::vector< ExtensionInfo > & | getAllExtensions () |
void | resetExtensionInfo () |
ExtensionInfo * | findExtensionInfo (std::string_view config) |
const std::string & | getTestResult (ExtensionInfo &info) |
void | addRecent (const TclObject &cmd) |
ImGuiPart (ImGuiManager &manager_) | |
ImGuiPart (const ImGuiPart &)=delete | |
ImGuiPart (ImGuiPart &&)=delete | |
Public Member Functions inherited from openmsx::ImGuiPart | |
ImGuiPart (ImGuiManager &manager_) | |
~ImGuiPart () | |
ImGuiPart (const ImGuiPart &)=delete | |
ImGuiPart (ImGuiPart &&)=delete | |
ImGuiPart & | operator= (const ImGuiPart &)=delete |
ImGuiPart & | operator= (ImGuiPart &&)=delete |
Public Member Functions inherited from openmsx::ImGuiPartInterface | |
virtual void | loadStart () |
virtual void | loadEnd () |
Static Public Member Functions | |
static void | printDatabase (const RomInfo &romInfo, const char *buf) |
static bool | selectMapperType (const char *label, RomType &item) |
static std::string | diskFilter () |
Public Attributes | |
bool | resetOnInsertRom = true |
Additional Inherited Members | |
Protected Attributes inherited from openmsx::ImGuiPart | |
ImGuiManager & | manager |
Definition at line 29 of file ImGuiMedia.hh.
|
strong |
Enumerator | |
---|---|
IMAGE | |
EXTENSION | |
EMPTY | |
NUM |
Definition at line 67 of file ImGuiMedia.hh.
|
strong |
Enumerator | |
---|---|
IMAGE | |
DIR_AS_DISK | |
RAMDISK | |
EMPTY | |
NUM |
Definition at line 63 of file ImGuiMedia.hh.
void openmsx::ImGuiMedia::addRecent | ( | const TclObject & | cmd | ) |
|
static |
Definition at line 216 of file ImGuiMedia.cc.
References openmsx::DiskImageCLI::getExtensions().
std::string openmsx::ImGuiMedia::displayNameForDriveContent | ( | unsigned | drive, |
bool | compact = false |
||
) |
Definition at line 373 of file ImGuiMedia.cc.
References openmsx::ImGuiManager::execute(), openmsx::FileOperations::getFilename(), openmsx::makeTclList(), openmsx::ImGuiPart::manager, and tmpStrCat().
std::string openmsx::ImGuiMedia::displayNameForExtension | ( | std::string_view | config | ) |
Definition at line 323 of file ImGuiMedia.cc.
References findExtensionInfo().
Referenced by displayNameForHardwareConfig(), and showMenu().
std::string openmsx::ImGuiMedia::displayNameForHardwareConfig | ( | const HardwareConfig & | config, |
bool | compact = false |
||
) |
Definition at line 346 of file ImGuiMedia.cc.
References displayNameForExtension(), displayNameForRom(), openmsx::HardwareConfig::EXTENSION, openmsx::HardwareConfig::getConfigName(), openmsx::HardwareConfig::getRomFilename(), and openmsx::HardwareConfig::getType().
Referenced by displayNameForSlotContent(), and slotAndNameForHardwareConfig().
std::string openmsx::ImGuiMedia::displayNameForRom | ( | const std::string & | filename, |
bool | compact = false |
||
) |
Definition at line 330 of file ImGuiMedia.cc.
References openmsx::FileOperations::getFilename(), openmsx::ImGuiManager::getReactor(), openmsx::Reactor::getSoftwareDatabase(), and openmsx::ImGuiPart::manager.
Referenced by displayNameForHardwareConfig().
std::string openmsx::ImGuiMedia::displayNameForSlotContent | ( | const CartridgeSlotManager & | slotManager, |
unsigned | slotNr, | ||
bool | compact = false |
||
) |
Definition at line 355 of file ImGuiMedia.cc.
References displayNameForHardwareConfig(), and openmsx::CartridgeSlotManager::getConfigForSlot().
Referenced by showMenu().
ImGuiMedia::ExtensionInfo * openmsx::ImGuiMedia::findExtensionInfo | ( | std::string_view | config | ) |
Definition at line 316 of file ImGuiMedia.cc.
References openmsx::ImGuiMedia::ExtensionInfo::configName, ranges::find(), and getAllExtensions().
Referenced by displayNameForExtension(), and showMenu().
std::vector< ImGuiMedia::ExtensionInfo > & openmsx::ImGuiMedia::getAllExtensions | ( | ) |
Definition at line 254 of file ImGuiMedia.cc.
References openmsx::ImGuiPart::manager.
Referenced by findExtensionInfo(), and showMenu().
const std::string & openmsx::ImGuiMedia::getTestResult | ( | ExtensionInfo & | info | ) |
Definition at line 267 of file ImGuiMedia.cc.
References openmsx::ImGuiMedia::ExtensionInfo::configName, openmsx::ImGuiManager::executeDelayed(), openmsx::ImGuiManager::getReactor(), openmsx::ImGuiPart::manager, and openmsx::ImGuiMedia::ExtensionInfo::testResult.
|
delete |
|
inlineexplicit |
Definition at line 12 of file ImGuiPart.hh.
|
delete |
|
inlineoverridevirtual |
Reimplemented from openmsx::ImGuiPartInterface.
Definition at line 42 of file ImGuiMedia.hh.
|
overridevirtual |
Reimplemented from openmsx::ImGuiPartInterface.
Definition at line 110 of file ImGuiMedia.cc.
References DIR_AS_DISK, openmsx::ImGuiMedia::ItemGroup::edit, EXTENSION, openmsx::ImGuiMedia::CassetteMediaInfo::group, IMAGE, openmsx::ImGuiMedia::MediaItem::ipsPatches, openmsx::loadOnePersistent(), openmsx::ImGuiMedia::MediaItem::name, openmsx::RomInfo::nameToRomType(), NUM, openmsx::ImGuiMedia::ItemGroup::recent, openmsx::ImGuiMedia::MediaItem::romType, openmsx::ImGuiMedia::CassetteMediaInfo::show, StringOp::stringToBool(), to_underlying(), and openmsx::UNKNOWN.
|
overridevirtual |
Reimplemented from openmsx::ImGuiPartInterface.
Definition at line 698 of file ImGuiMedia.cc.
References openmsx::CassettePortInterface::getCassettePlayer(), openmsx::MSXMotherBoard::getCassettePort(), openmsx::MSXMotherBoard::getSlotManager(), and xrange().
|
static |
Definition at line 1035 of file ImGuiMedia.cc.
References openmsx::RomInfo::getCompany(), openmsx::RomInfo::getCountry(), openmsx::RomInfo::getOriginal(), openmsx::RomInfo::getOrigType(), openmsx::RomInfo::getRemark(), openmsx::RomInfo::getTitle(), openmsx::RomInfo::getYear(), strAppend(), and ImGui::TextUnformatted().
Referenced by openmsx::ImGuiManager::paintImGui().
void openmsx::ImGuiMedia::resetExtensionInfo | ( | ) |
Definition at line 262 of file ImGuiMedia.cc.
|
overridevirtual |
Reimplemented from openmsx::ImGuiPartInterface.
Definition at line 47 of file ImGuiMedia.cc.
References DIR_AS_DISK, openmsx::ImGuiMedia::ItemGroup::edit, EXTENSION, openmsx::ImGuiMedia::CassetteMediaInfo::group, IMAGE, openmsx::ImGuiMedia::MediaItem::ipsPatches, openmsx::ImGuiMedia::MediaItem::name, openmsx::ImGuiMedia::ItemGroup::recent, openmsx::ImGuiMedia::MediaItem::romType, openmsx::RomInfo::romTypeToName(), openmsx::savePersistent(), openmsx::ImGuiMedia::CassetteMediaInfo::show, tmpStrCat(), and openmsx::UNKNOWN.
|
static |
Definition at line 846 of file ImGuiMedia.cc.
References im::Combo(), and openmsx::simpleToolTip().
Referenced by openmsx::ImGuiManager::paintImGui().
|
overridevirtual |
Reimplemented from openmsx::ImGuiPartInterface.
Definition at line 443 of file ImGuiMedia.cc.
References openmsx::applyComboFilter(), openmsx::applyDisplayNameFilter(), im::Disabled(), displayNameForExtension(), displayNameForSlotContent(), openmsx::TclObject::empty(), findExtensionInfo(), getAllExtensions(), openmsx::MSXMotherBoard::getExtensions(), openmsx::ImGuiManager::getInterpreter(), openmsx::CartridgeSlotManager::getPsSs(), openmsx::MSXMotherBoard::getSlotManager(), openmsx::TclObject::getString(), openmsx::HelpMarker(), im::Indent(), im::ListBox(), im::ListClipper(), openmsx::ImGuiPart::manager, openmsx::CartridgeSlotManager::MAX_SLOTS, im::Menu(), openmsx::NONE, openmsx::simpleToolTip(), strCat(), ImGui::StrCat(), ImGui::TextUnformatted(), to_vector(), and xrange().
std::string openmsx::ImGuiMedia::slotAndNameForHardwareConfig | ( | const CartridgeSlotManager & | slotManager, |
const HardwareConfig & | config | ||
) |
Definition at line 363 of file ImGuiMedia.cc.
References displayNameForHardwareConfig(), openmsx::CartridgeSlotManager::findSlotWith(), openmsx::CartridgeSlotManager::getPsSsString(), strAppend(), and strCat().
bool openmsx::ImGuiMedia::resetOnInsertRom = true |
Definition at line 112 of file ImGuiMedia.hh.