Added callback when new module is launched
This avoids having to guess the display window title format Also manually fixed the linting errors picked out by travis which do not get picked up using xb format locally
This commit is contained in:
@@ -35,11 +35,12 @@ class EmulatorWindow {
|
||||
ui::Loop* loop() const { return loop_.get(); }
|
||||
ui::Window* window() const { return window_.get(); }
|
||||
|
||||
void UpdateTitle();
|
||||
|
||||
private:
|
||||
explicit EmulatorWindow(Emulator* emulator);
|
||||
|
||||
bool Initialize();
|
||||
void UpdateTitle();
|
||||
|
||||
void CpuTimeScalarReset();
|
||||
void CpuTimeScalarSetHalf();
|
||||
|
||||
@@ -195,7 +195,8 @@ int xenia_main(const std::vector<std::wstring>& args) {
|
||||
// Normalize the path and make absolute.
|
||||
std::wstring abs_path = xe::to_absolute_path(path);
|
||||
|
||||
result = emulator->LaunchPath(abs_path);
|
||||
result = emulator->LaunchPath(abs_path,
|
||||
[&]() { emulator_window->UpdateTitle(); });
|
||||
if (XFAILED(result)) {
|
||||
XELOGE("Failed to launch target: %.8X", result);
|
||||
emulator.reset();
|
||||
|
||||
Reference in New Issue
Block a user