xfree86: improve readability of synthesized device.
No functional changes. The options we assign are the ones from the Pointer/Keyboard device so we might as well use those readable names instead of dev[count-1]->options. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Daniel Stone <daniel@fooishbar.org>
This commit is contained in:
parent
5aa826cdd1
commit
5669aa2d24
|
@ -1208,16 +1208,16 @@ checkCoreInputDevices(serverLayoutPtr servlayoutp, Bool implicitLayout)
|
||||||
if (foundPointer && confInput) {
|
if (foundPointer && confInput) {
|
||||||
foundPointer = configInput(&Pointer, confInput, from);
|
foundPointer = configInput(&Pointer, confInput, from);
|
||||||
if (foundPointer) {
|
if (foundPointer) {
|
||||||
|
Pointer.options = xf86addNewOption(Pointer.options,
|
||||||
|
xnfstrdup("CorePointer"), "on");
|
||||||
|
Pointer.fd = -1;
|
||||||
count++;
|
count++;
|
||||||
devs = xnfrealloc(servlayoutp->inputs,
|
devs = xnfrealloc(servlayoutp->inputs,
|
||||||
(count + 1) * sizeof(InputInfoPtr));
|
(count + 1) * sizeof(InputInfoPtr));
|
||||||
devs[count - 1] = xnfalloc(sizeof(InputInfoRec));
|
devs[count - 1] = xnfalloc(sizeof(InputInfoRec));
|
||||||
Pointer.fd = -1;
|
|
||||||
*devs[count - 1] = Pointer;
|
|
||||||
devs[count - 1]->options =
|
|
||||||
xf86addNewOption(devs[count -1]->options,
|
|
||||||
xnfstrdup("CorePointer"), "on");
|
|
||||||
devs[count] = NULL;
|
devs[count] = NULL;
|
||||||
|
|
||||||
|
*devs[count - 1] = Pointer;
|
||||||
servlayoutp->inputs = devs;
|
servlayoutp->inputs = devs;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1254,15 +1254,16 @@ checkCoreInputDevices(serverLayoutPtr servlayoutp, Bool implicitLayout)
|
||||||
confInput = &defPtr;
|
confInput = &defPtr;
|
||||||
foundPointer = configInput(&Pointer, confInput, from);
|
foundPointer = configInput(&Pointer, confInput, from);
|
||||||
if (foundPointer) {
|
if (foundPointer) {
|
||||||
|
Pointer.options = xf86addNewOption(NULL,
|
||||||
|
xnfstrdup("AlwaysCore"), "on");
|
||||||
|
Pointer.fd = -1;
|
||||||
count++;
|
count++;
|
||||||
devs = xnfrealloc(servlayoutp->inputs,
|
devs = xnfrealloc(servlayoutp->inputs,
|
||||||
(count + 1) * sizeof(InputInfoPtr));
|
(count + 1) * sizeof(InputInfoPtr));
|
||||||
devs[count - 1] = xnfalloc(sizeof(InputInfoRec));
|
devs[count - 1] = xnfalloc(sizeof(InputInfoRec));
|
||||||
Pointer.fd = -1;
|
|
||||||
*devs[count - 1] = Pointer;
|
|
||||||
devs[count - 1]->options =
|
|
||||||
xf86addNewOption(NULL, xnfstrdup("AlwaysCore"), "on");
|
|
||||||
devs[count] = NULL;
|
devs[count] = NULL;
|
||||||
|
|
||||||
|
*devs[count - 1] = Pointer;
|
||||||
servlayoutp->inputs = devs;
|
servlayoutp->inputs = devs;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1351,16 +1352,16 @@ checkCoreInputDevices(serverLayoutPtr servlayoutp, Bool implicitLayout)
|
||||||
if (foundKeyboard && confInput) {
|
if (foundKeyboard && confInput) {
|
||||||
foundKeyboard = configInput(&Keyboard, confInput, from);
|
foundKeyboard = configInput(&Keyboard, confInput, from);
|
||||||
if (foundKeyboard) {
|
if (foundKeyboard) {
|
||||||
|
Keyboard.options = xf86addNewOption(Keyboard.options,
|
||||||
|
xnfstrdup("CoreKeyboard"), "on");
|
||||||
|
Keyboard.fd = -1;
|
||||||
count++;
|
count++;
|
||||||
devs = xnfrealloc(servlayoutp->inputs,
|
devs = xnfrealloc(servlayoutp->inputs,
|
||||||
(count + 1) * sizeof(InputInfoPtr));
|
(count + 1) * sizeof(InputInfoPtr));
|
||||||
devs[count - 1] = xnfalloc(sizeof(InputInfoRec));
|
devs[count - 1] = xnfalloc(sizeof(InputInfoRec));
|
||||||
Keyboard.fd = -1;
|
|
||||||
*devs[count - 1] = Keyboard;
|
|
||||||
devs[count - 1]->options =
|
|
||||||
xf86addNewOption(devs[count - 1]->options,
|
|
||||||
xnfstrdup("CoreKeyboard"), "on");
|
|
||||||
devs[count] = NULL;
|
devs[count] = NULL;
|
||||||
|
|
||||||
|
*devs[count - 1] = Keyboard;
|
||||||
servlayoutp->inputs = devs;
|
servlayoutp->inputs = devs;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user