Commit Graph

6 Commits (master)

Author SHA1 Message Date
Vlad Zahorodnii 4ce853e8e4 Prettify license headers 2020-08-07 19:57:56 +00:00
Vlad Zahorodnii 1fb9f6f13a Switch to SPDX license markers
The main advantage of SPDX license identifiers over the traditional
license headers is that it's more difficult to overlook inappropriate
licenses for kwin, for example GPL 3. We also don't have to copy a
lot of boilerplate text.

In order to create this change, I ran licensedigger -r -c from the
toplevel source directory.
2020-08-07 19:57:56 +00:00
Boudewijn Rempt 6ddf294b55 Warnings--: unused parameters 2015-06-12 17:17:21 +02:00
Thomas Lübking 3597959c0e add Screens::name(int screen); STUB but for XRandr
required to compare __GL_SYNC_DISPLAY_DEVICE and
later on to assign windows to an output rather than
a screen number
2015-05-15 23:55:27 +02:00
Thomas Lübking c7f13c7266 add refreshRate to Screens. STUB but for XRandr!
the randr refreshrate is calculated from the current mode
2015-05-15 23:55:27 +02:00
Martin Gräßlin 4eadc9daef [auto-tests] Add an initial test for Screens
This is a very interesting auto test as Screens uses both Workspace
and Client. Thus it operates in the "impossible to mock" area.

The solution is to provide mock includes in autotests and ensure that
when building the auto-test the mock header includes will be picked
first. There is now a mock class for Workspace and Client providing
just the API pieces used inside Screens.

As Screens is abstract and we cannot properly interact with
QDesktopWidget there is also a MockScreens class inheriting from Screens
and mocking the required functionality (by just operating on a list of
QRects).

The auto-test itself is only performing checks on the abstract class.
The mock class is indirectly tested by Screens calling into the virtual
methods. The test case is not yet complete, but looking quite good
already.
2014-09-17 10:29:03 +02:00