Thread: Subclassing

  1. #1
    Registered User
    Join Date
    Jan 2008
    Posts
    2

    Subclassing

    Hi,
    I'm a newbie to this forum and I'm sure your advices will be very useful to me.
    This is my question:
    is there a way to intercept mouse messages from internet explorer in my mfc application? I need a way to catch the middle mouse button and use it for going back to the previous page or close the window. I was thinking about subclassing the internet explorer window, but I don't know how to do.
    Can anyone help me please?
    Thank you

  2. #2
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Yes, the most obvious way would probably be using a window hook I think. But such code is typically a little tricky. Maybe codeproject has some sample code.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  3. #3
    Registered User
    Join Date
    Jan 2008
    Posts
    2
    I did something with global hooking. It works fine but I can't completely override the middle mouse in ie window, I mean, when I click on middle mouse the double arrow of the autoscroll compares for some moments. I would like to avoid that.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. I got subclassing to work, but....
    By cl2606 in forum Windows Programming
    Replies: 2
    Last Post: 07-06-2008, 03:28 PM
  2. Subclassing
    By Mithoric in forum Windows Programming
    Replies: 5
    Last Post: 11-22-2003, 05:30 PM
  3. Subclassing Problem
    By Thunder in forum Windows Programming
    Replies: 4
    Last Post: 10-22-2003, 03:49 PM
  4. Subclassing a dialog->Calling DialogProc
    By knutso in forum Windows Programming
    Replies: 7
    Last Post: 05-20-2003, 12:33 AM
  5. Subclassing a listbox and the speed of the postal service
    By SMurf in forum Windows Programming
    Replies: 3
    Last Post: 09-14-2002, 07:25 PM