If the window filter rejects a window, that window won't be in the
stacking_order and henceforth won't be painted, so finalDrawWindow()
does extra work of checking again if the window is accepted.
Effects may perform cleanup when a deleted window is removed. If that
happens and the SceneWindow is accessed, kwin may crash.
The Scene processes Workspace::deletedRemoved() before effects.
In order to fix dereferencing null pointer, this change makes the Window
destroy its associated SceneWindow.
Format modifiers enable the graphics hardware to be much more efficient,
especially when it comes to multi-gpu transfers. With the issues regarding
bandwidth limits now solved, enable them by default to make all supported
systems benefit from them.
CCBUG: 452397
CCBUG: 452219
When explicit modifiers are used, it can happen that Mesa chooses modifiers that make
the display hardware hit bandwidth limits. In that case, atomic tests fail and the
outputs don't work, or KWin may even crash.
In order to work around that, DrmGpu now removes the used modifier whenever an atomic
test fails, and tries to find a working combination of outputs and modifiers.
If a window is destroyed before the frame is presented, the window
pointer will be dangling.
In order to make kwin handle that case correctly, the window is captured
using a QPointer.
While having all state be public is great for avoiding the boilerplate that
comes with setters and getters, it also exposes more state than necessary
to the rest of the backend and makes it more error-prone if more than one
part of the state needs to be changed at the same time.
WindowThumbnailItem doesn't depend on features that are available only
with managed window.
By making WindowThumbnailItem work with all kinds of windows, its code
is easier to work with and refactor.
Instead of passing all possible field values to the initialize()
function, pass all relevant data in a struct. With designated
initializers, it's more readable and makes code more comprehensible.
The general goal is to split Output's data in two categories - general
information about the output (e.g. edid) and mutable state (position,
mode, etc).
With this, the drm backend will be able to associate drmModeModeInfo
with Output's modes, which can be useful if there are several modes with
the same resolution and refresh rate but different flags.
This makes KWin switch to in-tree copy of KWaylandServer codebase.
KWaylandServer namespace has been left as is. It will be addressed later
by renaming classes in order to fit in the KWin namespace.
Instead of creating a gammaramp object with a fixed size, make the color
device create a color transformation object that can be used to construct
arbitrary LUTs. This is needed in order to support tiled displays well
and is useful for further color management work.
When we do more color management stuff we'll need it in more places,
making it a hard requirement reduces the amount of needed ifdefs and
should make adding color management features a little simpler.
being naturalx something that needs to map to the actual geometry of the window which is in absolute coordinates but mapped to a view which geometry correspond to the one of one particular screen (plus the layout the thumbnail lives in has its own geometry in the scene)
Some Toplevel properties were redefined in the AbstractClient class to
allow property mutability.
Now, since both classes were merged, those properties can be defined
only once.
A "Select All" option has the value of all the rest of the options
combined. Used for the Window Types property.
An Exclusive option cannot be check as the same time as any other
options, but uses its own value. Used for "All Activities" and
"All Virtual Desktops" properties.
Co-Authored-By: Fushan Wen <qydwhotmail@gmail.com>
Provide `allOptionsMask`, `bitMask`and `useFlags` as properties
and roles from OptionsModel in C++ side, to simplify the QML part
and improve the treatment of flag-based properties in `OptionsComboBox`.
Basically this is a well known issue in wayland for globals. If bind
comes after destroyed, it will raise a invalid global error. The common
practice is to delay the destroy of global. Similar technique is also
applied to wl_output.
CCBUG: 452435
If the backend needs to apply custom logic when changing the transform,
it should override Platform::applyOutputChanges(); otherwise just update
the Output's internal transform state.
AbstractOutput is not so Abstract and it's common to avoid the word
"Abstract" in class names as it doesn't contribute any new information.
It also significantly reduces the line width in some places.
The API of SurfaceInterface was changed so it always maintains an opaque
region.
At the surface commit, if the attached buffer is opaque, the whole
surface will be marked opaque. Otherwise, the specified opaque region
will be intersected with the surface rect.