The only thing I want to know is how to get the HWND of the Widget.
This program uses EcWin7 to display tasks on win 7 The progress of the bar icon, but requires an HWND. After changing Q_WS_WIN to Q_OS_WIN, the lib itself seems to compile well)
In Qt4 on Windows, Wid is just a typedef of HWND, so this is fine.
In Qt5 , This is no longer the case.
I found some mailing list postings that can provide clues, but it seems that QPlatformNativeInterface is no longer part of Qt5’s public API.
This program calls EcWin7. init(this-> winId()); I need some way to convert this ID to HWND ID or other ways to get this ID.
bool winEvent(MSG* pMsg, long* result)
It’s now
bool nativeEvent(const QByteArray & eventType, void * message, long *result)
In EcWin7::winEvent you Must be forced to MSG:
bool EcWin7::winEvent(void * message, long * result)
{
MSG* msg = reinterpret_cast(message);
if (msg->message == mTaskbarMessageId)
{
...
I can make the application work! Just replace:
mWindowId = wid;
Same
mWindowId = (HWND)wid ;
I am trying to convert a Qt4 application to Qt5.
The only thing I want to know is how to get the HWND of the Widget.
The program uses EcWin7 to The progress of the taskbar icon on win 7 is displayed, but an HWND is required. After changing Q_WS_WIN to Q_OS_WIN, the lib itself seems to compile well)
In Qt4 on Windows, WId is just a typedef of HWND, so this is no problem.
br>In Qt5, this is no longer the case.
I found some mailing list postings that can provide clues, but it seems that QPlatformNativeInterface is no longer part of Qt5’s public API.
The program calls EcWin7.init(this->winId()); I need some way to convert this ID to HWND ID or other ways to get this ID.
In Qt5, winEvent is replaced by nativeEvent:
bool winEvent(MSG* pMsg, long* result)
It’s now< /p>
bool nativeEvent(const QByteArray & eventType, void * message, long *result)
In EcWin7::winEvent you must force conversion to MSG:< /p>
bool EcWin7::winEvent(void * message, long * result)
{
MSG* msg = reinterpret_cast(message);< br /> if (msg->message == mTaskbarMessageId)
{
...
I can make the application work! Just replace:
mWindowId = wid;
Same
mWindowId = (HWND)wid ;
WordPress database error: [Table 'yf99682.wp_s6mz6tyggq_comments' doesn't exist]SELECT SQL_CALC_FOUND_ROWS wp_s6mz6tyggq_comments.comment_ID FROM wp_s6mz6tyggq_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 2155 ORDER BY wp_s6mz6tyggq_comments.comment_date_gmt ASC, wp_s6mz6tyggq_comments.comment_ID ASC