[pywin32-bugs] [ pywin32-Bugs-965610 ] docview.py & COM draw Framework into the machine
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: SourceForge.net <no...@so...> - 2004-10-09 06:01:51
|
Bugs item #965610, was opened at 2004-06-03 19:17 Message generated for change (Comment added) made by mhammond You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=965610&group_id=78018 Category: pythonwin Group: None >Status: Pending Resolution: None Priority: 5 Submitted By: Robert Kiendl (kxroberto) Assigned to: Nobody/Anonymous (nobody) Summary: docview.py & COM draw Framework into the machine Initial Comment: docview.py draws the framework into the machine (e.g. py2exe creates output +1MB in size). Software uses unnecessary lots of memory. and: now win32com/server/dispatcher.py also draws the framework/debugger ! i patched it like this ( but not very elegant because i don't overview the framework module design well; but only 2 locations changing ) # docview.py self.MakeView=MakeView self._SetupSharedMenu_() def _SetupSharedMenu_(self): pass #to be replaced by framework! ### todo - _SetupSharedMenu_ should be moved to a framework class. ## def _SetupSharedMenu_(self): ## sharedMenu = self.GetSharedMenu() ## from pywin.framework import toolmenu ## toolmenu.SetToolsMenu(sharedMenu) ## from pywin.framework import help ## help.SetHelpMenuOtherHelp(sharedMenu) def _CreateDocTemplate(self, resourceId): return win32ui.CreateDocTemplate(resourceId) def __del__(self): # intpyapp.py import dbgcommands lastLocateFileName = ".py" # used in the "File/Locate" dialog... # todo - _SetupSharedMenu should be moved to a framework class. def _SetupSharedMenu_(self): sharedMenu = self.GetSharedMenu() from pywin.framework import toolmenu toolmenu.SetToolsMenu(sharedMenu) from pywin.framework import help help.SetHelpMenuOtherHelp(sharedMenu) from pywin.mfc import docview docview.DocTemplate._SetupSharedMenu_=_SetupSharedMenu_ class MainFrame(app.MainFrame): def OnCreate(self, createStruct): self.closing = 0 # dispatcher.py def __init__(self, policyClass, ob): exec "import pywin.debugger" pywin.debugger.brk() ---------------------------------------------------------------------- >Comment By: Mark Hammond (mhammond) Date: 2004-10-09 16:01 Message: Logged In: YES user_id=14198 You can tell py2exe to exclude them, but if you could turn your code into either a .patch or the complete files as "clean" as possible, I'd certainly consider it. Please reset the bug status to "open" when you do (or just create a new "patch") Thanks ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=965610&group_id=78018 |