Fix compiler warnings

This commit is contained in:
Martin Gräßlin 2015-09-02 16:20:10 +02:00
parent 8dc1e73f5d
commit 66838ccf33
4 changed files with 5 additions and 4 deletions

View file

@ -103,7 +103,7 @@ void CompositorInterface::Private::createSurface(wl_client *client, wl_resource
return;
}
QObject::connect(surface->client(), &ClientConnection::disconnected, surface,
[surface] (ClientConnection *c) {
[surface] {
if (surface->resource()) {
wl_resource_destroy(surface->resource());
delete surface;
@ -128,7 +128,7 @@ void CompositorInterface::Private::createRegion(wl_client *client, wl_resource *
return;
}
QObject::connect(region->client(), &ClientConnection::disconnected, region,
[region] (ClientConnection *c) {
[region] {
if (region->resource()) {
wl_resource_destroy(region->resource());
delete region;

View file

@ -552,7 +552,7 @@ static quint32 qtToWaylandButton(Qt::MouseButton button)
// further mapping not possible, 0x120 is BTN_JOYSTICK
});
return s_buttons.value(button, 0);
};
}
bool SeatInterface::isPointerButtonPressed(Qt::MouseButton button) const
{

View file

@ -18,4 +18,4 @@ You should have received a copy of the GNU Lesser General Public
License along with this library. If not, see <http://www.gnu.org/licenses/>.
*********************************************************************/
#include "logging_p.h"
Q_LOGGING_CATEGORY(KWAYLAND_SERVER, "kwayland-server", QtCriticalMsg);
Q_LOGGING_CATEGORY(KWAYLAND_SERVER, "kwayland-server", QtCriticalMsg)

View file

@ -132,6 +132,7 @@ void PanelTest::setupRegistry(Registry *registry)
auto p = m_seat->createPointer(this);
connect(p, &Pointer::buttonStateChanged, this,
[this] (quint32 serial, quint32 time, quint32 button, KWayland::Client::Pointer::ButtonState state) {
Q_UNUSED(time)
Q_UNUSED(serial)
if (!m_windowManagement) {
return;