Results 1 to 2 of 2

Thread: webview from UI and mousepressevent

  1. #1
    Join Date
    May 2010
    Posts
    22
    Thanks
    4
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60

    Default webview from UI and mousepressevent

    Hi.

    I have QWebView widget add by QtCreator on MainWidget . I have to detect midButtom pressed. And I know that i can do this by subClass QWebView and overrite mousePressEvent void. But i don't want to write other subclasses.

    If any solution to overrite mousepressevent without create new subclass? I have ui_mainwidget.h and there is evertyhing about widgets on form. but I can/t modyfy this file because QtCreator show that this file is change from outside.

    Thanks in advance.
    maston

  2. #2
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: webview from UI and mousepressevent

    Install an event filter on your QWebView.

  3. The following user says thank you to Lykurg for this useful post:

    maston (2nd September 2010)

Similar Threads

  1. How to make webView editable?
    By isamert in forum Qt Programming
    Replies: 2
    Last Post: 14th July 2010, 09:14
  2. Webview different Win & Linux
    By wirasto in forum Qt Programming
    Replies: 1
    Last Post: 17th December 2009, 04:14
  3. qt4.6 webview has a window frame!!
    By billconan in forum Qt Programming
    Replies: 1
    Last Post: 14th November 2009, 03:49
  4. WebView
    By mskzo in forum Qt Programming
    Replies: 7
    Last Post: 5th December 2008, 21:18
  5. webView
    By peace_comp in forum Qt Programming
    Replies: 1
    Last Post: 6th July 2008, 17:57

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.