~sircmpwn/xrgears

eb006e208be2f9d3359818e77c384e6e36f3c115 — Lubosz Sarnecki 5 years ago 40284ad
vikWindowWayland: Use initialize display and mode when not set.
1 files changed, 7 insertions(+), 0 deletions(-)

M vitamin-k/window/vikWindowWayland.hpp
M vitamin-k/window/vikWindowWayland.hpp => vitamin-k/window/vikWindowWayland.hpp +7 -0
@@ 359,6 359,10 @@ class WindowWayland : public Window {

  void validate_display() {
    Display *d;

    if (settings->display < 0)
      settings->display = 0;

    if (settings->display > (int) displays.size()) {
      vik_log_e("Requested display %d, but only %d displays are available.",
                settings->display, displays.size());


@@ 374,6 378,9 @@ class WindowWayland : public Window {
  void validate_mode() {
    Display* d = current_display();

    if (settings->mode < 0)
      settings->mode = 0;

    if (settings->mode > (int) d->modes.size()) {
      vik_log_e("Requested mode %d, but only %d modes"
                " are available on display %d.",