[pywin32-bugs] [ pywin32-Bugs-1815499 ] SetWindowPos can't work with activex control
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: SourceForge.net <no...@so...> - 2007-10-24 07:39:53
|
Bugs item #1815499, was opened at 2007-10-18 02:23 Message generated for change (Comment added) made by weck You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1815499&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: zou guangxian (weck) Assigned to: Nobody/Anonymous (nobody) Summary: SetWindowPos can't work with activex control Initial Comment: In win32app.cpp:2166, BOOL ok = ::SetWindowPos( pWnd->GetSafeHwnd(), insertAfter, x, y, cx, cy, flags); should be changed to the following lines: CWnd wndInsertAfter; wndInsertAfter.Attach(insertAfter); BOOL ok = pWnd->SetWindowPos( &wndInsertAfter, x, y, cx, cy, flags); wndInsertAfter.Detach(); ---------------------------------------------------------------------- >Comment By: zou guangxian (weck) Date: 2007-10-24 07:39 Message: Logged In: YES user_id=499971 Originator: YES The attachment is a modification of flash.py in Lib\site-packages\pythonwin\pywin\Demos\ocx\. After it launched, it will create a window to host ShockwaveFlash control. User can drag the border to resize the window. but when host window became larger, the ShockwaveFlash only do a 'fake' resize. when you click on ShockwaveFlash control, it will shrink to the size when it was created. I've readed the source code and found that CWnd::SetWindowPos will do a lot of things except calling ::SetWindowPos. so I made a changement like the lines listed before, and it work very well. File Added: flash2.py ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2007-10-18 02:26 Message: Logged In: YES user_id=14198 Originator: NO Can you please show an example of some code that is broken now, but is fixed with this change? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1815499&group_id=78018 |