Let PanoramiXCreateConnectionBlock() only return x_rpcbuf_t, not touching
global structures anymore - it's caller will that now.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
1. move the panoramix enabled check into PanoramiXConsolidate()
2. declare a static inline dummy if XINERAMA is not defined,
so callers don't need extra ifdefs anymore.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
now that we have dixConnBlockScreenStart(), we don't need the
reference parameter of dixConnBlockScreenStart() anymore.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
adding a helper for calculating the offset of the first xWindowRoot
structure within the connection info block. this way getting rid
of the global connBlockScreenStart field.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
inline CreateConnectionBlock() into PanoramiXCreateConnectionBlock(),
in order to make future refactoring a bit easier. Further steps will
refactor the function to just return the buffer instead of setting
global variables.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Drop the global connSetupPrefix variable and instead create that
tiny struct on the fly (we need to copy it for byteswapping anyways)
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
a) replace custom callback machinery by standard CallbackListPtr
Dropping lots of unnecessarily duplicated code.
b) call the callbacks from PanoramiXConsolidate() instead of
PanoramiXCreateConnectionBlock()
Still called after Xinerama has been finished it's own setup (so Xv can do
it's xinerama-specific setups) and before the first client can connect.
But now we can re-call PanoramiXCreateConnectionBlock() any time.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Store it it's own variable as authorative source, so we don't
need to keep it in connSetupPrefix anymore - and get rid of that
in future steps.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Panoramix needs a special handling so that we're only sending one
screen (and numRoots becomes = 1). Instead of tweaking global
variables back and forth, just pass in the desired value.
When 0 is passed, using screenInfo.numScreens instead.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
These helpers are always defined, even when compiling w/o PanoramiX
at all (symbol XINERAMA not defined), so we need fewer ifdef's.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
move it them the compositeext_priv.h header, which is supposed to be
the one included by other parts of the Xserver.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
A frequent pattern inside request handlers looks like this:
int rc = doSomething(...);
if (rc != Success) {
return rc;
}
Making the code bit shorter & quicker to read my moving this
into a macro like this:
X_CALL_CHECK_ERR(doSomething(...));
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>