• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Return-To-The-Roots / s25client / 24635933460

19 Apr 2026 06:21PM UTC coverage: 50.203% (-0.2%) from 50.362%
24635933460

Pull #1890

github

web-flow
Merge 3877a723b into 7b5704a17
Pull Request #1890: Add support for borderless Windows

167 of 641 new or added lines in 44 files covered. (26.05%)

26 existing lines in 9 files now uncovered.

23078 of 45969 relevant lines covered (50.2%)

43616.87 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

40.0
/libs/driver/include/driver/VideoMode.h
1
// Copyright (C) 2005 - 2026 Settlers Freaks (sf-team at siedler25.org)
2
//
3
// SPDX-License-Identifier: GPL-2.0-or-later
4

5
#pragma once
6

7
/// Window size or resolution
8
struct VideoMode
9
{
10
    unsigned short width;
11
    unsigned short height;
12

13
    constexpr VideoMode() : width(0), height(0) {}
14✔
14
    constexpr VideoMode(unsigned short width, unsigned short height) : width(width), height(height) {}
28✔
15
    constexpr bool operator==(const VideoMode& o) const { return (width == o.width && height == o.height); }
7✔
NEW
16
    constexpr bool operator!=(const VideoMode& o) const { return !(*this == o); }
×
NEW
17
    constexpr bool operator<(const VideoMode& o) const
×
18
    {
NEW
19
        if(width != o.width)
×
NEW
20
            return width < o.width;
×
NEW
21
        return height < o.height;
×
22
    }
23
};
24

25
// Enum like type with extra flag
26
struct DisplayMode
27
{
28
    enum Type
29
    {
30
        Windowed,
31
        Fullscreen,
32
        BorderlessWindow,
33
    } type = Windowed;
34
    bool resizeable = true;
35

36
    constexpr DisplayMode() = default;
5✔
37
    constexpr DisplayMode(Type t) : type(t) {}
19✔
NEW
38
    constexpr explicit DisplayMode(unsigned t) : type(Type(t)) {}
×
39
    constexpr bool operator==(const Type& t) const { return type == t; }
17✔
NEW
40
    constexpr bool operator!=(const Type& t) const { return type != t; }
×
NEW
41
    constexpr bool operator==(const DisplayMode& o) const { return o.type == type && o.resizeable == resizeable; }
×
NEW
42
    constexpr bool operator!=(const DisplayMode& o) const { return !(o == *this); }
×
43
};
44

45
constexpr auto maxEnumValue(DisplayMode::Type)
46
{
47
    return DisplayMode::BorderlessWindow;
48
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc