Home > Mobile >  QT father-son window switch
QT father-son window switch

Time:03-24

Parent window is not the main window,,,, to create a window as a function selection window, click the corresponding button pop-up window, other fork off the parent window at the same time other Windows will also have closed, but such a window, and been on child window, click on the window, he won't, and what's the solution?
Or function of the window as the parent window, click the other out of the window, can also have close window closes the function, and how to realize solving bosses

CodePudding user response:

A window class, it is assumed that there are A, B, C three window, A window to window function, B and C for the pop-up window, click the button in A open B and C, respectively, using the connect () card slot to do this, click the button that linkage to create A window, also A window on the destructor, destroy the other Windows, namely A window closes, other Windows page follow close,

CodePudding user response:

Tried before, way of thinking is a function should be able to perform the destructor window is closed, the other window is new object, wrote in the destructor function window delete other Windows statements, running, shutdown functions other window does not close the window
  •  Tags:  
  • Qt
  • Related