MCPcopy Create free account
hub / github.com/axmolengine/axmol / setFileName

Method setFileName

core/ui/UIMediaPlayer.cpp:1077–1086  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1075}
1076
1077void MediaPlayer::setFileName(std::string_view fileName)
1078{
1079 auto fullPath = FileUtils::getInstance()->fullPathForFilename(fileName);
1080 if (ax::utils::filePathToUrl(std::forward<std::string>(fullPath)) != _videoURL)
1081 {
1082 reinterpret_cast<PrivateVideoDescriptor*>(_videoContext)->closePlayer();
1083 _videoURL = std::move(fullPath);
1084 }
1085 _videoSource = MediaPlayer::Source::FILENAME;
1086}
1087
1088void MediaPlayer::setURL(std::string_view videoUrl)
1089{

Callers

nothing calls this directly

Calls 3

getInstanceFunction · 0.85
fullPathForFilenameMethod · 0.80
closePlayerMethod · 0.80

Tested by

no test coverage detected