Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 549913

Summary: [win32][extract method] Extract "readRegistryDword" method from Display to OS
Product: [Eclipse Project] Platform Reporter: Niraj Modi <niraj.modi>
Component: SWTAssignee: Niraj Modi <niraj.modi>
Status: VERIFIED FIXED QA Contact: Alexandr Miloslavskiy <alexandr.miloslavskiy>
Severity: normal    
Priority: P3 CC: alexandr.miloslavskiy
Version: 4.13   
Target Milestone: 4.13 M3   
Hardware: PC   
OS: Windows 10   
See Also: https://git.eclipse.org/r/147351
https://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/?id=00b8a6b3ce979bf00109c9597563c22ab7fd7e3d
Whiteboard:
Bug Depends on: 549713    
Bug Blocks: 549414    

Description Niraj Modi CLA 2019-08-09 03:28:23 EDT
Refactor and extract Registry Dword read logic from Display class to OS class:
OS.readRegistryDword(int hkeyLocation, TCHAR key, TCHAR lpValueName)

The extracted method will be internal will be called from below methods:
Display.isSystemDarkTheme()
Display.isXMouseActive()
Comment 1 Niraj Modi CLA 2019-08-09 03:32:33 EDT
I have made the required changes will be share a gerrit shortly.
Comment 2 Eclipse Genie CLA 2019-08-09 04:12:46 EDT
New Gerrit change created: https://git.eclipse.org/r/147351
Comment 3 Niraj Modi CLA 2019-08-09 04:17:14 EDT
(In reply to Niraj Modi from comment #0)
> Refactor and extract Registry Dword read logic from Display class to OS
> class:
> OS.readRegistryDword(int hkeyLocation, TCHAR key, TCHAR lpValueName)
In order to cover the scenario when registry entry is not found, above extracted method will throw a checked Exception.
Comment 5 Niraj Modi CLA 2019-08-12 03:31:19 EDT
(In reply to Eclipse Genie from comment #4)
> Gerrit change https://git.eclipse.org/r/147351 was merged to [master].
> Commit:
> http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/
> ?id=00b8a6b3ce979bf00109c9597563c22ab7fd7e3d

Thanks Alexandr for the quick review, resolving now.
Comment 6 Niraj Modi CLA 2019-08-20 07:43:06 EDT
Verified in sources.