I've solved it in my code with a Timer. Thanks. --- Matteo Brichese Software Engineer mbrich...@came.it Came Cancelli Automatici S.p.A. www.came.com ________________________________________ Da: development-bounces+mbrichese=came...@qt-project.org [development-bounces+mbrichese=came...@qt-project.org] per conto di Giuseppe D'Angelo [giuseppe.dang...@kdab.com] Inviato: lunedì 20 maggio 2013 16.10 A: developm...@qt-project.org; interest@qt-project.org Oggetto: Re: [Development] Nested Mousearea don't pass events
Hi, Il 20/05/2013 14:36, Matteo Brichese ha scritto: > This is a sample of my code: > > import QtQuick 2.0 > > Rectangle { > width: 1024 > height: 768 > > MouseArea { > anchors.fill: parent; > onClicked: console.log("Click") > } > > MouseArea { > anchors.fill: parent; > onDoubleClicked: console.log("Double Click") > } > } > > I can only see logs of the double click. > I was hoping that if I single click the last mousearea the event passed to > the second one, but it don't work, is that a bug? Being a question about developing *with* Qt, the right list to post this message is the interest list, not the development list. Anyhow, I think you just miss a "propagateComposedEvents: true" in the second MouseArea. Note that for a double click you're still going to receive the first click in the bottom MouseArea (in other words I expect that a double click will print "Click" and "Double Click"). Hope this helps, -- Giuseppe D'Angelo | giuseppe.dang...@kdab.com | Software Engineer KDAB (UK) Ltd., a KDAB Group company Tel. UK +44-1738-450410, Sweden (HQ) +46-563-540090 KDAB - Qt Experts - Platform-independent software solutions _______________________________________________ Development mailing list developm...@qt-project.org http://lists.qt-project.org/mailman/listinfo/development _______________________________________________ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest