Review Request 117107: Do not use WId in KCookieServer
Aurélien Gâteau
agateau at kde.org
Thu Mar 27 09:59:14 UTC 2014
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/117107/
-----------------------------------------------------------
Review request for KDE Frameworks and Alexander Richardson.
Repository: kio
Description
-------
KCookieServer is exposed over DBus and DBus does not know about WId. Using WId as an argument in a method prevents it from being exposed, breaking KHTML build (see http://build.kde.org/view/Frameworks/job/khtml_master_qt5/60/console ). This patch partially reverts commit 08548e2ff72923aa72437f2f7cf68c5c0b81f605.
I haven't tested on Windows, but I see parent of 08548e2ff72923aa72437f2f7cf68c5c0b81f605 has this code:
#ifndef Q_OS_WIN
KWindowSystem::setMainWindow(kw, static_cast<WId>(windowId));
#else
KWindowSystem::setMainWindow(kw, (HWND)(long)windowId);
#endif
Do we need something like this? If so, I was thinking of adding this:
inline WId toWid(qlonglong value)
{
#ifdef Q_OS_WIN
return (HWND)(long)value;
#else
return static_cast<WId>(value);
#endif
}
And then wrapping all qlonglong args with it. Does it make sense?
Diffs
-----
src/ioslaves/http/kcookiejar/kcookieserver.h 204f3ca
src/ioslaves/http/kcookiejar/kcookieserver.cpp 81ea2bc
Diff: https://git.reviewboard.kde.org/r/117107/diff/
Testing
-------
Builds, fixes KHTML build.
Thanks,
Aurélien Gâteau
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20140327/86f0afb4/attachment.html>
More information about the Kde-frameworks-devel
mailing list