Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Using CView as a child window and CCmdUI

Using CView as a child window and CCmdUI

Scheduled Pinned Locked Moved C / C++ / MFC
designoophelpquestionannouncement
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    BadJerry
    wrote on last edited by
    #1

    Hi! Let me describe what I have and then I'll explain my problem: I have a SDI application which has a CFormView. In this CFormView I have several CDialog derived classes defined as child windows. In one of these CDialog I have a CView derived child window (a CHtmlEditView to be accurate). The problem is that whenever this view has focus my menus (through CCmdUI* pCmdUI) do not get updated anymore... Ideally, I would like the formview to be in charge of the menu update. After all it's only incidental that the chid window is a view... I suspect I need to have a dab at CCreateContext... but my view (which is part of a control I have not programmed although I have the source code - it's from here and I'd rather not change the code so I can use the future updates) has been create by Create and not CreateView. So here are my questions: a) can I ask that a view not to mess up with the CCmdUI* pCmdUI and let a parent view deal with it? b) if a) not possible, can I assign a CCreateContext to a view after its creation? c) if a ) and b) are not possible, can someone pay me a round of drinks so I can forget my dreams of good design and encapsulation? Thanks in advance

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups