Skip to content

Commit

Permalink
Merge pull request #88220 from FaycalElOuariachi/display_server_windo…
Browse files Browse the repository at this point in the history
…ws-clipboard_get_image-fix-DIB-image-import

Fix the fetching of images in `CF_DIB` format in `DisplayServerWindows::clipboard_get_image`
  • Loading branch information
akien-mga committed Feb 12, 2024
2 parents c8b3e39 + c1ec036 commit f317cc7
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions platform/windows/display_server_windows.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -760,8 +760,7 @@ Ref<Image> DisplayServerWindows::clipboard_get_image() const {
pba.append(rgbquad->rgbReserved);
}
}
image.instantiate();
image->create_from_data(info->biWidth, info->biHeight, false, Image::Format::FORMAT_RGBA8, pba);
image = Image::create_from_data(info->biWidth, info->biHeight, false, Image::Format::FORMAT_RGBA8, pba);

GlobalUnlock(mem);
}
Expand Down

0 comments on commit f317cc7

Please sign in to comment.