-
Jan-Marek Glogowski yazdı
For DC initialization we check the thread ID to assign a normal or cached DC to the corresponding WinSalGraphics variable. The cached DC has a usage count, as there are some limits on cached DCs count (DCX_CACHE). But for the WinSalGraphics DC init and release the variable just matters for the accounting, and generally which thread is doing the calls: the non-main thread always has to relay them to the main application thread. Since we're releasing all WinSalGraphics in ~WinSalFrame and do all release and re-init in ImplSetParentFrame, there is no way to correspond the thread ID to the WinSalGraphics variable. So this drops the wrong assertions based on the WinSalGraphics variables and renames the GETDC message to GETCACHEDDC to make usage of a cached DC (DCX_CACHE) more obvious. As a consequence of the different release DC handling this also fixes the accounting of the cached DCs, wich was broken in the initial fix; commit c15ea73f Change-Id: I11ce52a1b4005f26567f92588437fa37bf227a2e Reviewed-on: https://gerrit.libreoffice.org/51318Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
8939cb94