[Qt-interest] Overridig mouseDoubleClickEvent(QMouseEvent *event)
Keshava Krishna
keshavkrishna88 at gmail.com
Wed Mar 25 06:59:15 CET 2009
Sorry guys, there was a bug in my show_image() function.
Please ignore this mail...
On Wed, Mar 25, 2009 at 11:18 AM, Keshava Krishna <keshavkrishna88 at gmail.com
> wrote:
> Hi,
> i have overridden mouseDoubleClickEvent(QMouseEvent *event) in my
> application...
> void Win::mouseDoubleClickEvent(QMouseEvent *event)
> {
> int x=event->x();
> x-=100;
> x=x/50;
>
> if(!ImageList[x]->isNull())
> {
> imageFileName=*linkedImageList[x];
> show_image();
> }
>
> }
>
> in my application there are many images displayed, by double clicking on
> any of those i want the corresponding image to be maximized,,,
> this works fine if i doubleclick on an area containg an image, but it gives
> segmentation fault if i double click on an empty region..
> can anyone help me in debugging this?? is dat if condition not enough to
> handle this (which opens an image only if click on an image) ??
>
> Regards,
> Keshava.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090325/afe02460/attachment.html
More information about the Qt-interest-old
mailing list