You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
ORPA-pyOpenRPA/Resources/WPy64-3720/python-3.7.2.amd64/Lib/site-packages/pythonwin/pywin/framework/window.py

14 lines
500 B

6 years ago
# Framework Window classes.
# Most Pythonwin windows should use these classes rather than
# the raw MFC ones if they want Pythonwin specific functionality.
import pywin.mfc.window
import win32con
class MDIChildWnd(pywin.mfc.window.MDIChildWnd):
def AutoRestore(self):
"If the window is minimised or maximised, restore it."
p = self.GetWindowPlacement()
if p[1]==win32con.SW_MINIMIZE or p[1]==win32con.SW_SHOWMINIMIZED:
self.SetWindowPlacement(p[0], win32con.SW_RESTORE, p[2], p[3], p[4])