How to retain the minimizable ability of window docked

lets say I create a window using this

myWindow = cmds.window("myWindow1")
buttonForm = cmds.formLayout( parent = myWindow )
cmds.button( parent = buttonForm )
cmds.showWindow( 'myWindow1' )

now i can make this docked by running,

allowedAreas = ['right', 'left']
cmds.dockControl( area='left', content="myWindow1", allowedArea=allowedAreas )

but now when will make it floating its dockControl floating which doesnt have ability to minimize , is their any way i can make it minimizable ?

I’m sure you could hack it through PyQt or PySide, but I have no experience trying to do so. You might try calling myWindow.showMinimized() to see if it can be minimized manually, and if it minimizes the same way as other Maya windows. To open it again, call myWindow.showNormal()