What is a menu?

This is a discussion on What is a menu? within the Windows Programming forums, part of the Platform Specific Boards category; This question has been bugging me for some time now. What exactly is a menu? Is it a separate window ...

  1. #1
    Even death may die... Dante Shamest's Avatar
    Join Date
    Apr 2003
    Location
    Malaysia
    Posts
    970

    What is a menu?

    This question has been bugging me for some time now. What exactly is a menu?

    Is it a separate window (has a registered window class, window procedure)?

    Or is it somehow part of it's parent window's non-client area?

    This blog entry sparked my interest.

    [edit]

    After some crazy right-clicking and using Spy++, I have discovered that menus are indeed separate windows with the window class name "PopupMenu".

    [/edit]
    Last edited by Dante Shamest; 08-23-2004 at 03:44 AM.

  2. #2
    Super Moderator
    Join Date
    Sep 2001
    Posts
    4,913
    There are different types of menus, though it is a bit hard to figure out specifically what you're talking about. There's drop down menus as form elements, menus like the 'File' and 'Edit' menus, and then there's the kind you right click, which I think are called pop-up menus.

  3. #3
    Even death may die... Dante Shamest's Avatar
    Join Date
    Apr 2003
    Location
    Malaysia
    Posts
    970
    I'm talking about menus created with CreateMenu() and CreatePopupMenu().

  4. #4
    Registered User
    Join Date
    Sep 2003
    Posts
    23
    Yes,

    and I wander now what GetFocus() returns when menu bar has a focus?!
    Like, when I just press alt key without any other letter-key.

  5. #5
    Even death may die... Dante Shamest's Avatar
    Join Date
    Apr 2003
    Location
    Malaysia
    Posts
    970
    I think the menu bar is drawn by the owner window.

    The menus themselves are probably separate windows.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Checking array for string
    By Ayreon in forum C Programming
    Replies: 87
    Last Post: 03-09-2009, 03:25 PM
  2. Replies: 2
    Last Post: 03-05-2009, 09:25 AM
  3. Another syntax error
    By caldeira in forum C Programming
    Replies: 31
    Last Post: 09-05-2008, 01:01 AM
  4. Constructive Feed Back (Java Program)
    By xddxogm3 in forum Tech Board
    Replies: 12
    Last Post: 10-10-2004, 03:41 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21