Skip to content

Commit

Permalink
Fixes issue #625, which makes --headless mode work again on Ubuntu/Li…
Browse files Browse the repository at this point in the history
…nux.
  • Loading branch information
marceltaeumel committed Apr 27, 2022
1 parent 9732404 commit 2d7105d
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions platforms/unix/vm-display-X11/sqUnixX11.c
Original file line number Diff line number Diff line change
Expand Up @@ -4894,6 +4894,8 @@ display_ioScreenDepth(void)
static double
display_ioScreenScaleFactor(void)
{
if (headless || !isConnectedToXServer)
return nan("MISS");
double scale = sqDefaultScale();
/* respect users' choice */
if (sqUseEnvironmentScale()) {
Expand Down Expand Up @@ -4988,7 +4990,7 @@ display_ioSetCursorWithMask(sqInt cursorBitsIndex, sqInt cursorMaskIndex, sqInt
Cursor cursor;
Pixmap dataPixmap, maskPixmap;

if (!isConnectedToXServer)
if (headless || !isConnectedToXServer)
return 0;

if (fakeBigCursor())
Expand Down Expand Up @@ -5049,7 +5051,7 @@ display_ioSetCursorWithMaskBig(sqInt cursorBitsIndex, sqInt cursorMaskIndex, sqI
Cursor cursor;
Pixmap dataPixmap, maskPixmap;

if (!isConnectedToXServer)
if (headless || !isConnectedToXServer)
return 0;

if (cursorMaskIndex == null)
Expand Down Expand Up @@ -5112,6 +5114,9 @@ display_ioSetCursorARGB(sqInt cursorBitsIndex, sqInt extentX, sqInt extentY, sqI
Picture picture;
Cursor cursor;

if (headless || !isConnectedToXServer)
return 0;

if (fakeBigCursor())
return 0;

Expand Down

1 comment on commit 2d7105d

@LinqLover
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you tell me when will this change make it to http://files.squeak.org/trunk/? :-)

Please sign in to comment.