Skip to content

[Win32] Move OS-version-related functionality to OsVersion class #2099

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

HeikoKlare
Copy link
Contributor

@HeikoKlare HeikoKlare commented May 5, 2025

With the separation of the OS version check to the separate OsVersion class/DLL, version concerns have been spread over the OS and the OsVersion classes. This change consistently moves every such logic to the OsVersion class. It also replaces the manual checks of the current OS version against a specified version by an easy-to-read access to according constants identifying whether the current system is at least a specific Windows build version.

Follow up to:

Copy link
Contributor

github-actions bot commented May 5, 2025

Test Results

   539 files   -  6     539 suites   - 6   31m 48s ⏱️ + 2m 41s
 4 339 tests  - 37   4 323 ✅  - 35   15 💤  - 3  1 ❌ +1 
16 606 runs   - 37  16 468 ✅  - 35  137 💤  - 3  1 ❌ +1 

For more details on these failures, see this check.

Results for commit 32158e3. ± Comparison against base commit eac27cd.

This pull request removes 37 tests.
AllWin32Tests org.eclipse.swt.graphics.ImageWin32Tests ‑ testImageDataForDifferentFractionalZoomsShouldBeDifferent
AllWin32Tests org.eclipse.swt.graphics.ImageWin32Tests ‑ testImageShouldHaveDimesionAsPerZoomLevel
AllWin32Tests org.eclipse.swt.tests.win32.Test_org_eclipse_swt_dnd_DND ‑ testByteArrayTransfer
AllWin32Tests org.eclipse.swt.tests.win32.Test_org_eclipse_swt_dnd_DND ‑ testFileTransfer
AllWin32Tests org.eclipse.swt.tests.win32.Test_org_eclipse_swt_dnd_DND ‑ testHtmlTransfer
AllWin32Tests org.eclipse.swt.tests.win32.Test_org_eclipse_swt_dnd_DND ‑ testImageTransfer_fromCopiedImage
AllWin32Tests org.eclipse.swt.tests.win32.Test_org_eclipse_swt_dnd_DND ‑ testImageTransfer_fromImage
AllWin32Tests org.eclipse.swt.tests.win32.Test_org_eclipse_swt_dnd_DND ‑ testImageTransfer_fromImageData
AllWin32Tests org.eclipse.swt.tests.win32.Test_org_eclipse_swt_dnd_DND ‑ testImageTransfer_fromImageDataFromImage
AllWin32Tests org.eclipse.swt.tests.win32.Test_org_eclipse_swt_dnd_DND ‑ testRtfTransfer
…

♻️ This comment has been updated with latest results.

@HeikoKlare HeikoKlare force-pushed the win32-osversion-cleanup branch 2 times, most recently from b408f62 to 3ec6d15 Compare May 5, 2025 16:56
@HeikoKlare HeikoKlare marked this pull request as ready for review May 5, 2025 18:04
@HeikoKlare HeikoKlare force-pushed the win32-osversion-cleanup branch from 3ec6d15 to 77655b5 Compare May 5, 2025 19:20
With the separation of the OS version check to the separate OsVersion
class/DLL, version concerns have been spread over the OS and the
OsVersion classes. This change consistently moves every such logic to
the OsVersion class. It also replaces the manual checks of the current
OS version against a specified version by an easy-to-read access to
according constants identifying whether the current system is at least a
specific Windows build version.
@HeikoKlare HeikoKlare force-pushed the win32-osversion-cleanup branch from 77655b5 to 32158e3 Compare May 6, 2025 19:08
@HeikoKlare
Copy link
Contributor Author

Failing test is unrelated: #1843

@HeikoKlare HeikoKlare merged commit b94b33a into eclipse-platform:master May 6, 2025
16 of 17 checks passed
@HeikoKlare HeikoKlare deleted the win32-osversion-cleanup branch May 6, 2025 20:05
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.

2 participants