[Wnd-commit] wnd/wnd/api/shell __init__.py,1.4,1.5 functions.py,1.3,1.4
Status: Alpha
Brought to you by:
jurner
|
From: jürgen u. <cer...@us...> - 2005-07-23 19:16:00
|
Update of /cvsroot/wnd/wnd/wnd/api/shell In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27303 Modified Files: __init__.py functions.py Log Message: bit of this and a bit of that Index: functions.py =================================================================== RCS file: /cvsroot/wnd/wnd/wnd/api/shell/functions.py,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** functions.py 2 Jul 2005 09:00:57 -0000 1.3 --- functions.py 23 Jul 2005 19:15:37 -0000 1.4 *************** *** 55,59 **** ! def FileOperation(fileaction, From, To, title='', hwnd=0, *flags): if fileaction not in FILEOPERATIONS: --- 55,59 ---- ! def FileOperation(fileaction, From, To, *flags, **kwargs): if fileaction not in FILEOPERATIONS: *************** *** 69,73 **** try: sho.fFlags=FO_FLAGS[i] except: raise "invalid flag: %s" % i ! sho.hwnd=hwnd if fileaction != 'delete': --- 69,73 ---- try: sho.fFlags=FO_FLAGS[i] except: raise "invalid flag: %s" % i ! sho.hwnd=kwargs.get('title', 0) if fileaction != 'delete': *************** *** 80,84 **** sho.pFrom='%s\x00' % '\x00'.join(From) else: sho.pFrom=From ! sho.lpszProgressTitle=title if shell32.SHFileOperation(byref(sho)): --- 80,84 ---- sho.pFrom='%s\x00' % '\x00'.join(From) else: sho.pFrom=From ! sho.lpszProgressTitle=kwargs.get('title', '') if shell32.SHFileOperation(byref(sho)): *************** *** 88,102 **** return True ! def MoveFiles(From, To, title='', hwnd=0, *flags): ! return FileOperation('move', From, To, title, hwnd, *flags) def CopyFiles(From, To, title='', hwnd=0, *flags): ! return FileOperation('copy', From, To, title, hwnd, *flags) ! def DeleteFiles(From, To, title='', hwnd=0, *flags): ! return FileOperation('delete', From, To, title, hwnd, *flags) ! def RenameFiles(From, To, title='', hwnd=0, *flags): ! return FileOperation('rename', From, To, title, hwnd, *flags) #********************************************************** --- 88,102 ---- return True ! def MoveFiles(From, To, title='', hwnd=0, *flags, **kwargs): ! return FileOperation('move', From, To, *flags, **kwargs) def CopyFiles(From, To, title='', hwnd=0, *flags): ! return FileOperation('copy', From, To, flags, kwargs) ! def DeleteFiles(From, To, title='', hwnd=0, *flags, **kwargs): ! return FileOperation('delete', From, To, flags, kwargs) ! def RenameFiles(From, To, title='', hwnd=0, *flags, **kwargs): ! return FileOperation('rename', From, To, *flags, **kwargs) #********************************************************** Index: __init__.py =================================================================== RCS file: /cvsroot/wnd/wnd/wnd/api/shell/__init__.py,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** __init__.py 2 Jul 2005 09:00:57 -0000 1.4 --- __init__.py 23 Jul 2005 19:15:37 -0000 1.5 *************** *** 7,11 **** from wnd.api.shell.contextmenu import ShellContextMenu from wnd.api.shell.shelllink import ShellLink - from wnd.api.shell.browseforfolder import BrowseForFolder from wnd.api.shell.wintypes import Malloc, HRESULT_CODE from wnd.api.shell.consts import * --- 7,10 ---- |