MCStack *MCScreenDC::platform_getstackatpoint(int32_t x, int32_t y) { MCPoint t_loc; t_loc = MCPointMake(x, y); // IM-2014-01-28: [[ HiDPI ]] Convert logical to screen coordinates t_loc = logicaltoscreenpoint(t_loc); POINT t_location; t_location = MCPointToWin32POINT(t_loc); HWND t_window; t_window = WindowFromPoint(t_location); if (t_window == nil) return nil; return MCdispatcher->findstackwindowid((uint32_t)t_window); }
MCStack *MCScreenDC::platform_getstackatpoint(int32_t x, int32_t y) { MCPoint t_loc; t_loc = MCPointMake(x, y); // IM-2014-01-28: [[ HiDPI ]] Convert logical to screen coordinates t_loc = logicaltoscreenpoint(t_loc); POINT t_location; t_location = MCPointToWin32POINT(t_loc); HWND t_window; t_window = WindowFromPoint(t_location); if (t_window == nil) return nil; _Drawable d; d . type = DC_WINDOW; d . handle . window = (MCSysWindowHandle)t_window; return MCdispatcher -> findstackd(&d); }