Skip to content

v1.1.0 - Dropdown clicks

Latest

Choose a tag to compare

@gitTerebi gitTerebi released this 01 Sep 19:41
· 10 commits to master since this release

Fork of cnc-ddraw for Red Alert 2 and Yuri's Revenge, adding a menu input mode that keeps the upscaled menus clickable.

Fixed in this release

Dropdown list items did not respond to clicks. RA2 opens its own dropdown window (class ComboDropWin) and calls SetCapture on it. Mouse capture bypasses hit-testing, so Windows delivered click coordinates relative to the window's unscaled rectangle while the player clicked the upscaled artwork. The subclass procedure now recomputes those coordinates from the real cursor position whenever a child window holds capture.

Affects the keyboard customize screen (Category selector) and any other RA2 dropdown.

Already in v1.0.0

  • fixchilds=5, a menu input mode that forwards clicks to the unscaled dialog controls.
  • Campaign side emblems respond to clicks. RA2 hit-tests them through ChildWindowFromPointEx; the hook retries a missed lookup with the point divided back into dialog space.
  • The invisible unscaled dialog no longer swallows clicks in the top left region. Its controls answer WM_NCHITTEST with HTTRANSPARENT.
  • Mouse offset corrected for borderless maximized windows.
  • Multi-pass shader chains.

Install

Copy ddraw.dll next to game.exe, then set fixchilds=5 in the [game] section of ddraw.ini.