Commits (17)
......@@ -382,7 +382,7 @@ ProcXTestFakeInput(ClientPtr client)
if ((flags & POINTER_ABSOLUTE) && firstValuator <= 1 && numValuators > 0) {
if (firstValuator == 0)
valuators[0] += root->drawable.pScreen->x;
if (firstValuator < 2 && firstValuator + numValuators > 1)
if (firstValuator + numValuators > 1)
valuators[1 - firstValuator] += root->drawable.pScreen->y;
}
}
......
......@@ -150,7 +150,7 @@ def parse_all_matches(node):
# walk up to a parent match node
node = node.parentNode
if node == None or not is_match_node(node):
if node is None or not is_match_node(node):
break
# leave if there other options at this level
......@@ -184,9 +184,6 @@ def parse_fdi(fdi):
# find all <match> leaf nodes
num = 0
for match_node in fdi.getElementsByTagName('match'):
children = set([n.tagName for n in match_node.childNodes
if n.nodeType == xml.dom.minidom.Node.ELEMENT_NODE])
# see if there are any options at this level
(driver, ignore, options) = parse_options(match_node)
if not driver and not ignore and not options:
......
......@@ -365,7 +365,7 @@ CoreEnterLeaveNonLinear(DeviceIntPtr dev, WindowPtr A, WindowPtr B, int mode)
Case 3C: Otherwise:
The pointer window moves from W to a window above W.
The detail may need to be changed from Ancestor to Nonlinear or
vice versa depending on the the new P(W)
vice versa depending on the new P(W)
*/
if (!HasPointer(dev, A)) {
......@@ -447,7 +447,7 @@ CoreEnterLeaveToAncestor(DeviceIntPtr dev, WindowPtr A, WindowPtr B, int mode)
Case 3C: Otherwise:
The pointer window moves from W to a window above W.
The detail may need to be changed from Ancestor to Nonlinear or
vice versa depending on the the new P(W)
vice versa depending on the new P(W)
*/
if (!HasPointer(dev, A)) {
WindowPtr child = FirstPointerChild(A);
......@@ -1053,7 +1053,7 @@ CoreFocusNonLinear(DeviceIntPtr dev, WindowPtr A, WindowPtr B, int mode)
Case 3C: Otherwise:
The focus window moves from W to a window above W.
The detail may need to be changed from Ancestor to Nonlinear or
vice versa depending on the the new F(W)
vice versa depending on the new F(W)
*/
if (!HasFocus(A)) {
......@@ -1141,7 +1141,7 @@ CoreFocusToAncestor(DeviceIntPtr dev, WindowPtr A, WindowPtr B, int mode)
Case 3C: Otherwise:
The focus window moves from W to a window above W.
The detail may need to be changed from Ancestor to Nonlinear or
vice versa depending on the the new F(W)
vice versa depending on the new F(W)
*/
if (!HasFocus(A)) {
WindowPtr child = FirstFocusChild(A);
......
......@@ -87,7 +87,7 @@ exaCreatePixmap_driver(ScreenPtr pScreen, int w, int h, int depth,
}
else {
paddedWidth = ((w * bpp + FB_MASK) >> FB_SHIFT) * sizeof(FbBits);
if (paddedWidth / 4 > 32767 || h > 32767)
if (paddedWidth / 4 > 32767)
return NullPixmap;
exaSetFbPitch(pExaScr, pExaPixmap, w, h, bpp);
......
......@@ -72,7 +72,7 @@ exaCreatePixmap_mixed(ScreenPtr pScreen, int w, int h, int depth,
bpp = pPixmap->drawable.bitsPerPixel;
paddedWidth = ((w * bpp + FB_MASK) >> FB_SHIFT) * sizeof(FbBits);
if (paddedWidth / 4 > 32767 || h > 32767)
if (paddedWidth / 4 > 32767)
return NullPixmap;
/* We will allocate the system pixmap later if needed. */
......@@ -326,5 +326,3 @@ exaSetSharedPixmapBacking_mixed(PixmapPtr pPixmap, void *handle)
return ret;
}
......@@ -131,7 +131,6 @@ GlxContextTagInfo *GlxAllocContextTag(ClientPtr client, GlxServerVendor *vendor)
cl->contextTagCount = newSize;
}
assert(index >= 0);
assert(index < cl->contextTagCount);
memset(&cl->contextTags[index], 0, sizeof(GlxContextTagInfo));
cl->contextTags[index].tag = (GLXContextTag) (index + 1);
......
......@@ -369,7 +369,7 @@ KdUseMsg(void)
ErrorF("-softCursor Force software cursor\n");
ErrorF("-videoTest Start the server, pause momentarily and exit\n");
ErrorF
("-origin X,Y Locates the next screen in the the virtual screen (Xinerama)\n");
("-origin X,Y Locates the next screen in the virtual screen (Xinerama)\n");
ErrorF("-switchCmd Command to execute on vt switch\n");
ErrorF
("vtxx Use virtual terminal xx instead of the next available\n");
......
......@@ -1352,9 +1352,6 @@ xf86ValidateModes(ScrnInfoPtr scrp, DisplayModePtr availModes,
int saveType;
PixmapFormatRec *BankFormat;
ClockRangePtr cp;
int numTimings = 0;
range hsync[MAX_HSYNC];
range vrefresh[MAX_VREFRESH];
Bool inferred_virtual = FALSE;
DebugF
......@@ -1394,18 +1391,9 @@ xf86ValidateModes(ScrnInfoPtr scrp, DisplayModePtr availModes,
Bool specified = FALSE;
if (scrp->monitor->nHsync <= 0) {
if (numTimings > 0) {
scrp->monitor->nHsync = numTimings;
for (i = 0; i < numTimings; i++) {
scrp->monitor->hsync[i].lo = hsync[i].lo;
scrp->monitor->hsync[i].hi = hsync[i].hi;
}
}
else {
scrp->monitor->hsync[0].lo = 31.5;
scrp->monitor->hsync[0].hi = 48.0;
scrp->monitor->nHsync = 1;
}
scrp->monitor->hsync[0].lo = 31.5;
scrp->monitor->hsync[0].hi = 48.0;
scrp->monitor->nHsync = 1;
type = "default ";
}
else {
......@@ -1426,18 +1414,9 @@ xf86ValidateModes(ScrnInfoPtr scrp, DisplayModePtr availModes,
type = "";
if (scrp->monitor->nVrefresh <= 0) {
if (numTimings > 0) {
scrp->monitor->nVrefresh = numTimings;
for (i = 0; i < numTimings; i++) {
scrp->monitor->vrefresh[i].lo = vrefresh[i].lo;
scrp->monitor->vrefresh[i].hi = vrefresh[i].hi;
}
}
else {
scrp->monitor->vrefresh[0].lo = 50;
scrp->monitor->vrefresh[0].hi = 70;
scrp->monitor->nVrefresh = 1;
}
scrp->monitor->vrefresh[0].lo = 50;
scrp->monitor->vrefresh[0].hi = 70;
scrp->monitor->nVrefresh = 1;
type = "default ";
}
else {
......
......@@ -519,13 +519,13 @@ connector_add_prop(drmModeAtomicReq *req, drmmode_output_private_ptr drmmode_out
}
static int
drmmode_CompareKModes(drmModeModeInfo * kmode, drmModeModeInfo * other)
drmmode_CompareKModes(const drmModeModeInfo * kmode, const drmModeModeInfo * other)
{
return memcmp(kmode, other, sizeof(*kmode));
}
static int
drm_mode_ensure_blob(xf86CrtcPtr crtc, drmModeModeInfo mode_info)
drm_mode_ensure_blob(xf86CrtcPtr crtc, const drmModeModeInfo* mode_info)
{
modesettingPtr ms = modesettingPTR(crtc->scrn);
drmmode_crtc_private_ptr drmmode_crtc = crtc->driver_private;
......@@ -533,14 +533,14 @@ drm_mode_ensure_blob(xf86CrtcPtr crtc, drmModeModeInfo mode_info)
int ret;
if (drmmode_crtc->current_mode &&
drmmode_CompareKModes(&drmmode_crtc->current_mode->mode_info, &mode_info) == 0)
drmmode_CompareKModes(&drmmode_crtc->current_mode->mode_info, mode_info) == 0)
return 0;
mode = calloc(sizeof(drmmode_mode_rec), 1);
if (!mode)
return -1;
mode->mode_info = mode_info;
mode->mode_info = *mode_info;
ret = drmModeCreatePropertyBlob(ms->fd,
&mode->mode_info,
sizeof(mode->mode_info),
......@@ -589,7 +589,7 @@ crtc_add_dpms_props(drmModeAtomicReq *req, xf86CrtcPtr crtc,
drmModeModeInfo kmode;
drmmode_ConvertToKMode(crtc->scrn, &kmode, &crtc->mode);
ret |= drm_mode_ensure_blob(crtc, kmode);
ret |= drm_mode_ensure_blob(crtc, &kmode);
ret |= crtc_add_prop(req, drmmode_crtc,
DRMMODE_CRTC_ACTIVE, 1);
......
......@@ -61,6 +61,7 @@ static char consoleDev[PATH_MAX] = "/dev/fb";
Used by hw/xfree86/common/xf86AutoConfig.c for VIS_GETIDENTIFIER */
_X_HIDDEN char xf86SolarisFbDev[PATH_MAX] = "/dev/fb";
#ifdef HAS_USL_VTS
static void
switch_to(int vt, const char *from)
{
......@@ -76,6 +77,7 @@ switch_to(int vt, const char *from)
xf86Msg(X_WARNING, "%s: VT_WAITACTIVE failed: %s\n",
from, strerror(errno));
}
#endif
void
xf86OpenConsole(void)
......
......@@ -124,7 +124,7 @@ Flags
Hardware cursor data consists of two pieces, a source and a mask.
The mask is a bitmap indicating which parts of the cursor are
transparent and which parts are drawn. The source is a bitmap
indicating which parts of the non-transparent portion of the the
indicating which parts of the non-transparent portion of the
cursor should be painted in the foreground color and which should
be painted in the background color.
......
......@@ -58,7 +58,7 @@
* modularize it, was basically: 1) no unnecessary subroutine calls,
* 2) no routines more than about 200 lines in size, and 3) modularize
* any code that I might not get right the first time. The fetch_*
* subroutines fall into the latter category. The The decode_* fall
* subroutines fall into the latter category. The decode_* fall
* into the second category. The coding of the "switch(mod){ .... }"
* in many of the subroutines below falls into the first category.
* Especially, the coding of {add,and,or,sub,...}_{byte,word}
......
......@@ -2622,8 +2622,8 @@ ins(int size)
store_data_long_abs(M.x86.R_ES, M.x86.R_DI,
(*sys_inl) (M.x86.R_DX));
M.x86.R_DI += inc;
break;
}
break;
}
M.x86.R_CX = 0;
if (M.x86.mode & SYSMODE_PREFIX_DATA) {
......@@ -2688,8 +2688,8 @@ outs(int size)
(*sys_outl) (M.x86.R_DX,
fetch_data_long_abs(M.x86.R_ES, M.x86.R_SI));
M.x86.R_SI += inc;
break;
}
break;
}
M.x86.R_CX = 0;
if (M.x86.mode & SYSMODE_PREFIX_DATA) {
......
......@@ -309,7 +309,7 @@ development of
.PP
Since
.B Xnest
need not use the same default visual as the the real server, the top-level
need not use the same default visual as the real server, the top-level
window of the
.B Xnest
client always has its own color map.
......
......@@ -73,10 +73,10 @@ Enable syncing between the OSX pasteboard and clipboard/primary selection buffer
Update the X11 CLIPBOARD when the OSX NSPasteboard is updated.
.TP 8
.B defaults write @bundle_id_prefix@.X11 sync_pasteboard_to_primary -boolean true
Update the the X11 PRIMARY buffer when the OSX NSPasteboard is updated.
Update the X11 PRIMARY buffer when the OSX NSPasteboard is updated.
.TP 8
.B defaults write @bundle_id_prefix@.X11 sync_clipboard_to_pasteboard -boolean true
Update the the OSX NSPasteboard when the X11 CLIPBOARD is updated. Note that enabling this option causes the clipboard synchronization to act as a clipboard manager in X11. This makes it impossible to use xclipboard, klipper, or any other such clipboard managers. If you want to use any of these programs, you must disable this option.
Update the OSX NSPasteboard when the X11 CLIPBOARD is updated. Note that enabling this option causes the clipboard synchronization to act as a clipboard manager in X11. This makes it impossible to use xclipboard, klipper, or any other such clipboard managers. If you want to use any of these programs, you must disable this option.
.TP 8
.B defaults write @bundle_id_prefix@.X11 sync_primary_on_select -boolean true
This option defaults to false and is provided only "for experts." It updates the NSPasteboard whenever a new X11 selection is made (rather than requiring you to hit cmd-c to copy the selection to the NSPasteboard). Since the X11 protocol does not require applications to send notification when they change selection, this might not work in all cases (if you run into this problem, try selecting text in another application first, then selecting the text you want).
......
......@@ -386,7 +386,8 @@ static void
drm_lease_device_handle_released(void *data,
struct wp_drm_lease_device_v1 *wp_drm_lease_device_v1)
{
xwl_screen_destroy_drm_lease_device(data, wp_drm_lease_device_v1);
struct xwl_drm_lease_device *lease_device = data;
xwl_screen_destroy_drm_lease_device(lease_device->xwl_screen, wp_drm_lease_device_v1);
}
static void
......
......@@ -720,6 +720,27 @@ static const struct zxdg_output_v1_listener xdg_output_listener = {
xdg_output_handle_description,
};
#define XRANDR_EMULATION_PROP "RANDR Emulation"
static Atom
get_rand_emulation_property(void)
{
const char *emulStr = XRANDR_EMULATION_PROP;
return MakeAtom(emulStr, strlen(emulStr), TRUE);
}
static void
xwl_output_set_emulated(struct xwl_output *xwl_output)
{
int32_t val = TRUE;
RRChangeOutputProperty(xwl_output->randr_output,
get_rand_emulation_property(),
XA_INTEGER,
32, PropModeReplace, 1,
&val, FALSE, FALSE);
}
struct xwl_output *
xwl_output_create(struct xwl_screen *xwl_screen, uint32_t id)
{
......@@ -758,6 +779,7 @@ xwl_output_create(struct xwl_screen *xwl_screen, uint32_t id)
ErrorF("Failed creating RandR Output\n");
goto err;
}
xwl_output_set_emulated(xwl_output);
RRCrtcGammaSetSize(xwl_output->randr_crtc, 256);
RROutputSetCrtcs(xwl_output->randr_output, &xwl_output->randr_crtc, 1);
......@@ -896,6 +918,10 @@ xwl_randr_output_set_property(ScreenPtr pScreen,
Atom property,
RRPropertyValuePtr value)
{
/* RANDR Emulation property is read-only. */
if (get_rand_emulation_property() == property)
return FALSE;
return TRUE;
}
......
......@@ -24,7 +24,7 @@
# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
# MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
import sys, time, pdb, string, cProfile
import sys
from reg import *
# Default input / log files
......
......@@ -1134,7 +1134,7 @@ glxWinSetPixelFormat(HDC hdc, int bppOverride, int drawableTypeOverride,
winConfig->pixelFormatIndex);
/*
Normally, we can just use the the pixelFormatIndex corresponding
Normally, we can just use the pixelFormatIndex corresponding
to the fbconfig which has been specified by the client
*/
......
......@@ -461,20 +461,12 @@ rrGetPixmapSharingSyncProp(int numOutputs, RROutputPtr * outputs)
for (o = 0; o < numOutputs; o++) {
RRPropertyValuePtr val;
/* Try pending value first, then current value */
if ((val = RRGetOutputProperty(outputs[o], syncProp, TRUE)) &&
val->data) {
if (!(*(char *) val->data))
return FALSE;
continue;
}
if ((val = RRGetOutputProperty(outputs[o], syncProp, FALSE)) &&
val->data) {
if (!(*(char *) val->data))
return FALSE;
continue;
}
}
return TRUE;
......@@ -717,6 +709,25 @@ rrCheckPixmapBounding(ScreenPtr pScreen,
return TRUE;
}
#define XRANDR_EMULATION_PROP "RANDR Emulation"
static Bool
rrCheckEmulated(RROutputPtr output)
{
const char *emulStr = XRANDR_EMULATION_PROP;
Atom emulProp;
RRPropertyValuePtr val;
emulProp = MakeAtom(emulStr, strlen(emulStr), FALSE);
if (emulProp == None)
return FALSE;
val = RRGetOutputProperty(output, emulProp, TRUE);
if (val && val->data)
return !!val->data;
return FALSE;
}
/*
* Request that the Crtc be reconfigured
*/
......@@ -736,9 +747,11 @@ RRCrtcSet(RRCrtcPtr crtc,
crtcChanged = FALSE;
for (o = 0; o < numOutputs; o++) {
if (outputs[o] && outputs[o]->crtc != crtc) {
crtcChanged = TRUE;
break;
if (outputs[o]) {
if (rrCheckEmulated(outputs[o]) || (outputs[o]->crtc != crtc)) {
crtcChanged = TRUE;
break;
}
}
}
......