mirror of
https://github.com/hyprwm/aquamarine.git
synced 2024-11-17 03:46:00 +01:00
headless: add a default mode for headless outputs (#87)
This commit is contained in:
parent
8b728612a9
commit
203fc0f4e4
1 changed files with 1 additions and 0 deletions
|
@ -131,6 +131,7 @@ std::vector<SDRMFormat> Aquamarine::CHeadlessBackend::getCursorFormats() {
|
||||||
bool Aquamarine::CHeadlessBackend::createOutput(const std::string& name) {
|
bool Aquamarine::CHeadlessBackend::createOutput(const std::string& name) {
|
||||||
auto output = SP<CHeadlessOutput>(new CHeadlessOutput(name.empty() ? std::format("HEADLESS-{}", ++outputIDCounter) : name, self.lock()));
|
auto output = SP<CHeadlessOutput>(new CHeadlessOutput(name.empty() ? std::format("HEADLESS-{}", ++outputIDCounter) : name, self.lock()));
|
||||||
outputs.emplace_back(output);
|
outputs.emplace_back(output);
|
||||||
|
output->modes.emplace_back(SP<SOutputMode>(new SOutputMode(Vector2D{1920, 1080}, 60, true)));
|
||||||
output->swapchain = CSwapchain::create(backend->primaryAllocator, self.lock());
|
output->swapchain = CSwapchain::create(backend->primaryAllocator, self.lock());
|
||||||
output->self = output;
|
output->self = output;
|
||||||
backend->events.newOutput.emit(SP<IOutput>(output));
|
backend->events.newOutput.emit(SP<IOutput>(output));
|
||||||
|
|
Loading…
Reference in a new issue