Skip to content

Collected patches + update build to support Apple Silicon; add help string; update README#36

Open
williamla wants to merge 11 commits intojhford:masterfrom
williamla:collected
Open

Collected patches + update build to support Apple Silicon; add help string; update README#36
williamla wants to merge 11 commits intojhford:masterfrom
williamla:collected

Conversation

@williamla
Copy link

No description provided.

Yong Bakos and others added 11 commits August 16, 2016 10:55
Executing `screenresolution list` can result in the command prompt being
displayed immediately after the last resolution in the list.

Add a trailing line break so the command prompt is displayed on a new line.
Currently, the _compareCFDisplayModes method uses CGDisplayModeRef* as
the first and second parameters, in alignment with the
CFComparatorFunction type alias declaration expecting an
UnsafeRawPointer. But CGDisplayModeRef is already a pointer to
CGDisplayMode and doesn't need a reference again to work as a
comparator. Doing so also introduces extra referencing and dereferencing
that can be avoided.

Update the method signature to pass CGDisplayModeRef directly.
Newer versions of MacOS use a scaling factor (like 2x, which is the
default for newer MacBooks), leading to the default mode being half the
native resolution of the display. In such cases, it would be desirable
to fetch the maximum resolution supported by the display (native
resolution).

Add a getMax option to fetch this information.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants