Deglobalize System: Vi

This commit is contained in:
David Marcec 2019-09-21 19:37:03 +10:00
parent 2c6e4ce0ad
commit 4d220964df
3 changed files with 8 additions and 8 deletions

View file

@ -31,11 +31,11 @@ constexpr s64 frame_ticks_30fps = static_cast<s64>(Core::Timing::BASE_CLOCK_RATE
NVFlinger::NVFlinger(Core::Timing::CoreTiming& core_timing, Core::System& system)
: core_timing{core_timing}, system(system) {
displays.emplace_back(0, "Default");
displays.emplace_back(1, "External");
displays.emplace_back(2, "Edid");
displays.emplace_back(3, "Internal");
displays.emplace_back(4, "Null");
displays.emplace_back(0, "Default", system);
displays.emplace_back(1, "External", system);
displays.emplace_back(2, "Edid", system);
displays.emplace_back(3, "Internal", system);
displays.emplace_back(4, "Null", system);
// Schedule the screen composition events
composition_event = core_timing.RegisterEvent("ScreenComposition", [this](u64 userdata,

View file

@ -15,8 +15,8 @@
namespace Service::VI {
Display::Display(u64 id, std::string name) : id{id}, name{std::move(name)} {
auto& kernel = Core::System::GetInstance().Kernel();
Display::Display(u64 id, std::string name, Core::System& system) : id{id}, name{std::move(name)} {
auto& kernel = system.Kernel();
vsync_event = Kernel::WritableEvent::CreateEventPair(kernel, Kernel::ResetType::Manual,
fmt::format("Display VSync Event {}", id));
}

View file

@ -26,7 +26,7 @@ public:
/// @param id The unique ID for this display.
/// @param name The name for this display.
///
Display(u64 id, std::string name);
Display(u64 id, std::string name, Core::System& system);
~Display();
Display(const Display&) = delete;