2018-07-25 12:24:03 +00:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
namespace nall {
|
|
|
|
|
|
|
|
template<typename... P> auto vector<string>::append(const string& data, P&&... p) -> type& {
|
|
|
|
vector_base::append(data);
|
|
|
|
append(forward<P>(p)...);
|
|
|
|
return *this;
|
|
|
|
}
|
|
|
|
|
|
|
|
auto vector<string>::append() -> type& {
|
|
|
|
return *this;
|
|
|
|
}
|
|
|
|
|
|
|
|
auto vector<string>::isort() -> type& {
|
|
|
|
sort([](const string& x, const string& y) {
|
|
|
|
return memory::icompare(x.data(), x.size(), y.data(), y.size()) < 0;
|
|
|
|
});
|
|
|
|
return *this;
|
|
|
|
}
|
|
|
|
|
Update to v106r59 release.
byuu says:
Changelog:
- fixed bug in Emulator::Game::Memory::operator bool()
- nall: renamed view<string> back to `string_view`
- nall:: implemented `array_view`
- Game Boy: split cartridge-specific input mappings (rumble,
accelerometer) to their own separate ports
- Game Boy: fixed MBC7 accelerometer x-axis
- icarus: Game Boy, Super Famicom, Mega Drive cores output internal
header game titles to heuristics manifests
- higan, icarus, hiro/gtk: improve viewport geometry configuration;
fixed higan crashing bug with XShm driver
- higan: connect Video::poll(),update() functionality
- hiro, ruby: several compilation / bugfixes, should get the macOS
port compiling again, hopefully [Sintendo]
- ruby/video/xshm: fix crashing bug on window resize
- a bit hacky; it's throwing BadAccess Xlib warnings, but they're
not fatal, so I am catching and ignoring them
- bsnes: removed Application::Windows::onModalChange hook that's no
longer needed [Screwtape]
2018-08-26 06:49:54 +00:00
|
|
|
auto vector<string>::find(string_view source) const -> maybe<uint> {
|
2018-07-25 12:24:03 +00:00
|
|
|
for(uint n = 0; n < size(); n++) {
|
|
|
|
if(operator[](n).equals(source)) return n;
|
|
|
|
}
|
|
|
|
return {};
|
|
|
|
}
|
|
|
|
|
Update to v106r59 release.
byuu says:
Changelog:
- fixed bug in Emulator::Game::Memory::operator bool()
- nall: renamed view<string> back to `string_view`
- nall:: implemented `array_view`
- Game Boy: split cartridge-specific input mappings (rumble,
accelerometer) to their own separate ports
- Game Boy: fixed MBC7 accelerometer x-axis
- icarus: Game Boy, Super Famicom, Mega Drive cores output internal
header game titles to heuristics manifests
- higan, icarus, hiro/gtk: improve viewport geometry configuration;
fixed higan crashing bug with XShm driver
- higan: connect Video::poll(),update() functionality
- hiro, ruby: several compilation / bugfixes, should get the macOS
port compiling again, hopefully [Sintendo]
- ruby/video/xshm: fix crashing bug on window resize
- a bit hacky; it's throwing BadAccess Xlib warnings, but they're
not fatal, so I am catching and ignoring them
- bsnes: removed Application::Windows::onModalChange hook that's no
longer needed [Screwtape]
2018-08-26 06:49:54 +00:00
|
|
|
auto vector<string>::ifind(string_view source) const -> maybe<uint> {
|
2018-07-25 12:24:03 +00:00
|
|
|
for(uint n = 0; n < size(); n++) {
|
|
|
|
if(operator[](n).iequals(source)) return n;
|
|
|
|
}
|
|
|
|
return {};
|
|
|
|
}
|
|
|
|
|
Update to v106r59 release.
byuu says:
Changelog:
- fixed bug in Emulator::Game::Memory::operator bool()
- nall: renamed view<string> back to `string_view`
- nall:: implemented `array_view`
- Game Boy: split cartridge-specific input mappings (rumble,
accelerometer) to their own separate ports
- Game Boy: fixed MBC7 accelerometer x-axis
- icarus: Game Boy, Super Famicom, Mega Drive cores output internal
header game titles to heuristics manifests
- higan, icarus, hiro/gtk: improve viewport geometry configuration;
fixed higan crashing bug with XShm driver
- higan: connect Video::poll(),update() functionality
- hiro, ruby: several compilation / bugfixes, should get the macOS
port compiling again, hopefully [Sintendo]
- ruby/video/xshm: fix crashing bug on window resize
- a bit hacky; it's throwing BadAccess Xlib warnings, but they're
not fatal, so I am catching and ignoring them
- bsnes: removed Application::Windows::onModalChange hook that's no
longer needed [Screwtape]
2018-08-26 06:49:54 +00:00
|
|
|
auto vector<string>::match(string_view pattern) const -> vector<string> {
|
2018-07-25 12:24:03 +00:00
|
|
|
vector<string> result;
|
|
|
|
for(uint n = 0; n < size(); n++) {
|
|
|
|
if(operator[](n).match(pattern)) result.append(operator[](n));
|
|
|
|
}
|
|
|
|
return result;
|
|
|
|
}
|
|
|
|
|
Update to v106r59 release.
byuu says:
Changelog:
- fixed bug in Emulator::Game::Memory::operator bool()
- nall: renamed view<string> back to `string_view`
- nall:: implemented `array_view`
- Game Boy: split cartridge-specific input mappings (rumble,
accelerometer) to their own separate ports
- Game Boy: fixed MBC7 accelerometer x-axis
- icarus: Game Boy, Super Famicom, Mega Drive cores output internal
header game titles to heuristics manifests
- higan, icarus, hiro/gtk: improve viewport geometry configuration;
fixed higan crashing bug with XShm driver
- higan: connect Video::poll(),update() functionality
- hiro, ruby: several compilation / bugfixes, should get the macOS
port compiling again, hopefully [Sintendo]
- ruby/video/xshm: fix crashing bug on window resize
- a bit hacky; it's throwing BadAccess Xlib warnings, but they're
not fatal, so I am catching and ignoring them
- bsnes: removed Application::Windows::onModalChange hook that's no
longer needed [Screwtape]
2018-08-26 06:49:54 +00:00
|
|
|
auto vector<string>::merge(string_view separator) const -> string {
|
2018-07-25 12:24:03 +00:00
|
|
|
string output;
|
|
|
|
for(uint n = 0; n < size(); n++) {
|
|
|
|
output.append(operator[](n));
|
|
|
|
if(n < size() - 1) output.append(separator.data());
|
|
|
|
}
|
|
|
|
return output;
|
|
|
|
}
|
|
|
|
|
|
|
|
auto vector<string>::strip() -> type& {
|
|
|
|
for(uint n = 0; n < size(); n++) {
|
|
|
|
operator[](n).strip();
|
|
|
|
}
|
|
|
|
return *this;
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|