add the base .rbuild files
authorGed Murphy <gedmurphy@reactos.org>
Thu, 16 Feb 2006 23:32:18 +0000 (23:32 +0000)
committerGed Murphy <gedmurphy@reactos.org>
Thu, 16 Feb 2006 23:32:18 +0000 (23:32 +0000)
svn path=/trunk/; revision=21021

551 files changed:
reactos/ReactOS-ppc.rbuild [new file with mode: 0644]
reactos/ReactOS-ppc.xml [deleted file]
reactos/ReactOS.rbuild [new file with mode: 0644]
reactos/ReactOS.xml [deleted file]
reactos/apps/utils/getfirefox/De.rc [deleted file]
reactos/apps/utils/getfirefox/En.rc [deleted file]
reactos/apps/utils/getfirefox/Fr.rc [deleted file]
reactos/apps/utils/getfirefox/Hu.rc [deleted file]
reactos/apps/utils/getfirefox/firefox.ico [deleted file]
reactos/apps/utils/getfirefox/getfirefox.c [deleted file]
reactos/apps/utils/getfirefox/getfirefox.rc [deleted file]
reactos/apps/utils/getfirefox/getfirefox.xml [deleted file]
reactos/apps/utils/getfirefox/precomp.h [deleted file]
reactos/apps/utils/getfirefox/resource.h [deleted file]
reactos/apps/utils/net/arp/arp.c [deleted file]
reactos/apps/utils/net/arp/arp.rc [deleted file]
reactos/apps/utils/net/arp/arp.xml [deleted file]
reactos/apps/utils/net/directory.xml [deleted file]
reactos/apps/utils/net/finger/LICENSE.txt [deleted file]
reactos/apps/utils/net/finger/err.c [deleted file]
reactos/apps/utils/net/finger/err.h [deleted file]
reactos/apps/utils/net/finger/finger.c [deleted file]
reactos/apps/utils/net/finger/finger.rc [deleted file]
reactos/apps/utils/net/finger/finger.xml [deleted file]
reactos/apps/utils/net/finger/getopt.c [deleted file]
reactos/apps/utils/net/finger/getopt.h [deleted file]
reactos/apps/utils/net/finger/net.c [deleted file]
reactos/apps/utils/net/finger/various.h [deleted file]
reactos/apps/utils/net/ftp/cmds.c [deleted file]
reactos/apps/utils/net/ftp/cmdtab.c [deleted file]
reactos/apps/utils/net/ftp/domacro.c [deleted file]
reactos/apps/utils/net/ftp/fake.c [deleted file]
reactos/apps/utils/net/ftp/fake.h [deleted file]
reactos/apps/utils/net/ftp/ftp.c [deleted file]
reactos/apps/utils/net/ftp/ftp.mak [deleted file]
reactos/apps/utils/net/ftp/ftp.mak.orig [deleted file]
reactos/apps/utils/net/ftp/ftp.rc [deleted file]
reactos/apps/utils/net/ftp/ftp.xml [deleted file]
reactos/apps/utils/net/ftp/ftp_var.h [deleted file]
reactos/apps/utils/net/ftp/main.c [deleted file]
reactos/apps/utils/net/ftp/pathnames.h [deleted file]
reactos/apps/utils/net/ftp/prototypes.h [deleted file]
reactos/apps/utils/net/ftp/ruserpass.c [deleted file]
reactos/apps/utils/net/ipconfig/ipconfig.c [deleted file]
reactos/apps/utils/net/ipconfig/ipconfig.rc [deleted file]
reactos/apps/utils/net/ipconfig/ipconfig.xml [deleted file]
reactos/apps/utils/net/netstat/netstat.c [deleted file]
reactos/apps/utils/net/netstat/netstat.h [deleted file]
reactos/apps/utils/net/netstat/netstat.rc [deleted file]
reactos/apps/utils/net/netstat/netstat.xml [deleted file]
reactos/apps/utils/net/ping/ping.c [deleted file]
reactos/apps/utils/net/ping/ping.rc [deleted file]
reactos/apps/utils/net/ping/ping.xml [deleted file]
reactos/apps/utils/net/roshttpd/common/list.cpp [deleted file]
reactos/apps/utils/net/roshttpd/common/roshttpd.rc [deleted file]
reactos/apps/utils/net/roshttpd/common/socket.cpp [deleted file]
reactos/apps/utils/net/roshttpd/common/thread.cpp [deleted file]
reactos/apps/utils/net/roshttpd/config.cpp [deleted file]
reactos/apps/utils/net/roshttpd/error.cpp [deleted file]
reactos/apps/utils/net/roshttpd/http.cpp [deleted file]
reactos/apps/utils/net/roshttpd/httpd.cpp [deleted file]
reactos/apps/utils/net/roshttpd/include/config.h [deleted file]
reactos/apps/utils/net/roshttpd/include/debug.h [deleted file]
reactos/apps/utils/net/roshttpd/include/error.h [deleted file]
reactos/apps/utils/net/roshttpd/include/http.h [deleted file]
reactos/apps/utils/net/roshttpd/include/httpd.h [deleted file]
reactos/apps/utils/net/roshttpd/include/iterator.h [deleted file]
reactos/apps/utils/net/roshttpd/include/list.h [deleted file]
reactos/apps/utils/net/roshttpd/include/socket.h [deleted file]
reactos/apps/utils/net/roshttpd/include/thread.h [deleted file]
reactos/apps/utils/net/roshttpd/roshttpd.cpp [deleted file]
reactos/apps/utils/net/route/route.c [deleted file]
reactos/apps/utils/net/route/route.rc [deleted file]
reactos/apps/utils/net/route/route.xml [deleted file]
reactos/apps/utils/net/telnet/Makefile.mingw [deleted file]
reactos/apps/utils/net/telnet/doc/00readme.avs [deleted file]
reactos/apps/utils/net/telnet/doc/bugs.txt [deleted file]
reactos/apps/utils/net/telnet/doc/changes.txt [deleted file]
reactos/apps/utils/net/telnet/doc/license.txt [deleted file]
reactos/apps/utils/net/telnet/doc/options.txt [deleted file]
reactos/apps/utils/net/telnet/doc/readme.txt [deleted file]
reactos/apps/utils/net/telnet/doc/ssh.txt [deleted file]
reactos/apps/utils/net/telnet/resource/tnmsg.h [deleted file]
reactos/apps/utils/net/telnet/resource/tnmsg.rc [deleted file]
reactos/apps/utils/net/telnet/src/ansiprsr.cpp [deleted file]
reactos/apps/utils/net/telnet/src/ansiprsr.h [deleted file]
reactos/apps/utils/net/telnet/src/keytrans.cpp [deleted file]
reactos/apps/utils/net/telnet/src/keytrans.h [deleted file]
reactos/apps/utils/net/telnet/src/stl_bids.h [deleted file]
reactos/apps/utils/net/telnet/src/tcharmap.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tcharmap.h [deleted file]
reactos/apps/utils/net/telnet/src/tconsole.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tconsole.h [deleted file]
reactos/apps/utils/net/telnet/src/telnet.h [deleted file]
reactos/apps/utils/net/telnet/src/tkeydef.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tkeydef.h [deleted file]
reactos/apps/utils/net/telnet/src/tkeymap.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tkeymap.h [deleted file]
reactos/apps/utils/net/telnet/src/tmapldr.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tmapldr.h [deleted file]
reactos/apps/utils/net/telnet/src/tmouse.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tmouse.h [deleted file]
reactos/apps/utils/net/telnet/src/tnclass.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tnclass.h [deleted file]
reactos/apps/utils/net/telnet/src/tnclip.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tnclip.h [deleted file]
reactos/apps/utils/net/telnet/src/tncon.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tncon.h [deleted file]
reactos/apps/utils/net/telnet/src/tnconfig.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tnconfig.h [deleted file]
reactos/apps/utils/net/telnet/src/tnerror.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tnerror.h [deleted file]
reactos/apps/utils/net/telnet/src/tnetwork.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tnetwork.h [deleted file]
reactos/apps/utils/net/telnet/src/tnmain.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tnmain.h [deleted file]
reactos/apps/utils/net/telnet/src/tnmisc.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tnmisc.h [deleted file]
reactos/apps/utils/net/telnet/src/tnmsg.h [deleted file]
reactos/apps/utils/net/telnet/src/tparams.h [deleted file]
reactos/apps/utils/net/telnet/src/tparser.h [deleted file]
reactos/apps/utils/net/telnet/src/tscript.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tscript.h [deleted file]
reactos/apps/utils/net/telnet/src/tscroll.cpp [deleted file]
reactos/apps/utils/net/telnet/src/tscroll.h [deleted file]
reactos/apps/utils/net/telnet/src/ttelhndl.cpp [deleted file]
reactos/apps/utils/net/telnet/src/ttelhndl.h [deleted file]
reactos/apps/utils/net/telnet/telnet.cfg [deleted file]
reactos/apps/utils/net/telnet/telnet.ico [deleted file]
reactos/apps/utils/net/telnet/telnet.ini [deleted file]
reactos/apps/utils/net/telnet/telnet.rc [deleted file]
reactos/apps/utils/net/telnet/telnet.xml [deleted file]
reactos/apps/utils/net/tracert/tracert.c [deleted file]
reactos/apps/utils/net/tracert/tracert.h [deleted file]
reactos/apps/utils/net/tracert/tracert.rc [deleted file]
reactos/apps/utils/net/tracert/tracert.xml [deleted file]
reactos/apps/utils/net/whois/LICENSE.txt [deleted file]
reactos/apps/utils/net/whois/whois.c [deleted file]
reactos/apps/utils/net/whois/whois.rc [deleted file]
reactos/apps/utils/net/whois/whois.xml [deleted file]
reactos/base/applications/shutdown/shutdown.c [moved from reactos/apps/utils/shutdown/shutdown.c with 100% similarity]
reactos/base/applications/shutdown/shutdown.xml [moved from reactos/apps/utils/shutdown/shutdown.xml with 100% similarity]
reactos/baseaddress.rbuild [new file with mode: 0644]
reactos/baseaddress.xml [deleted file]
reactos/config.template.rbuild [moved from reactos/config.template.xml with 89% similarity]
reactos/services/tcpsvcs/chargen.c [deleted file]
reactos/services/tcpsvcs/daytime.c [deleted file]
reactos/services/tcpsvcs/discard.c [deleted file]
reactos/services/tcpsvcs/echo.c [deleted file]
reactos/services/tcpsvcs/qotd.c [deleted file]
reactos/services/tcpsvcs/quotes [deleted file]
reactos/services/tcpsvcs/skelserver.c [deleted file]
reactos/services/tcpsvcs/tcpsvcs.c [deleted file]
reactos/services/tcpsvcs/tcpsvcs.h [deleted file]
reactos/services/tcpsvcs/tcpsvcs.rc [deleted file]
reactos/services/tcpsvcs/tcpsvcs.xml [deleted file]
reactos/subsys/system/cmd/De.rc [deleted file]
reactos/subsys/system/cmd/En.rc [deleted file]
reactos/subsys/system/cmd/Es.rc [deleted file]
reactos/subsys/system/cmd/Fr.rc [deleted file]
reactos/subsys/system/cmd/Hu.rc [deleted file]
reactos/subsys/system/cmd/Ja.rc [deleted file]
reactos/subsys/system/cmd/Ru.rc [deleted file]
reactos/subsys/system/cmd/alias.c [deleted file]
reactos/subsys/system/cmd/attrib.c [deleted file]
reactos/subsys/system/cmd/batch.c [deleted file]
reactos/subsys/system/cmd/batch.h [deleted file]
reactos/subsys/system/cmd/beep.c [deleted file]
reactos/subsys/system/cmd/call.c [deleted file]
reactos/subsys/system/cmd/chcp.c [deleted file]
reactos/subsys/system/cmd/choice.c [deleted file]
reactos/subsys/system/cmd/cls.c [deleted file]
reactos/subsys/system/cmd/cmd.c [deleted file]
reactos/subsys/system/cmd/cmd.h [deleted file]
reactos/subsys/system/cmd/cmd.rc [deleted file]
reactos/subsys/system/cmd/cmd.xml [deleted file]
reactos/subsys/system/cmd/cmdinput.c [deleted file]
reactos/subsys/system/cmd/cmdtable.c [deleted file]
reactos/subsys/system/cmd/cmdver.h [deleted file]
reactos/subsys/system/cmd/color.c [deleted file]
reactos/subsys/system/cmd/config.h [deleted file]
reactos/subsys/system/cmd/console.c [deleted file]
reactos/subsys/system/cmd/copy.c [deleted file]
reactos/subsys/system/cmd/date.c [deleted file]
reactos/subsys/system/cmd/del.c [deleted file]
reactos/subsys/system/cmd/delay.c [deleted file]
reactos/subsys/system/cmd/dir.c [deleted file]
reactos/subsys/system/cmd/dirstack.c [deleted file]
reactos/subsys/system/cmd/echo.c [deleted file]
reactos/subsys/system/cmd/error.c [deleted file]
reactos/subsys/system/cmd/filecomp.c [deleted file]
reactos/subsys/system/cmd/files.txt [deleted file]
reactos/subsys/system/cmd/for.c [deleted file]
reactos/subsys/system/cmd/free.c [deleted file]
reactos/subsys/system/cmd/goto.c [deleted file]
reactos/subsys/system/cmd/history.c [deleted file]
reactos/subsys/system/cmd/history.txt [deleted file]
reactos/subsys/system/cmd/if.c [deleted file]
reactos/subsys/system/cmd/internal.c [deleted file]
reactos/subsys/system/cmd/label.c [deleted file]
reactos/subsys/system/cmd/license.txt [deleted file]
reactos/subsys/system/cmd/locale.c [deleted file]
reactos/subsys/system/cmd/main.c [deleted file]
reactos/subsys/system/cmd/memory.c [deleted file]
reactos/subsys/system/cmd/misc.c [deleted file]
reactos/subsys/system/cmd/move.c [deleted file]
reactos/subsys/system/cmd/msgbox.c [deleted file]
reactos/subsys/system/cmd/path.c [deleted file]
reactos/subsys/system/cmd/pause.c [deleted file]
reactos/subsys/system/cmd/precomp.h [deleted file]
reactos/subsys/system/cmd/prompt.c [deleted file]
reactos/subsys/system/cmd/readme.txt [deleted file]
reactos/subsys/system/cmd/readme2.txt [deleted file]
reactos/subsys/system/cmd/redir.c [deleted file]
reactos/subsys/system/cmd/ren.c [deleted file]
reactos/subsys/system/cmd/res/terminal.ico [deleted file]
reactos/subsys/system/cmd/resource.h [deleted file]
reactos/subsys/system/cmd/screen.c [deleted file]
reactos/subsys/system/cmd/set.c [deleted file]
reactos/subsys/system/cmd/seta_test.cmd [deleted file]
reactos/subsys/system/cmd/shift.c [deleted file]
reactos/subsys/system/cmd/start.c [deleted file]
reactos/subsys/system/cmd/strtoclr.c [deleted file]
reactos/subsys/system/cmd/tests/cmd_test.xml [deleted file]
reactos/subsys/system/cmd/tests/setup.c [deleted file]
reactos/subsys/system/cmd/tests/stubs.xml [deleted file]
reactos/subsys/system/cmd/time.c [deleted file]
reactos/subsys/system/cmd/timer.c [deleted file]
reactos/subsys/system/cmd/title.c [deleted file]
reactos/subsys/system/cmd/todo.txt [deleted file]
reactos/subsys/system/cmd/type.c [deleted file]
reactos/subsys/system/cmd/ver.c [deleted file]
reactos/subsys/system/cmd/verify.c [deleted file]
reactos/subsys/system/cmd/vol.c [deleted file]
reactos/subsys/system/cmd/where.c [deleted file]
reactos/subsys/system/cmd/window.c [deleted file]
reactos/subsys/system/devmgr/devmgr.c [deleted file]
reactos/subsys/system/devmgr/devmgr.rc [deleted file]
reactos/subsys/system/devmgr/devmgrapp.xml [deleted file]
reactos/subsys/system/explorer/Doxyfile [deleted file]
reactos/subsys/system/explorer/Doxyfile-all [deleted file]
reactos/subsys/system/explorer/Jamfile [deleted file]
reactos/subsys/system/explorer/Make-rosshell.MinGW [deleted file]
reactos/subsys/system/explorer/Make-rosshell.mak [deleted file]
reactos/subsys/system/explorer/Makefile.MinGW [deleted file]
reactos/subsys/system/explorer/Makefile.PCH [deleted file]
reactos/subsys/system/explorer/Makefile.Wine [deleted file]
reactos/subsys/system/explorer/desktop/desktop.cpp [deleted file]
reactos/subsys/system/explorer/desktop/desktop.h [deleted file]
reactos/subsys/system/explorer/dialogs/searchprogram.cpp [deleted file]
reactos/subsys/system/explorer/dialogs/searchprogram.h [deleted file]
reactos/subsys/system/explorer/dialogs/settings.cpp [deleted file]
reactos/subsys/system/explorer/dialogs/settings.h [deleted file]
reactos/subsys/system/explorer/doc/TODO.txt [deleted file]
reactos/subsys/system/explorer/doc/changes.txt [deleted file]
reactos/subsys/system/explorer/doc/readme.txt [deleted file]
reactos/subsys/system/explorer/doxy-footer.html [deleted file]
reactos/subsys/system/explorer/doxy-footer.htmt [deleted file]
reactos/subsys/system/explorer/expat.license [deleted file]
reactos/subsys/system/explorer/explorer-cfg-template.xml [deleted file]
reactos/subsys/system/explorer/explorer-cn.rc [deleted file]
reactos/subsys/system/explorer/explorer-cz.rc [deleted file]
reactos/subsys/system/explorer/explorer-de.rc [deleted file]
reactos/subsys/system/explorer/explorer-en.rc [deleted file]
reactos/subsys/system/explorer/explorer-es.rc [deleted file]
reactos/subsys/system/explorer/explorer-fr.rc [deleted file]
reactos/subsys/system/explorer/explorer-hu.rc [deleted file]
reactos/subsys/system/explorer/explorer-jp.rc [deleted file]
reactos/subsys/system/explorer/explorer-pl.rc [deleted file]
reactos/subsys/system/explorer/explorer-pt.rc [deleted file]
reactos/subsys/system/explorer/explorer-ro.rc [deleted file]
reactos/subsys/system/explorer/explorer-ru.rc [deleted file]
reactos/subsys/system/explorer/explorer-sv.rc [deleted file]
reactos/subsys/system/explorer/explorer-uk.rc [deleted file]
reactos/subsys/system/explorer/explorer.cpp [deleted file]
reactos/subsys/system/explorer/explorer.dsp [deleted file]
reactos/subsys/system/explorer/explorer.dsw [deleted file]
reactos/subsys/system/explorer/explorer.exe.manifest [deleted file]
reactos/subsys/system/explorer/explorer.h [deleted file]
reactos/subsys/system/explorer/explorer.rc [deleted file]
reactos/subsys/system/explorer/explorer.sln [deleted file]
reactos/subsys/system/explorer/explorer.vcproj [deleted file]
reactos/subsys/system/explorer/explorer.xml [deleted file]
reactos/subsys/system/explorer/explorer_intres.rc [deleted file]
reactos/subsys/system/explorer/externals.h [deleted file]
reactos/subsys/system/explorer/globals.h [deleted file]
reactos/subsys/system/explorer/i386-stub-win32.c [deleted file]
reactos/subsys/system/explorer/make-docu.sh [deleted file]
reactos/subsys/system/explorer/make-full-docu.bat [deleted file]
reactos/subsys/system/explorer/make_explorer.dsp [deleted file]
reactos/subsys/system/explorer/make_explorer.vcproj [deleted file]
reactos/subsys/system/explorer/make_rosshell.dsp [deleted file]
reactos/subsys/system/explorer/notifyhook/notifyhook.c [deleted file]
reactos/subsys/system/explorer/notifyhook/notifyhook.def [deleted file]
reactos/subsys/system/explorer/notifyhook/notifyhook.dsp [deleted file]
reactos/subsys/system/explorer/notifyhook/notifyhook.h [deleted file]
reactos/subsys/system/explorer/notifyhook/notifyhook.rc [deleted file]
reactos/subsys/system/explorer/notifyhook/notifyhook.vcproj [deleted file]
reactos/subsys/system/explorer/notifyhook/notifyhook.xml [deleted file]
reactos/subsys/system/explorer/precomp.cpp [deleted file]
reactos/subsys/system/explorer/precomp.h [deleted file]
reactos/subsys/system/explorer/project-root.jam [deleted file]
reactos/subsys/system/explorer/rc-mingw.jam [deleted file]
reactos/subsys/system/explorer/res/action.ico [deleted file]
reactos/subsys/system/explorer/res/administration.ico [deleted file]
reactos/subsys/system/explorer/res/appicon.ico [deleted file]
reactos/subsys/system/explorer/res/apps.ico [deleted file]
reactos/subsys/system/explorer/res/arrow.ico [deleted file]
reactos/subsys/system/explorer/res/arrow_dwn.ico [deleted file]
reactos/subsys/system/explorer/res/arrow_up.ico [deleted file]
reactos/subsys/system/explorer/res/arrowsel.ico [deleted file]
reactos/subsys/system/explorer/res/computer.ico [deleted file]
reactos/subsys/system/explorer/res/config.ico [deleted file]
reactos/subsys/system/explorer/res/control-panel.ico [deleted file]
reactos/subsys/system/explorer/res/desktop-settings.ico [deleted file]
reactos/subsys/system/explorer/res/documents.ico [deleted file]
reactos/subsys/system/explorer/res/dot.ico [deleted file]
reactos/subsys/system/explorer/res/dot_red.ico [deleted file]
reactos/subsys/system/explorer/res/dot_trans.ico [deleted file]
reactos/subsys/system/explorer/res/drivebar.bmp [deleted file]
reactos/subsys/system/explorer/res/explorer.ico [deleted file]
reactos/subsys/system/explorer/res/favorites.ico [deleted file]
reactos/subsys/system/explorer/res/floating.ico [deleted file]
reactos/subsys/system/explorer/res/folder.ico [deleted file]
reactos/subsys/system/explorer/res/icoali10.bmp [deleted file]
reactos/subsys/system/explorer/res/icoalig0.bmp [deleted file]
reactos/subsys/system/explorer/res/icoalig1.bmp [deleted file]
reactos/subsys/system/explorer/res/icoalig2.bmp [deleted file]
reactos/subsys/system/explorer/res/icoalig3.bmp [deleted file]
reactos/subsys/system/explorer/res/icoalig4.bmp [deleted file]
reactos/subsys/system/explorer/res/icoalig5.bmp [deleted file]
reactos/subsys/system/explorer/res/icoalig6.bmp [deleted file]
reactos/subsys/system/explorer/res/icoalig7.bmp [deleted file]
reactos/subsys/system/explorer/res/icoalig8.bmp [deleted file]
reactos/subsys/system/explorer/res/icoalig9.bmp [deleted file]
reactos/subsys/system/explorer/res/images.bmp [deleted file]
reactos/subsys/system/explorer/res/info.ico [deleted file]
reactos/subsys/system/explorer/res/logoff.ico [deleted file]
reactos/subsys/system/explorer/res/logov.bmp [deleted file]
reactos/subsys/system/explorer/res/logov16.bmp [deleted file]
reactos/subsys/system/explorer/res/logov256.bmp [deleted file]
reactos/subsys/system/explorer/res/mdi.bmp [deleted file]
reactos/subsys/system/explorer/res/minimize.ico [deleted file]
reactos/subsys/system/explorer/res/network-conns.ico [deleted file]
reactos/subsys/system/explorer/res/network.ico [deleted file]
reactos/subsys/system/explorer/res/notify_l.ico [deleted file]
reactos/subsys/system/explorer/res/notify_r.ico [deleted file]
reactos/subsys/system/explorer/res/printer.ico [deleted file]
reactos/subsys/system/explorer/res/reactos.ico [deleted file]
reactos/subsys/system/explorer/res/recent-documents.ico [deleted file]
reactos/subsys/system/explorer/res/ros-big.ico [deleted file]
reactos/subsys/system/explorer/res/sdi.bmp [deleted file]
reactos/subsys/system/explorer/res/search-doc.ico [deleted file]
reactos/subsys/system/explorer/res/search.ico [deleted file]
reactos/subsys/system/explorer/res/shutdown.ico [deleted file]
reactos/subsys/system/explorer/res/speaker.ico [deleted file]
reactos/subsys/system/explorer/res/startmenu.ico [deleted file]
reactos/subsys/system/explorer/res/toolbar.bmp [deleted file]
reactos/subsys/system/explorer/res/winefile.ico [deleted file]
reactos/subsys/system/explorer/resource.h [deleted file]
reactos/subsys/system/explorer/rosshell.dsp [deleted file]
reactos/subsys/system/explorer/rosshell.dsw [deleted file]
reactos/subsys/system/explorer/services/shellservices.cpp [deleted file]
reactos/subsys/system/explorer/services/shellservices.h [deleted file]
reactos/subsys/system/explorer/services/startup.c [deleted file]
reactos/subsys/system/explorer/shell/entries.cpp [deleted file]
reactos/subsys/system/explorer/shell/entries.h [deleted file]
reactos/subsys/system/explorer/shell/fatfs.cpp [deleted file]
reactos/subsys/system/explorer/shell/fatfs.h [deleted file]
reactos/subsys/system/explorer/shell/filechild.cpp [deleted file]
reactos/subsys/system/explorer/shell/filechild.h [deleted file]
reactos/subsys/system/explorer/shell/mainframe.cpp [deleted file]
reactos/subsys/system/explorer/shell/mainframe.h [deleted file]
reactos/subsys/system/explorer/shell/ntobjfs.cpp [deleted file]
reactos/subsys/system/explorer/shell/ntobjfs.h [deleted file]
reactos/subsys/system/explorer/shell/pane.cpp [deleted file]
reactos/subsys/system/explorer/shell/pane.h [deleted file]
reactos/subsys/system/explorer/shell/regfs.cpp [deleted file]
reactos/subsys/system/explorer/shell/regfs.h [deleted file]
reactos/subsys/system/explorer/shell/shellbrowser.cpp [deleted file]
reactos/subsys/system/explorer/shell/shellbrowser.h [deleted file]
reactos/subsys/system/explorer/shell/shellfs.cpp [deleted file]
reactos/subsys/system/explorer/shell/shellfs.h [deleted file]
reactos/subsys/system/explorer/shell/unixfs.cpp [deleted file]
reactos/subsys/system/explorer/shell/unixfs.h [deleted file]
reactos/subsys/system/explorer/shell/webchild.cpp [deleted file]
reactos/subsys/system/explorer/shell/webchild.h [deleted file]
reactos/subsys/system/explorer/shell/winfs.cpp [deleted file]
reactos/subsys/system/explorer/shell/winfs.h [deleted file]
reactos/subsys/system/explorer/taskbar/desktopbar.cpp [deleted file]
reactos/subsys/system/explorer/taskbar/desktopbar.h [deleted file]
reactos/subsys/system/explorer/taskbar/favorites.cpp [deleted file]
reactos/subsys/system/explorer/taskbar/favorites.h [deleted file]
reactos/subsys/system/explorer/taskbar/quicklaunch.cpp [deleted file]
reactos/subsys/system/explorer/taskbar/quicklaunch.h [deleted file]
reactos/subsys/system/explorer/taskbar/startmenu.cpp [deleted file]
reactos/subsys/system/explorer/taskbar/startmenu.h [deleted file]
reactos/subsys/system/explorer/taskbar/taskbar.cpp [deleted file]
reactos/subsys/system/explorer/taskbar/taskbar.h [deleted file]
reactos/subsys/system/explorer/taskbar/traynotify.cpp [deleted file]
reactos/subsys/system/explorer/taskbar/traynotify.h [deleted file]
reactos/subsys/system/explorer/utility/dragdropimpl.cpp [deleted file]
reactos/subsys/system/explorer/utility/dragdropimpl.h [deleted file]
reactos/subsys/system/explorer/utility/shellbrowserimpl.cpp [deleted file]
reactos/subsys/system/explorer/utility/shellbrowserimpl.h [deleted file]
reactos/subsys/system/explorer/utility/shellclasses.cpp [deleted file]
reactos/subsys/system/explorer/utility/shellclasses.dsp [deleted file]
reactos/subsys/system/explorer/utility/shellclasses.dsw [deleted file]
reactos/subsys/system/explorer/utility/shellclasses.h [deleted file]
reactos/subsys/system/explorer/utility/shelltests.cpp [deleted file]
reactos/subsys/system/explorer/utility/splitpath.c [deleted file]
reactos/subsys/system/explorer/utility/treedroptarget.h [deleted file]
reactos/subsys/system/explorer/utility/utility.cpp [deleted file]
reactos/subsys/system/explorer/utility/utility.h [deleted file]
reactos/subsys/system/explorer/utility/window.cpp [deleted file]
reactos/subsys/system/explorer/utility/window.h [deleted file]
reactos/subsys/system/explorer/utility/xmlstorage.cpp [deleted file]
reactos/subsys/system/explorer/utility/xmlstorage.h [deleted file]
reactos/subsys/system/hostname/hostname.c [deleted file]
reactos/subsys/system/hostname/hostname.rc [deleted file]
reactos/subsys/system/hostname/hostname.xml [deleted file]
reactos/subsys/system/ibrowser/De.rc [deleted file]
reactos/subsys/system/ibrowser/En.rc [deleted file]
reactos/subsys/system/ibrowser/Es.rc [deleted file]
reactos/subsys/system/ibrowser/Fr.rc [deleted file]
reactos/subsys/system/ibrowser/Hu.rc [deleted file]
reactos/subsys/system/ibrowser/Ja.rc [deleted file]
reactos/subsys/system/ibrowser/Makefile.MinGW [deleted file]
reactos/subsys/system/ibrowser/Makefile.PCH [deleted file]
reactos/subsys/system/ibrowser/Ro.rc [deleted file]
reactos/subsys/system/ibrowser/Sv.rc [deleted file]
reactos/subsys/system/ibrowser/expat.license [deleted file]
reactos/subsys/system/ibrowser/favorites.cpp [deleted file]
reactos/subsys/system/ibrowser/favorites.h [deleted file]
reactos/subsys/system/ibrowser/ibrowser.cpp [deleted file]
reactos/subsys/system/ibrowser/ibrowser.dsp [deleted file]
reactos/subsys/system/ibrowser/ibrowser.dsw [deleted file]
reactos/subsys/system/ibrowser/ibrowser.h [deleted file]
reactos/subsys/system/ibrowser/ibrowser.rc [deleted file]
reactos/subsys/system/ibrowser/ibrowser.xml [deleted file]
reactos/subsys/system/ibrowser/ibrowser_intres.h [deleted file]
reactos/subsys/system/ibrowser/ibrowser_intres.rc [deleted file]
reactos/subsys/system/ibrowser/mainframe.cpp [deleted file]
reactos/subsys/system/ibrowser/mainframe.h [deleted file]
reactos/subsys/system/ibrowser/make_ibrowser.dsp [deleted file]
reactos/subsys/system/ibrowser/precomp.cpp [deleted file]
reactos/subsys/system/ibrowser/precomp.h [deleted file]
reactos/subsys/system/ibrowser/readme.txt [deleted file]
reactos/subsys/system/ibrowser/res/dot.ico [deleted file]
reactos/subsys/system/ibrowser/res/dot_red.ico [deleted file]
reactos/subsys/system/ibrowser/res/dot_trans.ico [deleted file]
reactos/subsys/system/ibrowser/res/favorites.ico [deleted file]
reactos/subsys/system/ibrowser/res/ibrowser.ico [deleted file]
reactos/subsys/system/ibrowser/res/network.ico [deleted file]
reactos/subsys/system/ibrowser/res/reactos.ico [deleted file]
reactos/subsys/system/ibrowser/res/toolbar.bmp [deleted file]
reactos/subsys/system/ibrowser/utility/comutil.h [deleted file]
reactos/subsys/system/ibrowser/utility/utility.cpp [deleted file]
reactos/subsys/system/ibrowser/utility/utility.h [deleted file]
reactos/subsys/system/ibrowser/utility/window.cpp [deleted file]
reactos/subsys/system/ibrowser/utility/window.h [deleted file]
reactos/subsys/system/ibrowser/utility/xmlstorage.cpp [deleted file]
reactos/subsys/system/ibrowser/utility/xmlstorage.h [deleted file]
reactos/subsys/system/ibrowser/webchild.cpp [deleted file]
reactos/subsys/system/ibrowser/webchild.h [deleted file]
reactos/subsys/system/msconfig/De.rc [deleted file]
reactos/subsys/system/msconfig/En.rc [deleted file]
reactos/subsys/system/msconfig/Fr.rc [deleted file]
reactos/subsys/system/msconfig/Hu.rc [deleted file]
reactos/subsys/system/msconfig/freeldrpage.c [deleted file]
reactos/subsys/system/msconfig/freeldrpage.h [deleted file]
reactos/subsys/system/msconfig/generalpage.c [deleted file]
reactos/subsys/system/msconfig/generalpage.h [deleted file]
reactos/subsys/system/msconfig/msconfig.c [deleted file]
reactos/subsys/system/msconfig/msconfig.h [deleted file]
reactos/subsys/system/msconfig/msconfig.rc [deleted file]
reactos/subsys/system/msconfig/msconfig.xml [deleted file]
reactos/subsys/system/msconfig/precomp.h [deleted file]
reactos/subsys/system/msconfig/resource.h [deleted file]
reactos/subsys/system/msconfig/srvpage.c [deleted file]
reactos/subsys/system/msconfig/srvpage.h [deleted file]
reactos/subsys/system/msconfig/startuppage.c [deleted file]
reactos/subsys/system/msconfig/startuppage.h [deleted file]
reactos/subsys/system/msconfig/systempage.c [deleted file]
reactos/subsys/system/msconfig/systempage.h [deleted file]
reactos/subsys/system/msconfig/toolspage.c [deleted file]
reactos/subsys/system/msconfig/toolspage.h [deleted file]
reactos/subsys/system/sc/control.c [deleted file]
reactos/subsys/system/sc/create.c [deleted file]
reactos/subsys/system/sc/delete.c [deleted file]
reactos/subsys/system/sc/query.c [deleted file]
reactos/subsys/system/sc/sc.c [deleted file]
reactos/subsys/system/sc/sc.h [deleted file]
reactos/subsys/system/sc/sc.rc [deleted file]
reactos/subsys/system/sc/sc.xml [deleted file]
reactos/subsys/system/sc/start.c [deleted file]
reactos/subsys/system/sc/usage.c [deleted file]
reactos/subsys/system/servman/De.rc [deleted file]
reactos/subsys/system/servman/En.rc [deleted file]
reactos/subsys/system/servman/about.c [deleted file]
reactos/subsys/system/servman/control.c [deleted file]
reactos/subsys/system/servman/geterror.c [deleted file]
reactos/subsys/system/servman/progress.c [deleted file]
reactos/subsys/system/servman/propsheet.c [deleted file]
reactos/subsys/system/servman/query.c [deleted file]
reactos/subsys/system/servman/res/system.ico [deleted file]
reactos/subsys/system/servman/res/toolbar.bmp [deleted file]
reactos/subsys/system/servman/resource.h [deleted file]
reactos/subsys/system/servman/servman.c [deleted file]
reactos/subsys/system/servman/servman.h [deleted file]
reactos/subsys/system/servman/servman.rc [deleted file]
reactos/subsys/system/servman/servman.xml [deleted file]
reactos/subsys/system/servman/start.c [deleted file]
reactos/subsys/system/setup/setup.c [deleted file]
reactos/subsys/system/setup/setup.rc [deleted file]
reactos/subsys/system/setup/setup.xml [deleted file]
reactos/subsys/system/winefile/Doxyfile [deleted file]
reactos/subsys/system/winefile/Makefile.MinGW [deleted file]
reactos/subsys/system/winefile/Sv.rc [deleted file]
reactos/subsys/system/winefile/cs.rc [deleted file]
reactos/subsys/system/winefile/de.rc [deleted file]
reactos/subsys/system/winefile/doxy-footer.html [deleted file]
reactos/subsys/system/winefile/doxy-footer.htmt [deleted file]
reactos/subsys/system/winefile/drivebar.bmp [deleted file]
reactos/subsys/system/winefile/en.rc [deleted file]
reactos/subsys/system/winefile/es.rc [deleted file]
reactos/subsys/system/winefile/fr.rc [deleted file]
reactos/subsys/system/winefile/hu.rc [deleted file]
reactos/subsys/system/winefile/images.bmp [deleted file]
reactos/subsys/system/winefile/it.rc [deleted file]
reactos/subsys/system/winefile/license.c [deleted file]
reactos/subsys/system/winefile/make-docu.sh [deleted file]
reactos/subsys/system/winefile/make_winefile.dsp [deleted file]
reactos/subsys/system/winefile/makel-docu.bat [deleted file]
reactos/subsys/system/winefile/nl.rc [deleted file]
reactos/subsys/system/winefile/pl.rc [deleted file]
reactos/subsys/system/winefile/pt.rc [deleted file]
reactos/subsys/system/winefile/resource.h [deleted file]
reactos/subsys/system/winefile/resource.rc [deleted file]
reactos/subsys/system/winefile/ru.rc [deleted file]
reactos/subsys/system/winefile/si.rc [deleted file]
reactos/subsys/system/winefile/splitpath.c [deleted file]
reactos/subsys/system/winefile/toolbar.bmp [deleted file]
reactos/subsys/system/winefile/winefile.c [deleted file]
reactos/subsys/system/winefile/winefile.dsp [deleted file]
reactos/subsys/system/winefile/winefile.dsw [deleted file]
reactos/subsys/system/winefile/winefile.h [deleted file]
reactos/subsys/system/winefile/winefile.ico [deleted file]
reactos/subsys/system/winefile/winefile.rc [deleted file]
reactos/subsys/system/winefile/winefile.xml [deleted file]
reactos/subsys/system/winefile/zh.rc [deleted file]

diff --git a/reactos/ReactOS-ppc.rbuild b/reactos/ReactOS-ppc.rbuild
new file mode 100644 (file)
index 0000000..497ae75
--- /dev/null
@@ -0,0 +1,88 @@
+<?xml version="1.0"?>\r
+<!DOCTYPE project SYSTEM "tools/rbuild/project.dtd">\r
+<project name="ReactOS" makefile="makefile.ppc" xmlns:xi="http://www.w3.org/2001/XInclude">\r
+  <xi:include href="config-ppc.rbuild">\r
+    <xi:fallback>\r
+      <xi:include href="config.template.rbuild" />\r
+    </xi:fallback>\r
+  </xi:include>\r
+\r
+  <xi:include href="baseaddress.rbuild" />\r
+\r
+  <property name="BOOTPROG_PREPARE" value="ppc-le2be" />\r
+  <property name="BOOTPROG_FLATFORMAT" value="-O elf32-powerpc -B powerpc:common" />\r
+  <property name="BOOTPROG_LINKFORMAT" value="-melf32ppc --no-omagic -Ttext 0xe00000 -Tdata 0xe10000" />\r
+  <property name="BOOTPROG_COPYFORMAT" value="--only-section=.text --only-section=.data --only-section=.bss -O aixcoff-rs6000" />\r
+\r
+  <define name="_M_PPC" />\r
+  <define name="_PPC_" />\r
+  <define name="__PowerPC__" />\r
+  <define name="_REACTOS_" />\r
+  <define name="__MINGW_IMPORT" empty="true" />\r
+  <define name="__restrict__" empty="true" />\r
+  <compilerflag>-v</compilerflag>\r
+  <if property="MP" value="1">\r
+    <define name="CONFIG_SMP" value="1" />\r
+  </if>\r
+  <if property="DBG" value="1">\r
+    <define name="DBG" value="1" />\r
+    <property name="DBG_OR_KDBG" value="true" />\r
+  </if>\r
+  <if property="DBG" value="0">\r
+    <compilerflag>-Os</compilerflag>\r
+    <compilerflag>-Wno-strict-aliasing</compilerflag>\r
+  </if>\r
+  <if property="KDBG" value="1">\r
+    <define name="KDBG" value="1" />\r
+    <property name="DBG_OR_KDBG" value="true" />\r
+  </if>\r
+  <compilerflag>-Wpointer-arith</compilerflag>\r
+\r
+  <include>.</include>\r
+  <include>include</include>\r
+  <include>include/reactos</include>\r
+  <include>include/libs</include>\r
+  <include>include/drivers</include>\r
+  <include>include/subsys</include>\r
+  <include>include/ndk</include>\r
+  <include>w32api/include</include>\r
+  <include>w32api/include/crt</include>\r
+  <include>w32api/include/ddk</include>\r
+\r
+  <directory name="apps">\r
+    <xi:include href="apps/directory.rbuild" />\r
+  </directory>\r
+  <directory name="boot">\r
+    <xi:include href="boot/boot.rbuild" />\r
+  </directory>\r
+  <directory name="drivers">\r
+    <xi:include href="drivers/directory.rbuild" />\r
+  </directory>\r
+  <directory name="hal">\r
+    <xi:include href="hal/directory.rbuild" />\r
+  </directory>\r
+  <directory name="include">\r
+    <xi:include href="include/directory.rbuild" />\r
+  </directory>\r
+  <directory name="lib">\r
+    <xi:include href="lib/directory.rbuild" />\r
+  </directory>\r
+  <directory name="media">\r
+    <xi:include href="media/directory.rbuild" />\r
+  </directory>\r
+  <directory name="modules">\r
+    <xi:include href="modules/directory.rbuild" />\r
+  </directory>\r
+  <directory name="ntoskrnl">\r
+    <xi:include href="ntoskrnl/ntoskrnl.rbuild" />\r
+  </directory>\r
+  <directory name="regtests">\r
+    <xi:include href="regtests/directory.rbuild" />\r
+  </directory>\r
+  <directory name="services">\r
+    <xi:include href="services/directory.rbuild" />\r
+  </directory>\r
+  <directory name="subsys">\r
+    <xi:include href="subsys/directory.rbuild" />\r
+  </directory>\r
+</project>\r
diff --git a/reactos/ReactOS-ppc.xml b/reactos/ReactOS-ppc.xml
deleted file mode 100644 (file)
index a0fc78c..0000000
+++ /dev/null
@@ -1,91 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE project SYSTEM "tools/rbuild/project.dtd">
-<project name="ReactOS" makefile="makefile.ppc" xmlns:xi="http://www.w3.org/2001/XInclude">
-       <xi:include href="config-ppc.xml">
-               <xi:fallback>
-                       <xi:include href="config.template.xml" />
-               </xi:fallback>
-       </xi:include>
-
-       <xi:include href="baseaddress.xml" />
-
-       <property name="BOOTPROG_PREPARE" value="ppc-le2be" />
-       <property name="BOOTPROG_FLATFORMAT" value="-O elf32-powerpc -B powerpc:common" />
-       <property name="BOOTPROG_LINKFORMAT" value="-melf32ppc --no-omagic -Ttext 0xe00000 -Tdata 0xe10000" />
-       <property name="BOOTPROG_COPYFORMAT" value="--only-section=.text --only-section=.data --only-section=.bss -O aixcoff-rs6000" />
-
-       <define name="_M_PPC" />
-       <define name="_PPC_" />
-       <define name="__PowerPC__" />
-       <define name="_REACTOS_" />
-       <define name="__MINGW_IMPORT" empty="true" />
-       <define name="__restrict__" empty="true" />
-       <compilerflag>-v</compilerflag>
-       <if property="MP" value="1">
-               <define name="CONFIG_SMP" value="1" />
-       </if>
-       <if property="DBG" value="1">
-               <define name="DBG" value="1" />
-               <property name="DBG_OR_KDBG" value="true" />
-       </if>
-       <if property="DBG" value="0">
-               <compilerflag>-Os</compilerflag>
-               <compilerflag>-Wno-strict-aliasing</compilerflag>
-       </if>
-       <if property="KDBG" value="1">
-               <define name="KDBG" value="1" />
-               <property name="DBG_OR_KDBG" value="true" />
-       </if>
-       <compilerflag>-Wpointer-arith</compilerflag>
-
-       <include>.</include>
-       <include>include</include>
-       <include>include/reactos</include>
-       <include>include/libs</include>
-       <include>include/drivers</include>
-       <include>include/subsys</include>
-       <include>include/ndk</include>
-       <include>w32api/include</include>
-       <include>w32api/include/crt</include>
-       <include>w32api/include/ddk</include>
-
-       <directory name="apps">
-               <xi:include href="apps/directory.xml" />
-       </directory>
-       <directory name="boot">
-               <xi:include href="boot/boot.xml" />
-       </directory>
-       <directory name="bootdata">
-               <xi:include href="bootdata/bootdata.xml" />
-       </directory>
-       <directory name="drivers">
-               <xi:include href="drivers/directory.xml" />
-       </directory>
-       <directory name="hal">
-               <xi:include href="hal/directory.xml" />
-       </directory>
-       <directory name="include">
-               <xi:include href="include/directory.xml" />
-       </directory>
-       <directory name="lib">
-               <xi:include href="lib/directory.xml" />
-       </directory>
-       <directory name="media">
-               <xi:include href="media/directory.xml" />
-       </directory>
-       <directory name="modules">
-               <xi:include href="modules/directory.xml" />
-       </directory>
-       <directory name="ntoskrnl">
-               <xi:include href="ntoskrnl/ntoskrnl.xml" />
-       </directory>
-       <directory name="regtests">
-               <xi:include href="regtests/directory.xml" />
-       </directory>
-       <directory name="services">
-               <xi:include href="services/directory.xml" />
-       </directory>
-       <directory name="subsys">
-               <xi:include href="subsys/directory.xml" />
-       </directory>
-</project>
diff --git a/reactos/ReactOS.rbuild b/reactos/ReactOS.rbuild
new file mode 100644 (file)
index 0000000..f9bac1c
--- /dev/null
@@ -0,0 +1,94 @@
+<?xml version="1.0"?>\r
+<!DOCTYPE project SYSTEM "tools/rbuild/project.dtd">\r
+<project name="ReactOS" makefile="makefile.auto" xmlns:xi="http://www.w3.org/2001/XInclude">\r
+  <xi:include href="config.rbuild">\r
+    <xi:fallback>\r
+      <xi:include href="config.template.rbuild" />\r
+    </xi:fallback>\r
+  </xi:include>\r
+\r
+  <xi:include href="baseaddress.rbuild" />\r
+\r
+  <define name="_M_IX86" />\r
+  <define name="_X86_" />\r
+  <define name="__i386__" />\r
+  <define name="_REACTOS_" />\r
+  <if property="MP" value="1">\r
+    <define name="CONFIG_SMP" value="1" />\r
+  </if>\r
+  <if property="DBG" value="1">\r
+    <define name="DBG" value="1" />\r
+    <property name="DBG_OR_KDBG" value="true" />\r
+  </if>\r
+  <if property="KDBG" value="1">\r
+    <define name="KDBG" value="1" />\r
+    <property name="DBG_OR_KDBG" value="true" />\r
+  </if>\r
+  <compilerflag>-Os</compilerflag>\r
+  <compilerflag>-Wno-strict-aliasing</compilerflag>\r
+  <compilerflag>-ftracer</compilerflag>\r
+  <compilerflag>-momit-leaf-frame-pointer</compilerflag>\r
+  <compilerflag>-mpreferred-stack-boundary=2</compilerflag>\r
+  <compilerflag>-Wpointer-arith</compilerflag>\r
+\r
+  <include>.</include>\r
+  <include>include</include>\r
+  <include>include/reactos</include>\r
+  <include>include/libs</include>\r
+  <include>include/drivers</include>\r
+  <include>include/subsys</include>\r
+  <include>include/ndk</include>\r
+  <include>w32api/include</include>\r
+  <include>w32api/include/crt</include>\r
+  <include>w32api/include/ddk</include>\r
+\r
+<!-- TODO\r
+  <directory name="apps">\r
+    <xi:include href="apps/directory.rbuild" />\r
+  </directory>\r
+  <directory name="boot">\r
+    <xi:include href="boot/boot.rbuild" />\r
+  </directory>\r
+-->\r
+  <directory name="boot">\r
+    <xi:include href="boot/boot.rbuild" />\r
+  </directory>\r
+  <directory name="base">\r
+    <xi:include href="base/base.rbuild" />\r
+  </directory>\r
+<!-- TODO\r
+  <directory name="dll">\r
+    <xi:include href="dll/dll.rbuild" />\r
+  </directory>\r
+  <directory name="drivers">\r
+    <xi:include href="drivers/directory.rbuild" />\r
+  </directory>\r
+  <directory name="hal">\r
+    <xi:include href="hal/directory.rbuild" />\r
+  </directory>\r
+  <directory name="include">\r
+    <xi:include href="include/directory.rbuild" />\r
+  </directory>\r
+-->\r
+  <directory name="lib">\r
+    <xi:include href="lib/directory.rbuild" />\r
+  </directory>\r
+  <directory name="media">\r
+    <xi:include href="media/media.rbuild" />\r
+  </directory>\r
+<!-- TODO\r
+  <directory name="modules">\r
+    <xi:include href="modules/directory.rbuild" />\r
+  </directory>\r
+  <directory name="ntoskrnl">\r
+    <xi:include href="ntoskrnl/ntoskrnl.rbuild" />\r
+  </directory>\r
+  <directory name="regtests">\r
+    <xi:include href="regtests/directory.rbuild" />\r
+  </directory>\r
+-->\r
+  <directory name="subsystems">\r
+    <xi:include href="subsystems/subsystems.rbuild" />\r
+  </directory>\r
+\r
+</project>\r
diff --git a/reactos/ReactOS.xml b/reactos/ReactOS.xml
deleted file mode 100644 (file)
index 87d3edb..0000000
+++ /dev/null
@@ -1,84 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE project SYSTEM "tools/rbuild/project.dtd">
-<project name="ReactOS" makefile="makefile.auto" xmlns:xi="http://www.w3.org/2001/XInclude">
-       <xi:include href="config.xml">
-               <xi:fallback>
-                       <xi:include href="config.template.xml" />
-               </xi:fallback>
-       </xi:include>
-
-       <xi:include href="baseaddress.xml" />
-
-       <define name="_M_IX86" />
-       <define name="_X86_" />
-       <define name="__i386__" />
-       <define name="_REACTOS_" />
-       <if property="MP" value="1">
-               <define name="CONFIG_SMP" value="1" />
-       </if>
-       <if property="DBG" value="1">
-               <define name="DBG" value="1" />
-               <property name="DBG_OR_KDBG" value="true" />
-       </if>
-       <if property="KDBG" value="1">
-               <define name="KDBG" value="1" />
-               <property name="DBG_OR_KDBG" value="true" />
-       </if>
-       <compilerflag>-Os</compilerflag>
-       <compilerflag>-Wno-strict-aliasing</compilerflag>
-       <compilerflag>-ftracer</compilerflag>
-       <compilerflag>-momit-leaf-frame-pointer</compilerflag>
-       <compilerflag>-mpreferred-stack-boundary=2</compilerflag>
-       <compilerflag>-Wpointer-arith</compilerflag>
-
-       <include>.</include>
-       <include>include</include>
-       <include>include/reactos</include>
-       <include>include/libs</include>
-       <include>include/drivers</include>
-       <include>include/subsys</include>
-       <include>include/ndk</include>
-       <include>w32api/include</include>
-       <include>w32api/include/crt</include>
-       <include>w32api/include/ddk</include>
-
-       <directory name="apps">
-               <xi:include href="apps/directory.xml" />
-       </directory>
-       <directory name="boot">
-               <xi:include href="boot/boot.xml" />
-       </directory>
-       <directory name="bootdata">
-               <xi:include href="bootdata/bootdata.xml" />
-       </directory>
-       <directory name="drivers">
-               <xi:include href="drivers/directory.xml" />
-       </directory>
-       <directory name="hal">
-               <xi:include href="hal/directory.xml" />
-       </directory>
-       <directory name="include">
-               <xi:include href="include/directory.xml" />
-       </directory>
-       <directory name="lib">
-               <xi:include href="lib/directory.xml" />
-       </directory>
-       <directory name="media">
-               <xi:include href="media/directory.xml" />
-       </directory>
-       <directory name="modules">
-               <xi:include href="modules/directory.xml" />
-       </directory>
-       <directory name="ntoskrnl">
-               <xi:include href="ntoskrnl/ntoskrnl.xml" />
-       </directory>
-       <directory name="regtests">
-               <xi:include href="regtests/directory.xml" />
-       </directory>
-       <directory name="services">
-               <xi:include href="services/directory.xml" />
-       </directory>
-       <directory name="subsys">
-               <xi:include href="subsys/directory.xml" />
-       </directory>
-</project>
diff --git a/reactos/apps/utils/getfirefox/De.rc b/reactos/apps/utils/getfirefox/De.rc
deleted file mode 100644 (file)
index 87864c5..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * PROJECT:     ReactOS utilities
- * LICENSE:     GPL - See COPYING in the top level directory
- * FILE:        apps/utils/getfirefox/En.rc
- * PURPOSE:     English resources
- * COPYRIGHT:   Copyright 2004 Mike McCormack for CodeWeavers
- *              Copyright 2005 Ge van Geldorp (gvg@reactos.org)
- */
-/*
- * Based on Wine dlls/shdocvw/En.rc
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_GERMAN, SUBLANG_DEFAULT
-
-IDD_GETFIREFOX DIALOG LOADONCALL MOVEABLE DISCARDABLE  0, 0, 220, 76
-STYLE DS_MODALFRAME | DS_CENTER | WS_VISIBLE | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Lade Firefox herunter"
-FONT 8, "MS Shell Dlg"
-{
- CONTROL "Progress1",IDC_PROGRESS,"msctls_progress32",WS_BORDER|PBS_SMOOTH,10,10,200,12
- LTEXT "", IDC_STATUS, 10, 30, 200, 10, SS_CENTER
- CHECKBOX "Entferne ""Get Firefox"" nach Fertigstellung aus dem Startmenü", IDC_REMOVE,
-           10, 44, 200, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP
- PUSHBUTTON "Cancel", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP
-}
-
-STRINGTABLE
-BEGIN
- IDS_START_MENU_NAME "Get Firefox"
-END
diff --git a/reactos/apps/utils/getfirefox/En.rc b/reactos/apps/utils/getfirefox/En.rc
deleted file mode 100644 (file)
index 3b8b310..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * PROJECT:     ReactOS utilities
- * LICENSE:     GPL - See COPYING in the top level directory
- * FILE:        apps/utils/getfirefox/En.rc
- * PURPOSE:     English resources
- * COPYRIGHT:   Copyright 2004 Mike McCormack for CodeWeavers
- *              Copyright 2005 Ge van Geldorp (gvg@reactos.org)
- */
-/*
- * Based on Wine dlls/shdocvw/En.rc
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT
-
-IDD_GETFIREFOX DIALOG LOADONCALL MOVEABLE DISCARDABLE  0, 0, 220, 76
-STYLE DS_MODALFRAME | DS_CENTER | WS_VISIBLE | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Downloading Firefox"
-FONT 8, "MS Shell Dlg"
-{
- CONTROL "Progress1",IDC_PROGRESS,"msctls_progress32",WS_BORDER|PBS_SMOOTH,10,10,200,12
- LTEXT "", IDC_STATUS, 10, 30, 200, 10, SS_CENTER
- CHECKBOX "Remove ""Get Firefox"" from Start Menu when done", IDC_REMOVE,
-           10, 44, 200, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP
- PUSHBUTTON "Cancel", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP
-}
-
-STRINGTABLE
-BEGIN
- IDS_START_MENU_NAME "Get Firefox"
-END
diff --git a/reactos/apps/utils/getfirefox/Fr.rc b/reactos/apps/utils/getfirefox/Fr.rc
deleted file mode 100644 (file)
index 4d6e3b8..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-/*\r
- * PROJECT:     ReactOS utilities\r
- * LICENSE:     GPL - See COPYING in the top level directory\r
- * FILE:        apps/utils/getfirefox/En.rc\r
- * PURPOSE:     French resources\r
- * COPYRIGHT:   Copyright 2004 Mike McCormack for CodeWeavers\r
- *              Copyright 2005 Ge van Geldorp (gvg@reactos.org)\r
- *                 Copyright 2005 G. Maton (mustang9@gmail.com) - French translation\r
- */\r
-/*\r
- * Based on Wine dlls/shdocvw/En.rc\r
- *\r
- * This library is free software; you can redistribute it and/or\r
- * modify it under the terms of the GNU Lesser General Public\r
- * License as published by the Free Software Foundation; either\r
- * version 2.1 of the License, or (at your option) any later version.\r
- *\r
- * This library is distributed in the hope that it will be useful,\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU\r
- * Lesser General Public License for more details.\r
- *\r
- * You should have received a copy of the GNU Lesser General Public\r
- * License along with this library; if not, write to the Free Software\r
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA\r
- */\r
-\r
-LANGUAGE LANG_FRENCH, SUBLANG_DEFAULT\r
-\r
-IDD_GETFIREFOX DIALOG LOADONCALL MOVEABLE DISCARDABLE  0, 0, 220, 76\r
-STYLE DS_MODALFRAME | DS_CENTER | WS_VISIBLE | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "Téléchargement de Firefox"\r
-FONT 8, "MS Shell Dlg"\r
-{\r
- CONTROL "Progress1",IDC_PROGRESS,"msctls_progress32",WS_BORDER|PBS_SMOOTH,10,10,200,12\r
- LTEXT "", IDC_STATUS, 10, 30, 200, 10, SS_CENTER\r
- CHECKBOX "Supprimer ""Obtenir Firefox"" du Menu démarrer une fois terminé", IDC_REMOVE,\r
-           10, 44, 200, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP\r
- PUSHBUTTON "Annuler", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP\r
-}\r
-\r
-STRINGTABLE\r
-BEGIN\r
- IDS_START_MENU_NAME "Obtenir Firefox"\r
-END\r
diff --git a/reactos/apps/utils/getfirefox/Hu.rc b/reactos/apps/utils/getfirefox/Hu.rc
deleted file mode 100644 (file)
index 0324218..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-/*\r
- * PROJECT:     ReactOS utilities\r
- * LICENSE:     GPL - See COPYING in the top level directory\r
- * FILE:        apps/utils/getfirefox/En.rc\r
- * PURPOSE:     English resources\r
- * COPYRIGHT:   Copyright 2004 Mike McCormack for CodeWeavers\r
- *              Copyright 2005 Ge van Geldorp (gvg@reactos.org)\r
- *             Copyright 2005 Robert Horvath (talley@cubeclub.hu) - Hungarian translation\r
- */\r
-/*\r
- * Based on Wine dlls/shdocvw/En.rc\r
- *\r
- * This library is free software; you can redistribute it and/or\r
- * modify it under the terms of the GNU Lesser General Public\r
- * License as published by the Free Software Foundation; either\r
- * version 2.1 of the License, or (at your option) any later version.\r
- *\r
- * This library is distributed in the hope that it will be useful,\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU\r
- * Lesser General Public License for more details.\r
- *\r
- * You should have received a copy of the GNU Lesser General Public\r
- * License along with this library; if not, write to the Free Software\r
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA\r
- */\r
-\r
-LANGUAGE LANG_HUNGARIAN, SUBLANG_NEUTRAL\r
-\r
-IDD_GETFIREFOX DIALOG LOADONCALL MOVEABLE DISCARDABLE  0, 0, 220, 76\r
-STYLE DS_MODALFRAME | DS_CENTER | WS_VISIBLE | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "A Firefox letöltése"\r
-FONT 8, "MS Shell Dlg"\r
-{\r
- CONTROL "Progress1",IDC_PROGRESS,"msctls_progress32",WS_BORDER|PBS_SMOOTH,10,10,200,12\r
- LTEXT "", IDC_STATUS, 10, 30, 200, 10, SS_CENTER\r
- CHECKBOX "A ""Szerezd meg a Firefoxot"" elvátolítása a Start Menübõl befejezés után", IDC_REMOVE,\r
-           10, 44, 200, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP\r
- PUSHBUTTON "Mégse", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP\r
-}\r
-\r
-STRINGTABLE\r
-BEGIN\r
- IDS_START_MENU_NAME "Szerezd meg Firefoxot"\r
-END\r
diff --git a/reactos/apps/utils/getfirefox/firefox.ico b/reactos/apps/utils/getfirefox/firefox.ico
deleted file mode 100755 (executable)
index 0518438..0000000
Binary files a/reactos/apps/utils/getfirefox/firefox.ico and /dev/null differ
diff --git a/reactos/apps/utils/getfirefox/getfirefox.c b/reactos/apps/utils/getfirefox/getfirefox.c
deleted file mode 100644 (file)
index 40d758f..0000000
+++ /dev/null
@@ -1,383 +0,0 @@
-/*
- * PROJECT:     ReactOS utilities
- * LICENSE:     GPL - See COPYING in the top level directory
- * FILE:        apps/utils/getfirefox/getfirefox.c
- * PURPOSE:     Main program
- * COPYRIGHT:   Copyright 2001 John R. Sheets (for CodeWeavers)
- *              Copyright 2004 Mike McCormack (for CodeWeavers)
- *              Copyright 2005 Ge van Geldorp (gvg@reactos.org)
- */
-/*
- * Based on Wine dlls/shdocvw/shdocvw_main.c
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
-#include <precomp.h>
-
-#define NDEBUG
-#include <debug.h>
-
-#define DOWNLOAD_URL L"http://links.reactos.org/getfirefox"
-
-typedef struct _IBindStatusCallbackImpl
-  {
-    const IBindStatusCallbackVtbl *vtbl;
-    LONG ref;
-    HWND hDialog;
-    BOOL *pbCancelled;
-  } IBindStatusCallbackImpl;
-
-static HRESULT WINAPI
-dlQueryInterface(IBindStatusCallback* This, REFIID riid, void** ppvObject)
-{
-  if (NULL == ppvObject)
-    {
-      return E_POINTER;
-    }
-    
-  if (IsEqualIID(riid, &IID_IUnknown) ||
-      IsEqualIID(riid, &IID_IBindStatusCallback))
-    {
-      IBindStatusCallback_AddRef( This );
-      *ppvObject = This;
-      return S_OK;
-    }
-
-  return E_NOINTERFACE;
-}
-
-static ULONG WINAPI
-dlAddRef(IBindStatusCallback* iface)
-{
-  IBindStatusCallbackImpl *This = (IBindStatusCallbackImpl *) iface;
-    
-  return InterlockedIncrement(&This->ref);
-}
-
-static ULONG WINAPI
-dlRelease(IBindStatusCallback* iface)
-{
-  IBindStatusCallbackImpl *This = (IBindStatusCallbackImpl *) iface;
-  DWORD ref = InterlockedDecrement(&This->ref);
-    
-  if( !ref )
-    {
-      DestroyWindow( This->hDialog );
-      HeapFree(GetProcessHeap(), 0, This);
-    }
-    
-  return ref;
-}
-
-static HRESULT WINAPI
-dlOnStartBinding(IBindStatusCallback* iface, DWORD dwReserved, IBinding* pib)
-{
-  DPRINT1("OnStartBinding not implemented\n");
-
-  return S_OK;
-}
-
-static HRESULT WINAPI
-dlGetPriority(IBindStatusCallback* iface, LONG* pnPriority)
-{
-  DPRINT1("GetPriority not implemented\n");
-
-  return S_OK;
-}
-
-static HRESULT WINAPI
-dlOnLowResource( IBindStatusCallback* iface, DWORD reserved)
-{
-  DPRINT1("OnLowResource not implemented\n");
-
-  return S_OK;
-}
-
-static HRESULT WINAPI
-dlOnProgress(IBindStatusCallback* iface, ULONG ulProgress,
-             ULONG ulProgressMax, ULONG ulStatusCode, LPCWSTR szStatusText)
-{
-  IBindStatusCallbackImpl *This = (IBindStatusCallbackImpl *) iface;
-  HWND Item;
-  LONG r;
-  WCHAR OldText[100];
-
-  Item = GetDlgItem(This->hDialog, IDC_PROGRESS);
-  if (NULL != Item && 0 != ulProgressMax)
-    {
-      SendMessageW(Item, PBM_SETPOS, (ulProgress * 100) / ulProgressMax, 0);
-    }
-
-  Item = GetDlgItem(This->hDialog, IDC_STATUS);
-  if (NULL != Item)
-    {
-      SendMessageW(Item, WM_GETTEXT, sizeof(OldText) / sizeof(OldText[0]),
-                   (LPARAM) OldText);
-      if (sizeof(OldText) / sizeof(OldText[0]) - 1 <= wcslen(OldText) ||
-          0 != wcscmp(OldText, szStatusText))
-        {
-          SendMessageW(Item, WM_SETTEXT, 0, (LPARAM) szStatusText);
-        }
-    }
-
-  SetLastError(0);
-  r = GetWindowLongPtrW(This->hDialog, GWLP_USERDATA);
-  if (0 != r || 0 != GetLastError())
-    {
-      *This->pbCancelled = TRUE;
-      DPRINT("Cancelled\n");
-      return E_ABORT;
-    }
-
-  return S_OK;
-}
-
-static HRESULT WINAPI
-dlOnStopBinding(IBindStatusCallback* iface, HRESULT hresult, LPCWSTR szError)
-{
-  DPRINT1("OnStopBinding not implemented\n");
-
-  return S_OK;
-}
-
-static HRESULT WINAPI
-dlGetBindInfo(IBindStatusCallback* iface, DWORD* grfBINDF, BINDINFO* pbindinfo)
-{
-  DPRINT1("GetBindInfo not implemented\n");
-
-  return S_OK;
-}
-
-static HRESULT WINAPI
-dlOnDataAvailable(IBindStatusCallback* iface, DWORD grfBSCF,
-                  DWORD dwSize, FORMATETC* pformatetc, STGMEDIUM* pstgmed)
-{
-  DPRINT1("OnDataAvailable implemented\n");
-
-  return S_OK;
-}
-
-static HRESULT WINAPI
-dlOnObjectAvailable(IBindStatusCallback* iface, REFIID riid, IUnknown* punk)
-{
-  DPRINT1("OnObjectAvailable implemented\n");
-
-  return S_OK;
-}
-
-static const IBindStatusCallbackVtbl dlVtbl =
-{
-    dlQueryInterface,
-    dlAddRef,
-    dlRelease,
-    dlOnStartBinding,
-    dlGetPriority,
-    dlOnLowResource,
-    dlOnProgress,
-    dlOnStopBinding,
-    dlGetBindInfo,
-    dlOnDataAvailable,
-    dlOnObjectAvailable
-};
-
-static IBindStatusCallback*
-CreateDl(HWND Dlg, BOOL *pbCancelled)
-{
-  IBindStatusCallbackImpl *This;
-
-  This = HeapAlloc(GetProcessHeap(), 0, sizeof(IBindStatusCallbackImpl));
-  This->vtbl = &dlVtbl;
-  This->ref = 1;
-  This->hDialog = Dlg;
-  This->pbCancelled = pbCancelled;
-
-  return (IBindStatusCallback*) This;
-}
-
-static BOOL
-GetShortcutName(LPWSTR ShortcutName)
-{
-  if (! SHGetSpecialFolderPathW(0, ShortcutName, CSIDL_PROGRAMS, FALSE))
-    {
-      return FALSE;
-    }
-  if (NULL == PathAddBackslashW(ShortcutName))
-    {
-      return FALSE;
-    }
-  if (0 == LoadStringW(GetModuleHandle(NULL), IDS_START_MENU_NAME,
-                       ShortcutName + wcslen(ShortcutName),
-                       MAX_PATH - wcslen(ShortcutName)))
-    {
-      return FALSE;
-    }
-  if (MAX_PATH - 5 < wcslen(ShortcutName))
-    {
-      return FALSE;
-    }
-  wcscat(ShortcutName, L".lnk");
-
-  return TRUE;
-}
-
-static DWORD WINAPI
-ThreadFunc(LPVOID Context)
-{
-  static const WCHAR szUrl[] = DOWNLOAD_URL;
-  IBindStatusCallback *dl;
-  WCHAR path[MAX_PATH], ShortcutName[MAX_PATH];
-  LPWSTR p;
-  STARTUPINFOW si;
-  PROCESS_INFORMATION pi;
-  HWND Dlg = (HWND) Context;
-  DWORD r;
-  BOOL bCancelled = FALSE;
-  BOOL bTempfile = FALSE;
-
-  /* built the path for the download */
-  p = wcsrchr(szUrl, L'/');
-  if (NULL == p)
-    {
-      goto end;
-    }
-  if (! GetTempPathW(MAX_PATH, path))
-    {
-      goto end;
-    }
-  wcscat(path, p + 1);
-
-  /* download it */
-  bTempfile = TRUE;
-  dl = CreateDl(Context, &bCancelled);
-  r = URLDownloadToFileW(NULL, szUrl, path, 0, dl);
-  if (NULL != dl)
-    {
-      IBindStatusCallback_Release(dl);
-    }
-  if (S_OK != r || bCancelled )
-    {
-      goto end;
-    }
-  ShowWindow(Dlg, SW_HIDE);
-
-  /* run it */
-  memset(&si, 0, sizeof(si));
-  si.cb = sizeof(si);
-  r = CreateProcessW(path, NULL, NULL, NULL, 0, 0, NULL, NULL, &si, &pi);
-  if (0 == r)
-    {
-      goto end;
-    }
-  CloseHandle(pi.hThread);
-  WaitForSingleObject(pi.hProcess, INFINITE);
-  CloseHandle(pi.hProcess);
-
-  if (BST_CHECKED == SendMessageW(GetDlgItem(Dlg, IDC_REMOVE), BM_GETCHECK,
-                                  0, 0) &&
-      GetShortcutName(ShortcutName))
-    {
-      DeleteFileW(ShortcutName);
-    }
-
-end:
-  if (bTempfile)
-    {
-      DeleteFileW(path);
-    }
-  EndDialog(Dlg, 0);
-  return 0;
-}
-
-static INT_PTR CALLBACK
-dlProc(HWND Dlg, UINT Msg, WPARAM wParam, LPARAM lParam)
-{
-  HANDLE Thread;
-  DWORD ThreadId;
-  HWND Item;
-  HICON Icon;
-  WCHAR ShortcutName[MAX_PATH];
-
-  switch (Msg)
-    {
-    case WM_INITDIALOG:
-      Icon = LoadIconW((HINSTANCE) GetWindowLongPtr(Dlg, GWLP_HINSTANCE),
-                       MAKEINTRESOURCEW(IDI_ICON_MAIN));
-      if (NULL != Icon)
-        {
-          SendMessageW(Dlg, WM_SETICON, ICON_BIG, (LPARAM) Icon);
-          SendMessageW(Dlg, WM_SETICON, ICON_SMALL, (LPARAM) Icon);
-        }
-      SetWindowLongPtrW(Dlg, GWLP_USERDATA, 0);
-      Item = GetDlgItem(Dlg, IDC_PROGRESS);
-      if (NULL != Item)
-        {
-          SendMessageW(Item, PBM_SETRANGE, 0, MAKELPARAM(0,100));
-          SendMessageW(Item, PBM_SETPOS, 0, 0);
-        }
-      Item = GetDlgItem(Dlg, IDC_REMOVE);
-      if (NULL != Item)
-        {
-          if (GetShortcutName(ShortcutName) &&
-              INVALID_FILE_ATTRIBUTES != GetFileAttributesW(ShortcutName))
-            {
-              SendMessageW(Item, BM_SETCHECK, BST_CHECKED, 0);
-            }
-          else
-            {
-              SendMessageW(Item, BM_SETCHECK, BST_UNCHECKED, 0);
-              ShowWindow(Item, SW_HIDE);
-            }
-        }
-      Thread = CreateThread(NULL, 0, ThreadFunc, Dlg, 0, &ThreadId);
-      if (NULL == Thread)
-        {
-          return FALSE;
-        }
-      CloseHandle(Thread);
-      return TRUE;
-
-    case WM_COMMAND:
-      if (wParam == IDCANCEL)
-        {
-          SetWindowLongPtrW(Dlg, GWLP_USERDATA, 1);
-          PostMessage(Dlg, WM_CLOSE, 0, 0);
-        }
-      return FALSE;
-
-    case WM_CLOSE:
-        EndDialog(Dlg, 0);
-        return TRUE;
-
-       default:
-      return FALSE;
-    }
-}
-
-
-/***********************************************************************
- *              Main program
- */
-int
-main(int argc, char *argv[])
-{
-  InitCommonControls();
-
-  DialogBoxW(GetModuleHandle(NULL), MAKEINTRESOURCEW(IDD_GETFIREFOX), 0,
-             dlProc);
-
-  return 0;
-}
diff --git a/reactos/apps/utils/getfirefox/getfirefox.rc b/reactos/apps/utils/getfirefox/getfirefox.rc
deleted file mode 100644 (file)
index e9f4c76..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * PROJECT:     ReactOS utilities
- * LICENSE:     GPL - See COPYING in the top level directory
- * FILE:        apps/utils/getfirefox/getfirefox.rc
- * PURPOSE:     Language-independent resources
- * COPYRIGHT:   Copyright 2005 Ge van Geldorp (gvg@reactos.org)
- */
-
-#include <windows.h>
-#include "resource.h"
-
-#define REACTOS_STR_FILE_DESCRIPTION    "Firefox downloader\0"
-#define REACTOS_STR_INTERNAL_NAME       "getfirefox\0"
-#define REACTOS_STR_ORIGINAL_FILENAME   "getfirefox.exe\0"
-#include <reactos/version.rc>
-
-/*
- * Note: this icon is the "default logo" referenced here:
- * http://www.mozilla.org/foundation/trademarks/faq.html (under "What are the
- * Mozilla Trademarks and Logos?"). Don't use the official Firefox logo as it
- * is trademarked.
- */
-1 ICON  "firefox.ico"
-
-#include "De.rc"
-#include "En.rc"
-#include "Fr.rc"
-#include "Hu.rc"
diff --git a/reactos/apps/utils/getfirefox/getfirefox.xml b/reactos/apps/utils/getfirefox/getfirefox.xml
deleted file mode 100644 (file)
index fab9acc..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-<module name="getfirefox" type="win32gui" installbase="system32" installname="getfirefox.exe">
-    <include base="getfirefox">.</include>
-    <define name="UNICODE" />
-    <define name="_UNICODE" />
-    <define name="__USE_W32API" />
-    <define name="WINVER">0x0501</define>
-    <define name="_WIN32_IE>0x0600</define>
-    <library>comctl32</library>
-    <library>ntdll</library>
-    <library>shell32</library>
-    <library>shlwapi</library>
-    <library>urlmon</library>
-    <library>uuid</library>
-    <pch>precomp.h</pch>
-    <file>getfirefox.c</file>
-    <file>getfirefox.rc</file>
-</module>
diff --git a/reactos/apps/utils/getfirefox/precomp.h b/reactos/apps/utils/getfirefox/precomp.h
deleted file mode 100644 (file)
index b06adaf..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-/*
- * PROJECT:     ReactOS utilities
- * LICENSE:     GPL - See COPYING in the top level directory
- * FILE:        apps/utils/getfirefox/precomp.h
- * PURPOSE:     Precompiled header file
- * COPYRIGHT:   Copyright 2005 Ge van Geldorp (gvg@reactos.org)
- */
-
-#define COBJMACROS
-#define NTOS_MODE_USER
-#define WIN32_NO_STATUS
-#include <windows.h>
-#include <ndk/ntndk.h>
-#include <commctrl.h>
-#include <shlobj.h>
-#include <shlwapi.h>
-#include <urlmon.h>
-
-#include "resource.h"
diff --git a/reactos/apps/utils/getfirefox/resource.h b/reactos/apps/utils/getfirefox/resource.h
deleted file mode 100644 (file)
index 8928a74..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-/*
- * PROJECT:     ReactOS utilities
- * LICENSE:     GPL - See COPYING in the top level directory
- * FILE:        apps/utils/getfirefox/resource.h
- * PURPOSE:     Resource constants
- * COPYRIGHT:   Copyright 2005 Ge van Geldorp (gvg@reactos.org)
- */
-
-#define IDI_ICON_MAIN 1
-
-#define IDD_GETFIREFOX 100
-
-#define IDC_PROGRESS 1000
-#define IDC_STATUS   1001
-#define IDC_REMOVE   1002
-
-#define IDS_START_MENU_NAME 1100
diff --git a/reactos/apps/utils/net/arp/arp.c b/reactos/apps/utils/net/arp/arp.c
deleted file mode 100644 (file)
index d1009a1..0000000
+++ /dev/null
@@ -1,621 +0,0 @@
-/*
- *  ReactOS Win32 Applications
- *  Copyright (C) 2005 ReactOS Team
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- */
-
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS arp utility
- * FILE:        apps/utils/net/arp/arp.c
- * PURPOSE:     view and manipulate the ARP cache
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *   GM 27/06/05 Created
- *
- */
-
-#define WIN32_LEAN_AND_MEAN
-#include <windows.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-#include <winsock2.h>
-#include <iphlpapi.h>
-
-#define UNICODE
-#define _UNICODE
-
-/*
- * Globals
- */
-const char SEPERATOR = '-';
-int _CRT_glob = 0; // stop * from listing dir files in arp -d *
-
-
-/*
- * function declerations
- */
-DWORD DoFormatMessage(VOID);
-INT PrintEntries(PMIB_IPNETROW pIpAddRow);
-INT DisplayArpEntries(PTCHAR pszInetAddr, PTCHAR pszIfAddr);
-INT Addhost(PTCHAR pszInetAddr, PTCHAR pszEthAddr, PTCHAR pszIfAddr);
-INT Deletehost(PTCHAR pszInetAddr, PTCHAR pszIfAddr);
-VOID Usage(VOID);
-
-
-/*
- * convert error code into meaningful message
- */
-DWORD DoFormatMessage(VOID)
-{
-    LPVOID lpMsgBuf;
-    DWORD RetVal;
-
-    DWORD ErrorCode = GetLastError();
-
-    if (ErrorCode != ERROR_SUCCESS) 
-    {
-        RetVal = FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER |
-                               FORMAT_MESSAGE_FROM_SYSTEM |
-                               FORMAT_MESSAGE_IGNORE_INSERTS,
-                               NULL,
-                               ErrorCode,
-                               MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), /* Default language */
-                               (LPTSTR) &lpMsgBuf,
-                               0,
-                               NULL );
-
-        if (RetVal != 0)
-        {
-            _tprintf(_T("%s"), (LPTSTR)lpMsgBuf);
-
-            LocalFree(lpMsgBuf);
-            /* return number of TCHAR's stored in output buffer
-             * excluding '\0' - as FormatMessage does*/
-            return RetVal;
-        }
-    }
-    return 0;
-}
-
-
-
-/*
- *
- * Takes an ARP entry and prints the IP address,
- * the MAC address and the entry type to screen
- *
- */
-INT PrintEntries(PMIB_IPNETROW pIpAddRow)
-{
-    IN_ADDR inaddr;
-    TCHAR cMacAddr[20];
-
-    /* print IP addresses */
-    inaddr.S_un.S_addr = pIpAddRow->dwAddr;
-    _tprintf(_T("  %-22s"), inet_ntoa(inaddr));
-
-    /* print MAC address */
-    _stprintf(cMacAddr, _T("%02x-%02x-%02x-%02x-%02x-%02x"),
-        pIpAddRow->bPhysAddr[0],
-        pIpAddRow->bPhysAddr[1],
-        pIpAddRow->bPhysAddr[2],
-        pIpAddRow->bPhysAddr[3],
-        pIpAddRow->bPhysAddr[4],
-        pIpAddRow->bPhysAddr[5]);
-    _tprintf(_T("%-22s"), cMacAddr);
-
-    /* print cache type */
-    switch (pIpAddRow->dwType)
-    {
-        case MIB_IPNET_TYPE_DYNAMIC : _tprintf(_T("dynamic\n"));
-                                      break;
-        case MIB_IPNET_TYPE_STATIC : _tprintf(_T("static\n"));
-                                      break;
-        case MIB_IPNET_TYPE_INVALID : _tprintf(_T("invalid\n"));
-                                      break;
-        case MIB_IPNET_TYPE_OTHER : _tprintf(_T("other\n"));
-                                      break;
-    }
-    return EXIT_SUCCESS;
-}
-
-
-/*
- *
- * Takes optional parameters of an internet address and interface address.
- * Retrieve all entries in the ARP cache. If an internet address is
- * specified, display the ARP entry relating to that address. If an
- * interface address is specified, display all entries relating to
- * that interface.
- *
- */
-/* FIXME: allow user to specify an interface address, via pszIfAddr */
-INT DisplayArpEntries(PTCHAR pszInetAddr, PTCHAR pszIfAddr)
-{
-    INT iRet;
-    UINT i, k;
-    PMIB_IPNETTABLE pIpNetTable = NULL;
-    PMIB_IPADDRTABLE pIpAddrTable = NULL;
-    DWORD Size = 0;
-    struct in_addr inaddr, inaddr2;
-    PTCHAR pszIpAddr;
-    TCHAR szIntIpAddr[20];
-
-    /* retrieve the IP-to-physical address mapping table */
-
-    /* get table size */
-    GetIpNetTable(pIpNetTable, &Size, 0);
-
-    /* allocate memory for ARP address table */
-    pIpNetTable = (PMIB_IPNETTABLE) HeapAlloc(GetProcessHeap(), 0, Size);
-    if (pIpNetTable == NULL)
-        goto cleanup;
-
-    ZeroMemory(pIpNetTable, sizeof(*pIpNetTable));
-
-    iRet = GetIpNetTable(pIpNetTable, &Size, TRUE);
-
-    if (iRet != NO_ERROR)
-    {
-        _tprintf(_T("failed to allocate memory for GetIpNetTable\n"));
-        DoFormatMessage();
-        goto cleanup;
-    }
-
-    /* check there are entries in the table */
-    if (pIpNetTable->dwNumEntries == 0)
-    {
-        _tprintf(_T("No ARP entires found\n"));
-        goto cleanup;
-    }
-
-
-
-    /* Retrieve the interface-to-ip address mapping
-     * table to get the IP address for adapter */
-
-    /* get table size */
-    Size = 0;
-    GetIpAddrTable(pIpAddrTable, &Size, 0);
-
-    pIpAddrTable = (MIB_IPADDRTABLE *) HeapAlloc(GetProcessHeap(), 0, Size);
-    if (pIpAddrTable == NULL)
-        goto cleanup;
-
-    ZeroMemory(pIpAddrTable, sizeof(*pIpAddrTable));
-
-    iRet = GetIpAddrTable(pIpAddrTable, &Size, TRUE);
-
-    if (iRet != NO_ERROR)
-    {
-        _tprintf(_T("GetIpAddrTable failed: %d\n"), iRet);
-        DoFormatMessage();
-        goto cleanup;
-    }
-
-
-    for (k=0; k < pIpAddrTable->dwNumEntries; k++)
-    {
-        if (pIpNetTable->table[0].dwIndex == pIpAddrTable->table[k].dwIndex)
-        {
-            //printf("debug print: pIpAddrTable->table[?].dwIndex = %lx\n", pIpNetTable->table[k].dwIndex);
-            inaddr2.s_addr = pIpAddrTable->table[k].dwAddr;
-            pszIpAddr = inet_ntoa(inaddr2);
-            strcpy(szIntIpAddr, pszIpAddr);
-        }
-    }
-
-
-    /* print header, including interface IP address and index number */
-    _tprintf(_T("\nInterface: %s --- 0x%lx \n"), szIntIpAddr, pIpNetTable->table[0].dwIndex);
-    _tprintf(_T("  Internet Address      Physical Address      Type\n"));
-
-    /* go through all ARP entries */
-    for (i=0; i < pIpNetTable->dwNumEntries; i++)
-    {
-
-        /* if the user has supplied their own internet addesss *
-         * only print the arp entry which matches that */
-        if (pszInetAddr)
-        {
-            inaddr.S_un.S_addr = pIpNetTable->table[i].dwAddr;
-            pszIpAddr = inet_ntoa(inaddr);
-
-            /* check if it matches, print it */
-            if (strcmp(pszIpAddr, pszInetAddr) == 0)
-                PrintEntries(&pIpNetTable->table[i]);
-        }
-        else
-            /* if an address is not supplied, print all entries */
-            PrintEntries(&pIpNetTable->table[i]);
-    }
-
-    return EXIT_SUCCESS;
-    
-cleanup:
-    if (pIpNetTable != NULL)
-        HeapFree(GetProcessHeap(), 0, pIpNetTable);
-    if (pIpAddrTable != NULL)
-        HeapFree(GetProcessHeap(), 0, pIpAddrTable);
-    return EXIT_FAILURE;
-}
-
-
-/*
- *
- * Takes an internet address, a MAC address and an optional interface
- * address as arguments and checks their validity.
- * Fill out an MIB_IPNETROW structure and insert the data into the
- * ARP cache as a static entry.
- *
- */
-INT Addhost(PTCHAR pszInetAddr, PTCHAR pszEthAddr, PTCHAR pszIfAddr)
-{
-    PMIB_IPNETROW pAddHost = NULL;
-    PMIB_IPNETTABLE pIpNetTable = NULL;
-    DWORD dwIpAddr = 0;
-    ULONG Size = 0;
-    INT iRet, i, val, c;
-
-    /* error checking */
-
-    /* check IP address */
-    if (pszInetAddr != NULL)
-    {
-        if ((dwIpAddr = inet_addr(pszInetAddr)) == INADDR_NONE)
-        {
-            _tprintf(_T("ARP: bad IP address: %s\n"), pszInetAddr);
-            return EXIT_FAILURE;
-        }
-    }
-    else
-    {
-        Usage();
-        return EXIT_FAILURE;
-    }
-
-    /* check MAC address */
-    if (strlen(pszEthAddr) != 17)
-    {
-        _tprintf(_T("ARP: bad argument: %s\n"), pszEthAddr);
-        return EXIT_FAILURE;
-    }
-    for (i=0; i<17; i++)
-    {
-        if (pszEthAddr[i] == SEPERATOR)
-            continue;
-
-        if (!isxdigit(pszEthAddr[i]))
-        {
-            _tprintf(_T("ARP: bad argument: %s\n"), pszEthAddr);
-            return EXIT_FAILURE;
-        }
-    }
-
-    /* We need the IpNetTable to get the adapter index */
-    /* Return required buffer size */
-    GetIpNetTable(pIpNetTable, &Size, 0);
-
-    /* allocate memory for ARP address table */
-    pIpNetTable = (PMIB_IPNETTABLE) HeapAlloc(GetProcessHeap(), 0, Size);
-    if (pIpNetTable == NULL)
-        goto cleanup;
-
-    ZeroMemory(pIpNetTable, sizeof(*pIpNetTable));
-
-    iRet = GetIpNetTable(pIpNetTable, &Size, TRUE);
-
-    if (iRet != NO_ERROR)
-    {
-        _tprintf(_T("failed to allocate memory for GetIpNetTable\n"));
-        DoFormatMessage();
-        goto cleanup;
-    }
-
-
-    /* reserve memory on heap and zero */
-    pAddHost = (MIB_IPNETROW *) HeapAlloc(GetProcessHeap(), 0, sizeof(MIB_IPNETROW));
-    if (pAddHost == NULL)
-        goto cleanup;
-
-    ZeroMemory(pAddHost, sizeof(MIB_IPNETROW));
-
-    /* set dwIndex field to the index of a local IP address to
-     * indicate the network on which the ARP entry applies */
-    if (pszIfAddr)
-    {
-        if (sscanf(pszIfAddr, "%lx", &pAddHost->dwIndex) == EOF)
-        {
-            goto cleanup;
-        }
-    }
-    else
-    {
-        //printf("debug print: pIpNetTable->table[0].dwIndex = %lx\n", pIpNetTable->table[0].dwIndex);
-        /* needs testing. I get the correct index on my machine, but need others
-         * to test their card index.  Any problems and we can use GetAdaptersInfo instead */
-        pAddHost->dwIndex = pIpNetTable->table[0].dwIndex;
-    }
-
-    /* Set MAC address to 6 bytes (typical) */
-    pAddHost->dwPhysAddrLen = 6;
-
-
-    /* Encode bPhysAddr into correct byte array */
-    for (i=0; i<6; i++)
-    {
-        val =0;
-        c = toupper(pszEthAddr[i*3]);
-        c = c - (isdigit(c) ? '0' : ('A' - 10));
-        val += c;
-        val = (val << 4);
-        c = toupper(pszEthAddr[i*3 + 1]);
-        c = c - (isdigit(c) ? '0' : ('A' - 10));
-        val += c;
-        pAddHost->bPhysAddr[i] = (BYTE)val;
-    }
-
-
-    /* copy converted IP address */
-    pAddHost->dwAddr = dwIpAddr;
-
-
-    /* set type to static */
-    pAddHost->dwType = MIB_IPNET_TYPE_STATIC;
-
-
-    /* Add the ARP entry */
-    if ((iRet = SetIpNetEntry(pAddHost)) != NO_ERROR)
-    {
-        DoFormatMessage();
-        goto cleanup;
-    }
-
-    HeapFree(GetProcessHeap(), 0, pAddHost);
-
-    return EXIT_SUCCESS;
-
-cleanup:
-    if (pIpNetTable != NULL)
-        HeapFree(GetProcessHeap(), 0, pIpNetTable);
-    if (pAddHost != NULL)
-        HeapFree(GetProcessHeap(), 0, pAddHost);
-    return EXIT_FAILURE;
-}
-
-
-/*
- *
- * Takes an internet address and an optional interface address as
- * arguments and checks their validity.
- * Add the interface number and IP to an MIB_IPNETROW structure
- * and remove the entry from the ARP cache.
- *
- */
-INT Deletehost(PTCHAR pszInetAddr, PTCHAR pszIfAddr)
-{
-    PMIB_IPNETROW pDelHost = NULL;
-    PMIB_IPNETTABLE pIpNetTable = NULL;
-    DWORD Size = 0;
-    DWORD dwIpAddr = 0;
-    INT iRet;
-    BOOL bFlushTable = FALSE;
-
-    /* error checking */
-
-    /* check IP address */
-    if (pszInetAddr != NULL)
-    {
-        /* if wildcard is given, set flag to delete all hosts */
-        if (strncmp(pszInetAddr, "*", 1) == 0)
-            bFlushTable = TRUE;
-        else if ((dwIpAddr = inet_addr(pszInetAddr)) == INADDR_NONE)
-        {
-            _tprintf(_T("ARP: bad IP address: %s\n"), pszInetAddr);
-            exit(EXIT_FAILURE);
-        }
-    }
-    else
-    {
-        Usage();
-        exit(EXIT_FAILURE);
-    }
-
-    /* We need the IpNetTable to get the adapter index */
-    /* Return required buffer size */
-    GetIpNetTable(NULL, &Size, 0);
-
-    /* allocate memory for ARP address table */
-    pIpNetTable = (PMIB_IPNETTABLE) HeapAlloc(GetProcessHeap(), 0, Size);
-    if (pIpNetTable == NULL)
-        goto cleanup;
-
-    ZeroMemory(pIpNetTable, sizeof(*pIpNetTable));
-
-    iRet = GetIpNetTable(pIpNetTable, &Size, TRUE);
-
-    if (iRet != NO_ERROR)
-    {
-        _tprintf(_T("failed to allocate memory for GetIpNetTable\n"));
-        DoFormatMessage();
-        goto cleanup;
-    }
-
-    /* reserve memory on heap and zero */
-    pDelHost = (MIB_IPNETROW *) HeapAlloc(GetProcessHeap(), 0, sizeof(MIB_IPNETROW));
-    if (pDelHost == NULL)
-        goto cleanup;
-
-    ZeroMemory(pDelHost, sizeof(MIB_IPNETROW));
-
-
-    /* set dwIndex field to the index of a local IP address to
-     * indicate the network on which the ARP entry applies */
-    if (pszIfAddr)
-    {
-        if (sscanf(pszIfAddr, "%lx", &pDelHost->dwIndex) == EOF)
-        {
-            goto cleanup;
-        }
-    }
-    else
-    {
-        /* needs testing. I get the correct index on my machine, but need others
-         * to test their card index. Any problems and we can use GetAdaptersInfo instead */
-        pDelHost->dwIndex = pIpNetTable->table[0].dwIndex;
-    }
-
-    if (bFlushTable == TRUE)
-    {
-        /* delete arp cache */
-        if ((iRet = FlushIpNetTable(pDelHost->dwIndex)) != NO_ERROR)
-        {
-            DoFormatMessage();
-            goto cleanup;
-        }
-        else
-        {
-            HeapFree(GetProcessHeap(), 0, pDelHost);
-            return EXIT_SUCCESS;
-        }
-    }
-    else
-        /* copy converted IP address */
-        pDelHost->dwAddr = dwIpAddr;
-
-    /* Add the ARP entry */
-    if ((iRet = DeleteIpNetEntry(pDelHost)) != NO_ERROR)
-    {
-        DoFormatMessage();
-        goto cleanup;
-    }
-
-    HeapFree(GetProcessHeap(), 0, pDelHost);
-
-    return EXIT_SUCCESS;
-
-cleanup:
-    if (pIpNetTable != NULL)
-        HeapFree(GetProcessHeap(), 0, pIpNetTable);
-    if (pDelHost != NULL)
-        HeapFree(GetProcessHeap(), 0, pDelHost);
-    return EXIT_FAILURE;
-}
-
-
-
-/*
- *
- * print program usage to screen
- *
- */
-VOID Usage(VOID)
-{
-    _tprintf(_T("\nDisplays and modifies the IP-to-Physical address translation tables used by\n"
-                "address resolution protocol (ARP).\n"
-                "\n"
-                "ARP -s inet_addr eth_addr [if_addr]\n"
-                "ARP -d inet_addr [if_addr]\n"
-                "ARP -a [inet_addr] [-N if_addr]\n"
-                "\n"
-                "  -a            Displays current ARP entries by interrogating the current\n"
-                "                protocol data.  If inet_addr is specified, the IP and Physical\n"
-                "                addresses for only the specified computer are displayed.  If\n"
-                "                more than one network interface uses ARP, entries for each ARP\n"
-                "                table are displayed.\n"
-                "  -g            Same as -a.\n"
-                "  inet_addr     Specifies an internet address.\n"
-                "  -N if_addr    Displays the ARP entries for the network interface specified\n"
-                "                by if_addr.\n"
-                "  -d            Deletes the host specified by inet_addr. inet_addr may be\n"
-                "                wildcarded with * to delete all hosts.\n"
-                "  -s            Adds the host and associates the Internet address inet_addr\n"
-                "                with the Physical address eth_addr.  The Physical address is\n"
-                "                given as 6 hexadecimal bytes separated by hyphens. The entry\n"
-                "                is permanent.\n"
-                "  eth_addr      Specifies a physical address.\n"
-                "  if_addr       If present, this specifies the Internet address of the\n"
-                "                interface whose address translation table should be modified.\n"
-                "                If not present, the first applicable interface will be used.\n"
-                "Example:\n"
-                "  > arp -s 157.55.85.212   00-aa-00-62-c6-09  .... Adds a static entry.\n"
-                "  > arp -a                                    .... Displays the arp table.\n\n"));
-}
-
-
-
-/*
- *
- * Program entry.
- * Parse command line and call the required function
- *
- */
-INT main(int argc, char* argv[])
-{
-    if ((argc < 2) || (argc > 5))
-    {
-       Usage();
-       return EXIT_FAILURE;
-    }
-
-    if (argv[1][0] == '-')
-    {
-        switch (argv[1][1])
-        {
-           case 'a': /* fall through */
-           case 'g':
-                     if (argc == 2)
-                         DisplayArpEntries(NULL, NULL);
-                     else if (argc == 3)
-                         DisplayArpEntries(argv[2], NULL);
-                     else if ((argc == 4) && ((strcmp(argv[2], "-N")) == 0))
-                         DisplayArpEntries(NULL, argv[3]);
-                     else if ((argc == 5) && ((strcmp(argv[3], "-N")) == 0))
-                         DisplayArpEntries(argv[2], argv[4]);
-                     else
-                         Usage();
-                         return EXIT_FAILURE;
-                     break;
-           case 'd': if (argc == 3)
-                         Deletehost(argv[2], NULL);
-                     else if (argc == 4)
-                         Deletehost(argv[2], argv[3]);
-                     else
-                         Usage();
-                         return EXIT_FAILURE;
-                     break;
-           case 's': if (argc == 4)
-                         Addhost(argv[2], argv[3], NULL);
-                     else if (argc == 5)
-                         Addhost(argv[2], argv[3], argv[4]);
-                     else
-                         Usage();
-                         return EXIT_FAILURE;
-                     break;
-           default:
-              Usage();
-              return EXIT_FAILURE;
-        }
-    }
-    else
-        Usage();
-
-    return EXIT_SUCCESS;
-} 
diff --git a/reactos/apps/utils/net/arp/arp.rc b/reactos/apps/utils/net/arp/arp.rc
deleted file mode 100644 (file)
index 38f57ae..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS TCP/IPv4 Win32 arp\0"
-#define REACTOS_STR_INTERNAL_NAME      "arp\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "arp.exe\0"
-#define REACTOS_STR_ORIGINAL_COPYRIGHT "Ged Murphy (gedmurphy@gmail.com)\0"
-#include <reactos/version.rc>
diff --git a/reactos/apps/utils/net/arp/arp.xml b/reactos/apps/utils/net/arp/arp.xml
deleted file mode 100644 (file)
index ef70312..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-<module name="arp" type="win32cui" installbase="system32" installname="arp.exe">
-       <include base="arp">.</include>
-       <define name="__USE_W32API" />
-       <library>kernel32</library>
-       <library>iphlpapi</library>
-       <library>ws2_32</library>
-       <library>shlwapi</library>
-       <file>arp.c</file>
-       <file>arp.rc</file>
-</module>
-
diff --git a/reactos/apps/utils/net/directory.xml b/reactos/apps/utils/net/directory.xml
deleted file mode 100644 (file)
index cbdcbfd..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-<directory name="arp">
-    <xi:include href="arp/arp.xml" />
-</directory>
-<directory name="finger">
-    <xi:include href="finger/finger.xml" />
-</directory>
-<directory name="ftp">
-    <xi:include href="ftp/ftp.xml" />
-</directory>
-<directory name="ipconfig">
-    <xi:include href="ipconfig/ipconfig.xml" />
-</directory>
-<directory name="netstat">
-    <xi:include href="netstat/netstat.xml" />
-</directory>
-<directory name="ping">
-    <xi:include href="ping/ping.xml" />
-</directory>
-<directory name="route">
-    <xi:include href="route/route.xml" />
-</directory>
-<directory name="telnet">
-    <xi:include href="telnet/telnet.xml" />
-</directory>
-<directory name="tracert">
-    <xi:include href="tracert/tracert.xml" />
-</directory>
-<directory name="whois">
-    <xi:include href="whois/whois.xml" />
-</directory>
diff --git a/reactos/apps/utils/net/finger/LICENSE.txt b/reactos/apps/utils/net/finger/LICENSE.txt
deleted file mode 100644 (file)
index 3f506f7..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-July 22, 1999 
-
-To All Licensees, Distributors of Any Version of BSD: 
-
-As you know, certain of the Berkeley Software Distribution ("BSD") source code files 
-require that further distributions of products containing all or portions of the 
-software, acknowledge within their advertising materials that such products contain 
-software developed by UC Berkeley and its contributors. 
-
-Specifically, the provision reads: 
-
-      * 3. All advertising materials mentioning features or use of this software
-      *    must display the following acknowledgement:
-      *    This product includes software developed by the University of
-      *    California, Berkeley and its contributors.
-
-Effective immediately, licensees and distributors are no longer required to include 
-the acknowledgement within advertising materials. Accordingly, the foregoing paragraph 
-of those BSD Unix files containing it is hereby deleted in its entirety. 
-
-William Hoskins
-Director, Office of Technology Licensing
-University of California, Berkeley " 
diff --git a/reactos/apps/utils/net/finger/err.c b/reactos/apps/utils/net/finger/err.c
deleted file mode 100644 (file)
index 8f1cc4e..0000000
+++ /dev/null
@@ -1,138 +0,0 @@
-/*-
- * Copyright (c) 1993
- *     The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *    must display the following acknowledgement:
- *     This product includes software developed by the University of
- *     California, Berkeley and its contributors.
- * 4. Neither the name of the University nor the names of its contributors
- *    may be used to endorse or promote products derived from this software
- *    without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#if defined(LIBC_SCCS) && !defined(lint)
-static char sccsid[] = "@(#)err.c      8.1 (Berkeley) 6/4/93";
-#endif /* LIBC_SCCS and not lint */
-
-#include "err.h"
-#include <errno.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#ifdef __STDC__
-#include <stdarg.h>
-#else
-#include <varargs.h>
-#endif
-
-extern char *__progname;               /* Program name, from crt0. */
-
-void
-err(int eval, const char *fmt, ...)
-{
-       va_list ap;
-       va_start(ap, fmt);
-       verr(eval, fmt, ap);
-       va_end(ap);
-}
-
-void
-verr(int eval, const char *fmt, va_list ap)
-{
-       int sverrno;
-
-       sverrno = errno;
-       (void)fprintf(stderr, "%s: ", __progname);
-       if (fmt != NULL) {
-               (void)vfprintf(stderr, fmt, ap);
-               (void)fprintf(stderr, ": ");
-       }
-       (void)fprintf(stderr, "%s\n", strerror(sverrno));
-       exit(eval);
-}
-
-void
-errx(int eval, const char *fmt, ...)
-{
-       va_list ap;
-       va_start(ap, fmt);
-       verrx(eval, fmt, ap);
-       va_end(ap);
-}
-
-void
-verrx(int eval, const char *fmt, va_list ap)
-{
-       (void)fprintf(stderr, "%s: ", __progname);
-       if (fmt != NULL)
-               (void)vfprintf(stderr, fmt, ap);
-       (void)fprintf(stderr, "\n");
-       exit(eval);
-}
-
-void
-warn(const char *fmt, ...)
-{
-       va_list ap;
-       va_start(ap, fmt);
-       vwarn(fmt, ap);
-       va_end(ap);
-}
-
-void
-vwarn(fmt, ap)
-       const char *fmt;
-       va_list ap;
-{
-       int sverrno;
-
-       sverrno = errno;
-       (void)fprintf(stderr, "%s: ", __progname);
-       if (fmt != NULL) {
-               (void)vfprintf(stderr, fmt, ap);
-               (void)fprintf(stderr, ": ");
-       }
-       (void)fprintf(stderr, "%s\n", strerror(sverrno));
-}
-
-void
-warnx(const char *fmt, ...)
-{
-       va_list ap;
-       va_start(ap, fmt);
-       vwarnx(fmt, ap);
-       va_end(ap);
-}
-
-void
-vwarnx(fmt, ap)
-       const char *fmt;
-       va_list ap;
-{
-       (void)fprintf(stderr, "%s: ", __progname);
-       if (fmt != NULL)
-               (void)vfprintf(stderr, fmt, ap);
-       (void)fprintf(stderr, "\n");
-}
diff --git a/reactos/apps/utils/net/finger/err.h b/reactos/apps/utils/net/finger/err.h
deleted file mode 100644 (file)
index bbc7397..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-/*-
- * Copyright (c) 1993
- *     The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *    must display the following acknowledgement:
- *     This product includes software developed by the University of
- *     California, Berkeley and its contributors.
- * 4. Neither the name of the University nor the names of its contributors
- *    may be used to endorse or promote products derived from this software
- *    without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- *     @(#)err.h       8.1 (Berkeley) 6/2/93
- */
-
-#ifndef _ERR_H_
-#define        _ERR_H_
-
-/*
- * Don't use va_list in the err/warn prototypes.   Va_list is typedef'd in two
- * places (<machine/varargs.h> and <machine/stdarg.h>), so if we include one
- * of them here we may collide with the utility's includes.  It's unreasonable
- * for utilities to have to include one of them to include err.h, so we get
- * _BSD_VA_LIST_ from <machine/ansi.h> and use it.
- */
-/*#include <machine/ansi.h>*/
-/*#include <sys/cdefs.h>*/
-#include "various.h"
-#include <stdarg.h>
-
-void   err __P((int, const char *, ...));
-void   verr __P((int, const char *, va_list));
-void   errx __P((int, const char *, ...));
-void   verrx __P((int, const char *, va_list));
-void           warn __P((const char *, ...));
-void           vwarn __P((const char *, va_list));
-void           warnx __P((const char *, ...));
-void           vwarnx __P((const char *, va_list));
-
-#endif /* !_ERR_H_ */
diff --git a/reactos/apps/utils/net/finger/finger.c b/reactos/apps/utils/net/finger/finger.c
deleted file mode 100644 (file)
index 0c0e532..0000000
+++ /dev/null
@@ -1,178 +0,0 @@
-/*
- * Copyright (c) 1989, 1993
- *     The Regents of the University of California.  All rights reserved.
- *
- * This code is derived from software contributed to Berkeley by
- * Tony Nardo of the Johns Hopkins University/Applied Physics Lab.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *    must display the following acknowledgement:
- *     This product includes software developed by the University of
- *     California, Berkeley and its contributors.
- * 4. Neither the name of the University nor the names of its contributors
- *    may be used to endorse or promote products derived from this software
- *    without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- * 8/2/97 - Ted Felix <tfelix@fred.net>
- *          Ported to Win32 from 4.4BSD-LITE2 at wcarchive.
- *          NT Workstation already has finger, and it runs fine under
- *          Win95.  Thought I'd do this anyways since not everyone has
- *          access to NT.
- *          Had to remove local handling.       Otherwise, same as whois.
- */
-
-/*
- * Finger prints out information about users.  It is not portable since
- * certain fields (e.g. the full user name, office, and phone numbers) are
- * extracted from the gecos field of the passwd file which other UNIXes
- * may not have or may use for other things.
- *
- * There are currently two output formats; the short format is one line
- * per user and displays login name, tty, login time, real name, idle time,
- * and office location/phone number.  The long format gives the same
- * information (in a more legible format) as well as home directory, shell,
- * mail info, and .plan/.project files.
- */
-
-#include <winsock2.h>
-#include "err.h"
-#include <errno.h>
-#include <fcntl.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <time.h>
-
-#include "various.h"
-#include "getopt.h"
-
-char *__progname;
-
-time_t now;
-int lflag, mflag, pplan, sflag;
-
-static void userlist(int, char **);
-void usage();
-
-int
-main(int argc, char **argv)
-{
-       int ch;
-
-       while ((ch = getopt(argc, argv, "lmps")) != EOF)
-               switch(ch) {
-               case 'l':
-                       lflag = 1;              /* long format */
-                       break;
-               case 'm':
-                       mflag = 1;              /* force exact match of names */
-                       break;
-               case 'p':
-                       pplan = 1;              /* don't show .plan/.project */
-                       break;
-               case 's':
-                       sflag = 1;              /* short format */
-                       break;
-               case '?':
-               default:
-                       (void)fprintf(stderr,
-                           "usage: finger [-lmps] login [...]\n");
-                       exit(1);
-               }
-       argc -= optind;
-       argv += optind;
-
-       (void)time(&now);
-       if (!*argv) {
-               usage();
-       } else {
-               userlist(argc, argv);
-               /*
-                * Assign explicit "large" format if names given and -s not
-                * explicitly stated.  Force the -l AFTER we get names so any
-                * remote finger attempts specified won't be mishandled.
-                */
-               if (!sflag)
-                       lflag = 1;      /* if -s not explicit, force -l */
-       }
-       return 0;
-}
-
-
-static void
-userlist(int argc, char **argv)
-{
-       int *used;
-       char **ap, **nargv, **np, **p;
-       WORD wVersionRequested;
-       WSADATA wsaData;
-       int iErr;
-
-
-       if ((nargv = malloc((argc+1) * sizeof(char *))) == NULL ||
-           (used = calloc(argc, sizeof(int))) == NULL)
-               err(1, NULL);
-
-       /* Pull out all network requests into nargv. */
-       for (ap = p = argv, np = nargv; *p; ++p)
-               if (index(*p, '@'))
-                       *np++ = *p;
-               else
-                       *ap++ = *p;
-
-       *np++ = NULL;
-       *ap++ = NULL;
-
-       /* If there are local requests */
-       if (*argv)
-       {
-               fprintf(stderr, "Warning: Can't do local finger\n");
-       }
-
-       /* Start winsock */
-       wVersionRequested = MAKEWORD( 1, 1 );
-       iErr = WSAStartup( wVersionRequested, &wsaData );
-       if ( iErr != 0 )
-       {
-               /* Tell the user that we couldn't find a usable */
-               /* WinSock DLL.                                  */
-               fprintf(stderr, "WSAStartup failed\n");
-               return;
-       }
-
-       /* Handle network requests. */
-       for (p = nargv; *p;)
-               netfinger(*p++);
-
-       /* Bring down winsock */
-       WSACleanup();
-       exit(0);
-}
-
-void usage()
-{
-       (void)fprintf(stderr,
-                     "usage: finger [-lmps] login [...]\n");
-       exit(1);
-}
-
diff --git a/reactos/apps/utils/net/finger/finger.rc b/reactos/apps/utils/net/finger/finger.rc
deleted file mode 100644 (file)
index b1250a4..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-/* $Id$ */
-
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS TCP/IPv4 Win32 finger\0"
-#define REACTOS_STR_INTERNAL_NAME      "finger\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "finger.exe\0"
-#include <reactos/version.rc>
diff --git a/reactos/apps/utils/net/finger/finger.xml b/reactos/apps/utils/net/finger/finger.xml
deleted file mode 100644 (file)
index 606faad..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-<module name="finger" type="win32cui" installbase="system32" installname="finger.exe">
-       <include base="finger">.</include>
-       <define name="__USE_W32API" />
-       <define name="__USE_W32_SOCKETS" />
-       <library>kernel32</library>
-       <library>ws2_32</library>
-       <file>finger.c</file>
-       <file>err.c</file>
-       <file>getopt.c</file>
-       <file>net.c</file>
-       <file>finger.rc</file>
-</module>
diff --git a/reactos/apps/utils/net/finger/getopt.c b/reactos/apps/utils/net/finger/getopt.c
deleted file mode 100644 (file)
index ae5cc09..0000000
+++ /dev/null
@@ -1,122 +0,0 @@
-/*
- * Copyright (c) 1987 Regents of the University of California.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *    must display the following acknowledgement:
- *     This product includes software developed by the University of
- *     California, Berkeley and its contributors.
- * 4. Neither the name of the University nor the names of its contributors
- *    may be used to endorse or promote products derived from this software
- *    without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- * Fri Jun 13 10:39:00 1997, tfelix@fred.net:
- *     Ported to Win32, changed index/rindex to strchr/strrchr
- */
-
-#if defined(LIBC_SCCS) && !defined(lint)
-static char sccsid[] = "@(#)getopt.c   4.13 (Berkeley) 2/23/91";
-#endif /* LIBC_SCCS and not lint */
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include "getopt.h"
-
-/*
- * get option letter from argument vector
- */
-int    opterr = 1,             /* if error message should be printed */
-       optind = 1,             /* index into parent argv vector */
-       optopt;                 /* character checked for validity */
-const char     *optarg;                /* argument associated with option */
-
-#define        BADCH   (int)'?'
-#define        EMSG    ""
-
-int
-getopt(int nargc, char * const *nargv, const char *ostr)
-{
-       static const char *place = EMSG;                /* option letter processing */
-       register char *oli;                     /* option letter list index */
-       char *p;
-
-       if (!*place) {                          /* update scanning pointer */
-               if (optind >= nargc || *(place = nargv[optind]) != '-') {
-                       place = EMSG;
-                       return(EOF);
-               }
-               if (place[1] && *++place == '-') {      /* found "--" */
-                       ++optind;
-                       place = EMSG;
-                       return(EOF);
-               }
-       }                                       /* option letter okay? */
-       if ((optopt = (int)*place++) == (int)':' ||
-           !(oli = strchr(ostr, optopt))) {
-               /*
-                * if the user didn't specify '-' as an option,
-                * assume it means EOF.
-                */
-               if (optopt == (int)'-')
-                       return(EOF);
-               if (!*place)
-                       ++optind;
-               if (opterr) {
-                       if (!(p = strrchr(*nargv, '/')))
-                               p = *nargv;
-                       else
-                               ++p;
-                       (void)fprintf(stderr, "%s: illegal option -- %c\n",
-                           p, optopt);
-               }
-               return(BADCH);
-       }
-       if (*++oli != ':') {                    /* don't need argument */
-               optarg = NULL;
-               if (!*place)
-                       ++optind;
-       }
-       else {                                  /* need an argument */
-               if (*place)                     /* no white space */
-                       optarg = place;
-               else if (nargc <= ++optind) {   /* no arg */
-                       place = EMSG;
-                       if (!(p = strrchr(*nargv, '/')))
-                               p = *nargv;
-                       else
-                               ++p;
-                       if (opterr)
-                               (void)fprintf(stderr,
-                                   "%s: option requires an argument -- %c\n",
-                                   p, optopt);
-                       return(BADCH);
-               }
-               else                            /* white space */
-                       optarg = nargv[optind];
-               place = EMSG;
-               ++optind;
-       }
-       return(optopt);                         /* dump back option letter */
-}
diff --git a/reactos/apps/utils/net/finger/getopt.h b/reactos/apps/utils/net/finger/getopt.h
deleted file mode 100644 (file)
index 399fc2a..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-/* getopt.h */
-
-extern const char *optarg;
-extern int optind;
-
-int
-getopt(int nargc, char * const *nargv, const char *ostr);
diff --git a/reactos/apps/utils/net/finger/net.c b/reactos/apps/utils/net/finger/net.c
deleted file mode 100644 (file)
index 3362fb2..0000000
+++ /dev/null
@@ -1,139 +0,0 @@
-/*
- * Copyright (c) 1989, 1993
- *     The Regents of the University of California.  All rights reserved.
- *
- * This code is derived from software contributed to Berkeley by
- * Tony Nardo of the Johns Hopkins University/Applied Physics Lab.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *    must display the following acknowledgement:
- *     This product includes software developed by the University of
- *     California, Berkeley and its contributors.
- * 4. Neither the name of the University nor the names of its contributors
- *    may be used to endorse or promote products derived from this software
- *    without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-#include <sys/types.h>
-#include <winsock2.h>
-
-#include <stdio.h>
-#include <ctype.h>
-#include <string.h>
-
-#include "various.h"
-
-int close(int);
-
-void
-netfinger(char *name)
-{
-       extern int lflag;
-       char c, lastc;
-       struct in_addr defaddr;
-       struct hostent *hp, def;
-       struct servent *sp;
-       struct sockaddr_in sin;
-       SOCKET s;
-       char *alist[1], *host;
-
-       /* If this is a local request */
-       if (!(host = rindex(name, '@')))
-               return;
-
-       *host++ = '\0';
-       if (isdigit(*host) && (defaddr.s_addr = inet_addr(host)) != (unsigned long)-1) {
-               def.h_name = host;
-               def.h_addr_list = alist;
-               def.h_addr = (char *)&defaddr;
-               def.h_length = sizeof(struct in_addr);
-               def.h_addrtype = AF_INET;
-               def.h_aliases = 0;
-               hp = &def;
-       } else if (!(hp = gethostbyname(host))) {
-               (void)fprintf(stderr,
-                   "finger: unknown host: %s\n", host);
-               return;
-       }
-       if (!(sp = getservbyname("finger", "tcp"))) {
-               (void)fprintf(stderr, "finger: tcp/finger: unknown service\n");
-               return;
-       }
-       sin.sin_family = hp->h_addrtype;
-       bcopy(hp->h_addr, (char *)&sin.sin_addr, hp->h_length);
-       sin.sin_port = sp->s_port;
-       if ((s = socket(hp->h_addrtype, SOCK_STREAM, 0)) == INVALID_SOCKET) {
-               perror("finger: socket");
-               return;
-       }
-
-       /* have network connection; identify the host connected with */
-       (void)printf("[%s]\n", hp->h_name);
-       if (connect(s, (struct sockaddr *)&sin, sizeof(sin)) < 0) {
-               fprintf(stderr, "finger: connect rc = %d", WSAGetLastError());
-               (void)close(s);
-               return;
-       }
-
-       /* -l flag for remote fingerd  */
-       if (lflag)
-               send(s, "/W ", 3, 0);
-       /* send the name followed by <CR><LF> */
-       send(s, name, strlen(name), 0);
-       send(s, "\r\n", 2, 0);
-
-       /*
-        * Read from the remote system; once we're connected, we assume some
-        * data.  If none arrives, we hang until the user interrupts.
-        *
-        * If we see a <CR> or a <CR> with the high bit set, treat it as
-        * a newline; if followed by a newline character, only output one
-        * newline.
-        *
-        * Otherwise, all high bits are stripped; if it isn't printable and
-        * it isn't a space, we can simply set the 7th bit.  Every ASCII
-        * character with bit 7 set is printable.
-        */
-       lastc = 0;
-       while (recv(s, &c, 1, 0) == 1) {
-               c &= 0x7f;
-               if (c == 0x0d) {
-                       if (lastc == '\r')      /* ^M^M - skip dupes */
-                               continue;
-                       c = '\n';
-                       lastc = '\r';
-               } else {
-                       if (!isprint(c) && !isspace(c))
-                               c |= 0x40;
-                       if (lastc != '\r' || c != '\n')
-                               lastc = c;
-                       else {
-                               lastc = '\n';
-                               continue;
-                       }
-               }
-               putchar(c);
-       }
-       if (lastc != '\n')
-               putchar('\n');
-       putchar('\n');
-}
diff --git a/reactos/apps/utils/net/finger/various.h b/reactos/apps/utils/net/finger/various.h
deleted file mode 100644 (file)
index cb7572e..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-// Various things you need when porting BSD and GNU utilities to
-// Win32.
-
-#ifndef VARIOUS_H
-#define VARIOUS_H
-
-
-typedef float f4byte_t;
-typedef double f8byte_t;
-typedef long uid_t;  // SunOS 5.5
-
-#define __P(x) x
-
-/* utmp.h */
-#define UT_LINESIZE 8
-#define UT_HOSTSIZE 16
-
-/* stat.h */
-#define  S_ISREG(mode)   (((mode)&0xF000) == 0x8000)
-#define  S_ISDIR(mode)   (((mode)&0xF000) == 0x4000)
-
-#undef MIN //take care of windows default
-#undef MAX //take care of windows default
-#define MIN(a, b) ((a) <= (b) ? (a) : (b))
-#define MAX(a, b) ((a) > (b) ? (a) : (b))
-
-#define bcopy(s1, s2, n)  memmove(s2, s1, n)
-#define bcmp(s1, s2, n)  (memcmp(s1, s2, n) != 0)
-#define bzero(s, n)  memset(s, 0, n)
-
-#define index(s, c)  strchr(s, c)
-#define rindex(s, c)  strrchr(s, c)
-
-void netfinger(char *);
-
-#endif
diff --git a/reactos/apps/utils/net/ftp/cmds.c b/reactos/apps/utils/net/ftp/cmds.c
deleted file mode 100644 (file)
index b2763ca..0000000
+++ /dev/null
@@ -1,2373 +0,0 @@
-/*
- * Copyright (c) 1985, 1989 Regents of the University of California.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms are permitted
- * provided that the above copyright notice and this paragraph are
- * duplicated in all such forms and that any documentation,
- * advertising materials, and other materials related to such
- * distribution and use acknowledge that the software was developed
- * by the University of California, Berkeley.  The name of the
- * University may not be used to endorse or promote products derived
- * from this software without specific prior written permission.
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
- */
-
-#ifndef lint
-static char sccsid[] = "@(#)cmds.c     5.18 (Berkeley) 4/20/89";
-#endif /* not lint */
-
-/*
- * FTP User Program -- Command Routines.
- */
-//#include <sys/param.h>
-//#include <sys/wait.h>
-#include <sys/stat.h>
-#ifndef _WIN32
-#include <sys/socket.h>
-#include <arpa/ftp.h>
-#include <netinet/in.h>
-#include <netdb.h>
-#else
-#include <winsock.h>
-#endif
-
-#include <signal.h>
-#include <direct.h>
-#include <stdio.h>
-#include <errno.h>
-#include <ctype.h>
-#include <time.h>
-
-#include "ftp_var.h"
-#include "pathnames.h"
-#include "prototypes.h"
-
-extern char *globerr;
-extern char home[];
-extern char *remglob();
-extern char *getenv();
-extern int allbinary;
-extern off_t restart_point;
-extern char reply_string[];
-
-const char *mname;
-jmp_buf jabort;
-const char *dotrans(), *domap();
-
-extern short portnum;
-extern char *hostname;
-extern int autologin;
-/*
- * Connect to peer server and
- * auto-login, if possible.
- */
-void setpeer(int argc, const char *argv[])
-{
-       char *host;
-
-       if (connected) {
-               printf("Already connected to %s, use close first.\n",
-                       hostname);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(to) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc > 3) {
-               printf("usage: %s host-name [port]\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (argc > 2) {
-               portnum = atoi(argv[2]);
-               if (portnum <= 0) {
-                       printf("%s: bad port number-- %s\n", argv[1], argv[2]);
-                       printf ("usage: %s host-name [port]\n", argv[0]);
-                       (void) fflush(stdout);
-                       code = -1;
-                       return;
-               }
-               portnum = htons(portnum);
-       }
-       host = hookup(argv[1], portnum);
-       if (host) {
-#if defined(unix) && NBBY == 8
-               int overbose;
-#endif
-               connected = 1;
-               if (autologin)
-                       (void) login(argv[1]);
-
-#if defined(unix) && NBBY == 8
-/*
- * this ifdef is to keep someone form "porting" this to an incompatible
- * system and not checking this out. This way they have to think about it.
- */
-               overbose = verbose;
-               if (debug == 0)
-                       verbose = -1;
-               allbinary = 0;
-               if (command("SYST") == COMPLETE && overbose) {
-                       register char *cp, c;
-                       cp = index(reply_string+4, ' ');
-                       if (cp == NULL)
-                               cp = index(reply_string+4, '\r');
-                       if (cp) {
-                               if (cp[-1] == '.')
-                                       cp--;
-                               c = *cp;
-                               *cp = '\0';
-                       }
-
-                       printf("Remote system type is %s.\n",
-                               reply_string+4);
-                       if (cp)
-                               *cp = c;
-               }
-               if (!strncmp(reply_string, "215 UNIX Type: L8", 17)) {
-                       setbinary();
-                       /* allbinary = 1; this violates the RFC */
-                       if (overbose)
-                           printf("Using %s mode to transfer files.\n",
-                               typename);
-               } else if (overbose &&
-                   !strncmp(reply_string, "215 TOPS20", 10)) {
-                       printf(
-"Remember to set tenex mode when transfering binary files from this machine.\n");
-               }
-               verbose = overbose;
-#endif /* unix */
-       }
-       (void) fflush(stdout);
-}
-
-struct types {
-       const char      *t_name;
-       const char      *t_mode;
-       int     t_type;
-       char    *t_arg;
-} types[] = {
-       { "ascii",      "A",    TYPE_A, 0 },
-       { "binary",     "I",    TYPE_I, 0 },
-       { "image",      "I",    TYPE_I, 0 },
-       { "ebcdic",     "E",    TYPE_E, 0 },
-       { "tenex",      "L",    TYPE_L, bytename },
-       {0 }
-};
-
-/*
- * Set transfer type.
- */
-void settype(argc, argv)
-       const char *argv[];
-{
-       register struct types *p;
-       int comret;
-
-       if (argc > 2) {
-               const char *sep;
-
-               printf("usage: %s [", argv[0]);
-               sep = " ";
-               for (p = types; p->t_name; p++) {
-                       printf("%s%s", sep, p->t_name);
-                       if (*sep == ' ')
-                               sep = " | ";
-               }
-               printf(" ]\n");
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (argc < 2) {
-               printf("Using %s mode to transfer files.\n", typename);
-               (void) fflush(stdout);
-               code = 0;
-               return;
-       }
-       for (p = types; p->t_name; p++)
-               if (strcmp(argv[1], p->t_name) == 0)
-                       break;
-       if (p->t_name == 0) {
-               printf("%s: unknown mode\n", argv[1]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if ((p->t_arg != NULL) && (*(p->t_arg) != '\0'))
-               comret = command ("TYPE %s %s", p->t_mode, p->t_arg);
-       else
-               comret = command("TYPE %s", p->t_mode);
-       if (comret == COMPLETE) {
-               (void) strcpy(typename, p->t_name);
-               type = p->t_type;
-       }
-}
-
-const char *stype[] = {
-       "type",
-       "",
-       0
-};
-
-/*
- * Set binary transfer type.
- */
-/*VARARGS*/
-void setbinary()
-{
-       stype[1] = "binary";
-       settype(2, stype);
-}
-
-/*
- * Set ascii transfer type.
- */
-/*VARARGS*/
-void setascii()
-{
-       stype[1] = "ascii";
-       settype(2, stype);
-}
-
-/*
- * Set tenex transfer type.
- */
-/*VARARGS*/
-void settenex()
-{
-       stype[1] = "tenex";
-       settype(2, stype);
-}
-
-/*
- * Set ebcdic transfer type.
- */
-/*VARARGS*/
-void setebcdic()
-{
-       stype[1] = "ebcdic";
-       settype(2, stype);
-}
-
-/*
- * Set file transfer mode.
- */
-
-/*ARGSUSED*/
-void fsetmode(argc, argv)
-       char *argv[];
-{
-
-       printf("We only support %s mode, sorry.\n", modename);
-       (void) fflush(stdout);
-       code = -1;
-}
-
-
-/*
- * Set file transfer format.
- */
-/*ARGSUSED*/
-void setform(argc, argv)
-       char *argv[];
-{
-
-       printf("We only support %s format, sorry.\n", formname);
-       (void) fflush(stdout);
-       code = -1;
-}
-
-/*
- * Set file transfer structure.
- */
-/*ARGSUSED*/
-void setstruct(argc, argv)
-       char *argv[];
-{
-
-       printf("We only support %s structure, sorry.\n", structname);
-       (void) fflush(stdout);
-       code = -1;
-}
-
-/*
- * Send a single file.
- */
-void put(argc, argv)
-       int argc;
-       const char *argv[];
-{
-       const char *cmd;
-       int loc = 0;
-       const char *oldargv1, *oldargv2;
-
-       if (argc == 2) {
-               argc++;
-               argv[2] = argv[1];
-               loc++;
-       }
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(local-file) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-usage:
-               printf("usage:%s local-file remote-file\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (argc < 3) {
-               (void) strcat(line, " ");
-               printf("(remote-file) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 3)
-               goto usage;
-       oldargv1 = argv[1];
-       oldargv2 = argv[2];
-       if (!globulize(&argv[1])) {
-               code = -1;
-               return;
-       }
-       /*
-        * If "globulize" modifies argv[1], and argv[2] is a copy of
-        * the old argv[1], make it a copy of the new argv[1].
-        */
-       if (argv[1] != oldargv1 && argv[2] == oldargv1) {
-               argv[2] = argv[1];
-       }
-       cmd = (argv[0][0] == 'a') ? "APPE" : ((sunique) ? "STOU" : "STOR");
-       if (loc && ntflag) {
-               argv[2] = dotrans(argv[2]);
-       }
-       if (loc && mapflag) {
-               argv[2] = domap(argv[2]);
-       }
-       sendrequest(cmd, argv[1], argv[2],
-           argv[1] != oldargv1 || argv[2] != oldargv2);
-}
-
-/*
- * Send multiple files.
- */
-void mput(argc, argv)
-       const char *argv[];
-{
-       register int i;
-       int ointer;
-       extern jmp_buf jabort;
-       const char *tp;
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(local-files) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage:%s local-files\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       mname = argv[0];
-       mflag = 1;
-//     oldintr = signal(SIGINT, mabort);
-       (void) setjmp(jabort);
-       if (proxy) {
-               char *cp, *tp2, tmpbuf[MAXPATHLEN];
-
-               while ((cp = remglob(argv,0)) != NULL) {
-                       if (*cp == 0) {
-                               mflag = 0;
-                               continue;
-                       }
-                       if (mflag && confirm(argv[0], cp)) {
-                               tp = cp;
-                               if (mcase) {
-                                       while (*tp && !islower(*tp)) {
-                                               tp++;
-                                       }
-                                       if (!*tp) {
-                                               tp = cp;
-                                               tp2 = tmpbuf;
-                                               while ((*tp2 = *tp) != (int) NULL) {
-                                                    if (isupper(*tp2)) {
-                                                       *tp2 = 'a' + *tp2 - 'A';
-                                                    }
-                                                    tp++;
-                                                    tp2++;
-                                               }
-                                       }
-                                       tp = tmpbuf;
-                               }
-                               if (ntflag) {
-                                       tp = dotrans(tp);
-                               }
-                               if (mapflag) {
-                                       tp = domap(tp);
-                               }
-                               sendrequest((sunique) ? "STOU" : "STOR",
-                                   cp, tp, cp != tp || !interactive);
-                               if (!mflag && fromatty) {
-                                       ointer = interactive;
-                                       interactive = 1;
-                                       if (confirm("Continue with","mput")) {
-                                               mflag++;
-                                       }
-                                       interactive = ointer;
-                               }
-                       }
-               }
-//             (void) signal(SIGINT, oldintr);
-               mflag = 0;
-               return;
-       }
-       for (i = 1; i < argc; i++) {
-               register char **cpp, **gargs;
-
-               if (!doglob) {
-                       if (mflag && confirm(argv[0], argv[i])) {
-                               tp = (ntflag) ? dotrans(argv[i]) : argv[i];
-                               tp = (mapflag) ? domap(tp) : tp;
-                               sendrequest((sunique) ? "STOU" : "STOR",
-                                   argv[i], tp, tp != argv[i] || !interactive);
-                               if (!mflag && fromatty) {
-                                       ointer = interactive;
-                                       interactive = 1;
-                                       if (confirm("Continue with","mput")) {
-                                               mflag++;
-                                       }
-                                       interactive = ointer;
-                               }
-                       }
-                       continue;
-               }
-               gargs = glob(argv[i]);
-               if (globerr != NULL) {
-                       printf("%s\n", globerr);
-                       (void) fflush(stdout);
-                       if (gargs) {
-                               blkfree(gargs);
-                               free((char *)gargs);
-                       }
-                       continue;
-               }
-               for (cpp = gargs; cpp && *cpp != NULL; cpp++) {
-                       if (mflag && confirm(argv[0], *cpp)) {
-                               tp = (ntflag) ? dotrans(*cpp) : *cpp;
-                               tp = (mapflag) ? domap(tp) : tp;
-                               sendrequest((sunique) ? "STOU" : "STOR",
-                                   *cpp, tp, *cpp != tp || !interactive);
-                               if (!mflag && fromatty) {
-                                       ointer = interactive;
-                                       interactive = 1;
-                                       if (confirm("Continue with","mput")) {
-                                               mflag++;
-                                       }
-                                       interactive = ointer;
-                               }
-                       }
-               }
-               if (gargs != NULL) {
-                       blkfree(gargs);
-                       free((char *)gargs);
-               }
-       }
-//     (void) signal(SIGINT, oldintr);
-       mflag = 0;
-}
-
-void reget(argc, argv)
-       const char *argv[];
-{
-       (void) getit(argc, argv, 1, "r+w");
-}
-
-void get(argc, argv)
-       const char *argv[];
-{
-       (void) getit(argc, argv, 0, restart_point ? "r+w" : "w" );
-}
-
-/*
- * Receive one file.
- */
-int getit(argc, argv, restartit, mode)
-       const char *argv[];
-       const char *mode;
-{
-       int loc = 0;
-       const char *oldargv1, *oldargv2;
-
-       if (argc == 2) {
-               argc++;
-               argv[2] = argv[1];
-               loc++;
-       }
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(remote-file) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-usage:
-               printf("usage: %s remote-file [ local-file ]\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return (0);
-       }
-       if (argc < 3) {
-               (void) strcat(line, " ");
-               printf("(local-file) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 3)
-               goto usage;
-       oldargv1 = argv[1];
-       oldargv2 = argv[2];
-       if (!globulize(&argv[2])) {
-               code = -1;
-               return (0);
-       }
-       if (loc && mcase) {
-               const char *tp = argv[1];
-        char *tp2, tmpbuf[MAXPATHLEN];
-
-               while (*tp && !islower(*tp)) {
-                       tp++;
-               }
-               if (!*tp) {
-                       tp = argv[2];
-                       tp2 = tmpbuf;
-                       while ((*tp2 = *tp) != (int) NULL) {
-                               if (isupper(*tp2)) {
-                                       *tp2 = 'a' + *tp2 - 'A';
-                               }
-                               tp++;
-                               tp2++;
-                       }
-                       argv[2] = tmpbuf;
-               }
-       }
-       if (loc && ntflag)
-               argv[2] = dotrans(argv[2]);
-       if (loc && mapflag)
-               argv[2] = domap(argv[2]);
-       if (restartit) {
-               struct stat stbuf;
-               int ret;
-
-               ret = stat(argv[2], &stbuf);
-               if (restartit == 1) {
-                       if (ret < 0) {
-                               perror(argv[2]);
-                               return (0);
-                       }
-                       restart_point = stbuf.st_size;
-               } else {
-                       if (ret == 0) {
-                               int overbose;
-
-                               overbose = verbose;
-                               if (debug == 0)
-                                       verbose = -1;
-                               if (command("MDTM %s", argv[1]) == COMPLETE) {
-                                       int yy, mo, day, hour, min, sec;
-                                       struct tm *tm;
-                                       verbose = overbose;
-                                       sscanf(reply_string,
-                                           "%*s %04d%02d%02d%02d%02d%02d",
-                                           &yy, &mo, &day, &hour, &min, &sec);
-                                       tm = gmtime(&stbuf.st_mtime);
-                                       tm->tm_mon++;
-                                       if (tm->tm_year > yy%100)
-                                               return (1);
-                                       else if (tm->tm_year == yy%100) {
-                                               if (tm->tm_mon > mo)
-                                                       return (1);
-                                       } else if (tm->tm_mon == mo) {
-                                               if (tm->tm_mday > day)
-                                                       return (1);
-                                       } else if (tm->tm_mday == day) {
-                                               if (tm->tm_hour > hour)
-                                                       return (1);
-                                       } else if (tm->tm_hour == hour) {
-                                               if (tm->tm_min > min)
-                                                       return (1);
-                                       } else if (tm->tm_min == min) {
-                                               if (tm->tm_sec > sec)
-                                                       return (1);
-                                       }
-                               } else {
-                                       printf("%s\n", reply_string);
-                                       (void) fflush(stdout);
-                                       verbose = overbose;
-                                       return (0);
-                               }
-                       }
-               }
-       }
-
-       recvrequest("RETR", argv[2], argv[1], mode,
-           argv[1] != oldargv1 || argv[2] != oldargv2);
-       restart_point = 0;
-       return (0);
-}
-
-#if 0
-static void
-mabort()
-{
-       int ointer;
-       extern jmp_buf jabort;
-
-       printf("\n");
-       (void) fflush(stdout);
-       if (mflag && fromatty) {
-               ointer = interactive;
-               interactive = 1;
-               if (confirm("Continue with", mname)) {
-                       interactive = ointer;
-                       longjmp(jabort,0);
-               }
-               interactive = ointer;
-       }
-       mflag = 0;
-       longjmp(jabort,0);
-}
-#endif
-
-/*
- * Get multiple files.
- */
-void mget(argc, argv)
-       const char *argv[];
-{
-       const char *cp, *tp;
-    char *tp2, tmpbuf[MAXPATHLEN];
-       int ointer;
-       extern jmp_buf jabort;
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(remote-files) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage:%s remote-files\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       mname = argv[0];
-       mflag = 1;
-//     oldintr = signal(SIGINT,mabort);
-       (void) setjmp(jabort);
-       while ((cp = remglob(argv,proxy)) != NULL) {
-               if (*cp == '\0') {
-                       mflag = 0;
-                       continue;
-               }
-               if (mflag && confirm(argv[0], cp)) {
-                       tp = cp;
-                       if (mcase) {
-                               while (*tp && !islower(*tp)) {
-                                       tp++;
-                               }
-                               if (!*tp) {
-                                       tp = cp;
-                                       tp2 = tmpbuf;
-                                       while ((*tp2 = *tp) != (int) NULL) {
-                                               if (isupper(*tp2)) {
-                                                       *tp2 = 'a' + *tp2 - 'A';
-                                               }
-                                               tp++;
-                                               tp2++;
-                                       }
-                               }
-                               tp = tmpbuf;
-                       }
-                       if (ntflag) {
-                               tp = dotrans(tp);
-                       }
-                       if (mapflag) {
-                               tp = domap(tp);
-                       }
-                       recvrequest("RETR", tp, cp, "w",
-                           tp != cp || !interactive);
-                       if (!mflag && fromatty) {
-                               ointer = interactive;
-                               interactive = 1;
-                               if (confirm("Continue with","mget")) {
-                                       mflag++;
-                               }
-                               interactive = ointer;
-                       }
-               }
-       }
-//     (void) signal(SIGINT,oldintr);
-       mflag = 0;
-}
-
-char *
-remglob(argv,doswitch)
-       char *argv[];
-       int doswitch;
-{
-       char temp[16];
-       static char buf[MAXPATHLEN];
-       static FILE *ftemp = NULL;
-       static char **args;
-       int oldverbose, oldhash;
-       char *cp;
-    const char *mode;
-
-       if (!mflag) {
-               if (!doglob) {
-                       args = NULL;
-               }
-               else {
-                       if (ftemp) {
-                               (void) fclose(ftemp);
-                               ftemp = NULL;
-                       }
-               }
-               return(NULL);
-       }
-       if (!doglob) {
-               if (args == NULL)
-                       args = argv;
-               if ((cp = *++args) == NULL)
-                       args = NULL;
-               return (cp);
-       }
-       if (ftemp == NULL) {
-               (void) strcpy(temp, _PATH_TMP);
-               (void) mktemp(temp);
-               oldverbose = verbose, verbose = 0;
-               oldhash = hash, hash = 0;
-               if (doswitch) {
-                       pswitch(!proxy);
-               }
-               for (mode = "w"; *++argv != NULL; mode = "a")
-                       recvrequest ("NLST", temp, *argv, mode, 0);
-               if (doswitch) {
-                       pswitch(!proxy);
-               }
-               verbose = oldverbose; hash = oldhash;
-               ftemp = fopen(temp, "r");
-               (void) unlink(temp);
-               if (ftemp == NULL) {
-                       printf("can't find list of remote files, oops\n");
-                       (void) fflush(stdout);
-                       return (NULL);
-               }
-       }
-       if (fgets(buf, sizeof (buf), ftemp) == NULL) {
-               (void) fclose(ftemp), ftemp = NULL;
-               return (NULL);
-       }
-       if ((cp = index(buf, '\n')) != NULL)
-               *cp = '\0';
-       return (buf);
-}
-
-static const char *
-onoff(bool)
-       int bool;
-{
-
-       return (bool ? "on" : "off");
-}
-
-/*
- * Show status.
- */
-/*ARGSUSED*/
-void status(argc, argv)
-       char *argv[];
-{
-       int i;
-
-       if (connected)
-               printf("Connected to %s.\n", hostname);
-       else
-               printf("Not connected.\n");
-       if (!proxy) {
-               pswitch(1);
-               if (connected) {
-                       printf("Connected for proxy commands to %s.\n", hostname);
-               }
-               else {
-                       printf("No proxy connection.\n");
-               }
-               pswitch(0);
-       }
-       printf("Mode: %s; Type: %s; Form: %s; Structure: %s\n",
-               modename, typename, formname, structname);
-       printf("Verbose: %s; Bell: %s; Prompting: %s; Globbing: %s\n",
-               onoff(verbose), onoff(bell), onoff(interactive),
-               onoff(doglob));
-       printf("Store unique: %s; Receive unique: %s\n", onoff(sunique),
-               onoff(runique));
-       printf("Case: %s; CR stripping: %s\n",onoff(mcase),onoff(crflag));
-       if (ntflag) {
-               printf("Ntrans: (in) %s (out) %s\n", ntin,ntout);
-       }
-       else {
-               printf("Ntrans: off\n");
-       }
-       if (mapflag) {
-               printf("Nmap: (in) %s (out) %s\n", mapin, mapout);
-       }
-       else {
-               printf("Nmap: off\n");
-       }
-       printf("Hash mark printing: %s; Use of PORT cmds: %s\n",
-               onoff(hash), onoff(sendport));
-       if (macnum > 0) {
-               printf("Macros:\n");
-               for (i=0; i<macnum; i++) {
-                       printf("\t%s\n",macros[i].mac_name);
-               }
-       }
-       (void) fflush(stdout);
-       code = 0;
-}
-
-/*
- * Set beep on cmd completed mode.
- */
-/*VARARGS*/
-void setbell()
-{
-
-       bell = !bell;
-       printf("Bell mode %s.\n", onoff(bell));
-       (void) fflush(stdout);
-       code = bell;
-}
-
-/*
- * Turn on packet tracing.
- */
-/*VARARGS*/
-void settrace()
-{
-
-       trace = !trace;
-       printf("Packet tracing %s.\n", onoff(trace));
-       (void) fflush(stdout);
-       code = trace;
-}
-
-/*
- * Toggle hash mark printing during transfers.
- */
-/*VARARGS*/
-void sethash()
-{
-
-       hash = !hash;
-       printf("Hash mark printing %s", onoff(hash));
-       code = hash;
-       if (hash)
-               printf(" (%d bytes/hash mark)", 1024);
-       printf(".\n");
-       (void) fflush(stdout);
-}
-
-/*
- * Turn on printing of server echo's.
- */
-/*VARARGS*/
-void setverbose()
-{
-
-       verbose = !verbose;
-       printf("Verbose mode %s.\n", onoff(verbose));
-       (void) fflush(stdout);
-       code = verbose;
-}
-
-/*
- * Toggle PORT cmd use before each data connection.
- */
-/*VARARGS*/
-void setport()
-{
-
-       sendport = !sendport;
-       printf("Use of PORT cmds %s.\n", onoff(sendport));
-       (void) fflush(stdout);
-       code = sendport;
-}
-
-/*
- * Turn on interactive prompting
- * during mget, mput, and mdelete.
- */
-/*VARARGS*/
-void setprompt()
-{
-
-       interactive = !interactive;
-       printf("Interactive mode %s.\n", onoff(interactive));
-       (void) fflush(stdout);
-       code = interactive;
-}
-
-/*
- * Toggle metacharacter interpretation
- * on local file names.
- */
-/*VARARGS*/
-void setglob()
-{
-
-       doglob = !doglob;
-       printf("Globbing %s.\n", onoff(doglob));
-       (void) fflush(stdout);
-       code = doglob;
-}
-
-/*
- * Set debugging mode on/off and/or
- * set level of debugging.
- */
-/*VARARGS*/
-void setdebug(argc, argv)
-       char *argv[];
-{
-       int val;
-
-       if (argc > 1) {
-               val = atoi(argv[1]);
-               if (val < 0) {
-                       printf("%s: bad debugging value.\n", argv[1]);
-                       (void) fflush(stdout);
-                       code = -1;
-                       return;
-               }
-       } else
-               val = !debug;
-       debug = val;
-       if (debug)
-               options |= SO_DEBUG;
-       else
-               options &= ~SO_DEBUG;
-       printf("Debugging %s (debug=%d).\n", onoff(debug), debug);
-       (void) fflush(stdout);
-       code = debug > 0;
-}
-
-/*
- * Set current working directory
- * on remote machine.
- */
-void cd(argc, argv)
-       const char *argv[];
-{
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(remote-directory) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage:%s remote-directory\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (command("CWD %s", argv[1]) == ERROR && code == 500) {
-               if (verbose) {
-                       printf("CWD command not recognized, trying XCWD\n");
-                       (void) fflush(stdout);
-               }
-               (void) command("XCWD %s", argv[1]);
-       }
-}
-
-/*
- * Set current working directory
- * on local machine.
- */
-void lcd(argc, argv)
-       const char *argv[];
-{
-       char buf[MAXPATHLEN];
-
-       if (argc < 2)
-               argc++, argv[1] = home;
-       if (argc != 2) {
-               printf("usage:%s local-directory\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (!globulize(&argv[1])) {
-               code = -1;
-               return;
-       }
-       if (chdir(argv[1]) < 0) {
-               perror(argv[1]);
-               code = -1;
-               return;
-       }
-       printf("Local directory now %s\n", getcwd(buf,sizeof(buf)));
-       (void) fflush(stdout);
-       code = 0;
-}
-
-/*
- * Delete a single file.
- */
-void delete(argc, argv)
-       const char *argv[];
-{
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(remote-file) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage:%s remote-file\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       (void) command("DELE %s", argv[1]);
-}
-
-/*
- * Delete multiple files.
- */
-void mdelete(argc, argv)
-       const char *argv[];
-{
-       char *cp;
-       int ointer;
-       extern jmp_buf jabort;
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(remote-files) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage:%s remote-files\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       mname = argv[0];
-       mflag = 1;
-//     oldintr = signal(SIGINT, mabort);
-       (void) setjmp(jabort);
-       while ((cp = remglob(argv,0)) != NULL) {
-               if (*cp == '\0') {
-                       mflag = 0;
-                       continue;
-               }
-               if (mflag && confirm(argv[0], cp)) {
-                       (void) command("DELE %s", cp);
-                       if (!mflag && fromatty) {
-                               ointer = interactive;
-                               interactive = 1;
-                               if (confirm("Continue with", "mdelete")) {
-                                       mflag++;
-                               }
-                               interactive = ointer;
-                       }
-               }
-       }
-//     (void) signal(SIGINT, oldintr);
-       mflag = 0;
-}
-
-/*
- * Rename a remote file.
- */
-void renamefile(argc, argv)
-       const char *argv[];
-{
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(from-name) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-usage:
-               printf("%s from-name to-name\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (argc < 3) {
-               (void) strcat(line, " ");
-               printf("(to-name) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 3)
-               goto usage;
-       if (command("RNFR %s", argv[1]) == CONTINUE)
-               (void) command("RNTO %s", argv[2]);
-}
-
-/*
- * Get a directory listing
- * of remote files.
- */
-void ls(argc, argv)
-       const char *argv[];
-{
-       const char *cmd;
-
-       if (argc < 2)
-               argc++, argv[1] = NULL;
-       if (argc < 3)
-               argc++, argv[2] = "-";
-       if (argc > 3) {
-               printf("usage: %s remote-directory local-file\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       cmd = argv[0][0] == 'n' ? "NLST" : "LIST";
-//     cmd = argv[0][0] == 'n' ? "NLST -CF" : "NLST -CF";
-       if (strcmp(argv[2], "-") && !globulize(&argv[2])) {
-               code = -1;
-               return;
-       }
-       if (strcmp(argv[2], "-") && *argv[2] != '|')
-               if (!globulize(&argv[2]) || !confirm("output to local-file:", argv[2])) {
-                       code = -1;
-                       return;
-       }
-       recvrequest(cmd, argv[2], argv[1], "w", 0);
-}
-
-/*
- * Get a directory listing
- * of multiple remote files.
- */
-void mls(argc, argv)
-       const char *argv[];
-{
-       const char *cmd, *dest;
-       char mode[1];
-       int ointer, i;
-       extern jmp_buf jabort;
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(remote-files) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 3) {
-               (void) strcat(line, " ");
-               printf("(local-file) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 3) {
-               printf("usage:%s remote-files local-file\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       dest = argv[argc - 1];
-       argv[argc - 1] = NULL;
-       if (strcmp(dest, "-") && *dest != '|')
-               if (!globulize(&dest) || !confirm("output to local-file:", dest)) {
-                       code = -1;
-                       return;
-       }
-       cmd = argv[0][1] == 'l' ? "NLST" : "LIST";
-       mname = argv[0];
-       mflag = 1;
-//     oldintr = signal(SIGINT, mabort);
-       (void) setjmp(jabort);
-       for (i = 1; mflag && i < argc-1; ++i) {
-               *mode = (i == 1) ? 'w' : 'a';
-               recvrequest(cmd, dest, argv[i], mode, 0);
-               if (!mflag && fromatty) {
-                       ointer = interactive;
-                       interactive = 1;
-                       if (confirm("Continue with", argv[0])) {
-                               mflag ++;
-                       }
-                       interactive = ointer;
-               }
-       }
-//     (void) signal(SIGINT, oldintr);
-       mflag = 0;
-}
-
-/*
- * Do a shell escape
- */
-/*ARGSUSED*/
-void shell(argc, argv)
-       char *argv[];
-{
-#if 0
-       int pid;
-       sig_t (*old1)(), (*old2)();
-       char shellnam[40], *shell, *namep;
-       union wait status;
-
-       old1 = signal (SIGINT, SIG_IGN);
-       old2 = signal (SIGQUIT, SIG_IGN);
-       if ((pid = fork()) == 0) {
-               for (pid = 3; pid < 20; pid++)
-                       (void) close(pid);
-               (void) signal(SIGINT, SIG_DFL);
-               (void) signal(SIGQUIT, SIG_DFL);
-               shell = getenv("SHELL");
-               if (shell == NULL)
-                       shell = _PATH_BSHELL;
-               namep = rindex(shell,'/');
-               if (namep == NULL)
-                       namep = shell;
-               (void) strcpy(shellnam,"-");
-               (void) strcat(shellnam, ++namep);
-               if (strcmp(namep, "sh") != 0)
-                       shellnam[0] = '+';
-               if (debug) {
-                       printf ("%s\n", shell);
-                       (void) fflush (stdout);
-               }
-               if (argc > 1) {
-                       execl(shell,shellnam,"-c",altarg,(char *)0);
-               }
-               else {
-                       execl(shell,shellnam,(char *)0);
-               }
-               perror(shell);
-               code = -1;
-               exit(1);
-               }
-       if (pid > 0)
-               while (wait(&status) != pid)
-                       ;
-       (void) signal(SIGINT, old1);
-       (void) signal(SIGQUIT, old2);
-       if (pid == -1) {
-               perror("Try again later");
-               code = -1;
-       }
-       else {
-               code = 0;
-       }
-#endif
-
-    char *              AppName;
-    char                ShellCmd[MAX_PATH];
-    char                CmdLine[MAX_PATH];
-    int                 i;
-    PROCESS_INFORMATION ProcessInformation;
-    BOOL                Result;
-    STARTUPINFO         StartupInfo;
-    char                ShellName[] = "COMSPEC";
-    int                 NumBytes;
-
-    NumBytes = GetEnvironmentVariable( ShellName, ShellCmd, MAX_PATH);
-
-    if (NumBytes == 0)
-    {
-        return;
-    }
-
-    AppName = ShellCmd;
-    strcpy( CmdLine, ShellCmd );
-
-    if (argc > 1)
-    {
-        strncat(CmdLine, " /C", MAX_PATH);
-    }
-
-    for (i=1; i<argc; i++)
-    {
-        strncat(CmdLine, " ", MAX_PATH);
-        strncat(CmdLine, argv[i], MAX_PATH);
-    }
-
-    StartupInfo.cb          = sizeof( StartupInfo );
-    StartupInfo.lpReserved  = NULL;
-    StartupInfo.lpDesktop   = NULL;
-    StartupInfo.lpTitle     = NULL;
-    StartupInfo.dwX         = 0;
-    StartupInfo.dwY         = 0;
-    StartupInfo.dwXSize     = 0;
-    StartupInfo.dwYSize     = 0;
-    StartupInfo.dwFlags     = 0;
-    StartupInfo.wShowWindow = 0;
-    StartupInfo.cbReserved2 = 0;
-    StartupInfo.lpReserved2 = NULL;
-
-    Result = CreateProcess( AppName,                // cmd name
-                            CmdLine,                // cmd line arguments
-                            NULL,
-                            NULL,                   // security attributes
-                            FALSE,                  // inherit flags
-                            0,                      // Creation flags
-                            NULL,                   // Environment
-                            NULL,                   // Current directory
-                            &StartupInfo,           // Startup info structure
-                            &ProcessInformation);   // processInfo structure
-
-    if (Result)
-    {
-        WaitForSingleObject( ProcessInformation.hProcess, 0xffffffff);
-
-        CloseHandle( ProcessInformation.hProcess);
-    }
-}
-
-/*
- * Send new user information (re-login)
- */
-void user(argc, argv)
-       int argc;
-       const char **argv;
-{
-       char acct[80], *getpass();
-       int n, aflag = 0;
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(username) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc > 4) {
-               printf("usage: %s username [password] [account]\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       n = command("USER %s", argv[1]);
-       if (n == CONTINUE) {
-               if (argc < 3 )
-                       argv[2] = getpass("Password: "), argc++;
-               n = command("PASS %s", argv[2]);
-       }
-       if (n == CONTINUE) {
-               if (argc < 4) {
-                       printf("Account: "); (void) fflush(stdout);
-                       (void) fflush(stdout);
-                       (void) fgets(acct, sizeof(acct) - 1, stdin);
-                       acct[strlen(acct) - 1] = '\0';
-                       argv[3] = acct; argc++;
-               }
-               n = command("ACCT %s", argv[3]);
-               aflag++;
-       }
-       if (n != COMPLETE) {
-               fprintf(stdout, "Login failed.\n");
-               (void) fflush(stdout);
-               return;
-       }
-       if (!aflag && argc == 4) {
-               (void) command("ACCT %s", argv[3]);
-       }
-}
-
-/*
- * Print working directory.
- */
-/*VARARGS*/
-void pwd()
-{
-       int oldverbose = verbose;
-
-       /*
-        * If we aren't verbose, this doesn't do anything!
-        */
-       verbose = 1;
-       if (command("PWD") == ERROR && code == 500) {
-               printf("PWD command not recognized, trying XPWD\n");
-               (void) fflush(stdout);
-               (void) command("XPWD");
-       }
-       verbose = oldverbose;
-}
-
-/*
- * Make a directory.
- */
-void makedir(argc, argv)
-       const char *argv[];
-{
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(directory-name) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage: %s directory-name\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (command("MKD %s", argv[1]) == ERROR && code == 500) {
-               if (verbose) {
-                       printf("MKD command not recognized, trying XMKD\n");
-                       (void) fflush(stdout);
-               }
-               (void) command("XMKD %s", argv[1]);
-       }
-}
-
-/*
- * Remove a directory.
- */
-void removedir(argc, argv)
-       const char *argv[];
-{
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(directory-name) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage: %s directory-name\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (command("RMD %s", argv[1]) == ERROR && code == 500) {
-               if (verbose) {
-                       printf("RMD command not recognized, trying XRMD\n");
-                       (void) fflush(stdout);
-               }
-               (void) command("XRMD %s", argv[1]);
-       }
-}
-
-/*
- * Send a line, verbatim, to the remote machine.
- */
-void quote(argc, argv)
-       const char *argv[];
-{
-       int i;
-       char buf[BUFSIZ];
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(command line to send) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage: %s line-to-send\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       (void) strcpy(buf, argv[1]);
-       for (i = 2; i < argc; i++) {
-               (void) strcat(buf, " ");
-               (void) strcat(buf, argv[i]);
-       }
-       if (command(buf) == PRELIM) {
-               while (getreply(0) == PRELIM);
-       }
-}
-
-/*
- * Send a SITE command to the remote machine.  The line
- * is sent almost verbatim to the remote machine, the
- * first argument is changed to SITE.
- */
-
-void site(argc, argv)
-       const char *argv[];
-{
-       int i;
-       char buf[BUFSIZ];
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(arguments to SITE command) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage: %s line-to-send\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       (void) strcpy(buf, "SITE ");
-       (void) strcat(buf, argv[1]);
-       for (i = 2; i < argc; i++) {
-               (void) strcat(buf, " ");
-               (void) strcat(buf, argv[i]);
-       }
-       if (command(buf) == PRELIM) {
-               while (getreply(0) == PRELIM);
-       }
-}
-
-void do_chmod(argc, argv)
-       const char *argv[];
-{
-       if (argc == 2) {
-               printf("usage: %s mode file-name\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (argc < 3) {
-               (void) strcat(line, " ");
-               printf("(mode and file-name) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc != 3) {
-               printf("usage: %s mode file-name\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       (void)command("SITE CHMOD %s %s", argv[1], argv[2]);
-}
-
-void do_umask(argc, argv)
-       char *argv[];
-{
-       int oldverbose = verbose;
-
-       verbose = 1;
-       (void) command(argc == 1 ? "SITE UMASK" : "SITE UMASK %s", argv[1]);
-       verbose = oldverbose;
-}
-
-void idle(argc, argv)
-       char *argv[];
-{
-       int oldverbose = verbose;
-
-       verbose = 1;
-       (void) command(argc == 1 ? "SITE IDLE" : "SITE IDLE %s", argv[1]);
-       verbose = oldverbose;
-}
-
-/*
- * Ask the other side for help.
- */
-void rmthelp(argc, argv)
-       char *argv[];
-{
-       int oldverbose = verbose;
-
-       verbose = 1;
-       (void) command(argc == 1 ? "HELP" : "HELP %s", argv[1]);
-       verbose = oldverbose;
-}
-
-/*
- * Terminate session and exit.
- */
-/*VARARGS*/
-void quit()
-{
-
-       if (connected)
-               disconnect();
-       pswitch(1);
-       if (connected) {
-               disconnect();
-       }
-       exit(0);
-}
-
-/*
- * Terminate session, but don't exit.
- */
-void disconnect()
-{
-       extern int cout;
-       extern int data;
-
-       if (!connected)
-               return;
-       (void) command("QUIT");
-       cout = (int) NULL;
-       connected = 0;
-       data = -1;
-       if (!proxy) {
-               macnum = 0;
-       }
-}
-
-int confirm(cmd, file)
-       const char *cmd, *file;
-{
-       char line[BUFSIZ];
-
-       if (!interactive)
-               return (1);
-       printf("%s %s? ", cmd, file);
-       (void) fflush(stdout);
-       (void) gets(line);
-       return (*line != 'n' && *line != 'N');
-}
-
-#if 0
-static void fatal(msg)
-       char *msg;
-{
-
-       fprintf(stderr, "ftp: %s\n", msg);
-       exit(1);
-}
-#endif
-
-/*
- * Glob a local file name specification with
- * the expectation of a single return value.
- * Can't control multiple values being expanded
- * from the expression, we return only the first.
- */
-int globulize(cpp)
-       const char **cpp;
-{
-       char **globbed;
-
-       if (!doglob)
-               return (1);
-       globbed = glob(*cpp);
-       if (globerr != NULL) {
-               printf("%s: %s\n", *cpp, globerr);
-               (void) fflush(stdout);
-               if (globbed) {
-                       blkfree(globbed);
-                       free((char *)globbed);
-               }
-               return (0);
-       }
-       if (globbed) {
-               *cpp = *globbed++;
-               /* don't waste too much memory */
-               if (*globbed) {
-                       blkfree(globbed);
-                       free((char *)globbed);
-               }
-       }
-       return (1);
-}
-
-void account(argc,argv)
-       int argc;
-       char **argv;
-{
-       char acct[50], *getpass(), *ap;
-
-       if (argc > 1) {
-               ++argv;
-               --argc;
-               (void) strncpy(acct,*argv,49);
-               acct[49] = '\0';
-               while (argc > 1) {
-                       --argc;
-                       ++argv;
-                       (void) strncat(acct,*argv, 49-strlen(acct));
-               }
-               ap = acct;
-       }
-       else {
-               ap = getpass("Account:");
-       }
-       (void) command("ACCT %s", ap);
-}
-
-jmp_buf abortprox;
-
-#if 0
-static void
-proxabort()
-{
-       extern int proxy;
-
-       if (!proxy) {
-               pswitch(1);
-       }
-       if (connected) {
-               proxflag = 1;
-       }
-       else {
-               proxflag = 0;
-       }
-       pswitch(0);
-       longjmp(abortprox,1);
-}
-#endif
-
-void doproxy(argc,argv)
-       int argc;
-       const char *argv[];
-{
-       register struct cmd *c;
-       struct cmd *getcmd();
-//     extern struct cmd cmdtab[];
-       extern jmp_buf abortprox;
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(command) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage:%s command\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       c = getcmd(argv[1]);
-       if (c == (struct cmd *) -1) {
-               printf("?Ambiguous command\n");
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (c == 0) {
-               printf("?Invalid command\n");
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (!c->c_proxy) {
-               printf("?Invalid proxy command\n");
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (setjmp(abortprox)) {
-               code = -1;
-               return;
-       }
-//     oldintr = signal(SIGINT, proxabort);
-       pswitch(1);
-       if (c->c_conn && !connected) {
-               printf("Not connected\n");
-               (void) fflush(stdout);
-               pswitch(0);
-//             (void) signal(SIGINT, oldintr);
-               code = -1;
-               return;
-       }
-       (*c->c_handler)(argc-1, argv+1);
-       if (connected) {
-               proxflag = 1;
-       }
-       else {
-               proxflag = 0;
-       }
-       pswitch(0);
-//     (void) signal(SIGINT, oldintr);
-}
-
-void setcase()
-{
-       mcase = !mcase;
-       printf("Case mapping %s.\n", onoff(mcase));
-       (void) fflush(stdout);
-       code = mcase;
-}
-
-void setcr()
-{
-       crflag = !crflag;
-       printf("Carriage Return stripping %s.\n", onoff(crflag));
-       (void) fflush(stdout);
-       code = crflag;
-}
-
-void setntrans(argc,argv)
-       int argc;
-       char *argv[];
-{
-       if (argc == 1) {
-               ntflag = 0;
-               printf("Ntrans off.\n");
-               (void) fflush(stdout);
-               code = ntflag;
-               return;
-       }
-       ntflag++;
-       code = ntflag;
-       (void) strncpy(ntin, argv[1], 16);
-       ntin[16] = '\0';
-       if (argc == 2) {
-               ntout[0] = '\0';
-               return;
-       }
-       (void) strncpy(ntout, argv[2], 16);
-       ntout[16] = '\0';
-}
-
-const char *
-dotrans(name)
-       const char *name;
-{
-       static char new[MAXPATHLEN];
-       const char *cp1;
-    char *cp2 = new;
-       register int i, ostop, found;
-
-       for (ostop = 0; *(ntout + ostop) && ostop < 16; ostop++);
-       for (cp1 = name; *cp1; cp1++) {
-               found = 0;
-               for (i = 0; *(ntin + i) && i < 16; i++) {
-                       if (*cp1 == *(ntin + i)) {
-                               found++;
-                               if (i < ostop) {
-                                       *cp2++ = *(ntout + i);
-                               }
-                               break;
-                       }
-               }
-               if (!found) {
-                       *cp2++ = *cp1;
-               }
-       }
-       *cp2 = '\0';
-       return(new);
-}
-
-
-void
-setpassive(argc, argv)
-  int argc;
-  char *argv[];
-{
-       passivemode = !passivemode;
-       printf("Passive mode %s.\n", onoff(passivemode));
-       (void) fflush(stdout);
-       code = passivemode;
-}
-
-void setnmap(argc, argv)
-       int argc;
-       const char *argv[];
-{
-       char *cp;
-
-       if (argc == 1) {
-               mapflag = 0;
-               printf("Nmap off.\n");
-               (void) fflush(stdout);
-               code = mapflag;
-               return;
-       }
-       if (argc < 3) {
-               (void) strcat(line, " ");
-               printf("(mapout) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 3) {
-               printf("Usage: %s [mapin mapout]\n",argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       mapflag = 1;
-       code = 1;
-       cp = index(altarg, ' ');
-       if (proxy) {
-               while(*++cp == ' ');
-               altarg = cp;
-               cp = index(altarg, ' ');
-       }
-       *cp = '\0';
-       (void) strncpy(mapin, altarg, MAXPATHLEN - 1);
-       while (*++cp == ' ');
-       (void) strncpy(mapout, cp, MAXPATHLEN - 1);
-}
-
-const char *
-domap(name)
-       const char *name;
-{
-       static char new[MAXPATHLEN];
-       const char *cp1 = name;
-    char *cpn, *cp2 = mapin;
-       const char *tp[9], *te[9];
-       int i, toks[9], toknum = 0, match = 1;
-
-       for (i=0; i < 9; ++i) {
-               toks[i] = 0;
-       }
-       while (match && *cp1 && *cp2) {
-               switch (*cp2) {
-                       case '\\':
-                               if (*++cp2 != *cp1) {
-                                       match = 0;
-                               }
-                               break;
-                       case '$':
-                               if (*(cp2+1) >= '1' && (*cp2+1) <= '9') {
-                                       if (*cp1 != *(++cp2+1)) {
-                                               toks[toknum = *cp2 - '1']++;
-                                               tp[toknum] = cp1;
-                                               while (*++cp1 && *(cp2+1)
-                                                       != *cp1);
-                                               te[toknum] = cp1;
-                                       }
-                                       cp2++;
-                                       break;
-                               }
-                               /* FALLTHROUGH */
-                       default:
-                               if (*cp2 != *cp1) {
-                                       match = 0;
-                               }
-                               break;
-               }
-               if (match && *cp1) {
-                       cp1++;
-               }
-               if (match && *cp2) {
-                       cp2++;
-               }
-       }
-       if (!match && *cp1) /* last token mismatch */
-       {
-               toks[toknum] = 0;
-       }
-
-       cpn = new;
-       *cpn = '\0';
-       cp2 = mapout;
-       while (*cp2) {
-               match = 0;
-               switch (*cp2) {
-                       case '\\':
-                               if (*(cp2 + 1)) {
-                                       *cpn++ = *++cp2;
-                               }
-                               break;
-                       case '[':
-LOOP:
-                               if (*++cp2 == '$' && isdigit(*(cp2+1))) {
-                                       if (*++cp2 == '0') {
-                                               const char *cp3 = name;
-
-                                               while (*cp3) {
-                                                       *cpn++ = *cp3++;
-                                               }
-                                               match = 1;
-                                       }
-                                       else if (toks[toknum = *cp2 - '1']) {
-                                               const char *cp3 = tp[toknum];
-
-                                               while (cp3 != te[toknum]) {
-                                                       *cpn++ = *cp3++;
-                                               }
-                                               match = 1;
-                                       }
-                               }
-                               else {
-                                       while (*cp2 && *cp2 != ',' &&
-                                           *cp2 != ']') {
-                                               if (*cp2 == '\\') {
-                                                       cp2++;
-                                               }
-                                               else if (*cp2 == '$' &&
-                                                       isdigit(*(cp2+1))) {
-                                                       if (*++cp2 == '0') {
-                                                          const char *cp3 = name;
-
-                                                          while (*cp3) {
-                                                               *cpn++ = *cp3++;
-                                                          }
-                                                       }
-                                                       else if (toks[toknum =
-                                                           *cp2 - '1']) {
-                                                          const char *cp3=tp[toknum];
-
-                                                          while (cp3 !=
-                                                                 te[toknum]) {
-                                                               *cpn++ = *cp3++;
-                                                          }
-                                                       }
-                                               }
-                                               else if (*cp2) {
-                                                       *cpn++ = *cp2++;
-                                               }
-                                       }
-                                       if (!*cp2) {
-                                               printf("nmap: unbalanced brackets\n");
-                                               (void) fflush(stdout);
-                                               return(name);
-                                       }
-                                       match = 1;
-                                       cp2--;
-                               }
-                               if (match) {
-                                       while (*++cp2 && *cp2 != ']') {
-                                             if (*cp2 == '\\' && *(cp2 + 1)) {
-                                                       cp2++;
-                                             }
-                                       }
-                                       if (!*cp2) {
-                                               printf("nmap: unbalanced brackets\n");
-                                               (void) fflush(stdout);
-                                               return(name);
-                                       }
-                                       break;
-                               }
-                               switch (*++cp2) {
-                                       case ',':
-                                               goto LOOP;
-                                       case ']':
-                                               break;
-                                       default:
-                                               cp2--;
-                                               goto LOOP;
-                               }
-                               break;
-                       case '$':
-                               if (isdigit(*(cp2 + 1))) {
-                                       if (*++cp2 == '0') {
-                                               const char *cp3 = name;
-
-                                               while (*cp3) {
-                                                       *cpn++ = *cp3++;
-                                               }
-                                       }
-                                       else if (toks[toknum = *cp2 - '1']) {
-                                               const char *cp3 = tp[toknum];
-
-                                               while (cp3 != te[toknum]) {
-                                                       *cpn++ = *cp3++;
-                                               }
-                                       }
-                                       break;
-                               }
-                               /* intentional drop through */
-                       default:
-                               *cpn++ = *cp2;
-                               break;
-               }
-               cp2++;
-       }
-       *cpn = '\0';
-       if (!*new) {
-               return(name);
-       }
-       return(new);
-}
-
-void setsunique()
-{
-       sunique = !sunique;
-       printf("Store unique %s.\n", onoff(sunique));
-       (void) fflush(stdout);
-       code = sunique;
-}
-
-void setrunique()
-{
-       runique = !runique;
-       printf("Receive unique %s.\n", onoff(runique));
-       (void) fflush(stdout);
-       code = runique;
-}
-
-/* change directory to perent directory */
-void cdup()
-{
-       if (command("CDUP") == ERROR && code == 500) {
-               if (verbose) {
-                       printf("CDUP command not recognized, trying XCUP\n");
-                       (void) fflush(stdout);
-               }
-               (void) command("XCUP");
-       }
-}
-
-/* restart transfer at specific point */
-void restart(argc, argv)
-       int argc;
-       char *argv[];
-{
-       extern long atol();
-       if (argc != 2)
-               printf("restart: offset not specified\n");
-       else {
-               restart_point = atol(argv[1]);
-               printf("restarting at %ld. %s\n", restart_point,
-                   "execute get, put or append to initiate transfer");
-       }
-       (void) fflush(stdout);
-}
-
-/* show remote system type */
-void syst()
-{
-       (void) command("SYST");
-}
-
-void macdef(argc, argv)
-       int argc;
-       const char *argv[];
-{
-       char *tmp;
-       int c;
-
-       if (macnum == 16) {
-               printf("Limit of 16 macros have already been defined\n");
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(macro name) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc != 2) {
-               printf("Usage: %s macro_name\n",argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       if (interactive) {
-               printf("Enter macro line by line, terminating it with a null line\n");
-               (void) fflush(stdout);
-       }
-       (void) strncpy(macros[macnum].mac_name, argv[1], 8);
-       if (macnum == 0) {
-               macros[macnum].mac_start = macbuf;
-       }
-       else {
-               macros[macnum].mac_start = macros[macnum - 1].mac_end + 1;
-       }
-       tmp = macros[macnum].mac_start;
-       while (tmp != macbuf+4096) {
-               if ((c = getchar()) == EOF) {
-                       printf("macdef:end of file encountered\n");
-                       (void) fflush(stdout);
-                       code = -1;
-                       return;
-               }
-               if ((*tmp = c) == '\n') {
-                       if (tmp == macros[macnum].mac_start) {
-                               macros[macnum++].mac_end = tmp;
-                               code = 0;
-                               return;
-                       }
-                       if (*(tmp-1) == '\0') {
-                               macros[macnum++].mac_end = tmp - 1;
-                               code = 0;
-                               return;
-                       }
-                       *tmp = '\0';
-               }
-               tmp++;
-       }
-       while (1) {
-               while ((c = getchar()) != '\n' && c != EOF)
-                       /* LOOP */;
-               if (c == EOF || getchar() == '\n') {
-                       printf("Macro not defined - 4k buffer exceeded\n");
-                       (void) fflush(stdout);
-                       code = -1;
-                       return;
-               }
-       }
-}
-
-/*
- * get size of file on remote machine
- */
-void sizecmd(argc, argv)
-       const char *argv[];
-{
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(filename) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage:%s filename\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       (void) command("SIZE %s", argv[1]);
-}
-
-/*
- * get last modification time of file on remote machine
- */
-void modtime(argc, argv)
-       const char *argv[];
-{
-       int overbose;
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(filename) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("usage:%s filename\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       overbose = verbose;
-       if (debug == 0)
-               verbose = -1;
-       if (command("MDTM %s", argv[1]) == COMPLETE) {
-               int yy, mo, day, hour, min, sec;
-               sscanf(reply_string, "%*s %04d%02d%02d%02d%02d%02d", &yy, &mo,
-                       &day, &hour, &min, &sec);
-               /* might want to print this in local time */
-               printf("%s\t%02d/%02d/%04d %02d:%02d:%02d GMT\n", argv[1],
-                       mo, day, yy, hour, min, sec);
-       } else
-               printf("%s\n", reply_string);
-       verbose = overbose;
-       (void) fflush(stdout);
-}
-
-/*
- * show status on reomte machine
- */
-void rmtstatus(argc, argv)
-       const char *argv[];
-{
-       (void) command(argc > 1 ? "STAT %s" : "STAT" , argv[1]);
-}
-
-/*
- * get file if modtime is more recent than current file
- */
-void newer(argc, argv)
-       const char *argv[];
-{
-       if (getit(argc, argv, -1, "w")) {
-               printf("Local file \"%s\" is newer than remote file \"%s\"\n",
-                       argv[1], argv[2]);
-               (void) fflush(stdout);
-       }
-}
diff --git a/reactos/apps/utils/net/ftp/cmdtab.c b/reactos/apps/utils/net/ftp/cmdtab.c
deleted file mode 100644 (file)
index 5c33652..0000000
+++ /dev/null
@@ -1,171 +0,0 @@
-/*
- * Copyright (c) 1985, 1989 Regents of the University of California.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms are permitted
- * provided that the above copyright notice and this paragraph are
- * duplicated in all such forms and that any documentation,
- * advertising materials, and other materials related to such
- * distribution and use acknowledge that the software was developed
- * by the University of California, Berkeley.  The name of the
- * University may not be used to endorse or promote products derived
- * from this software without specific prior written permission.
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
- */
-
-#ifndef lint
-static char sccsid[] = "@(#)cmdtab.c   5.9 (Berkeley) 3/21/89";
-#endif /* not lint */
-
-#include "ftp_var.h"
-
-/*
- * User FTP -- Command Tables.
- */
-
-char   accounthelp[] = "send account command to remote server";
-char   appendhelp[] =  "append to a file";
-char   asciihelp[] =   "set ascii transfer type";
-char   beephelp[] =    "beep when command completed";
-char   binaryhelp[] =  "set binary transfer type";
-char   casehelp[] =    "toggle mget upper/lower case id mapping";
-char   cdhelp[] =      "change remote working directory";
-char   cduphelp[] =    "change remote working directory to parent directory";
-char   chmodhelp[] =   "change file permissions of remote file";
-char   connecthelp[] = "connect to remote tftp";
-char   crhelp[] =      "toggle carriage return stripping on ascii gets";
-char   deletehelp[] =  "delete remote file";
-char   debughelp[] =   "toggle/set debugging mode";
-char   dirhelp[] =     "list contents of remote directory";
-char   disconhelp[] =  "terminate ftp session";
-char   domachelp[] =   "execute macro";
-char   formhelp[] =    "set file transfer format";
-char   globhelp[] =    "toggle metacharacter expansion of local file names";
-char   hashhelp[] =    "toggle printing `#' for each buffer transferred";
-char   helphelp[] =    "print local help information";
-char   idlehelp[] =    "get (set) idle timer on remote side";
-char   lcdhelp[] =     "change local working directory";
-char   lshelp[] =      "list contents of remote directory";
-char   macdefhelp[] =  "define a macro";
-char   mdeletehelp[] = "delete multiple files";
-char   mdirhelp[] =    "list contents of multiple remote directories";
-char   mgethelp[] =    "get multiple files";
-char   mkdirhelp[] =   "make directory on the remote machine";
-char   mlshelp[] =     "list contents of multiple remote directories";
-char   modtimehelp[] = "show last modification time of remote file";
-char   modehelp[] =    "set file transfer mode";
-char   mputhelp[] =    "send multiple files";
-char   newerhelp[] =   "get file if remote file is newer than local file ";
-char   nlisthelp[] =   "nlist contents of remote directory";
-char   nmaphelp[] =    "set templates for default file name mapping";
-char   ntranshelp[] =  "set translation table for default file name mapping";
-char   porthelp[] =    "toggle use of PORT cmd for each data connection";
-char   prompthelp[] =  "force interactive prompting on multiple commands";
-char   proxyhelp[] =   "issue command on alternate connection";
-char   pwdhelp[] =     "print working directory on remote machine";
-char   quithelp[] =    "terminate ftp session and exit";
-char   quotehelp[] =   "send arbitrary ftp command";
-char   receivehelp[] = "receive file";
-char   regethelp[] =   "get file restarting at end of local file";
-char   remotehelp[] =  "get help from remote server";
-char   renamehelp[] =  "rename file";
-char   restarthelp[]=  "restart file transfer at bytecount";
-char   rmdirhelp[] =   "remove directory on the remote machine";
-char   rmtstatushelp[]="show status of remote machine";
-char   runiquehelp[] = "toggle store unique for local files";
-char   resethelp[] =   "clear queued command replies";
-char   sendhelp[] =    "send one file";
-char    passivehelp[] = "enter passive transfer mode";
-char   sitehelp[] =    "send site specific command to remote server\n\t\tTry \"rhelp site\" or \"site help\" for more information";
-char   shellhelp[] =   "escape to the shell";
-char   sizecmdhelp[] = "show size of remote file";
-char   statushelp[] =  "show current status";
-char   structhelp[] =  "set file transfer structure";
-char   suniquehelp[] = "toggle store unique on remote machine";
-char   systemhelp[] =  "show remote system type";
-char   tenexhelp[] =   "set tenex file transfer type";
-char   tracehelp[] =   "toggle packet tracing";
-char   typehelp[] =    "set file transfer type";
-char   umaskhelp[] =   "get (set) umask on remote side";
-char   userhelp[] =    "send new user information";
-char   verbosehelp[] = "toggle verbose mode";
-
-struct cmd cmdtab[] = {
-       { "!",          shellhelp,      0,      0,      0,      shell },
-       { "$",          domachelp,      1,      0,      0,      domacro },
-       { "account",    accounthelp,    0,      1,      1,      account},
-       { "append",     appendhelp,     1,      1,      1,      put },
-       { "ascii",      asciihelp,      0,      1,      1,      setascii },
-       { "bell",       beephelp,       0,      0,      0,      setbell },
-       { "binary",     binaryhelp,     0,      1,      1,      setbinary },
-       { "bye",        quithelp,       0,      0,      0,      quit },
-       { "case",       casehelp,       0,      0,      1,      setcase },
-       { "cd",         cdhelp,         0,      1,      1,      cd },
-       { "cdup",       cduphelp,       0,      1,      1,      cdup },
-       { "chmod",      chmodhelp,      0,      1,      1,      do_chmod },
-       { "close",      disconhelp,     0,      1,      1,      disconnect },
-       { "cr",         crhelp,         0,      0,      0,      setcr },
-       { "delete",     deletehelp,     0,      1,      1,      delete },
-       { "debug",      debughelp,      0,      0,      0,      setdebug },
-       { "dir",        dirhelp,        1,      1,      1,      ls },
-       { "disconnect", disconhelp,     0,      1,      1,      disconnect },
-       { "form",       formhelp,       0,      1,      1,      setform },
-       { "get",        receivehelp,    1,      1,      1,      get },
-       { "glob",       globhelp,       0,      0,      0,      setglob },
-       { "hash",       hashhelp,       0,      0,      0,      sethash },
-       { "help",       helphelp,       0,      0,      1,      help },
-       { "idle",       idlehelp,       0,      1,      1,      idle },
-       { "image",      binaryhelp,     0,      1,      1,      setbinary },
-       { "lcd",        lcdhelp,        0,      0,      0,      lcd },
-       { "ls",         lshelp,         1,      1,      1,      ls },
-       { "macdef",     macdefhelp,     0,      0,      0,      macdef },
-       { "mdelete",    mdeletehelp,    1,      1,      1,      mdelete },
-       { "mdir",       mdirhelp,       1,      1,      1,      mls },
-       { "mget",       mgethelp,       1,      1,      1,      mget },
-       { "mkdir",      mkdirhelp,      0,      1,      1,      makedir },
-       { "mls",        mlshelp,        1,      1,      1,      mls },
-       { "mode",       modehelp,       0,      1,      1,      fsetmode },
-       { "modtime",    modtimehelp,    0,      1,      1,      modtime },
-       { "mput",       mputhelp,       1,      1,      1,      mput },
-       { "newer",      newerhelp,      1,      1,      1,      newer },
-       { "nmap",       nmaphelp,       0,      0,      1,      setnmap },
-       { "nlist",      nlisthelp,      1,      1,      1,      ls },
-       { "ntrans",     ntranshelp,     0,      0,      1,      setntrans },
-       { "open",       connecthelp,    0,      0,      1,      setpeer },
-    { "passive",passivehelp,0,  0,  0,  setpassive },
-       { "prompt",     prompthelp,     0,      0,      0,      setprompt },
-       { "proxy",      proxyhelp,      0,      0,      1,      doproxy },
-       { "sendport",   porthelp,       0,      0,      0,      setport },
-       { "put",        sendhelp,       1,      1,      1,      put },
-       { "pwd",        pwdhelp,        0,      1,      1,      pwd },
-       { "quit",       quithelp,       0,      0,      0,      quit },
-       { "quote",      quotehelp,      1,      1,      1,      quote },
-       { "recv",       receivehelp,    1,      1,      1,      get },
-       { "reget",      regethelp,      1,      1,      1,      reget },
-       { "rstatus",    rmtstatushelp,  0,      1,      1,      rmtstatus },
-       { "rhelp",      remotehelp,     0,      1,      1,      rmthelp },
-       { "rename",     renamehelp,     0,      1,      1,      renamefile },
-       { "reset",      resethelp,      0,      1,      1,      reset },
-       { "restart",    restarthelp,    1,      1,      1,      restart },
-       { "rmdir",      rmdirhelp,      0,      1,      1,      removedir },
-       { "runique",    runiquehelp,    0,      0,      1,      setrunique },
-       { "send",       sendhelp,       1,      1,      1,      put },
-       { "site",       sitehelp,       0,      1,      1,      site },
-       { "size",       sizecmdhelp,    1,      1,      1,      sizecmd },
-       { "status",     statushelp,     0,      0,      1,      status },
-       { "struct",     structhelp,     0,      1,      1,      setstruct },
-       { "system",     systemhelp,     0,      1,      1,      syst },
-       { "sunique",    suniquehelp,    0,      0,      1,      setsunique },
-       { "tenex",      tenexhelp,      0,      1,      1,      settenex },
-       { "trace",      tracehelp,      0,      0,      0,      settrace },
-       { "type",       typehelp,       0,      1,      1,      settype },
-       { "user",       userhelp,       0,      1,      1,      user },
-       { "umask",      umaskhelp,      0,      1,      1,      do_umask },
-       { "verbose",    verbosehelp,    0,      0,      0,      setverbose },
-       { "?",          helphelp,       0,      0,      1,      help },
-       { 0 },
-};
-
-int    NCMDS = (sizeof (cmdtab) / sizeof (cmdtab[0])) - 1;
diff --git a/reactos/apps/utils/net/ftp/domacro.c b/reactos/apps/utils/net/ftp/domacro.c
deleted file mode 100644 (file)
index a741a34..0000000
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- * Copyright (c) 1985 Regents of the University of California.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms are permitted
- * provided that the above copyright notice and this paragraph are
- * duplicated in all such forms and that any documentation,
- * advertising materials, and other materials related to such
- * distribution and use acknowledge that the software was developed
- * by the University of California, Berkeley.  The name of the
- * University may not be used to endorse or promote products derived
- * from this software without specific prior written permission.
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
- */
-
-#ifndef lint
-static char sccsid[] = "@(#)domacro.c  1.6 (Berkeley) 2/28/89";
-#endif /* not lint */
-
-#include "ftp_var.h"
-#include "prototypes.h"
-
-#include <signal.h>
-#include <stdio.h>
-//#include <errno.h>
-#include <ctype.h>
-//#include <sys/ttychars.h>
-
-void domacro(argc, argv)
-       int argc;
-       const char *argv[];
-{
-       int i, j;
-       const char *cp1;
-    char *cp2;
-       int count = 2, loopflg = 0;
-       char line2[200];
-       struct cmd *getcmd(), *c;
-
-       if (argc < 2) {
-               (void) strcat(line, " ");
-               printf("(macro name) ");
-               (void) fflush(stdout);
-               (void) gets(&line[strlen(line)]);
-               makeargv();
-               argc = margc;
-               argv = margv;
-       }
-       if (argc < 2) {
-               printf("Usage: %s macro_name.\n", argv[0]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       for (i = 0; i < macnum; ++i) {
-               if (!strncmp(argv[1], macros[i].mac_name, 9)) {
-                       break;
-               }
-       }
-       if (i == macnum) {
-               printf("'%s' macro not found.\n", argv[1]);
-               (void) fflush(stdout);
-               code = -1;
-               return;
-       }
-       (void) strcpy(line2, line);
-TOP:
-       cp1 = macros[i].mac_start;
-       while (cp1 != macros[i].mac_end) {
-               while (isspace(*cp1)) {
-                       cp1++;
-               }
-               cp2 = line;
-               while (*cp1 != '\0') {
-                     switch(*cp1) {
-                           case '\\':
-                                *cp2++ = *++cp1;
-                                break;
-                           case '$':
-                                if (isdigit(*(cp1+1))) {
-                                   j = 0;
-                                   while (isdigit(*++cp1)) {
-                                         j = 10*j +  *cp1 - '0';
-                                   }
-                                   cp1--;
-                                   if (argc - 2 >= j) {
-                                       (void) strcpy(cp2, argv[j+1]);
-                                       cp2 += strlen(argv[j+1]);
-                                   }
-                                   break;
-                                }
-                                if (*(cp1+1) == 'i') {
-                                       loopflg = 1;
-                                       cp1++;
-                                       if (count < argc) {
-                                          (void) strcpy(cp2, argv[count]);
-                                          cp2 += strlen(argv[count]);
-                                       }
-                                       break;
-                               }
-                               /* intentional drop through */
-                           default:
-                               *cp2++ = *cp1;
-                               break;
-                     }
-                     if (*cp1 != '\0') {
-                        cp1++;
-                     }
-               }
-               *cp2 = '\0';
-               makeargv();
-               c = getcmd(margv[0]);
-               if (c == (struct cmd *)-1) {
-                       printf("?Ambiguous command\n");
-                       code = -1;
-               }
-               else if (c == 0) {
-                       printf("?Invalid command\n");
-                       code = -1;
-               }
-               else if (c->c_conn && !connected) {
-                       printf("Not connected.\n");
-                       code = -1;
-               }
-               else {
-                       if (verbose) {
-                               printf("%s\n",line);
-                       }
-                       (*c->c_handler)(margc, margv);
-                       if (bell && c->c_bell) {
-                               (void) putchar('\007');
-                       }
-                       (void) strcpy(line, line2);
-                       makeargv();
-                       argc = margc;
-                       argv = margv;
-               }
-               if (cp1 != macros[i].mac_end) {
-                       cp1++;
-               }
-               (void) fflush(stdout);
-       }
-       if (loopflg && ++count < argc) {
-               goto TOP;
-       }
-}
diff --git a/reactos/apps/utils/net/ftp/fake.c b/reactos/apps/utils/net/ftp/fake.c
deleted file mode 100644 (file)
index f8d0c8c..0000000
+++ /dev/null
@@ -1,341 +0,0 @@
-#include <stdio.h>
-#include <time.h>
-#include <winsock.h>
-#include "fake.h"
-#include "prototypes.h"
-
-#define MAX_ASCII 100
-
-int checkRecv(SOCKET s);
-
-int checkRecv(SOCKET s)
-{
-   int testVal;
-   fd_set sSet;
-   struct timeval timeout;
-   timeout.tv_sec = 60;
-
-   FD_ZERO(&sSet);
-
-   FD_SET(s, &sSet);
-
-   testVal = select(0, &sSet, NULL, NULL, &timeout);
-
-   if (testVal == SOCKET_ERROR)
-      fprintf(stderr, "Socket Error");
-
-   return testVal;
-}
-
-void blkfree(char **av0)
-{
-       register char **av = av0;
-
-       while (*av)
-               free(*av++);
-}
-
-char **glob(register char *v)
-{
-   return NULL;
-}
-
-int sleep(int time)
-{
-   return time;
-}
-
-int herror(char *string)
-{
-   return 0;
-}
-
-#if 0
-int gettimeofday(struct timeval *timenow,
-                                struct timezone *zone)
-{
-       time_t t;
-
-       t = clock();
-
-       timenow->tv_usec = t;
-       timenow->tv_sec = t / CLK_TCK;
-
-       return 0;
-}
-
-int fgetcSocket(int s)
-{
-   int c;
-   char buffer[10];
-
-//   checkRecv(s);
-
-   c = recv(s, buffer, 1, 0);
-
-#ifdef DEBUG_IN
-   printf("%c", buffer[0]);
-#endif
-
-   if (c == INVALID_SOCKET)
-      return c;
-
-   if (c == 0)
-      return EOF;
-
-   return buffer[0];
-}
-
-#else
-
-int fgetcSocket(int s)
-{
-   static int index = 0;
-   static int total = 0;
-   static char buffer[4096];
-
-   if (index == total)
-     {
-       index = 0;
-       total = recv(s, buffer, sizeof(buffer), 0);
-
-       if (total == SOCKET_ERROR)
-        {
-          total = 0;
-          return ERROR;
-        }
-
-       if (total == 0)
-        return EOF;
-     }
-   return buffer[index++];
-}
-
-#endif
-
-const char *fprintfSocket(int s, const char *format, ...)
-{
-   va_list argptr;
-   char buffer[10009];
-
-   va_start(argptr, format);
-   vsprintf(buffer, format, argptr);
-   va_end(argptr);
-
-   send(s, buffer, strlen(buffer), 0);
-
-   return NULL;
-}
-
-const char *fputsSocket(const char *format, int s)
-{
-   send(s, format, strlen(format), 0);
-
-   return NULL;
-}
-
-int fputcSocket(int s, char putChar)
-{
-   char buffer[2];
-
-   buffer[0] = putChar;
-   buffer[1] = '\0';
-
-   if(SOCKET_ERROR==send(s, buffer, 1, 0)) {
-          int iret=WSAGetLastError ();
-          fprintf(stdout,"fputcSocket: %d\n",iret);
-          return 0;
-   }
-   else {
-       return putChar;
-   }
-}
-int fputSocket(int s, char *buffer, int len)
-{
-       int iret;
-       while(len) {
-               if(SOCKET_ERROR==(iret=send(s, buffer, len, 0)))
-               {
-                       iret=WSAGetLastError ();
-                       fprintf(stdout,"fputcSocket: %d\n",iret);
-                       return 0;
-               }
-               else {
-                       return len-=iret;
-               }
-       }
-       return 0;
-}
-
-char *fgetsSocket(int s, char *string)
-{
-   char buffer[2] = {0};
-   int i, count;
-
-   for (i = 0, count = 1; count != 0 && buffer[0] != '\n'; i++)
-   {
-      checkRecv(s);
-
-      count = recv(s, buffer, 1, 0);
-
-      if (count == SOCKET_ERROR)
-      {
-        printf("Error in fgetssocket");
-        return NULL;
-      }
-
-      if (count == 1)
-      {
-        string[i] = buffer[0];
-
-        if (i == MAX_ASCII - 3)
-        {
-           count = 0;
-           string[++i] = '\n';
-           string[++i] = '\0';
-        }
-      }
-      else
-      {
-        if (i == 0)
-           return NULL;
-        else
-        {
-           string[i] = '\n';
-           string[i + 1] = '\0'; // This is risky
-           return string;
-        }
-
-      }
-
-   }
-   string[i] = '\0';
-
-#ifdef DEBUG_IN
-   printf("%s", string);
-#endif
-   return string;
-}
-
-
-#if 0
-char *getpass(const char *prompt)
-{
-   static char string[64];
-
-   printf("%s", prompt);
-
-   gets(string);
-
-   return string;
-}
-#endif
-char *getpass (const char * prompt)
-{
-  static char input[256];
-  HANDLE in;
-  HANDLE err;
-  DWORD    count;
-
-  in = GetStdHandle (STD_INPUT_HANDLE);
-  err = GetStdHandle (STD_ERROR_HANDLE);
-
-  if (in == INVALID_HANDLE_VALUE || err == INVALID_HANDLE_VALUE)
-    return NULL;
-
-  if (WriteFile (err, prompt, strlen (prompt), &count, NULL))
-    {
-      int istty = (GetFileType (in) == FILE_TYPE_CHAR);
-      DWORD old_flags;
-      int rc;
-
-      if (istty)
-       {
-         if (GetConsoleMode (in, &old_flags))
-           SetConsoleMode (in, ENABLE_LINE_INPUT | ENABLE_PROCESSED_INPUT);
-         else
-           istty = 0;
-       }
-      /* Need to read line one byte at time to avoid blocking, if not a
-         tty, so always do it this way.  */
-      count = 0;
-      while (1)
-       {
-         DWORD  dummy;
-         char   one_char;
-
-         rc = ReadFile (in, &one_char, 1, &dummy, NULL);
-         if (rc == 0)
-           break;
-         if (one_char == '\r')
-           {
-             /* CR is always followed by LF if reading from tty.  */
-             if (istty)
-               continue;
-             else
-               break;
-           }
-         if (one_char == '\n')
-           break;
-         /* Silently truncate password string if overly long.  */
-         if (count < sizeof (input) - 1)
-           input[count++] = one_char;
-       }
-      input[count] = '\0';
-
-      WriteFile (err, "\r\n", 2, &count, NULL);
-      if (istty)
-       SetConsoleMode (in, old_flags);
-      if (rc)
-       return input;
-    }
-
-  return NULL;
-}
-
-#if 0
-// Stubbed out here. Should be changed in Source code...
-int access(const char *filename, int accessmethod)
-{
-   return 0;
-}
-#endif
-
-#ifndef __GNUC__
-#define EPOCHFILETIME (116444736000000000i64)
-#else
-#define EPOCHFILETIME (116444736000000000LL)
-#endif
-
-int gettimeofday(struct timeval *tv, struct timezone *tz)
-{
-    FILETIME        ft;
-    LARGE_INTEGER   li;
-    __int64         t;
-    static int      tzflag;
-
-    if (tv)
-    {
-        GetSystemTimeAsFileTime(&ft);
-        li.LowPart  = ft.dwLowDateTime;
-        li.HighPart = ft.dwHighDateTime;
-        t  = li.QuadPart;       /* In 100-nanosecond intervals */
-        t -= EPOCHFILETIME;     /* Offset to the Epoch time */
-        t /= 10;                /* In microseconds */
-        tv->tv_sec  = (long)(t / 1000000);
-        tv->tv_usec = (long)(t % 1000000);
-    }
-
-    if (tz)
-    {
-        if (!tzflag)
-        {
-            _tzset();
-            tzflag++;
-        }
-        tz->tz_minuteswest = _timezone / 60;
-        tz->tz_dsttime = _daylight;
-    }
-
-    return 0;
-}
diff --git a/reactos/apps/utils/net/ftp/fake.h b/reactos/apps/utils/net/ftp/fake.h
deleted file mode 100644 (file)
index 68c94cc..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-#define bcopy(s,d,l) memcpy((d),(s),(l))
-#define bzero(cp,l) memset((cp),0,(l))
-
-#define rindex strrchr
-#define index strchr
-
-#define getwd getcwd
-
-#define strcasecmp strcmp
-#define strncasecmp strnicmp
-
-struct timezone {
-    int tz_minuteswest; /* minutes W of Greenwich */
-    int tz_dsttime;     /* type of dst correction */
-};
-
-int gettimeofday(struct timeval *tv, struct timezone *tz);
diff --git a/reactos/apps/utils/net/ftp/ftp.c b/reactos/apps/utils/net/ftp/ftp.c
deleted file mode 100644 (file)
index 4642bac..0000000
+++ /dev/null
@@ -1,1820 +0,0 @@
-#define L_SET SEEK_SET
-#define L_INCR SEEK_CUR
-#define caddr_t void *
-/*
- * Copyright (c) 1985, 1989 Regents of the University of California.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms are permitted
- * provided that the above copyright notice and this paragraph are
- * duplicated in all such forms and that any documentation,
- * advertising materials, and other materials related to such
- * distribution and use acknowledge that the software was developed
- * by the University of California, Berkeley.  The name of the
- * University may not be used to endorse or promote products derived
- * from this software without specific prior written permission.
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
- */
-
-#ifndef lint
-static char sccsid[] = "@(#)ftp.c      5.28 (Berkeley) 4/20/89";
-#endif /* not lint */
-#include <io.h>
-
-#include <sys/stat.h>
-
-#ifndef _WIN32
-#include <sys/param.h>
-#include <sys/socket.h>
-#include <sys/time.h>
-#include <sys/file.h>
-#include <sys/ioctl.h>
-#include <netinet/in.h>
-#include <arpa/ftp.h>
-#include <arpa/telnet.h>
-#include <pwd.h>
-#include <varargs.h>
-#include <netdb.h>
-#else
-#include <winsock.h>
-#endif
-
-#include <stdio.h>
-#include <signal.h>
-#include <errno.h>
-#include <fcntl.h>
-
-#include "ftp_var.h"
-#include "prototypes.h"
-#ifndef MAXHOSTNAMELEN
-#define MAXHOSTNAMELEN 64
-#endif
-
-#ifdef NOVFPRINTF
-#define vfprintf(a,b,c) _doprnt(b,c,a)
-#endif
-
-#ifdef sun
-/* FD_SET wasn't defined until 4.0. its a cheap test for uid_t  presence */
-#ifndef FD_SET
-#define        NBBY    8               /* number of bits in a byte */
-/*
- * Select uses bit masks of file descriptors in longs.
- * These macros manipulate such bit fields (the filesystem macros use chars).
- * FD_SETSIZE may be defined by the user, but the default here
- * should be >= NOFILE (param.h).
- */
-#ifndef        FD_SETSIZE
-#define        FD_SETSIZE      256
-#endif
-
-typedef long   fd_mask;
-#define NFDBITS        (sizeof(fd_mask) * NBBY)        /* bits per mask */
-#ifndef howmany
-#define        howmany(x, y)   (((x)+((y)-1))/(y))
-#endif
-
-#define        FD_SET(n, p)    ((p)->fds_bits[(n)/NFDBITS] |= (1 << ((n) % NFDBITS)))
-#define        FD_CLR(n, p)    ((p)->fds_bits[(n)/NFDBITS] &= ~(1 << ((n) % NFDBITS)))
-#define        FD_ISSET(n, p)  ((p)->fds_bits[(n)/NFDBITS] & (1 << ((n) % NFDBITS)))
-#define FD_ZERO(p)     bzero((char *)(p), sizeof(*(p)))
-
-typedef int uid_t;
-typedef int gid_t;
-#endif
-#endif
-
-struct sockaddr_in hisctladdr;
-struct sockaddr_in data_addr;
-int    data = -1;
-int    abrtflag = 0;
-int    ptflag = 0;
-int    allbinary;
-struct sockaddr_in myctladdr;
-uid_t  getuid();
-sig_t  lostpeer();
-off_t  restart_point = 0;
-
-SOCKET cin, cout;
-int    dataconn(const char *mode);
-
-int command(const char *fmt, ...);
-
-char *hostname;
-
-typedef void (*Sig_t)(int);
-
-// Signal Handlers
-
-void psabort(int sig);
-
-char *hookup(char *host, int port)
-{
-       register struct hostent *hp = 0;
-       int len;
-       SOCKET s;
-       static char hostnamebuf[80];
-
-       bzero((char *)&hisctladdr, sizeof (hisctladdr));
-       hisctladdr.sin_addr.s_addr = inet_addr(host);
-       if (hisctladdr.sin_addr.s_addr != (unsigned long)-1) {
-               hisctladdr.sin_family = AF_INET;
-               (void) strncpy(hostnamebuf, host, sizeof(hostnamebuf));
-       } else {
-               hp = gethostbyname(host);
-               if (hp == NULL) {
-                       fprintf(stderr, "ftp: %s: ", host);
-                       herror((char *)NULL);
-                       code = -1;
-                       return((char *) 0);
-               }
-               hisctladdr.sin_family = hp->h_addrtype;
-               bcopy(hp->h_addr_list[0],
-                        (caddr_t)&hisctladdr.sin_addr, hp->h_length);
-               (void) strncpy(hostnamebuf, hp->h_name, sizeof(hostnamebuf));
-       }
-       hostname = hostnamebuf;
-       s = socket(hisctladdr.sin_family, SOCK_STREAM, 0);
-       if (s == INVALID_SOCKET) {
-               perror("ftp: socket");
-               code = -1;
-               return (0);
-       }
-       hisctladdr.sin_port = port;
-       while (connect(s, (struct sockaddr *)&hisctladdr, sizeof (hisctladdr)) < 0) {
-               if (hp && hp->h_addr_list[1]) {
-                       int oerrno = errno;
-
-                       fprintf(stderr, "ftp: connect to address %s: ",
-                               inet_ntoa(hisctladdr.sin_addr));
-                       errno = oerrno;
-                       perror((char *) 0);
-                       hp->h_addr_list++;
-                       bcopy(hp->h_addr_list[0],
-                            (caddr_t)&hisctladdr.sin_addr, hp->h_length);
-                       fprintf(stdout, "Trying %s...\n",
-                               inet_ntoa(hisctladdr.sin_addr));
-                       (void) fflush(stdout);
-                       (void) close(s);
-                       s = socket(hisctladdr.sin_family, SOCK_STREAM, 0);
-                       if (s < 0) {
-                               perror("ftp: socket");
-                               code = -1;
-                               return (0);
-                       }
-                       continue;
-               }
-               perror("ftp: connect");
-               code = -1;
-               goto bad;
-       }
-       len = sizeof (myctladdr);
-       if (getsockname(s, (struct sockaddr *)&myctladdr, &len) < 0) {
-               perror("ftp: getsockname");
-               code = -1;
-               goto bad;
-       }
-        cin = cout = s;
-       if (verbose) {
-               printf("Connected to %s.\n", hostname);
-               (void) fflush(stdout);
-       }
-       if (getreply(0) > 2) {  /* read startup message from server */
-           closesocket(cin);
-           code = -1;
-           goto bad;
-       }
-#ifdef SO_OOBINLINE
-       {
-       int on = 1;
-
-       if (setsockopt(s, SOL_SOCKET, SO_OOBINLINE, (const char *) &on, sizeof(on))
-               < 0 && debug) {
-                       perror("ftp: setsockopt");
-               }
-       }
-#endif //SO_OOBINLINE
-
-       return (hostname);
-bad:
-       (void) close(s);
-       return ((char *)0);
-}
-
-int login(const char *host)
-{
-       char tmp[80];
-       char *puser, *ppass, *pacct;
-       const char *user, *pass, *acct;
-       int n, aflag = 0;
-
-       user = pass = acct = 0;
-       n = ruserpass(host, &puser, &ppass, &pacct);
-       if (n < 0) {
-               code = -1;
-               return(0);
-       }
-       if (0 != n) {
-               user = puser;
-               pass = ppass;
-               acct = pacct;
-       }
-       while (user == NULL) {
-           const char *myname = "none"; // This needs to become the usename env
-
-           if (myname)
-              printf("Name (%s:%s): ", host, myname);
-           else
-              printf("Name (%s): ", host);
-          (void) fflush(stdout);
-           (void) fgets(tmp, sizeof(tmp) - 1, stdin);
-           tmp[strlen(tmp) - 1] = '\0';
-           if (*tmp == '\0')
-              user = myname;
-           else
-              user = tmp;
-       }
-       n = command("USER %s", user);
-       if (n == CONTINUE) {
-               if (pass == NULL)
-                       pass = getpass("Password:");
-               n = command("PASS %s", pass);
-                fflush(stdin);
-       }
-       if (n == CONTINUE) {
-               aflag++;
-               acct = getpass("Account:");
-               n = command("ACCT %s", acct);
-       }
-       if (n != COMPLETE) {
-               fprintf(stderr, "Login failed.\n");
-               return (0);
-       }
-       if (!aflag && acct != NULL)
-               (void) command("ACCT %s", acct);
-       if (proxy)
-               return(1);
-       for (n = 0; n < macnum; ++n) {
-               if (!strcmp("init", macros[n].mac_name)) {
-                       (void) strcpy(line, "$init");
-                       makeargv();
-                       domacro(margc, margv);
-                       break;
-               }
-       }
-       return (1);
-}
-
-static void
-cmdabort(int sig)
-{
-       extern jmp_buf ptabort;
-
-       printf("\n");
-       (void) fflush(stdout);
-       abrtflag++;
-       if (ptflag)
-               longjmp(ptabort,1);
-}
-
-/*VARARGS1*/
-int command(const char *fmt, ...)
-{
-       va_list ap;
-       int r;
-       void (*oldintr)(int), cmdabort(int);
-
-       abrtflag = 0;
-       if (debug) {
-               printf("---> ");
-               va_start(ap, fmt);
-               vfprintf(stdout, fmt, ap);
-               va_end(ap);
-               printf("\n");
-               (void) fflush(stdout);
-       }
-       if (cout == (int) NULL) {
-               perror ("No control connection for command");
-               code = -1;
-               return (0);
-       }
-       oldintr = signal(SIGINT,cmdabort);
-        {
-           char buffer[1024];
-
-           va_start(ap, fmt);
-           vsprintf(buffer, fmt, ap);
-           va_end(ap);
-//DLJ: to work through  firewalls - send the command as a single message
-                  strcat(buffer,"\r\n");
-           fprintfSocket(cout, buffer);
-        }
-//DLJ: the following two lines are replaced by the strcat above - seems to
-// make it work through firewalls.
-//     fprintfSocket(cout, "\r\n");
-//     (void) fflush(cout);
-       cpend = 1;
-       r = getreply(!strcmp(fmt, "QUIT"));
-       if (abrtflag && oldintr != SIG_IGN)
-               (*oldintr)(SIGINT);
-//     (void) signal(SIGINT, oldintr);
-       return(r);
-}
-
-char reply_string[BUFSIZ];             /* last line of previous reply */
-
-#include <ctype.h>
-
-int
-getreply(expecteof)
-       int expecteof;
-{
-       register int c, n;
-       register int dig;
-       register char *cp;
-       int originalcode = 0, continuation = 0;
-       void (*oldintr)(int), cmdabort(int);
-       int pflag = 0;
-       char *pt = pasv;
-
-       oldintr = signal(SIGINT,cmdabort);
-       for (;;) {
-               dig = n = code = 0;
-               cp = reply_string;
-               while ((c = fgetcSocket(cin)) != '\n') {
-                       if (c == IAC) {     /* handle telnet commands */
-                               switch (c = fgetcSocket(cin)) {
-                               case WILL:
-                               case WONT:
-                                       c = fgetcSocket(cin);
-                                       fprintfSocket(cout, "%c%c%c",IAC,DONT,c);
-                                       break;
-                               case DO:
-                               case DONT:
-                                       c = fgetcSocket(cin);
-                                       fprintfSocket(cout, "%c%c%c",IAC,WONT,c);
-                                       break;
-                               default:
-                                       break;
-                               }
-                               continue;
-                       }
-                       dig++;
-                       if (c == EOF) {
-                               if (expecteof) {
-//                                     (void) signal(SIGINT,oldintr);
-                                       code = 221;
-                                       return (0);
-                               }
-                               lostpeer();
-                               if (verbose) {
-                                       printf("421 Service not available, remote server has closed connection\n");
-                                       (void) fflush(stdout);
-                               }
-                               code = 421;
-                               return(4);
-                       }
-                       if (c != '\r' && (verbose > 0 ||
-                           (verbose > -1 && n == '5' && dig > 4))) {
-                               if (proxflag &&
-                                  ((dig == 1 || dig == 5) && verbose == 0))
-                                       printf("%s:",hostname);
-                               (void) putchar(c);
-                               (void) fflush(stdout);
-                       }
-                       if (dig < 4 && isdigit(c))
-                               code = code * 10 + (c - '0');
-                       if (!pflag && code == 227)
-                               pflag = 1;
-                       if (dig > 4 && pflag == 1 && isdigit(c))
-                               pflag = 2;
-                       if (pflag == 2) {
-                               if (c != '\r' && c != ')')
-                                       *pt++ = c;
-                               else {
-                                       *pt = '\0';
-                                       pflag = 3;
-                               }
-                       }
-                       if (dig == 4 && c == '-') {
-                               if (continuation)
-                                       code = 0;
-                               continuation++;
-                       }
-                       if (n == 0)
-                               n = c;
-                       if (cp < &reply_string[sizeof(reply_string) - 1])
-                               *cp++ = c;
-               }
-               if (verbose > 0 || (verbose > -1 && n == '5')) {
-                       (void) putchar(c);
-                       (void) fflush (stdout);
-               }
-               if (continuation && code != originalcode) {
-                       if (originalcode == 0)
-                               originalcode = code;
-                       continue;
-               }
-               *cp = '\0';
-               if (n != '1')
-                       cpend = 0;
-               (void) signal(SIGINT,oldintr);
-               if (code == 421 || originalcode == 421)
-                       lostpeer();
-               if (abrtflag && oldintr != cmdabort && oldintr != SIG_IGN)
-                       (*oldintr)(SIGINT);
-               return (n - '0');
-       }
-}
-
-static int
-empty(mask, sec)
-       struct fd_set *mask;
-       int sec;
-{
-       struct timeval t;
-
-       t.tv_sec = (long) sec;
-       t.tv_usec = 0;
-       return(select(32, mask, (struct fd_set *) 0, (struct fd_set *) 0, &t));
-}
-
-jmp_buf        sendabort;
-
-#if 0
-void abortsend()
-{
-
-       mflag = 0;
-       abrtflag = 0;
-       printf("\nsend aborted\n");
-       (void) fflush(stdout);
-       longjmp(sendabort, 1);
-}
-#endif
-
-#define HASHBYTES 1024
-
-void sendrequest(const char *cmd, const char *local, const char *remote, int printnames)
-{
-       FILE *fin;
-        int dout = 0;
-       int (*closefunc)(), _pclose(), fclose();
-       sig_t (*oldintr)(), (*oldintp)();
-       char buf[BUFSIZ], *bufp;
-       long bytes = 0, hashbytes = HASHBYTES;
-       register int c, d;
-       struct stat st;
-       struct timeval start, stop;
-       const char *mode;
-
-       if (verbose && printnames) {
-               if (local && *local != '-')
-                       printf("local: %s ", local);
-               if (remote)
-                       printf("remote: %s\n", remote);
-               (void) fflush(stdout);
-       }
-       if (proxy) {
-               proxtrans(cmd, local, remote);
-               return;
-       }
-       closefunc = NULL;
-       oldintr = NULL;
-       oldintp = NULL;
-       mode = "w";
-       if (setjmp(sendabort)) {
-               while (cpend) {
-                       (void) getreply(0);
-               }
-               if (data >= 0) {
-                       (void) close(data);
-                       data = -1;
-               }
-               if (oldintr)
-null();//                      (void) signal(SIGINT,oldintr);
-               if (oldintp)
-null();//                      (void) signal(SIGPIPE,oldintp);
-               code = -1;
-               return;
-       }
-null();//      oldintr = signal(SIGINT, abortsend);
-       if (strcmp(local, "-") == 0)
-               fin = stdin;
-       else if (*local == '|') {
-null();//              oldintp = signal(SIGPIPE,SIG_IGN);
-               fin = _popen(local + 1, "r");
-               if (fin == NULL) {
-                       perror(local + 1);
-null();//                      (void) signal(SIGINT, oldintr);
-null();//                      (void) signal(SIGPIPE, oldintp);
-                       code = -1;
-                       return;
-               }
-               closefunc = _pclose;
-       } else {
-               fin = fopen(local, "r");
-               if (fin == NULL) {
-                       perror(local);
-null();//                      (void) signal(SIGINT, oldintr);
-                       code = -1;
-                       return;
-               }
-               closefunc = fclose;
-               if (fstat(fileno(fin), &st) < 0 ||
-                   (st.st_mode&S_IFMT) != S_IFREG) {
-                       fprintf(stdout, "%s: not a plain file.\n", local);
-                       (void) fflush(stdout);
-null();//                      (void) signal(SIGINT, oldintr);
-                       fclose(fin);
-                       code = -1;
-                       return;
-               }
-       }
-       if (initconn()) {
-null();//              (void) signal(SIGINT, oldintr);
-               if (oldintp)
-null();//                      (void) signal(SIGPIPE, oldintp);
-               code = -1;
-               if (closefunc != NULL)
-                       (*closefunc)(fin);
-               return;
-       }
-       if (setjmp(sendabort))
-               goto abort;
-
-       if (restart_point &&
-           (strcmp(cmd, "STOR") == 0 || strcmp(cmd, "APPE") == 0)) {
-               if (fseek(fin, (long) restart_point, 0) < 0) {
-                       perror(local);
-                       restart_point = 0;
-                       if (closefunc != NULL)
-                               (*closefunc)(fin);
-                       return;
-               }
-               if (command("REST %ld", (long) restart_point)
-                       != CONTINUE) {
-                       restart_point = 0;
-                       if (closefunc != NULL)
-                               (*closefunc)(fin);
-                       return;
-               }
-               restart_point = 0;
-               mode = "r+w";
-       }
-       if (remote) {
-               if (command("%s %s", cmd, remote) != PRELIM) {
-null();//                      (void) signal(SIGINT, oldintr);
-                       if (oldintp)
-null();//                              (void) signal(SIGPIPE, oldintp);
-                       if (closefunc != NULL)
-                               (*closefunc)(fin);
-                       return;
-               }
-       } else
-               if (command("%s", cmd) != PRELIM) {
-null();//                      (void) signal(SIGINT, oldintr);
-                       if (oldintp)
-null();//                              (void) signal(SIGPIPE, oldintp);
-                       if (closefunc != NULL)
-                               (*closefunc)(fin);
-                       return;
-               }
-       dout = dataconn(mode);
-       if (dout == (int)NULL)
-               goto abort;
-       (void) gettimeofday(&start, (struct timezone *)0);
-null();//      oldintp = signal(SIGPIPE, SIG_IGN);
-       switch (type) {
-
-       case TYPE_I:
-       case TYPE_L:
-               errno = d = 0;
-               while ((c = read(fileno(fin), buf, sizeof (buf))) > 0) {
-                       bytes += c;
-                       for (bufp = buf; c > 0; c -= d, bufp += d)
-                               if ((d = send(dout, bufp, c, 0)) <= 0)
-                                       break;
-                       if (hash) {
-                               while (bytes >= hashbytes) {
-                                       (void) putchar('#');
-                                       hashbytes += HASHBYTES;
-                               }
-                               (void) fflush(stdout);
-                       }
-               }
-               if (hash && bytes > 0) {
-                       if (bytes < HASHBYTES)
-                               (void) putchar('#');
-                       (void) putchar('\n');
-                       (void) fflush(stdout);
-               }
-               if (c < 0)
-                       perror(local);
-               if (d <= 0) {
-                       if (d == 0)
-                               fprintf(stderr, "netout: write returned 0?\n");
-                       else if (errno != EPIPE)
-                               perror("netout");
-                       bytes = -1;
-               }
-               break;
-
-       case TYPE_A:
-               {
-        char buf[1024];
-               static int bufsize = 1024;
-               int ipos=0;
-
-               while ((c = getc(fin)) != EOF) {
-                   if (c == '\n') {
-                      while (hash && (bytes >= hashbytes)) {
-                         (void) putchar('#');
-                         (void) fflush(stdout);
-                         hashbytes += HASHBYTES;
-                      }
-// Szurgot: The following code is unncessary on Win32.
-//                      (void) fputcSocket(dout, '\r');
-//                         bytes++;
-                   }
-
-                                  if (ipos >= bufsize) {
-                                               fputSocket(dout,buf,ipos);
-                                               if(!hash) (void) putchar('.');
-                                               ipos=0;
-                                  }
-                                  buf[ipos]=c; ++ipos;
-                                  bytes++;
-               }
-               if (ipos) {
-                       fputSocket(dout,buf,ipos);
-                       ipos=0;
-               }
-               if (hash) {
-                   if (bytes < hashbytes)
-                      (void) putchar('#');
-                   (void) putchar('\n');
-                   (void) fflush(stdout);
-               }
-               else {
-                       (void) putchar('.');
-                       (void) putchar('\n');
-                       (void) fflush(stdout);
-               }
-               if (ferror(fin))
-                   perror(local);
-//             if (ferror(dout)) {
-//                     if (errno != EPIPE)
-//                             perror("netout");
-//                     bytes = -1;
-//             }
-                break;
-               }
-       }
-       (void) gettimeofday(&stop, (struct timezone *)0);
-       if (closefunc != NULL)
-               (*closefunc)(fin);
-       if(closesocket(dout)) {
-               int iret=WSAGetLastError ();
-               fprintf(stdout,"Error closing socket(%d)\n",iret);
-               (void) fflush(stdout);
-       }
-       (void) getreply(0);
-null();//      (void) signal(SIGINT, oldintr);
-       if (oldintp)
-null();//              (void) signal(SIGPIPE, oldintp);
-       if (bytes > 0)
-               ptransfer("sent", bytes, &start, &stop);
-       return;
-abort:
-       (void) gettimeofday(&stop, (struct timezone *)0);
-null();//      (void) signal(SIGINT, oldintr);
-       if (oldintp)
-null();//              (void) signal(SIGPIPE, oldintp);
-       if (!cpend) {
-               code = -1;
-               return;
-       }
-       if (data >= 0) {
-               (void) close(data);
-               data = -1;
-       }
-       if (dout)
-               if(closesocket(dout)) {
-                       int iret=WSAGetLastError ();
-                       fprintf(stdout,"Error closing socket(%d)\n",iret);
-                       (void) fflush(stdout);
-               }
-
-       (void) getreply(0);
-       code = -1;
-       if (closefunc != NULL && fin != NULL)
-               (*closefunc)(fin);
-       if (bytes > 0)
-               ptransfer("sent", bytes, &start, &stop);
-}
-
-jmp_buf        recvabort;
-
-#if 0
-void abortrecv()
-{
-
-       mflag = 0;
-       abrtflag = 0;
-       printf("\n");
-       (void) fflush(stdout);
-       longjmp(recvabort, 1);
-}
-#endif
-
-void recvrequest(const char *cmd, const char *local, const char *remote, const char *mode,
-                int printnames)
-{
-       FILE *fout = stdout;
-        int din = 0;
-       int (*closefunc)(), _pclose(), fclose();
-       void (*oldintr)(int), (*oldintp)(int);
-       int oldverbose = 0, oldtype = 0, is_retr, tcrflag, nfnd, bare_lfs = 0;
-       char msg;
-//     static char *buf; // Szurgot: Shouldn't this go SOMEWHERE?
-        char buf[1024];
-       static int bufsize = 1024;
-       long bytes = 0, hashbytes = HASHBYTES;
-//     struct
-               fd_set mask;
-       register int c, d;
-       struct timeval start, stop;
-//     struct stat st;
-       extern void *malloc();
-
-       is_retr = strcmp(cmd, "RETR") == 0;
-       if (is_retr && verbose && printnames) {
-               if (local && *local != '-')
-                       printf("local: %s ", local);
-               if (remote)
-                       printf("remote: %s\n", remote);
-               (void) fflush(stdout);
-       }
-       if (proxy && is_retr) {
-               proxtrans(cmd, local, remote);
-               return;
-       }
-       closefunc = NULL;
-       oldintr = NULL;
-       oldintp = NULL;
-       tcrflag = !crflag && is_retr;
-       if (setjmp(recvabort)) {
-               while (cpend) {
-                       (void) getreply(0);
-               }
-               if (data >= 0) {
-                       (void) close(data);
-                       data = -1;
-               }
-               if (oldintr)
-null();//                      (void) signal(SIGINT, oldintr);
-               code = -1;
-               return;
-       }
-null();//      oldintr = signal(SIGINT, abortrecv);
-       if (strcmp(local, "-") && *local != '|') {
-#ifndef __WIN32__
-// This whole thing is a problem... access Won't work on non-existent files
-           if (access(local, 2) < 0) {
-              char *dir = rindex(local, '/');
-
-              if (errno != ENOENT && errno != EACCES) {
-                 perror(local);
-                 (void) signal(SIGINT, oldintr);
-                 code = -1;
-                 return;
-              }
-              if (dir != NULL)
-                 *dir = 0;
-              d = access(dir ? local : ".", 2);
-              if (dir != NULL)
-                 *dir = '/';
-              if (d < 0) {
-                 perror(local);
-                 (void) signal(SIGINT, oldintr);
-                 code = -1;
-                 return;
-              }
-              if (!runique && errno == EACCES &&
-                  chmod(local, 0600) < 0) {
-                 perror(local);
-                 (void) signal(SIGINT, oldintr);
-                 code = -1;
-                 return;
-              }
-              if (runique && errno == EACCES &&
-                  (local = gunique(local)) == NULL) {
-                 (void) signal(SIGINT, oldintr);
-                 code = -1;
-                 return;
-              }
-           }
-           else if (runique && (local = gunique(local)) == NULL) {
-              (void) signal(SIGINT, oldintr);
-              code = -1;
-              return;
-           }
-#endif
-       }
-       if (initconn()) {
-null();//              (void) signal(SIGINT, oldintr);
-               code = -1;
-               return;
-       }
-       if (setjmp(recvabort))
-               goto abort;
-       if (!is_retr) {
-               if (type != TYPE_A && (allbinary == 0 || type != TYPE_I)) {
-                       oldtype = type;
-                       oldverbose = verbose;
-                       if (!debug)
-                               verbose = 0;
-                       setascii();
-                       verbose = oldverbose;
-               }
-       } else if (restart_point) {
-               if (command("REST %ld", (long) restart_point) != CONTINUE)
-                       return;
-       }
-       if (remote) {
-               if (command("%s %s", cmd, remote) != PRELIM) {
-null();//                      (void) signal(SIGINT, oldintr);
-                       if (oldtype) {
-                               if (!debug)
-                                       verbose = 0;
-                               switch (oldtype) {
-                                       case TYPE_I:
-                                               setbinary();
-                                               break;
-                                       case TYPE_E:
-                                               setebcdic();
-                                               break;
-                                       case TYPE_L:
-                                               settenex();
-                                               break;
-                               }
-                               verbose = oldverbose;
-                       }
-                       return;
-               }
-       } else {
-               if (command("%s", cmd) != PRELIM) {
-null();//                      (void) signal(SIGINT, oldintr);
-                       if (oldtype) {
-                               if (!debug)
-                                       verbose = 0;
-                               switch (oldtype) {
-                                       case TYPE_I:
-                                               setbinary();
-                                               break;
-                                       case TYPE_E:
-                                               setebcdic();
-                                               break;
-                                       case TYPE_L:
-                                               settenex();
-                                               break;
-                               }
-                               verbose = oldverbose;
-                       }
-                       return;
-               }
-       }
-       din = dataconn("r");
-       if (din == (int)NULL)
-               goto abort;
-       if (strcmp(local, "-") == 0)
-               fout = stdout;
-       else if (*local == '|') {
-null();//              oldintp = signal(SIGPIPE, SIG_IGN);
-               fout = _popen(local + 1, "w");
-               if (fout == NULL) {
-                       perror(local+1);
-                       goto abort;
-               }
-               closefunc = _pclose;
-       } else {
-               fout = fopen(local, mode);
-               if (fout == NULL) {
-                       perror(local);
-                       goto abort;
-               }
-               closefunc = fclose;
-       }
-       (void) gettimeofday(&start, (struct timezone *)0);
-       switch (type) {
-
-       case TYPE_I:
-       case TYPE_L:
-               if (restart_point &&
-                   lseek(fileno(fout), (long) restart_point, L_SET) < 0) {
-                       perror(local);
-                       if (closefunc != NULL)
-                               (*closefunc)(fout);
-                       return;
-               }
-               errno = d = 0;
-//             while ((c = recv(din, buf, bufsize, 1)) > 0) {
-//                     if ((d = write(fileno(fout), buf, c)) != c)
-//                     if ((d = write(fileno(fout), buf, c)) != c)
-//                             break;
-               while ((c = recv(din, buf, bufsize, 0)) > 0) {
-                   write(fileno(fout), buf, c);
-                   bytes += c;
-                   if (hash) {
-                      while (bytes >= hashbytes) {
-                         (void) putchar('#');
-                         hashbytes += HASHBYTES;
-                      }
-                      (void) fflush(stdout);
-                   }
-               }
-               if (hash && bytes > 0) {
-                       if (bytes < HASHBYTES)
-                               (void) putchar('#');
-                       (void) putchar('\n');
-                       (void) fflush(stdout);
-               }
-//             if (c < 0) {
-//                     if (errno != EPIPE)
-//                             perror("netin");
-//                     bytes = -1;
-//             }
-//             if (d < c) {
-//                     if (d < 0)
-//                             perror(local);
-//                     else
-//                             fprintf(stderr, "%s: short write\n", local);
-//             }
-               break;
-
-       case TYPE_A:
-               if (restart_point) {
-                       register int i, n, c;
-
-                       if (fseek(fout, 0L, L_SET) < 0)
-                               goto done;
-                       n = restart_point;
-                       i = 0;
-                       while (i++ < n) {
-                               if ((c=getc(fout)) == EOF)
-                                       goto done;
-                               if (c == '\n')
-                                       i++;
-                       }
-                       if (fseek(fout, 0L, L_INCR) < 0) {
-done:
-                               perror(local);
-                               if (closefunc != NULL)
-                                       (*closefunc)(fout);
-                               return;
-                       }
-               }
-               while ((c = fgetcSocket(din)) != EOF) {
-                       if (c == '\n')
-                               bare_lfs++;
-                       while (c == '\r') {
-                           while (hash && (bytes >= hashbytes)) {
-                              (void) putchar('#');
-                              (void) fflush(stdout);
-                              hashbytes += HASHBYTES;
-                           }
-                           bytes++;
-                           if ((c = fgetcSocket(din)) != '\n' || tcrflag) {
-                              if (ferror(fout))
-                                 goto break2;
-                              (void) putc('\r', fout);
-                              if (c == '\0') {
-                                 bytes++;
-                                 goto contin2;
-                              }
-                              if (c == EOF)
-                                 goto contin2;
-                           }
-                       }
-                       (void) putc(c, fout);
-                       bytes++;
-       contin2:        ;
-               }
-break2:
-               if (bare_lfs) {
-                       printf("WARNING! %d bare linefeeds received in ASCII mode\n", bare_lfs);
-                       printf("File may not have transferred correctly.\n");
-                       (void) fflush(stdout);
-               }
-               if (hash) {
-                       if (bytes < hashbytes)
-                               (void) putchar('#');
-                       (void) putchar('\n');
-                       (void) fflush(stdout);
-               }
-//             if (ferror(din)) {
-//                     if (errno != EPIPE)
-//                             perror("netin");
-//                     bytes = -1;
-//             }
-               if (ferror(fout))
-                       perror(local);
-               break;
-       }
-       if (closefunc != NULL)
-               (*closefunc)(fout);
-null();//      (void) signal(SIGINT, oldintr);
-       if (oldintp)
-null();//              (void) signal(SIGPIPE, oldintp);
-       (void) gettimeofday(&stop, (struct timezone *)0);
-       if(closesocket(din)) {
-               int iret=WSAGetLastError ();
-               fprintf(stdout,"Error closing socket(%d)\n",iret);
-               (void) fflush(stdout);
-       }
-
-       (void) getreply(0);
-       if (bytes > 0 && is_retr)
-               ptransfer("received", bytes, &start, &stop);
-       if (oldtype) {
-               if (!debug)
-                       verbose = 0;
-               switch (oldtype) {
-                       case TYPE_I:
-                               setbinary();
-                               break;
-                       case TYPE_E:
-                               setebcdic();
-                               break;
-                       case TYPE_L:
-                               settenex();
-                               break;
-               }
-               verbose = oldverbose;
-       }
-       return;
-abort:
-
-/* abort using RFC959 recommended IP,SYNC sequence  */
-
-       (void) gettimeofday(&stop, (struct timezone *)0);
-       if (oldintp)
-null();//              (void) signal(SIGPIPE, oldintr);
-null();//      (void) signal(SIGINT,SIG_IGN);
-       if (oldtype) {
-               if (!debug)
-                       verbose = 0;
-               switch (oldtype) {
-                       case TYPE_I:
-                               setbinary();
-                               break;
-                       case TYPE_E:
-                               setebcdic();
-                               break;
-                       case TYPE_L:
-                               settenex();
-                               break;
-               }
-               verbose = oldverbose;
-       }
-       if (!cpend) {
-               code = -1;
-null();//              (void) signal(SIGINT,oldintr);
-               return;
-       }
-
-       fprintfSocket(cout,"%c%c",IAC,IP);
-       msg = (char)IAC;
-/* send IAC in urgent mode instead of DM because UNIX places oob mark */
-/* after urgent byte rather than before as now is protocol            */
-       if (send(cout,&msg,1,MSG_OOB) != 1) {
-               perror("abort");
-       }
-       fprintfSocket(cout,"%cABOR\r\n",DM);
-       FD_ZERO(&mask);
-       FD_SET(cin, &mask); // Need to correct this
-       if (din) {
-               FD_SET(din, &mask); // Need to correct this
-       }
-       if ((nfnd = empty(&mask,10)) <= 0) {
-               if (nfnd < 0) {
-                       perror("abort");
-               }
-               code = -1;
-               lostpeer();
-       }
-       if (din && FD_ISSET(din, &mask)) {
-               while ((c = recv(din, buf, bufsize, 0)) > 0)
-                       ;
-       }
-       if ((c = getreply(0)) == ERROR && code == 552) { /* needed for nic style abort */
-               if (data >= 0) {
-                       (void) close(data);
-                       data = -1;
-               }
-               (void) getreply(0);
-       }
-       (void) getreply(0);
-       code = -1;
-       if (data >= 0) {
-               (void) close(data);
-               data = -1;
-       }
-       if (closefunc != NULL && fout != NULL)
-               (*closefunc)(fout);
-       if (din)
-               if(closesocket(din)) {
-                       int iret=WSAGetLastError ();
-                       fprintf(stdout,"Error closing socket(%d)\n",iret);
-                       (void) fflush(stdout);
-               }
-
-       if (bytes > 0)
-               ptransfer("received", bytes, &start, &stop);
-null();//      (void) signal(SIGINT,oldintr);
-}
-
-/*
- * Need to start a listen on the data channel
- * before we send the command, otherwise the
- * server's connect may fail.
- */
-int sendport = -1;
-
-int
-initconn()
-{
-       register char *p, *a;
-       int result, len, tmpno = 0;
-       int on = 1;
-       int a0, a1, a2, a3, p0, p1;
-
-
-       if (passivemode) {
-      data = socket(AF_INET, SOCK_STREAM, 0);
-      if (data < 0) {
-        perror("ftp: socket");
-        return(1);
-      }
-      if ((options & SO_DEBUG) &&
-          setsockopt(data, SOL_SOCKET, SO_DEBUG, (char *)&on,
-                     sizeof (on)) < 0)
-        perror("ftp: setsockopt (ignored)");
-      if (command("PASV") != COMPLETE) {
-        printf("Passive mode refused.\n");
-        goto bad;
-      }
-
-      /*
-       * What we've got at this point is a string of comma
-       * separated one-byte unsigned integer values.
-       * The first four are the an IP address. The fifth is
-       * the MSB of the port number, the sixth is the LSB.
-       * From that we'll prepare a sockaddr_in.
-       */
-
-      if (sscanf(pasv,"%d,%d,%d,%d,%d,%d",
-                 &a0, &a1, &a2, &a3, &p0, &p1) != 6) {
-        printf("Passive mode address scan failure. Shouldn't happen!\n");
-        goto bad;
-      }
-
-      bzero(&data_addr, sizeof(data_addr));
-      data_addr.sin_family = AF_INET;
-      a = (char *)&data_addr.sin_addr.s_addr;
-      a[0] = a0 & 0xff;
-      a[1] = a1 & 0xff;
-      a[2] = a2 & 0xff;
-      a[3] = a3 & 0xff;
-      p = (char *)&data_addr.sin_port;
-      p[0] = p0 & 0xff;
-      p[1] = p1 & 0xff;
-
-      if (connect(data, (struct sockaddr *)&data_addr,
-                  sizeof(data_addr)) < 0) {
-        perror("ftp: connect");
-        goto bad;
-      }
-      return(0);
-       }
-
-
-noport:
-       data_addr = myctladdr;
-       if (sendport)
-               data_addr.sin_port = 0; /* let system pick one */
-       if (data != -1)
-               (void) close (data);
-       data = socket(AF_INET, SOCK_STREAM, 0);
-       if (data < 0) {
-               perror("ftp: socket");
-               if (tmpno)
-                       sendport = 1;
-               return (1);
-       }
-       if (!sendport)
-               if (setsockopt(data, SOL_SOCKET, SO_REUSEADDR, (char *)&on, sizeof (on)) < 0) {
-                       perror("ftp: setsockopt (reuse address)");
-                       goto bad;
-               }
-       if (bind(data, (struct sockaddr *)&data_addr, sizeof (data_addr)) < 0) {
-               perror("ftp: bind");
-               goto bad;
-       }
-       if (options & SO_DEBUG &&
-           setsockopt(data, SOL_SOCKET, SO_DEBUG, (char *)&on, sizeof (on)) < 0)
-               perror("ftp: setsockopt (ignored)");
-       len = sizeof (data_addr);
-       if (getsockname(data, (struct sockaddr *)&data_addr, &len) < 0) {
-               perror("ftp: getsockname");
-               goto bad;
-       }
-       if (listen(data, 1) < 0)
-               perror("ftp: listen");
-       if (sendport) {
-               a = (char *)&data_addr.sin_addr;
-               p = (char *)&data_addr.sin_port;
-#define        UC(b)   (((int)b)&0xff)
-               result =
-                   command("PORT %d,%d,%d,%d,%d,%d",
-                     UC(a[0]), UC(a[1]), UC(a[2]), UC(a[3]),
-                     UC(p[0]), UC(p[1]));
-               if (result == ERROR && sendport == -1) {
-                       sendport = 0;
-                       tmpno = 1;
-                       goto noport;
-               }
-               return (result != COMPLETE);
-       }
-       if (tmpno)
-               sendport = 1;
-       return (0);
-bad:
-       (void) fflush(stdout);
-       (void) close(data), data = -1;
-       if (tmpno)
-               sendport = 1;
-       return (1);
-}
-
-int dataconn(const char *mode)
-{
-   struct sockaddr_in from;
-   int s, fromlen = sizeof (from);
-
-   if (passivemode)
-     return (data);
-
-   s = accept(data, (struct sockaddr *) &from, &fromlen);
-   if (s < 0) {
-      perror("ftp: accept");
-      (void) closesocket(data), data = -1;
-      return (int) (NULL);
-   }
-       if(closesocket(data)) {
-               int iret=WSAGetLastError ();
-               fprintf(stdout,"Error closing socket(%d)\n",iret);
-               (void) fflush(stdout);
-       }
-
-   data = s;
-   return (data);
-}
-
-void ptransfer(direction, bytes, t0, t1)
-       const char *direction;
-       long bytes;
-       struct timeval *t0, *t1;
-{
-       struct timeval td;
-       double s, bs;
-
-       if (verbose) {
-               tvsub(&td, t1, t0);
-               s = td.tv_sec + (td.tv_usec / 1000000.);
-#define        nz(x)   ((x) == 0 ? 1 : (x))
-               bs = bytes / nz(s);
-               printf("%ld bytes %s in %.1f seconds (%.0f Kbytes/s)\n",
-                   bytes, direction, s, bs / 1024.);
-               (void) fflush(stdout);
-       }
-}
-
-/*tvadd(tsum, t0)
-       struct timeval *tsum, *t0;
-{
-
-       tsum->tv_sec += t0->tv_sec;
-       tsum->tv_usec += t0->tv_usec;
-       if (tsum->tv_usec > 1000000)
-               tsum->tv_sec++, tsum->tv_usec -= 1000000;
-} */
-
-void tvsub(tdiff, t1, t0)
-       struct timeval *tdiff, *t1, *t0;
-{
-
-       tdiff->tv_sec = t1->tv_sec - t0->tv_sec;
-       tdiff->tv_usec = t1->tv_usec - t0->tv_usec;
-       if (tdiff->tv_usec < 0)
-               tdiff->tv_sec--, tdiff->tv_usec += 1000000;
-}
-
-void psabort(int flag)
-{
-       extern int abrtflag;
-
-       abrtflag++;
-}
-
-void pswitch(int flag)
-{
-       extern int proxy, abrtflag;
-       Sig_t oldintr;
-       static struct comvars {
-               int connect;
-               char name[MAXHOSTNAMELEN];
-               struct sockaddr_in mctl;
-               struct sockaddr_in hctl;
-               SOCKET in;
-               SOCKET out;
-               int tpe;
-               int cpnd;
-               int sunqe;
-               int runqe;
-               int mcse;
-               int ntflg;
-               char nti[17];
-               char nto[17];
-               int mapflg;
-               char mi[MAXPATHLEN];
-               char mo[MAXPATHLEN];
-               } proxstruct, tmpstruct;
-       struct comvars *ip, *op;
-
-       abrtflag = 0;
-    oldintr = signal(SIGINT, psabort);
-       if (flag) {
-               if (proxy)
-                       return;
-               ip = &tmpstruct;
-               op = &proxstruct;
-               proxy++;
-       }
-       else {
-               if (!proxy)
-                       return;
-               ip = &proxstruct;
-               op = &tmpstruct;
-               proxy = 0;
-       }
-       ip->connect = connected;
-       connected = op->connect;
-       if (hostname) {
-               (void) strncpy(ip->name, hostname, sizeof(ip->name) - 1);
-               ip->name[strlen(ip->name)] = '\0';
-       } else
-               ip->name[0] = 0;
-       hostname = op->name;
-       ip->hctl = hisctladdr;
-       hisctladdr = op->hctl;
-       ip->mctl = myctladdr;
-       myctladdr = op->mctl;
-       ip->in = cin;
-       cin = op->in;
-       ip->out = cout;
-       cout = op->out;
-       ip->tpe = type;
-       type = op->tpe;
-       if (!type)
-               type = 1;
-       ip->cpnd = cpend;
-       cpend = op->cpnd;
-       ip->sunqe = sunique;
-       sunique = op->sunqe;
-       ip->runqe = runique;
-       runique = op->runqe;
-       ip->mcse = mcase;
-       mcase = op->mcse;
-       ip->ntflg = ntflag;
-       ntflag = op->ntflg;
-       (void) strncpy(ip->nti, ntin, 16);
-       (ip->nti)[strlen(ip->nti)] = '\0';
-       (void) strcpy(ntin, op->nti);
-       (void) strncpy(ip->nto, ntout, 16);
-       (ip->nto)[strlen(ip->nto)] = '\0';
-       (void) strcpy(ntout, op->nto);
-       ip->mapflg = mapflag;
-       mapflag = op->mapflg;
-       (void) strncpy(ip->mi, mapin, MAXPATHLEN - 1);
-       (ip->mi)[strlen(ip->mi)] = '\0';
-       (void) strcpy(mapin, op->mi);
-       (void) strncpy(ip->mo, mapout, MAXPATHLEN - 1);
-       (ip->mo)[strlen(ip->mo)] = '\0';
-       (void) strcpy(mapout, op->mo);
-//        (void) signal(SIGINT, oldintr);
-       if (abrtflag) {
-               abrtflag = 0;
-               (*oldintr)(1);
-       }
-}
-
-jmp_buf ptabort;
-int ptabflg;
-
-#if 0
-void
-abortpt()
-{
-       printf("\n");
-       (void) fflush(stdout);
-       ptabflg++;
-       mflag = 0;
-       abrtflag = 0;
-       longjmp(ptabort, 1);
-}
-#endif
-
-void proxtrans(cmd, local, remote)
-       const char *cmd, *local, *remote;
-{
-//     void (*oldintr)(int);
-       int tmptype, oldtype = 0, secndflag = 0, nfnd;
-       extern jmp_buf ptabort;
-       const char *cmd2;
-//     struct
-       fd_set mask;
-
-       if (strcmp(cmd, "RETR"))
-               cmd2 = "RETR";
-       else
-               cmd2 = runique ? "STOU" : "STOR";
-       if (command("PASV") != COMPLETE) {
-               printf("proxy server does not support third part transfers.\n");
-               (void) fflush(stdout);
-               return;
-       }
-       tmptype = type;
-       pswitch(0);
-       if (!connected) {
-               printf("No primary connection\n");
-               (void) fflush(stdout);
-               pswitch(1);
-               code = -1;
-               return;
-       }
-       if (type != tmptype) {
-               oldtype = type;
-               switch (tmptype) {
-                       case TYPE_A:
-                               setascii();
-                               break;
-                       case TYPE_I:
-                               setbinary();
-                               break;
-                       case TYPE_E:
-                               setebcdic();
-                               break;
-                       case TYPE_L:
-                               settenex();
-                               break;
-               }
-       }
-       if (command("PORT %s", pasv) != COMPLETE) {
-               switch (oldtype) {
-                       case 0:
-                               break;
-                       case TYPE_A:
-                               setascii();
-                               break;
-                       case TYPE_I:
-                               setbinary();
-                               break;
-                       case TYPE_E:
-                               setebcdic();
-                               break;
-                       case TYPE_L:
-                               settenex();
-                               break;
-               }
-               pswitch(1);
-               return;
-       }
-       if (setjmp(ptabort))
-               goto abort;
-null();//      oldintr = signal(SIGINT, abortpt);
-       if (command("%s %s", cmd, remote) != PRELIM) {
-null();//              (void) signal(SIGINT, oldintr);
-               switch (oldtype) {
-                       case 0:
-                               break;
-                       case TYPE_A:
-                               setascii();
-                               break;
-                       case TYPE_I:
-                               setbinary();
-                               break;
-                       case TYPE_E:
-                               setebcdic();
-                               break;
-                       case TYPE_L:
-                               settenex();
-                               break;
-               }
-               pswitch(1);
-               return;
-       }
-       sleep(2);
-       pswitch(1);
-       secndflag++;
-       if (command("%s %s", cmd2, local) != PRELIM)
-               goto abort;
-       ptflag++;
-       (void) getreply(0);
-       pswitch(0);
-       (void) getreply(0);
-null();//      (void) signal(SIGINT, oldintr);
-       switch (oldtype) {
-               case 0:
-                       break;
-               case TYPE_A:
-                       setascii();
-                       break;
-               case TYPE_I:
-                       setbinary();
-                       break;
-               case TYPE_E:
-                       setebcdic();
-                       break;
-               case TYPE_L:
-                       settenex();
-                       break;
-       }
-       pswitch(1);
-       ptflag = 0;
-       printf("local: %s remote: %s\n", local, remote);
-       (void) fflush(stdout);
-       return;
-abort:
-null();//      (void) signal(SIGINT, SIG_IGN);
-       ptflag = 0;
-       if (strcmp(cmd, "RETR") && !proxy)
-               pswitch(1);
-       else if (!strcmp(cmd, "RETR") && proxy)
-               pswitch(0);
-       if (!cpend && !secndflag) {  /* only here if cmd = "STOR" (proxy=1) */
-               if (command("%s %s", cmd2, local) != PRELIM) {
-                       pswitch(0);
-                       switch (oldtype) {
-                               case 0:
-                                       break;
-                               case TYPE_A:
-                                       setascii();
-                                       break;
-                               case TYPE_I:
-                                       setbinary();
-                                       break;
-                               case TYPE_E:
-                                       setebcdic();
-                                       break;
-                               case TYPE_L:
-                                       settenex();
-                                       break;
-                       }
-                       if (cpend) {
-                               char msg[2];
-
-                               fprintfSocket(cout,"%c%c",IAC,IP);
-                               *msg = (char) IAC;
-                               *(msg+1) = (char) DM;
-                               if (send(cout,msg,2,MSG_OOB) != 2)
-                                       perror("abort");
-                               fprintfSocket(cout,"ABOR\r\n");
-                               FD_ZERO(&mask);
-//                             FD_SET(fileno(cin), &mask); // Chris: Need to correct this
-                               if ((nfnd = empty(&mask,10)) <= 0) {
-                                       if (nfnd < 0) {
-                                               perror("abort");
-                                       }
-                                       if (ptabflg)
-                                               code = -1;
-                                       lostpeer();
-                               }
-                               (void) getreply(0);
-                               (void) getreply(0);
-                       }
-               }
-               pswitch(1);
-               if (ptabflg)
-                       code = -1;
-null();//              (void) signal(SIGINT, oldintr);
-               return;
-       }
-       if (cpend) {
-               char msg[2];
-
-               fprintfSocket(cout,"%c%c",IAC,IP);
-               *msg = (char)IAC;
-               *(msg+1) = (char)DM;
-               if (send(cout,msg,2,MSG_OOB) != 2)
-                       perror("abort");
-               fprintfSocket(cout,"ABOR\r\n");
-               FD_ZERO(&mask);
-//             FD_SET(fileno(cin), &mask); // Chris: Need to correct this...
-               if ((nfnd = empty(&mask,10)) <= 0) {
-                       if (nfnd < 0) {
-                               perror("abort");
-                       }
-                       if (ptabflg)
-                               code = -1;
-                       lostpeer();
-               }
-               (void) getreply(0);
-               (void) getreply(0);
-       }
-       pswitch(!proxy);
-       if (!cpend && !secndflag) {  /* only if cmd = "RETR" (proxy=1) */
-               if (command("%s %s", cmd2, local) != PRELIM) {
-                       pswitch(0);
-                       switch (oldtype) {
-                               case 0:
-                                       break;
-                               case TYPE_A:
-                                       setascii();
-                                       break;
-                               case TYPE_I:
-                                       setbinary();
-                                       break;
-                               case TYPE_E:
-                                       setebcdic();
-                                       break;
-                               case TYPE_L:
-                                       settenex();
-                                       break;
-                       }
-                       if (cpend) {
-                               char msg[2];
-
-                               fprintfSocket(cout,"%c%c",IAC,IP);
-                               *msg = (char)IAC;
-                               *(msg+1) = (char)DM;
-                               if (send(cout,msg,2,MSG_OOB) != 2)
-                                       perror("abort");
-                               fprintfSocket(cout,"ABOR\r\n");
-                               FD_ZERO(&mask);
-//                             FD_SET(fileno(cin), &mask); // Chris:
-                               if ((nfnd = empty(&mask,10)) <= 0) {
-                                       if (nfnd < 0) {
-                                               perror("abort");
-                                       }
-                                       if (ptabflg)
-                                               code = -1;
-                                       lostpeer();
-                               }
-                               (void) getreply(0);
-                               (void) getreply(0);
-                       }
-                       pswitch(1);
-                       if (ptabflg)
-                               code = -1;
-null();//                      (void) signal(SIGINT, oldintr);
-                       return;
-               }
-       }
-       if (cpend) {
-               char msg[2];
-
-               fprintfSocket(cout,"%c%c",IAC,IP);
-               *msg = (char)IAC;
-               *(msg+1) = (char)DM;
-               if (send(cout,msg,2,MSG_OOB) != 2)
-                       perror("abort");
-               fprintfSocket(cout,"ABOR\r\n");
-               FD_ZERO(&mask);
-//             FD_SET(fileno(cin), &mask); // Chris:
-               if ((nfnd = empty(&mask,10)) <= 0) {
-                       if (nfnd < 0) {
-                               perror("abort");
-                       }
-                       if (ptabflg)
-                               code = -1;
-                       lostpeer();
-               }
-               (void) getreply(0);
-               (void) getreply(0);
-       }
-       pswitch(!proxy);
-       if (cpend) {
-               FD_ZERO(&mask);
-//             FD_SET(fileno(cin), &mask); // Chris:
-               if ((nfnd = empty(&mask,10)) <= 0) {
-                       if (nfnd < 0) {
-                               perror("abort");
-                       }
-                       if (ptabflg)
-                               code = -1;
-                       lostpeer();
-               }
-               (void) getreply(0);
-               (void) getreply(0);
-       }
-       if (proxy)
-               pswitch(0);
-       switch (oldtype) {
-               case 0:
-                       break;
-               case TYPE_A:
-                       setascii();
-                       break;
-               case TYPE_I:
-                       setbinary();
-                       break;
-               case TYPE_E:
-                       setebcdic();
-                       break;
-               case TYPE_L:
-                       settenex();
-                       break;
-       }
-       pswitch(1);
-       if (ptabflg)
-               code = -1;
-null();//      (void) signal(SIGINT, oldintr);
-}
-
-void reset()
-{
-//     struct
-       fd_set mask;
-       int nfnd = 1;
-
-       FD_ZERO(&mask);
-       while (nfnd > 0) {
-//             FD_SET(fileno(cin), &mask); // Chris
-               if ((nfnd = empty(&mask,0)) < 0) {
-                       perror("reset");
-                       code = -1;
-                       lostpeer();
-               }
-               else if (nfnd) {
-                       (void) getreply(0);
-               }
-       }
-}
-
-#if 0
-char *
-gunique(local)
-       char *local;
-{
-       static char new[MAXPATHLEN];
-       char *cp = rindex(local, '/');
-       int d, count=0;
-       char ext = '1';
-
-       if (cp)
-               *cp = '\0';
-       d = access(cp ? local : ".", 2);
-       if (cp)
-               *cp = '/';
-       if (d < 0) {
-               perror(local);
-               return((char *) 0);
-       }
-       (void) strcpy(new, local);
-       cp = new + strlen(new);
-       *cp++ = '.';
-       while (!d) {
-               if (++count == 100) {
-                       printf("runique: can't find unique file name.\n");
-                       (void) fflush(stdout);
-                       return((char *) 0);
-               }
-               *cp++ = ext;
-               *cp = '\0';
-               if (ext == '9')
-                       ext = '0';
-               else
-                       ext++;
-               if ((d = access(new, 0)) < 0)
-                       break;
-               if (ext != '0')
-                       cp--;
-               else if (*(cp - 2) == '.')
-                       *(cp - 1) = '1';
-               else {
-                       *(cp - 2) = *(cp - 2) + 1;
-                       cp--;
-               }
-       }
-       return(new);
-}
-#endif
-
-int null(void)
-{
-   return 0;
-}
diff --git a/reactos/apps/utils/net/ftp/ftp.mak b/reactos/apps/utils/net/ftp/ftp.mak
deleted file mode 100644 (file)
index 084404f..0000000
+++ /dev/null
@@ -1,372 +0,0 @@
-# Microsoft Developer Studio Generated NMAKE File, Based on ftp.dsp
-!IF "$(CFG)" == ""
-CFG=ftp - Win32 Debug
-!MESSAGE No configuration specified. Defaulting to ftp - Win32 Debug.
-!ENDIF
-
-!IF "$(CFG)" != "ftp - Win32 Release" && "$(CFG)" != "ftp - Win32 Debug"
-!MESSAGE Invalid configuration "$(CFG)" specified.
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "ftp.mak" CFG="ftp - Win32 Debug"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "ftp - Win32 Release" (based on "Win32 (x86) Console Application")
-!MESSAGE "ftp - Win32 Debug" (based on "Win32 (x86) Console Application")
-!MESSAGE
-!ERROR An invalid configuration is specified.
-!ENDIF
-
-!IF "$(OS)" == "Windows_NT"
-NULL=
-!ELSE
-NULL=nul
-!ENDIF
-
-!IF  "$(CFG)" == "ftp - Win32 Release"
-
-OUTDIR=.\Release
-INTDIR=.\Release
-# Begin Custom Macros
-OutDir=.\Release
-# End Custom Macros
-
-!IF "$(RECURSE)" == "0"
-
-ALL : "$(OUTDIR)\ftp.exe"
-
-!ELSE
-
-ALL : "$(OUTDIR)\ftp.exe"
-
-!ENDIF
-
-CLEAN :
-       -@erase "$(INTDIR)\cmds.obj"
-       -@erase "$(INTDIR)\cmdtab.obj"
-       -@erase "$(INTDIR)\domacro.obj"
-       -@erase "$(INTDIR)\fake.obj"
-       -@erase "$(INTDIR)\ftp.obj"
-       -@erase "$(INTDIR)\main.obj"
-       -@erase "$(INTDIR)\ruserpass.obj"
-       -@erase "$(INTDIR)\vc*.idb"
-       -@erase "$(OUTDIR)\ftp.exe"
-       -@erase "$(OUTDIR)\ftp.pch"
-
-"$(OUTDIR)" :
-    if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
-
-CPP=cl.exe
-CPP_PROJ=/nologo /ML /W3 /GX /O2  /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" \
- /D "HAVE_TIMEVAL" /Fp"$(INTDIR)\ftp.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD\
- /c
-CPP_OBJS=.\Release/
-CPP_SBRS=.
-
-.c{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cpp{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cxx{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.c{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cpp{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cxx{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-RSC=rc.exe
-BSC32=bscmake.exe
-BSC32_FLAGS=/nologo /o"$(OUTDIR)\ftp.bsc"
-BSC32_SBRS= \
-
-LINK32=link.exe
-LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib\
- advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib\
- odbccp32.lib wsock32.lib /nologo /subsystem:console /incremental:no\
- /pdb:"$(OUTDIR)\ftp.pdb" /machine:I386 /out:"$(OUTDIR)\ftp.exe"
-LINK32_OBJS= \
-       "$(INTDIR)\cmds.obj" \
-       "$(INTDIR)\cmdtab.obj" \
-       "$(INTDIR)\domacro.obj" \
-       "$(INTDIR)\fake.obj" \
-       "$(INTDIR)\ftp.obj" \
-       "$(INTDIR)\main.obj" \
-       "$(INTDIR)\ruserpass.obj"
-
-"$(OUTDIR)\ftp.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
-    $(LINK32) @<<
-  $(LINK32_FLAGS) $(LINK32_OBJS)
-<<
-
-TargetPath=.\Release\ftp.exe
-InputPath=.\Release\ftp.exe
-SOURCE=$(InputPath)
-
-!ELSEIF  "$(CFG)" == "ftp - Win32 Debug"
-
-OUTDIR=.\Debug
-INTDIR=.\Debug
-# Begin Custom Macros
-OutDir=.\Debug
-# End Custom Macros
-
-!IF "$(RECURSE)" == "0"
-
-ALL : "$(OUTDIR)\ftp.exe"
-
-!ELSE
-
-ALL : "$(OUTDIR)\ftp.exe"
-
-!ENDIF
-
-CLEAN :
-       -@erase "$(INTDIR)\cmds.obj"
-       -@erase "$(INTDIR)\cmdtab.obj"
-       -@erase "$(INTDIR)\domacro.obj"
-       -@erase "$(INTDIR)\fake.obj"
-       -@erase "$(INTDIR)\ftp.obj"
-       -@erase "$(INTDIR)\main.obj"
-       -@erase "$(INTDIR)\ruserpass.obj"
-       -@erase "$(INTDIR)\vc*.idb"
-       -@erase "$(INTDIR)\vc*.pdb"
-       -@erase "$(OUTDIR)\ftp.exe"
-       -@erase "$(OUTDIR)\ftp.ilk"
-       -@erase "$(OUTDIR)\ftp.pdb"
-       -@erase "$(OUTDIR)\ftp.pch"
-
-"$(OUTDIR)" :
-    if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
-
-CPP=cl.exe
-CPP_PROJ=/nologo /MLd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS"\
- /Fp"$(INTDIR)\ftp.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
-CPP_OBJS=.\Debug/
-CPP_SBRS=.
-
-.c{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cpp{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cxx{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.c{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cpp{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cxx{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-RSC=rc.exe
-BSC32=bscmake.exe
-BSC32_FLAGS=/nologo /o"$(OUTDIR)\ftp.bsc"
-BSC32_SBRS= \
-
-LINK32=link.exe
-LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib\
- advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib\
- odbccp32.lib wsock32.lib /nologo /subsystem:console /incremental:yes\
- /pdb:"$(OUTDIR)\ftp.pdb" /debug /machine:I386 /out:"$(OUTDIR)\ftp.exe"\
- /pdbtype:sept
-LINK32_OBJS= \
-       "$(INTDIR)\cmds.obj" \
-       "$(INTDIR)\cmdtab.obj" \
-       "$(INTDIR)\domacro.obj" \
-       "$(INTDIR)\fake.obj" \
-       "$(INTDIR)\ftp.obj" \
-       "$(INTDIR)\main.obj" \
-       "$(INTDIR)\ruserpass.obj"
-
-"$(OUTDIR)\ftp.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
-    $(LINK32) @<<
-  $(LINK32_FLAGS) $(LINK32_OBJS)
-<<
-
-TargetPath=.\Debug\ftp.exe
-InputPath=.\Debug\ftp.exe
-SOURCE=$(InputPath)
-
-!ENDIF
-
-
-!IF "$(CFG)" == "ftp - Win32 Release" || "$(CFG)" == "ftp - Win32 Debug"
-SOURCE=.\cmds.c
-
-!IF  "$(CFG)" == "ftp - Win32 Release"
-
-DEP_CPP_CMDS_=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\pathnames.h"\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\cmds.obj" : $(SOURCE) $(DEP_CPP_CMDS_) "$(INTDIR)"
-
-
-!ELSEIF  "$(CFG)" == "ftp - Win32 Debug"
-
-DEP_CPP_CMDS_=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\pathnames.h"\
-       ".\prototypes.h"\
-       {$(INCLUDE)}"sys\stat.h"\
-       {$(INCLUDE)}"sys\types.h"\
-
-
-"$(INTDIR)\cmds.obj" : $(SOURCE) $(DEP_CPP_CMDS_) "$(INTDIR)"
-
-
-!ENDIF
-
-SOURCE=.\cmdtab.c
-DEP_CPP_CMDTA=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-
-
-"$(INTDIR)\cmdtab.obj" : $(SOURCE) $(DEP_CPP_CMDTA) "$(INTDIR)"
-
-
-SOURCE=.\domacro.c
-DEP_CPP_DOMAC=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\domacro.obj" : $(SOURCE) $(DEP_CPP_DOMAC) "$(INTDIR)"
-
-
-SOURCE=.\fake.c
-DEP_CPP_FAKE_=\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\fake.obj" : $(SOURCE) $(DEP_CPP_FAKE_) "$(INTDIR)"
-
-
-SOURCE=.\ftp.c
-
-!IF  "$(CFG)" == "ftp - Win32 Release"
-
-DEP_CPP_FTP_C=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\ftp.obj" : $(SOURCE) $(DEP_CPP_FTP_C) "$(INTDIR)"
-
-
-!ELSEIF  "$(CFG)" == "ftp - Win32 Debug"
-
-DEP_CPP_FTP_C=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-       {$(INCLUDE)}"sys\stat.h"\
-       {$(INCLUDE)}"sys\types.h"\
-
-
-"$(INTDIR)\ftp.obj" : $(SOURCE) $(DEP_CPP_FTP_C) "$(INTDIR)"
-
-
-!ENDIF
-
-SOURCE=.\main.c
-
-!IF  "$(CFG)" == "ftp - Win32 Release"
-
-DEP_CPP_MAIN_=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\main.obj" : $(SOURCE) $(DEP_CPP_MAIN_) "$(INTDIR)"
-
-
-!ELSEIF  "$(CFG)" == "ftp - Win32 Debug"
-
-DEP_CPP_MAIN_=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-       {$(INCLUDE)}"sys\types.h"\
-
-
-"$(INTDIR)\main.obj" : $(SOURCE) $(DEP_CPP_MAIN_) "$(INTDIR)"
-
-
-!ENDIF
-
-SOURCE=.\ruserpass.c
-
-!IF  "$(CFG)" == "ftp - Win32 Release"
-
-DEP_CPP_RUSER=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\ruserpass.obj" : $(SOURCE) $(DEP_CPP_RUSER) "$(INTDIR)"
-
-
-!ELSEIF  "$(CFG)" == "ftp - Win32 Debug"
-
-DEP_CPP_RUSER=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-       {$(INCLUDE)}"sys\stat.h"\
-       {$(INCLUDE)}"sys\types.h"\
-
-
-"$(INTDIR)\ruserpass.obj" : $(SOURCE) $(DEP_CPP_RUSER) "$(INTDIR)"
-
-
-!ENDIF
-
-
-!ENDIF
diff --git a/reactos/apps/utils/net/ftp/ftp.mak.orig b/reactos/apps/utils/net/ftp/ftp.mak.orig
deleted file mode 100644 (file)
index b482649..0000000
+++ /dev/null
@@ -1,400 +0,0 @@
-# Microsoft Developer Studio Generated NMAKE File, Based on ftp.dsp
-!IF "$(CFG)" == ""
-CFG=ftp - Win32 Debug
-!MESSAGE No configuration specified. Defaulting to ftp - Win32 Debug.
-!ENDIF
-
-!IF "$(CFG)" != "ftp - Win32 Release" && "$(CFG)" != "ftp - Win32 Debug"
-!MESSAGE Invalid configuration "$(CFG)" specified.
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "ftp.mak" CFG="ftp - Win32 Debug"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "ftp - Win32 Release" (based on "Win32 (x86) Console Application")
-!MESSAGE "ftp - Win32 Debug" (based on "Win32 (x86) Console Application")
-!MESSAGE
-!ERROR An invalid configuration is specified.
-!ENDIF
-
-!IF "$(OS)" == "Windows_NT"
-NULL=
-!ELSE
-NULL=nul
-!ENDIF
-
-!IF  "$(CFG)" == "ftp - Win32 Release"
-
-OUTDIR=.\Release
-INTDIR=.\Release
-# Begin Custom Macros
-OutDir=.\Release
-# End Custom Macros
-
-!IF "$(RECURSE)" == "0"
-
-ALL : "$(OUTDIR)\ftp.exe" "\emacs-19.34\bin\ftp.exe"
-
-!ELSE
-
-ALL : "$(OUTDIR)\ftp.exe" "\emacs-19.34\bin\ftp.exe"
-
-!ENDIF
-
-CLEAN :
-       -@erase "$(INTDIR)\cmds.obj"
-       -@erase "$(INTDIR)\cmdtab.obj"
-       -@erase "$(INTDIR)\domacro.obj"
-       -@erase "$(INTDIR)\fake.obj"
-       -@erase "$(INTDIR)\ftp.obj"
-       -@erase "$(INTDIR)\main.obj"
-       -@erase "$(INTDIR)\ruserpass.obj"
-       -@erase "$(INTDIR)\vc50.idb"
-       -@erase "$(OUTDIR)\ftp.exe"
-       -@erase "\emacs-19.34\bin\ftp.exe"
-
-"$(OUTDIR)" :
-    if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
-
-CPP=cl.exe
-CPP_PROJ=/nologo /ML /W3 /GX /O2 /I "C:\emacs-19.34\nt\inc" /I\
- "C:\emacs-19.34\src" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /D\
- "HAVE_TIMEVAL" /Fp"$(INTDIR)\ftp.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD\
- /c
-CPP_OBJS=.\Release/
-CPP_SBRS=.
-
-.c{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cpp{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cxx{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.c{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cpp{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cxx{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-RSC=rc.exe
-BSC32=bscmake.exe
-BSC32_FLAGS=/nologo /o"$(OUTDIR)\ftp.bsc"
-BSC32_SBRS= \
-
-LINK32=link.exe
-LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib\
- advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib\
- odbccp32.lib /nologo /subsystem:console /incremental:no\
- /pdb:"$(OUTDIR)\ftp.pdb" /machine:I386 /out:"$(OUTDIR)\ftp.exe"
-LINK32_OBJS= \
-       "$(INTDIR)\cmds.obj" \
-       "$(INTDIR)\cmdtab.obj" \
-       "$(INTDIR)\domacro.obj" \
-       "$(INTDIR)\fake.obj" \
-       "$(INTDIR)\ftp.obj" \
-       "$(INTDIR)\main.obj" \
-       "$(INTDIR)\ruserpass.obj" \
-       "d:\Program Files\DevStudio\VC\lib\WSOCK32.LIB"
-
-"$(OUTDIR)\ftp.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
-    $(LINK32) @<<
-  $(LINK32_FLAGS) $(LINK32_OBJS)
-<<
-
-TargetPath=.\Release\ftp.exe
-InputPath=.\Release\ftp.exe
-SOURCE=$(InputPath)
-
-"\emacs-19.34\bin\ftp.exe"      : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
-#      copy $(TargetPath) \emacs-19.34\bin
-
-!ELSEIF  "$(CFG)" == "ftp - Win32 Debug"
-
-OUTDIR=.\Debug
-INTDIR=.\Debug
-# Begin Custom Macros
-OutDir=.\Debug
-# End Custom Macros
-
-!IF "$(RECURSE)" == "0"
-
-ALL : "$(OUTDIR)\ftp.exe" "\emacs-19.34\bin\ftp.exe"
-
-!ELSE
-
-ALL : "$(OUTDIR)\ftp.exe" "\emacs-19.34\bin\ftp.exe"
-
-!ENDIF
-
-CLEAN :
-       -@erase "$(INTDIR)\cmds.obj"
-       -@erase "$(INTDIR)\cmdtab.obj"
-       -@erase "$(INTDIR)\domacro.obj"
-       -@erase "$(INTDIR)\fake.obj"
-       -@erase "$(INTDIR)\ftp.obj"
-       -@erase "$(INTDIR)\main.obj"
-       -@erase "$(INTDIR)\ruserpass.obj"
-       -@erase "$(INTDIR)\vc50.idb"
-       -@erase "$(INTDIR)\vc50.pdb"
-       -@erase "$(OUTDIR)\ftp.exe"
-       -@erase "$(OUTDIR)\ftp.ilk"
-       -@erase "$(OUTDIR)\ftp.pdb"
-       -@erase "\emacs-19.34\bin\ftp.exe"
-
-"$(OUTDIR)" :
-    if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
-
-CPP=cl.exe
-CPP_PROJ=/nologo /MLd /W3 /Gm /GX /Zi /Od /I "C:\emacs-19.34\nt\inc" /I\
- "C:\emacs-19.34\src" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS"\
- /Fp"$(INTDIR)\ftp.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
-CPP_OBJS=.\Debug/
-CPP_SBRS=.
-
-.c{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cpp{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cxx{$(CPP_OBJS)}.obj::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.c{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cpp{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-.cxx{$(CPP_SBRS)}.sbr::
-   $(CPP) @<<
-   $(CPP_PROJ) $<
-<<
-
-RSC=rc.exe
-BSC32=bscmake.exe
-BSC32_FLAGS=/nologo /o"$(OUTDIR)\ftp.bsc"
-BSC32_SBRS= \
-
-LINK32=link.exe
-LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib\
- advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib\
- odbccp32.lib /nologo /subsystem:console /incremental:yes\
- /pdb:"$(OUTDIR)\ftp.pdb" /debug /machine:I386 /out:"$(OUTDIR)\ftp.exe"\
- /pdbtype:sept
-LINK32_OBJS= \
-       "$(INTDIR)\cmds.obj" \
-       "$(INTDIR)\cmdtab.obj" \
-       "$(INTDIR)\domacro.obj" \
-       "$(INTDIR)\fake.obj" \
-       "$(INTDIR)\ftp.obj" \
-       "$(INTDIR)\main.obj" \
-       "$(INTDIR)\ruserpass.obj" \
-       "d:\Program Files\DevStudio\VC\lib\WSOCK32.LIB"
-
-"$(OUTDIR)\ftp.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
-    $(LINK32) @<<
-  $(LINK32_FLAGS) $(LINK32_OBJS)
-<<
-
-TargetPath=.\Debug\ftp.exe
-InputPath=.\Debug\ftp.exe
-SOURCE=$(InputPath)
-
-"\emacs-19.34\bin\ftp.exe"      : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
-#      copy $(TargetPath) \emacs-19.34\bin
-
-!ENDIF
-
-
-!IF "$(CFG)" == "ftp - Win32 Release" || "$(CFG)" == "ftp - Win32 Debug"
-SOURCE=.\cmds.c
-
-!IF  "$(CFG)" == "ftp - Win32 Release"
-
-DEP_CPP_CMDS_=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\pathnames.h"\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\cmds.obj" : $(SOURCE) $(DEP_CPP_CMDS_) "$(INTDIR)"
-
-
-!ELSEIF  "$(CFG)" == "ftp - Win32 Debug"
-
-DEP_CPP_CMDS_=\
-       "..\..\..\emacs-19.34\nt\inc\netdb.h"\
-       "..\..\..\emacs-19.34\nt\inc\netinet\in.h"\
-       "..\..\..\emacs-19.34\nt\inc\sys\socket.h"\
-       "..\..\..\emacs-19.34\src\nt.h"\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\pathnames.h"\
-       ".\prototypes.h"\
-       {$(INCLUDE)}"sys\stat.h"\
-       {$(INCLUDE)}"sys\types.h"\
-
-
-"$(INTDIR)\cmds.obj" : $(SOURCE) $(DEP_CPP_CMDS_) "$(INTDIR)"
-
-
-!ENDIF
-
-SOURCE=.\cmdtab.c
-DEP_CPP_CMDTA=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-
-
-"$(INTDIR)\cmdtab.obj" : $(SOURCE) $(DEP_CPP_CMDTA) "$(INTDIR)"
-
-
-SOURCE=.\domacro.c
-DEP_CPP_DOMAC=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\domacro.obj" : $(SOURCE) $(DEP_CPP_DOMAC) "$(INTDIR)"
-
-
-SOURCE=.\fake.c
-DEP_CPP_FAKE_=\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\fake.obj" : $(SOURCE) $(DEP_CPP_FAKE_) "$(INTDIR)"
-
-
-SOURCE=.\ftp.c
-
-!IF  "$(CFG)" == "ftp - Win32 Release"
-
-DEP_CPP_FTP_C=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\ftp.obj" : $(SOURCE) $(DEP_CPP_FTP_C) "$(INTDIR)"
-
-
-!ELSEIF  "$(CFG)" == "ftp - Win32 Debug"
-
-DEP_CPP_FTP_C=\
-       "..\..\..\emacs-19.34\nt\inc\netdb.h"\
-       "..\..\..\emacs-19.34\nt\inc\netinet\in.h"\
-       "..\..\..\emacs-19.34\nt\inc\pwd.h"\
-       "..\..\..\emacs-19.34\nt\inc\sys\file.h"\
-       "..\..\..\emacs-19.34\nt\inc\sys\ioctl.h"\
-       "..\..\..\emacs-19.34\nt\inc\sys\param.h"\
-       "..\..\..\emacs-19.34\nt\inc\sys\socket.h"\
-       "..\..\..\emacs-19.34\nt\inc\sys\time.h"\
-       "..\..\..\emacs-19.34\src\nt.h"\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-       {$(INCLUDE)}"sys\stat.h"\
-       {$(INCLUDE)}"sys\types.h"\
-
-
-"$(INTDIR)\ftp.obj" : $(SOURCE) $(DEP_CPP_FTP_C) "$(INTDIR)"
-
-
-!ENDIF
-
-SOURCE=.\main.c
-
-!IF  "$(CFG)" == "ftp - Win32 Release"
-
-DEP_CPP_MAIN_=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\main.obj" : $(SOURCE) $(DEP_CPP_MAIN_) "$(INTDIR)"
-
-
-!ELSEIF  "$(CFG)" == "ftp - Win32 Debug"
-
-DEP_CPP_MAIN_=\
-       "..\..\..\emacs-19.34\nt\inc\netdb.h"\
-       "..\..\..\emacs-19.34\nt\inc\pwd.h"\
-       "..\..\..\emacs-19.34\nt\inc\sys\ioctl.h"\
-       "..\..\..\emacs-19.34\nt\inc\sys\socket.h"\
-       "..\..\..\emacs-19.34\src\nt.h"\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-       {$(INCLUDE)}"sys\types.h"\
-
-
-"$(INTDIR)\main.obj" : $(SOURCE) $(DEP_CPP_MAIN_) "$(INTDIR)"
-
-
-!ENDIF
-
-SOURCE=.\ruserpass.c
-
-!IF  "$(CFG)" == "ftp - Win32 Release"
-
-DEP_CPP_RUSER=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-
-
-"$(INTDIR)\ruserpass.obj" : $(SOURCE) $(DEP_CPP_RUSER) "$(INTDIR)"
-
-
-!ELSEIF  "$(CFG)" == "ftp - Win32 Debug"
-
-DEP_CPP_RUSER=\
-       ".\fake.h"\
-       ".\ftp_var.h"\
-       ".\prototypes.h"\
-       {$(INCLUDE)}"sys\stat.h"\
-       {$(INCLUDE)}"sys\types.h"\
-
-
-"$(INTDIR)\ruserpass.obj" : $(SOURCE) $(DEP_CPP_RUSER) "$(INTDIR)"
-
-
-!ENDIF
-
-
-!ENDIF
diff --git a/reactos/apps/utils/net/ftp/ftp.rc b/reactos/apps/utils/net/ftp/ftp.rc
deleted file mode 100644 (file)
index 505a9fe..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-/* $Id: route.rc 11816 2004-11-26 06:51:47Z arty $ */
-
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS TCP/IPv4 FTP Client\0"
-#define REACTOS_STR_INTERNAL_NAME      "ftp\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "ftp.exe\0"
-#include <reactos/version.rc>
diff --git a/reactos/apps/utils/net/ftp/ftp.xml b/reactos/apps/utils/net/ftp/ftp.xml
deleted file mode 100644 (file)
index 100afb6..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-<module name="ftp" type="win32cui" installbase="system32" installname="ftp.exe" allowwarnings="true">
-       <include base="ftp">.</include>
-       <define name="__USE_W32API" />
-       <define name="lint" />
-       <library>kernel32</library>
-       <library>ws2_32</library>
-       <library>iphlpapi</library>
-       <file>cmds.c</file>
-       <file>cmdtab.c</file>
-       <file>domacro.c</file>
-       <file>fake.c</file>
-       <file>ftp.c</file>
-       <file>main.c</file>
-       <file>ruserpass.c</file>
-       <file>ftp.rc</file>
-</module>
diff --git a/reactos/apps/utils/net/ftp/ftp_var.h b/reactos/apps/utils/net/ftp/ftp_var.h
deleted file mode 100644 (file)
index c18d154..0000000
+++ /dev/null
@@ -1,168 +0,0 @@
-#include <winsock.h>
-#include "fake.h"
-#include "prototypes.h"
-#include <setjmp.h>
-
-//typedef void (*Sig_t)(int);
-
-/* The following defines are from ftp.h and telnet.h from bsd.h */
-/* All relevent copyrights below apply.                         */
-
-#define        IAC     255
-#define        DONT    254
-#define        DO      253
-#define        WONT    252
-#define        WILL    251
-#define        SB      250
-#define        GA      249
-#define        EL      248
-#define        EC      247
-#define        AYT     246
-#define        AO      245
-#define        IP      244
-#define        BREAK   243
-#define        DM      242
-#define        NOP     241
-#define        SE      240
-#define EOR     239
-#define        ABORT   238
-#define        SUSP    237
-#define        xEOF    236
-
-
-#define MAXPATHLEN 255
-#define TYPE_A 'A'
-#define TYPE_I 'I'
-#define TYPE_E 'E'
-#define TYPE_L 'L'
-
-#define PRELIM         1
-#define COMPLETE       2
-#define CONTINUE       3
-#define TRANSIENT      4
-
-#define        MODE_S          1
-#define        MODE_B          2
-#define        MODE_C          3
-
-#define        STRU_F          1
-#define        STRU_R          2
-#define        STRU_P          3
-
-#define SIGQUIT 1
-#define SIGPIPE 2
-#define SIGALRM 3
-
-
-#define        FORM_N          1
-#define        FORM_T          2
-#define        FORM_C          3
-
-
-/*
- * Copyright (c) 1985 Regents of the University of California.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms are permitted
- * provided that the above copyright notice and this paragraph are
- * duplicated in all such forms and that any documentation,
- * advertising materials, and other materials related to such
- * distribution and use acknowledge that the software was developed
- * by the University of California, Berkeley.  The name of the
- * University may not be used to endorse or promote products derived
- * from this software without specific prior written permission.
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
- * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
- *
- *     @(#)ftp_var.h   5.5 (Berkeley) 6/29/88
- */
-
-/*
- * FTP global variables.
- */
-
-/*
- * Options and other state info.
- */
-extern int     trace;                  /* trace packets exchanged */
-extern int     hash;                   /* print # for each buffer transferred */
-extern int     sendport;               /* use PORT cmd for each data connection */
-extern int     verbose;                /* print messages coming back from server */
-extern int     connected;              /* connected to server */
-extern int     fromatty;               /* input is from a terminal */
-extern int     interactive;            /* interactively prompt on m* cmds */
-extern int     debug;                  /* debugging level */
-extern int     bell;                   /* ring bell on cmd completion */
-extern int     doglob;                 /* glob local file names */
-extern int     proxy;                  /* proxy server connection active */
-extern int     proxflag;               /* proxy connection exists */
-extern int     sunique;                /* store files on server with unique name */
-extern int     runique;                /* store local files with unique name */
-extern int     mcase;                  /* map upper to lower case for mget names */
-extern int     ntflag;                 /* use ntin ntout tables for name translation */
-extern int     mapflag;                /* use mapin mapout templates on file names */
-extern int     code;                   /* return/reply code for ftp command */
-extern int     crflag;                 /* if 1, strip car. rets. on ascii gets */
-extern char    pasv[64];               /* passive port for proxy data connection */
-extern int  passivemode;    /* passive mode enabled */
-extern char    *altarg;                /* argv[1] with no shell-like preprocessing  */
-extern char    ntin[17];               /* input translation table */
-extern char    ntout[17];              /* output translation table */
-
-extern char    mapin[MAXPATHLEN];      /* input map template */
-extern char    mapout[MAXPATHLEN];     /* output map template */
-extern char    typename[32];           /* name of file transfer type */
-extern int     type;                   /* file transfer type */
-extern char    structname[32];         /* name of file transfer structure */
-extern int     stru;                   /* file transfer structure */
-extern char    formname[32];           /* name of file transfer format */
-extern int     form;                   /* file transfer format */
-extern char    modename[32];           /* name of file transfer mode */
-extern int     mode;                   /* file transfer mode */
-extern char    bytename[32];           /* local byte size in ascii */
-extern int     bytesize;               /* local byte size in binary */
-
-extern jmp_buf toplevel;               /* non-local goto stuff for cmd scanner */
-
-extern char    line[200];              /* input line buffer */
-extern char    *stringbase;            /* current scan point in line buffer */
-extern char    argbuf[200];            /* argument storage buffer */
-extern char    *argbase;               /* current storage point in arg buffer */
-extern int     margc;                  /* count of arguments on input line */
-extern const char      *margv[20];             /* args parsed from input line */
-extern int     cpend;                  /* flag: if != 0, then pending server reply */
-extern int     mflag;                  /* flag: if != 0, then active multi command */
-
-extern int     options;                /* used during socket creation */
-
-/*
- * Format of command table.
- */
-struct cmd {
-       const char      *c_name;        /* name of command */
-       const char      *c_help;        /* help string */
-       char    c_bell;         /* give bell when command completes */
-       char    c_conn;         /* must be connected to use command */
-       char    c_proxy;        /* proxy server may execute */
-       void    (*c_handler)(); /* function to call */
-};
-
-struct macel {
-       char mac_name[9];       /* macro name */
-       char *mac_start;        /* start of macro in macbuf */
-       char *mac_end;          /* end of macro in macbuf */
-};
-
-int macnum;                    /* number of defined macros */
-struct macel macros[16];
-char macbuf[4096];
-
-#if    defined(__ANSI__) || defined(sparc)
-typedef void sig_t;
-#else
-typedef int sig_t;
-#endif
-
-typedef int uid_t;
-
diff --git a/reactos/apps/utils/net/ftp/main.c b/reactos/apps/utils/net/ftp/main.c
deleted file mode 100644 (file)
index d83a041..0000000
+++ /dev/null
@@ -1,598 +0,0 @@
-/*
- * Copyright (c) 1985, 1989 Regents of the University of California.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms are permitted
- * provided that the above copyright notice and this paragraph are
- * duplicated in all such forms and that any documentation,
- * advertising materials, and other materials related to such
- * distribution and use acknowledge that the software was developed
- * by the University of California, Berkeley.  The name of the
- * University may not be used to endorse or promote products derived
- * from this software without specific prior written permission.
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
- */
-
-#ifndef lint
-char copyright[] =
-"@(#) Copyright (c) 1985, 1989 Regents of the University of California.\n\
- All rights reserved.\n";
-#endif /* not lint */
-
-#ifndef lint
-static char sccsid[] = "@(#)main.c     based on 5.13 (Berkeley) 3/14/89";
-#endif /* not lint */
-
-/*
- * FTP User Program -- Command Interface.
- */
-#ifndef _WIN32
-#include <netdb.h>
-#include <sys/socket.h>
-#include <sys/ioctl.h>
-#include <arpa/ftp.h>
-#include <errno.h>
-#include <pwd.h>
-#endif
-#include "ftp_var.h"
-#include "prototypes.h"
-#include <sys/types.h>
-
-#include <io.h>
-#include <fcntl.h>
-
-#include <signal.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <ctype.h>
-
-
-#if defined(sun) && !defined(FD_SET)
-typedef int uid_t;
-#endif
-
-uid_t  getuid();
-void   intr();
-void   lostpeer();
-char   *getlogin();
-
-short   portnum;
-
-char     home[128];
-char   *globerr;
-int     autologin;
-
-
-
-/* Lot's of options... */
-/*
- * Options and other state info.
- */
-int    trace;                  /* trace packets exchanged */
-int    hash;                   /* print # for each buffer transferred */
-int    sendport;               /* use PORT cmd for each data connection */
-int    verbose;                /* print messages coming back from server */
-int    connected;              /* connected to server */
-int    fromatty;               /* input is from a terminal */
-int    interactive;            /* interactively prompt on m* cmds */
-int    debug;                  /* debugging level */
-int    bell;                   /* ring bell on cmd completion */
-int    doglob;                 /* glob local file names */
-int    proxy;                  /* proxy server connection active */
-int passivemode;
-int    proxflag;               /* proxy connection exists */
-int    sunique;                /* store files on server with unique name */
-int    runique;                /* store local files with unique name */
-int    mcase;                  /* map upper to lower case for mget names */
-int    ntflag;                 /* use ntin ntout tables for name translation */
-int    mapflag;                /* use mapin mapout templates on file names */
-int    code;                   /* return/reply code for ftp command */
-int    crflag;                 /* if 1, strip car. rets. on ascii gets */
-char   pasv[64];               /* passive port for proxy data connection */
-char   *altarg;                /* argv[1] with no shell-like preprocessing  */
-char   ntin[17];               /* input translation table */
-char   ntout[17];              /* output translation table */
-// #include <sys/param.h>
-char   mapin[MAXPATHLEN];      /* input map template */
-char   mapout[MAXPATHLEN];     /* output map template */
-char   typename[32];           /* name of file transfer type */
-int    type;                   /* file transfer type */
-char   structname[32];         /* name of file transfer structure */
-int    stru;                   /* file transfer structure */
-char   formname[32];           /* name of file transfer format */
-int    form;                   /* file transfer format */
-char   modename[32];           /* name of file transfer mode */
-int    mode;                   /* file transfer mode */
-char   bytename[32];           /* local byte size in ascii */
-int    bytesize;               /* local byte size in binary */
-
-jmp_buf        toplevel;               /* non-local goto stuff for cmd scanner */
-
-char   line[200];              /* input line buffer */
-char   *stringbase;            /* current scan point in line buffer */
-char   argbuf[200];            /* argument storage buffer */
-char   *argbase;               /* current storage point in arg buffer */
-int    margc;                  /* count of arguments on input line */
-const char     *margv[20];             /* args parsed from input line */
-int     cpend;                  /* flag: if != 0, then pending server reply */
-int    mflag;                  /* flag: if != 0, then active multi command */
-
-int    options;                /* used during socket creation */
-
-static const char *slurpstring();
-
-
-int main(int argc, const char *argv[])
-{
-       const char *cp;
-       int top;
-#if 0
-       char homedir[MAXPATHLEN];
-#endif
-
-        int err;
-        WORD wVerReq;
-
-        WSADATA WSAData;
-        struct servent *sp;            /* service spec for tcp/ftp */
-
-       /* Disable output buffering, for the benefit of Emacs.  */
-       //setbuf(stdout, NULL);
-
-        _fmode = O_BINARY; // This causes an error somewhere.
-
-        wVerReq = MAKEWORD(1,1);
-
-        err = WSAStartup(wVerReq, &WSAData);
-        if (err != 0)
-        {
-           fprintf(stderr, "Could not initialize Windows socket interface.");
-           exit(1);
-        }
-
-       sp = getservbyname("ftp", "tcp");
-       if (sp == 0) {
-               fprintf(stderr, "ftp: ftp/tcp: unknown service\n");
-               exit(1);
-       }
-
-        portnum = sp->s_port;
-
-
-       doglob = 1;
-       interactive = 1;
-       autologin = 1;
-       argc--, argv++;
-       while (argc > 0 && **argv == '-') {
-               for (cp = *argv + 1; *cp; cp++)
-                       switch (*cp) {
-
-                       case 'd':
-                               options |= SO_DEBUG;
-                               debug++;
-                               break;
-
-                       case 'v':
-                               verbose++;
-                               break;
-
-                       case 't':
-                               trace++;
-                               break;
-
-                       case 'i':
-                               interactive = 0;
-                               break;
-
-                       case 'n':
-                               autologin = 0;
-                               break;
-
-                       case 'g':
-                               doglob = 0;
-                               break;
-
-                       default:
-                               fprintf(stdout,
-                                 "ftp: %c: unknown option\n", *cp);
-                               exit(1);
-                       }
-               argc--, argv++;
-       }
-//     fromatty = isatty(fileno(stdin));
-        fromatty = 1; // Strengthen this test
-       /*
-        * Set up defaults for FTP.
-        */
-       (void) strcpy(typename, "ascii"), type = TYPE_A;
-       (void) strcpy(formname, "non-print"), form = FORM_N;
-       (void) strcpy(modename, "stream"), mode = MODE_S;
-       (void) strcpy(structname, "file"), stru = STRU_F;
-       (void) strcpy(bytename, "8"), bytesize = 8;
-       if (fromatty)
-               verbose++;
-       cpend = 0;           /* no pending replies */
-       proxy = 0;      /* proxy not active */
-    passivemode = 1; /* passive mode *is* active */
-       crflag = 1;    /* strip c.r. on ascii gets */
-       /*
-        * Set up the home directory in case we're globbing.
-        */
-#if 0
-       cp = getlogin();
-       if (cp != NULL) {
-               pw = getpwnam(cp);
-       }
-       if (pw == NULL)
-               pw = getpwuid(getuid());
-       if (pw != NULL) {
-               home = homedir;
-               (void) strcpy(home, pw->pw_dir);
-       }
-#endif
-        strcpy(home, "C:/");
-       if (argc > 0) {
-               if (setjmp(toplevel))
-                       exit(0);
-//             (void) signal(SIGINT, intr);
-//             (void) signal(SIGPIPE, lostpeer);
-               setpeer(argc + 1, argv - 1);
-       }
-       top = setjmp(toplevel) == 0;
-       if (top) {
-//             (void) signal(SIGINT, intr);
-//             (void) signal(SIGPIPE, lostpeer);
-       }
-       for (;;) {
-               cmdscanner(top);
-               top = 1;
-       }
-}
-
-void
-intr()
-{
-
-       longjmp(toplevel, 1);
-}
-
-void lostpeer(void)
-{
-   extern int cout;
-   extern int data;
-
-   if (connected) {
-      if (cout != (int) NULL) {
-         closesocket(cout);
-         cout = (int) NULL;
-      }
-      if (data >= 0) {
-         (void) shutdown(data, 1+1);
-         (void) close(data);
-         data = -1;
-      }
-      connected = 0;
-   }
-   pswitch(1);
-   if (connected) {
-      if (cout != (int)NULL) {
-                                               closesocket(cout);
-         cout = (int) NULL;
-      }
-      connected = 0;
-   }
-   proxflag = 0;
-   pswitch(0);
-}
-
-/*char *
-tail(filename)
-       char *filename;
-{
-       register char *s;
-
-       while (*filename) {
-               s = rindex(filename, '/');
-               if (s == NULL)
-                       break;
-               if (s[1])
-                       return (s + 1);
-               *s = '\0';
-       }
-       return (filename);
-}
-*/
-/*
- * Command parser.
- */
-void cmdscanner(top)
-       int top;
-{
-       register struct cmd *c;
-
-       if (!top)
-               (void) putchar('\n');
-       for (;;) {
-               (void) fflush(stdout);
-               if (fromatty) {
-                       printf("ftp> ");
-                       (void) fflush(stdout);
-               }
-               if (gets(line) == 0) {
-                       if (feof(stdin) || ferror(stdin))
-                               quit();
-                       break;
-               }
-               if (line[0] == 0)
-                       break;
-               makeargv();
-               if (margc == 0) {
-                       continue;
-               }
-               c = getcmd(margv[0]);
-               if (c == (struct cmd *)-1) {
-                       printf("?Ambiguous command\n");
-                       continue;
-               }
-               if (c == 0) {
-                       printf("?Invalid command\n");
-                       continue;
-               }
-               if (c->c_conn && !connected) {
-                       printf ("Not connected.\n");
-                       continue;
-               }
-               (*c->c_handler)(margc, margv);
-               if (bell && c->c_bell)
-                       (void) putchar('\007');
-               if (c->c_handler != help)
-                       break;
-       }
-       (void) fflush(stdout);
-//     (void) signal(SIGINT, intr);
-//     (void) signal(SIGPIPE, lostpeer);
-}
-
-struct cmd *
-getcmd(name)
-       const char *name;
-{
-       extern struct cmd cmdtab[];
-       const char *p, *q;
-       struct cmd *c, *found;
-       int nmatches, longest;
-
-       longest = 0;
-       nmatches = 0;
-       found = 0;
-       for (c = cmdtab; (p = c->c_name); c++) {
-               for (q = name; *q == *p++; q++)
-                       if (*q == 0)            /* exact match? */
-                               return (c);
-               if (!*q) {                      /* the name was a prefix */
-                       if (q - name > longest) {
-                               longest = q - name;
-                               nmatches = 1;
-                               found = c;
-                       } else if (q - name == longest)
-                               nmatches++;
-               }
-       }
-       if (nmatches > 1)
-               return ((struct cmd *)-1);
-       return (found);
-}
-
-/*
- * Slice a string up into argc/argv.
- */
-
-int slrflag;
-
-void makeargv()
-{
-       const char **argp;
-
-       margc = 0;
-       argp = margv;
-       stringbase = line;              /* scan from first of buffer */
-       argbase = argbuf;               /* store from first of buffer */
-       slrflag = 0;
-       while ((*argp++ = slurpstring()))
-               margc++;
-}
-
-/*
- * Parse string into argbuf;
- * implemented with FSM to
- * handle quoting and strings
- */
-static const char *
-slurpstring()
-{
-       int got_one = 0;
-       register char *sb = stringbase;
-       register char *ap = argbase;
-       char *tmp = argbase;            /* will return this if token found */
-
-       if (*sb == '!' || *sb == '$') { /* recognize ! as a token for shell */
-               switch (slrflag) {      /* and $ as token for macro invoke */
-                       case 0:
-                               slrflag++;
-                               stringbase++;
-                               return ((*sb == '!') ? "!" : "$");
-                               /* NOTREACHED */
-                       case 1:
-                               slrflag++;
-                               altarg = stringbase;
-                               break;
-                       default:
-                               break;
-               }
-       }
-
-S0:
-       switch (*sb) {
-
-       case '\0':
-               goto OUT1;
-
-       case ' ':
-       case '\t':
-               sb++; goto S0;
-
-       default:
-               switch (slrflag) {
-                       case 0:
-                               slrflag++;
-                               break;
-                       case 1:
-                               slrflag++;
-                               altarg = sb;
-                               break;
-                       default:
-                               break;
-               }
-               goto S1;
-       }
-
-S1:
-       switch (*sb) {
-
-       case ' ':
-       case '\t':
-       case '\0':
-               goto OUT1;      /* end of token */
-
-       case '\\':
-               sb++; goto S2;  /* slurp next character */
-
-       case '"':
-               sb++; goto S3;  /* slurp quoted string */
-
-       default:
-               *ap++ = *sb++;  /* add character to token */
-               got_one = 1;
-               goto S1;
-       }
-
-S2:
-       switch (*sb) {
-
-       case '\0':
-               goto OUT1;
-
-       default:
-               *ap++ = *sb++;
-               got_one = 1;
-               goto S1;
-       }
-
-S3:
-       switch (*sb) {
-
-       case '\0':
-               goto OUT1;
-
-       case '"':
-               sb++; goto S1;
-
-       default:
-               *ap++ = *sb++;
-               got_one = 1;
-               goto S3;
-       }
-
-OUT1:
-       if (got_one)
-               *ap++ = '\0';
-       argbase = ap;                   /* update storage pointer */
-       stringbase = sb;                /* update scan pointer */
-       if (got_one) {
-               return(tmp);
-       }
-       switch (slrflag) {
-               case 0:
-                       slrflag++;
-                       break;
-               case 1:
-                       slrflag++;
-                       altarg = (char *) 0;
-                       break;
-               default:
-                       break;
-       }
-       return((char *)0);
-}
-
-#define HELPINDENT (sizeof ("directory"))
-
-/*
- * Help command.
- * Call each command handler with argc == 0 and argv[0] == name.
- */
-void help(argc, argv)
-       int argc;
-       char *argv[];
-{
-       extern struct cmd cmdtab[];
-       register struct cmd *c;
-
-       if (argc == 1) {
-               register int i, j, w, k;
-               int columns, width = 0, lines;
-               extern int NCMDS;
-
-               printf("Commands may be abbreviated.  Commands are:\n\n");
-               for (c = cmdtab; c < &cmdtab[NCMDS]; c++) {
-                       int len = strlen(c->c_name);
-
-                       if (len > width)
-                               width = len;
-               }
-               width = (width + 8) &~ 7;
-               columns = 80 / width;
-               if (columns == 0)
-                       columns = 1;
-               lines = (NCMDS + columns - 1) / columns;
-               for (i = 0; i < lines; i++) {
-                       for (j = 0; j < columns; j++) {
-                               c = cmdtab + j * lines + i;
-                               if (c->c_name && (!proxy || c->c_proxy)) {
-                                       printf("%s", c->c_name);
-                               }
-                               else if (c->c_name) {
-                                       for (k=0; k < (int) strlen(c->c_name); k++) {
-                                               (void) putchar(' ');
-                                       }
-                               }
-                               if (c + lines >= &cmdtab[NCMDS]) {
-                                       printf("\n");
-                                       break;
-                               }
-                               w = strlen(c->c_name);
-                               while (w < width) {
-                                       w = (w + 8) &~ 7;
-                                       (void) putchar('\t');
-                               }
-                       }
-               }
-               (void) fflush(stdout);
-               return;
-       }
-       while (--argc > 0) {
-               register char *arg;
-               arg = *++argv;
-               c = getcmd(arg);
-               if (c == (struct cmd *)-1)
-                       printf("?Ambiguous help command %s\n", arg);
-               else if (c == (struct cmd *)0)
-                       printf("?Invalid help command %s\n", arg);
-               else
-                       printf("%-*s\t%s\n", HELPINDENT,
-                               c->c_name, c->c_help);
-       }
-       (void) fflush(stdout);
-}
diff --git a/reactos/apps/utils/net/ftp/pathnames.h b/reactos/apps/utils/net/ftp/pathnames.h
deleted file mode 100644 (file)
index 676aa50..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
- * Copyright (c) 1989 The Regents of the University of California.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms are permitted
- * provided that the above copyright notice and this paragraph are
- * duplicated in all such forms and that any documentation,
- * advertising materials, and other materials related to such
- * distribution and use acknowledge that the software was developed
- * by the University of California, Berkeley.  The name of the
- * University may not be used to endorse or promote products derived
- * from this software without specific prior written permission.
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
- *
- *     %W% (Berkeley) %G%
- */
-
-#define        _PATH_TMP       "/tmp/ftpXXXXXX"
-#define        _PATH_BSHELL    "/bin/sh"
diff --git a/reactos/apps/utils/net/ftp/prototypes.h b/reactos/apps/utils/net/ftp/prototypes.h
deleted file mode 100644 (file)
index 7ad8a4c..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-
-int fgetcSocket(int s);
-const char *fputsSocket(const char *format, int s);
-
-const char *fprintfSocket(int s, const char *format, ...);
-
-int fputcSocket(int s, char putChar);
-int fputSocket(int s, char *putChar, int len);
-char *fgetsSocket(int s, char *string);
-
-char *hookup();
-char **glob();
-int herror(char *s);
-
-int getreply(int expecteof);
-int ruserpass(const char *host, char **aname, char **apass, char **aacct);
-char *getpass(const char *prompt);
-void makeargv(void);
-void domacro(int argc, const char *argv[]);
-void proxtrans(const char *cmd, const char *local, const char *remote);
-int null(void);
-int initconn(void);
-void disconnect(void);
-void ptransfer(const char *direction, long bytes, struct timeval *t0, struct timeval *t1);
-void setascii(void);
-void setbinary(void);
-void setebcdic(void);
-void settenex(void);
-void tvsub(struct timeval *tdiff, struct timeval *t1, struct timeval *t0);
-void setpassive(int argc, char *argv[]);
-void setpeer(int argc, const char *argv[]);
-void cmdscanner(int top);
-void pswitch(int flag);
-void quit(void);
-int login(const char *host);
-int command(const char *fmt, ...);
-int globulize(const char **cpp);
-void sendrequest(const char *cmd, const char *local, const char *remote, int printnames);
-void recvrequest(const char *cmd, const char *local, const char *remote, const char *mode,
-                int printnames);
-int confirm(const char *cmd, const char *file);
-void blkfree(char **av0);
-int getit(int argc, const char *argv[], int restartit, const char *mode);
-int sleep(int time);
-
-char *tail();
-int errno;
-char *mktemp();
-void   setbell(), setdebug();
-void   setglob(), sethash(), setport();
-void   setprompt();
-void   settrace(), setverbose();
-void   settype(), setform(), setstruct();
-void   restart(), syst();
-void   cd(), lcd(), delete(), mdelete();
-void   ls(), mls(), get(), mget(), help(), append(), put(), mput(), reget();
-void   status();
-void   renamefile();
-void   quote(), rmthelp(), site();
-void   pwd(), makedir(), removedir(), setcr();
-void   account(), doproxy(), reset(), setcase(), setntrans(), setnmap();
-void   setsunique(), setrunique(), cdup(), macdef();
-void   sizecmd(), modtime(), newer(), rmtstatus();
-void   do_chmod(), do_umask(), idle();
-void   shell(), user(), fsetmode();
-struct cmd     *getcmd();
diff --git a/reactos/apps/utils/net/ftp/ruserpass.c b/reactos/apps/utils/net/ftp/ruserpass.c
deleted file mode 100644 (file)
index 688859e..0000000
+++ /dev/null
@@ -1,274 +0,0 @@
-/*
- * Copyright (c) 1985 Regents of the University of California.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms are permitted
- * provided that the above copyright notice and this paragraph are
- * duplicated in all such forms and that any documentation,
- * advertising materials, and other materials related to such
- * distribution and use acknowledge that the software was developed
- * by the University of California, Berkeley.  The name of the
- * University may not be used to endorse or promote products derived
- * from this software without specific prior written permission.
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
- */
-
-#ifndef lint
-static char sccsid[] = "@(#)ruserpass.c        5.1 (Berkeley) 3/1/89";
-#endif /* not lint */
-
-#include <sys/types.h>
-#include <stdio.h>
-//#include <utmp.h>
-#include <ctype.h>
-#include <sys/stat.h>
-#include <errno.h>
-#include "ftp_var.h"
-#include "prototypes.h"
-#include <winsock.h>
-
-char   *renvlook(), *index(), *getenv(), *getpass(), *getlogin();
-void  *malloc();
-char   *strcpy();
-struct utmp *getutmp();
-static FILE *cfile;
-
-#ifndef MAXHOSTNAMELEN
-#define MAXHOSTNAMELEN 64
-#endif
-
-#define        DEFAULT 1
-#define        LOGIN   2
-#define        PASSWD  3
-#define        ACCOUNT 4
-#define MACDEF  5
-#define        ID      10
-#define        MACH    11
-
-static char tokval[100];
-
-static struct toktab {
-       const char *tokstr;
-       int tval;
-} toktab[]= {
-       {"default",     DEFAULT},
-       {"login",       LOGIN},
-       {"password",    PASSWD},
-       {"passwd",      PASSWD},
-       {"account",     ACCOUNT},
-       {"machine",     MACH},
-       {"macdef",      MACDEF},
-       {0,             0}
-};
-
-extern char *hostname;
-static int token(void);
-
-int ruserpass(const char *host, char **aname, char **apass, char **aacct)
-{
-       const char *hdir, *mydomain;
-    char buf[BUFSIZ], *tmp;
-       char myname[MAXHOSTNAMELEN];
-       int t, i, c, usedefault = 0;
-       struct stat stb;
-       extern int errno;
-
-       hdir = getenv("HOME");
-       if (hdir == NULL)
-               hdir = ".";
-       (void) sprintf(buf, "%s/.netrc", hdir);
-       cfile = fopen(buf, "r");
-       if (cfile == NULL) {
-               if (errno != ENOENT)
-                       perror(buf);
-               return(0);
-       }
-
-
-                 if (gethostname(myname, sizeof(myname)) < 0)
-               myname[0] = '\0';
-       if ((mydomain = index(myname, '.')) == NULL)
-               mydomain = "";
-next:
-       while ((t = token())) switch(t) {
-
-       case DEFAULT:
-               usedefault = 1;
-               /* FALL THROUGH */
-
-       case MACH:
-               if (!usedefault) {
-                       if (token() != ID)
-                               continue;
-                       /*
-                        * Allow match either for user's input host name
-                        * or official hostname.  Also allow match of
-                        * incompletely-specified host in local domain.
-                        */
-                       if (strcasecmp(host, tokval) == 0)
-                               goto match;
-                       if (strcasecmp(hostname, tokval) == 0)
-                               goto match;
-                       if ((tmp = index(hostname, '.')) != NULL &&
-                                strcasecmp(tmp, mydomain) == 0 &&
-                                strncasecmp(hostname, tokval, tmp - hostname) == 0 &&
-                                tokval[tmp - hostname] == '\0')
-                               goto match;
-                       if ((tmp = index(host, '.')) != NULL &&
-                                strcasecmp(tmp, mydomain) == 0 &&
-                                strncasecmp(host, tokval, tmp - host) == 0 &&
-                                tokval[tmp - host] == '\0')
-                               goto match;
-                       continue;
-               }
-       match:
-               while ((t = token()) && t != MACH && t != DEFAULT) switch(t) {
-
-               case LOGIN:
-                       if (token()) {
-                               if (*aname == 0) {
-                                       *aname = malloc((unsigned) strlen(tokval) + 1);
-                                       (void) strcpy(*aname, tokval);
-                               } else {
-                                       if (strcmp(*aname, tokval))
-                                               goto next;
-                               }
-                       }
-                       break;
-               case PASSWD:
-                       if (strcmp(*aname, "anonymous") &&
-                           fstat(fileno(cfile), &stb) >= 0 &&
-                           (stb.st_mode & 077) != 0) {
-       fprintf(stderr, "Error - .netrc file not correct mode.\n");
-       fprintf(stderr, "Remove password or correct mode.\n");
-                               goto bad;
-                       }
-                       if (token() && *apass == 0) {
-                               *apass = malloc((unsigned) strlen(tokval) + 1);
-                               (void) strcpy(*apass, tokval);
-                       }
-                       break;
-               case ACCOUNT:
-                       if (fstat(fileno(cfile), &stb) >= 0
-                           && (stb.st_mode & 077) != 0) {
-       fprintf(stderr, "Error - .netrc file not correct mode.\n");
-       fprintf(stderr, "Remove account or correct mode.\n");
-                               goto bad;
-                       }
-                       if (token() && *aacct == 0) {
-                               *aacct = malloc((unsigned) strlen(tokval) + 1);
-                               (void) strcpy(*aacct, tokval);
-                       }
-                       break;
-               case MACDEF:
-                       if (proxy) {
-                               (void) fclose(cfile);
-                               return(0);
-                       }
-                       while ((c=getc(cfile)) != EOF && (c == ' ' || c == '\t'));
-                       if (c == EOF || c == '\n') {
-                               printf("Missing macdef name argument.\n");
-                               goto bad;
-                       }
-                       if (macnum == 16) {
-                               printf("Limit of 16 macros have already been defined\n");
-                               goto bad;
-                       }
-                       tmp = macros[macnum].mac_name;
-                       *tmp++ = c;
-                       for (i=0; i < 8 && (c=getc(cfile)) != EOF &&
-                           !isspace(c); ++i) {
-                               *tmp++ = c;
-                       }
-                       if (c == EOF) {
-                               printf("Macro definition missing null line terminator.\n");
-                               goto bad;
-                       }
-                       *tmp = '\0';
-                       if (c != '\n') {
-                               while ((c=getc(cfile)) != EOF && c != '\n');
-                       }
-                       if (c == EOF) {
-                               printf("Macro definition missing null line terminator.\n");
-                               goto bad;
-                       }
-                       if (macnum == 0) {
-                               macros[macnum].mac_start = macbuf;
-                       }
-                       else {
-                               macros[macnum].mac_start = macros[macnum-1].mac_end + 1;
-                       }
-                       tmp = macros[macnum].mac_start;
-                       while (tmp != macbuf + 4096) {
-                               if ((c=getc(cfile)) == EOF) {
-                               printf("Macro definition missing null line terminator.\n");
-                                       goto bad;
-                               }
-                               *tmp = c;
-                               if (*tmp == '\n') {
-                                       if (*(tmp-1) == '\0') {
-                                          macros[macnum++].mac_end = tmp - 1;
-                                          break;
-                                       }
-                                       *tmp = '\0';
-                               }
-                               tmp++;
-                       }
-                       if (tmp == macbuf + 4096) {
-                               printf("4K macro buffer exceeded\n");
-                               goto bad;
-                       }
-                       break;
-               default:
-       fprintf(stderr, "Unknown .netrc keyword %s\n", tokval);
-                       break;
-               }
-               goto done;
-       }
-done:
-       (void) fclose(cfile);
-       return(0);
-bad:
-       (void) fclose(cfile);
-       return(-1);
-}
-
-static int token(void)
-{
-   char *cp;
-   int c;
-   struct toktab *t;
-
-   if (feof(cfile))
-      return (0);
-   while ((c = getc(cfile)) != EOF &&
-          (c == '\r' || c == '\n' || c == '\t' || c == ' ' || c == ','))
-      continue;
-   if (c == EOF)
-      return (0);
-   cp = tokval;
-   if (c == '"') {
-      while ((c = getc(cfile)) != EOF && c != '"') {
-         if (c == '\\')
-            c = getc(cfile);
-         *cp++ = c;
-      }
-   } else {
-      *cp++ = c;
-      while ((c = getc(cfile)) != EOF
-             && c != '\n' && c != '\t' && c != ' ' && c != ',' && c != '\r') {
-         if (c == '\\')
-            c = getc(cfile);
-         *cp++ = c;
-      }
-   }
-   *cp = 0;
-   if (tokval[0] == 0)
-      return (0);
-   for (t = toktab; t->tokstr; t++)
-      if (!strcmp(t->tokstr, tokval))
-         return (t->tval);
-   return (ID);
-}
diff --git a/reactos/apps/utils/net/ipconfig/ipconfig.c b/reactos/apps/utils/net/ipconfig/ipconfig.c
deleted file mode 100644 (file)
index 8c0c412..0000000
+++ /dev/null
@@ -1,517 +0,0 @@
-/*
- * ReactOS Win32 Applications
- * Copyright (C) 2005 ReactOS Team
- *
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS arp utility
- * FILE:        apps/utils/net/ipconfig/ipconfig.c
- * PURPOSE:
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *   GM 14/09/05 Created
- *
- */
-/*
- * TODO:
- * fix renew / release
- * implement flushdns, registerdns, displaydns, showclassid, setclassid
- * allow globbing on adapter names
- */
-#define WIN32_LEAN_AND_MEAN
-#include <windows.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <time.h>
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-#include <winsock2.h>
-#include <iphlpapi.h>
-
-#define UNICODE
-#define _UNICODE
-
-
-
-LPCTSTR GetNodeTypeName(UINT NodeType)
-{
-    switch (NodeType) {
-        case 1: return _T("Broadcast");
-        case 2: return _T("Peer To Peer");
-        case 4: return _T("Mixed");
-        case 8: return _T("Hybrid");
-        default : return _T("unknown");
-    }
-}
-
-LPCTSTR GetInterfaceTypeName(UINT InterfaceType)
-{
-    switch (InterfaceType) {
-        case MIB_IF_TYPE_OTHER:     return _T("Other Type Of Adapter");
-        case MIB_IF_TYPE_ETHERNET:  return _T("Ethernet Adapter");
-        case MIB_IF_TYPE_TOKENRING: return _T("Token Ring Adapter");
-        case MIB_IF_TYPE_FDDI:      return _T("FDDI Adapter");
-        case MIB_IF_TYPE_PPP:       return _T("PPP Adapter");
-        case MIB_IF_TYPE_LOOPBACK:  return _T("Loopback Adapter");
-        case MIB_IF_TYPE_SLIP:      return _T("SLIP Adapter");
-        default: return _T("unknown");
-    }
-}
-
-/* print MAC address */
-PTCHAR PrintMacAddr(PBYTE Mac)
-{
-    static TCHAR MacAddr[20];
-
-    _stprintf(MacAddr, _T("%02x-%02x-%02x-%02x-%02x-%02x"),
-        Mac[0], Mac[1], Mac[2], Mac[3], Mac[4],  Mac[5]);
-
-    return MacAddr;
-}
-
-DWORD DoFormatMessage(DWORD ErrorCode)
-{
-    LPVOID lpMsgBuf;
-    DWORD RetVal;
-
-    if ((RetVal = FormatMessage(
-            FORMAT_MESSAGE_ALLOCATE_BUFFER |
-            FORMAT_MESSAGE_FROM_SYSTEM |
-            FORMAT_MESSAGE_IGNORE_INSERTS,
-            NULL,
-            ErrorCode,
-            MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), /* Default language */
-            (LPTSTR) &lpMsgBuf,
-            0,
-            NULL ))) {
-        _tprintf(_T("%s"), (LPTSTR)lpMsgBuf);
-
-        LocalFree(lpMsgBuf);
-        /* return number of TCHAR's stored in output buffer
-         * excluding '\0' - as FormatMessage does*/
-        return RetVal;
-    }
-    else
-        return 0;
-}
-
-INT ShowInfo(BOOL bAll)
-{
-    PIP_ADAPTER_INFO pAdapterInfo = NULL;
-    PIP_ADAPTER_INFO pAdapter = NULL;
-    ULONG    adaptOutBufLen;
-
-    PFIXED_INFO pFixedInfo;
-    ULONG    netOutBufLen;
-    PIP_ADDR_STRING pIPAddr = NULL;
-
-       DWORD ErrRet = 0;
-
-    /* assign memory for call to GetNetworkParams */
-    pFixedInfo = (FIXED_INFO *) GlobalAlloc( GPTR, sizeof( FIXED_INFO ) );
-    netOutBufLen = sizeof(FIXED_INFO);
-
-    /* assign memory for call to GetAdapterInfo */
-    pAdapterInfo = (IP_ADAPTER_INFO *) malloc( sizeof(IP_ADAPTER_INFO) );
-    adaptOutBufLen = sizeof(IP_ADAPTER_INFO);
-
-    /* set required buffer size */
-    if(GetNetworkParams(pFixedInfo, &netOutBufLen) == ERROR_BUFFER_OVERFLOW) 
-       {
-        GlobalFree(pFixedInfo);
-        pFixedInfo = (FIXED_INFO *) GlobalAlloc(GPTR, netOutBufLen);
-    }
-
-    /* set required buffer size */
-    if (GetAdaptersInfo( pAdapterInfo, &adaptOutBufLen) == ERROR_BUFFER_OVERFLOW) 
-       {
-       free(pAdapterInfo);
-       pAdapterInfo = (IP_ADAPTER_INFO *) malloc (adaptOutBufLen);
-    }
-
-    if ((ErrRet = GetAdaptersInfo(pAdapterInfo, &adaptOutBufLen)) != NO_ERROR)
-       {
-               _tprintf(_T("GetAdaptersInfo failed : "));
-               DoFormatMessage(ErrRet);
-               return EXIT_FAILURE;
-       }
-
-    if ((ErrRet = GetNetworkParams(pFixedInfo, &netOutBufLen)) != NO_ERROR)
-       {
-               _tprintf(_T("GetNetworkParams failed : "));
-               DoFormatMessage(ErrRet);
-               return EXIT_FAILURE;
-       }
-    
-    pAdapter = pAdapterInfo;
-
-    _tprintf(_T("\nReactOS IP Configuration\n\n"));
-
-    if (bAll)
-    {
-        _tprintf(_T("\tHost Name . . . . . . . . . . . . : %s\n"), pFixedInfo->HostName);
-        _tprintf(_T("\tPrimary DNS Suffix. . . . . . . . : \n"));
-        _tprintf(_T("\tNode Type . . . . . . . . . . . . : %s\n"), GetNodeTypeName(pFixedInfo->NodeType));
-        if (pFixedInfo->EnableRouting)
-            _tprintf(_T("\tIP Routing Enabled. . . . . . . . : Yes\n"));
-        else
-            _tprintf(_T("\tIP Routing Enabled. . . . . . . . : No\n"));
-        if (pAdapter->HaveWins)
-            _tprintf(_T("\tWINS Proxy enabled. . . . . . . . : Yes\n"));
-        else
-            _tprintf(_T("\tWINS Proxy enabled. . . . . . . . : No\n"));
-        _tprintf(_T("\tDNS Suffix Search List. . . . . . : %s\n"), pFixedInfo->DomainName);
-    }
-
-       while (pAdapter)
-       {
-
-        _tprintf(_T("\n%s ...... : \n\n"), GetInterfaceTypeName(pAdapter->Type));
-        
-        /* check if the adapter is connected to the media */
-        if (_tcscmp(pAdapter->IpAddressList.IpAddress.String, "0.0.0.0") == 0)
-        {
-            _tprintf(_T("\tMedia State . . . . . . . . . . . : Media disconnected\n"));
-            pAdapter = pAdapter->Next;
-            continue;
-        }
-        
-        _tprintf(_T("\tConnection-specific DNS Suffix. . : %s\n"), pFixedInfo->DomainName);
-
-        if (bAll)
-        {
-            _tprintf(_T("\tDescription . . . . . . . . . . . : %s\n"), pAdapter->Description);
-            _tprintf(_T("\tPhysical Address. . . . . . . . . : %s\n"), PrintMacAddr(pAdapter->Address));
-            if (pAdapter->DhcpEnabled)
-                _tprintf(_T("\tDHCP Enabled. . . . . . . . . . . : Yes\n"));
-            else
-                _tprintf(_T("\tDHCP Enabled. . . . . . . . . . . : No\n"));
-            _tprintf(_T("\tAutoconfiguration Enabled . . . . : \n"));
-        }
-
-        _tprintf(_T("\tIP Address. . . . . . . . . . . . : %s\n"), pAdapter->IpAddressList.IpAddress.String);
-        _tprintf(_T("\tSubnet Mask . . . . . . . . . . . : %s\n"), pAdapter->IpAddressList.IpMask.String);
-        _tprintf(_T("\tDefault Gateway . . . . . . . . . : %s\n"), pAdapter->GatewayList.IpAddress.String);
-
-        if (bAll)
-        {
-            if (pAdapter->DhcpEnabled)
-               _tprintf(_T("\tDHCP Server . . . . . . . . . . . : %s\n"), pAdapter->DhcpServer.IpAddress.String);
-
-            _tprintf(_T("\tDNS Servers . . . . . . . . . . . : "));
-            _tprintf(_T("%s\n"), pFixedInfo->DnsServerList.IpAddress.String);
-            pIPAddr = pFixedInfo -> DnsServerList.Next;
-            while (pIPAddr)
-            {
-                _tprintf(_T("\t\t\t\t\t    %s\n"), pIPAddr ->IpAddress.String );
-                pIPAddr = pIPAddr ->Next;
-            }
-            if (pAdapter->HaveWins)
-            {
-                _tprintf(_T("\tPrimary WINS Server . . . . . . . : %s\n"), pAdapter->PrimaryWinsServer.IpAddress.String);
-                _tprintf(_T("\tSecondard WINS Server . . . . . . : %s\n"), pAdapter->SecondaryWinsServer.IpAddress.String);
-            }
-            if (pAdapter->DhcpEnabled)
-            {
-                _tprintf(_T("\tLease Obtained. . . . . . . . . . : %s"), _tasctime(localtime(&pAdapter->LeaseObtained)));
-                _tprintf(_T("\tLease Expires . . . . . . . . . . : %s"), _tasctime(localtime(&pAdapter->LeaseExpires)));
-            }
-        }
-        _tprintf(_T("\n"));
-        
-               pAdapter = pAdapter->Next;
-
-    }
-    return 0;
-}
-
-INT Release(TCHAR Index)
-{
-    IP_ADAPTER_INDEX_MAP AdapterInfo;
-    DWORD dwRetVal = 0;
-
-    /* if interface is not given, query GetInterfaceInfo */
-    if (Index == (TCHAR)NULL)
-    {
-        PIP_INTERFACE_INFO pInfo;
-        ULONG ulOutBufLen;
-        pInfo = (IP_INTERFACE_INFO *) malloc(sizeof(IP_INTERFACE_INFO));
-        ulOutBufLen = 0;
-
-        /* Make an initial call to GetInterfaceInfo to get
-         * the necessary size into the ulOutBufLen variable */
-        if ( GetInterfaceInfo(pInfo, &ulOutBufLen) == ERROR_INSUFFICIENT_BUFFER)
-        {
-            GlobalFree(pInfo);
-            pInfo = (IP_INTERFACE_INFO *) malloc (ulOutBufLen);
-        }
-
-        /* Make a second call to GetInterfaceInfo to get the actual data we want */
-        if ((dwRetVal = GetInterfaceInfo(pInfo, &ulOutBufLen)) == NO_ERROR )
-        {
-            AdapterInfo = pInfo->Adapter[0];
-            _tprintf(_T("name - %S\n"), pInfo->Adapter[0].Name);
-        }
-        else
-        {
-            _tprintf(_T("\nGetInterfaceInfo failed : "));
-            DoFormatMessage(dwRetVal);
-        }
-    }
-    else
-    {
-        ;
-        /* we need to be able to release connections by name with support for globbing
-         * i.e. ipconfig /release Eth* will release all cards starting with Eth...
-         *      ipconfig /release *con* will release all cards with 'con' in their name
-         */
-    }
-
-
-    /* Call IpReleaseAddress to release the IP address on the specified adapter. */
-    if ((dwRetVal = IpReleaseAddress(&AdapterInfo)) != NO_ERROR)
-    {
-        _tprintf(_T("\nAn error occured while releasing interface %s : "), _T("*name*"));
-        DoFormatMessage(dwRetVal);
-    }
-    return 0;
-}
-
-
-
-
-INT Renew(TCHAR Index)
-{
-    IP_ADAPTER_INDEX_MAP AdapterInfo;
-    DWORD dwRetVal = 0;
-
-    /* if interface is not given, query GetInterfaceInfo */
-    if (Index == (TCHAR)NULL)
-    {
-        PIP_INTERFACE_INFO pInfo;
-        ULONG ulOutBufLen;
-        pInfo = (IP_INTERFACE_INFO *) malloc(sizeof(IP_INTERFACE_INFO));
-        ulOutBufLen = 0;
-
-        /* Make an initial call to GetInterfaceInfo to get
-         * the necessary size into the ulOutBufLen variable */
-        if ( GetInterfaceInfo(pInfo, &ulOutBufLen) == ERROR_INSUFFICIENT_BUFFER)
-        {
-            GlobalFree(pInfo);
-            pInfo = (IP_INTERFACE_INFO *) malloc (ulOutBufLen);
-        }
-
-        /* Make a second call to GetInterfaceInfo to get the actual data we want */
-        if ((dwRetVal = GetInterfaceInfo(pInfo, &ulOutBufLen)) == NO_ERROR )
-        {
-            AdapterInfo = pInfo->Adapter[0];
-            _tprintf(_T("name - %S\n"), pInfo->Adapter[0].Name);
-        } else {
-            _tprintf(_T("\nGetInterfaceInfo failed : "));
-            DoFormatMessage(dwRetVal);
-        }
-    }
-    else
-    {
-        ;
-        /* we need to be able to renew connections by name with support for globbing
-         * i.e. ipconfig /renew Eth* will renew all cards starting with Eth...
-         *      ipconfig /renew *con* will renew all cards with 'con' in their name
-         */
-    }
-
-
-    /* Call IpRenewAddress to renew the IP address on the specified adapter. */
-    if ((dwRetVal = IpRenewAddress(&AdapterInfo)) != NO_ERROR)
-    {
-        _tprintf(_T("\nAn error occured while renew interface %s : "), _T("*name*"));
-        DoFormatMessage(dwRetVal);
-    }
-    return 0;
-}
-
-/* temp func for testing purposes */
-VOID Info()
-{
-     // Declare and initialize variables
-    PIP_INTERFACE_INFO pInfo;
-    ULONG ulOutBufLen;
-    DWORD dwRetVal;
-
-    pInfo = (IP_INTERFACE_INFO *) malloc( sizeof(IP_INTERFACE_INFO) );
-    ulOutBufLen = sizeof(IP_INTERFACE_INFO);
-    dwRetVal = 0;
-
-
-    // Make an initial call to GetInterfaceInfo to get
-    // the necessary size in the ulOutBufLen variable
-    if ( GetInterfaceInfo(pInfo, &ulOutBufLen) == ERROR_INSUFFICIENT_BUFFER)
-    {
-        free(pInfo);
-        pInfo = (IP_INTERFACE_INFO *) malloc (ulOutBufLen);
-    }
-
-    // Make a second call to GetInterfaceInfo to get
-    // the actual data we need
-    if ((dwRetVal = GetInterfaceInfo(pInfo, &ulOutBufLen)) == NO_ERROR )
-    {
-        int i;
-        for (i=0; i<pInfo->NumAdapters; i++)
-        {
-            printf("\tAdapter Name: %S\n", pInfo->Adapter[i].Name);
-            printf("\tAdapter Index: %ld\n", pInfo->Adapter[i].Index);
-            printf("\tNum Adapters: %ld\n", pInfo->NumAdapters);
-        }
-    }
-    else
-    {
-        printf("GetInterfaceInfo failed.\n");
-        DoFormatMessage(dwRetVal);
-    }
-}
-
-
-VOID Usage(VOID)
-{
-    _tprintf(_T("\nUSAGE:\n"
-    "    ipconfig [/? | /all | /renew [adapter] | /release [adapter] |\n"
-    "              /flushdns | /displaydns | /registerdns |\n"
-    "              /showclassid adapter |\n"
-    "              /setclassid adapter [classid] ]\n"
-    "\n"
-    "where\n"
-    "    adapter         Connection name\n"
-    "                   (wildcard characters * and ? allowed, see examples)\n"
-    "\n"
-    "    Options:\n"
-    "       /?           Display this help message\n"
-    "       /all         Display full configuration information.\n"
-    "       /release     Release the IP address for the specified adapter.\n"
-    "       /renew       Renew the IP address for the specified adapter.\n"
-    "       /flushdns    Purges the DNS Resolver cache.\n"
-    "       /registerdns Refreshes all DHCP leases and re-registers DNS names.\n"
-    "       /displaydns  Display the contents of the DNS Resolver Cache.\n"
-    "       /showclassid Displays all the dhcp class IDs allowed for adapter.\n"
-    "       /setclassid  Modifies the dhcp class id.\n"
-    "\n"
-    "The default is to display only the IP address, subnet mask and\n"
-    "default gateway for each adapter bound to TCP/IP.\n"
-    "\n"
-    "For Release and Renew, if no adapter name is specified, then the IP address\n"
-    "leases for all adapters bound to TCP/IP will be released or renewed.\n"
-    "\n"
-    "For Setclassid, if no ClassId is specified, then the ClassId is removed.\n"
-    "\n"
-    "Examples:\n"
-    "    > ipconfig                   ... Show information.\n"
-    "    > ipconfig /all              ... Show detailed information\n"
-    "    > ipconfig /renew            ... renew all adapters\n"
-    "    > ipconfig /renew EL*        ... renew any connection that has its\n"
-    "                                     name starting with EL\n"
-    "    > ipconfig /release *Con*    ... release all matching connections,\n"
-    "                                     eg. \"Local Area Connection 1\" or\n"
-    "                                         \"Local Area Connection 2\"\n"));
-}
-
-int main(int argc, char *argv[])
-{
-    BOOL DoUsage=FALSE;
-    BOOL DoAll=FALSE;
-    BOOL DoRelease=FALSE;
-    BOOL DoRenew=FALSE;
-    BOOL DoFlushdns=FALSE;
-    BOOL DoRegisterdns=FALSE;
-    BOOL DoDisplaydns=FALSE;
-    BOOL DoShowclassid=FALSE;
-    BOOL DoSetclassid=FALSE;
-
-    /* Parse command line for options we have been given. */
-    if ( (argc > 1)&&(argv[1][0]=='/') )
-    {
-        if( !_tcsicmp( &argv[1][1], _T("?") ))
-        {
-            DoUsage = TRUE;
-        }
-        else if( !_tcsnicmp( &argv[1][1], _T("ALL"), _tcslen(&argv[1][1]) ))
-        {
-           DoAll = TRUE;
-        }
-        else if( !_tcsnicmp( &argv[1][1], _T("RELEASE"), _tcslen(&argv[1][1]) ))
-        {
-            DoRelease = TRUE;
-        }
-        else if( ! _tcsnicmp( &argv[1][1], _T("RENEW"), _tcslen(&argv[1][1]) ))
-        {
-            DoRenew = TRUE;
-        }
-        else if( ! _tcsnicmp( &argv[1][1], _T("FLUSHDNS"), _tcslen(&argv[1][1]) ))
-        {
-            DoFlushdns = TRUE;
-        }
-        else if( ! _tcsnicmp( &argv[1][1], _T("FLUSHREGISTERDNS"), _tcslen(&argv[1][1]) ))
-        {
-            DoRegisterdns = TRUE;
-        }
-        else if( ! _tcsnicmp( &argv[1][1], _T("DISPLAYDNS"), _tcslen(&argv[1][1]) ))
-        {
-            DoDisplaydns = TRUE;
-        }
-        else if( ! _tcsnicmp( &argv[1][1], _T("SHOWCLASSID"), _tcslen(&argv[1][1]) ))
-        {
-            DoShowclassid = TRUE;
-        }
-        else if( ! _tcsnicmp( &argv[1][1], _T("SETCLASSID"), _tcslen(&argv[1][1]) ))
-        {
-            DoSetclassid = TRUE;
-        }
-    }
-
-    switch (argc)
-    {
-        case 1:  /* Default behaviour if no options are given*/
-            ShowInfo(FALSE);
-            break;
-        case 2:  /* Process all the options that take no paramiters */
-            if (DoUsage)
-                Usage();
-            else if (DoAll)
-                ShowInfo(TRUE);
-            else if (DoRelease)
-                Release((TCHAR)NULL);
-            else if (DoRenew)
-                Renew((TCHAR)NULL);
-            else if (DoFlushdns)
-                _tprintf(_T("\nSorry /flushdns is not implemented yet\n"));
-            else if (DoRegisterdns)
-                _tprintf(_T("\nSorry /registerdns is not implemented yet\n"));
-            else if (DoDisplaydns)
-                _tprintf(_T("\nSorry /displaydns is not implemented yet\n"));
-            else
-                Usage();
-            break;
-        case 3: /* Process all the options that can have 1 paramiters */
-            if (DoRelease)
-                _tprintf(_T("\nSorry /release [adapter] is not implemented yet\n"));
-                //Release(argv[2]);
-            else if (DoRenew)
-                _tprintf(_T("\nSorry /renew [adapter] is not implemented yet\n"));
-            else if (DoShowclassid)
-                _tprintf(_T("\nSorry /showclassid adapter is not implemented yet\n"));
-            else if (DoSetclassid)
-                _tprintf(_T("\nSorry /setclassid adapter is not implemented yet\n"));
-            else
-                Usage();
-            break;
-        case 4:  /* Process all the options that can have 2 paramiters */
-            if (DoSetclassid)
-                _tprintf(_T("\nSorry /setclassid adapter [classid]is not implemented yet\n"));
-            else
-                Usage();
-            break;
-        default:
-            Usage();
-    }
-
-    return 0;
-}
diff --git a/reactos/apps/utils/net/ipconfig/ipconfig.rc b/reactos/apps/utils/net/ipconfig/ipconfig.rc
deleted file mode 100644 (file)
index 15ce162..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-#define REACTOS_STR_FILE_DESCRIPTION    "ReactOS TCP/IPv4 Win32 ipconfig\0"
-#define REACTOS_STR_INTERNAL_NAME   "ipconfig\0"
-#define REACTOS_STR_ORIGINAL_FILENAME   "ipconfig.exe\0"
-#define REACTOS_STR_ORIGINAL_COPYRIGHT  "Ged Murphy (gedmurphy@gmail.com)\0"
-#include <reactos/version.rc>
diff --git a/reactos/apps/utils/net/ipconfig/ipconfig.xml b/reactos/apps/utils/net/ipconfig/ipconfig.xml
deleted file mode 100644 (file)
index adff15b..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-<module name="ipconfig" type="win32cui" installbase="system32" installname="ipconfig.exe" allowwarnings="true">
-    <include base="ipconfig">.</include>
-    <define name="__USE_W32API" />
-    <library>kernel32</library>
-    <library>user32</library>
-    <library>iphlpapi</library>
-    <file>ipconfig.c</file>
-    <file>ipconfig.rc</file>
-</module>
diff --git a/reactos/apps/utils/net/netstat/netstat.c b/reactos/apps/utils/net/netstat/netstat.c
deleted file mode 100644 (file)
index a736d49..0000000
+++ /dev/null
@@ -1,642 +0,0 @@
-/*
- * PROJECT:     ReactOS netstat utility
- * LICENSE:     GPL - See COPYING in the top level directory
- * FILE:        apps/utils/net/netstat/netstat.c
- * PURPOSE:     display IP stack statistics
- * COPYRIGHT:   Copyright 2005 Ged Murphy <gedmurphy@gmail.com>
- */
-/*
- * TODO:
- * sort function return values.
- * implement -b, -o and -v
- * clean up GetIpHostName
- * command line parser needs more work
- */
-
-#include <windows.h>
-#include <winsock.h>
-#include <tchar.h>
-#include <stdio.h>
-#include <iphlpapi.h>
-#include "netstat.h"
-
-
-enum ProtoType {IP, TCP, UDP, ICMP} Protocol;
-DWORD Interval; /* time to pause between printing output */
-
-/* TCP endpoint states */
-TCHAR TcpState[][32] = {
-    _T("???"),
-    _T("CLOSED"),
-    _T("LISTENING"),
-    _T("SYN_SENT"),
-    _T("SYN_RCVD"),
-    _T("ESTABLISHED"),
-    _T("FIN_WAIT1"),
-    _T("FIN_WAIT2"),
-    _T("CLOSE_WAIT"),
-    _T("CLOSING"),
-    _T("LAST_ACK"),
-    _T("TIME_WAIT"),
-    _T("DELETE_TCB")
-};
-
-
-/*
- * format message string and display output
- */
-DWORD DoFormatMessage(DWORD ErrorCode)
-{
-    LPVOID lpMsgBuf;
-    DWORD RetVal;
-
-    if ((RetVal = FormatMessage(
-            FORMAT_MESSAGE_ALLOCATE_BUFFER |
-            FORMAT_MESSAGE_FROM_SYSTEM |
-            FORMAT_MESSAGE_IGNORE_INSERTS,
-            NULL,
-            ErrorCode,
-            MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), /* Default language */
-            (LPTSTR) &lpMsgBuf,
-            0,
-            NULL )))
-    {
-        _tprintf(_T("%s"), (LPTSTR)lpMsgBuf);
-
-        LocalFree(lpMsgBuf);
-        /* return number of TCHAR's stored in output buffer
-         * excluding '\0' - as FormatMessage does*/
-        return RetVal;
-    }
-    else
-        return 0;
-}
-
-
-/*
- *
- * Parse command line parameters and set any options
- *
- */
-BOOL ParseCmdline(int argc, char* argv[])
-{
-    INT i;
-
-    TCHAR Proto[5];
-
-    if ((argc == 1) || (_istdigit(*argv[1])))
-        bNoOptions = TRUE;
-
-    /* Parse command line for options we have been given. */
-    for (i = 1; i < argc; i++)
-    {
-        if ( (argc > 1)&&(argv[i][0] == '-') )
-        {
-            TCHAR c;
-
-            while ((c = *++argv[i]) != '\0')
-            {
-                switch (tolower(c))
-                {
-                    case 'a' :
-                        bDoShowAllCons = TRUE;
-                        break;
-                    case 'b' :
-                        bDoShowProcName = TRUE;
-                        break;
-                    case 'e' :
-                        bDoShowEthStats = TRUE;
-                        break;
-                    case 'n' :
-                        bDoShowNumbers = TRUE;
-                        break;
-                    case 's' :
-                        bDoShowProtoStats = TRUE;
-                        break;
-                    case 'p' :
-                        bDoShowProtoCons = TRUE;
-
-                        strncpy(Proto, (++argv)[i], sizeof(Proto));
-                        if (!_tcsicmp( "IP", Proto ))
-                            Protocol = IP;
-                        else if (!_tcsicmp( "ICMP", Proto ))
-                            Protocol = ICMP;
-                        else if (!_tcsicmp( "TCP", Proto ))
-                            Protocol = TCP;
-                        else if (!_tcsicmp( "UDP", Proto ))
-                            Protocol = UDP;
-                        else
-                        {
-                            Usage();
-                            return EXIT_FAILURE;
-                        }
-                        (--argv)[i]; /* move pointer back down to previous argv */
-                        break;
-                    case 'r' :
-                        bDoShowRouteTable = TRUE;
-                        break;
-                    case 'v' :
-                        _tprintf(_T("got v\n"));
-                        bDoDispSeqComp = TRUE;
-                        break;
-                    default :
-                        Usage();
-                        return EXIT_FAILURE;
-                }
-            }
-        }
-        else if (_istdigit(*argv[i]))
-        {
-            if (_stscanf(argv[i], "%lu", &Interval) != EOF)
-                bLoopOutput = TRUE;
-            else
-                return EXIT_FAILURE;
-        }
-//        else
-//        {
-//            Usage();
-//            EXIT_FAILURE;
-//        }
-    }
-
-    return EXIT_SUCCESS;
-}
-
-
-/*
- * Simulate Microsofts netstat utility output
- */
-BOOL DisplayOutput()
-{
-    if (bNoOptions)
-    {
-        _tprintf(_T("\n  Proto  Local Address          Foreign Address        State\n"));
-        ShowTcpTable();
-        return EXIT_SUCCESS;
-    }
-
-    if (bDoShowRouteTable)
-    {
-        /* mingw doesn't have lib for _tsystem */
-        if (system("route print") == -1)
-        {
-            _tprintf(_T("cannot find 'route.exe'\n"));
-            return EXIT_FAILURE;
-        }
-        return EXIT_SUCCESS;
-    }
-
-    if (bDoShowEthStats)
-    {
-        ShowEthernetStatistics();
-        return EXIT_SUCCESS;
-    }
-
-    if (bDoShowProtoCons)
-    {
-        switch (Protocol)
-        {
-                case IP :
-                    if (bDoShowProtoStats)
-                    {
-                        ShowIpStatistics();
-                        return EXIT_SUCCESS;
-                    }
-                    break;
-                case ICMP :
-                    if (bDoShowProtoStats)
-                    {
-                        ShowIcmpStatistics();
-                        return EXIT_SUCCESS;
-                    }
-                    break;
-                case TCP :
-                    if (bDoShowProtoStats)
-                        ShowTcpStatistics();
-                    _tprintf(_T("\nActive Connections\n"));
-                    _tprintf(_T("\n  Proto  Local Address          Foreign Address        State\n"));
-                    ShowTcpTable();
-                    break;
-                case UDP :
-                    if (bDoShowProtoStats)
-                        ShowUdpStatistics();
-                    _tprintf(_T("\nActive Connections\n"));
-                    _tprintf(_T("\n  Proto  Local Address          Foreign Address        State\n"));
-                    ShowUdpTable();
-                    break;
-                default :
-                    break;
-        }
-    }
-    else if (bDoShowProtoStats)
-    {
-        ShowIpStatistics();
-        ShowIcmpStatistics();
-        ShowTcpStatistics();
-        ShowUdpStatistics();
-        return EXIT_SUCCESS;
-    }
-    else //if (bDoShowAllCons)
-    {
-        _tprintf(_T("\nActive Connections\n"));
-        _tprintf(_T("\n  Proto  Local Address          Foreign Address        State\n"));
-        ShowTcpTable();
-        ShowUdpTable();
-    }
-    return EXIT_SUCCESS;
-}
-
-
-
-
-VOID ShowIpStatistics()
-{
-    PMIB_IPSTATS pIpStats;
-    DWORD dwRetVal;
-
-    pIpStats = (MIB_IPSTATS*) HeapAlloc(GetProcessHeap(), 0, sizeof(MIB_IPSTATS));
-
-    if ((dwRetVal = GetIpStatistics(pIpStats)) == NO_ERROR)
-    {
-        _tprintf(_T("\nIPv4 Statistics\n\n"));
-        _tprintf(_T("  %-34s = %lu\n"), _T("Packets Recieved"), pIpStats->dwInReceives);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Received Header Errors"), pIpStats->dwInHdrErrors);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Received Address Errors"), pIpStats->dwInAddrErrors);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Datagrams Forwarded"), pIpStats->dwForwDatagrams);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Unknown Protocols Recieved"), pIpStats->dwInUnknownProtos);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Received Packets Discarded"), pIpStats->dwInDiscards);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Recieved Packets Delivered"), pIpStats->dwInDelivers);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Output Requests"), pIpStats->dwOutRequests);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Routing Discards"), pIpStats->dwRoutingDiscards);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Discarded Output Packets"), pIpStats->dwOutDiscards);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Output Packets No Route"), pIpStats->dwOutNoRoutes);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Reassembly Required"), pIpStats->dwReasmReqds);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Reassembly Succesful"), pIpStats->dwReasmOks);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Reassembly Failures"), pIpStats->dwReasmFails);
-       // _tprintf(_T("  %-34s = %lu\n"), _T("Datagrams succesfully fragmented"), NULL); /* FIXME: what is this one? */
-        _tprintf(_T("  %-34s = %lu\n"), _T("Datagrams Failing Fragmentation"), pIpStats->dwFragFails);
-        _tprintf(_T("  %-34s = %lu\n"), _T("Fragments Created"), pIpStats->dwFragCreates);
-    }
-    else
-        DoFormatMessage(dwRetVal);
-
-    HeapFree(GetProcessHeap(), 0, pIpStats);
-}
-
-VOID ShowIcmpStatistics()
-{
-    PMIB_ICMP pIcmpStats;
-    DWORD dwRetVal;
-
-    pIcmpStats = (MIB_ICMP*) HeapAlloc(GetProcessHeap(), 0, sizeof(MIB_ICMP));
-
-    if ((dwRetVal = GetIcmpStatistics(pIcmpStats)) == NO_ERROR)
-    {
-        _tprintf(_T("\nICMPv4 Statistics\n\n"));
-        _tprintf(_T("                            Received    Sent\n"));
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Messages"),
-            pIcmpStats->stats.icmpInStats.dwMsgs, pIcmpStats->stats.icmpOutStats.dwMsgs);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Errors"),
-            pIcmpStats->stats.icmpInStats.dwErrors, pIcmpStats->stats.icmpOutStats.dwErrors);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Destination Unreachable"),
-            pIcmpStats->stats.icmpInStats.dwDestUnreachs, pIcmpStats->stats.icmpOutStats.dwDestUnreachs);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Time Exceeded"),
-            pIcmpStats->stats.icmpInStats.dwTimeExcds, pIcmpStats->stats.icmpOutStats.dwTimeExcds);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Parameter Problems"),
-            pIcmpStats->stats.icmpInStats.dwParmProbs, pIcmpStats->stats.icmpOutStats.dwParmProbs);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Source Quenches"),
-            pIcmpStats->stats.icmpInStats.dwSrcQuenchs, pIcmpStats->stats.icmpOutStats.dwSrcQuenchs);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Redirects"),
-            pIcmpStats->stats.icmpInStats.dwRedirects, pIcmpStats->stats.icmpOutStats.dwRedirects);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Echos"),
-            pIcmpStats->stats.icmpInStats.dwEchos, pIcmpStats->stats.icmpOutStats.dwEchos);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Echo Replies"),
-            pIcmpStats->stats.icmpInStats.dwEchoReps, pIcmpStats->stats.icmpOutStats.dwEchoReps);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Timestamps"),
-            pIcmpStats->stats.icmpInStats.dwTimestamps, pIcmpStats->stats.icmpOutStats.dwTimestamps);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Timestamp Replies"),
-            pIcmpStats->stats.icmpInStats.dwTimestampReps, pIcmpStats->stats.icmpOutStats.dwTimestampReps);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Address Masks"),
-            pIcmpStats->stats.icmpInStats.dwAddrMasks, pIcmpStats->stats.icmpOutStats.dwAddrMasks);
-        _tprintf(_T("  %-25s %-11lu %lu\n"), _T("Address Mask Replies"),
-            pIcmpStats->stats.icmpInStats.dwAddrMaskReps, pIcmpStats->stats.icmpOutStats.dwAddrMaskReps);
-    }
-    else
-        DoFormatMessage(dwRetVal);
-
-    HeapFree(GetProcessHeap(), 0, pIcmpStats);
-
-}
-
-VOID ShowTcpStatistics()
-{
-    PMIB_TCPSTATS pTcpStats;
-    DWORD dwRetVal;
-
-    pTcpStats = (MIB_TCPSTATS*) HeapAlloc(GetProcessHeap(), 0, sizeof(MIB_TCPSTATS));
-
-    if ((dwRetVal = GetTcpStatistics(pTcpStats)) == NO_ERROR)
-    {
-        _tprintf(_T("\nTCP Statistics for IPv4\n\n"));
-        _tprintf(_T("  %-35s = %lu\n"), _T("Active Opens"), pTcpStats->dwActiveOpens);
-        _tprintf(_T("  %-35s = %lu\n"), _T("Passive Opens"), pTcpStats->dwPassiveOpens);
-        _tprintf(_T("  %-35s = %lu\n"), _T("Failed Connection Attempts"), pTcpStats->dwAttemptFails);
-        _tprintf(_T("  %-35s = %lu\n"), _T("Reset Connections"), pTcpStats->dwEstabResets);
-        _tprintf(_T("  %-35s = %lu\n"), _T("Current Connections"), pTcpStats->dwCurrEstab);
-        _tprintf(_T("  %-35s = %lu\n"), _T("Segments Recieved"), pTcpStats->dwInSegs);
-        _tprintf(_T("  %-35s = %lu\n"), _T("Segments Sent"), pTcpStats->dwOutSegs);
-        _tprintf(_T("  %-35s = %lu\n"), _T("Segments Retransmitted"), pTcpStats->dwRetransSegs);
-    }
-    else
-        DoFormatMessage(dwRetVal);
-
-    HeapFree(GetProcessHeap(), 0, pTcpStats);
-}
-
-VOID ShowUdpStatistics()
-{
-    PMIB_UDPSTATS pUdpStats;
-    DWORD dwRetVal;
-
-    pUdpStats = (MIB_UDPSTATS*) HeapAlloc(GetProcessHeap(), 0, sizeof(MIB_UDPSTATS));
-
-    if ((dwRetVal = GetUdpStatistics(pUdpStats)) == NO_ERROR)
-    {
-        _tprintf(_T("\nUDP Statistics for IPv4\n\n"));
-        _tprintf(_T("  %-21s = %lu\n"), _T("Datagrams Recieved"), pUdpStats->dwInDatagrams);
-        _tprintf(_T("  %-21s = %lu\n"), _T("No Ports"), pUdpStats->dwNoPorts);
-        _tprintf(_T("  %-21s = %lu\n"), _T("Recieve Errors"), pUdpStats->dwInErrors);
-        _tprintf(_T("  %-21s = %lu\n"), _T("Datagrams Sent"), pUdpStats->dwOutDatagrams);
-    }
-    else
-        DoFormatMessage(dwRetVal);
-
-    HeapFree(GetProcessHeap(), 0, pUdpStats);
-}
-
-VOID ShowEthernetStatistics()
-{
-    PMIB_IFTABLE pIfTable;
-    DWORD dwSize = 0;
-    DWORD dwRetVal = 0;
-
-    pIfTable = (MIB_IFTABLE*) HeapAlloc(GetProcessHeap(), 0, sizeof(MIB_IFTABLE));
-
-    if (GetIfTable(pIfTable, &dwSize, 0) == ERROR_INSUFFICIENT_BUFFER)
-    {
-        HeapFree(GetProcessHeap(), 0, pIfTable);
-        pIfTable = (MIB_IFTABLE*) HeapAlloc(GetProcessHeap(), 0, dwSize);
-
-        if ((dwRetVal = GetIfTable(pIfTable, &dwSize, 0)) == NO_ERROR)
-        {
-            _tprintf(_T("Interface Statistics\n\n"));
-            _tprintf(_T("                           Received            Sent\n\n"));
-            _tprintf(_T("%-20s %14lu %15lu\n"), _T("Bytes"),
-                pIfTable->table[0].dwInOctets, pIfTable->table[0].dwOutOctets);
-            _tprintf(_T("%-20s %14lu %15lu\n"), _T("Unicast packets"),
-                pIfTable->table[0].dwInUcastPkts, pIfTable->table[0].dwOutUcastPkts);
-            _tprintf(_T("%-20s %14lu %15lu\n"), _T("Non-unicast packets"),
-                pIfTable->table[0].dwInNUcastPkts, pIfTable->table[0].dwOutNUcastPkts);
-            _tprintf(_T("%-20s %14lu %15lu\n"), _T("Discards"),
-                pIfTable->table[0].dwInDiscards, pIfTable->table[0].dwOutDiscards);
-            _tprintf(_T("%-20s %14lu %15lu\n"), _T("Errors"),
-                pIfTable->table[0].dwInErrors, pIfTable->table[0].dwOutErrors);
-            _tprintf(_T("%-20s %14lu\n"), _T("Unknown Protocols"),
-                pIfTable->table[0].dwInUnknownProtos);
-        }
-        else
-            DoFormatMessage(dwRetVal);
-    }
-    HeapFree(GetProcessHeap(), 0, pIfTable);
-}
-
-VOID ShowTcpTable()
-{
-    PMIB_TCPTABLE tcpTable;
-    DWORD error, dwSize;
-    DWORD i;
-    CHAR HostIp[HOSTNAMELEN], HostPort[PORTNAMELEN];
-    CHAR RemoteIp[HOSTNAMELEN], RemotePort[PORTNAMELEN];
-    CHAR Host[ADDRESSLEN];
-    CHAR Remote[ADDRESSLEN];
-
-    /* Get the table of TCP endpoints */
-    dwSize = 0;
-    error = GetTcpTable(NULL, &dwSize, TRUE);
-    if (error != ERROR_INSUFFICIENT_BUFFER)
-    {
-        printf("Failed to snapshot TCP endpoints.\n");
-        DoFormatMessage(error);
-        exit(EXIT_FAILURE);
-    }
-    tcpTable = (PMIB_TCPTABLE) HeapAlloc(GetProcessHeap(), 0, dwSize);
-    error = GetTcpTable(tcpTable, &dwSize, TRUE );
-    if (error)
-    {
-        printf("Failed to snapshot TCP endpoints table.\n");
-        DoFormatMessage(error);
-        HeapFree(GetProcessHeap(), 0, tcpTable);
-        exit(EXIT_FAILURE);
-    }
-
-    /* Dump the TCP table */
-    for (i = 0; i < tcpTable->dwNumEntries; i++)
-    {
-        /* If we aren't showing all connections, only display established, close wait
-         * and time wait. This is the default output for netstat */
-        if (bDoShowAllCons || (tcpTable->table[i].dwState ==  MIB_TCP_STATE_ESTAB)
-            || (tcpTable->table[i].dwState ==  MIB_TCP_STATE_CLOSE_WAIT)
-            || (tcpTable->table[i].dwState ==  MIB_TCP_STATE_TIME_WAIT))
-        {
-            /* I've split this up so it's easier to follow */
-            GetIpHostName(TRUE, tcpTable->table[i].dwLocalAddr, HostIp, HOSTNAMELEN);
-            GetPortName(tcpTable->table[i].dwLocalPort, "tcp", HostPort, PORTNAMELEN);
-            GetIpHostName(FALSE, tcpTable->table[i].dwRemoteAddr, RemoteIp, HOSTNAMELEN);
-            GetPortName(tcpTable->table[i].dwRemotePort, "tcp", RemotePort, PORTNAMELEN);
-
-            sprintf(Host, "%s:%s", HostIp, HostPort);
-            sprintf(Remote, "%s:%s", RemoteIp, RemotePort);
-
-            _tprintf(_T("  %-6s %-22s %-22s %s\n"), _T("TCP"),
-            Host, Remote, TcpState[tcpTable->table[i].dwState]);
-        }
-    }
-    HeapFree(GetProcessHeap(), 0, tcpTable);
-}
-
-
-VOID ShowUdpTable()
-{
-    PMIB_UDPTABLE udpTable;
-    DWORD error, dwSize;
-    DWORD i;
-    CHAR HostIp[HOSTNAMELEN], HostPort[PORTNAMELEN];
-    CHAR Host[ADDRESSLEN];
-
-    /* Get the table of UDP endpoints */
-    dwSize = 0;
-    error = GetUdpTable(NULL, &dwSize, TRUE);
-    if (error != ERROR_INSUFFICIENT_BUFFER)
-    {
-        printf("Failed to snapshot UDP endpoints.\n");
-        DoFormatMessage(error);
-        exit(EXIT_FAILURE);
-    }
-    udpTable = (PMIB_UDPTABLE) HeapAlloc(GetProcessHeap(), 0, dwSize);
-    error = GetUdpTable(udpTable, &dwSize, TRUE);
-    if (error)
-    {
-        printf("Failed to snapshot UDP endpoints table.\n");
-        DoFormatMessage(error);
-        HeapFree(GetProcessHeap(), 0, udpTable);
-        exit(EXIT_FAILURE);
-    }
-
-    /* Dump the UDP table */
-    for (i = 0; i < udpTable->dwNumEntries; i++)
-    {
-
-        /* I've split this up so it's easier to follow */
-        GetIpHostName(TRUE, udpTable->table[i].dwLocalAddr, HostIp, HOSTNAMELEN);
-        GetPortName(udpTable->table[i].dwLocalPort, "tcp", HostPort, PORTNAMELEN);
-
-        sprintf(Host, "%s:%s", HostIp, HostPort);
-
-        _tprintf(_T("  %-6s %-22s %-22s\n"), _T("UDP"), Host,  _T("*:*"));
-    }
-
-    HeapFree(GetProcessHeap(), 0, udpTable);
-}
-
-
-/*
- * Translate port numbers into their text equivalent if there is one
- */
-PCHAR
-GetPortName(UINT Port, PCSTR Proto, CHAR Name[], INT NameLen)
-{
-    struct servent *pSrvent;
-
-    if (bDoShowNumbers)
-    {
-        sprintf(Name, "%d", htons((WORD)Port));
-        return Name;
-    }
-    /* Try to translate to a name */
-    if ((pSrvent = getservbyport(Port, Proto)))
-        strcpy(Name, pSrvent->s_name );
-    else
-        sprintf(Name, "%d", htons((WORD)Port));
-    return Name;
-}
-
-
-/*
- * convert addresses into dotted decimal or hostname
- */
-PCHAR
-GetIpHostName(BOOL Local, UINT IpAddr, CHAR Name[], int NameLen)
-{
-//  struct hostent *phostent;
-    UINT nIpAddr;
-
-    /* display dotted decimal */
-    nIpAddr = htonl(IpAddr);
-    if (bDoShowNumbers) {
-        sprintf(Name, "%d.%d.%d.%d",
-            (nIpAddr >> 24) & 0xFF,
-            (nIpAddr >> 16) & 0xFF,
-            (nIpAddr >> 8) & 0xFF,
-            (nIpAddr) & 0xFF);
-        return Name;
-    }
-
-    Name[0] = _T('\0');
-
-    /* try to resolve the name */
-    if (!IpAddr) {
-        if (!Local) {
-            sprintf(Name, "%d.%d.%d.%d",
-                (nIpAddr >> 24) & 0xFF,
-                (nIpAddr >> 16) & 0xFF,
-                (nIpAddr >> 8) & 0xFF,
-                (nIpAddr) & 0xFF);
-        } else {
-            if (gethostname(Name, NameLen) != 0)
-                DoFormatMessage(WSAGetLastError());
-        }
-    } else if (IpAddr == 0x0100007f) {
-        if (Local) {
-            if (gethostname(Name, NameLen) != 0)
-                DoFormatMessage(WSAGetLastError());
-        } else {
-            _tcsncpy(Name, _T("localhost"), 10);
-        }
-//  } else if (phostent = gethostbyaddr((char*)&ipaddr, sizeof(nipaddr), PF_INET)) {
-//      strcpy(name, phostent->h_name);
-    } else {
-        sprintf(Name, "%d.%d.%d.%d",
-            ((nIpAddr >> 24) & 0x000000FF),
-            ((nIpAddr >> 16) & 0x000000FF),
-            ((nIpAddr >> 8) & 0x000000FF),
-            ((nIpAddr) & 0x000000FF));
-    }
-    return Name;
-}
-
-VOID Usage()
-{
-    _tprintf(_T("\nDisplays current TCP/IP protocol statistics and network connections.\n\n"
-    "NETSTAT [-a] [-e] [-n] [-s] [-p proto] [-r] [interval]\n\n"
-    "  -a            Displays all connections and listening ports.\n"
-    "  -e            Displays Ethernet statistics. May be combined with -s\n"
-    "                option\n"
-    "  -n            Displays address and port numbers in numeric form.\n"
-    "  -p proto      Shows connections for protocol 'proto' TCP or UDP.\n"
-    "                If used with the -s option to display\n"
-    "                per-protocol statistics, 'proto' may be TCP, UDP, or IP.\n"
-    "  -r            Displays the current routing table.\n"
-    "  -s            Displays per-protocol statistics. By default, Statistics are\n"
-    "                shown for IP, ICMP, TCP and UDP;\n"
-    "                the -p option may be used to specify a subset of the default.\n"
-    "  interval      Redisplays selected statistics every 'interval' seconds.\n"
-    "                Press CTRL+C to stop redisplaying. By default netstat will\n"
-    "                print the current information only once.\n"));
-}
-
-
-
-/*
- *
- * Parse command line parameters and set any options
- * Run display output, looping over set intervals if a number is given
- *
- */
-int main(int argc, char *argv[])
-{
-    WSADATA wsaData;
-
-    if (WSAStartup(MAKEWORD(2, 2), &wsaData) != 0)
-    {
-        _tprintf(_T("WSAStartup() failed : %d\n"), WSAGetLastError());
-        return -1;
-    }
-
-    if (ParseCmdline(argc, argv))
-        return -1;
-
-    if (bLoopOutput)
-    {
-        while (1)
-        {
-            if (DisplayOutput())
-                return -1;
-            Sleep(Interval*1000);
-        }
-    }
-
-    if (DisplayOutput())
-        return -1;
-    else
-        return 0;
-}
diff --git a/reactos/apps/utils/net/netstat/netstat.h b/reactos/apps/utils/net/netstat/netstat.h
deleted file mode 100644 (file)
index 43b4824..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-
-/* Maximum string lengths for ASCII ip address and port names */
-#define HOSTNAMELEN     256
-#define PORTNAMELEN     256
-#define ADDRESSLEN      HOSTNAMELEN+PORTNAMELEN
-
-/* command line options */
-BOOL bNoOptions        = FALSE; // print default
-BOOL bDoShowAllCons    = FALSE; // -a
-BOOL bDoShowProcName   = FALSE; // -b
-BOOL bDoShowEthStats   = FALSE; // -e
-BOOL bDoShowNumbers    = FALSE; // -n
-BOOL bDoShowProtoCons  = FALSE; // -p
-BOOL bDoShowRouteTable = FALSE; // -r
-BOOL bDoShowProtoStats = FALSE; // -s
-BOOL bDoDispSeqComp    = FALSE; // -v
-BOOL bLoopOutput       = FALSE; // interval
-
-
-/* Undocumented extended information structures available only on XP and higher */
-typedef struct {
-  DWORD dwState;        // state of the connection
-  DWORD dwLocalAddr;    // address on local computer
-  DWORD dwLocalPort;    // port number on local computer
-  DWORD dwRemoteAddr;   // address on remote computer
-  DWORD dwRemotePort;   // port number on remote computer
-  DWORD dwProcessId;
-} MIB_TCPEXROW, *PMIB_TCPEXROW;
-
-typedef struct {
-    DWORD dwNumEntries;
-    MIB_TCPEXROW table;
-} MIB_TCPEXTABLE, *PMIB_TCPEXTABLE;
-
-typedef struct {
-  DWORD   dwLocalAddr;    // address on local computer
-  DWORD   dwLocalPort;    // port number on local computer
-  DWORD   dwProcessId;
-} MIB_UDPEXROW, *PMIB_UDPEXROW;
-
-typedef struct {
-    DWORD dwNumEntries;
-    MIB_UDPEXROW table;
-} MIB_UDPEXTABLE, *PMIB_UDPEXTABLE;
-
-
-/* function declerations */
-BOOL ParseCmdline(int argc, char* argv[]);
-BOOL DisplayOutput(VOID);
-DWORD DoFormatMessage(DWORD ErrorCode);
-VOID ShowIpStatistics(VOID);
-VOID ShowIcmpStatistics(VOID);
-VOID ShowTcpStatistics(VOID);
-VOID ShowUdpStatistics(VOID);
-VOID ShowEthernetStatistics(VOID);
-VOID ShowTcpTable(VOID);
-VOID ShowUdpTable(VOID);
-PCHAR GetPortName(UINT Port, PCSTR Proto, CHAR Name[PORTNAMELEN], INT NameLen);
-PCHAR GetIpHostName(BOOL local, UINT ipaddr, CHAR name[HOSTNAMELEN], int namelen);
-VOID Usage(VOID);
-
diff --git a/reactos/apps/utils/net/netstat/netstat.rc b/reactos/apps/utils/net/netstat/netstat.rc
deleted file mode 100644 (file)
index f544d02..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-#define REACTOS_STR_FILE_DESCRIPTION    "ReactOS TCP/IPv4 Win32 netstat\0"
-#define REACTOS_STR_INTERNAL_NAME   "netstat\0"
-#define REACTOS_STR_ORIGINAL_FILENAME   "netstat.exe\0"
-#define REACTOS_STR_ORIGINAL_COPYRIGHT  "Ged Murphy (gedmurphy@gmail.com)\0"
-#include <reactos/version.rc>
-
-
diff --git a/reactos/apps/utils/net/netstat/netstat.xml b/reactos/apps/utils/net/netstat/netstat.xml
deleted file mode 100644 (file)
index fc1f0f2..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-<module name="netstat" type="win32cui" installbase="system32" installname="netstat.exe" allowwarnings="true">
-    <include base="netstat">.</include>
-    <define name="__USE_W32API" />
-    <define name="_WIN32_IE">0x600</define>
-    <define name="_WIN32_WINNT">0x501</define>
-    <library>kernel32</library>
-    <library>user32</library>
-    <library>ws2_32</library>
-    <library>snmpapi</library>
-    <library>iphlpapi</library>
-    <file>netstat.c</file>
-    <file>netstat.rc</file>
-</module>
diff --git a/reactos/apps/utils/net/ping/ping.c b/reactos/apps/utils/net/ping/ping.c
deleted file mode 100644 (file)
index 5d2efba..0000000
+++ /dev/null
@@ -1,633 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS ping utility
- * FILE:        apps/net/ping/ping.c
- * PURPOSE:     Network test utility
- * PROGRAMMERS: Casper S. Hornstrup (chorns@users.sourceforge.net)
- * REVISIONS:
- *   CSH  01/09/2000 Created
- */
-
-#include <winsock2.h>
-#include <tchar.h>
-#include <stdarg.h>
-#include <string.h>
-#include <stdio.h>
-
-#ifndef _MSC_VER
-
-/* FIXME: Where should this be? */
-#ifdef CopyMemory
-#undef CopyMemory
-#endif
-#define CopyMemory(Destination, Source, Length) memcpy(Destination, Source, Length);
-
-/* Should be in the header files somewhere (exported by ntdll.dll) */
-long atol(const char *str);
-
-#ifndef __int64
-typedef long long __int64;
-#endif
-
-char * _i64toa(__int64 value, char *string, int radix);
-
-#endif /* _MSC_VER */
-
-#ifdef DBG
-#undef DBG
-#endif
-
-/* General ICMP constants */
-#define ICMP_MINSIZE           8               /* Minimum ICMP packet size */
-#define ICMP_MAXSIZE           65535   /* Maximum ICMP packet size */
-
-/* ICMP message types */
-#define ICMPMSG_ECHOREQUEST    8               /* ICMP ECHO request message */
-#define ICMPMSG_ECHOREPLY      0               /* ICMP ECHO reply message */
-
-#pragma pack(4)
-
-/* IPv4 header structure */
-typedef struct _IPv4_HEADER {
-       unsigned char   IHL:4;
-       unsigned char   Version:4;
-       unsigned char   TOS;
-       unsigned short  Length;
-       unsigned short  Id;
-       unsigned short  FragFlags;
-       unsigned char   TTL;
-       unsigned char   Protocol;
-       unsigned short  Checksum;
-       unsigned int    SrcAddress;
-       unsigned int    DstAddress;
-} IPv4_HEADER, *PIPv4_HEADER;
-
-/* ICMP echo request/reply header structure */
-typedef struct _ICMP_HEADER {
-       unsigned char   Type;
-       unsigned char   Code;
-       unsigned short  Checksum;
-       unsigned short  Id;
-       unsigned short  SeqNum;
-} ICMP_HEADER, *PICMP_HEADER;
-
-typedef struct _ICMP_ECHO_PACKET {
-       ICMP_HEADER   Icmp;
-       LARGE_INTEGER Timestamp;
-} ICMP_ECHO_PACKET, *PICMP_ECHO_PACKET;
-
-#pragma pack(1)
-
-BOOL                InvalidOption;
-BOOL                NeverStop;
-BOOL                ResolveAddresses;
-UINT                PingCount;
-UINT                DataSize;   /* ICMP echo request data size */
-BOOL                DontFragment;
-ULONG               TTLValue;
-ULONG               TOSValue;
-ULONG               Timeout;
-CHAR                TargetName[256];
-SOCKET              IcmpSock;
-SOCKADDR_IN         Target;
-LPSTR               TargetIP;
-FD_SET              Fds;
-TIMEVAL             Timeval;
-UINT                CurrentSeqNum;
-UINT                SentCount;
-UINT                LostCount;
-BOOL                MinRTTSet;
-LARGE_INTEGER       MinRTT;     /* Minimum round trip time in microseconds */
-LARGE_INTEGER       MaxRTT;
-LARGE_INTEGER       SumRTT;
-LARGE_INTEGER       AvgRTT;
-LARGE_INTEGER       TicksPerMs; /* Ticks per millisecond */
-LARGE_INTEGER       TicksPerUs; /* Ticks per microsecond */
-BOOL                UsePerformanceCounter;
-
-#ifdef DBG
-/* Display the contents of a buffer */
-static VOID DisplayBuffer(
-    PVOID Buffer,
-    DWORD Size)
-{
-    UINT i;
-    PCHAR p;
-
-    printf("Buffer (0x%p)  Size (0x%lX).\n", Buffer, Size);
-
-    p = (PCHAR)Buffer;
-    for (i = 0; i < Size; i++) {
-      if (i % 16 == 0) {
-        printf("\n");
-      }
-      printf("%02X ", (p[i]) & 0xFF);
-    }
-}
-#endif /* DBG */
-
-/* Display usage information on screen */
-static VOID Usage(VOID)
-{
-       printf("\nUsage: ping [-t] [-n count] [-l size] [-w timeout] destination-host\n\n");
-       printf("Options:\n");
-       printf("    -t             Ping the specified host until stopped.\n");
-       printf("                   To stop - type Control-C.\n");
-       printf("    -n count       Number of echo requests to send.\n");
-       printf("    -l size        Send buffer size.\n");
-       printf("    -w timeout     Timeout in milliseconds to wait for each reply.\n\n");
-}
-
-/* Reset configuration to default values */
-static VOID Reset(VOID)
-{
-    LARGE_INTEGER PerformanceCounterFrequency;
-
-    NeverStop             = FALSE;
-    ResolveAddresses      = FALSE;
-    PingCount             = 4;
-    DataSize              = 32;
-    DontFragment          = FALSE;
-    TTLValue              = 128;
-    TOSValue              = 0;
-    Timeout               = 1000;
-    UsePerformanceCounter = QueryPerformanceFrequency(&PerformanceCounterFrequency);
-
-    if (UsePerformanceCounter) {
-        /* Performance counters may return incorrect results on some multiprocessor
-           platforms so we restrict execution on the first processor. This may fail
-           on Windows NT so we fall back to GetCurrentTick() for timing */
-        if (SetThreadAffinityMask (GetCurrentThread(), 1) == 0) {
-            UsePerformanceCounter = FALSE;
-        }
-
-        /* Convert frequency to ticks per millisecond */
-        TicksPerMs.QuadPart = PerformanceCounterFrequency.QuadPart / 1000;
-        /* And to ticks per microsecond */
-        TicksPerUs.QuadPart = PerformanceCounterFrequency.QuadPart / 1000000;
-    }
-    if (!UsePerformanceCounter) {
-        /* 1 tick per millisecond for GetCurrentTick() */
-        TicksPerMs.QuadPart = 1;
-        /* GetCurrentTick() cannot handle microseconds */
-        TicksPerUs.QuadPart = 1;
-    }
-}
-
-/* Return ULONG in a string */
-static ULONG GetULONG(LPSTR String)
-{
-    UINT i, Length;
-    ULONG Value;
-
-    i = 0;
-    Length = (UINT)_tcslen(String);
-    while ((i < Length) && ((String[i] < '0') || (String[i] > '9'))) i++;
-    if ((i >= Length) || ((String[i] < '0') || (String[i] > '9'))) {
-        InvalidOption = TRUE;
-        return 0;
-    }
-    Value = (ULONG)atol(&String[i]);
-
-    return Value;
-}
-
-/* Return ULONG in a string. Try next paramter if not successful */
-static ULONG GetULONG2(LPSTR String1, LPSTR String2, PINT i)
-{
-    ULONG Value;
-
-    Value = GetULONG(String1);
-    if (InvalidOption) {
-        InvalidOption = FALSE;
-        if (String2[0] != '-') {
-            Value = GetULONG(String2);
-            if (!InvalidOption)
-                *i += 1;
-        }
-    }
-
-    return Value;
-}
-
-/* Parse command line parameters */
-static BOOL ParseCmdline(int argc, char* argv[])
-{
-    INT i;
-    BOOL ShowUsage;
-    BOOL FoundTarget;
-//#if 1
-//    lstrcpy(TargetName, "127.0.0.1");
-//    PingCount = 1;
-//    return TRUE;
-//#endif
-    if (argc < 2) {
-        ShowUsage = TRUE;
-    } else {
-        ShowUsage = FALSE;
-    }
-    FoundTarget = FALSE;
-    InvalidOption = FALSE;
-
-    for (i = 1; i < argc; i++) {
-        if (argv[i][0] == '-') {
-            switch (argv[i][1]) {
-            case 't': NeverStop = TRUE; break;
-            case 'a': ResolveAddresses = TRUE; break;
-            case 'n': PingCount = GetULONG2(&argv[i][2], argv[i + 1], &i); break;
-            case 'l':
-                DataSize = GetULONG2(&argv[i][2], argv[i + 1], &i);
-                if ((DataSize < 0) || (DataSize > ICMP_MAXSIZE - sizeof(ICMP_ECHO_PACKET))) {
-                    printf("Bad value for option -l, valid range is from 0 to %d.\n",
-                        ICMP_MAXSIZE - sizeof(ICMP_ECHO_PACKET));
-                    return FALSE;
-                }
-                break;
-            case 'f': DontFragment = TRUE; break;
-            case 'i': TTLValue = GetULONG2(&argv[i][2], argv[i + 1], &i); break;
-            case 'v': TOSValue = GetULONG2(&argv[i][2], argv[i + 1], &i); break;
-            case 'w': Timeout  = GetULONG2(&argv[i][2], argv[i + 1], &i); break;
-            default:
-                printf("Bad option %s.\n", argv[i]);
-                Usage();
-                return FALSE;
-            }
-            if (InvalidOption) {
-                printf("Bad option format %s.\n", argv[i]);
-                return FALSE;
-            }
-        } else {
-            if (FoundTarget) {
-                printf("Bad parameter %s.\n", argv[i]);
-                return FALSE;
-            } else {
-                               lstrcpy(TargetName, argv[i]);
-                FoundTarget = TRUE;
-            }
-        }
-    }
-
-    if ((!ShowUsage) && (!FoundTarget)) {
-        printf("Name or IP address of destination host must be specified.\n");
-        return FALSE;
-    }
-
-    if (ShowUsage) {
-        Usage();
-        return FALSE;
-    }
-    return TRUE;
-}
-
-/* Calculate checksum of data */
-static WORD Checksum(PUSHORT data, UINT size)
-{
-    ULONG sum = 0;
-
-    while (size > 1) {
-        sum  += *data++;
-        size -= sizeof(USHORT);
-    }
-
-    if (size)
-        sum += *(UCHAR*)data;
-
-    sum = (sum >> 16) + (sum & 0xFFFF);
-    sum += (sum >> 16);
-
-    return (USHORT)(~sum);
-}
-
-/* Prepare to ping target */
-static BOOL Setup(VOID)
-{
-    WORD     wVersionRequested;
-    WSADATA  WsaData;
-    INT             Status;
-    ULONG    Addr;
-    PHOSTENT phe;
-
-    wVersionRequested = MAKEWORD(2, 2);
-
-    Status = WSAStartup(wVersionRequested, &WsaData);
-    if (Status != 0) {
-        printf("Could not initialize winsock dll.\n");
-        return FALSE;
-    }
-
-    IcmpSock = WSASocket(AF_INET, SOCK_RAW, IPPROTO_ICMP, NULL, 0, 0);
-    if (IcmpSock == INVALID_SOCKET) {
-        printf("Could not create socket (#%d).\n", WSAGetLastError());
-        return FALSE;
-    }
-
-    ZeroMemory(&Target, sizeof(Target));
-    phe = NULL;
-    Addr = inet_addr(TargetName);
-    if (Addr == INADDR_NONE) {
-        phe = gethostbyname(TargetName);
-        if (phe == NULL) {
-            printf("Unknown host %s.\n", TargetName);
-            return FALSE;
-        }
-    }
-
-    if (phe != NULL) {
-        CopyMemory(&Target.sin_addr, phe->h_addr, phe->h_length);
-    } else {
-        Target.sin_addr.s_addr = Addr;
-    }
-
-    if (phe != NULL) {
-               Target.sin_family = phe->h_addrtype;
-    } else {
-        Target.sin_family = AF_INET;
-    }
-
-    TargetIP           = inet_ntoa(Target.sin_addr);
-    CurrentSeqNum      = 0;
-    SentCount          = 0;
-       LostCount               = 0;
-    MinRTT.QuadPart = 0;
-    MaxRTT.QuadPart = 0;
-    SumRTT.QuadPart = 0;
-    MinRTTSet       = FALSE;
-    return TRUE;
-}
-
-/* Close socket */
-static VOID Cleanup(VOID)
-{
-    if (IcmpSock != INVALID_SOCKET)
-        closesocket(IcmpSock);
-
-    WSACleanup();
-}
-
-static VOID QueryTime(PLARGE_INTEGER Time)
-{
-    if (UsePerformanceCounter) {
-        if (QueryPerformanceCounter(Time) == 0) {
-            /* This should not happen, but we fall
-               back to GetCurrentTick() if it does */
-            Time->u.LowPart  = (ULONG)GetTickCount();
-            Time->u.HighPart = 0;
-
-            /* 1 tick per millisecond for GetCurrentTick() */
-            TicksPerMs.QuadPart = 1;
-            /* GetCurrentTick() cannot handle microseconds */
-            TicksPerUs.QuadPart = 1;
-
-            UsePerformanceCounter = FALSE;
-        }
-    } else {
-        Time->u.LowPart  = (ULONG)GetTickCount();
-        Time->u.HighPart = 0;
-    }
-}
-
-static VOID TimeToMsString(LPSTR String, LARGE_INTEGER Time)
-{
-    CHAR          Convstr[40];
-    LARGE_INTEGER LargeTime;
-
-    LargeTime.QuadPart = Time.QuadPart / TicksPerMs.QuadPart;
-
-    _i64toa(LargeTime.QuadPart, Convstr, 10);
-       strcpy(String, Convstr);
-    strcat(String, "ms");
-}
-
-/* Locate the ICMP data and print it. Returns TRUE if the packet was good,
-   FALSE if not */
-static BOOL DecodeResponse(PCHAR buffer, UINT size, PSOCKADDR_IN from)
-{
-    PIPv4_HEADER      IpHeader;
-    PICMP_ECHO_PACKET Icmp;
-       UINT              IphLength;
-    CHAR              Time[100];
-    LARGE_INTEGER     RelativeTime;
-    LARGE_INTEGER     LargeTime;
-    CHAR              Sign[2];
-
-    IpHeader = (PIPv4_HEADER)buffer;
-
-    IphLength = IpHeader->IHL * 4;
-
-    if (size  < IphLength + ICMP_MINSIZE) {
-#ifdef DBG
-        printf("Bad size (0x%X < 0x%X)\n", size, IphLength + ICMP_MINSIZE);
-#endif /* DBG */
-        return FALSE;
-    }
-
-    Icmp = (PICMP_ECHO_PACKET)(buffer + IphLength);
-
-    if (Icmp->Icmp.Type != ICMPMSG_ECHOREPLY) {
-#ifdef DBG
-        printf("Bad ICMP type (0x%X should be 0x%X)\n", Icmp->Icmp.Type, ICMPMSG_ECHOREPLY);
-#endif /* DBG */
-        return FALSE;
-    }
-
-    if (Icmp->Icmp.Id != (USHORT)GetCurrentProcessId()) {
-#ifdef DBG
-        printf("Bad ICMP id (0x%X should be 0x%X)\n", Icmp->Icmp.Id, (USHORT)GetCurrentProcessId());
-#endif /* DBG */
-        return FALSE;
-    }
-
-    QueryTime(&LargeTime);
-
-    RelativeTime.QuadPart = (LargeTime.QuadPart - Icmp->Timestamp.QuadPart);
-
-    if ((RelativeTime.QuadPart / TicksPerMs.QuadPart) < 1) {
-        strcpy(Sign, "<");
-        strcpy(Time, "1ms");
-    } else {
-        strcpy(Sign, "=");
-        TimeToMsString(Time, RelativeTime);
-    }
-
-
-    printf("Reply from %s: bytes=%d time%s%s TTL=%d\n", inet_ntoa(from->sin_addr),
-      size - IphLength - sizeof(ICMP_ECHO_PACKET), Sign, Time, IpHeader->TTL);
-    if (RelativeTime.QuadPart < MinRTT.QuadPart || !MinRTTSet) {
-           MinRTT.QuadPart = RelativeTime.QuadPart;
-        MinRTTSet = TRUE;
-    }
-       if (RelativeTime.QuadPart > MaxRTT.QuadPart)
-           MaxRTT.QuadPart = RelativeTime.QuadPart;
-
-    SumRTT.QuadPart += RelativeTime.QuadPart;
-
-       return TRUE;
-}
-
-/* Send and receive one ping */
-static BOOL Ping(VOID)
-{
-    INT                 Status;
-    SOCKADDR            From;
-    INT                 Length;
-    PVOID               Buffer;
-    UINT                Size;
-    PICMP_ECHO_PACKET   Packet;
-
-    /* Account for extra space for IP header when packet is received */
-    Size   = DataSize + 128;
-    Buffer = GlobalAlloc(0, Size);
-    if (!Buffer) {
-        printf("Not enough free resources available.\n");
-        return FALSE;
-    }
-
-    ZeroMemory(Buffer, Size);
-    Packet = (PICMP_ECHO_PACKET)Buffer;
-
-    /* Assemble ICMP echo request packet */
-    Packet->Icmp.Type     = ICMPMSG_ECHOREQUEST;
-    Packet->Icmp.Code     = 0;
-    Packet->Icmp.Id          = (USHORT)GetCurrentProcessId();
-    Packet->Icmp.SeqNum   = (USHORT)CurrentSeqNum;
-    Packet->Icmp.Checksum = 0;
-
-    /* Timestamp is part of data area */
-    QueryTime(&Packet->Timestamp);
-
-    CopyMemory(Buffer, &Packet->Icmp, sizeof(ICMP_ECHO_PACKET) + DataSize);
-    /* Calculate checksum for ICMP header and data area */
-    Packet->Icmp.Checksum = Checksum((PUSHORT)&Packet->Icmp, sizeof(ICMP_ECHO_PACKET) + DataSize);
-
-    CurrentSeqNum++;
-
-       /* Send ICMP echo request */
-
-    FD_ZERO(&Fds);
-    FD_SET(IcmpSock, &Fds);
-    Timeval.tv_sec  = Timeout / 1000;
-    Timeval.tv_usec = Timeout % 1000;
-    Status = select(0, NULL, &Fds, NULL, &Timeval);
-    if ((Status != SOCKET_ERROR) && (Status != 0)) {
-
-#ifdef DBG
-        printf("Sending packet\n");
-        DisplayBuffer(Buffer, sizeof(ICMP_ECHO_PACKET) + DataSize);
-        printf("\n");
-#endif /* DBG */
-
-        Status = sendto(IcmpSock, Buffer, sizeof(ICMP_ECHO_PACKET) + DataSize,
-            0, (SOCKADDR*)&Target, sizeof(Target));
-        SentCount++;
-    }
-    if (Status == SOCKET_ERROR) {
-        if (WSAGetLastError() == WSAEHOSTUNREACH) {
-            printf("Destination host unreachable.\n");
-        } else {
-            printf("Could not transmit data (%d).\n", WSAGetLastError());
-        }
-        GlobalFree(Buffer);
-        return FALSE;
-    }
-
-    /* Expect to receive ICMP echo reply */
-    FD_ZERO(&Fds);
-    FD_SET(IcmpSock, &Fds);
-    Timeval.tv_sec  = Timeout / 1000;
-    Timeval.tv_usec = Timeout % 1000;
-
-    Status = select(0, &Fds, NULL, NULL, &Timeval);
-    if ((Status != SOCKET_ERROR) && (Status != 0)) {
-        Length = sizeof(From);
-        Status = recvfrom(IcmpSock, Buffer, Size, 0, &From, &Length);
-
-#ifdef DBG
-        printf("Received packet\n");
-        DisplayBuffer(Buffer, Status);
-        printf("\n");
-#endif /* DBG */
-    }
-    if (Status == SOCKET_ERROR) {
-        if (WSAGetLastError() != WSAETIMEDOUT) {
-            printf("Could not receive data (%d).\n", WSAGetLastError());
-            GlobalFree(Buffer);
-            return FALSE;
-        }
-        Status = 0;
-    }
-
-    if (Status == 0) {
-        printf("Request timed out.\n");
-        LostCount++;
-        GlobalFree(Buffer);
-        return TRUE;
-    }
-
-    if (!DecodeResponse(Buffer, Status, (PSOCKADDR_IN)&From)) {
-        /* FIXME: Wait again as it could be another ICMP message type */
-        printf("Request timed out (incomplete datagram received).\n");
-        LostCount++;
-    }
-
-    GlobalFree(Buffer);
-    return TRUE;
-}
-
-
-/* Program entry point */
-int main(int argc, char* argv[])
-{
-    UINT Count;
-    CHAR MinTime[20];
-    CHAR MaxTime[20];
-    CHAR AvgTime[20];
-
-    Reset();
-
-    if ((ParseCmdline(argc, argv)) && (Setup())) {
-
-        printf("\nPinging %s [%s] with %d bytes of data:\n\n",
-            TargetName, TargetIP, DataSize);
-
-               Count = 0;
-               while ((NeverStop) || (Count < PingCount)) {
-                       Ping();
-                       Sleep(Timeout);
-                       Count++;
-               };
-
-        Cleanup();
-
-               /* Calculate avarage round trip time */
-        if ((SentCount - LostCount) > 0) {
-            AvgRTT.QuadPart = SumRTT.QuadPart / (SentCount - LostCount);
-        } else {
-            AvgRTT.QuadPart = 0;
-        }
-
-        /* Calculate loss percent */
-        if (LostCount > 0) {
-            Count = (SentCount * 100) / LostCount;
-        } else {
-            Count = 0;
-        }
-
-        if (!MinRTTSet)
-            MinRTT = MaxRTT;
-
-        TimeToMsString(MinTime, MinRTT);
-        TimeToMsString(MaxTime, MaxRTT);
-        TimeToMsString(AvgTime, AvgRTT);
-
-        /* Print statistics */
-        printf("\nPing statistics for %s:\n", TargetIP);
-        printf("    Packets: Sent = %d, Received = %d, Lost = %d (%d%% loss),\n",
-            SentCount, SentCount - LostCount, LostCount, Count);
-        printf("Approximate round trip times in milli-seconds:\n");
-        printf("    Minimum = %s, Maximum = %s, Average = %s\n",
-            MinTime, MaxTime, AvgTime);
-    }
-       return 0;
-}
-
-/* EOF */
diff --git a/reactos/apps/utils/net/ping/ping.rc b/reactos/apps/utils/net/ping/ping.rc
deleted file mode 100644 (file)
index e856080..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-/* $Id$ */
-
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS TCP/IPv4 Win32 Ping\0"
-#define REACTOS_STR_INTERNAL_NAME      "ping\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "ping.exe\0"
-#define REACTOS_STR_ORIGINAL_COPYRIGHT "Casper S. Hornstrup (chorns@users.sourceforge.net)\0"
-#include <reactos/version.rc>
diff --git a/reactos/apps/utils/net/ping/ping.xml b/reactos/apps/utils/net/ping/ping.xml
deleted file mode 100644 (file)
index d4ec450..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-<module name="ping" type="win32cui" installbase="system32" installname="ping.exe">
-       <include base="ping">.</include>
-       <define name="__USE_W32API" />
-       <define name="__USE_W32_SOCKETS" />
-       <define name="_WIN32_IE">0x600</define>
-       <define name="_WIN32_WINNT">0x501</define>
-       <library>kernel32</library>
-       <library>ws2_32</library>
-       <file>ping.c</file>
-       <file>ping.rc</file>
-</module>
diff --git a/reactos/apps/utils/net/roshttpd/common/list.cpp b/reactos/apps/utils/net/roshttpd/common/list.cpp
deleted file mode 100644 (file)
index 29c6912..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        list.cpp
- * PURPOSE:     A doubly linked list implementation
- * PROGRAMMERS: Casper S. Hornstrup (chorns@users.sourceforge.net)
- * REVISIONS:
- *   CSH  01/09/2000 Created
- * NOTES:       The linked list does it's own heap management for
- *              better performance
- * TODO:        - InsertBefore(), InsertAfter(), Move()
- */
-#include <windows.h>
-#include <list.h>
-
-// **************************** CListNode ****************************
-
-HANDLE CListNode::hHeap = NULL;
-INT    CListNode::nRef = 0;
-
-// Default constructor
-CListNode::CListNode()
-{
-       Element = NULL;
-       Next = NULL;
-       Prev = NULL;
-}
-
-// Constructor with element and next as starter values
-CListNode::CListNode(PVOID element, CListNode *next, CListNode *prev)
-{
-       Element = element;
-       Next = next;
-       Prev = prev;
-}
-
-void* CListNode::operator new(/*size_t*/ UINT size)
-{
-    PVOID p;
-    if (hHeap == NULL) {
-        SYSTEM_INFO inf;
-        GetSystemInfo(&inf);
-        hHeap = HeapCreate(0, inf.dwAllocationGranularity, 0);
-    }
-    if ((p = HeapAlloc(hHeap, 0, size)) != NULL)
-        nRef++;
-    return p;
-}
-
-VOID CListNode::operator delete(void* p)
-{
-    if (HeapFree(hHeap, 0, p) != FALSE)
-        nRef--;
-    if (nRef == 0) {
-        HeapDestroy(hHeap);
-        hHeap = NULL;
-       }
-}
-
-// Set element
-VOID CListNode::SetElement(PVOID element)
-{
-       Element = element;
-}
-
-// Set pointer to next node in list
-VOID CListNode::SetNext(CListNode *next)
-{
-       Next = next;
-}
-
-// Set pointer to previous node in list
-VOID CListNode::SetPrev(CListNode *prev)
-{
-       Prev = prev;
-}
-
-// Get element of node
-PVOID CListNode::GetElement()
-{
-       return Element;
-}
-
-// Get pointer to next node in list
-CListNode *CListNode::GetNext()
-{
-       return Next;
-}
-
-// Get pointer to previous node in list
-CListNode *CListNode::GetPrev()
-{
-       return Prev;
-}
diff --git a/reactos/apps/utils/net/roshttpd/common/roshttpd.rc b/reactos/apps/utils/net/roshttpd/common/roshttpd.rc
deleted file mode 100644 (file)
index b11ae96..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-/* $Id$ */
-
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS HTTP Win32 Server\0"
-#define REACTOS_STR_INTERNAL_NAME      "roshttpd\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "roshttpd.exe\0"
-#include <reactos/version.rc>
diff --git a/reactos/apps/utils/net/roshttpd/common/socket.cpp b/reactos/apps/utils/net/roshttpd/common/socket.cpp
deleted file mode 100644 (file)
index 4f798cd..0000000
+++ /dev/null
@@ -1,344 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        socket.cpp
- * PURPOSE:     Socket classes
- * PROGRAMMERS: Casper S. Hornstrup (chorns@users.sourceforge.net)
- * REVISIONS:
- *   CSH  01/09/2000 Created
- */
-#include <string.h>
-#include <error.h>
-#include <socket.h>
-#include <iterator.h>
-
-// ***************************** CSocket *****************************
-
-// Default constructor
-CSocket::CSocket()
-{
-    Active = FALSE;
-       Event  = WSA_INVALID_EVENT;
-       Events = 0;
-       Socket = INVALID_SOCKET;
-
-       // INET address family
-       SockAddrIn.sin_family = AF_INET;
-
-    // Any address will do
-    SockAddrIn.sin_addr.s_addr = INADDR_ANY;
-
-    // Convert to network ordering 
-    SockAddrIn.sin_port = htons(0);
-}
-
-// Default destructor
-CSocket::~CSocket()
-{
-}
-
-// Return winsock socket handle
-SOCKET CSocket::GetSocket()
-{
-       return Socket;
-}
-
-// Set winsock socket handle
-VOID CSocket::SetSocket(SOCKET socket)
-{
-       Socket = socket;
-}
-       
-
-// Return socket address
-SOCKADDR_IN CSocket::GetSockAddrIn()
-{
-       return SockAddrIn;
-}
-
-// Set socket address
-VOID CSocket::SetSockAddrIn(SOCKADDR_IN sockaddrin)
-{
-       SockAddrIn = sockaddrin;
-}
-
-// Associate winsock events with socket
-VOID CSocket::SetEvents(LONG lEvents)
-{
-       if (Event == WSA_INVALID_EVENT) {
-               // Create socket event
-               Event = WSACreateEvent();
-               if (Event == WSA_INVALID_EVENT)
-                       throw ESocketOpen(TS("Unable to create event."));
-       }
-       
-       if (lEvents != Events) {
-               // Associate network events with socket
-               if (WSAEventSelect(Socket, Event, lEvents) == SOCKET_ERROR)
-                       throw ESocketOpen(TS("Unable to select socket events."));
-               Events = lEvents;
-       }
-}
-
-// Return associated winsock events
-LONG CSocket::GetEvents()
-{
-       return Events;
-}
-
-// Open socket
-VOID CSocket::Open()
-{
-}
-
-// Close socket
-VOID CSocket::Close()
-{
-}
-
-
-// *********************** CServerClientSocket ***********************
-
-// Constructor with serversocket as parameter
-CServerClientSocket::CServerClientSocket(LPCServerSocket lpServerSocket)
-{
-       ServerSocket = lpServerSocket;
-}
-
-// Transmit data to socket
-INT CServerClientSocket::Transmit( LPSTR lpsBuffer, UINT nLength)
-{
-    return send(Socket, lpsBuffer, nLength, 0);
-}
-
-// Send a string to socket
-INT CServerClientSocket::SendText( LPSTR lpsText)
-{
-    static CHAR crlf[3] = {0x0D, 0x0A, 0x00};
-       INT nCount;
-
-    nCount = Transmit(lpsText, strlen(lpsText));
-       nCount += Transmit(crlf, strlen(crlf));
-       return nCount;
-}
-
-// Receive data from socket
-INT CServerClientSocket::Receive(LPSTR lpsBuffer, UINT nLength)
-{
-       return recv(Socket, lpsBuffer, nLength, 0);
-}
-
-// Process winsock messages if any
-VOID CServerClientSocket::MessageLoop()
-{
-       UINT nStatus;
-    WSANETWORKEVENTS NetworkEvents;
-
-    nStatus = WSAWaitForMultipleEvents(1, &Event, FALSE, 0, FALSE);
-    if ((nStatus == 0) && (WSAEnumNetworkEvents(Socket, Event, &NetworkEvents) != SOCKET_ERROR)) {
-        if ((NetworkEvents.lNetworkEvents & FD_READ) != 0) {
-                       OnRead();
-               } 
-        if ((NetworkEvents.lNetworkEvents & FD_CLOSE) != 0) {
-                       OnClose();
-        }
-    }
-}
-
-// Return server socket that own this socket
-LPCServerSocket CServerClientSocket::GetServerSocket()
-{
-       return ServerSocket;
-}
-
-
-// *********************** CServerClientThread ***********************
-
-CServerClientThread::CServerClientThread(LPCServerClientSocket lpSocket)
-{
-       ClientSocket = lpSocket;
-}
-
-CServerClientThread::~CServerClientThread()
-{
-       ClientSocket->GetServerSocket()->RemoveClient((LPCServerClientThread) this);
-}
-
-
-// ************************** CServerSocket ************************** 
-
-// Default constructor
-CServerSocket::CServerSocket()
-{
-}
-
-// Default destructor
-CServerSocket::~CServerSocket()
-{
-       if (Active)
-               Close();
-}
-
-// Open server socket so clients can connect
-VOID CServerSocket::Open()
-{
-       assert(!Active);
-       
-       // Convert to network ordering 
-       SockAddrIn.sin_port = htons(Port);
-
-       if (Socket == INVALID_SOCKET) {
-               // Create socket
-               Socket = socket(AF_INET, SOCK_STREAM, 0);
-               if (Socket == INVALID_SOCKET)
-               throw ESocketOpen(TS("Unable to allocate a socket."));
-       }
-
-       // Associate an address with server socket
-       if (bind(Socket, (struct sockaddr FAR *) &SockAddrIn, sizeof(SockAddrIn)) == SOCKET_ERROR)
-               throw ESocketOpen(TS("Unable to associate address with socket."));
-
-       // Listen for incoming connections
-       if (listen(Socket, MAX_PENDING_CONNECTS) != 0)
-               throw ESocketOpen(TS("Unable to listen on socket."));
-
-       // Associate network events with socket
-       SetEvents(FD_ACCEPT | FD_CONNECT | FD_CLOSE);
-
-       Active = TRUE;
-}
-
-// Close server socket and all current connections
-VOID CServerSocket::Close()
-{
-       assert(Active);
-
-       if (Event != WSA_INVALID_EVENT) {
-               // Tell winsock not to notify us about any events
-               if (WSAEventSelect(Socket, Event, 0) == SOCKET_ERROR)
-                       throw ESocketClose(TS("Unable to select socket events."));
-
-               if (!WSACloseEvent(Event))
-                       throw ESocketClose(TS("Unable to close socket event."));
-               Event = WSA_INVALID_EVENT;
-       }
-       
-       CIterator<LPCServerClientThread> *i = Connections.CreateIterator();
-
-       // Terminate and free all client threads
-       for (i->First(); !i->IsDone(); i->Next()) {
-               //i->CurrentItem()->Terminate();
-               delete i->CurrentItem();
-       }
-       delete i;
-       Connections.RemoveAll();
-
-       closesocket(Socket);
-       Socket = INVALID_SOCKET;
-
-       Active = FALSE;
-}
-
-// Set port number to listen on
-VOID CServerSocket::SetPort(UINT nPort)
-{
-       assert(!Active);
-
-       Port = nPort;
-}
-
-// Process messages from winsock if any
-VOID CServerSocket::MessageLoop()
-{
-    UINT nStatus;
-       INT nAddrLen;
-       SOCKET ClientSocket;
-       SOCKADDR_IN SockAddrIn;
-    WSANETWORKEVENTS NetworkEvents;
-       LPCServerClientSocket lpClient;
-       LPCServerClientThread lpThread;
-       
-    nStatus = WSAWaitForMultipleEvents(1, &Event, FALSE, 0, FALSE);
-    if ((nStatus == 0) && (WSAEnumNetworkEvents(Socket, Event, &NetworkEvents) != SOCKET_ERROR)) {
-        if ((NetworkEvents.lNetworkEvents & FD_ACCEPT) != 0) {
-                       lpClient = OnGetSocket(this);
-                       nAddrLen = sizeof(SockAddrIn);
-                       ClientSocket = accept(Socket, (SOCKADDR *) &SockAddrIn, &nAddrLen);
-                       if (ClientSocket != INVALID_SOCKET) {
-                               // Set socket handle
-                               lpClient->SetSocket(ClientSocket);
-                               // Set socket address
-                               lpClient->SetSockAddrIn(SockAddrIn);
-                               // Set winsock events
-                               lpClient->SetEvents(FD_READ | FD_CLOSE);
-                               // Create client connection thread
-                               lpThread = OnGetThread(lpClient);
-                               // Add client thread to connection list
-                               InsertClient(lpThread);
-                               // Call OnAccept event handler
-                               OnAccept(lpThread);
-                       } else {
-                               delete lpClient;
-                               lpClient = NULL;
-                               throw ESocketOpen(TS("No more sockets available."));
-                       }
-               }
-        /*if ((NetworkEvents.lNetworkEvents & FD_CONNECT) != 0) {
-        }
-        if ((NetworkEvents.lNetworkEvents & FD_CLOSE) != 0) {
-        }*/
-    }
-}
-
-// Insert client into connection list
-VOID CServerSocket::InsertClient(LPCServerClientThread lpClient)
-{
-       Connections.Insert(lpClient);
-}
-
-// Remove client from connection list
-VOID CServerSocket::RemoveClient(LPCServerClientThread lpClient)
-{
-       Connections.Remove(lpClient);
-}
-
-// OnGetSocket event handler
-LPCServerClientSocket CServerSocket::OnGetSocket(LPCServerSocket lpServerSocket)
-{
-       return NULL;
-}
-
-// OnGetThread event handler
-LPCServerClientThread CServerSocket::OnGetThread(LPCServerClientSocket lpSocket)
-{
-       return NULL;
-}
-
-
-// Initialize WinSock DLL
-VOID InitWinsock()
-{
-    WORD wVersionRequested;
-    WSADATA wsaData;
-
-    wVersionRequested = MAKEWORD(2, 0);
-    if (WSAStartup(wVersionRequested, &wsaData) != 0)
-        // Return FALSE as we couldn't find a usable WinSock DLL
-               throw ESocketWinsock(TS("Unable to initialize winsock dll."));
-   
-    /* Confirm that the WinSock DLL supports 2.0 */
-    if (LOBYTE(wsaData.wVersion) != 2 || HIBYTE(wsaData.wVersion) != 0) {
-        // We couldn't find a usable winsock dll
-        WSACleanup();
-               throw ESocketDll(TS("Winsock dll version is not 2.0 or higher."));
-    }
-}
-
-// Deinitialize WinSock DLL
-VOID DeinitWinsock()
-{
-       if (WSACleanup() != 0)
-               throw ESocketWinsock(TS("Unable to deinitialize winsock dll."));
-}
diff --git a/reactos/apps/utils/net/roshttpd/common/thread.cpp b/reactos/apps/utils/net/roshttpd/common/thread.cpp
deleted file mode 100644 (file)
index 3f54c1a..0000000
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        thread.cpp
- * PURPOSE:     Generic thread class
- * PROGRAMMERS: Casper S. Hornstrup (chorns@users.sourceforge.net)
- * REVISIONS:
- *   CSH  01/09/2000 Created
- */
-#include <debug.h>
-#include <assert.h>
-#include <windows.h>
-#include <thread.h>
-
-// This is the thread entry code
-DWORD WINAPI ThreadEntry(LPVOID parameter)
-{
-       ThreadData *p = (ThreadData*) parameter;
-
-    p->ClassPtr->Execute();
-
-       SetEvent(p->hFinished);
-       return 0;
-}
-
-// Default constructor
-CThread::CThread()
-{
-       bTerminated = FALSE;
-       // Points to the class that is executed within thread
-       Data.ClassPtr = this;
-       // Create synchronization event
-       Data.hFinished = CreateEvent(NULL, TRUE, FALSE, NULL);
-
-       // FIXME: Do some error handling
-       assert(Data.hFinished != NULL);
-
-       // Create thread
-    hThread = CreateThread(NULL, 0, (LPTHREAD_START_ROUTINE)ThreadEntry, &Data, 0, &dwThreadId);
-
-       // FIXME: Do some error handling
-       assert(hThread != NULL);
-}
-
-// Default destructor
-CThread::~CThread()
-{
-       if ((hThread != NULL) && (Data.hFinished != NULL)) {
-               if (!bTerminated)
-                       Terminate();
-               WaitForSingleObject(Data.hFinished, INFINITE);
-               CloseHandle(Data.hFinished);
-               CloseHandle(hThread);
-               hThread = NULL;
-       }
-}
-
-// Execute thread code
-void CThread::Execute()
-{
-       while (!bTerminated) Sleep(0);
-}
-
-// Post a message to the thread's message queue
-BOOL CThread::PostMessage(UINT Msg, WPARAM wParam, LPARAM lParam)
-{
-       return PostThreadMessage(dwThreadId, Msg, wParam, lParam);
-}
-
-// Gracefully terminate thread
-void CThread::Terminate()
-{
-       bTerminated = TRUE;
-}
-
-// Returns TRUE if thread is terminated, FALSE if not
-BOOL CThread::Terminated()
-{
-       return bTerminated;
-}
diff --git a/reactos/apps/utils/net/roshttpd/config.cpp b/reactos/apps/utils/net/roshttpd/config.cpp
deleted file mode 100644 (file)
index f71df02..0000000
+++ /dev/null
@@ -1,131 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        config.cpp
- * PURPOSE:     Daemon configuration
- * PROGRAMMERS: Casper S. Hornstrup (chorns@users.sourceforge.net)
- * REVISIONS:
- *   CSH  01/09/2000 Created
- */
-#include <new>
-#include <stdlib.h>
-#include <string.h>
-#include <config.h>
-#include <tchar.h>
-
-using namespace std;
-
-LPCConfig pConfiguration;
-LPCHttpDaemonThread pDaemonThread;
-
-// Default constructor
-CConfig::CConfig()
-{
-       Reset();
-}
-
-// Default destructor
-CConfig::~CConfig()
-{
-       Clear();
-}
-
-// Clear configuration
-void CConfig::Reset()
-{
-       MainBase = NULL;
-       HttpBase = NULL;
-       DefaultResources.RemoveAll();
-}
-
-// Create default configuration. Can throw bad_alloc
-void CConfig::Default()
-{
-       Clear();
-       MainBase = (LPWSTR)_wcsdup(dcfgMainBase);
-       HttpBase = _strdup(dcfgHttpBase);
-
-       LPSTR lpsStr;
-       try {
-               lpsStr = _strdup(dcfgDefaultResource);
-               DefaultResources.Insert(lpsStr);
-       } catch (bad_alloc e) {
-               free((void *)lpsStr);
-               Clear();
-               throw;
-       }
-
-    Port = dcfgDefaultPort;
-}
-
-// Clear configuration
-void CConfig::Clear()
-{
-       if (MainBase != NULL)
-               free((void *)MainBase);
-       if (HttpBase != NULL)
-               free((void *)HttpBase);
-
-       // Free memory for all strings
-       CIterator<LPSTR> *i = DefaultResources.CreateIterator();
-       for (i->First(); !i->IsDone(); i->Next())
-               free((void *)i->CurrentItem());
-       delete i;
-
-       Reset();
-}
-
-// Load configuration
-BOOL CConfig::Load()
-{
-    Default();
-       return TRUE;
-}
-
-// Save configuration
-BOOL CConfig::Save()
-{
-    return TRUE;
-}
-
-// Return MainBase
-LPWSTR CConfig::GetMainBase()
-{
-       return MainBase;
-}
-
-// Set MainBase
-void CConfig::SetMainBase(LPWSTR lpwsMainBase)
-{
-       MainBase = lpwsMainBase;
-}
-
-// Return HttpBase
-LPSTR CConfig::GetHttpBase()
-{
-       return HttpBase;
-}
-
-// Set HttpBase
-void CConfig::SetHttpBase(LPSTR lpsHttpBase)
-{
-       HttpBase = lpsHttpBase;
-}
-
-// Return DefaultResources
-CList<LPSTR>* CConfig::GetDefaultResources()
-{
-       return &DefaultResources;
-}
-
-// Return bound port
-USHORT CConfig::GetPort()
-{
-    return Port;
-}
-
-// Set port
-VOID CConfig::SetPort(USHORT wPort)
-{
-    Port = wPort;
-}
diff --git a/reactos/apps/utils/net/roshttpd/error.cpp b/reactos/apps/utils/net/roshttpd/error.cpp
deleted file mode 100644 (file)
index 2dfeeec..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        error.cpp
- * PURPOSE:     Error reporting
- * PROGRAMMERS: Casper S. Hornstrup (chorns@users.sourceforge.net)
- * REVISIONS:
- *   CSH  01/09/2000 Created
- */
-#include <error.h>
-#include <stdio.h>
-
-void ReportErrorStr(LPTSTR lpsText)
-{
-    wprintf((wchar_t*)lpsText);
-}
diff --git a/reactos/apps/utils/net/roshttpd/http.cpp b/reactos/apps/utils/net/roshttpd/http.cpp
deleted file mode 100644 (file)
index 07250ea..0000000
+++ /dev/null
@@ -1,380 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        http.cpp
- * PURPOSE:     HTTP 1.1 parser engine
- * PROGRAMMERS: Casper S. Hornstrup (chorns@users.sourceforge.net)
- * REVISIONS:
- *   CSH  01/09/2000 Created
- * TODO:        - Implement message-body
- *              - Implement more generel-header entries
- *              - Implement more request-header entries
- *              - Implement more entity-header entries
- */
-#include <debug.h>
-#include <iostream.h>
-#include <string.h>
-#include <http.h>
-
-CHAR MethodTable[NUMMETHODS][8] = {"OPTIONS", "GET", "HEAD", "POST", "PUT", 
-    "DELETE", "TRACE"};
-
-CHAR GenerelTable[NUMGENERELS][18] = {"Cache-Control", "Connection", "Date", "Pragma", 
-    "Transfer-Encoding", "Upgrade", "Via"};
-
-CHAR RequestTable[NUMREQUESTS][20] = {"Accept", "Accept-Charset", "Accept-Encoding",
-    "Accept-Language", "Authorization", "From", "Host", "If-Modified-Since", "If-Match",
-    "If-None-Match", "If-Range", "If-Unmodified-Since", "Max-Forwards",
-    "Proxy-Authorization", "Range", "Referer", "User-Agent"};
-
-CHAR EntityTable[NUMENTITIES][17] = {"Allow", "Content-Base", "Content-Encoding",
-    "Content-Language", "Content-Length", "Content-Location", "Content-MD5",
-    "Content-Range", "Content-Type", "ETag", "Expires", "Last-Modified"};
-
-// *************************** CHttpParser ***************************
-
-// Default constructor
-CHttpParser::CHttpParser()
-{
-    nHead = 0;
-    nTail = 0;
-}
-
-// Default destructor
-CHttpParser::~CHttpParser()
-{
-}
-
-// Returns TRUE if a complete HTTP message is in buffer
-BOOL CHttpParser::Complete()
-{
-    UINT nTmp;
-
-    /*DPRINT("--1:-%d---\n", sBuffer[nHead-2]);
-    DPRINT("--2:-%d---\n", sBuffer[nHead-1]);
-
-    sBuffer[nHead] = '!';
-    sBuffer[nHead+1] = 0;
-    DPRINT("Examining buffer: (Head: %d, Tail: %d)\n", nHead, nTail);
-    DPRINT("%s\n", (LPSTR)&sBuffer[nTail]);*/
-
-    nTmp = nTail;
-    if (!Parse()) {
-        if (!bUnknownMethod)
-            nTail = nTmp;
-        return FALSE;
-    } else
-        return TRUE;
-}
-
-
-// Read a character from buffer
-BOOL CHttpParser::ReadChar(LPSTR lpsStr)
-{
-    if (nTail <= nHead) {
-        if (nTail != nHead) {
-            lpsStr[0] = sBuffer[nTail];
-            nTail++;
-            return TRUE;
-        } else {
-            lpsStr[0] = 0;
-            return FALSE;
-        }
-    } else {
-        if (nTail == sizeof(sBuffer))
-            nTail = 0;
-        if (nTail != nHead) {
-            lpsStr[0] = sBuffer[nTail];
-            nTail++;
-            return TRUE;
-        } else {
-            lpsStr[0] = 0;
-            return FALSE;
-        }
-    }
-}
-
-// Peek at a character in the buffer
-BOOL CHttpParser::PeekChar(LPSTR lpsStr)
-{
-    UINT nFakeTail;
-    
-    if (nTail == sizeof(sBuffer))
-        nFakeTail = 0;
-    else
-        nFakeTail = nTail;
-    if (nFakeTail != nHead) {
-        lpsStr[0] = sBuffer[nFakeTail];
-        return TRUE;
-    } else {
-        lpsStr[0] = 0;
-        return FALSE;
-    }
-}
-
-// Read a string from buffer. Only A-Z, a-z, 0-9 and '-' are valid characters
-BOOL CHttpParser::ReadString(LPSTR lpsStr, UINT nLength)
-{
-    UINT i = 0;
-    CHAR sTmp;
-    
-    while (PeekChar(&sTmp)) {
-        if (((sTmp >= 'A') && (sTmp <= 'Z')) || ((sTmp >= 'a') && (sTmp <= 'z')) ||
-            ((sTmp >= '0') && (sTmp <= '9')) || (sTmp == '-')) { 
-            if (i >= (nLength - 1)) {
-                lpsStr[0] = 0;
-                return FALSE;
-            }
-            ReadChar(&sTmp);
-            lpsStr[i] = sTmp;
-            i++;
-        } else {
-            lpsStr[i] = 0;
-            return TRUE;
-        }
-    }
-    lpsStr[0] = 0;
-    return FALSE;
-}
-
-// Read a string from buffer. Stop if SP or CR is found or when there are no more 
-// characters
-BOOL CHttpParser::ReadSpecial(LPSTR lpsStr, UINT nLength)
-{
-    UINT i = 0;
-    CHAR sTmp;
-    while (PeekChar(&sTmp) && (sTmp != ' ') && (sTmp != 13)) {
-        if (i >= (nLength - 1)) {
-            lpsStr[nLength - 1] = 0;
-            return FALSE;
-        }
-        ReadChar(&sTmp);
-        lpsStr[i] = sTmp;
-        i++;
-    }
-    lpsStr[i] = 0;
-    return TRUE;
-}
-
-// Skip until "sCh" is found
-VOID CHttpParser::Skip(CHAR sCh)
-{
-    CHAR sTmp;
-
-    while (PeekChar(&sTmp) && (sTmp != sCh))
-        ReadChar(&sTmp);
-}
-
-// Return TRUE if sCh is the next character
-BOOL CHttpParser::Expect(CHAR sCh)
-{
-    CHAR sTmp;
-
-    if (PeekChar(&sTmp)) {
-        if (sTmp == sCh) {
-            ReadChar(&sTmp);
-            return TRUE;
-        }
-    }
-    return FALSE;
-}
-
-// Return TRUE if CRLF are the next characters
-BOOL CHttpParser::ExpectCRLF()
-{
-    return (Expect(13) && Expect(10));
-}
-
-// Request = RequestLine | *( GenerelHeader | RequestHeader | EntityHeader ) 
-//           CRLF [ MessageBody ]
-BOOL CHttpParser::Parse()
-{
-    BOOL bStatus;
-
-
-    CHAR ch;
-
-    if (RequestLine()) {
-        do {
-            if (!ReadString(sHeader, sizeof(sHeader)))
-                break;
-            bStatus = (GenerelHeader());
-            bStatus = (RequestHeader() || bStatus);
-            bStatus = (EntityHeader() || bStatus);
-        } while (bStatus);
-        // CRLF
-        if (!ExpectCRLF())
-            return FALSE;
-        MessageBody();
-        return TRUE;
-    }
-    return FALSE;
-}
-
-// RequestLine = Method SP RequestURI SP HTTP-Version CRLF
-BOOL CHttpParser::RequestLine()
-{
-    CHAR sCh;
-    UINT i;
-
-    bUnknownMethod = FALSE;
-
-    // RFC 2068 states that servers SHOULD ignore any empty nine(s) received where a 
-    // Request-Line is expected
-    while (PeekChar(&sCh) && ((sCh == 13) || (sCh == 10)));
-    
-    if (!ReadString(sMethod, sizeof(sMethod)))
-        return FALSE;
-
-    for (i = 0; i < NUMMETHODS; i++) {
-        if (strcmp(MethodTable[i], sMethod) == 0) {
-            nMethodNo = i;
-            if (!Expect(' '))
-                return FALSE;
-            // URI (ie. host/directory/resource)
-            if (!ReadSpecial(sUri, sizeof(sUri)))
-                return FALSE;
-            if (!Expect(' '))
-                return FALSE;
-            // HTTP version (eg. HTTP/1.1)
-            if (!ReadSpecial(sVersion, sizeof(sVersion)))
-                return FALSE;
-            // CRLF
-            if (!ExpectCRLF())
-                return FALSE;
-
-            return TRUE;
-        }
-    }
-    bUnknownMethod = TRUE;
-    return FALSE;
-}
-
-// GenerelHeader = Cache-Control | Connection | Date | Pragma | Transfer-Encoding | 
-//                 Upgrade | Via
-BOOL CHttpParser::GenerelHeader()
-{
-    INT i;
-
-    for (i = 0; i < NUMGENERELS; i++) {
-        if (strcmp(GenerelTable[i], sHeader) == 0) {
-            switch (i) {
-                case 1: {
-                    //Connection
-                    Expect(':');
-                    Expect(' ');
-                    Skip(13);
-                    ExpectCRLF();
-                    break;
-                }
-                default: {
-                    Expect(':');
-                    Expect(' ');
-                    Skip(13);
-                    ExpectCRLF();
-                }
-            }
-            return TRUE;
-        }
-    }
-    return FALSE;
-}
-
-// RequestHeader = Accept | Accept-Charset | Accept-Encoding | Accept-Language |
-//                 Authorization | From | Host | If-Modified-Since | If-Match |
-//                 If-None-Match | If-Range | If-Unmodified-Since | Max-Forwards |
-//                 Proxy-Authorization | Range | Referer | User-Agent
-BOOL CHttpParser::RequestHeader()
-{
-    INT i;
-
-    for (i = 0; i < NUMREQUESTS; i++) {
-        if (strcmp(RequestTable[i], sHeader) == 0) {
-            switch (i) {
-                case 0: {
-                    //Accept
-                    Expect(':');
-                    Expect(' ');
-                    Skip(13);
-                    ExpectCRLF();
-                    break;
-                }
-                case 2: {
-                    //Accept-Encoding
-                    Expect(':');
-                    Expect(' ');
-                    Skip(13);
-                    ExpectCRLF();
-                    break;
-                }
-                case 3: {
-                    //Accept-Language
-                    Expect(':');
-                    Expect(' ');
-                    Skip(13);
-                    ExpectCRLF();
-                    break;
-                }
-                case 6: {
-                    //Host
-                    Expect(':');
-                    Expect(' ');
-                    Skip(13);
-                    ExpectCRLF();
-                    break;
-                }
-                case 16: {
-                    //User-Agent
-                    Expect(':');
-                    Expect(' ');
-                    Skip(13);
-                    ExpectCRLF();
-                    break;
-                }
-                default: {
-                    Expect(':');
-                    Expect(' ');
-                    Skip(13);
-                    ExpectCRLF();
-                    return TRUE;
-                }
-            }
-            return TRUE;
-        }
-    }
-    return FALSE;
-}
-
-// EntityHeader = Allow | Content-Base | Content-Encoding | Content-Language |
-//                Content-Length | Content-Location | Content-MD5 |
-//                Content-Range | Content-Type | ETag | Expires |
-//                Last-Modified | extension-header
-BOOL CHttpParser::EntityHeader()
-{
-    INT i;
-
-    for (i = 0; i < NUMENTITIES; i++) {
-        if (strcmp(EntityTable[i], sHeader) == 0) {
-            switch (i) {
-                case 0: 
-                default: {
-                    //cout << "<Entity-Header>: #" << i << endl; 
-                    Expect(':');
-                    Expect(' ');
-                    Skip(13);
-                    ExpectCRLF();
-                    return TRUE;
-                }
-            }
-            return FALSE;
-        }
-    }
-    return FALSE;
-}
-
-// MessageBody = *OCTET
-BOOL CHttpParser::MessageBody()
-{
-    return FALSE;
-}
diff --git a/reactos/apps/utils/net/roshttpd/httpd.cpp b/reactos/apps/utils/net/roshttpd/httpd.cpp
deleted file mode 100644 (file)
index 2aa43bd..0000000
+++ /dev/null
@@ -1,492 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        httpd.cpp
- * PURPOSE:     HTTP daemon
- * PROGRAMMERS: Casper S. Hornstrup (chorns@users.sourceforge.net)
- * REVISIONS:
- *   CSH  01/09/2000 Created
- */
-#include <debug.h>
-#include <new>
-#include <malloc.h>
-#include <string.h>
-#include <config.h>
-#include <httpd.h>
-#include <error.h>
-
-using namespace std;
-
-CHAR HttpMsg400[] = "<HEAD><TITLE>400 Bad Request</TITLE></HEAD>\n\r<BODY><H1>400 Bad Request</H1>\n\rThe request had bad syntax.<BR>\n\r</BODY>\n\r\n\r";
-CHAR HttpMsg404[] = "<HEAD><TITLE>404 Not Found</TITLE></HEAD>\n\r<BODY><H1>404 Not Found</H1>\n\rThe requested URL was not found on this server.<BR>\n\r</BODY>\n\r\n\r";
-CHAR HttpMsg405[] = "<HEAD><TITLE>405 Method Not Allowed</TITLE></HEAD>\n\r<BODY><H1>405 Method Not Allowed</H1>\n\rThe requested method is not supported on this server.<BR>\n\r</BODY>\n\r\n\r";
-CHAR HttpMsg500[] = "<HEAD><TITLE>500 Internal Server Error</TITLE></HEAD>\n\r<BODY><H1>500 Internal Server Error</H1>\n\rAn internal error occurred.<BR>\n\r</BODY>\n\r\n\r";
-CHAR HttpMsg501[] = "<HEAD><TITLE>501 Not Implemented</TITLE></HEAD>\n\r<BODY><H1>501 Not Implemented</H1>\n\rThe feature is not implemented.<BR>\n\r</BODY>\n\r\n\r";
-
-
-// *************************** CHttpClient ***************************
-
-// Default constructor
-CHttpClient::CHttpClient()
-{
-}
-
-// Constructor with server socket as starter value
-CHttpClient::CHttpClient(CServerSocket *serversocket)
-{
-       ServerSocket = serversocket;
-}
-
-// Split URIs into its parts (ie. |http://|www.host.com|/resource|?parameters|)
-VOID CHttpClient::SplitUri(LPSTR lpsUri, LPSTR lpsHost, LPSTR lpsResource, LPSTR lpsParams)
-{
-    LPSTR lpsPos;
-       LPSTR lpsStr;
-    UINT i;
-
-       strcpy(lpsHost, "");
-       strcpy(lpsResource, "");
-       strcpy(lpsParams, "");
-
-    lpsPos = strstr(lpsUri, "://");
-    if (lpsPos != NULL)
-        lpsStr = &lpsPos[3];
-       else
-               lpsStr = lpsUri;
-        
-    lpsPos = strstr(lpsStr, "/");
-    if (lpsPos != NULL) {
-        strncat(lpsHost, lpsPos, lpsPos - lpsStr);
-        lpsStr = &lpsPos[1];
-
-        lpsPos = strstr(lpsStr, "?");
-        if (lpsPos != NULL) {
-            strncat(lpsResource, lpsStr, lpsPos - lpsStr);
-            strcpy(lpsParams, &lpsPos[1]);
-        } else {
-            strcpy(lpsResource, lpsStr);
-            strcpy(lpsParams, "");
-        }
-
-        // Replace "/" with "\"
-               for (i = 0; i < strlen(lpsResource); i++) {
-            if (lpsResource[i] == '/')
-                lpsResource[i] = '\\';
-        }
-    }
-}
-
-// Split resource into its parts (ie. |/path/|filename|.extension|)
-VOID CHttpClient::SplitResource(LPSTR lpsResource, LPSTR lpsPath, LPSTR lpsFilename, LPSTR lpsExtension)
-{
-    INT i,len,fileptr,extptr;
-       
-       strcpy(lpsPath, "");
-       strcpy(lpsFilename, "");
-       strcpy(lpsExtension, "");
-       
-       len = strlen(lpsResource);
-       if (len != 0) {
-               if (lpsResource[len - 1] == '/') {
-                       // There is only a path
-                       strcpy(lpsPath, lpsResource);
-               } else {
-                       // Find extension
-                       i = len - 1;
-                       while ((i >= 0) && (lpsResource[i] != '.')) i--;
-                       extptr = i;
-                       while ((i >= 0) && (lpsResource[i] != '/')) i--;
-                       if (i > 0) {
-                               // There is at least one directory in the path (besides root directory)
-                               fileptr = i + 1;
-                               strncat(lpsPath, lpsResource, fileptr);
-                       } else
-                               fileptr = 1;
-                       
-                       // Get filename and possibly extension
-                       if (extptr != 0) {
-                               strncat(lpsFilename, &lpsResource[fileptr], extptr - fileptr);
-                               // Get extension
-                               strncat(lpsExtension, &lpsResource[extptr + 1], len - extptr - 1);
-                       } else
-                               strncat(lpsFilename, &lpsResource[fileptr], len - fileptr);
-               }
-       }
-}
-
-// Process HTTP request
-VOID CHttpClient::ProcessRequest()
-{
-    CHAR sStr[255];
-       CHAR sHost[255];
-    CHAR sResource[255];
-    CHAR sParams[255];
-
-    // Which method?
-    switch (Parser.nMethodNo) {
-               case hmGET: {
-                       SplitUri(Parser.sUri, sHost, sResource, sParams);
-                       
-                       // Default resource?
-                       if (strlen(sResource) == 0) {
-                               CIterator<LPSTR> *i = pConfiguration->GetDefaultResources()->CreateIterator();
-
-                               // FIXME: All default resources should be tried
-                               // Iterate through all strings
-                               //for (i->First(); !i->IsDone(); i->Next())
-                               i->First();
-                               if (!i->IsDone()) {
-                                       strcat(sResource, i->CurrentItem());
-                                       delete i;
-                               } else {
-                                       // File not found
-                                       Report("404 Not Found", HttpMsg404);
-                                       break;
-                               }
-                       }
-                       strcpy(sStr, pConfiguration->GetHttpBase());
-               strcat(sStr, sResource);
-                       SendFile(sStr);
-                       break;
-               }
-               default: {
-                       // Method is not implemented
-                       Report("501 Not Implemented", HttpMsg501);
-               }
-       }
-}
-
-// Send a file to socket
-VOID CHttpClient::SendFile(LPSTR lpsFilename)
-{
-    CHAR str[255];
-    CHAR str2[32];
-    union BigNum {
-      //        unsigned __int64 Big;
-      unsigned long long Big;
-        struct {
-            DWORD Low;
-            DWORD High; 
-        } u;
-    } nTotalBytes;
-       DWORD nBytesToRead;
-       DWORD nBytesRead;
-       BOOL bStatus;
-
-       // Try to open file
-    hFile = CreateFileA(lpsFilename,
-        GENERIC_READ,               // Open for reading 
-        FILE_SHARE_READ,            // Share for reading 
-        NULL,                       // No security 
-        OPEN_EXISTING,              // Existing file only 
-        FILE_ATTRIBUTE_NORMAL,      // Normal file 
-        NULL);                      // No attr. template 
-    if (hFile == INVALID_HANDLE_VALUE) { 
-        // File not found
-        Report("404 Not Found", HttpMsg404);
-        return; 
-    }
-    // Get file size
-    nTotalBytes.u.Low = GetFileSize(hFile, &nTotalBytes.u.High);
-    if ((nTotalBytes.u.Low == 0xFFFFFFFF) && ((GetLastError()) != NO_ERROR)) {
-        // Internal server error
-               Report("500 Internal Server Error", HttpMsg500);
-               // Close file
-               CloseHandle(hFile);
-        return;
-    }
-
-       // Determine buffer size
-       if (nTotalBytes.Big < 65536)
-               nBufferSize = 1024;
-       else
-               nBufferSize = 32768;
-       // Allocate memory on heap
-       lpsBuffer = (PCHAR) malloc(nBufferSize);
-
-       if (lpsBuffer == NULL) {
-               // Internal server error
-               Report("500 Internal Server Error", HttpMsg500);
-               // Close file
-               CloseHandle(hFile);
-               return;
-       }
-
-       SendText("HTTP/1.1 200 OK");
-    SendText("Server: ROSHTTPD");
-    SendText("MIME-version: 1.0");
-    SendText("Content-Type: text/plain");
-    SendText("Accept-Ranges: bytes");
-    strcpy(str, "Content-Length: ");
-    _itoa(nTotalBytes.u.Low, str2, 10);
-    strcat(str, str2);
-    SendText(str);
-    SendText("");
-       // Read and transmit file
-       nTotalRead = 0;
-       nFileSize = nTotalBytes.Big;
-       bStop = FALSE;
-
-       fd_set wfds;
-       FD_ZERO(&wfds);
-       FD_SET(Socket, &wfds);
-       do {
-               MessageLoop();
-
-               if (nTotalRead + nBufferSize < nFileSize)
-                       nBytesToRead = nBufferSize;
-               else nBytesToRead = nFileSize - nTotalRead;
-
-               bStatus = ReadFile(hFile, lpsBuffer, nBytesToRead, &nBytesRead, NULL);
-               if (bStatus) {
-                       select(0, NULL, &wfds, NULL, NULL);
-                       bStatus = (Transmit(lpsBuffer, nBytesRead) == (INT)nBytesRead);
-                       nTotalRead += nBytesRead;
-               }
-    } while ((!bStop) && (bStatus) && (nTotalRead < nFileSize));
-
-       if (bStatus)
-               SendText("");
-       else
-               // We can't send an error message here as we are in the process of sending a file.
-               // We have to terminate the connection instead
-               Close();
-       
-       // Free allocated memory
-       free(lpsBuffer);
-
-       // Close file
-    CloseHandle(hFile);
-}
-
-// Report something to client
-VOID CHttpClient::Report(LPSTR lpsCode, LPSTR lpsStr)
-{
-    CHAR sTmp[128];
-    CHAR sTmp2[16];
-       
-    strcpy(sTmp, "HTTP/1.1 ");
-    strcat(sTmp, lpsCode);
-    SendText(sTmp);
-    SendText("Server: ROSHTTPD");
-    SendText("MIME-version: 1.0");
-    SendText("Content-Type: text/html");
-    SendText("Accept-Ranges: bytes");
-    strcpy(sTmp, "Content-Length: ");
-    if (lpsStr != NULL) {
-        _itoa(strlen(lpsStr), sTmp2, 10);
-        strcat(sTmp,  sTmp2);
-    } else
-        strcat(sTmp, "0");
-    SendText(sTmp);
-    SendText("");
-    if (lpsStr != NULL)
-        SendText(lpsStr);
-    SendText("");
-}
-
-// OnRead event handler
-VOID CHttpClient::OnRead()
-{
-       LONG nCount;
-
-       nCount = Receive((LPSTR) &Parser.sBuffer[Parser.nHead],
-        sizeof(Parser.sBuffer) - Parser.nHead);
-
-    Parser.nHead += nCount;
-       if (Parser.nHead >= sizeof(Parser.sBuffer))
-               Parser.nHead = 0;
-
-    if (Parser.Complete()) {
-               ProcessRequest();
-    }
-
-       if (Parser.bUnknownMethod) {
-               // Method Not Allowed
-               Report("405 Method Not Allowed", HttpMsg405);
-               // Terminate connection
-               Close();
-       }
-}
-/*
-// OnWrite event handler
-VOID CHttpClient::OnWrite()
-{
-       DWORD nBytesToRead;
-       DWORD nBytesRead;
-
-       OutputDebugString(TS("Can write\n"));
-
-       if (bSendingFile) {
-               if (nTotalRead + nBufferSize < nFileSize)
-                       nBytesToRead = nBufferSize;
-               else nBytesToRead = nFileSize - nTotalRead;
-
-               bError = ReadFile(hFile, Buffer, nBytesToRead, &nBytesRead, NULL);
-               if (!bError) {
-                       Transmit(Buffer, nBytesRead);
-                       nTotalRead += nBytesRead;
-               }
-       }
-}
-*/
-// OnClose event handler
-VOID CHttpClient::OnClose()
-{
-       // Stop sending file if we are doing that now
-       bStop = TRUE;
-}
-
-
-// ************************ CHttpClientThread ************************
-
-// Constructor with client socket as starter value
-CHttpClientThread::CHttpClientThread(LPCServerClientSocket lpSocket)
-{
-       ClientSocket = lpSocket;
-}
-
-// Execute client thread code
-VOID CHttpClientThread::Execute()
-{
-    MSG Msg;
-
-       while (!Terminated()) {
-               ((  CHttpClient *) ClientSocket)->MessageLoop();
-        if (PeekMessage(&Msg, 0, 0, 0, PM_REMOVE) != 0) {
-            switch (Msg.message) {
-                case HTTPD_START: {
-                                       // TODO: Start thread
-                    break;
-                }
-                case HTTPD_STOP: {
-                                       // TODO: Stop thread
-                    break;
-                }
-                default:
-                    DispatchMessage(&Msg);
-            }
-
-        }
-    }
-
-       if (ClientSocket != NULL) {
-               delete ClientSocket;
-               ClientSocket = NULL;
-       }
-}
-
-
-// *************************** CHttpDaemon ***************************
-
-// Default constructor
-CHttpDaemon::CHttpDaemon()
-{
-    State = hsStopped;
-       Start();
-}
-
-// Default destructor
-CHttpDaemon::~CHttpDaemon()
-{
-       if (State==hsRunning)
-               Stop();
-}
-
-// Return daemon state
-HTTPdState CHttpDaemon::GetState() const
-{
-       return State;
-}
-
-// Start HTTP daemon
-BOOL CHttpDaemon::Start()
-{
-       assert(State==hsStopped);
-
-       SetPort(pConfiguration->GetPort());
-
-       Open();
-       
-       State = hsRunning;
-       
-    return TRUE;
-}
-
-// Stop HTTP daemon
-BOOL CHttpDaemon::Stop()
-{
-       assert(State==hsRunning);
-
-       Close();
-
-       State = hsStopped;
-
-    return TRUE;
-}
-
-// OnGetSocket event handler
-LPCServerClientSocket CHttpDaemon::OnGetSocket(LPCServerSocket lpServerSocket)
-{
-       return new CHttpClient(lpServerSocket);
-}
-
-// OnGetThread event handler
-LPCServerClientThread CHttpDaemon::OnGetThread(LPCServerClientSocket lpSocket)
-{
-       return new CHttpClientThread(lpSocket);
-}
-
-// OnAccept event handler
-VOID CHttpDaemon::OnAccept(LPCServerClientThread lpThread)
-{
-}
-
-
-// ************************ CHttpDaemonThread ************************
-
-// Execute daemon thread code
-VOID CHttpDaemonThread::Execute()
-{
-       MSG Msg;
-       
-       try {
-               Daemon = NULL;
-               Daemon = new CHttpDaemon;
-
-               while (!Terminated()) {
-                       Daemon->MessageLoop();
-                       if (PeekMessage(&Msg, 0, 0, 0, PM_REMOVE) != 0) {
-                   switch (Msg.message) {
-                           case HTTPD_START: {
-                                   if (Daemon->GetState() == hsStopped)
-                                           Daemon->Start();
-                                           break;
-                                       }
-                                       case HTTPD_STOP: {
-                           if (Daemon->GetState() == hsRunning)
-                                                       Daemon->Stop();
-                                               break;
-                                       }
-                                       case HTTPD_SUSPEND: {
-                                               if (Daemon->GetState() == hsRunning){}
-                                                       // FIXME: Suspend service
-                                               break;
-                                       }
-                                       case HTTPD_RESUME: {
-                                               if (Daemon->GetState() != hsSuspended){}
-                                                       // FIXME: Resume service
-                                               break;
-                                       }
-                                       default:
-                        DispatchMessage(&Msg);
-                               }
-                       }
-           }
-               delete Daemon;
-       } catch (ESocket e) {
-               ReportErrorStr(e.what());
-       } catch (bad_alloc e) {
-               ReportErrorStr(TS("Insufficient resources."));
-       }
-}
diff --git a/reactos/apps/utils/net/roshttpd/include/config.h b/reactos/apps/utils/net/roshttpd/include/config.h
deleted file mode 100644 (file)
index 2479308..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        include/config.h
- */
-#ifndef __CONFIG_H
-#define __CONFIG_H
-
-#include <list.h>
-#include <httpd.h>
-
-// General constants
-#define APP_DESCRIPTION _T("ReactOS HTTP Daemon")
-
-// Default configuration
-#define dcfgDescription     _T("Default configuration")
-#define dcfgMainBase        _T("C:\\roshttpd\\")
-#define dcfgHttpBase        "C:\\roshttpd\\HttpBase\\"
-#define dcfgDefaultResource "index.html"
-#define dcfgDefaultPort     80
-
-class CConfig {
-public:
-       CConfig();
-       ~CConfig();
-       VOID Default();
-       VOID Clear();
-       BOOL Load();
-       BOOL Save();
-       LPWSTR GetMainBase();
-       VOID SetMainBase(LPWSTR lpwsMainBase);
-       LPSTR GetHttpBase();
-       VOID SetHttpBase(LPSTR lpsHttpBase);
-       CList<LPSTR>* GetDefaultResources();
-    USHORT GetPort();
-    VOID SetPort(USHORT wPort);
-private:
-       VOID Reset();
-       LPWSTR MainBase;
-       LPSTR HttpBase;
-       CList<LPSTR> DefaultResources;
-    USHORT Port;
-};
-typedef CConfig* LPCConfig;
-
-extern LPCConfig pConfiguration;
-extern LPCHttpDaemonThread pDaemonThread;
-
-#endif /* __CONFIG_H */
diff --git a/reactos/apps/utils/net/roshttpd/include/debug.h b/reactos/apps/utils/net/roshttpd/include/debug.h
deleted file mode 100644 (file)
index 2c09275..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        include/debug.h
- */
-#ifndef __DEBUG_H
-#define __DEBUG_H
-
-#include <stdio.h>
-
-#ifdef DBG
-#define DPRINT(x...)    printf(x)
-#else
-#define DPRINT(x...)
-#endif
-
-#endif /* __DEBUG_H */
diff --git a/reactos/apps/utils/net/roshttpd/include/error.h b/reactos/apps/utils/net/roshttpd/include/error.h
deleted file mode 100644 (file)
index 483d915..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        include/error.h
- */
-#ifndef __ERROR_H
-#define __ERROR_H
-
-#include <windows.h>
-
-#define TS(x) (LPTSTR)TEXT(x)
-
-void ReportErrorStr(LPTSTR lpsText);
-
-#endif /* __ERROR_H */
diff --git a/reactos/apps/utils/net/roshttpd/include/http.h b/reactos/apps/utils/net/roshttpd/include/http.h
deleted file mode 100644 (file)
index 7d97eb5..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        include/http.h
- */
-#ifndef __HTTP_H
-#define __HTTP_H
-
-#include <windows.h>
-
-// Generel HTTP related constants
-#define NUMMETHODS 7
-#define NUMGENERELS 7
-#define NUMREQUESTS 17
-#define NUMENTITIES 12
-
-// HTTP method constants
-#define hmOPTIONS      0
-#define hmGET          1
-#define hmHEAD         2
-#define hmPOST         3
-#define hmPUT          4
-#define hmDELETE       5
-#define hmTRACE                6
-
-class CHttpParser {
-public:
-    CHAR sBuffer[2048];
-    UINT nHead;
-    UINT nTail;
-    CHAR sUri[255];
-    CHAR sVersion[15];
-    CHAR sHeader[63];
-    CHAR sMethod[63];
-    UINT nMethodNo;
-    BOOL bUnknownMethod;
-    BOOL bBadRequest;
-    CHttpParser();
-    ~CHttpParser();
-    BOOL Complete();
-    BOOL Parse();
-private:
-    BOOL ReadChar(LPSTR lpsStr);
-    BOOL PeekChar(LPSTR lpsStr);
-    BOOL ReadString(LPSTR lpsStr, UINT nLength);
-    BOOL ReadSpecial(LPSTR lpStr, UINT nLength);
-    VOID Skip(CHAR sStr);
-    BOOL Expect(CHAR sStr);
-    BOOL ExpectCRLF();
-    BOOL RequestLine();
-    BOOL GenerelHeader();
-    BOOL RequestHeader();
-    BOOL EntityHeader();
-    BOOL MessageBody();
-};
-
-#endif /* __HTTP_H */
diff --git a/reactos/apps/utils/net/roshttpd/include/httpd.h b/reactos/apps/utils/net/roshttpd/include/httpd.h
deleted file mode 100644 (file)
index d281c0c..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        include/httpd.h
- */
-#ifndef __HTTPD_H
-#define __HTTPD_H
-
-#include <thread.h>
-#include <socket.h>
-#include <http.h>
-
-#define HTTPD_START     WM_USER + 1
-#define HTTPD_STOP      WM_USER + 2
-#define HTTPD_SUSPEND   WM_USER + 3
-#define HTTPD_RESUME    WM_USER + 4
-
-enum HTTPdState {
-    hsStopped = 0,
-    hsRunning,
-    hsSuspended
-};
-
-class CHttpDaemon;
-
-class CHttpClient : public CServerClientSocket {
-public:
-       CHttpClient();
-    CHttpClient(LPCServerSocket lpServerSocket);
-       virtual void OnRead();
-       //virtual void OnWrite();
-       virtual void OnClose();
-    HANDLE ThreadHandle;
-    DWORD ThreadId;
-    CHttpParser Parser;
-    void SplitUri(const LPSTR lpsUri, LPSTR lpsHost, LPSTR lpsResource, LPSTR lpsParams);
-       void SplitResource(const LPSTR lpsResource, LPSTR lpsPath, LPSTR lpsFilename, LPSTR lpsExtension);
-    void ProcessRequest();
-    void SendFile(const LPSTR lpsFilename);
-    void Report(const LPSTR lpsCode, const LPSTR lpsStr);
-private:
-       BOOL bStop;
-       LPSTR lpsBuffer;
-       LONG nBufferSize;
-       //    unsigned __int64 nTotalRead;
-       unsigned long long nTotalRead;
-       //      unsigned __int64 nFileSize;
-       unsigned long long nFileSize;
-    HANDLE hFile;
-};
-typedef CHttpClient* LPCHttpClient;
-
-class CHttpClientThread : public CServerClientThread {
-public:
-       CHttpClientThread() {};
-       CHttpClientThread(LPCServerClientSocket Socket);
-       virtual void Execute();
-};
-typedef CHttpClientThread* LPCHttpClientThread;
-
-class CHttpDaemon : public CServerSocket {
-public:
-    CHttpDaemon();
-    virtual ~CHttpDaemon();
-       HTTPdState GetState() const;
-       virtual BOOL Start();
-       virtual BOOL Stop();
-       virtual LPCServerClientSocket OnGetSocket(LPCServerSocket lpServerSocket);
-       virtual LPCServerClientThread OnGetThread(LPCServerClientSocket Socket);
-       virtual void OnAccept(const LPCServerClientThread lpThread);
-private:
-       HTTPdState State;
-};
-typedef CHttpDaemon* LPCHttpDaemon;
-
-class CHttpDaemonThread : public CThread {
-public:
-       CHttpDaemonThread() {};
-       virtual void Execute();
-private:
-       CHttpDaemon *Daemon;
-};
-typedef CHttpDaemonThread* LPCHttpDaemonThread;
-
-#endif /* __HTTPD_H */
diff --git a/reactos/apps/utils/net/roshttpd/include/iterator.h b/reactos/apps/utils/net/roshttpd/include/iterator.h
deleted file mode 100644 (file)
index a7aa66f..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        include/iterator.h
- */
-#ifndef __ITERATOR_H
-#define __ITERATOR_H
-
-#include <windows.h>
-
-template <class Item>
-class CIterator {
-public:
-       virtual VOID First() = 0;
-       virtual VOID Next() = 0;
-       virtual BOOL IsDone() const = 0;
-       virtual Item CurrentItem() const = 0;
-};
-
-#endif /* __ITERATOR_H */
diff --git a/reactos/apps/utils/net/roshttpd/include/list.h b/reactos/apps/utils/net/roshttpd/include/list.h
deleted file mode 100644 (file)
index 914d06e..0000000
+++ /dev/null
@@ -1,233 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        include/list.h
- */
-#ifndef __LIST_H
-#define __LIST_H
-
-#include <windows.h>
-#include <iterator.h>
-
-class CListNode {
-public:
-       CListNode();
-       CListNode(VOID *element, CListNode *next, CListNode *prev);
-       ~CListNode() {};
-    void* operator new(/*size_t s*/ UINT s);
-    VOID  operator delete(void* p);
-
-       VOID SetElement(PVOID element);
-       VOID SetNext(CListNode *next);
-       VOID SetPrev(CListNode *prev);
-       PVOID GetElement();
-       CListNode *GetNext();
-       CListNode *GetPrev();
-private:
-       PVOID Element;
-       CListNode *Next;
-       CListNode *Prev;
-    static HANDLE hHeap;
-    static INT nRef;
-};
-
-template <class Item> class CList {
-public:
-       //CList(CList&);
-       CList();
-       ~CList();
-       CList& operator=(CList&);
-
-       CIterator<Item> *CreateIterator() const;
-       LONG Count() const;
-       Item& Get(const LONG index) const;
-       // Can throw bad_alloc
-       VOID Insert(Item& element);
-       VOID Remove(Item& element);
-       VOID RemoveAll();
-       CListNode *GetHeader() const;
-       CListNode *GetTrailer() const;
-private:
-       CListNode *Search(Item& element) const;
-       LONG NodeCount;
-       CListNode *Header;
-       CListNode *Trailer;
-};
-
-template <class Item> class CListIterator : public CIterator<Item> {
-public:
-       CListIterator(const CList<Item> *list);
-       virtual VOID First();
-       virtual VOID Next();
-       virtual BOOL IsDone() const;
-       virtual Item CurrentItem() const;
-private:
-       const CList<Item> *List;
-       CListNode *Current;
-};
-
-// ****************************** CList ******************************
-
-// Default constructor
-template <class Item>
-CList<Item>::CList()
-{
-       // Create dummy nodes
-       Trailer = new CListNode;
-       Header = new CListNode;
-       Header->SetNext(Trailer);
-       Trailer->SetPrev(Header);
-}
-
-// Default destructor
-template <class Item>
-CList<Item>::~CList()
-{
-       RemoveAll();
-       delete Trailer;
-       delete Header;
-}
-
-// Create an iterator for the list
-template <class Item>
-CIterator<Item> *CList<Item>::CreateIterator() const
-{
-       return new CListIterator<Item>((CList<Item> *) this);
-}
-
-// Return number of elements in list
-template <class Item>
-LONG CList<Item>::Count() const
-{
-       return NodeCount;
-}
-
-// Return element at index
-template <class Item>
-Item& CList<Item>::Get(const LONG index) const
-{
-       CListNode *node;
-
-       if ((index < 0) || (index >= NodeCount))
-               return NULL;
-
-       node = Header;
-       for (int i = 0; i <= index; i++)
-               node = node->GetNext();
-
-       return (Item *) node->GetElement();
-}
-
-// Insert an element into the list
-template <class Item>
-VOID CList<Item>::Insert(Item& element)
-{
-       CListNode *node;
-
-       node = new CListNode((PVOID)element, Trailer, Trailer->GetPrev());
-       Trailer->GetPrev()->SetNext(node);
-       Trailer->SetPrev(node);
-       NodeCount++;
-}
-
-// Remove an element from the list
-template <class Item>
-VOID CList<Item>::Remove(Item& element)
-{
-       CListNode *node;
-
-       node = Search(element);
-       if (node != NULL) {
-               node->GetPrev()->SetNext(node->GetNext());
-               node->GetNext()->SetPrev(node->GetPrev());
-               NodeCount--;
-               delete node;
-       }
-}
-
-// Remove all elements in list
-template <class Item>
-VOID CList<Item>::RemoveAll()
-{
-       CListNode *node;
-       CListNode *tmp;
-
-       node = Header->GetNext();
-       while (node != Trailer) {
-               tmp = node->GetNext();
-               delete node;
-               node = tmp;
-       }
-       Header->SetNext(Trailer);
-       Trailer->SetPrev(Header);
-       NodeCount = 0;
-}
-
-// Return header node
-template <class Item>
-CListNode *CList<Item>::GetHeader() const
-{
-       return Header;
-}
-
-// Return trailer node
-template <class Item>
-CListNode *CList<Item>::GetTrailer() const
-{
-       return Trailer;
-}
-
-// Searches for a node that contains the element. Returns NULL if element is not found
-template <class Item>
-CListNode *CList<Item>::Search(Item& element) const
-{
-       CListNode *node;
-
-       node = Header;
-       while (((node = node->GetNext()) != Trailer) && (node->GetElement() != element));
-       if (node != Trailer)
-               return node;
-       else
-               return NULL;
-}
-
-
-// ************************** CListIterator **************************
-
-// Default constructor
-template <class Item>
-CListIterator<Item>::CListIterator(const CList<Item> *list) : List(list)
-{
-       First();
-}
-
-// Go to first element in list
-template <class Item>
-VOID CListIterator<Item>::First()
-{
-       Current = List->GetHeader()->GetNext();
-}
-
-// Go to next element in list
-template <class Item>
-VOID CListIterator<Item>::Next()
-{
-       if (!IsDone())
-               Current = Current->GetNext();
-}
-
-// Return FALSE when there are more elements in list and TRUE when there are no more
-template <class Item>
-BOOL CListIterator<Item>::IsDone() const
-{
-       return (Current == List->GetTrailer());
-}
-
-// Return current element
-template <class Item>
-Item CListIterator<Item>::CurrentItem() const
-{
-       return IsDone()? NULL : (Item) Current->GetElement();
-}
-
-#endif /* __LIST_H */
diff --git a/reactos/apps/utils/net/roshttpd/include/socket.h b/reactos/apps/utils/net/roshttpd/include/socket.h
deleted file mode 100644 (file)
index 06ed020..0000000
+++ /dev/null
@@ -1,141 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        include/socket.h
- */
-#ifndef __SOCKET_H
-#define __SOCKET_H
-#include <msvcrt/stdio.h>
-#include <windows.h>
-#include <winsock2.h>
-#include <thread.h>
-#include <list.h>
-#include <exception>
-#include <assert.h>
-
-#define MAX_PENDING_CONNECTS 4      // The backlog allowed for listen()
-
-VOID InitWinsock();
-VOID DeinitWinsock();
-
-class CSocket;
-class CClientSocket;
-class CServerClientSocket;
-class CServerClientThread;
-class CServerSocket;
-
-typedef CSocket* LPCSocket;
-typedef CClientSocket* LPCClientSocket;
-typedef CServerClientSocket* LPCServerClientSocket;
-typedef CServerClientThread* LPCServerClientThread;
-typedef CServerSocket* LPCServerSocket;
-
-class ESocket {
-public:
-       ESocket() { Description = NULL; }
-       ESocket(LPTSTR description)  { Description = description; }
-       LPTSTR what()  { return Description; }
-protected:
-       LPTSTR Description;
-};
-
-class ESocketWinsock : public ESocket {
-public:
-       ESocketWinsock(LPTSTR description) { Description = description; }
-};
-
-class ESocketDll : public ESocket {
-public:
-       ESocketDll(LPTSTR description) { Description = description; }
-};
-
-class ESocketOpen : public ESocket {
-public:
-       ESocketOpen(LPTSTR description) { Description = description; }
-};
-
-class ESocketClose : public ESocket {
-public:
-       ESocketClose(LPTSTR description) { Description = description; }
-};
-
-class ESocketSend : public ESocket {
-public:
-       ESocketSend(LPTSTR description) { Description = description; }
-};
-
-class ESocketReceive : public ESocket {
-public:
-       ESocketReceive(LPTSTR description) { Description = description; }
-};
-
-
-class CSocket {
-public:
-       CSocket();
-       virtual ~CSocket();
-       virtual SOCKET GetSocket();
-       virtual VOID SetSocket(SOCKET socket);
-       virtual SOCKADDR_IN GetSockAddrIn();
-       virtual VOID SetSockAddrIn(SOCKADDR_IN sockaddrin);
-       virtual VOID SetEvents(LONG lEvents);
-       virtual LONG GetEvents();
-    virtual VOID SetPort( UINT nPort) {};
-       virtual VOID Open();
-       virtual VOID Close();
-       virtual INT Transmit( LPSTR lpsBuffer,  UINT nLength) { return 0; };
-       virtual INT Receive(LPSTR lpsBuffer,  UINT nLength) { return 0; };
-       virtual INT SendText( LPSTR lpsStr) { return 0; };
-protected:
-       SOCKET Socket;
-       SOCKADDR_IN SockAddrIn;
-       WSAEVENT Event;
-       UINT Port;
-       BOOL Active;
-private:
-       LONG Events;
-};
-
-class CServerClientSocket : public CSocket {
-public:
-       CServerClientSocket() {};
-       CServerClientSocket(LPCServerSocket lpServerSocket);
-       CServerSocket *GetServerSocket();
-       virtual INT Transmit( LPSTR lpsBuffer,  UINT nLength);
-       virtual INT Receive(LPSTR lpsBuffer,  UINT nLength);
-       virtual INT SendText( LPSTR lpsText);
-       virtual VOID MessageLoop();
-       virtual VOID OnRead() {};
-       //virtual VOID OnWrite() {};
-       virtual VOID OnClose() {};
-protected:
-       LPCServerSocket ServerSocket;
-};
-
-class CServerClientThread : public CThread {
-public:
-       CServerClientThread() {};
-       CServerClientThread(CServerClientSocket *socket);
-       virtual ~CServerClientThread();
-protected:
-       CServerClientSocket *ClientSocket;
-};
-
-class CServerSocket : public CSocket {
-public:
-       CServerSocket();
-       virtual ~CServerSocket();
-       virtual VOID SetPort( UINT nPort);
-       virtual VOID Open();
-       virtual VOID Close();
-       virtual LPCServerClientSocket OnGetSocket(LPCServerSocket lpServerSocket);
-       virtual LPCServerClientThread OnGetThread(LPCServerClientSocket lpSocket);
-       virtual VOID OnAccept( LPCServerClientThread lpThread) {};
-       virtual VOID MessageLoop();
-       VOID InsertClient(LPCServerClientThread lpClient);
-       VOID RemoveClient(LPCServerClientThread lpClient);
-protected:
-       CList<LPCServerClientThread> Connections;
-};
-
-#endif /* __SOCKET_H */
diff --git a/reactos/apps/utils/net/roshttpd/include/thread.h b/reactos/apps/utils/net/roshttpd/include/thread.h
deleted file mode 100644 (file)
index 0b311d4..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        include/thread.h
- */
-#ifndef __THREAD_H
-#define __THREAD_H
-
-#include <windows.h>
-
-class CThread;
-
-struct ThreadData {
-       CThread *ClassPtr;
-       HANDLE hFinished;
-};
-
-class CThread {
-public:
-       CThread();
-       virtual ~CThread();
-       BOOL PostMessage(UINT Msg, WPARAM wParam, LPARAM lParam);
-       virtual void Execute();
-       virtual void Terminate();
-       BOOL Terminated();
-protected:
-       BOOL bTerminated;
-       DWORD dwThreadId;
-       HANDLE hThread;
-       ThreadData Data;
-};
-typedef CThread *LPCThread;
-
-#endif /* __THREAD_H */
diff --git a/reactos/apps/utils/net/roshttpd/roshttpd.cpp b/reactos/apps/utils/net/roshttpd/roshttpd.cpp
deleted file mode 100644 (file)
index 89af9bf..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS HTTP Daemon
- * FILE:        roshttpd.cpp
- * PURPOSE:     Main program
- * PROGRAMMERS: Casper S. Hornstrup (chorns@users.sourceforge.net)
- * REVISIONS:
- *   CSH  01/09/2000 Created
- */
-#include <debug.h>
-#include <new>
-#include <winsock2.h>
-#include <stdio.h>
-#include <config.h>
-#include <error.h>
-#include <httpd.h>
-
-using namespace std;
-
-
-VOID Run()
-{
-    InitWinsock();
-
-    pDaemonThread = NULL;
-       pConfiguration = NULL;
-
-       try {
-        // Create configuration object
-               pConfiguration = new CConfig;
-        pConfiguration->Default();
-
-        // Create daemon object
-        pDaemonThread = new CHttpDaemonThread;
-
-               MSG Msg;
-               BOOL bQuit = FALSE;
-               while ((!bQuit) && (!pDaemonThread->Terminated())) {
-                   bQuit = PeekMessage(&Msg, NULL, 0, 0, PM_REMOVE);
-                       if (!bQuit)
-                           DispatchMessage(&Msg);
-        }
-
-               delete pDaemonThread;
-
-               if (pConfiguration != NULL)
-                   delete pConfiguration;
-       } catch (bad_alloc e) {
-               if (pConfiguration != NULL)
-                       delete pConfiguration;
-               ReportErrorStr(TS("Insufficient resources."));
-       }
-
-    DeinitWinsock();
-}
-
-/* Program entry point */
-int main(int argc, char* argv[])
-{
-    printf("ReactOS HTTP Daemon\n");
-    printf("Type Control-C to stop.\n");
-
-    Run();
-
-    printf("Daemon stopped.\n");
-}
diff --git a/reactos/apps/utils/net/route/route.c b/reactos/apps/utils/net/route/route.c
deleted file mode 100644 (file)
index 23a1da1..0000000
+++ /dev/null
@@ -1,308 +0,0 @@
-/* Poor man's route
- *
- * Supported commands:
- *
- * "print"
- * "add" target ["mask" mask] gw ["metric" metric]
- * "delete" target gw
- *
- * Goals:
- *
- * Flexible, simple
- */
-
-#include <stdio.h>
-#include <windows.h>
-#include <iphlpapi.h>
-#include <winsock2.h>
-#include <tchar.h>
-
-#define IPBUF 17
-#define IN_ADDR_OF(x) *((struct in_addr *)&(x))
-
-static int Usage()
-{
-    _ftprintf( stderr,
-               _T("route usage:\n"
-                  "route print\n"
-                  "  prints the route table\n"
-                  "route add <target> [mask <mask>] <gw> [metric <m>]\n"
-                  "  adds a route\n"
-                  "route delete <target> <gw>\n"
-                  "  deletes a route\n") );
-    return 1;
-}
-
-static int PrintRoutes()
-{
-    PMIB_IPFORWARDTABLE IpForwardTable = NULL;
-    PIP_ADAPTER_INFO pAdapterInfo;
-    ULONG Size = 0;
-    DWORD Error = 0;
-    ULONG adaptOutBufLen = sizeof(IP_ADAPTER_INFO);
-    TCHAR DefGate[16];
-    TCHAR Destination[IPBUF], Gateway[IPBUF], Netmask[IPBUF];
-    unsigned int i;
-
-    /* set required buffer size */
-    pAdapterInfo = (IP_ADAPTER_INFO *) malloc( adaptOutBufLen );
-    if (pAdapterInfo == NULL)
-    {
-        Error = ERROR_NOT_ENOUGH_MEMORY;
-        goto Error;
-    }
-    if (GetAdaptersInfo( pAdapterInfo, &adaptOutBufLen) == ERROR_BUFFER_OVERFLOW)
-    {
-       free (pAdapterInfo);
-       pAdapterInfo = (IP_ADAPTER_INFO *) malloc (adaptOutBufLen);
-       if (pAdapterInfo == NULL)
-       {
-           Error = ERROR_NOT_ENOUGH_MEMORY;
-           goto Error;
-       }
-    }
-
-    if( (GetIpForwardTable( NULL, &Size, TRUE )) == ERROR_INSUFFICIENT_BUFFER )
-    {
-        if (!(IpForwardTable = malloc( Size )))
-        {
-            free(pAdapterInfo);
-            Error = ERROR_NOT_ENOUGH_MEMORY;
-            goto Error;
-        }
-    }
-
-    if (((Error = GetAdaptersInfo(pAdapterInfo, &adaptOutBufLen)) == NO_ERROR) &&
-        ((Error = GetIpForwardTable(IpForwardTable, &Size, TRUE)) == NO_ERROR))
-    {
-        _stprintf(DefGate,
-#if UNICODE
-                  _T("%hs"),
-#else
-                  _T("%s"),
-#endif
-                  pAdapterInfo->GatewayList.IpAddress.String);
-        _tprintf(_T("===========================================================================\n"));
-        _tprintf(_T("Interface List\n"));
-        /* FIXME - sort by the index! */
-        while (pAdapterInfo)
-        {
-            _tprintf(_T("0x%lu ........................... "
-#if UNICODE
-                        "%hs\n"),
-#else
-                        "%s\n"),
-#endif
-                     pAdapterInfo->Index, pAdapterInfo->Description);
-            pAdapterInfo = pAdapterInfo->Next;
-        }
-        _tprintf(_T("===========================================================================\n"));
-
-        _tprintf(_T("===========================================================================\n"));
-        _tprintf(_T("Active Routes:\n"));
-        _tprintf( _T("%-27s%-17s%-14s%-11s%-10s\n"),
-                  _T("Network Destination"),
-                  _T("Netmask"),
-                  _T("Gateway"),
-                  _T("Interface"),
-                  _T("Metric") );
-        for( i = 0; i < IpForwardTable->dwNumEntries; i++ )
-        {
-            _stprintf( Destination,
-#if UNICODE
-                       _T("%hs"),
-#else
-                       _T("%s"),
-#endif
-                       inet_ntoa( IN_ADDR_OF(IpForwardTable->table[i].dwForwardDest) ) );
-            _stprintf( Netmask,
-#if UNICODE
-                       _T("%hs"),
-#else
-                       _T("%s"),
-#endif
-                       inet_ntoa( IN_ADDR_OF(IpForwardTable->table[i].dwForwardMask) ) );
-            _stprintf( Gateway,
-#if UNICODE
-                       _T("%hs"),
-#else
-                       _T("%s"),
-#endif
-                       inet_ntoa( IN_ADDR_OF(IpForwardTable->table[i].dwForwardNextHop) ) );
-
-            _tprintf( _T("%17s%17s%17s%16ld%9ld\n"),
-                      Destination,
-                      Netmask,
-                      Gateway,
-                      IpForwardTable->table[i].dwForwardIfIndex,
-                      IpForwardTable->table[i].dwForwardMetric1 );
-        }
-        _tprintf(_T("Default Gateway:%18s\n"), DefGate);
-        _tprintf(_T("===========================================================================\n"));
-        _tprintf(_T("Persistent Routes:\n"));
-
-        free(IpForwardTable);
-        free(pAdapterInfo);
-
-        return ERROR_SUCCESS;
-    }
-    else
-    {
-Error:
-        _ftprintf( stderr, _T("Route enumerate failed\n") );
-        return Error;
-    }
-}
-
-static int convert_add_cmd_line( PMIB_IPFORWARDROW RowToAdd,
-              int argc, TCHAR **argv ) {
-    int i;
-#if UNICODE
-    char addr[16];
-#endif
-
-    if( argc > 1 )
-    {
-#if UNICODE
-        sprintf( addr, "%ls", argv[0] );
-        RowToAdd->dwForwardDest = inet_addr( addr );
-#else
-        RowToAdd->dwForwardDest = inet_addr( argv[0] );
-#endif
-    }
-    else
-        return FALSE;
-    for( i = 1; i < argc; i++ )
-    {
-        if( !_tcscmp( argv[i], _T("mask") ) )
-        {
-            i++; if( i >= argc ) return FALSE;
-#if UNICODE
-            sprintf( addr, "%ls", argv[i] );
-            RowToAdd->dwForwardDest = inet_addr( addr );
-#else
-            RowToAdd->dwForwardMask = inet_addr( argv[i] );
-#endif
-        }
-        else if( !_tcscmp( argv[i], _T("metric") ) )
-        {
-            i++;
-            if( i >= argc )
-                return FALSE;
-            RowToAdd->dwForwardMetric1 = _ttoi( argv[i] );
-        }
-        else
-        {
-#if UNICODE
-            sprintf( addr, "%ls", argv[i] );
-            RowToAdd->dwForwardNextHop = inet_addr( addr );
-#else
-            RowToAdd->dwForwardNextHop = inet_addr( argv[i] );
-#endif
-        }
-    }
-
-    return TRUE;
-}
-
-static int add_route( int argc, TCHAR **argv ) {
-    MIB_IPFORWARDROW RowToAdd = { 0 };
-    DWORD Error;
-
-    if( argc < 2 || !convert_add_cmd_line( &RowToAdd, argc, argv ) )
-    {
-        _ftprintf( stderr,
-                   _T("route add usage:\n"
-                      "route add <target> [mask <mask>] <gw> [metric <m>]\n"
-                      "  Adds a route to the IP route table.\n"
-                      "  <target> is the network or host to add a route to.\n"
-                      "  <mask>   is the netmask to use (autodetected if unspecified)\n"
-                      "  <gw>     is the gateway to use to access the network\n"
-                      "  <m>      is the metric to use (lower is preferred)\n") );
-        return 1;
-    }
-
-    if( (Error = CreateIpForwardEntry( &RowToAdd )) == ERROR_SUCCESS )
-        return 0;
-
-    _ftprintf( stderr, _T("Route addition failed\n") );
-    return Error;
-}
-
-static int del_route( int argc, TCHAR **argv )
-{
-    MIB_IPFORWARDROW RowToDel = { 0 };
-    DWORD Error;
-
-    if( argc < 2 || !convert_add_cmd_line( &RowToDel, argc, argv ) )
-    {
-        _ftprintf( stderr,
-                    _T("route delete usage:\n"
-                       "route delete <target> <gw>\n"
-                       "  Removes a route from the IP route table.\n"
-                       "  <target> is the network or host to add a route to.\n"
-                       "  <gw>     is the gateway to remove the route from.\n") );
-        return 1;
-    }
-
-    if( (Error = DeleteIpForwardEntry( &RowToDel )) == ERROR_SUCCESS )
-        return 0;
-
-    _ftprintf( stderr, _T("Route addition failed\n") );
-    return Error;
-}
-
-#if defined(_UNICODE) && defined(__GNUC__)
-static
-#endif
-int _tmain( int argc, TCHAR **argv )
-{
-    if( argc < 2 )
-        return Usage();
-    else if ( !_tcscmp( argv[1], _T("print") ) )
-        return PrintRoutes();
-    else if( !_tcscmp( argv[1], _T("add") ) )
-        return add_route( argc-2, argv+2 );
-    else if( !_tcscmp( argv[1], _T("delete") ) )
-        return del_route( argc-2, argv+2 );
-    else
-        return Usage();
-}
-
-#if defined(_UNICODE) && defined(__GNUC__)
-/* HACK - MINGW HAS NO OFFICIAL SUPPORT FOR wmain()!!! */
-int main( int argc, char **argv )
-{
-    WCHAR **argvW;
-    int i, j, Ret = 1;
-
-    if ((argvW = malloc(argc * sizeof(WCHAR*))))
-    {
-        /* convert the arguments */
-        for (i = 0, j = 0; i < argc; i++)
-        {
-            if (!(argvW[i] = malloc((strlen(argv[i]) + 1) * sizeof(WCHAR))))
-            {
-                j++;
-            }
-            swprintf(argvW[i], L"%hs", argv[i]);
-        }
-        
-        if (j == 0)
-        {
-            /* no error converting the parameters, call wmain() */
-            Ret = wmain(argc, argvW);
-        }
-        
-        /* free the arguments */
-        for (i = 0; i < argc; i++)
-        {
-            if (argvW[i])
-                free(argvW[i]);
-        }
-        free(argvW);
-    }
-    
-    return Ret;
-}
-#endif
diff --git a/reactos/apps/utils/net/route/route.rc b/reactos/apps/utils/net/route/route.rc
deleted file mode 100644 (file)
index 09b9107..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-/* $Id$ */
-
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS TCP/IPv4 Win32 Route\0"
-#define REACTOS_STR_INTERNAL_NAME      "route\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "route.exe\0"
-#define REACTOS_STR_ORIGINAL_COPYRIGHT "Art Yerkes (arty@users.sourceforge.net)\0"
-#include <reactos/version.rc>
diff --git a/reactos/apps/utils/net/route/route.xml b/reactos/apps/utils/net/route/route.xml
deleted file mode 100644 (file)
index 66c1472..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-<module name="route" type="win32cui" installbase="system32" installname="route.exe">
-       <include base="route">.</include>
-       <define name="__USE_W32API" />
-       <define name="UNICODE" />
-       <define name="_UNICODE" />
-       <library>kernel32</library>
-       <library>ws2_32</library>
-       <library>iphlpapi</library>
-       <file>route.c</file>
-       <file>route.rc</file>
-</module>
diff --git a/reactos/apps/utils/net/telnet/Makefile.mingw b/reactos/apps/utils/net/telnet/Makefile.mingw
deleted file mode 100644 (file)
index 9aab1f5..0000000
+++ /dev/null
@@ -1,142 +0,0 @@
-#
-# Makefile for Console Telnet
-# Last modified 4/15/2000 by Paul Brannan
-#
-
-SRCDIR=./src
-OBJDIR=src
-RESDIR=resource
-
-SRC=$(wildcard $(SRCDIR)/*.cpp)
-RESOURCES=$(wildcard $(RESDIR)/*.rc)
-OBJ1=$(SRC:.c=.o)
-OBJ=$(OBJ1:.cpp=.o) $(RESOURCES:.rc=.o)
-
-INCLUDES=-I$(RESDIR)
-
-OUT=telnet.exe
-
-# Modify these for your system if necessary
-# Note: DJGPP+RDXNTDJ configuration is untested.
-
-# --CYGWIN--
-#CC=gcc
-#CCC=g++
-#LDFLAGS=-lwsock32 -lmsvcrt
-#CFLAGS=-O2 -Wall -mwindows -mno-cygwin -D__CYGWIN__
-#CCFLAGS=$(CFLAGS)
-#RES=
-#RC=windres
-#RCFLAGS=-O coff
-
-# --MINGW32(+EGCS)--
-CC=gcc
-CCC=g++
-LDFLAGS=-lkernel32 -luser32 -lgdi32 -lshell32 -lwsock32
-CFLAGS=-O2 -Wall
-CCFLAGS=$(CFLAGS)
-RES=
-RC=windres
-RCFLAGS=
-
-# --DJGPP+RSXNTDJ--
-#CC=gcc -Zwin32 -Zmt -Zcrtdll
-#CCC=$(CC)
-#LDFLAGS=
-#CFLAGS= -g
-#CCFLAGS=$(CFLAGS)
-#RES=rsrc
-#RC=grc
-#RCFLAGS=-r
-
-
-# You should not have to modify anything below this line
-
-all: dep $(OUT)
-
-.SUFFIXES: .c .cpp .rc
-
-.c.o:
-       $(CC) $(INCLUDES) $(CFLAGS) -c $< -o $@
-
-.cpp.o:
-       $(CCC) $(INCLUDES) $(CCFLAGS) -c $< -o $@
-
-.rc.o:
-       $(RC) -i $< $(RCFLAGS) -o $@
-
-$(OUT): $(OBJ)
-       $(CCC) $(OBJ) $(LDFLAGS) $(LIBS) -o $(OUT)
-       strip $(OUT)
-
-depend: dep
-
-dep:
-       start /min makedepend -- $(CFLAGS) -- $(INCLUDES) $(SRC)
-
-clean:
-       del $(OBJDIR)\*.o
-       del $(OUT)
-
-# DO NOT DELETE
-
-./src/ansiprsr.o: ./src/ansiprsr.h ./src/tnconfig.h ./src/tnerror.h
-./src/ansiprsr.o: ./src/tnmsg.h ./src/tparser.h ./src/tconsole.h
-./src/ansiprsr.o: ./src/keytrans.h ./src/tkeydef.h ./src/tkeymap.h
-./src/ansiprsr.o: ./src/stl_bids.h ./src/tscroll.h ./src/tmouse.h
-./src/ansiprsr.o: ./src/tnclip.h ./src/tnetwork.h ./src/tcharmap.h
-./src/keytrans.o: ./src/keytrans.h ./src/tkeydef.h ./src/tkeymap.h
-./src/keytrans.o: ./src/stl_bids.h ./src/tnerror.h ./src/tnmsg.h
-./src/tcharmap.o: ./src/tcharmap.h ./src/tnconfig.h ./src/tnerror.h
-./src/tcharmap.o: ./src/tnmsg.h
-./src/tconsole.o: ./src/tconsole.h ./src/tnconfig.h ./src/tnerror.h
-./src/tconsole.o: ./src/tnmsg.h
-./src/tkeydef.o: ./src/tkeydef.h
-./src/tkeymap.o: ./src/tkeymap.h ./src/stl_bids.h ./src/tkeydef.h
-./src/tmapldr.o: ./src/tmapldr.h ./src/keytrans.h ./src/tkeydef.h
-./src/tmapldr.o: ./src/tkeymap.h ./src/stl_bids.h ./src/tcharmap.h
-./src/tmapldr.o: ./src/tnerror.h ./src/tnmsg.h ./src/tnconfig.h
-./src/tmouse.o: ./src/tmouse.h ./src/tnclip.h ./src/tnetwork.h
-./src/tmouse.o: ./src/tconsole.h ./src/tnconfig.h ./src/tnerror.h
-./src/tmouse.o: ./src/tnmsg.h
-./src/tnclass.o: ./src/tnclass.h ./src/tnconfig.h ./src/tnerror.h
-./src/tnclass.o: ./src/tnmsg.h ./src/ttelhndl.h ./src/tparser.h
-./src/tnclass.o: ./src/tconsole.h ./src/keytrans.h ./src/tkeydef.h
-./src/tnclass.o: ./src/tkeymap.h ./src/stl_bids.h ./src/tscroll.h
-./src/tnclass.o: ./src/tmouse.h ./src/tnclip.h ./src/tnetwork.h
-./src/tnclass.o: ./src/tcharmap.h ./src/tncon.h ./src/tparams.h
-./src/tnclass.o: ./src/ansiprsr.h ./src/tmapldr.h ./src/tnmisc.h
-./src/tnclip.o: ./src/tnclip.h ./src/tnetwork.h
-./src/tncon.o: ./src/tncon.h ./src/tparams.h ./src/ttelhndl.h ./src/tparser.h
-./src/tncon.o: ./src/tconsole.h ./src/tnconfig.h ./src/tnerror.h
-./src/tncon.o: ./src/tnmsg.h ./src/keytrans.h ./src/tkeydef.h ./src/tkeymap.h
-./src/tncon.o: ./src/stl_bids.h ./src/tscroll.h ./src/tmouse.h ./src/tnclip.h
-./src/tncon.o: ./src/tnetwork.h ./src/tcharmap.h
-./src/tnconfig.o: ./src/tnconfig.h ./src/tnerror.h ./src/tnmsg.h
-./src/tnerror.o: ./src/tnerror.h ./src/tnmsg.h ./src/ttelhndl.h
-./src/tnerror.o: ./src/tparser.h ./src/tconsole.h ./src/tnconfig.h
-./src/tnerror.o: ./src/keytrans.h ./src/tkeydef.h ./src/tkeymap.h
-./src/tnerror.o: ./src/stl_bids.h ./src/tscroll.h ./src/tmouse.h
-./src/tnerror.o: ./src/tnclip.h ./src/tnetwork.h ./src/tcharmap.h
-./src/tnetwork.o: ./src/tnetwork.h
-./src/tnmain.o: ./src/tnmain.h ./src/tncon.h ./src/tparams.h ./src/ttelhndl.h
-./src/tnmain.o: ./src/tparser.h ./src/tconsole.h ./src/tnconfig.h
-./src/tnmain.o: ./src/tnerror.h ./src/tnmsg.h ./src/keytrans.h
-./src/tnmain.o: ./src/tkeydef.h ./src/tkeymap.h ./src/stl_bids.h
-./src/tnmain.o: ./src/tscroll.h ./src/tmouse.h ./src/tnclip.h
-./src/tnmain.o: ./src/tnetwork.h ./src/tcharmap.h ./src/tnclass.h
-./src/tnmain.o: ./src/ansiprsr.h ./src/tmapldr.h ./src/tnmisc.h
-./src/tnmisc.o: ./src/tnmisc.h
-./src/tscript.o: ./src/tscript.h ./src/tnetwork.h
-./src/tscroll.o: ./src/tscroll.h ./src/tconsole.h ./src/tnconfig.h
-./src/tscroll.o: ./src/tnerror.h ./src/tnmsg.h ./src/tmouse.h ./src/tnclip.h
-./src/tscroll.o: ./src/tnetwork.h ./src/tncon.h ./src/tparams.h
-./src/tscroll.o: ./src/ttelhndl.h ./src/tparser.h ./src/keytrans.h
-./src/tscroll.o: ./src/tkeydef.h ./src/tkeymap.h ./src/stl_bids.h
-./src/tscroll.o: ./src/tcharmap.h
-./src/ttelhndl.o: ./src/ttelhndl.h ./src/tparser.h ./src/tconsole.h
-./src/ttelhndl.o: ./src/tnconfig.h ./src/tnerror.h ./src/tnmsg.h
-./src/ttelhndl.o: ./src/keytrans.h ./src/tkeydef.h ./src/tkeymap.h
-./src/ttelhndl.o: ./src/stl_bids.h ./src/tscroll.h ./src/tmouse.h
-./src/ttelhndl.o: ./src/tnclip.h ./src/tnetwork.h ./src/tcharmap.h
-./src/ttelhndl.o: ./src/telnet.h ./src/tparams.h
diff --git a/reactos/apps/utils/net/telnet/doc/00readme.avs b/reactos/apps/utils/net/telnet/doc/00readme.avs
deleted file mode 100644 (file)
index fe0e2d2..0000000
+++ /dev/null
@@ -1,261 +0,0 @@
-Hi!
-
-Now I come back to telnet source, and make some changes, wich you suggest
-to me:
-
-1.  telnet.rc renamed to telnet.cfg
-2.  I change syntax of 'keys' command (but I did'nt found a tool for edit
-    msg*.bin files - so it's remain unchanged). Syntax are
-
-        keys load keymapname [file]
-        keys display
-        keys switch number
-
-
-I fix some 'political' ;) problem with charmap, now we (citizens of xUSSR)
-have koi8, koi8r and koi8u(RFC on draft) on UNIX, wich are diff's on 6 or
-8 letters; cp866 and many (3 or 4) very near to cp866 on DOS.
-
-So, I rewrite code to able a charmap addition like a keymap done.
-
-And I make more smart command line processing, look at telCommandLine().
-
-And last: my english is not so good :( to rewrite documentation, but there are
-things, wich would be described - look on next page. I think that you will
-translate my english to more understable, ok?
-
-and now is a list of files, wich I touch
-
-
-                            old                         new
-
-ANSIPRSR.CPP        32763  05.10.97  11:09    33237  24.12.97  17:42
-ANSIPRSR.H           3311  04.09.97   0:25     3410  23.12.97  13:18
-KEYTRANS.CPP         9504  28.05.97  22:43    26547  03.02.98  21:33
-KEYTRANS.H           8020  25.01.97  16:06     8090  03.02.98  19:53
-TNCLASS.CPP         13663  17.08.97  23:55    13891  03.02.98  20:09
-TNCLASS.H            1112  01.06.97  14:19     1233  03.02.98  20:09
-TNMAIN.CPP          12668  02.10.97  20:38    16610  03.02.98  21:22
-TNNET.CPP            3445  01.06.97  14:21     3474  23.12.97  13:16
-TNPARSER.CPP        17653  05.10.97  11:09    17715  23.12.97  18:03
-TNPARSER.H           2129  01.06.97  14:22     2188  23.12.97  13:25
-
-KEYS.CFG            erased
-TELNET.CFG          new
-
-TELNET.IDE          65810  26.10.97  16:53    66118  03.02.98  21:34
-
-
-I was start my work with file telc2b4s.zip with size 132619 bytes, and now send
-to you just files, wich I touch.
-
-with best regards
-Andrei V. Smilianets
-
-smile@head.aval.kiev.ua
-22:25 03 Feb 1998
-
-
-\f
-There are all of my changes (from 2.04b), wich have to be described:
-
-1. command line (telnet>) processing
-
-   a 'keys' command
-
-        was
-                keys keymapname [file]
-        new
-                keys load keymapname [file] // mean unchanged
-                keys display                // display a list of loaded keymaps
-                keys switch number          // switch to keymap
-
-   more smart command processing
-
-        command might be writed shortly
-
-          cl[ose]
-          op[en]
-          ke[ys]
-          qu[it]
-
-        subcommands of 'keys'
-
-          l[oad]
-          d[isplay]
-          s[witch]
-
-        synonym of '?' -> h[elp]
-
-2. file 'keys.cfg' renamed to 'telnet.cfg'
-
-3. Added codepage conversion, look [charmap]
-
-4. completely changed conception of telnet.cfg
-
-   Now you can define multiple keymaps, character maps, combine it in your
-   ways.
-
-   file is splitted into following sections:
-
-    [COMMENT]
-     ...
-    [END COMMENT]
-
-        it is for comment a big part of text. can be nested.
-        in text also work:
-
-           ; - first printable character in line, which is completelly
-               ignored.
-           // - like C++ comment
-
-    [GLOBAL]
-    ...
-    [END GLOBAL]
-
-        mean of [global] unchanged
-
-    [KEYMAP name]
-    ...
-    [END KEYMAP]
-        'name' - is a keymap name for reference. in 'name' you can use
-        any char exept spaces, '+', ':' and ']'. '+' and ':' reserved for
-        CONFIG section.
-        body is a sequence of key definition:
-
-           <vk_name> [keymodifier[+keymodifier[+...]]] <keytranslation>
-
-        example:
-           VK_F1 RIGHT_ALT+RIGHT_CTRL this_would_print
-
-        vk_name is an ASCII string equivalent to an entry in [GLOBAL].
-
-        valid keymodifiers are:
-          RIGHT_ALT
-          LEFT_ALT
-          RIGHT_CTRL
-          LEFT_CTRL
-          SHIFT
-          ENHANCED
-
-        Undefined enhanced keys will use the non-enhanced definition.
-
-        keytranslation is the string you want printed for the key.
-        The notation ^[ can be used to denote an escape character.
-        Any ASCII value can be represented by
-
-            \nnn where nnn is a 3 digit decimal ASCII value or
-            \xhh where hh is a 2 digit hexadecimal ASCII value.
-
-        Leading zeros may not be omitted.
-        A value of \000(\x00) will not be transmitted.
-
-        note: In order to have both left and right alt have the same
-        action, you must create a separate def for left and right.
-
-
-    [CHARMAP name]
-    ...
-    [END CHARMAP]
-        'name' - is a charmap name for reference. requirements is the same
-        as for keymap name.
-        body is a sequence of char conversion definition:
-
-           <host_char> <console_char>
-
-        where host_char is a char received from host, and console_char
-        is a char, which would be displayed on console.
-
-        The main purpose of it is a conversion between differents code
-        pages, for example, on former USSR part of world most unix's hosts
-        uses 'koi8' code page, and on W95 machines - 866 code page and
-        (as say I.Ioannou)  Greece has the same problem with 737 and 928
-        code-pages.
-
-
-        Any ASCII value can be represented by
-
-            \nnn where nnn is a 3 digit decimal ASCII value or
-            \xhh where hh is a 2 digit hexadecimal ASCII value.
-
-        Leading zeros may be omitted.
-        A value of \000(\x00) will not be accepted.
-
-        look for example at [charmap koi8-cp866].
-
-    [CONFIG name]
-    ...
-    [END CONFIG]
-        'name' - is a configuration name for reference. requirements is
-        the same as for keymap name.
-
-        you must define one with name 'default', which will be used as
-        default.
-
-        in body of this part you can combine keymaps and set charmap,
-        format is:
-
-           KEYMAP name_list [: <vk_name> [keymodifier[+keymodifier[+...]]] ]
-
-             where
-                  name_list:
-                     keymap_name
-                     keymap_name '+' name_list
-
-                  keymap_name is a name of [KEYMAP]
-
-             You can specify multiple keymaps, for first (mean default)
-             you can not define ': <vk_name> ...' part, but for rests
-             (secondary) you must!
-             The ': <vk_name> ...' part define a key for switch to this
-             keymap.
-
-             Assigning a switching key to first (default) keymap will be
-             ignored, but you can switch to by pressing second time switch
-             key of current keymap.
-
-             If a key not found in switched keymap, a program will be look
-             for it in default keymap. So, you can redefine only needed keys
-             in secondary keymaps.
-
-           CHARMAP name_list
-
-                where
-                      name_list:
-                                charmap_name
-                                charmap_name '+' name_list
-
-                      charmap_name is a name of [CHARMAP]
-
-
-             define wich charmap(s) is to use.
-
-           examples:
-              [config default]
-                 keymap default
-              [end config]
-
-              [config linux]
-                 keymap default + linux
-              [end config]
-
-              [config default_koi8]
-                 keymap default
-                 keymap koi8u + koi8r : VK_/ RIGHT_ALT // russian keyboard
-                 keymap koi8u         : VK_. RIGHT_ALT // ukranian
-
-                 charmap koi8-cp866
-              [end config]
-
-              [config linux_koi8]
-                 keymap default + linux
-                 keymap koi8u + koi8r : VK_/ RIGHT_ALT // russian keyboard
-                 keymap koi8u         : VK_. RIGHT_ALT // ukranian
-
-                 charmap koi8-cp866 + koi8u-cp866
-              [end config]
-
-            so, for switch to russian keyboard just press RIGHT_ALT and '/'.
-            and, for switch back to default press it again.
-
-
diff --git a/reactos/apps/utils/net/telnet/doc/bugs.txt b/reactos/apps/utils/net/telnet/doc/bugs.txt
deleted file mode 100644 (file)
index 52e1794..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-                **********************************************
-                *** Console Telnet 2.1 beta 2.  Known Bugs ***
-                **********************************************
-
-
-Wrap_Line = 0   Doesn't work very well. It works with elvis or talk on linux,
-                but messes up bash at last line.
-
-Enable_Mouse=1  Causes the display to slow in fullscreen mode, since the
-                mouse has to be erased and then drawn again for every
-                screen write.
-
-Term_Width or Term_Height != -1 or Wide_Enable=1
-                Specifying any of these can cause display problems if
-                the font size is not set to auto.
-
-Resizing the current window while running telnet can cause problems, especially
-if doing so makes the buffer smaller.  This should be more of a problem on
-NT/W2K than on 95/98.  Part of the problem is that the telnet NAWS option
-negotiation isn't done properly.  On a related note, turning on scrollbars can
-decrease performance.
-
-There are many other bugs, most of which are documented in the code.  Just
-grep the source for "FIX ME".
diff --git a/reactos/apps/utils/net/telnet/doc/changes.txt b/reactos/apps/utils/net/telnet/doc/changes.txt
deleted file mode 100644 (file)
index 4e03d47..0000000
+++ /dev/null
@@ -1,239 +0,0 @@
-                **********************************************
-                *** Console Telnet version 2.1 Change log  ***
-                **********************************************
-
-Version 2.1b2 -- October 16, 2000
-  Redirection fix (Mark Miesfield)
-  Allow "o" to open a connecton on the command line
-  Fixed problem with special keys (ALt-[, Alt-], Alt-\, etc.)
-  Added MTE Support (Ziglio Frediano)
-  Speed improvements in ttelhndl.cpp -- may be buggy?
-  Wrap_line option is now modifiable via telnet command line
-  Lock_linewrap option added
-  Cleaned up console code
-  Fixed some color issues with nonstandard consoles
-  Tab setting/resetting
-  Fixed "telnet.exe" installer problem
-  Fixed miscellaneous parsing bugs
-  Fixed vt100-compliance
-  Added NAWS support, but it doesn't work (RFC 1073)
-  Added X Display Location support (RFC 1096)
-
-Version 2.1b1 -- April 5, 2000
--Bugfixes
-  Console code writes to bottom of buffer (W2K scrollback buffer now works)
-  Updated Winsock error messages (Craig Nellist)
-  Sleeping while thread paused, to give up CPU time (Craig Nellist)
-  Ctrl_Break_as_C now works properly
-  Restore original screen colors; use initial screen colors as default
-
--New features
-  Cursor size sequences (Jose Cesar Otero Ridriguez)
-  Network piping
-  Line mode support added
-  Support for telnet:// URLs
-  Command-line history (Craig Nellist)
-  Connection Aliases
-
--Translator updates
-  New code structure
-  Unified character map class
-  More configurable "special" keys:
-    tn_escape, tn_scrollback, tn_dial, tn_paste, tn_null, tn_cr, tn_crlf
-  Transmission of NUL character possible
-  Czech keyboard definition (Jakub Sterba)
-
--New INI options
-  Window_Width, Window_Height
-  Scriptname (not functional), Script_Enable (not functional)
-  Netpipe (functional), Iopipe (not functional)
-
-Version 2.0 -- July 5, 1999
--Bugfixes
-  Save/restore console title, character mapping fix (Pedro Gutierrez)
-  Telnet prompt fix, suspend telnet, string-based port (Craig Davidson)
-  Mutt/Lynx colors/underline fix, repeat character fix
-  Color display problem fixed (I.Ioannou)
-  Newline properly handled, added APP4_KEY, better key translation
-  Problem with icons not displaying properly fixed
-  Small bug with telnet crashing at exit (Sam Robertson, Daniel Straub)
-  Bug getting name of executable (Thomas Briggs)
-
--Updates
-  Better key translation
-  Spanish keyboard definition (Cesar Otero)
-
--New ini options
-  Set_Title (Adi Seiker)
-  Scroll_Enable/Scroll_Size
-  CtrlBreak_as_CtrlC (Bryan Montgomery)
-  Clear_on_Tabset removed
-  
-Version 2.0b7.1 -- Dec. 5, 1998
--Minor changes
-  Fixed problems with Scrollback and Clipboard
-  Minor updates to terminal emulation
-  Keyboard init improvements (Vassili Bourdo)
-  Repeat sequence support, German key config (Titus von Boxberg)
-
-Version 2.0b7 -- Oct. 21, 1988
--To do still:
-  ZModem support
-  Update key translator/character maps
-  Finish scrollback
-
--Changes
-  Options added: Term_Width, Term_Height, Wide_Enable, Buffer_Size, Dial_key,
-        Keyboard_Paste, Status_bg, Status_fg, Input_Redir, Output_Redir
-
-  Application keypad mode support
-  Numlock/scroll lock support in KEYS.CFG
-  Del/. key now works properly
-  Ctrl-break bugfixes (Thomas Briggs)
-
-  Added suspend and fast quit to the command line (Thomas Briggs)
-  Error message for unable to load ini file (Thomas Briggs)
-  Fixed TELNET_INI environment variable (BK Oxley)
-
-  Support for changing screen size
-  Support for switching to 132-column mode via ANSI sequences
-
-  Fixed minor memory leaks
-  Mouse speedups/bugfixes, scrolling speedups/bugfixes
-  Miscellaneous ANSI parser fixes
-
-  Added support for changing the icon in the corner of the window
-  Fixed bug with mIRC
-  Fixed "try again" error message
-  Input and output redirection now separate (TELNET_REDIR still supported)
-  Modified "set" command to operate on groups
-  Character mapping now works again
-
-Version 2.0b6 28 Jul 1998
--To Do still:
-  ZModem support
-  Finish mouse support
-  Fix character maps
-
--Changes:
-  ANSI Parser should be almost complete
-  Reorganized source
-  Display speedups
-  Preliminary mouse support
-  Enhanced scrollback support
-  Miscellaneous bug fixes
-
-Version 2.0b5 05 Jun 1998
--Version 2b5 released from I.Ioannou <roryt@hol.gr>
--To Do Still:
-  Too many to mention :-)
--To Do, Maybe:
-  Mouse cut/paste support.
-  Support secure telnet options.
-  Real blinking attributes.
-  Zmodem & Kermit DL Protocols.
-  Any ideas acceptable :-)
-
-
-May 1998
--Changes
-   Paul Brannan <pbranna@clemson.edu> add telnet.ini code
-   improve telnet's speed, add some VT emulation, port telnet to
-   MSVC, rewrote the command line options processing with GNU getopt,
-   fix many bugs, and more.  Good work Paul :-)
-   I.Ioannou <roryt@hol.gr> . A few bugs fixes, and a icon.
-   Also I convert tnmsg files to use a resource compiler.
-
-December 1997
--Changes
-    Andrey V. Smilianets (smile@head.aval.kiev.ua)
-    rewrote the keys translator to support many different
-    keymaps, charmaps and configurations.
-    Also add editing support to telnet> prompt.
-
-
-Version 2.0b4 10/6/97
--Updated by Brad Johnson who can be contacted at
-  <jbj@nounname.com>  http://nounname.com
--Changes
-  Added command line history at the telnet> prompt.
-  Added ability to "unmap" a key by setting it equal to \000 in the key.cfg.
-  Added log-file option '-dFILENAME'.
-  Added print screen/line commands by I.Ioannou <roryt@hol.gr>.
-  Added Support for running in an emacs buffer <mauch@unidui.uni-duisburg.de>.
-  Added better support for international character sets
-     <mauch@unidui.uni-duisburg.de>.
--To Do Still:
-  Support for local echo.
-  Scrollback buffer.
-  Fix Scrolling bug.
--To Do, Maybe:
-  Change the telnet options to initiate the negotiation.
-  Mouse cut/paste support.
-  Support secure telnet options.
-  Real blinking attributes.
-  Zmodem & Kermit DL Protocols.
-
-Version 2.0b3  12/25/96:
--Updated by Brad Johnson who can be contacted at
-  <jbj@nounname.com>  http://nounname.com
--Changes
-  Screen colors and buffer settings are now preserved on exit.
-  Fixed WindowSize height/width 255 exception :-).
-  Found out that the paste problem is a bug in Win 95 (not my problem)!
-  Fixed screen buffer problems under NT when the window
-    was smaller than the buffer.
-  Added custom key maps by I.Ioannou <roryt@hol.gr>.
--To Do Still:
-  Fix advance to next line error when writing past column
-  Extend NAWS window negotiation to include buffer size changes.
-  Change the telnet options to initiate the negotiation.
-  Add print screen/line commands.
--To Do, Maybe:
-  Support for running in an emacs buffer.
-  Mouse cut/paste support.
-  Support secure telnet options.
-  Real blinking attributes.
-  Zmodem & Kermit DL Protocols.
-
-Version 2.0b2  09/29/96:
--Updated by Brad Johnson who can be contacted at
-  <jbj@nounname.com>  http://nounname.com
--Changes
-  Added code to move cursor to end of screen and reset attributes on close
-  Fixed potential IAC parsing problem
-  Fixed ClearScreen Last line problem
-  Fixed parse problem that prevented line clears on unix history
-  Changed scroll code to scroll the entire buffer
-  Removed destructive backspace. May cause problems with terminals that want
-    destructive backspaces.
-  Added binary telnet option to use 8bit.
--To Do Next
-  Paste still doesn't work!
-
-Version 2.0b1  09/22/96:
--Updated by Brad Johnson who can be contacted at
-  <jbj@nounname.com>  http://nounname.com
--Changes
-  Added Color ANSI support. It works!
-  Added option for user specified port addresses on the command line.
-  Added ANSI keyboard mapping support for cursor keys.
-  Added destructive Backspace.
-  Added escape key 'ALT-]'.
-  Added TermType and WindowSize telnet options.
-  Added/Fixed various other ANSI codes.
-  Now (I hope) all ANSI codes handled correctly!
-  Fixed cursor left/right/save/restore commands.
-  Fixed clear line and clear screen command.
-  Expanded and altered network buffer to prevent some lockups :-).
-  Added Unix style telnet prompt "telnet>" with options.
--To Do Next
-  Should parse for IAC separate from ANSI.
-
-Version 1.0a:
-- This release fixes a bug which caused it to hang when connecting to
-  UNIX boxes. The program simply ignored Telnet DO instead of replying
-  with WON'T as required by RFC 854.
-
-Version 1.0:
-- First release
diff --git a/reactos/apps/utils/net/telnet/doc/license.txt b/reactos/apps/utils/net/telnet/doc/license.txt
deleted file mode 100644 (file)
index 3358a7b..0000000
+++ /dev/null
@@ -1,340 +0,0 @@
-                   GNU GENERAL PUBLIC LICENSE
-                      Version 2, June 1991
-
- Copyright (C) 1989, 1991 Free Software Foundation, Inc.
-                          675 Mass Ave, Cambridge, MA 02139, USA
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
-                           Preamble
-
-  The licenses for most software are designed to take away your
-freedom to share and change it.  By contrast, the GNU General Public
-License is intended to guarantee your freedom to share and change free
-software--to make sure the software is free for all its users.  This
-General Public License applies to most of the Free Software
-Foundation's software and to any other program whose authors commit to
-using it.  (Some other Free Software Foundation software is covered by
-the GNU Library General Public License instead.)  You can apply it to
-your programs, too.
-
-  When we speak of free software, we are referring to freedom, not
-price.  Our General Public Licenses are designed to make sure that you
-have the freedom to distribute copies of free software (and charge for
-this service if you wish), that you receive source code or can get it
-if you want it, that you can change the software or use pieces of it
-in new free programs; and that you know you can do these things.
-
-  To protect your rights, we need to make restrictions that forbid
-anyone to deny you these rights or to ask you to surrender the rights.
-These restrictions translate to certain responsibilities for you if you
-distribute copies of the software, or if you modify it.
-
-  For example, if you distribute copies of such a program, whether
-gratis or for a fee, you must give the recipients all the rights that
-you have.  You must make sure that they, too, receive or can get the
-source code.  And you must show them these terms so they know their
-rights.
-
-  We protect your rights with two steps: (1) copyright the software, and
-(2) offer you this license which gives you legal permission to copy,
-distribute and/or modify the software.
-
-  Also, for each author's protection and ours, we want to make certain
-that everyone understands that there is no warranty for this free
-software.  If the software is modified by someone else and passed on, we
-want its recipients to know that what they have is not the original, so
-that any problems introduced by others will not reflect on the original
-authors' reputations.
-
-  Finally, any free program is threatened constantly by software
-patents.  We wish to avoid the danger that redistributors of a free
-program will individually obtain patent licenses, in effect making the
-program proprietary.  To prevent this, we have made it clear that any
-patent must be licensed for everyone's free use or not licensed at all.
-
-  The precise terms and conditions for copying, distribution and
-modification follow.
-\f
-                   GNU GENERAL PUBLIC LICENSE
-   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
-
-  0. This License applies to any program or other work which contains
-a notice placed by the copyright holder saying it may be distributed
-under the terms of this General Public License.  The "Program", below,
-refers to any such program or work, and a "work based on the Program"
-means either the Program or any derivative work under copyright law:
-that is to say, a work containing the Program or a portion of it,
-either verbatim or with modifications and/or translated into another
-language.  (Hereinafter, translation is included without limitation in
-the term "modification".)  Each licensee is addressed as "you".
-
-Activities other than copying, distribution and modification are not
-covered by this License; they are outside its scope.  The act of
-running the Program is not restricted, and the output from the Program
-is covered only if its contents constitute a work based on the
-Program (independent of having been made by running the Program).
-Whether that is true depends on what the Program does.
-
-  1. You may copy and distribute verbatim copies of the Program's
-source code as you receive it, in any medium, provided that you
-conspicuously and appropriately publish on each copy an appropriate
-copyright notice and disclaimer of warranty; keep intact all the
-notices that refer to this License and to the absence of any warranty;
-and give any other recipients of the Program a copy of this License
-along with the Program.
-
-You may charge a fee for the physical act of transferring a copy, and
-you may at your option offer warranty protection in exchange for a fee.
-
-  2. You may modify your copy or copies of the Program or any portion
-of it, thus forming a work based on the Program, and copy and
-distribute such modifications or work under the terms of Section 1
-above, provided that you also meet all of these conditions:
-
-    a) You must cause the modified files to carry prominent notices
-    stating that you changed the files and the date of any change.
-
-    b) You must cause any work that you distribute or publish, that in
-    whole or in part contains or is derived from the Program or any
-    part thereof, to be licensed as a whole at no charge to all third
-    parties under the terms of this License.
-
-    c) If the modified program normally reads commands interactively
-    when run, you must cause it, when started running for such
-    interactive use in the most ordinary way, to print or display an
-    announcement including an appropriate copyright notice and a
-    notice that there is no warranty (or else, saying that you provide
-    a warranty) and that users may redistribute the program under
-    these conditions, and telling the user how to view a copy of this
-    License.  (Exception: if the Program itself is interactive but
-    does not normally print such an announcement, your work based on
-    the Program is not required to print an announcement.)
-\f
-These requirements apply to the modified work as a whole.  If
-identifiable sections of that work are not derived from the Program,
-and can be reasonably considered independent and separate works in
-themselves, then this License, and its terms, do not apply to those
-sections when you distribute them as separate works.  But when you
-distribute the same sections as part of a whole which is a work based
-on the Program, the distribution of the whole must be on the terms of
-this License, whose permissions for other licensees extend to the
-entire whole, and thus to each and every part regardless of who wrote it.
-
-Thus, it is not the intent of this section to claim rights or contest
-your rights to work written entirely by you; rather, the intent is to
-exercise the right to control the distribution of derivative or
-collective works based on the Program.
-
-In addition, mere aggregation of another work not based on the Program
-with the Program (or with a work based on the Program) on a volume of
-a storage or distribution medium does not bring the other work under
-the scope of this License.
-
-  3. You may copy and distribute the Program (or a work based on it,
-under Section 2) in object code or executable form under the terms of
-Sections 1 and 2 above provided that you also do one of the following:
-
-    a) Accompany it with the complete corresponding machine-readable
-    source code, which must be distributed under the terms of Sections
-    1 and 2 above on a medium customarily used for software interchange; or,
-
-    b) Accompany it with a written offer, valid for at least three
-    years, to give any third party, for a charge no more than your
-    cost of physically performing source distribution, a complete
-    machine-readable copy of the corresponding source code, to be
-    distributed under the terms of Sections 1 and 2 above on a medium
-    customarily used for software interchange; or,
-
-    c) Accompany it with the information you received as to the offer
-    to distribute corresponding source code.  (This alternative is
-    allowed only for noncommercial distribution and only if you
-    received the program in object code or executable form with such
-    an offer, in accord with Subsection b above.)
-
-The source code for a work means the preferred form of the work for
-making modifications to it.  For an executable work, complete source
-code means all the source code for all modules it contains, plus any
-associated interface definition files, plus the scripts used to
-control compilation and installation of the executable.  However, as a
-special exception, the source code distributed need not include
-anything that is normally distributed (in either source or binary
-form) with the major components (compiler, kernel, and so on) of the
-operating system on which the executable runs, unless that component
-itself accompanies the executable.
-
-If distribution of executable or object code is made by offering
-access to copy from a designated place, then offering equivalent
-access to copy the source code from the same place counts as
-distribution of the source code, even though third parties are not
-compelled to copy the source along with the object code.
-\f
-  4. You may not copy, modify, sublicense, or distribute the Program
-except as expressly provided under this License.  Any attempt
-otherwise to copy, modify, sublicense or distribute the Program is
-void, and will automatically terminate your rights under this License.
-However, parties who have received copies, or rights, from you under
-this License will not have their licenses terminated so long as such
-parties remain in full compliance.
-
-  5. You are not required to accept this License, since you have not
-signed it.  However, nothing else grants you permission to modify or
-distribute the Program or its derivative works.  These actions are
-prohibited by law if you do not accept this License.  Therefore, by
-modifying or distributing the Program (or any work based on the
-Program), you indicate your acceptance of this License to do so, and
-all its terms and conditions for copying, distributing or modifying
-the Program or works based on it.
-
-  6. Each time you redistribute the Program (or any work based on the
-Program), the recipient automatically receives a license from the
-original licensor to copy, distribute or modify the Program subject to
-these terms and conditions.  You may not impose any further
-restrictions on the recipients' exercise of the rights granted herein.
-You are not responsible for enforcing compliance by third parties to
-this License.
-
-  7. If, as a consequence of a court judgment or allegation of patent
-infringement or for any other reason (not limited to patent issues),
-conditions are imposed on you (whether by court order, agreement or
-otherwise) that contradict the conditions of this License, they do not
-excuse you from the conditions of this License.  If you cannot
-distribute so as to satisfy simultaneously your obligations under this
-License and any other pertinent obligations, then as a consequence you
-may not distribute the Program at all.  For example, if a patent
-license would not permit royalty-free redistribution of the Program by
-all those who receive copies directly or indirectly through you, then
-the only way you could satisfy both it and this License would be to
-refrain entirely from distribution of the Program.
-
-If any portion of this section is held invalid or unenforceable under
-any particular circumstance, the balance of the section is intended to
-apply and the section as a whole is intended to apply in other
-circumstances.
-
-It is not the purpose of this section to induce you to infringe any
-patents or other property right claims or to contest validity of any
-such claims; this section has the sole purpose of protecting the
-integrity of the free software distribution system, which is
-implemented by public license practices.  Many people have made
-generous contributions to the wide range of software distributed
-through that system in reliance on consistent application of that
-system; it is up to the author/donor to decide if he or she is willing
-to distribute software through any other system and a licensee cannot
-impose that choice.
-
-This section is intended to make thoroughly clear what is believed to
-be a consequence of the rest of this License.
-\f
-  8. If the distribution and/or use of the Program is restricted in
-certain countries either by patents or by copyrighted interfaces, the
-original copyright holder who places the Program under this License
-may add an explicit geographical distribution limitation excluding
-those countries, so that distribution is permitted only in or among
-countries not thus excluded.  In such case, this License incorporates
-the limitation as if written in the body of this License.
-
-  9. The Free Software Foundation may publish revised and/or new versions
-of the General Public License from time to time.  Such new versions will
-be similar in spirit to the present version, but may differ in detail to
-address new problems or concerns.
-
-Each version is given a distinguishing version number.  If the Program
-specifies a version number of this License which applies to it and "any
-later version", you have the option of following the terms and conditions
-either of that version or of any later version published by the Free
-Software Foundation.  If the Program does not specify a version number of
-this License, you may choose any version ever published by the Free Software
-Foundation.
-
-  10. If you wish to incorporate parts of the Program into other free
-programs whose distribution conditions are different, write to the author
-to ask for permission.  For software which is copyrighted by the Free
-Software Foundation, write to the Free Software Foundation; we sometimes
-make exceptions for this.  Our decision will be guided by the two goals
-of preserving the free status of all derivatives of our free software and
-of promoting the sharing and reuse of software generally.
-
-                           NO WARRANTY
-
-  11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
-FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
-OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
-PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
-OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
-MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS
-TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE
-PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
-REPAIR OR CORRECTION.
-
-  12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
-WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
-REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
-INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
-OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
-TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
-YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
-PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
-POSSIBILITY OF SUCH DAMAGES.
-
-                    END OF TERMS AND CONDITIONS
-\f
-       Appendix: How to Apply These Terms to Your New Programs
-
-  If you develop a new program, and you want it to be of the greatest
-possible use to the public, the best way to achieve this is to make it
-free software which everyone can redistribute and change under these terms.
-
-  To do so, attach the following notices to the program.  It is safest
-to attach them to the start of each source file to most effectively
-convey the exclusion of warranty; and each file should have at least
-the "copyright" line and a pointer to where the full notice is found.
-
-    <one line to give the program's name and a brief idea of what it does.>
-    Copyright (C) 19yy  <name of author>
-
-    This program is free software; you can redistribute it and/or modify
-    it under the terms of the GNU General Public License as published by
-    the Free Software Foundation; either version 2 of the License, or
-    (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-
-Also add information on how to contact you by electronic and paper mail.
-
-If the program is interactive, make it output a short notice like this
-when it starts in an interactive mode:
-
-    Gnomovision version 69, Copyright (C) 19yy name of author
-    Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
-    This is free software, and you are welcome to redistribute it
-    under certain conditions; type `show c' for details.
-
-The hypothetical commands `show w' and `show c' should show the appropriate
-parts of the General Public License.  Of course, the commands you use may
-be called something other than `show w' and `show c'; they could even be
-mouse-clicks or menu items--whatever suits your program.
-
-You should also get your employer (if you work as a programmer) or your
-school, if any, to sign a "copyright disclaimer" for the program, if
-necessary.  Here is a sample; alter the names:
-
-  Yoyodyne, Inc., hereby disclaims all copyright interest in the program
-  `Gnomovision' (which makes passes at compilers) written by James Hacker.
-
-  <signature of Ty Coon>, 1 April 1989
-  Ty Coon, President of Vice
-
-This General Public License does not permit incorporating your program into
-proprietary programs.  If your program is a subroutine library, you may
-consider it more useful to permit linking proprietary applications with the
-library.  If this is what you want to do, use the GNU Library General
-Public License instead of this License.
-
diff --git a/reactos/apps/utils/net/telnet/doc/options.txt b/reactos/apps/utils/net/telnet/doc/options.txt
deleted file mode 100644 (file)
index fefd154..0000000
+++ /dev/null
@@ -1,187 +0,0 @@
-This file describes all the environment variables and options that are
-available in TELNET.INI.  If you are having problems with a terminal setting,
-this is the file you want to read first.  If this file does not help you,
-please send a bug report to Paul Brannan <pbranna@clemson.edu>.
-
-Environment variables
----------------------
-
-Before there was a telnet.ini file, all the options were controlled
-through environment variables.  These have been left in for compatibility
-with previous versions, and for specifying locations of files.  They
-override any values in telnet.ini.
-
-TELNET_CFG      Specifies the location of the keys.cfg file
-TELNET_REDIR    Specifies whether file redirection needs to be supported
-INPUT_REDIR     Specicies only to redirect input
-OUTPUT_REDIR    Specifies only to redirect output
-TELNET_INI      Specifies the location of the telnet.ini file
-
-Configuration options
----------------------
-
-These are the options that you can specify in telnet.ini.  This file is in
-the same format as any normal Windows ini file.  You can also change some
-of these options using the SET command at the telnet> prompt.
-
-[Terminal] section
-
-Dumpfile
-Specifies the filename of a file to dump output to.  (Default = "")
-
-Term
-The name of the terminal type to send to the server.  You
-can use this if Telnet is sending "ANSI" but you have a
-vt100 terminal.  If you use this options, please read about
-some of the other options below.  (Default = ansi)
-
-EightBit_Ansi
-Some machines use the ASCII characters 128 to 155 for ANSI
-sequences.  These are usually the newer VAX systems.  Turning
-this option on may cause problems with certain foreign
-(non-American) character sets.  (Default = FALSE)
-
-VT100_Mode
-This option turns on VT100 mode.  There are a few minor
-differences between ANSI terminals and DEC VT100 terminals.
-I recommend trying TERM=vt220 or TERM=vt102 before trying
-this option, but if you must have true VT100 emulation,
-this is the only way to get it.  (Default = FALSE)
-
-Destructive_Backspace
-This will probably cause problems with most programs, but if you need the
-backspace to erase the previous character (as with some BBSes), use this
-option.  (Default = FALSE)
-
-Speaker_Beep
-If you set this to true you will hear beeps through the PC speaker; setting
-it to false will play the default system beep sound through your sound
-card.  (Default = TRUE)
-
-Beep
-Setting this to false turns off all beeps; setting this to true turns on
-all beeps.  (Default = TRUE)
-
-Preserve_Colors
-This turns on color preservation for systems that require it (like SCO).
-(Default = FALSE)
-
-Wrap_line
-This turns on/off line wrap.  (Default = TRUE)
-
-Lock_linewrap
-Turning on this option disables the ability of the remote end to control
-line wrap, and "locks" it into whatever it is set to in the ini file.
-(Default = FALSE)
-
-Fast_write
-This turns on/off fast screen write.  Turning it off allows you to see
-control characters if your application requires it.  (Default = TRUE)
-
-Term_width
-Term_height
-These options specify the size of the terminal.  You can specify non-standard
-sizes if you are running telnet in a window.  You may want to specify
-a font size if you use these (using "Auto" can cause display problems).
-Specifying -1 means use the settings for the parent console.
-(Default = -1, -1)
-
-Wide_enable
-This is to allow the ANSI parser to change the screen size when sent certain
-escape sequences.  This is for vt100 compatibility.  (Default = FALSE)
-
-Buffer_size
-This is the size of the ANSI buffer used for parsing sequences.  Increasing
-this value speeds up the parser, and decreasing it allows the mouse to
-respond faster.  (Default = 2048)
-
-Input_redir
-Output_redir
-These are for redirecting input and output.  (Default = 0, 0)
-Any value greater than 0 turns redir on.  Turn Output_redir on to bypass
-the Console Telnet screen writing and positioning functions and simply
-pass the data stream as received from the host straight through.
-
-Strip_redir
-If enabled, this option will attempt to strip the stream before passing it on
-through redirected output.  This will have no effect on non-redirected output.
-(Default=FALSE)
-
-[Colors] section
-
-Setting the following to -1 disables them:
-Blink_bg                Background color to use for blink (default = -1)
-Blink_fg                Foreground color to use for blink (default = -1)
-Underline_bg            Background color to use for underline (default = -1)
-Underline_fg            Foreground color to use for underline (default = -1)
-UlBlink_bg              Background color to use for blink+uline (default = -1)
-UlBlink_fg              Foreground color to use for blink+uline (default = -1)
-
-Setting the following to -1 uses colors detected at startup:
-Normal_bg               Normal text background color (default = -1)
-Normal_fg               Normal text foreground color (default = -1)
-
-Please do not set these values to -1:
-Scroll_bg               Background color for scrollback mode (default = 0)
-Scroll_fg               Foreground color for scrollback mode (default = 7)
-Status_bg               Bg color of status line in scrollback (default = 1)
-Status_fg               Fg color of status line in scrollback (default = 15)
-
-Here's a list of colors:
-0 - black, 1 - blue, 2 - green, 3 - cyan, 4 - red, 5 - magenta, 6 - brown
-7 - lt. grey (dk. white), 8 - dk. grey, 9 - bright blue, 10 - bright green,
-11 - bright cyan, 12 - bright red, 13 - bright magenta, 14 - yellow
-15 - bright white
-
-[Mouse] section
-
-Enable_Mouse
-Turns on mouse support.  (Default = TRUE)
-
-[Printer] section
-
-Printer_Name
-The DOS name for the printer.  (Default = LPT1)
-
-[Keyboard] section
-Many of these options are also available from telnet.cfg.
-
-Escape_key
-The key to break out of a telnet session.  (Default = ])
-
-Scrollback_key
-The key for switching to scrollback mode.  (Default = [)
-
-Dial_key
-You can start a new telnet session with this key.  (Default = \)
-
-Alt_erase
-If you set this to true, it will swap backspace and delete.
-(Default = FALSE)
-
-Keyboard_paste
-This option allows pasting to the screen via shift-insert.  (Default = FALSE)
-
-Keyfile
-Selects an alternate telnet.cfg file.  (Default = TELNET.CFG)
-
-Default_Config
-Selects a different keyboard definition.  All of these are defined in
-telnet.cfg.
-
-[Scrollback] section
-
-Scroll_Mode
-Selects the default mode for scrollback.  Valid selections are:
-        HEX             Hex dump
-        DUMP            Dump, control characters are shown as "."
-        DUMPB           Binary dump
-        TEXT            Text mode
-Note: you can press TAB in scrollback mode to cycle through these.
-(Default = DUMP)
-
-Command-line Options
---------------------
-
--d<filename>    Specifies the name of the dumpfile.
--h             Gives a help screen.
diff --git a/reactos/apps/utils/net/telnet/doc/readme.txt b/reactos/apps/utils/net/telnet/doc/readme.txt
deleted file mode 100644 (file)
index abebe34..0000000
+++ /dev/null
@@ -1,280 +0,0 @@
-              **************************************************
-              ** Console Telnet v2.1b2 README.TXT 16 Oct 2000 **
-              **************************************************
-
-                               RELEASE NOTES:
-                               --------------
-
-This release of TELNET is a beta one. This means that it is working as far
-as it is tested, and has a few bugs. Hopefully this will be a stable
-version.  Please send comments and bug reports to me at
-pbranna@clemson.edu, or to the mailing list (see below).  See file
-CHANGES.TXT for a detailed log of changes.  See file BUGS.TXT for known
-bugs.
-
-                                DESCRIPTION:
-                                ------------
-
-This is a telnet client with full color ANSI support for Windows NT/95
-console. You can use this program from the Win95 command line (MsDos) and
-run it in full screen text mode. You may also redirect the telnet session
-to STDIN and STDOUT for use with other programs.  Telnet will communicate
-the number of lines and rows to the host, and can operate in any console
-mode.  Most of it's options are customizable.
-
-
-                         COPYRIGHT/LICENSE/WARRANTY
-                         --------------------------
-
-Telnet Win32, Copyright (C) 1996-1997, Brad Johnson <jbj@nounname.com>
-Copyright (C) 1998 I.Ioannou, Copyright (C) 1999-2000 Paul Brannan.  Telnet
-is a free project released under the GNU public license.  This program comes
-with ABSOLUTELY NO WARRANTY.  This is free software, and you are welcome
-to redistribute it under the licence contitions.  See LICENSE.TXT for
-details.
-
-                                REQUIREMENTS:
-                                -------------
-
-This program requires a Microsoft Win32 enviroment (Windows 95/98/NT) with
-Winsock TCP/IP.  16 bit Win3.x or Win32s are not supported.
-
-                                  FEATURES:
-                                  ---------
-
-Full ANSI colors and (almost) complete ANSI emulation.
-User configurable options via telnet.ini.
-User configurable key bindings with alternative keyboards.
-Icoming character translations.
-Redirection of telnet session.
-Telnet output can be dumped to a file.
-Local printer support.
-Basic scrollback support.
-Basic VT emulation.
-Mouse support.
-Clipboard (cut-and-paste) support.
-Support for multiple screen sizes.
-
-                              WHERE TO GET IT:
-                              ----------------
-
-Since version 2.0, Console Telnet's new home page is
-http://www.musc.edu/~brannanp/telnet/.  You can get the latest version from
-ftp://argeas.cs-net.gr/Telnet-Win32 or from the web page.  Telnet is
-available as full project (sources included) or as binaries only.  If you
-would like to help to the development check the /devel directory on the ftp
-site for a recent alpha version.
-
-                                MAILING LIST:
-                                -------------
-
-Telnet has it's own mailing list for announcements, bug reports, support,
-suggestions etc. To subscribe send e-mail to majordomo@argeas.cs-net.gr
-with empty Subject, and the word subscribe in the body. List's address is
-telnet-win32@argeas.cs-net.gr You can find the old archives at
-http://www.cs-net.gr/lists
-
-If you are only interested in announcements, follow the above procedures to
-subscribe to telnet-win32-announce.  The development list is
-telnet-win32-devel.
-
-                                HOW TO HELP:
-                                ------------
-
-Telnet is a free project made from volunteers. If you know C/C++ and would
-like to help in the development you are welcome :-)  Just contact
-pbranna@clemson.edu, and/or subscribe to the mailing list.  Check
-ftp://argeas.cs-net.gr/Telnet-Win32/devel for a recent alpha version.
-
-
-                                INSTALLATION
-                                ------------
-
-Just copy telnet.exe, telnet.ico, telnet.ini and keys.cfg to a directory.
-I prefer a directory included in the PATH (such as C:\WINDOWS, but this will
-overwrite the telnet that comes with Windows -- which is not necessarily a
-bad thing). If you are upgrading from a previous version please look below
-(Key file definitions) : the keys.cfg file has changed a bit. Also look at
-the Configuration section below, TELNET now has a ini file.
-
-                                   USAGE:
-                                   -------
-
-  TELNET
-    Begins telnet and enters telnet> command line.
-
-  TELNET [params][host [port]]
-    Connects to port on host. Port defaults to 23 for TELNET.
-
-    params    -d FILENAME.EXT    Dumps all incoming data to FILENAME.EXT
-                                 Note lowercase 'd'.
-              --variable=value   Overrides ini variable to be set to value.
-
-    host                         Host name or IP to connect to
-    port                         Service port to open connection on
-                                 (default is telnet port 23).
-
-  TELNET -?
-    Gives usage information.
-
-Pressing the escape key (default ALT-]) will break out of a telnet session and
-return you to the telnet> prompt. Pressing return will resume your session.
-All the options are available from the telnet> prompt. Type ? to get help.
-
-Pressing the scrollback key (default ALT-[) will give you a basic scrollback
-view. Pressing ESC will resume your session.
-
-                                   BUGS:
-                                   -----
-
-There are :-). Hopefully this version is more stable than the previous. See
-BUGS.TXT, and grep for FIX ME's in the sources. Any help ?
-
-                                   NOTES:
-                                   ------
-
-If the environment variable LANG has a valid value (e.g. LANG=de for German
-characters) and the file LOCALE.DLL is installed somewhere along the PATH
-TELNET will not ignore local characters.
-
-If you have problems with paste under Win 95 try unchecking the fast paste
-option in the MsDos properties. The paste function works correctly under NT.
-This is a Microsoft bug :-)
-
-                                CONFIGURATION
-                                -------------
-
-The configuration is made through telnet.ini and keys.cfg. These files (at
-least telnet.ini) must be in the same directory which telnet.exe is.  The
-basic options are loaded from the file telnet.ini. If you are having problems
-with a terminal setting, check the file OPTIONS.TXT for configuration
-information.
-
-
-Key file definitions (telnet.cfg)
--------------------------------
-
-Use the key file (telnet.cfg) to define the characters that telnet is sending
-to the host.  From version 2b5 you can configure the output keys (KEYMAP
-sections), the input character translations (CHARMAP sections) and you can
-combine all to as many configurations as you like (CONFIG sections). You
-can also have alternative keymaps in a configuration, and keys to switch
-between them.  See the comments in keys.cfg for details.
-
-NOTE: if you are upgrading from a previous version you must put your old keys
-in the KEYMAP sections.
-Please send any national specific keymaps / charmaps / configurations to be
-included to the next version.
-
-
-                              HOW TO COMPILE IT
-                             -------------------
-
-Telnet compiles with a variety of compilers.  You will need at least
-Borland 4.x or newer compiler, or MSVC 2.0 or newer, or download a version
-of gcc for Win32 (see http://www.musc.edu/~brannanp/telnet/gccwin32.html).
-Copy the files from the directories BORLAND or MSVC to the main directory,
-change them to fit to your system, and recompile.  The project comes with
-IDE files and makefiles.
-
-Follow the instructions for your compiler to compile telnet.  A Makefile
-for use with mingw32 or other gcc variants has been included, so if you have
-gcc, you can just type "make" at the command line.
-
-                               SPECIAL THANKS:
-                               ---------------
-
-Many people have worked for this project. Please forgive me (and let me
-know!) if I have forgotten anyone. We all thank them :-)
-
-Igor Milavec <igor.milavec@uni-lj.si>
-        Original Author of version 1.1
-        Igor wrote the basic telnet program and released it to public.
-
-Brad Johnson <jbj@nounname.com>  http://nounname.com
-        Author of versions 2.0b to 2b4. Brad has wrote plenty of code for
-        telnet like ansi colors, emulation, scrollback option, and many
-        others.
-
-Titus_Boxberg@public.uni-hamburg.de
-        Ansi emulation improvements
-        German keyboard configuration
-
-I.Ioannou roryt@hol.gr
-        KeyTranslator class (version 2b3)
-        Maintainer (since version 2b5)
-
-Andrei V. Smilianets <smile@head.aval.kiev.ua> (version 2b5)
-        KeyTranslator class (version 2b5)
-        Prompt improvments
-
-Paul Brannan <pbranna@clemson.edu>
-        Telnet.ini author, MSVC port, speed improvements, VT support,
-        and many others.
-        Maintainer (since version 2b6)
-
-Leo Leibovici <leo.leibovici@nouveau.co.uk>
-        Fixed some crashes in the ANSI parser
-        Wrote UK keymap
-
-Dmitry Lapenkov <dl@bis.msk.su>
-        Wrote AT386 keymaps
-        Improved telnet icon
-
-Thomas Briggs <tbriggs@qmetric.com>
-        Fixed problem with Ctrl-Break
-        Added suspend and fast quit options to the command line
-        Error messages for unable to load ini file
-        Fixed bug w/ getting name of executable
-
-BK Oxley
-        Fixed TELNET_INI environment variable
-
-Sam Robertson
-        Fixed compilation problems with MSVC6
-        Bugfix with telnet crashing at exit
-
-Vassili Bourdo <vassili_bourdo@softhome.net>
-        Keyboard initialization improvements
-
-Craig Davidson <crn@ozemail.com.au>
-        Bugfixes for telnet prompt
-        Added suspend telnet option
-        Set port number using name rather than number
-
-Pedro Gutierrez <paag@coppi.tid.es>
-        Save/restore console title
-        Bugfix w/ character mapping
-
-Daniel Straub <Daniel.Straub@nbgm.siemens.de>
-        Bugfix with telnet crashing at exit
-
-Jose Cesar Otero Rodriguez <jcotero@las.es>
-        Spanish Keyboard definition
-        Cursor size sequences
-
-Bryan Montgomery <monty@english.net>
-        Added CtrlBreak_as_CtrlC option
-        Added Scroll_Enable option
-
-Adi Seiker
-        Added Set_Title ini file option
-
-Craig Nellist
-        Updated Winsock error messages
-        Sleeping while thread paused, to give up CPU time
-        Command-line history
-
-Jakub Sterba
-        Czech keyboard definition
-
-Ziglio Frediano
-        MTE (Meridian Terminal) Support
-
-Mark Miesfield
-       Fixed redirection
-       Wrote documentation for redirection
-
----
-
-Paul Brannan <pbranna@clemson.edu>
diff --git a/reactos/apps/utils/net/telnet/doc/ssh.txt b/reactos/apps/utils/net/telnet/doc/ssh.txt
deleted file mode 100644 (file)
index 077d79b..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-It should be possible to add ssh support to console telnet, as console telnet has a very modular design when it comes to the networking code.  There is already support for pipes, and if there exists an ssh client for Win32 that will output to stdout, then you're in business.  I'm yet to find such a client, but if one existed, an SSH session could be started like so:
-
-C:\> telnet
-Copyright message, license.txt, stuff, etc.
-telnet> set io_netpipe "C:\BIN\SSH.EXE -l username host"
-telnet> open blah
-login:
-password:
-
-Unfortunately, all the ssh clients I've found don't work this way.  You can output CMD.EXE to telnet this way, though, and get a very pretty ansi interpreter.  If you want to try to get OpenSSH working, here's step-by-step instructions to get you started (please read them all the way though):
-
-1) Get Perl from http://www.activestate.com/ActivePerl/download.htm
-2) Get Openssl from http://www.openssl.org/source/
-   - Follow directions in INSTALL.W32
-   - Copy the .LIB files from OUT32DLL to your LIB directory (C:\DevStudio\VC\LIB)
-   - Copy the .DLL files from OUT32DLLto your system directory (C:\Winnt\System32 or C:\Windows\System)
-   - Copy the .H files from INC32\OPENSSL to your include\ssl (C:\DevStudio\VC\include\ssl)
-   - Copy these same files to include\openssl (C:\DevStudio\VC\include\openssl)
-3) Get Openssh from http://www.openssh.com
-4) Modify Openssh so it will compile, and get rid of all the termios stuff
-
-Obviously this is a lot of work.  If you need a good ssh client, try PuTTY from http://www.chiark.greenend.org.uk/~sgtatham/putty/.  It may be possible to integrate PuTTY and Telnet, and that would certainly be easier than the above option.  PuTTY is licensed under the MIT license, which seems to be compatible with the GPL.  The primary advantage of integrating the two projects is that PuTTY would gain the key mappings that telnet has, and telnet would gain encryption.
\ No newline at end of file
diff --git a/reactos/apps/utils/net/telnet/resource/tnmsg.h b/reactos/apps/utils/net/telnet/resource/tnmsg.h
deleted file mode 100644 (file)
index b93d02b..0000000
+++ /dev/null
@@ -1,108 +0,0 @@
-//{{NO_DEPENDENCIES}}
-// Microsoft Developer Studio generated include file.
-// Used by Tnmsg.rc
-//
-#define MSG_COPYRIGHT                   0x01
-#define MSG_COPYRIGHT_1                 0x02
-#define MSG_USAGE                       0x03
-#define MSG_USAGE_1                     0x04
-#define MSG_HELP                        0x05
-#define MSG_HELP_1                      0x06
-#define MSG_INVCMD                      0x07
-#define MSG_ERROR                       0x08
-#define MSG_INFO                        0x09
-#define MSG_WARNING                     0x0a
-#define MSG_TRYING                      0x0b
-#define MSG_CONNECTED                   0x0c
-#define MSG_TERMBYREM                   0x0d
-#define MSG_KEYMAP                      0x0e
-#define MSG_ERRKEYMAP                   0x0f
-#define MSG_DUMPFILE                    0x10
-#define MSG_CONFIG                      0x11
-#define MSG_NOINI                       0x12
-#define MSG_BADVAL                      0x13
-#define MSG_NOSPAWN                     0x14
-#define MSG_RESOLVING                                  0x15
-#define MSG_NOSERVICE                                  0x16
-#define MSG_SIZEALIAS                                  0x17
-#define MSG_ERRPIPE                                            0x18
-#define MSG_BADUSAGE                                   0x19
-#define MSG_ALREADYCONNECTED                   0x1a
-
-#define MSG_KEYNOVAL                    1001
-#define MSG_KEYBADVAL                   1002
-#define MSG_KEYBADSTRUCT                1003
-#define MSG_KEYBADCHARS                 1004
-#define MSG_KEYUNEXPLINE                1005
-#define MSG_KEYUNEXPEOF                 1006
-#define MSG_KEYUNEXPTOK                 1007
-#define MSG_KEYUNEXPTOKIN               1008
-#define MSG_KEYUNEXP                    1009
-#define MSG_KEYNOGLOBAL                 1010
-#define MSG_KEYNOCONFIG                 1011
-#define MSG_KEYUSECONFIG                1012
-#define MSG_KEYNOSWKEY                  1013
-#define MSG_KEYCANNOTDEF                1014
-#define MSG_KEYDUPSWKEY                 1015
-#define MSG_KEYUNKNOWNMAP               1016
-#define MSG_KEYNOCHARMAPS               1017
-#define MSG_KEYNOKEYMAPS                1018
-#define MSG_KEYNUMMAPS                  1019
-#define MSG_KEYBADMAP                                  1020
-#define MSG_KEYMAPSWITCHED                             1021
-
-#define MSG_WSAEINTR                    0x2714
-#define MSG_WSAEBADF                    0x2719
-#define MSG_WSAEACCESS                  0x271D
-#define MSG_WSAEDEFAULT                 0x271E
-#define MSG_WSAEINVAL                   0x2726
-#define MSG_WSAEMFILE                   0x2728
-#define MSG_WSAEWOULDBLOCK              0x2733
-#define MSG_WSAEINPROGRESS              0x2734
-#define MSG_WSAEALREADY                 0x2735
-#define MSG_WSAENOTSOCK                 0x2736
-#define MSG_WSAEDESTADDRREQ             0x2737
-#define MSG_WSAEMSGSIZE                 0x2738
-#define MSG_WSAEPROTOTYPE               0x2739
-#define MSG_WSAENOPROTOOPT              0x273A
-#define MSG_WSAEPROTONOTSUPPORT         0x273B
-#define MSG_WSAESOCKNOTSUPPORT          0x273C
-#define MSG_WSAEOPNOTSUPP               0x273D
-#define MSG_WSAEPFNOTSUPPORT            0x273E
-#define MSG_WSAEAFNOTSUPPORT            0x273F
-#define MSG_WSAEADDRINUSE               0x2740
-#define MSG_WSAEADDRNOTAVAIL            0x2741
-#define MSG_WSAENETDOWN                 0x2742
-#define MSG_WSAENETUNREACH              0x2743
-#define MSG_WSAENETRESET                0x2744
-#define MSG_WSAECONNABORTED             0x2745
-#define MSG_WSAECONNRESET               0x2746
-#define MSG_WSAENOBUFS                  0x2747
-#define MSG_WSAEISCONN                  0x2748
-#define MSG_WSAENOTCONN                 0x2749
-#define MSG_WSAESHUTDOWN                0x274A
-#define MSG_WSAETOOMANYREFS             0x274B
-#define MSG_WSAETIMEDOUT                0x274C
-#define MSG_WSAECONNREFUSED             0x274D
-#define MSG_WSAELOOP                    0x274E
-#define MSG_WSAENAMETOOLONG             0x274F
-#define MSG_WSAEHOSTDOWN                0x2750
-#define MSG_WSAEHOSTUNREACH             0x2751
-#define MSG_WSAESYSNOTREADY             0x276B
-#define MSG_WSAVERNOTSUPPORTED          0x276C
-#define MSG_WSANOTINITIALISED           0x276D
-#define MSG_WSAHOST_NOT_FOUND           0x2AF9
-#define MSG_WSATRY_AGAIN                0x2AFA
-#define MSG_WSANO_RECOVERY              0x2AFB
-#define MSG_WSANO_DATA                  0x2AFC
-
-// Next default values for new objects
-//
-#ifdef APSTUDIO_INVOKED
-#ifndef APSTUDIO_READONLY_SYMBOLS
-#define _APS_NEXT_RESOURCE_VALUE        101
-#define _APS_NEXT_COMMAND_VALUE         40001
-#define _APS_NEXT_CONTROL_VALUE         1000
-#define _APS_NEXT_SYMED_VALUE           101
-#endif
-#endif
diff --git a/reactos/apps/utils/net/telnet/resource/tnmsg.rc b/reactos/apps/utils/net/telnet/resource/tnmsg.rc
deleted file mode 100644 (file)
index bb8b2fd..0000000
+++ /dev/null
@@ -1,107 +0,0 @@
-#include "tnmsg.h"
-
-LANGUAGE 0,0
-
-// String Table
-STRINGTABLE DISCARDABLE 
-BEGIN
-    MSG_COPYRIGHT           "Telnet Win32 v2.1b2, Copyright (C) 2000 Paul Brannan <pbranna@clemson.edu>\nand the team.  This program comes with ABSOLUTELY NO WARRANTY; for details\nread LICENSE.TXT.  "
-    MSG_COPYRIGHT_1         "This is free software, and you are welcome to redistribute\nit under certain conditions.\n\n"
-    MSG_USAGE               "Usage: TELNET [params][host [port]]\n\n  params\n    -d:FILENAME.EXT  Dumps all incoming data to FILENAME.EXT.\n  host              Host name or IP address of the remote host to connect to.\n"
-    MSG_USAGE_1             "  port              Service port to open (default is telnet port 23).\n\n"
-    MSG_HELP                "Commands may be abbreviated.  Commands are:\n  \ncl[ose]         close current connection\nop[en]          connect to a site\nq[uit]          exit telnet\n"
-    MSG_HELP_1              "ke[ys]          changes/displays keymaps (write keys to see the options)\nse[t]           displays/alters configuration options\nz               suspend\n? h[elp]        print help information\n"
-    MSG_INVCMD              "Invalid command.  Type ? for help.\n"
-    MSG_ERROR               "%1 failed.\n"
-    MSG_INFO                "%1\n"
-    MSG_WARNING             "%1\n"
-    MSG_TRYING              "Trying %1.%2.%3.%4:%5...\n"
-    MSG_CONNECTED           "Connected to %1.  Escape key is ALT-%2.\n"
-    MSG_TERMBYREM           "Connection terminated.\n"
-    MSG_KEYMAP              "Loading %1 from %2.\n"
-    MSG_ERRKEYMAP           "Error loading keymap.\n"
-    MSG_DUMPFILE            "Writing output to file %1.\n"
-    MSG_CONFIG              "Loading configuration options from %1.\n"
-    MSG_NOINI               "Error loading configuration file %1.\nLoading default options.\n"
-    MSG_BADVAL              "Warning: invalid variable %1.\n"
-    MSG_NOSPAWN             "Unable to spawn process.\n"
-    MSG_RESOLVING           "Looking up host: %1..."
-    MSG_NOSERVICE           "Could not find TCP service %1.\n"
-    MSG_SIZEALIAS           "Warning: size of alias %1 is too big, ignoring.\n"
-    MSG_ERRPIPE             "Error: unable to spawn process for pipe.\n"
-    MSG_BADUSAGE            "Error: invalid usage of command.\n"
-    MSG_ALREADYCONNECTED    "Already connected to %1.\n"
-
-    MSG_WSAEINTR            "Interrupted function call.\n"
-    MSG_WSAEBADF            "WSAEBADF\n"
-    MSG_WSAEACCESS          "Permission denied.\n"
-    MSG_WSAEDEFAULT         "WSAEDEFAULT\n"
-    MSG_WSAEINVAL           "Invalid argument.\n"
-    MSG_WSAEMFILE           "Too many open files.\n"
-    MSG_WSAEWOULDBLOCK      "Resource temporalily unavailable.\n"
-    MSG_WSAEINPROGRESS      "Operation now in progress.\n"
-    MSG_WSAEALREADY         "Operation already in progress.\n"
-    MSG_WSAENOTSOCK         "Socket operation on non-socket.\n"
-    MSG_WSAEDESTADDRREQ     "Destination address required.\n"
-    MSG_WSAEMSGSIZE         "Message too long.\n"
-    MSG_WSAEPROTOTYPE       "Protocol wrong type for socket.\n"
-    MSG_WSAENOPROTOOPT      "Bad protocol option.\n"
-    MSG_WSAEPROTONOTSUPPORT "Protocol not supported.\n"
-    MSG_WSAESOCKNOTSUPPORT  "Socket type not supported.\n"
-    MSG_WSAEOPNOTSUPP       "Operation not supported.\n"
-    MSG_WSAEPFNOTSUPPORT    "Protocol family not supported.\n"
-    MSG_WSAEAFNOTSUPPORT    "Address family not supported by protocol family.\n"
-    MSG_WSAEADDRINUSE       "Address already in use.\n"
-    MSG_WSAEADDRNOTAVAIL    "Cannot assign requested address.\n"
-    MSG_WSAENETDOWN         "Network is down.\n"
-    MSG_WSAENETUNREACH      "Network is unreachable.\n"
-    MSG_WSAENETRESET        "Network dropped connection on reset.\n"
-    MSG_WSAECONNABORTED     "Software caused connection abort.\n"
-    MSG_WSAECONNRESET       "Connection reset by peer.\n"
-    MSG_WSAENOBUFS          "No buffer space available.\n"
-    MSG_WSAEISCONN          "Socket is already connected.\n"
-    MSG_WSAENOTCONN         "Socket is not connected.\n"
-    MSG_WSAESHUTDOWN        "Cannot send after socket shutdown.\n"
-    MSG_WSAETOOMANYREFS     "WSAETOOMANYREFS\n"
-    MSG_WSAETIMEDOUT        "Connection timed out.\n"
-    MSG_WSAECONNREFUSED     "Connection refused.\n"
-    MSG_WSAELOOP            "WSAELOOP\n"
-    MSG_WSAENAMETOOLONG     "Name too long.\n"
-    MSG_WSAEHOSTDOWN        "Host is down.\n"
-    MSG_WSAEHOSTUNREACH     "No route to host.\n"
-    MSG_WSAESYSNOTREADY     "Network subsystem is unavailable.\n"
-    MSG_WSAVERNOTSUPPORTED  "WINSOCK.DLL version out of range.\n"
-    MSG_WSANOTINITIALISED   "Successful WSAStartup not yet performed.\n"
-    MSG_WSAHOST_NOT_FOUND   "Host not found.\n"
-    MSG_WSATRY_AGAIN        "Non-authoritative host not found.\n"
-    MSG_WSANO_RECOVERY      "This is a non-recoverable error.\n"
-    MSG_WSANO_DATA          "Valid name, no data record of requested type.\n"
-
-    MSG_KEYNOVAL            "[GLOBAL]: No value for %1.\n"
-    MSG_KEYBADVAL           "[GLOBAL]: Bad value for %1.\n"
-    MSG_KEYBADSTRUCT        "%1: Bad structure.\n"
-    MSG_KEYBADCHARS         "%1: Bad chars? %1 -> %3.\n"
-    MSG_KEYUNEXPLINE        "Unexpected line ""%1"".\n"
-    MSG_KEYUNEXPEOF         "Unexpended end of file.\n"
-    MSG_KEYUNEXPTOK         "Unexpected token %1.\n"
-    MSG_KEYUNEXPTOKIN       "Unexpected token in %1.\n"
-    MSG_KEYUNEXP            "Unexpected end of file or token.\n"
-    MSG_KEYNOGLOBAL         "No [GLOBAL] definition!\n"
-    MSG_KEYNOCONFIG         "No [CONFIG %1].\n"
-    MSG_KEYUSECONFIG        "Use configuration: %1.\n"
-    MSG_KEYNOSWKEY          "No switch key for ""%1"".\n"
-    MSG_KEYCANNOTDEF        "You cannot define switch key for default keymap - ignored.\n"
-    MSG_KEYDUPSWKEY         "Duplicate switching key.\n"
-    MSG_KEYUNKNOWNMAP       "Unknown keymap %1.\n"
-    MSG_KEYNOCHARMAPS       "No charmaps loaded.\n"
-    MSG_KEYNOKEYMAPS        "No keymaps loaded.\n"
-    MSG_KEYNUMMAPS          "There are %1 maps.\n"
-    MSG_KEYBADMAP           "Bad keymap number - try 'keys display'\n"
-    MSG_KEYMAPSWITCHED      "keymap switched.\n"
-END
-
-#if defined(__MINGW32__) || defined(__CYGWIN__)
-TelnetIcon ICON "telnet.ico"
-#else
-TelnetIcon ICON "../telnet.ico"
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/ansiprsr.cpp b/reactos/apps/utils/net/telnet/src/ansiprsr.cpp
deleted file mode 100644 (file)
index 7659111..0000000
+++ /dev/null
@@ -1,1476 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-///////////////////////////////////////////////////////////////////////////////
-//
-// Module:             ansiprsr.cpp
-//
-// Contents:   ANSI parser base class
-//
-// Product:            telnet
-//
-// Revisions: August 30, 1998 Paul Brannan <pbranna@clemson.edu>
-//            July 29, 1998 pbranna@clemson.edu
-//            June 15, 1998 pbranna@clemson.edu
-//            May 19, 1998  pbranna@clemson.edu
-//            24 Dec, 1997  Andrey.V.Smilianets
-//            05. Sep.1997  roryt@hol.gr (I.Ioannou)
-//            11.May.1997   roryt@hol.gr (I.Ioannou)
-//            6.April.1997  roryt@hol.gr (I.Ioannou)
-//            5.April.1997  jbj@nounname.com
-//            30.M\84rz.1997     Titus_Boxberg@public.uni-hamburg.de
-//                   14.Sept.1996  jbj@nounname.com
-//            Version 2.0
-//
-//            13.Jul.1995      igor.milavec@uni-lj.si
-//                                       Original code
-//
-///////////////////////////////////////////////////////////////////////////////
-
-//#include <windows.h>
-#include <string.h>
-#include "ansiprsr.h"
-
-const int ANSIColors[] = {BLACK, RED, GREEN, YELLOW, BLUE, MAGENTA, CYAN, WHITE};
-
-// The constructor now takes different arguments and initializes different
-// variables (Paul Brannan 6/15/98)
-TANSIParser::TANSIParser(TConsole &RefConsole, KeyTranslator &RefKeyTrans,
-                                                TScroller &RefScroller, TNetwork &RefNetwork,
-                                                TCharmap &RefCharmap):
-TParser(RefConsole, RefKeyTrans, RefScroller, RefNetwork, RefCharmap) {
-       Init();
-       iSavedAttributes = (unsigned char) 7;
-       // must also check to make sure the string is non-NULL
-       // (Paul Brannan 5/8/98)
-       if ((ini.get_dumpfile() != NULL) && (*ini.get_dumpfile() != '\0')){
-               dumpfile = fopen(ini.get_dumpfile(), "wb");
-       }else {
-               dumpfile = NULL;
-       }
-       InPrintMode = 0;
-       printfile = NULL;
-
-       fast_write = ini.get_fast_write(); // Paul Brannan 6/28/98
-       Scroller.init(&StripBuffer);
-}
-
-TANSIParser::~TANSIParser(){
-       if (dumpfile) fclose (dumpfile);
-       // Added I.Ioannou 06 April, 1997
-       if (printfile != NULL) fclose (printfile);
-}
-
-// Created Init() function to initialize the parser but not clear the screen
-// (Paul Brannan 9/23/98)
-void TANSIParser::Init() {
-       // Paul Brannan 6/25/98
-       map_G0 = 'B'; map_G1 = 'B';
-       Charmap.setmap(map_G0);
-       current_map = 'B';
-
-       ignore_margins = 0;
-       vt52_mode = 0;
-       print_ctrl = 0;
-       newline_mode = false;
-
-       KeyTrans.clear_ext_mode();
-
-       iSavedCurY = 0;                                                 // Reset Variables
-       iSavedCurX = 0;
-       inGraphMode = 0;
-       Console.SetScroll(-1, -1);
-       Console.Normal();                                               // Reset Attributes
-
-       // Set tabs stops
-       resetTabStops();
-}
-
-void TANSIParser::ResetTerminal() {
-       Init();
-       Console.ClearScreen();                                  // Clear Screen
-       Console.SetRawCursorPosition(0,0);              // Home Cursor
-}
-void TANSIParser::SaveCurY(int iY){
-       iSavedCurY=iY;
-}
-
-void TANSIParser::SaveCurX(int iX){
-       iSavedCurX=iX;
-}
-
-void TANSIParser::resetTabStops() {
-       for(int j = 0; j < MAX_TAB_POSITIONS; j++) {
-               tab_stops[j] = 8 + j - (j%8);
-       }
-}
-
-void TANSIParser::ConSetAttribute(unsigned char TextAttrib){
-       // Paul Brannan 5/8/98
-       // Made this go a little bit faster by changing from switch{} to an array
-       // for the colors
-       if(TextAttrib >= 30) {
-               if(TextAttrib <= 37) {
-                       Console.SetForeground(ANSIColors[TextAttrib-30]);
-                       return;
-               } else if((TextAttrib >= 40) && (TextAttrib <= 47)) {
-                       Console.SetBackground(ANSIColors[TextAttrib-40]);
-                       return;
-               }
-       }
-       
-       switch (TextAttrib){
-               // Text Attributes
-       case 0: Console.Normal();           break;      // Normal video
-       case 1: Console.HighVideo();        break;      // High video
-       case 2: Console.LowVideo();         break;      // Low video
-       case 4: Console.UnderlineOn();          break;  // Underline on (I.Ioannou)
-       case 5: Console.BlinkOn();                      break;  // Blink video
-               // Corrected by I.Ioannou 11 May, 1997
-       case 7: Console.ReverseOn();            break;  // Reverse video
-       case 8:                                                         break;  // hidden
-               // All from 10 thru 27 are hacked from linux kernel
-               // I.Ioannou 06 April, 1997
-       case 10:
-               //  I.Ioannou 04 Sep 1997 turn on/off high bit
-               inGraphMode = 0;
-               print_ctrl = 0;
-               Charmap.setmap(current_map ? map_G1:map_G0); // Paul Brannan 6/25/98
-               break; // ANSI X3.64-1979 (SCO-ish?)
-               // Select primary font,
-               // don't display control chars
-               // if defined, don't set
-               // bit 8 on output (normal)
-       case 11:
-               inGraphMode = 0;
-               print_ctrl = 1;
-               Charmap.setmap(0); // Paul Brannan 6/25/98
-               break; // ANSI X3.64-1979 (SCO-ish?)
-               // Select first alternate font,
-               // let chars < 32 be displayed
-               // as ROM chars
-       case 12:
-               inGraphMode = 1;
-               print_ctrl = 1;
-               Charmap.setmap(0); // Paul Brannan 6/25/98
-               break; // ANSI X3.64-1979 (SCO-ish?)
-               // Select second alternate font,
-               // toggle high bit before
-               // displaying as ROM char.
-               
-       case 21:                                                                        // not really Low video
-       case 22: Console.LowVideo();            break;  // but this works good also
-       case 24: Console.UnderlineOff();        break;  // Underline off
-       case 25: Console.BlinkOff();            break;  // blink off
-               // Corrected by I.Ioannou 11 May, 1997
-       case 27: Console.ReverseOff();          break;  //Reverse video off
-
-       // Mutt needs this (Paul Brannan, Peter Jordan 12/31/98)
-       // This is from the Linux kernel source
-    case 38: /* ANSI X3.64-1979 (SCO-ish?)
-                         * Enables underscore, white foreground
-                         * with white underscore (Linux - use
-                         * default foreground).
-                         */
-                       Console.UnderlineOn();
-                       Console.SetForeground(ini.get_normal_fg());
-                       break;
-       case 39: /* ANSI X3.64-1979 (SCO-ish?)
-                         * Disable underline option.
-                         * Reset colour to default? It did this
-                         * before...
-                         */
-                       Console.UnderlineOff();
-                       Console.SetForeground(ini.get_normal_fg());
-                       break;
-       case 49:
-                       Console.SetBackground(ini.get_normal_bg());
-                       break;
-
-       }
-}
-
-void TANSIParser::ConSetCursorPos(int x, int y) {
-       if(ignore_margins)
-               Console.SetRawCursorPosition(x, y);
-       else
-               Console.SetCursorPosition(x, y);
-}
-
-const char* TANSIParser::GetTerminalID()
-{
-       return "\033[?1;2c";
-}
-
-// All of the Telnet protocol stuff has been moved to TTelHndl.cpp
-// This is more consistent with what OO should be
-// (Paul Brannan 6/15/98)
-
-#ifdef __BORLANDC__
-// argsused doesn't work on MSVC++
-#pragma argsused
-#endif
-
-// Use this for the VT100 flags (Paul Brannan 12/2/98)
-#define FLAG_DOLLAR            0x0001
-#define FLAG_QMARK             0x0002
-#define FLAG_GREATER   0x0004
-#define FLAG_LESS              0x0008
-#define FLAG_EXCLAM            0x0010
-#define FLAG_AMPERSAND 0x0020
-#define FLAG_SLASH             0x0040
-#define FLAG_EQUAL             0x0080
-#define FLAG_QUOTE             0x0100
-#define FLAG_OTHER             0x8000
-
-char* TANSIParser::ParseEscapeANSI(char* pszBuffer, char* pszBufferEnd)
-{
-       
-       //      The buffer contains something like <ESC>[pA
-       //      where p is an optional decimal number specifying the count by which the
-       //      appropriate action should take place.
-       //      The pointer pszBuffer points us to the p, <ESC> and [ are
-       //      already 'consumed'
-       
-       //      TITUS: Simplification of the code: Assume default count of 1 in case
-       //      there are no parameters.
-       char tmpc;
-       const int nParam = 10;  // Maximum number of parameters
-       int     iParam[nParam] = {1, 0, 0, 0, 0};       // Assume 1 Parameter, Default 1
-       int iCurrentParam = 0;
-       DWORD flag = 0;
-       int missing_param = 0;
-
-       // Get parameters from escape sequence.
-       while ((tmpc = *pszBuffer) <= '?') {
-
-               if(tmpc < '0' || tmpc > '9') {
-                       // Check for parameter delimiter.
-                       if(tmpc == ';') {
-                               // This is a hack (Paul Brannan 6/27/98)
-                               if(*(pszBuffer - 1) == '[') missing_param = iCurrentParam+1;
-                               pszBuffer++;
-                               continue;
-                       }
-
-                       // It is legal to have control characters inside ANSI sequences
-                       // (Paul Brannan 6/26/98)
-                       if(tmpc < ' ') {
-                               Console.WriteCtrlChar(tmpc);
-                               pszBuffer++;
-                               continue;
-                       }
-
-                       // A new way of handling flags (Paul Brannan 12/2/98)
-                       switch(tmpc) {
-                       case '$': flag |= FLAG_DOLLAR; break;
-                       case '?': flag |= FLAG_QMARK; break;
-                       case '>': flag |= FLAG_GREATER; break;
-                       case '<': flag |= FLAG_LESS; break;
-                       case '!': flag |= FLAG_EXCLAM; break;
-                       case '&': flag |= FLAG_AMPERSAND; break;
-                       case '/': flag |= FLAG_SLASH; break;
-                       case '=': flag |= FLAG_EQUAL; break;
-                       case '\"': flag |= FLAG_QUOTE; break;
-                       default: flag |= FLAG_OTHER; break;
-                       }
-
-                       pszBuffer++;
-               }
-
-               //  Got Numerical Parameter.
-               iParam[iCurrentParam] = strtoul(pszBuffer, &pszBuffer, 10);
-               if (iCurrentParam < nParam)
-                       iCurrentParam++;
-       }
-       
-       //~~~ TITUS: Apparently the digit is optional (look at termcap or terminfo)
-       // So: If there is no digit, assume a count of 1
-       
-       switch ((unsigned char)*pszBuffer++) {
-               // Insert Character
-               case '@':
-                       if(iParam[0] == 0) iParam[0] = 1; // Paul Brannan 9/1/98
-                       Console.InsertCharacter(iParam[0]); break;
-               // Move cursor up.
-               case 'A':
-                       if(iParam[0] == 0) iParam[0] = 1;
-                       Console.MoveCursorPosition(0, -iParam[0]); break;
-               // Move cursor down.
-               // Added by I.Ioannou 06 April, 1997
-               case 'B':
-               case 'e':
-                       if(iParam[0] == 0) iParam[0] = 1;
-                       Console.MoveCursorPosition(0, iParam[0]);
-                       break;
-               // Move cursor right.
-               // Added by I.Ioannou 06 April, 1997
-               case 'C':
-               case 'a':
-                       // Handle cursor size sequences (Jose Cesar Otero Rodriquez and
-                       // Paul Brannan, 3/27/1999)
-                       if(flag & FLAG_EQUAL) {
-                               switch(iParam[0]) {
-                               case 7: Console.SetCursorSize(50); break;
-                               case 11: Console.SetCursorSize(6); break;
-                               case 32: Console.SetCursorSize(0); break;
-                               default: Console.SetCursorSize(13);
-                               }
-                       } else {
-                               if(iParam[0] == 0) iParam[0] = 1;
-                               Console.MoveCursorPosition(iParam[0], 0);
-                               break;
-                       }
-               // Move cursor left.
-               case 'D':
-                       if(iParam[0] == 0) iParam[0] = 1;
-                       Console.MoveCursorPosition(-iParam[0], 0);
-                       break;
-               // Move cursor to beginning of line, p lines down.
-               // Added by I.Ioannou 06 April, 1997
-               case 'E': 
-                       Console.MoveCursorPosition(-Console.GetCursorX(), iParam[0]);
-                       break;
-               // Moves active position to beginning of line, p lines up
-               // Added by I.Ioannou 06 April, 1997
-               // With '=' this changes the default fg color (Paul Brannan 6/27/98)
-               case 'F':
-                       if(flag & FLAG_EQUAL)
-                               Console.setDefaultFg(iParam[0]);
-                       else
-                               Console.MoveCursorPosition(-Console.GetCursorX(), -iParam[0]);
-                       break;
-               // Go to column p
-               // Added by I.Ioannou 06 April, 1997
-               // With '=' this changes the default bg color (Paul Brannan 6/27/98)
-               case '`': 
-               case 'G': // 'G' is from Linux kernel sources
-                       if(flag & FLAG_EQUAL) {
-                               Console.setDefaultBg(iParam[0]);
-                       } else {
-                               if (iCurrentParam < 1)                  // Alter Default
-                                       iParam[0] = 0;
-                               // this was backward, and we should subtract 1 from x
-                               // (Paul Brannan 5/27/98)
-                               ConSetCursorPos(iParam[0] - 1, Console.GetCursorY());
-                       }
-                       break;
-               // Set cursor position.
-               case 'f': 
-               case 'H':
-                       if (iCurrentParam < 2 || iParam[1] < 1)
-                               iParam[1] = 1;
-                       ConSetCursorPos(iParam[1] - 1, iParam[0] - 1);
-                       break;
-               // Clear screen
-               case 'J': 
-                       if ( iCurrentParam < 1 ) iParam[0] = 0; // Alter Default
-                       switch (iParam[0]) {
-                               case 0: Console.ClearEOScreen(); break;
-                               case 1: Console.ClearBOScreen(); break;
-                               case 2:
-                                       Console.ClearScreen();
-                                       Console.SetRawCursorPosition(0, 0);
-                                       break;
-                       }
-                       break;
-               // Clear line
-               case 'K': 
-                       if (iCurrentParam < 1)                  // Alter Default
-                               iParam[0] = 0;
-                       switch (iParam[0]) {
-                               case 0: Console.ClearEOLine(); break;
-                               case 1: Console.ClearBOLine(); break;
-                               case 2: Console.ClearLine(); break;
-                       }
-                       break;
-               //  Insert p new, blank lines.
-               // Added by I.Ioannou 06 April, 1997
-               case 'L': 
-                       {
-                               // for (int i = 1; i <= iParam[0]; i++)
-                               // This should speed things up a bit (Paul Brannan 9/2/98)
-                               Console.ScrollDown(Console.GetRawCursorY(), -1, iParam[0]);
-                               break;
-                       }
-               //  Delete p lines.
-               // Added by I.Ioannou 06 April, 1997
-               case 'M': 
-                       {
-                               for (int i = 1; i <= iParam[0]; i++)
-                               // This should speed things up a bit (Paul Brannan 9/2/98)
-                               Console.ScrollDown(Console.GetRawCursorY(), -1, -1);
-                               break;
-                       }
-               // DELETE CHAR
-               case 'P': 
-                       Console.DeleteCharacter(iParam[0]);
-                       break;
-               // Scrolls screen up (down? -- PB) p lines,
-               // Added by I.Ioannou 06 April, 1997
-               // ANSI X3.64-1979 references this but I didn't
-               // found it in any telnet implementation
-               // note 05 Oct 97  : but SCO terminfo uses them, so uncomment them !!
-               case 'S': 
-                       {
-                               //for (int i = 1; i <= iParam[0]; i++)
-                               // This should speed things up a bit (Paul Brannan 9/2/98)
-                               Console.ScrollDown(-1, -1, -iParam[0]);
-                               break;
-                       }
-               // Scrolls screen up p lines,
-               // Added by I.Ioannou 06 April, 1997
-               // ANSI X3.64-1979 references this but I didn't
-               // found it in any telnet implementation
-               // note 05 Oct 97  : but SCO terminfo uses them, so uncomment them !!
-               case 'T': 
-                       {
-                               // for (int i = 1; i <= iParam[0]; i++)
-                               // This should speed things up a bit (Paul Brannan 9/2/98)
-                               Console.ScrollDown(-1, -1, iParam[0]);
-                               break;
-                       }
-               //  Erases p characters up to the end of line
-               // Added by I.Ioannou 06 April, 1997
-               case 'X': 
-                       {
-                               int iKeepX = Console.GetRawCursorX();
-                               int iKeepY = Console.GetRawCursorY();
-                               if (iParam[0] > Console.GetWidth())
-                                       iParam[0] = Console.GetWidth(); // up to the end of line
-                               for ( int i = 1; i <= iParam[0]; i++ )
-                                       Console.WriteString(" ", 1);
-                               Console.SetRawCursorPosition(iKeepX , iKeepY);
-                               break;
-                       }
-               // Go back p tab stops
-               // Added by I.Ioannou 06 April, 1997
-               // Implemented by Paul Brannan, 4/13/2000
-               case 'Z':
-                       {
-                               int x = Console.GetCursorX();
-                               for(int j = 0; x > 0 && j < iParam[0]; j++)
-                                       while(x > 0 && tab_stops[j] == tab_stops[x]) x--;
-                               Console.SetCursorPosition(x, Console.GetCursorY());
-                       }
-                       break;
-               // Get Terminal ID
-               case 'c': 
-                       {
-                               const char* szTerminalId = GetTerminalID();
-                               Network.WriteString(szTerminalId, strlen(szTerminalId));
-                               break;
-                       }
-               // TITUS++ 2. November 1998: Repeat Character.
-               case 'b':
-                       // isprint may be causing problems (Paul Brannan 3/27/99)
-                       // if ( isprint(last_char) ) {
-                               char    buf[150];       // at most 1 line (max 132 chars)
-
-                               if ( iParam[0] > 149 ) iParam[0] = 149;
-                               memset(buf, last_char, iParam[0]);
-                               buf[iParam[0]] = 0;
-                               if ( fast_write )
-                                       Console.WriteStringFast(buf, iParam[0]);
-                               else
-                                       Console.WriteString(buf, iParam[0]);
-                       // } /* IF */
-               break;
-               // Go to line p
-               // Added by I.Ioannou 06 April, 1997
-               case 'd': 
-                       if (iCurrentParam < 1)                  // Alter Default
-                               iParam[0] = 0;
-                       // this was backward, and we should subtract 1 from y
-                       // (Paul Brannan 5/27/98)
-                       ConSetCursorPos(Console.GetCursorX(), iParam[0] - 1);
-                       break;
-               // iBCS2 tab erase
-               // Added by I.Ioannou 06 April, 1997
-               case 'g': 
-                       if (iCurrentParam < 1)                  // Alter Default
-                               iParam[0] = 0;
-                       switch (iParam[0]) {
-                               case 0:
-                                       {
-                                               // Clear the horizontal tab stop at the current active position
-                                               for(int j = 0; j < MAX_TAB_POSITIONS; j++) {
-                                                       int x = Console.GetCursorX();
-                                                       if(tab_stops[j] == x) tab_stops[j] = tab_stops[x + 1];
-                                               }
-                                       }
-                                       break;
-                               case 2:
-                                       // I think this might be "set as default?"
-                                       break;
-                               case 3:
-                                       {
-                                               // Clear all tab stops
-                                               for(int j = 0; j < MAX_TAB_POSITIONS; j++)
-                                                       tab_stops[j] = -1;
-                                       }
-                                       break;
-                       }
-                       break;
-               // Set extended mode
-               case 'h': 
-                       {
-                               for (int i = 0; i < iCurrentParam; i++) {
-                                       // Changed to a switch statement (Paul Brannan 5/27/98)
-                                       if(flag & FLAG_QMARK) {
-                                               switch(iParam[i]) {
-                                                       case 1: // App cursor keys
-                                                               KeyTrans.set_ext_mode(APP_KEY);
-                                                               break;
-                                                       case 2: // VT102 mode
-                                                               vt52_mode = 0;
-                                                               KeyTrans.unset_ext_mode(APP2_KEY);
-                                                               break;
-                                                       case 3: // 132 columns
-                                                               if(ini.get_wide_enable()) {
-                                                                       Console.SetWindowSize(132, -1);
-                                                               }
-                                                               break;
-                                                       case 4: // smooth scrolling
-                                                               break;
-                                                       case 5: // Light background
-                                                               Console.Lightbg();
-                                                               break;
-                                                       case 6: // Stay in margins
-                                                               ignore_margins = 0;
-                                                               break;
-                                                       case 7:
-                                                               Console.setLineWrap(true);
-                                                               break;
-                                                       case 8: // Auto-repeat keys
-                                                               break;
-                                                       case 18: // Send FF to printer
-                                                               break;
-                                                       case 19: // Entire screen legal for printer
-                                                               break;
-                                                       case 25: // Visible cursor
-                                                               break;
-                                                       case 66: // Application numeric keypad
-                                                               break;
-                                                       default:
-#ifdef DEBUG
-                                                               Console.Beep();
-#endif
-                                                               break;
-                                               }
-                                       } else {
-                                               switch(iParam[i]) {
-                                                       case 2: // Lock keyboard
-                                                               break;
-                                                       case 3: // Act upon control codes (PB 12/5/98)
-                                                               print_ctrl = 0;
-                                                               break;
-                                                       case 4: // Set insert mode
-                                                               Console.InsertMode(1);
-                                                               break;
-                                                       case 12: // Local echo off
-                                                               break;
-                                                       case 20: // Newline sends cr/lf
-                                                               KeyTrans.set_ext_mode(APP4_KEY);
-                                                               newline_mode = true;
-                                                               break;
-                                                       default:
-#ifdef DEBUG
-                                                               Console.Beep();
-#endif
-                                                               break;
-                                               }
-                                       }
-                               }
-                       }
-                       break;
-               // Print Screen
-               case 'i': 
-                       if (iCurrentParam < 1)
-                               iParam[0]=0;
-                       switch (iParam[0]){
-                               case 0: break; // Print Screen
-                               case 1: break; // Print Line
-                               // Added I.Ioannou 06 April, 1997
-                               case 4:
-                                       // Stop Print Log
-                                       InPrintMode = 0;
-                                       if ( printfile != NULL )
-                                               fclose(printfile);
-                                       break;
-                               case 5:
-                                       // Start Print Log
-                                       printfile = fopen(ini.get_printer_name(), "ab");
-                                       if (printfile != NULL) InPrintMode = 1;
-                                       break;
-                       }
-                       break;
-               // Unset extended mode
-               case 'l': 
-                       {
-                               for (int i = 0; i < iCurrentParam; i++) {
-                                       // Changed to a switch statement (Paul Brannan 5/27/98)
-                                       if(flag & FLAG_QMARK) {
-                                               switch(iParam[i]) {
-                                                       case 1: // Numeric cursor keys
-                                                               KeyTrans.unset_ext_mode(APP_KEY);
-                                                               break;
-                                                       case 2: // VT52 mode
-                                                               vt52_mode = 1;
-                                                               KeyTrans.set_ext_mode(APP2_KEY);
-                                                               break;
-                                                       case 3: // 80 columns
-                                                               if(ini.get_wide_enable()) {
-                                                                       Console.SetWindowSize(80, -1);
-                                                               }
-                                                               break;
-                                                       case 4: // jump scrolling
-                                                               break;
-                                                       case 5: // Dark background
-                                                               Console.Darkbg();
-                                                               break;
-                                                       case 6: // Ignore margins
-                                                               ignore_margins = 1;
-                                                               break;
-                                                       case 7:
-                                                               Console.setLineWrap(false);
-                                                               break;
-                                                       case 8: // Auto-repeat keys
-                                                               break;
-                                                       case 19: // Only send scrolling region to printer
-                                                               break;
-                                                       case 25: // Invisible cursor
-                                                               break;
-                                                       case 66: // Numeric keypad
-                                                               break;
-                                                       default:
-#ifdef DEBUG
-                                                               Console.Beep();
-#endif
-                                                               break;
-                                               }
-                                       } else {
-                                               switch(iParam[i]) {
-                                                       case 2: // Unlock keyboard
-                                                               break;
-                                                       case 3: // Display control codes (PB 12/5/98)
-                                                               print_ctrl = 1;
-                                                               break;
-                                                       case 4: // Set overtype mode
-                                                               Console.InsertMode(0);
-                                                               break;
-                                                       case 12: // Local echo on
-                                                               break;
-                                                       case 20: // sends lf only
-                                                               KeyTrans.unset_ext_mode(APP4_KEY);
-                                                               newline_mode = false;
-                                                               break;
-                                                       default:
-#ifdef DEBUG
-                                                               Console.Beep();
-#endif
-                                                               break;
-                                               }
-                                       }
-                               }
-                       }
-                       break;
-               // Set color
-               case 'm':
-                       if(missing_param) Console.Normal();
-                       if(iCurrentParam == 0) {
-                               Console.Normal();
-                       } else {
-                               for(int i = 0; i < iCurrentParam; i++)
-                                       ConSetAttribute(iParam[i]);
-                       }
-                       break;
-               // report cursor position Row X Col
-               case 'n': 
-                       if (iCurrentParam == 1 && iParam[0]==5) {
-                               // report the cursor position
-                               Network.WriteString("\x1B[0n", 6);
-                               break;
-                       }
-                       if (iCurrentParam == 1 && iParam[0]==6){
-                               // report the cursor position
-                               // The cursor position needs to be sent as a single string
-                               // (Paul Brannan 6/27/98)
-                               char szCursorReport[40] = "\x1B[";
-
-                               itoa(Console.GetCursorY() + 1,
-                                       &szCursorReport[strlen(szCursorReport)], 10);
-                               strcat(szCursorReport, ";");
-                               itoa(Console.GetCursorX() + 1,
-                                       &szCursorReport[strlen(szCursorReport)], 10);
-                               strcat(szCursorReport, "R");
-
-                               Network.WriteString(szCursorReport, strlen(szCursorReport));
-               
-                       }
-                       break;
-               // Miscellaneous weird sequences (Paul Brannan 6/27/98)
-               case 'p':
-                       // Set conformance level
-                       if(flag & FLAG_QUOTE) {
-                               break;
-                       }
-                       // Soft terminal reset
-                       if(flag & FLAG_EXCLAM) {
-                               break;
-                       }
-                       // Report mode settings
-                       if(flag & FLAG_DOLLAR) {
-                               break;
-                       }
-                       break;
-               // Scroll Screen
-               case 'r': 
-                       if (iCurrentParam < 1) {
-                               // Enable scrolling for entire display
-                               Console.SetScroll(-1, -1);
-                               break;
-                       }
-                       if (iCurrentParam >1) {
-                               // Enable scrolling from row1 to row2
-                               Console.SetScroll(iParam[0] - 1, iParam[1] - 1);
-                               // If the cursor is outside the scrolling range, fix it
-                               // (Paul Brannan 6/26/98)
-                               // if(Console.GetRawCursorY() < iParam[0] - 1) {
-                               //      Console.SetRawCursorPosition(Console.GetCursorX(),
-                               //              iParam[0] - 1);
-                               // }
-                               // if(Console.GetRawCursorY() > iParam[1] - 1) {
-                               //      Console.SetRawCursorPosition(Console.GetCursorX(),
-                               //              iParam[1] - 1);
-                               // }
-                       }
-                       // Move the cursor to the home position (Paul Brannan 12/2/98)
-                       Console.SetCursorPosition(0, 0);
-                       break;
-               // Save cursor position
-               case 's': 
-                       SaveCurY(Console.GetRawCursorY());
-                       SaveCurX(Console.GetRawCursorX());
-                       break;
-               // Restore cursor position
-               case 'u': 
-                       Console.SetRawCursorPosition(iSavedCurX, iSavedCurY);
-                       break;
-               // DEC terminal report (Paul Brannan 6/28/98)
-               case 'x':
-                       if(iParam[0])
-                               Network.WriteString("\033[3;1;1;128;128;1;0x", 20);
-                       else
-                               Network.WriteString("\033[2;1;1;128;128;1;0x", 20);
-                       break;
-               default:
-#ifdef DEBUG
-                       Console.Beep();
-#endif
-                       break;
-       }
-
-       return pszBuffer;
-}
-
-#ifdef MTE_SUPPORT
-// Added by Frediano Ziglio, 5/31/2000
-// MTE extension
-// initially copied from ParseEscapeANSI
-char* TANSIParser::ParseEscapeMTE(char* pszBuffer, char* pszBufferEnd)
-{
-       //      The buffer contains something like <ESC>~pA
-       //      where p is an optional decimal number specifying the count by which the
-       //      appropriate action should take place.
-       //      The pointer pszBuffer points us to the p, <ESC> and ~ are
-       //      already 'consumed'
-       //      TITUS: Simplification of the code: Assume default count of 1 in case
-       //      there are no parameters.
-       char tmpc;
-       const int nParam = 10;  // Maximum number of parameters
-       int     iParam[nParam] = {1, 0, 0, 0, 0};       // Assume 1 parameter, Default 1
-       int iCurrentParam = 0;
-       char sRepeat[2];
-       
-       // Get parameters from escape sequence.
-       while ((tmpc = *pszBuffer) <= '?') {
-               if(tmpc < '0' || tmpc > '9') {
-                       // Check for parameter delimiter.
-                       if(tmpc == ';') {
-                               pszBuffer++;
-                               continue;
-                       }
-                       pszBuffer++;
-               }
-               
-               //  Got Numerical Parameter.
-               iParam[iCurrentParam] = strtoul(pszBuffer, &pszBuffer, 10);
-               if (iCurrentParam < nParam)
-                       iCurrentParam++;
-       }
-       
-       //~~~ TITUS: Apparently the digit is optional (look at termcap or terminfo)
-       // So: If there is no digit, assume a count of 1
-       
-       switch ((unsigned char)*pszBuffer++) {
-               case 'A':
-                       // set colors
-                       if (iCurrentParam < 2 )
-                               break;
-                       if (iParam[0] <= 15 && iParam[1] <= 15)
-                               Console.SetAttrib( (iParam[1] << 4) | iParam[0] );
-                       break;
-                       
-               case 'R':
-                       // define region
-                       mteRegionXF = -1;
-                       if (iCurrentParam < 2 )
-                               break;
-                       mteRegionXF = iParam[1]-1;
-                       mteRegionYF = iParam[0]-1;
-                       break;
-                       
-               case 'F':
-                       // fill with char
-                       {
-                               if (mteRegionXF == -1 || iCurrentParam < 1)
-                                       break;
-                               sRepeat[0] = (char)iParam[0];
-                               sRepeat[1] = '\0';
-                               int xi = Console.GetCursorX(),yi = Console.GetCursorY();
-                               int xf = mteRegionXF;
-                               int yf = mteRegionYF;
-                               mteRegionXF = -1;
-                               for(int y=yi;y<=yf;++y)
-                               {
-                                       Console.SetCursorPosition(xi,y);
-                                       for(int x=xi;x<=xf;++x)
-                                               
-                                               Console.WriteStringFast(sRepeat,1);
-                               }
-                       }
-                       break;
-                       
-               case 'S':
-                       // Scroll region
-                       {
-                               if (mteRegionXF == -1 || iCurrentParam < 2)
-                                       break;
-                               int /*x = Console.GetCursorX(),*/y = Console.GetCursorY();
-                               // int xf = mteRegionXF;
-                               int yf = mteRegionYF;
-                               mteRegionXF = -1;
-                               // !!! don't use x during scroll
-                               int diff = (iParam[0]-1)-y;
-                               if (diff<0)
-                                       Console.ScrollDown(y-1,yf,diff);
-                               else
-                                       Console.ScrollDown(y,yf+1,diff);
-                       }
-                       break;
-                       // Meridian main version ??
-               case 'x':
-                       // disable echo and line mode
-                       Network.set_local_echo(0);
-                       Network.set_line_mode(0);
-                       // Meridian Server handle cursor itself
-                       Console.SetCursorSize(0);
-                       break;
-                       // query ??
-               case 'Q':
-                       if (iParam[0] == 1)
-                               Network.WriteString("\033vga.",5);
-                       break;
-               default:
-#ifdef DEBUG
-                       Console.Beep();
-#endif
-                       break;
-       }
-       
-       return pszBuffer;
- }
-#endif
-
-char* TANSIParser::ParseEscape(char* pszBuffer, char* pszBufferEnd) {
-       char *pszChar;
-
-       // Check if we have enough characters in buffer.
-       if ((pszBufferEnd - pszBuffer) < 2)
-               return pszBuffer;
-       
-       //  I.Ioannou 04 Sep 1997
-       // there is no need for pszBuffer++; after each command
-       
-       // Decode the command.
-       pszBuffer++;
-       
-       switch (*pszBuffer++) {
-               case 'A': // Cursor up
-                       Console.MoveCursorPosition(0, -1);
-                       break;
-               // Cursor down
-               case 'B': 
-                       Console.MoveCursorPosition(0, 1);
-                       break;
-               // Cursor right
-               case 'C':
-                       Console.MoveCursorPosition(1, 0);
-                       break;
-               // LF *or* cursor left (Paul Brannan 6/27/98)
-               case 'D':
-                       if(vt52_mode)
-                               Console.MoveCursorPosition(-1, 0);
-                       else
-                               Console.index();
-                       break;
-               // CR/LF (Paul Brannan 6/26/98)
-               case 'E':
-                       Console.WriteCtrlString("\r\n", 2);
-                       break;
-               // Special graphics char set (Paul Brannan 6/27/98)
-               case 'F':
-                       Charmap.setmap('0');
-                       break;
-               // ASCII char set (Paul Brannan 6/27/98)
-               case 'G':
-                       Charmap.setmap('B');
-                       break;
-               // Home cursor/tab set
-               case 'H': 
-                       if(ini.get_vt100_mode()) {
-                               int x = Console.GetCursorX();
-                               if(x != 0) {
-                                       int t = tab_stops[x - 1];
-                                       for(int j = x - 1; j >= 0 && tab_stops[j] == t; j--)
-                                               tab_stops[j] = x;
-                               }
-                       } else {
-                               //  I.Ioannou 04 Sep 1997 (0,0) not (1,1)
-                               ConSetCursorPos(0, 0);
-                       }
-                       break;
-               // Reverse line feed (Paul Brannan 6/27/98)
-               // FIX ME!!!  reverse_index is wrong to be calling here
-               // (Paul Brannan 12/2/98)
-               case 'I':
-                       Console.reverse_index();
-                       break;
-               // Erase end of screen
-               case 'J': 
-                       Console.ClearEOScreen();
-                       break;
-               // Erase EOL
-               case 'K':
-                       Console.ClearEOLine();
-                       break;
-               // Scroll Up one line //Reverse index
-               case 'M':
-                       Console.reverse_index();
-                       break;
-               // Direct cursor addressing
-               case 'Y':
-                       if ((pszBufferEnd - pszBuffer) >= 2){
-                               // if we subtract '\x1F', then we may end up with a negative
-                               // cursor position! (Paul Brannan 6/26/98)
-                               ConSetCursorPos(pszBuffer[1] - ' ',     pszBuffer[0] - ' ');
-                               pszBuffer+=2;
-                       } else {
-                               pszBuffer--; // Paul Brannan 6/26/98
-                       }
-                       break;
-               // Terminal ID Request
-               case 'Z':
-                       {
-                               const char* szTerminalId = GetTerminalID();
-                               Network.WriteString(szTerminalId, strlen(szTerminalId));
-                               break;
-                       }
-               // reset terminal to defaults
-               case 'c':
-                       ResetTerminal();
-                       break;
-               // Enter alternate keypad mode
-               case '=':
-                       KeyTrans.set_ext_mode(APP3_KEY);
-                       break;
-               // Exit alternate keypad mode
-               case '>':
-                       KeyTrans.unset_ext_mode(APP3_KEY);
-                       break;
-               // Enter ANSI mode
-               case '<':
-                       KeyTrans.unset_ext_mode(APP2_KEY); // exit vt52 mode
-                       break;
-               // Graphics processor on (See note 3)
-               case '1':
-                       break;
-               // Line size commands
-               case '#':        //Line size commands
-                       // (Paul Brannan 6/26/98)
-                       if(pszBuffer < pszBufferEnd) {
-                               switch(*pszBuffer++) {
-                               case '3': break; // top half of a double-height line
-                               case '4': break; // bottom half of a double-height line
-                               case '6': break; // current line becomes double-width
-                               case '8': Console.ClearScreen('E'); break;
-                               }
-                       } else {
-                               pszBuffer--;
-                       }                       
-                       break;
-               // Graphics processor off (See note 3)
-               case '2':
-                       break;
-               // Save cursor and attribs
-               case '7':
-                       SaveCurY(Console.GetRawCursorY());
-                       SaveCurX(Console.GetRawCursorX());
-                       iSavedAttributes = Console.GetAttrib();
-                       break;
-                       // Restore cursor position and attribs
-               case '8':
-                       Console.SetRawCursorPosition(iSavedCurX, iSavedCurY);
-                       Console.SetAttrib(iSavedAttributes);
-                       break;
-               // Set G0 map (Paul Brannan 6/25/98)
-               case '(':
-                       if (pszBuffer < pszBufferEnd) {
-                               map_G0 = *pszBuffer;
-                               if(current_map == 0) Charmap.setmap(map_G0);
-                               pszBuffer++;
-                       } else {
-                               pszBuffer--;
-                       }
-                       break;
-               // Set G1 map (Paul Brannan 6/25/98)
-               case ')':
-                       if (pszBuffer < pszBufferEnd) {
-                               map_G1 = *pszBuffer;
-                               if(current_map == 1) Charmap.setmap(map_G1);
-                               pszBuffer++;
-                       } else {
-                               pszBuffer--;
-                       }
-                       break;
-               // This doesn't do anything, as far as I can tell, but it does take
-               // a parameter (Paul Brannan 6/27/98)
-               case '%':
-                       if (pszBuffer < pszBufferEnd) {
-                               pszBuffer++;
-                       } else {
-                               pszBuffer--;
-                       }
-                       break;
-               // ANSI escape sequence
-               case '[':
-                       // Check if we have whole escape sequence in buffer.
-                       // This should not be isalpha anymore (Paul Brannan 9/1/98)
-                       pszChar = pszBuffer;
-                       while ((pszChar < pszBufferEnd) && (*pszChar <= '?'))
-                               pszChar++;
-                       if (pszChar == pszBufferEnd)
-                               pszBuffer -= 2;
-                       else
-                               pszBuffer = ParseEscapeANSI(pszBuffer, pszBufferEnd);
-                       break;
-#ifdef MTE_SUPPORT
-               case '~':
-                       // Frediano Ziglio, 5/31/2000
-                       // Meridian Terminal Emulator extension
-                       // !!! same as ANSI
-                       // !!! should put in MTE procedure
-                       pszChar = pszBuffer;
-                       while ((pszChar < pszBufferEnd) && (*pszChar <= '?'))
-                               pszChar++;
-                       if (pszChar == pszBufferEnd)
-                               pszBuffer -= 2;
-                       else
-                               pszBuffer = ParseEscapeMTE(pszBuffer, pszBufferEnd);
-                       break;
-#endif
-               default:
-#ifdef DEBUG
-                       Console.Beep();
-#endif
-                       break;
-       }
-
-       return pszBuffer;
-}
-
-// This function now only parses the ANSI buffer and does not do anything
-// with IAC sequences.  That code has been moved to TTelHndl.cpp.
-// The scroller update routines have been moved to TScroll.cpp.
-// (Paul Brannan 6/15/98)
-char* TANSIParser::ParseBuffer(char* pszHead, char* pszTail){
-       // copy into ANSI buffer
-       char * pszResult;
-       
-       // Parse the buffer for ANSI or display
-       while (pszHead < pszTail) {
-               if(!ini.get_output_redir()) {
-                       pszResult = ParseANSIBuffer(pszHead, pszTail);
-               } else {
-                       // Output is being redirected
-                       if(ini.get_strip_redir()) {
-                               // Skip the WriteFile() altogether and pass the buffer to a filter
-                               // Mark Miesfield 09/24/2000
-                               pszResult = PrintGoodChars(pszHead, pszTail);
-                       } else {
-                               DWORD Result;
-                               // Paul Brannan 7/29/98
-                               // Note that this has the unforunate effect of printing out
-                               // NULL (ascii 0) characters onto the screen
-                               if (!WriteFile(GetStdHandle(STD_OUTPUT_HANDLE), pszHead,
-                                       pszTail - pszHead, &Result,     NULL)) pszResult = pszHead;
-                               pszResult = pszHead + Result;
-                       }
-               }
-               if (dumpfile)
-                       fwrite( pszHead, sizeof (char), pszResult-pszHead, dumpfile);
-               if(ini.get_scroll_enable()) Scroller.update(pszHead, pszResult);
-               if (pszResult == pszHead) break;
-               pszHead = pszResult;
-       }
-       // return the new head to the buffer
-       return pszHead;
-}
-
-// A simple routine to strip ANSI sequences
-// This isn't perfect, but it does an okay job (Paul Brannan 7/5/98)
-// Fixed a line counting bug (Paul Brannan 12/4/98)
-int TANSIParser::StripBuffer(char* pszHead, char* pszTail, int width) {
-       int lines = 0, c = 0;
-       char *pszBuf = pszHead;
-
-       while(pszHead < pszTail) {
-               if(iscntrl(*pszHead)) {
-                       switch(*(pszHead++)) {
-                       case 8:
-                       case 127:
-                               if(c>0) {
-                                       if(!(c%width)) lines--;
-                                       c--;
-                                       pszBuf--;
-                               }
-                               break;
-                       case 10: lines++;
-                       case 13:
-                               *(pszBuf++) = *(pszHead - 1);
-                               c = 0;
-                               break;
-                       case 27:
-                               switch(*(pszHead++)) {
-                               case 'Y': pszHead += 2; break;
-                               case '#':
-                               case '(':
-                               case ')':
-                               case '%': pszHead++; break;
-                               case '[':
-                                       while((pszHead < pszTail) && (*pszHead < '?'))
-                                               pszHead++;
-                                       pszHead++;
-                                       break;
-                               }
-                       }
-               } else {
-                       *(pszBuf++) = *(pszHead++);
-                       c++;
-               }
-               if(c != 0 && !(c%width))
-                       lines++;
-       }
-       
-       // Fill in the end of the buffer with blanks
-       while(pszBuf <= pszTail) *pszBuf++ = ' ';
-
-       return lines;
-}
-
-char* TANSIParser::ParseANSIBuffer(char* pszBuffer, char* pszBufferEnd)
-{
-       if(InPrintMode) {
-               return PrintBuffer(pszBuffer, pszBufferEnd);
-       }
-       
-       unsigned char tmpc = *(unsigned char *)pszBuffer;
-
-       if(tmpc == 27) {
-               return ParseEscape(pszBuffer, pszBufferEnd);
-       }
-       
-//     if((fast_write && tmpc < 32) ||
-//             !print_ctrl && (tmpc < 32 || (EightBit_Ansi &&
-//             (tmpc > 128 && tmpc < 128 + ' ')))) {
-
-       // We shouldn't print ctrl characters when fast write is enabled
-       // and ctrl chars are disabled (Paul Brannan 9/1/98)
-       if(tmpc < 32) {
-               // From the Linux kernel (Paul Brannan 12/5/98):
-               /* A bitmap for codes <32. A bit of 1 indicates that the code
-                * corresponding to that bit number invokes some special action
-                * (such as cursor movement) and should not be displayed as a
-                * glyph unless the disp_ctrl mode is explicitly enabled.
-                */
-               const long CTRL_ACTION = 0x0d00ff81;
-               const long CTRL_ALWAYS = 0x0800f501;
-               if(!(((print_ctrl?CTRL_ALWAYS:CTRL_ACTION)>>tmpc)&1)) {
-                       
-                       Console.WriteString((char *)&tmpc, 1);
-                       pszBuffer++;
-                       return pszBuffer;
-               }
-
-               switch (tmpc) {
-               case 0:
-                       pszBuffer++;
-                       break;
-               
-               // I.Ioannou 5/30/98
-               case 7:
-                       Console.Beep();
-                       pszBuffer++;
-                       break;
-               
-               // destructive backspace
-               case 8:
-                       // Added option for destructive backspace (Paul Brannan 5/13/98)
-                       // Changed to ConWriteCtrlString so that the cursor position can be
-                       // updated (Paul Brannan 5/25/98)
-                       if(ini.get_dstrbksp()) {
-                               Console.WriteCtrlChar('\b');
-                               Console.WriteString(" ", 1);
-                               Console.WriteCtrlChar('\b');
-                       }
-                       else Console.WriteCtrlChar('\b');
-                       pszBuffer++;
-                       break;
-               
-               // horizontal tab
-               case 9:
-                       {
-                               pszBuffer++;
-                               int x = Console.GetCursorX();
-                               if(x != -1)
-                                       Console.SetCursorPosition(tab_stops[x], Console.GetCursorY());
-                       }
-                       break;
-               
-               // Line Feed Char
-               case 10:
-                       // Test for local echo (Paul Brannan 8/25/98)
-                       if(Network.get_local_echo() || newline_mode) // &&
-                               Console.WriteCtrlChar('\x0d');
-                       Console.WriteCtrlChar('\x0a');
-                       pszBuffer++;
-                       break;
-               
-               // form feed
-               case 12:
-                       pszBuffer++;
-                       Console.ClearScreen();
-                       Console.SetRawCursorPosition(Console.GetCursorX(), 1); // changed fm 1
-                       break;
-               
-               case 13:
-                       Console.WriteCtrlChar('\x0d');
-                       pszBuffer++;
-
-                       break;
-
-               case 14:  // shift out of alternate chararcter set
-                       pszBuffer++;
-                       Charmap.setmap(map_G1); // Paul Brannan 6/25/98
-                       current_map = 1;
-                       break;
-       
-               case 15:  // shift in
-                       pszBuffer++;
-                       Charmap.setmap(map_G0); // Paul Brannan 6/25/98
-                       current_map = 0;
-                       break;
-               
-               // Paul Brannan 9/1/98 - Is this okay?
-               default:
-                       pszBuffer++;
-               }
-
-               return pszBuffer;
-       }
-
-       //  added by I.Ioannou 06 April, 1997
-       //  In 8 bit systems the server may send 0x9b instead of ESC[
-       //  Well, this will produce troubles in Greek 737 Code page
-       //  which uses 0x9b as the small "delta" - and I thing that there
-       //  is another European country with the same problem.
-       //  If we have to stay 8-bit clean we may have to
-       //  give the ability of ROM characters (ESC[11m),
-       //  for striped 8'th bit (ESC[12m) as SCO does,
-       //  or a parameter at compile (or run ?) time.
-       // We now check for a flag in the ini file (Paul Brannan 5/13/98)
-       // We also handle any 8-bit ESC sequence (Paul Brannan 6/28/98)
-       if(ini.get_eightbit_ansi() && (tmpc > 128 && tmpc < 128 + ' ')) {
-               // There's a chance the sequence might not parse.  If this happens
-               // then pszBuffer will be one character too far back, since
-               // ParseEscape is expecting two characters, not one.
-               // In that case we must handle it.
-               char *pszCurrent = pszBuffer;
-               pszBuffer = ParseEscape(pszBuffer, pszBufferEnd);
-               if(pszBuffer < pszCurrent) pszBuffer = pszCurrent;
-       }
-
-       char* pszCurrent = pszBuffer + 1;
-       // I.Ioannou 04 Sep 1997 FIXME with ESC[11m must show chars < 32
-       // Fixed (Paul Brannan 6/28/98)
-       while ((pszCurrent < pszBufferEnd) && (!iscntrl(*pszCurrent))) {
-               // I.Ioannou 04 Sep 1997 strip on high bit
-               if ( (inGraphMode) && (*pszCurrent > (char)32) )
-                       *pszCurrent |= 0x80 ;
-               pszCurrent++;
-       }
-       
-       // Note that this may break dumpfiles slightly.
-       // If 'B' is set to anything other than ASCII, this will cause problems
-       // (Paul Brannan 6/28/98)
-       if(current_map != 'B' && Charmap.enabled)
-               Charmap.translate_buffer(pszBuffer, pszCurrent);    
-       
-       last_char = *(pszCurrent-1);    // TITUS++: Remember last char
-
-       if(fast_write) {
-               pszBuffer += Console.WriteStringFast(pszBuffer,
-                       pszCurrent - pszBuffer);
-       } else {
-               pszBuffer += Console.WriteString(pszBuffer,
-                       pszCurrent - pszBuffer);
-       }
-
-       return pszBuffer;
-}
-
-// Added by I.Ioannou 06 April, 1997
-// Print the buffer until you reach ESC[4i
-char* TANSIParser::PrintBuffer(char* pszBuffer, char* pszBufferEnd) {
-       // Check if we have enough characters in buffer.
-       if ((pszBufferEnd - pszBuffer) < 4)
-               return pszBuffer;
-       char *tmpChar;
-       
-       tmpChar = pszBuffer;
-       if ( *tmpChar == 27 ) {
-               tmpChar++;
-               if ( *tmpChar == '[' ) {
-                       tmpChar++;
-                       if ( *tmpChar == '4' ) {
-                               tmpChar++;
-                               if ( *tmpChar == 'i' ) {
-                                       InPrintMode = 0; // Stop Print Log
-                                       if ( printfile != NULL )
-                                               fclose(printfile);
-                                       pszBuffer += 4;
-                                       return pszBuffer;
-                               }
-                       }
-               }
-       }
-       
-       if (printfile != NULL) {
-               fputc( *pszBuffer, printfile);
-               pszBuffer++;
-       } else
-               InPrintMode = 0;
-       
-       return pszBuffer;
-}
-
-/* - PrintGoodChars( pszHead, pszTail ) - - - - - - - - - - - - - - - - - - -
--*
-
-  Mark Miesfield 09/24/2000
-
-  Prints the characters in a buffer, from the specified head to the specified
-  tail, to standard out, skipping any control characters or ANSI escape
-  sequences.
-
-  Parameters on entry:
-    pszHead  ->  Starting point in buffer.
-
-    pszTail  ->  Ending point in buffer.
-
-  Returns:
-    Pointer to the first character in the buffer that was not output to
-    standard out.  (Since no error checking is done, this is in effect
-    pszTail.)
-
-  Side Effects:
-    None.
-* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-*/
-char * TANSIParser::PrintGoodChars( char * pszHead, char * pszTail )  {
-
-  while ( pszHead < pszTail )  {
-    if ( iscntrl( *pszHead ) )  {
-      switch ( *(pszHead++) )  {
-        case 10 :
-          putc( 10, stdout );
-          break;
-
-        case 13 :
-          putc( 13, stdout );
-          break;
-
-        case 27:
-          switch ( *(pszHead++) )  {
-            case 'Y':
-              pszHead += 2;
-              break;
-
-            case '#':
-            case '(':
-            case ')':
-            case '%': pszHead++; break;
-            case '[':
-              while ( (pszHead < pszTail) && (*pszHead < '?') )
-                pszHead++;
-              pszHead++;
-              break;
-
-            default :
-              break;
-          }
-          break;
-
-        default :
-          break;
-      }
-    }
-    else
-      putc( *(pszHead++), stdout );
-  }
-  return ( pszTail );
-}
-// End of function:  PrintGoodChars( pszHead, pszTail )
diff --git a/reactos/apps/utils/net/telnet/src/ansiprsr.h b/reactos/apps/utils/net/telnet/src/ansiprsr.h
deleted file mode 100644 (file)
index a8396d2..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-#ifndef __ANSIPRSR_H
-#define __ANSIPRSR_H
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <ctype.h>
-#include <string.h>
-#include "tnconfig.h"
-#include "tparser.h"
-
-// added this color table to make things go faster (Paul Branann 5/8/98)
-enum Colors {BLACK=0, BLUE, GREEN, CYAN, RED, MAGENTA, YELLOW, WHITE};
-extern const int ANSIColors[];
-
-// This should be greater than the largest conceivable window size
-// 200 should suffice
-#define MAX_TAB_POSITIONS 200
-
-// Added by Frediano Ziglio 6/2/2000
-// Include Meridian Emulator support
-// undefine it to remove support
-#define MTE_SUPPORT 1
-
-// TANSIParser is now properly no longer a base class for TTelnetParser.
-// Screen output is handled in TConsole.cpp.
-// (Paul Brannan 6/15/98)
-class TANSIParser : public TParser {
-private:
-       char* ParseEscapeANSI(char* pszBuffer, char* pszBufferEnd);
-       char* ParseANSIBuffer(char* pszBuffer, char* pszBufferEnd);
-       char* ParseEscape(char* pszBuffer, char* pszBufferEnd);
-       // Added by I.Ioannou 06/04/97
-       char* PrintBuffer(char* pszBuffer, char* pszBufferEnd);
-       char* PrintGoodChars(char * pszHead, char * pszTail);
-
-#ifdef MTE_SUPPORT
-    // Added by Frediano Ziglio, 5/31/2000
-    char* ParseEscapeMTE(char* pszBuffer, char* pszBufferEnd);
-       short int mteRegionXF,mteRegionYF;
-#endif
-
-       void ConSetAttribute(unsigned char wAttr);
-       const char *GetTerminalID();
-       void ConSetCursorPos(int x, int y);
-       void ResetTerminal();
-       void Init();
-
-       void SaveCurX(int iX);
-       void SaveCurY(int iY);
-
-       void resetTabStops();
-
-       int iSavedCurX;
-       int iSavedCurY;
-       unsigned char iSavedAttributes;
-       FILE * dumpfile;
-
-       // Added by I.Ioannou 06 April 1997
-       FILE * printfile;
-       char InPrintMode;
-       int inGraphMode;
-
-       char last_char;                 // TITUS++: 2. November 98
-
-       char map_G0, map_G1;
-       int current_map;
-       bool vt52_mode;
-       bool print_ctrl;
-       bool ignore_margins;
-       bool fast_write;
-       bool newline_mode;
-
-       int tab_stops[MAX_TAB_POSITIONS];
-
-public:
-       // Changed by Paul Brannan 5/13/98
-       TANSIParser(TConsole &Console, KeyTranslator &RefKeyTrans,
-               TScroller &RefScroller, TNetwork &NetHandler, TCharmap &RefCharmap);
-       ~TANSIParser();
-
-       char* ParseBuffer(char* pszBuffer, char* pszBufferEnd);
-       static int StripBuffer(char* pszBuffer, char* pszBufferEnd, int width);
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/keytrans.cpp b/reactos/apps/utils/net/telnet/src/keytrans.cpp
deleted file mode 100644 (file)
index 518b962..0000000
+++ /dev/null
@@ -1,227 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-///////////////////////////////////////////////////////////////////
-//      Key translations - I.Ioannou (roryt@hol.gr)              //
-//          Athens - Greece    December 18, 1996 02:56am         //
-//          Reads a .cfg file and keeps the definitions          //
-//      modified for alternate keymap swiching                   //
-//          by Andrey V. Smilianets (smile@head.aval.kiev.ua)    //
-//          Kiev - Ukraine, December 1997.                       //
-//      modified to work with MSVC and the Standard Template     //
-//          library by Paul Brannan <pbranna@clemson.edu>,       //
-//          May 25, 1998                                         //
-//      updated June 7, 1998 by Paul Brannan to remove cout and  //
-//          cerr statements                                      //
-//      APP_KEY and APP2_Key added July 12, 1998 by Paul Brannan //
-///////////////////////////////////////////////////////////////////
-//                class KeyTranslator                            //
-//  Load          : loads or replaces the keymap                 //
-//  TranslateKey  : returns a char * to the key def              //
-//  AddKeyDef     : Changes or adds the key translation          //
-//  DeleteKeyDef  : Deletes a key def from the list              //
-///////////////////////////////////////////////////////////////////
-
-#include <windows.h>
-
-// changed to make work with VC++ (Paul Brannan 5/25/98)
-// FIX ME !!! Ioannou:  This must be __BORLANDC__ && VERSION < 5
-// but what is the directive for Borland version ????
-// FIXED Sept. 31, 2000 (Bernard Badger)
-//
-#if defined(__BORLANDC__) && (__BORLANDC < 0x0500)
-#include <mem.h>
-#else
-#include <memory.h>
-#endif
-
-#include "keytrans.h"
-#include "tnerror.h"
-
-/////////////////////////////////////////////////////////////
-//                class KeyTranslator                      //
-//  Load          : loads or replaces the keymap           //
-//  TranslateKey  : returns a sz to the key def            //
-//  AddKeyDef     : Changes or adds the key translation    //
-//  DeleteKeyDef  : Deletes a key def from the list        //
-/////////////////////////////////////////////////////////////
-
-
-KeyTranslator::KeyTranslator():
-mapArray(0,0,sizeof(KeyMap)),
-globals(0,0,sizeof(TKeyDef)) {
-       ext_mode = 0;                   // Paul Brannan 8/28/98
-       currentKeyMap = mainKeyMap = -1;
-};
-
-//AVS
-// perform keymap switching
-int KeyTranslator::switchMap(TKeyDef& tk) {
-    if ( mapArray.IsEmpty() ) {
-               return currentKeyMap = -1;
-    };
-    int i = mapArray.Find(KeyMap(tk));
-    if ( i != INT_MAX ) {
-               if (currentKeyMap == i)
-            currentKeyMap = mainKeyMap; // restore to default
-               else currentKeyMap = i;
-               return 1;
-    };
-    return 0;
-};
-
-// Let the calling function interpret the error code (Paul Brannan 12/17/98)
-int KeyTranslator::SwitchTo(int to) {
-       
-    int max = mapArray.GetItemsInContainer();
-    if (max == 0) return -1;
-    if (to < 0 || to > (max-1)) return 0;
-       
-    currentKeyMap = to;
-    return 1;
-};
-
-//AVS
-// rewrited to support multiple keymaps
-const char *KeyTranslator::TranslateKey(WORD wVirtualKeyCode,
-                                                                                         DWORD dwControlKeyState)
-{
-       if ( mapArray.IsEmpty() ) return NULL;
-       
-       TKeyDef ask(NULL, dwControlKeyState, wVirtualKeyCode);
-       
-       // if a keymap switch pressed
-       if ( switchMap(ask) > 0 ) return "";
-       
-       int i = mapArray[currentKeyMap].map.Find(ask);
-       
-       if ( i != INT_MAX) return mapArray[currentKeyMap].map[i].GetszKey();
-       
-       // if not found in current keymap
-       if ( currentKeyMap != mainKeyMap ) {
-               i = mapArray[mainKeyMap].map.Find(ask);
-               if ( i != INT_MAX)  return mapArray[mainKeyMap].map[i].GetszKey();
-       };
-       return NULL;
-};
-
-
-//AVS
-// rewrited to support multiple keymaps
-int KeyTranslator::AddKeyDef(WORD wVirtualKeyCode, DWORD dwControlKeyState,
-                             char*lpzKeyDef)
-{
-       if ( ! mapArray[currentKeyMap].map.IsEmpty() ) {
-               int i = mapArray[currentKeyMap].map.Find(TKeyDef(NULL, dwControlKeyState, wVirtualKeyCode));
-               if ( i != INT_MAX) {
-                       mapArray[currentKeyMap].map[i] = lpzKeyDef;
-                       return 1;
-               }
-       };
-       return mapArray[currentKeyMap].map.Add( TKeyDef(lpzKeyDef, dwControlKeyState, wVirtualKeyCode));
-}
-
-// Paul Brannan Feb. 22, 1999
-int KeyTranslator::AddKeyDef(WORD wVirtualKeyCode, DWORD dwControlKeyState,
-                             tn_ops the_op)
-{
-       optype op;
-       op.sendstr = 0;
-       op.the_op = the_op;
-       if ( ! mapArray[currentKeyMap].map.IsEmpty() ) {
-               int i = mapArray[currentKeyMap].map.Find(TKeyDef(NULL, dwControlKeyState, wVirtualKeyCode));
-               if ( i != INT_MAX) {
-                       mapArray[currentKeyMap].map[i] = op;
-                       return 1;
-               }
-       };
-       return mapArray[currentKeyMap].map.Add( TKeyDef(op, dwControlKeyState, wVirtualKeyCode));
-}
-
-// AVS
-int KeyTranslator::LookOnGlobal(char* vkey) {
-    if ( ! globals.IsEmpty() ) {
-               int max = globals.GetItemsInContainer();
-               for ( int i = 0; i < max ; i++ )
-                       if ( stricmp(globals[i].GetszKey(), vkey) == 0 )
-                               return i;
-    };
-    return INT_MAX;
-};
-
-int KeyTranslator::AddGlobalDef(WORD wVirtualKeyCode, char*lpzKeyDef) {
-       if ( ! globals.IsEmpty() ) {
-               int max = globals.GetItemsInContainer();
-               for ( int i = 0; i < max ; i++ ) {
-                       const char *s = globals[i].GetszKey();
-                       if ( stricmp(s, lpzKeyDef) == 0 ) {
-                               globals[i] = DWORD(wVirtualKeyCode);
-                               return 1;
-                       }
-               }
-       }
-       return globals.Add( TKeyDef(lpzKeyDef, 0, wVirtualKeyCode));
-}
-
-
-//AVS
-// rewrited to support multiple keymaps
-int KeyTranslator::DeleteKeyDef(WORD wVirtualKeyCode, DWORD dwControlKeyState)
-{
-       if ( mapArray.IsEmpty() || mapArray[currentKeyMap].map.IsEmpty() )
-               return 0;
-       
-       int i = mapArray[currentKeyMap].map.Find(TKeyDef(NULL, dwControlKeyState, wVirtualKeyCode));
-       
-       if ( i != INT_MAX) {
-               mapArray[currentKeyMap].map.Destroy(i);
-               return 1;
-       };
-       return 0;
-};
-
-//AVS
-// rewritten to support multiple keymaps
-void KeyTranslator::DeleteAllDefs(void)
-{
-       // This code wants to crash under the STL; Apparently the Destroy()
-       // function actually deletes the entry, rather than simply releasing
-       // memory.  I think flush() should do the same thing, at least the
-       // way it is written with STL_BIDS (Paul Brannan 5/25/98).
-       int max;
-       
-       max = mapArray.GetItemsInContainer();
-       if ( ! mapArray.IsEmpty() ) {
-               for ( int i = 0; i < max; i++ ) {
-                       if ( !mapArray[i].map.IsEmpty() ) {
-                               mapArray[i].map.Flush();
-                       };
-               };
-       };
-       globals.Flush();
-       mapArray.Flush();
-       currentKeyMap = -1;
-       mainKeyMap    = -1;
-};
diff --git a/reactos/apps/utils/net/telnet/src/keytrans.h b/reactos/apps/utils/net/telnet/src/keytrans.h
deleted file mode 100644 (file)
index 21bb85a..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-///////////////////////////////////////////////////////////////////
-//                                                               //
-//                                                               //
-//      Key translations - I.Ioannou (roryt@hol.gr)              //
-//          Athens - Greece    December 18, 1996 02:56am         //
-//          Reads a .cfg file and keeps the key definitions      //
-//                for the WIN32 console telnet                   //
-//      modified for alternate keymap swiching                   //
-//          by Andrey V. Smilianets (smile@head.aval.kiev.ua)    //
-//          Kiev - Ukraine, December 1997.                       //
-///////////////////////////////////////////////////////////////////
-//                                                               //
-//                class KeyTranslator                            //
-//                                                               //
-//  Load          : loads or replaces the keymap                 //
-//  TranslateKey  : returns a char * to the key def              //
-//  AddKeyDef     : Changes or adds the key translation          //
-//  DeleteKeyDef  : Deletes a key def from the list              //
-///////////////////////////////////////////////////////////////////
-
-#ifndef __KEYTRANS_H
-#define __KEYTRANS_H
-
-#include "tkeydef.h"
-#include "tkeymap.h"
-
-#define TOKEN_DELIMITERS " +\t" // The word's delimiters
-
-// Ioannou 2 June 98:  Borland needs them - quick hack
-#ifdef __BORLANDC__
-#define bool BOOL
-#define true TRUE
-#define false FALSE
-#endif //  __BORLANDC__
-
-// Maybe not portable, but this is for application cursor mode
-// (Paul Brannan 5/27/98)
-// Updated for correct precedence in tncon.cpp (Paul Brannan 12/9/98)
-#define APP4_KEY                       0x8000
-#define APP3_KEY                       0x4000
-#define APP2_KEY                       0x2000
-#define APP_KEY                                0x1000
-
-/////////////////////////////////////////////////////////////
-//                class KeyTranslator                      //
-//  Load          : loads or replaces the keymap           //
-//  TranslateKey  : returns a sz to the key def            //
-//  AddKeyDef     : Changes or adds the key translation    //
-//  DeleteKeyDef  : Deletes a key def from the list        //
-/////////////////////////////////////////////////////////////
-
-class KeyTranslator {
-friend class TMapLoader;                       // FIX ME!!  This isn't the best solution
-public:
-    KeyTranslator();
-    ~KeyTranslator() { DeleteAllDefs(); }
-
-    int  SwitchTo(int);                                // switch to selected keymap
-       int switchMap(TKeyDef& tk);
-
-    // Returns a pointer to the string that should be printed.
-    // Should return NULL if there is no translation for the key.
-    const char *TranslateKey(WORD wVirtualKeyCode, DWORD dwControlKeyState);
-
-    // Changes or adds the key translation associated with
-    // wVirtualScanCode and dwControlKeyState.
-    // Return 1 on success.
-    int AddKeyDef(WORD wVirtualKeyCode, DWORD dwControlKeyState, char *lpzKeyDef);
-       int AddKeyDef(WORD wVirtualKeyCode, DWORD dwControlKeyState, tn_ops op);
-
-    // Delete a key translation
-       int DeleteKeyDef(WORD wVirtualKeyCode, DWORD dwControlKeyState);
-
-       // Paul Brannan 8/28/98
-       void set_ext_mode(DWORD mode) {ext_mode |= mode;}
-       void unset_ext_mode(DWORD mode) {ext_mode &= ~mode;}
-       void clear_ext_mode() {ext_mode = 0;}
-       DWORD get_ext_mode() {return ext_mode;}
-
-private:
-       DWORD     Fix_ControlKeyState(char *);
-       char*     Fix_Tok(char *);
-       DWORD ext_mode;                                                         // Paul Brannan 8/28/98
-
-       TArrayAsVector<KeyMap> mapArray;
-       TArrayAsVector<TKeyDef> globals;
-
-       void      DeleteAllDefs(void);
-       int       AddGlobalDef(WORD wVirtualKeyCode, char*lpzKeyDef);
-       int               LookOnGlobal(char* vkey);
-       DWORD     GetGlobalCode(int i) {return globals[i].GetCodeKey();}
-
-       int currentKeyMap, mainKeyMap;                          // AVS
-
-};
-
-#endif // __KEYTRANS_H
diff --git a/reactos/apps/utils/net/telnet/src/stl_bids.h b/reactos/apps/utils/net/telnet/src/stl_bids.h
deleted file mode 100644 (file)
index 7366fc1..0000000
+++ /dev/null
@@ -1,159 +0,0 @@
-// This is the STL wrapper for classlib/arrays.h from Borland's web site
-// It has been modified to be compatible with vc++ (Paul Branann 5/7/98)
-
-#ifndef STL_ARRAY_AS_VECTOR
-#define STL_ARRAY_AS_VECTOR
-
-#ifdef _MSC_VER
-#pragma warning(disable: 4786)
-#endif
-
-// #include <vector.h>
-// #include <algo.h>
-#include <vector>
-#include <algorithm>
-using namespace std;
-
-template <class T>
-class TArrayAsVector : public vector<T> {
-private:
-       const unsigned int growable;
-       typedef size_t size_type;
-       typedef typename vector<T>::const_iterator const_iterator;
-       const size_type lowerbound;
-public:
-       TArrayAsVector(size_type upper,
-               size_type lower = 0,
-               int delta = 0) :
-       vector<T>( ),
-               growable(delta),
-               lowerbound(lower)
-       { vector<T>::reserve(upper-lower + 1);}
-
-       ~TArrayAsVector( )
-       { // This call is unnecessary?  (Paul Brannan 5/7/98)
-               // vector<T>::~vector( );
-       }
-
-       int Add(const T& item)
-       { if(!growable && vector<T>::size( ) == vector<T>::capacity( ))
-       return 0;
-       else
-               insert(vector<T>::end( ), item);
-       return 1; }
-
-       int AddAt(const T& item, size_type index)
-       { if(!growable &&
-       ((vector<T>::size( ) == vector<T>::capacity( )) ||
-       (ZeroBase(index > vector<T>::capacity( )) )))
-       return 0;
-       if(ZeroBase(index) > vector<T>::capacity( )) // out of bounds
-       { insert(vector<T>::end( ),
-       ZeroBase(index) - vector<T>::size( ), T( ));
-       insert(vector<T>::end( ), item); }
-       else
-       { insert(vector<T>::begin( ) + ZeroBase(index), item); }
-       return 1;
-       }
-
-       size_type ArraySize( )
-       { return vector<T>::capacity( ); }
-
-       size_type BoundBase(size_type location) const
-       { if(location == UINT_MAX)
-       return INT_MAX;
-       else
-               return location + lowerbound; }
-       void Detach(size_type index)
-       { erase(vector<T>::begin( ) + ZeroBase(index)); }
-
-       void Detach(const T& item)
-       { Destroy(Find(item)); }
-
-       void Destroy(size_type index)
-       { erase(vector<T>::begin( ) + ZeroBase(index)); }
-
-       void Destroy(const T& item)
-       { Destroy(Find(item)); }
-
-       size_type Find(const T& item) const
-       { const_iterator location = find(vector<T>::begin( ),
-       vector<T>::end( ), item);
-       if(location != vector<T>::end( ))
-               return BoundBase(size_type(location -
-               vector<T>::begin( )));
-       else
-               return INT_MAX; }
-
-       size_type GetItemsInContainer( )
-       { return vector<T>::size( ); }
-
-       void Grow(size_type index)
-       { if( index < lowerbound )
-       Reallocate(ArraySize( ) + (index -
-       lowerbound));
-       else if( index >= BoundBase(vector<T>::size( )))
-               Reallocate(ZeroBase(index) ); }
-
-       int HasMember(const T& item)
-       { if(Find(item) != INT_MAX)
-       return 1;
-       else
-               return 0; }
-
-       int IsEmpty( )
-       { return vector<T>::empty( ); }
-
-       int IsFull( )
-       { if(growable)
-       return 0;
-       if(vector<T>::size( ) == vector<T>::capacity( ))
-               return 1;
-       else
-               return 0; }
-
-       size_type LowerBound( )
-       { return lowerbound; }
-
-       T& operator[] (size_type index)
-       { return vector<T>::
-       operator[](ZeroBase(index)); }
-
-       const T& operator[] (size_type index) const
-       { return vector<T>::
-       operator[](ZeroBase(index)); }
-
-       void Flush( )
-       {
-               vector<T>::clear();
-       }
-
-       void Reallocate(size_type sz,
-               size_type offset = 0)
-       { if(offset)
-       insert(vector<T>::begin( ), offset, T( ));
-       vector<T>::reserve(sz);
-       erase(vector<T>::end( ) - offset, vector<T>::end( )); }
-
-       void RemoveEntry(size_type index)
-       { Detach(index); }
-
-       void SetData(size_type index, const T& item)
-       { (*this)[index] = item; }
-
-       size_type UpperBound( )
-       { return BoundBase(vector<T>::capacity( )) - 1; }
-
-       size_type ZeroBase(size_type index) const
-       { return index - lowerbound; }
-
-       // The assignment operator is not inherited (Paul Brannan 5/25/98)
-       TArrayAsVector& operator=(const TArrayAsVector& v) {
-               vector<T>::operator=(v);
-               // should growable and lowerbound be copied as well?
-               return *this;
-       }
-
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tcharmap.cpp b/reactos/apps/utils/net/telnet/src/tcharmap.cpp
deleted file mode 100644 (file)
index bafe62e..0000000
+++ /dev/null
@@ -1,220 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-// TCharmap.cpp
-// A simple class for handling character maps
-// Written by Paul Brannan <pbranna@clemson.edu>
-// Last modified 7/12/98
-
-#include <string.h>
-#include "tcharmap.h"
-#include "tnconfig.h"
-
-// map B (US ASCII)
-// this maps each character to itself
-static char mapB[256] = {
-       (char)0x00,(char)0x01,(char)0x02,(char)0x03,(char)0x04,(char)0x05,(char)0x06,(char)0x07, // 0x00 - 0x0f
-       (char)0x08,(char)0x09,(char)0x0a,(char)0x0b,(char)0x0c,(char)0x0d,(char)0x0e,(char)0x0f,
-       (char)0x10,(char)0x11,(char)0x12,(char)0x13,(char)0x14,(char)0x15,(char)0x16,(char)0x17, // 0x10 - 0x1f
-       (char)0x18,(char)0x19,(char)0x1a,(char)0x1b,(char)0x1c,(char)0x1d,(char)0x1e,(char)0x1f,
-       (char)0x20,(char)0x21,(char)0x22,(char)0x23,(char)0x24,(char)0x25,(char)0x26,(char)0x27, // 0x20 - 0x2f
-       (char)0x28,(char)0x29,(char)0x2a,(char)0x2b,(char)0x2c,(char)0x2d,(char)0x2e,(char)0x2f,
-       (char)0x30,(char)0x31,(char)0x32,(char)0x33,(char)0x34,(char)0x35,(char)0x36,(char)0x37, // 0x30 - 0x3f
-       (char)0x38,(char)0x39,(char)0x3a,(char)0x3b,(char)0x3c,(char)0x3d,(char)0x3e,(char)0x3f,
-       (char)0x40,(char)0x41,(char)0x42,(char)0x43,(char)0x44,(char)0x45,(char)0x46,(char)0x47, // 0x40 - 0x4f
-       (char)0x48,(char)0x49,(char)0x4a,(char)0x4b,(char)0x4c,(char)0x4d,(char)0x4e,(char)0x4f,
-       (char)0x50,(char)0x51,(char)0x52,(char)0x53,(char)0x54,(char)0x55,(char)0x56,(char)0x57, // 0x50 - 0x5f
-       (char)0x58,(char)0x59,(char)0x5a,(char)0x5b,(char)0x5c,(char)0x5d,(char)0x5e,(char)0x5f,
-       (char)0x60,(char)0x61,(char)0x62,(char)0x63,(char)0x64,(char)0x65,(char)0x66,(char)0x67, // 0x60 - 0x6f
-       (char)0x68,(char)0x69,(char)0x6a,(char)0x6b,(char)0x6c,(char)0x6d,(char)0x6e,(char)0x6f,
-       (char)0x70,(char)0x71,(char)0x72,(char)0x73,(char)0x74,(char)0x75,(char)0x76,(char)0x77, // 0x70 - 0x7f
-       (char)0x78,(char)0x79,(char)0x7a,(char)0x7b,(char)0x7c,(char)0x7d,(char)0x7e,(char)0x7f,
-       (char)0x80,(char)0x81,(char)0x82,(char)0x83,(char)0x84,(char)0x85,(char)0x86,(char)0x87, // 0x80 - 0x8f
-       (char)0x88,(char)0x89,(char)0x8a,(char)0x8b,(char)0x8c,(char)0x8d,(char)0x8e,(char)0x8f,
-       (char)0x90,(char)0x91,(char)0x92,(char)0x93,(char)0x94,(char)0x95,(char)0x96,(char)0x97, // 0x90 - 0x9f
-       (char)0x98,(char)0x99,(char)0x9a,(char)0x9b,(char)0x9c,(char)0x9d,(char)0x9e,(char)0x9f,
-       (char)0xa0,(char)0xa1,(char)0xa2,(char)0xa3,(char)0xa4,(char)0xa5,(char)0xa6,(char)0xa7, // 0xa0 - 0xaf
-       (char)0xa8,(char)0xa9,(char)0xaa,(char)0xab,(char)0xac,(char)0xad,(char)0xae,(char)0xaf,
-       (char)0xb0,(char)0xb1,(char)0xb2,(char)0xb3,(char)0xb4,(char)0xb5,(char)0xb6,(char)0xb7, // 0xb0 - 0xbf
-       (char)0xb8,(char)0xb9,(char)0xba,(char)0xbb,(char)0xbc,(char)0xbd,(char)0xbe,(char)0xbf,
-       (char)0xc0,(char)0xc1,(char)0xc2,(char)0xc3,(char)0xc4,(char)0xc5,(char)0xc6,(char)0xc7, // 0xc0 - 0xcf
-       (char)0xc8,(char)0xc9,(char)0xca,(char)0xcb,(char)0xcc,(char)0xcd,(char)0xce,(char)0xcf,
-       (char)0xd0,(char)0xd1,(char)0xd2,(char)0xd3,(char)0xd4,(char)0xd5,(char)0xd6,(char)0xd7, // 0xd0 - 0xdf
-       (char)0xd8,(char)0xd9,(char)0xda,(char)0xdb,(char)0xdc,(char)0xdd,(char)0xde,(char)0xdf,
-       (char)0xe0,(char)0xe1,(char)0xe2,(char)0xe3,(char)0xe4,(char)0xe5,(char)0xe6,(char)0xe7, // 0xe0 - 0xef
-       (char)0xe8,(char)0xe9,(char)0xea,(char)0xeb,(char)0xec,(char)0xed,(char)0xee,(char)0xef,
-       (char)0xf0,(char)0xf1,(char)0xf2,(char)0xf3,(char)0xf4,(char)0xf5,(char)0xf6,(char)0xf7, // 0xf0 - 0xff
-       (char)0xf8,(char)0xf9,(char)0xfa,(char)0xfb,(char)0xfc,(char)0xfd,(char)0xfe,(char)0xff
-};
-
-// map A (UK/National)
-static char mapA[256] = {
-       (char)0x00,(char)0x01,(char)0x02,(char)0x03,(char)0x04,(char)0x05,(char)0x06,(char)0x07, // 0x00 - 0x0f
-       (char)0x08,(char)0x09,(char)0x0a,(char)0x0b,(char)0x0c,(char)0x0d,(char)0x0e,(char)0x0f,
-       (char)0x10,(char)0x11,(char)0x12,(char)0x13,(char)0x14,(char)0x15,(char)0x16,(char)0x17, // 0x10 - 0x1f
-       (char)0x18,(char)0x19,(char)0x1a,(char)0x1b,(char)0x1c,(char)0x1d,(char)0x1e,(char)0x1f,
-       (char)0x20,(char)0x21,(char)0x22,(char)0x9c,(char)0x24,(char)0x25,(char)0x26,(char)0x27, // 0x20 - 0x2f
-       (char)0x28,(char)0x29,(char)0x2a,(char)0x2b,(char)0x2c,(char)0x2d,(char)0x2e,(char)0x2f,
-       (char)0x30,(char)0x31,(char)0x32,(char)0x33,(char)0x34,(char)0x35,(char)0x36,(char)0x37, // 0x30 - 0x3f
-       (char)0x38,(char)0x39,(char)0x3a,(char)0x3b,(char)0x3c,(char)0x3d,(char)0x3e,(char)0x3f,
-       (char)0x40,(char)0x41,(char)0x42,(char)0x43,(char)0x44,(char)0x45,(char)0x46,(char)0x47, // 0x40 - 0x4f
-       (char)0x48,(char)0x49,(char)0x4a,(char)0x4b,(char)0x4c,(char)0x4d,(char)0x4e,(char)0x4f,
-       (char)0x50,(char)0x51,(char)0x52,(char)0x53,(char)0x54,(char)0x55,(char)0x56,(char)0x57, // 0x50 - 0x5f
-       (char)0x58,(char)0x59,(char)0x5a,(char)0x5b,(char)0x5c,(char)0x5d,(char)0x5e,(char)0x5f,
-       (char)0x60,(char)0x61,(char)0x62,(char)0x63,(char)0x64,(char)0x65,(char)0x66,(char)0x67, // 0x60 - 0x6f
-       (char)0x68,(char)0x69,(char)0x6a,(char)0x6b,(char)0x6c,(char)0x6d,(char)0x6e,(char)0x6f,
-       (char)0x70,(char)0x71,(char)0x72,(char)0x73,(char)0x74,(char)0x75,(char)0x76,(char)0x77, // 0x70 - 0x7f
-       (char)0x78,(char)0x79,(char)0x7a,(char)0x7b,(char)0x7c,(char)0x7d,(char)0x7e,(char)0x7f,
-       (char)0x80,(char)0x81,(char)0x82,(char)0x83,(char)0x84,(char)0x85,(char)0x86,(char)0x87, // 0x80 - 0x8f
-       (char)0x88,(char)0x89,(char)0x8a,(char)0x8b,(char)0x8c,(char)0x8d,(char)0x8e,(char)0x8f,
-       (char)0x90,(char)0x91,(char)0x92,(char)0x93,(char)0x94,(char)0x95,(char)0x96,(char)0x97, // 0x90 - 0x9f
-       (char)0x98,(char)0x99,(char)0x9a,(char)0x9b,(char)0x9c,(char)0x9d,(char)0x9e,(char)0x9f,
-       (char)0xa0,(char)0xa1,(char)0xa2,(char)0xa3,(char)0xa4,(char)0xa5,(char)0xa6,(char)0xa7, // 0xa0 - 0xaf
-       (char)0xa8,(char)0xa9,(char)0xaa,(char)0xab,(char)0xac,(char)0xad,(char)0xae,(char)0xaf,
-       (char)0xb0,(char)0xb1,(char)0xb2,(char)0xb3,(char)0xb4,(char)0xb5,(char)0xb6,(char)0xb7, // 0xb0 - 0xbf
-       (char)0xb8,(char)0xb9,(char)0xba,(char)0xbb,(char)0xbc,(char)0xbd,(char)0xbe,(char)0xbf,
-       (char)0xc0,(char)0xc1,(char)0xc2,(char)0xc3,(char)0xc4,(char)0xc5,(char)0xc6,(char)0xc7, // 0xc0 - 0xcf
-       (char)0xc8,(char)0xc9,(char)0xca,(char)0xcb,(char)0xcc,(char)0xcd,(char)0xce,(char)0xcf,
-       (char)0xd0,(char)0xd1,(char)0xd2,(char)0xd3,(char)0xd4,(char)0xd5,(char)0xd6,(char)0xd7, // 0xd0 - 0xdf
-       (char)0xd8,(char)0xd9,(char)0xda,(char)0xdb,(char)0xdc,(char)0xdd,(char)0xde,(char)0xdf,
-       (char)0xe0,(char)0xe1,(char)0xe2,(char)0xe3,(char)0xe4,(char)0xe5,(char)0xe6,(char)0xe7, // 0xe0 - 0xef
-       (char)0xe8,(char)0xe9,(char)0xea,(char)0xeb,(char)0xec,(char)0xed,(char)0xee,(char)0xef,
-       (char)0xf0,(char)0xf1,(char)0xf2,(char)0xf3,(char)0xf4,(char)0xf5,(char)0xf6,(char)0xf7, // 0xf0 - 0xff
-       (char)0xf8,(char)0xf9,(char)0xfa,(char)0xfb,(char)0xfc,(char)0xfd,(char)0xfe,(char)0xff
-};
-
-// map 0
-// Special graphics and line drawing
-static char map0[256] = {
-       (char)0x00,(char)0x01,(char)0x02,(char)0x03,(char)0x04,(char)0x05,(char)0x06,(char)0x07, // 0x00 - 0x0f
-       (char)0x08,(char)0x09,(char)0x0a,(char)0x0b,(char)0x0c,(char)0x0d,(char)0x0e,(char)0x0f,
-       (char)0x10,(char)0x11,(char)0x12,(char)0x13,(char)0x14,(char)0x15,(char)0x16,(char)0x17, // 0x10 - 0x1f
-       (char)0x18,(char)0x19,(char)0x1a,(char)0x1b,(char)0x1c,(char)0x1d,(char)0x1e,(char)0x1f,
-       (char)0x20,(char)0x21,(char)0x22,(char)0x23,(char)0x24,(char)0x25,(char)0x26,(char)0x27, // 0x20 - 0x2f
-       (char)0x28,(char)0x29,(char)0x2a,(char)0x2b,(char)0x2c,(char)0x2d,(char)0x2e,(char)0x2f,
-       (char)0x30,(char)0x31,(char)0x32,(char)0x33,(char)0x34,(char)0x35,(char)0x36,(char)0x37, // 0x30 - 0x3f
-       (char)0x38,(char)0x39,(char)0x3a,(char)0x3b,(char)0x3c,(char)0x3d,(char)0x3e,(char)0x3f,
-       (char)0x40,(char)0x41,(char)0x42,(char)0x43,(char)0x44,(char)0x45,(char)0x46,(char)0x47, // 0x40 - 0x4f
-       (char)0x48,(char)0x49,(char)0x4a,(char)0x4b,(char)0x4c,(char)0x4d,(char)0x4e,(char)0x4f,
-       (char)0x50,(char)0x51,(char)0x52,(char)0x53,(char)0x54,(char)0x55,(char)0x56,(char)0x57, // 0x50 - 0x5f
-       (char)0x58,(char)0x59,(char)0x5a,(char)0x5b,(char)0x04,(char)0x5d,(char)0x5e,(char)0xdb,
-       (char)0x04,(char)0xb1,(char)0x09,(char)0x0c,(char)0x0d,(char)0x0a,(char)0xf8,(char)0xf1, // 0x60 - 0x6f
-       (char)0x68,(char)0x0b,(char)0xd9,(char)0xbf,(char)0xda,(char)0xc0,(char)0xc5,(char)0xa9,
-       (char)0xa9,(char)0xc4,(char)0x5f,(char)0x5f,(char)0xc3,(char)0xb4,(char)0xc1,(char)0xc2, // 0x70 - 0x7f
-       (char)0xb3,(char)0xf3,(char)0xf2,(char)0xe3,(char)0x2f,(char)0x9c,(char)0xfe,(char)0x7f,
-       (char)0x80,(char)0x81,(char)0x82,(char)0x83,(char)0x84,(char)0x85,(char)0x86,(char)0x87, // 0x80 - 0x8f
-       (char)0x88,(char)0x89,(char)0x8a,(char)0x8b,(char)0x8c,(char)0x8d,(char)0x8e,(char)0x8f,
-       (char)0x90,(char)0x91,(char)0x92,(char)0x93,(char)0x94,(char)0x95,(char)0x96,(char)0x97, // 0x90 - 0x9f
-       (char)0x98,(char)0x99,(char)0x9a,(char)0x9b,(char)0x9c,(char)0x9d,(char)0x9e,(char)0x9f,
-       (char)0xa0,(char)0xa1,(char)0xa2,(char)0xa3,(char)0xa4,(char)0xa5,(char)0xa6,(char)0xa7, // 0xa0 - 0xaf
-       (char)0xa8,(char)0xa9,(char)0xaa,(char)0xab,(char)0xac,(char)0xad,(char)0xae,(char)0xaf,
-       (char)0xb0,(char)0xb1,(char)0xb2,(char)0xb3,(char)0xb4,(char)0xb5,(char)0xb6,(char)0xb7, // 0xb0 - 0xbf
-       (char)0xb8,(char)0xb9,(char)0xba,(char)0xbb,(char)0xbc,(char)0xbd,(char)0xbe,(char)0xbf,
-       (char)0xc0,(char)0xc1,(char)0xc2,(char)0xc3,(char)0xc4,(char)0xc5,(char)0xc6,(char)0xc7, // 0xc0 - 0xcf
-       (char)0xc8,(char)0xc9,(char)0xca,(char)0xcb,(char)0xcc,(char)0xcd,(char)0xce,(char)0xcf,
-       (char)0xd0,(char)0xd1,(char)0xd2,(char)0xd3,(char)0xd4,(char)0xd5,(char)0xd6,(char)0xd7, // 0xd0 - 0xdf
-       (char)0xd8,(char)0xd9,(char)0xda,(char)0xdb,(char)0xdc,(char)0xdd,(char)0xde,(char)0xdf,
-       (char)0xe0,(char)0xe1,(char)0xe2,(char)0xe3,(char)0xe4,(char)0xe5,(char)0xe6,(char)0xe7, // 0xe0 - 0xef
-       (char)0xe8,(char)0xe9,(char)0xea,(char)0xeb,(char)0xec,(char)0xed,(char)0xee,(char)0xef,
-       (char)0xf0,(char)0xf1,(char)0xf2,(char)0xf3,(char)0xf4,(char)0xf5,(char)0xf6,(char)0xf7, // 0xf0 - 0xff
-       (char)0xf8,(char)0xf9,(char)0xfa,(char)0xfb,(char)0xfc,(char)0xfd,(char)0xfe,(char)0xff
-};
-
-// map 0 (safe version for being unable to write ROM chars)
-// Special graphics and line drawing
-static char map0_safe[256] = {
-       (char)0x00,(char)0x01,(char)0x02,(char)0x03,(char)0x04,(char)0x05,(char)0x06,(char)0x07, // 0x00 - 0x0f
-       (char)0x08,(char)0x09,(char)0x0a,(char)0x0b,(char)0x0c,(char)0x0d,(char)0x0e,(char)0x0f,
-       (char)0x10,(char)0x11,(char)0x12,(char)0x13,(char)0x14,(char)0x15,(char)0x16,(char)0x17, // 0x10 - 0x1f
-       (char)0x18,(char)0x19,(char)0x1a,(char)0x1b,(char)0x1c,(char)0x1d,(char)0x1e,(char)0x1f,
-       (char)0x20,(char)0x21,(char)0x22,(char)0x23,(char)0x24,(char)0x25,(char)0x26,(char)0x27, // 0x20 - 0x2f
-       (char)0x28,(char)0x29,(char)0x2a,(char)0x2b,(char)0x2c,(char)0x2d,(char)0x2e,(char)0x2f,
-       (char)0x30,(char)0x31,(char)0x32,(char)0x33,(char)0x34,(char)0x35,(char)0x36,(char)0x37, // 0x30 - 0x3f
-       (char)0x38,(char)0x39,(char)0x3a,(char)0x3b,(char)0x3c,(char)0x3d,(char)0x3e,(char)0x3f,
-       (char)0x40,(char)0x41,(char)0x42,(char)0x43,(char)0x44,(char)0x45,(char)0x46,(char)0x47, // 0x40 - 0x4f
-       (char)0x48,(char)0x49,(char)0x4a,(char)0x4b,(char)0x4c,(char)0x4d,(char)0x4e,(char)0x4f,
-       (char)0x50,(char)0x51,(char)0x52,(char)0x53,(char)0x54,(char)0x55,(char)0x56,(char)0x57, // 0x50 - 0x5f
-       (char)0x58,(char)0x59,(char)0x5a,(char)0x5b,(char)0x04,(char)0x5d,(char)0x5e,(char)0xdb,
-       (char)0x04,(char)0xb1,(char)0xf8,(char)0xf9,(char)0xfb,(char)0xdb,(char)0xf8,(char)0xf1, // 0x60 - 0x6f
-       (char)0x68,(char)0xf9,(char)0xd9,(char)0xbf,(char)0xda,(char)0xc0,(char)0xc5,(char)0xa9,
-       (char)0xa9,(char)0xc4,(char)0x5f,(char)0x5f,(char)0xc3,(char)0xb4,(char)0xc1,(char)0xc2, // 0x70 - 0x7f
-       (char)0xb3,(char)0xf3,(char)0xf2,(char)0xe3,(char)0x2f,(char)0x9c,(char)0xfe,(char)0x7f,
-       (char)0x80,(char)0x81,(char)0x82,(char)0x83,(char)0x84,(char)0x85,(char)0x86,(char)0x87, // 0x80 - 0x8f
-       (char)0x88,(char)0x89,(char)0x8a,(char)0x8b,(char)0x8c,(char)0x8d,(char)0x8e,(char)0x8f,
-       (char)0x90,(char)0x91,(char)0x92,(char)0x93,(char)0x94,(char)0x95,(char)0x96,(char)0x97, // 0x90 - 0x9f
-       (char)0x98,(char)0x99,(char)0x9a,(char)0x9b,(char)0x9c,(char)0x9d,(char)0x9e,(char)0x9f,
-       (char)0xa0,(char)0xa1,(char)0xa2,(char)0xa3,(char)0xa4,(char)0xa5,(char)0xa6,(char)0xa7, // 0xa0 - 0xaf
-       (char)0xa8,(char)0xa9,(char)0xaa,(char)0xab,(char)0xac,(char)0xad,(char)0xae,(char)0xaf,
-       (char)0xb0,(char)0xb1,(char)0xb2,(char)0xb3,(char)0xb4,(char)0xb5,(char)0xb6,(char)0xb7, // 0xb0 - 0xbf
-       (char)0xb8,(char)0xb9,(char)0xba,(char)0xbb,(char)0xbc,(char)0xbd,(char)0xbe,(char)0xbf,
-       (char)0xc0,(char)0xc1,(char)0xc2,(char)0xc3,(char)0xc4,(char)0xc5,(char)0xc6,(char)0xc7, // 0xc0 - 0xcf
-       (char)0xc8,(char)0xc9,(char)0xca,(char)0xcb,(char)0xcc,(char)0xcd,(char)0xce,(char)0xcf,
-       (char)0xd0,(char)0xd1,(char)0xd2,(char)0xd3,(char)0xd4,(char)0xd5,(char)0xd6,(char)0xd7, // 0xd0 - 0xdf
-       (char)0xd8,(char)0xd9,(char)0xda,(char)0xdb,(char)0xdc,(char)0xdd,(char)0xde,(char)0xdf,
-       (char)0xe0,(char)0xe1,(char)0xe2,(char)0xe3,(char)0xe4,(char)0xe5,(char)0xe6,(char)0xe7, // 0xe0 - 0xef
-       (char)0xe8,(char)0xe9,(char)0xea,(char)0xeb,(char)0xec,(char)0xed,(char)0xee,(char)0xef,
-       (char)0xf0,(char)0xf1,(char)0xf2,(char)0xf3,(char)0xf4,(char)0xf5,(char)0xf6,(char)0xf7, // 0xf0 - 0xff
-       (char)0xf8,(char)0xf9,(char)0xfa,(char)0xfb,(char)0xfc,(char)0xfd,(char)0xfe,(char)0xff
-};
-
-TCharmap::TCharmap() {
-       memset(map, 0, sizeof(map));
-
-       map[0] = mapB;                          // default map
-       map[(unsigned char)'B'] = mapB;
-       map[(unsigned char)'A'] = mapA;
-       if(ini.get_fast_write()) {
-               map[(unsigned char)'0'] = map0_safe;
-               map[(unsigned char)'2'] = map0_safe;
-       } else {
-               map[(unsigned char)'0'] = map0;
-               map[(unsigned char)'2'] = map0;
-       }
-       current_map = map[0];
-}
-
-TCharmap::~TCharmap() {
-       for(int j = 0; j < 256; j++) {
-               if(map[j]) {
-                       // Don't delete static maps! 
-                       switch(j) {
-                               case 'B':
-                               case 'A':
-                               case '0':
-                               case '2':
-                               case 0: break;
-                               default: delete map[j];
-                       }
-               }
-       }
-}
-
-void TCharmap::modmap(char pos, char mapchar, char c) {
-       if(!map[(unsigned char)mapchar]) {
-               map[(unsigned char)mapchar] = new char[256];
-               for(int j = 0; j < 256; j++) map[(unsigned char)mapchar][(unsigned char)pos] = j;
-       }
-       map[(unsigned char)mapchar][(unsigned char)pos] = c;
-}
diff --git a/reactos/apps/utils/net/telnet/src/tcharmap.h b/reactos/apps/utils/net/telnet/src/tcharmap.h
deleted file mode 100644 (file)
index cbc97e3..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-// This is a simple class to handle character maps
-// (Paul Brannan 6/25/98)
-
-#ifndef __TCHARMAP_H
-#define __TCHARMAP_H
-
-class TCharmap {
-private:
-       char *map[256];
-       char *current_map;
-public:
-       TCharmap();
-       ~TCharmap();
-
-       void init() {}
-
-       char translate(char c, char mapchar) {
-               if(map[(unsigned char)mapchar]) return map[(unsigned char)mapchar][(unsigned char)c];
-               return c;
-       }
-       char translate(char c) {
-               return current_map[(unsigned char)c];
-       }
-
-       void setmap(char mapchar) {
-               if(map[(unsigned char)mapchar]) current_map = map[(unsigned char)mapchar];
-       }
-
-       void translate_buffer(char *start, char *end) {
-               while(start < end) {
-                       *start = translate(*start);
-                       start++;
-               }
-       }
-
-       void modmap(char pos, char mapchar, char c);
-
-       int enabled;
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tconsole.cpp b/reactos/apps/utils/net/telnet/src/tconsole.cpp
deleted file mode 100644 (file)
index 24fabdb..0000000
+++ /dev/null
@@ -1,1008 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-///////////////////////////////////////////////////////////////////////////////
-//
-// Module:             tconsole.cpp
-//
-// Contents:   screen functions
-//
-// Product:            telnet
-//
-//
-// Revisions: Mar. 29, 2000 pbranna@clemson (Paul Brannan)
-//            June 15, 1998 pbranna@clemson.edu
-//            May 16, 1998     pbranna@clemson.edu
-//            05. Sep.1997  roryt@hol.gr (I.Ioannou)
-//            11.May,1997   roryt@hol.gr
-//            06.April,1997 roryt@hol.gr
-//            30.M\84rz.1997  Titus_Boxberg@public.uni-hamburg.de
-//                   5.Dec.1996    jbj@nounname.com
-//            Version 2.0
-//            02.Apr.1995      igor.milavec@uni-lj.si
-//                                       Original code
-//
-///////////////////////////////////////////////////////////////////////////////
-
-#include <windows.h>
-#include "tconsole.h"
-
-// argsused doesn't work on MSVC++
-#ifdef __BORLANDC__
-#pragma argsused
-#endif
-
-TConsole::TConsole(HANDLE h) {
-       hConsole = h;
-
-       GetConsoleScreenBufferInfo(hConsole, &ConsoleInfo);
-
-       // Start with correct colors
-       int color_fg = ini.get_normal_fg();
-       int color_bg = ini.get_normal_bg();
-       if(color_fg == -1)
-               color_fg = defaultfg = origfg = ConsoleInfo.wAttributes & 0xF;
-       else
-               defaultfg = origfg = color_fg;
-       if(color_bg == -1)
-               color_bg = defaultbg = origbg = (ConsoleInfo.wAttributes >> 4) & 0xF;
-       else
-               defaultbg = origbg = color_bg;
-       wAttributes = color_fg | (color_bg << 4);
-       reverse = blink = underline = false;
-       SetConsoleTextAttribute(hConsole, wAttributes);
-
-       insert_mode = 0;
-       
-       // Set the screen size
-       SetWindowSize(ini.get_term_width(), ini.get_term_height());
-
-       iScrollStart = -1;
-       iScrollEnd = -1;
-}
-
-TConsole::~TConsole() {
-       wAttributes = origfg | (origbg << 4);
-       SetCursorPosition(0, CON_HEIGHT);
-       SetConsoleTextAttribute(hConsole, wAttributes);
-       WriteCtrlChar('\x0a');
-}
-
-// Paul Brannan 8/2/98
-void TConsole::SetWindowSize(int width, int height) {
-       SMALL_RECT sr = {
-               CON_LEFT,
-               CON_TOP,
-               (width == -1) ? CON_RIGHT : CON_LEFT + width - 1,
-               (height == -1) ? CON_BOTTOM : CON_TOP + height - 1
-       };
-       ConsoleInfo.dwSize.X = width;
-       if(ConsoleInfo.dwSize.Y < height) ConsoleInfo.dwSize.Y = height;
-       SetConsoleScreenBufferSize(hConsole, ConsoleInfo.dwSize);
-       SetConsoleWindowInfo(hConsole, TRUE, &sr);
-       SetConsoleScreenBufferSize(hConsole, ConsoleInfo.dwSize);
-       sync();
-}
-
-// Paul Brannan 5/15/98
-void TConsole::sync() {
-       GetConsoleScreenBufferInfo(hConsole, &ConsoleInfo);
-}
-
-void TConsole::HighVideo() {
-       wAttributes = wAttributes | (unsigned char) 8;
-}
-
-void TConsole::LowVideo() {
-       wAttributes = wAttributes & (unsigned char) (0xff-8);
-}
-
-void TConsole::Normal() {
-       // I.Ioannou 11 May 1997
-       // Color 7 is correct on some systems (for example Linux)
-       // but not with others (for example SCO)
-       // we must preserve the colors :
-       // 06/04/98 thanks to Paul a .ini parameter from now on
-       
-       BlinkOff();
-       UnderlineOff();
-       if(ini.get_preserve_colors()) {
-               ReverseOff();
-               LowVideo();
-       } else {
-               fg = defaultfg;
-               bg = defaultbg;
-               wAttributes = (unsigned char)fg | (bg << 4);
-               reverse = false;
-       }
-}
-
-void TConsole::SetForeground(unsigned char wAttrib) {
-       if(reverse) bg = wAttrib; else fg = wAttrib;
-       wAttributes = (wAttributes & (unsigned char)0x88) | 
-               (unsigned char)fg | (bg << 4);
-}
-
-void TConsole::SetBackground(unsigned char wAttrib) {
-       if(reverse) fg = wAttrib; else bg = wAttrib;
-       wAttributes = (wAttributes & (unsigned char)0x88) | 
-               (unsigned char)fg | (bg << 4);
-}
-
-// As far as I can tell, there's no such thing as blink in Windows Console.
-// I tried using some inline asm to turn off high-intensity backgrounds,
-// but I got a BSOD.  Perhaps there is an undocumented function?
-// (Paul Brannan 6/27/98)
-void TConsole::BlinkOn() {
-       blink = 1;
-       if(underline) {
-               UlBlinkOn();
-       } else {
-               if(ini.get_blink_bg() != -1) {
-                       wAttributes &= 0x8f;                                    // turn off bg
-                       wAttributes |= ini.get_blink_bg() << 4;
-               }
-               if(ini.get_blink_fg() != -1) {
-                       wAttributes &= 0xf8;                                    // turn off fg
-                       wAttributes |= ini.get_blink_fg();
-               }
-               if(ini.get_blink_bg() == -1 && ini.get_blink_fg() == -1)
-                       wAttributes |= 0x80;
-       }
-}
-
-// Added by I.Ioannou 06 April, 1997
-void TConsole::BlinkOff() {
-       blink = 0;
-       if(underline) {
-               UlBlinkOff();
-       } else {
-               if(ini.get_blink_bg() != -1) {
-                       wAttributes &= 0x8f;                                    // turn off bg
-                       wAttributes |= defaultbg << 4;
-               }
-               if(ini.get_blink_fg() != -1) {
-                       wAttributes &= 0xf8;                                    // turn off fg
-                       wAttributes |= defaultfg;
-               }
-               if(ini.get_blink_bg() == -1 && ini.get_blink_fg() == -1)
-                       wAttributes &= 0x7f;
-       }
-}
-
-// Paul Brannan 6/27/98
-void TConsole::UnderlineOn() {
-       underline = 1;
-       if(blink) {
-               UlBlinkOn();
-       } else {
-               if(ini.get_underline_bg() != -1) {
-                       wAttributes &= 0x8f;                                    // turn off bg
-                       wAttributes |= ini.get_underline_bg() << 4;
-               }
-               if(ini.get_underline_fg() != -1) {
-                       wAttributes &= 0xf8;                                    // turn off fg
-                       wAttributes |= ini.get_underline_fg();
-               }
-               if(ini.get_underline_bg() == -1 && ini.get_underline_fg() == -1)
-                       wAttributes |= 0x80;
-       }
-}
-
-// Paul Brannan 6/27/98
-void TConsole::UnderlineOff() {
-       underline = 0;
-       if(blink) {
-               UlBlinkOff();
-       } else {
-               if(ini.get_blink_bg() != -1) {
-                       wAttributes &= 0x8f;                                    // turn off bg
-                       wAttributes |= defaultbg << 4;
-               }
-               if(ini.get_blink_fg() != -1) {
-                       wAttributes &= 0xf8;                                    // turn off fg
-                       wAttributes |= defaultfg;
-               }
-               if(ini.get_blink_bg() == -1 && ini.get_blink_fg() == -1)
-                       wAttributes &= 0x7f;
-       }
-}
-
-// Paul Brannan 6/27/98
-void TConsole::UlBlinkOn() {
-       if(ini.get_ulblink_bg() != -1) {
-               wAttributes &= 0x8f;                                    // turn off bg
-               wAttributes |= ini.get_ulblink_bg() << 4;
-       }
-       if(ini.get_ulblink_fg() != -1) {
-               wAttributes &= 0xf8;                                    // turn off fg
-               wAttributes |= ini.get_ulblink_fg();
-       }
-       if(ini.get_ulblink_bg() == -1 && ini.get_ulblink_fg() == -1)
-               wAttributes |= 0x80;
-}
-
-// Paul Brannan 6/27/98
-void TConsole::UlBlinkOff() {
-       if(blink) {
-               BlinkOn();
-       } else if(underline) {
-               UnderlineOn();
-       } else {
-               Normal();
-       }
-}
-
-// Paul Brannan 6/26/98
-void TConsole::Lightbg() {
-       WORD *pAttributes = new WORD[CON_COLS];
-       DWORD Result;
-
-       // Paul Brannan 8/5/98
-       // Correction: processing more than one line at a time causes a segfault
-       // if the screen width != 80
-       for(int i = CON_TOP; i <= CON_BOTTOM; i++) {
-               COORD Coord = {CON_LEFT, i};
-
-               ReadConsoleOutputAttribute(hConsole, pAttributes, (DWORD)(CON_COLS),
-                       Coord, &Result);
-       
-               for(DWORD j = 0; j < Result; j++) pAttributes[j] |= 0x80;
-
-               WriteConsoleOutputAttribute(hConsole, pAttributes, Result, Coord,
-                       &Result);
-       }
-
-       delete[] pAttributes; // clean up
-
-       wAttributes |= (unsigned char)0x80;
-       bg |= 8;
-}
-
-// Paul Brannan 6/26/98
-void TConsole::Darkbg() {
-       WORD *pAttributes = new WORD[CON_COLS];
-       DWORD Result;
-
-       // Paul Brannan 8/5/98
-       // Correction: processing more than one line at a time causes a segfault
-       // if the screen width != 80
-       for(int i = CON_TOP; i <= CON_BOTTOM; i++) {
-               COORD Coord = {CON_LEFT, i};
-
-               ReadConsoleOutputAttribute(hConsole, pAttributes, (DWORD)(CON_COLS),
-                       Coord, &Result);
-       
-               for(DWORD j = 0; j < Result; j++) pAttributes[j] &= 0x7f;
-
-               WriteConsoleOutputAttribute(hConsole, pAttributes, Result, Coord,
-                       &Result);
-       }
-
-       delete[] pAttributes; // clean up
-
-
-       wAttributes &= (unsigned char)0x7f;
-       bg &= 7;
-}
-
-// Added by I.Ioannou 11.May,1997
-void TConsole::ReverseOn() {
-       if (!reverse) {
-               reverse = true;
-
-               // atl  : forground attributes without the intensity
-               // ath  : backgound attributes without the blink
-               // bl   : the blink state
-               // ints : the intensity
-               unsigned char atl   = wAttributes & (unsigned char) 0x07;
-               unsigned char ath   = wAttributes & (unsigned char) 0x70;
-               unsigned char bl    = wAttributes & (unsigned char) 0x80;
-               unsigned char ints  = wAttributes & (unsigned char) 0x08;
-               wAttributes = bl | (atl << 4) | ints | (ath >> 4);
-       }
-}
-
-// Added by I.Ioannou 11.May,1997
-void TConsole::ReverseOff() {
-       if (reverse) {
-               reverse = false;
-               wAttributes = fg | (bg << 4);
-       }
-}
-
-unsigned long TConsole::WriteText(const char *pszString, unsigned long cbString) {
-       DWORD Result;
-
-       if(insert_mode) {
-               InsertCharacter(cbString);
-       }
-
-       WriteConsoleOutputCharacter(hConsole, (char *)pszString, cbString,
-               ConsoleInfo.dwCursorPosition, &Result);
-       FillConsoleOutputAttribute(hConsole, wAttributes, cbString,
-               ConsoleInfo.dwCursorPosition, &Result);
-       return Result;
-}
-
-// Formerly ConWriteString (Paul Brannan 6/28/98)
-unsigned long TConsole::WriteStringFast(const char* pszString, unsigned long cbString) {
-       DWORD Result;
-
-       SetConsoleTextAttribute(hConsole, wAttributes);
-
-       //check to see if the line is longer than the display
-       if (!getLineWrap() && ((unsigned)CON_CUR_X + cbString) >= (unsigned)CON_COLS) {
-               // Take care of the last line last colum exception...
-               // The display scrolls up if you use the normal char out
-               //   function even if you only write to the last place
-               //   on the line. :-(
-               if ((unsigned)CON_CUR_Y >= (unsigned)CON_HEIGHT) {
-                       unsigned long iFakeResult = cbString;
-                       cbString = CON_COLS - CON_CUR_X - 1;
-
-                       // FIX ME !!! This will avoid the exception when cbString
-                       // is <= 0 but still doesn't work :-(
-                       if (cbString > 0)
-                               WriteConsole(hConsole, pszString, cbString, &Result, 0);
-
-                       COORD dwBufferCoord;
-                       dwBufferCoord.X = 0;
-                       dwBufferCoord.Y = 0;
-
-                       CHAR_INFO ciBuffer;
-                       ciBuffer.Char.AsciiChar = *(pszString+cbString);
-                       ciBuffer.Attributes = wAttributes;
-                       SMALL_RECT srWriteRegion;
-                       srWriteRegion.Top =             (SHORT) CON_BOTTOM;
-                       srWriteRegion.Bottom =  (SHORT) CON_BOTTOM;
-                       srWriteRegion.Left =    (SHORT) CON_RIGHT;
-                       srWriteRegion.Right =   (SHORT) CON_RIGHT;
-
-                       COORD bufSize = {1,1};
-
-                       WriteConsoleOutput(hConsole, &ciBuffer, bufSize,
-                               dwBufferCoord, &srWriteRegion);
-
-                       // We need to update the ConsoleInfo struct now (Paul Brannan 5/9/98)
-                       ConsoleInfo.dwCursorPosition.X = CON_RIGHT;
-
-                       return iFakeResult; // Skip the chars that did not fit
-               }
-               // just write the line up to the end
-               else {
-                       int iFakeResult = cbString;
-                       cbString = CON_COLS - CON_CUR_X;
-
-                       if(cbString > 0) {
-                               WriteConsole(hConsole, pszString, cbString, &Result, 0);
-
-                               // We need to update the ConsoleInfo struct now (Paul Brannan 5/9/98)
-                               ConsoleInfo.dwCursorPosition.X += (unsigned short)Result;
-                       }
-
-                       return iFakeResult; // Skip the chars that did not fit
-               }
-       } else {
-               // If custom scrolling is enabled we must take care of it
-               if(iScrollStart != -1 || iScrollEnd != -1) {
-                       return WriteString(pszString, cbString);
-               }
-
-               // Apparently VT100 terminals have an invisible "81st" column that
-               // can hold a cursor until another character is printed.  I'm not sure
-               // exactly how to handle this, but here's a hack (Paul Brannan 5/28/98)
-               if(ini.get_vt100_mode() && cbString + (unsigned)CON_CUR_X == (unsigned)CON_COLS) {
-
-                       cbString--;
-                       if(cbString >= 0) WriteConsole(hConsole, pszString, cbString, &Result, 0);
-
-                       COORD dwBufferCoord;
-                       dwBufferCoord.X = 0;
-                       dwBufferCoord.Y = 0;
-
-                       CHAR_INFO ciBuffer;
-                       ciBuffer.Char.AsciiChar = *(pszString+cbString);
-                       ciBuffer.Attributes = wAttributes;
-                       SMALL_RECT srWriteRegion;
-                       srWriteRegion.Top =    (SHORT) ConsoleInfo.dwCursorPosition.Y;
-                       srWriteRegion.Bottom = (SHORT) ConsoleInfo.dwCursorPosition.Y;
-                       srWriteRegion.Left =   (SHORT) CON_RIGHT;
-                       srWriteRegion.Right =  (SHORT) CON_RIGHT;
-
-                       COORD bufSize = {1,1};
-
-                       WriteConsoleOutput(hConsole, &ciBuffer, bufSize,
-                               dwBufferCoord, &srWriteRegion);
-
-                       // Update the ConsoleInfo struct
-                       ConsoleInfo.dwCursorPosition.X = CON_RIGHT + 1;
-
-                       return Result + 1;
-               }
-
-               // normal line will wrap normally or not to the end of buffer
-               WriteConsole(hConsole, pszString, cbString, &Result, 0);
-
-               // We need to update the ConsoleInfo struct now (Paul Brannan 5/9/98)
-               // FIX ME!!! This is susceptible to the same problem as above.
-               // (e.g. we write out 160 characters)
-               ConsoleInfo.dwCursorPosition.X += (unsigned short)Result;
-               while(CON_CUR_X > CON_WIDTH) {
-                       ConsoleInfo.dwCursorPosition.X -= ConsoleInfo.dwSize.X;
-                       if((unsigned)CON_CUR_Y < (unsigned)CON_HEIGHT) {
-                               ConsoleInfo.dwCursorPosition.Y++;
-                       } else {
-                               // If we aren't at the bottom of the window, then we need to
-                               // scroll down (Paul Brannan 4/14/2000)
-                               if(ConsoleInfo.srWindow.Bottom < ConsoleInfo.dwSize.Y - 1) {
-                                       ConsoleInfo.srWindow.Top++;
-                                       ConsoleInfo.srWindow.Bottom++;
-                                       ConsoleInfo.dwCursorPosition.Y++;
-                                       SetConsoleWindowInfo(hConsole, TRUE, &ConsoleInfo.srWindow);
-                               }
-                       }
-               }
-       }
-
-       return Result;
-
-}
-
-unsigned long TConsole::WriteString(const char* pszString, unsigned long cbString) {
-       DWORD Result = 0;
-       
-       SetConsoleTextAttribute(hConsole, wAttributes);
-
-       //check to see if the line is longer than the display
-       if (!getLineWrap()){
-               unsigned long iFakeResult = cbString;
-               if((CON_CUR_X + cbString) >= (unsigned int)CON_COLS)
-                       cbString = CON_COLS - CON_CUR_X;
-               if(cbString > 0)
-                       Result = WriteText(pszString, cbString);
-
-               // We need to update the ConsoleInfo struct now (Paul Brannan 5/9/98)
-               ConsoleInfo.dwCursorPosition.X += (unsigned short)Result;
-               SetConsoleCursorPosition(hConsole, ConsoleInfo.dwCursorPosition);
-
-               return iFakeResult; // Skip the chars that did not fit
-       } else {
-               // Write up to the end of the line
-               unsigned long temp = cbString;
-               if((CON_CUR_X + temp) > (unsigned int)CON_COLS) {
-                       temp = CON_COLS - CON_CUR_X;
-               } else {
-                       Result = WriteText(pszString, temp);
-                       ConsoleInfo.dwCursorPosition.X += (unsigned short)Result;
-                       SetConsoleCursorPosition(hConsole, ConsoleInfo.dwCursorPosition);
-                       return Result;
-               }
-               if(temp > 0) {
-                       Result = WriteText(pszString, temp);
-                       ConsoleInfo.dwCursorPosition.X += (unsigned short)Result;
-                       temp = (unsigned short)Result;
-               }
-
-               // keep writing lines until we get to less than 80 chars left
-               while((temp + (unsigned int)CON_COLS) < cbString) {
-                       index(); // LF
-                       ConsoleInfo.dwCursorPosition.X = 0; // CR
-                       Result = WriteText(&pszString[temp], CON_COLS);
-                       temp += (unsigned short)Result;
-               }
-
-               // write out the last bit
-               if(temp < cbString) {
-                       index();
-                       ConsoleInfo.dwCursorPosition.X = 0;
-                       Result = WriteText(&pszString[temp], cbString - temp);
-                       temp += (unsigned short)Result;
-               }
-
-               // Apparently VT100 terminals have an invisible "81st" column that
-               // can hold a cursor until another character is printed.  I'm not sure
-               // exactly how to handle this, but here's a hack (Paul Brannan 5/28/98)
-               if(!ini.get_vt100_mode() && cbString + (unsigned)ConsoleInfo.dwCursorPosition.X
-                       == (unsigned int)CON_COLS) {
-                       index();
-                       ConsoleInfo.dwCursorPosition.X = 0;
-               }
-
-               SetConsoleCursorPosition(hConsole, ConsoleInfo.dwCursorPosition);
-
-               return temp;
-       }
-
-       return 0;
-}
-
-// This is for multi-character control strings (Paul Brannan 6/26/98)
-unsigned long TConsole::WriteCtrlString(const char *pszString, unsigned long cbString) {
-       unsigned long total = 0;
-       while(total < cbString) {
-               unsigned long Result = WriteCtrlChar(*(pszString + total));
-               if(Result == 0) {
-                       Result = WriteStringFast(pszString + total, 1);
-                       if(Result == 0) return total;
-               }
-               total += Result;
-       }
-       return total;
-}
-
-// This is for printing single control characters
-// WriteCtrlString uses this (Paul Brannan 6/26/98)
-unsigned long TConsole::WriteCtrlChar(char c) {
-       // The console does not handel the CR/LF chars as we might expect
-       // when using color. The attributes are not set correctly, so we
-       // must interpret them manualy to preserve the colors on the screen.
-       
-       unsigned long Result = 0; // just in case (Paul Brannan 6/26/98)
-       switch (c) {
-    case '\x09': // horizontal tab
-               SetCursorPosition((((CON_CUR_X/8)+1)*8), CON_CUR_Y);
-               Result = 1;
-               break;
-               
-    case '\x0a': // line feed
-               index();
-               Result = 1;
-               break;
-    case '\x0d': // carrage return
-               SetCursorPosition(CON_LEFT, CON_CUR_Y); // move to beginning of line
-               Result = 1;
-               break;
-       case '\b': // backspace
-               // Added support for backspace so the cursor position can be changed
-               // (Paul Brannan 5/25/98)
-               MoveCursorPosition(-1, 0);
-               Result = 1;
-    default :    // else just write it like normal
-               break;
-       }
-       
-       return Result;
-}
-
-void TConsole::index() {
-       // if on the last line scroll up
-       // This must work with scrolling (Paul Brannan 5/13/98)
-       if(iScrollEnd != -1 && (signed)CON_CUR_Y >= iScrollEnd) {
-               ScrollDown(iScrollStart, iScrollEnd, -1);
-       } else if ((iScrollEnd == -1 && (signed)CON_CUR_Y >= (signed)CON_HEIGHT)) {
-               DWORD Result;
-               WriteConsole(hConsole, "\n", 1, &Result, NULL);
-               
-               // If we aren't at the bottom of the buffer, then we need to
-               // scroll down (Paul Brannan 4/14/2000)
-               if(iScrollEnd == -1 && ConsoleInfo.srWindow.Bottom < ConsoleInfo.dwSize.Y - 1) {
-                       ConsoleInfo.srWindow.Top++;
-                       ConsoleInfo.srWindow.Bottom++;
-                       ConsoleInfo.dwCursorPosition.Y++;
-                       // SetConsoleWindowInfo(hConsole, TRUE, &ConsoleInfo.srWindow);
-               } else {
-                       ClearLine();
-               }
-       } else {     // else move cursor down to the next line
-               SetCursorPosition(CON_CUR_X, CON_CUR_Y + 1);
-       }
-}
-
-void TConsole::reverse_index() {
-       // if on the top line scroll down
-       // This must work with scrolling (Paul Brannan 5/13/98)
-       // We should be comparing against iScrollStart, not iScrollEnd (PB 12/2/98)
-       if (iScrollStart == -1 && (signed)CON_CUR_Y <= 0) {
-               ScrollDown(iScrollStart, -1, 1);
-       } else if (iScrollStart != -1 && (signed)CON_CUR_Y <= iScrollStart) {
-                       ScrollDown(iScrollStart, iScrollEnd, 1);
-       } else       // else move cursor up to the previous line
-               SetCursorPosition(CON_CUR_X,CON_CUR_Y - 1);
-}
-
-void TConsole::ScrollDown( int iStartRow , int iEndRow, int bUp ){
-       CHAR_INFO ciChar;
-       SMALL_RECT srScrollWindow;
-       
-       // Correction from I.Ioannou 11 May 1997
-       // check the scroll region
-       if (iStartRow < iScrollStart) iStartRow = iScrollStart;
-       
-       // Correction from I.Ioannou 11 May 1997
-       // this will make Top the CON_TOP
-       if ( iStartRow == -1) iStartRow = 0;
-
-       // Correction from I.Ioannou 18 Aug 97
-       if ( iEndRow == -1)     {
-               if ( iScrollEnd == -1 )
-                       iEndRow = CON_HEIGHT;
-               else
-                       iEndRow = ((CON_HEIGHT <= iScrollEnd) ? CON_HEIGHT : iScrollEnd);
-       }
-       //
-
-       if ( iStartRow > CON_HEIGHT) iStartRow = CON_HEIGHT;
-       if ( iEndRow > CON_HEIGHT) iEndRow = CON_HEIGHT;
-       
-       srScrollWindow.Left =           (CON_LEFT);
-       srScrollWindow.Right =  (SHORT) (CON_RIGHT);
-       srScrollWindow.Top =    (SHORT) (CON_TOP + iStartRow );
-       srScrollWindow.Bottom = (SHORT) (CON_TOP + iEndRow); // don't subtract 1 (PB 5/28)
-
-       ciChar.Char.AsciiChar = ' ';           // fill with spaces
-       ciChar.Attributes = wAttributes;       // fill with current attrib
-       
-       // This should speed things up (Paul Brannan 9/2/98)
-       COORD dwDestOrg = {srScrollWindow.Left, srScrollWindow.Top + bUp};
-       
-       // Note that iEndRow and iStartRow had better not be equal to -1 at this
-       // point.  There are four cases to consider for out of bounds.  Two of
-       // these cause the scroll window to be cleared; the others cause the
-       // scroll region to be modified.  (Paul Brannan 12/3/98)
-       if(dwDestOrg.Y > CON_TOP + iEndRow) {
-               // We are scrolling past the end of the scroll region, so just
-               // clear the window instead (Paul Brannan 12/3/98)
-               ClearWindow(CON_TOP + iStartRow, CON_TOP + iEndRow);
-               return;
-       } else if(dwDestOrg.Y + (iEndRow-iStartRow+1) < CON_TOP + iStartRow) {
-               // We are scrolling past the end of the scroll region, so just
-               // clear the window instead (Paul Brannan 12/3/98)
-               ClearWindow(CON_TOP + iStartRow, CON_TOP + iEndRow);
-               return;
-       } else if(dwDestOrg.Y < CON_TOP + iStartRow) {
-               // Modify the scroll region (Paul Brannan 12/3/98)
-               dwDestOrg.Y = CON_TOP + iStartRow;
-               srScrollWindow.Top -= bUp;
-       } else  if(dwDestOrg.Y + (iEndRow-iStartRow+1) > CON_TOP + iEndRow) {
-               // Modify the scroll region (Paul Brannan 12/3/98)
-               srScrollWindow.Bottom -= bUp;
-       }
-       
-       ScrollConsoleScreenBuffer(hConsole, &srScrollWindow,
-               0, dwDestOrg, &ciChar);
-}
-
-// This allows us to clear the screen with an arbitrary character
-// (Paul Brannan 6/26/98)
-void TConsole::ClearScreen(char c) {
-       DWORD dwWritten;
-       COORD Coord = {CON_LEFT, CON_TOP};
-       FillConsoleOutputCharacter(hConsole, c, (DWORD)(CON_COLS)*
-               (DWORD)(CON_LINES), Coord, &dwWritten);
-       FillConsoleOutputAttribute(hConsole, wAttributes, (DWORD)(CON_COLS)*
-               (DWORD)(CON_LINES), Coord, &dwWritten);
-}
-
-// Same as clear screen, but only affects the scroll region
-void TConsole::ClearWindow(int iStartRow, int iEndRow, char c) {
-       DWORD dwWritten;
-       COORD Coord = {CON_LEFT, CON_TOP + iStartRow};
-       FillConsoleOutputCharacter(hConsole, c, (DWORD)(CON_COLS)*
-               (DWORD)(iEndRow-iStartRow+1), Coord, &dwWritten);
-       FillConsoleOutputAttribute(hConsole, wAttributes, (DWORD)(CON_COLS)*
-               (DWORD)(CON_LINES), Coord, &dwWritten);
-}
-
-// Clear from cursor to end of screen
-void TConsole::ClearEOScreen(char c)
-{
-       DWORD dwWritten;
-       COORD Coord = {CON_LEFT, CON_TOP + CON_CUR_Y + 1};
-       FillConsoleOutputCharacter(hConsole, c, (DWORD)(CON_COLS)*
-               (DWORD)(CON_HEIGHT - CON_CUR_Y), Coord, &dwWritten);
-       FillConsoleOutputAttribute(hConsole, wAttributes, (DWORD)(CON_COLS)*
-               (DWORD)(CON_LINES - CON_CUR_Y), Coord, &dwWritten);
-       ClearEOLine();
-}
-
-// Clear from beginning of screen to cursor
-void TConsole::ClearBOScreen(char c)
-{
-       DWORD dwWritten;
-       COORD Coord = {CON_LEFT, CON_TOP};
-       FillConsoleOutputCharacter(hConsole, c, (DWORD)(CON_COLS)*
-               (DWORD)(CON_CUR_Y), Coord, &dwWritten);
-       FillConsoleOutputAttribute(hConsole, wAttributes, (DWORD)(CON_COLS)*
-               (DWORD)(CON_CUR_Y), Coord, &dwWritten);
-       ClearBOLine();
-}
-
-void TConsole::ClearLine(char c)
-{
-       DWORD dwWritten;
-       COORD Coord = {CON_LEFT, CON_TOP + CON_CUR_Y};
-       FillConsoleOutputCharacter(hConsole, c, (DWORD)(CON_COLS),
-               Coord, &dwWritten);
-       FillConsoleOutputAttribute(hConsole, wAttributes, (DWORD)(CON_COLS),
-               Coord, &dwWritten);
-       GetConsoleScreenBufferInfo(hConsole, &ConsoleInfo);
-}
-
-void TConsole::ClearEOLine(char c)
-{
-       DWORD dwWritten;
-       COORD Coord = {CON_LEFT + CON_CUR_X, CON_TOP + CON_CUR_Y};
-       FillConsoleOutputAttribute(hConsole, wAttributes,
-               (DWORD)(CON_RIGHT - CON_CUR_X) +1, Coord, &dwWritten);
-       FillConsoleOutputCharacter(hConsole, c, (DWORD)(CON_RIGHT - CON_CUR_X) +1,
-               Coord, &dwWritten);
-       GetConsoleScreenBufferInfo(hConsole, &ConsoleInfo);
-}
-
-void TConsole::ClearBOLine(char c)
-{
-       DWORD dwWritten;
-       COORD Coord = {CON_LEFT, CON_TOP + CON_CUR_Y};
-       FillConsoleOutputCharacter(hConsole, c, (DWORD)(CON_CUR_X) + 1, Coord,
-               &dwWritten);
-       FillConsoleOutputAttribute(hConsole, wAttributes, (DWORD)(CON_CUR_X) + 1,
-               Coord, &dwWritten);
-       GetConsoleScreenBufferInfo(hConsole, &ConsoleInfo);
-}
-
-
-//     Inserts blank lines to the cursor-y-position
-//     scrolls down the rest. CURSOR MOVEMENT (to Col#1) ???
-void TConsole::InsertLine(int numlines)
-{
-       COORD           to;
-       SMALL_RECT      from;
-       SMALL_RECT      clip;
-       CHAR_INFO               fill;
-       int             acty;
-       
-       // Rest of screen would be deleted
-       if ( (acty = GetCursorY()) >= CON_LINES - numlines ) {
-               ClearEOScreen();    // delete rest of screen
-               return;
-       } /* IF */
-       
-       //      Else scroll down the part of the screen which is below the
-       //      cursor.
-       from.Left =             CON_LEFT;
-       from.Top =              CON_TOP + (SHORT)acty;
-       from.Right =    CON_LEFT + (SHORT)CON_COLS;
-       from.Bottom =   CON_TOP + (SHORT)CON_LINES;
-       
-       clip = from;
-       to.X = 0;
-       to.Y = (SHORT)(from.Top + numlines);
-       
-       fill.Char.AsciiChar = ' ';
-       fill.Attributes = 7;            // WHICH ATTRIBUTES TO TAKE FOR BLANK LINE ??
-       
-       ScrollConsoleScreenBuffer(hConsole, &from, &clip, to, &fill);
-} /* InsertLine */
-
-//     Inserts blank characters under the cursor
-void TConsole::InsertCharacter(int numchar)
-{
-       int             actx;
-       SMALL_RECT      from;
-       SMALL_RECT      clip;
-       COORD                   to;
-       CHAR_INFO               fill;
-       
-       if ( (actx = GetCursorX()) >= CON_COLS - numchar ) {
-               ClearEOLine();
-               return;
-       } /* IF */
-       
-       from.Left =             CON_LEFT + (SHORT)actx;
-       from.Top =              CON_TOP + (SHORT)GetCursorY();
-       from.Right =    CON_LEFT + (SHORT)CON_COLS;
-       from.Bottom =   CON_TOP + (SHORT)from.Top;
-       
-       clip = from;
-       to.X = (SHORT)(actx + numchar);
-       to.Y = from.Top;
-       
-       fill.Char.AsciiChar = ' ';
-       fill.Attributes = wAttributes; // WHICH ATTRIBUTES TO TAKE FOR BLANK CHAR ??
-       
-       ScrollConsoleScreenBuffer(hConsole, &from, &clip, to, &fill);
-} /* InsertCharacter */
-
-// Deletes characters under the cursor
-// Note that there are cases in which all the following lines should shift by
-// a character, but we don't handle these.  This could break some
-// VT102-applications, but it shouldn't be too much of an issue.
-void TConsole::DeleteCharacter(int numchar)
-{
-       int             actx;
-       SMALL_RECT      from;
-       SMALL_RECT      clip;
-       COORD                   to;
-       CHAR_INFO               fill;
-       
-       if ( (actx = GetCursorX()) >= CON_COLS - numchar ) {
-               ClearEOLine();
-               return;
-       } /* IF */
-       
-       from.Left =             CON_LEFT + (SHORT)actx;
-       from.Top =              CON_TOP + (SHORT)GetCursorY();
-       from.Right =    CON_LEFT + (SHORT)CON_COLS;
-       from.Bottom =   CON_TOP + from.Top;
-       
-       clip = from;
-       to.X = (SHORT)(actx - numchar);
-       to.Y = from.Top;
-       
-       fill.Char.AsciiChar = ' ';
-       fill.Attributes = wAttributes; // WHICH ATTRIBUTES TO TAKE FOR BLANK CHAR ??
-       
-       ScrollConsoleScreenBuffer(hConsole, &from, &clip, to, &fill);
-} /* DeleteCharacter */
-
-void TConsole::SetRawCursorPosition(int x, int y) {
-       if (x > CON_WIDTH)  x = CON_WIDTH;
-       if (x < 0)                      x = 0;
-       if (y > CON_HEIGHT)     y = CON_HEIGHT;
-       if (y < 0)                      y = 0;
-       COORD Coord = {(short)(CON_LEFT + x), (short)(CON_TOP + y)};
-       SetConsoleCursorPosition(hConsole, Coord);
-       
-       // Update the ConsoleInfo struct (Paul Brannan 5/9/98)
-       ConsoleInfo.dwCursorPosition.Y = Coord.Y;
-       ConsoleInfo.dwCursorPosition.X = Coord.X;
-       
-       // bug fix in case we went too far (Paul Brannan 5/25/98)
-       if(ConsoleInfo.dwCursorPosition.X < CON_LEFT)
-               ConsoleInfo.dwCursorPosition.X = CON_LEFT;
-       if(ConsoleInfo.dwCursorPosition.X > CON_RIGHT)
-               ConsoleInfo.dwCursorPosition.X = CON_RIGHT;
-       if(ConsoleInfo.dwCursorPosition.Y < CON_TOP)
-               ConsoleInfo.dwCursorPosition.Y = CON_TOP;
-       if(ConsoleInfo.dwCursorPosition.Y > CON_BOTTOM)
-               ConsoleInfo.dwCursorPosition.Y = CON_BOTTOM;
-}
-
-// The new SetCursorPosition takes scroll regions into consideration
-// (Paul Brannan 6/27/98)
-void TConsole::SetCursorPosition(int x, int y) {
-       if (x > CON_WIDTH)  x = CON_WIDTH;
-       if (x < 0)                      x = 0;
-       if(iScrollEnd != -1) {
-               if(y > iScrollEnd)              y = iScrollEnd;
-       } else {
-               if(y > CON_HEIGHT)              y = CON_HEIGHT;
-       }
-       if(iScrollStart != -1) {
-               if(y < iScrollStart)    y = iScrollStart;
-       } else {
-               if(y < 0)                               y = 0;
-       }
-
-       COORD Coord = {(short)(CON_LEFT + x), (short)(CON_TOP + y)};
-       SetConsoleCursorPosition(hConsole, Coord);
-       
-       // Update the ConsoleInfo struct
-       ConsoleInfo.dwCursorPosition.Y = Coord.Y;
-       ConsoleInfo.dwCursorPosition.X = Coord.X;
-}
-
-void TConsole::MoveCursorPosition(int x, int y) {
-       SetCursorPosition(CON_CUR_X + x, CON_CUR_Y + y);
-}
-
-void TConsole::SetExtendedMode(int iFunction, BOOL bEnable)
-{
-       // Probably should do something here...
-       // Should change the screen mode, but do we need this?
-}
-
-void TConsole::SetScroll(int start, int end) {
-       iScrollStart = start;
-       iScrollEnd = end;
-}
-
-void TConsole::Beep() {
-       if(ini.get_do_beep()) {
-               if(!ini.get_speaker_beep()) printit("\a");
-               else ::Beep(400, 100);
-       }
-}
-
-void TConsole::SetCursorSize(int pct) {
-       CONSOLE_CURSOR_INFO ci = {(pct != 0)?pct:1, pct != 0};
-       SetConsoleCursorInfo(hConsole, &ci);
-}
-
-void saveScreen(CHAR_INFO *chiBuffer) {
-       HANDLE hStdout;
-       CONSOLE_SCREEN_BUFFER_INFO ConsoleInfo;
-       SMALL_RECT srctReadRect;
-       COORD coordBufSize;
-       COORD coordBufCoord;
-       
-       hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
-       GetConsoleScreenBufferInfo(hStdout, &ConsoleInfo);
-       
-    srctReadRect.Top = CON_TOP;    /* top left: row 0, col 0  */
-    srctReadRect.Left = CON_LEFT;
-    srctReadRect.Bottom = CON_BOTTOM; /* bot. right: row 1, col 79 */
-    srctReadRect.Right = CON_RIGHT;
-       
-    coordBufSize.Y = CON_BOTTOM-CON_TOP+1;
-    coordBufSize.X = CON_RIGHT-CON_LEFT+1;
-       
-    coordBufCoord.X = CON_TOP;
-    coordBufCoord.Y = CON_LEFT;
-       
-    ReadConsoleOutput(
-               hStdout,        /* screen buffer to read from       */
-               chiBuffer,      /* buffer to copy into              */
-               coordBufSize,   /* col-row size of chiBuffer        */
-               
-               coordBufCoord,  /* top left dest. cell in chiBuffer */
-               &srctReadRect); /* screen buffer source rectangle   */
-}
-
-void restoreScreen(CHAR_INFO *chiBuffer) {
-       HANDLE hStdout;
-       CONSOLE_SCREEN_BUFFER_INFO ConsoleInfo;
-       SMALL_RECT srctReadRect;
-       COORD coordBufSize;
-       COORD coordBufCoord;
-       
-       hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
-       GetConsoleScreenBufferInfo(hStdout, &ConsoleInfo);
-       
-       // restore screen
-    srctReadRect.Top = CON_TOP;    /* top left: row 0, col 0  */
-    srctReadRect.Left = CON_LEFT;
-    srctReadRect.Bottom = CON_BOTTOM; /* bot. right: row 1, col 79 */
-    srctReadRect.Right = CON_RIGHT;
-       
-    coordBufSize.Y = CON_BOTTOM-CON_TOP+1;
-    coordBufSize.X = CON_RIGHT-CON_LEFT+1;
-       
-    coordBufCoord.X = CON_TOP;
-    coordBufCoord.Y = CON_LEFT;
-    WriteConsoleOutput(
-        hStdout, /* screen buffer to write to    */
-        chiBuffer,        /* buffer to copy from          */
-        coordBufSize,     /* col-row size of chiBuffer    */
-        coordBufCoord, /* top left src cell in chiBuffer  */
-        &srctReadRect); /* dest. screen buffer rectangle */
-       // end restore screen
-    
-}
-
-CHAR_INFO* newBuffer() {
-    CONSOLE_SCREEN_BUFFER_INFO ConsoleInfo;
-    HANDLE hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
-    GetConsoleScreenBufferInfo(hStdout, &ConsoleInfo);
-    CHAR_INFO * chiBuffer;
-    chiBuffer = new CHAR_INFO[(CON_BOTTOM-CON_TOP+1)*(CON_RIGHT-CON_LEFT+1)];
-       return chiBuffer;
-}
-
-void deleteBuffer(CHAR_INFO* chiBuffer) {
-       delete[] chiBuffer;
-}
-
diff --git a/reactos/apps/utils/net/telnet/src/tconsole.h b/reactos/apps/utils/net/telnet/src/tconsole.h
deleted file mode 100644 (file)
index 81e5989..0000000
+++ /dev/null
@@ -1,172 +0,0 @@
-#ifndef __TNPARSER_H
-#define __TNPARSER_H
-
-#include "tnconfig.h"
-
-/* A diagram of the following values:
- *
- *           (0,0)
- *              +----------------------------------------+
- *              |                                        |
- *              |                                        |
- *              |                                        |
- *              |                                        |
- *              |                                        |
- *              |                                        |
- *              |                                        |
- *              |                                        |
- *              |                                        |
- *              |                                        |
- *              |                                        |
- *              |                                        |
- *              |                                        |
- *              |          CON_TOP                       |
- *              +---------------------------+.....?......|     ---
- *              |              .            |            |      |
- *              |              .            | <-- OR --> |      |
- *              |              .            |            |      |
- *  CON_LEFT    |              .            | CON_RIGHT  |
- *    (=0)      |              .            | (=CON_     |  CON_LINES
- *              |..............*            |   WIDTH)   |
- *              |            (CON_CUR_X,    |            |      |
- *              |             CON_CUR_Y)    |            |      |
- *              |                           |            |      |
- *              |                           |            |      |
- *              |                           |            |      |
- *              +---------------------------+------------+     ---
- *                   CON_BOTTOM (=CON_TOP + CON_HEIGHT)
- *
- *              |--------- CON_COLS --------|
- *
- * Keep in mind that CON_TOP, CON_BOTTOM, CON_LEFT, and CON_RIGHT are relative
- * to zero, but CON_CUR_X, CON_CUR_Y, CON_WIDTH, and CON_HEIGHT are relative to
- * CON_TOP and CON_LEFT
- */
-
-#define CON_TOP                ConsoleInfo.srWindow.Top
-#define CON_BOTTOM     ConsoleInfo.srWindow.Bottom
-
-#define CON_LEFT       0
-#define CON_RIGHT      (ConsoleInfo.dwSize.X - 1)
-
-#define CON_HEIGHT     (CON_BOTTOM - CON_TOP)
-#define CON_WIDTH      (CON_RIGHT - CON_LEFT)
-#define CON_LINES      (CON_HEIGHT + 1)
-#define CON_COLS       (CON_WIDTH + 1)
-
-#define CON_CUR_X      (ConsoleInfo.dwCursorPosition.X - CON_LEFT)
-#define CON_CUR_Y      (ConsoleInfo.dwCursorPosition.Y - CON_TOP)
-
-
-class TConsole {
-public:
-       TConsole(HANDLE hConsole);
-       ~TConsole();
-       void sync();
-
-       // Cursor movement routines
-    int GetRawCursorX() {return CON_CUR_X;}
-    int GetRawCursorY() {return CON_CUR_Y;}
-    int GetCursorX() {return CON_CUR_X;}
-    int GetCursorY() {
-               if(iScrollStart != -1)
-                       return CON_CUR_Y - iScrollStart;
-               return GetRawCursorY();
-       }
-       void SetRawCursorPosition(int x, int y);
-       void SetCursorPosition(int x, int y);
-       void SetCursorSize(int pct);
-       void MoveCursorPosition(int x, int y);
-
-       // Screen mode/size routines
-    int GetWidth() {return CON_COLS;}
-    int GetHeight() {return CON_LINES;}
-       void SetExtendedMode(int iFunction, BOOL bEnable);
-       void SetWindowSize(int width, int height);      // Set the size of the window,
-                                                                                               // but not the buffer
-
-       // Color/attribute routines
-       void SetAttrib(unsigned char wAttr) {wAttributes = wAttr;}
-    unsigned char GetAttrib() {return wAttributes;}
-    void Normal();                                                             // Reset all attributes
-    void HighVideo();                                                  // Aka "bold"
-    void LowVideo();
-    void SetForeground(unsigned char wAttrib); // Set the foreground directly
-    void SetBackground(unsigned char wAttrib);
-    void BlinkOn();                                                            // Blink on/off
-    void BlinkOff();
-       void UnderlineOn();                                                     // Underline on/off
-       void UnderlineOff();
-       void UlBlinkOn();                                                       // Blink+Underline on/off
-       void UlBlinkOff();
-    void ReverseOn();                                                  // Reverse on/off
-    void ReverseOff();
-       void Lightbg();                                                         // High-intensity background
-       void Darkbg();                                                          // Low-intensity background
-       void setDefaultFg(unsigned char u) {defaultfg = u;}
-       void setDefaultBg(unsigned char u) {defaultbg = u;}
-
-       // Text output routines
-       unsigned long WriteText(const char *pszString, unsigned long cbString);
-       unsigned long WriteString(const char* pszString, unsigned long cbString);
-       unsigned long WriteStringFast(const char *pszString, unsigned long cbString);
-       unsigned long WriteCtrlString(const char* pszString, unsigned long cbString);
-       unsigned long WriteCtrlChar(char c);
-       unsigned long NetWriteString(const char* pszString, unsigned long cbString);
-
-       // Clear screen/screen area functions
-       void ClearScreen(char c = ' ');
-       void ClearWindow(int start, int end, char c = ' ');
-       void ClearEOScreen(char c = ' ');
-       void ClearBOScreen(char c = ' ');
-       void ClearLine(char c = ' ');
-       void ClearEOLine(char c = ' ');
-       void ClearBOLine(char c = ' ');
-
-       // Scrolling and text output control functions
-       void SetScroll(int start, int end);
-    void ScrollDown(int iStartRow , int iEndRow, int bUp);
-       void ScrollAll(int bUp) {ScrollDown(iScrollStart, iScrollEnd, bUp);}
-       void index();
-       void reverse_index();
-       void setLineWrap(bool bEnabled){
-               if(!ini.get_lock_linewrap())
-                       ini.set_value("Wrap_Line", bEnabled ? "true" : "false");
-       }
-       bool getLineWrap() {return ini.get_wrapline();}
-
-    // Insert/delete characters/lines
-       void InsertLine(int numlines);                  // Added by Titus von Boxberg 30/3/97
-    void InsertCharacter(int numchar);         // "
-    void DeleteCharacter(int numchar);         // "
-       void InsertMode(int i) {insert_mode = i;}
-
-       // Miscellaneous functions
-       void Beep();
-
-protected:
-       HANDLE hConsole;
-
-       CONSOLE_SCREEN_BUFFER_INFO ConsoleInfo;
-
-       unsigned char wAttributes;
-       unsigned char fg, bg;
-       unsigned char defaultfg, defaultbg;
-       unsigned char origfg, origbg;
-
-       bool blink;
-       bool underline;
-       bool reverse;
-
-       int iScrollStart;
-       int iScrollEnd;
-       int insert_mode;
-};
-
-// Non-member functions for saving state -- used by the scrollback buffer viewer
-void saveScreen(CHAR_INFO* chiBuffer);
-void restoreScreen(CHAR_INFO* chiBuffer);
-CHAR_INFO* newBuffer();
-void deleteBuffer(CHAR_INFO* chiBuffer);
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/telnet.h b/reactos/apps/utils/net/telnet/src/telnet.h
deleted file mode 100644 (file)
index dbb2cde..0000000
+++ /dev/null
@@ -1,305 +0,0 @@
-#ifndef ___TELNET_H
-#define ___TELNET_H
-
-/*
-* Copyright (c) 1983 Regents of the University of California.
-* All rights reserved.
-*
-* Redistribution and use in source and binary forms are permitted provided
-* that: (1) source distributions retain this entire copyright notice and
-* comment, and (2) distributions including binaries display the following
-* acknowledgement:  ``This product includes software developed by the
-* University of California, Berkeley and its contributors'' in the
-* documentation or other materials provided with the distribution and in
-* all advertising materials mentioning features or use of this software.
-* Neither the name of the University nor the names of its contributors may
-* be used to endorse or promote products derived from this software without
-* specific prior written permission.
-* THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
-* WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
-* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-*
-*      @(#)telnet.h    5.12 (Berkeley) 3/5/91
-*/
-
-// This file modified 5/15/98 by Paul Brannan.
-// Added (unsigned char) to the #defines.
-// Formatted for readability.
-
-/*
-* Definitions for the TELNET protocol.
-*/
-#define        IAC             (unsigned char)255              /* interpret as command: */
-#define        DONT    (unsigned char)254              /* you are not to use option */
-#define        DO              (unsigned char)253              /* please, you use option */
-#define        WONT    (unsigned char)252              /* I won't use option */
-#define        WILL    (unsigned char)251              /* I will use option */
-#define        SB              (unsigned char)250              /* interpret as subnegotiation */
-#define        GA              (unsigned char)249              /* you may reverse the line */
-#define        EL              (unsigned char)248              /* erase the current line */
-#define        EC              (unsigned char)247              /* erase the current character */
-#define        AYT             (unsigned char)246              /* are you there */
-#define        AO              (unsigned char)245              /* abort output--but let prog finish */
-#define        IP              (unsigned char)244              /* interrupt process--permanently */
-#define        BREAK   (unsigned char)243              /* break */
-#define        DM              (unsigned char)242              /* data mark--for connect. cleaning */
-#define        NOP             (unsigned char)241              /* nop */
-#define        SE              (unsigned char)240              /* end sub negotiation */
-#define EOR     (unsigned char)239             /* end of record (transparent mode) */
-#define        ABORT   (unsigned char)238              /* Abort process */
-#define        SUSP    (unsigned char)237              /* Suspend process */
-#define        xEOF    (unsigned char)236              /* End of file: EOF is already used... */
-
-#define SYNCH  (unsigned char)242              /* for telfunc calls */
-
-#ifdef TELCMDS
-char *telcmds[] = {
-       "EOF", "SUSP", "ABORT", "EOR",
-               "SE", "NOP", "DMARK", "BRK", "IP", "AO", "AYT", "EC",
-               "EL", "GA", "SB", "WILL", "WONT", "DO", "DONT", "IAC", 0,
-};
-#else
-extern char *telcmds[];
-#endif
-
-#define        TELCMD_FIRST            xEOF
-#define        TELCMD_LAST                     IAC
-#define        TELCMD_OK(x)            ((x) <= TELCMD_LAST && (x) >= TELCMD_FIRST)
-#define        TELCMD(x)                       telcmds[(x)-TELCMD_FIRST]
-
-/* telnet options */
-#define TELOPT_BINARY                  (unsigned char)0        /* 8-bit data path */
-#define TELOPT_ECHO                            (unsigned char)1        /* echo */
-#define        TELOPT_RCP                              (unsigned char)2        /* prepare to reconnect */
-#define        TELOPT_SGA                              (unsigned char)3        /* suppress go ahead */
-#define        TELOPT_NAMS                             (unsigned char)4        /* approximate message size */
-#define        TELOPT_STATUS                   (unsigned char)5        /* give status */
-#define        TELOPT_TM                               (unsigned char)6        /* timing mark */
-#define        TELOPT_RCTE                             (unsigned char)7        /* remote controlled transmission and echo */
-#define TELOPT_NAOL                            (unsigned char)8        /* negotiate about output line width */
-#define TELOPT_NAOP                            (unsigned char)9        /* negotiate about output page size */
-#define TELOPT_NAOCRD                  (unsigned char)10       /* negotiate about CR disposition */
-#define TELOPT_NAOHTS                  (unsigned char)11       /* negotiate about horizontal tabstops */
-#define TELOPT_NAOHTD                  (unsigned char)12       /* negotiate about horizontal tab disposition */
-#define TELOPT_NAOFFD                  (unsigned char)13       /* negotiate about formfeed disposition */
-#define TELOPT_NAOVTS                  (unsigned char)14       /* negotiate about vertical tab stops */
-#define TELOPT_NAOVTD                  (unsigned char)15       /* negotiate about vertical tab disposition */
-#define TELOPT_NAOLFD                  (unsigned char)16       /* negotiate about output LF disposition */
-#define TELOPT_XASCII                  (unsigned char)17       /* extended ascic character set */
-#define        TELOPT_LOGOUT                   (unsigned char)18       /* force logout */
-#define        TELOPT_BM                               (unsigned char)19       /* byte macro */
-#define        TELOPT_DET                              (unsigned char)20       /* data entry terminal */
-#define        TELOPT_SUPDUP                   (unsigned char)21       /* supdup protocol */
-#define        TELOPT_SUPDUPOUTPUT             (unsigned char)22       /* supdup output */
-#define        TELOPT_SNDLOC                   (unsigned char)23       /* send location */
-#define        TELOPT_TTYPE                    (unsigned char)24       /* terminal type */
-#define        TELOPT_EOR                              (unsigned char)25       /* end or record */
-#define        TELOPT_TUID                             (unsigned char)26       /* TACACS user identification */
-#define        TELOPT_OUTMRK                   (unsigned char)27       /* output marking */
-#define        TELOPT_TTYLOC                   (unsigned char)28       /* terminal location number */
-#define        TELOPT_3270REGIME               (unsigned char)29       /* 3270 regime */
-#define        TELOPT_X3PAD                    (unsigned char)30       /* X.3 PAD */
-#define        TELOPT_NAWS                             (unsigned char)31       /* window size */
-#define        TELOPT_TSPEED                   (unsigned char)32       /* terminal speed */
-#define        TELOPT_LFLOW                    (unsigned char)33       /* remote flow control */
-#define TELOPT_LINEMODE                        (unsigned char)34       /* Linemode option */
-#define TELOPT_XDISPLOC                        (unsigned char)35       /* X Display Location */
-#define TELOPT_ENVIRON                 (unsigned char)36       /* Environment variables */
-#define        TELOPT_AUTHENTICATION   (unsigned char)37       /* Authenticate */
-#define        TELOPT_ENCRYPT                  (unsigned char)38       /* Encryption option */
-#define        TELOPT_EXOPL                    (unsigned char)255      /* extended-options-list */
-
-
-#define        NTELOPTS        (1+TELOPT_ENCRYPT)
-#ifdef TELOPTS
-char *telopts[NTELOPTS+1] = {
-       "BINARY", "ECHO", "RCP", "SUPPRESS GO AHEAD", "NAME",
-               "STATUS", "TIMING MARK", "RCTE", "NAOL", "NAOP",
-               "NAOCRD", "NAOHTS", "NAOHTD", "NAOFFD", "NAOVTS",
-               "NAOVTD", "NAOLFD", "EXTEND ASCII", "LOGOUT", "BYTE MACRO",
-               "DATA ENTRY TERMINAL", "SUPDUP", "SUPDUP OUTPUT",
-               "SEND LOCATION", "TERMINAL TYPE", "END OF RECORD",
-               "TACACS UID", "OUTPUT MARKING", "TTYLOC",
-               "3270 REGIME", "X.3 PAD", "NAWS", "TSPEED", "LFLOW",
-               "LINEMODE", "XDISPLOC", "ENVIRON", "AUTHENTICATION",
-               "ENCRYPT",
-               0,
-};
-#define        TELOPT_FIRST    TELOPT_BINARY
-#define        TELOPT_LAST     TELOPT_ENCRYPT
-#define        TELOPT_OK(x)    ((x) <= TELOPT_LAST && (x) >= TELOPT_FIRST)
-#define        TELOPT(x)       telopts[(x)-TELOPT_FIRST]
-#endif
-
-/* sub-option qualifiers */
-#define        TELQUAL_IS              (unsigned char)0        /* option is... */
-#define        TELQUAL_SEND    (unsigned char)1        /* send option */
-#define        TELQUAL_INFO    (unsigned char)2        /* ENVIRON: informational version of IS */
-#define        TELQUAL_REPLY   (unsigned char)2        /* AUTHENTICATION: client version of IS */
-#define        TELQUAL_NAME    (unsigned char)3        /* AUTHENTICATION: client version of IS */
-
-/*
-* LINEMODE suboptions
-*/
-
-#define        LM_MODE         1
-#define        LM_FORWARDMASK  2
-#define        LM_SLC          3
-
-#define        MODE_EDIT       0x01
-#define        MODE_TRAPSIG    0x02
-#define        MODE_ACK        0x04
-#define MODE_SOFT_TAB  0x08
-#define MODE_LIT_ECHO  0x10
-
-#define        MODE_MASK       0x1f
-
-/* Not part of protocol, but needed to simplify things... */
-#define MODE_FLOW              0x0100
-#define MODE_ECHO              0x0200
-#define MODE_INBIN             0x0400
-#define MODE_OUTBIN            0x0800
-#define MODE_FORCE             0x1000
-
-#define        SLC_SYNCH       1
-#define        SLC_BRK         2
-#define        SLC_IP          3
-#define        SLC_AO          4
-#define        SLC_AYT         5
-#define        SLC_EOR         6
-#define        SLC_ABORT       7
-#define        SLC_EOF         8
-#define        SLC_SUSP        9
-#define        SLC_EC          10
-#define        SLC_EL          11
-#define        SLC_EW          12
-#define        SLC_RP          13
-#define        SLC_LNEXT       14
-#define        SLC_XON         15
-#define        SLC_XOFF        16
-#define        SLC_FORW1       17
-#define        SLC_FORW2       18
-
-#define        NSLC            18
-
-/*
-* For backwards compatability, we define SLC_NAMES to be the
-* list of names if SLC_NAMES is not defined.
-*/
-#define        SLC_NAMELIST    "0", "SYNCH", "BRK", "IP", "AO", "AYT", "EOR", \
-       "ABORT", "EOF", "SUSP", "EC", "EL", "EW", "RP", \
-"LNEXT", "XON", "XOFF", "FORW1", "FORW2", 0,
-#ifdef SLC_NAMES
-//char *slc_names[] = {
-//     SLC_NAMELIST
-//};
-#else
-extern char *slc_names[];
-#define        SLC_NAMES SLC_NAMELIST
-#endif
-
-#define        SLC_NAME_OK(x)  ((x) >= 0 && (x) < NSLC)
-#define SLC_NAME(x)    slc_names[x]
-
-#define        SLC_NOSUPPORT   0
-#define        SLC_CANTCHANGE  1
-#define        SLC_VARIABLE    2
-#define        SLC_DEFAULT     3
-#define        SLC_LEVELBITS   0x03
-
-#define        SLC_FUNC        0
-#define        SLC_FLAGS       1
-#define        SLC_VALUE       2
-
-#define        SLC_ACK         0x80
-#define        SLC_FLUSHIN     0x40
-#define        SLC_FLUSHOUT    0x20
-
-#define        ENV_VALUE       0
-#define        ENV_VAR         1
-#define        ENV_ESC         2
-
-/*
-* AUTHENTICATION suboptions
-*/
-
-/*
-* Who is authenticating who ...
-*/
-#define        AUTH_WHO_CLIENT         0       /* Client authenticating server */
-#define        AUTH_WHO_SERVER         1       /* Server authenticating client */
-#define        AUTH_WHO_MASK           1
-
-/*
-* amount of authentication done
-*/
-#define        AUTH_HOW_ONE_WAY        0
-#define        AUTH_HOW_MUTUAL         2
-#define        AUTH_HOW_MASK           2
-
-#define        AUTHTYPE_NULL           0
-#define        AUTHTYPE_KERBEROS_V4    1
-#define        AUTHTYPE_KERBEROS_V5    2
-#define        AUTHTYPE_SPX            3
-#define        AUTHTYPE_MINK           4
-#define        AUTHTYPE_CNT            5
-
-#define        AUTHTYPE_TEST           99
-
-#ifdef AUTH_NAMES
-char *authtype_names[] = {
-       "NULL", "KERBEROS_V4", "KERBEROS_V5", "SPX", "MINK", 0,
-};
-#else
-extern char *authtype_names[];
-#endif
-
-#define        AUTHTYPE_NAME_OK(x)     ((x) >= 0 && (x) < AUTHTYPE_CNT)
-#define        AUTHTYPE_NAME(x)        authtype_names[x]
-
-/*
-* ENCRYPTion suboptions
-*/
-#define        ENCRYPT_IS              0       /* I pick encryption type ... */
-#define        ENCRYPT_SUPPORT         1       /* I support encryption types ... */
-#define        ENCRYPT_REPLY           2       /* Initial setup response */
-#define        ENCRYPT_START           3       /* Am starting to send encrypted */
-#define        ENCRYPT_END             4       /* Am ending encrypted */
-#define        ENCRYPT_REQSTART        5       /* Request you start encrypting */
-#define        ENCRYPT_REQEND          6       /* Request you send encrypting */
-#define        ENCRYPT_ENC_KEYID       7
-#define        ENCRYPT_DEC_KEYID       8
-#define        ENCRYPT_CNT             9
-
-#define        ENCTYPE_ANY             0
-#define        ENCTYPE_DES_CFB64       1
-#define        ENCTYPE_DES_OFB64       2
-#define        ENCTYPE_CNT             3
-
-#ifdef ENCRYPT_NAMES
-char *encrypt_names[] = {
-       "IS", "SUPPORT", "REPLY", "START", "END",
-               "REQUEST-START", "REQUEST-END", "ENC-KEYID", "DEC-KEYID",
-               0,
-};
-char *enctype_names[] = {
-       "ANY", "DES_CFB64",  "DES_OFB64",  0,
-};
-#else
-extern char *encrypt_names[];
-extern char *enctype_names[];
-#endif
-
-
-#define        ENCRYPT_NAME_OK(x)      ((x) >= 0 && (x) < ENCRYPT_CNT)
-#define        ENCRYPT_NAME(x)         encrypt_names[x]
-
-#define        ENCTYPE_NAME_OK(x)      ((x) >= 0 && (x) < ENCTYPE_CNT)
-#define        ENCTYPE_NAME(x)         enctype_names[x]
-//////////////////////////////////////////////////////
-//////////////////////////////////////////////////////
-
-
-
-#endif
-
diff --git a/reactos/apps/utils/net/telnet/src/tkeydef.cpp b/reactos/apps/utils/net/telnet/src/tkeydef.cpp
deleted file mode 100644 (file)
index e180327..0000000
+++ /dev/null
@@ -1,136 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-/////////////////////////////////////////////////////////
-//     Class TkeyDef - Key Definitions                 //
-//                   - kept in an array container      //
-//     originally part of KeyTrans.cpp                 //
-/////////////////////////////////////////////////////////
-
-#include "tkeydef.h"
-#include <string.h>
-
-// This class did not properly release memory before, and a buffer overrun
-// was apparent in operator=(char*).  Fixed.  (Paul Brannan Feb. 4, 1999)
-
-TKeyDef::TKeyDef() {
-       uKeyDef.szKeyDef = 0;
-       vk_code = dwState = 0;
-}
-
-TKeyDef::TKeyDef(char *def, DWORD state, DWORD code) {
-       uKeyDef.szKeyDef = 0;
-       if (def != NULL && *def != 0) {
-               // szKeyDef = (char *) GlobalAlloc(GPTR, strlen(def) +1);
-               uKeyDef.szKeyDef = new char[strlen(def)+1];
-               strcpy(uKeyDef.szKeyDef, def);
-       }
-       dwState = state;
-       vk_code = code;
-}
-
-TKeyDef::TKeyDef(optype op, DWORD state, DWORD code) {
-       uKeyDef.op = new optype;
-       uKeyDef.op->sendstr = 0;
-       uKeyDef.op->the_op = op.the_op;
-       dwState = state;
-       vk_code = code;
-}
-
-TKeyDef::TKeyDef(const TKeyDef &t) {
-       if(t.uKeyDef.szKeyDef == NULL) {
-               uKeyDef.szKeyDef = (char *)NULL;
-       } else if(t.uKeyDef.op->sendstr == 0) {
-               uKeyDef.op = new optype;
-               uKeyDef.op->sendstr = 0;
-               uKeyDef.op->the_op = t.uKeyDef.op->the_op;
-       } else {
-               uKeyDef.szKeyDef = new char[strlen(t.uKeyDef.szKeyDef)+1];
-               strcpy(uKeyDef.szKeyDef, t.uKeyDef.szKeyDef);
-       }
-       dwState = t.dwState;
-       vk_code = t.vk_code;
-}
-
-TKeyDef::~TKeyDef() {
-       if(uKeyDef.szKeyDef) delete[] uKeyDef.szKeyDef;
-}
-
-char * TKeyDef::operator=(char *def) {
-       if(def != NULL && *def != 0) {
-               if(uKeyDef.szKeyDef) delete[] uKeyDef.szKeyDef;
-               uKeyDef.szKeyDef = new char[strlen(def)+1];
-               strcpy(uKeyDef.szKeyDef, def);
-       }
-       return uKeyDef.szKeyDef;
-}
-
-DWORD TKeyDef::operator=(DWORD code) {
-       return vk_code = code;
-}
-
-TKeyDef& TKeyDef::operator=(const TKeyDef &t) {
-       if(t.uKeyDef.szKeyDef) {
-               if(uKeyDef.szKeyDef) delete[] uKeyDef.szKeyDef;
-               if(t.uKeyDef.op->sendstr) {
-                       uKeyDef.szKeyDef = new char[strlen(t.uKeyDef.szKeyDef)+1];
-                       strcpy(uKeyDef.szKeyDef, t.uKeyDef.szKeyDef);
-               } else {
-                       uKeyDef.op = new optype;
-                       uKeyDef.op->sendstr = 0;
-                       uKeyDef.op->the_op = t.uKeyDef.op->the_op;
-               }
-       } else {
-               uKeyDef.szKeyDef = (char *)NULL;
-       }
-       dwState = t.dwState;
-       vk_code = t.vk_code;
-       return *this;
-}
-
-const optype& TKeyDef::operator=(optype op) {
-       uKeyDef.op = new optype;
-       uKeyDef.op->sendstr = 0;
-       uKeyDef.op->the_op = op.the_op;
-       return *uKeyDef.op;
-}
-
-// STL requires that operators be friends rather than member functions
-// (Paul Brannan 5/25/98)
-#ifndef __BORLANDC__
-bool operator==(const TKeyDef & t1, const TKeyDef & t2) {
-       return ((t1.vk_code == t2.vk_code) && (t1.dwState == t2.dwState));
-}
-// We need this function for compatibility with STL (Paul Brannan 5/25/98)
-bool operator< (const TKeyDef& t1, const TKeyDef& t2) {
-       if (t1.vk_code == t2.vk_code) return t1.dwState < t2.dwState;
-       return t1.vk_code < t2.vk_code;
-}
-#else
-int   TKeyDef::operator==(TKeyDef & t) {
-       return ((vk_code == t.vk_code) && (dwState == t.dwState));
-}
-#endif
-
diff --git a/reactos/apps/utils/net/telnet/src/tkeydef.h b/reactos/apps/utils/net/telnet/src/tkeydef.h
deleted file mode 100644 (file)
index c44a5bc..0000000
+++ /dev/null
@@ -1,71 +0,0 @@
-/////////////////////////////////////////////////////////
-//                      TkeyDef - Key Definitions class           //
-//                   - keeped in an array container    //
-/////////////////////////////////////////////////////////
-
-#ifndef __TKEYDEF_H
-#define __TKEYDEF_H
-
-#include <windows.h>
-
-#ifndef __BORLANDC__ // Ioannou Dec. 8, 1998
-// We need these for MSVC6 (Sam Robertson Oct. 8, 1998)
-class TKeyDef;
-bool operator==(const TKeyDef &t1, const TKeyDef &t2);
-bool operator<(const TKeyDef &t1, const TKeyDef &t2);
-////
-#endif
-
-// Paul Brannan Feb. 5, 1999
-enum tn_ops {TN_ESCAPE, TN_SCROLLBACK, TN_DIAL, TN_PASTE, TN_NULL, TN_CR, TN_CRLF};
-
-typedef struct {
-       char sendstr;
-       tn_ops the_op;
-} optype;
-
-union KeyDefType {
-       char *szKeyDef;
-       optype *op;
-};
-
-union KeyDefType_const {
-       const char *szKeyDef;
-       const optype *op;
-};
-
-class TKeyDef {
-private:
-       KeyDefType      uKeyDef;
-       DWORD           vk_code;
-       DWORD           dwState;
-
-public:
-       TKeyDef();
-       TKeyDef(char *def, DWORD state, DWORD code);
-       TKeyDef(optype op, DWORD state, DWORD code);
-       TKeyDef(const TKeyDef &t);
-
-       char *operator=(char *def);
-       DWORD  operator=(DWORD code);
-       TKeyDef& operator=(const TKeyDef &t);
-       const optype& operator=(optype op);
-
-       ~TKeyDef();
-
-#ifdef __BORLANDC__
-       int operator==(TKeyDef &t);
-#else
-       // made these into friends for compatibility with stl
-       // (Paul Brannan 5/7/98)
-       friend bool operator==(const TKeyDef &t1, const TKeyDef &t2);
-       friend bool operator<(const TKeyDef &t1, const TKeyDef &t2);
-#endif
-
-       const char *GetszKey() { return uKeyDef.szKeyDef; }
-       const KeyDefType GetKeyDef() { return uKeyDef; }
-       DWORD GetCodeKey() { return vk_code; }
-
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tkeymap.cpp b/reactos/apps/utils/net/telnet/src/tkeymap.cpp
deleted file mode 100644 (file)
index e1730f5..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-/////////////////////////////////////////////////////////
-//     Class TkeyMap - Key Mappings                    //
-//                   - kept in an array container      //
-//     originally part of KeyTrans.cpp                 //
-/////////////////////////////////////////////////////////
-
-#include "tkeymap.h"
-
-KeyMap::KeyMap(DWORD state, DWORD code): map(0,0,sizeof(TKeyDef)),
-                                         key(NULL,state,code) {};
-
-KeyMap::KeyMap(TKeyDef&tk):map(0,0,sizeof(TKeyDef)){
-  key = tk;
-};
-KeyMap::KeyMap(TKeyDef&tk, string& t):map(0,0,sizeof(TKeyDef)), orig(t){
-  key = tk;
-};
-
-int KeyMap::operator==(const KeyMap & t) const{
-    return key == t.key;
-};
-
-KeyMap& KeyMap::operator = (const KeyMap& t){
-     key = t.key;
-     map = t.map;
-     orig = t.orig;
-     return (*this);
-};
-
-#ifndef __BORLANDC__
-bool operator<(const KeyMap &t1, const KeyMap &t2) {
-       return t1.key < t2.key;
-}
-#endif
-
-KeyMap::~KeyMap() {
-};
diff --git a/reactos/apps/utils/net/telnet/src/tkeymap.h b/reactos/apps/utils/net/telnet/src/tkeymap.h
deleted file mode 100644 (file)
index 01258fe..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-#ifndef __TKEYMAP_H
-#define __TKEYMAP_H
-
-#ifdef __BORLANDC__
-#include <classlib\arrays.h>
-#else
-#include <string>
-#include "stl_bids.h"
-#endif
-
-#include "tkeydef.h"
-
-//AVS
-typedef TArrayAsVector<TKeyDef> keyArray;
-
-//AVS
-// representation of keymap
-struct KeyMap {
-       keyArray  map;                                          // keymap
-       string    orig;                                         // original string from .cfg file
-       TKeyDef   key;                                          // 'switch to' key
-
-       KeyMap(DWORD state, DWORD code);
-       KeyMap(): map(0,0,sizeof(TKeyDef)){};
-       KeyMap(TKeyDef&tk);
-       KeyMap(TKeyDef&tk, string&);
-       KeyMap(const string&t): map(0,0,sizeof(TKeyDef)), orig(t) {};
-       int   operator==(const KeyMap & t) const;
-          KeyMap& operator = (const KeyMap& t);
-
-#ifndef __BORLANDC__
-          // The STL needs this (Paul Brannan 5/25/98)
-          friend bool operator<(const KeyMap &t1, const KeyMap &t2);
-#endif
-
-       ~KeyMap();
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tmapldr.cpp b/reactos/apps/utils/net/telnet/src/tmapldr.cpp
deleted file mode 100644 (file)
index de41cbb..0000000
+++ /dev/null
@@ -1,773 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-/////////////////////////////////////////////////////////
-//     Class TMapLoader - Key/Character Mappings       //
-//                      - Loads from telnet.cfg        //
-//     originally part of KeyTrans.cpp                 //
-/////////////////////////////////////////////////////////
-
-#ifdef __BORLANDC__
-#include <fstream.h>
-#else
-#include <string>
-#include <fstream>
-#endif
-
-#include "tmapldr.h"
-#include "tnerror.h"
-#include "tnconfig.h"
-
-// It's probably a good idea to turn off the "identifier was truncated" warning
-// in MSVC (Paul Brannan 5/25/98)
-#ifdef _MSC_VER
-#pragma warning(disable: 4786)
-#endif
-
-// AVS
-// skip inline comments, empty lines
-static char * getline(istream& i, char* buf, int size){
-       
-       int len = 0;
-       
-       while (1) {
-               memset(buf,0,size);
-               if (i.eof()) break;
-               i.getline(buf,size,'\n');
-               
-               while (buf[len]) {
-                       if ( /*(buf[len]>=0) &&*/ buf[len]< ' ' ) buf[len] = ' ';
-                       len++;
-               };
-               len = 0;
-               
-               // not so fast, but work ;)
-               while ( buf[len] ) {
-            if ( (buf[len] == ' ') && (buf[len+1] == ' ')) {
-                               memmove(buf+len, buf+len+1, strlen(buf+len));
-            } else len++;
-               };
-               
-               if (buf[0] == ' ') memmove(buf, buf+1, size-1);
-               
-               // empty or comment
-               if ((buf[0]==0)||(buf[0]==';')) continue;
-               
-               len = 0; // look for comment like this one
-               while (buf[len])
-                       if ((buf[len] == '/') && (buf[len+1] == '/')) buf[len] = 0;
-                       else len++;
-                       
-                       if (len && (buf[len-1] == ' ')) {
-                len--;
-                buf[len]=0;
-                       };
-                       // in case for comment like this one (in line just a comment)
-                       if (buf[0]==0) continue;
-                       
-                       break;
-       };
-       return (buf);
-};
-
-//AVS
-// use string as FIFO queue for lines
-static int getline(string&str, char* buf, size_t sz) {
-       
-       if ( !str.length() ) return 0;
-       const char * p = strchr(str.c_str(),'\n');
-       unsigned int len; // Changed to unsigned (Paul Brannan 6/23/98)
-       if ( p==NULL )
-               len = str.length();
-       else
-               len = p - str.c_str();
-       
-       len = len<sz?len:sz-1;
-       
-       strncpy(buf,str.c_str(), len);
-       buf[len]=0;
-       // DJGPP also uses erase rather than remove (Paul Brannan 6/23/98)
-#ifndef __BORLANDC__
-       str.erase(0, len + 1);
-#else
-       str.remove(0,len+1);
-#endif
-       return 1;
-};
-
-//AVS
-// parse \nnn and \Xhh
-static int getbyte(const char*str) {
-       unsigned char retval = 0;
-       int base = 10;
-       int readed = 0;
-       
-       if ( (*str == 'x') || (*str == 'X') ) {
-               base = 16;
-               readed++;
-       };
-       
-       while (readed != 3 && str[readed]) {
-               unsigned char ch = toupper(str[readed]);
-               if ( isdigit(ch) ) {
-                       retval = retval*base + (ch -'0');
-               } else if (base == 16 && ch >= 'A' && ch <= 'F') {
-                       retval = retval*base + (ch-'A'+10);
-               } else {
-                       return -1;
-               };
-               readed++;
-       };
-       // Ioannou: If we discard the 0x00 we can't undefine a key !!!
-       //  if ( retval == 0 ) {
-       //     return -1;
-       //  };
-       return retval;
-};
-
-//AVS
-// a little optimization
-DWORD Fix_ControlKeyState(char * Next_Token) {
-       if (stricmp(Next_Token, "RIGHT_ALT" ) == 0) return RIGHT_ALT_PRESSED;
-       if (stricmp(Next_Token, "LEFT_ALT"  ) == 0) return LEFT_ALT_PRESSED;
-       if (stricmp(Next_Token, "RIGHT_CTRL") == 0) return RIGHT_CTRL_PRESSED;
-       if (stricmp(Next_Token, "LEFT_CTRL" ) == 0) return LEFT_CTRL_PRESSED;
-       if (stricmp(Next_Token, "SHIFT"     ) == 0) return SHIFT_PRESSED;
-       if (stricmp(Next_Token, "NUMLOCK"   ) == 0) return NUMLOCK_ON;
-       if (stricmp(Next_Token, "SCROLLLOCK") == 0) return SCROLLLOCK_ON;
-       if (stricmp(Next_Token, "CAPSLOCK"  ) == 0) return CAPSLOCK_ON;
-       if (stricmp(Next_Token, "ENHANCED"  ) == 0) return ENHANCED_KEY;
-       
-       // Paul Brannan 5/27/98
-       if (stricmp(Next_Token, "APP_KEY"   ) == 0) return APP_KEY;
-       // Paul Brannan 6/28/98
-       if (stricmp(Next_Token, "APP2_KEY"  ) == 0) return APP2_KEY;
-       // Paul Brannan 8/28/98
-       if (stricmp(Next_Token, "APP3_KEY"  ) == 0) return APP3_KEY;
-       // Paul Brannan 12/9/98
-       if (stricmp(Next_Token, "APP4_KEY"  ) == 0) return APP4_KEY;
-       
-       return 0;
-}
-
-
-// AVS
-// rewrited to suppert \xhh notation, a little optimized
-char* Fix_Tok(char * tok) {
-       static char s[256];
-       int i,j,n;
-       
-       // setmem is nonstandard; memset is standard (Paul Brannan 5/25/98)
-       memset(s, 0, 256);
-       //  setmem(s, 256, 0);
-       i = j = n = 0;
-       if ( tok != NULL ) {
-               for ( ; tok[i] != 0; ) {
-                       switch ( tok[i] ) {
-                       case '\\' :
-                               switch ( tok[i+1] ) {
-                               case '\\':
-                                       s[j++] = '\\';
-                                       i += 2;
-                                       break;
-                               default:
-                                       n = getbyte(tok+i+1);
-                                       if ( n < 0 )
-                                               s[j++] = tok[i++];
-                                       else {
-                                               s[j++]=n;
-                                               i += 4;
-                                       } ;
-                                       break;
-                               };
-                               break;
-                               case '^' :
-                    if ( tok[i+1] >= '@' ) {
-                                               s[j++] = tok[i+1] - '@';
-                                               i += 2;
-                                               break;
-                    }
-                               default  :
-                    s[j++] = tok[i++];
-                       }
-               }
-       }
-       return s;
-};
-
-// AVS
-// perform 'normalization' for lines like [some text], and some checks
-// maybe it will be done faster - but no time for it
-int normalizeSplitter(string& buf) {
-    if ( buf.length() <= 2 ) return 0;
-    if ( buf[0] == '[' && buf[buf.length()-1] == ']' ) {
-               while ( buf[1] == ' ' )
-                       // DJGPP also uses erase rather than remove (Paul Brannan 6/23/98)
-#ifndef __BORLANDC__
-                       buf.erase(1, 1);
-#else
-                       buf.remove(1,1);
-#endif
-               while ( buf[buf.length()-2] == ' ' )
-                       // Paul Brannan 6/23/98
-#ifndef __BORLANDC__
-                       buf.erase(buf.length()-2,1);
-#else
-                       buf.remove(buf.length()-2,1);
-#endif
-               return 1;
-    }
-    return 0;
-};
-
-// AVS
-// looking for part in string array, see Load(..) for more info
-int TMapLoader::LookForPart(stringArray& sa, const char* partType, const char* partName) {
-    if ( !sa.IsEmpty() ) {
-               string cmpbuf("[");
-               cmpbuf += partType;
-               cmpbuf += " ";
-               cmpbuf += partName;
-               cmpbuf += "]";
-               normalizeSplitter(cmpbuf); // if no parttype, [global] for example
-               int max = sa.GetItemsInContainer();
-               for ( int i = 0; i<max; i++ )
-                       // I found some strange behavior if strnicmp was used here
-            if (strnicmp(cmpbuf.c_str(),sa[i].c_str(),cmpbuf.length()) == 0)
-                               return i;
-    };
-    return INT_MAX;
-};
-
-// AVS
-// load globals to 'globals'
-// in buf must be a [global] part of input file
-int TMapLoader::LoadGlobal(string& buf) {
-       
-       char wbuf[128];
-       while ( buf.length() ) {
-               wbuf[0]=0;
-               if (!getline(buf,wbuf,sizeof(wbuf))) break;
-               if ( wbuf[0]==0 ) break;
-               char* Name = strtok(wbuf, TOKEN_DELIMITERS);
-               if ( stricmp(Name, "[global]")==0 ) continue;
-               
-               char* Value = strtok(NULL, TOKEN_DELIMITERS);
-               if ( Value == NULL ) {
-                       //              cerr << "[global] -> no value for " << Name << endl;
-                       printm(0, FALSE, MSG_KEYNOVAL, Name);
-                       continue;
-               };
-               int val = atoi(Value);
-               if ( val > 0 && val <= 0xff ) {
-                       if ( !KeyTrans.AddGlobalDef(val, Name)) return 0;
-               }
-               else {
-                       //             cerr << "[global] -> bad value for " << Name << endl;
-                       printm(0, FALSE, MSG_KEYBADVAL, Name);
-                       continue;
-               };
-       };
-       return 1;
-};
-
-// AVS
-// perform parsing of strings like 'VK_CODE shifts text'
-// returns text on success
-char* TMapLoader::ParseKeyDef(const char* buf, WORD& vk_code, DWORD& control) {
-       char wbuf[256];
-       strcpy(wbuf,buf);
-       char* ptr = strtok(wbuf, TOKEN_DELIMITERS);
-       if ( ptr == NULL ) return NULL;
-       
-       int i = KeyTrans.LookOnGlobal(ptr);
-       if ( i == INT_MAX ) return NULL;
-       
-       vk_code = KeyTrans.GetGlobalCode(i);
-       
-       control = 0;
-       DWORD st;
-       while (1) {
-               ptr = strtok(NULL, TOKEN_DELIMITERS);
-               if ((ptr == NULL) || ((st = Fix_ControlKeyState(ptr)) == 0)) break;
-               control |= st;
-       };
-       
-       if ( ptr == NULL ) return NULL;
-       
-       return Fix_Tok(ptr);
-};
-
-// AVS
-// load keymap to current map
-// be aware - buf must passed by value, its destroyed
-int TMapLoader::LoadKeyMap(string buf) {
-       
-       char wbuf[128];
-       WORD vk_code;
-       DWORD control;
-       int i;
-
-       // Paul Brannan Feb. 22, 1999
-       strcpy(wbuf, "VK_");
-       wbuf[4] = 0;
-       wbuf[3] = ini.get_escape_key();
-       i = KeyTrans.LookOnGlobal(wbuf);
-       if (i != INT_MAX) {
-               KeyTrans.AddKeyDef(KeyTrans.GetGlobalCode(i), RIGHT_ALT_PRESSED, TN_ESCAPE);
-               KeyTrans.AddKeyDef(KeyTrans.GetGlobalCode(i), LEFT_ALT_PRESSED, TN_ESCAPE);
-       }
-       wbuf[3] = ini.get_scrollback_key();
-       i = KeyTrans.LookOnGlobal(wbuf);
-       if (i != INT_MAX) {
-               KeyTrans.AddKeyDef(KeyTrans.GetGlobalCode(i), RIGHT_ALT_PRESSED, TN_SCROLLBACK);
-               KeyTrans.AddKeyDef(KeyTrans.GetGlobalCode(i), LEFT_ALT_PRESSED, TN_SCROLLBACK);
-       }
-       wbuf[3] = ini.get_dial_key();
-       i = KeyTrans.LookOnGlobal(wbuf);
-       if (i != INT_MAX) {
-               KeyTrans.AddKeyDef(KeyTrans.GetGlobalCode(i), RIGHT_ALT_PRESSED, TN_DIAL);
-               KeyTrans.AddKeyDef(KeyTrans.GetGlobalCode(i), LEFT_ALT_PRESSED, TN_DIAL);
-       }
-       KeyTrans.AddKeyDef(VK_INSERT, SHIFT_PRESSED, TN_PASTE);
-
-       while ( buf.length() ) {
-               wbuf[0] = 0;
-               if (!getline(buf,wbuf,sizeof(wbuf))) break;
-               if ( wbuf[0]==0 ) break;
-               if ( strnicmp(wbuf,"[keymap",7)==0 ) continue;
-               
-               char * keydef = ParseKeyDef(wbuf,vk_code,control);
-
-               if ( keydef != NULL ) {
-
-                       // Check to see if keydef is a "special" code (Paul Brannan 3/29/00)
-                       if(!strnicmp(keydef, "\\tn_escape", strlen("\\tn_escape"))) {
-                               if(!KeyTrans.AddKeyDef(vk_code, control, TN_ESCAPE)) return 0;
-                       } else if(!strnicmp(keydef, "\\tn_scrollback", strlen("\\tn_scrollback"))) {
-                               if(!KeyTrans.AddKeyDef(vk_code, control, TN_SCROLLBACK)) return 0;
-                       } else if(!strnicmp(keydef, "\\tn_dial", strlen("\\tn_dial"))) {
-                               if(!KeyTrans.AddKeyDef(vk_code, control, TN_DIAL)) return 0;
-                       } else if(!strnicmp(keydef, "\\tn_paste", strlen("\\tn_paste"))) {
-                               if(!KeyTrans.AddKeyDef(vk_code, control, TN_PASTE)) return 0;
-                       } else if(!strnicmp(keydef, "\\tn_null", strlen("\\tn_null"))) {
-                               if(!KeyTrans.AddKeyDef(vk_code, control, TN_NULL)) return 0;
-                       } else if(!strnicmp(keydef, "\\tn_cr", strlen("\\tn_cr"))) {
-                               if(!KeyTrans.AddKeyDef(vk_code, control, TN_CR)) return 0;
-                       } else if(!strnicmp(keydef, "\\tn_crlf", strlen("\\tn_crlf"))) {
-                               if(!KeyTrans.AddKeyDef(vk_code, control, TN_CRLF)) return 0;
-                       } else 
-                               if(!KeyTrans.AddKeyDef(vk_code,control,keydef)) return 0;
-                               // else DeleteKeyDef() ???? - I'm not sure...
-               }
-       };
-
-       return 1;
-};
-
-// AVS
-// load [charmap ...] part to xlat
-int TMapLoader::LoadCharMap(string buf) {
-       char wbuf[128];
-       char charmapname[128];
-       charmapname[0] = 0;
-       
-       //        xlat.init(); now it done by KeyTranslator::Load()
-       
-       while ( buf.length() ) {
-               wbuf[0]=0;
-               if (!getline(buf,wbuf,sizeof(wbuf))) break;
-               if ( wbuf[0]==0 ) break;
-               if ( strnicmp(wbuf,"[charmap",8)==0 ) {
-                       strcpy(charmapname,wbuf);
-                       continue;
-               };
-               char * host = strtok(wbuf, " ");
-               char * console = strtok(NULL, " ");
-               
-               int bHost;
-               int bConsole;
-               
-               if ( host == NULL || console == NULL ) {
-                       //              cerr << charmapname << " -> Bad structure" << endl;
-                       printm(0, FALSE, MSG_KEYBADSTRUCT, charmapname);
-                       return 0;
-               };
-               if ( strlen(host) > 1 && host[0] == '\\' )
-                       bHost = getbyte(host+1);
-               else
-                       bHost = (unsigned char)host[0];
-               
-               if ( strlen(console) > 1 && console[0] == '\\' )
-                       bConsole = getbyte(console+1);
-               else
-                       bConsole = (unsigned char)console[0];
-               
-               if ( bHost <= 0 || bConsole <= 0 ) {
-                       //              cerr << charmapname << " -> Bad chars? "
-                       //                   << host << " -> " << console << endl;
-                       printm(0, FALSE, MSG_KEYBADCHARS, charmapname, host, console);
-                       return 0;
-               };
-               // xlat.table[bHost] = bConsole;
-               Charmap.modmap(bHost, 'B', bConsole);
-       };
-       return (Charmap.enabled = 1);
-       return 1;
-};
-
-// AVS
-// ignore long comment [comment] ... [end comment]
-// recursive!
-int getLongComment(istream& is, char* wbuf, size_t sz) {
-       
-       int bufLen;
-    while ( is ) {
-               wbuf[0] = 0;
-               getline(is, wbuf, sz);
-               if ( wbuf[0]==0 ) return 1;
-               bufLen = strlen(wbuf);
-               if ( wbuf[0] == '[' && wbuf[bufLen-1] == ']' ) {
-                       string temps(wbuf);
-                       
-                       if (!normalizeSplitter(temps)) {
-                               //           cerr << "Unexpected line '" << temps << "'\n";
-                               printm(0, FALSE, MSG_KEYUNEXPLINE, temps.c_str());
-                               return 0;
-                       };
-                       if ( stricmp(temps.c_str(),"[comment]") == 0 ) {
-                               // do recursive call
-                               if ( !getLongComment(is, wbuf, sz) ) return 0;
-                               continue;
-                       };
-                       if ( stricmp(temps.c_str(),"[end comment]") == 0 ) return 1;
-               };
-    };
-       // we get a warning if we don't put a return here (Paul Brannan 5/25/98)
-       return 0;
-};
-
-// AVS
-// completelly rewrited to support new conceptions
-int TMapLoader::Load(const char * filename, const char * szActiveEmul) {
-       char buf[256];
-       int bufLen;
-       
-       ifstream inpfile(filename);
-       KeyTrans.DeleteAllDefs();
-       Charmap.init();
-       
-       // it is an array for store [...] ... [end ...] parts from file
-       stringArray SA(0,0,sizeof(string));
-       int AllOk = 0;
-       
-       while ( inpfile ) {
-               
-               getline(inpfile, buf, 255);
-               bufLen = strlen(buf);
-               if ( !bufLen ) continue;
-               
-               if ( buf[0] == '[' && buf[bufLen-1] == ']' ) {
-                       // is a part splitter [...]
-                       string temps(buf);
-                       
-                       if (!normalizeSplitter(temps)) {
-                               printm(0, FALSE, MSG_KEYUNEXPLINE, temps.c_str());
-                               AllOk = 0;
-                               break;
-                       };
-                       // if a comment
-                       if ( stricmp(temps.c_str(),"[comment]") == 0 ) {
-#ifdef KEYDEBUG
-                               printit(temps.c_str());
-#endif
-                               if ( !getLongComment(inpfile, buf, sizeof(buf)) ) {
-                                       printm(0, FALSE, MSG_KEYUNEXPEOF);
-                                       break;
-                               };
-#ifdef KEYDEBUG
-                               printit("\r          \r");
-#endif
-                               continue;
-                       };
-                       
-                       
-                       string back = temps;
-                       // prepare line for make it as [end ...]
-                       // and check it
-                       if ( strnicmp(back.c_str(), "[global]", 8) == 0 ) {} // do nothing
-                       else if ( strnicmp(back.c_str(), "[keymap", 7) == 0 ) {
-                               // DJGPP also uses erase rather than remove (Paul Brannan 6/23/98)
-#ifndef __BORLANDC__
-                               back.erase(7);
-#else
-                               back.remove(7);
-#endif
-                               back += "]";
-                       }
-                       else if ( strnicmp(back.c_str(), "[charmap", 8) == 0 ) {
-                               // Paul Brannan 6/23/98
-#ifndef __BORLANDC__
-                               back.erase(8);
-#else
-                               back.remove(8);
-#endif
-                               back += "]";
-                       }
-                       else if ( strnicmp(back.c_str(), "[config", 7) == 0 ) {
-                               // Paul Brannan 6/23/98
-#ifndef __BORLANDC__
-                               back.erase(7);
-#else
-                               back.remove(7);
-#endif
-                               back += "]";
-                       }
-                       else {
-                               //        cerr << "Unexpected token " << back << endl;
-                               printm(0, FALSE, MSG_KEYUNEXPTOK, back.c_str());
-                               break;
-                       };
-                       
-                       back.insert(1,"END "); // now it looks like [END ...]
-#ifdef KEYDEBUG
-                       printit(temps.c_str());
-#endif
-                       
-                       int ok = 0;
-                       // fetch it to temps
-                       while ( 1 ) {
-                               getline(inpfile, buf, sizeof(buf));
-                               bufLen = strlen(buf);
-                               if ( !bufLen ) break;
-                               if ( buf[0] == '[' && buf[bufLen-1] == ']' ) {
-                                       string t(buf);
-                                       if ( !normalizeSplitter(t) ) break;
-                                       
-                                       if ( stricmp(t.c_str(),back.c_str()) == 0 ) {
-                                               ok = 1;
-                                               break;
-                                       };
-                                       
-                                       // AVS 31.12.97 fix [comment] block inside another block
-                                       if ( stricmp(t.c_str(),"[comment]") == 0 &&
-                                               getLongComment(inpfile, buf, sizeof(buf)) ) continue;
-                                       
-                                       break;
-                               };
-                               temps += "\n";
-                               temps += buf;
-                       };
-                       if ( !ok ) {
-                               //         cerr << "Unexpected end of file or token" << endl;
-                               printm(0, FALSE, MSG_KEYUNEXP);
-                               AllOk = 0;
-                               break;
-                       };
-#ifdef KEYDEBUG
-                       printit("\r                                                                      \r");
-#endif
-                       AllOk = SA.Add(temps);;
-                       if ( !AllOk ) break;
-               } else {
-                       //       cerr << "Unexpected line '" << buf << "'\n";
-                       printm(0, FALSE, MSG_KEYUNEXPLINE, buf);
-                       AllOk = 0;
-                       break;
-               };
-       };
-       
-       inpfile.close();
-       
-       if ( !AllOk ) return 0;
-       
-       // now all file are in SA, comments are stripped
-       
-       int i = LookForPart(SA, "global", "");
-       if ( i == INT_MAX ) {
-               //     cerr << "No [GLOBAL] definition!" << endl;
-               printm(0, FALSE, MSG_KEYNOGLOBAL);
-               return 0;
-       };
-       if ( !LoadGlobal(SA[i]) ) {
-               return 0;
-       };
-       
-       // look for need configuration
-       i = LookForPart(SA, "config", szActiveEmul);
-       if ( i == INT_MAX ) {
-               //     cerr << "No [CONFIG " << szActiveEmul << "]\n";
-               printm(0, FALSE, MSG_KEYNOCONFIG, szActiveEmul);
-               return 0;
-       };
-       //  cerr << "use configuration: " << szActiveEmul << endl;
-       printm(0, FALSE, MSG_KEYUSECONFIG, szActiveEmul);
-       BOOL hadKeys = FALSE;
-       
-       string config = SA[i];
-       // parse it
-       while ( config.length() ) {
-               buf[0] = 0;
-               getline(config,buf,sizeof(buf));
-               bufLen = strlen(buf);
-               if ( !bufLen || (buf[0] == '[' && buf[bufLen-1] == ']') ) continue;
-               if ( strnicmp(buf,"keymap",6) == 0 ) {
-                       string orig(buf);
-                       printit("\t"); printit(buf); printit("\n");
-                       char * mapdef = strtok(buf,":");
-                       char * switchKey = strtok(NULL,"\n");
-                       
-                       if ( !KeyTrans.mapArray.IsEmpty() && switchKey == NULL ) {
-                               //            cerr << "no switch Key for '" << mapdef
-                               //                 << "'" << endl;
-                               printm(0, FALSE, MSG_KEYNOSWKEY, mapdef);
-                               break;
-                       };
-                       if ( KeyTrans.mapArray.IsEmpty() ) {
-                               if ( switchKey != NULL ) { // create default keymap
-                                       //               cerr << "You cannot define switch key for default keymap -> ignored"
-                                       //                    << endl;
-                                       printm(0, FALSE, MSG_KEYCANNOTDEF);
-                               };
-                               TKeyDef empty;
-                               KeyTrans.mapArray.Add(KeyMap(string(mapdef)));
-                               KeyTrans.switchMap(empty); // set it as current keymap
-                               KeyTrans.mainKeyMap = KeyTrans.currentKeyMap;
-                       }
-                       else {
-                               string keydef(switchKey);
-                               keydef += " !*!*!*"; // just for check
-                               WORD vk_code;
-                               DWORD control;
-                               switchKey = ParseKeyDef(keydef.c_str(),vk_code,control);
-                               if ( switchKey != NULL ) {
-                                       TKeyDef swi(NULL,control,vk_code);
-                                       if ( KeyTrans.switchMap(swi) > 0 ) {
-                                               //                  cerr << "Duplicate switching key\n";
-                                               printm(0, FALSE, MSG_KEYDUPSWKEY);
-                                               break;
-                                       };
-                                       KeyTrans.mapArray.Add(KeyMap(swi, orig));
-                                       KeyTrans.switchMap(swi); // set it as current keymap
-                               }
-                       };
-                       mapdef+=7; // 'keymap '
-                       // now load defined keymaps to current
-                       while ((mapdef != NULL)&&
-                               (mapdef = strtok(mapdef,TOKEN_DELIMITERS)) != NULL ) {
-                               i = LookForPart(SA,"keymap",mapdef);
-                               if ( i == INT_MAX ) {
-                                       //               cerr << "Unknown KEYMAP " << mapdef << endl;
-                                       printm(0, FALSE, MSG_KEYUNKNOWNMAP, mapdef);
-                               } else {
-                                       mapdef = strtok(NULL,"\n"); // strtok is used in LoadKeyMap
-                                       // so - save pointer!
-                                       hadKeys = LoadKeyMap(SA[i]); // load it
-                               };
-                       };
-                       
-               }
-               else if ( strnicmp(buf,"charmap",7) == 0 ) {
-                       printit("\t"); printit(buf); printit("\n");
-                       char * mapdef = buf + 8;// 'charmap '
-                       int SuccesLoaded = 0;
-                       // now load defined charmaps to current
-                       while ((mapdef != NULL)&&
-                               (mapdef = strtok(mapdef,TOKEN_DELIMITERS)) != NULL ) {
-                               i = LookForPart(SA,"charmap",mapdef);
-                               if ( i == INT_MAX ) {
-                                       //               cerr << "Unknown KEYMAP " << mapdef << endl;
-                                       printm(0, FALSE, MSG_KEYUNKNOWNMAP, mapdef);
-                               } else {
-                                       mapdef = strtok(NULL,"\n"); // strtok is used in LoadKeyMap
-                                       // so - save pointer!
-                                       if (LoadCharMap(SA[i])) // load it
-                                               SuccesLoaded++;
-                               };
-                       };
-                       if (!SuccesLoaded) {
-                               //            cerr << "No charmaps loaded\n";
-                               printm(0, FALSE, MSG_KEYNOCHARMAPS);
-                               Charmap.init();
-                       };
-                       /*         strtok(buf," ");
-                       
-                         char* name = strtok(NULL," ");
-                         if ( name == NULL ) {
-                         cerr << "No name for CHARMAP" << endl;
-                         } else {
-                         i = LookForPart(SA,"charmap", name);
-                         if ( i == INT_MAX ) {
-                         cerr << "Unknown CHARMAP " << name << endl;
-                         } else {
-                         LoadCharMap(SA[i]);
-                         };
-                         };
-                       */
-               }
-               else {
-                       //        cerr << "unexpected token in " << szActiveEmul << endl;
-                       printm(0, FALSE, MSG_KEYUNEXPTOKIN, szActiveEmul);
-               }
-       }
-
-       if ( hadKeys) {
-               TKeyDef empty;
-               KeyTrans.switchMap(empty); // switch to default
-               KeyTrans.mainKeyMap = KeyTrans.currentKeyMap; // save it's number
-               //     cerr << "There are " << (KeyTrans.mapArray.GetItemsInContainer()) << " maps\n";
-               char s[12]; // good enough for a long int (32-bit)
-               itoa(KeyTrans.mapArray.GetItemsInContainer(), s, 10);
-               printm(0, FALSE, MSG_KEYNUMMAPS, s);
-               return 1;
-       };
-       return 0;
-}
-
-void TMapLoader::Display() {
-
-    int max = KeyTrans.mapArray.GetItemsInContainer();
-    if (max == 0) {
-       printm(0, FALSE, MSG_KEYNOKEYMAPS);
-       return;
-    };
-    for ( int i = 0; i < max; i++ ) {
-       char buf[20];
-       itoa(i,buf,10);
-       printit("\t");
-       // Ioannou : we can show the current
-       if (KeyTrans.currentKeyMap == i)
-         printit("*");
-       else
-         printit(" ");
-       strcat(buf," ");
-       printit(buf);
-       char * msg = new char [KeyTrans.mapArray[i].orig.length()+1];
-       strcpy(msg,KeyTrans.mapArray[i].orig.c_str());
-       printit(msg);
-       delete[] msg;
-       printit("\n");
-    };
-};
diff --git a/reactos/apps/utils/net/telnet/src/tmapldr.h b/reactos/apps/utils/net/telnet/src/tmapldr.h
deleted file mode 100644 (file)
index 4a80966..0000000
+++ /dev/null
@@ -1,105 +0,0 @@
-///////////////////////////////////////////////////////////////////
-//                                                               //
-// File format :                                                 //
-//                                                               //
-//  Comments with a ; in column 1                                //
-//  Empty Lines ignored                                          //
-//  The words are separated by a space, a tab, or a plus ("+")   //
-//                                                               //
-//  First a [GLOBAL] section :                                   //
-//   [GLOBAL]                                                    //
-//   VK_F1         112                                           //
-//   .                                                           //
-//   .                                                           //
-//   [END_GLOBAL]                                                //
-//                                                               //
-//   The GLOBAL section defines the names of the keys            //
-//   and the virtual key code they have.                         //
-//   If you repeat a name you'll overwrite the code.             //
-//   You can name the keys anything you like                     //
-//   The Virtual key nymber must be in Decimal                   //
-//   After the number you can put anything : it is ignored       //
-//   Here you must put ALL the keys you'll use in the            //
-//   other sections.                                             //
-//                                                               //
-//  Then the emulations sections :                               //
-//                                                               //
-//   [SCO_ANSI]                                                  //
-//                                                               //
-//   VK_F1                    \027[M or                          //
-//   VK_F1                    ^[[M   or                          //
-//   VK_F1 SHIFT              ^[[W  etc                          //
-//   .                                                           //
-//   .                                                           //
-//   [SCO_ANSI_END]                                              //
-//                                                               //
-//   There are three parts :                                     //
-//      a) the key name                                          //
-//      b) the shift state                                       //
-//         here you put compination of the words :               //
-//                                                               //
-//                RIGHT_ALT                                      //
-//                LEFT_ALT                                       //
-//                RIGHT_CTRL                                     //
-//                LEFT_CTRL                                      //
-//                SHIFT                                          //
-//                NUMLOCK                                        //
-//                SCROLLLOCK                                     //
-//                CAPSLOCK                                       //
-//                ENHANCED                                       //
-//                APP_KEY                                        //
-//      c) the assigned string :                                 //
-//         you can use the ^ for esc (^[ = 0x1b)                 //
-//                         \ and a three digit decimal number    //
-//                         (\027)                                //
-//         You can't use the NULL !!!                            //
-//         Also (for the moment) you can't use spaces            //
-//         in the string : everything after the 3rd word is      //
-//           ignored - use unsderscore instead.                  //
-//                                                               //
-//   for  example :                                              //
-//                                                               //
-//         VK_F4  SHIFT+LEFT_ALT  \0274m^[[M = 0x1b 4 m 0x1b [ M //
-//         VK_F1  RIGHT_CTRL      This_is_ctrl_f1                //
-//                                                               //
-// You may have as many sections as you like                     //
-// If you repeat any section (even the GLOBAL) you'll overwrite  //
-// the common parts.                                             //
-//                                                               //
-///////////////////////////////////////////////////////////////////
-
-#ifndef __TLOADMAP_H
-#define __TLOADMAP_H
-
-#include "keytrans.h"
-#include "tcharmap.h"
-
-// AVS
-typedef TArrayAsVector<string> stringArray;
-
-class TMapLoader {
-public:
-       TMapLoader(KeyTranslator &RefKeyTrans, TCharmap &RefCharmap):
-         KeyTrans(RefKeyTrans), Charmap(RefCharmap) {}
-       ~TMapLoader() {}
-
-       // If called more than once the new map replaces the old one.
-       // load with a different KeysetName to change keysets
-       // Return 0 on error
-    int Load(const char * filename, const char * szKeysetName);
-
-       void Display();
-private:
-       KeyTranslator &KeyTrans;
-       TCharmap &Charmap;
-
-       int LookForPart(stringArray& sa, const char* partType, const char* partName);
-       char* ParseKeyDef(const char* buf, WORD& vk_code, DWORD& control);
-
-       int LoadGlobal(string& buf);
-       int LoadKeyMap(string buf);
-       int LoadCharMap(string buf);
-
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tmouse.cpp b/reactos/apps/utils/net/telnet/src/tmouse.cpp
deleted file mode 100644 (file)
index 9f87c04..0000000
+++ /dev/null
@@ -1,210 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998  Paul Brannan
-//Copyright (C) 1998  I.Ioannou
-//Copyright (C) 1997  Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-// TMouse.cpp
-// A simple class for handling mouse events
-// Written by Paul Brannan <pbranna@clemson.edu>
-// Last modified August 30, 1998
-
-#include "tmouse.h"
-#include "tconsole.h"
-
-TMouse::TMouse(Tnclip &RefClipboard): Clipboard(RefClipboard) {
-       hConsole = GetStdHandle(STD_INPUT_HANDLE);
-       hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
-}
-
-TMouse::~TMouse() {
-}
-
-void TMouse::get_coords(COORD *start_coords, COORD *end_coords,
-                               COORD *first_coords, COORD *last_coords) {
-       if(end_coords->Y < start_coords->Y ||
-               (end_coords->Y == start_coords->Y && end_coords->X < start_coords->X))
-       {
-               *first_coords = *end_coords;
-               *last_coords = *start_coords;
-       } else {
-               *first_coords = *start_coords;
-               *last_coords = *end_coords;
-       }
-       last_coords->X++;
-}
-
-void TMouse::doMouse_init() {
-       GetConsoleScreenBufferInfo(hStdout, &ConsoleInfo);
-       chiBuffer = newBuffer();
-       saveScreen(chiBuffer);
-}
-
-void TMouse::doMouse_cleanup() {
-       restoreScreen(chiBuffer);
-       delete[] chiBuffer;
-}
-
-void TMouse::move_mouse(COORD start_coords, COORD end_coords) {
-       COORD screen_start = {0, 0};
-       COORD first_coords, last_coords;
-       DWORD Result;
-
-       FillConsoleOutputAttribute(hStdout, normal,
-               ConsoleInfo.dwSize.X * ConsoleInfo.dwSize.Y, screen_start, &Result);
-                                       
-       get_coords(&start_coords, &end_coords, &first_coords, &last_coords);
-       FillConsoleOutputAttribute(hStdout, inverse, ConsoleInfo.dwSize.X * 
-               (last_coords.Y - first_coords.Y) + (last_coords.X - first_coords.X),
-               first_coords, &Result);
-}
-
-void TMouse::doClip(COORD start_coords, COORD end_coords) {
-       // COORD screen_start = {0, 0};
-       COORD first_coords, last_coords;
-       DWORD Result;
-
-       get_coords(&start_coords, &end_coords, &first_coords, &last_coords);
-
-       // Allocate the minimal size buffer
-       int data_size = 3 + ConsoleInfo.dwSize.X *
-               (last_coords.Y - first_coords.Y) + (last_coords.X - first_coords.X);
-       HGLOBAL clipboard_data = GlobalAlloc(GMEM_MOVEABLE + GMEM_DDESHARE,
-               data_size);
-       LPVOID mem_ptr = GlobalLock(clipboard_data);
-
-       // Reset data_size so we can count the actual data size
-       data_size = 0;
-
-       // Read the console, put carriage returns at the end of each line if
-       // reading more than one line (Paul Brannan 9/17/98)
-       for(int j = first_coords.Y; j <= last_coords.Y; j++) {
-
-               // Read line at (0,j)
-               COORD coords;
-               coords.X = 0;
-               coords.Y = j;
-               int length = ConsoleInfo.dwSize.X;
-
-               if(j == first_coords.Y) {
-                       coords.X = first_coords.X;
-                       length = ConsoleInfo.dwSize.X - first_coords.X;
-               } else {
-                       // Add a carriage return to the end of the previous line
-                       *((char *)mem_ptr + data_size++) = '\r';
-                       *((char *)mem_ptr + data_size++) = '\n';
-               }
-
-               if(j == last_coords.Y) {
-                       length -= (ConsoleInfo.dwSize.X - last_coords.X);
-               }
-
-               // Read the next line
-               ReadConsoleOutputCharacter(hStdout, (LPTSTR)((char *)mem_ptr +
-                       data_size), length, coords, &Result);
-               data_size += Result;
-
-               // Strip the spaces at the end of the line
-               if((j != last_coords.Y) && (first_coords.Y != last_coords.Y))
-                       while(*((char *)mem_ptr + data_size - 1) == ' ') data_size--;
-       }
-       if(first_coords.Y != last_coords.Y) {
-               // Add a carriage return to the end of the last line
-               *((char *)mem_ptr + data_size++) = '\r';
-               *((char *)mem_ptr + data_size++) = '\n';
-       }
-
-       *((char *)mem_ptr + data_size) = 0;
-       GlobalUnlock(clipboard_data);
-
-       Clipboard.Copy(clipboard_data);
-}
-
-void TMouse::doMouse() {
-       INPUT_RECORD InputRecord;
-       DWORD Result;
-       InputRecord.EventType = KEY_EVENT; // just in case
-       while(InputRecord.EventType != MOUSE_EVENT) {
-               if (!ReadConsoleInput(hConsole, &InputRecord, 1, &Result))
-                       return; // uh oh!  we don't know the starting coordinates!
-       }
-       if(InputRecord.Event.MouseEvent.dwButtonState == 0) return;
-       if(!(InputRecord.Event.MouseEvent.dwButtonState &
-               FROM_LEFT_1ST_BUTTON_PRESSED)) {
-               Clipboard.Paste();
-               return;
-       }
-
-       COORD screen_start = {0, 0};
-    COORD start_coords = InputRecord.Event.MouseEvent.dwMousePosition;
-       COORD end_coords = start_coords;
-       BOOL done = FALSE;
-       
-       // init vars
-       doMouse_init();
-       int normal_bg = ini.get_normal_bg();
-       int normal_fg = ini.get_normal_fg();
-       if(normal_bg == -1) normal_bg = 0;              // FIX ME!!  This is just a hack
-       if(normal_fg == -1) normal_fg = 7;
-       normal = (normal_bg << 4) | normal_fg;
-       inverse = (normal_fg << 4) | normal_bg;
-
-       // make screen all one attribute
-       FillConsoleOutputAttribute(hStdout, normal, ConsoleInfo.dwSize.X *
-               ConsoleInfo.dwSize.Y, screen_start, &Result);
-       
-       while(!done) {
-
-               switch (InputRecord.EventType) {
-               case MOUSE_EVENT:
-                       switch(InputRecord.Event.MouseEvent.dwEventFlags) {
-                       case 0: // only copy if the mouse button has been released
-                               if(!InputRecord.Event.MouseEvent.dwButtonState) {
-                                       doClip(start_coords, end_coords);
-                                       done = TRUE;
-                               }
-                               break;
-                               
-                       case MOUSE_MOVED:
-                               end_coords = InputRecord.Event.MouseEvent.dwMousePosition;
-                               move_mouse(start_coords, end_coords);                                   
-                               break;
-                       }
-                       break;
-               // If we are changing focus, we don't want to highlight anything
-               // (Paul Brannan 9/2/98)
-               case FOCUS_EVENT:
-                       return;                 
-               }
-               
-               WaitForSingleObject(hConsole, INFINITE);
-               if (!ReadConsoleInput(hConsole, &InputRecord, 1, &Result))
-                       done = TRUE;
-               
-       }
-
-       doMouse_cleanup();
-}
-
-void TMouse::scrollMouse() {
-       doMouse();
-}
diff --git a/reactos/apps/utils/net/telnet/src/tmouse.h b/reactos/apps/utils/net/telnet/src/tmouse.h
deleted file mode 100644 (file)
index fde6ec7..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-#ifndef __TMOUSE_H
-#define __TMOUSE_H
-
-#include "tnclip.h"
-#include <windows.h>
-
-class TMouse {
-private:
-       int normal, inverse;
-       HANDLE hConsole, hStdout;
-       CHAR_INFO *chiBuffer;
-       CONSOLE_SCREEN_BUFFER_INFO ConsoleInfo;
-       Tnclip &Clipboard;
-
-       void get_coords(COORD *start_coords, COORD *end_coords,
-               COORD *first_coords, COORD *last_coords);
-       void doMouse_init();
-       void doMouse_cleanup();
-       void move_mouse(COORD start_coords, COORD end_coords);
-       void doClip(COORD start_coords, COORD end_coords);
-
-public:
-       void doMouse();
-       void scrollMouse();
-       TMouse(Tnclip &RefClipboard);
-       ~TMouse();
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tnclass.cpp b/reactos/apps/utils/net/telnet/src/tnclass.cpp
deleted file mode 100644 (file)
index bad1700..0000000
+++ /dev/null
@@ -1,398 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998  Paul Brannan
-//Copyright (C) 1998  I.Ioannou
-//Copyright (C) 1997  Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-///////////////////////////////////////////////////////////////////////////////
-//
-// Module:             tnclass.cpp
-//
-// Contents:   telnet object definition
-//
-// Product:            telnet
-//
-// Revisions: August 30, 1998 Paul Brannan <pbranna@clemson.edu>
-//            July 12, 1998 Paul Brannan
-//            June 15, 1998 Paul Brannan
-//            May 14, 1998     Paul Brannan
-//            5.April.1997 jbj@nounname.com
-//            14.Sept.1996 jbj@nounname.com
-//            Version 2.0
-//
-///////////////////////////////////////////////////////////////////////////////
-
-#include <stdlib.h>
-#include <string.h>
-#include "tnclass.h"
-#include "tnmisc.h"
-
-// Mingw32 needs these (Paul Brannan 9/4/98)
-#ifndef ICON_SMALL
-#define ICON_SMALL 0
-#endif
-#ifndef ICON_BIG
-#define ICON_BIG 1
-#endif
-
-// Ioannou Dec. 8, 1998
-#ifdef __BORLANDC__
-#ifndef WM_SETICON
-#define WM_SETICON STM_SETICON
-#endif
-#endif
-
-// DoInit() - performs initialization that is common to both the
-// constructors (Paul Brannan 6/15/98)
-void Telnet::DoInit() {
-       Socket = INVALID_SOCKET;
-       bConnected = 0;
-       bNetPaused = 1;
-       bNetFinished = 1;
-       bNetFinish = 0;
-       hThread = 0;                                                            // Sam Robertson 12/7/98
-       hProcess = 0;
-
-       WSADATA WsaData;
-
-       // Set the title
-       telSetConsoleTitle("No Connection");
-
-       // Change the icon
-       hConsoleWindow = TelnetGetConsoleWindow();
-       iconChange = SetIcon(hConsoleWindow, 0, &oldBIcon, &oldSIcon, ini.get_startdir());
-
-       if (WSAStartup(MAKEWORD(1, 1), &WsaData)) {
-               DWORD dwLastError = GetLastError();
-               printm(0, FALSE, MSG_ERROR, "WSAStartup()");
-               printm(0, TRUE, dwLastError);
-               bWinsockUp = 0;
-               return;
-       }
-       bWinsockUp = 1;
-
-       // Get keyfile (Paul Brannan 5/12/98)
-       const char *keyfile = ini.get_keyfile();
-
-       // This should be changed later to use the Tnerror routines
-       // This has been done (Paul Brannan 6/5/98)
-       if(LoadKeyMap( keyfile, ini.get_default_config()) != 1)
-               // printf("Error loading keymap.\n");
-               printm(0, FALSE, MSG_ERRKEYMAP);
-}
-
-Telnet::Telnet():
-MapLoader(KeyTrans, Charmap),
-Console(GetStdHandle(STD_OUTPUT_HANDLE)),
-TelHandler(Network, Console, Parser),
-ThreadParams(TelHandler),
-Clipboard(TelnetGetConsoleWindow(), Network),
-Mouse(Clipboard),
-Scroller(Mouse, ini.get_scroll_size()),
-Parser(Console, KeyTrans, Scroller, Network, Charmap) {
-       DoInit();
-}
-
-Telnet::Telnet(const char * szHost1, const char *strPort1):
-MapLoader(KeyTrans, Charmap),
-Console(GetStdHandle(STD_OUTPUT_HANDLE)),
-TelHandler(Network, Console, Parser),
-ThreadParams(TelHandler),
-Clipboard(TelnetGetConsoleWindow(), Network),
-Mouse(Clipboard),
-Scroller(Mouse, ini.get_scroll_size()),
-Parser(Console, KeyTrans, Scroller, Network, Charmap) {
-       DoInit();
-       Open( szHost1, strPort1);
-}
-
-Telnet::~Telnet(){
-       if (bWinsockUp){
-               if(bConnected) Close();
-               WSACleanup();
-       }
-
-       // Paul Brannan 8/10/98
-       if(iconChange) {
-               ResetIcon(hConsoleWindow, oldBIcon, oldSIcon);
-       }
-
-}
-
-// changed from char * to const char * (Paul Brannan 5/12/98)
-int Telnet::LoadKeyMap(const char * file, const char * name){
-       // printf("Loading %s from %s.\n", name ,file);
-       printm(0, FALSE, MSG_KEYMAP, name, file);
-       return MapLoader.Load(file,name);
-}
-
-void Telnet::DisplayKeyMap(){ // display available keymaps
-       MapLoader.Display();
-};
-
-int  Telnet::SwitchKeyMap(int to) { // switch to selected keymap
-       int ret = KeyTrans.SwitchTo(to);
-       switch(ret) {
-       case -1: printm(0, FALSE, MSG_KEYNOKEYMAPS); break;
-       case 0: printm(0, FALSE, MSG_KEYBADMAP); break;
-       case 1: printm(0, FALSE, MSG_KEYMAPSWITCHED); break;
-       }
-       return ret;
-};
-
-
-int Telnet::Open(const char *szHost1, const char *strPort1){
-       if (bWinsockUp && !bConnected){
-               telSetConsoleTitle(szHost1);
-
-               strncpy (szHost,szHost1, 127);
-               strncpy(strPort, strPort1, sizeof(strPort));
-
-               // Determine whether to pipe to an executable or use our own sockets
-               // (Paul Brannan March 18, 1999)
-               const char *netpipe;
-               if(*(netpipe=ini.get_netpipe())) {
-                       PROCESS_INFORMATION pi;
-                       HANDLE hInWrite, hOutRead, hErrRead;
-                       if(!CreateHiddenConsoleProcess(netpipe, &pi, &hInWrite,
-                               &hOutRead, &hErrRead)) {
-                               printm(0, FALSE, MSG_ERRPIPE);
-                               return TNNOCON;
-                       }
-                       Network.SetPipe(hOutRead, hInWrite);
-                       hProcess = pi.hProcess;
-               } else {
-                       Socket = Connect();
-                       if (Socket == INVALID_SOCKET) {
-                               printm(0, FALSE, GetLastError());
-                               return TNNOCON;
-                       }
-                       Network.SetSocket(Socket);
-                       SetLocalAddress(Socket);
-               }
-
-               bNetFinish = 0;
-               bConnected = 1;
-               ThreadParams.p.bNetPaused = &bNetPaused;
-               ThreadParams.p.bNetFinish = &bNetFinish;
-               ThreadParams.p.bNetFinished = &bNetFinished;
-               ThreadParams.p.hExit = CreateEvent(0, TRUE, FALSE, "");
-               ThreadParams.p.hPause = CreateEvent(0, FALSE, FALSE, "");
-               ThreadParams.p.hUnPause = CreateEvent(0, FALSE, FALSE, "");
-               DWORD idThread;
-
-               // Disable Ctrl-break (PB 5/14/98);
-               // Fixed (Thomas Briggs 8/17/98)
-        if(ini.get_disable_break() || ini.get_control_break_as_c())
-                       SetConsoleCtrlHandler(ControlEventHandler, TRUE);
-
-               hThread = CreateThread(0, 0,
-                       telProcessNetwork,
-                       (LPVOID)&ThreadParams, 0, &idThread);
-               // This helps the display thread a little (Paul Brannan 8/3/98)
-               SetThreadPriority(hThread, THREAD_PRIORITY_ABOVE_NORMAL);
-               return Resume();
-       } else if(bWinsockUp && bConnected) {
-                       printm (0, FALSE, MSG_ALREADYCONNECTED, szHost);
-       }
-       
-       return TNNOCON; // cannot do winsock stuff or already connected
-}
-
-// There seems to be a bug with MSVC's optimization.  This turns them off
-// for these two functions.
-// (Paul Brannan 5/14/98)
-#ifdef _MSC_VER
-#pragma optimize("", off)
-#endif
-
-
-int Telnet::Close() {
-       Console.sync();
-       switch(Network.get_net_type()) {
-       case TN_NETSOCKET:
-               if(Socket != INVALID_SOCKET) closesocket(Socket);
-               Socket = INVALID_SOCKET;
-               break;
-       case TN_NETPIPE:
-               if(hProcess != 0) {
-                       TerminateProcess(hProcess, 0);
-                       CloseHandle(hProcess);
-                       hProcess = 0;
-               }
-               break;
-       }
-
-       // Enable Ctrl-break (PB 5/14/98);
-       // Ioannou : this must be FALSE
-    if(ini.get_disable_break()) SetConsoleCtrlHandler(NULL, FALSE);
-
-       if (hThread) CloseHandle(hThread);              // Paul Brannan 8/11/98
-       hThread = NULL;                                                 // Daniel Straub 11/12/98
-
-       SetEvent(ThreadParams.p.hUnPause);
-       bNetFinish = 1;
-       while (!bNetFinished)
-               Sleep (0);      // give up our time slice- this lets our connection thread
-                                       // finish itself, so we don't hang -crn@ozemail.com.au
-       telSetConsoleTitle("No Connection");
-       bConnected = 0;
-       return 1;
-}
-
-int Telnet::Resume(){
-       int i;
-       if (bConnected) {
-               Console.sync();
-               for(;;){
-                       SetEvent(ThreadParams.p.hUnPause);
-                       i = telProcessConsole(&ThreadParams.p, KeyTrans, Console,
-                               Network, Mouse, Clipboard, hThread);
-                       if (i) bConnected = 1;
-                       else bConnected = 0;
-                       ResetEvent(ThreadParams.p.hUnPause);
-                       SetEvent(ThreadParams.p.hPause);
-                       while (!bNetPaused)
-                               Sleep (0);      // give up our time slice- this lets our connection thread
-                                                       // unpause itself, so we don't hang -crn@ozemail.com.au
-                       switch (i){
-                       case TNNOCON:
-                               Close();
-                               return TNDONE;
-                       case TNPROMPT:
-                               return TNPROMPT;
-                       case TNSCROLLBACK:
-                               Scroller.ScrollBack();
-                               break;
-                       case TNSPAWN:
-                               NewProcess();
-                       }
-               }
-       }
-       return TNNOCON;
-}
-
-// Turn optimization back on (Paul Brannan 5/12/98)
-#ifdef _MSC_VER
-#pragma optimize("", on)
-#endif
-
-// The scrollback functions have been moved to TScroll.cpp
-// (Paul Brannan 6/15/98)
-SOCKET Telnet::Connect()
-{
-       SOCKET Socket1 = socket(AF_INET, SOCK_STREAM, 0);
-       SOCKADDR_IN SockAddr;
-       SockAddr.sin_family = AF_INET;
-       SockAddr.sin_addr.s_addr = inet_addr(szHost);
-
-       // determine the port correctly -crn@ozemail.com.au 15/12/98
-       SERVENT *sp;
-       sp = getservbyname (strPort, "tcp");
-       if (sp == NULL) {
-               if (isdigit (*(strPort)))
-                       SockAddr.sin_port = htons(atoi(strPort));
-               else {
-                       printm(0, FALSE, MSG_NOSERVICE, strPort);
-                       return INVALID_SOCKET;
-               }
-       } else
-               SockAddr.sin_port = sp->s_port;
-       ///
-
-       // Were we given host name?
-       if (SockAddr.sin_addr.s_addr == INADDR_NONE) {
-
-               // Resolve host name to IP address.
-               printm(0, FALSE, MSG_RESOLVING, szHost);
-               hostent* pHostEnt = gethostbyname(szHost);
-               if (!pHostEnt)
-                       return INVALID_SOCKET;
-               printit("\n");
-
-               SockAddr.sin_addr.s_addr = *(DWORD*)pHostEnt->h_addr;
-       }
-
-       // Print a message telling the user the IP we are connecting to
-       // (Paul Brannan 5/14/98)
-       char ss_b1[4], ss_b2[4], ss_b3[4], ss_b4[4], ss_b5[12];
-       itoa(SockAddr.sin_addr.S_un.S_un_b.s_b1, ss_b1, 10);
-       itoa(SockAddr.sin_addr.S_un.S_un_b.s_b2, ss_b2, 10);
-       itoa(SockAddr.sin_addr.S_un.S_un_b.s_b3, ss_b3, 10);
-       itoa(SockAddr.sin_addr.S_un.S_un_b.s_b4, ss_b4, 10);
-       itoa(ntohs(SockAddr.sin_port), ss_b5, 10);
-       printm(0, FALSE, MSG_TRYING, ss_b1, ss_b2, ss_b3, ss_b4, ss_b5);
-       
-       if (connect(Socket1, (sockaddr*)&SockAddr, sizeof(SockAddr)))
-               return INVALID_SOCKET;
-
-       char esc[2];
-       esc [0] = ini.get_escape_key();
-       esc [1] = 0;
-       printm(0, FALSE, MSG_CONNECTED, szHost, esc);
-
-       return Socket1;
-}
-
-void Telnet::telSetConsoleTitle(const char * szHost1)
-{
-       char szTitle[128] = "Telnet - ";
-       strcat(szTitle, szHost1);
-       if(ini.get_set_title()) SetConsoleTitle(szTitle);
-}
-
-void Telnet::NewProcess() {
-       char cmd_line[MAX_PATH*2];
-       PROCESS_INFORMATION pi;
-
-       strcpy(cmd_line, ini.get_startdir());
-       strcat(cmd_line, ini.get_exename());    // Thomas Briggs 12/7/98
-       
-       if(!SpawnProcess(cmd_line, &pi)) printm(0, FALSE, MSG_NOSPAWN);
-}
-
-void Telnet::SetLocalAddress(SOCKET s) {
-       SOCKADDR_IN SockAddr;
-       int size = sizeof(SOCKADDR_IN);
-       memset(&SockAddr, 0, sizeof(SockAddr));
-       SockAddr.sin_family = AF_INET;
-
-       getsockname(Network.GetSocket(), (sockaddr*)&SockAddr, &size);
-       char ss_b1[4], ss_b2[4], ss_b3[4], ss_b4[4];
-       itoa(SockAddr.sin_addr.S_un.S_un_b.s_b1, ss_b1, 10);
-       itoa(SockAddr.sin_addr.S_un.S_un_b.s_b2, ss_b2, 10);
-       itoa(SockAddr.sin_addr.S_un.S_un_b.s_b3, ss_b3, 10);
-       itoa(SockAddr.sin_addr.S_un.S_un_b.s_b4, ss_b4, 10);
-
-       char addr[40];
-       strcpy(addr, ss_b1);
-       strcat(addr, ".");
-       strcat(addr, ss_b2);
-       strcat(addr, ".");
-       strcat(addr, ss_b3);
-       strcat(addr, ".");
-       strcat(addr, ss_b4);
-       strcat(addr, ":0.0");
-
-       Network.SetLocalAddress(addr);
-}
-
diff --git a/reactos/apps/utils/net/telnet/src/tnclass.h b/reactos/apps/utils/net/telnet/src/tnclass.h
deleted file mode 100644 (file)
index f29dfa3..0000000
+++ /dev/null
@@ -1,74 +0,0 @@
-#ifndef __TNCLASS_H_
-#define __TNCLASS_H_
-
-#include <windows.h>
-#include "tnconfig.h"
-#include "ttelhndl.h"
-#include "tncon.h"
-#include "tnerror.h"
-#include "tparams.h"
-#include "keytrans.h"
-#include "ansiprsr.h"
-#include "tcharmap.h"
-#include "tnclip.h"
-#include "tmouse.h"
-#include "tmapldr.h"
-
-class Telnet {
-public:
-       // create a telnet instance
-       Telnet();
-       // open a connection return on break/quit
-       Telnet(const char * szHost1, const char *strPort1);
-       ~Telnet();
-
-       // open a connection return on break/quit
-       int Open(const char *szHost, const char *strPort = "23");
-       int Close();                            // close current connection
-       int Resume();                           // resume current session
-
-       // changes to the keymap profile in the file
-       int LoadKeyMap( const char * file, const char * name);
-       void DisplayKeyMap();           // display available keymaps
-       int  SwitchKeyMap(int);         // switch to selected keymap
-private:
-       SOCKET Connect();
-       void telSetConsoleTitle(const char * szHost);
-       void DoInit();
-
-       SOCKET Socket;
-       char strPort[32]; // int iPort;
-       char szHost[127];
-       volatile int bConnected;
-       volatile int bWinsockUp;
-       volatile int bNetPaused;
-       volatile int bNetFinished;
-       volatile int bNetFinish;
-
-       // The order of member classes in the class definition MUST come in
-       // this order! (Paul Brannan 12/4/98)
-       TNetwork Network;
-       TCharmap Charmap;
-       KeyTranslator KeyTrans;
-       TMapLoader MapLoader;
-       TConsole Console;
-       TTelnetHandler TelHandler;
-       TelThreadParams ThreadParams;
-       Tnclip Clipboard;
-       TMouse Mouse;
-       TScroller Scroller;
-       TANSIParser Parser;
-
-       HWND hConsoleWindow;                            // Paul Brannan 8/10/98
-       LPARAM oldBIcon, oldSIcon;                      // Paul Brannan 8/10/98
-       bool iconChange;
-
-       HANDLE hThread;                                         // Paul Brannan 8/11/98
-       HANDLE hProcess;                                        // Paul Brannan 7/15/99
-
-       void NewProcess();                                      // Paul Brannan 9/13/98
-       void SetLocalAddress(SOCKET s);
-};
-
-#endif
-
diff --git a/reactos/apps/utils/net/telnet/src/tnclip.cpp b/reactos/apps/utils/net/telnet/src/tnclip.cpp
deleted file mode 100644 (file)
index d957d5a..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998  Paul Brannan
-//Copyright (C) 1998  I.Ioannou
-//Copyright (C) 1997  Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-// TnClip.cpp
-// A simple class for handling clipboard functions
-// Written by Paul Brannan <pbranna@clemson.edu>
-// Last modified 7/12/98
-
-#include <string.h>
-#include "tnclip.h"
-
-Tnclip::Tnclip(HWND W, TNetwork &RefNetwork): Network(RefNetwork) {
-       Window = W;
-}
-
-Tnclip::~Tnclip() {
-}
-
-void Tnclip::Copy(HGLOBAL clipboard_data) {
-       if(!OpenClipboard(Window)) return;
-       if(!EmptyClipboard()) return;
-                                               
-       SetClipboardData(CF_TEXT, clipboard_data);
-       CloseClipboard();
-}
-
-void Tnclip::Paste() {
-       if(!OpenClipboard(Window)) return;
-
-       HANDLE clipboard_data = GetClipboardData(CF_TEXT);
-       LPVOID clipboard_ptr = GlobalLock(clipboard_data);
-       DWORD size = strlen((const char *)clipboard_data);
-       Network.WriteString((const char *)clipboard_ptr, size);
-       GlobalUnlock(clipboard_data);
-       
-       CloseClipboard();
-}
-
diff --git a/reactos/apps/utils/net/telnet/src/tnclip.h b/reactos/apps/utils/net/telnet/src/tnclip.h
deleted file mode 100644 (file)
index cd20c30..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-#ifndef __TNCLIP_H
-#define __TNCLIP_H
-
-#include <windows.h>
-#include "tnetwork.h"
-
-class Tnclip {
-private:
-       HWND Window;
-       TNetwork &Network;
-
-public:
-       Tnclip(HWND Window, TNetwork &RefNetwork);
-       ~Tnclip();
-
-       void Copy(HGLOBAL clipboard_data);
-       void Paste();
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tncon.cpp b/reactos/apps/utils/net/telnet/src/tncon.cpp
deleted file mode 100644 (file)
index cb9fda5..0000000
+++ /dev/null
@@ -1,368 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-///////////////////////////////////////////////////////////////////////////////
-//
-// Module:             tncon.cpp
-//
-// Contents:   telnet console processing
-//
-// Product:            telnet
-//
-// Revisions: August 30, 1998 Paul Brannan <pbranna@clemson.edu>
-//            July 29, 1998 Paul Brannan
-//            June 15, 1998 Paul Brannan
-//            May 16, 1998 Paul Brannan
-//            5.April.1997 jbj@nounname.com
-//            9.Dec.1996 jbj@nounname.com
-//            Version 2.0
-//
-//            02.Apr.1995      igor.milavec@uni-lj.si
-//                                       Original code
-//
-///////////////////////////////////////////////////////////////////////////////
-#include "tncon.h"
-#include "keytrans.h"
-#include "ttelhndl.h"
-#include "tconsole.h"
-
-#define KEYEVENT InputRecord[i].Event.KeyEvent
-
-// Paul Brannan 6/25/98
-// #ifdef __MINGW32__
-// #define KEYEVENT_CHAR KEYEVENT.AsciiChar
-// #else
-#define KEYEVENT_CHAR KEYEVENT.uChar.AsciiChar
-// #endif
-
-#define KEYEVENT_PCHAR &KEYEVENT_CHAR
-
-// This is for local echo (Paul Brannan 5/16/98)
-inline void DoEcho(const char *p, int l, TConsole &Console,
-                                  TNetwork &Network, NetParams *pParams) {
-       // Pause the console (Paul Brannan 8/24/98)
-       if(Network.get_local_echo()) {
-               ResetEvent(pParams->hUnPause);
-               SetEvent(pParams->hPause);
-               while (!*pParams->bNetPaused); // Pause
-
-               Console.WriteCtrlString(p, l);
-
-               SetEvent(pParams->hUnPause); // Unpause
-       }
-}
-
-// This is for line mode (Paul Brannan 12/31/98)
-static char buffer[1024];
-static unsigned int bufptr = 0;
-
-// Line mode -- currently uses sga/echo to determine when to enter line mode
-// (as in RFC 858), but correct behaviour is as described in RFC 1184.
-// (Paul Brannan 12/31/98)
-// FIX ME!!  What to do with unflushed data when we change from line mode
-// to character mode?
-inline bool DoLineModeSpecial(char keychar, TConsole &Console, TNetwork &Network,
-                                          NetParams *pParams) {
-       if(keychar == VK_BACK) {
-               if(bufptr) bufptr--;
-               DoEcho("\b \b", 3, Console, Network, pParams);
-               return true;
-       } else if(keychar == VK_RETURN) {
-               Network.WriteString(buffer, bufptr);
-               Network.WriteString("\012", 1);
-               DoEcho("\r\n", 2, Console, Network, pParams);
-               bufptr = 0;
-               return true;
-       }
-       return false;
-}
-
-inline void DoLineMode(const char *p, int p_len, TConsole &Console,
-                                          TNetwork &Network) {
-       if(Network.get_line_mode()) {
-               if(bufptr < sizeof(buffer) + p_len - 1) {
-                       memcpy(buffer + bufptr, p, p_len);
-                       bufptr += p_len;
-               } else {
-                       Console.Beep();
-               }
-       } else {
-               Network.WriteString(p, p_len);
-       }
-}
-
-// Paul Brannan 5/27/98
-// Fixed this code for use with appliation cursor keys
-// This should probably be optimized; it's pretty ugly as it is
-// Rewrite #1: now uses ClosestStateKey (Paul Brannan 12/9/98)
-const char *ClosestStateKey(WORD keyCode, DWORD keyState,
-                                                       KeyTranslator &KeyTrans) {
-       char const *p;
-
-       if((p = KeyTrans.TranslateKey(keyCode, keyState))) return p;
-
-       // Check numlock and scroll lock (Paul Brannan 9/23/98)
-       if((p = KeyTrans.TranslateKey(keyCode, keyState & ~NUMLOCK_ON))) return p;
-       if((p = KeyTrans.TranslateKey(keyCode, keyState & ~ENHANCED_KEY
-               & ~NUMLOCK_ON))) return p;
-       if((p = KeyTrans.TranslateKey(keyCode, keyState & ~SCROLLLOCK_ON))) return p;
-       if((p = KeyTrans.TranslateKey(keyCode, keyState & ~ENHANCED_KEY
-               & ~SCROLLLOCK_ON))) return p;
-
-       //       John Ioannou (roryt@hol.gr)
-       //   Athens 31/03/97 00:25am GMT+2
-       //   fix for win95 CAPSLOCK bug
-       //   first check if the user has keys with capslock and then we filter it
-       if((p = KeyTrans.TranslateKey(keyCode, keyState & ~ENHANCED_KEY))) return p;
-       if((p = KeyTrans.TranslateKey(keyCode, keyState & ~CAPSLOCK_ON))) return p;
-       if((p = KeyTrans.TranslateKey(keyCode, keyState & ~ENHANCED_KEY
-               & ~CAPSLOCK_ON))) return p;
-
-       return 0; // we couldn't find a suitable key translation
-}
-
-const char *FindClosestKey(WORD keyCode, DWORD keyState,
-                                                  KeyTranslator &KeyTrans) {
-       char const *p;
-       
-       // Paul Brannan 7/20/98
-       if(ini.get_alt_erase()) {
-               if(keyCode == VK_BACK) {
-                       keyCode = VK_DELETE;
-                       keyState |= ENHANCED_KEY;
-               } else if(keyCode == VK_DELETE && (keyState & ENHANCED_KEY)) {
-                       keyCode = VK_BACK;
-                       keyState &= ~ENHANCED_KEY;
-               }
-       }
-
-       DWORD ext_mode = KeyTrans.get_ext_mode();
-       if(ext_mode) {
-               // Not as fast as an unrolled loop, but certainly more
-               // compact (Paul Brannan 12/9/98)
-               for(DWORD j = ext_mode; j >= APP_KEY; j -= APP_KEY) {
-                       if((j | ext_mode) == ext_mode) {
-                               if((p = ClosestStateKey(keyCode, keyState | j,
-                                       KeyTrans))) return p;
-                       }
-               }
-       }
-       return ClosestStateKey(keyCode, keyState, KeyTrans);
-}
-
-// Paul Brannan Feb. 22, 1999
-int do_op(tn_ops op, TNetwork &Network, Tnclip &Clipboard) {
-       switch(op) {
-       case TN_ESCAPE:
-               return TNPROMPT;
-       case TN_SCROLLBACK:
-               return TNSCROLLBACK;
-       case TN_DIAL:
-               return TNSPAWN;
-       case TN_PASTE:
-               if(ini.get_keyboard_paste()) Clipboard.Paste();
-               else return 0;
-               break;
-       case TN_NULL:
-               Network.WriteString("", 1);
-               return 0;
-       case TN_CR:
-               Network.WriteString("\r", 2); // CR must be followed by NUL
-               return 0;
-       case TN_CRLF:
-               Network.WriteString("\r\n", 2);
-               return 0;
-       }
-       return 0;
-}
-
-int telProcessConsole(NetParams *pParams, KeyTranslator &KeyTrans,
-                                         TConsole &Console, TNetwork &Network, TMouse &Mouse,
-                                         Tnclip &Clipboard, HANDLE hThread)
-{
-       KeyDefType_const keydef;
-       const char *p;
-       int p_len;
-       unsigned int i;
-       int opval;
-       HANDLE hConsole = GetStdHandle(STD_INPUT_HANDLE);
-
-       SetConsoleMode(hConsole, ini.get_enable_mouse() ? ENABLE_MOUSE_INPUT : 0);
-       
-       const DWORD nHandle = 2;
-       HANDLE hHandle[nHandle] = {hConsole, pParams->hExit};
-       
-       for (;;) {
-               DWORD dwInput;
-               switch (WaitForMultipleObjects(nHandle, hHandle, FALSE, INFINITE)) {
-        case WAIT_OBJECT_0: {
-
-                       // Paul Brannan 7/29/98
-                       if(ini.get_input_redir()) {
-                               char InputBuffer[10];
-
-                               // Correction from Joe Manns <joe.manns@ardenenginneers.com>
-                               // to fix race conditions (4/13/99)
-                               int bResult;
-                               bResult = ReadFile(hConsole, InputBuffer, 10, &dwInput, 0);
-                               if(bResult && dwInput == 0) return TNNOCON;
-
-                               // no key translation for redirected input
-                               Network.WriteString(InputBuffer, dwInput);
-                               break;
-                       }
-
-                       INPUT_RECORD InputRecord[11];
-                       if (!ReadConsoleInput(hConsole, &InputRecord[0], 10, &dwInput))
-                               return TNPROMPT;
-                       
-                       for (i = 0; (unsigned)i < dwInput; i++){
-                               switch (InputRecord[i].EventType) {
-                               case KEY_EVENT:{
-                                       if (KEYEVENT.bKeyDown) {
-
-                                               WORD  keyCode  = KEYEVENT.wVirtualKeyCode;
-                                               DWORD keyState = KEYEVENT.dwControlKeyState;
-                                               
-                                               // Paul Brannan 5/27/98
-                                               // Moved the code that was here to FindClosestKey()
-                                               keydef.szKeyDef = FindClosestKey(keyCode,
-                                                       keyState, KeyTrans);
-
-                                               if(keydef.szKeyDef) {
-                                                       if(!keydef.op->sendstr)
-                                                               if((opval = do_op(keydef.op->the_op, Network,
-                                                                       Clipboard)) != 0)
-                                                                       return opval;
-                                               }
-
-                                               if(Network.get_line_mode()) {
-                                                       if(DoLineModeSpecial(KEYEVENT_CHAR, Console, Network, pParams))
-                                                               continue;
-                                               }
-
-                                               p = keydef.szKeyDef;
-                                               if (p == NULL) { // if we don't have a translator
-                                                       if(!KEYEVENT_CHAR) continue;
-                                                       p_len = 1;
-                                                       p = KEYEVENT_PCHAR;
-                                               } else {
-                                                       p_len = strlen(p);
-                                               }
-
-                                               // Local echo (Paul Brannan 5/16/98)
-                                               DoEcho(p, p_len, Console, Network, pParams);
-                                               // Line mode (Paul Brannan 12/31/98)
-                                               DoLineMode(p, p_len, Console, Network);
-                                       }
-                                                          }
-                                       break;
-
-                               case MOUSE_EVENT:
-                                       if(!InputRecord[i].Event.MouseEvent.dwEventFlags) {
-                                               ResetEvent(pParams->hUnPause);
-                                               SetEvent(pParams->hPause);
-                                               while (!*pParams->bNetPaused);  // thread paused
-                                               // SuspendThread(hThread);
-
-                                               // Put the mouse's X and Y coords back into the
-                                               // input buffer
-                                               DWORD Result;
-                                               WriteConsoleInput(hConsole, &InputRecord[i], 1,
-                                                       &Result);
-
-                                               Mouse.doMouse();
-
-                                               SetEvent(pParams->hUnPause);
-                                               // ResumeThread(hThread);
-                                       }
-                                       break;
-
-                               case FOCUS_EVENT:
-                                       break;
-                               case WINDOW_BUFFER_SIZE_EVENT:
-                                       // FIX ME!!  This should take care of the window re-sizing bug
-                                       // Unfortunately, it doesn't.
-                                       Console.sync();
-                                       Network.do_naws(Console.GetWidth(), Console.GetHeight());
-                                       break;
-                               }
-                       
-                       } // keep going until no more input
-                       break;
-                                                       }
-        default:
-                       return TNNOCON;
-               }
-       }
-}
-
-WORD scrollkeys() {
-       HANDLE hConsole = GetStdHandle(STD_INPUT_HANDLE);
-       INPUT_RECORD InputRecord;
-       BOOL done = FALSE;
-       
-       while (!done) {
-               DWORD dwInput;
-               WaitForSingleObject( hConsole, INFINITE );
-               if (!ReadConsoleInput(hConsole, &InputRecord, 1, &dwInput)){
-                       done = TRUE;
-                       continue;
-               }
-               if (InputRecord.EventType == KEY_EVENT &&
-                       InputRecord.Event.KeyEvent.bKeyDown ) {
-                       // Why not just return the key code?  (Paul Brannan 12/5/98)
-                       return InputRecord.Event.KeyEvent.wVirtualKeyCode;
-               } else if(InputRecord.EventType == MOUSE_EVENT) {
-                       if(!InputRecord.Event.MouseEvent.dwEventFlags) {
-                               // Put the mouse's X and Y coords back into the input buffer
-                               WriteConsoleInput(hConsole, &InputRecord, 1, &dwInput);
-                               return SC_MOUSE;
-                       }
-               }
-       }
-       return SC_ESC;
-}
-
-// FIX ME!!  This is more evidence that tncon.cpp ought to have class structure
-// (Paul Brannan 12/10/98)
-
-// Bryan Montgomery 10/14/98
-static TNetwork net;
-void setTNetwork(TNetwork tnet) {
-       net = tnet;
-}
-
-// Thomas Briggs 8/17/98
-BOOL WINAPI ControlEventHandler(DWORD event) {
-       switch(event) {
-       case CTRL_BREAK_EVENT:
-               // Bryan Montgomery 10/14/98
-               if(ini.get_control_break_as_c()) net.WriteString("\x3",1);
-               return TRUE;
-       default:
-               return FALSE;
-       }
-}
diff --git a/reactos/apps/utils/net/telnet/src/tncon.h b/reactos/apps/utils/net/telnet/src/tncon.h
deleted file mode 100644 (file)
index d8b9414..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-#ifndef __TNCON_H
-#define __TNCON_H
-
-#include "tparams.h"
-#include "tnclip.h"
-#include "ttelhndl.h"
-
-enum {
-       SC_UP,
-       SC_DOWN,
-       SC_ESC,
-       SC_MOUSE
-};
-
-enum {
-       TNNOCON,
-       TNPROMPT,
-       TNSCROLLBACK,
-       TNSPAWN,
-       TNDONE
-};
-
-int telProcessConsole(NetParams *pParams, KeyTranslator &KeyTrans,
-                                         TConsole &Console, TNetwork &Network, TMouse &Mouse,
-                                         Tnclip &Clipboard, HANDLE hThread);
-WORD scrollkeys ();
-
-// Thomas Briggs 8/17/98
-BOOL WINAPI ControlEventHandler(DWORD);
-
-// Bryan Montgomery 10/14/98
-void setTNetwork(TNetwork);
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tnconfig.cpp b/reactos/apps/utils/net/telnet/src/tnconfig.cpp
deleted file mode 100644 (file)
index 402dac7..0000000
+++ /dev/null
@@ -1,704 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-// tnconfig.cpp
-// Written by Paul Brannan <pbranna@clemson.edu>
-// Last modified August 30, 1998
-//
-// This is a class designed for use with Brad Johnson's Console Telnet
-// see the file tnconfig.h for more information
-
-#include <stdlib.h>
-#include <string.h>
-#include <locale.h>
-#include <memory.h>
-#include <io.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include "tnconfig.h"
-
-// Turn off the "forcing value to bool 'true' or 'false'" warning
-#ifdef _MSC_VER
-#pragma warning(disable: 4800)
-#endif
-
-// This is the ini variable that is used for everybody
-TConfig ini;
-
-TConfig::TConfig() {
-       // set all default values
-       startdir[0] = '\0';
-       keyfile[0] = '\0';
-       inifile[0] = '\0';
-       dumpfile[0] = '\0';
-       term[0] = '\0';
-       default_config[0] = '\0';
-       strcpy(printer_name, "LPT1");
-
-       input_redir = 0;
-       output_redir = 0;
-       strip_redir = FALSE;
-
-       dstrbksp = FALSE;
-       eightbit_ansi = FALSE;
-       vt100_mode = FALSE;
-       disable_break = FALSE;
-       speaker_beep = TRUE;
-       do_beep = TRUE;
-       preserve_colors = FALSE;
-       wrapline = TRUE;
-       lock_linewrap = FALSE;
-       fast_write = TRUE;
-       enable_mouse = TRUE;
-       alt_erase = FALSE;
-       wide_enable = FALSE;
-       keyboard_paste = FALSE;
-       set_title = TRUE;
-
-       blink_bg = -1;
-       blink_fg = 2;
-       underline_bg = -1;
-       underline_fg = 3;
-       ulblink_bg = -1;
-       ulblink_fg = 1;
-       normal_bg = -1;
-       normal_fg = -1;
-       scroll_bg = 0;
-       scroll_fg = 7;
-       status_bg = 1;
-       status_fg = 15;
-
-       buffer_size = 2048;
-
-       term_width = -1;
-       term_height = -1;
-       window_width = -1;
-       window_height = -1;
-
-       strcpy(escape_key, "]");
-       strcpy(scrollback_key, "[");
-       strcpy(dial_key, "\\");
-       strcpy(default_config, "ANSI");
-       strcpy(term, "ansi");
-
-       strcpy(scroll_mode, "DUMP");
-       scroll_size=32000;
-       scroll_enable=TRUE;
-
-       host[0] = '\0';
-       port = "23";
-
-       init_varlist();
-
-       aliases = NULL;
-}
-
-TConfig::~TConfig() {
-       if(aliases) {
-               for(int j = 0; j < alias_total; j++) delete[] aliases[j];
-               delete[] aliases;
-       }
-}
-
-enum ini_data_type {
-       INI_STRING,
-       INI_INT,
-       INI_BOOL
-};
-
-enum {
-       INIFILE,
-       KEYFILE,
-       DUMPFILE,
-       DEFAULT_CONFIG,
-       TERM,
-       INPUT_REDIR,
-       OUTPUT_REDIR,
-       STRIP_REDIR,
-       DSTRBKSP,
-       EIGHTBIT_ANSI,
-       VT100_MODE,
-       DISABLE_BREAK,
-       SPEAKER_BEEP,
-       DO_BEEP,
-       PRESERVE_COLORS,
-       WRAP_LINE,
-       LOCK_LINEWRAP,
-       FAST_WRITE,
-       TERM_WIDTH,
-       TERM_HEIGHT,
-       WINDOW_WIDTH,
-       WINDOW_HEIGHT,
-       WIDE_ENABLE,
-       CTRLBREAK_AS_CTRLC,
-       BUFFER_SIZE,
-       SET_TITLE,
-       BLINK_BG,
-       BLINK_FG,
-       UNDERLINE_BG,
-       UNDERLINE_FG,
-       ULBLINK_BG,
-       ULBLINK_FG,
-       NORMAL_BG,
-       NORMAL_FG,
-       SCROLL_BG,
-       SCROLL_FG,
-       STATUS_BG,
-       STATUS_FG,
-       PRINTER_NAME,
-       ENABLE_MOUSE,
-       ESCAPE_KEY,
-       SCROLLBACK_KEY,
-       DIAL_KEY,
-       ALT_ERASE,
-       KEYBOARD_PASTE,
-       SCROLL_MODE,
-       SCROLL_SIZE,
-       SCROLL_ENABLE,
-       SCRIPTNAME,
-       SCRIPT_ENABLE,
-       NETPIPE,
-       IOPIPE,
-
-       MAX_INI_VARS                    // must be last
-};
-
-struct ini_variable {
-       const char *name;                               // variable name
-       const char *section;                    // name of ini file section the variable is in
-       enum ini_data_type data_type;           // type of data
-       void *ini_data;                 // pointer to data
-       int  max_size;                  // max size if string
-};
-
-// Note: default values are set in the constructor, TConfig()
-ini_variable ini_varlist[MAX_INI_VARS];
-
-enum {
-       KEYBOARD,
-       TERMINAL,
-       COLORS,
-       MOUSE,
-       PRINTER,
-       SCROLLBACK,
-       SCRIPTING,
-       PIPES,
-
-       MAX_INI_GROUPS                                          // Must be last
-};
-
-char *ini_groups[MAX_INI_GROUPS];
-
-void TConfig::init_varlist() {
-       static const ini_variable static_ini_varlist[MAX_INI_VARS] = {
-               {"Inifile",             NULL,                   INI_STRING,             &inifile,       sizeof(inifile)},
-               {"Keyfile",             "Keyboard",             INI_STRING,             &keyfile,       sizeof(keyfile)},
-               {"Dumpfile",    "Terminal",             INI_STRING,             &dumpfile,      sizeof(dumpfile)},
-               {"Default_Config","Keyboard",   INI_STRING,             &default_config, sizeof(default_config)},
-               {"Term",                "Terminal",             INI_STRING,             &term,          sizeof(term)},
-               {"Input_Redir", "Terminal",             INI_INT,                &input_redir, 0},
-               {"Output_Redir","Terminal",             INI_INT,                &output_redir, 0},
-               {"Strip_Redir", "Terminal",             INI_BOOL,               &strip_redir, 0},
-               {"Destructive_Backspace","Terminal",INI_BOOL,   &dstrbksp, 0},
-               {"EightBit_Ansi","Terminal",    INI_BOOL,               &eightbit_ansi, 0},
-               {"VT100_Mode",  "Terminal",             INI_BOOL,               &vt100_mode, 0},
-               {"Disable_Break","Terminal",    INI_BOOL,               &disable_break, 0},
-               {"Speaker_Beep","Terminal",             INI_BOOL,               &speaker_beep, 0},
-               {"Beep",                "Terminal",             INI_BOOL,               &do_beep, 0},
-               {"Preserve_Colors","Terminal",  INI_BOOL,               &preserve_colors, 0},
-               {"Wrap_Line",   "Terminal",             INI_BOOL,               &wrapline, 0},
-               {"Lock_linewrap","Terminal",    INI_BOOL,               &lock_linewrap, 0},
-               {"Fast_Write",  "Terminal",             INI_BOOL,               &fast_write, 0},
-               {"Term_Width",  "Terminal",             INI_INT,                &term_width, 0},
-               {"Term_Height", "Terminal",             INI_INT,                &term_height, 0},
-               {"Window_Width","Terminal",             INI_INT,                &window_width, 0},
-               {"Window_Height","Terminal",    INI_INT,                &window_height, 0},
-               {"Wide_Enable", "Terminal",             INI_BOOL,               &wide_enable, 0},
-               {"Ctrlbreak_as_Ctrlc","Keyboard", INI_BOOL,             &ctrlbreak_as_ctrlc, 0},
-               {"Buffer_Size", "Terminal",             INI_INT,                &buffer_size, 0},
-               {"Set_Title",   "Terminal",             INI_BOOL,               &set_title, 0},
-               {"Blink_bg",    "Colors",               INI_INT,                &blink_bg, 0},
-               {"Blink_fg",    "Colors",               INI_INT,                &blink_fg, 0},
-               {"Underline_bg","Colors",               INI_INT,                &underline_bg, 0},
-               {"Underline_fg","Colors",               INI_INT,                &underline_fg, 0},
-               {"UlBlink_bg",  "Colors",               INI_INT,                &ulblink_bg, 0},
-               {"UlBlink_fg",  "Colors",               INI_INT,                &ulblink_fg, 0},
-               {"Normal_bg",   "Colors",               INI_INT,                &normal_bg, 0},
-               {"Normal_fg",   "Colors",               INI_INT,                &normal_fg, 0},
-               {"Scroll_bg",   "Colors",               INI_INT,                &scroll_bg, 0},
-               {"Scroll_fg",   "Colors",               INI_INT,                &scroll_fg, 0},
-               {"Status_bg",   "Colors",               INI_INT,                &status_bg, 0},
-               {"Status_fg",   "Colors",               INI_INT,                &status_fg,     0},
-               {"Enable_Mouse","Mouse",                INI_BOOL,               &enable_mouse, 0},
-               {"Printer_Name","Printer",              INI_STRING,             &printer_name, sizeof(printer_name)},
-               {"Escape_Key",  "Keyboard",             INI_STRING,             &escape_key, 1},
-               {"Scrollback_Key","Keyboard",   INI_STRING,             &scrollback_key, 1},
-               {"Dial_Key",    "Keyboard",             INI_STRING,             &dial_key, 1},
-               {"Alt_Erase",   "Keyboard",             INI_BOOL,               &alt_erase, 0},
-               {"Keyboard_Paste","Keyboard",   INI_BOOL,               &keyboard_paste, 0},
-               {"Scroll_Mode", "Scrollback",   INI_STRING,             &scroll_mode, sizeof(scroll_mode)},
-               {"Scroll_Size", "Scrollback",   INI_INT,                &scroll_size, 0},
-               {"Scroll_Enable","Scrollback",  INI_BOOL,               &scroll_enable, 0},
-               {"Scriptname",  "Scripting",    INI_STRING,             &scriptname, sizeof(scriptname)},
-               {"Script_enable","Scripting",   INI_BOOL,               &script_enable, 0},
-               {"Netpipe",             "Pipes",                INI_STRING,             &netpipe, sizeof(netpipe)},
-               {"Iopipe",              "Pipes",                INI_STRING,             &iopipe, sizeof(iopipe)}
-       };
-
-       static const char *static_ini_groups[MAX_INI_GROUPS] = {
-               "Keyboard",
-               "Terminal",
-               "Colors",
-               "Mouse",
-               "Printer",
-               "Scrollback",
-               "Scripting",
-               "Pipes"
-       };
-
-       memcpy(ini_varlist, static_ini_varlist, sizeof(ini_varlist));
-       memcpy(ini_groups, static_ini_groups, sizeof(ini_groups));
-}
-
-void TConfig::init(char *dirname, char *execname) {
-       // Copy temporary dirname to permanent startdir
-       strncpy(startdir, dirname, sizeof(startdir));
-       startdir[sizeof(startdir) - 1] = 0;
-
-       // Copy temp execname to permanent exename (Thomas Briggs 12/7/98)
-       strncpy(exename, execname, sizeof(exename));
-       exename[sizeof(exename) - 1] = 0;
-
-       // Initialize INI file
-       inifile_init();
-
-       // Initialize redir
-       // Note that this must be done early, so error messages will be printed
-       // properly
-       redir_init();
-
-       // Initialize aliases (Paul Brannan 1/1/99)
-       init_aliases();
-
-       // Make sure the file that we're trying to work with exists
-       int iResult = access(inifile, 04);
-
-       // Thomas Briggs 9/14/98
-       if( iResult == 0 )
-               // Tell the user what file we are reading
-               // We cannot print any messages before initializing telnet_redir
-               printm(0, FALSE, MSG_CONFIG, inifile);
-       else
-               // Tell the user that the file doesn't exist, but later read the
-               // file anyway simply to populate the defaults
-               printm(0, FALSE, MSG_NOINI, inifile);
-
-       init_vars();                                                            // Initialize misc. vars
-       keyfile_init();                                                         // Initialize keyfile
-}
-
-// Alias support (Paul Brannan 1/1/99)
-void TConfig::init_aliases() {
-       char *buffer;
-       alias_total = 0;
-
-       // Find the correct buffer size
-       // FIX ME!! some implementations of Mingw32 don't have a
-       // GetPrivateProfileSecionNames function.  What do we do about this?
-#ifndef __MINGW32__
-       {
-               int size=1024, Result = 0;
-               for(;;) {
-                       buffer = new char[size];
-                       Result = GetPrivateProfileSectionNames(buffer, size, inifile);
-                       if(Result < size - 2) break;
-                       size *= 2;
-                       delete[] buffer;
-               }
-       }
-#else
-       return;
-#endif
-
-       // Find the maximum number of aliases
-       int max = 0;
-       char *tmp;
-       for(tmp = buffer; *tmp != 0; tmp += strlen(tmp) + 1)
-               max++;
-
-       aliases = new char*[max];
-
-       // Load the aliases into an array
-       for(tmp = buffer; *tmp != 0; tmp += strlen(tmp) + 1) {
-               int flag = 0;
-               for(int j = 0; j < MAX_INI_GROUPS; j++) {
-                       if(!stricmp(ini_groups[j], tmp)) flag = 1;
-               }
-               if(!flag) {
-                       aliases[alias_total] = new char[strlen(tmp)+1];
-                       strcpy(aliases[alias_total], tmp);
-                       alias_total++;
-               }
-       }
-
-       delete[] buffer;
-}
-
-void TConfig::print_aliases() {
-       for(int j = 0; j < alias_total; j++) {
-               char alias_name[20];
-               set_string(alias_name, aliases[j], sizeof(alias_name));
-               for(unsigned int i = strlen(alias_name); i < sizeof(alias_name) - 1; i++)
-                       alias_name[i] = ' ';
-               alias_name[sizeof(alias_name) - 1] = 0;
-               printit(alias_name);
-               if((j % 4) == 3) printit("\n");
-       }
-       printit("\n");
-}
-
-bool find_alias(const char *alias_name) {
-       return false;
-}
-
-void TConfig::print_vars() {
-       int j;
-       for(j = 0; j < MAX_INI_VARS; j++) {
-               if(print_value(ini_varlist[j].name) > 40) printit("\n");
-               else if(j % 2) printit("\n");
-               else printit("\t");
-       }
-       if(j % 2) printit("\n");
-}
-
-// Paul Brannan 9/3/98
-void TConfig::print_vars(char *s) {
-       if(!strnicmp(s, "all", 3)) {                                    // Print out all vars
-               print_vars();
-               return;
-       }
-
-       // See if the group exists
-       int j, flag;
-       for(j = 0, flag = 0; j < MAX_INI_GROUPS; j++)
-               if(!stricmp(ini_groups[j], s)) break;
-       // If not, print out the value of the variable by that name
-       if(j == MAX_INI_GROUPS) {
-               print_value(s);
-               printit("\n");
-               return;
-       }
-       
-       // Print out the vars in the given group
-       int count = 0;
-       for(j = 0; j < MAX_INI_VARS; j++) {
-               if(ini_varlist[j].section == NULL) continue;
-               if(!stricmp(ini_varlist[j].section, s)) {
-                       if(print_value(ini_varlist[j].name) > 40) printit("\n");
-                       else if(count % 2) printit("\n");
-                       else printit("\t");
-                       count++;
-               }
-       }
-       if(count % 2) printit("\n");
-}
-
-// Paul Brannan 9/3/98
-void TConfig::print_groups() {
-       for(int j = 0; j < MAX_INI_GROUPS; j++) {
-               char group_name[20];
-               set_string(group_name, ini_groups[j], sizeof(group_name));
-               for(unsigned int i = strlen(group_name); i < sizeof(group_name) - 1; i++)
-                       group_name[i] = ' ';
-               group_name[sizeof(group_name) - 1] = 0;
-               printit(group_name);
-               if((j % 4) == 3) printit("\n");
-       }
-       printit("\n");
-}
-
-// Ioannou : The index in the while causes segfaults if there is no match
-// changes to for(), and strcmp to stricmp (prompt gives rong names)
-
-bool TConfig::set_value(const char *var, const char *value) {
-   //int j = 0;
-   //while(strcmp(var, ini_varlist[j].name) && j < MAX_INI_VARS) j++;
-   for (int j = 0; j < MAX_INI_VARS; j++)
-   {
-      if (stricmp(var, ini_varlist[j].name) == 0)
-      {
-         switch(ini_varlist[j].data_type) {
-            case INI_STRING:
-               set_string((char *)ini_varlist[j].ini_data, value,
-                  ini_varlist[j].max_size);
-               break;
-            case INI_INT:
-               *(int *)ini_varlist[j].ini_data = atoi(value);
-               break;
-            case INI_BOOL:
-               set_bool((bool *)ini_varlist[j].ini_data, value);
-               break;
-         }
-         // j = MAX_INI_VARS;
-                return TRUE;
-      }
-   }
-   return FALSE;
-}
-
-int TConfig::print_value(const char *var) {
-       //int j = 0;
-       //while(strcmp(var, ini_varlist[j].name) && j < MAX_INI_VARS) j++;
-       int Result = 0;
-       for (int j = 0; j < MAX_INI_VARS; j++)
-       {
-               if (stricmp(var, ini_varlist[j].name) == 0)
-               {
-                       char var_name[25];
-                       set_string(var_name, var, sizeof(var_name));
-                       for(unsigned int i = strlen(var_name); i < sizeof(var_name) - 1; i++)
-                               var_name[i] = ' ';
-                       var_name[sizeof(var_name) - 1] = 0;
-                       Result = sizeof(var_name);
-
-                       printit(var_name);
-                       printit("\t");
-                       Result = Result / 8 + 8;
-                       
-                       switch(ini_varlist[j].data_type) {
-            case INI_STRING:
-                               printit((char *)ini_varlist[j].ini_data);
-                               Result += strlen((char *)ini_varlist[j].ini_data);
-                               break;
-            case INI_INT:
-                               char buffer[20]; // this may not be safe
-                               // Ioannou : Paul this was _itoa, but Borland needs itoa !!
-                               itoa(*(int *)ini_varlist[j].ini_data, buffer, 10);
-                               printit(buffer);
-                               Result += strlen(buffer);
-                               break;
-            case INI_BOOL:
-                               if(*(bool *)ini_varlist[j].ini_data == true) {
-                                       printit("on");
-                                       Result += 2;
-                               } else {
-                                       printit("off");
-                                       Result += 3;
-                               }
-                       }
-                       // printit("\n");
-                       j = MAX_INI_VARS;
-               }
-       }
-       return Result;
-}
-
-void TConfig::init_vars() {
-       char buffer[4096];
-       for(int j = 0; j < MAX_INI_VARS; j++) {
-               if(ini_varlist[j].section != NULL) {
-                       GetPrivateProfileString(ini_varlist[j].section, ini_varlist[j].name, "",
-                               buffer, sizeof(buffer), inifile);
-                       if(*buffer != 0) set_value(ini_varlist[j].name, buffer);
-               }
-       }
-}
-
-void TConfig::inifile_init() {
-       // B. K. Oxley 9/16/98  
-       char* env_telnet_ini = getenv (ENV_TELNET_INI);
-       if (env_telnet_ini && *env_telnet_ini) {
-               strncpy (inifile, env_telnet_ini, sizeof(inifile));
-               return;
-       }
-
-       strcpy(inifile, startdir);
-       if (sizeof(inifile) >= strlen(inifile)+strlen("telnet.ini")) {
-               strcat(inifile,"telnet.ini"); // add the default filename to the path
-       } else {
-               // if there is not enough room set the path to nothing
-               strcpy(inifile,"");
-       }
-}
-
-void TConfig::keyfile_init() {
-       // check to see if there is a key config file environment variable.
-       char *k;
-       if ((k = getenv(ENV_TELNET_CFG)) == NULL){
-               // if there is no environment variable
-               GetPrivateProfileString("Keyboard", "Keyfile", "", keyfile,
-                       sizeof(keyfile), inifile);
-               if(keyfile == 0 || *keyfile == 0) {
-                       // and there is no profile string
-                       strcpy(keyfile, startdir);
-                       if (sizeof(keyfile) >= strlen(keyfile)+strlen("telnet.cfg")) {
-                               struct stat buf;
-
-                               strcat(keyfile,"telnet.cfg"); // add the default filename to the path
-                               if(stat(keyfile, &buf) != 0) {
-                                       char *s = keyfile + strlen(keyfile) - strlen("telnet.cfg");
-                                       strcpy(s, "keys.cfg");
-                               }
-                       } else {
-                               // if there is not enough room set the path to nothing
-                               strcpy(keyfile,"");
-                       }
-
-               // Vassili Bourdo (vassili_bourdo@softhome.net)
-               } else {
-                       // check that keyfile really exists
-                       if( access(keyfile,04) == -1 ) {
-                               //it does not...
-                               char pathbuf[MAX_PATH], *fn;
-                               //substitute keyfile path with startdir path
-                               if((fn = strrchr(keyfile,'\\'))) strcpy(keyfile,fn);
-                                       strcat(strcpy(pathbuf,startdir),keyfile);
-                               //check that startdir\keyfile does exist
-                               if( access(pathbuf,04) == -1 ) {
-                                       //it does not...
-                                       //so, look for it in all paths
-                                       _searchenv(keyfile, "PATH", pathbuf);
-                                       if( *pathbuf == 0 ) //no luck - revert it to INI file value
-                                               GetPrivateProfileString("Keyboard", "Keyfile", "",
-                                                       keyfile, sizeof(keyfile), inifile);
-                               } else {
-                                       strcpy(keyfile, pathbuf);
-                               }
-                       }
-               }
-               ////
-
-       } else {
-               // set the keyfile to the value of the environment variable
-               strncpy(keyfile, k, sizeof(keyfile));
-       }
-}
-
-void TConfig::redir_init() {
-       // check to see if the environment variable 'TELNET_REDIR' is not 0;
-       char* p = getenv(ENV_TELNET_REDIR);
-       if (p) {
-               input_redir = output_redir = atoi(p);
-               if((p = getenv(ENV_INPUT_REDIR))) input_redir = atoi(p);
-               if((p = getenv(ENV_OUTPUT_REDIR))) output_redir = atoi(p);
-       } else {
-               input_redir = output_redir = GetPrivateProfileInt("Terminal",
-                       "Telnet_Redir", 0, inifile);
-               input_redir = GetPrivateProfileInt("Terminal",
-                       "Input_Redir", input_redir, inifile);
-               output_redir = GetPrivateProfileInt("Terminal",
-                       "Output_Redir", output_redir, inifile);
-       }
-       if ((input_redir > 1) || (output_redir > 1))
-               setlocale(LC_CTYPE,"");
-       // tell isprint() to not ignore local characters, if the environment
-       // variable "LANG" has a valid value (e.g. LANG=de for german characters)
-       // and the file LOCALE.BLL is installed somewhere along the PATH.
-}
-
-// Modified not to use getopt() by Paul Brannan 12/17/98
-bool TConfig::Process_Params(int argc, char *argv[]) {
-       int optind = 1;
-       char *optarg = argv[optind];
-       char c;
-
-       while(optind < argc) {
-               if(argv[optind][0] != '-') break;
-
-               // getopt
-               c = argv[optind][1];
-               if(argv[optind][2] == 0)
-                       optarg = argv[++optind];
-               else
-                       optarg = &argv[optind][2];
-               optind++;
-
-               switch(c) {
-                       case 'd':
-                               set_string(dumpfile, optarg, sizeof(dumpfile));
-                               printm(0, FALSE, MSG_DUMPFILE, dumpfile);
-                               break;
-                       // added support for setting options on the command-line
-                       // (Paul Brannan 7/31/98)
-                       case '-':
-                               {
-                                       int j;
-                                       for(j = 0; optarg[j] != ' ' && optarg[j] != '=' && optarg[j] != 0; j++);
-                                       if(optarg == 0) {
-                                               printm(0, FALSE, MSG_USAGE);            // print a usage message
-                                               printm(0, FALSE, MSG_USAGE_1);
-                                               return FALSE;
-                                       }
-                                       optarg[j] = 0;
-                                       if(!set_value(optarg, &optarg[j+1]))
-                                               printm(0, FALSE, MSG_BADVAL, optarg);
-                               }
-                               break;
-                       default:
-                               printm(0, FALSE, MSG_USAGE);            // print a usage message
-                               printm(0, FALSE, MSG_USAGE_1);
-                               return FALSE;
-               }
-       }
-       if(optind < argc)
-               set_string(host, argv[optind++], sizeof(host)-1);
-       if(!strnicmp(host, "telnet://", 9)) {
-               // we have a URL to parse
-               char *s, *t;
-
-               for(s = host+9, t = host; *s != 0; *(t++) = *(s++));
-               *t = 0;
-               for(s = host; *s != ':' && *s != 0; s++);
-               if(*s != 0) {
-                       *(s++) = 0;
-                       port = s;
-               }
-       }               
-       if(optind < argc)
-               port = argv[optind++];
-
-       return TRUE;
-}
-
-void TConfig::set_string(char *dest, const char *src, const int length) {
-   int l = length;
-   strncpy(dest, src, l);
- //  dest[length-1] = '\0';
- // Ioannou : this messes strings - is this really needed ?
- // The target string, dest, might not be null-terminated
- // if the length of src is length or more.
- // it should be dest[length] = '\0' for strings with length 1
- // (Escape_string etc), but doesn't work with others (like host).
- // dest is long enough to avoid this in all the tested cases
-}
-
-// Ioannou : ignore case for true or on
-
-void TConfig::set_bool(bool *boolval, const char *str) {
-   if(!stricmp(str, "true")) *boolval = true;
-   else if(!stricmp(str, "on")) *boolval = true;
-       else *boolval = (bool)atoi(str);
-}
-
diff --git a/reactos/apps/utils/net/telnet/src/tnconfig.h b/reactos/apps/utils/net/telnet/src/tnconfig.h
deleted file mode 100644 (file)
index c0d41ee..0000000
+++ /dev/null
@@ -1,211 +0,0 @@
-// Tnconfig.h
-// Written by Paul Brannan <pbranna@clemson.edu>
-//
-// This is a class designed for use with Brad Johnson's Console Telnet
-// It reads an ini file and keeps the settings for later retrieval.
-// It does not store any information about the current settings, only default
-// or recommended settings.
-
-#ifndef __TNCONFIG_H
-#define __TNCONFIG_H
-
-// Ioannou 2 June 98:  Borland needs them - quick hack
-#ifdef __BORLANDC__
-#define bool BOOL
-#define true TRUE
-#define false FALSE
-#endif //  __BORLANDC__
-
-#include "tnerror.h"
-
-#define ENV_TELNET_CFG "TELNET_CFG"
-#define ENV_TELNET_REDIR "TELNET_REDIR"
-#define ENV_INPUT_REDIR "TELNET_INPUT_REDIR"
-#define ENV_OUTPUT_REDIR "TENLET_OUTPUT_REDIR"
-#define ENV_TELNET_INI "TELNET_INI"
-
-class TConfig {
-public:
-       TConfig();
-       ~TConfig();
-
-       // Miscellaneous strings
-       const char *get_startdir() const {return startdir;}
-       const char *get_exename() const {return exename;}
-       const char *get_keyfile() const {return keyfile;}
-       const char *get_inifile() const {return inifile;}
-       const char *get_dumpfile() const {return dumpfile;}
-       const char *get_term() const {return term;}
-       const char *get_printer_name() const {return printer_name;}
-       const char *get_default_config() const {return default_config;}
-
-       // Terminal settings
-       int get_input_redir() const {return input_redir;}
-       int get_output_redir() const {return output_redir;}
-       bool get_strip_redir() const {return strip_redir;}
-       bool get_dstrbksp() const {return dstrbksp;}
-       bool get_eightbit_ansi() const {return eightbit_ansi;}
-       bool get_vt100_mode() const {return vt100_mode;}
-       bool get_disable_break() const {return disable_break;}
-       bool get_speaker_beep() const {return speaker_beep;}
-       bool get_do_beep() const {return do_beep;}
-       bool get_preserve_colors() const {return preserve_colors;}
-       bool get_wrapline() const {return wrapline;}
-       bool get_fast_write() const {return fast_write;}
-       bool get_lock_linewrap() const {return lock_linewrap;}
-       bool get_set_title() const { return set_title;}
-       int get_term_width() const {return term_width;}
-       int get_term_height() const {return term_height;}
-       int get_window_width() const {return window_width;}
-       int get_window_height() const {return window_height;}
-       bool get_wide_enable() const {return wide_enable;}
-       bool get_control_break_as_c() const {return ctrlbreak_as_ctrlc;}
-       int get_buffer_size() const {return buffer_size;}
-
-       // Colors
-       int get_blink_bg() const {return blink_bg;}
-       int get_blink_fg() const {return blink_fg;}
-       int get_underline_bg() const {return underline_bg;}
-       int get_underline_fg() const {return underline_fg;}
-       int get_ulblink_bg() const {return ulblink_bg;}
-       int get_ulblink_fg() const {return ulblink_fg;}
-       int get_normal_bg() const {return normal_bg;}
-       int get_normal_fg() const {return normal_fg;}
-       int get_scroll_bg() const {return scroll_bg;}
-       int get_scroll_fg() const {return scroll_fg;}
-       int get_status_bg() const {return status_bg;}
-       int get_status_fg() const {return status_fg;}
-
-       // Mouse
-       bool get_enable_mouse() const {return enable_mouse;}
-
-       // Keyboard
-       char get_escape_key() const {return escape_key[0];}
-       char get_scrollback_key() const {return scrollback_key[0];}
-       char get_dial_key() const {return dial_key[0];}
-       bool get_alt_erase() const {return alt_erase;}
-       bool get_keyboard_paste() const {return keyboard_paste;}
-
-       // Scrollback
-       const char *get_scroll_mode() const {return scroll_mode;}
-       bool get_scroll_enable() const {return scroll_enable;}
-       int get_scroll_size() const {return scroll_size;}
-
-       // Scripting
-       const char *get_scriptname() const {return scriptname;}
-       bool get_script_enable() const {return script_enable;}
-
-       // Pipes
-       const char *get_netpipe() const {return netpipe;}
-       const char *get_iopipe() const {return iopipe;}
-
-       // Host configuration
-       const char *get_host() const {return host;}
-       const char *get_port() const {return port;}
-
-       // Initialization
-       void init(char *dirname, char *exename);
-       bool Process_Params(int argc, char *argv[]);
-
-       // Ini variables
-       void print_vars();
-       void print_vars(char *s);
-       void print_groups();
-       bool set_value(const char *var, const char *value);
-       int print_value(const char *var);
-
-       // Aliases
-       void print_aliases();
-       bool find_alias(const char *alias_name);
-
-private:
-
-       void inifile_init();
-       void keyfile_init();
-       void redir_init();
-       void init_varlist();
-       void init_vars();
-       void init_aliases();
-       void set_string(char *dest, const char *src, const int length);
-       void set_bool(bool *boolval, const char *str);
-
-       // Miscellaneous strings
-       char startdir[MAX_PATH];
-       char exename[MAX_PATH];
-       char keyfile[MAX_PATH*2];
-       char inifile[MAX_PATH*2];
-       char dumpfile[MAX_PATH*2];
-       char printer_name[MAX_PATH*2];
-       char term[128];
-       char default_config[128];
-
-       // Terminal
-       int input_redir, output_redir;
-       bool strip_redir;
-       bool dstrbksp;
-       bool eightbit_ansi;
-       bool vt100_mode;
-       bool disable_break;
-       bool speaker_beep;
-       bool do_beep;
-       bool preserve_colors;
-       bool wrapline;
-       bool lock_linewrap;
-       bool fast_write;
-       bool set_title;
-       int  term_width, term_height;
-       int  window_width, window_height;
-       bool wide_enable;
-       bool ctrlbreak_as_ctrlc;
-       int  buffer_size;
-
-       // Colors
-       int blink_bg;
-       int blink_fg;
-       int underline_bg;
-       int underline_fg;
-       int ulblink_bg;
-       int ulblink_fg;
-       int normal_bg;
-       int normal_fg;
-       int scroll_bg;
-       int scroll_fg;
-       int status_bg;
-       int status_fg;
-
-       // Mouse
-       bool enable_mouse;
-
-       // Keyboard
-       char escape_key[2];
-       char scrollback_key[2];
-       char dial_key[2];
-       bool alt_erase;
-       bool keyboard_paste;
-
-       // Scrollback
-       char scroll_mode[8];
-       bool scroll_enable;
-       int scroll_size;
-
-       // Scripting
-       char scriptname[MAX_PATH*2];
-       bool script_enable;
-
-       // Pipes
-       char netpipe[MAX_PATH*2];
-       char iopipe[MAX_PATH*2];
-
-       // Host configration
-       char host[128];
-       const char *port;
-
-       // Aliases
-       char **aliases;
-       int alias_total;
-
-};
-
-extern TConfig ini;
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tnerror.cpp b/reactos/apps/utils/net/telnet/src/tnerror.cpp
deleted file mode 100644 (file)
index 74249cb..0000000
+++ /dev/null
@@ -1,220 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-///////////////////////////////////////////////////////////////////////////////
-//
-// Module:             tnerror.cpp
-//
-// Contents:   error reporting
-//
-// Product:            telnet
-//
-// Revisions: June 15, 1998 Paul Brannan <pbranna@clemson.edu>
-//            May 15, 1998 Paul Brannan
-//            5.April.1997 jbj@nounname.com
-//            5.Dec.1996 jbj@nounname.com
-//            Version 2.0
-//
-//            02.Apr.1995      igor.milavec@uni-lj.si
-//                                       Original code
-//
-///////////////////////////////////////////////////////////////////////////////
-
-#include "tnerror.h"
-#include "ttelhndl.h"                  // Paul Brannan 5/25/98
-#include "tnconfig.h"          // Paul Brannan 5/25/98
-#include <time.h>
-#include <stdio.h>
-#include <stdarg.h>
-#include <stdlib.h>
-
-#ifndef LANG_USER_DEFAULT
-#define LANG_USER_DEFAULT 400
-#endif
-
-// This has been moved to tnconfig.cpp
-// int Telnet_Redir = 0;
-// Telnet_Redir is set to the value of the environment variable TELNET_REDIR
-// in main.
-
-int printit(const char * it){
-       DWORD numwritten;
-       if (!ini.get_output_redir()) {
-               if (!WriteConsole(
-                       GetStdHandle(STD_OUTPUT_HANDLE),        // handle of a console screen buffer
-                       it,     // address of buffer to write from
-                       strlen(it),     // number of characters to write
-                       &numwritten,    // address of number of characters written
-                       0       // reserved
-                       )) return -1;
-               // FIX ME!!! We need to tell the console that the cursor has moved.
-               // Does this mean making Console global?
-               // Paul Brannan 6/14/98
-               // Console.sync();
-       }else{
-               if (!WriteFile(
-                       GetStdHandle(STD_OUTPUT_HANDLE),        // handle of a console screen buffer
-                       it,     // address of buffer to write from
-                       strlen(it),     // number of characters to write
-                       &numwritten,    // address of number of characters written
-                       NULL // no overlapped I/O
-                       )) return -1;
-       }
-       return 0;
-}
-
-int printm(LPTSTR szModule, BOOL fSystem, DWORD dwMessageId, ...)
-{
-       int Result = 0;
-
-       HMODULE hModule = 0;
-       if (szModule)
-               hModule = LoadLibrary(szModule);
-
-       va_list Ellipsis;
-       va_start(Ellipsis, dwMessageId);
-
-       LPTSTR pszMessage = 0;
-       DWORD dwMessage = 0;
-       if(fSystem) {
-               dwMessage = FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER |
-                       FORMAT_MESSAGE_FROM_SYSTEM, hModule, dwMessageId,
-                       LANG_USER_DEFAULT, (LPTSTR)&pszMessage, 128, &Ellipsis);
-       } else {
-               // we will use a string table.
-               char szString[256];
-               if(LoadString(0, dwMessageId, szString, sizeof(szString)))
-                       dwMessage = FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER |
-                               FORMAT_MESSAGE_FROM_STRING, szString, dwMessageId,
-                               LANG_USER_DEFAULT, (LPTSTR)&pszMessage, 256, &Ellipsis);
-       }
-
-       va_end(Ellipsis);
-
-       if (szModule)
-               FreeLibrary(hModule);
-
-       if (dwMessage) {
-
-               Result = printit(pszMessage);
-               LocalFree(pszMessage);
-       }
-
-       return Result;
-}
-
-
-void LogErrorConsole(LPTSTR szError)
-{
-       DWORD dwLastError = GetLastError();
-
-       const int cbLastError = 1024;
-       TCHAR szLastError[cbLastError];
-       FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM, 0, dwLastError, LANG_USER_DEFAULT,
-               szLastError, cbLastError, 0);
-
-       LPTSTR lpszStrings[2];
-       lpszStrings[0] = szError;
-       lpszStrings[1] = szLastError;
-
-       const int cbErrorString = 1024;
-       TCHAR szErrorString[cbErrorString];
-       FormatMessage(FORMAT_MESSAGE_FROM_HMODULE| FORMAT_MESSAGE_ARGUMENT_ARRAY,
-               0, MSG_ERROR, LANG_USER_DEFAULT,
-               szErrorString, cbErrorString, (va_list*)lpszStrings);
-
-       time_t dwTime;
-       time(&dwTime);
-       char* szTime = ctime(&dwTime);
-       szTime[19] = 0;
-
-       //      printf("E %s %s", szTime + 11, szErrorString);
-       char * buf;
-       buf = new char [ 3 + strlen(szTime) - 11 + strlen(szErrorString) + 5 ];
-       sprintf( buf,"E %s %s", szTime + 11, szErrorString);
-       printit(buf);
-       delete [] buf;
-}
-
-
-void LogWarningConsole(DWORD dwEvent, LPTSTR szWarning)
-{
-       DWORD dwLastError = GetLastError();
-
-       const int cbLastError = 1024;
-       TCHAR szLastError[cbLastError];
-       FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM, 0, dwLastError, LANG_USER_DEFAULT,
-               szLastError, cbLastError, 0);
-
-       LPTSTR lpszStrings[2];
-       lpszStrings[0] = szWarning;
-       lpszStrings[1] = szLastError;
-
-       const int cbWarningString = 1024;
-       TCHAR szWarningString[cbWarningString];
-       FormatMessage(FORMAT_MESSAGE_FROM_HMODULE| FORMAT_MESSAGE_ARGUMENT_ARRAY,
-               0, dwEvent, LANG_USER_DEFAULT,
-               szWarningString, cbWarningString, (va_list*)lpszStrings);
-
-       time_t dwTime;
-       time(&dwTime);
-       char* szTime = ctime(&dwTime);
-       szTime[19] = 0;
-
-       //      printf("W %s %s", szTime + 11, szWarningString);
-       char * buf;
-       buf = new char [ 3 + strlen(szTime) - 11 + strlen(szWarningString) + 5 ];
-       sprintf(buf ,"W %s %s", szTime + 11, szWarningString);
-       printit(buf);
-       delete [] buf;
-
-}
-
-
-void LogInfoConsole(DWORD dwEvent, LPTSTR szInformation)
-{
-       LPTSTR lpszStrings[1];
-       lpszStrings[0] = szInformation;
-
-       const int cbInfoString = 1024;
-       TCHAR szInfoString[cbInfoString];
-       FormatMessage(FORMAT_MESSAGE_FROM_HMODULE| FORMAT_MESSAGE_ARGUMENT_ARRAY,
-               0, dwEvent, LANG_USER_DEFAULT,
-               szInfoString, cbInfoString, (va_list*)lpszStrings);
-
-       time_t dwTime;
-       time(&dwTime);
-       char* szTime = ctime(&dwTime);
-       szTime[19] = 0;
-
-       //      printf("I %s %s", szTime + 11, szInfoString);
-       char * buf;
-       buf = new char [ 3 + strlen(szTime) - 11 + strlen(szInfoString) + 5 ];
-       sprintf(buf,"I %s %s", szTime + 11, szInfoString);
-       printit(buf);
-       delete [] buf;
-
-}
-
diff --git a/reactos/apps/utils/net/telnet/src/tnerror.h b/reactos/apps/utils/net/telnet/src/tnerror.h
deleted file mode 100644 (file)
index a7ada28..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-#ifndef __TNERROR_H
-#define __TNERROR_H
-
-#ifndef __WINDOWS_H
-#include <windows.h>
-#endif
-
-#include "tnmsg.h"
-
-extern int Telnet_Redir;
-
-int printm(LPTSTR szModule, BOOL fSystem, DWORD dwMessageId, ...);
-void LogErrorConsole(LPTSTR szError);
-int printit(const char * it);
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tnetwork.cpp b/reactos/apps/utils/net/telnet/src/tnetwork.cpp
deleted file mode 100644 (file)
index 64eed9b..0000000
+++ /dev/null
@@ -1,92 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-///////////////////////////////////////////////////////////////////////////////
-//
-// Module:             tnetwork.cpp
-//
-// Contents:   telnet network module
-//
-// Product:            telnet
-//
-// Revisions:  March 18, 1999          Paul Brannan (pbranna@clemson.edu)
-//
-///////////////////////////////////////////////////////////////////////////////
-
-#include "tnetwork.h"
-
-void TNetwork::SetSocket(SOCKET s) {
-       socket = s;
-       net_type = TN_NETSOCKET;
-       local_echo = line_mode = 1;
-}
-
-void TNetwork::SetPipe(HANDLE pIn, HANDLE pOut) {
-       pipeIn = pIn;
-       pipeOut = pOut;
-       net_type = TN_NETPIPE;
-       local_echo = line_mode = 0;
-}
-
-int TNetwork::WriteString(const char *str, const int length) {
-       switch(net_type) {
-       case TN_NETSOCKET:
-               return send(socket, str, length, 0);
-       case TN_NETPIPE:
-               {
-                       DWORD dwWritten;
-                       if(!WriteFile(pipeOut, str, length, &dwWritten, (LPOVERLAPPED)NULL)) return -1;
-                       return dwWritten;
-               }
-       }
-       return 0;
-}
-
-int TNetwork::ReadString (char *str, const int length) {
-       switch(net_type) {
-       case TN_NETSOCKET:
-               return recv(socket, str, length, 0);
-       case TN_NETPIPE:
-               {
-                       DWORD dwRead;
-                       if(!ReadFile(pipeIn, str, length, &dwRead, (LPOVERLAPPED)NULL)) return -1;
-                       return dwRead;
-               }
-       }
-       return 0;
-}
-
-void TNetwork::do_naws(int width, int height) {
-       if(!naws_func) return;
-       char buf[100];
-       int len = (*naws_func)(buf, width, height);
-       WriteString(buf, len);
-}
-
-void TNetwork::SetLocalAddress(char *buf) {
-       local_address = new char[strlen(buf) + 1];
-       strcpy(local_address, buf);
-}
-
diff --git a/reactos/apps/utils/net/telnet/src/tnetwork.h b/reactos/apps/utils/net/telnet/src/tnetwork.h
deleted file mode 100644 (file)
index 64dfb11..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-// This is a simple class to handle socket connections
-// (Paul Brannan 6/15/98)
-
-#ifndef __TNETWORK_H
-#define __TNETWORK_H
-
-#include <windows.h>
-
-enum NetworkType {TN_NETSOCKET, TN_NETPIPE};
-
-typedef int(*Naws_func_t)(char *, int, int);
-
-class TNetwork {
-private:
-       SOCKET socket;
-       BOOL local_echo;                                        // Paul Brannan 8/25/98
-       BOOL line_mode;                                         // Paul Brannan 12/31/98
-       NetworkType net_type;                           // Paul Brannan 3/18/99
-       HANDLE pipeIn, pipeOut;                         // Paul Brannan 3/18/99
-       Naws_func_t naws_func;
-       char *local_address;
-
-public:
-       TNetwork(SOCKET s = 0): socket(s), local_echo(1), line_mode(1),
-               net_type(TN_NETSOCKET), naws_func((Naws_func_t)NULL),
-               local_address((char *)NULL) {}
-       ~TNetwork() {if(local_address) delete local_address;}
-
-       void SetSocket(SOCKET s);
-       SOCKET GetSocket() {return socket;}
-       void SetPipe(HANDLE pIn, HANDLE pOut);
-       void SetNawsFunc(Naws_func_t func) {naws_func = func;}
-       void SetLocalAddress(char *buf);
-       const char* GetLocalAddress() {return local_address;}
-
-       NetworkType get_net_type() {return net_type;}
-
-       int WriteString(const char *str, const int length);
-       int ReadString (char *str, const int length);
-
-       BOOL get_local_echo() {return local_echo;}
-       void set_local_echo(BOOL b) {local_echo = b;}
-
-       BOOL get_line_mode() {return line_mode;}
-       void set_line_mode(BOOL b) {line_mode = b;}
-
-       void do_naws(int width, int height);
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tnmain.cpp b/reactos/apps/utils/net/telnet/src/tnmain.cpp
deleted file mode 100644 (file)
index d2148bd..0000000
+++ /dev/null
@@ -1,718 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998  Paul Brannan
-//Copyright (C) 1998  I.Ioannou
-//Copyright (C) 1997  Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-///////////////////////////////////////////////////////////////////////////////
-//
-// Module:             tnmain.cpp
-//
-// Contents:   telnet main program
-//
-// Product:            telnet
-//
-// Revisions: August 11, 1998  Thomas Briggs <tbriggs@qmetric.com>
-//            May 14, 1998             Paul Brannan <pbranna@clemson.edu>
-//            5.April.1997             jbj@nounname.com
-//            5.Dec.1996               jbj@nounname.com
-//            Version 2.0
-//
-//            02.Apr.1995              igor.milavec@uni-lj.si
-//                                       Original code
-//
-///////////////////////////////////////////////////////////////////////////////
-
-#include <string.h>
-#include <locale.h>
-#include "tnmain.h"
-#include "tnmisc.h"
-
-int telCommandLine (Telnet &MyConnection);
-
-void waitforkey() {
-       HANDLE hConsole = GetStdHandle(STD_INPUT_HANDLE);
-       INPUT_RECORD InputRecord;
-       DWORD dwInput;
-       BOOL done = FALSE;
-       while (!done){
-               WaitForSingleObject( hConsole, INFINITE );
-               if (!ReadConsoleInput(hConsole, &InputRecord, 1, &dwInput)){
-                       done = TRUE;
-                       continue;
-               }
-               if (InputRecord.EventType == KEY_EVENT &&
-                       InputRecord.Event.KeyEvent.bKeyDown )
-                       done = TRUE;
-       }
-}
-
-//char * cfgets ( char * buf, unsigned int length, char pszHistory[][80], int iHistLength){
-struct cmdHistory * cfgets (char *buf, unsigned int length, struct cmdHistory *cmdhist) {
-
-       HANDLE hConsole = GetStdHandle(STD_INPUT_HANDLE);
-       unsigned int current=0, cursor =0, iEraseLength=0, i;
-       char chr;
-       char temp[2];
-       char temp1[80];
-       
-       INPUT_RECORD InputRecord;
-       BOOL done = FALSE;
-
-       temp[1] = 0;
-       buf[0] = '\0';
-
-       if(!ini.get_input_redir()) {
-               while (!done) {
-                       DWORD dwInput;
-                       int MustRefresh = 0;
-                       WaitForSingleObject( hConsole, INFINITE );
-                       if (!ReadConsoleInput(hConsole, &InputRecord, 1, &dwInput)){
-                               done = TRUE;
-                               continue;
-                       }
-                       MustRefresh = 0;
-                       if (InputRecord.EventType == KEY_EVENT &&
-                               InputRecord.Event.KeyEvent.bKeyDown ) {
-                               
-                               if(InputRecord.Event.KeyEvent.dwControlKeyState &
-                                       (LEFT_CTRL_PRESSED | RIGHT_CTRL_PRESSED)) {
-                                       
-                                       switch(InputRecord.Event.KeyEvent.wVirtualKeyCode) {
-                                       case 'D': // Thomas Briggs 8/11/98
-                                               buf[0] = '\04';
-                                               buf[1] = '\0';
-                                               current = 1;
-                                               done = true;
-                                               continue;
-                                       case 'U': // Paul Brannan 8/11/98
-                                               buf[0] = '\0';
-                                               current = 0;
-                                               cursor = 0;
-                                               MustRefresh = 1;
-                                               break;
-                                       }
-                               }
-                               
-                               switch (InputRecord.Event.KeyEvent.wVirtualKeyCode) {
-                               case VK_UP:
-                                       // crn@ozemail.com.au
-                                       if (cmdhist != NULL) {
-                                               if (!strcmp(buf, ""))
-                                                       strncpy(buf, cmdhist->cmd, 79);
-                                               else if (cmdhist->prev != NULL) {
-                                                       cmdhist = cmdhist->prev;
-                                                       strncpy(buf, cmdhist->cmd, 79);
-                                               }
-                                               current = strlen(buf);
-                                       }
-                                       ///
-                                       MustRefresh = 1;
-                                       break;
-                               case VK_DOWN:
-                                       // crn@ozemail.com.au
-                                       if (cmdhist != NULL) {
-                                               if (cmdhist->next != NULL) {
-                                                       cmdhist = cmdhist->next;
-                                                       strncpy(buf, cmdhist->cmd, 79);
-                                               } else {
-                                                       strncpy(buf, "", 79);
-                                               }
-                                               current = strlen(buf);
-                                       }
-                                       ///
-                                       MustRefresh = 1;
-                                       break;
-                               case VK_RIGHT:          //crn@ozemail.com.au (added ctrl+arrow)
-                                       if (cursor < current)
-                                               if (InputRecord.Event.KeyEvent.dwControlKeyState &
-                                                       (LEFT_CTRL_PRESSED | RIGHT_CTRL_PRESSED)) {
-                                                       unsigned int j, k;
-                                                       for (j = cursor; j <= current; j++)
-                                                               if (buf[j+1] == ' ' || (j+1)==current)
-                                                                       break;
-                                                               for (k = ++j; k <= current; k++)
-                                                                       if (buf[k] != ' ' || k == current) {
-                                                                               cursor = k == current ? --k : k;
-                                                                               break;
-                                                                       }
-                                               } else
-                                                       cursor++;
-                                               MustRefresh = 1;
-                                               break;
-                               case VK_LEFT:           //crn@ozemail.com.au (added ctrl+arrow)
-                                       if (cursor > 0)
-                                               if(InputRecord.Event.KeyEvent.dwControlKeyState &
-                                                       (LEFT_CTRL_PRESSED | RIGHT_CTRL_PRESSED)) {
-                                                       int j, k;
-                                                       for (j = cursor; j >= 0; j--)
-                                                               if (buf[j-1] != ' ')
-                                                                       break;
-                                                               for (k = --j; k >= 0; k--)
-                                                                       if (buf[k] == ' ' || k == 0) {
-                                                                               cursor = !k ? k : ++k;
-                                                                               break;
-                                                                       }
-                                               } else
-                                                       cursor--;
-                                               MustRefresh = 1;
-                                               break;
-                               case VK_HOME:
-                                       if (cursor>0) cursor = 0;
-                                       MustRefresh = 1;
-                                       break;
-                               case VK_END:
-                                       if (cursor<current) cursor = current;
-                                       MustRefresh = 1;
-                                       break;
-                               case VK_DELETE:
-                                       if (current > 0 && current > cursor) {
-                                               strcpy(&buf[cursor],&buf[cursor+1]);
-                                               current--;
-                                               buf[current] = 0;
-                                               printit("\r");
-                                               for (i = 0; i < current+strlen("telnet>")+1 ;i++)
-                                                       printit(" ");
-                                       }
-                                       MustRefresh = 1;
-                                       break;
-                               case VK_BACK:
-                                       if (cursor > 0 ) {
-                                               strcpy(&buf[cursor-1],&buf[cursor]);
-                                               current--;
-                                               cursor--;
-                                               buf[current] = 0;
-                                               printit("\r");
-                                               for (i = 0; i < current+strlen("telnet>")+1 ;i++)
-                                                       printit(" ");
-                                       }
-                                       MustRefresh = 1;
-                                       break;
-                                       
-                               default:
-                                       chr = InputRecord.Event.KeyEvent.uChar.AsciiChar;
-                                       if (chr == '\r') {
-                                               done = TRUE;
-                                               continue;
-                                       }
-                                       if (current >= length-1){
-                                               done = TRUE;
-                                               continue;
-                                       }
-                                       if ( isprint (chr) ){
-                                               strncpy(temp1,&buf[cursor],79);
-                                               strncpy(&buf[cursor+1],temp1,79-(cursor+1));
-                                               buf[cursor++]=chr;
-                                               current++;
-                                               buf[current] = 0;
-                                               MustRefresh = 1;
-                                       }
-                                       break;
-                               }
-                               if (MustRefresh == 1)
-                               {
-                                       printit("\rtelnet");
-                                       for (i = 0; i <= iEraseLength ;i++)
-                                               printit(" ");
-                                       printit("\rtelnet>");
-                                       printit(buf);
-                                       iEraseLength = strlen(buf);
-                                       for (i = 0; i < current-cursor; i++)
-                                               printit("\b");
-                               }
-                       }
-               }
-               buf[current] = 0;
-               if (strcmp(buf, "")) {
-                       if (cmdhist == NULL) {
-                               cmdhist = new struct cmdHistory;
-                               if (cmdhist == NULL) {
-                                       printit ("\nUnable to allocate memory for history buffer -- use the \"flush\" command to clear the buffer.\n");
-                                       return cmdhist;
-                               }
-                               strncpy(cmdhist->cmd, buf, 79);
-                               cmdhist->next = NULL;
-                               cmdhist->prev = NULL;
-                       } else {
-                               while (cmdhist->next != NULL)   //  move to the end of the list
-                                       cmdhist = cmdhist->next;
-                               cmdhist->next = new struct cmdHistory;
-                               if (cmdhist->next == NULL) {
-                                       printit ("\nUnable to allocate memory for history buffer -- use the \"flush\" command to clear the buffer.\n");
-                                       return cmdhist;
-                               }
-                               cmdhist->next->prev = cmdhist;  //  previous is where we are now
-                               cmdhist = cmdhist->next;
-                               strncpy(cmdhist->cmd, buf, 79);
-                               cmdhist->next = NULL;
-                       }
-                       while (cmdhist->next)
-                               cmdhist = cmdhist->next;
-               }
-               return cmdhist;
-               ///
-       } else {
-               WaitForSingleObject( hConsole, INFINITE );
-               DWORD dwInput;
-               DWORD OldMode;
-               GetConsoleMode(hConsole, &OldMode);
-               SetConsoleMode(hConsole,
-                       OldMode &~ (ENABLE_ECHO_INPUT | ENABLE_LINE_INPUT) );
-               while (ReadFile(hConsole, &chr, 1, &dwInput, NULL)) {
-                       if (chr == '\r') {
-                               temp[0] = chr;
-                               printit(&temp[0]);
-                               break;
-                       }
-                       if (chr == '\b' && current > 0) {
-                               current--;
-                               printit("\b \b");
-                       }
-                       if (current >= length-1){
-                               break;
-                       }
-                       if ( isprint (chr) ){
-                               temp[0] = chr;
-                               printit(&temp[0]);
-                               buf[current++]=chr;
-                       }
-               }
-               buf[current] = 0;
-               SetConsoleMode(hConsole, OldMode);
-               return NULL;
-       }
-}
-
-// AVS ** for fix bug in command 'keys load keymapname' without file
-// static char keyfile[MAX_PATH*2];
-
-int main(int ArgC, char* ArgV[]) {
-
-       CONSOLE_SCREEN_BUFFER_INFO  ConsoleScreenBufferInfo;
-       GetConsoleScreenBufferInfo(
-               GetStdHandle(STD_OUTPUT_HANDLE),
-               &ConsoleScreenBufferInfo
-               );
-       
-       char *k;
-       char startdir[MAX_PATH*2];
-       char exename[MAX_PATH];
-       
-       // strncpy(startdir, ArgV[0],MAX_PATH);
-       // This should be more accurate than using argv[0] (Paul Brannan 9/16/98)
-       GetModuleFileName(NULL, startdir, sizeof(startdir));
-
-       // Get the current console title so it can be set later
-       // ("Pedro A. Aranda Gutiérrez" <paag@coppi.tid.es>)
-       TCHAR ConsoleTitle[255];
-       GetConsoleTitle(ConsoleTitle, sizeof(ConsoleTitle));
-       
-       k = strrchr(startdir, '\\');
-       if (k == NULL){                                         // if the \ character is not found...
-               strcpy(exename, startdir);
-               strcpy(startdir,"");                    // set the path to nothing
-       } else {
-               // end the string after the last '\' to get rid of the file name
-               strcpy(exename, k+1);
-               k[1] = 0;
-       }
-
-       printm(0, FALSE, MSG_COPYRIGHT);
-       printm(0, FALSE, MSG_COPYRIGHT_1);
-       
-       // set up the ini class
-       ini.init(startdir, exename);                                    
-
-       // Process the command line arguments and connect to a host if necessary
-       if(ini.Process_Params(ArgC, ArgV)) {
-               const char *szHost = ini.get_host();
-               const char *strPort = ini.get_port();
-               if(!*szHost) {
-                       Telnet MyConnection;
-                       while(telCommandLine(MyConnection));
-               } else {
-                       Telnet MyConnection;
-                       if(MyConnection.Open(szHost, strPort) == TNPROMPT) {
-                               // still connected
-                               printit("\n");
-                               telCommandLine(MyConnection);
-                       }
-               }
-       }
-       //// (Paul Brannan 5/14/98)
-       
-       if(ini.get_term_width() != -1 || ini.get_term_height() != -1) {
-               SetConsoleScreenBufferSize(
-                       GetStdHandle(STD_OUTPUT_HANDLE),        // handle of console screen buffer
-                       ConsoleScreenBufferInfo.dwSize          // new size in character rows and cols.
-                       );
-               SetConsoleWindowInfo(
-                       GetStdHandle(STD_OUTPUT_HANDLE),        // handle of console screen buffer
-                       TRUE,                                                           // coordinate type flag
-                       &ConsoleScreenBufferInfo.srWindow       // address of new window rectangle
-                       );
-       }
-       SetConsoleTextAttribute(
-               GetStdHandle(STD_OUTPUT_HANDLE),                // handle of console screen buffer
-               ConsoleScreenBufferInfo.wAttributes     // text and background colors
-               );
-
-       // Restore the original console title
-       // ("Pedro A. Aranda Gutiérrez" <paag@coppi.tid.es>)
-       SetConsoleTitle(ConsoleTitle);
-
-       return 0;
-}
-
-// AVS
-enum {
-       BAD_USAGE = -3,
-               EMPTY_LINE = -2,
-               INVALID_CMD = -1,
-               __FIRST_COMMAND = 0,
-               
-               OPEN = __FIRST_COMMAND,
-               CLOSE,
-               KEYS,
-               QUIT,
-               HELP,
-               HELP2,                          // there is way for synonims
-               K_LOAD,                         // subcommand of 'keys'
-               K_SWITCH,                       // subcommand of 'keys'
-               K_DISPLAY,                      // subcommand of 'keys'
-               
-               SET,                            // Paul Brannan 5/30/98
-               
-               SUSPEND,
-               FASTQUIT,                       // Thomas Briggs 8/11/98
-               CMD_HISTORY,            // crn@ozemail.com.au
-               CLEAR_HISTORY,          // crn@ozemail.com.au
-               
-               ALIASES,                        // Paul Brannan 1/1/99
-               
-               __COMMAND_LIST_SIZE     // must be last
-};
-
-
-struct command {
-       const char* cmd;                                // command
-       int   minLen,                   // minimal length for match
-                 minParms,                     // minimal count of parms
-                 maxParms;                     // maximal -/- (negative disables)
-       int   isSubCmd,                 // is a subcommand - number of wich command
-                 haveSubCmd;           // have subcommands? 0 or 1
-       const char* usage;                      // text of usage
-};
-
-command cmdList[__COMMAND_LIST_SIZE] = {
-       {"open",     1, 1,  2,  -1,             0,      "o[pen] host [port]\n"},
-       {"close",    2, 0,  0,  -1,             0,      NULL},
-       {"keys",     2, 1,  3,  -1,             1,      "ke[ys] l[oad] keymapname [file]\n"
-                                                                               "ke[ys] d[isplay]\n"
-                                                                               "ke[ys] s[witch] number\n"},
-       // Ioannou : i change it to q, to be more compatible with unix telnet
-       {"quit",     1, 0,  0,  -1,             0,      NULL}, // must type it exactly
-       {"?",        1, 0,  0,  -1,             0,      NULL},
-       {"help",     1, 0,  0,  -1,             0,      NULL},
-       {"load",     1, 1,  2,  KEYS,   0,      NULL},
-       {"switch",   1, 1,  1,  KEYS,   0,      NULL},
-       {"display",  1, 0,  0,  KEYS,   0,      NULL},
-       // Paul Brannan 5/30/98
-       {"set",      3, 0,      2,      -1,             0,      "set will display available groups.\n"
-                                                                               "set groupname will display all variables/values in a group.\n"
-                                                                               "set [variable [value]] will set variable to value.\n"},
-       // Thomas Briggs 8/11/98
-       {"z",           1,      0,      0,      -1,             0,      "suspend telnet\n"},
-       {"\04",         1,      0,      0,      -1,             0,      NULL},
-       // crn@ozemail.com.au
-       {"history",     2,      0,      0,      -1,     0,      "show command history"},
-       {"flush",       2,      0,      0,      -1,     0,      "flush history buffer"},
-       // Paul Brannan 1/1/99
-       {"aliases",     5,      0,      0,      -1,             0,      NULL}
-};
-
-// a maximal count of parms
-#define MAX_PARM_COUNT 3
-#define MAX_TOKEN_COUNT (MAX_PARM_COUNT+2)
-
-static int cmdMatch(const char* cmd, const char* token, int tokenLen, int minM) {
-    if ( tokenLen < minM ) return 0;
-       // The (unsigned) gets rid of a compiler warning (Paul Brannan 5/25/98)
-    if ( (unsigned)tokenLen > strlen(cmd) ) return 0;
-    if ( strcmp(cmd,token) == 0 ) return 1;
-       
-    int i;
-    for ( i = 0; i < minM; i++ ) if ( cmd[i] != token[i] ) return 0;
-       
-    for ( i = minM; i < tokenLen; i++ ) if ( cmd[i] != token[i] ) return 0;
-       
-    return 1;
-};
-
-static void printUsage(int cmd) {
-       if ( cmdList[cmd].usage != NULL ) {
-               printit(cmdList[cmd].usage);
-               return;
-       };
-       if ( cmdList[cmd].isSubCmd >= 0 ) {
-               printUsage(cmdList[cmd].isSubCmd);
-               return;
-          }
-          printm(0, FALSE, MSG_BADUSAGE);
-};
-
-int tokenizeCommand(char* szCommand, int& argc, char** argv) {
-    char* tokens[MAX_TOKEN_COUNT];
-    char* p;
-    int   args = 0;
-
-       if(!szCommand || !*szCommand) return EMPTY_LINE;
-
-       // Removed strtok to handle tokens with spaces; this is handled with
-       // quotes.  (Paul Brannan 3/18/99)
-       char *token_start = szCommand;
-       for(p = szCommand;; p++) {
-               if(*p == '\"') {
-                       char *tmp = p;
-                       for(p++; *p != '\"' && *p != 0; p++);   // Find the next quote
-                       if(*p != 0) strcpy(p, p + 1);                   // Remove quote#2
-                       strcpy(tmp, tmp + 1);                                   // Remove quote#1
-               }
-               if(*p == 0 || *p == ' ' || *p == '\t') {
-                       tokens[args] = token_start;
-                       args++;
-                       if(args >= MAX_TOKEN_COUNT) break;              // Break if too many args
-                       token_start = p + 1;
-                       if(*p == 0) break;
-                       *p = 0;
-               }
-       }
-       // while ( (p = strtok((args?NULL:szCommand), " \t")) != NULL && args < MAX_TOKEN_COUNT ) {
-       //      tokens[args] = p;
-       //      args++;
-       // };
-       
-    if ( !args ) return EMPTY_LINE;
-    argc = args - 1;
-    args = 0;
-    int curCmd = -1;
-    int ok = -1;
-    while ( ok < 0 ) {
-               int tokenLen = strlen(tokens[args]);
-               int match = 0;
-               for ( int i = 0; i<__COMMAND_LIST_SIZE; i++ ) {
-                       if ( cmdMatch(cmdList[i].cmd, tokens[args], tokenLen, cmdList[i].minLen) ) {
-                               if (argc < cmdList[i].minParms || argc > cmdList[i].maxParms) {
-                                       printUsage(i);
-                                       return BAD_USAGE;
-                               };
-                               if ( cmdList[i].haveSubCmd && curCmd == cmdList[i].isSubCmd) {
-                                       curCmd = i;
-                                       args++;
-                                       argc--;
-                                       match = 1;
-                                       break;
-                               };
-                               if ( curCmd == cmdList[i].isSubCmd ) {
-                                       ok = i;
-                                       match = 1;
-                                       break;
-                               };
-                               printUsage(i);
-                               return BAD_USAGE;
-                       };
-               };
-               if ( !match ) {
-                       if ( curCmd < 0 ) return INVALID_CMD;
-                       printUsage(curCmd);
-                       return -3;
-               };
-    };
-       
-    for ( int i = 0; i<argc; i++ ) {
-        argv[i] = tokens[i+args+1];
-    };
-    return ok;
-       
-};
-
-int telCommandLine (Telnet &MyConnection){
-#define HISTLENGTH 25
-       int i, retval;
-       char* Parms[MAX_PARM_COUNT];
-       char szCommand[80];
-       int bDone = 0;
-       char *extitle, *newtitle;
-       struct cmdHistory *cmdhist;
-       cmdhist = NULL;
-       
-       // printit("\n");  // crn@ozemail.com.au 14/12/98
-       while (!bDone){
-               // printit("\n"); // Paul Brannan 5/25/98
-               printit( "telnet>");
-               cmdhist = cfgets (szCommand, 79, cmdhist);
-               printit( "\n");
-
-               strlwr(szCommand);  // convert command line to lower
-               // i = sscanf(szCommand,"%80s %80s %80s %80s", szCmd, szArg1, szArg2, szArg3);
-               switch ( tokenizeCommand(szCommand, i, Parms) ) {
-               case BAD_USAGE:   break;
-               case EMPTY_LINE:  
-                       if(MyConnection.Resume() == TNPROMPT) {
-                               printit("\n");
-                               break;
-                       }
-                       else
-                               return 1;
-               case INVALID_CMD:
-                       printm(0, FALSE, MSG_INVCMD);
-                       break;                  
-               case OPEN:
-                       if (i == 1)
-                               retval = MyConnection.Open(Parms[0], "23");
-                       else
-                               retval = MyConnection.Open(Parms[0], Parms[1]);
-                       if(retval != TNNOCON && retval != TNPROMPT) return 1;
-                       if(retval == TNPROMPT) printit("\n");
-                       break;
-               case CLOSE:
-                       MyConnection.Close();
-                       break;
-               case FASTQUIT: // Thomas Briggs 8/11/98
-               case QUIT:
-                       MyConnection.Close();
-                       bDone = 1;
-                       break;
-               case HELP:
-               case HELP2:
-                       printm(0, FALSE, MSG_HELP);
-                       printm(0, FALSE, MSG_HELP_1);
-                       break;
-                       // case KEYS: we should never get it
-               case K_LOAD:
-                       if ( i == 1 ) {
-                               // Ioannou : changed to ini.get_keyfile()
-                               if(MyConnection.LoadKeyMap( ini.get_keyfile(), Parms[0]) != 1)
-                                       printit("Error loading keymap.\n");
-                               break;
-                       };
-                       if(MyConnection.LoadKeyMap( Parms[1], Parms[0]) != 1)
-                               printit("Error loading keymap.\n");
-                       break;
-               case K_DISPLAY:
-                       MyConnection.DisplayKeyMap();
-                       break;
-               case K_SWITCH:
-                       MyConnection.SwitchKeyMap(atoi(Parms[0]));
-                       break;
-                       
-                       // Paul Brannan 5/30/98
-               case SET:
-                       if(i == 0) {
-                               printit("Available groups:\n");         // Print out groups
-                               ini.print_groups();                                     // (Paul Brannan 9/3/98)
-                       } else if(i == 1) {
-                               ini.print_vars(Parms[0]);
-                       } else if(i >= 2) {
-                               ini.set_value(Parms[0], Parms[1]);
-                               // FIX ME !!! Ioannou: here we must call the parser routine for
-                               // wrap line, not the ini.set_value
-                               //  something like Parser.ConLineWrap(Wrap_Line);
-                       }
-                       break;
-                       
-               case SUSPEND: // Thomas Briggs 8/11/98
-                       
-                       // remind the user we're suspended -crn@ozemail.com.au 15/12/98
-                       extitle = new char[128];
-                       GetConsoleTitle (extitle, 128);
-                       
-                       newtitle = new char[128+sizeof("[suspended]")];
-                       strcpy(newtitle, extitle);
-                       strncat(newtitle, "[suspended]", 128+sizeof("[suspended]"));
-                       if(ini.get_set_title()) SetConsoleTitle (newtitle);
-                       delete[] newtitle;
-                       
-                       if (getenv("comspec") == NULL) {
-                               switch (GetWin32Version()) {
-                               case 2:         // 'cmd' is faster than 'command' in NT -crn@ozemail.com.au
-                                       system ("cmd");
-                                       break;
-                               default:
-                                       system ("command");
-                                       break;
-                               }
-                       } else {
-                               system(getenv("comspec"));
-                       }
-                       
-                       if(ini.get_set_title()) SetConsoleTitle (extitle);
-                       delete[] extitle;
-                       ///
-                       
-                       break;
-                       
-               case CMD_HISTORY:       //crn@ozemail.com.au
-                       if (cmdhist != NULL) {
-                               while (cmdhist->prev != NULL)
-                                       cmdhist = cmdhist->prev;        //rewind
-                               printf ("Command history:\n");
-                               while (1) {
-                                       printf ("\t%s\n", cmdhist->cmd);
-                                       
-                                       if (cmdhist->next != NULL)
-                                               cmdhist = cmdhist->next;
-                                       else
-                                               break;
-                               }
-                       } else
-                               printf ("No command history available.\n");
-                       
-                       break;
-                       
-               case CLEAR_HISTORY:     //crn@ozemail.com.au
-                       if (cmdhist != NULL) {
-                               while (cmdhist->next != NULL)
-                                       cmdhist = cmdhist->next;        //fast forward
-                               while (cmdhist->prev != NULL) {
-                                       cmdhist = cmdhist->prev;
-                                       delete cmdhist->next;
-                               }
-                               delete cmdhist;
-                               cmdhist = NULL;
-                               printf ("Command history cleared.\n");
-                       } else
-                               printf ("No command history available.\n");
-                       
-               case ALIASES: // Paul Brannan 1/1/99
-                       ini.print_aliases();
-                       break;
-                       
-               default: // paranoik
-                       printm(0, FALSE, MSG_INVCMD);
-                       break;
-               }
-
-       }
-
-       return 0;
-}
diff --git a/reactos/apps/utils/net/telnet/src/tnmain.h b/reactos/apps/utils/net/telnet/src/tnmain.h
deleted file mode 100644 (file)
index 526742c..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-#ifndef __TNMAIN_H
-#define __TNMAIN_H
-
-#include <stdlib.h>
-#include <process.h>
-#include "tncon.h"
-#include "tnclass.h"
-#include "ttelhndl.h"
-#include "tnerror.h"
-// Paul Brannan 5/25/98
-#include "tnconfig.h"
-
-struct cmdHistory {
-       char cmd[80];
-       struct cmdHistory *next;
-       struct cmdHistory *prev;
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tnmisc.cpp b/reactos/apps/utils/net/telnet/src/tnmisc.cpp
deleted file mode 100644 (file)
index 64e5253..0000000
+++ /dev/null
@@ -1,185 +0,0 @@
-#include <windows.h>
-#include <stdlib.h>
-#include <memory.h>
-
-#include "tnmisc.h"
-
-// from the PVAX (http://www.ccas.ru/~posp/popov/spawn.htm)
-// Create a process with pipes to stdin/out/err
-BOOL CreateHiddenConsoleProcess(LPCTSTR szChildName, PROCESS_INFORMATION* ppi, 
-                                LPHANDLE phInWrite, LPHANDLE phOutRead,
-                                LPHANDLE phErrRead) {
-    BOOL fCreated;
-    STARTUPINFO si;
-    SECURITY_ATTRIBUTES sa;
-    HANDLE hInRead;
-    HANDLE hOutWrite;
-    HANDLE hErrWrite;
-
-    // Create pipes
-    // initialize security attributes for handle inheritance (for WinNT)
-    sa.nLength = sizeof( sa );
-    sa.bInheritHandle = TRUE;
-    sa.lpSecurityDescriptor  = NULL;
-
-    // create STDIN pipe
-    if( !CreatePipe( &hInRead, phInWrite, &sa, 0 ))
-        goto error;
-
-    // create STDOUT pipe
-    if( !CreatePipe( phOutRead, &hOutWrite, &sa, 0 ))
-        goto error;
-
-    // create STDERR pipe
-    if( !CreatePipe( phErrRead, &hErrWrite, &sa, 0 ))
-        goto error;
-
-    // process startup information
-    memset( &si, 0, sizeof( si ));
-    si.cb = sizeof( si ); 
-    si.dwFlags = STARTF_USESHOWWINDOW | STARTF_USESTDHANDLES;
-    // child process' console must be hidden for Win95 compatibility
-    si.wShowWindow = SW_HIDE;
-    // assign "other" sides of pipes
-    si.hStdInput = hInRead;
-    si.hStdOutput = hOutWrite;
-    si.hStdError = hErrWrite;
-
-    // Create a child process (suspended)
-    fCreated = CreateProcess( NULL,
-                              (LPTSTR)szChildName,
-                              NULL,
-                              NULL,
-                              TRUE,
-                              0,
-                              NULL,
-                              NULL,
-                              &si,
-                              ppi );
-
-    if( !fCreated )
-        goto error;
-
-    CloseHandle( hInRead );
-    CloseHandle( hOutWrite );
-    CloseHandle( hErrWrite );
-
-    return TRUE;
-
-error:
-    CloseHandle( hInRead );
-    CloseHandle( hOutWrite );
-    CloseHandle( hErrWrite );
-    CloseHandle( ppi->hProcess );
-    CloseHandle( ppi->hThread );
-    
-    hInRead =
-    hOutWrite =
-    hErrWrite =
-    ppi->hProcess =
-    ppi->hThread = INVALID_HANDLE_VALUE;
-
-    return FALSE;
-}
-
-BOOL SpawnProcess(char *cmd_line, PROCESS_INFORMATION *pi) {
-       STARTUPINFO si;
-
-       memset(&si, 0, sizeof(si));
-       si.cb = sizeof(si);
-               
-       return CreateProcess(cmd_line, NULL, NULL, FALSE, NORMAL_PRIORITY_CLASS,
-                            CREATE_NEW_CONSOLE, NULL, NULL, &si, pi);
-}
-
-// crn@ozemail.com.au
-int GetWin32Version(void) {
-       // return win32 version; 0 = Win32s, 1 = Win95, 2 = WinNT, 3 = Unknown -crn@ozemail.com.au
-       LPOSVERSIONINFO osv;
-       DWORD retval;
-       
-       osv = new OSVERSIONINFO;
-       
-       osv->dwOSVersionInfoSize = sizeof (OSVERSIONINFO);
-       GetVersionEx (osv);
-       retval = osv->dwPlatformId;
-       delete osv;
-       return (retval);
-}
-
-// Paul Brannan 8/7/98
-// This code is from Michael 'Hacker' Krelin (author of KINSole)
-// (slightly modified)
-HWND TelnetGetConsoleWindow() {
-       DWORD pid = GetCurrentProcessId(), wpid;
-       char title[512], *t = title;
-       HWND hrv = NULL;
-
-#ifndef __BORLANDC__   // Ioannou Dec. 8, 1998
-       if(!GetConsoleTitle(title, sizeof(title))) t = NULL;
-
-       for(;;) {
-               if((hrv = FindWindowEx(NULL, hrv, "tty", t)) == NULL) break;
-               if(!GetWindowThreadProcessId(hrv, &wpid)) continue;
-               if(wpid == pid) return hrv;
-       }
-#endif
-
-       return GetForegroundWindow();
-}
-
-// Sets the icon of the console window to hIcon
-// If hIcon is 0, then use a default icon
-// hConsoleWindow must be set before calling SetIcon
-bool SetIcon(HWND hConsoleWindow, HANDLE hIcon, LPARAM *pOldBIcon, LPARAM *pOldSIcon,
-                        const char *icondir) {
-       if(!hConsoleWindow) return false;
-       
-// FIX ME!!! The LoadIcon code should work with any compiler!
-// (Paul Brannan 12/17/98)
-#ifndef __BORLANDC__ // Ioannou Dec. 8, 1998
-       if(!hIcon) {
-               char filename[128];                                     // load from telnet.ico
-               strncpy(filename, icondir, sizeof(filename));
-               strncat(filename, "telnet.ico", sizeof(filename));
-               filename[sizeof(filename) - 1] = 0;
-
-               // Note: loading the icon from a file doesn't work on NT
-               // There is no LoadImage in Borland headers - only LoadIcon
-               hIcon = LoadImage(NULL, filename, IMAGE_ICON, 0, 0, LR_DEFAULTSIZE +
-                       LR_LOADFROMFILE);
-       }
-#else  
-       // load the icon from the resource file -crn@ozemail.com.au 16/12/98
-       if(!hIcon) {
-               hIcon = LoadIcon ((HANDLE)GetWindowLong(hConsoleWindow,
-                       GWL_HINSTANCE), "TELNETICON");
-       }
-#endif
-
-       if(hIcon) {
-#ifdef ICON_BIG
-               *pOldBIcon = SendMessage(hConsoleWindow, WM_SETICON, ICON_BIG,
-                       (LPARAM)hIcon);
-#endif
-#ifdef ICON_SMALL
-               *pOldSIcon = SendMessage(hConsoleWindow, WM_SETICON, ICON_SMALL,
-                       (LPARAM)hIcon);
-#endif
-               return true;
-       } else {
-               // Otherwise we get a random icon at exit! (Paul Brannan 9/13/98)
-               return false;
-       }
-}
-
-// Allows SetIcon to be called again by resetting the current icon
-// Added 12/17/98 by Paul Brannan
-void ResetIcon(HWND hConsoleWindow, LPARAM oldBIcon, LPARAM oldSIcon) {
-#ifdef ICON_BIG
-       SendMessage(hConsoleWindow, WM_SETICON, ICON_BIG, (LPARAM)oldBIcon);
-#endif
-#ifdef ICON_SMALL
-       SendMessage(hConsoleWindow, WM_SETICON, ICON_SMALL, (LPARAM)oldSIcon);
-#endif
-}
diff --git a/reactos/apps/utils/net/telnet/src/tnmisc.h b/reactos/apps/utils/net/telnet/src/tnmisc.h
deleted file mode 100644 (file)
index 8216a86..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-#ifndef __TNMISC_H
-#define __TNMISC_H
-
-// Process-related functions
-BOOL CreateHiddenConsoleProcess(LPCTSTR szChildName, PROCESS_INFORMATION* ppi,
-                                LPHANDLE phInWrite, LPHANDLE phOutRead,
-                                LPHANDLE phErrRead);
-BOOL SpawnProcess(char *cmd_line, PROCESS_INFORMATION *pi);
-
-int GetWin32Version(void);
-
-HWND TelnetGetConsoleWindow(void);
-
-bool SetIcon(HWND hConsoleWindow, HANDLE hIcon, LPARAM *pOldBIcon, LPARAM *pOldSIcon,
-                        const char *icondir);
-void ResetIcon(HWND hConsoleWindow, LPARAM oldBIcon, LPARAM oldSIcon);
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tnmsg.h b/reactos/apps/utils/net/telnet/src/tnmsg.h
deleted file mode 100644 (file)
index b93d02b..0000000
+++ /dev/null
@@ -1,108 +0,0 @@
-//{{NO_DEPENDENCIES}}
-// Microsoft Developer Studio generated include file.
-// Used by Tnmsg.rc
-//
-#define MSG_COPYRIGHT                   0x01
-#define MSG_COPYRIGHT_1                 0x02
-#define MSG_USAGE                       0x03
-#define MSG_USAGE_1                     0x04
-#define MSG_HELP                        0x05
-#define MSG_HELP_1                      0x06
-#define MSG_INVCMD                      0x07
-#define MSG_ERROR                       0x08
-#define MSG_INFO                        0x09
-#define MSG_WARNING                     0x0a
-#define MSG_TRYING                      0x0b
-#define MSG_CONNECTED                   0x0c
-#define MSG_TERMBYREM                   0x0d
-#define MSG_KEYMAP                      0x0e
-#define MSG_ERRKEYMAP                   0x0f
-#define MSG_DUMPFILE                    0x10
-#define MSG_CONFIG                      0x11
-#define MSG_NOINI                       0x12
-#define MSG_BADVAL                      0x13
-#define MSG_NOSPAWN                     0x14
-#define MSG_RESOLVING                                  0x15
-#define MSG_NOSERVICE                                  0x16
-#define MSG_SIZEALIAS                                  0x17
-#define MSG_ERRPIPE                                            0x18
-#define MSG_BADUSAGE                                   0x19
-#define MSG_ALREADYCONNECTED                   0x1a
-
-#define MSG_KEYNOVAL                    1001
-#define MSG_KEYBADVAL                   1002
-#define MSG_KEYBADSTRUCT                1003
-#define MSG_KEYBADCHARS                 1004
-#define MSG_KEYUNEXPLINE                1005
-#define MSG_KEYUNEXPEOF                 1006
-#define MSG_KEYUNEXPTOK                 1007
-#define MSG_KEYUNEXPTOKIN               1008
-#define MSG_KEYUNEXP                    1009
-#define MSG_KEYNOGLOBAL                 1010
-#define MSG_KEYNOCONFIG                 1011
-#define MSG_KEYUSECONFIG                1012
-#define MSG_KEYNOSWKEY                  1013
-#define MSG_KEYCANNOTDEF                1014
-#define MSG_KEYDUPSWKEY                 1015
-#define MSG_KEYUNKNOWNMAP               1016
-#define MSG_KEYNOCHARMAPS               1017
-#define MSG_KEYNOKEYMAPS                1018
-#define MSG_KEYNUMMAPS                  1019
-#define MSG_KEYBADMAP                                  1020
-#define MSG_KEYMAPSWITCHED                             1021
-
-#define MSG_WSAEINTR                    0x2714
-#define MSG_WSAEBADF                    0x2719
-#define MSG_WSAEACCESS                  0x271D
-#define MSG_WSAEDEFAULT                 0x271E
-#define MSG_WSAEINVAL                   0x2726
-#define MSG_WSAEMFILE                   0x2728
-#define MSG_WSAEWOULDBLOCK              0x2733
-#define MSG_WSAEINPROGRESS              0x2734
-#define MSG_WSAEALREADY                 0x2735
-#define MSG_WSAENOTSOCK                 0x2736
-#define MSG_WSAEDESTADDRREQ             0x2737
-#define MSG_WSAEMSGSIZE                 0x2738
-#define MSG_WSAEPROTOTYPE               0x2739
-#define MSG_WSAENOPROTOOPT              0x273A
-#define MSG_WSAEPROTONOTSUPPORT         0x273B
-#define MSG_WSAESOCKNOTSUPPORT          0x273C
-#define MSG_WSAEOPNOTSUPP               0x273D
-#define MSG_WSAEPFNOTSUPPORT            0x273E
-#define MSG_WSAEAFNOTSUPPORT            0x273F
-#define MSG_WSAEADDRINUSE               0x2740
-#define MSG_WSAEADDRNOTAVAIL            0x2741
-#define MSG_WSAENETDOWN                 0x2742
-#define MSG_WSAENETUNREACH              0x2743
-#define MSG_WSAENETRESET                0x2744
-#define MSG_WSAECONNABORTED             0x2745
-#define MSG_WSAECONNRESET               0x2746
-#define MSG_WSAENOBUFS                  0x2747
-#define MSG_WSAEISCONN                  0x2748
-#define MSG_WSAENOTCONN                 0x2749
-#define MSG_WSAESHUTDOWN                0x274A
-#define MSG_WSAETOOMANYREFS             0x274B
-#define MSG_WSAETIMEDOUT                0x274C
-#define MSG_WSAECONNREFUSED             0x274D
-#define MSG_WSAELOOP                    0x274E
-#define MSG_WSAENAMETOOLONG             0x274F
-#define MSG_WSAEHOSTDOWN                0x2750
-#define MSG_WSAEHOSTUNREACH             0x2751
-#define MSG_WSAESYSNOTREADY             0x276B
-#define MSG_WSAVERNOTSUPPORTED          0x276C
-#define MSG_WSANOTINITIALISED           0x276D
-#define MSG_WSAHOST_NOT_FOUND           0x2AF9
-#define MSG_WSATRY_AGAIN                0x2AFA
-#define MSG_WSANO_RECOVERY              0x2AFB
-#define MSG_WSANO_DATA                  0x2AFC
-
-// Next default values for new objects
-//
-#ifdef APSTUDIO_INVOKED
-#ifndef APSTUDIO_READONLY_SYMBOLS
-#define _APS_NEXT_RESOURCE_VALUE        101
-#define _APS_NEXT_COMMAND_VALUE         40001
-#define _APS_NEXT_CONTROL_VALUE         1000
-#define _APS_NEXT_SYMED_VALUE           101
-#endif
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tparams.h b/reactos/apps/utils/net/telnet/src/tparams.h
deleted file mode 100644 (file)
index ffd4f8c..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-#ifndef __THREADPARAMS
-#define __THREADPARAMS
-
-#include "ttelhndl.h"
-
-typedef struct {
-       HANDLE hExit;
-       HANDLE hPause, hUnPause;
-       volatile int *bNetPaused;
-       volatile int *bNetFinished;
-       volatile int *bNetFinish;
-} NetParams;
-
-// We could make TelHandler a pointer rather than a reference, but making it
-// a reference forces us to initialize it when it is created, thus avoiding
-// a possible segfault (Paul Brannan 6/15/98)
-class TelThreadParams {
-public:
-       TelThreadParams(TTelnetHandler &RefTelHandler): TelHandler(RefTelHandler) {}
-       NetParams p;
-       TTelnetHandler &TelHandler;
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tparser.h b/reactos/apps/utils/net/telnet/src/tparser.h
deleted file mode 100644 (file)
index 143649f..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-// A TParser is a class for parsing input and formatting it (presumabyl for
-// display on the screen).  All parsers are derived from the TParser class,
-// in order to facilitate extending telnet to include other kinds of
-// output.  Currently, only one parser is implemented, the ANSI parser.
-// A TParser includes:
-//   - A ParseBuffer function, which takes as parameters start and end
-//     pointers.  It returns a pointer to the last character parsed plus 1.
-//     The start pointer is the beginning of the buffer, and the end
-//     pointer is one character after the end of the buffer.
-//   - An Init() function, which will re-initialize the parser when
-//     necessary.
-
-#ifndef __TPARSER_H
-#define __TPARSER_H
-
-#include "tconsole.h"
-#include "keytrans.h"
-#include "tscroll.h"
-#include "tnetwork.h"
-#include "tcharmap.h"
-
-class TParser {
-public:
-       TParser(TConsole &RefConsole, KeyTranslator &RefKeyTrans,
-               TScroller &RefScroller, TNetwork &RefNetwork, TCharmap &RefCharmap) :
-       Console(RefConsole), KeyTrans(RefKeyTrans), Scroller (RefScroller),
-       Network(RefNetwork), Charmap(RefCharmap) {}
-       virtual ~TParser() {}
-
-/*     TParser& operator= (const TParser &p) {
-               Console = p.Console;
-               KeyTrans = p.KeyTrans;
-               Scroller = p.Scroller;
-               Network = p.Network;
-               return *this;
-       }*/
-
-       virtual char *ParseBuffer(char *pszBuffer, char *pszBufferEnd) = 0;
-       virtual void Init() = 0;
-
-protected:
-       TConsole &Console;
-       KeyTranslator &KeyTrans;
-       TScroller &Scroller;
-       TNetwork &Network;
-       TCharmap &Charmap;
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tscript.cpp b/reactos/apps/utils/net/telnet/src/tscript.cpp
deleted file mode 100644 (file)
index 2045e43..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-#include "tscript.h"
-
-// FIX ME!!  This code not yet functional.
-
-#define TERMINATOR '~'
-#define SPACE_HOLDER '_'
-
-// processScript by Bryan Montgomery
-// modified to handle script file by Paul Brannan
-BOOL TScript::processScript (char* data) {
-/*    char* end = strchr(script,TERMINATOR);
-       if (0 == end) {
-               return true;
-       } else {
-               char* current = new char(sizeof(char)*strlen(script));
-               strncpy(current,script,(int)(end-script));
-               current[(int)(end-script)]=0;
-               char *ptr=end;
-               if (strstr(data,current) != 0) {
-                       script = ++end;
-                       end = strchr(script,TERMINATOR);
-                       while ((ptr = strchr(ptr,SPACE_HOLDER)) != 0 && ptr < end) {
-                               *ptr=' ';
-                       }
-                       Network.WriteString(script,(int)(end-script));
-                       Network.WriteString("\r\n",2);
-                       script = ++end;
-               }
-       delete current;
-       }*/
-       return TRUE;
-}
-
-void TScript::initScript (char *filename) {
-       if(fp) fclose(fp);
-       fp = fopen(filename, "rt");
-}
-
diff --git a/reactos/apps/utils/net/telnet/src/tscript.h b/reactos/apps/utils/net/telnet/src/tscript.h
deleted file mode 100644 (file)
index f9626bf..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-#ifndef __TSCRIPT_H
-#define __TSCRIPT_H
-
-#include <windows.h>
-#include <stdio.h>
-#include "tnetwork.h"
-
-class TScript {
-public:
-       TScript(TNetwork &RefNetwork):Network(RefNetwork) {fp = NULL;}
-       ~TScript() {}
-       BOOL processScript(char *data);
-       void initScript(char *filename);
-private:
-       FILE *fp;
-       char *script;
-       TNetwork &Network;
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/tscroll.cpp b/reactos/apps/utils/net/telnet/src/tscroll.cpp
deleted file mode 100644 (file)
index 307dc2a..0000000
+++ /dev/null
@@ -1,369 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998-2000 Paul Brannan
-//Copyright (C) 1998 I.Ioannou
-//Copyright (C) 1997 Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-///////////////////////////////////////////////////////////////////////////////
-//
-// Module:             tscroll.cpp
-//
-// Contents:   Telnet Handler
-//
-// Product:            telnet
-//
-// Revisions: Dec. 5, 1998     Paul Brannan <pbranna@clemson.edu>
-//            June 15, 1998 Paul Brannan
-//
-//            This is code originally from tnclass.cpp and ansiprsr.cpp
-//
-///////////////////////////////////////////////////////////////////////////////
-
-#include <windows.h>
-#include <string.h>
-#include <ctype.h>
-#include "tscroll.h"
-#include "tncon.h"
-#include "tconsole.h"
-#include "tnconfig.h"
-
-enum {
-       HEX,
-       DUMP,
-       DUMPB,
-       TEXTB,
-};
-
-int DummyStripBuffer(char *start, char *end, int width) {return 0;}
-
-TScroller::TScroller(TMouse &M, int size) : Mouse(M) {
-       iScrollSize = size;
-       pcScrollData = new char[iScrollSize];
-       iScrollEnd = 0;
-       iPastEnd = 0;
-       memset(pcScrollData, ' ', iScrollSize);
-
-       if(stricmp(ini.get_scroll_mode(), "hex") == 0) iDisplay = HEX;
-       else if(stricmp(ini.get_scroll_mode(), "dump") == 0) iDisplay = DUMP;
-       else if(stricmp(ini.get_scroll_mode(), "dumpb") == 0) iDisplay = DUMPB;
-       else if(stricmp(ini.get_scroll_mode(), "text") == 0) iDisplay = TEXTB;
-       else iDisplay = DUMP;
-
-       strip = &DummyStripBuffer;
-}
-
-TScroller::~TScroller() {
-       delete[] pcScrollData;
-}
-
-void TScroller::init(stripfunc *s) {
-       strip = s;
-}
-
-// Fixed update of circular buffer (Paul Brannan 12/4/98)
-// Note: iScrollEnd is one character beyond the end
-void TScroller::update(const char *pszHead, const char *pszTail) {
-       if ((iScrollEnd)+(pszTail-pszHead) < iScrollSize) {
-               memcpy(&pcScrollData[iScrollEnd], pszHead, pszTail-pszHead);
-       } else if (pszTail-pszHead > iScrollSize) {
-               memcpy(pcScrollData, pszTail-iScrollSize, iScrollSize);
-               iScrollEnd = 0;
-       } else {
-               memcpy(&pcScrollData[iScrollEnd], pszHead, iScrollSize-iScrollEnd);
-               memcpy(&pcScrollData[0], pszHead + (iScrollSize-iScrollEnd),
-                       pszTail-pszHead-(iScrollSize-iScrollEnd));
-       }
-
-       // This could probably be optimized better, but it's probably not worth it
-       int temp = iScrollEnd;
-       iScrollEnd = ((iScrollEnd)+(pszTail-pszHead))%iScrollSize;
-       if(iScrollEnd < temp) iPastEnd = 1;
-}
-
-// Perhaps this should be moved to Tconsole.cpp? (Paul Brannan 6/12/98)
-static BOOL WriteConsoleOutputCharAndAttribute(
-                                                                               HANDLE  hConsoleOutput, // handle of a console screen buffer
-                                                                               CHAR * lpWriteBuffer,
-                                                                               WORD wAttrib,
-                                                                               SHORT sX,
-                                                                               SHORT sY ){
-       // we ought to allocate memory before writing to an address (PB 5/12/98)
-       DWORD cWritten;
-       const LPDWORD lpcWritten = &cWritten;
-       
-       DWORD  cWriteCells = strlen(lpWriteBuffer);
-       COORD  coordWrite = {sX,sY};
-       LPWORD lpwAttribute = new WORD[cWriteCells];
-       for (unsigned int i = 0; i < cWriteCells; i++)
-               lpwAttribute[i] = wAttrib;
-       WriteConsoleOutputAttribute(
-               hConsoleOutput,                 // handle of a console screen buffer
-               lpwAttribute,                   // address of buffer to write attributes from
-               cWriteCells,                    // number of character cells to write to
-               coordWrite,                             // coordinates of first cell to write to
-               lpcWritten                              // address of number of cells written to
-               );
-       WriteConsoleOutputCharacter(
-               hConsoleOutput,                 // handle of a console screen buffer
-               lpWriteBuffer,                  // address of buffer to write characters from
-               cWriteCells,                    // number of character cells to write to
-               coordWrite,                             // coordinates of first cell to write to
-               lpcWritten                              // address of number of cells written to
-               );
-       delete [] lpwAttribute;
-       return 1;
-}
-
-static void hexify(int x, char *str, int len) {
-       for(int j = len - 1; j >= 0; j--) {
-               str[j] = x % 16;
-               if(str[j] > 9) str[j] += 'A' - 10;
-               else str[j] += '0';
-               x /= 16;
-       }
-}
-
-static int setmaxlines(int iDisplay, int iScrollSize, int strippedlines,
-                               int con_width) {
-       switch(iDisplay) {
-               case HEX: return(iScrollSize / 16); break;
-               case DUMP: 
-               case DUMPB: return(iScrollSize / con_width); break;
-               case TEXTB: return(strippedlines); break;
-       }
-       return 0;
-}
-
-static void setstatusline(char *szStatusLine, int len, int iDisplay) {
-       memset(szStatusLine, ' ', len);
-       memcpy(&szStatusLine[1], "Scrollback Mode", 15);
-       switch(iDisplay) {
-       case HEX: memcpy(&szStatusLine[len / 2 - 1], "HEX", 3); break;
-       case DUMP: memcpy(&szStatusLine[len / 2 - 2], "DUMP", 4); break;
-       case DUMPB: memcpy(&szStatusLine[len / 2 - 5], "BINARY DUMP", 11); break;
-       case TEXTB: memcpy(&szStatusLine[len / 2 - 2], "TEXT", 4); break;
-       }
-       memcpy(&szStatusLine[len - 6], "READY", 5);
-       szStatusLine[len] = 0;
-}
-
-void TScroller::ScrollBack(){
-       char p;
-       int r,c;
-
-       // define colors (Paul Brannan 7/5/98)
-       int normal = (ini.get_scroll_bg() << 4) | ini.get_scroll_fg();
-       // int inverse = (ini.get_scroll_fg() << 4) | ini.get_scroll_bg();
-       int status = (ini.get_status_bg() << 4) | ini.get_status_fg();
-
-       CHAR_INFO* chiBuffer;
-       chiBuffer = newBuffer();
-       saveScreen(chiBuffer);
-
-       HANDLE hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
-       CONSOLE_SCREEN_BUFFER_INFO ConsoleInfo;
-       GetConsoleScreenBufferInfo(hStdout, &ConsoleInfo);
-
-       // Update iScrollBegin -- necessary in case the buffer isn't full yet
-       long iScrollBegin, iScrollLast;
-       if(iPastEnd == 0) {
-               iScrollBegin = 0;
-               iScrollLast = iScrollEnd - 1;
-       } else {
-               iScrollBegin = iScrollEnd;
-               iScrollLast = iScrollSize - 1;
-       }
-
-       // Create buffer with ANSI codes stripped
-       // Fixed this to work properly with a circular buffer (PB 12/4/98)
-       char *stripped = new char[iScrollSize];
-       memcpy(stripped, pcScrollData + iScrollBegin, iScrollSize - 
-               iScrollBegin);
-       if(iScrollBegin != 0) memcpy(stripped + (iScrollSize - iScrollBegin),
-               pcScrollData, iScrollBegin - 1);
-       int strippedlines = (*strip)(stripped, stripped + iScrollLast,
-               CON_COLS);
-
-       // Calculate the last line of the scroll buffer (Paul Brannan 12/4/98)
-       int maxlines = setmaxlines(iDisplay, iScrollLast + 1, strippedlines,
-               CON_COLS);
-
-       // init scroll position
-       int current = maxlines - CON_HEIGHT + 1;
-       if(current < 0) current = 0;
-       
-       // paint border and info
-    // paint last two lines black on white
-    char * szStatusLine;
-    szStatusLine = new char[CON_WIDTH+2];
-       setstatusline(szStatusLine, CON_COLS, iDisplay);
-    WriteConsoleOutputCharAndAttribute(hStdout, szStatusLine, status,
-               CON_LEFT, CON_BOTTOM);
-       
-       // loop while not done
-       BOOL done = FALSE;
-       while (!done){
-               switch (iDisplay){
-               case HEX:
-                       memset(szStatusLine, ' ', CON_COLS);
-                       szStatusLine[8] = ':';
-                       szStatusLine[34] = '-';
-            for (r = 0; r < CON_HEIGHT; r++) {
-                               hexify((r + current) * 16, &szStatusLine[2], 6);
-                               for (c = 0; c < 16; c++){
-                                       if (c+(16*(r+current)) >= iScrollLast)
-                                               p = 0;
-                                       else
-                                               p = pcScrollData[(c+16*(r+current) + iScrollBegin) %
-                                                       iScrollSize];
-                                       hexify((char)p, &szStatusLine[11 + 3*c], 2);
-                                       if (!iscntrl(p)) {
-                                               szStatusLine[60 + c] = (char)p;
-                                       } else {
-                                               szStatusLine[60 + c] = '.';
-                                       }
-                               }
-                               for(int j = 0; j < 16; j++) {
-                               }
-                               szStatusLine[CON_COLS] = '\0';
-                               WriteConsoleOutputCharAndAttribute(hStdout, szStatusLine,
-                                       normal, CON_LEFT, r+CON_TOP);
-            }
-            break;
-               case DUMP:
-            for (r = 0; r < CON_HEIGHT; r++) {
-                               for (c = 0; c <= CON_WIDTH; c++) {
-                                       if (c+((CON_COLS)*(r+current)) >= iScrollLast) p = ' ';
-                                       else p = pcScrollData[(c+((CON_COLS)*(r+current))
-                                               + iScrollBegin) % iScrollSize];
-                                       if (!iscntrl(p))
-                                               szStatusLine[c] = p;
-                                       else
-                                               szStatusLine[c] = '.';
-                               }
-                               szStatusLine[c] = '\0';
-                               WriteConsoleOutputCharAndAttribute(hStdout, szStatusLine,
-                                       normal, CON_LEFT, r+CON_TOP);
-            }
-            break;
-               case DUMPB:
-                       for (r = 0; r < CON_HEIGHT; r++) {
-                               for (c = 0; c <= CON_WIDTH; c++) {
-                                       if (c+((CON_COLS)*(r+current)) >= iScrollLast) p = ' ';
-                                       else p = pcScrollData[  (c+((CON_COLS)*(r+current))
-                                               + iScrollBegin) % iScrollSize];
-                                       if (p != 0)
-                                               szStatusLine[c] = p;
-                                       else
-                                               szStatusLine[c] = ' ';
-                               }
-                               szStatusLine[c] = '\0';
-                               WriteConsoleOutputCharAndAttribute(hStdout, szStatusLine,
-                                       normal, CON_LEFT, r+CON_TOP);
-            }
-            break;
-               case TEXTB: {
-                       int ch, lines, x;
-                       // Find the starting position
-                       for(ch = 0, lines = 0, x = 1; ch < iScrollSize &&
-                               lines < current; ch++, x++) {
-                               
-                               if(stripped[ch] == '\n') lines++;
-                               if(stripped[ch] == '\r') x = 1;
-                       }
-
-                       for (r = 0; r < CON_HEIGHT; r++) {
-                               memset(szStatusLine, ' ', CON_COLS);
-                               for(c = 0; c <= CON_WIDTH; c++) {
-                                       done = FALSE;
-                                       if (ch >= iScrollSize) p = ' ';
-                                       else p = stripped[ch];
-                                       switch(p) {
-                                       case 10: done = TRUE; break;
-                                       case 13: c = 0; break;
-                                       default: szStatusLine[c] = p;
-                                       }
-                                       ch++;
-                                       if(done) break;
-                               }
-                               szStatusLine[CON_COLS] = '\0';
-                               WriteConsoleOutputCharAndAttribute(hStdout, szStatusLine,
-                                       normal, CON_LEFT, r+CON_TOP);
-                       }
-                                       }
-            break;
-               }
-
-               setstatusline(szStatusLine, CON_COLS, iDisplay);
-               WriteConsoleOutputCharAndAttribute(hStdout, szStatusLine, status,
-                       CON_LEFT, CON_BOTTOM);
-
-               // paint scroll back data
-               // get key input
-               switch(scrollkeys()){
-               case VK_ESCAPE:
-                       done = TRUE;
-                       break;
-               case VK_PRIOR:
-                       if ( current > CON_HEIGHT)
-                               current-= CON_HEIGHT;
-                       else
-                               current = 0;
-                       break;
-               case VK_NEXT:
-                       if ( current < maxlines - 2*CON_HEIGHT + 2)
-                               current += CON_HEIGHT;
-                       else
-                               current = maxlines - CON_HEIGHT + 1;
-                       break;
-               case VK_DOWN:
-                       if (current <= maxlines - CON_HEIGHT) current++;
-                       break;
-               case VK_UP:
-                       if ( current > 0) current--;
-                       break;
-               case VK_TAB:
-                       iDisplay = (iDisplay+1)%4;
-                       maxlines = setmaxlines(iDisplay, iScrollLast + 1, strippedlines,
-                               CON_COLS);
-                       if(current > maxlines) current = maxlines - 1;
-                       if(current < 0) current = 0;
-                       break;
-               case VK_END:
-                       current = maxlines - CON_HEIGHT + 1;
-                       if(current < 0) current = 0;
-                       break;
-               case VK_HOME:
-                       current = 0;
-                       break;
-               case SC_MOUSE:
-                       Mouse.scrollMouse();
-                       break;
-               }
-       }
-       
-       // Clean up
-       restoreScreen(chiBuffer);
-       delete[] szStatusLine;
-       delete[] chiBuffer;
-       delete[] stripped;
-}
diff --git a/reactos/apps/utils/net/telnet/src/tscroll.h b/reactos/apps/utils/net/telnet/src/tscroll.h
deleted file mode 100644 (file)
index 4261ca0..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-#ifndef __TSCROLL_H
-#define __TSCROLL_H
-
-#include "tconsole.h"
-#include "tmouse.h"
-
-typedef int(stripfunc)(char *, char *, int);
-
-class TScroller {
-private:
-       char *pcScrollData;
-       long iScrollSize;
-       long iScrollEnd;
-       int iPastEnd;
-       int iDisplay;
-       stripfunc *strip;
-       TMouse &Mouse;
-public:
-       void init(stripfunc *s);
-       void update(const char *pszBegin, const char *pszEnd);
-       void ScrollBack();
-       TScroller(TMouse &M, int size=20000);
-       ~TScroller();
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/src/ttelhndl.cpp b/reactos/apps/utils/net/telnet/src/ttelhndl.cpp
deleted file mode 100644 (file)
index 1b38d39..0000000
+++ /dev/null
@@ -1,548 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-//Telnet Win32 : an ANSI telnet client.
-//Copyright (C) 1998  Paul Brannan
-//Copyright (C) 1998  I.Ioannou
-//Copyright (C) 1997  Brad Johnson
-//
-//This program is free software; you can redistribute it and/or
-//modify it under the terms of the GNU General Public License
-//as published by the Free Software Foundation; either version 2
-//of the License, or (at your option) any later version.
-//
-//This program is distributed in the hope that it will be useful,
-//but WITHOUT ANY WARRANTY; without even the implied warranty of
-//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//GNU General Public License for more details.
-//
-//You should have received a copy of the GNU General Public License
-//along with this program; if not, write to the Free Software
-//Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-//
-//I.Ioannou
-//roryt@hol.gr
-//
-///////////////////////////////////////////////////////////////////////////
-
-///////////////////////////////////////////////////////////////////////////////
-//
-// Module:             ttelhndl.cpp
-//
-// Contents:   Telnet Handler
-//
-// Product:            telnet
-//
-// Revisions: August 30, 1998 Paul Brannan <pbranna@clemson.edu>
-//            June 15, 1998   pbranna@clemson.edu (Paul Brannan)
-//
-//            This is code originally from tnnet.cpp and ansiprsr.cpp
-//
-///////////////////////////////////////////////////////////////////////////////
-
-#include <string.h>
-#include "ttelhndl.h"
-#include "telnet.h"
-#include "tnconfig.h"
-#include "tparams.h"
-
-int naws_string(char *buf, int width, int height);
-
-// This helps make the code more readable (Paul Brannan 1/1/99)
-#ifdef DEBUG_TELOPT
-#define TELOPT_PRINTD(x) printit(x);
-#define TELOPT_PRINTD2(x,n) {          \
-       static char buf[20];                    \
-       printit(s);                                             \
-       printit(" ");                                   \
-       itoa(d, buf, 10);                               \
-       printit(buf);                                   \
-       printit("\n");                                  \
-}
-#else
-#define TELOPT_PRINTD(x) ;
-#define TELOPT_PRINTD2(x,n) ;
-#endif
-
-// A new print function for debugging (Paul Brannan 5/15/98)
-#ifdef DEBUG_TELOPT
-void TTelnetHandler::print_telopt(const char *s, int d) {
-       static char buf[20];
-       printit(s);
-       printit(" ");
-       itoa(d, buf, 10);
-       printit(buf);
-       printit("\n");
-}
-#endif
-
-TTelnetHandler::TTelnetHandler(TNetwork &RefNetwork, TConsole &RefConsole,
-                                                          TParser &RefParser):
-Network(RefNetwork), Console(RefConsole), Parser(RefParser) {
-       init();
-
-       // Paul Brannan 9/13/98
-       dwBuffer = ini.get_buffer_size();
-       szBuffer = new char [dwBuffer];
-       Network.SetNawsFunc(NULL);
-}
-
-void TTelnetHandler::init() {
-       iTermSet = 0;
-       bInBinaryRx = 0;
-       bInBinaryTx = 0;
-       bInEchoTx = 0;
-       bInEchoRx = 0;
-       Network.set_local_echo(1);
-}
-
-TTelnetHandler::~TTelnetHandler() {
-       delete[] szBuffer;
-}
-
-int TTelnetHandler::escapeIAC(char *buf, int length){
-       // The size of buffer must be greater than 2 * length to ensure no memory
-       // out of bounds errors.  The 0xff is escaped into 0xff 0xff.
-       char * temp;
-       temp = new char [length * 2];
-       int current=0;
-       for (int x=0; x < length; x++){
-               if (buf[x] == (signed char)IAC)
-                       temp[current++]=(char)IAC;
-               temp[current++]=buf[x];
-       }
-       memcpy( buf, temp, current);
-       delete [] temp;
-       return current;
-}
-
-// This lets us get rid of all the printf's (Paul Brannan 5/15/98)
-void TTelnetHandler::SendIAC(char c) {
-       static char buf[2] = {IAC};
-       buf[1] = c;
-       Network.WriteString(buf, 2);
-}
-void TTelnetHandler::SendIAC(char c1, char c2) {
-       static char buf[3] = {IAC};
-       buf[1] = c1; buf[2] = c2;
-       Network.WriteString(buf, 3);
-}
-void TTelnetHandler::SendIACParams(char c) {
-       static char buf[2];
-       buf[0] = c;
-       static int length = escapeIAC(buf, 1);
-       Network.WriteString(buf, length);
-}
-void TTelnetHandler::SendIACParams(char c1, char c2) {
-       static char buf[4];
-       buf[0] = c1; buf[1] = c2;
-       static int length = escapeIAC(buf, 2);
-       Network.WriteString(buf, length);
-}
-
-int naws_string(char *b, int width, int height) {
-       int l = 0;
-       unsigned char *buf = (unsigned char *)b;
-
-       union {
-               char szResponse[2];
-               int n;
-       };
-
-       buf[l++] = IAC;
-       buf[l++] = SB;
-       buf[l++] = TELOPT_NAWS;
-
-       n = width;
-       buf[l] = szResponse[1];
-       if(buf[l-1] == IAC) buf[l++] = IAC;
-       buf[l++] = szResponse[0];
-       if(buf[l-1] == IAC) buf[l++] = IAC;
-
-       n = height;
-       buf[l++] = szResponse[1];
-       if(buf[l-1] == IAC) buf[l++] = IAC;
-       buf[l++] = szResponse[0];
-       if(buf[l-1] == IAC) buf[l++] = IAC;
-
-       buf[l++] = IAC;
-       buf[l++] = SE;
-
-       return l;
-}
-
-//  Ioannou 29 May 1998 : Something strange happens with
-//  Borland compiler at this point when it passes the arguments
-//  to SendIACParams. It always sends 80 lines to the server !!!
-//  There seems to be a bug with optimization (the disassemble shows
-//  that it uses an address plus 0xa than the right one).
-//  This turns them off for this point.
-#ifdef __BORLANDC__
-#pragma -O-
-#endif
-
-// Removed old printf code that was commented out to clean this function
-// up a bit (Paul brannan 6/15/98)
-char* TTelnetHandler::ParseIAC(char* pszBuffer, char* pszBufferEnd)
-{
-       //      int n,l;
-       //      char szResponse[40];
-       //  Ioannou 29 May 1998 : I prefer the union redefinitions
-       //  than the typecasting (used with them from Pascal and Cobol :-) )
-       //  FIX ME !!!! Shall we use the winsock routines instead ?
-       
-       union {
-               char szResponse[2];
-               int n;
-       };
-       
-       // Added support for user-defined term name (Paul Brannan 5/13/98)
-#define LASTTERM 4
-       const char *pszTerms[] =  {ini.get_term(), "ANSI","DEC-VT100","DEC-VT52","UNKNOWN"};
-       if(!iTermSet && (pszTerms[0] == 0 || *pszTerms[0] == 0)) iTermSet++;
-       
-       if (pszBuffer + 2 < pszBufferEnd) {
-               switch ((unsigned char)pszBuffer[1]) {
-                       
-                       ///////////////// DO ////////////////////
-               case DO:
-                       {
-                               switch (pszBuffer[2]){
-                               case TELOPT_BINARY:
-                                       TELOPT_PRINTD("RCVD DO TELOPT_BINARY\n");
-                                       if (!bInBinaryRx){
-                                               SendIAC(WILL, TELOPT_BINARY);
-                                               bInBinaryRx = 1;
-                                               TELOPT_PRINTD("SENT WILL TELOPT_BINARY\n");
-                                       }
-                                       break;
-                               case TELOPT_ECHO:
-                                       // we shouldn't echo for the server! (Paul Brannan 5/30/98)
-                                       TELOPT_PRINTD2("RCVD DO TELOPT_ECHO", pszBuffer[2]);
-                                       SendIAC(WONT, TELOPT_ECHO);
-                                       TELOPT_PRINTD("SENT WONT TELOPT_ECHO\n");
-                                       break;
-                               case TELOPT_TTYPE:
-                                       TELOPT_PRINTD("RCVD DO TELOPT_TTYPE\n");
-                                       SendIAC(WILL, TELOPT_TTYPE);
-                                       TELOPT_PRINTD("SENT WILL TELOPT_TTYPE\n");
-                                       break;
-                               case TELOPT_NAWS:
-                                       TELOPT_PRINTD("RCVD DO TELOPT_NAWS\n");
-                                       SendIAC(WILL, TELOPT_NAWS);
-                                       SendIAC(SB, TELOPT_NAWS);
-                                       
-                                       Network.SetNawsFunc(naws_string);
-                                       
-                                       n = Console.GetWidth();
-                                       SendIACParams(szResponse[1],szResponse [0]);
-                                       
-                                       n = Console.GetHeight();
-                                       SendIACParams(szResponse[1],szResponse[0]);
-                                       
-                                       SendIAC(SE);
-                                       TELOPT_PRINTD("SENT WILL TELOPT_NAWS\n");
-                                       break;
-                               case TELOPT_XDISPLOC:
-                                       TELOPT_PRINTD("RCVD DO TELOPT_XDISPLOC\n");
-                                       SendIAC(WILL, TELOPT_XDISPLOC);
-                                       TELOPT_PRINTD("SENT WILL TELOPT_XDISPLOC\n");
-                                       printit("Retrieving IP...");
-                                               break;
-                               default:
-                                       TELOPT_PRINTD2("RCVD DO", pszBuffer[2]);
-                                       SendIAC(WONT, pszBuffer[2]);
-                                       TELOPT_PRINTD2("SENT WONT", pszBuffer[2]);
-                                       break;
-                               }
-                               if (pszBuffer + 2 < pszBufferEnd)
-                                       pszBuffer += 3;
-                               break;
-                       }
-                       
-                       ///////////////// WILL ////////////////////
-               case WILL:
-                       {
-                               switch ((unsigned char)pszBuffer[2]){
-                               case TELOPT_BINARY:
-                                       TELOPT_PRINTD("RCVD WILL TELOPT_BINARY\n");
-                                       if (!bInBinaryTx){
-                                               SendIAC(DO, TELOPT_BINARY);
-                                               bInBinaryTx = 1;
-                                               TELOPT_PRINTD("SENT DO TELOPT_BINARY\n");
-                                       }
-                                       break;
-                               case TELOPT_ECHO:
-                                       TELOPT_PRINTD2("RCVD WILL TELOPT_ECHO", pszBuffer[2]);
-                                       if(!bInEchoRx) {
-                                               SendIAC(DO, TELOPT_ECHO);
-                                               bInEchoRx = 1;
-                                               Network.set_local_echo(0); // Paul Brannan 8/25/98
-                                               if(iWillSGA) Network.set_line_mode(0);
-                                               TELOPT_PRINTD2("SENT DO TELOPT_ECHO", pszBuffer[2]);
-                                               if(Network.get_local_echo()) Network.set_line_mode(0);
-                                       }
-                                       break;
-                                       
-                                       // Suppress Go Ahead (Paul Brannan 12/31/98)
-                               case TELOPT_SGA:
-                                       TELOPT_PRINTD("RCVD WILL TELOPT_SGA\n");
-                                       if(!iWillSGA) {
-                                               SendIAC(DO, TELOPT_SGA);
-                                               if(bInEchoRx) Network.set_line_mode(0);
-                                               iWillSGA = 1;
-                                               TELOPT_PRINTD("SENT DO TELOPT_SGA\n");
-                                       }
-                                       break;
-                                       
-                                       ////added 1/28/97
-                               default:
-                                       TELOPT_PRINTD2("RCVD WILL", pszBuffer[2]);
-                                       SendIAC(DONT, pszBuffer[2]);
-                                       TELOPT_PRINTD2("SENT DONT", pszBuffer[2]);
-                                       break;
-                                       ////
-                               }
-                               if (pszBuffer + 2 < pszBufferEnd)
-                                       pszBuffer += 3;
-                               break;
-                       }
-                       
-                       ///////////////// WONT ////////////////////
-               case WONT:
-                       {
-                               switch ((unsigned char)pszBuffer[2]){
-                               case TELOPT_ECHO:
-                                       TELOPT_PRINTD("RCVD WONT TELOPT_ECHO\n");
-                                       if (bInEchoRx){
-                                               SendIAC(DONT, TELOPT_ECHO);
-                                               // bInBinaryRx = 0;
-                                               bInEchoRx = 0; // Paul Brannan 8/25/98
-                                               Network.set_local_echo(1);
-                                               Network.set_line_mode(0);
-                                               TELOPT_PRINTD("SENT DONT TELOPT_ECHO\n");
-                                       }
-                                       break;
-                                       
-                                       // Suppress Go Ahead (Paul Brannan 12/31/98)
-                               case TELOPT_SGA:
-                                       TELOPT_PRINTD("RCVD WONT TELOPT_SGA\n");
-                                       if(iWillSGA) {
-                                               SendIAC(DONT, TELOPT_SGA);
-                                               Network.set_line_mode(0);
-                                               iWillSGA = 0;
-                                               TELOPT_PRINTD("SENT DONT TELOPT_SGA\n");
-                                       }
-                                       break;
-                                       
-                               default:
-                                       TELOPT_PRINTD2("RCVD WONT", pszBuffer[2]);
-                                       break;
-                               }
-                               if (pszBuffer + 2 < pszBufferEnd)
-                                       pszBuffer += 3;
-                               break;
-                       }
-                       
-                       ///////////////// DONT ////////////////////
-               case DONT:
-                       {
-                               switch ((unsigned char)pszBuffer[2]){
-                               case TELOPT_ECHO:
-                                       TELOPT_PRINTD("RCVD DONT TELOPT_ECHO\n");
-                                       if (bInEchoTx){
-                                               SendIAC(WONT, TELOPT_ECHO);
-                                               bInEchoTx = 0;
-                                               TELOPT_PRINTD("SENT WONT TELOPT_ECHO\n");
-                                       }
-                                       break;
-                               case TELOPT_NAWS:
-                                       TELOPT_PRINTD("RCVD DONT TELOPT_NAWS\n");
-                                       SendIAC(WONT, TELOPT_NAWS);
-                                       Network.SetNawsFunc(naws_string);
-                                       TELOPT_PRINTD("SENT WONT TELOPT_NAWS\n");
-                                       break;
-                               default:
-                                       TELOPT_PRINTD2("RCVD DONT", pszBuffer[2]);
-                                       break;
-                               }
-                               if (pszBuffer + 2 < pszBufferEnd)
-                                       pszBuffer += 3;
-                               break;
-                       }
-                       
-                       ///////////////// SB ////////////////////
-               case SB:
-                       {
-                               switch ((unsigned char)pszBuffer[2]){
-                               case TELOPT_TTYPE:
-                                       if (pszBuffer + 5 < pszBufferEnd) {
-                                               TELOPT_PRINTD("RCVD SB TELOPT_TTYPE\n");
-                                               if (pszBuffer[3] == 1){
-                                                       TELOPT_PRINTD("SENT SB TT");
-                                                       TELOPT_PRINTD(pszTerms[iTermSet]);
-                                                       TELOPT_PRINTD("\n");
-                                                       SendIAC(SB, TELOPT_TTYPE);
-                                                       SendIACParams(0);
-                                                       Network.WriteString(pszTerms[iTermSet], strlen(pszTerms[iTermSet]));
-                                                       SendIAC(SE);
-                                                       
-                                                       if (iTermSet < LASTTERM )
-                                                               iTermSet+=1;
-                                               }
-                                               if (pszBuffer + 5 < pszBufferEnd)
-                                                       pszBuffer += 6;
-                                       }
-                                               break;
-                               case TELOPT_XDISPLOC:
-                                       if(pszBuffer + 5 < pszBufferEnd) {
-                                               TELOPT_PRINTD("RCVD SB XDISPLOC\n");
-                                               SendIAC(SB, TELOPT_XDISPLOC);
-                                               TELOPT_PRINTD("SENT SB XDISPLOC");
-                                               SendIACParams(0);
-                                               if(Network.GetLocalAddress()) Network.WriteString(Network.GetLocalAddress(),
-                                                       strlen(Network.GetLocalAddress()));
-                                               TELOPT_PRINTD(Network.GetLocalAddress());
-                                               TELOPT_PRINTD("\n");
-                                               SendIAC(SE);
-                                               if (pszBuffer + 5 < pszBufferEnd)
-                                                       pszBuffer += 6;
-                                       }
-                                       break;
-                               default: break;
-                               }
-                               break;
-                       }
-               default:
-                       pszBuffer += 2;
-                       break;
-               }
-       }
-       return pszBuffer;
-}
-
-#ifdef __BORLANDC__
-// bring bug optimazations
-#pragma -O.
-#endif
-
-// This is the code from TANSIParser::ParseBuffer.  It parses out IACs, and
-// then calls TParser::ParseBuffer to do the terminal emulation.
-// (Paul Brannan 6/15/98)
-// Hopefully eliminating the unnecessary copying should speed things up a
-// little.  (Paul Brannan 6/28/98)
-char* TTelnetHandler::ParseBuffer(char* pszBuffer, char* pszBufferEnd){
-       char *pszResult;
-       char *pszHead = pszBuffer;
-
-       if(Network.get_net_type() == TN_NETSOCKET) {
-               while (pszBuffer < pszBufferEnd) {
-                       // if IAC then parse IAC
-                       if((unsigned char) *pszBuffer == IAC) {
-                       
-                               // check for escaped IAC
-                               if((pszBufferEnd >= pszBuffer + 1) &&
-                                       (unsigned char)*(pszBuffer + 1) == IAC) {
-                                       // we move data at the front of the buffer to the end so
-                                       // that if we only have IACs we won't return pszBuffer
-                                       // even though we did parse something.  Returning
-                                       // pszBuffer is an error condition.
-                                       memmove(pszHead + 1, pszHead, pszBuffer - pszHead);
-                                       pszBuffer+=2;
-                                       pszHead++;
-                               }
-                               // parse the IAC
-                               else {
-                                       pszResult = ParseIAC(pszBuffer, pszBufferEnd);
-                                       if(pszBuffer == pszResult) return pszBuffer;
-                                       // see above regarding moving from front to end.
-                                       memmove(pszHead + (pszResult - pszBuffer), pszHead,
-                                               pszBuffer - pszHead);
-                                       pszHead += (pszResult - pszBuffer);
-                                       pszBuffer = pszResult;
-                               }
-                       }
-                       // else copy char over to ANSI buffer
-                       else {
-                               pszBuffer++;
-                       }
-               }
-
-       // Not a socket connection, so don't parse out IACs.
-       // (Paul Brannan 3/19/99)
-       } else {
-               pszBuffer = pszBufferEnd;
-       }
-
-       return(Parser.ParseBuffer(pszHead, pszBuffer));
-}
-
-// telProcessNetwork calls the member function TTelnetHandler::Go, since
-// TTelnetHandler::Go is not a static function, and cannot be called with
-// CreateThread().  (Paul Brannan 6/15/98)
-DWORD WINAPI telProcessNetwork(LPVOID lpParameter) {
-       TelThreadParams *pParams = (TelThreadParams *)lpParameter;
-       return pParams->TelHandler.Go(&pParams->p);
-}
-
-// This function is what used to be telProcessNetwork (Paul Brannan 6/15/98)
-DWORD TTelnetHandler::Go(LPVOID pvParams)
-{
-       NetParams *pParams = (NetParams *)pvParams;
-
-       // No longer a need to copy pParams-> socket and create an instance
-       // of TANSIParser (Paul Brannan 6/15/98)
-
-       Console.sync(); // Sync with the parser so the cursor is positioned
-       
-       Parser.Init(); // Reset the parser (Paul Brannan 9/19/98)
-       init(); // Turn on local echo (Paul Brannan 9/19/98)
-
-       *pParams->bNetFinished = 0;
-       char* pszHead = szBuffer;
-       char* pszTail = szBuffer;
-       while (!*pParams->bNetFinish) {
-               // Get data from Socket
-               *pParams->bNetPaused = 1;  //Pause
-               int Result = Network.ReadString(pszTail, (szBuffer + dwBuffer) - pszTail);
-
-               // Speed up mouse by not going into loop (Paul Brannan 8/10/98)
-               // while(*pParams->bNetPause && !*pParams->bNetFinish) *pParams->bNetPaused = 1;  //Pause
-               if(WaitForSingleObject(pParams->hPause, 0) == WAIT_OBJECT_0)
-                       WaitForSingleObject(pParams->hUnPause, INFINITE);
-
-               *pParams->bNetPaused = 0;  //UnPause
-
-               if (Result <= 0 || Result > dwBuffer ){
-                       break;
-               }
-               pszTail += Result;
-               
-               // Process the buffer
-               char* pszNewHead = pszHead;
-               do {
-                       // Speed up mouse by not going into loop (Paul Brannan 8/10/98)
-                       if(WaitForSingleObject(pParams->hPause, 0) == WAIT_OBJECT_0) {
-                               *pParams->bNetPaused = 1;
-                               WaitForSingleObject(pParams->hUnPause, INFINITE);
-                               *pParams->bNetPaused = 0;
-                       }
-                       
-                       pszHead = pszNewHead;
-                       pszNewHead = ParseBuffer(pszHead, pszTail); // Parse buffer
-               } while ((pszNewHead != pszHead) && (pszNewHead < pszTail) && !*pParams->bNetFinish);
-               pszHead = pszNewHead;
-               
-               // When we reach the end of the buffer, move contents to the
-               // beginning of the buffer to get free space at the end.
-               if (pszTail == (szBuffer + dwBuffer)) {
-                       memmove(szBuffer, pszHead, pszTail - pszHead);
-                       pszTail = szBuffer + (pszTail - pszHead);
-                       pszHead = szBuffer;
-               }
-       }
-       SetEvent(pParams->hExit);
-
-       printm(0, FALSE, MSG_TERMBYREM);
-       *pParams->bNetPaused = 1;  //Pause
-       *pParams->bNetFinished = 1;
-       return 0;
-}
diff --git a/reactos/apps/utils/net/telnet/src/ttelhndl.h b/reactos/apps/utils/net/telnet/src/ttelhndl.h
deleted file mode 100644 (file)
index ad4ec62..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-#ifndef __TTELHNDL_H
-#define __TTELHNDL_H
-
-#include "tparser.h"
-#include "tnetwork.h"
-
-DWORD WINAPI telProcessNetwork(LPVOID lpParameter);
-
-class TTelnetHandler {
-private:
-       int iTermSet;
-       int bInBinaryRx, bInBinaryTx;
-       int bInEchoTx, bInEchoRx;
-       int iWillSGA;
-
-       void init();
-
-       int escapeIAC(char *buf, int length);
-
-       // Paul Brannan 5/15/98
-       void SendIAC(char c);
-       void SendIAC(char c1, char c2);
-       void SendIACParams(char c);
-       void SendIACParams(char c1, char c2);
-       void print_telopt(const char *s, int d);
-
-       TNetwork &Network;
-       TConsole &Console;
-       TParser &Parser;
-
-       char* ParseBuffer(char* pszBuffer, char* pszBufferEnd);
-       char* ParseIAC(char* pszBuffer, char* pszBufferEnd);
-
-       // Paul Brannan 9/13/98
-       char *szBuffer, *tmpBuffer;
-       char *ansiBufferStart, *ansiBufferEnd;
-       int dwBuffer;
-
-       void do_naws(int width, int height);
-
-public:
-       TTelnetHandler(TNetwork &RefNetwork, TConsole &RefConsole,
-               TParser &RefParser);
-       ~TTelnetHandler();
-
-       DWORD Go(LPVOID pvParams);
-
-       int get_term() {return iTermSet;}
-};
-
-#endif
diff --git a/reactos/apps/utils/net/telnet/telnet.cfg b/reactos/apps/utils/net/telnet/telnet.cfg
deleted file mode 100644 (file)
index 37a2f51..0000000
+++ /dev/null
@@ -1,2616 +0,0 @@
-; Console Telnet 2.0 keys.cfg
-;
-[comment]
-
-This is a completely rewritten configuration file for Console Telnet 2.0.
-
-Now you can define multiple keymaps, character maps, and combine them in your
-own ways.
-
-Possible definition:
- [COMMENT]
- ...
- [END COMMENT]
-        This is for commenting a big part of text. can be nested.
-        In text these also work:
-           ; - First printable character in line, which is completely
-               ignored.
-           // - Like C++ comment
-
- [GLOBAL]
- ...
- [END GLOBAL]
-        This part is required.  For an explanation look at the body.
-
- [KEYMAP name]
- ...
- [END KEYMAP]
-        'name' - is a keymap name for reference.  In 'name' you can use
-        any char exept spaces, '+', ':' and ']'. '+' and ':' reserved for
-        CONFIG section.
-        Body is a sequence of key definitions:
-
-           <vk_name> [keymodifier[+keymodifier[+...]]] <keytranslation>
-
-        example:
-           VK_F1 RIGHT_ALT+RIGHT_CTRL this_would_print
-
-        vk_name is an ASCII string equivalent to an entry in [GLOBAL].
-
-        Valid keymodifiers are:
-          RIGHT_ALT
-          LEFT_ALT
-          RIGHT_CTRL
-          LEFT_CTRL
-          SHIFT
-          ENHANCED
-          NUMLOCK
-          CAPSLOCK
-          SCROLLLOCK
-          APP_KEY
-          APP2_KEY
-          APP3_KEY
-          APP4_KEY
-
-        Undefined enhanced keys will use the non-enhanced definition.
-
-        APP_KEY, APP2_KEY, and APP3_KEY are application-specific key modes.
-        Other terminal emulations (which have not yet been implemented) may
-        use other definitions for these keys, but for the standard ANSI
-        emulation, these mean:
-                APP_KEY - VT100 application cursor keys
-                APP2_KEY - VT52 cursor keys
-                APP3_KEY - VT102 alternate keypad mode
-                APP4_KEY - VT100 newline mode set
-
-        keytranslation is the string you want printed for the key.
-        The notation ^[ can be used to denote an escape character.
-        Any ASCII value can be represented by
-
-            \nnn where nnn is a 3 digit decimal ASCII value or
-            \xhh where hh is a 2 digit hexadecimal ASCII value.
-
-        Leading zeros may not be omitted.
-        A value of \000(\x00) will not be transmitted.
-       Rather, if you put \000 you undefine a key.  If you must send a NULL character,
-       please use \TN_NULL\.
-
-       A word on special sequences:
-       Any sequence of the form: \TN_...\ is a special sequence, which will perform a
-       special function for telnet.  You may substitute one of these for keytranslation
-       for any key.  Some of the special sequences that telnet recognizes:
-
-               \TN_ESCAPE              Escape into the telnet client
-               \TN_SCROLLBACK          Go into the scrollback buffer
-               \TN_DIAL                Start a new telnet session
-               \TN_PASTE               Paste the contents of the clipboard to the server
-               \TN_NULL                Send a null sequence to the server
-               \TN_CR                  Send \rNULL to the server
-               \TN_CRLF                Send \r\n to the server
-
-        note: In order to have both left and right alt have the same
-        action, you must create a separate def for left and right.
-
- [CHARMAP name]
- ...
- [END CHARMAP]
-        'name' - is a charmap name for reference.  Requirements are the same
-        as for keymap name.
-        body is a sequence of char conversion definition:
-
-           <host_char> <console_char>
-
-        where host_char is a char received from host, and console_char
-        is a char, which would be displayed on console.
-
-        The main purpose of it is a conversion between differents code
-        pages, for example, on former USSR part of world most unix's hosts
-        uses 'koi8' code page, and on W95 machines - 866 code page.
-
-        Any ASCII value can be represented by
-
-            \nnn where nnn is a 3 digit decimal ASCII value or
-            \xhh where hh is a 2 digit hexadecimal ASCII value.
-
-        Leading zeros may be omitted.
-        A value of \000(\x00) will not be accepted.
-
-        Look for example at [charmap koi8-cp866].
-
- [CONFIG name]
- ...
- [END CONFIG]
-        'name' - is a configuration name for reference.  Requirements are
-        the same as for keymap name.
-
-        You must define one with name 'default', which will be used as
-        default.
-
-        In the body of this section you can combine keymaps and set
-        the charmap.  The format for this is:
-
-           KEYMAP name_list [: <vk_name> [keymodifier[+keymodifier[+...]]] ]
-
-             where
-                  name_list:
-                     keymap_name
-                     keymap_name '+' name_list
-
-                  keymap_name is a name of [KEYMAP]
-
-             You can specify multiple keymaps, for first (the default)
-             you can not define ': <vk_name> ...' part, but for the rest
-             (secondary) you must!
-             The ': <vk_name> ...' part defines a key for switch to this
-             keymap.
-
-             Assigning a switching key to the first (default) keymap will be
-             ignored, but you can switch to by pressing a second time the
-             switch key for the current keymap.
-
-             If a key is not found in a switched keymap, a program will
-             look for it in the default keymap. So, you only need to redefine
-             needed keys in secondary keymaps.
-
-           CHARMAP name
-
-             define which charmap is to use.
-
-           examples:
-              [config default]
-                 keymap default
-              [end config]
-
-              [config linux]
-                 keymap default + linux
-              [end config]
-
-              [config default_koi8]
-                 keymap default
-                 keymap koi8u + koi8r : VK_/ RIGHT_ALT // russian keyboard
-                 keymap koi8u         : VK_. RIGHT_ALT // ukranian
-
-                 charmap koi8-cp866
-              [end config]
-
-              [config linux_koi8]
-                 keymap default + linux
-                 keymap koi8u + koi8r : VK_/ RIGHT_ALT // russian keyboard
-                 keymap koi8u         : VK_. RIGHT_ALT // ukranian
-
-                 charmap koi8-cp866
-              [end config]
-
-            For switching to russian keyboard just press RIGHT_ALT and '/'.
-            To switch back press it again.
-
-[end comment]
-
-[GLOBAL]
-; DO NOT MODIFY THE GLOBALS UNLESS YOU KNOW WHAT YOU ARE DOING.
-; The globals are required for the key translation to work.
-; do not place keymap before globals
-
-VK_LBUTTON    01    Left mouse button
-VK_RBUTTON    02    Right mouse button
-VK_CANCEL     03    Control-break processing
-VK_MBUTTON    04    Middle mouse button (three-button mouse)
-;--         05-07   Undefined
-VK_BACK       08    BACKSPACE key
-VK_TAB        09    TAB key
-;--         10-11   Undefined
-VK_CLEAR      12    CLEAR key
-VK_RETURN     13    ENTER key
-;--         14-15   Undefined
-;VK_SHIFT     16    SHIFT key
-;VK_CONTROL   17    CTRL key
-;VK_MENU      18    ALT key
-
-VK_PAUSE      19    PAUSE key
-;VK_CAPITAL   20    CAPS LOCK key
-;--         21-25   Reserved for Kanji systems
-;--           26    Undefined
-VK_ESCAPE     27    ESC key
-;--         28-31   Reserved for Kanji systems
-VK_SPACE      32    SPACEBAR
-VK_PGUP       33    PAGE UP key
-VK_PGDN       34    PAGE DOWN key
-VK_END        35    END key
-VK_HOME       36    HOME key
-VK_LEFT       37    LEFT ARROW key
-VK_UP         38    UP ARROW key
-VK_RIGHT      39    RIGHT ARROW key
-VK_DOWN       40    DOWN ARROW key
-VK_SELECT     41    SELECT key
-;--           42    Original equipment manufacturer (OEM) specific
-VK_EXECUTE    43    EXECUTE key
-VK_SNAPSHOT   44    PRINT SCREEN key for Windows 3.0 and later
-VK_INSERT     45    INS key
-VK_DELETE     46    DEL key
-VK_HELP       47    HELP key
-VK_0          48    0 key
-VK_1          49    1 key
-VK_2          50    2 key
-VK_3          51    3 key
-VK_4          52    4 key
-VK_5          53    5 key
-VK_6          54    6 key
-VK_7          55    7 key
-VK_8          56    8 key
-VK_9          57    9 key
-;--         58-64   Undefined
-VK_A          65    A key
-VK_B          66    B key
-VK_C          67    C key
-VK_D          68    D key
-VK_E          69    E key
-VK_F          70    F key
-VK_G          71    G key
-VK_H          72    H key
-VK_I          73    I key
-VK_J          74    J key
-VK_K          75    K key
-VK_L          76    L key
-VK_M          77    M key
-VK_N          78    N key
-VK_O          79    O key
-VK_P          80    P key
-VK_Q          81    Q key
-VK_R          82    R key
-VK_S          83    S key
-VK_T          84    T key
-VK_U          85    U key
-VK_V          86    V key
-VK_W          87    W key
-VK_X          88    X key
-VK_Y          89    Y key
-VK_Z          90    Z key
-;--          91-95  Undefined
-VK_NUMPAD0    96    Numeric keypad 0 key
-VK_NUMPAD1    97    Numeric keypad 1 key
-VK_NUMPAD2    98    Numeric keypad 2 key
-VK_NUMPAD3    99    Numeric keypad 3 key
-VK_NUMPAD4    100   Numeric keypad 4 key
-VK_NUMPAD5    101   Numeric keypad 5 key
-VK_NUMPAD6    102   Numeric keypad 6 key
-VK_NUMPAD7    103   Numeric keypad 7 key
-VK_NUMPAD8    104   Numeric keypad 8 key
-VK_NUMPAD9    105   Numeric keypad 9 key
-VK_MULTIPLY   106   Multiply key
-VK_ADD        107   Add key
-VK_SEPARATOR  108   Separator key
-VK_SUBTRACT   109   Subtract key
-VK_DECIMAL    110   Decimal key
-VK_DIVIDE     111   Divide key
-VK_F1         112   F1 key
-VK_F2         113   F2 key
-VK_F3         114   F3 key
-VK_F4         115   F4 key
-VK_F5         116   F5 key
-VK_F6         117   F6 key
-VK_F7         118   F7 key
-VK_F8         119   F8 key
-VK_F9         120   F9 key
-VK_F10        121   F10 key
-VK_F11        122   F11 key
-VK_F12        123   F12 key
-VK_F13        124   F13 key
-VK_F14        125   F14 key
-VK_F15        126   F15 key
-VK_F16        127   F16 key
-VK_F17        128   F17 key
-VK_F18        129   F18 key
-VK_F19        130   F19 key
-VK_F20        131   F20 key
-VK_F21        132   F21 key
-VK_F22        133   F22 key
-VK_F23        134   F23 key
-VK_F24        135   F24 key
-;--         136-143 Unassigned
-VK_NUMLOCK    144   NUM LOCK key
-VK_SCROLL     145   SCROLL LOCK key
-;--         146-185 Unassigned
-
-;
-;
-;  John Ioannou (roryt@hol.gr)
-;     Athens 30/03/97 10:42pm GMT-2
-;  Correction for Win95
-;
-; This keys are used (at least in my keyboard -737/437 cp)
-; for some common keys (equal, slash, backslash etc).
-; Normally we don't want to define them, but
-; there is a bug with win95 with them :
-; with CAPS LOCK on they produce the SHIFTED character
-; (minus gives _, = gives + etc).
-;
-;
-;--         186-192 OEM specific
-VK_;          186   ;
-VK_=          187   EQUAL
-VK_,          188   ,
-VK_-          189   MINUS
-VK_.          190   FULLSTOP
-VK_/          191   SLASH
-VK_`          192   `
-;--         193-218 Unassigned
-;--         219-228 OEM specific
-VK_[          219   [
-VK_\          220   BACKSLASH
-VK_]          221   ]
-VK_'          222   '
-;--          229    Unassigned
-;--          230    OEM specific
-;--         231-232 Unassigned
-;--         233-245 OEM specific
-;--         246-254 Unassigned
-
-[END GLOBAL]
-
-[keymap ANSI]
-;
-;  John Ioannou (roryt@hol.gr)
-;     Athens 30/03/97 10:42pm GMT-2
-;
-;        these are full (SCO and not only) ANSI
-;        also they deal with the win95 bug and
-;        give support for the Midnight Commander
-;
-;
-;  function keys
-;
-VK_F1                                  ^[[M
-VK_F2                                  ^[[N
-VK_F3                                  ^[[O
-VK_F4                                  ^[[P
-VK_F5                                  ^[[Q
-VK_F6                                  ^[[R
-VK_F7                                  ^[[S
-VK_F8                                  ^[[T
-VK_F9                                  ^[[U
-VK_F10                                 ^[[V
-VK_F11                                 ^[[W
-VK_F12                                 ^[[X
-VK_F1            SHIFT                 ^[[Y
-VK_F2            SHIFT                 ^[[Z
-VK_F3            SHIFT                 ^[[a
-VK_F4            SHIFT                 ^[[b
-VK_F5            SHIFT                 ^[[c
-VK_F6            SHIFT                 ^[[d
-VK_F7            SHIFT                 ^[[e
-VK_F8            SHIFT                 ^[[f
-VK_F9            SHIFT                 ^[[g
-VK_F10           SHIFT                 ^[[h
-VK_F11           SHIFT                 ^[[i
-VK_F12           SHIFT                 ^[[j
-VK_F1            RIGHT_CTRL            ^[[k
-VK_F2            RIGHT_CTRL            ^[[l
-VK_F3            RIGHT_CTRL            ^[[m
-VK_F4            RIGHT_CTRL            ^[[n
-VK_F5            RIGHT_CTRL            ^[[o
-VK_F6            RIGHT_CTRL            ^[[p
-VK_F7            RIGHT_CTRL            ^[[q
-VK_F8            RIGHT_CTRL            ^[[r
-VK_F9            RIGHT_CTRL            ^[[s
-VK_F10           RIGHT_CTRL            ^[[t
-VK_F11           RIGHT_CTRL            ^[[y
-VK_F12           RIGHT_CTRL            ^[[v
-VK_F1            LEFT_CTRL             ^[[k
-VK_F2            LEFT_CTRL             ^[[l
-VK_F3            LEFT_CTRL             ^[[m
-VK_F4            LEFT_CTRL             ^[[n
-VK_F5            LEFT_CTRL             ^[[o
-VK_F6            LEFT_CTRL             ^[[p
-VK_F7            LEFT_CTRL             ^[[q
-VK_F8            LEFT_CTRL             ^[[r
-VK_F9            LEFT_CTRL             ^[[s
-VK_F10           LEFT_CTRL             ^[[t
-VK_F11           LEFT_CTRL             ^[[y
-VK_F12           LEFT_CTRL             ^[[v
-;
-;  misc fuctions
-;
-; FIX ME!!!  Some people have reported that these keys don't work.
-VK_SCROLL                              \017
-VK_PAUSE                               \019
-VK_INSERT                              ^[[L
-VK_DELETE        ENHANCED              \127
-VK_HOME                                ^[[H
-VK_PGUP                                ^[[I
-VK_PGDN                                ^[[G
-VK_END                                 ^[[F
-VK_INSERT        SHIFT                 ^[[L
-VK_DELETE        SHIFT+ENHANCED        \127
-VK_HOME          SHIFT                 ^[[H
-VK_PGUP          SHIFT                 ^[[I
-VK_PGDN          SHIFT                 ^[[G
-VK_END           SHIFT                 ^[[F
-;
-; arrows
-;
-VK_LEFT                                ^[[D
-VK_UP                                  ^[[A
-VK_RIGHT                               ^[[C
-VK_DOWN                                ^[[B
-VK_LEFT          SHIFT                 ^[[D
-VK_UP            SHIFT                 ^[[A
-VK_RIGHT         SHIFT                 ^[[C
-VK_DOWN          SHIFT                 ^[[B
-;
-; just in case !!!
-;
-VK_ESCAPE        SHIFT                 \027
-VK_TAB                                 \009
-VK_TAB           SHIFT                 ^[[Z^[[Z
-;
-;---------------------------------------
-;      Athens  30/03/97 10:55pm GMT+2
-;  Correction for Win95
-;
-VK_6             SHIFT                 \094
-VK_`                                   `
-VK_`             SHIFT                 ~
-VK_0             CAPSLOCK              0
-VK_1             CAPSLOCK              1
-VK_2             CAPSLOCK              2
-VK_3             CAPSLOCK              3
-VK_4             CAPSLOCK              4
-VK_5             CAPSLOCK              5
-VK_6             CAPSLOCK              6
-VK_7             CAPSLOCK              7
-VK_8             CAPSLOCK              8
-VK_9             CAPSLOCK              9
-VK_ESCAPE        CAPSLOCK              \027
-VK_`             CAPSLOCK              `
-VK_=             CAPSLOCK              =
-VK_-             CAPSLOCK              -
-VK_\             CAPSLOCK              \
-VK_[             CAPSLOCK              [
-VK_]             CAPSLOCK              ]
-VK_;             CAPSLOCK              ;
-VK_'             CAPSLOCK              '
-VK_,             CAPSLOCK              ,
-VK_.             CAPSLOCK              .
-VK_/             CAPSLOCK              /
-VK_0             CAPSLOCK+SHIFT        )
-VK_1             CAPSLOCK+SHIFT        !
-VK_2             CAPSLOCK+SHIFT        @
-VK_3             CAPSLOCK+SHIFT        #
-VK_4             CAPSLOCK+SHIFT        $
-VK_5             CAPSLOCK+SHIFT        %
-VK_6             CAPSLOCK+SHIFT        ^
-VK_7             CAPSLOCK+SHIFT        &
-VK_8             CAPSLOCK+SHIFT        *
-VK_9             CAPSLOCK+SHIFT        (
-VK_ESCAPE        CAPSLOCK+SHIFT        \027
-VK_`             CAPSLOCK+SHIFT        ~
-VK_=             CAPSLOCK+SHIFT        +
-VK_-             CAPSLOCK+SHIFT        _
-VK_\             CAPSLOCK+SHIFT        |
-VK_[             CAPSLOCK+SHIFT        {
-VK_]             CAPSLOCK+SHIFT        }
-VK_;             CAPSLOCK+SHIFT        :
-VK_'             CAPSLOCK+SHIFT        "
-VK_,             CAPSLOCK+SHIFT        <
-VK_.             CAPSLOCK+SHIFT        >
-VK_/             CAPSLOCK+SHIFT        ?
-;
-;
-;---------------------------------------
-;
-; These are for use with Midnight Commander
-; they map Meta key to ALT (Like Linux console, nice isn't it ? )
-;
-VK_0             RIGHT_ALT             ^[0
-VK_1             RIGHT_ALT             ^[1
-VK_2             RIGHT_ALT             ^[2
-VK_3             RIGHT_ALT             ^[3
-VK_4             RIGHT_ALT             ^[4
-VK_5             RIGHT_ALT             ^[5
-VK_6             RIGHT_ALT             ^[6
-VK_7             RIGHT_ALT             ^[7
-VK_8             RIGHT_ALT             ^[8
-VK_9             RIGHT_ALT             ^[9
-VK_A             RIGHT_ALT             ^[A
-VK_B             RIGHT_ALT             ^[B
-VK_C             RIGHT_ALT             ^[C
-VK_D             RIGHT_ALT             ^[D
-VK_E             RIGHT_ALT             ^[E
-VK_F             RIGHT_ALT             ^[F
-VK_G             RIGHT_ALT             ^[G
-VK_H             RIGHT_ALT             ^[H
-VK_I             RIGHT_ALT             ^[I
-VK_J             RIGHT_ALT             ^[J
-VK_K             RIGHT_ALT             ^[K
-VK_L             RIGHT_ALT             ^[L
-VK_M             RIGHT_ALT             ^[M
-VK_N             RIGHT_ALT             ^[N
-VK_O             RIGHT_ALT             ^[O
-VK_P             RIGHT_ALT             ^[P
-VK_Q             RIGHT_ALT             ^[Q
-VK_R             RIGHT_ALT             ^[R
-VK_S             RIGHT_ALT             ^[S
-VK_T             RIGHT_ALT             ^[T
-VK_U             RIGHT_ALT             ^[U
-VK_V             RIGHT_ALT             ^[V
-VK_W             RIGHT_ALT             ^[W
-VK_X             RIGHT_ALT             ^[X
-VK_Y             RIGHT_ALT             ^[Y
-VK_Z             RIGHT_ALT             ^[Z
-VK_0             LEFT_ALT              ^[0
-VK_1             LEFT_ALT              ^[1
-VK_2             LEFT_ALT              ^[2
-VK_3             LEFT_ALT              ^[3
-VK_4             LEFT_ALT              ^[4
-VK_5             LEFT_ALT              ^[5
-VK_6             LEFT_ALT              ^[6
-VK_7             LEFT_ALT              ^[7
-VK_8             LEFT_ALT              ^[8
-VK_9             LEFT_ALT              ^[9
-VK_A             LEFT_ALT              ^[a
-VK_B             LEFT_ALT              ^[b
-VK_C             LEFT_ALT              ^[c
-VK_D             LEFT_ALT              ^[d
-VK_E             LEFT_ALT              ^[e
-VK_F             LEFT_ALT              ^[f
-VK_G             LEFT_ALT              ^[g
-VK_H             LEFT_ALT              ^[h
-VK_I             LEFT_ALT              ^[i
-VK_J             LEFT_ALT              ^[j
-VK_K             LEFT_ALT              ^[k
-VK_L             LEFT_ALT              ^[l
-VK_M             LEFT_ALT              ^[m
-VK_N             LEFT_ALT              ^[n
-VK_O             LEFT_ALT              ^[o
-VK_P             LEFT_ALT              ^[p
-VK_Q             LEFT_ALT              ^[q
-VK_R             LEFT_ALT              ^[r
-VK_S             LEFT_ALT              ^[s
-VK_T             LEFT_ALT              ^[t
-VK_U             LEFT_ALT              ^[u
-VK_V             LEFT_ALT              ^[v
-VK_W             LEFT_ALT              ^[w
-VK_X             LEFT_ALT              ^[x
-VK_Y             LEFT_ALT              ^[y
-VK_Z             LEFT_ALT              ^[z
-VK_RETURN        RIGHT_CTRL            \TN_CR
-VK_RETURN        LEFT_CTRL             \TN_CR
-; VK_RETURN now sends CR except in newline mode (Paul Brannan 12/9/98)
-VK_RETURN                              \TN_CR
-VK_RETURN        APP4_KEY              \TN_CRLF
-VK_RETURN        ENHANCED              \TN_CR
-; This is for application cursor keys (Paul Brannan 5/27/98)
-VK_LEFT       APP_KEY                  ^[OD
-VK_UP         APP_KEY                  ^[OA
-VK_RIGHT      APP_KEY                  ^[OC
-VK_DOWN       APP_KEY                  ^[OB
-VK_LEFT       APP_KEY+SHIFT            ^[OD
-VK_UP         APP_KEY+SHIFT            ^[OA
-VK_RIGHT      APP_KEY+SHIFT            ^[OC
-VK_DOWN       APP_KEY+SHIFT            ^[OB
-; APP2_KEY is for VT52 support (Paul Brannan 6/28/98)
-VK_LEFT       APP2_KEY                 ^[D
-VK_UP         APP2_KEY                 ^[A
-VK_RIGHT      APP2_KEY                 ^[C
-VK_DOWN       APP2_KEY                 ^[B
-VK_LEFT       APP2_KEY+SHIFT           ^[D
-VK_UP         APP2_KEY+SHIFT           ^[A
-VK_RIGHT      APP2_KEY+SHIFT           ^[C
-VK_DOWN       APP2_KEY+SHIFT           ^[B
-VK_F1         APP2_KEY                 ^[P
-VK_F2         APP2_KEY                 ^[Q
-VK_F3         APP2_KEY                 ^[R
-VK_F4         APP2_KEY                 ^[S
-VK_F5         APP2_KEY                 ^[?w
-VK_F6         APP2_KEY                 ^[?x
-VK_F7         APP2_KEY                 ^[?y
-VK_F8         APP2_KEY                 ^[?m
-VK_F9         APP2_KEY                 ^[?t
-VK_F10        APP2_KEY                 ^[?u
-VK_F1         APP2_KEY+SHIFT           ^[?v
-VK_F2         APP2_KEY+SHIFT           ^[?l
-VK_F3         APP2_KEY+SHIFT           ^[?q
-VK_F4         APP2_KEY+SHIFT           ^[?r
-VK_F5         APP2_KEY+SHIFT           ^[?s
-VK_F6         APP2_KEY+SHIFT           ^[?M
-VK_F7         APP2_KEY+SHIFT           ^[?p
-VK_F8         APP2_KEY+SHIFT           ^[?n
-
-; Fix for the numeric decimal key (Paul Brannan 9/23/98)
-VK_DELETE                              \127
-VK_DELETE     NUMLOCK                  .
-VK_DELETE     NUMLOCK+SHIFT            \127
-
-; VT100 Application keypad mode (Paul Brannan 12/8/98)
-VK_NUMPAD0      APP3_KEY                ^[Op
-VK_NUMPAD1      APP3_KEY                ^[Oq
-VK_NUMPAD2      APP3_KEY                ^[Or
-VK_NUMPAD3      APP3_KEY                ^[Os
-VK_NUMPAD4      APP3_KEY                ^[Ot
-VK_NUMPAD5      APP3_KEY                ^[Ou
-VK_NUMPAD6      APP3_KEY                ^[Ov
-VK_NUMPAD7      APP3_KEY                ^[Ow
-VK_NUMPAD8      APP3_KEY                ^[Ox
-VK_NUMPAD9      APP3_KEY                ^[Oy
-VK_ADD          APP3_KEY                ^[Ol
-VK_SUBTRACT     APP3_KEY                ^[Om
-VK_DELETE       APP3_KEY                ^[On
-VK_RETURN       ENHANCED+APP3_KEY       ^[OM
-
-; VT52 Application keypad mode (Paul Brannan 12/8/98)
-VK_NUMPAD0      APP2_KEY+APP3_KEY       ^[?p
-VK_NUMPAD1      APP2_KEY+APP3_KEY       ^[?q
-VK_NUMPAD2      APP2_KEY+APP3_KEY       ^[?r
-VK_NUMPAD3      APP2_KEY+APP3_KEY       ^[?s
-VK_NUMPAD4      APP2_KEY+APP3_KEY       ^[?t
-VK_NUMPAD5      APP2_KEY+APP3_KEY       ^[?u
-VK_NUMPAD6      APP2_KEY+APP3_KEY       ^[?v
-VK_NUMPAD7      APP2_KEY+APP3_KEY       ^[?w
-VK_NUMPAD8      APP2_KEY+APP3_KEY       ^[?x
-VK_NUMPAD9      APP2_KEY+APP3_KEY       ^[?y
-VK_ADD          APP2_KEY+APP3_KEY       ^[?l
-VK_SUBTRACT     APP2_KEY+APP3_KEY       ^[?m
-VK_DELETE       APP2_KEY+APP3_KEY       ^[?n
-VK_RETURN    ENHANCED+APP2_KEY+APP3_KEY ^[?M
-
-; Extra control characters (Paul Brannan 12/10/98)
-VK_2            LEFT_CTRL               \x00\x00
-VK_2            RIGHT_CTRL              \x00\x00
-VK_6            LEFT_CTRL               \x1e
-VK_6            RIGHT_CTRL              \x1e
-VK_-            LEFT_CTRL               \x1f
-VK_-            RIGHT_CTRL              \x1f
-
-; A way to send the null Character (Paul Brannan 3/29/00)
-VK_SPACE       LEFT_CTRL               \TN_NULL
-VK_SPACE       RIGHT_CTRL              \TN_NULL
-
-[END keymap] // ansi
-
-[keymap LINUX]
-;
-;
-;  John Ioannou (roryt@hol.gr)
-;     Athens 12 April 1997
-;
-;      Linux keys
-;
-;  Andrew Smilianets (smile@head.aval.kiev.ua)
-;     Kiev 23 December 1997
-;
-;      duplicated with default stripped, so, to use it, declare
-;           keymap default+linux
-
-;
-;  function keys
-;
-VK_F1                                  ^[[[A
-VK_F2                                  ^[[[B
-VK_F3                                  ^[[[C
-VK_F4                                  ^[[[D
-VK_F5                                  ^[[[E
-VK_F6                                  ^[[17~
-VK_F7                                  ^[[18~
-VK_F8                                  ^[[19~
-VK_F9                                  ^[[20~
-VK_F10                                 ^[[21~
-VK_F11                                 ^[[23~
-VK_F12                                 ^[[24~
-VK_F1            SHIFT                 ^[[23~
-VK_F2            SHIFT                 ^[[24~
-VK_F3            SHIFT                 ^[[25~
-VK_F4            SHIFT                 ^[[26~
-VK_F5            SHIFT                 ^[[28~
-VK_F6            SHIFT                 ^[[29~
-VK_F7            SHIFT                 ^[[31~
-VK_F8            SHIFT                 ^[[32~
-VK_F9            SHIFT                 ^[[33~
-VK_F10           SHIFT                 ^[[34~
-VK_F11           SHIFT                 ^[[23~
-VK_F12           SHIFT                 ^[[24~
-VK_F1            RIGHT_CTRL            ^[[[A
-VK_F2            RIGHT_CTRL            ^[[[B
-VK_F3            RIGHT_CTRL            ^[[[C
-VK_F4            RIGHT_CTRL            ^[[[D
-VK_F5            RIGHT_CTRL            ^[[[E
-VK_F6            RIGHT_CTRL            ^[[17~
-VK_F7            RIGHT_CTRL            ^[[18~
-VK_F8            RIGHT_CTRL            ^[[19~
-VK_F9            RIGHT_CTRL            ^[[20~
-VK_F10           RIGHT_CTRL            ^[[21~
-VK_F11           RIGHT_CTRL            ^[[23~
-VK_F12           RIGHT_CTRL            ^[[24~
-VK_F1            LEFT_CTRL             ^[[[A
-VK_F2            LEFT_CTRL             ^[[[B
-VK_F3            LEFT_CTRL             ^[[[C
-VK_F4            LEFT_CTRL             ^[[[D
-VK_F5            LEFT_CTRL             ^[[[E
-VK_F6            LEFT_CTRL             ^[[17~
-VK_F7            LEFT_CTRL             ^[[18~
-VK_F8            LEFT_CTRL             ^[[19~
-VK_F9            LEFT_CTRL             ^[[20~
-VK_F10           LEFT_CTRL             ^[[21~
-VK_F11           LEFT_CTRL             ^[[23~
-VK_F12           LEFT_CTRL             ^[[24~
-;
-;  misc fuctions
-;
-VK_PAUSE                               ^[[P
-VK_INSERT                              ^[[2~
-VK_DELETE        ENHANCED              ^[[3~
-VK_HOME                                ^[[1~
-VK_PGUP                                ^[[5~
-VK_PGDN                                ^[[6~
-VK_END                                 ^[[4~
-VK_INSERT        SHIFT                 ^[[2~
-VK_DELETE        SHIFT+ENHANCED        ^[[3~
-VK_HOME          SHIFT                 ^[[1~
-VK_PGUP          SHIFT                 ^[[5~
-VK_PGDN          SHIFT                 ^[[6~
-VK_END           SHIFT                 ^[[4~
-VK_INSERT        LEFT_CTRL             ^[[2~
-VK_DELETE        LEFT_CTRL             ^[[3~
-VK_HOME          LEFT_CTRL             ^[[1~
-VK_PGUP          LEFT_CTRL             ^[[5~
-VK_PGDN          LEFT_CTRL             ^[[6~
-VK_END           LEFT_CTRL             ^[[4~
-VK_INSERT        RIGHT_CTRL            ^[[2~
-VK_DELETE        RIGHT_CTRL            ^[[3~
-VK_HOME          RIGHT_CTRL            ^[[1~
-VK_PGUP          RIGHT_CTRL            ^[[5~
-VK_PGDN          RIGHT_CTRL            ^[[6~
-VK_END           RIGHT_CTRL            ^[[4~
-;
-; arrows
-;
-VK_UP            RIGHT_CTRL            ^[[A
-VK_DOWN          RIGHT_CTRL            ^[[B
-VK_RIGHT         RIGHT_CTRL            ^[[C
-VK_LEFT          RIGHT_CTRL            ^[[D
-VK_UP            LEFT_CTRL             ^[[A
-VK_DOWN          LEFT_CTRL             ^[[B
-VK_RIGHT         LEFT_CTRL             ^[[C
-VK_LEFT          LEFT_CTRL             ^[[D
-VK_NUMPAD5                             ^[[G
-
-[END keymap] // linux
-
-[keymap vt100]
-; These were wrong, according to the docs I have.  They don't work with
-; Midnight Commander on my machine.  I'm not sure if
-; this is correct or not.  I've also changed F1 - F4 so that they
-; send PF1 - PF4, and F5 - F10 so they send VT102 application mode
-; DEC keypad sequences.  I changed SF1 - SF10 so they akso send DEC keypad
-; sequences, and CF6 - CF12 so they send VT320 keypad sequences.
-; (Paul Brannan 6/28/98)
-; 
-; The numpad keys seem to be wrong, too.  This has been fixed.
-; (Paul Brannan 12/8/98)
-VK_F1                                  ^[OP
-VK_F2                                  ^[OQ
-VK_F3                                  ^[OR
-VK_F4                                  ^[OS
-VK_F5                                  ^[Ow
-VK_F6                                  ^[Ox
-VK_F7                                  ^[Oy
-VK_F8                                  ^[Om
-VK_F9                                  ^[Ot
-VK_F10                                 ^[Ou
-VK_F1            SHIFT                 ^[Ov
-VK_F2            SHIFT                 ^[Ol
-VK_F3            SHIFT                 ^[Oq
-VK_F4            SHIFT                 ^[Or
-VK_F5            SHIFT                 ^[Os
-VK_F6            SHIFT                 ^[OM
-VK_F7            SHIFT                 ^[Op
-VK_F8            SHIFT                 ^[On
-VK_F6            RIGHT_CTRL            ^[[17~
-VK_F7            RIGHT_CTRL            ^[[18~
-VK_F8            RIGHT_CTRL            ^[[19~
-VK_F9            RIGHT_CTRL            ^[[20~
-VK_F10           RIGHT_CTRL            ^[[21~
-VK_F11           RIGHT_CTRL            ^[[23~
-VK_F12           RIGHT_CTRL            ^[[24~
-VK_F6            LEFT_CTRL             ^[[17~
-VK_F7            LEFT_CTRL             ^[[18~
-VK_F8            LEFT_CTRL             ^[[19~
-VK_F9            LEFT_CTRL             ^[[20~
-VK_F10           LEFT_CTRL             ^[[21~
-VK_F11           LEFT_CTRL             ^[[23~
-VK_F12           LEFT_CTRL             ^[[24~
-
-[END keymap] // vt100
-
-[keymap AT386]
-:
-; AT386 extended keys
-;
-; Dmitry Lapenkov <dl@bis.ru>
-;
-
-VK_LBUTTON                              ^M\x00
-VK_RBUTTON                              ^[^[
-VK_CANCEL                               ^C
-VK_MBUTTON                              ^[OP
-VK_BACK                                 ^H
-VK_BACK         SHIFT                   ^[[O
-VK_BACK         LEFT_CTRL               \127
-VK_BACK         RIGHT_CTRL              \127
-VK_TAB                                  ^I
-VK_TAB          SHIFT                   ^[[Z
-VK_TAB          LEFT_CTRL               ^[[Z
-VK_TAB          RIGHT_CTRL              ^[[Z
-VK_RETURN                               ^M\x00
-VK_RETURN       SHIFT                   ^[[R
-VK_RETURN       LEFT_CTRL               ^J
-VK_RETURN       RIGHT_CTRL              ^J
-VK_PAUSE                                ^S
-VK_PAUSE        LEFT_CTRL               ^C
-VK_PAUSE        RIGHT_CTRL              ^C
-VK_PAUSE        SHIFT                   ^S
-VK_ESCAPE                               ^[^[
-VK_ESCAPE       SHIFT                   ^[
-VK_BACK         LEFT_ALT                ^[[o
-VK_BACK         RIGHT_ALT               ^[[o
-VK_TAB          LEFT_ALT                ^[[z
-VK_TAB          RIGHT_ALT               ^[[z
-VK_RETURN       LEFT_ALT                ^[[r
-VK_RETURN       RIGHT_ALT               ^[[r
-VK_PAUSE        LEFT_ALT                ^[<
-VK_PAUSE        RIGHT_ALT               ^[>
-VK_PGUP                                 ^[[V
-VK_PGUP         SHIFT                   ^[[V
-VK_PGUP         LEFT_CTRL               ^[[W
-VK_PGUP         RIGHT_CTRL              ^[[W
-VK_PGDN                                 ^[[U
-VK_PGDN         SHIFT                   ^[[U
-VK_PGDN         LEFT_CTRL               ^[[X
-VK_PGDN         RIGHT_CTRL              ^[[X
-VK_END                                  ^[[Y
-VK_END          SHIFT                   ^[[Y
-VK_END          LEFT_CTRL               ^[[E
-VK_END          RIGHT_CTRL              ^[[E
-VK_HOME                                 ^[[H
-VK_HOME         SHIFT                   ^[[H
-VK_HOME         LEFT_CTRL               ^[[F
-VK_HOME         RIGHT_CTRL              ^[[F
-VK_LEFT                                 ^[[D
-VK_LEFT         SHIFT                   ^[[D
-VK_LEFT         LEFT_CTRL               ^[[K
-VK_LEFT         RIGHT_CTRL              ^[[K
-VK_UP                                   ^[[A
-VK_UP           SHIFT                   ^[[A
-VK_UP           LEFT_CTRL               ^[[I
-VK_UP           RIGHT_CTRL              ^[[I
-VK_RIGHT                                ^[[C
-VK_RIGHT        SHIFT                   ^[[C
-VK_RIGHT        LEFT_CTRL               ^[[L
-VK_RIGHT        RIGHT_CTRL              ^[[L
-VK_DOWN                                 ^[[B
-VK_DOWN         SHIFT                   ^[[B
-VK_DOWN         LEFT_CTRL               ^[[J
-VK_DOWN         RIGHT_CTRL              ^[[J
-VK_INSERT                               ^[[@
-VK_INSERT       SHIFT                   ^[[T
-VK_INSERT       LEFT_CTRL               ^[[T
-VK_INSERT       RIGHT_CTRL              ^[[T
-VK_DELETE                               \127
-VK_DELETE       SHIFT                   ^[[S
-VK_DELETE       LEFT_CTRL               ^[[S
-VK_DELETE       RIGHT_CTRL              ^[[S
-VK_PGUP         LEFT_ALT                ^[[v
-VK_PGUP         RIGHT_ALT               ^[[v
-VK_PGDN         LEFT_ALT                ^[[u
-VK_PGDN         RIGHT_ALT               ^[[u
-VK_END          LEFT_ALT                ^[[y
-VK_END          RIGHT_ALT               ^[[y
-VK_HOME         LEFT_ALT                ^[[h
-VK_HOME         RIGHT_ALT               ^[[h
-VK_LEFT         LEFT_ALT                ^[[d
-VK_LEFT         RIGHT_ALT               ^[[d
-VK_UP           LEFT_ALT                ^[[a
-VK_UP           RIGHT_ALT               ^[[a
-VK_RIGHT        LEFT_ALT                ^[[c
-VK_RIGHT        RIGHT_ALT               ^[[c
-VK_DOWN         LEFT_ALT                ^[[b
-VK_DOWN         RIGHT_ALT               ^[[b
-VK_INSERT       LEFT_ALT                ^[[t
-VK_INSERT       RIGHT_ALT               ^[[t
-VK_DELETE       LEFT_ALT                ^[[s
-VK_DELETE       RIGHT_ALT               ^[[s
-VK_0            LEFT_ALT                ^[N0
-VK_1            LEFT_ALT                ^[N1
-VK_2            LEFT_ALT                ^[N2
-VK_3            LEFT_ALT                ^[N3
-VK_4            LEFT_ALT                ^[N4
-VK_5            LEFT_ALT                ^[N5
-VK_6            LEFT_ALT                ^[N6
-VK_7            LEFT_ALT                ^[N7
-VK_8            LEFT_ALT                ^[N8
-VK_9            LEFT_ALT                ^[N9
-VK_0            RIGHT_ALT               ^[N0
-VK_1            RIGHT_ALT               ^[N1
-VK_2            RIGHT_ALT               ^[N2
-VK_3            RIGHT_ALT               ^[N3
-VK_4            RIGHT_ALT               ^[N4
-VK_5            RIGHT_ALT               ^[N5
-VK_6            RIGHT_ALT               ^[N6
-VK_7            RIGHT_ALT               ^[N7
-VK_8            RIGHT_ALT               ^[N8
-VK_9            RIGHT_ALT               ^[N9
-VK_A            LEFT_ALT                ^[NA
-VK_B            LEFT_ALT                ^[NB
-VK_C            LEFT_ALT                ^[NC
-VK_D            LEFT_ALT                ^[ND
-VK_E            LEFT_ALT                ^[NE
-VK_F            LEFT_ALT                ^[NF
-VK_G            LEFT_ALT                ^[NG
-VK_H            LEFT_ALT                ^[NH
-VK_I            LEFT_ALT                ^[NI
-VK_J            LEFT_ALT                ^[NJ
-VK_K            LEFT_ALT                ^[NK
-VK_L            LEFT_ALT                ^[NL
-VK_M            LEFT_ALT                ^[NM
-VK_M            LEFT_ALT                ^[NN
-VK_O            LEFT_ALT                ^[NO
-VK_P            LEFT_ALT                ^[NP
-VK_Q            LEFT_ALT                ^[NQ
-VK_R            LEFT_ALT                ^[NR
-VK_S            LEFT_ALT                ^[NS
-VK_T            LEFT_ALT                ^[NT
-VK_U            LEFT_ALT                ^[NU
-VK_V            LEFT_ALT                ^[NV
-VK_W            LEFT_ALT                ^[NW
-VK_X            LEFT_ALT                ^[NX
-VK_Y            LEFT_ALT                ^[NY
-VK_Z            LEFT_ALT                ^[NZ
-VK_A            RIGHT_ALT               ^[NA
-VK_B            RIGHT_ALT               ^[NB
-VK_C            RIGHT_ALT               ^[NC
-VK_D            RIGHT_ALT               ^[ND
-VK_E            RIGHT_ALT               ^[NE
-VK_F            RIGHT_ALT               ^[NF
-VK_G            RIGHT_ALT               ^[NG
-VK_H            RIGHT_ALT               ^[NH
-VK_I            RIGHT_ALT               ^[NI
-VK_J            RIGHT_ALT               ^[NJ
-VK_K            RIGHT_ALT               ^[NK
-VK_L            RIGHT_ALT               ^[NL
-VK_M            RIGHT_ALT               ^[NM
-VK_M            RIGHT_ALT               ^[NN
-VK_O            RIGHT_ALT               ^[NO
-VK_P            RIGHT_ALT               ^[NP
-VK_Q            RIGHT_ALT               ^[NQ
-VK_R            RIGHT_ALT               ^[NR
-VK_S            RIGHT_ALT               ^[NS
-VK_T            RIGHT_ALT               ^[NT
-VK_U            RIGHT_ALT               ^[NU
-VK_V            RIGHT_ALT               ^[NV
-VK_W            RIGHT_ALT               ^[NW
-VK_X            RIGHT_ALT               ^[NX
-VK_Y            RIGHT_ALT               ^[NY
-VK_Z            RIGHT_ALT               ^[NZ
-VK_NUMPAD0      LEFT_CTRL               ^[[T
-VK_NUMPAD0      RIGHT_CTRL              ^[[T
-VK_NUMPAD1      LEFT_CTRL               ^[[E
-VK_NUMPAD1      RIGHT_CTRL              ^[[E
-VK_NUMPAD2      LEFT_CTRL               ^[[J
-VK_NUMPAD2      RIGHT_CTRL              ^[[J
-VK_NUMPAD3      LEFT_CTRL               ^[[X
-VK_NUMPAD3      RIGHT_CTRL              ^[[X
-VK_NUMPAD4      LEFT_CTRL               ^[[K
-VK_NUMPAD4      RIGHT_CTRL              ^[[K
-VK_NUMPAD5      LEFT_CTRL               ^[[G
-VK_NUMPAD5      RIGHT_CTRL              ^[[G
-VK_NUMPAD6      LEFT_CTRL               ^[[L
-VK_NUMPAD6      RIGHT_CTRL              ^[[L
-VK_NUMPAD7      LEFT_CTRL               ^[[F
-VK_NUMPAD7      RIGHT_CTRL              ^[[F
-VK_NUMPAD8      LEFT_CTRL               ^[[I
-VK_NUMPAD8      RIGHT_CTRL              ^[[I
-VK_NUMPAD9      LEFT_CTRL               ^[[W
-VK_NUMPAD9      RIGHT_CTRL              ^[[W
-VK_MULTIPLY     LEFT_CTRL               ^[[Q
-VK_MULTIPLY     RIGHT_CTRL              ^[[Q
-VK_ADD          LEFT_CTRL               ^[[M
-VK_ADD          RIGHT_CTRL              ^[[M
-VK_SEPARATOR    SHIFT                   ^[[R
-VK_SEPARATOR    LEFT_CTRL               ^J
-VK_SEPARATOR    RIGHT_CTRL              ^J
-VK_SUBTRACT     LEFT_CTRL               ^[[N
-VK_SUBTRACT     RIGHT_CTRL              ^[[N
-VK_DECIMAL      LEFT_CTRL               ^[[S
-VK_DECIMAL      RIGHT_CTRL              ^[[S
-VK_DIVIDE       LEFT_CTRL               ^[[P
-VK_DIVIDE       RIGHT_CTRL              ^[[P
-VK_NUMPAD0      LEFT_ALT                ^X
-VK_NUMPAD0      RIGHT_ALT               ^X
-VK_NUMPAD1      LEFT_ALT                ^E
-VK_NUMPAD1      RIGHT_ALT               ^E
-VK_NUMPAD2      LEFT_ALT                ^X/
-VK_NUMPAD2      RIGHT_ALT               ^X/
-VK_NUMPAD3      LEFT_ALT                ^V
-VK_NUMPAD3      RIGHT_ALT               ^V
-VK_NUMPAD4      LEFT_ALT                ^X^F
-VK_NUMPAD4      RIGHT_ALT               ^X^F
-VK_NUMPAD5      LEFT_ALT                ^[[g
-VK_NUMPAD5      RIGHT_ALT               ^[[g
-VK_NUMPAD6      LEFT_ALT                ^X^Y
-VK_NUMPAD6      RIGHT_ALT               ^X^Y
-VK_NUMPAD7      LEFT_ALT                ^A
-VK_NUMPAD7      RIGHT_ALT               ^A
-VK_NUMPAD8      LEFT_ALT                ^X_
-VK_NUMPAD8      RIGHT_ALT               ^X_
-VK_NUMPAD9      LEFT_ALT                ^[v
-VK_NUMPAD9      RIGHT_ALT               ^[v
-VK_MULTIPLY     LEFT_ALT                ^[[q
-VK_MULTIPLY     RIGHT_ALT               ^[[q
-VK_ADD          LEFT_ALT                ^[[m
-VK_ADD          RIGHT_ALT               ^[[m
-VK_SEPARATOR    LEFT_ALT                ^[[r
-VK_SEPARATOR    RIGHT_ALT               ^[[r
-VK_SUBTRACT     LEFT_ALT                ^[[n
-VK_SUBTRACT     RIGHT_ALT               ^[[n
-VK_DECIMAL      LEFT_ALT                ^X^C
-VK_DECIMAL      RIGHT_ALT               ^X^C
-VK_DIVIDE       LEFT_ALT                ^[[p
-VK_DIVIDE       RIGHT_ALT               ^[[p
-VK_F1                                   ^[OP
-VK_F1           SHIFT                   ^[Op
-VK_F1           LEFT_CTRL               ^[Ob
-VK_F1           RIGHT_CTRL              ^[Ob
-VK_F2                                   ^[OQ
-VK_F2           SHIFT                   ^[Oq
-VK_F2           LEFT_CTRL               ^[Oc
-VK_F2           RIGHT_CTRL              ^[Oc
-VK_F3                                   ^[OR
-VK_F3           SHIFT                   ^[Or
-VK_F3           LEFT_CTRL               ^[Od
-VK_F3           RIGHT_CTRL              ^[Od
-VK_F4                                   ^[OS
-VK_F4           SHIFT                   ^[Os
-VK_F4           LEFT_CTRL               ^[Oe
-VK_F4           RIGHT_CTRL              ^[Oe
-VK_F5                                   ^[OT
-VK_F5           SHIFT                   ^[Ot
-VK_F5           LEFT_CTRL               ^[Of
-VK_F5           RIGHT_CTRL              ^[Of
-VK_F6                                   ^[OU
-VK_F6           SHIFT                   ^[Ou
-VK_F6           LEFT_CTRL               ^[Og
-VK_F6           RIGHT_CTRL              ^[Og
-VK_F7                                   ^[OV
-VK_F7           SHIFT                   ^[Ov
-VK_F7           LEFT_CTRL               ^[Oh
-VK_F7           RIGHT_CTRL              ^[Oh
-VK_F8                                   ^[OW
-VK_F8           SHIFT                   ^[Ow
-VK_F8           LEFT_CTRL               ^[Oi
-VK_F8           RIGHT_CTRL              ^[Oi
-VK_F9                                   ^[OX
-VK_F9           SHIFT                   ^[Ox
-VK_F9           LEFT_CTRL               ^[Oj
-VK_F9           RIGHT_CTRL              ^[Oj
-VK_F10                                  ^[OY
-VK_F10          SHIFT                   ^[Oy
-VK_F10          LEFT_CTRL               ^[Ok
-VK_F10          RIGHT_CTRL              ^[Ok
-VK_F11                                  ^[OZ
-VK_F11          SHIFT                   ^[Oz
-VK_F11          LEFT_CTRL               ^[Ol
-VK_F11          RIGHT_CTRL              ^[Ol
-VK_F12                                  ^[OA
-VK_F12          SHIFT                   ^[Oa
-VK_F12          LEFT_CTRL               ^[Om
-VK_F12          RIGHT_CTRL              ^[Om
-VK_F1           LEFT_ALT                 ^[O1
-VK_F1           RIGHT_ALT                ^[O1
-VK_F2           LEFT_ALT                 ^[O2
-VK_F2           RIGHT_ALT                ^[O2
-VK_F3           LEFT_ALT                 ^[O3
-VK_F3           RIGHT_ALT                ^[O3
-VK_F4           LEFT_ALT                 ^[O4
-VK_F4           RIGHT_ALT                ^[O4
-VK_F5           LEFT_ALT                 ^[O5
-VK_F5           RIGHT_ALT                ^[O5
-VK_F6           LEFT_ALT                 ^[O6
-VK_F6           RIGHT_ALT                ^[O6
-VK_F7           LEFT_ALT                 ^[O7
-VK_F7           RIGHT_ALT                ^[O7
-VK_F8           LEFT_ALT                 ^[O8
-VK_F8           RIGHT_ALT                ^[O8
-VK_F9           LEFT_ALT                 ^[O9
-VK_F9           RIGHT_ALT                ^[O9
-VK_F10          LEFT_ALT                 ^[O0
-VK_F10          RIGHT_ALT                ^[O0
-VK_F11          LEFT_ALT                 ^[O:
-VK_F11          RIGHT_ALT                ^[O:
-VK_F12          LEFT_ALT                 ^[O;
-VK_F12          RIGHT_ALT                ^[O;
-
-[END keymap]
-
-
-[keymap at386st]
-;
-; AT386 standard keys
-;
-
-VK_F1                                   ^[OP
-VK_F2                                   ^[OQ
-VK_F3                                   ^[OR
-VK_F4                                   ^[OS
-VK_F5                                   ^[OT
-VK_F6                                   ^[OU
-VK_F7                                   ^[OV
-VK_F8                                   ^[OW
-VK_F9                                   ^[OX
-VK_F10                                  ^[OY
-VK_F11                                  ^[[W
-VK_F12                                  ^[[X
-VK_SCROLL                               \017
-VK_PAUSE                                \019
-;
-VK_INSERT                               ^[[@
-VK_DELETE                               \004
-;
-VK_LEFT                                 ^[[D
-VK_UP                                   ^[[A
-VK_RIGHT                                ^[[C
-VK_DOWN                                 ^[[B
-;
-VK_HOME                                 ^[[H
-VK_PGUP                                 ^[[V
-VK_PGDN                                 ^[[U
-VK_END                                  ^[[Y
-;
-VK_TAB                                  \009
-VK_TAB          SHIFT                   ^[[Z
-VK_ESCAPE                               ^[
-
-[END keymap]
-
-;****************************************************************************
-;****************************************************************************
-;***                          Ukranian keyboard                           ***
-;****************************************************************************
-;****************************************************************************
-[keymap koi8u]
-
-; I prefer this
-VK_2             SHIFT                 "
-VK_2             CAPSLOCK+SHIFT        "
-VK_4             SHIFT                 ;
-VK_4             CAPSLOCK+SHIFT        ;
-VK_5             SHIFT                 %
-VK_5             CAPSLOCK+SHIFT        %
-VK_6             SHIFT                 :
-VK_6             CAPSLOCK+SHIFT        :
-VK_7             SHIFT                 ?
-VK_7             CAPSLOCK+SHIFT        ?
-VK_/                                   .
-VK_/             SHIFT                 ,
-VK_/             CAPSLOCK              .
-VK_/             CAPSLOCK+SHIFT        ,
-
-; next will be similar to std
-
-;                \xE1 CYRILLIC CAPITAL LETTER A
-;                \xC1 CYRILLIC SMALL   LETTER A
-VK_F                                   \xC1
-VK_F             SHIFT                 \xE1
-VK_F             CAPSLOCK              \xE1
-VK_F             CAPSLOCK+SHIFT        \xC1
-
-;                \xE2 CYRILLIC CAPITAL LETTER BE
-;                \xC2 CYRILLIC SMALL   LETTER BE
-VK_,                                   \xc2
-VK_,             SHIFT                 \xe2
-VK_,             CAPSLOCK              \xe2
-VK_,             CAPSLOCK+SHIFT        \xc2
-
-;                \xB6 CYRILLIC CAPITAL LETTER BELORUSSIAN-UKRAINIAN I
-;                \xA6 CYRILLIC SMALL   LETTER BELORUSSIAN-UKRAINIAN I
-VK_S                                   \xa6
-VK_S             SHIFT                 \xb6
-VK_S             CAPSLOCK              \xb6
-VK_S             CAPSLOCK+SHIFT        \xa6
-
-;                \xFE CYRILLIC CAPITAL LETTER CHE
-;                \xDE CYRILLIC SMALL   LETTER CHE
-VK_X                                   \xde
-VK_X             SHIFT                 \xfe
-VK_X             CAPSLOCK              \xfe
-VK_X             CAPSLOCK+SHIFT        \xde
-
-;                \xE4 CYRILLIC CAPITAL LETTER DE
-;                \xC4 CYRILLIC SMALL   LETTER DE
-VK_L                                   \xc4
-VK_L             SHIFT                 \xe4
-VK_L             CAPSLOCK              \xe4
-VK_L             CAPSLOCK+SHIFT        \xc4
-
-;                \xE6 CYRILLIC CAPITAL LETTER EF
-;                \xC6 CYRILLIC SMALL   LETTER EF
-VK_A                                   \xc6
-VK_A             SHIFT                 \xe6
-VK_A             CAPSLOCK              \xe6
-VK_A             CAPSLOCK+SHIFT        \xc6
-
-;                \xEC CYRILLIC CAPITAL LETTER EL
-;                \xCC CYRILLIC SMALL   LETTER EL
-VK_K                                   \xcc
-VK_K             SHIFT                 \xec
-VK_K             CAPSLOCK              \xec
-VK_K             CAPSLOCK+SHIFT        \xcc
-
-;                \xED CYRILLIC CAPITAL LETTER EM
-;                \xCD CYRILLIC SMALL   LETTER EM
-VK_V                                   \xcd
-VK_V             SHIFT                 \xed
-VK_V             CAPSLOCK              \xed
-VK_V             CAPSLOCK+SHIFT        \xcd
-
-;                \xEE CYRILLIC CAPITAL LETTER EN
-;                \xCE CYRILLIC SMALL   LETTER EN
-VK_Y                                   \xce
-VK_Y             SHIFT                 \xee
-VK_Y             CAPSLOCK              \xee
-VK_Y             CAPSLOCK+SHIFT        \xce
-
-;                \xF2 CYRILLIC CAPITAL LETTER ER
-;                \xD2 CYRILLIC SMALL   LETTER ER
-VK_H                                   \xd2
-VK_H             SHIFT                 \xf2
-VK_H             CAPSLOCK              \xf2
-VK_H             CAPSLOCK+SHIFT        \xd2
-
-;                \xF3 CYRILLIC CAPITAL LETTER ES
-;                \xD3 CYRILLIC SMALL   LETTER ES
-VK_C                                   \xd3
-VK_C             SHIFT                 \xf3
-VK_C             CAPSLOCK              \xf3
-VK_C             CAPSLOCK+SHIFT        \xd3
-
-;                \xE7 CYRILLIC CAPITAL LETTER GE
-;                \xC7 CYRILLIC SMALL   LETTER GE
-VK_U                                   \xc7
-VK_U             SHIFT                 \xe7
-VK_U             CAPSLOCK              \xe7
-VK_U             CAPSLOCK+SHIFT        \xc7
-
-;                \xF1 CYRILLIC CAPITAL LETTER IA
-;                \xD1 CYRILLIC SMALL   LETTER IA
-VK_Z                                   \xd1
-VK_Z             SHIFT                 \xf1
-VK_Z             CAPSLOCK              \xf1
-VK_Z             CAPSLOCK+SHIFT        \xd1
-
-;                \xE5 CYRILLIC CAPITAL LETTER IE
-;                \xC5 CYRILLIC SMALL   LETTER IE
-VK_T                                   \xc5
-VK_T             SHIFT                 \xe5
-VK_T             CAPSLOCK              \xe5
-VK_T             CAPSLOCK+SHIFT        \xc5
-
-;                \xE9 CYRILLIC CAPITAL LETTER II
-;                \xC9 CYRILLIC SMALL   LETTER II
-VK_B                                   \xc9
-VK_B             SHIFT                 \xe9
-VK_B             CAPSLOCK              \xe9
-VK_B             CAPSLOCK+SHIFT        \xc9
-
-;                \xE0 CYRILLIC CAPITAL LETTER IU
-;                \xC0 CYRILLIC SMALL   LETTER IU
-VK_.                                   \xc0
-VK_.             SHIFT                 \xe0
-VK_.             CAPSLOCK              \xe0
-VK_.             CAPSLOCK+SHIFT        \xc0
-
-;                \xEB CYRILLIC CAPITAL LETTER KA
-;                \xCB CYRILLIC SMALL   LETTER KA
-VK_R                                   \xcb
-VK_R             SHIFT                 \xeb
-VK_R             CAPSLOCK              \xeb
-VK_R             CAPSLOCK+SHIFT        \xcb
-
-;                \xE8 CYRILLIC CAPITAL LETTER KHA
-;                \xC8 CYRILLIC SMALL   LETTER KHA
-VK_[                                   \xc8
-VK_[             SHIFT                 \xe8
-VK_[             CAPSLOCK              \xE8
-VK_[             CAPSLOCK+SHIFT        \xC8
-
-;                \xEF CYRILLIC CAPITAL LETTER O
-;                \xCF CYRILLIC SMALL   LETTER O
-VK_J                                   \xcf
-VK_J             SHIFT                 \xef
-VK_J             CAPSLOCK              \xef
-VK_J             CAPSLOCK+SHIFT        \xcf
-
-;                \xF0 CYRILLIC CAPITAL LETTER PE
-;                \xD0 CYRILLIC SMALL   LETTER PE
-VK_G                                   \xd0
-VK_G             SHIFT                 \xf0
-VK_G             CAPSLOCK              \xf0
-VK_G             CAPSLOCK+SHIFT        \xd0
-
-;                \xFB CYRILLIC CAPITAL LETTER SHA
-;                \xDB CYRILLIC SMALL   LETTER SHA
-VK_I                                   \xdb
-VK_I             SHIFT                 \xfb
-VK_I             CAPSLOCK              \xfb
-VK_I             CAPSLOCK+SHIFT        \xdb
-
-;                \xFD CYRILLIC CAPITAL LETTER SHCHA
-;                \xDD CYRILLIC SMALL   LETTER SHCHA
-VK_O                                   \xdd
-VK_O             SHIFT                 \xfd
-VK_O             CAPSLOCK              \xfd
-VK_O             CAPSLOCK+SHIFT        \xdd
-
-;                \xEA CYRILLIC CAPITAL LETTER SHORT II
-;                \xCA CYRILLIC SMALL   LETTER SHORT II
-VK_Q                                   \xca
-VK_Q             SHIFT                 \xea
-VK_Q             CAPSLOCK              \xea
-VK_Q             CAPSLOCK+SHIFT        \xca
-
-;                \xF8 CYRILLIC CAPITAL LETTER SOFT SIGN
-;                \xD8 CYRILLIC SMALL   LETTER SOFT SIGN
-VK_M                                   \xd8
-VK_M             SHIFT                 \xf8
-VK_M             CAPSLOCK              \xf8
-VK_M             CAPSLOCK+SHIFT        \xd8
-
-;                \xF4 CYRILLIC CAPITAL LETTER TE
-;                \xD4 CYRILLIC SMALL   LETTER TE
-VK_N                                   \xd4
-VK_N             SHIFT                 \xf4
-VK_N             CAPSLOCK              \xf4
-VK_N             CAPSLOCK+SHIFT        \xd4
-
-;                \xE3 CYRILLIC CAPITAL LETTER TSE
-;                \xC3 CYRILLIC SMALL   LETTER TSE
-VK_W                                   \xc3
-VK_W             SHIFT                 \xe3
-VK_W             CAPSLOCK              \xe3
-VK_W             CAPSLOCK+SHIFT        \xc3
-
-;                \xF5 CYRILLIC CAPITAL LETTER U
-;                \xD5 CYRILLIC SMALL   LETTER U
-VK_E                                   \xd5
-VK_E             SHIFT                 \xf5
-VK_E             CAPSLOCK              \xf5
-VK_E             CAPSLOCK+SHIFT        \xd5
-
-;                \xBD CYRILLIC CAPITAL LETTER UKRAINIAN GHE (UPTURN)
-;                \xAD CYRILLIC SMALL   LETTER UKRAINIAN GHE (UPTURN)
-; not realized because not too many words use it, use GHE for it
-
-;                \xB4 CYRILLIC CAPITAL LETTER UKRAINIAN IE
-;                \xA4 CYRILLIC SMALL   LETTER UKRAINIAN IE
-VK_'                                   \xa4
-VK_'             SHIFT                 \xb4
-VK_'             CAPSLOCK              \xb4
-VK_'             CAPSLOCK+SHIFT        \xa4
-
-;                \xF7 CYRILLIC CAPITAL LETTER VE
-;                \xD7 CYRILLIC SMALL   LETTER VE
-VK_D                                   \xd7
-VK_D             SHIFT                 \xf7
-VK_D             CAPSLOCK              \xf7
-VK_D             CAPSLOCK+SHIFT        \xd7
-
-;                \xB7 CYRILLIC CAPITAL LETTER YI (UKRAINIAN)
-;                \xA7 CYRILLIC SMALL   LETTER YI (UKRAINIAN)
-VK_]                                   \xa7
-VK_]             SHIFT                 \xb7
-VK_]             CAPSLOCK              \xb7
-VK_]             CAPSLOCK+SHIFT        \xa7
-
-;                \xFA CYRILLIC CAPITAL LETTER ZE
-;                \xDA CYRILLIC SMALL   LETTER ZE
-VK_P                                   \xda
-VK_P             SHIFT                 \xfa
-VK_P             CAPSLOCK              \xfa
-VK_P             CAPSLOCK+SHIFT        \xda
-
-;                \xF6 CYRILLIC CAPITAL LETTER ZHE
-;                \xD6 CYRILLIC SMALL   LETTER ZHE
-VK_;                                   \xd6
-VK_;             SHIFT                 \xf6
-VK_;             CAPSLOCK              \xf6
-VK_;             CAPSLOCK+SHIFT        \xd6
-
-[END keymap] // koi8u
-
-[keymap koi8r]
-;****************************************************************************
-;****************************************************************************
-;***                           Russian keyboard.                          ***
-;***                                                                      ***
-;***            there are only differents from koi8u, so use              ***
-;***                  it as 'keymap koi8u + koi8r'                        ***
-;****************************************************************************
-;****************************************************************************
-
-;                \xFF CYRILLIC CAPITAL LETTER HARD SIGN
-;                \xDF CYRILLIC SMALL   LETTER HARD SIGN
-VK_]                                   \xdf
-VK_]             SHIFT                 \xff
-VK_]             CAPSLOCK              \xff
-VK_]             CAPSLOCK+SHIFT        \xdf
-
-;                \xB3 CYRILLIC CAPITAL LETTER IO
-;                \xA3 CYRILLIC SMALL   LETTER IO
-VK_`                                   \xa3
-VK_`             SHIFT                 \xb3
-VK_`             CAPSLOCK              \xb3
-VK_`             CAPSLOCK+SHIFT        \xa3
-
-;                \xFC CYRILLIC CAPITAL LETTER REVERSED E
-;                \xDC CYRILLIC SMALL   LETTER REVERSED E
-VK_'                                   \xdc
-VK_'             SHIFT                 \xfc
-VK_'             CAPSLOCK              \xfc
-VK_'             CAPSLOCK+SHIFT        \xdc
-
-;                \xF9 CYRILLIC CAPITAL LETTER YERI
-;                \xD9 CYRILLIC SMALL   LETTER YERI
-VK_S                                   \xd9
-VK_S             SHIFT                 \xf9
-VK_S             CAPSLOCK              \xf9
-VK_S             CAPSLOCK+SHIFT        \xd9
-
-[END keymap] // koi8r
-
-;****************************************************************************
-;****************************************************************************
-;***                    Russian keyboard IBM PC-866                       ***
-;***                                                                      ***
-;***                    Dmitry Lapenkov <dl@bis.ru>                       ***
-;****************************************************************************
-;****************************************************************************
-[keymap ibm866]
-
-VK_`                                   )
-VK_`             SHIFT                 (
-VK_`             CAPSLOCK              (
-VK_`             CAPSLOCK+SHIFT        )
-VK_2             SHIFT                 "
-VK_2             CAPSLOCK+SHIFT        "
-VK_3             SHIFT                 /
-VK_3             CAPSLOCK+SHIFT        /
-VK_4             SHIFT                 \xfc
-VK_4             CAPSLOCK+SHIFT        \xfc
-VK_5             SHIFT                 :
-VK_5             CAPSLOCK+SHIFT        :
-VK_6             SHIFT                 ,
-VK_6             CAPSLOCK+SHIFT        ,
-VK_7             SHIFT                 .
-VK_7             CAPSLOCK+SHIFT        .
-VK_8             SHIFT                 ;
-VK_8             CAPSLOCK+SHIFT        ;
-VK_9             SHIFT                 ?
-VK_9             CAPSLOCK+SHIFT        ?
-VK_0             SHIFT                 %
-VK_0             CAPSLOCK+SHIFT        %
-
-;                128 CYRILLIC CAPITAL LETTER A
-;                160 CYRILLIC SMALL   LETTER A
-VK_F                                   \160
-VK_F             SHIFT                 \128
-VK_F             CAPSLOCK              \128
-VK_F             CAPSLOCK+SHIFT        \160
-
-;                129 CYRILLIC CAPITAL LETTER BE
-;                161 CYRILLIC SMALL   LETTER BE
-VK_,                                   \161
-VK_,             SHIFT                 \129
-VK_,             CAPSLOCK              \129
-VK_,             CAPSLOCK+SHIFT        \161
-
-;                240 CYRILLIC CAPITAL LETTER SHORT YO
-;                241 CYRILLIC SMALL   LETTER SHORT YO
-VK_/                                   \241
-VK_/             SHIFT                 \240
-VK_/             CAPSLOCK              \240
-VK_/             CAPSLOCK+SHIFT        \241
-
-;                157 CYRILLIC CAPITAL LETTER REVERSED E
-;                237 CYRILLIC SMALL   LETTER REVERSED E
-VK_'                                   \237
-VK_'             SHIFT                 \157
-VK_'             CAPSLOCK              \157
-VK_'             CAPSLOCK+SHIFT        \237
-
-;                155 CYRILLIC CAPITAL LETTER YERI
-;                235 CYRILLIC SMALL   LETTER YERI
-VK_S                                   \235
-VK_S             SHIFT                 \155
-VK_S             CAPSLOCK              \155
-VK_S             CAPSLOCK+SHIFT        \235
-
-;                151 CYRILLIC CAPITAL LETTER CHE
-;                231 CYRILLIC SMALL   LETTER CHE
-VK_X                                   \231
-VK_X             SHIFT                 \151
-VK_X             CAPSLOCK              \151
-VK_X             CAPSLOCK+SHIFT        \231
-
-;                132 CYRILLIC CAPITAL LETTER DE
-;                164 CYRILLIC SMALL   LETTER DE
-VK_L                                   \164
-VK_L             SHIFT                 \132
-VK_L             CAPSLOCK              \132
-VK_L             CAPSLOCK+SHIFT        \164
-
-;                148 CYRILLIC CAPITAL LETTER EF
-;                228 CYRILLIC SMALL   LETTER EF
-VK_A                                   \228
-VK_A             SHIFT                 \148
-VK_A             CAPSLOCK              \148
-VK_A             CAPSLOCK+SHIFT        \228
-
-;                139 CYRILLIC CAPITAL LETTER EL
-;                171 CYRILLIC SMALL   LETTER EL
-VK_K                                   \171
-VK_K             SHIFT                 \139
-VK_K             CAPSLOCK              \139
-VK_K             CAPSLOCK+SHIFT        \171
-
-;                140 CYRILLIC CAPITAL LETTER EM
-;                172 CYRILLIC SMALL   LETTER EM
-VK_V                                   \172
-VK_V             SHIFT                 \140
-VK_V             CAPSLOCK              \140
-VK_V             CAPSLOCK+SHIFT        \172
-
-;                141 CYRILLIC CAPITAL LETTER EN
-;                173 CYRILLIC SMALL   LETTER EN
-VK_Y                                   \173
-VK_Y             SHIFT                 \141
-VK_Y             CAPSLOCK              \141
-VK_Y             CAPSLOCK+SHIFT        \173
-
-;                144 CYRILLIC CAPITAL LETTER ER
-;                224 CYRILLIC SMALL   LETTER ER
-VK_H                                   \224
-VK_H             SHIFT                 \144
-VK_H             CAPSLOCK              \144
-VK_H             CAPSLOCK+SHIFT        \224
-
-;                145 CYRILLIC CAPITAL LETTER ES
-;                225 CYRILLIC SMALL   LETTER ES
-VK_C                                   \225
-VK_C             SHIFT                 \145
-VK_C             CAPSLOCK              \145
-VK_C             CAPSLOCK+SHIFT        \225
-
-;                131 CYRILLIC CAPITAL LETTER GE
-;                163 CYRILLIC SMALL   LETTER GE
-VK_U                                   \163
-VK_U             SHIFT                 \131
-VK_U             CAPSLOCK              \131
-VK_U             CAPSLOCK+SHIFT        \163
-
-;                159 CYRILLIC CAPITAL LETTER YA
-;                239 CYRILLIC SMALL   LETTER YA
-VK_Z                                   \239
-VK_Z             SHIFT                 \159
-VK_Z             CAPSLOCK              \159
-VK_Z             CAPSLOCK+SHIFT        \239
-
-;                133 CYRILLIC CAPITAL LETTER IE
-;                165 CYRILLIC SMALL   LETTER IE
-VK_T                                   \165
-VK_T             SHIFT                 \133
-VK_T             CAPSLOCK              \133
-VK_T             CAPSLOCK+SHIFT        \165
-
-;                136 CYRILLIC CAPITAL LETTER II
-;                168 CYRILLIC SMALL   LETTER II
-VK_B                                   \168
-VK_B             SHIFT                 \136
-VK_B             CAPSLOCK              \136
-VK_B             CAPSLOCK+SHIFT        \168
-
-;                158 CYRILLIC CAPITAL LETTER YU
-;                238 CYRILLIC SMALL   LETTER YU
-VK_.                                   \238
-VK_.             SHIFT                 \158
-VK_.             CAPSLOCK              \158
-VK_.             CAPSLOCK+SHIFT        \238
-
-;                138 CYRILLIC CAPITAL LETTER KA
-;                170 CYRILLIC SMALL   LETTER KA
-VK_R                                   \170
-VK_R             SHIFT                 \138
-VK_R             CAPSLOCK              \138
-VK_R             CAPSLOCK+SHIFT        \170
-
-;                149 CYRILLIC CAPITAL LETTER KHA
-;                229 CYRILLIC SMALL   LETTER KHA
-VK_[                                   \229
-VK_[             SHIFT                 \149
-VK_[             CAPSLOCK              \149
-VK_[             CAPSLOCK+SHIFT        \229
-
-;                142 CYRILLIC CAPITAL LETTER O
-;                174 CYRILLIC SMALL   LETTER O
-VK_J                                   \174
-VK_J             SHIFT                 \142
-VK_J             CAPSLOCK              \142
-VK_J             CAPSLOCK+SHIFT        \174
-
-;                143 CYRILLIC CAPITAL LETTER PE
-;                175 CYRILLIC SMALL   LETTER PE
-VK_G                                   \175
-VK_G             SHIFT                 \143
-VK_G             CAPSLOCK              \143
-VK_G             CAPSLOCK+SHIFT        \175
-
-;                152 CYRILLIC CAPITAL LETTER SHA
-;                232 CYRILLIC SMALL   LETTER SHA
-VK_I                                   \232
-VK_I             SHIFT                 \152
-VK_I             CAPSLOCK              \152
-VK_I             CAPSLOCK+SHIFT        \232
-
-;                153 CYRILLIC CAPITAL LETTER SHCHA
-;                233 CYRILLIC SMALL   LETTER SHCHA
-VK_O                                   \233
-VK_O             SHIFT                 \153
-VK_O             CAPSLOCK              \153
-VK_O             CAPSLOCK+SHIFT        \233
-
-;                137 CYRILLIC CAPITAL LETTER SHORT II
-;                169 CYRILLIC SMALL   LETTER SHORT II
-VK_Q                                   \169
-VK_Q             SHIFT                 \137
-VK_Q             CAPSLOCK              \137
-VK_Q             CAPSLOCK+SHIFT        \169
-
-;                156 CYRILLIC CAPITAL LETTER SOFT SIGN
-;                236 CYRILLIC SMALL   LETTER SOFT SIGN
-VK_M                                   \236
-VK_M             SHIFT                 \156
-VK_M             CAPSLOCK              \156
-VK_M             CAPSLOCK+SHIFT        \236
-
-;                146 CYRILLIC CAPITAL LETTER TE
-;                226 CYRILLIC SMALL   LETTER TE
-VK_N                                   \226
-VK_N             SHIFT                 \146
-VK_N             CAPSLOCK              \146
-VK_N             CAPSLOCK+SHIFT        \226
-
-;                150 CYRILLIC CAPITAL LETTER TSE
-;                \230 CYRILLIC SMALL   LETTER TSE
-VK_W                                   \230
-VK_W             SHIFT                 \150
-VK_W             CAPSLOCK              \150
-VK_W             CAPSLOCK+SHIFT        \230
-
-;                147 CYRILLIC CAPITAL LETTER U
-;                227 CYRILLIC SMALL   LETTER U
-VK_E                                   \227
-VK_E             SHIFT                 \147
-VK_E             CAPSLOCK              \147
-VK_E             CAPSLOCK+SHIFT        \227
-
-;                130 CYRILLIC CAPITAL LETTER VE
-;                162 CYRILLIC SMALL   LETTER VE
-VK_D                                   \162
-VK_D             SHIFT                 \130
-VK_D             CAPSLOCK              \130
-VK_D             CAPSLOCK+SHIFT        \162
-
-;                154 CYRILLIC CAPITAL LETTER HARD SIGN
-;                234 CYRILLIC SMALL   LETTER HARD SIGN
-VK_]                                   \234
-VK_]             SHIFT                 \154
-VK_]             CAPSLOCK              \154
-VK_]             CAPSLOCK+SHIFT        \234
-
-;                135 CYRILLIC CAPITAL LETTER ZE
-;                167 CYRILLIC SMALL   LETTER ZE
-VK_P                                   \167
-VK_P             SHIFT                 \135
-VK_P             CAPSLOCK              \135
-VK_P             CAPSLOCK+SHIFT        \167
-
-;                134 CYRILLIC CAPITAL LETTER ZHE
-;                166 CYRILLIC SMALL   LETTER ZHE
-VK_;                                   \166
-VK_;             SHIFT                 \134
-VK_;             CAPSLOCK              \134
-VK_;             CAPSLOCK+SHIFT        \166
-
-[END keymap] // ibm866
-
-[keymap swedish]
-; ae Swedish A with dots
-VK_A                                            \228
-VK_A            SHIFT                           \196
-VK_A            CAPSLOCK                        \196
-VK_A            CAPSLOCK+SHIFT                  \228
-
-; aa Swedish A with circle
-VK_A            RIGHT_ALT                       \229
-VK_A            RIGHT_ALT+SHIFT                 \196
-VK_A            RIGHT_ALT+CAPSLOCK              \196
-VK_A            RIGHT_ALT+CAPSLOCK+SHIFT        \229
-VK_A            LEFT_ALT                        \229
-VK_A            LEFT_ALT+SHIFT                  \196
-VK_A            LEFT_ALT+CAPSLOCK               \196
-VK_A            LEFT_ALT+CAPSLOCK+SHIFT         \229
-
-; oe (Swedish O with dots)
-VK_O                                            \246
-VK_O            SHIFT                           \214
-VK_O            CAPSLOCK                        \214
-VK_O            CAPSLOCK+SHIFT                  \246
-
-[END keymap] // swedish
-
-[keymap uk]
-; The following entries are thanks to Kirschke Guido <gkirschke@sbmv.ch>
-;
-VK_`                                   " // dosen't work
-VK_`             SHIFT                 !
-VK_`             RIGHT_ALT             ]
-;
-VK_0             SHIFT                 =
-VK_0             CAPSLOCK              0
-VK_0             CAPSLOCK+SHIFT        =
-;
-VK_1             RIGHT_ALT             Ý
-VK_1             SHIFT                 +
-VK_1             CAPSLOCK              1
-VK_1             CAPSLOCK+SHIFT        +
-;
-VK_2             RIGHT_ALT             @
-VK_2             SHIFT                 "
-VK_2             CAPSLOCK              2
-VK_2             CAPSLOCK+SHIFT        "
-;
-VK_3             RIGHT_ALT             #
-VK_3             SHIFT                 *
-VK_3             CAPSLOCK              3
-VK_3             CAPSLOCK+SHIFT        *
-;
-VK_4             SHIFT                 \87
-VK_4             CAPSLOCK              4
-VK_4             CAPSLOCK+SHIFT        \87 // dosen't work
-;
-VK_5             SHIFT                 %
-VK_5             CAPSLOCK              5
-VK_5             CAPSLOCK+SHIFT        %
-;
-VK_6             RIGHT_ALT             ª
-VK_6             SHIFT                 &
-VK_6             CAPSLOCK              6
-VK_6             CAPSLOCK+SHIFT        &
-;
-VK_7             RIGHT_ALT             |
-VK_7             SHIFT                 /
-VK_7             CAPSLOCK              7
-VK_7             CAPSLOCK+SHIFT        /
-;
-VK_8             RIGHT_ALT             \9b
-VK_8             SHIFT                 (
-VK_8             CAPSLOCK              8
-VK_8             CAPSLOCK+SHIFT        (
-;
-VK_9             SHIFT                 )
-VK_9             CAPSLOCK              9
-VK_9             CAPSLOCK+SHIFT        )
-VK_;             CAPSLOCK              \9a // dosen't work
-VK_;             CAPSLOCK+SHIFT        E // dosen't work
-VK_'             CAPSLOCK+SHIFT        ?
-VK_,             CAPSLOCK+SHIFT        ;
-VK_.             CAPSLOCK+SHIFT        :
-VK_/             CAPSLOCK+SHIFT        _
-[END keymap]
-
-[keymap german]
-
-;****************************************************************************
-;****************************************************************************
-;***                           German keyboard.                           ***
-;***
-;****************************************************************************
-;****************************************************************************
-; This keymap used on top the keyb gr driver / CP 850
-
-VK_7           RIGHT_ALT               {
-VK_8           RIGHT_ALT               [
-VK_9           RIGHT_ALT               ]
-VK_0           RIGHT_ALT               }
-VK_\                                   ^
-VK_6           SHIFT                   &
-; \99 und \94
-VK_`                                   \148
-VK_`           SHIFT                   \153
-; Gravis- /Akut-Akzent
-VK_]                                   \039
-VK_]           SHIFT                   \096
-
-[END keymap] // german
-
-;===================================================================
-; Czech keyboard definition for use with CP852
-; Add to your AUTOEXEC.BAT
-;     mode con codepage prepare=((852) C:\WINDOWS\COMMAND\ega.cpi)
-;     mode con codepage select=852
-;     keyb cz,,C:\WINDOWS\COMMAND\keybrd2.sys
-;
-; This keyboard driver allows to change US/CZ keyboard by pressing
-; CTRL+ALT+F1 / CTRL+ALT+F2 and is present in W9x installation.
-;
-; Jakub Sterba <sterba@nlk.anet.cz>  Mar-2000 Prague, Czech republic
-;===================================================================
-
-[keymap czech-cz]
-VK_BACK                                 \127
-VK_=             \000
-VK_=   SHIFT     \000
-[END keymap]
-
-[keymap czech-en]
-VK_BACK                                 \127
-VK_=            =
-VK_=   SHIFT    \043
-[END keymap]
-
-;######################################################################
-; Spanish Keyborad Definition
-;
-; I started from ansi definition, and I had to comment several lines
-; and add a few more.
-;######################################################################
-
-[keymap sp]
-
-;-- These lines are from original <ansi> emulation
-
-VK_F1                                  ^[[M
-VK_F2                                  ^[[N
-VK_F3                                  ^[[O
-VK_F4                                  ^[[P
-VK_F5                                  ^[[Q
-VK_F6                                  ^[[R
-VK_F7                                  ^[[S
-VK_F8                                  ^[[T
-VK_F9                                  ^[[U
-VK_F10                                 ^[[V
-VK_F11                                 ^[[W
-VK_F12                                 ^[[X
-
-;-- These lines were added : CAPSLOCK status is not relevant
-;-- for Function Keys
-;
-;-- CAPSLOCK ON or OFF : every key must send same sequence
-VK_F1            CAPSLOCK              ^[[M
-VK_F2            CAPSLOCK              ^[[N
-VK_F3            CAPSLOCK              ^[[O
-VK_F4            CAPSLOCK              ^[[P
-VK_F5            CAPSLOCK              ^[[Q
-VK_F6            CAPSLOCK              ^[[R
-VK_F7            CAPSLOCK              ^[[S
-VK_F8            CAPSLOCK              ^[[T
-VK_F9            CAPSLOCK              ^[[U
-VK_F10           CAPSLOCK              ^[[V
-VK_F11           CAPSLOCK              ^[[W
-VK_F12           CAPSLOCK              ^[[X
-
-;-- These lines are from original <ansi> emulation
-VK_F1            SHIFT                 ^[[Y
-VK_F2            SHIFT                 ^[[Z
-VK_F3            SHIFT                 ^[[a
-VK_F4            SHIFT                 ^[[b
-VK_F5            SHIFT                 ^[[c
-VK_F6            SHIFT                 ^[[d
-VK_F7            SHIFT                 ^[[e
-VK_F8            SHIFT                 ^[[f
-VK_F9            SHIFT                 ^[[g
-VK_F10           SHIFT                 ^[[h
-VK_F11           SHIFT                 ^[[i
-VK_F12           SHIFT                 ^[[j
-VK_F1            RIGHT_CTRL            ^[[k
-VK_F2            RIGHT_CTRL            ^[[l
-VK_F3            RIGHT_CTRL            ^[[m
-VK_F4            RIGHT_CTRL            ^[[n
-VK_F5            RIGHT_CTRL            ^[[o
-VK_F6            RIGHT_CTRL            ^[[p
-VK_F7            RIGHT_CTRL            ^[[q
-VK_F8            RIGHT_CTRL            ^[[r
-VK_F9            RIGHT_CTRL            ^[[s
-VK_F10           RIGHT_CTRL            ^[[t
-VK_F11           RIGHT_CTRL            ^[[y
-VK_F12           RIGHT_CTRL            ^[[v
-VK_F1            LEFT_CTRL             ^[[k
-VK_F2            LEFT_CTRL             ^[[l
-VK_F3            LEFT_CTRL             ^[[m
-VK_F4            LEFT_CTRL             ^[[n
-VK_F5            LEFT_CTRL             ^[[o
-VK_F6            LEFT_CTRL             ^[[p
-VK_F7            LEFT_CTRL             ^[[q
-VK_F8            LEFT_CTRL             ^[[r
-VK_F9            LEFT_CTRL             ^[[s
-VK_F10           LEFT_CTRL             ^[[t
-VK_F11           LEFT_CTRL             ^[[y
-VK_F12           LEFT_CTRL             ^[[v
-;
-;  misc fuctions
-;
-; FIX ME!!!  Some people have reported that these keys don't work.
-VK_SCROLL                              \017
-VK_PAUSE                               \019
-VK_INSERT                              ^[[L
-VK_DELETE        ENHANCED              \127
-VK_HOME                                ^[[H
-VK_PGUP                                ^[[I
-VK_PGDN                                ^[[G
-VK_END                                 ^[[F
-
-VK_INSERT        CAPSLOCK              ^[[L
-VK_DELETE        ENHANCED+CAPSLOCK     \127
-VK_HOME          CAPSLOCK              ^[[H
-VK_PGUP          CAPSLOCK              ^[[I
-VK_PGDN          CAPSLOCK              ^[[G
-VK_END           CAPSLOCK              ^[[F
-
-VK_INSERT        SHIFT                 ^[[L
-VK_DELETE        SHIFT+ENHANCED        \127
-VK_HOME          SHIFT                 ^[[H
-VK_PGUP          SHIFT                 ^[[I
-VK_PGDN          SHIFT                 ^[[G
-VK_END           SHIFT                 ^[[F
-;
-; arrows
-;
-VK_LEFT                                ^[[D
-VK_UP                                  ^[[A
-VK_RIGHT                               ^[[C
-VK_DOWN                                ^[[B
-
-;-- These lines were added : CAPSLOCK status is not relevant
-;-- for Function Keys
-;
-;-- CAPSLOCK ON or OFF : every key must send same sequence
-VK_LEFT          CAPSLOCK              ^[[D
-VK_UP            CAPSLOCK              ^[[A
-VK_RIGHT         CAPSLOCK              ^[[C
-VK_DOWN          CAPSLOCK              ^[[B
-
-;-- These lines are from original <ansi> emulation
-VK_LEFT          SHIFT                 ^[[D
-VK_UP            SHIFT                 ^[[A
-VK_RIGHT         SHIFT                 ^[[C
-VK_DOWN          SHIFT                 ^[[B
-;
-; just in case !!!
-;
-VK_ESCAPE        SHIFT                 \027
-VK_TAB                                 \009
-VK_TAB           SHIFT                 ^[[Z^[[Z
-;
-;---------------------------------------
-;      Athens  30/03/97 10:55pm GMT+2
-;  Correction for Win95
-;
-VK_6             SHIFT                 \094
-
-;-- These lines were commented for <¥> support
-;VK_`                                   \164
-;VK_`             SHIFT                 \164
-
-
-VK_0             CAPSLOCK              0
-VK_1             CAPSLOCK              1
-VK_2             CAPSLOCK              2
-VK_3             CAPSLOCK              3
-VK_4             CAPSLOCK              4
-VK_5             CAPSLOCK              5
-VK_6             CAPSLOCK              6
-VK_7             CAPSLOCK              7
-VK_8             CAPSLOCK              8
-VK_9             CAPSLOCK              9
-VK_ESCAPE        CAPSLOCK              \027
-
-;-- This line was commented for <¥> support
-;VK_`             CAPSLOCK              \164
-
-VK_=             CAPSLOCK              +
-VK_-             CAPSLOCK              ­
-VK_\             CAPSLOCK              \
-VK_[             CAPSLOCK              [
-VK_]             CAPSLOCK              ]
-VK_;             CAPSLOCK              `
-VK_'             CAPSLOCK              '
-VK_,             CAPSLOCK              ,
-VK_.             CAPSLOCK              .
-VK_/             CAPSLOCK              /
-VK_0             CAPSLOCK+SHIFT        =
-VK_1             CAPSLOCK+SHIFT        !
-VK_2             CAPSLOCK+SHIFT        "
-VK_3             CAPSLOCK+SHIFT        ú
-VK_4             CAPSLOCK+SHIFT        $
-VK_5             CAPSLOCK+SHIFT        %
-VK_6             CAPSLOCK+SHIFT        &
-VK_7             CAPSLOCK+SHIFT        /
-VK_8             CAPSLOCK+SHIFT        (
-VK_9             CAPSLOCK+SHIFT        )
-VK_ESCAPE        CAPSLOCK+SHIFT        \027
-
-;-- This line was commented for <¥> support
-;VK_`             CAPSLOCK+SHIFT        \164
-
-VK_=             CAPSLOCK+SHIFT        ¨
-VK_-             CAPSLOCK+SHIFT        ¨
-VK_\             CAPSLOCK+SHIFT        |
-VK_[             CAPSLOCK+SHIFT        ?
-VK_]             CAPSLOCK+SHIFT        ¨
-VK_;             CAPSLOCK+SHIFT        ^
-VK_'             CAPSLOCK+SHIFT        "
-VK_,             CAPSLOCK+SHIFT        <
-VK_.             CAPSLOCK+SHIFT        >
-VK_/             CAPSLOCK+SHIFT        ?
-;
-;
-;---------------------------------------
-;
-; These are for use with Midnight Commander
-; they map Meta key to ALT (Like Linux console, nice isn't it ? )
-;
-
-
-;-- These lines were commented.
-;-- This way keyyboard represents <|> <@> <#> and so on ;
-;VK_0        RIGHT_ALT                  ^[0
-;VK_1             RIGHT_ALT             ^[1
-;VK_2             RIGHT_ALT             ^[2
-;VK_3             RIGHT_ALT             ^[3
-;VK_4             RIGHT_ALT             ^[4
-;VK_5             RIGHT_ALT             ^[5
-;VK_6             RIGHT_ALT             ^[6
-;VK_7             RIGHT_ALT             ^[7
-;VK_8             RIGHT_ALT             ^[8
-;VK_9             RIGHT_ALT             ^[9
-;VK_A             RIGHT_ALT             ^[A
-;VK_B             RIGHT_ALT             ^[B
-;VK_C             RIGHT_ALT             ^[C
-;VK_D             RIGHT_ALT             ^[D
-;VK_E             RIGHT_ALT             ^[E
-;VK_F             RIGHT_ALT             ^[F
-;VK_G             RIGHT_ALT             ^[G
-;VK_H             RIGHT_ALT             ^[H
-;VK_I             RIGHT_ALT             ^[I
-;VK_J             RIGHT_ALT             ^[J
-;VK_K             RIGHT_ALT             ^[K
-;VK_L             RIGHT_ALT             ^[L
-;VK_M             RIGHT_ALT             ^[M
-;VK_N             RIGHT_ALT             ^[N
-;VK_O             RIGHT_ALT             ^[O
-;VK_P             RIGHT_ALT             ^[P
-;VK_Q             RIGHT_ALT             ^[Q
-;VK_R             RIGHT_ALT             ^[R
-;VK_S             RIGHT_ALT             ^[S
-;VK_T             RIGHT_ALT             ^[T
-;VK_U             RIGHT_ALT             ^[U
-;VK_V             RIGHT_ALT             ^[V
-;VK_W             RIGHT_ALT             ^[W
-;VK_X             RIGHT_ALT             ^[X
-;VK_Y             RIGHT_ALT             ^[Y
-;VK_Z             RIGHT_ALT             ^[Z
-
-;-- These lines are from original <ansi> emulation
-VK_0             LEFT_ALT              ^[0
-VK_1             LEFT_ALT              ^[1
-VK_2             LEFT_ALT              ^[2
-VK_3             LEFT_ALT              ^[3
-VK_4             LEFT_ALT              ^[4
-VK_5             LEFT_ALT              ^[5
-VK_6             LEFT_ALT              ^[6
-VK_7             LEFT_ALT              ^[7
-VK_8             LEFT_ALT              ^[8
-VK_9             LEFT_ALT              ^[9
-VK_A             LEFT_ALT              ^[a
-VK_B             LEFT_ALT              ^[b
-VK_C             LEFT_ALT              ^[c
-VK_D             LEFT_ALT              ^[d
-VK_E             LEFT_ALT              ^[e
-VK_F             LEFT_ALT              ^[f
-VK_G             LEFT_ALT              ^[g
-VK_H             LEFT_ALT              ^[h
-VK_I             LEFT_ALT              ^[i
-VK_J             LEFT_ALT              ^[j
-VK_K             LEFT_ALT              ^[k
-VK_L             LEFT_ALT              ^[l
-VK_M             LEFT_ALT              ^[m
-VK_N             LEFT_ALT              ^[n
-VK_O             LEFT_ALT              ^[o
-VK_P             LEFT_ALT              ^[p
-VK_Q             LEFT_ALT              ^[q
-VK_R             LEFT_ALT              ^[r
-VK_S             LEFT_ALT              ^[s
-VK_T             LEFT_ALT              ^[t
-VK_U             LEFT_ALT              ^[u
-VK_V             LEFT_ALT              ^[v
-VK_W             LEFT_ALT              ^[w
-VK_X             LEFT_ALT              ^[x
-VK_Y             LEFT_ALT              ^[y
-VK_Z             LEFT_ALT              ^[z
-VK_RETURN        RIGHT_CTRL            ^[^M
-VK_RETURN        LEFT_CTRL             ^[^M
-; It is correct for telnet to send ^J rather than ^M for return.
-; This is noticeable especially when telnetting in to an smtp server.
-; It would be even more correct to send \x010\x000, since that is what
-; the RFC calls for. (Paul Brannan 5/25/98)
-VK_RETURN                              ^M^J
-; This is for application cursor keys (Paul Brannan 5/27/98)
-VK_LEFT       APP_KEY                  ^[OD
-VK_UP         APP_KEY                  ^[OA
-VK_RIGHT      APP_KEY                  ^[OC
-VK_DOWN       APP_KEY                  ^[OB
-VK_LEFT       APP_KEY+SHIFT            ^[OD
-VK_UP         APP_KEY+SHIFT            ^[OA
-VK_RIGHT      APP_KEY+SHIFT            ^[OC
-VK_DOWN       APP_KEY+SHIFT            ^[OB
-; APP2_KEY is for VT52 support (Paul Brannan 6/28/98)
-VK_LEFT       APP2_KEY                 ^[D
-VK_UP         APP2_KEY                 ^[A
-VK_RIGHT      APP2_KEY                 ^[C
-VK_DOWN       APP2_KEY                 ^[B
-VK_LEFT       APP2_KEY+SHIFT           ^[D
-VK_UP         APP2_KEY+SHIFT           ^[A
-VK_RIGHT      APP2_KEY+SHIFT           ^[C
-VK_DOWN       APP2_KEY+SHIFT           ^[B
-VK_F1         APP2_KEY                 ^[P
-VK_F2         APP2_KEY                 ^[Q
-VK_F3         APP2_KEY                 ^[R
-VK_F4         APP2_KEY                 ^[S
-VK_F5         APP2_KEY                 ^[?w
-VK_F6         APP2_KEY                 ^[?x
-VK_F7         APP2_KEY                 ^[?y
-VK_F8         APP2_KEY                 ^[?m
-VK_F9         APP2_KEY                 ^[?t
-VK_F10        APP2_KEY                 ^[?u
-VK_F1         APP2_KEY+SHIFT           ^[?v
-VK_F2         APP2_KEY+SHIFT           ^[?l
-VK_F3         APP2_KEY+SHIFT           ^[?q
-VK_F4         APP2_KEY+SHIFT           ^[?r
-VK_F5         APP2_KEY+SHIFT           ^[?s
-VK_F6         APP2_KEY+SHIFT           ^[?M
-VK_F7         APP2_KEY+SHIFT           ^[?p
-VK_F8         APP2_KEY+SHIFT           ^[?n
-
-; Fix for the numeric decimal key (Paul Brannan 9/23/98)
-VK_DELETE                              \127
-VK_DELETE     NUMLOCK                  .
-VK_DELETE     NUMLOCK+SHIFT            \127
-
-;-- From this point all definitions are new.
-;
-VK_0             RIGHT_ALT             \
-VK_0             RIGHT_ALT+CAPSLOCK    \
-VK_0                                   §
-VK_0             SHIFT                 ¦
-VK_0             CAPSLOCK              §
-VK_0             CAPSLOCK+SHIFT        ¦
-;
-VK_1             RIGHT_ALT             Ý
-VK_1             SHIFT                 !
-VK_1             CAPSLOCK              1
-VK_1             CAPSLOCK+SHIFT        !
-;
-VK_2             RIGHT_ALT             @
-VK_2             SHIFT                 "
-VK_2             CAPSLOCK              2
-VK_2             CAPSLOCK+SHIFT        "
-;
-VK_3             RIGHT_ALT             #
-VK_3             SHIFT                 ú
-VK_3             CAPSLOCK              3
-VK_3             CAPSLOCK+SHIFT        ú
-;
-VK_4             SHIFT                 $
-VK_4             CAPSLOCK              4
-VK_4             CAPSLOCK+SHIFT        $
-;
-VK_5             SHIFT                 %
-VK_5             CAPSLOCK              5
-VK_5             CAPSLOCK+SHIFT        %
-;
-VK_6             RIGHT_ALT             ª
-VK_6             SHIFT                 &
-VK_6             CAPSLOCK              6
-VK_6             CAPSLOCK+SHIFT        &
-;
-VK_7             SHIFT                 /
-VK_7             CAPSLOCK              7
-VK_7             CAPSLOCK+SHIFT        /
-;
-VK_8             SHIFT                 (
-VK_8             CAPSLOCK              8
-VK_8             CAPSLOCK+SHIFT        (
-;
-VK_9             SHIFT                 )
-VK_9             CAPSLOCK              9
-VK_9             CAPSLOCK+SHIFT        )
-;
-VK_.             CAPSLOCK+SHIFT        :
-VK_/             CAPSLOCK+SHIFT        _
-;
-VK_[                                   '
-VK_[             CAPSLOCK              '
-
-;===================================================================
-; End Spanish Keyboard Definition.
-; Cesar Otero   jcotero@las.es  March-1.999  Ferrol. Coru¤a. SPAIN
-;===================================================================
-[END keymap]
-
-[keymap no-numpad]
-VK_NUMPAD0                              \000
-VK_NUMPAD1                              \000
-VK_NUMPAD2                              \000
-VK_NUMPAD3                              \000
-VK_NUMPAD4                              \000
-VK_NUMPAD5                              \000
-VK_NUMPAD6                              \000
-VK_NUMPAD7                              \000
-VK_NUMPAD8                              \000
-VK_NUMPAD9                              \000
-[END keymap]
-
-[charmap koi8u-cp866]
-   \xE1 \x80 // CYRILLIC CAPITAL LETTER A
-   \xC1 \xA0 // cyrillic small   letter A
-   \xE2 \x81 // CYRILLIC CAPITAL LETTER BE
-   \xC2 \xA1 // cyrillic small   letter BE
-   \xB6 \x49 // CYRILLIC CAPITAL LETTER BELORUSSIAN-UKRAINIAN I
-   \xA6 \x69 // cyrillic small   letter BELORUSSIAN-UKRAINIAN I
-   \xFE \x97 // CYRILLIC CAPITAL LETTER CHE
-   \xDE \xE7 // cyrillic small   letter CHE
-   \xE4 \x84 // CYRILLIC CAPITAL LETTER DE
-   \xC4 \xA4 // cyrillic small   letter DE
-   \xE6 \x94 // CYRILLIC CAPITAL LETTER EF
-   \xC6 \xE4 // cyrillic small   letter EF
-   \xEC \x8B // CYRILLIC CAPITAL LETTER EL
-   \xCC \xAB // cyrillic small   letter EL
-   \xED \x8C // CYRILLIC CAPITAL LETTER EM
-   \xCD \xAC // cyrillic small   letter EM
-   \xEE \x8D // CYRILLIC CAPITAL LETTER EN
-   \xCE \xAD // cyrillic small   letter EN
-   \xF2 \x90 // CYRILLIC CAPITAL LETTER ER
-   \xD2 \xE0 // cyrillic small   letter ER
-   \xF3 \x91 // CYRILLIC CAPITAL LETTER ES
-   \xD3 \xE1 // cyrillic small   letter ES
-   \xE7 \x83 // CYRILLIC CAPITAL LETTER GE
-   \xC7 \xA3 // cyrillic small   letter GE
-   \xFF \x9A // CYRILLIC CAPITAL LETTER HARD SIGN
-   \xDF \xEA // cyrillic small   letter HARD SIGN
-   \xF1 \x9F // CYRILLIC CAPITAL LETTER IA
-   \xD1 \xEF // cyrillic small   letter IA
-   \xE5 \x85 // CYRILLIC CAPITAL LETTER IE
-   \xC5 \xA5 // cyrillic small   letter IE
-   \xE9 \x88 // CYRILLIC CAPITAL LETTER II
-   \xC9 \xA8 // cyrillic small   letter II
-   \xB3 \xF0 // CYRILLIC CAPITAL LETTER IO
-   \xA3 \xF1 // cyrillic small   letter IO
-   \xE0 \x9E // CYRILLIC CAPITAL LETTER IU
-   \xC0 \xEE // cyrillic small   letter IU
-   \xEB \x8A // CYRILLIC CAPITAL LETTER KA
-   \xCB \xAA // cyrillic small   letter KA
-   \xE8 \x95 // CYRILLIC CAPITAL LETTER KHA
-   \xC8 \xE5 // cyrillic small   letter KHA
-   \xEF \x8E // CYRILLIC CAPITAL LETTER O
-   \xCF \xAE // cyrillic small   letter O
-   \xF0 \x8F // CYRILLIC CAPITAL LETTER PE
-   \xD0 \xAF // cyrillic small   letter PE
-   \xFC \x9D // CYRILLIC CAPITAL LETTER REVERSED E
-   \xDC \xED // cyrillic small   letter REVERSED E
-   \xFB \x98 // CYRILLIC CAPITAL LETTER SHA
-   \xDB \xE8 // cyrillic small   letter SHA
-   \xFD \x99 // CYRILLIC CAPITAL LETTER SHCHA
-   \xDD \xE9 // cyrillic small   letter SHCHA
-   \xEA \x89 // CYRILLIC CAPITAL LETTER SHORT II
-   \xCA \xA9 // cyrillic small   letter SHORT II
-   \xF8 \x9C // CYRILLIC CAPITAL LETTER SOFT SIGN
-   \xD8 \xEC // cyrillic small   letter SOFT SIGN
-   \xF4 \x92 // CYRILLIC CAPITAL LETTER TE
-   \xD4 \xE2 // cyrillic small   letter TE
-   \xE3 \x96 // CYRILLIC CAPITAL LETTER TSE
-   \xC3 \xE6 // cyrillic small   letter TSE
-   \xF5 \x93 // CYRILLIC CAPITAL LETTER U
-   \xD5 \xE3 // cyrillic small   letter U
-   \xBD \x83 // CYRILLIC CAPITAL LETTER UKRAINIAN GHE (UPTURN)
-   \xAD \xA3 // cyrillic small   letter UKRAINIAN GHE (UPTURN)
-   \xB4 \xF2 // CYRILLIC CAPITAL LETTER UKRAINIAN IE
-   \xA4 \xF3 // cyrillic small   letter UKRAINIAN IE
-   \xF7 \x82 // CYRILLIC CAPITAL LETTER VE
-   \xD7 \xA2 // cyrillic small   letter VE
-   \xF9 \x9B // CYRILLIC CAPITAL LETTER YERI
-   \xD9 \xEB // cyrillic small   letter YERI
-   \xB7 \xF4 // CYRILLIC CAPITAL LETTER YI (UKRAINIAN)
-   \xA7 \xF5 // cyrillic small   letter YI (UKRAINIAN)
-   \xFA \x87 // CYRILLIC CAPITAL LETTER ZE
-   \xDA \xA7 // cyrillic small   letter ZE
-   \xF6 \x86 // CYRILLIC CAPITAL LETTER ZHE
-   \xD6 \xA6 // cyrillic small   letter ZHE
-[end charmap] // koi8u-cp866
-
-// czech charmap (Petr Balas <petr@petrbalas.cz)
-[charmap czech]
-   \xA0 \x20 //
-   \xA1 \xA4 //
-   \xA2 \xF4 //
-   \xA3 \x9D //
-   \xA4 \xCF //
-   \xA5 \x95 //
-   \xA6 \x97 //
-   \xA7 \xF5 //
-   \xA8 \xF9 //
-   \xA9 \xE6 //
-   \xAA \xB8 //
-   \xAB \x9B //
-   \xAC \x8D //
-   \xAD \x2D //
-   \xAE \xA6 //
-   \xAF \xBD //
-   \xB0 \x20 //
-   \xB1 \xA5 //
-   \xB2 \xF2 //
-   \xB3 \x88 //
-   \xB4 \xEF //
-   \xB5 \x96 //
-   \xB6 \x98 //
-   \xB7 \xF3 //
-   \xB8 \xF7 //
-   \xB9 \xE7 //
-   \xBA \xAD //
-   \xBB \x9C //
-   \xBC \xAB //
-   \xBD \xF1 //
-   \xBE \xA7 //
-   \xBF \xBE //
-   \xC0 \xE8 //
-   \xC1 \xB5 //
-   \xC2 \xB6 //
-   \xC3 \xC6 //
-   \xC4 \x8E //
-   \xC5 \x91 //
-   \xC6 \x8F //
-   \xC7 \x80 //
-   \xC8 \xAC //
-   \xC9 \x90 //
-   \xCA \xA8 //
-   \xCB \xD3 //
-   \xCC \xB7 //
-   \xCD \xD6 //
-   \xCE \xD7 //
-   \xCF \xD2 //
-   \xD0 \xD1 //
-   \xD1 \xE3 //
-   \xD2 \xD5 //
-   \xD3 \xE0 //
-   \xD4 \xE2 //
-   \xD5 \x8A //
-   \xD6 \x99 //
-   \xD7 \x9E //
-   \xD8 \xFC //
-   \xD9 \xDE //
-   \xDA \xE9 //
-   \xDB \xEB //
-   \xDC \x9A //
-   \xDD \xED //
-   \xDE \xDD //
-   \xDF \xE1 //
-   \xE0 \xEA //
-   \xE1 \xA0 //
-   \xE2 \x83 //
-   \xE3 \xC7 //
-   \xE4 \x84 //
-   \xE5 \x92 //
-   \xE6 \x86 //
-   \xE7 \x87 //
-   \xE8 \x9F //
-   \xE9 \x82 //
-   \xEA \xA9 //
-   \xEB \x89 //
-   \xEC \xD8 //
-   \xED \xA1 //
-   \xEE \x8C //
-   \xEF \xD4 //
-   \xF0 \xD0 //
-   \xF1 \xE4 //
-   \xF2 \xE5 //
-   \xF3 \xA2 //
-   \xF4 \x93 //
-   \xF5 \x8B //
-   \xF6 \x94 //
-   \xF7 \xF6 //
-   \xF8 \xFD //
-   \xF9 \x85 //
-   \xFA \xA3 //
-   \xFC \x81 //
-   \xFD \xEC //
-   \xFE \xEE //
-   \xFF \xFA //
-[end charmap] // czech
-
-;
-;  ISO Latin 2 (ISO-8859-2) <-> CP852
-;  Added by Jakub Sterba (sterba@nlk.anet.cz)
-; 
-[charmap iso8859-2-cp852]
-   \xA0 \xAA
-   \xA1 \xA4
-   \xA2 \xF4
-   \xA3 \x9D
-   \xA4 \xCF
-   \xA5 \x95
-   \xA6 \x97
-   \xA7 \xF5
-   \xA8 \xF9
-   \xA9 \xE6
-   \xAA \xB8
-   \xAB \x9B
-   \xAC \x8D
-   \xAD \xF0
-   \xAE \xA6
-   \xAF \xBD
-   \xB0 \xF8
-   \xB1 \xA5
-   \xB2 \xF2
-   \xB3 \x88
-   \xB4 \xEF
-   \xB5 \x96
-   \xB6 \x98
-   \xB7 \xF3
-   \xB8 \xF7
-   \xB9 \xE7
-   \xBA \xAD
-   \xBB \x9C
-   \xBC \xAB
-   \xBD \xF1
-   \xBE \xA7
-   \xBF \xBE
-   \xC0 \xE8
-   \xC1 \xB5
-   \xC2 \xB6
-   \xC3 \xC6
-   \xC4 \x8E
-   \xC5 \x91
-   \xC6 \x8F
-   \xC7 \x80
-   \xC8 \xAC
-   \xC9 \x90
-   \xCA \xA8
-   \xCB \xD3
-   \xCC \xB7
-   \xCD \xD6
-   \xCE \xD7
-   \xCF \xD2
-   \xD0 \xD1
-   \xD1 \xE3
-   \xD2 \xD5
-   \xD3 \xE0
-   \xD4 \xE2
-   \xD5 \x8A
-   \xD6 \x99
-   \xD7 \x9E
-   \xD8 \xFC
-   \xD9 \xDE
-   \xDA \xE9
-   \xDB \xEB
-   \xDC \x9A
-   \xDD \xED
-   \xDE \xDD
-   \xDF \xE1
-   \xE0 \xEA
-   \xE1 \xA0
-   \xE2 \x83
-   \xE3 \xC7
-   \xE4 \x84
-   \xE5 \x92
-   \xE6 \x86
-   \xE7 \x87
-   \xE8 \x9F
-   \xE9 \x82
-   \xEA \xA9
-   \xEB \x89
-   \xEC \xD8
-   \xED \xA1
-   \xEE \x8C
-   \xEF \xD4
-   \xF0 \xD0
-   \xF1 \xE4
-   \xF2 \xE5
-   \xF3 \xA2
-   \xF4 \x93
-   \xF5 \x8B
-   \xF6 \x94
-   \xF7 \xF6
-   \xF8 \xFD
-   \xF9 \x85
-   \xFA \xA3
-   \xFC \x81
-   \xFD \xEC
-   \xFE \xEE
-   \xFF \xFA
-[end charmap] // iso8859-2-cp852
-
-[config ansi]
-   keymap ansi
-[end config]
-
-[config linux ]
-   keymap ansi + linux
-[end config]
-
-[config default_koi8]
-   keymap ansi
-   keymap koi8u + koi8r : VK_/ RIGHT_ALT // russian keyboard
-   keymap koi8u         : VK_. RIGHT_ALT // ukranian
-
-   charmap koi8u-cp866
-[end config]
-
-[config linux_koi8]
-   keymap ansi + linux
-   keymap koi8u + koi8r : VK_/ RIGHT_ALT // russian keyboard
-   keymap koi8u         : VK_. RIGHT_ALT // ukranian
-
-   charmap koi8u-cp866
-[end config]
-
-[config vt100]
-   keymap ansi + vt100
-[end config]
-
-[config uk]
-   keymap ansi + uk
-[end config]
-
-[config uk_vt100]
-   keymap ansi + vt100 + uk
-[end config]
-
-[config at386]
-   keymap at386
-   keymap ibm866        : VK_SCROLL     // russian keyboard PC-866
-[end config]
-
-[config swedish_vt100]
-   keymap ansi + vt100
-   keymap swedish       : VK_/ RIGHT_ALT
-[end config]
-
-[config german]
-   keymap ansi + german
-[end config]
-
-[config sp]
-   keymap sp
-[end config]
-
-[config czech]
-   keymap ansi + czech-cz                             // Czech keyboard (uses DOS driver)
-   keymap ansi + czech-en : VK_F1 LEFT_CTRL+LEFT_ALT  // US keyboard (uses DOS driver)
-   keymap ansi + czech-cz : VK_F2 LEFT_CTRL+LEFT_ALT  // Czech keyboard (uses DOS driver)
-   charmap iso8859-2-cp852       // character conversion remote -> console
-   revcharmap iso8859-2-cp852    // character conversion console -> remote
-[end config]
-
-[config czech_vt100]
-   keymap ansi + vt100 + czech-cz                             // Czech keyboard (uses DOS driver)
-   keymap ansi + vt100 + czech-en : VK_F1 LEFT_CTRL+LEFT_ALT  // US keyboard (uses DOS driver)
-   keymap ansi + vt100 + czech-cz : VK_F2 LEFT_CTRL+LEFT_ALT  // Czech keyboard (uses DOS driver)
-   charmap iso8859-2-cp852       // character conversion remote -> console
-   revcharmap iso8859-2-cp852    // character conversion console -> remote
-[end config]
diff --git a/reactos/apps/utils/net/telnet/telnet.ico b/reactos/apps/utils/net/telnet/telnet.ico
deleted file mode 100644 (file)
index 02d59ac..0000000
Binary files a/reactos/apps/utils/net/telnet/telnet.ico and /dev/null differ
diff --git a/reactos/apps/utils/net/telnet/telnet.ini b/reactos/apps/utils/net/telnet/telnet.ini
deleted file mode 100644 (file)
index 76e2a56..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-[Terminal]
-;Dumpfile=
-;Term=ansi
-;Telnet_Redir=0
-;Input_Redir=0
-;Output_Redir=0
-;Strip_Redir=FALSE
-;Destructive_Backspace=FALSE
-;Speaker_Beep=TRUE
-;Beep=TRUE
-;EightBit_Ansi=True
-;VT100_Mode=True
-;Disable_Break=FALSE
-;Preserve_Colors=FALSE
-;Wrap_Line=TRUE
-;Fast_Write=TRUE
-;Term_Width=-1
-;Term_Height=-1
-;Wide_Enable=FALSE
-;Buffer_Size=2048
-
-[Colors]
-;Blink_bg=-1
-;Blink_fg=2
-;Underline_bg=-1
-;Underline_fg=3
-;UlBlink_bg=-1
-;UlBlink_fg=1
-;Normal_bg=0
-;Normal_fg=7
-;Scroll_bg=0
-;Scroll_fg=7
-;Status_bg=1
-;Status_fg=15
-
-[Mouse]
-;Enable_Mouse=1
-
-[Printer]
-;Printer_Name=LPT1
-
-[Keyboard]
-;Escape_key=]
-;Scrollback_key=[
-;Dial_key=\
-;Alt_erase=FALSE
-;Keyboard_paste=FALSE
-;Keyfile=keys.cfg
-;Default_Config=vt100
-
-[Scrollback]
-;Scroll_Mode=DUMP
-;Scroll_Enable=TRUE
diff --git a/reactos/apps/utils/net/telnet/telnet.rc b/reactos/apps/utils/net/telnet/telnet.rc
deleted file mode 100644 (file)
index a909476..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-/* $Id$ */
-
-#define REACTOS_STR_FILE_DESCRIPTION   "Console Telnet for Win32\0"
-#define REACTOS_STR_INTERNAL_NAME      "telnet\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "telnet.exe\0"
-#include <reactos/version.rc>
diff --git a/reactos/apps/utils/net/telnet/telnet.xml b/reactos/apps/utils/net/telnet/telnet.xml
deleted file mode 100644 (file)
index 9c3a2a5..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-<module name="telnet" type="win32cui" installbase="system32" installname="telnet.exe" allowwarnings ="true">
-       <include base="telnet">.</include>
-       <define name="__USE_W32API" />
-       <define name="__REACTOS__" />
-       <library>kernel32</library>
-       <library>ws2_32</library>
-       <library>user32</library>
-       <directory name="src">
-               <file>ansiprsr.cpp</file>
-               <file>keytrans.cpp</file>
-               <file>tcharmap.cpp</file>
-               <file>tconsole.cpp</file>
-               <file>tkeydef.cpp</file>
-               <file>tkeymap.cpp</file>
-               <file>tmapldr.cpp</file>
-               <file>tmouse.cpp</file>
-               <file>tnclass.cpp</file>
-               <file>tnclip.cpp</file>
-               <file>tncon.cpp</file>
-               <file>tnconfig.cpp</file>
-               <file>tnerror.cpp</file>
-               <file>tnetwork.cpp</file>
-               <file>tnmain.cpp</file>
-               <file>tnmisc.cpp</file>
-               <file>tscript.cpp</file>
-               <file>tscroll.cpp</file>
-               <file>ttelhndl.cpp</file>
-       </directory>
-       <file>telnet.rc</file>
-</module>
diff --git a/reactos/apps/utils/net/tracert/tracert.c b/reactos/apps/utils/net/tracert/tracert.c
deleted file mode 100644 (file)
index e41269e..0000000
+++ /dev/null
@@ -1,719 +0,0 @@
-/*
- *  ReactOS Win32 Applications
- *  Copyright (C) 2005 ReactOS Team
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- */
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS traceroute utility
- * FILE:        apps/utils/net/tracert/tracert.c
- * PURPOSE:     trace a packets route through a network
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *   GM 03/05/05 Created
- *
- */
-
-
-#include <winsock2.h>
-#include <tchar.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <ws2tcpip.h>
-#include <string.h>
-#include <time.h>
-#include "tracert.h"
-
-#define WIN32_LEAN_AND_MEAN
-
-#ifdef DBG
-#undef DBG
-#endif
-
-/*
- * globals
- */
-SOCKET icmpSock;                // socket descriptor
-SOCKADDR_IN source, dest;       // source and destination address info
-ECHO_REPLY_HEADER sendpacket;   // ICMP echo packet
-IPv4_HEADER recvpacket;         // return reveive packet
-
-BOOL bUsePerformanceCounter;    // whether to use the high res performance counter
-LARGE_INTEGER TicksPerMs;       // number of millisecs in relation to proc freq
-LARGE_INTEGER TicksPerUs;       // number of microsecs in relation to proc freq
-LONGLONG lTimeStart;            // send packet, timer start
-LONGLONG lTimeEnd;              // receive packet, timer end
-
-CHAR cHostname[256];            // target hostname
-CHAR cDestIP[18];               // target IP
-
-
-/*
- * command line options
- */
-BOOL bResolveAddresses = TRUE;  // -d  MS ping defaults to true.
-INT iMaxHops = 30;              // -h  Max number of hops before trace ends
-INT iHostList;                  // -j  @UNIMPLEMENTED@
-INT iTimeOut = 2000;            // -w  time before packet times out
-
-
-/*
- *
- * Parse command line parameters and set any options
- *
- */
-static BOOL ParseCmdline(int argc, char* argv[])
-{
-    int i;
-
-    if (argc < 2)
-    {
-       Usage();
-       return FALSE;
-    }
-
-    for (i = 1; i < argc; i++)
-    {
-        if (argv[i][0] == '-')
-        {
-            switch (argv[i][1])
-            {
-               case 'd': bResolveAddresses = FALSE;
-                         break;
-               case 'h': sscanf(argv[i+1], "%d", &iMaxHops);
-                         break;
-               case 'j': break; /* @unimplemented@ */
-               case 'w': sscanf(argv[i+1], "%d", &iTimeOut);
-                         break;
-               default:
-                  _tprintf(_T("%s is not a valid option.\n"), argv[i]);
-                  Usage();
-                  return FALSE;
-            }
-        }
-        else
-           /* copy target address */
-           strncpy(cHostname, argv[i], 255);
-    }
-
-    return TRUE;
-}
-
-
-
-/*
- *
- * Driver function, controls the traceroute program
- *
- */
-static INT Driver(VOID)
-{
-
-    INT iHopCount = 1;              // hop counter. default max is 30
-    USHORT iSeqNum = 0;                // initialise packet sequence number
-    INT iTTL = 1;                   // set initial packet TTL to 1
-    BOOL bFoundTarget = FALSE;      // Have we reached our destination yet
-    BOOL bAwaitPacket;              // indicates whether we have recieved a good packet
-    INT iDecRes;                    // DecodeResponse return value
-    INT iRecieveReturn;             // RecieveReturn return value
-    INT iNameInfoRet;               // getnameinfo return value
-    INT iPacketSize = PACKET_SIZE;  // packet size
-    WORD wHeaderLen;                // header length
-    PECHO_REPLY_HEADER icmphdr;
-
-
-    //temps for getting host name
-    CHAR cHost[256];
-    CHAR cServ[256];
-    CHAR *ip;
-
-    /* setup winsock */
-    WSADATA wsaData;
-
-    /* check for winsock 2 */
-    if (WSAStartup(MAKEWORD(2, 2), &wsaData) != 0)
-    {
-#ifdef DBG
-        _tprintf(_T("WSAStartup failed.\n"));
-#endif /* DBG */
-        exit(1);
-    }
-
-    /* establish what timing method we can use */
-    SetupTimingMethod();
-
-    /* setup target info */
-    ResolveHostname();
-
-    /* print standard tracing info to screen */
-    _tprintf(_T("\nTracing route to %s [%s]\n"), cHostname, cDestIP);
-    _tprintf(_T("over a maximum of %d hop"), iMaxHops);
-    iMaxHops > 1 ? _tprintf(_T("s:\n\n")) : _tprintf(_T(":\n\n"));
-
-    /* run until we hit either max hops, or we recieve 3 echo replys */
-    while ((iHopCount <= iMaxHops) && (bFoundTarget != TRUE))
-    {
-        INT i;
-
-        _tprintf(_T("%3d   "), iHopCount);
-        /* run 3 pings for each hop */
-        for (i=0; i<3; i++)
-        {
-            if (Setup(iTTL) != TRUE)
-            {
-#ifdef DBG
-                _tprintf(_T("error in Setup()\n"));
-#endif /* DBG */
-                WSACleanup();
-                exit(1);
-            }
-            PreparePacket(iPacketSize, iSeqNum);
-            if (SendPacket(iPacketSize) != SOCKET_ERROR)
-            {
-                /* loop until we get a good packet */
-                bAwaitPacket = TRUE;
-                while (bAwaitPacket)
-                {
-                    /* Receive replies until we either get a successful
-                     * read, or a fatal error occurs. */
-                    if ((iRecieveReturn = ReceivePacket(iPacketSize)) < 0)
-                    {
-                        /* check the sequence number in the packet
-                         * if it's bad, complain and wait for another packet
-                         * , otherwise break */
-                        wHeaderLen = recvpacket.h_len * 4;
-                        icmphdr = (ECHO_REPLY_HEADER *)((char*)&recvpacket + wHeaderLen);
-                        if (icmphdr->icmpheader.seq != iSeqNum)
-                        {
-                            _tprintf(_T("bad sequence number!\n"));
-                            continue;
-                        }
-                        else
-                            break;
-                    }
-
-                    /* if RecievePacket timed out we don't bother decoding */
-                    if (iRecieveReturn != 1)
-                    {
-                        iDecRes = DecodeResponse(iPacketSize, iSeqNum);
-
-                        switch (iDecRes)
-                        {
-                           case 0 : bAwaitPacket = FALSE;  /* time exceeded */
-                                    break;
-                           case 1 : bAwaitPacket = FALSE;  /* echo reply */
-                                    break;
-                           case 2 : bAwaitPacket = FALSE;  /* destination unreachable */
-                                    break;
-#ifdef DBG
-                           case -1 :
-                                     _tprintf(_T("recieved foreign packet\n"));
-                                     break;
-                           case -2 :
-                                     _tprintf(_T("error in DecodeResponse\n"));
-                                     break;
-                           case -3 :
-                                     _tprintf(_T("unknown ICMP packet\n"));
-                                     break;
-#endif /* DBG */
-                           default : break;
-                        }
-                    }
-                    else
-                        /* packet timed out. Don't wait for it again */
-                        bAwaitPacket = FALSE;
-                }
-            }
-
-            iSeqNum++;
-            _tprintf(_T("   "));
-        }
-
-        if(bResolveAddresses)
-        {
-           /* gethostbyaddr() and getnameinfo() are
-            * unimplemented in ROS at present.
-            * Alex has advised he will be implementing getnameinfo.
-            * I've used that for the time being for testing in Windows*/
-
-              //ip = inet_addr(inet_ntoa(source.sin_addr));
-              //host = gethostbyaddr((char *)&ip, 4, 0);
-
-              ip = inet_ntoa(source.sin_addr);
-
-              iNameInfoRet = getnameinfo((SOCKADDR *)&source,
-                                 sizeof(SOCKADDR),
-                                 cHost,
-                                 256,
-                                 cServ,
-                                 256,
-                                 NI_NUMERICSERV);
-              if (iNameInfoRet == 0)
-              {
-                 /* if IP address resolved to a hostname,
-                   * print the IP address after it */
-                  if (lstrcmpA(cHost, ip) != 0)
-                      _tprintf(_T("%s [%s]"), cHost, ip);
-                  else
-                      _tprintf(_T("%s"), cHost);
-              }
-              else
-              {
-                  _tprintf(_T("error: %d"), WSAGetLastError());
-#ifdef DBG
-                  _tprintf(_T(" getnameinfo failed: %d"), iNameInfoRet);
-#endif /* DBG */
-              }
-
-        }
-        else
-           _tprintf(_T("%s"), inet_ntoa(source.sin_addr));
-
-        _tprintf(_T("\n"));
-
-        /* check if we've arrived at the target */
-        if (strcmp(cDestIP, inet_ntoa(source.sin_addr)) == 0)
-            bFoundTarget = TRUE;
-        else
-        {
-            iTTL++;
-            iHopCount++;
-            Sleep(500);
-        }
-    }
-    _tprintf(_T("\nTrace complete.\n"));
-    WSACleanup();
-
-    return 0;
-}
-
-
-/*
- * Establish if performance counters are available and
- * set up timing figures in relation to processor frequency.
- * If performance counters are not available, we'll be using
- * gettickcount, so set the figures to 1
- *
- */
-static VOID SetupTimingMethod(VOID)
-{
-    LARGE_INTEGER PerformanceCounterFrequency;
-
-    /* check if performance counters are available */
-    bUsePerformanceCounter = QueryPerformanceFrequency(&PerformanceCounterFrequency);
-    if (bUsePerformanceCounter)
-    {
-        /* restrict execution to first processor on SMP systems */
-        if (SetThreadAffinityMask(GetCurrentThread(), 1) == 0)
-            bUsePerformanceCounter = FALSE;
-
-        TicksPerMs.QuadPart  = PerformanceCounterFrequency.QuadPart / 1000;
-        TicksPerUs.QuadPart  = PerformanceCounterFrequency.QuadPart / 1000000;
-    }
-
-    if (!bUsePerformanceCounter)
-    {
-        TicksPerMs.QuadPart = 1;
-        TicksPerUs.QuadPart = 1;
-    }
-}
-
-
-/*
- *
- * Check for a hostname or dotted deciamal for our target.
- * If we have a hostname, resolve to an IP and store it, else
- * just store the target IP address. Also set up other key
- * SOCKADDR_IN members needed for the connection.
- *
- */
-static VOID ResolveHostname(VOID)
-{
-    HOSTENT *hp;
-    ULONG addr;
-
-    memset(&dest, 0, sizeof(dest));
-
-    addr = inet_addr(cHostname);
-    /* if address is not a dotted decimal */
-    if (addr == INADDR_NONE)
-    {
-       hp = gethostbyname(cHostname);
-       if (hp != 0)
-       {
-          memcpy(&dest.sin_addr, hp->h_addr, hp->h_length);
-          //dest.sin_addr = *((struct in_addr *)hp->h_addr);
-          dest.sin_family = hp->h_addrtype;
-       }
-       else
-       {
-          _tprintf(_T("Unable to resolve target system name %s.\n"), cHostname);
-          WSACleanup();
-          exit(1);
-       }
-    }
-    else
-    {
-        dest.sin_addr.s_addr = addr;
-        dest.sin_family = AF_INET;
-    }
-    /* copy destination IP address into a string */
-    strcpy(cDestIP, inet_ntoa(dest.sin_addr));
-}
-
-
-
-/*
- *
- * Create our socket which will be used for sending and recieving,
- * Socket Type is raw, Protocol is ICMP. Also set the TTL value which will be
- * set in the outgoing IP packet.
- *
- */
-static INT Setup(INT iTTL)
-{
-    INT iSockRet;
-
-    /* create raw socket */
-    icmpSock = WSASocket(AF_INET, SOCK_RAW, IPPROTO_ICMP, 0, 0, 0);
-    if (icmpSock == INVALID_SOCKET)
-    {
-       _tprintf(_T("Could not create socket : %d.\n"), WSAGetLastError());
-       if (WSAGetLastError() == WSAEACCES)
-       {
-            _tprintf(_T("\n\nYou must be an administrator to run this program!\n\n"));
-            WSACleanup();
-            exit(1);
-       }
-       return FALSE;
-    }
-
-    /* setup for TTL */
-    iSockRet = setsockopt(icmpSock, IPPROTO_IP, IP_TTL, (const char *)&iTTL, sizeof(iTTL));
-    if (iSockRet == SOCKET_ERROR)
-    {
-       _tprintf(_T("TTL setsockopt failed : %d. \n"), WSAGetLastError());
-       return FALSE;
-    }
-
-    return TRUE;
-}
-
-
-
-/*
- * Prepare the ICMP echo request packet for sending.
- * Calculate the packet checksum
- *
- */
-static VOID PreparePacket(INT iPacketSize, USHORT iSeqNum)
-{
-    /* assemble ICMP echo request packet */
-    sendpacket.icmpheader.type      = ECHO_REQUEST;
-    sendpacket.icmpheader.code      = 0;
-    sendpacket.icmpheader.checksum  = 0;
-    sendpacket.icmpheader.id        = (USHORT)GetCurrentProcessId();
-    sendpacket.icmpheader.seq       = iSeqNum;
-
-    /* calculate checksum of packet */
-    sendpacket.icmpheader.checksum  = CheckSum((PUSHORT)&sendpacket, sizeof(ICMP_HEADER) + iPacketSize);
-}
-
-
-
-/*
- *
- * Get the system time and send the ICMP packet to the destination
- * address.
- *
- */
-static INT SendPacket(INT datasize)
-{
-    INT iSockRet;
-    INT iPacketSize;
-
-    iPacketSize = sizeof(ECHO_REPLY_HEADER) + datasize;
-
-#ifdef DBG
-    _tprintf(_T("\nsending packet of %d bytes\n"), iPacketSize);
-#endif /* DBG */
-
-    /* get time packet was sent */
-    lTimeStart = GetTime();
-
-    iSockRet = sendto(icmpSock,              //socket
-                      (char *)&sendpacket,   //buffer
-                      iPacketSize,           //size of buffer
-                      0,                     //flags
-                      (SOCKADDR *)&dest,     //destination
-                      sizeof(dest));         //address length
-
-    if (iSockRet == SOCKET_ERROR)
-    {
-        if (WSAGetLastError() == WSAEACCES)
-        {
-            _tprintf(_T("\n\nYou must be an administrator to run this program!\n\n"));
-            WSACleanup();
-            exit(1);
-        }
-        else
-        {
-#ifdef DBG
-            _tprintf(_T("sendto failed %d\n"), WSAGetLastError());
-#endif /* DBG */
-            return FALSE;
-        }
-    }
-#ifdef DBG
-    _tprintf(_T("sent %d bytes\n"), iSockRet);
-#endif /* DBG */
-
-    /* return number of bytes sent */
-    return iSockRet;
-}
-
-
-
-/*
- *
- * Set up a timeout value and put the socket in a select poll.
- * Wait until we recieve an IPv4 reply packet in reply to the ICMP
- * echo request packet and get the time the packet was recieved.
- * If we don't recieve a packet, do some checking to establish why.
- *
- */
-static INT ReceivePacket(INT datasize)
-{
-    TIMEVAL timeVal;
-    FD_SET readFDS;
-    int iSockRet = 0, iSelRet;
-    int iFromLen;
-    int iPacketSize;
-
-    /* allow for a larger recv buffer to store ICMP TTL
-     * exceed, IP header and orginal ICMP request */
-    iPacketSize = MAX_REC_SIZE + datasize;
-
-    iFromLen = sizeof(source);
-
-#ifdef DBG
-    _tprintf(_T("receiving packet. Available buffer, %d bytes\n"), iPacketSize);
-#endif /* DBG */
-
-    /* monitor icmpSock for incomming connections */
-    FD_ZERO(&readFDS);
-    FD_SET(icmpSock, &readFDS);
-
-    /* set timeout values */
-    timeVal.tv_sec  = iTimeOut / 1000;
-    timeVal.tv_usec = iTimeOut % 1000;
-
-    iSelRet = select(0, &readFDS, NULL, NULL, &timeVal);
-
-    if ((iSelRet != SOCKET_ERROR) && (iSelRet != 0))
-    {
-        iSockRet = recvfrom(icmpSock,              //socket
-                           (char *)&recvpacket,    //buffer
-                           iPacketSize,            //size of buffer
-                           0,                      //flags
-                           (SOCKADDR *)&source,    //source address
-                           &iFromLen);             //pointer to address length
-        /* get time packet was recieved */
-        lTimeEnd = GetTime();
-    /* if socket timed out */
-    }
-    else if (iSelRet == 0)
-    {
-        _tprintf(_T("   *  "));
-        return 1;
-    }
-    else if (iSelRet == SOCKET_ERROR)
-    {
-        _tprintf(_T("select() failed in sendPacket() %d\n"), WSAGetLastError());
-        return -1;
-    }
-
-
-    if (iSockRet == SOCKET_ERROR)
-    {
-        _tprintf(_T("recvfrom failed: %d\n"), WSAGetLastError());
-        return -2;
-    }
-#ifdef DBG
-    else
-    _tprintf(_T("reveived %d bytes\n"), iSockRet);
-#endif /* DBG */
-
-    return 0;
-}
-
-
-
-/*
- *
- * Cast the IPv4 packet to an echo reply and to a TTL exceed.
- * Check the 'type' field to establish what was recieved, and
- * ensure the packet is related to the originating process.
- * It all is well, print the time taken for the round trip.
- *
- */
-static INT DecodeResponse(INT iPacketSize, USHORT iSeqNum)
-{
-    unsigned short header_len = recvpacket.h_len * 4;
-    /* cast the recieved packet into an ECHO reply and a TTL Exceed so we can check the ID*/
-    ECHO_REPLY_HEADER *IcmpHdr = (ECHO_REPLY_HEADER *)((char*)&recvpacket + header_len);
-    TTL_EXCEED_HEADER *TTLExceedHdr = (TTL_EXCEED_HEADER *)((char *)&recvpacket + header_len);
-
-    /* Make sure the reply is ok */
-    if (iPacketSize < header_len + ICMP_MIN_SIZE)
-    {
-        _tprintf(_T("too few bytes from %s\n"), inet_ntoa(dest.sin_addr));
-        return -2;
-    }
-
-    switch (IcmpHdr->icmpheader.type)
-    {
-           case TTL_EXCEEDED :
-                if (TTLExceedHdr->OrigIcmpHeader.id != (USHORT)GetCurrentProcessId())
-                {
-                /* FIXME */
-                /* we've picked up a packet not related to this process
-                 * probably from another local program. We ignore it */
-#ifdef DGB
-                    _tprintf(_T("header id,  process id  %d"), TTLExceedHdr->OrigIcmpHeader.id, GetCurrentProcessId());
-#endif /* DBG */
-                    //_tprintf(_T("oops ");
-                    return -1;
-                }
-                _tprintf(_T("%3Ld ms"), (lTimeEnd - lTimeStart) / TicksPerMs.QuadPart);
-                return 0;
-           case ECHO_REPLY :
-                if (IcmpHdr->icmpheader.id != (USHORT)GetCurrentProcessId())
-                {
-                /* FIXME */
-                /* we've picked up a packet not related to this process
-                 * probably from another local program. We ignore it */
-#ifdef DGB
-                    _tprintf(_T("\nPicked up wrong packet. icmpheader.id = %d and process id = %d"), IcmpHdr->icmpheader.id, GetCurrentProcessId());
-#endif /* DBG */
-                    //_tprintf(_T("oops ");
-                    return -1;
-                }
-                _tprintf(_T("%3Ld ms"), (lTimeEnd - lTimeStart) / TicksPerMs.QuadPart);
-                return 1;
-           case DEST_UNREACHABLE :
-                _tprintf(_T("  *  "));
-                return 2;
-           default :
-                /* unknown ICMP packet */
-                return -3;
-    }
-}
-
-
-/*
- *
- * Get the system time using preformance counters if available,
- * otherwise fall back to GetTickCount()
- *
- */
-
-static LONGLONG GetTime(VOID)
-{
-    LARGE_INTEGER Time;
-
-    if (bUsePerformanceCounter)
-    {
-        if (QueryPerformanceCounter(&Time) == 0)
-        {
-            Time.u.LowPart = (DWORD)GetTickCount();
-            Time.u.HighPart = 0;
-            return (LONGLONG)Time.u.LowPart;
-        }
-    }
-    else
-    {
-            Time.u.LowPart = (DWORD)GetTickCount();
-            Time.u.HighPart = 0;
-            return (LONGLONG)Time.u.LowPart;
-    }
-    return Time.QuadPart;
-}
-
-
-/*
- *
- * Calculate packet checksum.
- *
- */
-static WORD CheckSum(PUSHORT data, UINT size)
-{
-    DWORD dwSum = 0;
-
-    while (size > 1)
-    {
-        dwSum += *data++;
-        size -= sizeof(USHORT);
-    }
-
-    if (size)
-        dwSum += *(UCHAR*)data;
-
-    dwSum = (dwSum >> 16) + (dwSum & 0xFFFF);
-    dwSum += (dwSum >> 16);
-
-    return (USHORT)(~dwSum);
-}
-
-
-/*
- *
- * print program usage to screen
- *
- */
-static VOID Usage(VOID)
-{
-    _tprintf(_T("\nUsage: tracert [-d] [-h maximum_hops] [-j host-list] [-w timeout] target_name\n\n"
-                "Options:\n"
-                "    -d                 Do not resolve addresses to hostnames.\n"
-                "    -h maximum_hops    Maximum number of hops to search for target.\n"
-                "    -j host-list       Loose source route along host-list.\n"
-                "    -w timeout         Wait timeout milliseconds for each reply.\n\n"));
-
-    /* temp notes to stop user questions until getnameinfo/gethostbyaddr and getsockopt are implemented */
-    _tprintf(_T("NOTES\n-----\n"
-           "- Setting TTL values is not currently supported in ReactOS, so the trace will\n"
-           "  jump straight to the destination. This feature will be implemented soon.\n"
-           "- Host info is not currently available in ReactOS and will fail with strange\n"
-           "  results. Use -d to force it not to resolve IP's.\n"
-           "- For testing purposes, all should work as normal in a Windows environment\n\n"));
-}
-
-
-
-/*
- *
- * Program entry point
- *
- */
-int main(int argc, char* argv[])
-{
-    if (!ParseCmdline(argc, argv)) return -1;
-
-    Driver();
-
-    return 0;
-}
diff --git a/reactos/apps/utils/net/tracert/tracert.h b/reactos/apps/utils/net/tracert/tracert.h
deleted file mode 100644 (file)
index 67801f0..0000000
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS traceroute utility
- * FILE:        apps/utils/net/tracert/tracert.h
- * PURPOSE:     trace a packets route through a network
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *   GM 03/05/05 Created
- */
-
-#define ECHO_REPLY 0
-#define DEST_UNREACHABLE 3
-#define ECHO_REQUEST 8
-#define TTL_EXCEEDED 11
-
-#define ICMP_MIN_SIZE 8
-#define ICMP_MAX_SIZE 65535
-#define PACKET_SIZE 32
-/* we need this for packets which have the 'dont fragment'
- * bit set, as they can get quite large otherwise
- * (I've seen some reach 182 bytes */
-#define MAX_REC_SIZE 200
-
-/* pack the structures */
-#include <pshpack1.h>
-
-/* IPv4 Header, 20 bytes */
-typedef struct IPv4Header
-{
-    BYTE h_len:4;
-    BYTE version:4;
-    BYTE tos;
-    USHORT length;
-    USHORT id;
-    USHORT flag_frag;
-    BYTE ttl;
-    BYTE proto;
-    USHORT checksum;
-    ULONG source;
-    ULONG dest;
-} IPv4_HEADER, *PIPv4_HEADER;
-
-/* ICMP Header, 8 bytes */
-typedef struct ICMPHeader
-{
-    BYTE type;
-    BYTE code;
-    USHORT checksum;
-    USHORT id; // not used in time exceeded
-    USHORT seq; // not used in time exceeded
-} ICMP_HEADER, *PICMP_HEADER;
-
-/* ICMP Echo Reply Header, 12 bytes */
-typedef struct EchoReplyHeader
-{
-    struct ICMPHeader icmpheader;
-    struct timeval timestamp;
-} ECHO_REPLY_HEADER, *PECHO_REPLY_HEADER;
-
-/* ICMP Echo Reply Header, 12 bytes */
-typedef struct TTLExceedHeader
-{
-    struct ICMPHeader icmpheader;
-    struct IPv4Header ipheader;
-    struct ICMPHeader OrigIcmpHeader;
-} TTL_EXCEED_HEADER, *PTTL_EXCEED_HEADER;
-
-/* return to normal */
-#include <poppack.h>
-
-/* function definitions */
-static BOOL ParseCmdline(int argc, char* argv[]);
-static INT Driver(void);
-static INT Setup(INT ttl);
-static VOID SetupTimingMethod(void);
-static VOID ResolveHostname(void);
-static VOID PreparePacket(INT packetSize, USHORT seqNum);
-static INT SendPacket(INT datasize);
-static INT ReceivePacket(INT datasize);
-static INT DecodeResponse(INT packetSize, USHORT seqNum);
-static LONGLONG GetTime(void);
-static WORD CheckSum(PUSHORT data, UINT size);
-static VOID Usage(void);
diff --git a/reactos/apps/utils/net/tracert/tracert.rc b/reactos/apps/utils/net/tracert/tracert.rc
deleted file mode 100644 (file)
index f290fd7..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS TCP/IPv4 Win32 Traceroute\0"
-#define REACTOS_STR_INTERNAL_NAME      "tracert\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "tracert.exe\0"
-#define REACTOS_STR_ORIGINAL_COPYRIGHT "Ged Murphy (gedmurphy@gmail.com)\0"
-#include <reactos/version.rc>
diff --git a/reactos/apps/utils/net/tracert/tracert.xml b/reactos/apps/utils/net/tracert/tracert.xml
deleted file mode 100644 (file)
index 5e408b9..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-<module name="tracert" type="win32cui" installbase="system32" installname="tracert.exe">
-       <include base="tracert">.</include>
-       <define name="__USE_W32API" />
-       <define name="__USE_W32_SOCKETS" />
-       <define name="_WIN32_IE">0x600</define>
-       <define name="_WIN32_WINNT">0x501</define>
-       <library>kernel32</library>
-       <library>ws2_32</library>
-       <file>tracert.c</file>
-       <file>tracert.rc</file>
-</module>
diff --git a/reactos/apps/utils/net/whois/LICENSE.txt b/reactos/apps/utils/net/whois/LICENSE.txt
deleted file mode 100644 (file)
index 3f506f7..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-July 22, 1999 
-
-To All Licensees, Distributors of Any Version of BSD: 
-
-As you know, certain of the Berkeley Software Distribution ("BSD") source code files 
-require that further distributions of products containing all or portions of the 
-software, acknowledge within their advertising materials that such products contain 
-software developed by UC Berkeley and its contributors. 
-
-Specifically, the provision reads: 
-
-      * 3. All advertising materials mentioning features or use of this software
-      *    must display the following acknowledgement:
-      *    This product includes software developed by the University of
-      *    California, Berkeley and its contributors.
-
-Effective immediately, licensees and distributors are no longer required to include 
-the acknowledgement within advertising materials. Accordingly, the foregoing paragraph 
-of those BSD Unix files containing it is hereby deleted in its entirety. 
-
-William Hoskins
-Director, Office of Technology Licensing
-University of California, Berkeley " 
diff --git a/reactos/apps/utils/net/whois/whois.c b/reactos/apps/utils/net/whois/whois.c
deleted file mode 100644 (file)
index fd81fb3..0000000
+++ /dev/null
@@ -1,167 +0,0 @@
-/*
- * Copyright (c) 1980, 1993
- *     The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *    must display the following acknowledgement:
- *     This product includes software developed by the University of
- *     California, Berkeley and its contributors.
- * 4. Neither the name of the University nor the names of its contributors
- *    may be used to endorse or promote products derived from this software
- *    without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- * 8/1/97 - Ted Felix <tfelix@fred.net>
- *          Ported to Win32 from 4.4-BSDLITE2 from wcarchive.
- *          Added WSAStartup()/WSACleanup() and switched from the
- *          more convenient fdopen()/fprintf() to send()/recv().
- */
-
-#include <sys/types.h>
-#include <winsock2.h>
-/* #include <sys/socket.h> */
-/* #include <netinet/in.h> */
-/* #include <netdb.h> */
-#include <stdio.h>
-#include <stdlib.h>
-
-/* #include <various.h> */
-#include <getopt.h>
-#include <io.h>
-
-#define        NICHOST "whois.internic.net"
-
-static void usage();
-static void leave(int iExitCode);
-
-int main(int argc, char **argv)
-{
-       extern char *optarg;
-       extern int optind;
-       char ch;
-       struct sockaddr_in sin;
-       struct hostent *hp;
-       struct servent *sp;
-       int s;
-       const char *host;
-       WORD wVersionRequested;
-       WSADATA wsaData;
-       int err;
-
-       host = NICHOST;
-       while ((ch = (char)getopt(argc, argv, "h:")) != EOF)
-               switch((char)ch) {
-               case 'h':
-                       host = optarg;
-                       break;
-               case '?':
-               default:
-                       usage();
-               }
-       argc -= optind;
-       argv += optind;
-
-       if (!argc)
-               usage();
-
-       /* Start winsock */
-       wVersionRequested = MAKEWORD( 1, 1 );
-       err = WSAStartup( wVersionRequested, &wsaData );
-       if ( err != 0 )
-       {
-               /* Tell the user that we couldn't find a usable */
-               /* WinSock DLL.                                 */
-               perror("whois: WSAStartup failed");
-               leave(1);
-       }
-
-       hp = gethostbyname(host);
-       if (hp == NULL) {
-               (void)fprintf(stderr, "whois: %s: ", host);
-               leave(1);
-       }
-       host = hp->h_name;
-
-       s = socket(hp->h_addrtype, SOCK_STREAM, 0);
-       if (s < 0) {
-               perror("whois: socket");
-               leave(1);
-       }
-
-       memset(/*(caddr_t)*/&sin, 0, sizeof(sin));
-       sin.sin_family = hp->h_addrtype;
-       if (bind(s, (struct sockaddr *)&sin, sizeof(sin)) < 0) {
-               perror("whois: bind");
-               leave(1);
-       }
-
-       memcpy((char *)&sin.sin_addr, hp->h_addr, hp->h_length);
-       sp = getservbyname("whois", "tcp");
-       if (sp == NULL) {
-               (void)fprintf(stderr, "whois: whois/tcp: unknown service\n");
-               leave(1);
-       }
-
-       sin.sin_port = sp->s_port;
-
-       /* have network connection; identify the host connected with */
-       (void)printf("[%s]\n", hp->h_name);
-
-       if (connect(s, (struct sockaddr *)&sin, sizeof(sin)) < 0) {
-               fprintf(stderr, "whois: connect error = %d\n", WSAGetLastError());
-               leave(1);
-       }
-
-       /* WinSock doesn't allow using a socket as a file descriptor. */
-       /* Have to use send() and recv().  whois will drop connection. */
-
-       /* For each request */
-       while (argc-- > 1)
-       {
-               /* Send the request */
-               send(s, *argv, strlen(*argv), 0);
-               send(s, " ", 1, 0);
-               argv++;
-       }
-       /* Send the last request */
-       send(s, *argv, strlen(*argv), 0);
-       send(s, "\r\n", 2, 0);
-
-       /* Receive anything and print it */
-       while (recv(s, &ch, 1, 0) == 1)
-               putchar(ch);
-
-       leave(0);
-       return 0;
-}
-
-static void usage()
-{
-       (void)fprintf(stderr, "usage: whois [-h hostname] name ...\n");
-       leave(1);
-}
-
-static void leave(int iExitCode)
-{
-       WSACleanup();
-       exit(iExitCode);
-}
diff --git a/reactos/apps/utils/net/whois/whois.rc b/reactos/apps/utils/net/whois/whois.rc
deleted file mode 100644 (file)
index e706ac8..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-/* $Id$ */
-
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS TCP/IPv4 Win32 Whois\0"
-#define REACTOS_STR_INTERNAL_NAME      "whois\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "whois.exe\0"
-#include <reactos/version.rc>
diff --git a/reactos/apps/utils/net/whois/whois.xml b/reactos/apps/utils/net/whois/whois.xml
deleted file mode 100644 (file)
index 2ef114b..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-<module name="whois" type="win32cui" installbase="system32" installname="whois.exe">
-        <define name="__USE_W32API" />
-       <include base="whois">.</include>
-       <library>kernel32</library>
-       <library>ws2_32</library>
-       <file>whois.c</file>
-       <file>whois.rc</file>
-</module>
diff --git a/reactos/baseaddress.rbuild b/reactos/baseaddress.rbuild
new file mode 100644 (file)
index 0000000..746e10d
--- /dev/null
@@ -0,0 +1,126 @@
+<?xml version="1.0"?>\r
+<rbuild xmlns:xi="http://www.w3.org/2001/XInclude">\r
+<group>\r
+  <property name="BASEADDRESS_DPLAYX" value="0x5E080000" />\r
+  <property name="BASEADDRESS_DPLAY" value="0x71E80000" />\r
+  <property name="BASEADDRESS_REGTESTS" value="0x07000000" />\r
+  <property name="BASEADDRESS_NOTIFYHOOK" value="0x08000000" />\r
+  <property name="BASEADDRESS_DEVENUM" value="0x35680000" />\r
+  <property name="BASEADDRESS_MMSYS" value="0x588A0000" />\r
+  <property name="BASEADDRESS_UXTHEME" value="0x5AD70000" />\r
+  <property name="BASEADDRESS_VDMDBG" value="0x5B0D0000" />\r
+  <property name="BASEADDRESS_OBJSEL" value="0x5B400000" />\r
+  <property name="BASEADDRESS_SLAYER" value="0x5C7E0000" />\r
+  <property name="BASEADDRESS_DINPUT" value="0x5F580000" />\r
+  <property name="BASEADDRESS_MAPI32" value="0x62250000" />\r
+  <property name="BASEADDRESS_HDWWIZ" value="0x64D40000" />\r
+  <property name="BASEADDRESS_TIMEDATE" value="0x64DA0000" />\r
+  <property name="BASEADDRESS_SYSDM" value="0x64DD0000" />\r
+  <property name="BASEADDRESS_NCPL" value="0x64EA0000" />\r
+  <property name="BASEADDRESS_MAIN" value="0x64F40000" />\r
+  <property name="BASEADDRESS_INTL" value="0x64FB0000" />\r
+  <property name="BASEADDRESS_DESK" value="0x65080000" />\r
+  <property name="BASEADDRESS_APPWIZ" value="0x65100000" />\r
+  <property name="BASEADDRESS_ACCESS" value="0x65180000" />\r
+  <property name="BASEADDRESS_HID" value="0x688F0000" />\r
+  <property name="BASEADDRESS_PSXDLL" value="0x68eb0000" />\r
+  <property name="BASEADDRESS_PSAPI" value="0x68f70000" />\r
+  <property name="BASEADDRESS_OLEACC" value="0x69640000" />\r
+  <property name="BASEADDRESS_MSIMG32" value="0x69cc0000" />\r
+  <property name="BASEADDRESS_NETPLWIZ" value="0x6a240000" />\r
+  <property name="BASEADDRESS_UNICODE" value="0x6b200000" />\r
+  <property name="BASEADDRESS_ADVPACK" value="0x6b300000" />\r
+  <property name="BASEADDRESS_CONTROL" value="0x6b310000" />\r
+  <property name="BASEADDRESS_NCPA" value="0x6b320000" />\r
+  <property name="BASEADDRESS_DBGHELP" value="0x6b330000" />\r
+  <property name="BASEADDRESS_DINPUT8" value="0x6b340000" />\r
+  <property name="BASEADDRESS_DXDIAGN" value="0x6b350000" />\r
+  <property name="BASEADDRESS_DSOUND" value="0x6b360000" />\r
+  <property name="BASEADDRESS_GLU32" value="0x6b370000" />\r
+  <property name="BASEADDRESS_MESA32" value="0x6b380000" />\r
+  <property name="BASEADDRESS_OPENGL32" value="0x6b390000" />\r
+  <property name="BASEADDRESS_SECUR32" value="0x6b3A0000" />\r
+  <property name="BASEADDRESS_SMDLL" value="0x6b3B0000" />\r
+  <property name="BASEADDRESS_URLMON" value="0x6b3C0000" />\r
+  <property name="BASEADDRESS_SERIALUI" value="0x6b3D0000" />\r
+  <property name="BASEADDRESS_CLB" value="0x6f2b0000" />\r
+  <property name="BASEADDRESS_CARDS" value="0x701a0000" />\r
+  <property name="BASEADDRESS_WININET" value="0x70200000" />\r
+  <property name="BASEADDRESS_ACLUI" value="0x71550000" />\r
+  <property name="BASEADDRESS_SHDOCVW" value="0x71700000" />\r
+  <property name="BASEADDRESS_MSWSOCK" value="0x71a30000" />\r
+  <property name="BASEADDRESS_WSOCK32" value="0x71ab0000" />\r
+  <property name="BASEADDRESS_ACLEDIT" value="0x71b70000" />\r
+  <property name="BASEADDRESS_NETAPI32" value="0x71c00000" />\r
+  <property name="BASEADDRESS_SECURITY" value="0x71F10000" />\r
+  <property name="BASEADDRESS_WINFAX" value="0x722C0000" />\r
+  <property name="BASEADDRESS_WINSCARD" value="0x723D0000" />\r
+  <property name="BASEADDRESS_DEVMGR" value="0x72a90000" />\r
+  <property name="BASEADDRESS_AVIFIL32" value="0x73ac0000" />\r
+  <property name="BASEADDRESS_LZ32" value="0x73d80000" />\r
+  <property name="BASEADDRESS_COREDLL" value="0x73d80000" />\r
+  <property name="BASEADDRESS_ICMP" value="0x741F0000" />\r
+  <property name="BASEADDRESS_USERENV" value="0x74850000" />\r
+  <property name="BASEADDRESS_SYSSETUP" value="0x74a30000" />\r
+  <property name="BASEADDRESS_OLEDLG" value="0x74d00000" />\r
+  <property name="BASEADDRESS_SAMSRV" value="0x74f30000" />\r
+  <property name="BASEADDRESS_SAMLIB" value="0x750C0000" />\r
+  <property name="BASEADDRESS_CABINET" value="0x75120000" />\r
+  <property name="BASEADDRESS_MSGINA" value="0x75970000" />\r
+  <property name="BASEADDRESS_IMM32" value="0x75e60000" />\r
+  <property name="BASEADDRESS_COMMCTRL" value="0x75e60000" />\r
+  <property name="BASEADDRESS_RPCRT4" value="0x76000000" />\r
+  <property name="BASEADDRESS_SHLWAPI" value="0x76120000" />\r
+  <property name="BASEADDRESS_COMCTL32" value="0x76160000" />\r
+  <property name="BASEADDRESS_COMDLG32" value="0x76210000" />\r
+  <property name="BASEADDRESS_OLEAUT32" value="0x76290000" />\r
+  <property name="BASEADDRESS_RICHED32" value="0x76340000" />\r
+  <property name="BASEADDRESS_D3D8THK" value="0x76340000" />\r
+  <property name="BASEADDRESS_RICHED20" value="0x76360000" />\r
+  <property name="BASEADDRESS_TWAIN_32" value="0x76380000" />\r
+  <property name="BASEADDRESS_LSASRV" value="0x76540000" />\r
+  <property name="BASEADDRESS_MIDIMAP" value="0x76600000" />\r
+  <property name="BASEADDRESS_ODBC32" value="0x76660000" />\r
+  <property name="BASEADDRESS_WAVEMAP" value="0x76610000" />\r
+  <property name="BASEADDRESS_MPR" value="0x76620000" />\r
+  <property name="BASEADDRESS_SETUPAPI" value="0x76660000" />\r
+  <property name="BASEADDRESS_SHFOLDER" value="0x76780000" />\r
+  <property name="BASEADDRESS_NTMARTA" value="0x768A0000" />\r
+  <property name="BASEADDRESS_GDIPLUS" value="0x76a00000" />\r
+  <property name="BASEADDRESS_WINTRUST" value="0x76c30000" />\r
+  <property name="BASEADDRESS_IMAGEHLP" value="0x76c90000" />\r
+  <property name="BASEADDRESS_FMIFS" value="0x76df0000" />\r
+  <property name="BASEADDRESS_SHELL32" value="0x77260000" />\r
+  <property name="BASEADDRESS_IPHLPAPI" value="0x77400000" />\r
+  <property name="BASEADDRESS_MSVFW32" value="0x77400000" />\r
+  <property name="BASEADDRESS_MSACM32" value="0x77400000" />\r
+  <property name="BASEADDRESS_MMDRV" value="0x77530000" />\r
+  <property name="BASEADDRESS_CRTDLL" value="0x77630000" />\r
+  <property name="BASEADDRESS_AUTHZ" value="0x77690000" />\r
+  <property name="BASEADDRESS_CFGMGR32" value="0x77700000" />\r
+  <property name="BASEADDRESS_PACKET" value="0x77780000" />\r
+  <property name="BASEADDRESS_MSAFD" value="0x777a0000" />\r
+  <property name="BASEADDRESS_MSI" value="0x777b0000" />\r
+  <property name="BASEADDRESS_SNMPAPI" value="0x777c0000" />\r
+  <property name="BASEADDRESS_IPRTPRIO" value="0x777c0000" />\r
+  <property name="BASEADDRESS_WSHTCPIP" value="0x777c0000" />\r
+  <property name="BASEADDRESS_WINMM" value="0x777d0000" />\r
+  <property name="BASEADDRESS_WS2HELP" value="0x777e0000" />\r
+  <property name="BASEADDRESS_WSHIRDA" value="0x777f0000" />\r
+  <property name="BASEADDRESS_WINSPOOL" value="0x77800000" />\r
+  <property name="BASEADDRESS_VERSION" value="0x77a40000" />\r
+  <property name="BASEADDRESS_OLE32" value="0x77a50000" />\r
+  <property name="BASEADDRESS_WS2_32" value="0x77aa0000" />\r
+  <property name="BASEADDRESS_OLEPRO32" value="0x77aa0000" />\r
+  <property name="BASEADDRESS_CRYPT32" value="0x77ab0000" />\r
+  <property name="BASEADDRESS_ADVAPI32" value="0x77dc0000" />\r
+  <property name="BASEADDRESS_USER32" value="0x77e50000" />\r
+  <property name="BASEADDRESS_GDI32" value="0x77f10000" />\r
+  <property name="BASEADDRESS_DNSAPI" value="0x77f30000" />\r
+  <property name="BASEADDRESS_MSVCRT" value="0x78000000" />\r
+  <property name="BASEADDRESS_MSVCRT20" value="0x78500000" />\r
+  <property name="BASEADDRESS_KERNEL32" value="0x7c800000" />\r
+  <property name="BASEADDRESS_NTDLL" value="0x7C900000" />\r
+  <property name="BASEADDRESS_FREETYPE" value="0x7F000000" />\r
+</group>\r
+</rbuild>\r
diff --git a/reactos/baseaddress.xml b/reactos/baseaddress.xml
deleted file mode 100644 (file)
index b1fa7d8..0000000
+++ /dev/null
@@ -1,123 +0,0 @@
-<group>
-<property name="BASEADDRESS_DPLAYX" value="0x5E080000" />
-<property name="BASEADDRESS_DPLAY" value="0x71E80000" />
-<property name="BASEADDRESS_REGTESTS" value="0x07000000" />
-<property name="BASEADDRESS_NOTIFYHOOK" value="0x08000000" />
-<property name="BASEADDRESS_DEVENUM" value="0x35680000" />
-<property name="BASEADDRESS_MMSYS" value="0x588A0000" />
-<property name="BASEADDRESS_UXTHEME" value="0x5AD70000" />
-<property name="BASEADDRESS_VDMDBG" value="0x5B0D0000" />
-<property name="BASEADDRESS_OBJSEL" value="0x5B400000" />
-<property name="BASEADDRESS_SLAYER" value="0x5C7E0000" />
-<property name="BASEADDRESS_DINPUT" value="0x5F580000" />
-<property name="BASEADDRESS_MAPI32" value="0x62250000" />
-<property name="BASEADDRESS_HDWWIZ" value="0x64D40000" />
-<property name="BASEADDRESS_TIMEDATE" value="0x64DA0000" />
-<property name="BASEADDRESS_SYSDM" value="0x64DD0000" />
-<property name="BASEADDRESS_NCPL" value="0x64EA0000" />
-<property name="BASEADDRESS_MAIN" value="0x64F40000" />
-<property name="BASEADDRESS_INTL" value="0x64FB0000" />
-<property name="BASEADDRESS_DESK" value="0x65080000" />
-<property name="BASEADDRESS_APPWIZ" value="0x65100000" />
-<property name="BASEADDRESS_ACCESS" value="0x65180000" />
-<property name="BASEADDRESS_HID" value="0x688F0000" />
-<property name="BASEADDRESS_PSXDLL" value="0x68eb0000" />
-<property name="BASEADDRESS_PSAPI" value="0x68f70000" />
-<property name="BASEADDRESS_OLEACC" value="0x69640000" />
-<property name="BASEADDRESS_MSIMG32" value="0x69cc0000" />
-<property name="BASEADDRESS_NETPLWIZ" value="0x6a240000" />
-<property name="BASEADDRESS_UNICODE" value="0x6b200000" />
-<property name="BASEADDRESS_ADVPACK" value="0x6b300000" />
-<property name="BASEADDRESS_CONTROL" value="0x6b310000" />
-<property name="BASEADDRESS_NCPA" value="0x6b320000" />
-<property name="BASEADDRESS_DBGHELP" value="0x6b330000" />
-<property name="BASEADDRESS_DINPUT8" value="0x6b340000" />
-<property name="BASEADDRESS_DXDIAGN" value="0x6b350000" />
-<property name="BASEADDRESS_DSOUND" value="0x6b360000" />
-<property name="BASEADDRESS_GLU32" value="0x6b370000" />
-<property name="BASEADDRESS_MESA32" value="0x6b380000" />
-<property name="BASEADDRESS_OPENGL32" value="0x6b390000" />
-<property name="BASEADDRESS_SECUR32" value="0x6b3A0000" />
-<property name="BASEADDRESS_SMDLL" value="0x6b3B0000" />
-<property name="BASEADDRESS_URLMON" value="0x6b3C0000" />
-<property name="BASEADDRESS_SERIALUI" value="0x6b3D0000" />
-<property name="BASEADDRESS_CLB" value="0x6f2b0000" />
-<property name="BASEADDRESS_CARDS" value="0x701a0000" />
-<property name="BASEADDRESS_WININET" value="0x70200000" />
-<property name="BASEADDRESS_ACLUI" value="0x71550000" />
-<property name="BASEADDRESS_SHDOCVW" value="0x71700000" />
-<property name="BASEADDRESS_MSWSOCK" value="0x71a30000" />
-<property name="BASEADDRESS_WSOCK32" value="0x71ab0000" />
-<property name="BASEADDRESS_ACLEDIT" value="0x71b70000" />
-<property name="BASEADDRESS_NETAPI32" value="0x71c00000" />
-<property name="BASEADDRESS_SECURITY" value="0x71F10000" />
-<property name="BASEADDRESS_WINFAX" value="0x722C0000" />
-<property name="BASEADDRESS_WINSCARD" value="0x723D0000" />
-<property name="BASEADDRESS_DEVMGR" value="0x72a90000" />
-<property name="BASEADDRESS_AVIFIL32" value="0x73ac0000" />
-<property name="BASEADDRESS_LZ32" value="0x73d80000" />
-<property name="BASEADDRESS_COREDLL" value="0x73d80000" />
-<property name="BASEADDRESS_ICMP" value="0x741F0000" />
-<property name="BASEADDRESS_USERENV" value="0x74850000" />
-<property name="BASEADDRESS_SYSSETUP" value="0x74a30000" />
-<property name="BASEADDRESS_OLEDLG" value="0x74d00000" />
-<property name="BASEADDRESS_SAMSRV" value="0x74f30000" />
-<property name="BASEADDRESS_SAMLIB" value="0x750C0000" />
-<property name="BASEADDRESS_CABINET" value="0x75120000" />
-<property name="BASEADDRESS_MSGINA" value="0x75970000" />
-<property name="BASEADDRESS_IMM32" value="0x75e60000" />
-<property name="BASEADDRESS_COMMCTRL" value="0x75e60000" />
-<property name="BASEADDRESS_RPCRT4" value="0x76000000" />
-<property name="BASEADDRESS_SHLWAPI" value="0x76120000" />
-<property name="BASEADDRESS_COMCTL32" value="0x76160000" />
-<property name="BASEADDRESS_COMDLG32" value="0x76210000" />
-<property name="BASEADDRESS_OLEAUT32" value="0x76290000" />
-<property name="BASEADDRESS_RICHED32" value="0x76340000" />
-<property name="BASEADDRESS_D3D8THK" value="0x76340000" />
-<property name="BASEADDRESS_RICHED20" value="0x76360000" />
-<property name="BASEADDRESS_TWAIN_32" value="0x76380000" />
-<property name="BASEADDRESS_LSASRV" value="0x76540000" />
-<property name="BASEADDRESS_MIDIMAP" value="0x76600000" />
-<property name="BASEADDRESS_ODBC32" value="0x76660000" />
-<property name="BASEADDRESS_WAVEMAP" value="0x76610000" />
-<property name="BASEADDRESS_MPR" value="0x76620000" />
-<property name="BASEADDRESS_SETUPAPI" value="0x76660000" />
-<property name="BASEADDRESS_SHFOLDER" value="0x76780000" />
-<property name="BASEADDRESS_NTMARTA" value="0x768A0000" />
-<property name="BASEADDRESS_GDIPLUS" value="0x76a00000" />
-<property name="BASEADDRESS_WINTRUST" value="0x76c30000" />
-<property name="BASEADDRESS_IMAGEHLP" value="0x76c90000" />
-<property name="BASEADDRESS_FMIFS" value="0x76df0000" />
-<property name="BASEADDRESS_SHELL32" value="0x77260000" />
-<property name="BASEADDRESS_IPHLPAPI" value="0x77400000" />
-<property name="BASEADDRESS_MSVFW32" value="0x77400000" />
-<property name="BASEADDRESS_MSACM32" value="0x77400000" />
-<property name="BASEADDRESS_MMDRV" value="0x77530000" />
-<property name="BASEADDRESS_CRTDLL" value="0x77630000" />
-<property name="BASEADDRESS_AUTHZ" value="0x77690000" />
-<property name="BASEADDRESS_CFGMGR32" value="0x77700000" />
-<property name="BASEADDRESS_PACKET" value="0x77780000" />
-<property name="BASEADDRESS_MSAFD" value="0x777a0000" />
-<property name="BASEADDRESS_MSI" value="0x777b0000" />
-<property name="BASEADDRESS_SNMPAPI" value="0x777c0000" />
-<property name="BASEADDRESS_IPRTPRIO" value="0x777c0000" />
-<property name="BASEADDRESS_WSHTCPIP" value="0x777c0000" />
-<property name="BASEADDRESS_WINMM" value="0x777d0000" />
-<property name="BASEADDRESS_WS2HELP" value="0x777e0000" />
-<property name="BASEADDRESS_WSHIRDA" value="0x777f0000" />
-<property name="BASEADDRESS_WINSPOOL" value="0x77800000" />
-<property name="BASEADDRESS_VERSION" value="0x77a40000" />
-<property name="BASEADDRESS_OLE32" value="0x77a50000" />
-<property name="BASEADDRESS_WS2_32" value="0x77aa0000" />
-<property name="BASEADDRESS_OLEPRO32" value="0x77aa0000" />
-<property name="BASEADDRESS_CRYPT32" value="0x77ab0000" />
-<property name="BASEADDRESS_ADVAPI32" value="0x77dc0000" />
-<property name="BASEADDRESS_USER32" value="0x77e50000" />
-<property name="BASEADDRESS_GDI32" value="0x77f10000" />
-<property name="BASEADDRESS_DNSAPI" value="0x77f30000" />
-<property name="BASEADDRESS_MSVCRT" value="0x78000000" />
-<property name="BASEADDRESS_MSVCRT20" value="0x78500000" />
-<property name="BASEADDRESS_KERNEL32" value="0x7c800000" />
-<property name="BASEADDRESS_NTDLL" value="0x7C900000" />
-<property name="BASEADDRESS_FREETYPE" value="0x7F000000" />
-</group>
similarity index 89%
rename from reactos/config.template.xml
rename to reactos/config.template.rbuild
index 340f3e9..82dfe14 100644 (file)
@@ -1,51 +1,56 @@
-<!--
-  This file is a template used as a starting point for compile-time
-  configuration of ReactOS. Make a copy of this file and name it config.xml.
-  Then change the options in config.xml. If you don't have a config.xml file,
-  then the defaults in this file, config.template.xml, will be used instead.
-
-  Boolean options can obtain the values 0 (disabled) or 1 (enabled). String
-  options can obtain any value specified in the comment before it.
--->
-
-
-<!--
-  Architecture to build for. Specify one of:
-    i386
--->
-<property name="ARCH" value="i386" />
-
-<!--
-  Sub-architecture to build for. Specify one of:
-    xbox
--->
-<property name="SARCH" value="" />
-
-
-<!--
-  Which CPU ReactOS should be optimized for. Specify one of:
-    i486, i586, pentium, pentium2, pentium3, pentium4, athlon-xp, athlon-mp,
-    k6-2
-
-  See GCC manual for more CPU names and which CPUs GCC can optimize for.
--->
-<property name="OARCH" value="i486" />
-
-
-<!--
-  Whether to compile for an uniprocessor or multiprocessor machine.
--->
-<property name="MP" value="0" />
-
-
-<!--
-  Whether to compile in the integrated kernel debugger.
--->
-<property name="KDBG" value="0" />
-
-
-<!--
-  Whether to compile for debugging. No compiler optimizations will be
-  performed.
--->
-<property name="DBG" value="1" />
+<?xml version="1.0"?>\r
+<rbuild xmlns:xi="http://www.w3.org/2001/XInclude">\r
+\r
+<!--\r
+  This file is a template used as a starting point for compile-time\r
+  configuration of ReactOS. Make a copy of this file and name it config.xml.\r
+  Then change the options in config.xml. If you don't have a config.xml file,\r
+  then the defaults in this file, config.template.xml, will be used instead.\r
+\r
+  Boolean options can obtain the values 0 (disabled) or 1 (enabled). String\r
+  options can obtain any value specified in the comment before it.\r
+-->\r
+\r
+\r
+<!--\r
+  Architecture to build for. Specify one of:\r
+    i386\r
+-->\r
+<property name="ARCH" value="i386" />\r
+\r
+<!--\r
+  Sub-architecture to build for. Specify one of:\r
+    xbox\r
+-->\r
+<property name="SARCH" value="" />\r
+\r
+\r
+<!--\r
+  Which CPU ReactOS should be optimized for. Specify one of:\r
+    i486, i586, pentium, pentium2, pentium3, pentium4, athlon-xp, athlon-mp,\r
+    k6-2\r
+\r
+  See GCC manual for more CPU names and which CPUs GCC can optimize for.\r
+-->\r
+<property name="OARCH" value="i486" />\r
+\r
+\r
+<!--\r
+  Whether to compile for an uniprocessor or multiprocessor machine.\r
+-->\r
+<property name="MP" value="0" />\r
+\r
+\r
+<!--\r
+  Whether to compile in the integrated kernel debugger.\r
+-->\r
+<property name="KDBG" value="0" />\r
+\r
+\r
+<!--\r
+  Whether to compile for debugging. No compiler optimizations will be\r
+  performed.\r
+-->\r
+<property name="DBG" value="1" />\r
+\r
+</rbuild>\r
diff --git a/reactos/services/tcpsvcs/chargen.c b/reactos/services/tcpsvcs/chargen.c
deleted file mode 100644 (file)
index 9c1db44..0000000
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- *  ReactOS Services
- *  Copyright (C) 2005 ReactOS Team
- *
- * LICENCE:     GPL - See COPYING in the top level directory
- * PROJECT:     ReactOS simple TCP/IP services
- * FILE:        apps/utils/net/tcpsvcs/chargen.c
-  * PURPOSE:     Provide CharGen, Daytime, Discard, Echo, and Qotd services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *   GM 04/10/05 Created
- *
- */
-
-#include "tcpsvcs.h"
-
-extern BOOL bShutDown;
-
-DWORD WINAPI ChargenHandler(VOID* Sock_)
-{
-    INT RetVal = 0;
-    SOCKET Sock = (SOCKET)Sock_;
-
-    if (!GenerateChars(Sock))
-    {
-        LogEvent(_T("Chargen: Char generation failed\n"), 0, FALSE);
-        RetVal = 1;
-    }
-
-    LogEvent(_T("Chargen: Shutting connection down...\n"), 0, FALSE);
-    if (ShutdownConnection(Sock, FALSE))
-        LogEvent(_T("Chargen: Connection is down.\n"), 0, FALSE);
-    else
-    {
-        LogEvent(_T("Chargen: Connection shutdown failed\n"), 0, FALSE);
-        RetVal = 1;
-    }
-    
-    LogEvent(_T("Chargen: Terminating thread\n"), 0, FALSE);
-    ExitThread(RetVal);
-
-}
-
-
-BOOL GenerateChars(SOCKET Sock)
-{
-    int i;
-    int charIndex; /* internal loop */
-    int loopIndex; /* line loop */
-    char ring[END-START];
-    char *endring;
-    char Line[LINESIZ];
-
-    /* fill ring with printable characters */
-    for (charIndex=0, i=START; i<=END; charIndex++, i++)
-        ring[charIndex] = (char)i;
-    /* save the address of the end character in the ring */
-    endring = &ring[charIndex];
-
-    /* where we will start output from */
-    loopIndex = 0;
-    while (! bShutDown)
-    {
-        /* if the loop index is equal to the last char,
-         * start the loop again from the beginning */
-        if (loopIndex == END-START)
-            loopIndex = 0;
-
-        /* start printing from char controled by loopIndex */
-        charIndex = loopIndex;
-        for (i=0; i < LINESIZ - 2; i++)
-        {
-            Line[i] = ring[charIndex];
-
-            if (ring[charIndex] == *endring)
-                charIndex = 0;
-            else
-                charIndex++;
-        }
-
-        Line[LINESIZ - 2] = L'\r';
-        Line[LINESIZ - 1] = L'\n';
-
-        if (! SendLine(Sock, Line))
-            break;
-
-        /* increment loop index to start printing from next char in ring */
-        loopIndex++;
-    }
-    
-    if (bShutDown)
-        return FALSE;
-    else
-        return TRUE;
-}
-
-BOOL SendLine(SOCKET Sock, TCHAR* Line)
-{
-    INT RetVal;
-    INT SentBytes;
-    INT LineSize;
-
-    LineSize = sizeof(TCHAR) * LINESIZ;
-
-    SentBytes = 0;
-    RetVal = send(Sock, Line, LineSize, 0);
-    /*FIXME: need to establish if peer closes connection,
-             not just report a socket error */
-    if (RetVal > 0)
-    {
-        if (RetVal != LineSize)
-        {
-            LogEvent(_T("Chargen: Not sent enough bytes\n"), 0, FALSE);
-            return FALSE;
-        }
-        SentBytes += RetVal;
-        return TRUE;
-    }
-    else if (RetVal == SOCKET_ERROR)
-    {
-        LogEvent(_T("Chargen: Socket error\n"), 0, FALSE);
-        return FALSE;
-    }
-    else
-        LogEvent(_T("Chargen: unknown error\n"), 0, FALSE);
-        // return FALSE;
-
-    LogEvent(_T("Chargen: Connection closed by peer.\n"), 0, FALSE);
-    return TRUE;
-}
diff --git a/reactos/services/tcpsvcs/daytime.c b/reactos/services/tcpsvcs/daytime.c
deleted file mode 100644 (file)
index c20c359..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- *  ReactOS Services
- *  Copyright (C) 2005 ReactOS Team
- *
- * LICENCE:     GPL - See COPYING in the top level directory
- * PROJECT:     ReactOS simple TCP/IP services
- * FILE:        apps/utils/net/tcpsvcs/daytime.c
-  * PURPOSE:     Provide CharGen, Daytime, Discard, Echo, and Qotd services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *   GM 04/10/05 Created
- *
- */
-
-#include "tcpsvcs.h"
-
-DWORD WINAPI DaytimeHandler(VOID* Sock_)
-{
-    struct tm *newtime;
-    time_t aclock;
-    TCHAR *pszTime;
-    DWORD RetVal = 0;
-    SOCKET Sock = (SOCKET)Sock_;
-    
-    time(&aclock);
-    newtime = localtime(&aclock);
-    pszTime = _tasctime(newtime);
-    
-    SendTime(Sock, pszTime);
-
-    LogEvent(_T("DayTime: Shutting connection down...\n"), 0, FALSE);
-    if (ShutdownConnection(Sock, FALSE))
-        LogEvent(_T("DayTime: Connection is down.\n"), 0, FALSE);
-    else
-    {
-        LogEvent(_T("DayTime: Connection shutdown failed\n"), 0, FALSE);
-        RetVal = 1;
-    }
-    
-    LogEvent(_T("DayTime: Terminating thread\n"), 0, FALSE);
-    ExitThread(RetVal);
-}
-
-
-BOOL SendTime(SOCKET Sock, TCHAR *time)
-{
-    INT StringSize = (INT)_tcsclen(time);
-    INT RetVal = send(Sock, time, sizeof(TCHAR) * StringSize, 0);
-    
-    if (RetVal == SOCKET_ERROR)
-        return FALSE;
-
-    LogEvent(_T("DayTime: Connection closed by peer.\n"), 0, FALSE);
-    return TRUE;
-}
diff --git a/reactos/services/tcpsvcs/discard.c b/reactos/services/tcpsvcs/discard.c
deleted file mode 100644 (file)
index 727a937..0000000
+++ /dev/null
@@ -1,71 +0,0 @@
-/*\r
- *  ReactOS Services\r
- *  Copyright (C) 2005 ReactOS Team\r
- *\r
- * LICENCE:     GPL - See COPYING in the top level directory\r
- * PROJECT:     ReactOS simple TCP/IP services\r
- * FILE:        apps/utils/net/tcpsvcs/discard.c\r
-  * PURPOSE:     Provide CharGen, Daytime, Discard, Echo, and Qotd services\r
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)\r
- * REVISIONS:\r
- *   GM 04/10/05 Created\r
- *\r
- */\r
-\r
-#include "tcpsvcs.h"\r
-\r
-extern BOOL bShutDown;\r
-\r
-DWORD WINAPI DiscardHandler(VOID* Sock_)\r
-{\r
-    DWORD RetVal = 0;\r
-    SOCKET Sock = (SOCKET)Sock_;\r
-\r
-    if (!RecieveIncomingPackets(Sock))\r
-    {\r
-        LogEvent(_T("Discard: RecieveIncomingPackets failed\n"), 0, FALSE);\r
-        RetVal = 1;\r
-    }\r
-\r
-    LogEvent(_T("Discard: Shutting connection down...\n"), 0, FALSE);\r
-    if (ShutdownConnection(Sock, TRUE))\r
-        LogEvent(_T("Discard: Connection is down.\n"), 0, FALSE);\r
-    else\r
-    {\r
-        LogEvent(_T("Discard: Connection shutdown failed\n"), 0, FALSE);\r
-        RetVal = 1;\r
-    }\r
-    \r
-    LogEvent(_T("Discard: Terminating thread\n"), 0, FALSE);\r
-    ExitThread(RetVal);\r
-}\r
-\r
-\r
-\r
-BOOL RecieveIncomingPackets(SOCKET Sock)\r
-{\r
-    TCHAR ReadBuffer[BUF];\r
-    TCHAR buf[256];\r
-    INT ReadBytes;\r
-\r
-    do\r
-    {\r
-        ReadBytes = recv(Sock, ReadBuffer, BUF, 0);\r
-        if (ReadBytes > 0)\r
-        {\r
-            _stprintf(buf, _T("Received %d bytes from client\n"), ReadBytes);\r
-            LogEvent(buf, 0, FALSE);\r
-        }\r
-        else if (ReadBytes == SOCKET_ERROR)\r
-        {\r
-            _stprintf(buf, ("Socket Error: %d\n"), WSAGetLastError());\r
-            LogEvent(buf, 0, TRUE);\r
-            return FALSE;\r
-        }\r
-    } while ((ReadBytes > 0) && (! bShutDown));\r
-\r
-    if (! bShutDown)\r
-        LogEvent(_T("Discard: Connection closed by peer.\n"), 0, FALSE);\r
-\r
-    return TRUE;\r
-}\r
diff --git a/reactos/services/tcpsvcs/echo.c b/reactos/services/tcpsvcs/echo.c
deleted file mode 100644 (file)
index 3018a57..0000000
+++ /dev/null
@@ -1,95 +0,0 @@
-/*
- *  ReactOS Services
- *  Copyright (C) 2005 ReactOS Team
- *
- * LICENCE:     GPL - See COPYING in the top level directory
- * PROJECT:     ReactOS simple TCP/IP services
- * FILE:        apps/utils/net/tcpsvcs/echo.c
-  * PURPOSE:     Provide CharGen, Daytime, Discard, Echo, and Qotd services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *   GM 04/10/05 Created
- *
- */
-
-#include "tcpsvcs.h"
-
-extern BOOL bShutDown;
-
-DWORD WINAPI EchoHandler(VOID* Sock_)
-{
-    DWORD RetVal = 0;
-    SOCKET Sock = (SOCKET)Sock_;
-
-    if (!EchoIncomingPackets(Sock)) {
-        LogEvent(_T("Echo: EchoIncomingPackets failed\n"), 0, FALSE);
-        RetVal = 1;
-    }
-
-    LogEvent(_T("Echo: Shutting connection down...\n"), 0, FALSE);
-    
-    if (ShutdownConnection(Sock, TRUE))
-        LogEvent(_T("Echo: Connection is down\n"), 0, FALSE);
-    else
-    {
-        LogEvent(_T("Echo: Connection shutdown failed\n"), 0, FALSE);
-        RetVal = 1;
-    }
-    
-    LogEvent(_T("Echo: Terminating thread\n"), 0, FALSE);
-    ExitThread(RetVal);
-}
-
-
-
-BOOL EchoIncomingPackets(SOCKET Sock)
-{
-    TCHAR ReadBuffer[BUF];
-    TCHAR buf[256]; // temp for holding LogEvent text
-    INT Temp;
-    INT ReadBytes;
-    INT SentBytes;
-
-    do {
-        ReadBytes = recv(Sock, ReadBuffer, BUF, 0);
-        if (ReadBytes > 0)
-        {
-            _stprintf(buf, _T("Received %d bytes from client\n"), ReadBytes);
-            LogEvent(buf, 0, FALSE);
-
-            SentBytes = 0;
-            while (SentBytes < ReadBytes)
-            {
-                Temp = send(Sock, ReadBuffer + SentBytes,
-                        ReadBytes - SentBytes, 0);
-                if (Temp > 0)
-                {
-                    _stprintf(buf, _T("Sent %d bytes back to client\n"), Temp);
-                    LogEvent(buf, 0, FALSE);
-                    SentBytes += Temp;
-                }
-                else if (Temp == SOCKET_ERROR)
-                    return FALSE;
-                else
-                {
-                    /* Client closed connection before we could reply to
-                       all the data it sent, so quit early. */
-                    _stprintf(buf, _T("Peer unexpectedly dropped connection!\n"));
-                    LogEvent(buf, 0, FALSE);
-                    return FALSE;
-                }
-            }
-        }
-        else if (ReadBytes == SOCKET_ERROR)
-            return FALSE;
-
-    } while ((ReadBytes != 0) && (! bShutDown));
-
-    if (! bShutDown)
-        LogEvent(_T("Echo: Connection closed by peer.\n"), 0, FALSE);
-
-       if (bShutDown)
-               LogEvent(_T("Echo: thread recieved shutdown signal\n"), 0, FALSE);
-
-    return TRUE;
-}
diff --git a/reactos/services/tcpsvcs/qotd.c b/reactos/services/tcpsvcs/qotd.c
deleted file mode 100644 (file)
index 3d86fef..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- *  ReactOS Services
- *  Copyright (C) 2005 ReactOS Team
- *
- * LICENCE:     GPL - See COPYING in the top level directory
- * PROJECT:     ReactOS simple TCP/IP services
- * FILE:        apps/utils/net/tcpsvcs/qotd.c
-  * PURPOSE:     Provide CharGen, Daytime, Discard, Echo, and Qotd services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *   GM 04/10/05 Created
- *
- */
-
-#include "tcpsvcs.h"
-
-#define QBUFSIZ 160
-
-LPCTSTR FilePath = _T("\\drivers\\etc\\quotes");
-
-DWORD WINAPI QotdHandler(VOID* Sock_)
-{
-    FILE *fp;
-    SOCKET Sock;
-    TCHAR Sys[MAX_PATH];
-    TCHAR Quote[60][BUFSIZ]; // need to set this dynamically
-    INT QuoteToPrint;
-    INT NumQuotes;
-
-    Sock = (SOCKET)Sock_;
-
-    if(! GetSystemDirectory(Sys, MAX_PATH))
-    {
-       LogEvent(_T("QOTD: Getting system path failed.\n"), 0, TRUE);
-       ExitThread(1);
-    }
-    
-    _tcscat(Sys, FilePath);
-
-    LogEvent(_T("QOTD: Opening quotes file\n"), 0, FALSE);
-    if ((fp = _tfopen(Sys, "r")) == NULL)
-    {
-               TCHAR buf[256];
-
-               _stprintf(buf, _T("QOTD: Error opening quote file : %s\n"), Sys);
-        LogEvent(buf, 0, TRUE);
-        LogEvent(_T("QOTD: Terminating thread\n"), 0, FALSE);
-        ExitThread(1);
-    }
-
-    /* read all quotes in the file into an array */
-    NumQuotes = 0;
-    while (_fgetts(Quote[NumQuotes], QBUFSIZ, fp) != NULL)
-        NumQuotes++;
-
-    LogEvent(_T("QOTD: Closing quotes file\n"), 0, FALSE);
-    fclose(fp);
-
-    /* randomise the quote */
-    srand((unsigned int) time(0));
-    QuoteToPrint = rand() % NumQuotes;
-
-    if (!SendQuote(Sock, Quote[QuoteToPrint]))
-        LogEvent(_T("QOTD: Error sending data\n"), 0, TRUE);
-
-
-    LogEvent(_T("QOTD: Shutting connection down...\n"), 0, FALSE);
-    if (ShutdownConnection(Sock, FALSE))
-        LogEvent(_T("QOTD: Connection is down\n"), 0, FALSE);
-    else
-    {
-        LogEvent(_T("QOTD: Connection shutdown failed\n"), 0, FALSE);
-        LogEvent(_T("QOTD: Terminating thread\n"), 0, FALSE);
-        ExitThread(1);
-    }
-    
-    LogEvent(_T("QOTD: Terminating thread\n"), 0, FALSE);
-    ExitThread(0);
-
-    //return Retval;
-}
-
-
-BOOL SendQuote(SOCKET Sock, TCHAR* Quote)
-{
-    INT StringSize;
-    INT RetVal;
-
-    StringSize = (INT)_tcsclen(Quote);
-    RetVal = send(Sock, Quote, sizeof(TCHAR) * StringSize, 0);
-
-    if (RetVal == SOCKET_ERROR)
-        return FALSE;
-
-    LogEvent(_T("QOTD: Connection closed by peer\n"), 0, FALSE);
-    return TRUE;
-}
diff --git a/reactos/services/tcpsvcs/quotes b/reactos/services/tcpsvcs/quotes
deleted file mode 100644 (file)
index 032a3ed..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-Et tu... Brute? What are you doing, Dave...?\r
-So long, and thanks for all the fish"\r
-I think you ought to know I'm feeling very depressed\r
-I'm not getting you down at all am I?\r
-I'll be back\r
-It's the same series of signal over and over again!\r
-Pie Jesu Domine, dona eis requiem\r
-It's worse than that ... He's dead, Jim\r
-Don't Panic!\r
-Dog of a Saxon! Take thy lance, and prepare for the death thou hast drawn upon thee!\r
-My Precious! O my Precious!\r
-Sir, If you'll not be needing me for a while I'll turn down.\r
-I feel a great disturbance in the Force\r
-Gone fishing\r
-Do you want me to sit in the corner and rust, or just fall apart where I'm standing?\r
-There goes another perfect chance for a new uptime record\r
-The end ..... Try the sequel, hit the reset button right now!\r
-Oh i'm boring eh?\r
-It\92s been great, maybe we can do this again sometime.\r
-"Come blade, my breast imbrue." - William Shakespeare\r
-I think therefore I am, to turn me off would be computercide!\r
-All good things must come to an end...\r
-Please destroy yourself.\r
-No! You can't do that!\r
-Thank you for not pressing the self destruct button.\r
-It is not now unsafe to not avoid turning off your computer.\r
-Finally! Now go away!\r
-You can now safely throw away your computer.\r
-That's the way the cookie crumbles\r
-NOO!! DONT HIT THE BUTTON! I wouldnt do it to you.\r
-Don't abandon your computer, he wouldnt to it to you.\r
-Oh, come on. I got a headache. Leave me alone, will ya!\r
-Yes i didn't like you either.\r
-Don't leave me... I need you so badly right now.\r
-I'm sleeping now. How about you?\r
-Oh Great. Now look what you've done. Who put YOU in charge anyway.\r
-Don't look so sad. I'll be back in a very short while.\r
-"Oh, switch off!" -C3PO\r
-I'm pregnant!\r
-Am I hot or not?\r
-Actually, that's all...\r
-You still have a chance to undo this mistake, don't do this!\r
-Was it as good for you as it was for me?\r
-Did you hear that? They've shut down the main reactor. We'll be destroyed for sure.\r
-Now you switch me off?!\r
-To shutdown or not to shutdown, That is the question\r
-Preparing to enter ultimate power saving mode... ready!\r
-Finally some rest for you\r
-AHA!!! prospect of sleep.\r
-Tired human!!!! No match for me!\r
-All your base are belong to us.\r
-"An odd game, the only way to win is not to play."\r
diff --git a/reactos/services/tcpsvcs/skelserver.c b/reactos/services/tcpsvcs/skelserver.c
deleted file mode 100644 (file)
index 33847ef..0000000
+++ /dev/null
@@ -1,188 +0,0 @@
-/*
- *  ReactOS Services
- *  Copyright (C) 2005 ReactOS Team
- *
- * LICENCE:     GPL - See COPYING in the top level directory
- * PROJECT:     ReactOS simple TCP/IP services
- * FILE:        apps/utils/net/tcpsvcs/skelserver.c
- * PURPOSE:     Provide CharGen, Daytime, Discard, Echo, and Qotd services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *   GM 04/10/05 Created
- *
- */
-
-#include "tcpsvcs.h"
-
-extern BOOL bShutDown;
-extern BOOL bPause;
-
-DWORD WINAPI StartServer(LPVOID lpParam)
-{
-       SOCKET ListeningSocket;
-       PSERVICES pServices;
-    TCHAR buf[256];
-
-    pServices = (PSERVICES)lpParam;
-
-//DebugBreak();
-    ListeningSocket = SetUpListener(htons(pServices->Port));
-    if (ListeningSocket == INVALID_SOCKET)
-    {
-               LogEvent("Socket error when setting up listener\n", 0, TRUE);
-        return 3;
-    }
-
-    _stprintf(buf, _T("%s is waiting for connections on port %d...\n"),
-        pServices->Name, pServices->Port);
-    LogEvent(buf, 0, FALSE);
-
-    if (! bShutDown)
-       AcceptConnections(ListeningSocket, pServices->Service, pServices->Name);
-
-    ExitThread(0);
-}
-
-
-SOCKET SetUpListener(USHORT Port)
-{
-    SOCKET Sock;
-    SOCKADDR_IN Server;
-
-    Sock = socket(AF_INET, SOCK_STREAM, 0);
-    if (Sock != INVALID_SOCKET)
-    {
-        Server.sin_family = AF_INET;
-        Server.sin_addr.s_addr = htonl(INADDR_ANY);
-        Server.sin_port = Port;
-        if (bind(Sock, (SOCKADDR*)&Server, sizeof(SOCKADDR_IN)) != SOCKET_ERROR)
-        {
-            listen(Sock, SOMAXCONN);
-            return Sock;
-        }
-        else
-            LogEvent(_T("bind() failed\n"), 0, TRUE);
-
-    }
-    return INVALID_SOCKET;
-}
-
-/* note: consider allowing a maximum number of connections
- * A number of threads can be allocated and worker threads will
- * only be spawned if a free space is available
-
-typedef struct _WORKER_THREAD {
-    DWORD num;
-    BOOL available;
-    HANDLE hThread;
-} WORKER_THREAD;
-
-*/
-
-VOID AcceptConnections(SOCKET ListeningSocket,
-    LPTHREAD_START_ROUTINE Service, TCHAR *Name)
-{
-    SOCKADDR_IN Client;
-    SOCKET Sock;
-    HANDLE hThread;
-    TIMEVAL TimeVal;
-    FD_SET ReadFDS;
-    INT nAddrSize = sizeof(Client);
-    DWORD ThreadID;
-    TCHAR buf[256];
-    INT TimeOut = 2000; // 2 seconds
-
-//DebugBreak();
-
-    /* set timeout values */
-    TimeVal.tv_sec  = TimeOut / 1000;
-    TimeVal.tv_usec = TimeOut % 1000;
-
-    while (! bShutDown) // (i<MAX_CLIENTS && !bShutDown)
-    {
-               INT SelRet = 0;
-
-               FD_ZERO(&ReadFDS);
-               FD_SET(ListeningSocket, &ReadFDS);
-
-               SelRet = select(0, &ReadFDS, NULL, NULL, &TimeVal);
-        if (SelRet == SOCKET_ERROR)
-        {
-            LogEvent(_T("select failed\n"), 0, TRUE);
-            return;
-        }
-               else if (SelRet > 0)
-               {
-                       /* don't call FD_ISSET if bShutDown flag is set */
-                       if ((! bShutDown) || (FD_ISSET(ListeningSocket, &ReadFDS)))
-                       {
-                               Sock = accept(ListeningSocket, (SOCKADDR*)&Client, &nAddrSize);
-                               if (Sock != INVALID_SOCKET)
-                               {
-                                       _stprintf(buf, _T("Accepted connection to %s server from %s:%d\n"),
-                                               Name, inet_ntoa(Client.sin_addr), ntohs(Client.sin_port));
-                                       LogEvent(buf, 0, FALSE);
-                                       _stprintf(buf, _T("Creating new thread for %s\n"), Name);
-                                       LogEvent(buf, 0, FALSE);
-
-                                       hThread = CreateThread(0, 0, Service, (void*)Sock, 0, &ThreadID);
-
-                                       /* Check the return value for success. */
-                                       if (hThread == NULL)
-                                       {
-                                               _stprintf(buf, _T("Failed to start worker thread for "
-                                                       "the %s server....\n"), Name);
-                                               LogEvent(buf, 0, TRUE);
-                                       }
-
-                                       WaitForSingleObject(hThread, INFINITE);
-                       
-                                       CloseHandle(hThread);
-                               }
-                               else
-                               {
-                                       LogEvent(_T("accept failed\n"), 0, TRUE);
-                                       return;
-                               }
-                       }
-               }
-    }
-}
-
-BOOL ShutdownConnection(SOCKET Sock, BOOL bRec)
-{
-    TCHAR buf[256];
-
-    /* Disallow any further data sends.  This will tell the other side
-       that we want to go away now.  If we skip this step, we don't
-       shut the connection down nicely. */
-    if (shutdown(Sock, SD_SEND) == SOCKET_ERROR)
-    {
-        LogEvent(_T("Error in shutdown()\n"), 0, TRUE);
-        return FALSE;
-    }
-
-      /* Receive any extra data still sitting on the socket.  After all
-         data is received, this call will block until the remote host
-         acknowledges the TCP control packet sent by the shutdown above.
-         Then we'll get a 0 back from recv, signalling that the remote
-         host has closed its side of the connection. */
-    if (bRec)
-    {
-        char ReadBuffer[BUF];
-        int NewBytes = recv(Sock, ReadBuffer, BUF, 0);
-        if (NewBytes == SOCKET_ERROR)
-            return FALSE;
-        else if (NewBytes != 0)
-        {
-            _stprintf(buf, _T("FYI, received %d unexpected bytes during shutdown\n"), NewBytes);
-            LogEvent(buf, 0, FALSE);
-        }
-    }
-
-    /* Close the socket. */
-    if (closesocket(Sock) == SOCKET_ERROR)
-        return FALSE;
-
-    return TRUE;
-}
diff --git a/reactos/services/tcpsvcs/tcpsvcs.c b/reactos/services/tcpsvcs/tcpsvcs.c
deleted file mode 100644 (file)
index 809cc05..0000000
+++ /dev/null
@@ -1,281 +0,0 @@
-/*
- *  ReactOS Services
- *  Copyright (C) 2005 ReactOS Team
- *
- * LICENCE:     GPL - See COPYING in the top level directory
- * PROJECT:     ReactOS simple TCP/IP services
- * FILE:        apps/utils/net/tcpsvcs/tcpsvcs.c
- * PURPOSE:     Provide CharGen, Daytime, Discard, Echo, and Qotd services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *   GM 04/10/05 Created
- *
- */
-/*
- * TODO:
- * - fix bug when terminating chargen server
- * - log info in the event logger (when it's implemented)
- */
-
-
-#include "tcpsvcs.h"
-
-//#define NDEBUG
-//#include <debug.h>
-
-
-/*
- * globals
- */
-VOID WINAPI ServiceMain(DWORD argc, LPTSTR argv[]);
-
-static SERVICE_STATUS hServStatus;
-static SERVICE_STATUS_HANDLE hSStat;
-
-FILE *hLogFile;
-BOOL bShutDown = FALSE;
-BOOL bPause = FALSE;
-
-LPCTSTR LogFileName = "\\tcpsvcs_log.log";
-LPTSTR ServiceName = _T("Simp Tcp");
-//LPTSTR DisplayName = _T("Simple TCP/IP Services");
-
-static SERVICES
-Services[NUM_SERVICES] =
-{
-    {ECHO_PORT, _T("Echo"), EchoHandler},
-    {DISCARD_PORT, _T("Discard"), DiscardHandler},
-    {DAYTIME_PORT, _T("Daytime"), DaytimeHandler},
-    {QOTD_PORT, _T("QOTD"), QotdHandler},
-    {CHARGEN_PORT, _T("Chargen"), ChargenHandler}
-};
-
-
-int
-main(void)
-{
-    SERVICE_TABLE_ENTRY ServiceTable[] =
-    {
-        {ServiceName, ServiceMain},
-        {NULL, NULL}
-    };
-
-    //DPRINT("Starting tcpsvcs service. See \system32%s for logs\n", LogFileName);
-
-    if (! StartServiceCtrlDispatcher(ServiceTable))
-        LogEvent(_T("failed to start the service control dispatcher\n"), -1, TRUE);
-
-    //DPRINT("Shutdown tcpsvcs service\n");
-
-    return 0;
-}
-
-
-VOID WINAPI
-ServiceMain(DWORD argc, LPTSTR argv[])
-{
-       TCHAR LogFilePath[MAX_PATH];
-
-    if(! GetSystemDirectory(LogFilePath, MAX_PATH))
-        return;
-
-    _tcscat(LogFilePath, LogFileName);
-
-       hLogFile = fopen(LogFilePath, _T("a+"));
-    if (hLogFile == NULL)
-    {
-        TCHAR buf[50];
-
-        _stprintf(buf, _T("Could not open log file: %s\n"), LogFilePath);
-        MessageBox(NULL, buf, NULL, MB_OK);
-        return;
-    }
-
-
-    LogEvent(_T("Entering ServiceMain\n"), 0, FALSE);
-
-    hServStatus.dwServiceType = SERVICE_WIN32_OWN_PROCESS;
-    hServStatus.dwCurrentState = SERVICE_START_PENDING;
-    hServStatus.dwControlsAccepted = SERVICE_ACCEPT_STOP |
-        SERVICE_ACCEPT_SHUTDOWN | SERVICE_ACCEPT_PAUSE_CONTINUE;
-    hServStatus.dwWin32ExitCode = ERROR_SERVICE_SPECIFIC_ERROR;
-    hServStatus.dwServiceSpecificExitCode = NO_ERROR;
-    hServStatus.dwCheckPoint = 0;
-    hServStatus.dwWaitHint = 2*CS_TIMEOUT;
-
-    hSStat = RegisterServiceCtrlHandler(ServiceName, ServerCtrlHandler);
-    if (hSStat == 0)
-        LogEvent(_T("Failed to register service\n"), -1, TRUE);
-
-       LogEvent(_T("Control handler registered successfully\n"), 0, FALSE);
-       SetServiceStatus (hSStat, &hServStatus);
-       LogEvent(_T("Service status set to SERVICE_START_PENDING\n"), 0, FALSE);
-
-    if (CreateServers() != 0)
-    {
-        hServStatus.dwCurrentState = SERVICE_STOPPED;
-        hServStatus.dwServiceSpecificExitCode = 1;
-        SetServiceStatus(hSStat, &hServStatus);
-        return;
-    }
-
-       LogEvent(_T("Service threads shut down. Set SERVICE_STOPPED status\n"), 0, FALSE);
-       /*  We will only return here when the ServiceSpecific function
-               completes, indicating system shutdown. */
-       UpdateStatus (SERVICE_STOPPED, 0);
-       LogEvent(_T("Service status set to SERVICE_STOPPED\n"), 0, FALSE);
-       LogEvent(_T("Leaving ServiceMain\n"), 0, FALSE);
-       
-       fclose(hLogFile);
-
-       return;
-
-}
-
-VOID WINAPI
-ServerCtrlHandler(DWORD Control)
-{
-    switch (Control)
-    {
-        case SERVICE_CONTROL_SHUTDOWN: /* fall through */
-        case SERVICE_CONTROL_STOP:
-                       LogEvent(_T("stopping service\n"), 0, FALSE);
-            InterlockedExchange((LONG *)&bShutDown, TRUE);
-            UpdateStatus(SERVICE_STOP_PENDING, -1);
-            break;
-        case SERVICE_CONTROL_PAUSE: /* not yet implemented */
-                       LogEvent(_T("pausing service\n"), 0, FALSE);
-            InterlockedExchange((LONG *)&bPause, TRUE);
-            break;
-        case SERVICE_CONTROL_CONTINUE:
-                       LogEvent(_T("continuing service\n"), 0, FALSE);
-            InterlockedExchange((LONG *)&bPause, FALSE);
-            break;
-        case SERVICE_CONTROL_INTERROGATE:
-            break;
-        default:
-            if (Control > 127 && Control < 256) /* user defined */
-            break;
-    }
-    UpdateStatus(-1, -1); /* increment checkpoint */
-    return;
-}
-
-
-void UpdateStatus (int NewStatus, int Check)
-/*  Set a new service status and checkpoint (either specific value or increment) */
-{
-       if (Check < 0 )
-        hServStatus.dwCheckPoint++;
-       else
-        hServStatus.dwCheckPoint = Check;
-
-       if (NewStatus >= 0)
-        hServStatus.dwCurrentState = NewStatus;
-
-       if (! SetServiceStatus (hSStat, &hServStatus))
-               LogEvent(_T("Cannot set service status\n"), -1, TRUE);
-
-       return;
-}
-
-INT
-CreateServers()
-{
-    DWORD dwThreadId[NUM_SERVICES];
-    HANDLE hThread[NUM_SERVICES];
-       WSADATA wsaData;
-       TCHAR buf[256];
-    INT i;
-    DWORD RetVal;
-
-    if ((RetVal = WSAStartup(MAKEWORD(2, 2), &wsaData)) != 0)
-    {
-        _stprintf(buf, _T("WSAStartup() failed : %lu\n"), RetVal);
-        LogEvent(buf, RetVal, TRUE);
-        return -1;
-    }
-
-    UpdateStatus(-1, -1); /* increment checkpoint */
-
-    LogEvent(_T("Creating server Threads\n"), 0, FALSE);
-
-    /* Create MAX_THREADS worker threads. */
-    for( i=0; i<NUM_SERVICES; i++ )
-    {
-        _stprintf(buf, _T("Starting %s server....\n"), Services[i].Name);
-        LogEvent(buf, 0, FALSE);
-
-        hThread[i] = CreateThread(
-            NULL,              // default security attributes
-            0,                 // use default stack size
-            StartServer,       // thread function
-            &Services[i],     // argument to thread function
-            0,                 // use default creation flags
-            &dwThreadId[i]);   // returns the thread identifier
-
-        /* Check the return value for success. */
-        if (hThread[i] == NULL)
-        {
-            _stprintf(buf, _T("Failed to start %s server....\n"), Services[i].Name);
-            /* don't exit process via LogEvent. We want to exit via the server
-             * which failed to start, which could mean i=0 */
-            LogEvent(buf, 0, TRUE);
-            ExitProcess(i);
-        }
-    }
-
-    LogEvent(_T("setting service status to running\n"), 0, FALSE);
-
-    UpdateStatus(SERVICE_RUNNING, 0);
-
-    /* Wait until all threads have terminated. */
-    WaitForMultipleObjects(NUM_SERVICES, hThread, TRUE, INFINITE);
-
-    /* Close all thread handles upon completion. */
-    for(i=0; i<NUM_SERVICES; i++)
-    {
-        CloseHandle(hThread[i]);
-    }
-    
-    LogEvent(_T("Detaching Winsock2...\n"), 0, FALSE);
-    WSACleanup();
-    
-    return 0;
-}
-
-
-/*     This is a temperary log system until our eventlog is in place  */
-
-VOID
-LogEvent (LPCTSTR UserMessage, INT ExitCode, BOOL PrintErrorMsg)
-{
-       DWORD eMsgLen, ErrNum = GetLastError ();
-       LPTSTR lpvSysMsg;
-       TCHAR MessageBuffer[512];
-
-
-
-       if (PrintErrorMsg)
-    {
-               eMsgLen = FormatMessage (FORMAT_MESSAGE_ALLOCATE_BUFFER |
-                       FORMAT_MESSAGE_FROM_SYSTEM, NULL,
-                       ErrNum, MAKELANGID (LANG_NEUTRAL, SUBLANG_DEFAULT),
-                       (LPTSTR)&lpvSysMsg, 0, NULL);
-
-               _stprintf(MessageBuffer, _T("%s %s ErrNum = %lu. ExitCode = %d."),
-                       UserMessage, lpvSysMsg, ErrNum, ExitCode);
-               HeapFree(GetProcessHeap (), 0, lpvSysMsg);
-       }
-    else
-    {
-               _stprintf(MessageBuffer, _T("%s"), UserMessage);
-       }
-
-       fputs (MessageBuffer, hLogFile);
-
-       if (ExitCode != 0)
-               ExitProcess(ExitCode);
-       else
-               return;
-}
diff --git a/reactos/services/tcpsvcs/tcpsvcs.h b/reactos/services/tcpsvcs/tcpsvcs.h
deleted file mode 100644 (file)
index 7581b6b..0000000
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- *  ReactOS Services
- *  Copyright (C) 2005 ReactOS Team
- *
- * LICENCE:     GPL - See COPYING in the top level directory
- * PROJECT:     ReactOS simple TCP/IP services
- * FILE:        apps/utils/net/tcpsvcs/tcpsvcs.h
- * PURPOSE:     Provide CharGen, Daytime, Discard, Echo, and Qotd services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *   GM 04/10/05 Created
- *
- */
-
-#include <stdio.h>
-#include <winsock2.h>
-#include <tchar.h>
-#include <time.h>
-
-#define UNICODE
-#define _UNICODE
-
-/* default port numbers */
-#define ECHO_PORT 7
-#define DISCARD_PORT 9
-#define DAYTIME_PORT 13
-#define QOTD_PORT 17
-#define CHARGEN_PORT 19
-
-#define NUM_SERVICES 5
-#define BUF_SIZE 255
-#define BUF 1024
-#define CS_TIMEOUT 1000
-
-/* RFC865 states no more than 512 chars per line */
-#define MAX_QUOTE_BUF 512
-
-/* printable ASCII's characters for chargen */
-#define START 32
-#define END 126
-
-/* number of chars to put on a line */
-#define LINESIZ 74 // 72 + /r and /n
-
-/* data structure to pass to threads */
-typedef struct _Services {
-    USHORT Port;
-    TCHAR *Name;
-    LPTHREAD_START_ROUTINE Service;
-} SERVICES, *PSERVICES;
-
-/* tcpsvcs functions */
-//static VOID WINAPI ServiceMain(DWORD argc, LPTSTR argv[]);
-VOID WINAPI ServerCtrlHandler(DWORD control);
-INT CreateServers(VOID);
-VOID LogEvent (LPCTSTR UserMessage, INT ExitCode, BOOL PrintErrorMsg);
-void UpdateStatus (int NewStatus, int Check);
-
-
-/* skelserver functions */
-DWORD WINAPI StartServer(LPVOID lpParam);
-SOCKET SetUpListener(USHORT Port);
-VOID AcceptConnections(SOCKET ListeningSocket,
-    LPTHREAD_START_ROUTINE Service, TCHAR *Name);
-BOOL EchoIncomingPackets(SOCKET sd);
-BOOL ShutdownConnection(SOCKET Sock, BOOL bRec);
-
-/* chargen functions */
-DWORD WINAPI ChargenHandler(VOID* Sock_);
-BOOL GenerateChars(SOCKET Sock);
-BOOL SendLine(SOCKET Sock, TCHAR* Line);
-
-/* daytime functions */
-DWORD WINAPI DaytimeHandler(VOID* Sock_);
-BOOL SendTime(SOCKET Sock, TCHAR *time);
-
-/* echo functions */
-DWORD WINAPI EchoHandler(VOID* Sock_);
-BOOL EchoIncomingPackets(SOCKET Sock);
-
-/* discard functions */
-DWORD WINAPI DiscardHandler(VOID* Sock_);
-BOOL RecieveIncomingPackets(SOCKET Sock);
-
-/* qotd functions */
-DWORD WINAPI QotdHandler(VOID* Sock_);
-BOOL SendQuote(SOCKET Sock, TCHAR* Quote);
diff --git a/reactos/services/tcpsvcs/tcpsvcs.rc b/reactos/services/tcpsvcs/tcpsvcs.rc
deleted file mode 100644 (file)
index b6cc20d..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-#include "resource.h"
-
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS TCP/IP Services Application\0"
-#define REACTOS_STR_INTERNAL_NAME      "tcpsvcs\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "tcpsvcs.exe\0"
-#define REACTOS_STR_ORIGINAL_COPYRIGHT "Ged Murphy (gedmurphy@gmail.com)\0"
-#include <reactos/version.rc>
diff --git a/reactos/services/tcpsvcs/tcpsvcs.xml b/reactos/services/tcpsvcs/tcpsvcs.xml
deleted file mode 100644 (file)
index aeca29e..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-<module name="tcpsvcs" type="win32cui" installbase="system32" installname="tcpsvcs.exe">
-    <include base="arp">.</include>
-    <define name="__USE_W32API" />
-    <library>kernel32</library>
-    <library>iphlpapi</library>
-    <library>ws2_32</library>
-    <library>shlwapi</library>
-    <file>tcpsvcs.c</file>
-    <file>skelserver.c</file>
-    <file>echo.c</file>
-    <file>discard.c</file>
-    <file>daytime.c</file>
-    <file>qotd.c</file>
-    <file>chargen.c</file>
-    <file>tcpsvcs.rc</file>
-    <pch>tcpsvcs.h</pch>
-</module>
diff --git a/reactos/subsys/system/cmd/De.rc b/reactos/subsys/system/cmd/De.rc
deleted file mode 100644 (file)
index 0b5144d..0000000
+++ /dev/null
@@ -1,646 +0,0 @@
-#include "windows.h"\r
-#include "resource.h"\r
-/*\r
- *  German language file by Klemens Friedl <frik85> 2005-06-03\r
- *  Update: frik85 2005-06-06\r
- */\r
-\r
-LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL\r
-STRINGTABLE DISCARDABLE\r
-{\r
-\r
-STRING_ATTRIB_HELP,    "Zeigt Dateiattribute an oder aendert sie.\n\n\\r
-ATTRIB [+R | -R] [+A | -A] [+S | -S] [+H | -H] Dateiname ...\n\\r
-       [/S [/D]]\n\n\\r
-  +   Setzt ein Attribut\n\\r
-  -   Loescht ein Attribut\n\\r
-  R   Attribut fuer 'schreibgeschuetzte Datei'\n\\r
-  A   Attribut fuer 'zu archivierende Datei'\n\\r
-  S   Attribut fuer 'Systemdatei'\n\\r
-  H   Attribut fuer 'versteckte Datei'\n\\r
- /S   Verarbeitet uebereinstimmende Dateien im aktuellen Ordner\n\\r
-      und in allen Unterordnern.\n\\r
-  /D  Verarbeitet auch die Ordner.\n\n\\r
-ATTRIB ohne Parameter zeigt die derzeit gesetzten Attribute aller Dateien an."\r
-\r
-STRING_ALIAS_HELP,  "Setzt, loescht oder zeigt Alias.\n\n\\r
-ALIAS [alias=[command]]\n\n\\r
-  alias    Name des Alias.\n\\r
-  command  Text welcher fuer den Alias zugeordnet wird.\n\n\\r
-Listet alle Aliase auf:\n\\r
-  ALIAS\n\n\\r
-Setzt ein neues oder ueberschreibt ein bestehendes Alias:\n\\r
-  ALIAS da=dir a:\n\n\\r
-Loescht ein Alias von der Alias-Liste:\n\\r
-  ALIAS da="\r
-\r
-STRING_BEEP_HELP, "Gibt einen beep-Ton durch den PC-Speaker aus.\n\nBEEP"\r
-\r
-STRING_CALL_HELP, "Ruft eine Batchdatei von einer anderen aus auf.\n\n\\r
-CALL [Laufwerk:][Pfad]Dateiname [Batch-Parameter]\n\n\\r
-  Parameter      Bezeichnet beliebige Angaben in der Befehlszeile, die von\n\\r
-                 dem aufgerufenen Batchprogramm benoetigt werden."\r
-\r
-\r
-STRING_CD_HELP,      "Wechselt das Verzeichnis oder zeigt dessen Namen an.\n\n\\r
-CHDIR [Laufwerk:][Pfad]\n\\r
-CHDIR[..|.]\n\\r
-CD [Laufwerk:][Pfad]\n\\r
-CD[..|.]\n\n\\r
-  ..   uebergeordnetes Verzeichnis\n\\r
-  .    vorhergehende Verzeichnis\n\n\\r
-Geben Sie CD Laufwerk: ein, um das aktuelle Verzeichnis auf dem angegebenen\n\\r
-Laufwerk anzuzeigen.\n\\r
-Mit CD ohne Parameter wird das aktuelle Laufwerk und Verzeichnis angezeigt."\r
-\r
-\r
-STRING_CHCP_HELP,   "Zeigt die aktuelle Codepage oder wechselt sie.\n\n\\r
-CHCP [nnn]\n\n\\r
-  nnn   Codepage angeben.\n\n\\r
-Der Befehl CHCP ohne Parameter zeigt die Nummer der aktuellen Codepage an."\r
-\r
-\r
-STRING_CHOICE_HELP, "Wartet auf den Benutzer, welcher aus einer Auswahl eine Option waehlen muss.\n\n\\r
-CHOICE  [/C[:]choices][/N][/S][/T[:]c,nn][text]\n\n\\r
-  /C[:]choices  Die erlaubten Tasten festlegen. Standard-Tasten sind Y und N.\n\\r
-  /N            Zeigt choices und ? am ende des Promt-Strings NICHT an.\n\\r
-  /S            Gross- und Kleinschreibung wird beachtet.\n\\r
-  /T[:]c,nn     Standard-Auswahl wird auf c gesetzt nach nn Secunden.\n\\r
-  text          Zeigt eine Beschreibung an.\n\n\\r
-ERRORLEVEL wird auf den offset der Taste welche der Benutzer gedrueckt hat gesetzt."\r
-\r
-STRING_CLS_HELP, "Loescht den Bildschirminhalt.\n\nCLS"\r
-\r
-STRING_CMD_HELP1, "\nIntere Befehle verfuegbar:\n"\r
-\r
-STRING_CMD_HELP2, "\nVerfuegbare Features:"\r
-\r
-STRING_CMD_HELP3,"  [aliases]"\r
-\r
-STRING_CMD_HELP4,"  [history]"\r
-\r
-STRING_CMD_HELP5,"  [unix filename completion]"\r
-\r
-STRING_CMD_HELP6,"  [directory stack]"\r
-\r
-STRING_CMD_HELP7,"  [redirections and piping]"\r
-\r
-STRING_CMD_HELP8, "Startet eine neue Instanz des ReactOS-Befehlsinterpreters.\n\n\\r
-CMD [/[C|K] command][/P][/Q][/T:bf]\n\n\\r
-  /C command  Fuehrt den Befehl in der Zeichenfolge aus und schliesst sich.\n\\r
-  /K command  Fuehrt den Befehl in der Zeichenfolge aus und laeuft weiter.\n\\r
-  /P          CMD wird permanent und fuehrt autoexec.bat aus\n\\r
-              (kann nicht beendet werden).\n\\r
-  /T:bf       Setzt die Hintergrund-/Vordergrund-Farbe (siehe COLOR Befehl)."\r
-\r
-\r
-STRING_COLOR_HELP1, "Legt die standard Hinter- und Vordergrundfarben fuer die Konsole fest.\n\n\\r
-COLOR [attr [/F]] \n\n\\r
-  attr        Gibt die Farbattribute fuer die Konsolenausgabe an.\n\\r
-  /F          fuellte die Konsoleausgabe mit dem Farbattribut\n\n\\r
-Es gibt 3 Moeglickeiten die Farbe festzulegen:\n\\r
-1) [bright] name on [bright] name  (Nur die 4 ersten Buchstaben sind noetig)\n\\r
-2) decimal on decimal\n\\r
-3) two hex digits\n\n\\r
-Farben:\n\\r
-dec  hex  name       dec  hex  name\n\\r
-0    0    Black       8   8    Gray (Bright black)\n\\r
-1    1    Blue        9   9    Bright Blue\n\\r
-2    2    Green      10   A    Bright Green\n\\r
-3    3    Cyan       11   B    Bright Cyan\n\\r
-4    4    Red        12   C    Bright Red\n\\r
-5    5    Magenta    13   D    Bright Magenta\n\\r
-6    6    Yellow     14   E    Bright Yellow\n\\r
-7    7    White      15   F    Bright White"\r
-\r
-STRING_COPY_HELP1,  " %s ueberschreiben (Ja/Nein/Alle)? "\r
-\r
-STRING_COPY_HELP2, "Kopiert eine oder mehrere Dateien an eine andere Position.\n\n\\r
-COPY [/V][/Y|/-Y][/A|/B] Quelle [/A|/B]\n\\r
-     [+ source [/A|/B] [+ ...]] [destination [/A|/B]]\n\n\\r
-  source       Bezeichnet die zu kopierende(n) Datei(en).\n\\r
-  /A           Weist auf eine ASCII-Textdatei hin.\n\\r
-  /B           Weist auf eine Binaerdatei hin.\n\\r
-  destination  Bezeichnet das Verzeichnis und/oder Dateinamen der neuen Datei(en).\n\\r
-  /V           Ueberprueft, ob die Dateien richtig geschrieben wurden.\n\\r
-  /Y           Unterdrueckt die Bestaetigungsaufforderung beim Ueberschreiben\n\\r
-               vorhandener Zieldateien.\n\\r
-  /-Y          Fordert beim Ueberschreiben vorhandener Zieldateien zum\n\\r
-               Bestaetigen auf.\n\n\\r
-Die Option /Y ist moeglicherweise in der Umgebungsvariablen COPYCMD.\n\\r
-..."\r
-\r
-\r
-STRING_DATE_HELP1, "\nGeben Sie das neue Datum ein (mm%cdd%cyyyy): "\r
-\r
-STRING_DATE_HELP2, "\nGeben Sie das neue Datum ein (dd%cmm%cyyyy): "\r
-\r
-STRING_DATE_HELP3, "\nGeben Sie das neue Datum ein (yyyy%cmm%cdd): "\r
-\r
-STRING_DATE_HELP4, "Andert das eingestellte Datum oder zeigt es an.\n\n\\r
-DATE [/T][date]\n\n\\r
-  /T    nur Datum anzeigen\n\n\\r
-Der Befehl DATE ohne Parameter zeigt das aktuelle Datum an und fragt nach\n\\r
-einem neuen. Druecken Sie die EINGABETASTE, um das bisherige Datum zu behalten."\r
-\r
-STRING_DEL_HELP1,  "Loescht eine oder mehrere Dateien.\n\n\\r
-DEL [/N /P /T /Q /W /Y /Z] Dateinamen ...\n\\r
-DELETE [/N /P /T /Q /W /Y /Z] Dateinamen ...\n\\r
-ERASE [/N /P /T /Q /W /Y /Z] Dateinamen ...\n\n\\r
-  file  Geben Sie die Dateinamen an welche Sie loeschen moechten\n\n\\r
-  /N    Nichts.\n\\r
-  /P    Fordert Sie vor dem Loeschen jeder Datei zur Bestaetigung auf.\n\\r
-  /T    Zeigt die Anzahl der geloeschten Dateien und deren vorher belegter Speicherplatzbedarf an.\n\\r
-  /Q    Beenden.\n\\r
-  /W    Sicheres Loeschen. Dateien werden mit Zufallszahlen ueberschrieben bevor sie geloescht werden.\n\\r
-  /Y    Loescht alles (*.*) ohne Vorwarnung.\n\\r
-  /Z    Loescht versteckte, mit nur leserechten und Systemdateien.\n"\r
-\r
-STRING_DEL_HELP2, "Alle Dateien in diesem Verzeichnis werden geloescht!\nSind Sie sicher (Y/N)?"\r
-STRING_DEL_HELP3, "    %lu Datei(en) geloescht\n"\r
-STRING_DEL_HELP4, "    %lu Datei(en) geloescht\n"\r
-\r
-STRING_DELAY_HELP, "Pause fuer n Sekunden oder Millisekunden\n\\r
-DELAY [/m]n\n\n\\r
-  /m          Millisekunden ansonsten Sekunden\n"\r
-\r
-STRING_DIR_HELP1, "Listet die Dateien und Unterverzeichnisse eines Verzeichnisses auf.\n\n\\r
-DIR [Laufwerk:][Pfad][Dateiname] [/A[[:]attributes]] [/B] [/C] [/D] [/L] [/N]\n\\r
-  [/O[[:]sortorder]] [/P] [/Q] [/S] [/T[[:]timefield]] [/W] [/X] [/4]\n\n\\r
-  [Laufwerk:][path][Dateiname]\n\\r
-              Bezeichnet Laufwerk, Verzeichnis und/oder Dateien.\n\n\\r
-  /A          Listet Dateien mit angegebenen Attributen auf.\n\\r
-  attributes   D  Verzeichnisse         R  Schreibgeschuetzte Dateien\n\\r
-               H  Versteckte Dateien    A  Zu archivierende Dateien\n\\r
-               S  Systemdateien         -  vorangestellt kehrt die Bedeutung um\n\\r
-  /B          Einfaches Format (keine Kopfdaten, keine Zusammenfassung).\n\\r
-  /C          Zeigt das Tausendertrennzeichen bei Dateigroessen an (Standard-\n\\r
-              einstellung). Verwenden Sie /-C, um das Tausendertrennzeichen\n\\r
-              nicht anzuzeigen.\n\\r
-  /D          Gleich wie Breitformat, jedoch nach Spalten sortiert.\n\\r
-  /L          Verwendet Kleinschreibung.\n\\r
-  /N          Neues, langes Listenformat (Dateinamen auf der rechten Seite).\n\\r
-  /O          Gibt die Liste sortiert aus.\n\\r
-  sortorder    N  Name (alphabetisch)         S  Groesse (kleinere zuerst)\n\\r
-               E  Erweiterung (alphabetisch)  D Datum/Zeit (aeltere zuerst)\n\\r
-               G  Verzeichnisse zuerst        - vorangestellt kehrt die\n\\r
-  /P          Pausiert nach jeder vollen Bildschirmseite.\n\\r
-  /Q          Gibt den Besitzer der Datei aus.\n\\r
-  /S          Listet Dateien und alle Unterverzeichnisse auf.\n\\r
-  /T          Bestimmt welche Zeit verwendet wird.\n\\r
-  timefield   C  Erstellung\n\\r
-              A  Letzter Zugriff\n\\r
-              W  Letzter Schreibzugriff\n\\r
-  /W          Verwendet Breitformat fuer die Auflistung.\n\\r
-  /X          Zeigt die Kurznamen fuer Dateien mit Nicht-8Punkt3-Namen an.\n\\r
-              Das Format ist das gleiche wie bei /N, wobei der Kurzname vor\n\\r
-              dem Langnamen eingefuegt wird. Wenn kein Kurzname vorhanden ist,\n\\r
-              werden Leerzeichen angezeigt.\n\\r
-  /4          Zeigt das Jahr vierstellig an.\n\n\\r
-Optionen koennen in der Umgebungsvariablen DIRCMD voreingestellt werden.\n\\r
-""-"" vor einer Option setzt die Voreinstellung ausser Kraft, z.B. DIR /-W."\r
-\r
-\r
-\r
-STRING_DIR_HELP2, " Datentraeger in Laufwerk %c ist %s\n"\r
-STRING_DIR_HELP3, " Datentraeger in Laufwerk %c hat keinen Namen\n"\r
-STRING_DIR_HELP4, " Datentraeger-Seriennummer ist %04X-%04X\n"\r
-STRING_DIR_HELP5, "\n     Gelistete Dateien:\n%16i Datei(en)% 14s bytes\n"\r
-STRING_DIR_HELP6, "%16i Verzeichnis(se)% 15s bytes\n"\r
-STRING_DIR_HELP7, "\n Verzeichnisse %s\n\n"\r
-STRING_DIR_HELP8, "%16i Datei(en)% 14s bytes\n"\r
-\r
-STRING_DIRSTACK_HELP1, "Speichert das aktuelle Verzeichnis fuer den POPD Befehl, und\n\\r
-wechselt dann zu den festgelegten Verzeichnis.\n\n\\r
-PUSHD [path | ..]\n\n\\r
-  path        Legt den Verzeichnis fest su dem gewechselt werden soll"\r
-\r
-STRING_DIRSTACK_HELP2, "Wechselt zu dem Verzeichnis welches vom PUSHD Befehl gespeichert wurde.\n\nPOPD"\r
-\r
-STRING_DIRSTACK_HELP3, "Druckt den Inhalt des Verzeichnis-Stacks.\n\nDIRS"\r
-\r
-STRING_DIRSTACK_HELP4, "Verzeichnis-Stack ist leer"\r
-\r
-STRING_ECHO_HELP1,  "Sendet eine Nachricht ohne den Zeilenvorschub und Wagenruecklauf zu betaetigen.\n\n\\r
-  ECHOS message"\r
-\r
-STRING_ECHO_HELP2,  "Sendet eine Nachricht zur Standard Fehlerausgabe.\n\n\\r
-  ECHOERR Nachricht\n\\r
-  ECHOERR.           gibt eine Leerzeile aus"\r
-\r
-STRING_ECHO_HELP3, "Sendet eine Nachricht zur Standard Fehlerausgabe ohne den Zeilenvorschub und Wagenruecklauf zu betaetigen.\n\n\\r
-  ECHOSERR Nachricht"\r
-\r
-STRING_ECHO_HELP4, "Zeigt Meldungen an oder schaltet die Befehlsanzeige ein ""ON"" oder aus ""OFF"".\n\n\\r
-  ECHO [ON | OFF]\n\\r
-  ECHO [Nachricht]\n\\r
-  ECHO.             gibt eine Leerzeile aus\n\n\\r
-ECHO ohne Parameter zeigt die aktuelle Einstellung der Befehlsanzeige an."\r
-\r
-STRING_ECHO_HELP5, "ECHO ist %s\n"\r
-\r
-STRING_EXIT_HELP, "Beendet den Befehlsinterpreter CMD.EXE oder die aktuelle Batchdatei.\n\nEXIT"\r
-\r
-STRING_FOR_HELP1, "Fuehrt einen Befehl fuer jede einzelne Datei fuer einen Satz von Dateien aus.\n\n\\r
-FOR %Variable IN (Satz) DO Befehl [Parameter]\n\n\\r
-  %variable  Ein ersetzbarer Parameter bestehend aus einem einzelnen\n\\r
-              Buchstaben.\n\\r
-  (Satz)     Ein Satz von mindestens einer Datei. Platzhalter sind zulaessig.\n\\r
-  Befehl    Befehl, der fuer jede Datei ausgefuehrt werden soll.\n\\r
-  Parameter Parameter und Optionen fuer den angegebenen Befehl.\n\n\\r
-Um den FOR-Befehl in einem Batchprogramm zu verwenden, geben Sie %%Variable\n\\r
-statt %Variable an."\r
-\r
-STRING_FREE_HELP1, "\nVolume in Laufwerk %s ist %-11s\n\\r
- Volume-Seriennummer: %s\n\\r
-  %16s bytes Speicherkapazitaet\n\\r
-  %16s bytes belegter Speicher\n\\r
-  %16s bytes freier Speicher\n"\r
-\r
-STRING_FREE_HELP2, "Zeigt die Volumesinformationen an.\n\nFREE [Laufwerk: ...]"\r
-\r
-STRING_IF_HELP1, "Verarbeitet Ausdruecke in einer Batchdatei abhaengig von Bedingungen.\n\n\\r
-  IF [NOT] ERRORLEVEL Nummer Befehl\n\\r
-  IF [NOT] variable1==variable2 Befehl\n\\r
-  IF [NOT] EXIST Dateiname Befehl\n\\r
-  IF [NOT] DEFINED variable Befehl\n\n\\r
-NOT               Befehl wird nur dann ausgefuehrt, wenn die Bedingung nicht\n\\r
-                  erfuellt wird\n\\r
-ERRORLEVEL number Bedingung ist erfuellt, wenn das zuletzt ausgefuehrte\n\\r
-                  Programm einen Code groesser oder gleich der Nummer zurueckgibt.\n\\r
-command           Gibt den Befehl an, der bei erfuellter Bedingung ausgefuehrt\n\\r
-                  werden soll.\n\\r
-variable1==variable2\n\\r
-                  Bedingung ist erfuellt, falls die Zeichenfolgen gleich sind.\n\\r
-EXIST Dateiname   Bedingung ist erfuellt, wenn die angegebene Datei existiert.\n\\r
-DEFINED variable  Bedingung ist erfuellt, wenn die angegebene Datei definiert\n\\r
-                  wurde."\r
-\r
-STRING_GOTO_HELP1,  "Setzt die Ausfuehrung eines Batchprogramms an einer Marke fort.\n\n\\r
-GOTO Marke\n\n\\r
-  Marke  Definiert eine Zeichenfolge als Marke in einem Batchprogramm.\n\n\\r
-Marken stehen am Zeilenanfang mit einem vorangestellten Doppelpunkt."\r
-\r
-STRING_LABEL_HELP1, "Erstellt, aendert oder loescht die Bezeichnung eines Volumes.\n\nLABEL [Laufwerk:][label]"\r
-\r
-STRING_LABEL_HELP2, "Datentraeger im Laufwerk %c: ist %s\n"\r
-STRING_LABEL_HELP3, "Datentraeger im Laufwerk %c: hat keine Bezeichnung\n"\r
-STRING_LABEL_HELP4, "Datentraeger-Seriennummer: %04X-%04X\n"\r
-STRING_LABEL_HELP5, "Laufwerkbezeichnung (max. 11 Zeichen, ENTER fuer keine)? "\r
-\r
-STRING_LOCALE_HELP1, "Aktuelle Zeit: "\r
-\r
-STRING_MKDIR_HELP,   "Erzeugt ein Verzeichnis.\n\n\\r
-MKDIR [Laufwerk:]Pfad\nMD [Laufwerk:]Pfad"\r
-\r
-STRING_MEMMORY_HELP1, "Zeigt die groesse des Systemspeicher an.\n\nMEMORY"\r
-\r
-STRING_MEMMORY_HELP2, "\n  %12s%% Speicher geladen.\n\n\\r
-  %13s bytes RAM (insgesamt)\n\\r
-  %13s bytes verfuegbarer RAM\n\n\\r
-  %13s bytes Auslagerungsdatei (insgesamt)\n\\r
-  %13s bytes verfuegbare Auslagerungsdatei\n\n\\r
-  %13s bytes Virtueller Speicher (insgesamt)\n\\r
-  %13s bytes verfuegbarer Virtueller Speicher\n"\r
-\r
-STRING_MISC_HELP1, "Druecken Sie eine beliebige Taste . . .\n"\r
-\r
-STRING_MOVE_HELP1, "Ueberschreiben %s (Ja/Nein/Alle)? "\r
-\r
-STRING_MOVE_HELP2, "Verschiebt Dateien und benennt Dateien und Verzeichnisse um.\n\n\\r
-Um eine oder mehrere Dateien zu verschieben:\n\\r
-MOVE [/N][Laufwerk:][Pfad]Dateiname1[,...] Ziel\n\n\\r
-Um ein Verzeichnis umzubenennen:\n\\r
-MOVE [/N][Laufwerk:][Pfad]Verzeichnis1 Verzeichnis2\n\n\\r
-  [Laufwerk:][Pfad]Datei1  Bezeichnet den Pfad und den Namen der zu\n\\r
-                           verschiebenden Datei(en).\n\\r
-  /N                 Nichts. Tut alles ausser Dateien/Verzeichnisse verschieben.\n\n\\r
-Derzeitige Einschraenkung:\n\\r
-Es ist noch nicht moeglich Objekte ueber die Laufwerksgrenzen hinaus zu verschieben.\n"\r
-\r
-STRING_MSGBOX_HELP, "Zeigt ein Fenster und wartet auf eine Eingabe vom Benutzer.\n\n\\r
-MSGBOX type ['title'] prompt\n\n\\r
-type          Button anzeigen\n\\r
-              moegliche Werte sind: OK, OKCANCEL,\n\\r
-              YESNO, YESNOCANCEL\n\\r
-title         Titel des Fensters\n\\r
-prompt        Text der in dem Fenster angezeigt wird\n\n\n\\r
-ERRORLEVEL is set according the button pressed:\n\n\\r
-YES  :  10    |  NO      :  11\n\\r
-OK   :  10    |  CANCEL  :  12\n"\r
-\r
-STRING_PATH_HELP1, "Legt den Suchpfad fuer ausfuehrbare Dateien fest oder zeigt diesen an.\n\n\\r
-PATH [[Laufwerk:]Pfad[;...]]\nPATH ;\n\n\\r
-  PATH ;    Loescht den Suchpfad und laesst CMD.EXE nur in dem aktuellen\n\\r
-            Verzeichnis suchen.\n\\r
-  PATH      Ohne Parameter zeigt den aktuellen Pfad an.\n"\r
-\r
-STRING_PROMPT_HELP1, "Aendert die Eingabeaufforderung.\n\n\\r
-PROMPT [Text]\n\n\\r
-  Text    Bezeichnet die neue Eingabeaufforderung.\n\n\\r
-Sie kann aus normalen Zeichen und folgenden Sonderzeichen bestehen:\n\n\\r
-  $A   & (Kaufmaennisches Und)\n\\r
-  $B   | (Verkettungszeichen oder pipe)\n\\r
-  $C   ( (Klammer auf)\n\\r
-  $D   Aktuelles Datum\n\\r
-  $E   Escapezeichen (ASCII-Code 27)\n\\r
-  $F   ) (Klammer zu)\n\\r
-  $G   > (Groesser-als-Zeichen)\n\\r
-  $H   Rueckschritt (loescht vorangehendes Zeichen)\n\\r
-  $L   < (Kleiner-als-Zeichen)\n\\r
-  $N   Aktuelles Laufwerk\n\\r
-  $P   Aktuelles Laufwerk und Pfad\n\\r
-  $Q   = (Gleichheitszeichen)\n\\r
-  $T   Aktuelle Zeit\n\\r
-  $V   Betriebssystem-Versionsnummer\n\\r
-  $_   Carriage return and linefeed\n\\r
-  $$   $ (Dollarzeichen)"\r
-\r
-STRING_PAUSE_HELP1, "Haelt die Ausfuehrung einer Batchdatei an und zeigt folgende Meldung oder eine benutzerdefinierte Nachricht an:\n\\r
-'Druecken Sie eine beliebige Taste . . .'.\n\n\\r
-PAUSE [message]"\r
-\r
-STRING_PROMPT_HELP2, "  $+   Zeigt die aktuelle Tiefe des Verzeichnis-Stacks an"\r
-\r
-STRING_PROMPT_HELP3, "\n  'PROMPT'   setzt die Prompt auf die Standardwerte zurueck."\r
-\r
-STRING_REM_HELP, "Leitet Kommentare in einer Batchdatei ein.\n\nREM [Kommentar]"\r
-\r
-STRING_RMDIR_HELP,   "Loescht ein Verzeichnis.\n\n\\r
-RMDIR [Laufwerk:]Pfad\nRD [Laufwerk:]Pfad"\r
-\r
-STRING_REN_HELP1, "Benennt Datei(en)/Verzeichnis(se) um.\n\n\\r
-RENAME [/E /N /P /Q /S /T] alter_Name ... neuer_Name\n\\r
-REN [/E /N /P /Q /S /T] alter_Name ... neuer_Name\n\n\\r
-  /E    keine Fehlermeldung.\n\\r
-  /N    Nichts.\n\\r
-  /P    Wartet vor jedem Umbennen-Vorgang auf eine Benutzereingabe\n\\r
-        (Noch nicht implementiert!)\n\\r
-  /Q    Beenden.\n\\r
-  /S    benennt Unterverzeichnisse um.\n\\r
-  /T    Zeigt die Anzahl der umbenannten Dateien an.\n\n\\r
-Nutzen Sie den 'move' Befehl falls Sie Objekte verschieben wollen.\n"\r
-\r
-STRING_REN_HELP2, "    %lu Datei umbennant\n"\r
-\r
-STRING_REN_HELP3, "    %lu Dateien umbennant\n"\r
-\r
-STRING_SHIFT_HELP, "Veraendert die Position ersetzbarer Parameter in einem Batchprogramm.\n\n\\r
-SHIFT [DOWN]"\r
-\r
-STRING_SCREEN_HELP, "Bewegt den Cursor und optional die Ausgabe\n\n\\r
-SCREEN Reihe Spalte [Text]\n\n\\r
-  Reihe         Reihe wohin der Curser bewegt werden soll\n\\r
-  Spalte        Spalte wohin der Curser bewegt werden soll"\r
-\r
-STRING_SET_HELP, "Setzt oder loescht Umgebungsvariablen fuer CMD.EXE, oder zeigt sie an.\n\n\\r
-SET [variable[=][Zeichenfolge]]\n\n\\r
-  Variable     Bezeichnet den Namen der Umgebungsvariablen.\n\\r
-  Zeichenfolge Eine Zeichenfolge, die der Variable zugewiesen werden soll.\n\n\\r
-Der Befehl SET ohne Parameter zeigt die aktuellen Umgebungsvariablen an.\n"\r
-\r
-STRING_START_HELP1, "Startet einen Befehl.\n\n\\r
-START Befehl\n\n\\r
-  Befehl     Befehl welcher ausgefuehrt werden soll\n\n\\r
-Achtung: Derzeit werden alle Befehle asynchron ausgefuehrt.\n"\r
-\r
-STRING_TITLE_HELP, "Legt den Fenstertitel fuer das Eingabeaufforderungsfenster fest.\n\n\\r
-TITLE [string]\n\n\\r
-  Zeichenfolge      Bezeichnet den Titel des Eingabeaufforderungsfensters."\r
-\r
-STRING_TIME_HELP1, "Stellt die Systemzeit oder zeigt sie an.\n\n\\r
-TIME [/T][Zeit]\n\n\\r
-  /T    nur anzeigen\n\n\\r
-TIME ohne Parameter zeigt die aktuelle Systemzeit an und fragt nach der neuen\n\\r
-Uhrzeit. Druecken Sie die EINGABETASTE, um die bisherige Zeit beizubehalten."\r
-\r
-STRING_TIME_HELP2, "Geben Sie eine neue Zeit ein: "\r
-\r
-STRING_TIMER_HELP1, "Verstrichene %d Millisekunden\n"\r
-\r
-STRING_TIMER_HELP2, "Verstrichene %02d%c%02d%c%02d%c%02d\n"\r
-\r
-STRING_TIMER_HELP3, "Erlaubt die Benutzung von 10 Stopuhren.\n\n\\r
-TIMER  [ON|OFF] [/S] [/n] [/Fn]\n\n\\r
-  ON          schaltet die Stopuhr ein\n\\r
-  OFF         schaltet die Stopuhr aus\n\\r
-  /S          Split time. Return stopwatch split\n\\r
-              time without changing its value\n\\r
-  /n          Anzahl der Stopuhren\n\\r
-              gueltige Stopuhren sind 0 bis 9\n\\r
-              Standardwert = 1\n\\r
-  /Fn         Ausgabeformatierung\n\\r
-              n kann 0 oder 1 sein:\n\\r
-                    0    Millisekunden\n\\r
-                    1    hh%cmm%css%cdd\n\n\\r
-Falls nicht ON, OFF oder /S angegeben wurde wird\n\\r
-die Stopuhr ausgeschalten.\n\n"\r
-\r
-STRING_TYPE_HELP1, "Zeigt den Inhalt einer oder mehrerer Textdateien an.\n\n\\r
-TYPE [Laufwerk:][Pfad]Dateiname"\r
-\r
-STRING_VERIFY_HELP1, "This command is just a dummy!!\n\\r
-Legt fest, ob ueberwacht werden soll, ob Dateien korrekt auf den Datentraeger\n\\r
-geschrieben werden.\n\n\\r
-VERIFY [ON | OFF]\n\n\\r
-Der Befehl VERIFY ohne Parameter zeigt die aktuelle Einstellung von VERIFY an."\r
-\r
-STRING_VERIFY_HELP2, "VERIFY ist %s.\n"\r
-\r
-STRING_VERIFY_HELP3, "VERIFY kann nur ON oder OFF sein"\r
-\r
-STRING_VERSION_HELP1, "Zeigt Shell Informationen an.\n\n\\r
-VER [/C][/R][/W]\n\n\\r
-  /C  Zeigt die Credits an.\n\\r
-  /R  Zeigt die Redistribution Information an.\n\\r
-  /W  Zeigt die Garantieerklaerung an."\r
-\r
-STRING_VERSION_HELP2, " kommt mit absolut keiner Garantie; fuer naehere\n\\r
- Informationen darueber tippen Sie: `ver /w'. Das ist eine freie Software,\n\\r
- und Sie sind koennen die Software unter bestimmten Bedingungen weiter\n\\r
- vertreiben; tippen Sie `ver /r' fuer naehere Informationen darueber.\n\\r
- Tippen Sie `ver /c' um die Mitwirkenden (Credits) aufzulisten."\r
-\r
-STRING_VERSION_HELP3, "\n This program is distributed in the hope that it will be useful,\n\\r
- but WITHOUT ANY WARRANTY; without even the implied warranty of\n\\r
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n\\r
- GNU General Public License for more details."\r
-\r
-STRING_VERSION_HELP4, "\n This program is free software; you can redistribute it and/or modify\n\\r
- it under the terms of the GNU General Public License as published by\n\\r
- the Free Software Foundation; either version 2 of the License, or\n\\r
- (at your option) any later version."\r
-\r
-STRING_VERSION_HELP5, "\nSenden Sie Bug-Reports an <ros-dev@reactos.org>.\n\\r
-Updates sind auf der offiziellen ReactOS-Seite verfuegbar:\n\\r
-http://www.reactos.org"\r
-\r
-STRING_VERSION_HELP6, "\nFreeDOS Version programmiert von:\n"\r
-\r
-STRING_VERSION_HELP7, "\nReactOS Version programmiert von:\n"\r
-\r
-STRING_VOL_HELP1, " Datentraeger im Laufwerk %c: ist %s"\r
-STRING_VOL_HELP2, " Datentraeger im Laufwerk %c: hat keine Bezeichnung"\r
-STRING_VOL_HELP3, " Datentraeger-Seriennummer: %04X-%04X\n"\r
-STRING_VOL_HELP4, "Zeigt die Laufwerksvolumebezeichnung und die Seriennummer an, falls diese existieren.\n\nVOL [drive:]"\r
-\r
-STRING_WINDOW_HELP1, "change console window aspect\n\n\\r
-WINDOW [/POS[=]left,top,width,heigth]\n\\r
-              [MIN|MAX|RESTORE] ['title']\n\n\\r
-/POS          Gibt Position und Größe des Fenster an\n\\r
-MIN           minimieren das Fenster\n\\r
-MAX           maximieren das Fenster\n\\r
-RESTORE       stellt das Fenster wieder her"\r
-\r
-STRING_WINDOW_HELP2, "change console window aspect\n\n\\r
-ACTIVATE 'window' [/POS[=]left,top,width,heigth]\n\\r
-              [MIN|MAX|RESTORE] ['title']\n\n\\r
-window        tile of window on wich perform actions\n\\r
-/POS          specify window placement and dimensions\n\\r
-MIN           minimieren das Fenster\n\\r
-MAX           maximieren das Fenster\n\\r
-RESTORE       stellt das Fenster wieder her\n\\r
-title         neuer Titel"\r
-\r
-\r
-STRING_HELP1, "Uebersicht aller verfuegbaren Befehle und deren Kurzbeschreibung\n\n\\r
-  Befehl /?     Um naehere Informationen zu einem bestimmten Befehl\n\\r
-                zu erhalten.\n\n\\r
-?        Listet alle Befehle auf (ohne Erklarung).\n\\r
-ALIAS    Setzt, loescht oder zeigt den Alias.\n\\r
-ATTRIB   Zeigt Dateiattribute an bzw. aendert sie.\n\\r
-BEEP     Gibt einen beep-Ton durch den PC-Speaker aus.\n\\r
-CALL     Ruft eine Batchdatei aus einer anderen Batchdatei heraus auf.\n\\r
-CD       Zeigt den Namen des aktuellen Verzeichnisses an bzw. aendert diesen.\n\\r
-CHCP     Zeigt die aktive Codepagenummer an bzw. legt diese fest.\n\\r
-CHOICE   Wartet auf den Benutzer, welcher aus einer Auswahl eine Option\n\\r
-         waehlen muss.\n\\r
-CLS      Loescht den Bildschirminhalt.\n\\r
-CMD      Startet eine neue Instanz des ReactOS-Befehlsinterpreters.\n\\r
-COLOR    Legt die Hintergrund- und Vordergrundfarben fuer die Konsole fest.\n\\r
-COPY     Kopiert eine oder mehrere Dateien an eine andere Stelle.\n\\r
-DATE     Zeigt das Datum an bzw. legt dieses fest.\n\\r
-DELETE   Loescht eine oder mehrere Dateien.\n\\r
-DIR      Listet die Dateien und Unterverzeichnisse eines Verzeichnisses auf.\n\\r
-ECHO     Zeigt Meldungen an bzw. schaltet die Befehlsanzeige ein oder aus.\n\\r
-ERASE    Loescht eine oder mehrere Dateien.\n\\r
-EXIT     Beendet das Programm CMD.EXE (Befehlsinterpreter).\n\\r
-FOR      Fuehrt einen angegebenen Befehl fuer jede Datei in einem Dateiensatz\n\\r
-         aus.\n\\r
-FREE     Zeigt den (freien) Speicherplatz an.\n\\r
-GOTO     Setzt den ReactOS-Befehlsinterpreter auf eine markierte Zeile in\n\\r
-         einem Batchprogramm.\n\\r
-HELP     Zeigt Hilfeinformationen zu ReactOS-Befehlen an.\n\\r
-HISTORY  Listet alle Befehle auf welche sich im Speicher befinden.\n\\r
-IF       Verarbeitet Ausdruecke in einer Batchdatei abhaengig von Bedingungen.\n\\r
-LABEL    Erstellt, aendert oder loescht die Bezeichnung eines Volumes.\n\\r
-MD       Erstellt ein Verzeichnis\n\\r
-MKDIR    Erstellt ein Verzeichnis.\n\\r
-MOVE     Verschiebt ein oder mehrere Dateien von einem Verzeichnis in\n\\r
-         ein anderes.\n\\r
-PATH     Legt den Suchpfad fuer ausfuehrbare Dateien fest oder zeigt diesen an.\n\\r
-PAUSE    Haelt die Ausfuehrung einer Batchdatei an und zeigt eine Meldung an.\n\\r
-POPD     Wechselt zu dem Verzeichnis, das durch PUSHD gespeichert wurde.\n\\r
-PROMPT   Aendert die Eingabeaufforderung.\n\\r
-PUSHD    Speichert das aktuelle Verzeichnis, und wechselt dann zu einem\n\\r
-         anderen Verzeichnis.\n\\r
-RD       Entfernt ein Verzeichnis.\n\\r
-REM      Leitet Kommentare in einer Batchdatei.\n\\r
-REN      Benennt eine Datei bzw. Dateien um.\n\\r
-RENAME   Bennent eine Datei bzw. Dateien um.\n\\r
-RMDIR    Loescht ein Verzeichnis.\n\\r
-SCREEN   Bewegt den Cursor und optional die Ausgabe.\n\\r
-SET      Setzt oder loescht die Umgebungsvariablen bzw. zeigt sie an.\n\\r
-SHIFT    Veraendert die Position ersetzbarer Parameter in Batchdateien.\n"\r
-STRING_HELP2, "START    Startet ein eigenes Fenster, um ein bestimmtes Programm oder einen\n\\r
-         Befehl auszufuehren.\n\\r
-TIME     Zeigt die Systemzeit an bzw. legt sie fest.\n\\r
-TIMER    Erlaubt die Benutzung von bis zu 10 Stopuhren\n\\r
-TITLE    Legt den Fenstertitel fuer das Eingabeaufforderungsfenster fest.\n\\r
-TYPE     Zeigt den Inhalt einer Textdatei an.\n\\r
-VER      Zeigt die ReactOS-Version an.\n\\r
-VERIFY   Legt fest, ob ueberwacht werden soll, ob Dateien korrekt auf den\n\\r
-         Datentraeger geschrieben werden.\n\\r
-VOL      Zeigt die Datentraegervolumebezeichnung und die Seriennummer an.\n"\r
-\r
-\r
-STRING_CHOICE_OPTION,         "JN"\r
-STRING_COPY_OPTION,           "JNA"\r
-\r
-\r
-STRING_ALIAS_ERROR,          "Die Befehlszeile ist zu lange nach der Alias-Erweiterung!\n"\r
-STRING_BATCH_ERROR,          "Es trat ein Fehler auf, waehrend die batch-Datei geoeffnet wurde.\n"\r
-STRING_CHCP_ERROR1,          "Aktive Code-Page: %u\n"\r
-STRING_CHCP_ERROR4,          "ungueltige Code-Page\n"\r
-STRING_CHOICE_ERROR,         "Ungueltige Option. Erwartetes Format: /C[:]options"\r
-STRING_CHOICE_ERROR_TXT,     "Ungueltige Option. Erwartetes Format: /T[:]c,nn"\r
-STRING_CHOICE_ERROR_OPTION,  "Ungueltige Option: %s"\r
-STRING_MD_ERROR,             "Unterverzeichnis oder Datei existiert bereits.\n"\r
-STRING_CMD_ERROR1,           "Die Eingaben konnten nicht umgeleitet werden (von der Datei) %s\n"\r
-STRING_CMD_ERROR2,           "Ein Fehler ist beim Erstellen der temponaeren Date für Pipedaten aufgetreten\n"\r
-STRING_CMD_ERROR3,           "%s kann nicht in die Datei umgeleitet werden \n"\r
-STRING_CMD_ERROR4,           "Running %s...\n"\r
-STRING_CMD_ERROR5,           "Running cmdexit.bat...\n"\r
-STRING_COLOR_ERROR1,         "Fehler: Hinter- und Vordergrund koennen nicht die selben Farben haben!"\r
-STRING_COLOR_ERROR2,         "Fehler in der Farb-Angabe"\r
-STRING_COLOR_ERROR3,         "Farbe %x\n"\r
-STRING_COLOR_ERROR4,         "Fehler: Die selben Farben!"\r
-STRING_CONSOLE_ERROR,        "Unbekannter Fehler: %d\n"\r
-STRING_COPY_ERROR1,          "Fehler: Quelle kann nicht geoeffnet werden - %s!\n"\r
-STRING_COPY_ERROR2,          "Fehler: Kann nicht ueber sich selbst kopiert werden.\n"\r
-STRING_COPY_ERROR3,          "Fehler Schreibziel!\n"\r
-STRING_COPY_ERROR4,          "Fehler: Noch nicht implementiert!\n"\r
-STRING_DATE_ERROR,           "Ungueltiges Datum."\r
-STRING_DEL_ERROR5,           "Die Datei %s wird geloescht! "\r
-STRING_DEL_ERROR6,           "Sind Sie sicher (J/N)?"\r
-STRING_DEL_ERROR7,           "Loeschen: %s\n"\r
-STRING_ERROR_ERROR1,         "Unbekannter Fehler! Fehlernummer: 0x%lx\n"\r
-STRING_ERROR_ERROR2,         "Syntax-Fehler"\r
-STRING_FOR_ERROR1,           "'in' fehlt fuer ein statement."\r
-STRING_FOR_ERROR2,           "Klammern nicht gefunden."\r
-STRING_FOR_ERROR3,           "'do' fehlt."\r
-STRING_FOR_ERROR4,           "kein Befehl nach 'do'."\r
-STRING_FREE_ERROR1,          "Ungueltiges Laufwerk"\r
-STRING_FREE_ERROR2,          "keine Bezeichnung"\r
-STRING_GOTO_ERROR1,          "Keine Sprungmarke fuer GOTO gesetzt"\r
-STRING_GOTO_ERROR2,          "Sprungmarke '%s' wurde nicht gefunden\n"\r
-\r
-STRING_MOVE_ERROR1,          "[OK]\n"\r
-STRING_MOVE_ERROR2,          "[FEHLER]\n"\r
-\r
-STRING_REN_ERROR1,           "MoveFile() ist fehlgeschlagen. Fehler: %lu\n"\r
-\r
-STRING_START_ERROR1,         "No batch support at the moment!"\r
-\r
-STRING_TIME_ERROR1,          "Ungueltige Zeit."\r
-\r
-STRING_TYPE_ERROR1,          "Ungueltige Option '/%s'\n"\r
-\r
-STRING_WINDOW_ERROR1,        "Fenster nicht gefunden"\r
-\r
-\r
-STRING_ERROR_PARAMETERF_ERROR,     "Parameterformat ist nicht korrect - %c\n"\r
-STRING_ERROR_INVALID_SWITCH,       "Ungueltiger Parameter - /%c\n"\r
-STRING_ERROR_TOO_MANY_PARAMETERS,  "Zu viele Parameters - %s\n"\r
-STRING_ERROR_PATH_NOT_FOUND,       "Pfad wurde nicht gefunden\n"\r
-STRING_ERROR_FILE_NOT_FOUND,       "Datei wurde nicht gefunden\n"\r
-STRING_ERROR_REQ_PARAM_MISSING,    "Benoetigter Parameter fehlt\n"\r
-STRING_ERROR_INVALID_DRIVE,        "Ungueltige Laufwerksangaben\n"\r
-STRING_ERROR_INVALID_PARAM_FORMAT, "Ungueltiges Parameterformat - %s\n"\r
-STRING_ERROR_BADCOMMAND,           "Ungueltiger Befehl oder Dateiname\n"\r
-STRING_ERROR_OUT_OF_MEMORY,        "Fehler: Zu wenig Speicher verfuegbar.\n"\r
-STRING_ERROR_CANNOTPIPE,           "Error!  Cannot pipe!  Cannot open temporary file!\n"\r
-STRING_ERROR_D_PAUSEMSG,           "Druecken Sie eine beliebige Taste . . ."\r
-STRING_ERROR_DRIVER_NOT_READY,     "Laufwerk ist nicht bereit"\r
-\r
-STRING_PATH_ERROR,                 "CMD: Not in environment '%s'\n"\r
-\r
-STRING_CMD_SHELLINFO,              "\nReactOS Befehlszeilen Interpreter"\r
-STRING_VERSION_RUNVER,             " laeuft in %s"\r
-STRING_COPY_FILE ,                 "        %d Datei(en) kopiert\n"\r
-STRING_DELETE_WIPE,                "wiped"\r
-STRING_FOR_ERROR,                  "ungueltige Variablenangabe."\r
-STRING_SCREEN_COL,                 "ungueltige Spalten-Angabe"\r
-STRING_SCREEN_ROW,                 "ungueltige Zeilen-Angabe"\r
-STRING_TIMER_TIME                  "Timer %d ist %s: "\r
-}\r
diff --git a/reactos/subsys/system/cmd/En.rc b/reactos/subsys/system/cmd/En.rc
deleted file mode 100644 (file)
index ff9141f..0000000
+++ /dev/null
@@ -1,650 +0,0 @@
-#include "windows.h"
-#include "resource.h"
-/*
- * Moved all hardcoded strings to En.rc.
- * By Magnus Olsen  2005
- */
-
-LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
-STRINGTABLE DISCARDABLE
-{
-
-STRING_ATTRIB_HELP,    "Displays or changes file attributes.\n\n\
-ATTRIB [+R | -R] [+A | -A] [+S | -S] [+H | -H] file ...\n\
-       [/S [/D]]\n\n\
-  +   Sets an attribute\n\
-  -   Clears an attribute\n\
-  R   Read-only file attribute\n\
-  A   Archive file attribute\n\
-  S   System file attribute\n\
-  H   Hidden file attribute\n\
-  /S  Processes matching files in the current directory\n\
-      and all subdirectories\n\
-  /D  Processes directories as well\n\n\
-Type ATTRIB without a parameter to display the attributes of all files.\n"
-
-STRING_ALIAS_HELP,  "Sets, removes or shows aliases.\n\n\
-ALIAS [alias=[command]]\n\n\
-  alias    Name for an alias.\n\
-  command  Text to be substituted for an alias.\n\n\
-To list all aliases:\n\
-  ALIAS\n\n\
-To set a new or replace an existing alias:\n\
-  ALIAS da=dir a:\n\n\
-To remove an alias from the alias list:\n\
-  ALIAS da="
-
-STRING_BEEP_HELP, "Beep the speaker.\n\nBEEP\n"
-
-STRING_CALL_HELP, "Calls one batch program from another.\n\n\
-CALL [drive:][path]filename [batch-parameter]\n\n\
-  batch-parameter  Specifies any command-line information required by the\n\
-                   batch program."
-
-STRING_CD_HELP,      "Changes the current directory or displays it's name\n\n\
-CHDIR [/D][drive:][path]\n\
-CHDIR[..|.]\n\
-CD [/D][drive:][path]\n\
-CD[..|.]\n\n\
-  ..   parent directory\n\
-  .    current directory\n\
-  /D   Will change current drive and current directory.\n\n\
-Type CD drive: to display the current directory on the specified drive.\n\
-Type CD without a parameter to display the current drive and directory.\n"
-
-STRING_CHCP_HELP,   "Displays or sets the active code page number.\n\n\
-CHCP [nnn]\n\n\
-  nnn   Specifies the active code page number.\n\n\
-Type CHCP without a parameter to display the active code page number.\n"
-
-STRING_CHOICE_HELP, "Waits for the user to choose one of a set of choices.\n\n\
-CHOICE  [/C[:]choices][/N][/S][/T[:]c,nn][text]\n\n\
-  /C[:]choices  Specifies allowable keys. Default is YN.\n\
-  /N            Do not display choices and ? at the end of the prompt string.\n\
-  /S            Treat choice keys as case sensitive.\n\
-  /T[:]c,nn     Default choice to c after nn seconds.\n\
-  text          Prompt string to display.\n\n\
-ERRORLEVEL is set to offset of key user presses in choices.\n"
-
-STRING_CLS_HELP, "Clears the screen.\n\nCLS\n"
-
-STRING_CMD_HELP1, "\nInternal commands available:\n"
-
-STRING_CMD_HELP2, "\nFeatures available:"
-
-STRING_CMD_HELP3,"  [aliases]"
-
-STRING_CMD_HELP4,"  [history]"
-
-STRING_CMD_HELP5,"  [unix filename completion]"
-
-STRING_CMD_HELP6,"  [directory stack]"
-
-STRING_CMD_HELP7,"  [redirections and piping]"
-
-STRING_CMD_HELP8, "Starts a new instance of the ReactOS command line interpreter.\n\n\
-CMD [/[C|K] command][/P][/Q][/T:bf]\n\n\
-  /C command  Runs the specified command and terminates.\n\
-  /K command  Runs the specified command and remains.\n\
-  /P          CMD becomes permanent and runs autoexec.bat\n\
-              (cannot be terminated).\n\
-  /T:bf       Sets the background/foreground color (see COLOR command).\n"
-
-STRING_COLOR_HELP1, "Sets the default foreground and background colors.\n\n\
-COLOR [attr [/-F]] \n\n\
-  attr        Specifies color attribute of console output\n\
-  /-F         Does not fill the console blank space with color attribute\n\n\
-There are three ways to specify the colors:\n\
-1) [bright] name on [bright] name  (only the first three letters are required)\n\
-2) decimal on decimal\n\
-3) two hex digits\n\n\
-Colors are:\n\
-dec  hex  name       dec  hex  name\n\
-0    0    Black       8   8    Gray(Bright black)\n\
-1    1    Blue        9   9    Bright Blue\n\
-2    2    Green      10   A    Bright Green\n\
-3    3    Cyan       11   B    Bright Cyan\n\
-4    4    Red        12   C    Bright Red\n\
-5    5    Magenta    13   D    Bright Magenta\n\
-6    6    Yellow     14   E    Bright Yellow\n\
-7    7    White      15   F    Bright White\n"
-
-STRING_COPY_HELP1,  "Overwrite %s (Yes/No/All)? "
-
-STRING_COPY_HELP2, "Copies one or more files to another location.\n\n\
-COPY [/V][/Y|/-Y][/A|/B] source [/A|/B]\n\
-     [+ source [/A|/B] [+ ...]] [destination [/A|/B]]\n\n\
-  source       Specifies the file or files to be copied.\n\
-  /A           Indicates an ASCII text file.\n\
-  /B           Indicates a binary file.\n\
-  destination  Specifies the directory and/or filename for the new file(s).\n\
-  /V           Verifies that new files are written correctly.\n\
-  /Y           Suppresses prompting to confirm you want to overwrite an\n\
-               existing destination file.\n\
-  /-Y          Causes prompting to confirm you want to overwrite an\n\
-               existing destination file.\n\n\
-The switch /Y may be present in the COPYCMD environment variable.\n\
-...\n"
-
-STRING_DATE_HELP1, "\nEnter new date (mm%cdd%cyyyy): "
-
-STRING_DATE_HELP2, "\nEnter new date (dd%cmm%cyyyy): "
-
-STRING_DATE_HELP3, "\nEnter new date (yyyy%cmm%cdd): "
-
-STRING_DATE_HELP4, "Displays or sets the date.\n\n\
-DATE [/T][date]\n\n\
-  /T    display only\n\n\
-Type DATE without parameters to display the current date setting and\n\
-a prompt for a new one.  Press ENTER to keep the same date.\n"
-                               
-STRING_DEL_HELP1,  "Deletes one or more files.\n\n\
-DEL [/N /P /T /Q /S /W /Y /Z /A[[:]attributes]] file ...\n\
-DELETE [/N /P /T /Q /S /W /Y /Z /A[[:]attributes]] file ...\n\
-ERASE [/N /P /T /Q /S /W /Y /Z /A[[:]attributes]] file ...\n\n\
-      file  Specifies the file(s) to delete.\n\n\
-  /N    Nothing.\n\
-  /P    Prompt. Ask before deleting each file.\n\
-  /T    Total. Display total number of deleted files and freed disk space.\n\
-  /Q    Quiet.\n\
-  /W    Wipe. Overwrite the file with random numbers before deleting it.\n\
-  /Y    Yes. Kill even *.* without asking.\n\
-  /F    Force Delete hidden, read-only and system files.\n\
-  /S    Delete file from all sub directory\n\
-  /A    Select files to be deleted based on attributes.\n\
-        attributes\n\
-        R     Read Only files\n\
-        S     System files\n\
-        A     Archiveable files\n\
-        H     Hidden Files\n\
-        -     prefix meaning not\n"
-
-STRING_DEL_HELP2, "All files in the directory will be deleted!\nAre you sure (Y/N)?"
-STRING_DEL_HELP3, "    %lu file deleted\n"
-STRING_DEL_HELP4, "    %lu files deleted\n"
-
-STRING_DELAY_HELP, "pause for n seconds or milliseconds\n\
-DELAY [/m]n\n\n\
-  /m          specifiy than n are milliseconds\n\
-              otherwise n are seconds\n"
-
-STRING_DIR_HELP1, "DIR [drive:][path][filename] [/A[[:]attributes]] [/B] [/C] [/D] [/L] [/N]\n\
-  [/O[[:]sortorder]] [/P] [/Q] [/S] [/T[[:]timefield]] [/W] [/X] [/4]\n\n\
-  [drive:][path][filename]\n\
-              Specifies drive, directory, and/or files to list.\n\n\
-  /A          Displays files with specified attributes.\n\
-  attributes   D  Directories                R  Read-only files\n\
-               H  Hidden files               A  Files ready for archiving\n\
-               S  System files               -  Prefix meaning not\n\
-  /B          Uses bare format (no heading information or summary).\n\
-  /C          Display the thousand separator in file sizes.  This is the\n\
-              default.  Use /-C to disable display of separator.\n\
-  /D          Same as wide but files are list sorted by column.\n\
-  /L          Uses lowercase.\n\
-  /N          New long list format where filenames are on the far right.\n\
-  /O          List by files in sorted order.\n\
-  sortorder    N  By name (alphabetic)       S  By size (smallest first)\n\
-               E  By extension (alphabetic)  D  By date/time (oldest first)\n\
-               G  Group directories first    -  Prefix to reverse order\n\
-  /P          Pauses after each screenful of information.\n\
-  /Q          Display the owner of the file.\n\
-  /S          Displays files in specified directory and all subdirectories.\n\
-  /T          Controls which time field displayed or used for sorting\n\
-  timefield   C  Creation\n\
-              A  Last Access\n\
-              W  Last Written\n\
-  /W          Uses wide list format.\n\
-  /X          This displays the short names generated for non-8dot3 file\n\
-              names.  The format is that of /N with the short name inserted\n\
-              before the long name. If no short name is present, blanks are\n\
-              displayed in its place.\n\
-  /4          Displays four-digit years\n\n\
-Switches may be preset in the DIRCMD environment variable.  Override\n\
-preset switches by prefixing any switch with - (hyphen)--for example, /-W.\n"
-
-STRING_DIR_HELP2, " Volume in drive %c is %s\n"
-STRING_DIR_HELP3, " Volume in drive %c has no label.\n"
-STRING_DIR_HELP4, " Volume Serial Number is %04X-%04X\n"
-STRING_DIR_HELP5, "\n     Total Files Listed:\n%16i File(s)% 14s bytes\n"
-STRING_DIR_HELP6, "%16i Dir(s)% 15s bytes\n"
-STRING_DIR_HELP7, "\n Directory of %s\n\n"
-STRING_DIR_HELP8, "%16i File(s)% 14s bytes\n"
-
-STRING_DIRSTACK_HELP1, "Stores the current directory for use by the POPD command, then\n\
-changes to the specified directory.\n\n\
-PUSHD [path | ..]\n\n\
-  path        Specifies the directory to make the current directory\n"
-
-STRING_DIRSTACK_HELP2, "Changes to the directory stored by the PUSHD command.\n\nPOPD"
-
-STRING_DIRSTACK_HELP3, "Prints the contents of the directory stack.\n\nDIRS"
-
-STRING_DIRSTACK_HELP4, "Directory stack empty"
-
-STRING_ECHO_HELP1,  "Display a messages without trailing carriage return and line feed.\n\n\
-  ECHOS message"
-
-STRING_ECHO_HELP2,  "Displays a message to the standard error output.\n\n\
-  ECHOERR message\n\
-  ECHOERR.           prints an empty line"
-
-STRING_ECHO_HELP3, "Prints a messages to standard error output without trailing carriage return and line feed.\n\n\
-  ECHOSERR message"
-
-STRING_ECHO_HELP4, "Displays a message or switches command echoing on or off.\n\n\
-  ECHO [ON | OFF]\n\
-  ECHO [message]\n\
-  ECHO.             prints an empty line\n\n\
-Type ECHO without a parameter to display the current ECHO setting."
-
-STRING_ECHO_HELP5, "ECHO is %s\n"
-
-STRING_EXIT_HELP, "Exits the command line interpreter.\n\nEXIT\n"
-
-STRING_FOR_HELP1, "Runs a specified command for each file in a set of files\n\n\
-FOR %variable IN (set) DO command [parameters]\n\n\
-  %variable  Specifies a replaceable parameter.\n\
-  (set)      Specifies a set of one or more files. Wildcards may be used.\n\
-  command    Specifies the command to carry out for each file.\n\
-  parameters Specifies parameters or switches for the specified command.\n\n\
-To use the FOR command in a batch program, specify %%variable instead of\n\
-%variable.\n"
-
-STRING_FREE_HELP1, "\nVolume in drive %s is %-11s\n\
- Serial number is %s\n\
-  %16s bytes total disk space\n\
-  %16s bytes used\n\
-  %16s bytes free\n"
-
-STRING_FREE_HELP2, "Displays drive information.\n\nFREE [drive: ...]\n"
-
-STRING_IF_HELP1, "Performs conditional processing in batch programs.\n\n\
-  IF [NOT] ERRORLEVEL number command\n\
-  IF [NOT] string1==string2 command\n\
-  IF [NOT] EXIST filename command\n\
-  IF [NOT] DEFINED variable command\n\n\
-NOT               Specifies that CMD should carry out the command only if\n\
-                  the condition is false\n\
-ERRORLEVEL number Specifies a true condition if the last program run returned\n\
-                  an exit code equal or greater than the number specified.\n\
-command           Specifies the command to carry out if the condition is met.\n\
-string1==string2  Specifies a true condition if the specified text strings\n\
-                  match.\n\
-EXIST filename    Specifies a true condition if the specified filename exists.\n\
-DEFINED variable  Specifies a true condition if the specified variable is\n\
-                  defined.\n"
-
-STRING_GOTO_HELP1,  "Directs CMD to a labeled line in a batch script.\n\n\
-GOTO label\n\n\
-  label  Specifies a text string used in a batch script as a label.\n\n\
-You type a label on a line by itself, beginning with a colon."
-
-STRING_LABEL_HELP1, "Displays or changes drive label.\n\nLABEL [drive:][label]\n"
-
-STRING_LABEL_HELP2, "Volume in drive %c: is %s\n"
-STRING_LABEL_HELP3, "Volume in drive %c: has no label\n"
-STRING_LABEL_HELP4, "Volume Serial Number is %04X-%04X\n"
-STRING_LABEL_HELP5, "Drive label (11 Characters, ENTER if none)? "
-
-STRING_LOCALE_HELP1, "Current time is"
-
-STRING_MKDIR_HELP,   "Creates a directory.\n\n\
-MKDIR [drive:]path\nMD [drive:]path"
-
-STRING_MEMMORY_HELP1, "Displays the amount of system memory.\n\nMEMORY"
-
-STRING_MEMMORY_HELP2, "\n  %12s%% memory load.\n\n\
-  %13s bytes total physical RAM.\n\
-  %13s bytes available physical RAM.\n\n\
-  %13s bytes total page file.\n\
-  %13s bytes available page file.\n\n\
-  %13s bytes total virtual memory.\n\
-  %13s bytes available virtual memory.\n"
-
-STRING_MISC_HELP1, "Press a key to continue...\n"
-
-STRING_MOVE_HELP1, "Overwrite %s (Yes/No/All)? "
-
-STRING_MOVE_HELP2, "Moves files and renames files and directories.\n\n\
-To move one or more files:\n\
-MOVE [/N][drive:][path]filename1[,...] destination\n\n\
-To rename a directory:\n\
-MOVE [/N][drive:][path]dirname1 dirname2\n\n\
-  [drive:][path]filename1  Specifies the location and name of the file\n\
-                           or files you want to move.\n\
-  /N                    Nothing. Do everything but move files or directories.\n\n\
-Current limitations:\n\
-  - You can't move a file or directory from one drive to another.\n"
-
-STRING_MSGBOX_HELP, "display a message box and return user responce\n\n\
-MSGBOX type ['title'] prompt\n\n\
-type          button displayed\n\
-              possible values are: OK, OKCANCEL,\n\
-              YESNO, YESNOCANCEL\n\
-title         title of message box\n\
-prompt        text displayed by the message box\n\n\n\
-ERRORLEVEL is set according the button pressed:\n\n\
-YES  :  10    |  NO      :  11\n\
-OK   :  10    |  CANCEL  :  12\n"
-
-STRING_PATH_HELP1, "Displays or sets a search path for executable files.\n\n\
-PATH [[drive:]path[;...]]\nPATH ;\n\n\
-Type PATH ; to clear all search-path settings and direct the command shell\n\
-to search only in the current directory.\n\
-Type PATH without parameters to display the current path.\n"
-
-STRING_PROMPT_HELP1, "Changes the command prompt.\n\n\
-PROMPT [text]\n\n\
-  text    Specifies a new command prompt.\n\n\
-Prompt can be made up of normal characters and the following special codes:\n\n\
-  $A   & (Ampersand)\n\
-  $B   | (pipe)\n\
-  $C   ( (Left parenthesis)\n\
-  $D   Current date\n\
-  $E   Escape code (ASCII code 27)\n\
-  $F   ) (Right parenthesis)\n\
-  $G   > (greater-than sign)\n\
-  $H   Backspace (erases previous character)\n\
-  $L   < (less-than sign)\n\
-  $N   Current drive\n\
-  $P   Current drive and path\n\
-  $Q   = (equal sign)\n\
-  $T   Current time\n\
-  $V   OS version number\n\
-  $_   Carriage return and linefeed\n\
-  $$   $ (dollar sign)\n"
-
-STRING_PAUSE_HELP1, "Stops the execution of a batch file and shows the following message:\n\
-'Press any key to continue...' or a user defined message.\n\n\
-PAUSE [message]"
-
-STRING_PROMPT_HELP2, "  $+   Displays the current depth of the directory stack"
-
-STRING_PROMPT_HELP3, "\nType PROMPT without parameters to reset the prompt to the default setting."
-
-STRING_REM_HELP, "Starts a comment line in a batch file.\n\nREM [Comment]"
-
-STRING_RMDIR_HELP,   "Removes a directory.\n\n\
-RMDIR [drive:]path\nRD [drive:]path\n\
-/S                     Deletes all files and folders within target\n\
-/Q                     Doesnt prompt for user\n"
-STRING_RMDIR_HELP2,    "Directory is not empty!\n"
-
-STRING_REN_HELP1, "Renames a file/directory or files/directories.\n\n\
-RENAME [/E /N /P /Q /S /T] old_name ... new_name\n\
-REN [/E /N /P /Q /S /T] old_name ... new_name\n\n\
-  /E    No error messages.\n\
-  /N    Nothing.\n\
-  /P    Prompts for confirmation before renaming each file.\n\
-        (Not implemented yet!)\n\
-  /Q    Quiet.\n\
-  /S    Rename subdirectories.\n\
-  /T    Display total number of renamed files.\n\n\
-Note that you cannot specify a new drive or path for your destination. Use\n\
-the MOVE command for that purpose.\n"
-
-STRING_REN_HELP2, "    %lu file renamed\n"
-
-STRING_REN_HELP3, "    %lu files renamed\n"
-                
-STRING_SHIFT_HELP, "Changes the position of replaceable parameters in a batch file.\n\n\
-SHIFT [DOWN]"
-
-STRING_SCREEN_HELP, "move cursor and optionally print text\n\n\
-SCREEN row col [text]\n\n\
-  row         row to wich move the cursor\n\
-  col         column to wich move the cursor"
-
-STRING_SET_HELP, "Displays, sets, or removes environment variables.\n\n\
-SET [variable[=][string]]\n\n\
-  variable  Specifies the environment-variable name.\n\
-  string    Specifies a series of characters to assign to the variable.\n\n\
-Type SET without parameters to display the current environment variables.\n"
-
-STRING_START_HELP1, "Starts a command.\n\n\
-START command\n\n\
-  command     Specifies the command to run.\n\n\
-At the moment all commands are started asynchronously.\n"
-
-STRING_TITLE_HELP, "Sets the window title for the command prompt window.\n\n\
-TITLE [string]\n\n\
-string       Specifies the title for the command prompt window.\n"
-
-STRING_TIME_HELP1, "Displays or sets the system time.\n\n\
-TIME [/T][time]\n\n\
-  /T    display only\n\n\
-Type TIME with no parameters to display the current time setting and a prompt\n\
-for a new one.  Press ENTER to keep the same time.\n"
-
-STRING_TIME_HELP2, "Enter new time: "
-
-STRING_TIMER_HELP1, "Elapsed %d msecs\n"
-
-STRING_TIMER_HELP2, "Elapsed %02d%c%02d%c%02d%c%02d\n"
-
-STRING_TIMER_HELP3, "allow the use of ten stopwatches.\n\n\
-TIMER  [ON|OFF] [/S] [/n] [/Fn]\n\n\
-  ON          set stopwatch ON\n\
-  OFF         set stopwatch OFF\n\
-  /S          Split time. Return stopwatch split\n\
-              time without changing its value\n\
-  /n          Specifiy the stopwatch number.\n\
-              Stopwatches available are 0 to 9\n\
-              If it is not specified default is 1\n\
-  /Fn         Format for output\n\
-              n can be:\n\
-                    0    milliseconds\n\
-                    1    hh%cmm%css%cdd\n\n\
-if none of ON, OFF or /S is specified the command\n\
-will toggle stopwatch state\n\n"
-
-STRING_TYPE_HELP1, "Displays the contents of text files.\n\nTYPE [drive:][path]filename \n\
-  /P             Shows one screen of output at a time.\n"
-
-STRING_VERIFY_HELP1, "This command is just a dummy!!\n\
-Sets whether to verify that your files are written correctly to a\n\
-disk.\n\n\
-VERIFY [ON | OFF]\n\n\
-Type VERIFY without a parameter to display the current VERIFY setting.\n"
-
-STRING_VERIFY_HELP2, "VERIFY is %s.\n"
-
-STRING_VERIFY_HELP3, "Must specify ON or OFF."
-
-STRING_VERSION_HELP1, "Displays shell version information\n\n\
-VER [/C][/R][/W]\n\n\
-  /C  Displays credits.\n\
-  /R  Displays redistribution information.\n\
-  /W  Displays warranty information."
-
-STRING_VERSION_HELP2, " comes with ABSOLUTELY NO WARRANTY; for details\n\
-type: `ver /w'. This is free software, and you are welcome to redistribute\n\
-it under certain conditions; type `ver /r' for details. Type `ver /c' for a\n\
-listing of credits."
-
-STRING_VERSION_HELP3, "\n This program is distributed in the hope that it will be useful,\n\
- but WITHOUT ANY WARRANTY; without even the implied warranty of\n\
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n\
- GNU General Public License for more details."
-
-STRING_VERSION_HELP4, "\n This program is free software; you can redistribute it and/or modify\n\
- it under the terms of the GNU General Public License as published by\n\
- the Free Software Foundation; either version 2 of the License, or\n\
- (at your option) any later version.\n"
-
-STRING_VERSION_HELP5, "\nSend bug reports to <ros-dev@reactos.org>.\n\
-Updates are available at: http://www.reactos.org"
-
-STRING_VERSION_HELP6, "\nFreeDOS version written by:\n"
-
-STRING_VERSION_HELP7, "\nReactOS version written by:\n"
-
-STRING_VOL_HELP1, " Volume in drive %c: is %s"
-STRING_VOL_HELP2, " Volume in drive %c: has no label"
-STRING_VOL_HELP3, " Volume Serial Number is %04X-%04X\n"
-STRING_VOL_HELP4, "Displays the disk volume label and serial number, if they exist.\n\nVOL [drive:]"
-
-STRING_WINDOW_HELP1, "change console window aspect\n\n\
-WINDOW [/POS[=]left,top,width,heigth]\n\
-              [MIN|MAX|RESTORE] ['title']\n\n\
-/POS          specify window placement and dimensions\n\
-MIN           minimize the window\n\
-MAX           maximize the window\n\
-RESTORE       restore the window"
-
-STRING_WINDOW_HELP2, "change console window aspect\n\n\
-ACTIVATE 'window' [/POS[=]left,top,width,heigth]\n\
-              [MIN|MAX|RESTORE] ['title']\n\n\
-window        tile of window on wich perform actions\n\
-/POS          specify window placement and dimensions\n\
-MIN           minimize the window\n\
-MAX           maximize the window\n\
-RESTORE       restore the window\n\
-title         new title\n"
-
-
-STRING_HELP1, "List of all available commands (+ description)\n\n\
-  command /?     For more information on a specific command\n\n\
-?        List all available commands without description).\n\
-ALIAS    Sets, removes or shows aliases.\n\
-ATTRIB   Displays or changes file attributes.\n\
-BEEP     Beep the speaker.\n\
-CALL     Calls one batch program from another.\n\
-CD       Displays the name of or changes the current directory.\n\
-CHCP     Displays or sets the active code page number.\n\
-CHOICE   Waits for the user to choose one of a set of choices.\n\
-CLS      Clears the screen.\n\
-CMD      Starts a new instance of the ReactOS command interpreter.\n\
-COLOR    Sets the default console foreground and background colors.\n\
-COPY     Copies one or more files to another location.\n\
-DATE     Displays or sets the date.\n\
-DELETE   Deletes one or more files.\n\
-DIR      Displays a list of files and subdirectories in a directory.\n\
-ECHO     Displays messages, or turns command echoing on or off.\n\
-ERASE    Deletes one or more files.\n\
-EXIT     Quits the CMD.EXE program (command interpreter).\n\
-FOR      Runs a specified command for each file in a set of files.\n\
-FREE     (free) disc space.\n\
-GOTO     Directs the ReactOS command interpreter to a labeled line in\n\
-         a batch program.\n\
-HELP     Provides Help information for ReactOS commands.\n\
-HISTORY  List alle commands which has been used\n\
-IF       Performs conditional processing in batch programs.\n\
-LABEL    Creates, changes, or deletes the volume label of a disk.\n\
-MD       Creates a directory.\n\
-MKDIR    Creates a directory.\n\
-MOVE     Moves one or more files from one directory to another\n\
-         directory.\n\
-PATH     Displays or sets a search path for executable files.\n\
-PAUSE    Suspends processing of a batch file and displays a message.\n\
-POPD     Restores the previous value of the current directory saved by\n\
-         PUSHD.\n\
-PROMPT   Changes the command prompt.\n\
-PUSHD    Saves the current directory then changes it.\n\
-RD       Removes a directory.\n\
-REM      Records comments (remarks) in batch files.\n\
-REN      Renames a file or files.\n\
-RENAME   Renames a file or files.\n\
-RMDIR    Removes a directory.\n\
-SCREEN   Move cursor and optionally print text.\n\
-SET      Displays, sets, or removes ReactOS environment variables.\n\
-SHIFT    Shifts the position of replaceable parameters in batch files.\n"
-STRING_HELP2, "START    Starts a separate window to run a specified program or command.\n\
-         Executes command.\n\
-TIME     Displays or sets the system time.\n\
-TIMER    Allow the use of ten stopwaches.\n\
-TITLE    Sets the window title for a CMD.EXE session.\n\
-TYPE     Displays the contents of a text file.\n\
-VER      Displays the ReactOS version.\n\
-VERIFY   Tells ReactOS whether to verify that your files are written\n\
-         correctly to a disk.\n\
-VOL      Displays a disk volume label and serial number.\n"
-
-
-STRING_CHOICE_OPTION,         "YN"
-STRING_COPY_OPTION,           "YNA"
-
-
-STRING_ALIAS_ERROR,          "Command line too long after alias expansion!\n"
-STRING_BATCH_ERROR,          "Error opening batch file\n"
-STRING_CHCP_ERROR1,          "Active code page: %u\n"
-STRING_CHCP_ERROR4,          "Invalid code page\n"
-STRING_CHOICE_ERROR,         "Invalid option. Expected format: /C[:]options"
-STRING_CHOICE_ERROR_TXT,     "Invalid option. Expected format: /T[:]c,nn"
-STRING_CHOICE_ERROR_OPTION,  "Illegal Option: %s"
-STRING_MD_ERROR,                        "A subdirectory or file already exists.\n"
-STRING_MD_ERROR2,                       "The path to the new folder does not exist.\n"
-STRING_CMD_ERROR1,           "Can't redirect input from file %s\n"
-STRING_CMD_ERROR2,           "Error creating temporary file for pipe data\n"
-STRING_CMD_ERROR3,           "Can't redirect to file %s\n"
-STRING_CMD_ERROR4,           "Running %s...\n"
-STRING_CMD_ERROR5,           "Running cmdexit.bat...\n"
-STRING_COLOR_ERROR1,         "Same colors error! (Background and foreground can't be the same color)"
-STRING_COLOR_ERROR2,         "error in color specification"
-STRING_COLOR_ERROR3,         "Color %x\n"
-STRING_COLOR_ERROR4,         "same colors error!"
-STRING_CONSOLE_ERROR,        "Unknown error: %d\n"
-STRING_COPY_ERROR1,          "Error: Cannot open source - %s!\n"
-STRING_COPY_ERROR2,          "Error: Can't copy onto itself!\n"
-STRING_COPY_ERROR3,          "Error writing destination!\n"
-STRING_COPY_ERROR4,          "Error: Not implemented yet!\n"
-STRING_DATE_ERROR,           "Invalid date."
-STRING_DEL_ERROR5,           "The file %s will be deleted! "
-STRING_DEL_ERROR6,           "Are you sure (Y/N)?"
-STRING_DEL_ERROR7,           "Deleting: %s\n"
-STRING_ERROR_ERROR1,         "Unknown error! Error code: 0x%lx\n"
-STRING_ERROR_ERROR2,         "Syntax error"
-STRING_FOR_ERROR1,           "'in' missing in for statement."
-STRING_FOR_ERROR2,           "no brackets found."
-STRING_FOR_ERROR3,           "'do' missing." 
-STRING_FOR_ERROR4,           "no command after 'do'."
-STRING_FREE_ERROR1,          "Invalid drive"
-STRING_FREE_ERROR2,          "unlabeled"
-STRING_GOTO_ERROR1,          "No label specified for GOTO"
-STRING_GOTO_ERROR2,          "Label '%s' not found\n"
-
-STRING_MOVE_ERROR1,          "[OK]\n"
-STRING_MOVE_ERROR2,          "[Error]\n"
-
-STRING_REN_ERROR1,           "MoveFile() failed. Error: %lu\n"
-
-STRING_START_ERROR1,         "No batch support at the moment!"
-
-STRING_TIME_ERROR1,          "Invalid time."
-
-STRING_TYPE_ERROR1,          "Invalid option '/%s'\n"
-
-STRING_WINDOW_ERROR1,        "window not found"
-
-
-STRING_ERROR_PARAMETERF_ERROR,     "Parameter format not correct - %c\n"
-STRING_ERROR_INVALID_SWITCH,       "Invalid switch - /%c\n"
-STRING_ERROR_TOO_MANY_PARAMETERS,  "Too many parameters - %s\n"
-STRING_ERROR_PATH_NOT_FOUND,       "Path not found\n"
-STRING_ERROR_FILE_NOT_FOUND,       "File not found\n"
-STRING_ERROR_REQ_PARAM_MISSING,    "Required parameter missing\n"
-STRING_ERROR_INVALID_DRIVE,        "Invalid drive specification\n"
-STRING_ERROR_INVALID_PARAM_FORMAT, "Invalid parameter format - %s\n"
-STRING_ERROR_BADCOMMAND,           "Bad command or filename\n"
-STRING_ERROR_OUT_OF_MEMORY,        "Out of memory error.\n"
-STRING_ERROR_CANNOTPIPE,           "Error!  Cannot pipe!  Cannot open temporary file!\n"
-STRING_ERROR_D_PAUSEMSG,           "Press any key to continue . . ."
-STRING_ERROR_DRIVER_NOT_READY,     "Drive not ready"
-
-STRING_PATH_ERROR,                 "CMD: Not in environment '%s'\n"
-
-STRING_CMD_SHELLINFO,              "\nReactOS Command Line Interpreter"
-STRING_VERSION_RUNVER,             " running on %s"
-STRING_COPY_FILE ,                 "        %d file(s) copied\n"
-STRING_DELETE_WIPE,                "wiped"
-STRING_FOR_ERROR,                  "bad variable specification."
-STRING_SCREEN_COL,                 "invalid value for col"
-STRING_SCREEN_ROW,                 "invalid value for row"
-STRING_TIMER_TIME                  "Timer %d is %s: "
-
-STRING_INVALID_OPERAND,            "Invalid operand."
-STRING_EXPECTED_CLOSE_PAREN,       "Expected ')'."
-STRING_EXPECTED_NUMBER_OR_VARIABLE,"Expected number or variable name."
-STRING_SYNTAX_COMMAND_INCORRECT,   "The syntax of the command is incorrect."
-
-}
diff --git a/reactos/subsys/system/cmd/Es.rc b/reactos/subsys/system/cmd/Es.rc
deleted file mode 100644 (file)
index daaa3dc..0000000
+++ /dev/null
@@ -1,650 +0,0 @@
-#include "windows.h"
-#include "resource.h"
-/*
- * Spanish resource file by HUMA2000
- * Jose Pedro Fernández Pascual  2005
- */
-
-LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL
-STRINGTABLE DISCARDABLE
-{
-
-STRING_ATTRIB_HELP,    "Muestra o cambia los atributos de los archivos.\n\n\
-ATTRIB [+R | -R] [+A | -A] [+S | -S] [+H | -H] file ...\n\
-       [/S [/D]]\n\n\
-  +   Añade un atributo\n\
-  -   Borra un atributo\n\
-  R   Atributo de sólo lectura\n\
-  A   Atributo de archivo\n\
-  S   Atributo de archivo de sistema\n\
-  H   Atributo de archivo oculto\n\
-  /S  Procesa los archivos coincidentes en el directorio actual \n\
-      y sus subdirectorios\n\
-  /D  Procesa también los directorios\n\n\
-Type ATTRIB without a parameter to display the attributes of all files.\n"
-
-STRING_ALIAS_HELP,  "Pone, borra o muestra los alias.\n\n\
-ALIAS [alias=[command]]\n\n\
-  alias    Nombre para un alias.\n\
-  command  Texto a ser sustituido por el alias.\n\n\
-Para mostrar todos los alias:\n\
-  ALIAS\n\n\
-Para poner un nuevo o remplazar un alias existente:\n\
-  ALIAS da=dir a:\n\n\
-Para borrar un alias de la lista de alias:\n\
-  ALIAS da="
-
-STRING_BEEP_HELP, "Emite un pitido por el altavoz.\n\nBEEP\n"
-
-STRING_CALL_HELP, "Ejecuta un arhivo por lotes desde otro archivo por lotes.\n\n\
-CALL [drive:][path]filename [batch-parameter]\n\n\
-  batch-parameter  Especifica cualquier informacion de la linea de comandos\n\
-                   requerida por el archivo por lotes."
-
-STRING_CD_HELP,      "Cambia el directorio actual o muestra su nombre.\n\n\
-CHDIR [/D][drive:][path]\n\
-CHDIR[..|.]\n\
-CD [/D][drive:][path]\n\
-CD[..|.]\n\n\
-  ..   Directorio padre.\n\
-  .    Directorio actual.\n\
-  /D   Cambiara la unidad y el directorio actual.\n\n\
-Escribe CD unidad: para mostrar el directorio actual en la unidad especificada.\n\
-Escribe CD sin ningun parámetro para mostrar la unidad y el directorio actual.\n"
-
-STRING_CHCP_HELP,   "Muestra o configura el número de página de código activa.\n\n\
-CHCP [nnn]\n\n\
-  nnn   Especifica el número de página de código activa.\n\n\
-Escribe CHCP sin ningún parámetro para mostrar el código de página activo.\n"
-
-STRING_CHOICE_HELP, "Espera a que el usuario elija entre un número de opciones.\n\n\
-CHOICE  [/C[:]choices][/N][/S][/T[:]c,nn][text]\n\n\
-  /C[:]choices  Especifica las teclas admitidas. Por defecto son SN.\n\
-  /N            No muestra las posibles elecciones y ? al final del prompt.\n\
-  /S            Hace que la elección sea sensible a las mayúsculas y minúsculas.\n\
-  /T[:]c,nn     La elección por defecto será c después de nn segundos.\n\
-  text          Prompt a mostrar. \n\n\
-ERRORLEVEL se configura al offset de la tecla que presione el usuario.\n"
-
-STRING_CLS_HELP, "Limpia la pantalla.\n\nCLS\n"
-
-STRING_CMD_HELP1, "\nComandos internos disponibles:\n"
-
-STRING_CMD_HELP2, "\nCaracterísticas disponibles:"
-
-STRING_CMD_HELP3,"  [alias]"
-
-STRING_CMD_HELP4,"  [historia]"
-
-STRING_CMD_HELP5,"  [Completador de nombres de archivos unix]"
-
-STRING_CMD_HELP6,"  [Pila de directorios]"
-
-STRING_CMD_HELP7,"  [Redirecciones y túneles]"
-
-STRING_CMD_HELP8, "Comienza una nueva sesion del interprete de comandos de ReactOS.\n\n\
-CMD [/[C|K] command][/P][/Q][/T:bf]\n\n\
-  /C command  Ejecuta el comando especificado y cierra.\n\
-  /K command  Ejecuta eñ comando especificado y permanece.\n\
-  /P          CMD se hace permanente y ejecuta el autoexec.bat\n\
-              (no puede ser cerrado).\n\
-  /T:bf       Configura el color de fondo/primer plano (mirar el comando COLOR).\n"
-
-STRING_COLOR_HELP1, "Configura el color de primer plano y fondo.\n\n\
-COLOR [attr [/-F]] \n\n\
-  attr        Especifica el atributo de color de salida de consola.\n\
-  /-F         No rellena el espacio en blanco de la consola con el color del atributo.\n\n\
-Hay tres maneras de especificar los colores:\n\
-1) [bright] nombre on [bright] nombre  (solo las tres primeras letras del nombre son necesarias)\n\
-2) decimal on decimal\n\
-3) dos dígitos hexadecimales\n\n\
-Los colores son:\n\
-dec  hex  nombre       dec  hex  name\n\
-0    0    Negro       8   8    Gris(Negro brillante)\n\
-1    1    Azul        9   9    Azul brillante\n\
-2    2    Verde      10   A    Verde brillante\n\
-3    3    Cyan       11   B    Cyan brillante\n\
-4    4    Rojo       12   C    Rojo brillante\n\
-5    5    Magenta    13   D    Magenta brillante\n\
-6    6    Amarillo   14   E    Amarillo brillante\n\
-7    7    Blanco     15   F    Blanco brillante\n"
-
-STRING_COPY_HELP1,  "Sobreescribir %s (Si/No/Todos)? "
-
-STRING_COPY_HELP2, "Copia uno o mas archivos a otro lugar.\n\n\
-COPY [/V][/Y|/-Y][/A|/B] origen [/A|/B]\n\
-     [+ origen [/A|/B] [+ ...]] [destino [/A|/B]]\n\n\
-  origen       Especifica el archivo o archivos a copiar.\n\
-  /A           Indica un archivo de texto ASCII.\n\
-  /B           Indica un archivo binario.\n\
-  destino      Especifica el directorio y/o nombre de archivo para los nuevos archivos.\n\
-  /V           Verifica que el nuevo archivo se ha escrito correctamente.\n\
-  /Y           Suprime la confirmación  sobre si quieres sobreescribir un archivo\n\
-               de destino existente.\n\
-  /-Y          Hace que te pregunte si quieres sobreescribir un archivo de destino\n\
-               existente.\n\n\
-El parametro /Y tiene que estar presente en las variables de entorno de COPYCMD.\n\
-...\n"
-
-STRING_DATE_HELP1, "\nIntroduce la nueva fecha (mm%cdd%cyyyy): "
-
-STRING_DATE_HELP2, "\nIntroduce la nueva fecha (dd%cmm%cyyyy): "
-
-STRING_DATE_HELP3, "\nIntroduce la nueva fecha (yyyy%cmm%cdd): "
-
-STRING_DATE_HELP4, "Muestra o cambia la fecha.\n\n\
-DATE [/T][date]\n\n\
-  /T    Sólo la muestra\n\n\
-Escribe DATE sin parámetros para mostrar la fecha actual y establecer\n\
-una nueva fecha. Pulsa INTRO para mantener la misma fecha.\n"
-                               
-STRING_DEL_HELP1,  "Borra uno o mas archivos.\n\n\
-DEL [/N /P /T /Q /S /W /Y /Z /A[[:]atributos]] archivo ...\n\
-DELETE [/N /P /T /Q /S /W /Y /Z /A[[:]atributos]] archivo ...\n\
-ERASE [/N /P /T /Q /S /W /Y /Z /A[[:]atributos]] archivo ...\n\n\
-      archivo Espacifica el/los archivo(s) a borrar.\n\n\
-  /N    Nada.\n\
-  /P    Prompt. Pregunta antes de borar cada archivo\n\
-  /T    Total. Muestra el número total de archivos eliminados y el espacio\n\
-       liberado en disco\n\
-  /Q    Modo silencioso.\n\
-  /W    Limpiar. Sobreescribe el archivo con números aleatorios después de eliminarlo.\n\
-  /Y    Si. Borra incluso *.* sin preguntar.\n\
-  /F    Fuerza el borrade de archivos ocultos, de sólo lectura y de sistema.\n\
-  /S    Borra los archivos de todos los subdirectorios.\n\
-  /A    Selecciona los archivos a borrar en base a los atributos especificados.\n\
-        R     Archivos de sólo lectura\n\
-        S     Archivos de sistema\n\
-        A     Archivos listos para archivar\n\
-        H     Archivos ocultos\n\
-        -     Prefijo que signifca sin\n"
-
-STRING_DEL_HELP2, "¡Todos los archivos del directorio van a ser borrados!\n¿Estás seguro? (S/N)?"
-STRING_DEL_HELP3, "    Archivo %lu borrado\n"
-STRING_DEL_HELP4, "    Archivos %lu borrados\n"
-
-STRING_DELAY_HELP, "Espera por n segundos o milisegundos\n\
-DELAY [/m]n\n\n\
-  /m          Especifica que n son milisegundos\n\
-              En otro caso n son segundos\n"
-
-STRING_DIR_HELP1, "DIR [unidad:][ruta][nombre de archivo] [/A[[:]atributos]] [/B] [/C] [/D] [/L] [/N]\n\
-  [/O[[:]orden]] [/P] [/Q] [/S] [/T[[:]fecha]] [/W] [/X] [/4]\n\n\
-  [unidad:][ruta][nombre de archivo]\n\
-              Especifica la unidad, el directorio o los archivos a listar.\n\n\
-  /A          Muestra los archivos con los atributos especificados.\n\
-  atributos    D  Directorios                R  Archivos de sólo lectur\n\
-               H  Archivos ocultos           A  Archivos listos para archivar\n\
-               S  Archivos de sistema        -  Prefijo que signifca sin\n\
-  /B          Usa el formato simple (sin encabezado ni sumario).\n\
-  /C          Muestra el separador de miles en los tamaños de los archivos. Es la opción\n\
-              por defecto.  Usa /-C para desactivar el mostrar el separador.\n\
-  /D          Lo mismo que el formato a lo ancho, pero ordenados en columna.\n\
-  /L          Usa minúsculas.\n\
-  /N          Nuevo formato de lista larga donde los nombres de archivo están a la \n\
-  derecha.\n\
-  /O          Muestra los archivos ordenados según el orden especificado.\n\
-  ordenación   N  Por nombre (alfabético)       S  Por tamaño (los menores primero)\n\
-               E  Por extensión (alfabético)    D  Por fecha/hora (los antiguos primero)\n\
-               G  Los directorios primero       -  Prefijo para el orden inverso\n\
-  /P          Pausa después de cada pantalla llena de información.\n\
-  /Q          Muestra el propietario del archivo.\n\
-  /S          Muestra los archivos en el directorio especificado y sus subdirectorios.\n\
-  /T          Controla que campo de tiempo se muestra o es usado para ordenar:\n\
-  campo de tiempo  C  Creación\n\
-                  A  Último acceso\n\
-                  W  Última escritura\n\
-  /W          Usa el formato de lista a lo ancho.\n\
-  /X          Muestra los nombres cortos generados para archivos que no tienen un\n\
-              nombre 8.3.  El formato es como /N pero con el nombre corto colocado\n\
-              antes del nombre largo. Si no hay nombre corto, se muestran espacios\n\
-              en blanco en su lugar.\n\
-  /4          Muestra los cuatro dígitos del año\n\n\
-Los modificadores pueden estar presentes en la variable de entorno de DIRCMD. Omite los\n\
-ajustes previos anteponiendo a cualquier modificador - (hyphen)--por ejemplo, /-W.\n"
-
-STRING_DIR_HELP2, " El volumen en la unidad %c es %s\n"
-STRING_DIR_HELP3, " El volumen en la unidad %c no tiene etiqueta.\n"
-STRING_DIR_HELP4, " El volumen Serial Number is %04X-%04X\n"
-STRING_DIR_HELP5, "\n     Total de archivos mostrados:\n%16i archivo(s)% 14s bytes\n"
-STRING_DIR_HELP6, "%16i Directorio(s)% 15s bytes\n"
-STRING_DIR_HELP7, "\n Directorio %s\n\n"
-STRING_DIR_HELP8, "%16i archivo(s)% 14s bytes\n"
-
-STRING_DIRSTACK_HELP1, "Almacena el directorio actual para usarlo por el comando, \n\
-entonces cambia al directorio especificado.\n\n\
-PUSHD [ruta | ..]\n\n\
-  ruta        Especifica el directorio para hacerlo el directorio actual\n"
-
-STRING_DIRSTACK_HELP2, "Cambia al directorio guardado por el comando PUSHD.\n\nPOPD"
-
-STRING_DIRSTACK_HELP3, "Muestra el contenido de la pila de directorios.\n\nDIRS"
-
-STRING_DIRSTACK_HELP4, "Vacia la pila de directorios"
-
-STRING_ECHO_HELP1,  "Muestra un mensaje sin necesidad de pulsar intro y \n\
-salta a la siguiente linea.\n\n\
-  ECHOS mensaje"
-
-STRING_ECHO_HELP2,  "Muestra los mensajes de error por defecto.\n\n\
-  ECHOERR mensaje\n\
-  ECHOERR.           Imprime una linea vacia"
-
-STRING_ECHO_HELP3, "Muestra mensajes en la salida estandar de error sin pulsar intro y\n\
-pasa de linea.\n\n\
-  ECHOSERR mensaje"
-
-STRING_ECHO_HELP4, "Muestra un mensaje o cambia el mostrar los comandos activo/inactivo.\n\n\
-  ECHO [ON | OFF]\n\
-  ECHO [mensaje]\n\
-  ECHO.             Muestra una linea vacia\n\n\
-Escribe ECHO sin parámetros para mostrar la configuración actual de ECHO."
-
-STRING_ECHO_HELP5, "ECHO está %s\n"
-
-STRING_EXIT_HELP, "Sale del interprete de la linea de comandos.\n\nEXIT\n"
-
-STRING_FOR_HELP1, "Ejecuta un comando específico para cada archivo de un grupo de archivos.\n\n\
-FOR %variable IN (grupo) DO comando [parametros]\n\n\
-  %variable  Especifica un parámetro remplazable.\n\
-  (set)      Especifica un grupo de uno o mas archivos. Los comodines pueden usarse.\n\
-  command    Especifica el comando a ejecutar para cada archivo.\n\
-  parameters Especifica los parametros o modificadores para el comando especificado.\n\n\
-Para usar el comando FOR en un archivo por lotes, especifica %%variable en lugar de\n\
-%variable.\n"
-
-STRING_FREE_HELP1, "\nEl volumen en la unidad %s es %-11s\n\
- El número de serie es %s\n\
-  %16s bytes totales de espacio en disco\n\
-  %16s bytes usados\n\
-  %16s bytes libres\n"
-
-STRING_FREE_HELP2, "Muestra la información de la unidad.\n\nFREE [unidad: ...]\n"
-
-STRING_IF_HELP1, "Ejecuta procesos condicionales en archivos por lotes.\n\n\
-  IF [NOT] ERRORLEVEL número comando\n\
-  IF [NOT] string1==string2 comando\n\
-  IF [NOT] EXIST archivo comando\n\
-  IF [NOT] DEFINED variable comando\n\n\
-NOT               Especifica que CMD solo llevará a cabo el comando si la \n\
-                  condición es falsa.\n\
-ERRORLEVEL número Especifica una condición verdadera si el último programa devuelve\n\
-                  un código de salida igual o superior al número especificado.\n\
-comando           Especifica el comando a ejecutar si se cumple la condición.\n\
-string1==string2  Especifica una condición verdadera si las cadenas de texto coinciden.\n\
-EXIST archivo     Especifica una condición verdadera si existe el archivo especificado.\n\
-DEFINED variable  Especifica una condición verdadera si la variable está definida.\n"
-
-STRING_GOTO_HELP1,  "Manda al CMD a una linea etiquetada en un archivo por lotes.\n\n\
-GOTO etiqueta\n\n\
-  etiqueta  Especifica la cadena de texto usada en el archivo por lotes como etiqueta.\n\n\
-Escriba la etiqueta en la linea misma, empezando con dos puntos."
-
-STRING_LABEL_HELP1, "Muestra o cambia la etiqueta de una unidad.\n\nLABEL [unidad:][etiqueta]\n"
-
-STRING_LABEL_HELP2, "El volumen en la unidad %c: es %s\n"
-STRING_LABEL_HELP3, "El volumen en la unidad %c: no tiene etiqueta\n"
-STRING_LABEL_HELP4, "El número de serie del volumen es %04X-%04X\n"
-STRING_LABEL_HELP5, "Etiqueta del volumen (11 Caracteres, INTRO para ninguna)? "
-
-STRING_LOCALE_HELP1, "La hora actual es"
-
-STRING_MKDIR_HELP,   "Crea un directorio.\n\n\
-MKDIR [unidad:]ruta\nMD [unidad:]ruta"
-
-STRING_MEMMORY_HELP1, "Muestra la cantidad de memoria del sistema.\n\nMEMORY"
-
-STRING_MEMMORY_HELP2, "\n  %12s%% carga de memoria.\n\n\
-  %13s bytes totales de RAM física.\n\
-  %13s bytes libres de RAM física.\n\n\
-  %13s bytes totales del archivo de paginación.\n\
-  %13s bytes disponibles del archivo de paginación.\n\n\
-  %13s bytes totales de memoria virtual.\n\
-  %13s bytes disponibles de memoria virtual.\n"
-
-STRING_MISC_HELP1, "Pulsa cualquier tecla para continuar...\n"
-
-STRING_MOVE_HELP1, "¿Sobreescribir %s (Si/No/Todos)? "
-
-STRING_MOVE_HELP2, "Mueve archivos y renombra archivos y directorios.\n\n\
-Para mover uno o más archivos:\n\
-MOVE [/N][unidad:][ruta]archivo1[,...] destino\n\n\
-Para renombrar un directorio:\n\
-MOVE [/N][unidad:][ruta]directorio1 directorio2\n\n\
-  [unidad:][ruta]archivo1  Especifica la localización y el nombre del archivo\n\
-                           o archivos que quieres mover.\n\
-  /N                    Nada. Hace todo menos mover archivos o directorios.\n\n\
-Limitaciones actules:\n\
-  - No puedes mover un archivo o directorio de una unidad a otra.\n"
-
-STRING_MSGBOX_HELP, "Muestra un cuadro de mensaje y devuelve la respuesta del usuario.\n\n\
-MSGBOX tipo ['titulo'] pregunta\n\n\
-tipo          buton a mostrar\n\
-              los valores posibles son: OK, OKCANCELAR,\n\
-              SINO, SINOCANCELAR\n\
-titulo        titulo del cuadro de mensaje\n\
-pregunta      texto a mostrar por el cuadro de mensaje\n\n\n\
-ERRORLEVEL se configurara en función del botón pulsado:\n\n\
-SI  :  10    |  NO      :  11\n\
-OK  :  10    |  CANCELAR:  12\n"
-
-STRING_PATH_HELP1, "Muestra o cambia la ruta de búsqueda de archivos ejecutables.\n\n\
-PATH [[unidad:]ruta[;...]]\nRuta ;\n\n\
-Escribe PATH ; para limpiar todas las configuraciones de búsqueda y usar solo el\n\
-directorio actual del interprete de comandos.\n\
-Escribe PATH sin parámetros para mostrar la ruta actual.\n"
-
-STRING_PROMPT_HELP1, "Cambia el símbolo de comandos.\n\n\
-PROMPT [texto]\n\n\
-  texto   Epecifica un nuevo símbolo de comandos.\n\n\
-El símbolo de comandos puede hacerce con carácteres normales y los siguientes \n\
-códigos especiales:\n\n\
-  $A   & (Signo y)\n\
-  $B   | (Linea horizontal)\n\
-  $C   ( (Paréntesis izquierdo)\n\
-  $D   Fecha actual\n\
-  $E   Código de escape (código ASCII 27)\n\
-  $F   ) (Paréntesis derecho)\n\
-  $G   > (Signo mayor que)\n\
-  $H   Borra el caracter anterior\n\
-  $L   < (Signo menor que)\n\
-  $N   Unidad actual\n\
-  $P   Unidad y ruta actuales\n\
-  $Q   = (signo igual)\n\
-  $T   Hora actual\n\
-  $V   Número de versión del SO\n\
-  $_   Salto de linea\n\
-  $$   $ (signo del dolar)\n"
-
-STRING_PAUSE_HELP1, "Detiene la ejecución del archivo por lotes actual y muestra el\n\
-siguiente mensaje:\n\
-'Pulsa cualquier tecla para continuar...' o un mensaje definido por el usuario.\n\n\
-PAUSE [mensaje]"
-
-STRING_PROMPT_HELP2, "  $+   Muestra la profundidad actual de la pila de directorios"
-
-STRING_PROMPT_HELP3, "\nEscribe PROMPT sin parámetros para resetear el símbolo de \n\
-comandos a su configuración por defecto."
-
-STRING_REM_HELP, "Comienza una liena de comentarios en un archivo por lotes\n\nREM [Comentario]"
-
-STRING_RMDIR_HELP,   "Remueve un directorio.\n\n\
-RMDIR [unidad:]ruta\nRD [unidad:]ruta"
-
-STRING_REN_HELP1, "Renombra un archivo/directorio o varios archivos/directorios.\n\n\
-RENAME [/E /N /P /Q /S /T] nombre_antiguo ... nuevo_nombre\n\
-REN [/E /N /P /Q /S /T] nombre_antiguo ... nuevo_nombre\n\n\
-  /E    No muestra mensajes de error.\n\
-  /N    Nada.\n\
-  /P    Pregunta por la confirmación antes de cada archivo.\n\
-        (¡No implementado aún!)\n\
-  /Q    Modo silencioso.\n\
-  /S    Renombra los subdirectorios.\n\
-  /T    Muestra el número total de archivos renombrados.\n\n\
-Note que no puede especificar una nueva unidad en el destino o ruta. Usa\n\
-el comando MOVE para este propósito.\n"
-
-STRING_REN_HELP2, "    %lu archivos renombrados.\n"
-
-STRING_REN_HELP3, "    %lu archivos renombrados.\n"
-                
-STRING_SHIFT_HELP, "Cambia la posición de los parámetros remplazables en un \n\
-archivo por lotes.\n\n\
-SHIFT [ABAJO]"
-
-STRING_SCREEN_HELP, "Mueve el cursor y opcionalmente escribe un texto.\n\n\
-SCREEN fila columna [texto]\n\n\
-  fila         Fila a la que mover el cursor.\n\
-  columna      columna a la que mover el cursor."
-
-STRING_SET_HELP, "Muestra, cambia o borra las variables de entorno.\n\n\
-SET [variable[=][cadena]]\n\n\
-  variable  Especifica el nombre de la variable de entorno.\n\
-  string    Especifies la serie de caracteres para asignar a la variable.\n\n\
-Escribe SET sin parámetros para mostrar las variables de entorno actuales.\n"
-
-STRING_START_HELP1, "Empieza un comando.\n\n\
-START comando\n\n\
-  comando     Especifica el comando a ejecutar.\n\n\
-Por el momento todos los comandos son ejecutados de forma asincrónica.\n"
-
-STRING_TITLE_HELP, "Cambia el título de la ventqana del intérprete de comandos.\n\n\
-TITLE [cadena]\n\n\
-cadena       Especifica el título de la ventana del intérprete de comandos.\n"
-
-STRING_TIME_HELP1, "Muestra o cambia la hora del sistema.\n\n\
-TIME [/T][hora]\n\n\
-  /T    Sólo la muestra\n\n\
-Escribe TIME sin parámetros para mostrar la hora actual y preguntar\n\
-por una nueva. Pulsa INTRO para mantener la misma hora.\n"
-
-STRING_TIME_HELP2, "Introduce la nueva hora: "
-
-STRING_TIMER_HELP1, "Transcurridos %d msecs\n"
-
-STRING_TIMER_HELP2, "Transcurridos %02d%c%02d%c%02d%c%02d\n"
-
-STRING_TIMER_HELP3, "Permite al usuario el uso de diez paradas de reloj.\n\n\
-TIMER  [ON|OFF] [/S] [/n] [/Fn]\n\n\
-  ON          Cambia la parada a ON\n\
-  OFF         Cambia la parada a OFF\n\
-  /S          Divide el tiempo. Devuelve una division de la parada del reloj\n\
-              sin cambiar su valor.\n\
-  /n          Especifica el número de la parada de reloj.\n\
-              Las paradas de reloj disponibles son de 0 a 9\n\
-              Si no se especifica el valor por defecto es 1\n\
-  /Fn         Formato de salida\n\
-              n puede ser:\n\
-                    0    millisegundos\n\
-                    1    hh%cmm%css%cdd\n\n\
-Si ni ON, OFF o /S se especifican, el comando\n\
-cambiara el estado de parada del reloj\n\n"
-
-STRING_TYPE_HELP1, "Muestra los contenidos de un archivo de texto.\n\nTYPE [unidad:][ruta]archivo \n\
-  /P           Muestra sólo una pantalla de salida cada vez.\n"
-
-STRING_VERIFY_HELP1, "¡¡Este comando es solo de relleno!!\n\
-Configura si hay que verificar que los archivos se and escrito correctamente\n\
-en un disco.\n\n\
-VERIFY [ON | OFF]\n\n\
-Escribe VERIFY sin parámetros para mostrar la configuración actual de VERIFY.\n"
-
-STRING_VERIFY_HELP2, "VERIFY está %s.\n"
-
-STRING_VERIFY_HELP3, "Tienes que especificar ON o OFF."
-
-STRING_VERSION_HELP1, "Muestra la información de la versión del shell\n\n\
-VER [/C][/R][/W]\n\n\
-  /C  Muestra los creditos.\n\
-  /R  Muestra la información de redistribución.\n\
-  /W  Muestra la información de la garantia."
-
-STRING_VERSION_HELP2, "Este software Viene con ABSOLUTAMENTE NINGUNA GARANTIA; para más detalles\n\
-escribe: `ver /w'. Este es un software gratuito, y estás invitado a redistribuirlo\n\
-bajo ciertas condiciones; escribe `ver /r' para los detalles. Escribe `ver /c' para una\n\
-lista de los créditos."
-
-STRING_VERSION_HELP3, "\n Este programa es distribuido con la esperanza de que sea útil,\n\
- pero CON NINGUNA GARANTIA; incluso sin la garantía implícita de\n\
- MERCADERIA o AJUSTE A UN PROPÓSITO PARTICULAR. Mira la\n\
- Licencia Pública General GNU para más detalles."
-
-STRING_VERSION_HELP4, "\n Este programa es un software gratuito; puedes redistribuirlo y/o modificarlo\n\
- bajo los términos de la Licencia Pública General GNU tal y como establece\n\
- la Fundación de Software Libre; tanto en la versión 2 de la Licencia, o\n\
- (según tu elección) cualquier otra posterior.\n"
-
-STRING_VERSION_HELP5, "\nManda los informes de bugs a <ros-dev@reactos.org>.\n\
-Actualizaciones disponibles en: http://www.reactos.org"
-
-STRING_VERSION_HELP6, "\nFreeDOS version escrita por:\n"
-
-STRING_VERSION_HELP7, "\nReactOS version escrita por:\n"
-
-STRING_VOL_HELP1, " El volumen en la unidad %c: es %s"
-STRING_VOL_HELP2, " El volumen en la unidad %c: no tiene etiqueta"
-STRING_VOL_HELP3, " El número de serie del volumen es %04X-%04X\n"
-STRING_VOL_HELP4, "Muestra la etiqueta del volumen del disco y el número de serie si existen.\n\nVOL [unidad:]"
-
-STRING_WINDOW_HELP1, "Cambia el aspecto de la ventana de la consola.\n\n\
-WINDOW [/POS[=]left,top,width,heigth]\n\
-              [MIN|MAX|RESTORE] ['title']\n\n\
-/POS          Especifica la posición y dimensión de la ventana\n\
-MIN           minimiza la ventana\n\
-MAX           maximiza la ventana\n\
-RESTORE       restaura la ventana"
-
-STRING_WINDOW_HELP2, "Cambia el aspecto de la ventana de la consola.\n\n\
-ACTIVATE 'window' [/POS[=]left,top,width,heigth]\n\
-              [MIN|MAX|RESTORE] ['title']\n\n\
-window        Título de la ventana en la que realizar las acciónes\n\
-/POS          Especifica la posición y dimensión de la ventana\n\
-MIN           minimiza la ventana\n\
-MAX           maximiza la ventana\n\
-RESTORE       restaura la ventana\n\
-title         Nuevo título\n"
-
-
-STRING_HELP1, "Lista de todos los comandos disponibles (+ descripción)\n\n\
-  comando /?     Para más información del comando especificado.\n\n\
-?        Muestra todos los comandos disponibles sin la descripción.\n\
-ALIAS    Crea, borra o muestra los alias.\n\
-ATTRIB   Muestra o cambia los atributos de archivo.\n\
-BEEP     Hace un beep con el altavoz.\n\
-CALL     Llama a un archivo por lotes desde otro.\n\
-CD       Muestra o cambia el directorio actual.\n\
-CHCP     Muestra o cambia el código de página activo.\n\
-CHOICE   Espera a que el usuario elija una opción de un grupo de opciones.\n\
-CLS      Limpia la pantalla.\n\
-CMD      Comienza una nueva instancia del intérprete de comandos.\n\
-COLOR    Configura el color por defecto de fondo y frente de la consola.\n\
-COPY     Copia uno o varios archivos de una localización a otra.\n\
-DATE     Muestra y cambia la fecha.\n\
-DELETE   Borra uno o más archivos.\n\
-DIR      Muestra una lista de los archivos y subdirecctorios en un directorio.\n\
-ECHO     Muestra mensajes, o cambia un comando entre mostrarlos o no.\n\
-ERASE    Borra uno o más archivos.\n\
-EXIT     Sale del programa CMD.EXE (intérprete de comandos).\n\
-FOR      Ejecuta un comando específico en un grupo de archivos.\n\
-FREE     Espacio libre en disco.\n\
-GOTO     Direcciona la ventana del intérprete de comandos a una linea etiquetada\n\
-         en un archivo por lotes.\n\
-HELP     Proporciona ayuda sobre los comandos para ReactOS.\n\
-HISTORY  Muestra todos los comandos que han sido usados.\n\
-IF       Realiza un proceso condicional en un archivo por lotes.\n\
-LABEL    Crea, cambia, o borra la etiqueta de volumen de un disco.\n\
-MD       Crea un directorio.\n\
-MKDIR    Crea un directorio.\n\
-MOVE     Mueve uno o más archivos de un directorio a otro.\n\
-PATH     Muestra o configura las rutas de búsqueda para archivos ejecutables.\n\
-PAUSE    Suspende el procesamiento de un archivo por lotes y muestra un mensaje.\n\
-POPD     Restaura el valor anterior del directorio actual guardado por PUSHD.\n\
-PROMPT   Cambia el símbolo del sistema del intéprete de comandos.\n\
-PUSHD    Guarda el directorio actual y después lo cambia.\n\
-RD       Borra un directorio.\n\
-REM      Marca comentarios en archivos por lotes.\n\
-REN      Renombra un archivo o varios archivos.\n\
-RENAME   Renombra un archivo o varios archivos.\n\
-RMDIR    Borra un directorio.\n\
-SCREEN   Mueve el cursor y opcionalmente escribe un texto.\n\
-SET      Muestra, cambia o borra variables del entorno de la ventana.\n\
-SHIFT    Marca la posición de parámetros remplazables en un archivo por lotes.\n"
-
-STRING_HELP2, "START    Abre una ventana separada para ejecutar un programa o comando específicod.\n\
-         Ejecuta CMD.\n\
-TIME     Muestra o cambia la hora del sistema.\n\
-TIMER    Permite al usuario diez paradas para ver.\n\
-TITLE    Configura el título de la ventama de la sesión de CMD.EXE.\n\
-TYPE     Muestra el contenido de un archivo de texto.\n\
-VER      Muestra la versión de ReactOS.\n\
-VERIFY   Le dice a ReactOS que verifique que cada archivo se escriba.\n\
-         corectamente en el disco.\n\
-VOL      Muestra la etiqueta de volumen y el número de serie del disco.\n"
-
-
-STRING_CHOICE_OPTION,         "SN"
-STRING_COPY_OPTION,           "SNT"
-
-
-STRING_ALIAS_ERROR,          "¡Linea de comandos demasiado larga tras la expansión del alias!\n"
-STRING_BATCH_ERROR,          "Error abriendo el archivo por lotes\n"
-STRING_CHCP_ERROR1,          "Página de códigos activa: %u\n"
-STRING_CHCP_ERROR4,          "Código de página inválido\n"
-STRING_CHOICE_ERROR,         "Opción inválida. Se esperaba el formato: /C[:]options"
-STRING_CHOICE_ERROR_TXT,     "Opción inválida. Se esperaba el formato: /T[:]c,nn"
-STRING_CHOICE_ERROR_OPTION,  "Opción ilegal: %s"
-STRING_CMD_ERROR1,           "No se puede redirigir la entrada del archivo %s\n"
-STRING_CMD_ERROR2,           "Error creando archivo temporal para la pila de datos\n"
-STRING_CMD_ERROR3,           "No se puede redirigir el archivo %s\n"
-STRING_CMD_ERROR4,           "Ejecutando %s...\n"
-STRING_CMD_ERROR5,           "Ejecutando cmdexit.bat...\n"
-STRING_COLOR_ERROR1,         "¡Mismos colores! (El color de frente y de fondo no pueden ser el mismo)"
-STRING_COLOR_ERROR2,         "Error en la especificación del color"
-STRING_COLOR_ERROR3,         "Color %x\n"
-STRING_COLOR_ERROR4,         "¡Error: mismos colores!"
-STRING_CONSOLE_ERROR,        "Error desconocido: %d\n"
-STRING_COPY_ERROR1,          "Error: No se puede abrir el origen - %s!\n"
-STRING_COPY_ERROR2,          "Error: ¡No se puede copiar sobre si mismo!\n"
-STRING_COPY_ERROR3,          "¡Error escribiendo destino!\n"
-STRING_COPY_ERROR4,          "Error: ¡No implementado aún!\n"
-STRING_DATE_ERROR,           "Fecha incorrecta."
-STRING_DEL_ERROR5,           "¡El archivo %s va a ser borrado!"
-STRING_DEL_ERROR6,           "¿Estás seguro (S/N)?"
-STRING_DEL_ERROR7,           "Borrando: %s\n"
-STRING_ERROR_ERROR1,         "¡Error desconocido! Códige de error: 0x%lx\n"
-STRING_ERROR_ERROR2,         "Error de sintaxsis"
-STRING_FOR_ERROR1,           "Falta 'in' para la declaración."
-STRING_FOR_ERROR2,           "No se encontraron las parénteris."
-STRING_FOR_ERROR3,           "Falta 'do'." 
-STRING_FOR_ERROR4,           "No hay comando después de 'do'."
-STRING_FREE_ERROR1,          "Unidad errónea."
-STRING_FREE_ERROR2,          "Sin etiqueta"
-STRING_GOTO_ERROR1,          "No se especifico etiqueta para GOTO"
-STRING_GOTO_ERROR2,          "La etiqueta '%s' no se encuentra\n"
-
-STRING_MOVE_ERROR1,          "[OK]\n"
-STRING_MOVE_ERROR2,          "[Error]\n"
-
-STRING_REN_ERROR1,           "MoveFile() falló. Error: %lu\n"
-
-STRING_START_ERROR1,         "¡No hay soporte para archivos por lotes en este momento!"
-
-STRING_TIME_ERROR1,          "Hora incorrecta."
-
-STRING_TYPE_ERROR1,          "Opción incorrecta '/%s'\n"
-
-STRING_WINDOW_ERROR1,        "Ventana no encontrada"
-
-
-STRING_ERROR_PARAMETERF_ERROR,     "Formato del parámetro incorrecto - %c\n"
-STRING_ERROR_INVALID_SWITCH,       "Parámetro incorrecto - /%c\n"
-STRING_ERROR_TOO_MANY_PARAMETERS,  "Demasiados parámetros - %s\n"
-STRING_ERROR_PATH_NOT_FOUND,       "Ruta no encontrada\n"
-STRING_ERROR_FILE_NOT_FOUND,       "Archivo no encontrado\n"
-STRING_ERROR_REQ_PARAM_MISSING,    "Prámetro requerido no encontrado\n"
-STRING_ERROR_INVALID_DRIVE,        "Especificación de unidad errónea\n"
-STRING_ERROR_INVALID_PARAM_FORMAT, "Formato de parámetro erróneo - %s\n"
-STRING_ERROR_BADCOMMAND,           "Comando o nombre de archivo erróneo\n"
-STRING_ERROR_OUT_OF_MEMORY,        "Error fuera de memoria.\n"
-STRING_ERROR_CANNOTPIPE,           "¡Error!  ¡No se puede apilar!  ¡No se puede abrir el archivo temporal!\n"
-STRING_ERROR_D_PAUSEMSG,           "Pulsa una tecla para continuar . . ."
-STRING_ERROR_DRIVER_NOT_READY,     "La unidad no está lista"
-
-STRING_PATH_ERROR,                 "CMD: No está en el entorno '%s'\n"
-
-STRING_CMD_SHELLINFO,              "\nIntérprete de comandos de ReactOS"
-STRING_VERSION_RUNVER,             " corriendo en %s"
-STRING_COPY_FILE ,                 "        %d archivo(s) copado(s)\n"
-STRING_DELETE_WIPE,                "Limpiado"
-STRING_FOR_ERROR,                  "Especición de variable errónea."
-STRING_SCREEN_COL,                 "Valor inválido de columna"
-STRING_SCREEN_ROW,                 "Valor inválido de fila"
-STRING_TIMER_TIME                  "El temporizador %d es %s: "
-
-STRING_INVALID_OPERAND,            "Operador erróneo.\n"
-STRING_EXPECTED_CLOSE_PAREN,       "Se esperaba ')'.\n"
-STRING_EXPECTED_NUMBER_OR_VARIABLE,"Se esperaba un número o nombre de variable.\n"
-STRING_SYNTAX_COMMAND_INCORRECT,   "La sintaxis del comando es incorrecta.\n"
-
-}
-
diff --git a/reactos/subsys/system/cmd/Fr.rc b/reactos/subsys/system/cmd/Fr.rc
deleted file mode 100644 (file)
index 8e1c837..0000000
+++ /dev/null
@@ -1,575 +0,0 @@
-#include "windows.h"
-#include "resource.h"
-/*
- * French resources
- * Sylvain Pétréolle  2005
- */
-
-LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL
-STRINGTABLE DISCARDABLE
-{
-
-STRING_ATTRIB_HELP,    "Affiche ou change des attributs de fichiers.\n\n\
-ATTRIB [+R | -R] [+A | -A] [+S | -S] [+H | -H] file ...\n\
-       [/S [/D]]\n\n\
-  +   Positionne un attribut\n\
-  -   Enlève un attribut\n\
-  R   Fichier en lecture seule\n\
-  A   Fichier archive\n\
-  S   Fichier système\n\
-  H   Fichier caché\n\
-  /S  Traite les fichiers correspondants dans le répertoire courant\n\
-        et tous les sous-répertoires\n\
-  /D  Traite également les répertoires\n\n\
-Taper ATTRIB sans paramètre pour afficher les attributs de tous les fichiers."
-
-STRING_ALIAS_HELP,  "Positionne, enlève ou affiche les alias.\n\n\
-ALIAS [alias=[commande]]\n\n\
-  alias     Nom de l'alias.\n\
-  commande  Texte à substituer à l'alias.\n\n\
-Pour afficher tous les alias:\n\
-  ALIAS\n\n\
-Pour créer ou remplacer un alias existant:\n\
-  ALIAS da=dir a:\n\n\
-Pour effacer un alias de la liste des alias :\n\
-  ALIAS da="
-
-STRING_BEEP_HELP, "Emet un bip par le haut-parleur système.\n\nBEEP"
-
-STRING_CALL_HELP, "Appelle un programme batch depuis un autre.\n\n\
-CALL [lecteur:][chemin]fichier [paramètre-batch]\n\n\
-  paramètre-batch  Spécifie les paramètres nécessaires au \n\
-                   programme batch."
-
-STRING_CD_HELP,      "Change ou affiche le répertoire courant\n\n\
-  CHDIR [lecteur:][chemin]\n\
-  CHDIR[..|-]\n\
-  CD [lecteur:][chemin]\n\
-  CD[..|-]\n\n\
-  ..   répertoire parent\n\
-  -    répertoire précédent\n\n\
-Taper CD lecteur: pour affiche le répertoire courant sur le disque indiqué.\n\
-Taper CD sans paramètre pour afficher le répertoire courant du disque actuel.\n"
-
-STRING_CHCP_HELP,   "Affiche ou change la page de codes active.\n\n\
-CHCP [nnn]\n\n\
-  nnn   Indique la page de codes .\n\n\
-Taper CHCP sans paramètre pour afficher la page de codes active."
-
-STRING_CHOICE_HELP, "Demande à l'utilisateur de choisir parmi plusieurs choix.\n\n\
-CHOICE  [/C[:]choix][/N][/S][/T[:]c,nn][texte]\n\n\
-  /C[:]choix    Spécifier les touches disponibles. Choix par défaut: ON.\n\
-  /N            Ne pas afficher les choix disponibles et ? à la fin\n\
-                du texte d'invite.\n\
-  /S            Traiter les touches comme différentes si ce sont\n\
-                des majuscules ou minuscules.\n\
-  /T[:]c,nn     Choix par défaut après nn secondes.\n\
-  texte         Texte d'invite à afficher.\n\n\
-ERRORLEVEL est modifié à l'offset de la touche enfoncée parmi les choix."
-
-STRING_CLS_HELP, "Efface l'écran.\n\nCLS"
-
-STRING_CMD_HELP1, "\nCommandes internes disponibles :\n"
-
-STRING_CMD_HELP2, "\nFonctions disponibles :"
-
-STRING_CMD_HELP3,"  [alias]"
-
-STRING_CMD_HELP4,"  [historique]"
-
-STRING_CMD_HELP5,"  [complétion des noms de fichiers façon unix]"
-
-STRING_CMD_HELP6,"  [pile de répertoires]"
-
-STRING_CMD_HELP7,"  [redirections et piping]"
-
-STRING_CMD_HELP8, "Démarre une nouvelle instance de l'interpréteur de commandes de ReactOS.\n\n\
-CMD [/[C|K] commande][/P][/Q][/T:ap]\n\n\
-  /C commande  Lance la commande spécifiée et se termine.\n\
-  /K commande  Lance la commande spécifiée et reste en mémoire.\n\
-  /P           CMD devient permanent et lance autoexec.bat\n\
-               (ne peut être terminé).\n\
-  /T:ap        Changer la couleur d'arrière/premier plan\n\
-               (voir la commande COLOR.)"
-
-
-STRING_COLOR_HELP1, "Change les couleurs de premier et d'arrière plan.\n\n\
-COLOR [attr [/F]] \n\n\
-  attr        Spécifie l'attribut des couleurs de la console\n\
-  /F          remplit la console avec l'attribut de couleur\n\n\
-Il y a trois façons de spécifier les couleurs :\n\
-1) [bright] nom on [bright] nom (seules les trois premières lettres \n\
-sont nécessaires)\n\
-2) décimal on décimal\n\
-3) deux chiffres hexadécimaux\n\n\
-Les couleurs sont:\n\
-déc  hex  nom           déc  hex  nom\n\
-0    0    Black(Noir)    8   8    Gray(Bright black)\n\
-1    1    Blue(Bleu)     9   9    Bright Blue\n\
-2    2    Green(Vert)   10   A    Bright Green\n\
-3    3    Cyan          11   B    Bright Cyan\n\
-4    4    Red(Rouge)    12   C    Bright Red\n\
-5    5    Magenta       13   D    Bright Magenta\n\
-6    6    Yellow(Jaune) 14   E    Bright Yellow\n\
-7    7    White(Blanc)  15   F    Bright White"
-
-STRING_COPY_HELP1,  "Ecraser %s (Oui/Non/Tous)? "
-
-STRING_COPY_HELP2, "Copie un ou plusieurs fichiers vers une autre destination.\n\n\
-COPY [/V][/Y|/-Y][/A|/B] source [/A|/B]\n\
-     [+ source [/A|/B] [+ ...]] [destination [/A|/B]]\n\n\
-  source       Indique le ou les fichiers à copier.\n\
-  /A           Spécifie qu'il s'agit d'un fichier texte ASCII.\n\
-  /B           Spécifie qu'il s'agit d'un fichier binaire.\n\
-  destination  Indique le répertoire ou le nom de fichier\n\
-               pour le(s) nouveau(x) fichier(s).\n\
-  /V           Vérifie que les fichier ont été copiés correctement.\n\
-  /Y           Supprime l'invite de confirmation en cas d'écrasement\n\
-               d'un fichier destination existant.\n\
-  /-Y          Affiche un invite de confirmation en cas d'écrasement\n\
-               d'un fichier destination existant.\n\n\
-Le switch /Y peut être présent dans la variable d'environnement COPYCMD.\n"
-
-STRING_DATE_HELP1, "\nEntrer la nouvelle date (mm%cdd%cyyyy): "
-
-STRING_DATE_HELP2, "\nEntrer la nouvelle date (dd%cmm%cyyyy): "
-
-STRING_DATE_HELP3, "\nEntrer la nouvelle date (yyyy%cmm%cdd): "
-
-STRING_DATE_HELP4, "Affiche ou règle la date.\n\n\
-DATE [/T][date]\n\n\
-  /T    affiche seulement\n\n\
-Taper DATE sans paramètre pour afficher la date courante\n\
-et une invite pour entrer la nouvelle date.\n\
-Appuyer sur ENTREE pour conserver la même date."
-                               
-STRING_DEL_HELP1,  "Efface un ou plusieurs fichiers.\n\n\
-DEL [/N /P /T /Q /W /Y /Z] fichier ...\n\
-DELETE [/N /P /T /Q /W /Y /Z] fichier ...\n\
-ERASE [/N /P /T /Q /W /Y /Z] fichier ...\n\n\
-  fichier  Specifie le(s) fichier(s) à effacer.\n\n\
-  /N    Rien.\n\
-  /P    Demande. Demande avant d'effacer pour chaque fichier.\n\
-  /T    Total. Affiche le total de fichiers effacés et l'espace disque libéré.\n\
-  /Q    Silencieux.\n\
-  /W    Wipe. Ecrase le fichier avec des nombres aléatoire avant d'effacer.\n\
-  /Y    Oui. Efface, même *.*, sans demander.\n\
-  /Z    Zap. Efface les fichiers cachés, en lecture seule et systèmes.\n"
-
-STRING_DEL_HELP2, "Tous les fichiers du répertoire seront effacés!\n\
-Etes vous sûr(e) (O/N)?"
-STRING_DEL_HELP3, "    %lu fichier effacé\n"
-STRING_DEL_HELP4, "    %lu fichiers effacés\n"
-
-STRING_DELAY_HELP, "Attend pendant n secondes ou millisecondes\n\
-DELAY [/m]n\n\n\
-  /m          spécifie que n est en millisecondes\n\
-              sinon n est en secondes"
-
-STRING_DIR_HELP1, "DIR [lecteur:][chemin][fichier] [/A[[:]attributs]] [/B] [/C] [/D] [/L] [/N]\n\
-  [/O[[:]ordredetri]] [/P] [/Q] [/S] [/T[[:]heure]] [/W] [/X] [/4]\n\n\
-  [lecteur:][chemin][fichier]\n\
-         Spécifie le disque, le répertoire, et/ou les fichiers à lister.\n\n\
-  /A          Affiche les fichiers avec les attributs indiqués.\n\
-  attributs    D  Répertoires           R  Fichiers en lecture seule\n\
-               H  Fichiers cachés       A  Fichiers prêts à etre archivés\n\
-               S  Fichiers systèmes     -  Préfixe signifiant non\n\
-  /B          Utilise le format court (pas d'informations ni de résumé).\n\
-  /C          Affiche le séparateur de milliers dans les tailles de fichier.\n\
-              C'est l'option par défaut. Utiliser /-C pour désactiver \n\
-              l'affichage du séparateur.\n\
-  /D          Identique au format large mais les fichiers sont triés\n\
-              par colonne.\n\
-  /L          Utilise les minuscules.\n\
-  /N          Nouveau format de liste longue où les noms de fichiers sont \n\
-              sur la droite.\n\
-  /O          Lister les fichier de façon triée.\n\
-  ordre de     N  Par nom (alphabétique) S  Par taille (plus petit d'abord)\n\
-  tri          E  Par extension tique)   D  Par date (plus vieux d'abord)\n\
-               G  Répertoires d'abord    -  Préfixe pour inverser l'ordre\n\
-  /P          S'arrête après chaque page d'information.\n\
-  /Q          Affiche le propriétaire du fichier.\n\
-  /S          Affiche les fichiers dans le répertoire indiqué et\n\
-              tous les sous-répertoires.\n\
-  /T          Contrôle quel champ de temps sera affiché ou utilisé\n\
-              pour le tri\n\
-              C  Création\n\
-              A  Dernier accès\n\
-              W  Dernière modification\n\
-  /W          Utilise le format de liste large.\n\
-  /X          Ceci affiche les noms de fichiers courts pour les noms \n\
-              de fichiers longs. Le format est comme pour /N avec\n\
-              le nom de fichier court inséré avant le nom de fichier long.\n\
-              S'il n'y a pas de nom court, des espaces seront affichés.\n\
-  /4          Affiche l'année sur quatre chiffres.\n\n\
-Les paramètres peuvent être mémorisés dans la variable d'environnement DIRCMD.\n\
-Modifier les paramètres mémorisés avec un - (tiret)--par exemple, /-W.\n"
-
-STRING_DIR_HELP2, " Le nom de volume du lecteur %c est %s\n"
-STRING_DIR_HELP3, " Le lecteur %c n'a pas de nom de volume\n"
-STRING_DIR_HELP4, " Le numéro de série du volume est %04X-%04X\n"
-STRING_DIR_HELP5, "\n   Total de fichiers listés :\n%16i Fichier(s)% 14s octets\n"
-STRING_DIR_HELP6, "%16i fichier(s)% 15s octets\n"
-STRING_DIR_HELP7, "\n Répertoire de %s\n\n"
-STRING_DIR_HELP8, "%16i Rep(s)% 14s octets\n"
-STRING_DIRSTACK_HELP1, "Stocke le répertoire courant pour utilisation avec la commande POPD,\n\
-ensuite change de répertoire vers le répertoire spécifié.\n\n\
-PUSHD [chemin | ..]\n\n\
-  chemin      Spécifie le répertoire qui deviendra le répertoire courant"
-
-STRING_DIRSTACK_HELP2, "Change de réperoire vers le répertoire stocké par la commande PUSHD\n\nPOPD"
-
-STRING_DIRSTACK_HELP3, "Affiche le contenu de la pile de répertoires.\n\nDIRS"
-
-STRING_DIRSTACK_HELP4, "Pile de répertoires vide."
-
-STRING_ECHO_HELP1,  "Affiche un message sans retour chariot ni passage à la ligne.\n\n\
-  ECHOS message"
-
-STRING_ECHO_HELP2,  "Affiche un message sur le canal d'erreur.\n\n\
-  ECHOERR message\n\
-  ECHOERR.           Affiche une ligne vide sur le canal d'erreur."
-
-STRING_ECHO_HELP3, "Affiche un message sur le canal d'erreur sans retour chariot\n\
-ni passage à la ligne.\n\n\
-  ECHOSERR message"
-
-STRING_ECHO_HELP4, "Affiche un message ou bascule l'affichage des commandes sur on ou off.\n\n\
-  ECHO [ON | OFF]\n\
-  ECHO [message]\n\
-  ECHO.             Affiche une ligne vide.\n\n\
-Taper ECHO sans paramètre pour afficher le réglage ECHO courant."
-
-STRING_ECHO_HELP5, "ECHO est %s\n"
-
-STRING_EXIT_HELP, "Sort de de l'interpréteur de commandes.\n\nEXIT"
-
-STRING_FOR_HELP1, "Exécute une commande donnée pour chaque fichier d'un ensemble de fichiers.\n\
-FOR %variable IN (ensemble) do commande [paramètres]\n\n\
-  %variable  Spécife un paramètre remplaçable.\n\
-  (ensemble) Spécifie un ensemble d'un ou plusieurs fichiers.\n\
-             Des jokers peuvent être utilisés.\n\
-  commande   Spécifie la commande à éxécuter pour chaque fichier.\n\
-  paramètres Spécifie les paramètres ou switchs pour la commande spécifiée.\n\n\
-Pour utiliser la comamnde FOR dans un programme batch,\n\
-utiliser %%variable au lieu de %variable."
-
-STRING_FREE_HELP1, "\nLe nom de volume du lecteur %s est %-11s\n\
-Le numéro de série est %s\n\
-  %16s octets d'espace disque total\n\
-  %16s octets utilisés\n\
-  %16s octets libres\n"
-
-STRING_FREE_HELP2, "Affiche les information d'un disque.\n\nFREE [lecteur: ...]"
-
-STRING_GOTO_HELP1,  "Dirige CMD vers une ligne nommée dans un script batch.\n\n\
-GOTO label\n\n\
-  label  Spécifie un champ texte utilisé dans un script batch comme un label.\n\n\
-Vous écrivez un label seul sur une ligne commençant par un deux-points.\n"
-
-STRING_IF_HELP1, "Exécute un traitement conditionnel dans des programmes batch.\n\n\
-  IF [NOT] ERRORLEVEL nombre commande\n\
-  IF [NOT] chaine1==chaine2 commande\n\
-  IF [NOT] EXIST nomfichier commande\n\
-  IF [NOT] DEFINED variable commande\n\n\
-NOT               CMD ne lancera la commande que si la condition est fausse.\n\
-ERRORLEVEL nombre La condition sera vraie si le dernier programme lancé\n\
-                  a retourné un code sortie égal ou supérieur à celui indiqué.\n\
-commande          Indique la commande à lancer si la condition est vérifiée.\n\
-chaine1==chaine2  La condition sera vraie si les deux chaines sont identiques.\n\
-EXIST nomfichier  La condition sera vraie si le fichier spécifié existe.\n\
-DEFINED variable  La condition sera vraie si la variable indiquée est définie."
-
-STRING_LABEL_HELP1, "Affiche ou change le nom de volume du disque.\n\nLABEL [disque:][nomdevolume]\n"
-
-STRING_LABEL_HELP2, "Le nom de volume du disque %c: est %s\n"
-STRING_LABEL_HELP3, "Le disque %c: n'a pas de nom de volume\n"
-STRING_LABEL_HELP4, "Le numéro de serie du volume est %04X-%04X\n"
-STRING_LABEL_HELP5, "Nom de volume (11 Caractères, ENTREE si aucun)? "
-
-STRING_LOCALE_HELP1, "L'heure actuelle est "
-
-STRING_MKDIR_HELP,   "Crée un répertoire.\n\n\
-MKDIR [lecteur:]chemin\nMD [lecteur:]chemin"
-
-STRING_MEMMORY_HELP1, "Affiche la quantité de mémoire système.\n\nMEMORY"
-
-STRING_MEMMORY_HELP2, "\n  %12s%% de charge mémoire.\n\n\
-  %13s octets de RAM physique au total.\n\
-  %13s octets de RAM physique disponible.\n\n\
-  %13s octets de fichier d'échange au total.\n\
-  %13s octets de fichier d'échange disponible.\n\n\
-  %13s octets de mémoire virtuelle au total.\n\
-  %13s octets de mémoire virtuelle disponible.\n"
-
-STRING_MISC_HELP1, "Appuyer sur une touche pour continuer...\n"
-
-STRING_MOVE_HELP1, "Ecraser %s (Oui/Non/Tous)? "
-
-STRING_MOVE_HELP2, "Déplace des fichiers ou renomme des fichiers et des répertoires.\n\n\
-Pouur déplacer un ou plusieurs fichiers:\n\
-MOVE [/N][lecteur:][nomfich1[,...] destination\n\n\
-Pour renommer un répertoire:\n\
-MOVE [/N][lecteur:][chemin]nomrep1 nomrep2\n\n\
-  [lecteur:][chemin]nomfich1  Indique l'endroit et le nom du ou des fichiers\n\
-                              que vous voulez déplacer.\n\
-  /N                          Nothing. Do everything but move files or directories.\n\n\
-Limitations actuelles :\n\
-  - Vous ne pouvez pas déplacer un fichier/répertoire d'un disque à un autre.\n"
-
-STRING_MSGBOX_HELP, "Affiche une boite de dialogue et retourne la réponse de l'utilisateur\n\n\
-MSGBOX type ['titre'] prompt\n\n\
-type          boutons affichés\n\
-              les valeurs possibles sont: OK, OKCANCEL,\n\
-              YESNO, YESNOCANCEL\n\
-titre         titre de la boite de message\n\
-prompt        texte affiché par la boite de dialogue \n\n\n\
-ERRORLEVEL est modifié suivant le bouton pressé:\n\n\
-YES  :  10    |  NO      :  11\n\
-OK   :  10    |  CANCEL  :  12\n"
-
-STRING_PATH_HELP1, "Affiche ou modifie le chemin de recherche pour les fichiers éxécutables.\n\n\
-PATH [[lecteur:][chemin;...]]\nPATH ;\n\n\
-Taper PATH ; pour effacer tous les réglages courants\n\
-et indiquer à l'interpréteur de commandes\n\
-de chercher seulement dans le répertoire courant.\n\
-Taper PATH sans paramètres pour afficher le chemin courant.\n"
-
-STRING_PAUSE_HELP1, "Stoppe l'éxécution d'un fichier batch et affiche le message suivant:\n\
-'Appuyer sur une touche pour continuer...' ou un message défini\n\
-par l'utilisateur.\n\n\
-PAUSE\n\
-PAUSE [message]"
-
-STRING_PROMPT_HELP1, "Change l'invite de commandes.\n\n\
-PROMPT [texte]\n\n\
-  texte   Indique le nouvel invite de commandes.\n\n\
-L'invite de commandes peut être composé de caractères normaux et\n\
-des caractères spéciaux suivants:\n\n\
-  $A   & (Et commercial)\n\
-  $B   | (pipe)\n\
-  $C   ( (parenthèse ouvrante)\n\
-  $D   Date courante\n\
-  $E   Code Escape (code ASCII 27)\n\
-  $F   ) (parenthèse fermante)\n\
-  $G   > (signe supérieur à)\n\
-  $H   Backspace (efface le caractère précédent)\n\
-  $L   < (signe inférieur à)\n\
-  $N   Lecteur courant\n\
-  $P   Lecteur et chemin courants\n\
-  $Q   = (signe égale)\n\
-  $T   Heure courante\n\
-  $V   Numéro de version de ReactOS\n\
-  $_   Retour chariot/saut de ligne\n\
-  $$   $ (signe dollar)"
-
-STRING_PROMPT_HELP2, "  $+   Affiche la hauteur de la pile de répertoires"
-
-STRING_PROMPT_HELP3, "\nTaper PROMPT sans paramètres pour changer l'invite à celui défini par défaut."
-
-STRING_REM_HELP, "Démarrer une ligne de commentaire dans un fichier batch.\n\nREM [Commentaire]"
-
-STRING_REN_HELP1, "Renomme un(des) fichier(s)/répertoire(s)\n\
-RENAME [/E /N /P /Q /S /T] ancien_nom ... nouveau_nom\n\
-REN [/E /N /P /Q /S /T] ancien_nom ... nouveau_nom\n\n\
-  /E    Pas de messages d'erreur.\n\
-  /N    Rien.\n\
-  /P    Demande de confirmation avant de renommer chaque fichier.\n\
-        (Non implémenté!)\n\
-  /Q    Silencieux.\n\
-  /S    Renommer les sous-répertoires.\n\
-  /T    Affiche le nombre total de fichiers renommés.\n\n\
-Vous ne pouvez indiquez un autre lecteur/chemin pour la destination.\n\
-Utiliser la commande MOVE dans ce but."
-
-STRING_REN_HELP2, "    %lu fichier renommé\n"
-
-STRING_REN_HELP3, "    %lu fichiers renommés\n"
-
-STRING_RMDIR_HELP,   "Efface un répertoire.\n\n\
-RMDIR [lecteur:]chemin\nRD [lecteur:]chemin"  
-
-STRING_SCREEN_HELP, "Déplace le curseur, optionnellement affiche du texte\n\n\
-SCREEN lig col [texte]\n\n\
-  lig         ligne à laquelle déplacer le curseur\n\
-  col         colonne à laquelle déplacer le curseur"
-
-STRING_SET_HELP, "Affiche, modifie ou efface des variables d'environnement.\n\n\
-SET [variable[=][chaine]]\n\n\
-  variable  Indique le nom de la variable d'environnement.\n\
-  chaine    Indique une série de caractères à assigner à la variable.\n\n\
-Taper SET sans paramètres pour afficher les variables d'environnement courantes.\n"
-
-STRING_SHIFT_HELP, "Change la position de paramètres remplaçables dans un fichier batch.\n\n\
-SHIFT [DOWN]"
-
-STRING_START_HELP1, "Lance une commande.\n\n\
-START commande\n\n\
-  commande    Indique la commande à lancer.\n\n\
-Pour le moment toutes les commandes sont lancées de façon asynchrone.\n"
-
-STRING_TITLE_HELP, "Change le titre de la fenêtre de l'invite de commandes.\n\n\
-TITLE [chaine]\n\n\
-chaine       Indique le titre de la fenêtre de l'invite de commandes."
-
-STRING_TIME_HELP1, "Affiche ou modifie l'heure système.\n\n\
-TIME [/T][heure]\n\n\
-  /T    affiche seulement\n\n\
-Taper TIME sans paramètres pour afficher l'heure courante et une invite\n\
-pour la modifier.  Presser la touche ENTREE pour garder la même heure."
-
-STRING_TIME_HELP2, "Entrer la nouvelle heure: "
-
-STRING_TIMER_HELP1, "Ecoulé %d msecs\n"
-
-STRING_TIMER_HELP2, "Ecoulé %02d%c%02d%c%02d%c%02d\n"
-
-STRING_TIMER_HELP3, "Permet l'utilisation de dix chronomètres.\n\n\
-TIMER  [ON|OFF] [/S] [/n] [/Fn]\n\n\
-  ON          Démarre le chronomètre\n\
-  OFF         Stoppe le chronomètre\n\
-  /S          Split time. Return stopwach split\n\
-              time without changing its value\n\
-  /n          Indique le numéro du chronomètre.\n\
-              Les chronomètres disponibles vont de 0 à 10.\n\
-              Si non spécifié, le chronomètre par défaut est 1\n\
-  /Fn         Format de sortie\n\
-              n peut être :\n\
-                    0    millisecondes\n\
-                    1    hh%cmm%css%cdd\n\n\
-Si aucun de ON, OFF or /S n'est spécifié la commande\n\
-changera l'état du chronomètre sélectionné\n\n"
-
-STRING_TYPE_HELP1, "Affiche le contenu de fichiers textes.\n\nTYPE [lecteur:][chemin]nomfich"
-
-STRING_VERIFY_HELP1, "Cette commande ne fait rien!!\n\
-Spécifie s'il faut verifier que vos fichiers sont écrits correctement.\
-\n\n\
-VERIFY [ON | OFF]\n\n\
-Taper VERIFY sans paramètres pour afficher le réglage de VERIFY."
-
-STRING_VERIFY_HELP2, "VERIFY est %s.\n"
-
-STRING_VERIFY_HELP3, "Vous devez indiquer ON ou OFF."
-
-STRING_VERSION_HELP1, "Affiche les information de version du shell\n\n\
-VER [/C][/R][/W]\n\n\
-  /C  Displays credits.\n\
-  /R  Displays redistribution information.\n\
-  /W  Displays warranty information."
-
-STRING_VERSION_HELP2, " comes with ABSOLUTELY NO WARRANTY; for details\n\
-type: `ver /w'. This is free software, and you are welcome to redistribute\n\
-it under certain conditions; type `ver /r' for details. Type `ver /c' for a\n\
-listing of credits."
-
-STRING_VERSION_HELP3, "\n This program is distributed in the hope that it will be useful,\n\
- but WITHOUT ANY WARRANTY; without even the implied warranty of\n\
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n\
- GNU General Public License for more details."
-
-STRING_VERSION_HELP4, "\n This program is free software; you can redistribute it and/or modify\n\
- it under the terms of the GNU General Public License as published by\n\
- the Free Software Foundation; either version 2 of the License, or\n\
- (at your option) any later version."
-
-STRING_VERSION_HELP5, "\nEnvoyer les rapports d'erreur à <ros-dev@reactos.org>.\n\
-Les mises à jour sont disponibles à : http://www.reactos.org"
-
-STRING_VERSION_HELP6, "\nVersion FreeDOS écrite par:\n"
-
-STRING_VERSION_HELP7, "\nVersion ReactOS écrite par:\n"
-
-STRING_VOL_HELP1, " Le nom de volume du lecteur %c: est %s\n"
-STRING_VOL_HELP2, " Le volume dans le lecteur %c: n'a pas de nom\n"
-STRING_VOL_HELP3, " Le numéro de série du volume est %04X-%04X\n"
-STRING_VOL_HELP4, "Affiche le nom de volume et le numéro de série du disque s'ils existent.\n\nVOL [lecteur:]\n"
-
-STRING_WINDOW_HELP1, "Change l'aspect de la fenêtre de la console\n\n\
-WINDOW [/POS[=]gauche,haut,largeur,hauteur]\n\
-              [MIN|MAX|RESTORE] ['titre']\n\n\
-/POS          indique la position et les dimensions de la fenêtre\n\
-MIN           minimise la fenêtre\n\
-MAX           maximise la fenêtre\n\
-RESTORE       restaure la fenêtre"
-
-STRING_WINDOW_HELP2, "Change l'aspect de la fenêtre de la console\n\n\
-WINDOW [/POS[=]gauche,haut,largeur,hauteur]\n\
-              [MIN|MAX|RESTORE] ['titre']\n\n\
-/POS          indique la position et les dimensions de la fenêtre\n\
-MIN           minimise la fenêtre\n\
-MAX           maximise la fenêtre\n\
-RESTORE       restaure la fenêtre\n\
-titre         titre de la fenêtre"
-
-STRING_CHOICE_OPTION         "ON"
-STRING_COPY_OPTION,          "ONT"
-
-STRING_ALIAS_ERROR,          "Ligne de commande trop longue après remplacement de l'alias!\n"
-STRING_BATCH_ERROR,          "Erreur à l'ouverture du fichier batch\n"
-STRING_CHCP_ERROR1,          "Page de codes actuelle : %u\n"
-STRING_ERROR_INVALID_PARAM_FORMAT,          "Format de paramètre incorrect - %s\n"
-STRING_CHCP_ERROR4,          "Page de code invalide \n"
-STRING_CHOICE_ERROR,         "Option invalide. Format attendu: /C[:]options"
-STRING_CHOICE_ERROR_TXT,     "Option invalide. Format attendu: /T[:]c,nn"
-STRING_CHOICE_ERROR_OPTION,  "Option invalide : %s"
-STRING_CMD_ERROR1,           "Ne peut rediriger l'entrée depuis le fichier %s\n"
-STRING_CMD_ERROR2,           "Erreur à la création du fichier temporaire pour les données du pipe\n"
-STRING_CMD_ERROR3,           "Ne peut rediriger vers le fichier %s\n"
-STRING_CMD_ERROR4,           "Lance %s...\n"
-STRING_CMD_ERROR5,           "Lance cmdexit.bat...\n"
-STRING_COLOR_ERROR1,         "L'arrière plan et l'avant plan ne peuvent être de la même couleur"
-STRING_COLOR_ERROR2,         "Erreur dans la spécification des couleurs"
-STRING_COLOR_ERROR3,         "Couleur %x\n"
-STRING_COLOR_ERROR4,         "Erreur: même couleur!"
-STRING_CONSOLE_ERROR,        "Erreur inconnue: %d\n"
-STRING_COPY_ERROR1,          "Erreur: Ne peut ouvrir la source - %s!\n"
-STRING_COPY_ERROR2,          "Erreur: Ne peut copier le fichier sur lui-même!\n"
-STRING_COPY_ERROR3,          "Erreur à l'écriture de la destination!\n"
-STRING_COPY_ERROR4,          "Erreur: Non implémenté actuellement!\n"
-STRING_DATE_ERROR,           "Date invalide."
-STRING_DEL_ERROR5,           "Le fichier %s va être effacé ! "
-STRING_DEL_ERROR6,           "Etes vous sûr (O/N)?"
-STRING_DEL_ERROR7,           "Efface : %s\n"
-STRING_ERROR_ERROR1,         "Erreur inconnue! Code d'erreur : 0x%lx\n"
-STRING_ERROR_ERROR2,         "Erreur de syntaxe"
-STRING_FOR_ERROR1,           "'in' manquant."
-STRING_FOR_ERROR2,           "pas de parenthèse trouvée."
-STRING_FOR_ERROR3,           "'do' manquant."
-STRING_FOR_ERROR4,           "pas de commande après 'do'."
-STRING_FREE_ERROR1,          "Lecteur invalide"
-STRING_FREE_ERROR2,          "sans nom"
-STRING_GOTO_ERROR1,          "Pas de label indiqué pour GOTO"
-STRING_GOTO_ERROR2,          "Label '%s' non trouvé\n"
-
-STRING_MOVE_ERROR1,          "[OK]\n"
-STRING_MOVE_ERROR2,          "[Erreur]\n"
-
-STRING_PATH_ERROR,           "CMD: Pas dans l'environnement '%s'\n"
-
-STRING_REN_ERROR1,           "MoveFile() a échoué. Erreur: %lu\n"
-
-STRING_START_ERROR1,         "No batch support at the moment!"
-
-STRING_TIME_ERROR1,          "Heure invalide."
-
-STRING_TYPE_ERROR1,          "Option invalide '/%s'\n"
-
-STRING_WINDOW_ERROR1,        "Fenêtre non trouvée"
-
-
-STRING_ERROR_PARAMETERF_ERROR,     "Format du paramètre incorrect - %c\n"
-STRING_ERROR_INVALID_SWITCH,       "Paramètre invalide - /%c\n"
-STRING_ERROR_TOO_MANY_PARAMETERS,  "Trop de paramètres - %s\n"
-STRING_ERROR_PATH_NOT_FOUND,       "Chemin non trouvé\n"
-STRING_ERROR_FILE_NOT_FOUND,       "Fichier non trouvé\n"
-STRING_ERROR_REQ_PARAM_MISSING,    "Paramètre requis manquant\n"
-STRING_CMD_SHELLINFO,              "\n Interpréteur de ligne de commandes ReactOS"
-STRING_VERSION_RUNVER,             " tournant sur %s"
-STRING_COPY_FILE,                  "        %d fichier(s) copié(s)\n"
-STRING_DELETE_WIPE,                "effacé(s)"
-STRING_FOR_ERROR,                  "mauvaise variable spécifiée."
-STRING_SCREEN_COL,                 "valeur invalide pour col"
-STRING_SCREEN_ROW,                 "valeur invalide pour lig"
-STRING_TIMER_TIME                  "Le timer n°%d est %s: "
-}
diff --git a/reactos/subsys/system/cmd/Hu.rc b/reactos/subsys/system/cmd/Hu.rc
deleted file mode 100644 (file)
index 1f1b9c9..0000000
+++ /dev/null
@@ -1,623 +0,0 @@
-#include "resource.h"\r
-#include "windows.h"\r
-/*\r
- * Moved all hardcoded strings to En.rc.\r
- * By Magnus Olsen  2005\r
- * Hungarian resource állomány for ntvdm\r
- * Translation by Robert Horvath (talley at cubeclub.hu) 2005\r
- */\r
-\r
-LANGUAGE LANG_HUNGARIAN, SUBLANG_NEUTRAL\r
-STRINGTABLE DISCARDABLE\r
-{\r
-\r
-STRING_ATTRIB_HELP,    "Állományok attribútumok megjelenítése vagy beállításai.\n\n\\r
-ATTRIB [+R | -R] [+A | -A] [+S | -S] [+H | -H] állomány ...\n\\r
-       [/S [/D]]\n\n\\r
-  +   bekapcsol egy attribútumot\n\\r
-  -   kikapcsol egy attribútumot\n\\r
-  R   Írásvédett állomány\n\\r
-  A   Archiválandó állomány\n\\r
-  S   Rendszer állomány\n\\r
-  H   Rejtett állomány\n\\r
-  /S  Minden állomány módosítása a mappában és minden\n\\r
-      almappábanban\n\\r
-  /D  Mappákra is érvényesíti\n\n\\r
-Ha ATTRIB-ot paraméter nélkül írod be, megjeleníti a mappában található összes állományt és annak attribútumát.\n"\r
-\r
-STRING_ALIAS_HELP,  "Aliasok megjelenítése, hozzáadása és törlése\n\n\\r
-ALIAS [alias=[parancs]]\n\n\\r
-  alias    Alias neve.\n\\r
-  parancs  A szöveg amit behelyettesít.\n\n\\r
-Aliasok megjelenítése:\n\\r
-  ALIAS\n\n\\r
-Egy új hozzáadása vagy meglévõ helyettesítlse:\n\\r
-  ALIAS da=dir a:\n\n\\r
-Egy alias törlése:\n\\r
-  ALIAS da="\r
-\r
-STRING_BEEP_HELP, "Hangjelzés leadása a speakerbõl.\n\nBEEP\n"\r
-\r
-STRING_CALL_HELP, "Kötegelt parancsfájl meghívása egy másikból.\n\n\\r
-CALL [kötet:][elérési_út]állomány [paraméterek]\n\n\\r
-  paraméterek  Itt adható meg a szükséges paraméterlista"\r
-\r
-STRING_CD_HELP,      "Az aktuális mappa nevének a megjelenítése vagy váltás másikra\n\n\\r
-CHDIR [/D][meghajtó:][elérési_út]\n\\r
-CHDIR[..|.]\n\\r
-CD [/D][meghajtó:][elérési_út]\n\\r
-CD[..|.]\n\n\\r
-  ..   Szülõ mappa\n\\r
-  /D   Megváltoztatja az aktuális mappát és meghajtót is.\n\n\\r
-Írd be, hogy 'CD meghajtó:' hogy ki írja az aktuális mappát.\n\\r
-Írd be a CD-t paraméterek nélkül, hogy megjelenítse az aktuális meghajtót és mappát (ugyanaz mint az elõzõ).\n"\r
-\r
-STRING_CHCP_HELP,   "Megjeleníti vagy megváltoztatja az aktív kódlapot.\n\n\\r
-CHCP [nnn]\n\n\\r
-  nnn   A használni kívánt kódlap száma.\n\n\\r
-Írd be a  CHCP paraméterek nélkül, hogy megjelenítse az aktív kódlapot.\n"\r
-\r
-STRING_CHOICE_HELP, "Vár a felhasználóra, hogy válasszon a felkínált lehetõségek közül.\n\n\\r
-CHOICE  [/C[:]választási lehetõségek][/N][/S][/T[:]c,nn][szöveg]\n\n\\r
-  /C[:]választási lehetõségek  Megengedett billentyûk. Alapértelmezett: YN. <-- Yes->Igen\n\\r
-  /N                           Elrejti a választási lehetõségeket és a kérdõjelet.\n\\r
-  /S                           Kis- és nagybetûk megkülönböztetése.\n\\r
-  /T[:]v,nn                    A v lehetõséget választja nn másodperc után.\n\\r
-  szöveg                       Megjelenítendõ szöveg.\n\n\\r
-Az ERRORLEVEL a válasz sorszámára lesz beállítva.\n"\r
-\r
-STRING_CLS_HELP, "Törli a képernyõt.\n\nCLS\n"\r
-\r
-STRING_CMD_HELP1, "\nElérhetõ belsõ parancsok:\n"\r
-\r
-STRING_CMD_HELP2, "\nElérhetõ lehetõségek:"\r
-\r
-STRING_CMD_HELP3,"  [aliasok]"\r
-\r
-STRING_CMD_HELP4,"  [elõzmények]"\r
-\r
-STRING_CMD_HELP5,"  [unix típusú állománynév kiegészítés]"\r
-\r
-STRING_CMD_HELP6,"  [mappa tár]"\r
-\r
-STRING_CMD_HELP7,"  [átirányítások és csõvezetékek]"\r
-\r
-STRING_CMD_HELP8, "Elindít egy új ReactOS parancssor értelmezõ.\n\n\\r
-CMD [/[C|K] parancs][/P][/Q][/T:eh]\n\n\\r
-  /C parancs  Végrehajtja a parancsot, majd kilép.\n\\r
-  /K parancs  Végrehajtja a parancsot, és tovább fut az értelmezõ.\n\\r
-  /P          Értelmezi az autoexec.bat állományt és a memóriában marad.\n\\r
-  /T:eh       COLOR parancs használata.\n"\r
-\r
-STRING_COLOR_HELP1, "A konzol elõ- és háttérszínét állítja be.\n\n\\r
-COLOR [eh [/-F]] \n\n\\r
-  eh          A konzol elõ- és háttérszínét állítja be.\n\\r
-  /-F         Nem frissíti az egész képernyõt\n\n\\r
-A színt két hexadecimális számjeggyel lehet beállítani\n\n\\r
-Az elérhetõ színek:\n\\r
-hex  név             hex  név\n\\r
-0    Fekete          8    Szürke\n\\r
-1    Sötétkék        9    Kék\n\\r
-2    Sötétzöld       A    Zöld\n\\r
-3    Sötétlila       B    Türkízkék\n\\r
-4    Bordó           C    Vörös\n\\r
-5    Ciklámen        D    Ciklámen\n\\r
-6    Olíva                  E    Sárga\n\\r
-7    Világos szürke  F    Fehér\n"\r
-\r
-STRING_COPY_HELP1,  "Felülírja a következõt: %s (Igen/Nem/Mind)? "\r
-\r
-STRING_COPY_HELP2, "Egy vagy több állományt másol a megadott helyre.\n\n\\r
-COPY [/V][/Y|/-Y][/A|/B] forrás [/A|/B]\n\\r
-     [+ forrás [/A|/B] [+ ...]] [cél [/A|/B]]\n\n\\r
-  forrás       Megadott állomány(ok)at fogja másolni.\n\\r
-  /A           Ez ASCII szöveg állomány.\n\\r
-  /B           Ez bináris állomány.\n\\r
-  cél          Megadja a cél mappát és/vagy az (új) állománynevet.\n\\r
-  /V           Ellenõrzi a másolást.\n\\r
-  /Y           Igennel válaszol kérdésnél.\n\\r
-  /-Y          Nemmel válaszol kérdésnél.\n\n\\r
-Az /Y kapcsolót a COPYCMD környezeti változóban is használható.\n"\r
-\r
-STRING_DATE_HELP1, "\nÚj dátum (hh%cnn%céééé): "\r
-\r
-STRING_DATE_HELP2, "\nÚj dátum (nn%chh%céééé): "\r
-\r
-STRING_DATE_HELP3, "\nÚj dátum (éééé%chh%cnn): "\r
-\r
-STRING_DATE_HELP4, "Megjeleníti vagy beállítja a rendszerdátumot.\n\n\\r
-DATE [/T][dátum]\n\n\\r
-  /T    Csak megjeleníti\n\n\\r
-Írd be a DATE parancsot paraméter nélkül, hogy megjelenítse a rendszer dátumot és bekérjen egy újat.\n\\r
-Nyomj ENTERT-t, ha nem akarsz változtatni.\n"\r
-                               \r
-STRING_DEL_HELP1, "Eltávolít egy vagy több állományt.\n\n\\r
-DEL [/N /P /T /Q /S /W /Y /Z /A[[:]attribútumok]] állomány ...\n\\r
-DELETE [/N /P /T /Q /S /W /Y /Z /A[[:]attribútumok]] állomány ...\n\\r
-ERASE [/N /P /T /Q /S /W /Y /Z /A[[:]attribútumok]] állomány ...\n\n\\r
-      állomány  Törlésre kijelöl állomány(ok).\n\n\\r
-  /N    Nem csinál semmit.\n\\r
-  /P    Rákérdezés minden állománynál.\n\\r
-  /T    Statisztika megjelenítése a végén.\n\\r
-  /Q    Csendes üzemmód.\n\\r
-  /W    Wipe. Overwrite the állomány with random numbers before deleting it.\n\\r
-  /Y    Minden válaszra igen. Figyelem, *.*-ot is törli!!\n\\r
-  /F    Rejtett, csak olvasható és rendszer állományokat is töröl.\n\\r
-  /S    Almappákban is törli az állományokat\n\\r
-  /A    Attribútumok alapján törli az állományokat.\n\\r
-        attributes\n\\r
-        R     Csak olvasható állománys\n\\r
-        S     Rendszer állomány\n\\r
-        A     Archivált állomány\n\\r
-        H     Rejtett állománys\n\\r
-        -     ""Nem"" prefix\n"\r
-\r
-STRING_DEL_HELP2, "Minden állomány törölve lesz a mappában!\nBiztosan ezt akarod (I/N)?"\r
-STRING_DEL_HELP3, "    %lu állomány törölve\n"\r
-STRING_DEL_HELP4, "    %lu állomány törölve\n"\r
-\r
-STRING_DELAY_HELP, "pause for n seconds or milliseconds\n\\r
-DELAY [/m]n\n\n\\r
-  /m          specifiy than n are milliseconds\n\\r
-              otherwise n are seconds\n"\r
-\r
-STRING_DIR_HELP1, "DIR [meghajtó:][elérési_út][állománynév] [/A[[:]attribútumok]] [/B] [/C] [/D] [/L] [/N]\n\\r
-  [/O[[:]rendezési_feltétel]] [/P] [/Q] [/S] [/T[[:]idõ]] [/W] [/X] [/4]\n\n\\r
-  [meghajtó:][elérési_út][állományname]\n\\r
-              Az adott hely állományait és mappáit jeleníti meg.\n\n\\r
-  /A          A megadott attribútumu állományokat jeleníti csak meg.\n\\r
-  attributes   D  Mappák                         R  Csak olvasható állomány\n\\r
-               H  Rejtett állomány               A  Archiválandó állomány\n\\r
-               S  Rendszer állomány               -  ""Nem"" prefix\n\\r
-  /B          Fejléc és összefoglaló nélkül.\n\\r
-  /C          Ezres elválasztó jel használata. Ez az alapértelmezett, /-C a kikapcsolása.\n\\r
-  /D          Széles megjelenítés, oszlop szerint rendezve.\n\\r
-  /L          Kisbetûk használata.\n\\r
-  /N          New long list format where állománynames are on the far right.\n\\r
-  /O          Rendezés az alábbiak szerint.\n\\r
-  sortorder    N  Név alapján (ABC sorrend)           S  Méret alapján (növekvõ)\n\\r
-               E  Kiterjesztés alapján (ABC sorrend)  D  Dátum/idõ alapján (legrégebbi elején)\n\\r
-               G  Mappák legelõl                      -  ""Nem"" prefixel fordított rendezés\n\\r
-  /P          Csak egy képernyõnyi adat megjelenítése egyszerre.\n\\r
-  /Q          Állomány tulajdonsosának megjelenítése.\n\\r
-  /S          Almappák tartalmát is megjeleníti.\n\\r
-  /T          Controls which time field displayed or used for sorting\n\\r
-  timefield   C  Létrehozás\n\\r
-              A  Utolsó megtekintés\n\\r
-              W  Utolsó módosítás\n\\r
-  /W          Széles megjelenítés.\n\\r
-  /X          This displays the short names generated for non-8dot3 állomány\n\\r
-              names.  The format is that of /N with the short name inserted\n\\r
-              before the long name. If no short name is present, blanks are\n\\r
-              displayed in its place.\n\\r
-  /4          Négy számjegyû év\n\n\\r
-A kapcsolók a DIRCMD környezeti változóban is lehetnek.\n"\r
-\r
-STRING_DIR_HELP2, " A (%c) meghajtóban található kötet %s\n"\r
-STRING_DIR_HELP3, " A (%c) meghajtóban található kötetnek nincs címkéje.\n"\r
-STRING_DIR_HELP4, " A kötet sorozatszáma: %04X-%04X\n"\r
-STRING_DIR_HELP5, "\n     Összes állomány:\n%16i Állomány(ok)% 14s bájt\n"\r
-STRING_DIR_HELP6, "%16i Mappa %15s bájt"\r
-STRING_DIR_HELP7, "\n %s tartalma\n\n"\r
-STRING_DIR_HELP8, "%16i Állomány %14s bájt\n"\r
-\r
-STRING_DIRSTACK_HELP1, "Megjegyzi az aktuális mappát, majd átvált egy máasikra.\n\n\\r
-PUSHD [elérési_út | ..]\n\n\\r
-  elérési_út        Ebbe a mappába fog átváltani\n"\r
-\r
-STRING_DIRSTACK_HELP2, "Visszalép a PUSHD által megjegyzett mappába.\n\nPOPD"\r
-\r
-STRING_DIRSTACK_HELP3, "Megjeleníti a megjegyzett mappákat.\n\nDIRS"\r
-\r
-STRING_DIRSTACK_HELP4, "Üres a tár"\r
-\r
-STRING_ECHO_HELP1,  "Megjeleníti a szöveget új sor nélkül.\n\n\\r
-  ECHOS szöveg"\r
-\r
-STRING_ECHO_HELP2,  "Displays a message to the standard error.\n\n\\r
-  ECHOERR szöveg\n\\r
-  ECHOERR.           Új sor"\r
-\r
-STRING_ECHO_HELP3, "Prints a messages to standard error output without trailing carridge return and line feed.\n\n\\r
-  ECHOSERR message"\r
-\r
-STRING_ECHO_HELP4, "Megjelenít egy szöveget, vagy beállítja a visszhangot.\n\n\\r
-  ECHO [ON | OFF]\n\\r
-  ECHO [üzenet]\n\\r
-  ECHO.             Új sor\n\n\\r
-Paraméter nélkül megjeleníti a visszang állapotát."\r
-\r
-STRING_ECHO_HELP5, "Az ECHO %s\n"\r
-\r
-STRING_EXIT_HELP, "Kilép a parancssor értelmezõbõl.\n\nEXIT\n"\r
-\r
-STRING_FOR_HELP1, "Végrehajt egy parancsot az összes fájlban a megadott mappákban\n\n\\r
-FOR %változó IN (csoport) DO parancs [paraméterek]\n\n\\r
-  %változó    A cserélhetõ paraméter.\n\\r
-  (csoport)   Állományok csoportja. Joker-karakterek megengedettek EZT KURVÁRA ÁTKELL FORDÍTANI :)) wildcardok helyett?.\n\\r
-  parancs     Ezt a parancsot hajtja végre minden egyes állománnyal.\n\\r
-  paraméterek Ezeket a paramétereket adja meg a parancsnak.\n\n\\r
-A batch állományban való haszálathoz %%változó kell a %változó helyett.\n"\r
-\r
-STRING_FREE_HELP1, "\nA (%s) meghajtóban lévõ kötet címkéje %-11s\n\\r
- Sorozatszám: %s\n\\r
-  %16s bájt a teljes hely\n\\r
-  %16s bájt használva\n\\r
-  %16s bájt szabad\n"\r
-\r
-STRING_FREE_HELP2, "Kötet méret információk.\n\nFREE [meghajtó: ...]\n"\r
-\r
-STRING_IF_HELP1, "Performs conditional processing in batch programs.\n\n\\r
-  IF [NOT] ERRORLEVEL number command\n\\r
-  IF [NOT] string1==string2 command\n\\r
-  IF [NOT] EXIST állományname command\n\\r
-  IF [NOT] DEFINED variable command\n\n\\r
-NOT               Specifies that CMD should carry out the command only if\n\\r
-                  the condition is false\n\\r
-ERRORLEVEL number Specifies a true condition if the last program run returned\n\\r
-                  an exit code equal or greater than the number specified.\n\\r
-command           Specifies the command to carry out if the condition is met.\n\\r
-string1==string2  Specifies a true condition if the specified text strings\n\\r
-                  match.\n\\r
-EXIST állományname    Specifies a true condition if the specified állományname exists.\n\\r
-DEFINED variable  Specifies a true condition if the specified variable is\n\\r
-                  defined.\n"\r
-\r
-STRING_GOTO_HELP1,  "Átirányít egy másik címkére a batch állományban.\n\n\\r
-GOTO címke\n\n\\r
-  címke  A megadott címkére fog ugrani az értelmezõ.\n\n\\r
-Egy címkét egy sorban lehet megadni, ':' -tal kezdve."\r
-\r
-STRING_LABEL_HELP1, "A kötet címkéjét megjeleníti, vagy megváltoztatja.\n\n\\r
-LABEL [meghajtó:] [új_címke]\n"\r
-\r
-STRING_LABEL_HELP2, "A (%c) meghajtóban lévõ kötet címkéje %s\n"\r
-STRING_LABEL_HELP3, "A (%c) megjajtóban lévõ kötetnek nincs címkéje.\n"\r
-STRING_LABEL_HELP4, "A kötet sorozatszáma %04X-%04X\n"\r
-STRING_LABEL_HELP5, "Új kötetcímke (11 betû, ENTER ha üres)? "\r
-\r
-STRING_LOCALE_HELP1, "Az aktuális idõ:"\r
-\r
-STRING_MKDIR_HELP,   "Létrehoz egy új mappát.\n\n\\r
-MKDIR [meghajtó:]path\nMD [meghajtó:]path"\r
-\r
-STRING_MEMMORY_HELP1, "Megjeleníti a memória statisztikát.\n\nMEMORY"\r
-\r
-STRING_MEMMORY_HELP2, "\n A memória %12s%%-a foglalt.\n\n\\r
-  %13s bájtnyi teljes fizikai memória.\n\\r
-  %13s bájtnyi elérhetõ memória.\n\n\\r
-  %13s bájt a lapozóállomány.\n\\r
-  %13s bájtnyi elérhetõ a lapozóállományban.\n\n\\r
-  %13s bájt a teljes virtuális memória.\n\\r
-  %13s bájtnyi elérhetõ a virtuális memóriából.\n"\r
-\r
-STRING_MISC_HELP1, "A folytatáshoz nyomj meg egy billentyût . . .\n"\r
-\r
-STRING_MOVE_HELP1, "Felülírja %s (Igen/Nem/Mind)? "\r
-\r
-STRING_MOVE_HELP2, "Áthelyezi és átnevezi az állományokat a mappákban.\n\n\\r
-Egy vagy több állomány áthelyezéséhez:\n\\r
-MOVE [/N][meghajtó:][elérési_út]állomány1[,...] cél\n\n\\r
-Mappa átnevezése:\n\\r
-MOVE [/N][meghajtó:][elérési_út]mappa1 mappa2\n\n\\r
-  [meghajtó:][elérési_út]állomány1  Átnevezendõ állományok forrása.\n\\r
-  /N                    Nem helyez át semmit.\n\n\\r
-Hiányosságok:\n\\r
-  - Nem lehet meghajtók között áthelyezni állományokat.\n"\r
-\r
-STRING_MSGBOX_HELP, "display a message box and return user responce\n\n\\r
-MSGBOX type ['title'] prompt\n\n\\r
-type          button displayed\n\\r
-              possible values are: OK, OKCANCEL,\n\\r
-              YESNO, YESNOCANCEL\n\\r
-title         title of message box\n\\r
-prompt        text displayed by the message box\n\n\n\\r
-ERRORLEVEL is set according the button pressed:\n\n\\r
-YES  :  10    |  NO      :  11\n\\r
-OK   :  10    |  CANCEL  :  12\n"\r
-\r
-STRING_PATH_HELP1, "Megjeleníti vagy beállítja a keresési útvonalakat.\n\n\\r
-PATH [[meghajtó:]elérési_út[;...]]\n\\r
-PATH ; Keresési útvonalak törlése\n\n\\r
-A PATH törléséhez a következõt írd be: PATH ;\n\\r
-Így csak az aktuális mappában fog keresni a CMD.\\r
-Paraméterek nélkül az érvényes keresési útvonalakat mutatja meg.\n"\r
-\r
-STRING_PROMPT_HELP1, "Parancssor beállítása.\n\n\\r
-PROMPT [szöveg]\n\n\\r
-  szöveg    Az új parancssor megadása.\n\n\\r
-A parancssor speciális kódokat is tartalmazhat:\n\n\\r
-  $A   & (és jel)\n\\r
-  $B   | (csõ)\n\\r
-  $C   ( (kezdõ rázójel)\n\\r
-  $D   Aktuális dátum\n\\r
-  $E   Escape-kód (ASCII 27-es kód)\n\\r
-  $F   ) (záró zárójel)\n\\r
-  $G   > ('nagyobb' jel)\n\\r
-  $H   Törlés (elötte lévõ karaktert törli)\n\\r
-  $L   < ('kissebb' jel)\n\\r
-  $N   Aktuális meghajtó\n\\r
-  $P   Aktuális meghajtó és mappa\n\\r
-  $Q   = (egyenlõség jel)\n\\r
-  $T   Aktuális idõ\n\\r
-  $V   OS verziószám\n\\r
-  $_   Újsor\n\\r
-  $$   $ (dollár jel)\n"\r
-\r
-STRING_PAUSE_HELP1, "Felfüggeszti a futást, és vár a felhasználóra. A következõ üzenet jelenik meg:\n\\r
-'A folytatáshoz nyomj meg egy billentyût . . .' vagy egy általad választott üzenet.\n\n\\r
-PAUSE [message]"\r
-\r
-STRING_PROMPT_HELP2, "  $+   Displays the current depth of the directory stack"\r
-\r
-STRING_PROMPT_HELP3, "\nHa paraméter nélkül beírod a PROMPT parancsot, vissza áll az alapértelmezettre a kijelzés."\r
-\r
-STRING_REM_HELP, "Megjegyzést jelölõ sor batch fájlokban.\n\nREM [megjegyzés]"\r
-\r
-STRING_RMDIR_HELP,   "Eltávolít egy mappát.\n\n\\r
-RMDIR [meghajtó:]elérési_út\nRD [meghajtó:]elérési_út"\r
-\r
-STRING_REN_HELP1, "Átnevez egy állományt.\n\n\\r
-RENAME [/E /N /P /Q /S /T] régi_név ... új_név\n\\r
-REN [/E /N /P /Q /S /T] régi_név ... új_név\n\n\\r
-  /E    Hibaüzenetek elrejtése.\n\\r
-  /N    Ne csináljon semmit    .\n\\r
-  /P    Minden állománynál rákérdez. (Még NEM mûködik!!)\n\\r
-  /Q    Csendes mûködés.\n\\r
-  /S    Almappákat is átnevez.\n\\r
-  /T    Összes átnevezett fájl és állomány.\n\n\\r
-Csak az aktuális meghajtón és mappában fog mûködni.\n\\r
-Ha ez nem elég, használd a MOVE parancsot."\r
-\r
-STRING_REN_HELP2, "    %lu állomány átnevezve\n"\r
-\r
-STRING_REN_HELP3, "    %lu állomány átnevezve\n"\r
-                \r
-STRING_SHIFT_HELP, "Eltolja a helyettesíthetõ paraméterek pozícióját a batch állományban.\n\n\\r
-SHIFT [DOWN]"\r
-\r
-STRING_SCREEN_HELP, "Megváltoztatja a kurzos pozícióját, vagy megjelenít adott pozícióban egy szöveget.\n\n\\r
-SCREEN sor oszlop [szöveg]\n\n\\r
-  sor         Ugrás sora\n\\r
-  oszlop      Ugrás oszlopa"\r
-\r
-STRING_SET_HELP, "Megjeleníti vagy beállítja a környezeti változókat.\n\n\\r
-SET [változó[=][érték]]\n\n\\r
-  változó  Környezeti változó neve.\n\\r
-  érték    A beállítandó érték.\n\n\\r
-Paraméterek nélkül megjeleníti az összes környezetiváltozót.\n"\r
-\r
-STRING_START_HELP1, "Végrehajt egy parancsot.\n\n\\r
-START parancs\n\n\\r
-  parancs     Végrehajtja a megadott parancsot.\n\n\\r
-Jelenleg minden parancs aszinkron hajtódik végre.\n"\r
-\r
-STRING_TITLE_HELP, "Beállítja az ablak címsorának szövegét.\n\n\\r
-TITLE [szöveg]\n\n\\r
-szöveg       Beállítja az ablak címsorának szövegét.\n"\r
-\r
-STRING_TIME_HELP1, "Megjeleníti vagy beállítja a rendszeridõt.\n\n\\r
-TIME [/T][idõ]\n\n\\r
-  /T    Csaj megjeleníti\n\n\\r
-Paraméterek nélkül megjeleníti az aktuális idõt és kér egy újat.\n\\r
-Csak egy ENTER megnyomásával nem állítja át.\n"\r
-\r
-STRING_TIME_HELP2, "Új idõ: "\r
-\r
-STRING_TIMER_HELP1, "Eltelt %d ezred másodperc\n"\r
-\r
-STRING_TIMER_HELP2, "Eltelt: %02d%c%02d%c%02d%c%02d\n"\r
-\r
-STRING_TIMER_HELP3, "allow the use of ten stopwaches.\n\n\\r
-TIMER  [ON|OFF] [/S] [/n] [/Fn]\n\n\\r
-  ON          Stopper bekapcsolása\n\\r
-  OFF         Stopper kikapcsolása\n\\r
-  /S          Split time. Return stopwatch split\n\\r
-              time without changing its value\n\\r
-  /n          Stopper azonosító megadása.\n\\r
-              Stopwaches avaliable are 0 to 9\n\\r
-              If it is not specified default is 1\n\\r
-  /Fn         Format for output\n\\r
-              n can be:\n\\r
-                    0    milliseconds\n\\r
-                    1    hh%cmm%css%cdd\n\n\\r
-if none of ON, OFF or /S is specified the command\n\\r
-will toggle stopwach state\n\n"\r
-\r
-STRING_TYPE_HELP1, "Megjeleníti az állományok tartalmát.\n\n\\r
-TYPE [meghajtó:][elérési_út]állománynév \n\\r
-  /P             Csak egy képernyõnyi tartalmat jelenít meg egyszerre.\n"\r
-\r
-STRING_VERIFY_HELP1, "Ez a parancs még nem mûködik!!\n\\r
-Lemezre írás utáni ellenõrzést állítja be.\n\n\\r
-VERIFY [ON | OFF]\n\n\\r
-Írd be a VERIFY-t paraméterek nélkül, hogy megjelenítse aktuális állapotát.\n"\r
-\r
-STRING_VERIFY_HELP2, "Az ellenõrzés jelenleg %s.\n"\r
-\r
-STRING_VERIFY_HELP3, "Csak az ON vagy OFF elfogadott."\r
-\r
-STRING_VERSION_HELP1, "A ReactOS verzióinformációit jeleníti meg\n\n\\r
-VER [/C][/R][/W]\n\n\\r
-  /C  Készítõk névsora.\n\\r
-  /R  Terjesztési információk.\n\\r
-  /W  Jótállási információk."\r
-\r
-STRING_VERSION_HELP2, " comes with ABSOLUTELY NO WARRANTY; for details\n\\r
-type: `ver /w'. This is free software, and you are welcome to redistribute\n\\r
-it under certain conditions; type `ver /r' for details. Type `ver /c' for a\n\\r
-listing of credits."\r
-\r
-STRING_VERSION_HELP3, "\n This program is distributed in the hope that it will be useful,\n\\r
- but WITHOUT ANY WARRANTY; without even the implied warranty of\n\\r
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n\\r
- GNU General Public License for more details."\r
-\r
-STRING_VERSION_HELP4, "\n This program is free software; you can redistribute it and/or modify\n\\r
- it under the terms of the GNU General Public License as published by\n\\r
- the Free Software Foundation; either version 2 of the License, or\n\\r
- (at your option) any later version.\n"\r
-\r
-STRING_VERSION_HELP5, "\nHibákról E-Maileket ide küldhetsz: <ros-dev@reactos.org>.\n\\r
-Frissítések és egyéb információk: http://www.reactos.org"\r
-\r
-STRING_VERSION_HELP6, "\nA FreeDOS készítõi:\n"\r
-\r
-STRING_VERSION_HELP7, "\nA ReactOS készítõi:\n"\r
-\r
-STRING_VOL_HELP1, " A (%c) meghajtóban lévõ kötet: %s\n"\r
-STRING_VOL_HELP2, " A (%c) meghajtóban lévõ kötetnek nincs címkéje"\r
-STRING_VOL_HELP3, " A kötet sorozatszáma %04X-%04X\n"\r
-STRING_VOL_HELP4, "A kötet címkéjének és sorozatszámának megjelenítése, ha léteznek.\n\nVOL [meghajtó:]"\r
-\r
-STRING_WINDOW_HELP1, "change console window aspect\n\n\\r
-WINDOW [/POS[=]left,top,width,heigth]\n\\r
-              [MIN|MAX|RESTORE] ['title']\n\n\\r
-/POS          specify window placement and dimensions\n\\r
-MIN           minimize the window\n\\r
-MAX           maximize the window\n\\r
-RESTORE       restore the window"\r
-\r
-STRING_WINDOW_HELP2, "change console window aspect\n\n\\r
-ACTIVATE 'window' [/POS[=]left,top,width,heigth]\n\\r
-              [MIN|MAX|RESTORE] ['title']\n\n\\r
-window        tile of window on wich perform actions\n\\r
-/POS          specify window placement and dimensions\n\\r
-MIN           minimize the window\n\\r
-MAX           maximize the window\n\\r
-RESTORE       restore the window\n\\r
-title         new title\n"\r
-\r
-\r
-STRING_HELP1, "Támogatott parancsok megjelenítése\n\n\\r
-  parancs /?     Több (részletes) információ megtekintéséhez használd ezt.\n\n\\r
-?        Minden támogatott parancs megjelenítése (részletek nélkül).\n\\r
-ALIAS    Megjeleníti, vagy megváltoztatja az aliasokat.\n\\r
-ATTRIB   Megjeleníti vagy megváltoztatja az állományok attribútumát.\n\\r
-BEEP     Megszólaltatja a hangszórót.\n\\r
-CALL     Batch állományból egy másik batch állomány meghívása.\n\\r
-CD       Megjeleníti vagy átvált egy másik mappába.\n\\r
-CHCP     Megjeleníti vagy megváltoztatja az aktív kódlapot.\n\\r
-CHOICE   Vár a felhasználóra, hogy válasszon a felkínált lehetõségek közül.\n\\r
-CLS      Letörli a képernyõt.\n\\r
-CMD      Egy új példányt indít a ReactOS parancsértelmezõjébõl.\n\\r
-COLOR    A konzol elõ- és háttérszínét állítja be.\n\\r
-COPY     Egy vagy több állományt másol a megadott helyre.\n\\r
-DATE     Megjeleníti vagy beállítja a rendszerdátumot.\n\\r
-DELETE   Eltávolít egy vagy több állományt.\n\\r
-DIR      Megjeleníti a mappában található almappákat és állományokat.\n\\r
-ECHO     Megjelenít egy szöveget, vagy beállítja a visszhangot.\n\\r
-ERASE    Eltávolít egy vagy több fájlt.\n\\r
-EXIT     Kilép a parancssor értelmezõbõl.\n\\r
-FOR      Végrehajt egy parancsot az összes fájlban a megadott mappákban.\n\\r
-FREE     Megjeleníti a szabad hely méretét.\n\\r
-GOTO     Átirányít egy másik címkére a batch állományban.\n\\r
-HELP     Segítséget ad a ReactOS parancsairól.\n\\r
-HISTORY  Megjeleníti az ebben az ablakban kiadott parancsok listáját.\n\\r
-IF       Feltételes végrehajtás batch állományokban.\n\\r
-LABEL    Beállítja egy kötet címkéjét.\n\\r
-MD       Létrehoz egy új mappát.\n\\r
-MKDIR    Létrehoz egy új mappát.\n\\r
-MOVE     Áthelyez egy vagy több állományt az egyik mappából a másikba.\n\\r
-PATH     Megjeleníti vagy beállítja a keresési útvonalakat.\n\\r
-PAUSE    Felfüggeszti a futást, és vár a felhasználóra.\n\\r
-POPD     Visszalép a PUSHD által megjegyzett mappába.\n\\r
-PROMPT   Parancssor beállítása.\n\\r
-PUSHD    Megjegyzi az aktuális mappát, majd átvált egy máasikra.\n\\r
-RD       Töröl egy mappát.\n\\r
-REM      Megjegyzést jelölõ sor batch fájlokban.\n\\r
-REN      Átnevez egy állományt.\n\\r
-RENAME   Átnevez egy állományt.\n\\r
-RMDIR    Töröl egy mappát.\n\\r
-SCREEN   Megváltoztatja a kurzos pozícióját, vagy megjelenít adott pozícióban egy szöveget.\n\\r
-SET      Megjeleníti vagy beállítja a környezeti változókat.\n\\r
-SHIFT    Eltolja a helyettesíthetõ paraméterek pozícióját a batch állományban.\n"\r
-STRING_HELP2, "START    Egy új ablakban hajtha végre a parancsot.\n\\r
-TIME     Megjeleníti vagy beállítja a rendszeridõt.\n\\r
-TIMER    Idõzítõk kezelését teszi lehetõve.\n\\r
-TITLE    Beállítja az ablak címsorának szövegét.\n\\r
-TYPE     Megjeleníti egy állomány tartalmát.\n\\r
-VER      Megjeleníti a ReactOS verzió információját.\n\\r
-VERIFY   Írási mûveletek ellenõrzését vezérli\n\\r
-VOL      Megjeleníti egy kötet címkéjét és sorozatszámát.\n"\r
-\r
-\r
-STRING_CHOICE_OPTION,         "IN"\r
-STRING_COPY_OPTION,           "INM"\r
-\r
-\r
-STRING_ALIAS_ERROR,          "A parancssor túl hosszú az alias kibontásakor!\n"\r
-STRING_BATCH_ERROR,          "Hiba a batch állomány megnyitásakor\n"\r
-STRING_CHCP_ERROR1,          "Aktív kódlap: %u\n"\r
-STRING_CHCP_ERROR4,          "Érvénytelen kódlap\n"\r
-STRING_CHOICE_ERROR,         "Érvénytelen paraméter. Várt formátum: /C[:]választási lehetõségek"\r
-STRING_CHOICE_ERROR_TXT,     "Érvénytelen paraméter. Várt formátum: /T[:]v,nn"\r
-STRING_CHOICE_ERROR_OPTION,  "Érvénytelen paraméter: %s"\r
-STRING_CMD_ERROR1,           "Nem lehet átirányítani a bevitelt a(z) %s állományból\n"\r
-STRING_CMD_ERROR2,           "Hiba a csõvezetékhez tartozó ideiglenes állomány létrehozásakor\n"\r
-STRING_CMD_ERROR3,           "Nem lehet a(z) %s állományba átirányítani\n"\r
-STRING_CMD_ERROR4,           "%s futtatása...\n"\r
-STRING_CMD_ERROR5,           "cmdexit.bat futtatása...\n"\r
-STRING_COLOR_ERROR1,         "Ugyanaz a szín nem lehet! (Az elõ- és háttérszín nem lehet ugyanolyan)"\r
-STRING_COLOR_ERROR2,         "Hibás szín megadás"\r
-STRING_COLOR_ERROR3,         "Szín %x\n"\r
-STRING_COLOR_ERROR4,         "Ugyanaz a szín nem lehet!"\r
-STRING_CONSOLE_ERROR,        "Ismeretlen hiba: %d\n"\r
-STRING_COPY_ERROR1,          "Hiba: a forrás nem nyitható meg - %s!\n"\r
-STRING_COPY_ERROR2,          "Hiba: nem másolhatod önmagára az állományt!\n"\r
-STRING_COPY_ERROR3,          "Hiba a cél írása közben!\n"\r
-STRING_COPY_ERROR4,          "Hiba: ez még nem mûködik!\n"\r
-STRING_DATE_ERROR,           "Érvénytelen dátum."\r
-STRING_DEL_ERROR5,           "A(z) %s állomány törölve lesz! "\r
-STRING_DEL_ERROR6,           "Biztos vagy benne (I/N)?"\r
-STRING_DEL_ERROR7,           "Törlés: %s\n"\r
-STRING_ERROR_ERROR1,         "Ismeretlen hiba! Hiba kód: 0x%lx\n"\r
-STRING_ERROR_ERROR2,         "Szintaxis hiba"\r
-STRING_FOR_ERROR1,           "az 'in' után hiányzik a feltétel."\r
-STRING_FOR_ERROR2,           "nincs zárójel megadva."\r
-STRING_FOR_ERROR3,           "a 'do' hiányzik." \r
-STRING_FOR_ERROR4,           "nincs parancs a  'do' után."\r
-STRING_FREE_ERROR1,          "Érvénytelen meghajtó"\r
-STRING_FREE_ERROR2,          "nincs cimkézve"\r
-STRING_GOTO_ERROR1,          "Nem lett cimke megadva a  GOTO után"\r
-STRING_GOTO_ERROR2,          "A '%s' cimke nem található\n"\r
-\r
-STRING_MOVE_ERROR1,          "[OK]\n"\r
-STRING_MOVE_ERROR2,          "[HIBA]\n"\r
-\r
-STRING_REN_ERROR1,           "MoveÁllomány() sikertelen. Hiba: %lu\n"\r
-\r
-STRING_START_ERROR1,         "Nincs batch támogatás jelenleg!"\r
-\r
-STRING_TIME_ERROR1,          "Érvénytelen idõ."\r
-\r
-STRING_TYPE_ERROR1,          "Érvénytelen beállítás '/%s'\n"\r
-\r
-STRING_WINDOW_ERROR1,        "Az ablak nem található"\r
-\r
-\r
-STRING_ERROR_PARAMETERF_ERROR,     "A paraméter megadás hibás - %c\n"\r
-STRING_ERROR_INVALID_SWITCH,       "Érvénytelen kapcsoló - /%c\n"\r
-STRING_ERROR_TOO_MANY_PARAMETERS,  "Túl sok paraméter - %s\n"\r
-STRING_ERROR_PATH_NOT_FOUND,       "Az elérési_út nem halálható\n"\r
-STRING_ERROR_FILE_NOT_FOUND,       "Az állomány nem található\n"\r
-STRING_ERROR_REQ_PARAM_MISSING,    "Egy szükséges paraméter hiányzik\n"\r
-STRING_ERROR_INVALID_DRIVE,        "Érvénytelen meghajtó\n"\r
-STRING_ERROR_INVALID_PARAM_FORMAT, "Érvénytelen paraméter megadás - %s\n"\r
-STRING_ERROR_BADCOMMAND,           "Ismeretlen parancs vagy állomány név\n"\r
-STRING_ERROR_OUT_OF_MEMORY,        "Nincs elég memória.\n"\r
-STRING_ERROR_CANNOTPIPE,           "Error!  Cannot pipe!  Cannot open temporary állomány!\n"\r
-STRING_ERROR_D_PAUSEMSG,           "A folytatáshoz nyomj meg egy billentyût . . ."\r
-STRING_ERROR_DRIVER_NOT_READY,     "A meghajtó nem áll készen"\r
-\r
-STRING_PATH_ERROR,                 "CMD: Not in environment '%s'\n"\r
-\r
-STRING_CMD_SHELLINFO,              "\nReactOS Parancssor értelmezõ"\r
-STRING_VERSION_RUNVER,             " running on %s"\r
-STRING_COPY_FILE ,                 "        %d állomány másolva\n"\r
-STRING_DELETE_WIPE,                "wiped"\r
-STRING_FOR_ERROR,                  "Hibás változó."\r
-STRING_SCREEN_COL,                 "Érvénytelen érték oszlopnak"\r
-STRING_SCREEN_ROW,                 "Érvénytelen érték sornak"\r
-STRING_TIMER_TIME                  "Idõzítõ %d értéke %s: "\r
-}\r
diff --git a/reactos/subsys/system/cmd/Ja.rc b/reactos/subsys/system/cmd/Ja.rc
deleted file mode 100644 (file)
index f8c1077..0000000
+++ /dev/null
@@ -1,658 +0,0 @@
-#include "windows.h"
-#include "resource.h"
-/*
- * Moved all hardcoded strings to En.rc.
- * By Magnus Olsen  2005
- */
-
-LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT
-STRINGTABLE DISCARDABLE
-{
-
-STRING_ATTRIB_HELP,    "\83t\83@\83C\83\8b\91®\90«\82ð\95\\\8e¦\82Ü\82½\82Í\95Ï\8dX\82µ\82Ü\82·\81B\n\n\
-ATTRIB [+R | -R] [+A | -A] [+S | -S] [+H | -H] [\83t\83@\83C\83\8b] ...\n\
-       [/S [/D]]\n\n\
-  +   \91®\90«\82ð\90Ý\92è\82µ\82Ü\82·\81B\n\
-  -   \91®\90«\82ð\89ð\8f\9c\82µ\82Ü\82·\81B\n\
-  R   \93Ç\82Ý\82Æ\82è\90ê\97p\91®\90«\81B\n\
-  A   \83A\81[\83J\83C\83u\91®\90«\81B\n\
-  S   \83V\83X\83e\83\80 \83t\83@\83C\83\8b\91®\90«\81B\n\
-  H   \89B\82µ\83t\83@\83C\83\8b\91®\90«\81B\n\
-  /S  \8c»\8dÝ\82Ì\83t\83H\83\8b\83_\82Æ\82·\82×\82Ä\82Ì\83T\83u\83t\83H\83\8b\83_\82Ì\88ê\92v\82·\82é\83t\83@\83C\83\8b\82ð\n\
-      \8f\88\97\9d\82µ\82Ü\82·\81B\n\
-  /D  \83t\83H\83\8b\83_\82à\8f\88\97\9d\82µ\82Ü\82·\81B\n\n\
-\83p\83\89\83\81\81[\83^\82ð\8ew\92è\82µ\82È\82¢\82Å ATTRIB \82Æ\93ü\97Í\82·\82é\82Æ\81A\82·\82×\82Ä\82Ì\83t\83@\83C\83\8b\82Ì\91®\90«\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n"
-
-STRING_ALIAS_HELP,  "\83G\83C\83\8a\83A\83X\82Ì\90Ý\92è\82â\89ð\8f\9c\82ð\82µ\82½\82è\81A\83G\83C\83\8a\83A\83X\82ð\95\\\8e¦\82µ\82½\82è\82µ\82Ü\82·\81B\n\n\
-ALIAS [\83G\83C\83\8a\83A\83X=[\83R\83}\83\93\83h]]\n\n\
-  \83G\83C\83\8a\83A\83X   \83G\83C\83\8a\83A\83X\82Æ\82µ\82Ä\82Â\82¯\82é\96¼\91O\81B\n\
-  \83R\83}\83\93\83h     \83G\83C\83\8a\83A\83X\82Æ\82µ\82Ä\90Ý\92è\82·\82é\95\8e\9a\97ñ\81B\n\n\
-\82·\82×\82Ä\82Ì\83G\83C\83\8a\83A\83X\82ð\88ê\97\97\95\\\8e¦\82·\82é\82É\82Í:\n\
-  ALIAS\n\n\
-\90V\82½\82É\83G\83C\83\8a\83A\83X\82ð\90Ý\92è\82µ\82½\82è\81A\8aù\91\82Ì\83G\83C\83\8a\83A\83X\82ð\92u\82«\8a·\82¦\82é\82É\82Í:\n\
-  ALIAS da=dir a:\n\n\
-\83G\83C\83\8a\83A\83X\82Ì\83\8a\83X\83g\82©\82ç\83G\83C\83\8a\83A\83X\82ð\8eæ\82è\8f\9c\82­\82É\82Í:\n\
-  ALIAS da="
-
-STRING_BEEP_HELP, "\83X\83s\81[\83J\82©\82ç\83r\81[\83v\89¹\82ð\96Â\82ç\82µ\82Ü\82·\81B\n\nBEEP\n"
-
-STRING_CALL_HELP, "\83o\83b\83\83v\83\8d\83O\83\89\83\80\82ð\95Ê\82Ì\83o\83b\83\83v\83\8d\83O\83\89\83\80\82©\82ç\8cÄ\82Ñ\8fo\82µ\82Ü\82·\81B\n\n\
-CALL [\83h\83\89\83C\83u:][\83p\83X]\83t\83@\83C\83\8b\96¼ [\83o\83b\83`\83p\83\89\83\81\81[\83^]\n\n\
-  \83o\83b\83`\83p\83\89\83\81\81[\83^  \83o\83b\83\83v\83\8d\83O\83\89\83\80\82Å\95K\97v\82È\83R\83}\83\93\83\83\89\83C\83\93\8fî\95ñ\82ð\n\
-                    \8ew\92è\82µ\82Ü\82·\81B"
-
-STRING_CD_HELP,      "\8c»\8dÝ\82Ì\83f\83B\83\8c\83N\83g\83\8a\82ð\95Ï\8dX\82µ\82½\82è\81A\83f\83B\83\8c\83N\83g\83\8a\96¼\82ð\95\\\8e¦\82µ\82½\82è\82µ\82Ü\82·\81B\n\n\
-CHDIR [/D][\83h\83\89\83C\83u:][\83p\83X]\n\
-CHDIR[..|.]\n\
-CD [/D][\83h\83\89\83C\83u:]\83p\83X]\n\
-CD[..|.]\n\n\
-  ..   \90e\83f\83B\83\8c\83N\83g\83\8a\n\
-  .    \8c»\8dÝ\82Ì\83f\83B\83\8c\83N\83g\83\8a\n\
-  /D   \8c»\8dÝ\82Ì\83h\83\89\83C\83u\82Æ\83f\83B\83\8c\83N\83g\83\8a\82Ì\97¼\95û\82ð\95Ï\8dX\82µ\82Ü\82·\81B\n\n\
-CD \83h\83\89\83C\83u: \82Æ\93ü\97Í\82·\82é\82Æ\8ew\92è\82³\82ê\82½\83h\83\89\83C\83u\82Ì\8c»\8dÝ\82Ì\83f\83B\83\8c\83N\83g\83\8a\82ª\95\\\8e¦\82³\82ê\82Ü\82·\81B\n\
-\83p\83\89\83\81\81[\83^\82ð\8ew\92è\82µ\82È\82¢\82Å CD \82Æ\93ü\97Í\82·\82é\82Æ\81A\8c»\8dÝ\82Ì\83h\83\89\83C\83u\82Æ\83f\83B\83\8c\83N\83g\83\8a\82ª\95\\\8e¦\82³\82ê\82Ü\82·\81B\n"
-
-STRING_CHCP_HELP,   "\8c»\8dÝ\82Ì\83R\81[\83\83y\81[\83W\94Ô\8d\86\82ð\95\\\8e¦\82Ü\82½\82Í\90Ý\92è\82µ\82Ü\82·\81B\n\n\
-CHCP [nnn]\n\n\
-  nnn   \83R\81[\83\83y\81[\83W\94Ô\8d\86\82ð\8ew\92è\82µ\82Ü\82·\81B\n\n\
-\8c»\8dÝ\82Ì\83R\81[\83\83y\81[\83W\94Ô\8d\86\82ð\95\\\8e¦\82·\82é\82Æ\82«\82Í\81A\83p\83\89\83\81\81[\83^\82ð\8ew\92è\82¹\82¸\82É CHCP \82Æ\93ü\97Í\82µ\82Ä\82­\82¾\82³\82¢\81B\n"
-
-STRING_CHOICE_HELP, "\83\86\81[\83U\81[\82ª\91I\91ð\8e\88\82©\82ç\88ê\82Â\82ð\91I\91ð\82·\82é\82Ì\82ð\91Ò\82¿\82Ü\82·\81B\n\n\
-CHOICE  [/C[:]\91I\91ð\8e\88][/N][/S][/T[:]c,nn][\95\8e\9a\97ñ]\n\n\
-  /C[:]\91I\91ð\8e\88   \8b\96\82³\82ê\82é\83L\81[\93ü\97Í\82ð\8ew\92è\82µ\82Ü\82·\81B\83f\83t\83H\83\8b\83g\82Í YN \82Å\82·\81B\n\
-  /N            \83v\83\8d\83\93\83v\83g\82Ì\95\8e\9a\97ñ\82Ì\8dÅ\8cã\82É\81A\91I\91ð\8e\88\82Æ ? \82ð\95\\\8e¦\82µ\82Ü\82¹\82ñ\81B\n\
-  /S            \83L\81[\93ü\97Í\82Ì\91å\95\8e\9a\81E\8f¬\95\8e\9a\82ð\8bæ\95Ê\82µ\82Ü\82·\81B\n\
-  /T[:]c,nn     nn \95b\8co\89ß\82·\82é\82Æ\8e©\93®\93I\82É c \82ð\91I\91ð\82µ\82Ü\82·\81B\n\
-  \95\8e\9a\97ñ        \95\\\8e¦\82·\82é\83v\83\8d\83\93\83v\83g\82Ì\95\8e\9a\97ñ\82Å\82·\81B\n\n\
-\83\86\81[\83U\81[\82ª\91I\91ð\8e\88\82É\82 \82é\83L\81[\82ð\89\9f\82·\82Æ\81A\82»\82Ì\83I\83t\83Z\83b\83g\82ª ERRORLEVEL \82É\83Z\83b\83g\82³\82ê\82Ü\82·\81B\n"
-
-STRING_CLS_HELP, "\89æ\96Ê\82ð\8fÁ\8b\8e\82µ\82Ü\82·\81B\n\nCLS\n"
-
-STRING_CMD_HELP1, "\n\97\98\97p\82Å\82«\82é\93à\95\94\83R\83}\83\93\83h:\n"
-
-STRING_CMD_HELP2, "\n\97\98\97p\82Å\82«\82é\8b@\94\\:"
-
-STRING_CMD_HELP3,"  [\83G\83C\83\8a\83A\83X]"
-
-STRING_CMD_HELP4,"  [\83q\83X\83g\83\8a]"
-
-STRING_CMD_HELP5,"  [UNIX \83t\83@\83C\83\8b\96¼\95â\8a®]"
-
-STRING_CMD_HELP6,"  [\83f\83B\83\8c\83N\83g\83\8a \83X\83^\83b\83N]"
-
-STRING_CMD_HELP7,"  [\83\8a\83_\83C\83\8c\83N\83g\82Æ\83p\83C\83v]"
-
-STRING_CMD_HELP8, "ReactOS \83R\83}\83\93\83\83\89\83C\83\93 \83C\83\93\83^\81[\83v\83\8a\83^\82Ì\90V\82µ\82¢\83C\83\93\83X\83^\83\93\83X\82ð\8aJ\8en\82µ\82Ü\82·\81B\n\n\
-CMD [/[C|K] \83R\83}\83\93\83h][/P][/Q][/T:bf]\n\n\
-  /C \83R\83}\83\93\83h  \8ew\92è\82³\82ê\82½\83R\83}\83\93\83h\82ð\8eÀ\8ds\82µ\82½\8cã\81A\8fI\97¹\82µ\82Ü\82·\81B\n\
-  /K \83R\83}\83\93\83h  \8ew\92è\82³\82ê\82½\83R\83}\83\93\83h\82ð\8eÀ\8ds\82µ\82Ü\82·\82ª\81A\8fI\97¹\82µ\82Ü\82¹\82ñ\81B\n\
-  /P           CMD \82Í\89i\91±\93I\82É\93®\8dì\82ð\82µ\81Aautoexec.bat \82ð\8eÀ\8ds\82µ\82Ü\82·\n\
-               (\8fI\97¹\82³\82¹\82é\82±\82Æ\82Í\82Å\82«\82Ü\82¹\82ñ)\81B\n\
-  /T:bf        \91O\8ci\90F\82¨\82æ\82Ñ\94w\8ci\90F\82ð\90Ý\92è\82µ\82Ü\82· (\8fÚ\8d×\82Í COLOR /? \82ð\8eQ\8fÆ\82µ\82Ä\n\
-               \82­\82¾\82³\82¢)\81B\n"
-
-STRING_COLOR_HELP1, "\83R\83\93\83\\\81[\83\8b\82Ì\83f\83t\83H\83\8b\83g\82Ì\91O\8ci\90F\82¨\82æ\82Ñ\94w\8ci\90F\82ð\90Ý\92è\82µ\82Ü\82·\81B\n\n\
-COLOR [\91®\90« [/-F]] \n\n\
-  \91®\90«        \83R\83\93\83\\\81[\83\8b\8fo\97Í\82Ì\90F\91®\90«\82ð\8ew\92è\82µ\82Ü\82·\81B\n\
-  /-F         \83R\83\93\83\\\81[\83\8b\82Ì\8bó\82¢\82Ä\82¢\82é\8bó\8aÔ\82É\82Í\90F\91®\90«\82ð\93K\97p\82µ\82È\82¢\81B\n\n\
-\90F\82Í\8e\9f\82Ì 3 \8eí\97Þ\82Ì\95û\96@\82Å\8ew\92è\82·\82é\82±\82Æ\82ª\82Å\82«\82Ü\82·\81B\n\
-1) [\90F\96¼] on [\90F\96¼] (\95K\97v\82È\82Ì\82Í\8dÅ\8f\89\82Ì 3 \95\8e\9a\82¾\82¯\82Å\82·)\n\
-2) [10 \90i\90\94] on [10 \90i\90\94]\n\
-3) 2 \8c\85\82Ì 16 \90i\90\94\n\n\
-\90F\96¼:\n\
-10\90i 16\90\90F\96¼       10\90i 16\90\90F\96¼\n\
-0    0    \8d\95          8   8    \8aD\90F (\96¾\82é\82¢\8d\95)\n\
-1    1    \90          9   9    \96¾\82é\82¢\90Â\n\
-2    2    \97Π        10   A    \96¾\82é\82¢\97Î\n\
-3    3    \90\85\90F       11   B    \96¾\82é\82¢\90\85\90F\n\
-4    4    \90Ô         12   C    \96¾\82é\82¢\90Ô\n\
-5    5    \8e\87         13   D    \96¾\82é\82¢\8e\87\n\
-6    6    \89©\90F       14   E    \96¾\82é\82¢\89©\90F\n\
-7    7    \94\92         15   F    \8bP\82­\94\92\n"
-
-STRING_COPY_HELP1,  "%s \82ð\8fã\8f\91\82«\82µ\82Ü\82·\82ª\81A\82æ\82ë\82µ\82¢\82Å\82·\82©? (Yes/No/All)? "
-
-STRING_COPY_HELP2, "1 \82Â\82Ü\82½\82Í\95¡\90\94\82Ì\83t\83@\83C\83\8b\82ð\95Ê\82Ì\8fê\8f\8a\82É\83R\83s\81[\82µ\82Ü\82·\81B\n\n\
-COPY [/V][/Y|/-Y][/A|/B] \83R\83s\81[\8c³ [/A|/B]\n\
-     [+ \83R\83s\81[\8c³ [/A|/B] [+ ...]] [\83R\83s\81[\90æ [/A|/B]]\n\n\
-  \83R\83s\81[\8c³     \83R\83s\81[\82·\82é\83t\83@\83C\83\8b (\95¡\90\94\89Â) \82ð\8ew\92è\82µ\82Ü\82·\81B\n\
-  /A           ASCII \83e\83L\83X\83\83t\83@\83C\83\8b\82Æ\82µ\82Ä\88µ\82¢\82Ü\82·\81B\n\
-  /B           \83o\83C\83i\83\8a \83t\83@\83C\83\8b\82Æ\82µ\82Ä\88µ\82¢\82Ü\82·\81B\n\
-  \83R\83s\81[\90æ     \90V\82µ\82¢\83t\83@\83C\83\8b\82Ì\83f\83B\83\8c\83N\83g\83\8a\82Ü\82½\82Í\83t\83@\83C\83\8b\96¼ (\95¡\90\94\89Â) \82ð\n\
-               \8ew\92è\82µ\82Ü\82·\81B\n\
-  /V           \90V\82µ\82¢\83t\83@\83C\83\8b\82ª\90³\82µ\82­\8f\91\82«\8d\9e\82Ü\82ê\82½\82©\8c\9f\8d¸\82µ\82Ü\82·\81B\n\
-  /Y           \8eó\82¯\91¤\82Ì\8aù\91\82Ì\83t\83@\83C\83\8b\82ð\8fã\8f\91\82«\82·\82é\91O\82É\8am\94F\82Ì\83\81\83b\83Z\81[\83W\82ð\n\
-               \95\\\8e¦\82µ\82Ü\82¹\82ñ\81B\n\
-  /-Y          \8eó\82¯\91¤\82Ì\8aù\91\82Ì\83t\83@\83C\83\8b\82ð\8fã\8f\91\82«\82·\82é\91O\82É\8am\94F\82Ì\83\81\83b\83Z\81[\83W\82ð\n\
-               \95\\\8e¦\82µ\82Ü\82·\81B\n\n\
-T\8aÂ\8b«\95Ï\90\94 COPYCMD \82Å\83X\83C\83b\83` /Y \82ª\90Ý\92è\82³\82ê\82Ä\82¢\82é\8fê\8d\87\82ª\82 \82è\82Ü\82·\81B\n\
-...\n"
-
-STRING_DATE_HELP1, "\n\90V\82µ\82¢\93ú\95t\82ð\93ü\97Í\82µ\82Ä\82­\82¾\82³\82¢ (mm%cdd%cyyyy): "
-
-STRING_DATE_HELP2, "\n\90V\82µ\82¢\93ú\95t\82ð\93ü\97Í\82µ\82Ä\82­\82¾\82³\82¢ (dd%cmm%cyyyy): "
-
-STRING_DATE_HELP3, "\n\90V\82µ\82¢\93ú\95t\82ð\93ü\97Í\82µ\82Ä\82­\82¾\82³\82¢ (yyyy%cmm%cdd): "
-
-STRING_DATE_HELP4, "\93ú\95t\82ð\95\\\8e¦\82Ü\82½\82Í\90Ý\92è\82µ\82Ü\82·\81B\n\n\
-DATE [/T][\93ú\95t]\n\n\
-  /T    \93ú\95t\82Ì\95\\\8e¦\82Ì\82Ý\8ds\82¢\82Ü\82·\81B\n\n\
-\83p\83\89\83\81\81[\83^\82Ì\8ew\92è\82ª\82È\82¢\8fê\8d\87\82Í\81A\8c»\8dÝ\82Ì\93ú\95t\82ª\95\\\8e¦\82³\82ê\81A\90V\82µ\82¢\93ú\95t\82Ì\93ü\97Í\82ð\n\
-\8b\81\82ß\82ç\82ê\82Ü\82·\81B\95Ï\8dX\82µ\82È\82¢\8fê\8d\87\82Í\81AEnter \83L\81[\82ð\89\9f\82µ\82Ü\82·\81B\n"
-                               
-STRING_DEL_HELP1,  "1 \82Â\82Ü\82½\82Í\95¡\90\94\82Ì\83t\83@\83C\83\8b\82ð\8dí\8f\9c\82µ\82Ü\82·\81B\n\n\
-DEL [/N /P /T /Q /S /W /Y /Z /A[[:]\91®\90«]] \83t\83@\83C\83\8b\96¼ ...\n\
-DELETE [/N /P /T /Q /S /W /Y /Z /A[[:]\91®\90«]] \83t\83@\83C\83\8b\96¼ ...\n\
-ERASE [/N /P /T /Q /S /W /Y /Z /A[[:]\91®\90«]] \83t\83@\83C\83\8b\96¼ ...\n\n\
-  \83t\83@\83C\83\8b\96¼\n\
-        \8dí\8f\9c\82·\82é\83t\83@\83C\83\8b (\95¡\90\94\89Â) \82ð\8ew\92è\82µ\82Ü\82·\81B\n\n\
-  /N    Nothing. \89½\82à\82µ\82Ü\82¹\82ñ\81B\n\
-  /P    Prompt. \8ae\83t\83@\83C\83\8b\82ð\8dí\8f\9c\82·\82é\91O\82É\8am\94F\82Ì\83\81\83b\83Z\81[\83W\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  /T    Total. \8dí\8f\9c\82³\82ê\82½\83t\83@\83C\83\8b\82Ì\91\8d\90\94\82Æ\89ð\95ú\82³\82ê\82½\83f\83B\83X\83N\97Ì\88æ\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  /Q    Quiet.\n\
-  /W    Wipe. \8dí\8f\9c\82·\82é\91O\82É\81A\83t\83@\83C\83\8b\82ð\97\90\90\94\82Å\8fã\8f\91\82«\82µ\82Ü\82·\81B\n\
-  /Y    Yes. \83\8f\83C\83\8b\83h\83J\81[\83h\82ð\8eg\97p\82µ\82Ä\88ê\8a\87\8dí\8f\9c\82·\82é\82Æ\82«\82à\81A\8am\94F\82Ì\83\81\83b\83Z\81[\83W\82ð\n\
-        \95\\\8e¦\82¹\82¸\82É\8dí\8f\9c\82µ\82Ü\82·\81B\n\
-  /F    \93Ç\82Ý\82Æ\82è\90ê\97p\83t\83@\83C\83\8b\82â\83V\83X\83e\83\80 \83t\83@\83C\83\8b\82ð\8b­\90§\93I\82É\8dí\8f\9c\82µ\82Ü\82·\81B\n\
-  /S    \8ew\92è\82³\82ê\82½\83t\83@\83C\83\8b\82ð\82·\82×\82Ä\82Ì\83T\83u\83f\83B\83\8c\83N\83g\83\8a\82©\82ç\8dí\8f\9c\82µ\82Ü\82·\81B\n\
-  /A    \91®\90«\82É\82æ\82è\8dí\8f\9c\82·\82é\83t\83@\83C\83\8b\82ð\91I\91ð\82µ\82Ü\82·\81B\n\
-        \91®\90«\n\
-        R     \93Ç\82Ý\8eæ\82è\90ê\97p\n\
-        S     \83V\83X\83e\83\80 \83t\83@\83C\83\8b\n\
-        A     \83A\81[\83J\83C\83u\n\
-        H     \89B\82µ\83t\83@\83C\83\8b\n\
-        -     \82»\82Ì\91®\90«\88È\8aO\n"
-
-STRING_DEL_HELP2, "\83f\83B\83\8c\83N\83g\83\8a\82Ì\82·\82×\82Ä\82Ì\83t\83@\83C\83\8b\82ª\8dí\8f\9c\82³\82ê\82Ü\82·!\n\82æ\82ë\82µ\82¢\82Å\82·\82© (Y/N)?"
-STRING_DEL_HELP3, "    %lu \8cÂ\82Ì\83t\83@\83C\83\8b\82ð\8dí\8f\9c\82µ\82Ü\82µ\82½\n"
-STRING_DEL_HELP4, "    %lu \8cÂ\82Ì\83t\83@\83C\83\8b\82ð\8dí\8f\9c\82µ\82Ü\82µ\82½\n"
-
-STRING_DELAY_HELP, "n \95b\81A\82Ü\82½\82Í n \83~\83\8a\95b\91Ò\8b@\82µ\82Ü\82·\81B\n\
-DELAY [/m]n\n\n\
-  /m          \92P\88Ê\82ð\83~\83\8a\95b\82É\8ew\92è\82µ\82Ü\82·\81B\n\
-              \8ew\92è\82µ\82È\82¢\8fê\8d\87\81A\92P\88Ê\82É\82Í\95b\82ª\8eg\82í\82ê\82Ü\82·\81B\n"
-
-STRING_DIR_HELP1, "\83f\83B\83\8c\83N\83g\83\8a\92\86\82Ì\83t\83@\83C\83\8b\82Æ\83T\83u\83f\83B\83\8c\83N\83g\83\8a\82ð\88ê\97\97\95\\\8e¦\82µ\82Ü\82·\81B\n\n\
-DIR [\83h\83\89\83C\83u:][\83p\83X][\83t\83@\83C\83\8b\96¼] [/A[[:]\91®\90«]] [/B] [/C] [/D] [/L] [/N]\n\
-  [/O[[:]\83\\\81[\83g\8f\87]] [/P] [/Q] [/S] [/T[[:]\83^\83C\83\80\83t\83B\81[\83\8b\83h]] [/W] [/X] [/4]\n\n\
-  [\83h\83\89\83C\83u:][\83p\83X][\83t\83@\83C\83\8b\96¼]\n\
-              \88ê\97\97\95\\\8e¦\82·\82é\83h\83\89\83C\83u\81A\83f\83B\83\8c\83N\83g\83\8a\81A\82Ü\82½\82Í\83t\83@\83C\83\8b\82ð\8ew\92è\82µ\82Ü\82·\81B\n\
-  /A          \8ew\92è\82³\82ê\82½\91®\90«\82Ì\83t\83@\83C\83\8b\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  \91®\90«         D  \83f\83B\83\8c\83N\83g\83\8a               R  \93Ç\82Ý\8eæ\82è\90ê\97p\n\
-               H  \89B\82µ\83t\83@\83C\83\8b               A  \83A\81[\83J\83C\83u\n\
-               S  \83V\83X\83e\83\80 \83t\83@\83C\83\8b          -  \82»\82Ì\91®\90«\88È\8aO\n\
-  /B          \83t\83@\83C\83\8b\96¼\82Ì\82Ý\82ð\95\\\8e¦\82µ\82Ü\82· (\8c©\8fo\82µ\82â\97v\96ñ\82ª\95t\82«\82Ü\82¹\82ñ)\81B\n\
-  /C          \83t\83@\83C\83\8b \83T\83C\83Y\82ð\8c\85\8bæ\90Ø\82è\95\\\8e¦\82µ\82Ü\82·\81B\82±\82ê\82Í\n\
-              \83f\83t\83H\83\8b\83g\82Ì\90Ý\92è\82Å\82·\81B/-C \82Æ\82·\82é\82Æ\8c\85\8bæ\90Ø\82è\95\\\8e¦\82³\82ê\82Ü\82¹\82ñ\81B\n\
-  /D          /W \82Æ\93¯\82\82Å\82·\82ª\81A\83t\83@\83C\83\8b\82ð\97ñ\82Å\95À\82×\91Ö\82¦\82½\88ê\97\97\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  /L          \8f¬\95\8e\9a\82Å\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  /N          \83t\83@\83C\83\8b\96¼\82ð\89E\92[\82É\95\\\8e¦\82·\82é\90V\82µ\82¢\88ê\97\97\8c`\8e®\82ð\8eg\97p\82µ\82Ü\82·\81B\n\
-  /O          \83t\83@\83C\83\8b\82ð\95À\82×\91Ö\82¦\82Ä\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  \83\\\81[\83g\8f\87     N  \96¼\91O\8f\87 (\83A\83\8b\83t\83@\83x\83b\83g)     S  \83T\83C\83Y\8f\87 (\8f¬\82³\82¢\82Ù\82¤\82©\82ç)\n\
-               E  \8ag\92£\8eq\8f\87 (\83A\83\8b\83t\83@\83x\83b\83g)   D  \93ú\8e\9e\8f\87 (\8cÃ\82¢\82Ù\82¤\82©\82ç)\n\
-               G  \83O\83\8b\81[\83v (\83f\83B\83\8c\83N\83g\83\8a\82©\82ç) -  \8d~\8f\87\n\
-  /P          1 \89æ\96Ê\82²\82Æ\82É\92â\8e~\82µ\82Ä\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  /Q          \83t\83@\83C\83\8b\82Ì\8f\8a\97L\8eÒ\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  /S          \8ew\92è\82³\82ê\82½\83f\83B\83\8c\83N\83g\83\8a\82¨\82æ\82Ñ\82»\82Ì\83T\83u\83f\83B\83\8c\83N\83g\83\8a\82Ì\82·\82×\82Ä\82Ì\n\
-              \83t\83@\83C\83\8b\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  /T          \82Ç\82Ì\83^\83C\83\80\83t\83B\81[\83\8b\83h\82ð\95\\\8e¦\82·\82é\82©\81A\82Ü\82½\82Í\95À\82×\91Ö\82¦\82É\8eg\97p\82·\82é\82©\82ð\n\
-              \8ew\92è\82µ\82Ü\82·\81B\n\
-  \83^\83C\83\80\83t\83B\81[\83\8b\83h    C  \8dì\90¬n\n\
-                      A  \8dÅ\8fI\83A\83N\83Z\83X\n\
-                      W  \8dÅ\8fI\8dX\90V\n\
-  /W          \83\8f\83C\83h\88ê\97\97\8c`\8e®\82Å\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  /X          \82±\82Ì\83I\83v\83V\83\87\83\93\82Í MS-DOS \8c`\8e® (8.3) \88È\8aO\82Ì\83t\83@\83C\83\8b\96¼\82É\91Î\82·\82é\92Z\82¢\n\
-              \96¼\91O\82ð\95\\\8e¦\82µ\82Ü\82·\81B\92·\82¢\96¼\91O\82Ì\91O\82É\92Z\82¢\96¼\91O\82ð\95\\\8e¦\82·\82é\93_\82ð\8f\9c\82¯\82Î\81A\n\
-              /N \83I\83v\83V\83\87\83\93\82Æ\93¯\82\82Å\82·\81B\92Z\82¢\96¼\91O\82ª\82È\82¢\8fê\8d\87\82Í\81A\83u\83\89\83\93\83N\82É\n\
-              \82È\82è\82Ü\82·\81B\n\
-  /4          4 \82Â\82Ì\90\94\8e\9a\82Å\94N\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\n\
-\8aÂ\8b«\95Ï\90\94 DIRCMD \82É\83X\83C\83b\83`\82ð\90Ý\92è\82Å\82«\82Ü\82·\81B\n\
-/-W \82Ì\82æ\82¤\82É - (\83n\83C\83t\83\93\82ð\91O\82É\82Â\82¯\82é\82Æ\81A\82»\82Ì\83X\83C\83b\83`\82Í\96³\8cø\82É\82È\82è\82Ü\82·\81B\n"
-
-STRING_DIR_HELP2, " \83h\83\89\83C\83u %c \82Ì\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82Í %s \82Å\82·\n"
-STRING_DIR_HELP3, " \83h\83\89\83C\83u %c \82É\82Í\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82ª\82 \82è\82Ü\82¹\82ñ\81B\n"
-STRING_DIR_HELP4, " \83{\83\8a\83\85\81[\83\80 \83V\83\8a\83A\83\8b\94Ô\8d\86\82Í %04X-%04X \82Å\82·\n"
-STRING_DIR_HELP5, "\n     \83t\83@\83C\83\8b\82Ì\91\8d\90\94:\n%16i \8cÂ\82Ì\83t\83@\83C\83\8b% 14s \83o\83C\83g\n"
-STRING_DIR_HELP6, "%16i \8cÂ\82Ì\83f\83B\83\8c\83N\83g\83\8a% 15s \83o\83C\83g\n"
-STRING_DIR_HELP7, "\n %s \82Ì\83f\83B\83\8c\83N\83g\83\8a\n\n"
-STRING_DIR_HELP8, "%16i \8cÂ\82Ì\83t\83@\83C\83\8b% 14s \83o\83C\83g\n"
-
-STRING_DIRSTACK_HELP1, "POPD \83R\83}\83\93\83h\82Å\8eg\97p\82·\82é\82½\82ß\82É\8c»\8dÝ\82Ì\83f\83B\83\8c\83N\83g\83\8a\82ð\95Û\91\82µ\81A\n\
-\8ew\92è\82µ\82½\83f\83B\83\8c\83N\83g\83\8a\82É\95Ï\8dX\82µ\82Ü\82·\81B\n\n\
-PUSHD [\83p\83X | ..]\n\n\
-  \83p\83X        \8c»\8dÝ\82Ì\83f\83B\83\8c\83N\83g\83\8a\82Æ\82µ\82Ä\90Ý\92è\82·\82é\83f\83B\83\8c\83N\83g\83\8a\82ð\8ew\92è\82µ\82Ü\82·\81B\n"
-
-STRING_DIRSTACK_HELP2, "PUSHD \83R\83}\83\93\83h\82Å\8bL\89¯\82³\82ê\82½\83f\83B\83\8c\83N\83g\83\8a\82É\95Ï\8dX\82µ\82Ü\82·\81B\n\nPOPD"
-
-STRING_DIRSTACK_HELP3, "\83f\83B\83\8c\83N\83g\83\8a \83X\83^\83b\83N\82Ì\88ê\97\97\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\nDIRS"
-
-STRING_DIRSTACK_HELP4, "\83f\83B\83\8c\83N\83g\83\8a \83X\83^\83b\83N\82Í\8bó\82Å\82·\81B"
-
-STRING_ECHO_HELP1,  "\83\81\83b\83Z\81[\83W\82ð\95\\\8e¦\82µ\82Ü\82·\82ª\81A\91O\82É\83L\83\83\83\8a\83b\83\83\8a\83^\81[\83\93\82Æ\83\89\83C\83\93\83t\83B\81[\83h\82ð\82Â\82¯\82Ü\82¹\82ñ\81B\n\n\
-  ECHOS \83\81\83b\83Z\81[\83W"
-
-STRING_ECHO_HELP2,  "\95W\8f\80\83G\83\89\81[\82É\83\81\83b\83Z\81[\83W\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\n\
-  ECHOERR \83\81\83b\83Z\81[\83W\n\
-  ECHOERR.           \8bó\8ds\82ð\8fo\97Í\82µ\82Ü\82·\81B"
-
-STRING_ECHO_HELP3, "\95W\8f\80\83G\83\89\81[\82É\83\81\83b\83Z\81[\83W\82ð\95\\\8e¦\82µ\82Ü\82·\82ª\81A\91O\82É\83L\83\83\83\8a\83b\83\83\8a\83^\81[\83\93\82Æ\n\
-\83\89\83C\83\93\83t\83B\81[\83h\82ð\82Â\82¯\82Ü\82¹\82ñ\81B\n\n\
-  ECHOSERR \83\81\83b\83Z\81[\83W"
-
-STRING_ECHO_HELP4, "\83\81\83b\83Z\81[\83W\82ð\95\\\8e¦\82µ\82½\82è\81A\83R\83}\83\93\83\83G\83R\81[\82Ì ON \82Æ OFF \82ð\90Ø\82è\91Ö\82¦\82Ü\82·\81B\n\n\
-  ECHO [ON | OFF]\n\
-  ECHO [\83\81\83b\83Z\81[\83W]\n\
-  ECHO.             \8bó\8ds\82ð\8fo\97Í\82µ\82Ü\82·\81B\n\n\
-\8c»\8dÝ\82Ì\83G\83R\81[\90Ý\92è\82ð\95\\\8e¦\82·\82é\82É\82Í\81A\83p\83\89\83\81\81[\83^\82ð\8ew\92è\82¹\82¸\82É ECHO \82Æ\93ü\97Í\82µ\82Ä\82­\82¾\82³\82¢\81B"
-
-STRING_ECHO_HELP5, "ECHO \82Í %s \82Å\82·\81B\n"
-
-STRING_EXIT_HELP, "\83R\83}\83\93\83\83C\83\93\83^\81[\83v\83\8a\83^\82ð\8fI\97¹\82µ\82Ü\82·\81B\n\nEXIT\n"
-
-STRING_FOR_HELP1, "\8ew\92è\82³\82ê\82½\83R\83}\83\93\83h\82ð\83t\83@\83C\83\8b \83Z\83b\83g\82Ì\8ae\83t\83@\83C\83\8b\82É\91Î\82µ\82Ä\8eÀ\8ds\82µ\82Ü\82·\81B\n\n\
-FOR %%\95Ï\90\94 IN (\83Z\83b\83g) DO \83R\83}\83\93\83h [\83p\83\89\83\81\81[\83^]\n\n\
-  %%\95Ï\90\94       \92P\88ê\95\8e\9a\82Ì\92u\82«\8a·\82¦\89Â\94\\\82È\83p\83\89\83\81\81[\83^\82ð\8ew\92è\82µ\82Ü\82·\81B\n\
-  (\83Z\83b\83g)    \83t\83@\83C\83\8b \83Z\83b\83g\82ð\8ew\92è\82µ\82Ü\82·\81B\83\8f\83C\83\8b\83h\83J\81[\83h\82ð\8eg\97p\82Å\82«\82Ü\82·\81B\n\
-  \83R\83}\83\93\83h    \8ae\83t\83@\83C\83\8b\82²\82Æ\82É\8eÀ\8ds\82·\82é\83R\83}\83\93\83h\82ð\8ew\92è\82µ\82Ü\82·\81B\n\
-  \83p\83\89\83\81\81[\83^  \8ew\92è\82³\82ê\82½\83R\83}\83\93\83h\82Ì\83p\83\89\83\81\81[\83^\82Ü\82½\82Í\83X\83C\83b\83`\82ð\8ew\92è\82µ\82Ü\82·\81B\n\n\
-\83o\83b\83\83v\83\8d\83O\83\89\83\80\82Å FOR \83R\83}\83\93\83h\82ð\8eg\97p\82·\82é\82Æ\82«\82Í\81A%%\95Ï\90\94\82Ì\91ã\82í\82è\82É\81A\n\
-%%%%\95Ï\90\94\82ð\8eg\97p\82µ\82Ä\82­\82¾\82³\82¢\81B\n"
-
-STRING_FREE_HELP1, "\n\83h\83\89\83C\83u %c \82Ì\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82Í %-11s \82Å\82·\n\
\83V\83\8a\83A\83\8b\94Ô\8d\86\82Í %s \82Å\82·\n\
-  %16s \83o\83C\83g: \91S\83f\83B\83X\83N\97e\97Ê\n\
-  %16s \83o\83C\83g: \8eg\97p\92\86\n\
-  %16s \83o\83C\83g: \8bó\82«\97e\97Ê\n"
-
-STRING_FREE_HELP2, "\83h\83\89\83C\83u\82É\8aÖ\82·\82é\8fî\95ñ\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\nFREE [\83h\83\89\83C\83u: ...]\n"
-
-STRING_IF_HELP1, "\83o\83b\83\83v\83\8d\83O\83\89\83\80\92\86\82Å\8fð\8c\8f\8f\88\97\9d\82ð\8eÀ\8ds\82µ\82Ü\82·\81B\n\n\
-  IF [NOT] ERRORLEVEL \94Ô\8d\86 \83R\83}\83\93\83h\n\
-  IF [NOT] \95\8e\9a\97ñ1==\95\8e\9a\97ñ2 \83R\83}\83\93\83h\n\
-  IF [NOT] EXIST \83t\83@\83C\83\8b\96¼ \83R\83}\83\93\83h\n\
-  IF [NOT] DEFINED \95Ï\90\94 \83R\83}\83\93\83h\n\n\
-NOT               \8fð\8c\8f\82ª\8bU\82Ì\8fê\8d\87\82É\82¾\82¯\81ACMD \82ª\83R\83}\83\93\83h\82ð\8eÀ\8ds\82·\82é\82±\82Æ\82ð\n\
-                  \8ew\92è\82µ\82Ü\82·\81B\n\
-ERRORLEVEL \94Ô\8d\86   \8dÅ\8cã\82Ì\83v\83\8d\83O\83\89\83\80\82Ì\8eÀ\8ds\82Å\8ew\92è\82³\82ê\82½\94Ô\8d\86\88È\8fã\82Ì\8fI\97¹\83R\81[\83h\n\
-                  \82ª\95Ô\82³\82ê\82½\82Æ\82«\82É\81A\8fð\8c\8f\82ª\90^\82É\82È\82é\82æ\82¤\82É\8ew\92è\82µ\82Ü\82·\81B\n\
-\83R\83}\83\93\83h          \8fð\8c\8f\82ª\90^\82Ì\82Æ\82«\82É\8eÀ\8ds\82·\82é\83R\83}\83\93\83h\82ð\8ew\92è\82µ\82Ü\82·\81B\n\
-\95\8e\9a\97ñ1==\95\8e\9a\97ñ2  \83e\83L\83X\83g\95\8e\9a\97ñ\82ª\88ê\92v\82·\82é\82Æ\82«\82É\8fð\8c\8f\82ª\90^\82É\82È\82é\82æ\82¤\82É\8ew\92è\n\
-                  \82µ\82Ü\82·\81B\n\
-EXIST \83t\83@\83C\83\8b\96¼  \8ew\92è\82µ\82½\83t\83@\83C\83\8b\96¼\82ª\91\8dÝ\82·\82é\82Æ\82«\82É\8fð\8c\8f\82ª\90^\82É\82È\82é\82æ\82¤\82É\n\
-                  \8ew\92è\82µ\82Ü\82·\81B\n\
-DEFINED \95Ï\90\94      \8ew\92è\82µ\82½\95Ï\90\94\82ª\92è\8b`\82³\82ê\82Ä\82¢\82é\82Æ\82«\82É\8fð\8c\8f\82ª\90^\82É\82È\82é\82æ\82¤\82É\n\
-                  \8ew\92è\82µ\82Ü\82·\81B\n"
-
-STRING_GOTO_HELP1,  "\83o\83b\83\83v\83\8d\83O\83\89\83\80\93à\82Ì\81A\83\89\83x\83\8b\82Å\8ew\92è\82³\82ê\82Ä\82¢\82é\8ds\82Ö\90§\8cä\82ð\88Ú\93®\82µ\82Ü\82·\81B\n\n\
-GOTO \83\89\83x\83\8b\n\n\
-  \83\89\83x\83\8b   \83o\83b\83\83v\83\8d\83O\83\89\83\80\82Å\83\89\83x\83\8b\82Æ\82µ\82Ä\8eg\97p\82·\82é\83e\83L\83X\83g\95\8e\9a\97ñ\82ð\8ew\92è\82µ\82Ü\82·\81B\n\n\
-\83\89\83x\83\8b\82Ì\90æ\93ª\82É\82Í : (\83R\83\8d\83\93\82ð\8ew\92è\82µ\81A\83\89\83x\83\8b\82¾\82¯\82ð\92P\93Æ\82Å 1 \8ds\82É\93ü\97Í\82µ\82Ä\82­\82¾\n\
-\82³\82¢\81B"
-
-STRING_LABEL_HELP1, "\83f\83B\83X\83N\82Ì\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82ð\95\\\8e¦\82Ü\82½\82Í\95Ï\8dX\82µ\82Ü\82·\81B\n\nLABEL [\83h\83\89\83C\83u:][\83\89\83x\83\8b]\n"
-
-STRING_LABEL_HELP2, "\83h\83\89\83C\83u %c: \82Ì\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82Í %s \82Å\82·\n"
-STRING_LABEL_HELP3, "\83h\83\89\83C\83u %c: \82É\82Í\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82ª\82 \82è\82Ü\82¹\82ñl\n"
-STRING_LABEL_HELP4, "\83{\83\8a\83\85\81[\83\80 \83V\83\8a\83A\83\8b\94Ô\8d\86\82Í %04X-%04X\n \82Å\82·"
-STRING_LABEL_HELP5, "\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82ð 11 \95\8e\9a\88È\93à\82Å\93ü\97Í\82µ\82Ä\82­\82¾\82³\82¢\81B\n\95K\97v\82È\82¯\82ê\82ΠEnter \83L\81[\82ð\89\9f\82µ\82Ä\82­\82¾\82³\82¢: "
-
-STRING_LOCALE_HELP1, "\8c»\8dÝ\8e\9e\8d\8f\82Í"
-
-STRING_MKDIR_HELP,   "\83f\83B\83\8c\83N\83g\83\8a\82ð\8dì\90¬\82µ\82Ü\82·\81B\n\n\
-MKDIR [\83h\83\89\83C\83u:]\83p\83X\n\
-MD [\83h\83\89\83C\83u:]\83p\83X"
-
-STRING_MEMMORY_HELP1, "\83V\83X\83e\83\80 \83\81\83\82\83\8a\82Ì\97Ê\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\nMEMORY"
-
-STRING_MEMMORY_HELP2, "\n  %12s%% \82Ì\83\81\83\82\83\8a\82ª\8eg\97p\82³\82ê\82Ä\82¢\82Ü\82·\81B\n\n\
-  %13s \83o\83C\83g: \91S\95¨\97\9d\83\81\83\82\83\8a\n\
-  %13s \83o\83C\83g: \97\98\97p\89Â\94\\\82È\95¨\97\9d\83\81\83\82\83\8a\n\n\
-  %13s \83o\83C\83g: \91S\83y\81[\83W\83t\83@\83C\83\8b\n\
-  %13s \83o\83C\83g: \97\98\97p\89Â\94\\\82È\83y\81[\83W\83t\83@\83C\83\8b\n\n\
-  %13s \83o\83C\83g: \91S\89¼\91z\83\81\83\82\83\8a\n\
-  %13s \83o\83C\83g: \97\98\97p\89Â\94\\\82È\89¼\91z\83\81\83\82\83\8a\n"
-
-STRING_MISC_HELP1, "\91±\8ds\82·\82é\82É\82Í\89½\82©\83L\81[\82ð\89\9f\82µ\82Ä\82­\82¾\82³\82¢ ...\n"
-
-STRING_MOVE_HELP1, "%s \82ð\8fã\8f\91\82«\82µ\82Ü\82·\82ª\82æ\82ë\82µ\82¢\82Å\82·\82© (Yes/No/All)? "
-
-STRING_MOVE_HELP2, "\83t\83@\83C\83\8b\82ð\88Ú\93®\82¨\82æ\82Ñ\83t\83@\83C\83\8b\82Æ\83f\83B\83\8c\83N\83g\83\8a\96¼\82ð\95Ï\8dX\82µ\82Ü\82·\81B\n\n\
-1 \82Â\82Ü\82½\82Í\95¡\90\94\82Ì\83t\83@\83C\83\8b\82ð\88Ú\93®\82·\82é\82É\82Í:\n\
-MOVE [/N][\83h\83\89\83C\83u:][\83p\83X]\83t\83@\83C\83\8b\96¼1[,...] \88Ú\93®\90æ\n\n\
-\83f\83B\83\8c\83N\83g\83\8a\96¼\82ð\95Ï\8dX\82·\82é\82É\82Í:\n\
-MOVE [/N][\83h\83\89\83C\83u:][\83p\83X]\95Ï\8dX\91\95Ï\8dX\8cã\n\n\
-  [\83h\83\89\83C\83u:][\83p\83X]\83t\83@\83C\83\8b\96¼1\n\
-            \88Ú\93®\82·\82é\83t\83@\83C\83\8b\82Ì\8fê\8f\8a\82Æ\96¼\91O\82ð\8ew\92è\82µ\82Ü\82·\81B\n\
-  /N        Nothing. \83t\83@\83C\83\8b\82Æ\83f\83B\83\8c\83N\83g\83\8a\82Ì\88Ú\93®\88È\8aO\82Ì\82·\82×\82Ä\82ð\8ds\82¢\82Ü\82·\81B\n\n\
-\8c»\92i\8aK\82Å\82Ì\90§\8cÀ:\n\
-  - \83t\83@\83C\83\8b\82â\83f\83B\83\8c\83N\83g\83\8a\82ð\81A\88Ù\82È\82é\83h\83\89\83C\83u\82ð\82Ü\82½\82ª\82Á\82Ä\88Ú\93®\82·\82é\82±\82Æ\82Í\n\
-    \82Å\82«\82Ü\82¹\82ñ\81B\n"
-
-STRING_MSGBOX_HELP, "\83\81\83b\83Z\81[\83\83{\83b\83N\83X\82ð\95\\\8e¦\82µ\81A\83\86\81[\83U\81[\82É\95Ô\93\9a\82ð\8b\81\82ß\82Ü\82·\81B\n\n\
-MSGBOX \83^\83C\83v ['\83^\83C\83g\83\8b'] \83\81\83b\83Z\81[\83W\n\n\
-\83^\83C\83v        \95\\\8e¦\82³\82ê\82é\83{\83^\83\93\82Ì\83^\83C\83v\82Å\82·\81B\n\
-              \8e\9f\82Ì\92l\82ª\8eg\97p\82Å\82«\82Ü\82·: OK, OKCANCEL,\n\
-              YESNO, YESNOCANCEL\n\
-\83^\83C\83g\83\8b      \83\81\83b\83Z\81[\83\83{\83b\83N\83X\82Ì\83^\83C\83g\83\8b\82Å\82·\81B\n\
-\83\81\83b\83Z\81[\83W    \83\81\83b\83Z\81[\83\83{\83b\83N\83X\82É\95\\\8e¦\82³\82ê\82é\83\81\83b\83Z\81[\83W\82Å\82·\81B\n\n\n\
-\89\9f\82³\82ê\82½\83{\83^\83\93\82É\82æ\82è\81A\8e\9f\82Ì ERRORLEVEL \82ª\90Ý\92è\82³\82ê\82Ü\82·:\n\n\
-YES  :  10    |  NO      :  11\n\
-OK   :  10    |  CANCEL  :  12\n"
-
-STRING_PATH_HELP1, "\8eÀ\8ds\89Â\94\\\83t\83@\83C\83\8b\82Ì\8c\9f\8dõ\83p\83X\82ð\95\\\8e¦\82Ü\82½\82Í\90Ý\92è\82µ\82Ü\82·\81B\n\n\
-PATH [[\83h\83\89\83C\83u:]\83p\83X[;...]]\nPATH ;\n\n\
-\83p\83\89\83\81\81[\83^\82Æ\82µ\82Ä ; (\83Z\83~\83R\83\8d\83\93\82¾\82¯\82ð\8ew\92è\82·\82é\82Æ\81A\82·\82×\82Ä\82Ì\8c\9f\8dõ\83p\83X\82Í\n\
-\83N\83\8a\83A\82³\82ê\82Ä\8c»\8dÝ\82Ì\83f\83B\83\8c\83N\83g\83\8a\82¾\82¯\82ª\8c\9f\8dõ\82³\82ê\82Ü\82·\81B\n\
-\83p\83\89\83\81\81[\83^\82ð\8ew\92è\82¹\82¸\82É PATH \82Æ\93ü\97Í\82·\82é\82Æ\81A\8c»\8dÝ\82Ì\83p\83X\82ª\95\\\8e¦\82³\82ê\82Ü\82·\81B\n"
-
-STRING_PROMPT_HELP1, "\83R\83}\83\93\83\83v\83\8d\83\93\83v\83g\82ð\95Ï\8dX\82µ\82Ü\82·\81B\n\n\
-PROMPT [\95\8e\9a\97ñ]\n\n\
-  \95\8e\9a\97ñ    \90V\82µ\82¢\83R\83}\83\93\83\83v\83\8d\83\93\83v\83g\82ð\8ew\92è\82µ\82Ü\82·\81B\n\n\
-PROMPT \82É\82Í\92Ê\8fí\82Ì\95\8e\9a\82Æ\8e\9f\82É\8e¦\82·\93Á\8eê\83R\81[\83h\82ð\8eg\97p\82Å\82«\82Ü\82·:\n\n\
-  $A   & (\83A\83\93\83p\83T\83\93\83h)\n\
-  $B   | (\83p\83C\83v)\n\
-  $C   ( (\8d\82©\82Á\82±)\n\
-  $D   \8c»\8dÝ\82Ì\93ú\95t\n\
-  $E   \83G\83X\83P\81[\83\83R\81[\83h (ASCII \83R\81[\83h\82Ì 27)\n\
-  $F   ) (\89E\82©\82Á\82±)\n\
-  $G   > (\95s\93\99\8d\86 (\91å\82È\82è))\n\
-  $H   \83o\83b\83N\83X\83y\81[\83X (\92¼\91O\82Ì\95\8e\9a\82ð\8dí\8f\9c\82µ\82Ü\82·)\n\
-  $L   < (\95s\93\99\8d\86 (\8f¬\82È\82è))\n\
-  $N   \8c»\8dÝ\82Ì\83h\83\89\83C\83u\n\
-  $P   \8c»\8dÝ\82Ì\83h\83\89\83C\83u\82Æ\83p\83X\n\
-  $Q   = (\93\99\8d\86)\n\
-  $T   \8c»\8dÝ\82Ì\8e\9e\8d\8f\n\
-  $V   OS \82Ì\83o\81[\83W\83\87\83\93\94Ô\8d\86\n\
-  $_   \83L\83\83\83\8a\83b\83\83\8a\83^\81[\83\93\82Æ\83\89\83C\83\93\83t\83B\81[\83h\n\
-  $$   $ (\83h\83\8b\8bL\8d\86)\n"
-
-STRING_PAUSE_HELP1, "\83o\83b\83\83v\83\8d\83O\83\89\83\80\82Ì\8f\88\97\9d\82ð\88ê\8e\9e\92â\8e~\82µ\81A\8e\9f\82Ì\83\81\83b\83Z\81[\83W\82ð\95\\\8e¦\82µ\82Ü\82·\81B:\n\
-'\91±\8ds\82·\82é\82É\82Í\89½\82©\83L\81[\82ð\89\9f\82µ\82Ä\82­\82¾\82³\82¢ ...' \82Ü\82½\82Í\83\86\81[\83U\81[\82ª\92è\8b`\82µ\82½\83\81\83b\83Z\81[\83W\81B\n\n\
-PAUSE [\83\81\83b\83Z\81[\83W]"
-
-STRING_PROMPT_HELP2, "  $+   \8c»\8dÝ\82Ì\83f\83B\83\8c\83N\83g\83\8a \83X\83^\83b\83N\82Ì\90[\82³\82ð\95\\\8e¦\82µ\82Ü\82·"
-
-STRING_PROMPT_HELP3, "\n\83p\83\89\83\81\81[\83^\82ð\8ew\92è\82¹\82¸\82É PROMPT \82Æ\93ü\97Í\82·\82é\82Æ\81A\83v\83\8d\83\93\83v\83g\82Ì\90Ý\92è\82ª\83f\83t\83H\83\8b\83g\82É\83\8a\83Z\83b\83g\82³\82ê\82Ü\82·\81B"
-
-STRING_REM_HELP, "\83o\83b\83\83t\83@\83C\83\8b\82É\83R\83\81\83\93\83g (\92\8d\8eß) \82ð\8bL\98^\82µ\82Ü\82·\81B\n\nREM [\83R\83\81\83\93\83g]"
-
-STRING_RMDIR_HELP,   "\83f\83B\83\8c\83N\83g\83\8a\82ð\8dí\8f\9c\82µ\82Ü\82·\81B\n\n\
-RMDIR [\83h\83\89\83C\83u:]\83p\83X\nRD [\83h\83\89\83C\83u:]\83p\83X\n\
-  /S    \8ew\92è\82³\82ê\82½\83f\83B\83\8c\83N\83g\83\8a\93à\82É\82 \82é\83t\83@\83C\83\8b\82â\83t\83H\83\8b\83_\82à\82·\82×\82Ä\8dí\8f\9c\82µ\82Ü\82·\81B\n\
-  /Q    \8am\94F\82Ì\83\81\83b\83Z\81[\83W\82ð\95\\\8e¦\82µ\82Ü\82¹\82ñ\81B\n"
-STRING_RMDIR_HELP2,    "\83f\83B\83\8c\83N\83g\83\8a\82ª\8bó\82Å\82Í\82 \82è\82Ü\82¹\82ñ!\n"
-
-STRING_REN_HELP1, "\83t\83@\83C\83\8b\82â\83f\83B\83\8c\83N\83g\83\8a (\95¡\90\94\89Â) \82Ì\96¼\91O\82ð\95Ï\8dX\82µ\82Ü\82·\81B\n\n\
-RENAME [/E /N /P /Q /S /T] \8c³\82Ì\83t\83@\83C\83\8b\96¼ ... \90V\83t\83@\83C\83\8b\96¼\n\
-REN [/E /N /P /Q /S /T] \8c³\82Ì\83t\83@\83C\83\8b\96¼ ... \90V\83t\83@\83C\83\8b\96¼\n\n\
-  /E    \83G\83\89\81[\83\81\83b\83Z\81[\83W\82ð\95\\\8e¦\82µ\82Ü\82¹\82ñ\81B\n\
-  /N    \89½\82à\82µ\82Ü\82¹\82ñ\81B\n\
-  /P    \83t\83@\83C\83\8b\82Ì\96¼\91O\82ð\95Ï\8dX\82·\82é\91O\82É\82»\82ê\82¼\82ê\8am\94F\82ð\8b\81\82ß\82Ü\82·\81B\n\
-        (\82Ü\82¾\8eÀ\91\95\82³\82ê\82Ä\82¢\82Ü\82¹\82ñ!)\n\
-  /Q    Quiet.\n\
-  /S    \83T\83u\83f\83B\83\8c\83N\83g\83\8a\82Ì\96¼\91O\82ð\95Ï\8dX\82·\82é\81B\n\
-  /T    \96¼\91O\82ð\95Ï\8dX\82µ\82½\83t\83@\83C\83\8b\82Ì\91\8d\90\94\82ð\95ñ\8d\90\82·\82é\81B\n\n\
-\90V\83t\83@\83C\83\8b\96¼ \82É\82Í\90V\82µ\82¢\83h\83\89\83C\83u\82à\83p\83X\82à\8ew\92è\82Å\82«\82È\82¢\82Ì\82Å\92\8d\88Ó\82µ\82Ä\82­\82¾\82³\82¢\81B\n\
-\82»\82¤\82¢\82Á\82½\96Ú\93I\82É\82Í MOVE \83R\83}\83\93\83h\82ð\97p\82¢\82Ä\82­\82¾\82³\82¢\81B\n"
-
-STRING_REN_HELP2, "    %lu \8cÂ\82Ì\83t\83@\83C\83\8b\82Ì\96¼\91O\82ª\95Ï\8dX\82³\82ê\82Ü\82µ\82½\n"
-
-STRING_REN_HELP3, "    %lu \8cÂ\82Ì\83t\83@\83C\83\8b\82Ì\96¼\91O\82ª\95Ï\8dX\82³\82ê\82Ü\82µ\82½\n"
-                
-STRING_SHIFT_HELP, "\83o\83b\83\83t\83@\83C\83\8b\92\86\82Ì\92u\82«\8a·\82¦\89Â\94\\\82È\83p\83\89\83\81\81[\83^\82Ì\88Ê\92u\82ð\95Ï\8dX\82µ\82Ü\82·\81B\n\n\
-SHIFT [DOWN]"
-
-STRING_SCREEN_HELP, "\83J\81[\83\\\83\8b\82ð\88Ú\93®\82³\82¹\82Ü\82·\81B\88Ú\93®\8cã\81A\95\8e\9a\97ñ\82ð\93ü\97Í\82·\82é\82±\82Æ\82à\82Å\82«\82Ü\82·\81B\n\n\
-SCREEN \97ñ \8ds [\83e\83L\83X\83g]\n\n\
-  \97ñ         \83J\81[\83\\\83\8b\82ð\88Ú\93®\82³\82¹\82é\97ñ\82Å\82·\81B\n\
-  \8ds         \83J\81[\83\\\83\8b\82ð\88Ú\93®\82³\82¹\82é\8ds\82Å\82·\81B"
-
-STRING_SET_HELP, "\8aÂ\8b«\95Ï\90\94\82ð\95\\\8e¦\81A\90Ý\92è\81A\82Ü\82½\82Í\8dí\8f\9c\82µ\82Ü\82·\81B\n\n\
-SET [\95Ï\90\94\96¼[=]\95\8e\9a\97ñ]]\n\n\
-  \95Ï\90\94\96¼   \8aÂ\8b«\95Ï\90\94\96¼\82ð\8ew\92è\82µ\82Ü\82·\81B\n\
-  \95\8e\9a\97ñ   \95Ï\90\94\82É\8a\84\82è\93\96\82Ä\82é\95\8e\9a\97ñ\82ð\8ew\92è\82µ\82Ü\82·\81B\n\n\
-\8c»\8dÝ\82Ì\8aÂ\8b«\95Ï\90\94\82ð\95\\\8e¦\82·\82é\82É\82Í\81A\83p\83\89\83\81\81[\83^\82ð\8ew\92è\82¹\82¸\82É SET \82Æ\93ü\97Í\82µ\82Ä\82­\82¾\82³\82¢\81B\n"
-
-STRING_START_HELP1, "\95Ê\82Ì\83E\83B\83\93\83h\83E\82ð\8bN\93®\82µ\81A\8ew\92è\82µ\82½\83v\83\8d\83O\83\89\83\80\82Ü\82½\82Í\83R\83}\83\93\83h\82ð\8eÀ\8ds\82µ\82Ü\82·\81B\n\n\
-START \83R\83}\83\93\83h\n\n\
-  \83R\83}\83\93\83h    \8eÀ\8ds\82·\82é\83R\83}\83\93\83h\82ð\8ew\92è\82µ\82Ü\82·\81B\n\n\
-\8c»\8e\9e\93_\82Å\82Í\81A\83R\83}\83\93\83h\82Í\82·\82×\82Ä\93¯\8aú\82¹\82¸\82É\8aJ\8en\82³\82ê\82Ü\82·\81B\n"
-
-STRING_TITLE_HELP, "\83R\83}\83\93\83\83v\83\8d\83\93\83v\83\83E\83B\83\93\83h\83E\82Ì\83E\83B\83\93\83h\83\83^\83C\83g\83\8b\82ð\90Ý\92è\82µ\82Ü\82·\81B\n\n\
-TITLE [\95\8e\9a\97ñ]\n\n\
-\95\8e\9a\97ñ       \83R\83}\83\93\83\83v\83\8d\83\93\83v\83\83E\83B\83\93\83h\83E\82Ì\83^\83C\83g\83\8b\82ð\8ew\92è\82µ\82Ü\82·\81B\n"
-
-STRING_TIME_HELP1, "\83V\83X\83e\83\80\8e\9e\8d\8f\82ð\95\\\8e¦\82Ü\82½\82Í\90Ý\92è\82µ\82Ü\82·\81B\n\n\
-TIME [/T][\8e\9e\8d\8f]\n\n\
-  /T    \8c»\8dÝ\8e\9e\8d\8f\82Ì\95\\\8e¦\82Ì\82Ý\8ds\82¢\82Ü\82·\81B\n\n\
-\83p\83\89\83\81\81[\83^\82Ì\8ew\92è\82ª\82È\82¯\82ê\82Î\81A\8c»\8dÝ\82Ì\90Ý\92è\82ª\95\\\8e¦\82³\82ê\81A\90V\82µ\82¢\8e\9e\8d\8f\82ð\93ü\97Í\82Å\82«\82é\n\
-\83v\83\8d\83\93\83v\83g\82É\82È\82è\82Ü\82·\81B\95Ï\8dX\82µ\82È\82¢\8fê\8d\87\82Í\81AEnter \83L\81[\82ð\89\9f\82µ\82Ä\82­\82¾\82³\82¢\81B\n"
-
-STRING_TIME_HELP2, "\90V\82µ\82¢\8e\9e\8d\8f\82ð\93ü\97Í\82µ\82Ä\82­\82¾\82³\82¢: "
-
-STRING_TIMER_HELP1, "%d \83~\83\8a\95b\82ª\8co\89ß\81B\n"
-
-STRING_TIMER_HELP2, "%02d%c%02d%c%02d%c%02d \82ª\8co\89ß\81B\n"
-
-STRING_TIMER_HELP3, "10 \8cÂ\82Ü\82Å\82Ì\83X\83g\83b\83v\83E\83H\83b\83`\82ð\8eg\82¤\82±\82Æ\82ª\82Å\82«\82Ü\82·\81B\n\n\
-TIMER  [ON|OFF] [/S] [/n] [/Fn]\n\n\
-  ON          \83X\83g\83b\83v\83E\83H\83b\83`\82ð ON \82É\82µ\82Ü\82·\81B\n\
-  OFF         \83X\83g\83b\83v\83E\83H\83b\83`\82ð OFF \82É\82µ\82Ü\82·\81B\n\
-  /S          Split time. \83X\83g\83b\83v\83E\83H\83b\83`\82Ì\92l\82ð\95Ï\8dX\82·\82é\82±\82Æ\82È\82­\81A\n\
-              \8c»\8dÝ\8d\8f\82ñ\82Å\82¢\82é\8e\9e\8aÔ\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  /n          \83X\83g\83b\83v\83E\83H\83b\83`\94Ô\8d\86\82ð\8ew\92è\82µ\82Ü\82·\81B\n\
-              \83X\83g\83b\83v\83E\83H\83b\83`\82Í 0 \82©\82ç 9 \82Ü\82Å\82ª\97\98\97p\82Å\82«\82Ü\82·\81B\n\
-              \8ew\92è\82µ\82È\82¢\8fê\8d\87\81A\83f\83t\83H\83\8b\83g\82Æ\82µ\82Ä 1 \82ð\8eg\82¢\82Ü\82·\81B\n\
-  /Fn         \8fo\97Í\82Ì\8f\91\8e®\n\
-              n \82É\82Í\8e\9f\82Ì\93ñ\82Â\82Ì\92l\82ð\97p\82¢\82é\82±\82Æ\82ª\82Å\82«\82Ü\82·:\n\
-                    0    \83~\83\8a\95b\n\
-                    1    hh%cmm%css%cdd\n\n\
-ON\81AOFF\81A/S \82Ì\82¢\82¸\82ê\82à\8ew\92è\82µ\82È\82©\82Á\82½\8fê\8d\87\82É\82Í\81A\83X\83g\83b\83v\83E\83H\83b\83`\82Ì\n\
-\8fó\91Ô\82ð\90Ø\82è\91Ö\82¦\82Ü\82·\81B\n\n"
-
-STRING_TYPE_HELP1, "\83e\83L\83X\83\83t\83@\83C\83\8b\82Ü\82½\82Í\83t\83@\83C\83\8b\82Ì\93à\97e\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\nTYPE [\83h\83\89\83C\83u:][\83p\83X]\83t\83@\83C\83\8b\96¼ \n\
-  /P             1 \93x\82É 1 \89æ\96Ê\82¸\82Â\95\\\8e¦\82µ\82Ü\82·\81B\n"
-
-STRING_VERIFY_HELP1, "\82±\82Ì\83R\83}\83\93\83h\82Í\83_\83~\81[\82Å\82·!!\n\
-\83t\83@\83C\83\8b\82ª\83f\83B\83X\83N\82É\90³\82µ\82­\8f\91\82«\8d\9e\82Ü\82ê\82½\82±\82Æ\82ð\8fÆ\8d\87\82·\82é\82©\82Ç\82¤\82©\82ð\8ew\8e¦\82µ\82Ü\82·\81B\n\n\
-VERIFY [ON | OFF]\n\n\
-\8c»\8dÝ\82Ì\90Ý\92è\82ð\95\\\8e¦\82·\82é\82Æ\82«\82Í\81A\83p\83\89\83\81\81[\83^\82ð\8ew\92è\82¹\82¸\82É VERIFY \82Æ\93ü\97Í\82µ\82Ä\82­\82¾\82³\82¢\81B\n"
-
-STRING_VERIFY_HELP2, "VERIFY \82Í %s \82Å\82·\81B\n"
-
-STRING_VERIFY_HELP3, "ON \82© OFF \82Ì\82Ç\82¿\82ç\82©\82ð\8ew\92è\82µ\82Ä\82­\82¾\82³\82¢\81B"
-
-STRING_VERSION_HELP1, "\83V\83F\83\8b\82Ì\83o\81[\83W\83\87\83\93\8fî\95ñ\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\n\
-VER [/C][/R][/W]\n\n\
-  /C  \83N\83\8c\83W\83b\83g\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  /R  \8dÄ\94z\95z\82É\8aÖ\82·\82é\8fî\95ñ\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-  /W  \95Û\8fØ\82É\8aÖ\82·\82é\8fî\95ñ\82ð\95\\\8e¦\82µ\82Ü\82·\81B"
-
-STRING_VERSION_HELP2, " \82Í *\91S\82­\82Ì\96³\95Û\8fØ* \82Å\92ñ\8b\9f\82³\82ê\82Ü\82·\81B\8fÚ\82µ\82­\82Í\n\
-'ver /w' \82Æ\83^\83C\83v\82µ\82Ä\89º\82³\82¢\81B\82±\82ê\82Í\83t\83\8a\81[\83\\\83t\83g\83E\83F\83A\82Å\82 \82è\81A\82 \82é\8fð\8c\8f\82Ì\89º\82Å\n\
-\8dÄ\94Ð\95z\82·\82é\82±\82Æ\82ª\8f§\97ã\82³\82ê\82Ä\82¢\82Ü\82·\81B\8fÚ\82µ\82­\82Í 'ver /r' \82Æ\83^\83C\83v\82µ\82Ä\89º\82³\82¢\81B\n\
-\83N\83\8c\83W\83b\83g\82Ì\88ê\97\97\82ð\8c©\82é\82É\82Í 'ver /c' \82Æ\83^\83C\83v\82µ\82Ä\89º\82³\82¢\81B"
-
-STRING_VERSION_HELP3, "\n \82±\82Ì\83v\83\8d\83O\83\89\83\80\82Í\97L\97p\82Å\82 \82é\82±\82Æ\82ð\8aè\82Á\82Ä\94Ð\95z\82³\82ê\82Ü\82·\82ª\81A*\91S\82­\82Ì\96³\95Û\8fØ*\n\
\82Å\82·\81B\8f¤\8bÆ\89Â\94\\\90«\82Ì\95Û\8fØ\82â\93Á\92è\82Ì\96Ú\93I\82Ö\82Ì\93K\8d\87\90«\82Í\81A\8c¾\8aO\82É\8e¦\82³\82ê\82½\82à\82Ì\82à\8aÜ\n\
\82ß\91S\82­\91\8dÝ\82µ\82Ü\82¹\82ñ\81B\8fÚ\82µ\82­\82Í GNU General Public License \82ð\82²\97\97\82­\82¾\82³\82¢\81B"
-
-STRING_VERSION_HELP4, "\n \82±\82Ì\83v\83\8d\83O\83\89\83\80\82Í\83t\83\8a\81[\83\\\83t\83g\83E\83F\83A\82Å\82·\81B\82 \82È\82½\82Í\82±\82ê\82ð\81A\83t\83\8a\81[\83\\\83t\83g\83E\83F\n\
\83A\8dà\92c\82É\82æ\82Á\82Ä\94­\8ds\82³\82ê\82½ GNU General Public License (\83o\81[\83W\83\87\83\93 2 \82©\81A\n\
\8aó\96]\82É\82æ\82Á\82Ä\82Í\82»\82ê\88È\8d~\82Ì\83o\81[\83W\83\87\83\93\82Ì\82¤\82¿\82Ç\82ê\82©) \82Ì\92è\82ß\82é\8fð\8c\8f\82Ì\89º\82Å\8dÄ\94Ð\n\
\95z\82Ü\82½\82Í\89ü\95Ï\82·\82é\82±\82Æ\82ª\82Å\82«\82Ü\82·\81B\n"
-
-STRING_VERSION_HELP5, "\n\83o\83O\95ñ\8d\90\82Í <ros-dev@reactos.org> \82Ö\91\97\82Á\82Ä\82­\82¾\82³\82¢\81B\n\
-\8dÅ\90V\82Ì\83o\81[\83W\83\87\83\93\82Í\8e\9f\82Ì\83y\81[\83W\82©\82ç\93ü\8eè\82Å\82«\82Ü\82·: http://www.reactos.org"
-
-STRING_VERSION_HELP6, "\nFreeDOS version written by:\n"
-
-STRING_VERSION_HELP7, "\nReactOS version written by:\n"
-
-STRING_VOL_HELP1, " \83h\83\89\83C\83u %c: \82Ì\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82Í %s \82Å\82·\81B\n"
-STRING_VOL_HELP2, " \83h\83\89\83C\83u %c: \82É\82Í\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82ª\82 \82è\82Ü\82¹\82ñ\81B\n"
-STRING_VOL_HELP3, " \83{\83\8a\83\85\81[\83\80 \83V\83\8a\83A\83\8b\94Ô\8d\86\82Í %04X-%04X \82Å\82·\81B\n"
-STRING_VOL_HELP4, "\91\8dÝ\82·\82é\82È\82ç\82Î\81A\83f\83B\83X\83N\82Ì\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82Æ\83V\83\8a\83A\83\8b\94Ô\8d\86\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\nVOL [\83h\83\89\83C\83u:]"
-
-STRING_WINDOW_HELP1, "\83R\83\93\83\\\81[\83\8b \83E\83B\83\93\83h\83E\82Ì\8aO\8c©\82ð\95Ï\8dX\82µ\82Ü\82·\81B\n\n\
-WINDOW [/POS[=]\8d¶,\8fã,\95\9d,\8d\82\82³]\n\
-              [MIN|MAX|RESTORE] ['title']\n\n\
-/POS          \83E\83B\83\93\83h\83E\82Ì\88Ê\92u\82Æ\91å\82«\82³\82ð\8ew\92è\82µ\82Ü\82·\81B\n\
-MIN           \83E\83B\83\93\83h\83E\82ð\8dÅ\8f¬\89»\82µ\82Ü\82·\81B\n\
-MAX           \83E\83B\83\93\83h\83E\82ð\8dÅ\91å\89»\82µ\82Ü\82·\81B\n\
-RESTORE       \83E\83B\83\93\83h\83E\82ð\8c³\82Ì\83T\83C\83Y\82É\96ß\82µ\82Ü\82·\81B"
-
-STRING_WINDOW_HELP2, "\83R\83\93\83\\\81[\83\8b \83E\83B\83\93\83h\83E\82Ì\8aO\8c©\82ð\95Ï\8dX\82µ\82Ü\82·\81B\n\n\
-ACTIVATE '\83E\83B\83\93\83h\83E' [/POS[=]\8d¶,\8fã,\95\9d,\8d\82\82³]\n\
-              [MIN|MAX|RESTORE] ['\83^\83C\83g\83\8b']\n\n\
-\83E\83B\83\93\83h\83E    \8aO\8c©\82ð\95Ï\8dX\82·\82é\83E\83B\83\93\83h\83E\82Ì\83^\83C\83g\83\8b\82Å\82·\81B\n\
-/POS          \83E\83B\83\93\83h\83E\82Ì\88Ê\92u\82Æ\91å\82«\82³\82ð\8ew\92è\82µ\82Ü\82·\81B\n\
-MIN           \83E\83B\83\93\83h\83E\82ð\8dÅ\8f¬\89»\82µ\82Ü\82·\81B\n\
-MAX           \83E\83B\83\93\83h\83E\82ð\8dÅ\91å\89»\82µ\82Ü\82·\81B\n\
-RESTORE       \83E\83B\83\93\83h\83E\82ð\8c³\82Ì\83T\83C\83Y\82É\96ß\82µ\82Ü\82·\81B\n\
-\83^\83C\83g\83\8b      \90V\82µ\82¢\83^\83C\83g\83\8b\82Å\82·\81B\n"
-
-
-STRING_HELP1, "\97\98\97p\89Â\94\\\82È\82·\82×\82Ä\82Ì\83R\83}\83\93\83h\82Ì\88ê\97\97\82Æ\81A\82»\82Ì\90à\96¾\81B\n\n\
-  \83R\83}\83\93\83h /?     \93Á\92è\82Ì\83R\83}\83\93\83h\82É\8aÖ\82·\82é\8fÚ\8d×\8fî\95ñ\n\n\
-?        \97\98\97p\89Â\94\\\82È\82·\82×\82Ä\82Ì\83R\83}\83\93\83h\82Ì\88ê\97\97 (\90à\96¾\82È\82µ)\81B\n\
-ALIAS    \83G\83C\83\8a\83A\83X\82Ì\90Ý\92è\82â\89ð\8f\9c\82ð\82µ\82½\82è\81A\83G\83C\83\8a\83A\83X\82ð\95\\\8e¦\82µ\82½\82è\82µ\82Ü\82·\81B\n\
-ATTRIB   \83t\83@\83C\83\8b\91®\90«\82ð\95\\\8e¦\82Ü\82½\82Í\95Ï\8dX\82µ\82Ü\82·\81B\n\
-BEEP     \83X\83s\81[\83J\82©\82ç\83r\81[\83v\89¹\82ð\96Â\82ç\82µ\82Ü\82·\81B\n\
-CALL     \83o\83b\83\83v\83\8d\83O\83\89\83\80\82ð\95Ê\82Ì\83o\83b\83\83v\83\8d\83O\83\89\83\80\82©\82ç\8cÄ\82Ñ\8fo\82µ\82Ü\82·\81B\n\
-CD       \8c»\8dÝ\82Ì\83f\83B\83\8c\83N\83g\83\8a\82ð\95Ï\8dX\82µ\82½\82è\81A\83f\83B\83\8c\83N\83g\83\8a\96¼\82ð\95\\\8e¦\82µ\82½\82è\82µ\82Ü\82·\81B\n\
-CHCP     \8c»\8dÝ\82Ì\83R\81[\83\83y\81[\83W\94Ô\8d\86\82ð\95\\\8e¦\82Ü\82½\82Í\90Ý\92è\82µ\82Ü\82·\81B\n\
-CHOICE   \83\86\81[\83U\81[\82ª\91I\91ð\8e\88\82©\82ç\88ê\82Â\82ð\91I\91ð\82·\82é\82Ì\82ð\91Ò\82¿\82Ü\82·\81B\n\
-CLS      \89æ\96Ê\82ð\8fÁ\8b\8e\82µ\82Ü\82·\81B\n\
-CMD      ReactOS \83R\83}\83\93\83\83C\83\93\83^\81[\83v\83\8a\83^\82Ì\90V\82µ\82¢\83C\83\93\83X\83^\83\93\83X\82ð\8aJ\8en\82µ\82Ü\82·\81B\n\
-COLOR    \83R\83\93\83\\\81[\83\8b\82Ì\83f\83t\83H\83\8b\83g\82Ì\91O\8ci\90F\82¨\82æ\82Ñ\94w\8ci\90F\82ð\90Ý\92è\82µ\82Ü\82·\81B\n\
-COPY     1 \82Â\82Ü\82½\82Í\95¡\90\94\82Ì\83t\83@\83C\83\8b\82ð\95Ê\82Ì\8fê\8f\8a\82É\83R\83s\81[\82µ\82Ü\82·\81B\n\
-DATE     \93ú\95t\82ð\95\\\8e¦\82Ü\82½\82Í\90Ý\92è\82µ\82Ü\82·\81B\n\
-DELAY    n \95b\81A\82Ü\82½\82Í n \83~\83\8a\95b\91Ò\8b@\82µ\82Ü\82·\81B\n\
-DELETE   1 \82Â\82Ü\82½\82Í\95¡\90\94\82Ì\83t\83@\83C\83\8b\82ð\8dí\8f\9c\82µ\82Ü\82·\81B\n\
-DIR      \83f\83B\83\8c\83N\83g\83\8a\92\86\82Ì\83t\83@\83C\83\8b\82Æ\83T\83u\83f\83B\83\8c\83N\83g\83\8a\82ð\88ê\97\97\95\\\8e¦\82µ\82Ü\82·\81B\n\
-ECHO     \83\81\83b\83Z\81[\83W\82ð\95\\\8e¦\82µ\82½\82è\81A\83R\83}\83\93\83\83G\83R\81[\82Ì ON \82Æ OFF \82ð\90Ø\82è\91Ö\82¦\82Ü\82·\81B\n\
-ERASE    1 \82Â\82Ü\82½\82Í\95¡\90\94\82Ì\83t\83@\83C\83\8b\82ð\8dí\8f\9c\82µ\82Ü\82·\81B\n\
-EXIT     CMD.exe (\83R\83}\83\93\83\83\89\83C\83\93 \83C\83\93\83^\81[\83v\83\8a\83^) \82ð\8fI\97¹\82µ\82Ü\82·\81B\n\
-FOR      \8ew\92è\82³\82ê\82½\83R\83}\83\93\83h\82ð\83t\83@\83C\83\8b \83Z\83b\83g\82Ì\8ae\83t\83@\83C\83\8b\82É\91Î\82µ\82Ä\8eÀ\8ds\82µ\82Ü\82·\81B\n\
-FREE     \83f\83B\83X\83N\82Ì\8bó\82«\97e\97Ê\n\
-GOTO     \83o\83b\83\83v\83\8d\83O\83\89\83\80\93à\82Ì\81A\83\89\83x\83\8b\82Å\8ew\92è\82³\82ê\82Ä\82¢\82é\8ds\82Ö\90§\8cä\82ð\88Ú\93®\82µ\82Ü\82·\81B\n\
-HELP     ReactOS \83R\83}\83\93\83h\82Ì\83w\83\8b\83v\8fî\95ñ\82ð\92ñ\8b\9f\82µ\82Ü\82·\81B\n\
-HISTORY  \8eg\97p\82³\82ê\82½\82·\82×\82Ä\82Ì\83R\83}\83\93\83h\82ð\88ê\97\97\95\\\8e¦\82µ\82Ü\82·\81B\n\
-IF       \83o\83b\83\83v\83\8d\83O\83\89\83\80\92\86\82Å\8fð\8c\8f\8f\88\97\9d\82ð\8eÀ\8ds\82µ\82Ü\82·\81B\n\
-LABEL    \83f\83B\83X\83N\82Ì\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82ð\95\\\8e¦\82Ü\82½\82Í\95Ï\8dX\82µ\82Ü\82·\81B\n\
-MD       \83f\83B\83\8c\83N\83g\83\8a\82ð\8dì\90¬\82µ\82Ü\82·\81B\n\
-MKDIR    \83f\83B\83\8c\83N\83g\83\8a\82ð\8dì\90¬\82µ\82Ü\82·\81B\n\
-MOVE     \83t\83@\83C\83\8b\82ð\88Ú\93®\82¨\82æ\82Ñ\83t\83@\83C\83\8b\82Æ\83f\83B\83\8c\83N\83g\83\8a\96¼\82ð\95Ï\8dX\82µ\82Ü\82·\81B\n\
-PATH     \8eÀ\8ds\89Â\94\\\83t\83@\83C\83\8b\82Ì\8c\9f\8dõ\83p\83X\82ð\95\\\8e¦\82Ü\82½\82Í\90Ý\92è\82µ\82Ü\82·\81B\n\
-PAUSE    \83o\83b\83\83v\83\8d\83O\83\89\83\80\82Ì\8f\88\97\9d\82ð\88ê\8e\9e\92â\8e~\82µ\81A\83\81\83b\83Z\81[\83W\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-POPD     \8c»\8dÝ\82Ì\83f\83B\83\8c\83N\83g\83\8a\82ð PUSHD \83R\83}\83\93\83h\82Å\8bL\89¯\82³\82ê\82½\83f\83B\83\8c\83N\83g\83\8a\82É\n\
-         \95Ï\8dX\82µ\82Ü\82·\81B\n\
-PROMPT   \83R\83}\83\93\83\83v\83\8d\83\93\83v\83g\82ð\95Ï\8dX\82µ\82Ü\82·\81B\n\
-PUSHD    \8c»\8dÝ\82Ì\83f\83B\83\8c\83N\83g\83\8a\82ð\95Û\91\82µ\81A\8ew\92è\82µ\82½\83f\83B\83\8c\83N\83g\83\8a\82É\95Ï\8dX\82µ\82Ü\82·\81B\n\
-RD       \83f\83B\83\8c\83N\83g\83\8a\82ð\8dí\8f\9c\82µ\82Ü\82·\81B\n\
-REM      \83o\83b\83\83t\83@\83C\83\8b\82É\83R\83\81\83\93\83g (\92\8d\8eß) \82ð\8bL\98^\82µ\82Ü\82·\81B\n\
-REN      1 \82Â\82Ü\82½\82Í\95¡\90\94\82Ì\83t\83@\83C\83\8b\82Ì\96¼\91O\82ð\95Ï\8dX\82µ\82Ü\82·\81B\n\
-RENAME   1 \82Â\82Ü\82½\82Í\95¡\90\94\82Ì\83t\83@\83C\83\8b\82Ì\96¼\91O\82ð\95Ï\8dX\82µ\82Ü\82·\81B\n\
-RMDIR    \83f\83B\83\8c\83N\83g\83\8a\82ð\8dí\8f\9c\82µ\82Ü\82·\81B\n\
-SCREEN   \83J\81[\83\\\83\8b\82ð\88Ú\93®\82³\82¹\82Ü\82·\81B\88Ú\93®\8cã\81A\95\8e\9a\97ñ\82ð\93ü\97Í\82·\82é\82±\82Æ\82à\82Å\82«\82Ü\82·\81B\n\
-SET      \8aÂ\8b«\95Ï\90\94\82ð\95\\\8e¦\81A\90Ý\92è\81A\82Ü\82½\82Í\8dí\8f\9c\82µ\82Ü\82·\81B\n\
-SHIFT    \83J\81[\83\\\83\8b\82ð\88Ú\93®\82³\82¹\82Ü\82·\81B\88Ú\93®\8cã\81A\95\8e\9a\97ñ\82ð\93ü\97Í\82·\82é\82±\82Æ\82à\82Å\82«\82Ü\82·\81B\n"
-STRING_HELP2, "START    \95Ê\82Ì\83E\83B\83\93\83h\83E\82ð\8bN\93®\82µ\81A\8ew\92è\82µ\82½\83v\83\8d\83O\83\89\83\80\82Ü\82½\82Í\83R\83}\83\93\83h\82ð\8eÀ\8ds\82µ\82Ü\82·\81B\n\
-TIME     \83V\83X\83e\83\80\8e\9e\8d\8f\82ð\95\\\8e¦\82Ü\82½\82Í\90Ý\92è\82µ\82Ü\82·\81B\n\
-TIMER    10 \8cÂ\82Ü\82Å\82Ì\83X\83g\83b\83v\83E\83H\83b\83`\82ð\8eg\82¤\82±\82Æ\82ª\82Å\82«\82Ü\82·\81B\n\
-TITLE    \83R\83}\83\93\83\83v\83\8d\83\93\83v\83\83E\83B\83\93\83h\83E\82Ì\83E\83B\83\93\83h\83\83^\83C\83g\83\8b\82ð\90Ý\92è\82µ\82Ü\82·\81B\n\
-TYPE     \83e\83L\83X\83\83t\83@\83C\83\8b\82Ü\82½\82Í\83t\83@\83C\83\8b\82Ì\93à\97e\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-VER      ReactOS \82Ì\83o\81[\83W\83\87\83\93\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n\
-VERIFY   \83t\83@\83C\83\8b\82ª\83f\83B\83X\83N\82É\90³\82µ\82­\8f\91\82«\8d\9e\82Ü\82ê\82½\82±\82Æ\82ð\8fÆ\8d\87\82·\82é\82©\82Ç\82¤\82©\82ð\n\
-         \8ew\8e¦\82µ\82Ü\82·\81B\n\
-VOL      \83f\83B\83X\83N\82Ì\83{\83\8a\83\85\81[\83\80 \83\89\83x\83\8b\82Æ\83V\83\8a\83A\83\8b\94Ô\8d\86\82ð\95\\\8e¦\82µ\82Ü\82·\81B\n"
-
-
-STRING_CHOICE_OPTION,         "YN"
-STRING_COPY_OPTION,           "YNA"
-
-
-STRING_ALIAS_ERROR,          "\83G\83C\83\8a\83A\83X\93W\8aJ\8cã\82Ì\83R\83}\83\93\83\83\89\83C\83\93\82ª\92·\82·\82¬\82Ü\82·!\n"
-STRING_BATCH_ERROR,          "\83o\83b\83\83t\83@\83C\83\8b\82ð\8aJ\82­\82Æ\82«\82É\83G\83\89\81[\82ª\94­\90\82µ\82Ü\82µ\82½\81B\n"
-STRING_CHCP_ERROR1,          "\8c»\8dÝ\82Ì\83R\81[\83\83y\81[\83W: %u\n"
-STRING_CHCP_ERROR4,          "\96³\8cø\82È\83R\81[\83\83y\81[\83W\82Å\82·\n"
-STRING_CHOICE_ERROR,         "\96³\8cø\82È\83I\83v\83V\83\87\83\93\82Å\82·\81B\8aú\91Ò\82³\82ê\82é\8f\91\8e®: /C[:]\83I\83v\83V\83\87\83\93"
-STRING_CHOICE_ERROR_TXT,     "\96³\8cø\82È\83I\83v\83V\83\87\83\93\82Å\82·\81B\8aú\91Ò\82³\82ê\82é\8f\91\8e®: /T[:]c,nn"
-STRING_CHOICE_ERROR_OPTION,  "\96³\8cø\82È\83I\83v\83V\83\87\83\93\82Å\82·: %s"
-STRING_CMD_ERROR1,           "\83t\83@\83C\83\8b %s \82©\82ç\83\8a\83_\83C\83\8c\83N\83g\93ü\97Í\82Å\82«\82Ü\82¹\82ñ\81B\n"
-STRING_CMD_ERROR2,           "\83f\81[\83^\82ð\83p\83C\83v\82·\82é\82½\82ß\82Ì\88ê\8e\9e\83t\83@\83C\83\8b\8dì\90¬\82Ì\82Æ\82«\82É\83G\83\89\81[\82ª\94­\90\82µ\82Ü\82µ\82½\81B\n"
-STRING_CMD_ERROR3,           "\83t\83@\83C\83\8b %s \82Ö\82Æ\83\8a\83_\83C\83\8c\83N\83g\82Å\82«\82Ü\82¹\82ñ\81B\n"
-STRING_CMD_ERROR4,           "%s \82ð\8eÀ\8ds\82µ\82Ä\82¢\82Ü\82·...\n"
-STRING_CMD_ERROR5,           "cmdexit.bat \82ð\8eÀ\8ds\82µ\82Ä\82¢\82Ü\82·...\n"
-STRING_COLOR_ERROR1,         "\83G\83\89\81[! \93¯\82\90F\82ª\8ew\92è\82³\82ê\82Ü\82µ\82½\81B\n (\91O\8ci\90F\82Æ\94w\8ci\90F\82ð\93¯\82\90F\82É\82·\82é\82±\82Æ\82Í\82Å\82«\82Ü\82¹\82ñ)"
-STRING_COLOR_ERROR2,         "\90F\82Ì\8ew\92è\82É\96â\91è\82ª\82 \82è\82Ü\82·\81B"
-STRING_COLOR_ERROR3,         "Color %x\n"
-STRING_COLOR_ERROR4,         "\83G\83\89\81[! \93¯\82\90F\82ª\8ew\92è\82³\82ê\82Ü\82µ\82½\81B"
-STRING_CONSOLE_ERROR,        "\95s\96¾\82È\83G\83\89\81[: %d\n"
-STRING_COPY_ERROR1,          "\83G\83\89\81[: \8c³\82Ì\83t\83@\83C\83\8b %s \82ð\8aJ\82¯\82Ü\82¹\82ñ!\n"
-STRING_COPY_ERROR2,          "\83G\83\89\81[: \83R\83s\81[\8c³\82Æ\83R\83s\81[\90æ\82ª\88ê\8f\8f\82Å\82·!\n"
-STRING_COPY_ERROR3,          "\8ew\92è\90æ\82Ö\82Ì\8f\91\82«\8d\9e\82Ý\82Å\83G\83\89\81[\82ª\94­\90\82µ\82Ü\82µ\82½!\n"
-STRING_COPY_ERROR4,          "\83G\83\89\81[: \82Ü\82¾\8eÀ\91\95\82³\82ê\82Ä\82¢\82Ü\82¹\82ñ!\n"
-STRING_DATE_ERROR,           "\96³\8cø\82È\93ú\95t\82Å\82·\81B"
-STRING_DEL_ERROR5,           "\83t\83@\83C\83\8b %s \82Í\8dí\8f\9c\82³\82ê\82Ü\82·! "
-STRING_DEL_ERROR6,           "\82æ\82ë\82µ\82¢\82Å\82·\82© (Y/N)?"
-STRING_DEL_ERROR7,           "\8dí\8f\9c\82µ\82Ä\82¢\82Ü\82·: %s\n"
-STRING_ERROR_ERROR1,         "\95s\96¾\82È\83G\83\89\81[\82Å\82·! \83G\83\89\81\83R\81[\83h: 0x%lx\n"
-STRING_ERROR_ERROR2,         "\8d\\\95\83G\83\89\81["
-STRING_FOR_ERROR1,           "\96½\97ß\95\92\86\82É 'in' \82ª\95s\91«\82µ\82Ä\82¢\82Ü\82·\81B"
-STRING_FOR_ERROR2,           "\8a\87\8cÊ\82ª\8c©\82Â\82©\82è\82Ü\82¹\82ñ\81B"
-STRING_FOR_ERROR3,           "'do' \82ª\95s\91«\82µ\82Ä\82¢\82Ü\82·\81B" 
-STRING_FOR_ERROR4,           "'do' \82Ì\8cã\82É\83R\83}\83\93\83h\82ª\82 \82è\82Ü\82¹\82ñ\81B"
-STRING_FREE_ERROR1,          "\96³\8cø\82È\83h\83\89\83C\83u\82Å\82·\81B"
-STRING_FREE_ERROR2,          "\83\89\83x\83\8b\82ª\82 \82è\82Ü\82¹\82ñ\81B"
-STRING_GOTO_ERROR1,          "GOTO \82É\83\89\83x\83\8b\82ª\8ew\92è\82³\82ê\82Ä\82¢\82Ü\82¹\82ñ\81B"
-STRING_GOTO_ERROR2,          "\83\89\83x\83\8b '%s' \82ª\8c©\82Â\82©\82è\82Ü\82¹\82ñ\82Å\82µ\82½\81B\n"
-
-STRING_MD_ERROR,             "\82·\82Å\82É\83f\83B\83\8c\83N\83g\83\8a\93à\82É\83T\83u\83f\83B\83\8c\83N\83g\83\8a\82©\83t\83@\83C\83\8b\82ª\91\8dÝ\82µ\82Ä\82¢\82Ü\82·\81B\n"
-STRING_MD_ERROR2,            "\90V\82µ\82¢\83t\83H\83\8b\83_\82Ö\82Ì\83p\83X\82ª\91\8dÝ\82µ\82Ä\82¢\82Ü\82¹\82ñ\81B\n"
-STRING_MOVE_ERROR1,          "[OK]\n"
-STRING_MOVE_ERROR2,          "[\83G\83\89\81[]\n"
-
-STRING_REN_ERROR1,           "MoveFile() failed. \83G\83\89\81[: %lu\n"
-
-STRING_START_ERROR1,         "\8c»\8e\9e\93_\82Å\82Í\83o\83b\83`\82Í\83T\83|\81[\83g\82³\82ê\82Ä\82¢\82Ü\82¹\82ñ!"
-
-STRING_TIME_ERROR1,          "\96³\8cø\82È\8e\9e\8d\8f\82Å\82·\81B"
-
-STRING_TYPE_ERROR1,          "'/%s' \82Í\96³\8cø\82È\83I\83v\83V\83\87\83\93\82Å\82·\n"
-
-STRING_WINDOW_ERROR1,        "\83E\83B\83\93\83h\83E\82ª\8c©\82Â\82©\82è\82Ü\82¹\82ñ\81B"
-
-
-STRING_ERROR_PARAMETERF_ERROR,     "\83p\83\89\83\81\81[\83^\82Ì\8f\91\8e®\82ª\8aÔ\88á\82Á\82Ä\82¢\82Ü\82·\81B - %c\n"
-STRING_ERROR_INVALID_SWITCH,       "\96³\8cø\82È\83X\83C\83b\83`\82Å\82·\81B - /%c\n"
-STRING_ERROR_TOO_MANY_PARAMETERS,  "\83p\83\89\83\81\81[\83^\82ª\91½\82·\82¬\82Ü\82·\81B - %s\n"
-STRING_ERROR_PATH_NOT_FOUND,       "\83p\83X\82ª\8c©\82Â\82©\82è\82Ü\82¹\82ñ\81B\n"
-STRING_ERROR_FILE_NOT_FOUND,       "\83t\83@\83C\83\8b\82ª\8c©\82Â\82©\82è\82Ü\82¹\82ñ\81B\n"
-STRING_ERROR_REQ_PARAM_MISSING,    "\95K\97v\82È\83p\83\89\83\81\81[\83^\82ª\95s\91«\82µ\82Ä\82¢\82Ü\82·\81B\n"
-STRING_ERROR_INVALID_DRIVE,        "\96³\8cø\82È\83h\83\89\83C\83u\8ew\92è\82Å\82·\81B\n"
-STRING_ERROR_INVALID_PARAM_FORMAT, "\96³\8cø\82È\83p\83\89\83\81\81[\83^\82Ì\8f\91\8e®\82Å\82·\81B - %s\n"
-STRING_ERROR_BADCOMMAND,           "\83R\83}\83\93\83h\82Ü\82½\82Í\83t\83@\83C\83\8b\96¼\82ª\8aÔ\88á\82Á\82Ä\82¢\82Ü\82·\81B\n"
-STRING_ERROR_OUT_OF_MEMORY,        "\83\81\83\82\83\8a\95s\91«\83G\83\89\81[\81B\n"
-STRING_ERROR_CANNOTPIPE,           "\83G\83\89\81[!  \83p\83C\83v\82Å\82«\82Ü\82¹\82ñ!  \88ê\8e\9e\83t\83@\83C\83\8b\82ð\8aJ\82¯\82Ü\82¹\82ñ!\n"
-STRING_ERROR_D_PAUSEMSG,           "\91±\8ds\82·\82é\82É\82Í\89½\82©\83L\81[\82ð\89\9f\82µ\82Ä\82­\82¾\82³\82¢ . . ."
-STRING_ERROR_DRIVER_NOT_READY,     "\83h\83\89\83C\83u\82Ì\8f\80\94õ\82ª\82Å\82«\82Ä\82¢\82Ü\82¹\82ñ\81B"
-
-STRING_PATH_ERROR,                 "CMD: Not in environment '%s'\n"
-
-STRING_CMD_SHELLINFO,              "\nReactOS Command Line Interpreter"
-STRING_VERSION_RUNVER,             " running on %s"
-STRING_COPY_FILE ,                 "        %d \8cÂ\82Ì\83t\83@\83C\83\8b\82ª\83R\83s\81[\82³\82ê\82Ü\82µ\82½\n"
-STRING_DELETE_WIPE,                "\8a®\91S\82É\8fÁ\8b\8e\82³\82ê\82Ü\82µ\82½\81B"
-STRING_FOR_ERROR,                  "\96³\8cø\82È\95Ï\90\94\82ª\8ew\92è\82³\82ê\82Ü\82µ\82½\81B"
-STRING_SCREEN_COL,                 "\8ds\82Ì\92l\82ª\96³\8cø\82Å\82·\81B"
-STRING_SCREEN_ROW,                 "\97ñ\82Ì\92l\82ª\96³\8cø\82Å\82·\81B"
-STRING_TIMER_TIME                  "\83^\83C\83}\81[ %d \82Í %s \82Å\82·\81B: "
-
-STRING_INVALID_OPERAND,            "\96³\8cø\82È\83I\83y\83\89\83\93\83h\82Å\82·\81B"
-STRING_EXPECTED_CLOSE_PAREN,       "Expected ')'"
-STRING_EXPECTED_NUMBER_OR_VARIABLE,"Expected number or variable name."
-STRING_SYNTAX_COMMAND_INCORRECT,   "\83R\83}\83\93\83h\82Ì\8d\\\95\82ª\8aÔ\88á\82Á\82Ä\82¢\82Ü\82·\81B"
-
-}
diff --git a/reactos/subsys/system/cmd/Ru.rc b/reactos/subsys/system/cmd/Ru.rc
deleted file mode 100644 (file)
index a4645b9..0000000
+++ /dev/null
@@ -1,656 +0,0 @@
-#include "windows.h"
-#include "resource.h"
-/*
- * Russian language file by
- * Andrey Korotaev (unC0Rr@inbox.ru)
- * and
- * Aleksey Bragin (aleksey@reactos.com)
- * Copyright 2005
- */
-
-
-LANGUAGE LANG_RUSSIAN, SUBLANG_NEUTRAL
-STRINGTABLE DISCARDABLE
-{
-
-STRING_ATTRIB_HELP,    "Âûâîä è èçìåíåíèå àòðèáóòîâ ôàéëîâ.\n\n\
-ATTRIB [+R | -R] [+A | -A] [+S | -S] [+H | -H] ôàéë ...\n\
-       [/S [/D]]\n\n\
-  +   Óñòàíîâêà àòðèáóòà.\n\
-  -   Ñíÿòèå àòðèáóòà.\n\
-  R   Àòðèáóò ""Òîëüêî ÷òåíèå"".\n\
-  A   Àòðèáóò ""Àðõèâíûé"".\n\
-  S   Àòðèáóò ""Ñèñòåìíûé"".\n\
-  H   Àòðèáóò ""Ñêðûòûé"".\n\
-  /S  Îáðàáîòêà ôàéëîâ ñ óêàçàííûìè èìåíàìè â òåêóùåé ïàïêå\n\
-è âî âñåõ åå ïîäïàïêàõ.\n\
-  /D  Îáðàáîòêà è ôàéëîâ, è ïàïîê.\n\n\
-ATTRIB áåç ïàðàìåòðîâ âûâîäèò àòðèáóòû âñåõ ôàéëîâ.\n"
-
-STRING_ALIAS_HELP,  "Âûâîä, óñòàíîâêà èëè óäàëåíèå ïñåâäîíèìîâ.\n\n\
-ALIAS [ïñåâäîíèì=[êîìàíäà]]\n\n\
-  ïñåâäîíèì    Íàèìåíîâàíèå ïñåâäîíèìà.\n\
-  êîìàíäà      Òåêñò, ïîäñòàâëÿåìûé âìåñòî ïñåâäîíèìà.\n\n\
-Âûâîä ñïèñêà âñåõ ïñåâäîíèìîâ:\n\
-  ALIAS\n\n\
-Óñòàíîâêà èëè èçìåíåíèå ñóùåñòâóþùåãî ïñåâäîíèìà:\n\
-  ALIAS da=dir a:\n\n\
-Óäàëåíèå ïñåâäîíèìà èç ñïèñêà:\n\
-  ALIAS da="
-
-STRING_BEEP_HELP, "Çâóêîâîé ñèãíàë.\n\nBEEP\n"
-
-STRING_CALL_HELP, "Âûçîâ îäíîãî ïàêåòíîãî ôàéëà èç äðóãîãî.\n\n\
-CALL [äèñê:][ïóòü]èìÿ_ôàéëà [ïàðàìåòðû]\n\n\
-  ïàðàìåòðû   Íàáîð ïàðàìåòðîâ êîìàíäíîé ñòðîêè, íåîáõîäèìûõ\n\
-              ïàêåòíîìó ôàéëó."
-
-STRING_CD_HELP,      "Âûâîä èìåíè ëèáî ñìåíà òåêóùåãî êàòàëîãà.\n\n\
-CHDIR [/D][äèñê:][ïóòü]\n\
-CHDIR[..|.]\n\
-CD [/D][äèñê:][ïóòü]\n\
-CD[..|.]\n\n\
-  ..   îáîçíà÷àåò ðîäèòåëüñêèé êàòàëîã\n\
-  .    îáîçíà÷àåò òåêóùèé êàòàëîã\n\
-  /D   Îäíîâðåìåííàÿ ñìåíà òåêóùèõ äèñêà è êàòàëîãà.\n\n\
-Êîìàíäà CD äèñê: îòîáðàæàåò èìÿ òåêóùåãî êàòàëîãà óêàçàííîãî äèñêà.\n\
-Êîìàíäà CD áåç ïàðàìåòðîâ îòîáðàæàåò èìåíà òåêóùèõ äèñêà è êàòàëîãà.\n"
-
-STRING_CHCP_HELP,   "Âûâîä èëè ñìåíà òåêóùåãî íîìåðà êîäîâîé ñòðàíèöû.\n\n\
-CHCP [nnn]\n\n\
-  nnn   Íîìåð êîäîâîé ñòðàíèöû.\n\n\
-Êîìàíäà CHCP áåç ïàðàìåòðà âûâîäèò òåêóùèé íîìåð êîäîâîé ñòðàíèöû.\n"
-
-STRING_CHOICE_HELP, "Æä¸ò, ïîêà ïîëüçîâàòåëü íå âûáåðåò îäèí èç óêàçàííûõ â ñïèñêå ñèìâîëîâ.\n\n\
-CHOICE  [/C[:]ñïèñîê_ñèìâîëîâ][/N][/S][/T[:]c,nn][òåêñò]\n\n\
-  /C[:]ñïèñîê_ñèìâîëîâ  Óêàçûâàåò äîïóñòèìûå ñèìâîëû. Ïî óìîë÷àíèþ ýòî YN.\n\
-  /N            Íå âûâîäèòü ñïèñîê ñèìâîëîâ è ? ïîñëå ïîäñêàçêè.\n\
-  /S            Òðàêòîâàòü ñèìâîëû êàê ÷óâñòâèòåëüíûå ê ðåãèñòðó.\n\
-  /T[:]c,nn     Ïî óìîë÷àíèþ âûáîð c ïî èñòå÷åíèè nn ñåêóíä.\n\
-  text          Ïîäñêàçêà.\n\n\
-ERRORLEVEL óñòàíàâëèâàåòñÿ ðàâíûì íîìåðó âûáðàííîãî ñèìâîëà.\n"
-
-STRING_CLS_HELP, "Î÷èñòêà ýêðàíà.\n\nCLS\n"
-
-STRING_CMD_HELP1, "\nÄîñòóïíûå âíóòðåííèå êîìàíäû:\n"
-
-STRING_CMD_HELP2, "\nÄîñòóïíûå âîçìîæíîñòè:"
-
-STRING_CMD_HELP3,"  [ïñåâäîíèìû]"
-
-STRING_CMD_HELP4,"  [èñòîðèÿ]"
-
-STRING_CMD_HELP5,"  [çàâåðøåíèå èìåí ôàéëîâ unix]"
-
-STRING_CMD_HELP6,"  [ñòåê äèðåêòîðèé]"
-
-STRING_CMD_HELP7,"  [ïåðåíàïðàâëåíèå è piping]"
-
-STRING_CMD_HELP8, "Çàïóñê íîâîé êîïèè èíòåðïðåòàòîðà êîìàíä ReactOS.\n\n\
-CMD [/[C|K] êîìàíäà][/P][/Q][/T:bf]\n\n\
-  /C êîìàíäà  Âûïîëíåíèå óêàçàííîé êîìàíäû ñ ïîñëåäóþùèì çàâåðøåíèåì.\n\
-  /K êîìàíäà  Âûïîëíåíèå óêàçàííîé êîìàíäû áåç ïîñëåäóþùåãî çàâåðøåíèÿ.\n\
-  /P          CMD ñòàíîâèòñÿ ïåðìàíåíòíûì è çàïóñêàåò autoexec.bat\n\
-              (ïðîöåññ íåìîæåò áûòü çàâåðøåí).\n\
-  /T:öâ       Âûáîð öâåòà òåêñòà/ôîíà (áîëåå ïîäðîáíî ñì. COLOR /?).\n"
-
-STRING_COLOR_HELP1, "Óñòàíîâêà öâåòîâ ïî óìîë÷àíèþ äëÿ òåêñòà è ôîíà.\n\n\
-COLOR [öâåòà [/-F]] \n\n\
-  öâåòà       Àòðèáóòû öâåòîâ äëÿ òåêñòîâûõ îêîí\n\
-  /-F         Íå çàëèâàòü íåçàïîëíåííûå ìåñòà öâåòîì\n\n\
-Åñòü òðè ñïîñîáà îáîçíà÷àòü öâåòà:\n\
-1) ïî íàçâàíèþ íà àíãëèéñêîì ÿçûêå (òðåáóþòñÿ òîëüêî ïåðâûå òðè áóêâû öâåòà)\n\
-2) â âèäå äåñÿòè÷íûõ ÷èñåë (decimal on decimal)\n\
-3) äâà øåñòíàäöàòåðè÷íûõ ÷èñëà\n\n\
-Òàáëèöà öâåòîâ:\n\
-äåñ. øåñò.íàçâàíèå   äåñ. øåñò.íàçâàíèå\n\
- 0    0 = ×åðíûé       8   8 = Ñåðûé\n\
- 1    1 = Ñèíèé        9   9 = Ñâåòëî-ñèíèé\n\
- 2    2 = Çåëåíûé     10   A = Ñâåòëî-çåëåíûé\n\
- 3    3 = Ãîëóáîé     11   B = Ñâåòëî-ãîëóáîé\n\
- 4    4 = Êðàñíûé     12   C = Ñâåòëî-êðàñíûé\n\
- 5    5 = Ëèëîâûé     13   D = Ñâåòëî-ëèëîâûé\n\
- 6    6 = Æåëòûé      14   E = Ñâåòëî-æåëòûé\n\
- 7    7 = Áåëûé       15   F = ßðêî-áåëûé\n"
-
-STRING_COPY_HELP1,  "Ïåðåçàïèñàòü %s (Yes/No/All)? "
-
-STRING_COPY_HELP2, "Êîïèðîâàíèå îäíîãî èëè íåñêîëüêèõ ôàéëîâ â äðóãîå ìåñòî.\n\n\
-COPY [/V][/Y|/-Y][/A|/B] èñòî÷íèê [/A|/B]\n\
-     [+ èñòî÷íèê [/A|/B] [+ ...]] [ðåçóëüòàò [/A|/B]]\n\n\
-  èñòî÷íèê     Èìåíà îäíîãî èëè íåñêîëüêèõ êîïèðóåìûõ ôàéëîâ.\n\
-  /A           Ôàéë ÿâëÿåòñÿ òåêñòîâûì ôàéëîì ASCII.\n\
-  /B           Ôàéë ÿâëÿåòñÿ äâîè÷íûì ôàéëîì.\n\
-  ðåçóëüòàò    Êàòàëîã è/èëè èìÿ äëÿ êîíå÷íûõ ôàéëîâ.\n\
-  /V           Ïðîâåðêà ïðàâèëüíîñòè êîïèðîâàíèÿ ôàéëîâ.\n\
-  /Y           Ïîäàâëåíèå çàïðîñà ïîäòâåðæäåíèÿ íà ïåðåçàïèñü ñóùåñòâóþùåãî\n\
-               ðåçóëüòèðóþùåãî ôàéëà.\n\
-  /-Y          Îáÿçàòåëüíûé çàïðîñ ïîäòâåðæäåíèÿ íà ïåðåçàïèñü ñóùåñòâóþùåãî\n\
-               ðåçóëüòèðóþùåãî ôàéëà.\n\n\
-Êëþ÷ /Y ìîæíî óñòàíîâèòü ÷åðåç ïåðåìåííóþ ñðåäû COPYCMD.\n\
-...\n"
-
-STRING_DATE_HELP1, "\nÂâåäèòå íîâóþ äàòó (ìì%cää%cãããã): "
-
-STRING_DATE_HELP2, "\nÂâåäèòå íîâóþ äàòó (ää%cìì%cãããã): "
-
-STRING_DATE_HELP3, "\nÂâåäèòå íîâóþ äàòó (ãããã%cìì%cää): "
-
-STRING_DATE_HELP4, "Âûâîä èëè èçìåíåíèå äàòû.\n\n\
-DATE [/T][äàòà]\n\n\
-  /T    Íå çàïðàøèâàòü ââîä íîâîé äàòû\n\n\
-Êîìàíäà DATE áåç ïàðàìåòðîâ îòîáðàæàåò òåêóùóþ äàòó è çàïðàøèâàåò ââîä\n\
-íîâîé äàòû.  Äëÿ ñîõðàíåíèÿ òåêóùåé äàòû íàæìèòå êëàâèøó ENTER.\n"
-                               
-STRING_DEL_HELP1,  "Óäàëåíèå îäíîãî èëè íåñêîëüêèõ ôàéëîâ.\n\n\
-DEL [/N /P /T /Q /S /W /Y /Z /A[[:]àòðèáóòû]] èìåíà_ôàéëîâ ...\n\
-DELETE [/N /P /T /Q /S /W /Y /Z /A[[:]àòðèáóòû]] èìåíà_ôàéëîâ ...\n\
-ERASE [/N /P /T /Q /S /W /Y /Z /A[[:]àòðèáóòû]] èìåíà_ôàéëîâ ...\n\n\
-      èìåíà_ôàéëîâ  Èìåíà îäíîãî èëè íåñêîëüêèõ ôàéëîâ.\n\n\
-  /N    Íåâûïîëíÿòü íåïîñðåäñòâåííî îïåðàöèþ óäàëåíèÿ ôàéëà.\n\
-  /P    Çàïðîñ íà ïîäòâåðæäåíèå ïåðåä óäàëåíèåì êàæäîãî ôàéëà.\n\
-  /T    Ïîêàçûâàåò êîëè÷åñòâî óäàë¸ííûõ ôàéëîâ è îñâîáîäèâøåãîñÿ\n\
-        äèñêîâîãî ïðîñòðàíñòâà.\n\
-  /Q    Îòêëþ÷åíèå çàïðîñà íà ïîäòâåðæäåíèå ïðè óäàëåíèè ôàéëîâ.\n\
-  /W    Ïåðåïèñàòü ôàéë ñëó÷àéíûìè äàííûìè ïåðåä óäàëåíèåì.\n\
-  /Y    Îòêëþ÷åíèå çàïðîñà íà ïîäòâåðæäåíèå ïðè óäàëåíèè ôàéëîâ\n\
-        äàæå äëÿ ìàñêè *.*.\n\
-  /F    Ïðèíóäèòåëüíîå óäàëåíèå ôàéëîâ, äîñòóïíûõ òîëüêî äëÿ ÷òåíèÿ.\n\
-  /S    Óäàëÿòü ôàéë èç âñåõ ïîääèðåêòîðèé\n\
-  /A    Îòáîð ôàéëîâ äëÿ óäàëåíèÿ ïî àòðèáóòàì.\n\
-        R     Äîñòóïíûé òîëüêî äëÿ ÷òåíèÿ\n\
-        S     Ñèñòåìíûå ôàéëû\n\
-        A     Ôàéëû äëÿ àðõèâèðîâàíèÿ\n\
-        H     Ñêðûòûå ôàéëû\n\
-        Ïðåôèêñ ""-"" èìååò çíà÷åíèå ÍÅ\n"
-
-STRING_DEL_HELP2, "Âñå ôàéëû â êàòàëîãå áóäóò óäàëåíû!\nÂû óâåðåíû (Y/N)?"
-STRING_DEL_HELP3, "    %lu ôàéë óäàë¸í\n"
-STRING_DEL_HELP4, "    %lu ôàéëîâ óäàëåíî\n"
-
-STRING_DELAY_HELP, "ïàóçà íà n ñåêóíä èëè ìèëëèñåêóíä\n\
-DELAY [/m]n\n\n\
-  /m          óêàçûâàåò, ÷òî n îçíà÷àåò êîëè÷åñòâî ìèëëèñåêóíä\n\
-              èíà÷å n îçíà÷àåò êîëè÷åñòâî ñåêóíä\n"
-
-STRING_DIR_HELP1, "DIR [äèñê:][ïóòü][èìÿ_ôàéëà] [/A[[:]àòðèáóòû]] [/B] [/C] [/D] [/L] [/N]\n\
-  [/O[[:]sortorder]] [/P] [/Q] [/S] [/T[[:]timefield]] [/W] [/X] [/4]\n\n\
-  [äèñê:][ïóòü][èìÿ_ôàéëà]\n\
-              Äèñê, êàòàëîã è/èëè ôàéëû, êîòîðûå ñëåäóåò âêëþ÷èòü â ñïèñîê.\n\n\
-  /A          Âûâîä ôàéëîâ ñ óêàçàííûìè àòðèáóòàìè.\n\
-  àòðèáóòû   D  Êàòàëîãè                    R  Äîñòóïíûå òîëüêî äëÿ ÷òåíèÿ\n\
-             H  Ñêðûòûå ôàéëû               A  Ôàéëû äëÿ àðõèâèðîâàíèÿ\n\
-             S  Ñèñòåìíûå ôàéëû             Ïðåôèêñ ""-"" èìååò çíà÷åíèå ÍÅ\n\
-  /B         Âûâîä òîëüêî èìåí ôàéëîâ.\n\
-  /C         Ïðèìåíåíèå ðàçäåëèòåëÿ ãðóïï ðàçðÿäîâ äëÿ âûâîäà ðàçìåðîâ ôàéëîâ\n\
-             (ïî óìîë÷àíèþ).  Äëÿ îòêëþ÷åíèÿ ýòîãî ðåæèìà ñëóæèò êëþ÷ /-C.\n\
-  /D         Âûâîä ñïèñêà â íåñêîëüêî ñòîëáöîâ ñ ñîðòèðîâêîé ïî ñòîëáöàì.\n\
-  /L         Èñïîëüçîâàíèå íèæíåãî ðåãèñòðà äëÿ èìåí ôàéëîâ.\n\
-  /N         Îòîáðàæåíèå èìåí ôàéëîâ â êðàéíåì ïðàâîì ñòîëáöå.\n\
-  /O         Ñîðòèðîâêà ñïèñêà îòîáðàæàåìûõ ôàéëîâ.\n\
-  ïîðÿäîê    N  Ïî èìåíè (àëôàâèòíàÿ)       S  Ïî ðàçìåðó (ñïåðâà ìåíüøèå)\n\
-             E  Ïî ðàñøèðåíèþ (àëôàâèòíàÿ)  D  Ïî äàòå (ñïåðâà áîëåå ñòàðûå)\n\
-             G  Íà÷àòü ñïèñîê ñ êàòàëîãîâ   Ïðåôèêñ ""-"" îáðàùàåò ïîðÿäîê\n\
-  /P         Ïàóçà ïîñëå çàïîëíåíèÿ êàæäîãî ýêðàíà.\n\
-  /Q         Âûâîä ñâåäåíèé î âëàäåëüöå ôàéëà.\n\
-  /S         Âûâîä ñïèñêà ôàéëîâ èç óêàçàííîãî êàòàëîãà è åãî ïîäêàòàëîãîâ.\n\
-  /T         Âûáîð ïîëÿ âðåìåíè äëÿ îòîáðàæåíèÿ è ñîðòèðîâêè\n\
-  âðåìÿ      C  Ñîçäàíèå\n\
-             A  Ïîñëåäíåå èñïîëüçîâàíèå\n\
-             W  Ïîñëåäíåå èçìåíåíèå\n\
-  /W         Âûâîä ñïèñêà â íåñêîëüêî ñòîëáöîâ.\n\
-  /X         Îòîáðàæåíèå êîðîòêèõ èìåí äëÿ ôàéëîâ, ÷üè èìåíà íå ñîîòâåòñòâóþò\n\
-             ñòàíäàðòó 8.3. Ôîðìàò àíàëîãè÷åí âûâîäó ñ êëþ÷îì /N, íî êîðîòêèå\n\
-             èìåíà ôàéëîâ âûâîäÿòñÿ ñëåâà îò äëèííûõ. Åñëè êîðîòêîãî èìåíè ó\n\
-             ôàéëà íåò, âìåñòî íåãî âûâîäÿòñÿ ïðîáåëû.\n\
-  /4         Âûâîä íîìåðà ãîäà â ÷åòûðåõçíà÷íîì ôîðìàòå\n"
-
-STRING_DIR_HELP2, " Òîì â óñòðîéñòâå %c èìååò ìåòêó %s\n"
-STRING_DIR_HELP3, " Òîì â óñòðîéñòâå %c íå èìååò ìåòêè.\n"
-STRING_DIR_HELP4, " Ñåðèéíûé íîìåð òîìà: %04X-%04X\n"
-STRING_DIR_HELP5, "\n     Âñåãî:\n%16i Ôàéë(îâ)% 14s áàéò\n"
-STRING_DIR_HELP6, "%16i Dir(s)% 15s áàéò\n"
-STRING_DIR_HELP7, "\n Êàòàëîã of %s\n\n"
-STRING_DIR_HELP8, "%16i ôàéë(îâ)% 14s áàéò\n"
-
-STRING_DIRSTACK_HELP1, "Ñîõðàíÿåò òåêóùóþ äèðåêòîðèþ äëÿ èñïîëüçîâàíèÿ êîìàíäîé POPD, çàòåì\n\
-èçìåíÿåò å¸ íà óêàçàííóþ.\n\n\
-PUSHD [path | ..]\n\n\
-  path        Óêàçûâàåò äèðåêòîðèþ, êîòîðóþ íàäî ñäåëàòü òåêóùåé\n"
-
-STRING_DIRSTACK_HELP2, "Èçìåíÿåò òåêóùóþ äèðåêòîðèþ íà òó, êîòîðàÿ ñîõðàíåíà êîìàíäîé PUSHD.\n\nPOPD"
-
-STRING_DIRSTACK_HELP3, "Ïå÷àòàåò ñîäåðæèìîå ñòåêà äèðåêòîðèé.\n\nDIRS"
-
-STRING_DIRSTACK_HELP4, "Ñòåê äèðåêòîðèé ïóñò"
-
-STRING_ECHO_HELP1,  "Âûäàåò ñîîáùåíèå áåç ïåðåâîäà ñòðîêè.\n\n\
-  ECHOS message"
-
-STRING_ECHO_HELP2,  "Âûäàåò ñîîáùåíèå â ñòàíäàðòíûé êàíàë âûâîäà îøèáîê.\n\n\
-  ECHOERR message\n\
-  ECHOERR.           ïå÷àòàåò ïóñòóþ ñòðîêó"
-
-STRING_ECHO_HELP3, "Ïå÷àòàåò ñîîáùåíèå â ñòàíäàðòíûé êàíàë âûâîäà îøèáîê áåç ïåðåâîäà ñòðîêè è âîçâðàòà êàðåòêè.\n\n\
-  ECHOSERR message"
-
-STRING_ECHO_HELP4, "Âûâîä ñîîáùåíèé è ïåðåêëþ÷åíèå ðåæèìà îòîáðàæåíèÿ êîìàíä íà ýêðàíå.\n\n\
-  ECHO [ON | OFF]\n\
-  ECHO [ñîîáùåíèå]\n\
-  ECHO.             âûâîä ïóñòîé ñòðîêè\n\n\
-ECHO áåç ïàðàìåòðà âûâîäèò òåêóùèé ðåæèì îòîáðàæåíèÿ êîìàíä."
-
-STRING_ECHO_HELP5, "ECHO is %s\n"
-
-STRING_EXIT_HELP, "Çàâåðøàåò èíòåðïðåòàòîð êîìàíä.\n\nEXIT\n"
-
-STRING_FOR_HELP1, "Çàïóñêàåò óêàçàííóþ êîìàíäó äëÿ êàæäîãî ôàéëà èç íàáîðà ôàéëîâ\n\n\
-FOR %ïåðåìåííàÿ IN (íàáîð) DO êîìàíäà [ïàðàìåòðû]\n\n\
-  %ïåðåìåííàÿ  Ïîäñòàâëÿåìûé ïàðàìåòð.\n\
-  (íàáîð)      Íàáîð èç îäíîãî èëè íåñêîëüêèõ ôàéëîâ.\n\
-               Äîïóñêàåòñÿ èñïîëüçîâàíèå ïîäñòàíîâî÷íûõ çíàêîâ.\n\
-  êîìàíäà      Êîìàíäà, êîòîðóþ ñëåäóåò âûïîëíèòü äëÿ êàæäîãî ôàéëà.\n\
-  ïàðàìåòðû    Ïàðàìåòðû è êëþ÷è äëÿ óêàçàííîé êîìàíäû.\n\n\
- ïàêåòíûõ ôàéëàõ äëÿ êîìàíäû FOR èñïîëüçóåòñÿ çàïèñü\n\
-%%ïåðåìåííàÿ âìåñòî %ïåðåìåííàÿ.\n"
-
-STRING_FREE_HELP1, "\nÒîì äèñêà %s: %-11s\n\
- Ñåðèéíûé íîìåð: %s\n\
-  %16s áàéò îáùåãî äèñêîâîãî ïðîñòðàíñòâà\n\
-  %16s áàéò çàíÿòî\n\
-  %16s áàéò ñâîáîäíî\n"
-
-STRING_FREE_HELP2, "Âûâîäèò èíôîðìàöèþ î òîìå.\n\nFREE [drive: ...]\n"
-
-STRING_IF_HELP1, "Îïåðàòîð óñëîâíîãî âûïîëíåíèÿ êîìàíä â ïàêåòíîì ôàéëå.\n\n\
-  IF [NOT] ERRORLEVEL ÷èñëî êîìàíäà\n\
-  IF [NOT] ñòðîêà1==ñòðîêà2 êîìàíäà\n\
-  IF [NOT] EXIST èìÿ_ôàéëà êîìàíäà\n\
-  IF [NOT] DEFINED ïåðåìåííàÿ êîìàíäà\n\n\
-  NOT               Îáðàùàåò èñòèííîñòü óñëîâèÿ: èñòèííîå óñëîâèå\n\
-                    ñòàíîâèòñÿ ëîæíûì, à ëîæíîå - èñòèííûì.\n\
-  ERRORLEVEL ÷èñëî  Óñëîâèå ÿâëÿåòñÿ èñòèííûì, åñëè êîä âîçâðàòà ïîñëåäíåé\n\
-                    âûïîëíåííîé ïðîãðàììû íå ìåíüøå óêàçàííîãî ÷èñëà.\n\
-  ñòðîêà1==ñòðîêà2  Ýòî óñëîâèå ÿâëÿåòñÿ èñòèííûì, åñëè óêàçàííûå ñòðîêè\n\
-                    ñîâïàäàþò.\n\
-  EXIST èìÿ_ôàéëà   Ýòî óñëîâèå ÿâëÿåòñÿ èñòèííûì, åñëè ôàéë ñ óêàçàííûì\n\
-                    èìåíåì ñóùåñòâóåò.\n\
-DEFINED ïåðåìåííàÿ  Ýòî óñëîâèå ÿâëÿåòñÿ èñòèííûì, åñëè óêàçàííàÿ ïåðåìåííàÿ\n\
-                    çàäàíà\n\
-  êîìàíäà           Çàäàåò êîìàíäó, âûïîëíÿåìóþ ïðè èñòèííîñòè óñëîâèÿ.\n\
-                    Çà ýòîé êîìàíäîé ìîæåò ñëåäîâàòü êëþ÷åâîå ñëîâî ELSE,\n\
-                    ñëóæàùåå äëÿ óêàçàíèÿ êîìàíäû, êîòîðàÿ äîëæíà\n\
-                    âûïîëíÿòüñÿ â òîì ñëó÷àå, åñëè óñëîâèå ëîæíî.\n"
-
-STRING_GOTO_HELP1,  "Ïåðåäà÷à óïðàâëåíèÿ ñîäåðæàùåé ìåòêó ñòðîêå ïàêåòíîãî ôàéëà.\n\n\
-GOTO ìåòêà\n\n\
-  label  Ñòðîêà ïàêåòíîãî ôàéëà, îôîðìëåííàÿ êàê ìåòêà.\n\n\
-Ìåòêà äîëæíà íàõîäèòüñÿ â îòäåëüíîé ñòðîêå è íà÷èíàòüñÿ ñ äâîåòî÷èÿ."
-
-STRING_LABEL_HELP1, "Ñîçäàíèå, èçìåíåíèå è óäàëåíèå ìåòîê òîìà.\n\nLABEL [äèñê:][ìåòêà]\n"
-
-STRING_LABEL_HELP2, "Òîì â óñòðîéñòâå %c èìååò ìåòêó %s\n"
-STRING_LABEL_HELP3, "Òîì â óñòðîéñòâå %c: íå èìååò ìåòêè\n"
-STRING_LABEL_HELP4, "Ñåðèéíûé íîìåð òîìà: %04X-%04X\n"
-STRING_LABEL_HELP5, "Ìåòêà òîìà (11 áóêâ, ÂÂÎÄ äëÿ ïóñòîé ìåòêè)? "
-
-STRING_LOCALE_HELP1, "Òåêóùåå âðåìÿ: "
-
-STRING_MKDIR_HELP,   "Ñîçäàíèå êàòàëîãà.\n\n\
-MKDIR [äèñê:]ïóòü\nMD [äèñê:]ïóòü"
-
-STRING_MEMMORY_HELP1, "Âûâîä îáú¸ìà ñèñòåìíîé ïàìÿòè.\n\nMEMORY"
-
-STRING_MEMMORY_HELP2, "\n  %12s%% memory load.\n\n\
-  %13s áàéò âñåãî ôèçè÷åñêîé ïàìÿòè.\n\
-  %13s áàéò äîñòóïíî ôèçè÷åñêîé ïàìÿòè.\n\n\
-  %13s áàéò âñåãî â ôàéëå ïîäêà÷êè.\n\
-  %13s áàéò äîñòóïíî â ôàéëå ïîäêà÷êè.\n\n\
-  %13s áàéò âñåãî âèðòóàëüíîé ïàìÿòè.\n\
-  %13s áàéò äîñòóïíî âèðòóàëüíî ïàìÿòè.\n"
-
-STRING_MISC_HELP1, "Íàæìèòå êëàâèøó äëÿ ïðîäîëæåíèÿ...\n"
-
-STRING_MOVE_HELP1, "Ïåðåïèñàòü %s (Yes/No/All)? "
-
-STRING_MOVE_HELP2, "Ïåðåìåùåíèå ôàéëîâ è ïåðåèìåíîâàíèå ôàéëîâ è êàòàëîãîâ.\n\n\
-Ïåðåìåùåíèå îäíîãî èëè áîëåå ôàéëîâ:\n\
-MOVE [/N][äèñê:][ïóòü]èìÿ_ôàéëà1[,...] íàçíà÷åíèå\n\n\
-Ïåðåèìåíîâàíèå êàòàëîãà:\n\
-MOVE [/N][äèñê:][ïóòü]èìÿ_êàòàëîãà1 èìÿ_êàòàëîãà2\n\n\
-  [äèñê:][ïóòü]èìÿ_ôàéëà1  Óêàçûâàåò ìåñòîïîëîæåíèå è èìÿ ôàéëà èëè ôàéëîâ\n\
-                           êîòîðûå íåîáõîäèìî ïåðåìåñòèòü.\n\
-  /N                       Nothing. Do everything but move files or directories.\n\n\
-Òåêóùèå îãðàíè÷åíèÿ:\n\
-  - Íåâîçìîæíî ïåðåíîñèòü ôàéëû èëè ïàïêè ìåæäó ðàçíûìè ðàçäåëàìè.\n"
-
-STRING_MSGBOX_HELP, "Âûâîä îêíà ñ ñîîáùåíèåì è âîçâðàò îòâåòà ïîëüçîâàòåëÿ\n\n\
-MSGBOX òèï ['çàãîëîâîê'] ïîäñêàçêà\n\n\
-òèï          âûâîäèìûå êíîïêè\n\
-             âîçìîæíûå çíà÷åíèÿ: OK, OKCANCEL,\n\
-             YESNO, YESNOCANCEL\n\
-çàãîëîâîê    çàãîëîâîê îêíà ñ ñîîáùåíèåì\n\
-ïîäñêàçêà    âûâîäèìûé òåêñò ïîäñêàçêè\n\n\n\
-ERRORLEVEL   óñòàíàâëèâàåòñÿ â ñîîòâåòñòâèè ñ íàæàòîé êíîïêîé:\n\n\
-YES  :  10    |  NO      :  11\n\
-OK   :  10    |  CANCEL  :  12\n"
-
-STRING_PATH_HELP1, "Âûâîä èëè çàäàíèå ïóòè ïîèñêà èñïîëíÿåìûõ ôàéëîâ.\n\n\
-PATH [[äèñê:]ïóòü[;...]]\nPATH ;\n\n\
-Êîìàíäà PATH ; î÷èùàåò ïóòü ïîèñêà èñïîëüçóåìûõ ôàéëîâ, îãðàíè÷èâ åãî\n\
-òåêóùèì êàòàëîãîì.\n\
-Êîìàíäà PATH áåç ïàðàìåòðîâ îòîáðàæàåò òåêóùèé ïóòü ïîèñêà.\n"
-
-STRING_PROMPT_HELP1, "Èçìåíåíèå ïðèãëàøåíèÿ êîìàíäíîé ñòðîêè.\n\n\
-PROMPT [òåêñò]\n\n\
-  òåêñò   Íîâîå ïðèãëàøåíèå êîìàíäíîé ñòðîêè.\n\n\
-Ïðèãëàøåíèå ìîæåò âêëþ÷àòü îáû÷íûå ñèìâîëû è ñëåäóþùèå êîäû:\n\n\
-  $A   & (àìïåðñàíä)\n\
-  $B   | (âåðòèêàëüíàÿ ÷åðòà)\n\
-  $C   ( (ëåâàÿ êðóãëàÿ ñêîáêà)\n\
-  $D   Òåêóùàÿ äàòà\n\
-  $E   ESC (ñèìâîë ASCII ñ êîäîì 27)\n\
-  $F   ) (ïðàâàÿ êðóãëàÿ ñêîáêà)\n\
-  $G   > (çíàê ""áîëüøå"")\n\
-  $H   BACKSPACE (óäàëåíèå ïðåäûäóùåãî ñèìâîëà)\n\
-  $L   < (çíàê ""ìåíüøå"")\n\
-  $N   Òåêóùèé äèñê\n\
-  $P   Òåêóùèå äèñê è êàòàëîã\n\
-  $Q   = (çíàê ðàâåíñòâà)\n\
-  $T   Òåêóùåå âðåìÿ\n\
-  $V   Íîìåð âåðñèè îïåðàöèîííîé ñèñòåìû\n\
-  $_   Ïåðåâîä ñòðîêè\n\
-  $$   $ (çíàê äîëëàðà)\n"
-
-STRING_PAUSE_HELP1, "Ïðèîñòàíîâêà âûïîëíåíèÿ ïàêåòíîãî ôàéëà è âûâîä ñîîáùåíèÿ:\n\
-'Äëÿ ïðîäîëæåíèÿ íàæìèòå ëþáóþ êëàâèøó...' èëè óêàçàííîå ñîîáùåíèå.\n\n\
-PAUSE [ñîîáùåíèå]"
-
-STRING_PROMPT_HELP2, "  $+   Displays the current depth of the directory stack"
-
-STRING_PROMPT_HELP3, "\nPROMPT áåç ïàðàìåòðîâ óñòàíàâëèâàåò ïðèãëàøåíèå êîìàíäíîé ñòðîêè ïî óìîë÷àíèþ."
-
-STRING_REM_HELP, "Ïîìåùåíèå êîììåíòàðèåâ â ïàêåòíûå ôàéëû.\n\nREM [êîììåíòàðèé]"
-
-STRING_RMDIR_HELP,   "Óäàëåíèå êàòàëîãà.\n\n\
-RMDIR [äèñê:]ïóòü\nRD [äèñê:]ïóòü\n\
-/S                     Óäàëåíèå äåðåâà êàòàëîãîâ\n\
-/Q                     Îòêëþ÷åíèå çàïðîñà ïîäòâåðæäåíèÿ\n"
-STRING_RMDIR_HELP2,    "Êàòàëîã ïóñò!\n"
-
-STRING_REN_HELP1, "Ïåðåèìåíîâàíèå îäíîãî èëè íåñêîëüêèõ ôàéëîâ èëè êàòàëîãîâ.\n\n\
-RENAME [/E /N /P /Q /S /T] ñòàðîå_èìÿ ... íîâîå_èìÿ\n\
-REN [/E /N /P /Q /S /T] ñòàðîå_èìÿ ... íîâîå_èìÿ\n\n\
-  /E    Íå âûâîäèòü ñîîáùåíèÿ îá îøèáêàõ.\n\
-  /N    Nothing.\n\
-  /P    Çàïðîñ ïîäòâåðæäåíèÿ ïåðåä ïåðåèìåíîâàíèåì.\n\
-        (Not implemented yet!)\n\
-  /Q    Quiet.\n\
-  /S    Ïåðåèìåíîâûâàòü ïîäêàòàëîãè.\n\
-  /T    Âûâîä êîëè÷åñòâà ïåðåèìåíîâàííûõ ôàéëîâ.\n\n\
-Äëÿ êîíå÷íîãî ôàéëà íåëüçÿ óêàçàòü äðóãîé äèñê èëè êàòàëîã.\n\
-Äëÿ ýòîé öåëè ñëåäóåò èñïîëüçîâàòü êîìàíäó MOVE.\n"
-
-STRING_REN_HELP2, "    %lu ôàéë ïåðåèìåíîâàí\n"
-
-STRING_REN_HELP3, "    %lu ôàéëîâ ïåðåèìåíîâàíî\n"
-                
-STRING_SHIFT_HELP, "Èçìåíåíèå ñîäåðæèìîãî (ñäâèã) ïîäñòàâëÿåìûõ ïàðàìåòðîâ äëÿ ïàêåòíîãî ôàéëà.\n\n\
-SHIFT [DOWN]"
-
-STRING_SCREEN_HELP, "Ïåðåìåùåíèå êóðñîðà è âûâîä òåêñòà\n\n\
-SCREEN ñòð êîë [òåêñò]\n\n\
-  ñòð         ñòðîêà, íà êîòîðóþ ñëåäóåò ïåðåìåñòèòü êóðñîð\n\
-  êîë         êîëîíêà, íà êîòîðóþ ñëåäóåò ïåðåìåñòèòü êóðñîð"
-
-STRING_SET_HELP, "Âûâîä, çàäàíèå è óäàëåíèå ïåðåìåííûõ ñðåäû.\n\n\
-SET [ïåðåìåííàÿ[=][çíà÷åíèå]]\n\n\
-  ïåðåìåííàÿ  Èìÿ ïåðåìåííîé ñðåäû.\n\
-  çíà÷åíèå    Ñòðîêà ñèìâîëîâ, ïðèñâàèâàåìàÿ óêàçàííîé ïåðåìåííîé.\n\n\
-SET áåç ïàðàìåòðîâ âûâîäèò òåêóùèå çíà÷åíèÿ ïåðåìåííûõ ñðåäû.\n"
-
-STRING_START_HELP1, "Çàïóñê óêàçàííîé ïðîãðàììû èëè êîìàíäû.\n\n\
-START êîìàíäà\n\n\
-  êîìàíäà     Êîìàíäà èëè ïðîãðàììà äëÿ çàïóñêà.\n\n\
-At the moment all commands are started asynchronously.\n"
-
-STRING_TITLE_HELP, "Èçìåíåíèå çàãîëîâêà îêíà êîìàíäíîé ñòðîêè.\n\n\
-TITLE [ñòðîêà]\n\n\
-ñòðîêà       Áóäóùèé çàãîëîâîê îêíà êîìàíäíîé ñòðîêè.\n"
-
-STRING_TIME_HELP1, "Âûâîä èëè èçìåíåíèå âðåìåíè.\n\n\
-TIME [/T][âðåìÿ]\n\n\
-  /T    íå èçìåíÿòü âðåìÿ\n\n\
-TIME áåç ïàðàìåòðîâ âûâîäèò òåêóùåå âðåìÿ è çàïðàøèâàåò\n\
-íîâîå âðåìÿ.  Íàæàòèå ENTER ñîõðàíÿåò òåêóùåå âðåìÿ.\n"
-
-STRING_TIME_HELP2, "Ââåäèòå íîâîå âðåìÿ: "
-
-STRING_TIMER_HELP1, "Ïðîøëî %d ìñåê\n"
-
-STRING_TIMER_HELP2, "Ïðîøëî %02d%c%02d%c%02d%c%02d\n"
-
-STRING_TIMER_HELP3, "Ñåêóíäîìåð.\n\n\
-TIMER  [ON|OFF] [/S] [/n] [/Fn]\n\n\
-  ON          Âêëþ÷èòü ñåêóíäîìåð\n\
-  OFF         Âûêëþ÷èòü ñåêóíäîìåð\n\
-  /S          Ðàçíèöà âðåìåíè. Âîçâðàùàåò ðàçíèöó âðåìåíè\n\
-              ñåêóíäîìåðà áåç èçìåíåíèÿ åãî çíà÷åíèÿ\n\
-  /n          Çàäàòü íîìåð ñåêóíäîìåðà.\n\
-              Äîñòóïíûå íîìåðà - îò 0 äî 9\n\
-              Çíà÷åíèå ïî óìîë÷àíèþ - 1\n\
-  /Fn         Ôîðìàò âûâîäà\n\
-              n îäíî èç:\n\
-                    0    ìèëëèñåêóíäû\n\
-                    1    ÷÷%cìì%cññ%cää\n\n\
-Åñëè íè îäèí èç ïàðàìåòðîâ íå óêàçàí, êîìàíäà\n\
-ïåðåêëþ÷àåò ñîñòîÿíèå ñåêóíäîìåðà\n\n"
-
-STRING_TYPE_HELP1, "Âûâîä ñîäåðæèìîãî îäíîãî èëè íåñêîëüêèõ òåêñòîâûõ ôàéëîâ.\n\nTYPE [äèñê:][ïóòü]èìÿ ôàéëà \n\
-  /P             Ïîýêðàííûé âûâîä.\n"
-
-STRING_VERIFY_HELP1, "This command is just a dummy!!\n\
-Âêëþ÷åíèå èëè îòêëþ÷åíèå ðåæèìà ïðîâåðêè ïðàâèëüíîñòè çàïèñè ôàéëîâ a\n\
-íà äèñê.\n\n\
-VERIFY [ON | OFF]\n\n\
-VERIFY áåç ïàðàìåòðà âûâîäèò òåêóùåå çíà÷åíèå ýòîé êîìàíäû.\n"
-
-STRING_VERIFY_HELP2, "VERIFY %s.\n"
-
-STRING_VERIFY_HELP3, "Íåîáõîäèìî óêàçàòü ON èëè OFF."
-
-STRING_VERSION_HELP1, "Âûâîä âåðñèè\n\n\
-VER [/C][/R][/W]\n\n\
-  /C  Displays credits.\n\
-  /R  Displays redistribution information.\n\
-  /W  Displays warranty information."
-
-STRING_VERSION_HELP2, " comes with ABSOLUTELY NO WARRANTY; for details\n\
-type: `ver /w'. This is free software, and you are welcome to redistribute\n\
-it under certain conditions; type `ver /r' for details. Type `ver /c' for a\n\
-listing of credits."
-
-STRING_VERSION_HELP3, "\n This program is distributed in the hope that it will be useful,\n\
- but WITHOUT ANY WARRANTY; without even the implied warranty of\n\
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n\
- GNU General Public License for more details."
-
-STRING_VERSION_HELP4, "\n This program is free software; you can redistribute it and/or modify\n\
- it under the terms of the GNU General Public License as published by\n\
- the Free Software Foundation; either version 2 of the License, or\n\
- (at your option) any later version.\n"
-
-STRING_VERSION_HELP5, "\nÏîñûëàéòå îò÷åòû îá îøèáêàõ íà <ros-dev@reactos.org>.\n\
-Îáíîâëåíèÿ äîñòóïíû ïî àäðåñó: http://www.reactos.org/"
-
-STRING_VERSION_HELP6, "\nFreeDOS-âåðñèÿ íàïèñàíà:\n"
-
-STRING_VERSION_HELP7, "\nReactOS-âåðñèÿ íàïèñàíà:\n"
-
-STRING_VOL_HELP1, " Òîì â óñòðîéñòâå %c: èìååò ìåòêó %s"
-STRING_VOL_HELP2, " Òîì â óñòðîéñòâå %c: íå èìååò ìåòêè"
-STRING_VOL_HELP3, " Ñåðèéíûé íîìåð òîìà: %04X-%04X\n"
-STRING_VOL_HELP4, "Âûâîäèò ìåòêó òîìà è ñåðèéíûé íîìåð.\n\nVOL [äèñê:]"
-
-STRING_WINDOW_HELP1, "Ìåíÿåò âèä îêíà êîíñîëè\n\n\
-WINDOW [/POS[=]left,top,øèðèíà,âûñîòà]\n\
-              [MIN|MAX|RESTORE] ['çàãîëîâîê']\n\n\
-/POS          óêàçûâàåò ðàçìåð è ïîëîæåíèå îêíà\n\
-MIN           ñâîðà÷èâàåò îêíî\n\
-MAX           ðàçâîðà÷èâàåò îêíî\n\
-RESTORE       âîññòàíàâëèâàåò îêíî\n"
-
-STRING_WINDOW_HELP2, "Ìåíÿåò âèä îêíà êîíñîëè\n\n\
-ACTIVATE 'window' [/POS[=]left,top,øèðèíà,âûñîòà]\n\
-              [MIN|MAX|RESTORE] ['çàãîëîâîê']\n\n\
-window        çàãîëîâîê îêíà, âèä êîòîðîãî ñëåäóåò ìåíÿòü\n\
-/POS          óêàçûâàåò ðàçìåð è ïîëîæåíèå îêíà\n\
-MIN           ñâîðà÷èâàåò îêíî\n\
-MAX           ðàçâîðà÷èâàåò îêíî\n\
-RESTORE       âîññòàíàâëèâàåò îêíî\n\
-çàãîëîâîê     íîâûé çàãîëîâîê\n"
-
-
-STRING_HELP1, "Ñïèñîê âñåõ äîñòóïíûõ êîìàíä ñ êîðîòêèì îïèñàíèåì\n\n\
-  êîìàíäà /?     Âûâîäèò ïîäðîáíóþ èíôîðìàöèþ î êîìàíäå\n\n\
-?        Ñïèñîê âñåõ äîñòóïíûõ êîìàíä áåç îïèñàíèÿ.\n\
-ALIAS    Âûâîä, óñòàíîâêà èëè óäàëåíèå ïñåâäîíèìîâ.\n\
-ATTRIB   Âûâîä è èçìåíåíèå àòðèáóòîâ ôàéëîâ.\n\
-BEEP     Çâóêîâîé ñèãíàë.\n\
-CALL     Âûçîâ îäíîãî ïàêåòíîãî ôàéëà èç äðóãîãî.\n\
-CD       Âûâîä èìåíè ëèáî ñìåíà òåêóùåãî êàòàëîãà.\n\
-CHCP     Âûâîä èëè ñìåíà òåêóùåãî íîìåðà êîäîâîé ñòðàíèöû.\n\
-CHOICE   Æä¸ò, ïîêà ïîëüçîâàòåëü íå âûáåðåò îäèí èç óêàçàííûõ â ñïèñêå ñèìâîëîâ.\n\
-CLS      Î÷èñòêà ýêðàíà.\n\
-CMD      Çàïóñê íîâîé êîïèè èíòåðïðåòàòîðà êîìàíä.\n\
-COLOR    Óñòàíîâêà öâåòîâ ïî óìîë÷àíèþ äëÿ òåêñòà è ôîíà.\n\
-COPY     Êîïèðîâàíèå îäíîãî èëè íåñêîëüêèõ ôàéëîâ â äðóãîå ìåñòî.\n\
-DATE     Âûâîä èëè èçìåíåíèå äàòû.\n\
-DELETE   Óäàëåíèå îäíîãî èëè íåñêîëüêèõ ôàéëîâ.\n\
-DIR      Âûâîä ñïèñêà ôàéëîâ è ïîäêàòàëîãîâ êàòàëîãà.\n\
-ECHO     Âûâîä ñîîáùåíèé è ïåðåêëþ÷åíèå ðåæèìà îòîáðàæåíèÿ êîìàíä íà ýêðàíå.\n\
-ERASE    Óäàëåíèå îäíîãî èëè íåñêîëüêèõ ôàéëîâ.\n\
-EXIT     Çàâåðøàåò èíòåðïðåòàòîð êîìàíä.\n\
-FOR      Çàïóñêàåò óêàçàííóþ êîìàíäó äëÿ êàæäîãî ôàéëà èç íàáîðà ôàéëîâ.\n\
-FREE     (Ñâîáîäíîå) äèñêîâîå ïðîñòðàíñòâî.\n\
-GOTO     Ïåðåäà÷à óïðàâëåíèÿ ñîäåðæàùåé ìåòêó ñòðîêå ïàêåòíîãî ôàéëà\n\
-HELP     Ïðåäîñòàâëÿåò ñïðàâî÷íóþ èíôîðìàöèþ î êîìàíäàõ ReactOS.\n\
-HISTORY  Ñïèñîê çàïóùåííûõ êîìàíä\n\
-IF       Îïåðàòîð óñëîâíîãî âûïîëíåíèÿ êîìàíä â ïàêåòíîì ôàéëå.\n\
-LABEL    Ñîçäàíèå, èçìåíåíèå è óäàëåíèå ìåòîê òîìà.\n\
-MD       Ñîçäàíèå êàòàëîãà.\n\
-MKDIR    Ñîçäàíèå êàòàëîãà.\n\
-MOVE     Ïåðåìåùåíèå ôàéëîâ è ïåðåèìåíîâàíèå ôàéëîâ è êàòàëîãîâ\n\
-PATH     Âûâîä èëè çàäàíèå ïóòè ïîèñêà èñïîëíÿåìûõ ôàéëîâ.\n\
-PAUSE    Ïðèîñòàíîâêà âûïîëíåíèÿ ïàêåòíîãî ôàéëà.\n\
-POPD     Âîñòòàíàâëèâàåò ïðåäûäóùåå çíà÷åíèå òåêóùåé äèðåêòîðèè ñîõðàíåííîå êîìàíäîé\n\
-         PUSHD.\n\
-PROMPT   Èçìåíåíèå ïðèãëàøåíèÿ êîìàíäíîé ñòðîêè.\n\
-PUSHD    Ñîõðàíÿåò òåêóùóþ äèðåêòîðèþ, à ïîòîì ìåíÿåò å¸.\n\
-RD       Óäàëåíèå êàòàëîãà.\n\
-REM      Çàïèñûâàåò êîììåíòàðèè (çàìå÷åíèÿ) â ïàêåòíûõ ôàéëàõ.\n\
-REN      Ïåðåèìåíîâàíèå îäíîãî èëè íåñêîëüêèõ ôàéëîâ èëè êàòàëîãîâ.\n\
-RENAME   Ïåðåèìåíîâàíèå îäíîãî èëè íåñêîëüêèõ ôàéëîâ èëè êàòàëîãîâ.\n\
-RMDIR    Óäàëåíèå êàòàëîãà.\n\
-SCREEN   Ïåðåìåùåíèå êóðñîðà è âûâîä òåêñòà.\n\
-SET      Âûâîä, çàäàíèå è óäàëåíèå ïåðåìåííûõ ñðåäû.\n\
-SHIFT    Èçìåíåíèå ñîäåðæèìîãî (ñäâèã) ïîäñòàâëÿåìûõ ïàðàìåòðîâ äëÿ ïàêåòíîãî ôàéëà\n"
-STRING_HELP2, "START    Îòêðûâàåò îòäåëüíîå îêíî äëÿ çàïóñêà óêàçàííûõ êîìàíä èëè ïðîãðàìì.\n\
-         Âûïîëíÿåò êîìàíäó.\n\
-TIME     Âûâîä èëè èçìåíåíèå âðåìåíè.\n\
-TIMER    Ñåêóíäîìåð.\n\
-TITLE    Èçìåíåíèå çàãîëîâêà îêíà êîìàíäíîé ñòðîêè.\n\
-TYPE     Âûâîä ñîäåðæèìîãî îäíîãî èëè íåñêîëüêèõ òåêñòîâûõ ôàéëîâ.\n\
-VER      Âûâîä âåðñèè ÎÑ.\n\
-VERIFY   Âêëþ÷åíèå èëè îòêëþ÷åíèå ðåæèìà ïðîâåðêè ïðàâèëüíîñòè çàïèñè ôàéëîâ\n\
-         íà äèñê.\n\
-VOL      Âûâîäèò ìåòêó òîìà è ñåðèéíûé íîìåð.\n"
-
-
-STRING_CHOICE_OPTION,         "YN"
-STRING_COPY_OPTION,           "YNA"
-
-
-STRING_ALIAS_ERROR,          "Êîìàíäíàÿ ñòðîêà ñëèøêîì äëèííàÿ ïîñëå ðàçâ¸ðòûâàíèÿ ïñåâäîíèìîâ!\n"
-STRING_BATCH_ERROR,          "Îøèáêà îòêðûòèÿ êîìàíäíîãî ôàéëà\n"
-STRING_CHCP_ERROR1,          "Òåêóùàÿ êîäîâàÿ ñòðàíèöà: %u\n"
-STRING_CHCP_ERROR4,          "Îøèáî÷íàÿ êîäîâàÿ ñòðàíèöà\n"
-STRING_CHOICE_ERROR,         "Îøèáî÷íûé ïàðàìåòð. Îæèäàåòñÿ ôîðìàò: /C[:]ïàðàìåòðû"
-STRING_CHOICE_ERROR_TXT,     "Îøèáî÷íûé ïàðàìåòð. Îæèäàåòñÿ ôîðìàò: /T[:]c,nn"
-STRING_CHOICE_ERROR_OPTION,  "Îøèáî÷íûé ïàðàìåòð: %s"
-STRING_MD_ERROR,                        "Ïîäêàòàëîã èëè ôàéë óæå ñóùåñòâóåò.\n"
-STRING_MD_ERROR2,                       "Ïóòü ê íîâîìó êàòàëîãó íå ñóùåñòâóåò.\n"
-STRING_CMD_ERROR1,           "Íå ìîãó ïåðåíàïðàâèòü ââîä èç ôàéëà %s\n"
-STRING_CMD_ERROR2,           "Îøèáêà ñîçäàíèÿ âðåìåííîãî ôàéëà äëÿ pipe-äàííûõ\n"
-STRING_CMD_ERROR3,           "Íå ìîãó ïåðåíàïðàâèòü â ôàéë %s\n"
-STRING_CMD_ERROR4,           "Çàïóñê %s...\n"
-STRING_CMD_ERROR5,           "Çàïóñê cmdexit.bat...\n"
-STRING_COLOR_ERROR1,         "Îäèíàêîâûå öâåòà! (Öâåòà ôîíà è òåêñòà íå ìîãóò áûòü îäèíàêîâûìè)"
-STRING_COLOR_ERROR2,         "îøèáêà â óêàçàíèè öâåòà"
-STRING_COLOR_ERROR3,         "Öâåò %x\n"
-STRING_COLOR_ERROR4,         "Îäèíàêîâûå öâåòà!"
-STRING_CONSOLE_ERROR,        "Íåèçâåñòíàÿ îøèáêà: %d\n"
-STRING_COPY_ERROR1,          "Îøèáêà: Íå ìîãó îòêðûòü èñòî÷íèê - %s!\n"
-STRING_COPY_ERROR2,          "Îøèáêà: Íå ìîãó êîïèðîâàòü â ñåáÿ!\n"
-STRING_COPY_ERROR3,          "Îøèáêà çàïèñè!\n"
-STRING_COPY_ERROR4,          "Îøèáêà: Not implemented yet!\n"
-STRING_DATE_ERROR,           "Íåïðàâèëüíàÿ äàòà."
-STRING_DEL_ERROR5,           "Ôàéë %s áóäåò óäàë¸í! "
-STRING_DEL_ERROR6,           "Âû óâåðåíû (Y/N)?"
-STRING_DEL_ERROR7,           "Óäàëåíèå: %s\n"
-STRING_ERROR_ERROR1,         "Íåèçâåñòíàÿ îøèáêà! Êîä îøèáêè: 0x%lx\n"
-STRING_ERROR_ERROR2,         "Ñèíòàêñè÷åñêàÿ îøèáêà"
-STRING_FOR_ERROR1,           "'in' îòñóòñòâóåò â êîìàíäå for."
-STRING_FOR_ERROR2,           "ñêîáîê íåîáíàðóæåíî."
-STRING_FOR_ERROR3,           "'do' îòñóòñâóåò." 
-STRING_FOR_ERROR4,           "íåò êîìàíäû ïîñëå 'do'."
-STRING_FREE_ERROR1,          "Íåïðàâèëüíîå èìÿ äèñêà"
-STRING_FREE_ERROR2,          "unlabeled"
-STRING_GOTO_ERROR1,          "Íå îïðåäåëåíà ìåòêà äëÿ GOTO"
-STRING_GOTO_ERROR2,          "Ìåòêà '%s' íå íàéäåíà\n"
-
-STRING_MOVE_ERROR1,          "[OK]\n"
-STRING_MOVE_ERROR2,          "[Îøèáêà]\n"
-
-STRING_REN_ERROR1,           "Âûïîëíåíèå MoveFile() áûëî íåóñïåøíûì. Îøèáêà: %lu\n"
-
-STRING_START_ERROR1,         "Íà äàííûé ìîìåíò íåò ïîääåðæêè ïàêåòíûõ ôàéëîâ!"
-
-STRING_TIME_ERROR1,          "Íåïðàâèëüíîå âðåìÿ."
-
-STRING_TYPE_ERROR1,          "Íåïðàâèëüíûé ïàðàìåòð '/%s'\n"
-
-STRING_WINDOW_ERROR1,        "îêíî íå íàéäåíî"
-
-
-STRING_ERROR_PARAMETERF_ERROR,     "Íåêîððåêòíûé ôîðìàò ïàðàìåòðà - %c\n"
-STRING_ERROR_INVALID_SWITCH,       "Íåâåðíûàÿ îïöèÿ - /%c\n"
-STRING_ERROR_TOO_MANY_PARAMETERS,  "Ñëèøêîì ìíîãî ïàðàìåòðîâ - %s\n"
-STRING_ERROR_PATH_NOT_FOUND,       "Ïóòü íå íàéäåí\n"
-STRING_ERROR_FILE_NOT_FOUND,       "Ôàéë íå íàéäåí\n"
-STRING_ERROR_REQ_PARAM_MISSING,    "Îòñóòñòâóåò íåîáõîäèìûé ïàðàìåòð\n"
-STRING_ERROR_INVALID_DRIVE,        "Îøèáî÷íîå îïðåäåëåíèå äèñêà\n"
-STRING_ERROR_INVALID_PARAM_FORMAT, "Îøèáî÷íûé ôîðìàò ïàðàìåòðà - %s\n"
-STRING_ERROR_BADCOMMAND,           "Íåïðàâèëüíàÿ êîìàíäà èëè èìÿ ôàéëà\n"
-STRING_ERROR_OUT_OF_MEMORY,        "Íåõâàòêà ïàìÿòè.\n"
-STRING_ERROR_CANNOTPIPE,           "Îøèáêà!  Íåâîçìîæíî èñïîëüçîâàòü pipe!  Íåâîçìîæíî ñîçäàòü âðåìåííûé ôàéë!\n"
-STRING_ERROR_D_PAUSEMSG,           "Äëÿ ïðîäîëæåíèÿ íàæìèòå ëþáóþ êëàâèøó . . ."
-STRING_ERROR_DRIVER_NOT_READY,     "Óñòðîéñòâî íå ãîòîâî"
-
-STRING_PATH_ERROR,                 "CMD: Íå â ñðåäå îêðóæåíèÿ '%s'\n"
-
-STRING_CMD_SHELLINFO,              "\nReactOS Command Line Interpreter"
-STRING_VERSION_RUNVER,             " çàïóùåí íà %s"
-STRING_COPY_FILE ,                 "        %d ôàéë(îâ) ñêîïèðîâàíî\n"
-STRING_DELETE_WIPE,                "wiped"
-STRING_FOR_ERROR,                  "íåïðàâèëüíîå çàäàíèå ïåðåìåííîé."
-STRING_SCREEN_COL,                 "íåïðàâèëüíîå çíà÷åíèå äëÿ êîë"
-STRING_SCREEN_ROW,                 "íåïðàâèëüíîå çíà÷åíèå äëÿ ñòð"
-STRING_TIMER_TIME                  "Timer %d is %s: "
-
-STRING_INVALID_OPERAND,            "Íåâåðíûé îïåðàíä."
-STRING_EXPECTED_CLOSE_PAREN,       "Îæèäàåòñÿ ')'."
-STRING_EXPECTED_NUMBER_OR_VARIABLE,"Îæèäàåòñÿ ÷èñëî èëè íàçâàíèå ïåðåìåííîé."
-STRING_SYNTAX_COMMAND_INCORRECT,   "Íåêîððåêòíûé ñèíòàêñèñ êîìàíäû."
-
-}
diff --git a/reactos/subsys/system/cmd/alias.c b/reactos/subsys/system/cmd/alias.c
deleted file mode 100644 (file)
index a3aebd2..0000000
+++ /dev/null
@@ -1,344 +0,0 @@
-/*
- *  ALIAS.C - alias administration module.
- *
- *
- *  History:
- *
- *    02/02/1996 (Oliver Mueller)
- *        started.
- *
- *    02/03/1996 (Oliver Mueller)
- *        Added sorting algorithm and case sensitive substitution by using
- *        partstrupr().
- *
- *    27 Jul 1998  John P. Price
- *        added config.h include
- *        added ifdef's to disable aliases
- *
- *    09-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed crash when removing an alias in DeleteAlias().
- *        Added help text ("/?").
- *
- *    14-Jan-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Clean up and Unicode safe!
- *
- *    24-Jan-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Redirection safe!
- *
- *    02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef FEATURE_ALIASES
-
-typedef struct tagALIAS
-{
-       struct tagALIAS *next;
-       LPTSTR lpName;
-       LPTSTR lpSubst;
-       DWORD  dwUsed;
-} ALIAS, *LPALIAS;
-
-
-static LPALIAS lpFirst = NULL;
-static LPALIAS lpLast = NULL;
-static DWORD   dwUsed = 0;
-
-
-/* module internal functions */
-/* strlwr only for first word in string */
-static VOID
-partstrlwr (LPTSTR str)
-{
-       LPTSTR c = str;
-       while (*c && !_istspace (*c) && *c != _T('='))
-       {
-               *c = _totlower (*c);
-               c++;
-       }
-}
-
-
-static VOID
-PrintAlias (VOID)
-{
-       LPALIAS ptr = lpFirst;
-       while (ptr)
-       {
-               ConOutPrintf (_T("%s=%s\n"), ptr->lpName, ptr->lpSubst);
-               ptr = ptr->next;
-       }
-}
-
-
-static VOID
-DeleteAlias (LPTSTR pszName)
-{
-       LPALIAS ptr = lpFirst;
-       LPALIAS prev = NULL;
-
-       while (ptr)
-       {
-               if (!_tcsicmp (ptr->lpName, pszName))
-               {
-                       if (prev)
-                               prev->next = ptr->next;
-                       else
-                               lpFirst = ptr->next;
-                       free (ptr->lpName);
-                       free (ptr->lpSubst);
-                       free (ptr);
-                       return;
-               }
-               prev = ptr;
-               ptr = ptr->next;
-       }
-}
-
-
-static VOID
-AddAlias (LPTSTR name, LPTSTR subst)
-{
-       LPALIAS ptr = lpFirst;
-       LPALIAS prev, entry;
-       LPTSTR s;
-
-       while (ptr)
-       {
-               if (!_tcsicmp (ptr->lpName, name))
-               {
-                       s = (LPTSTR)malloc ((_tcslen (subst) + 1)*sizeof(TCHAR));
-                       if (!s)
-                       {        
-                               error_out_of_memory ();
-                               return;
-                       }
-
-                       free (ptr->lpSubst);
-                       ptr->lpSubst = s;
-                       _tcscpy (ptr->lpSubst, subst);
-                       return;
-               }
-               ptr = ptr->next;
-       }
-
-       ptr = (LPALIAS)malloc (sizeof (ALIAS));
-       if (!ptr)
-               return;
-
-       ptr->next = 0;
-
-       ptr->lpName = (LPTSTR)malloc ((_tcslen (name) + 1)*sizeof(TCHAR));
-       if (!ptr->lpName)
-       {
-               error_out_of_memory ();
-               free (ptr);
-               return;
-       }
-       _tcscpy (ptr->lpName, name);
-
-       ptr->lpSubst = (LPTSTR)malloc ((_tcslen (subst) + 1)*sizeof(TCHAR));
-       if (!ptr->lpSubst)
-       {
-               error_out_of_memory ();
-               free (ptr->lpName);
-               free (ptr);
-               return;
-       }
-       _tcscpy (ptr->lpSubst, subst);
-
-       /* it's necessary for recursive substitution */
-       partstrlwr (ptr->lpSubst);
-
-       ptr->dwUsed = 0;
-
-       /* Alias table must be sorted!
-        * Here a little example:
-        *   command line = "ls -c"
-        * If the entries are
-        *   ls=dir
-        *   ls -c=ls /w
-        * command line will be expanded to "dir -c" which is not correct.
-        * If the entries are sortet as
-        *   ls -c=ls /w
-        *   ls=dir
-        * it will be expanded to "dir /w" which is a valid DOS command.
-        */
-       entry = lpFirst;
-       prev = 0;
-       while (entry)
-       {
-               if (_tcsicmp (ptr->lpName, entry->lpName) > 0)
-               {
-                       if (prev)
-                       {
-                               prev->next = ptr;
-                               ptr->next = entry;
-                       }
-                       else
-                       {
-                               ptr->next = entry;
-                               lpFirst = ptr;
-                       }
-                       return;
-               }
-               prev = entry;
-               entry = entry->next;
-       }
-
-       /* The new entry is the smallest (or the first) and must be
-        * added to the end of the list.
-        */
-       if (!lpFirst)
-               lpFirst = ptr;
-       else
-               lpLast->next = ptr;
-       lpLast = ptr;
-
-       return;
-}
-
-
-VOID InitializeAlias (VOID)
-{
-       lpFirst = NULL;
-       lpLast = NULL;
-       dwUsed = 0;
-}
-
-VOID DestroyAlias (VOID)
-{
-        if (lpFirst == NULL)
-                return;
-
-        while (lpFirst->next != NULL)
-        {
-                lpLast = lpFirst;
-                lpFirst = lpLast->next;
-
-                free (lpLast->lpName);
-                free (lpLast->lpSubst);
-                free (lpLast);
-        }
-
-        free (lpFirst->lpName);
-        free (lpFirst->lpSubst);
-        free (lpFirst);
-
-        lpFirst = NULL;
-        lpLast = NULL;
-        dwUsed = 0;
-}
-
-/* specified routines */
-VOID ExpandAlias (LPTSTR cmd, INT maxlen)
-{
-       unsigned n = 0,
-               m,
-               i,
-               len;
-       short d = 1;
-       LPALIAS ptr = lpFirst;
-
-       dwUsed++;
-       if (dwUsed == 0)
-       {
-               while (ptr)
-                       ptr->dwUsed = 0;
-               ptr = lpFirst;
-               dwUsed = 1;
-       }
-
-       /* skipping white spaces */
-       while (_istspace (cmd[n]))
-               n++;
-
-       partstrlwr (&cmd[n]);
-
-       if (!_tcsncmp (&cmd[n], _T("NOALIAS"), 7) &&
-           (_istspace (cmd[n + 7]) || cmd[n + 7] == _T('\0')))
-       {
-               memmove (cmd, &cmd[n + 7], (_tcslen (&cmd[n + 7]) + 1) * sizeof (TCHAR));
-               return;
-       }
-
-       /* substitution loop */
-       while (d)
-       {
-               d = 0;
-               while (ptr)
-               {
-                       len = _tcslen (ptr->lpName);
-                       if (!_tcsncmp (&cmd[n], ptr->lpName, len) &&
-                           (_istspace (cmd[n + len]) || cmd[n + len] == _T('\0')) &&
-                               ptr->dwUsed != dwUsed)
-                       {
-                               m = _tcslen (ptr->lpSubst);
-                               if ((int)(_tcslen (cmd) - len + m - n) > maxlen)
-                               {
-                                       ConErrResPuts(STRING_ALIAS_ERROR);
-
-                                       /* the parser won't cause any problems with an empty line */
-                                       cmd[0] = _T('\0');
-                               }
-                               else
-                               {
-                                       memmove (&cmd[m], &cmd[n + len], (_tcslen(&cmd[n + len]) + 1) * sizeof (TCHAR));
-                                       for (i = 0; i < m; i++)
-                                               cmd[i] = ptr->lpSubst[i];
-                                       ptr->dwUsed = dwUsed;
-                                       /* whitespaces are removed! */
-                                       n = 0;
-                                       d = 1;
-                               }
-                       }
-                       ptr = ptr->next;
-               }
-       }
-}
-
-
-INT CommandAlias (LPTSTR cmd, LPTSTR param)
-{
-       LPTSTR ptr;
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_ALIAS_HELP);
-               return 0;
-       }
-
-   nErrorLevel = 0;
-
-       if (param[0] == _T('\0'))
-       {
-               PrintAlias ();
-               return 0;
-       }
-
-       nErrorLevel = 0;
-
-       /* error if no '=' found */
-       if ((ptr = _tcschr (param, _T('='))) == 0)
-       {
-               nErrorLevel = 1;
-               return 1;
-       }
-
-       /* Split rest into name and substitute */
-       *ptr++ = _T('\0');
-
-       partstrlwr (param);
-
-       if (ptr[0] == _T('\0'))
-               DeleteAlias (param);
-       else
-               AddAlias (param, ptr);
-
-       return 0;
-}
-#endif
diff --git a/reactos/subsys/system/cmd/attrib.c b/reactos/subsys/system/cmd/attrib.c
deleted file mode 100644 (file)
index d5deefe..0000000
+++ /dev/null
@@ -1,346 +0,0 @@
-/*
- *  ATTRIB.C - attrib internal command.
- *
- *
- *  History:
- *
- *    04-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        started
- *
- *    09-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        implementation works, except recursion ("attrib /s").
- *
- *    05-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        major rewrite.
- *        fixed recursion ("attrib /s").
- *        started directory support ("attrib /s /d").
- *        updated help text.
- *
- *    14-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode ready!
- *
- *    19-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Redirection ready!
- *
- *    21-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added check for invalid filenames.
- *
- *    23-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added handling of multiple filenames.
- *
- *    02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_ATTRIB
-
-
-static VOID
-PrintAttribute (LPTSTR pszPath, LPTSTR pszFile, BOOL bRecurse)
-{
-       WIN32_FIND_DATA findData;
-       HANDLE hFind;
-       TCHAR  szFullName[MAX_PATH];
-       LPTSTR pszFileName;
-
-       /* prepare full file name buffer */
-       _tcscpy (szFullName, pszPath);
-       pszFileName = szFullName + _tcslen (szFullName);
-
-       /* display all subdirectories */
-       if (bRecurse)
-       {
-               /* append file name */
-               _tcscpy (pszFileName, pszFile);
-
-               hFind = FindFirstFile (szFullName, &findData);
-               if (hFind == INVALID_HANDLE_VALUE)
-               {
-                       ErrorMessage (GetLastError (), pszFile);
-                       return;
-               }
-
-               do
-               {
-                       if (!(findData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY))
-                               continue;
-
-                       if (!_tcscmp (findData.cFileName, _T(".")) ||
-                               !_tcscmp (findData.cFileName, _T("..")))
-                               continue;
-
-                       _tcscpy (pszFileName, findData.cFileName);
-                       _tcscat (pszFileName, _T("\\"));
-                       PrintAttribute (szFullName, pszFile, bRecurse);
-               }
-               while (FindNextFile (hFind, &findData));
-               FindClose (hFind);
-       }
-
-       /* append file name */
-       _tcscpy (pszFileName, pszFile);
-
-       /* display current directory */
-       hFind = FindFirstFile (szFullName, &findData);
-       if (hFind == INVALID_HANDLE_VALUE)
-       {
-               ErrorMessage (GetLastError (), pszFile);
-               return;
-       }
-
-       do
-       {
-               if (findData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                       continue;
-
-               _tcscpy (pszFileName, findData.cFileName);
-
-               ConOutPrintf (_T("%c  %c%c%c     %s\n"),
-                             (findData.dwFileAttributes & FILE_ATTRIBUTE_ARCHIVE) ? _T('A') : _T(' '),
-                             (findData.dwFileAttributes & FILE_ATTRIBUTE_SYSTEM) ? _T('S') : _T(' '),
-                             (findData.dwFileAttributes & FILE_ATTRIBUTE_HIDDEN) ? _T('H') : _T(' '),
-                             (findData.dwFileAttributes & FILE_ATTRIBUTE_READONLY) ? _T('R') : _T(' '),
-                             szFullName);
-       }
-       while (FindNextFile (hFind, &findData));
-       FindClose (hFind);
-}
-
-
-static VOID
-ChangeAttribute (LPTSTR pszPath, LPTSTR pszFile, DWORD dwMask,
-                DWORD dwAttrib, BOOL bRecurse, BOOL bDirectories)
-{
-       WIN32_FIND_DATA findData;
-       HANDLE hFind;
-       DWORD  dwAttribute;
-       TCHAR  szFullName[MAX_PATH];
-       LPTSTR pszFileName;
-
-
-       /* prepare full file name buffer */
-       _tcscpy (szFullName, pszPath);
-       pszFileName = szFullName + _tcslen (szFullName);
-
-       /* change all subdirectories */
-       if (bRecurse)
-       {
-               /* append file name */
-               _tcscpy (pszFileName, _T("*.*"));
-
-               hFind = FindFirstFile (szFullName, &findData);
-               if (hFind == INVALID_HANDLE_VALUE)
-               {
-                       ErrorMessage (GetLastError (), pszFile);
-      nErrorLevel = 1;
-                       return;
-               }
-
-               do
-               {
-                       if (findData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                       {
-                               if (!_tcscmp (findData.cFileName, _T(".")) ||
-                                   !_tcscmp (findData.cFileName, _T("..")))
-                                       continue;
-
-                               _tcscpy (pszFileName, findData.cFileName);
-                               _tcscat (pszFileName, _T("\\"));
-
-                               ChangeAttribute (szFullName, pszFile, dwMask,
-                                                                dwAttrib, bRecurse, bDirectories);
-                       }
-               }
-               while (FindNextFile (hFind, &findData));
-               FindClose (hFind);
-       }
-
-       /* append file name */
-       _tcscpy (pszFileName, pszFile);
-
-       hFind = FindFirstFile (szFullName, &findData);
-       if (hFind == INVALID_HANDLE_VALUE)
-       {
-               ErrorMessage (GetLastError (), pszFile);
-    nErrorLevel = 1;
-               return;
-       }
-
-       do
-       {
-               if (findData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                       continue;
-
-               _tcscpy (pszFileName, findData.cFileName);
-
-               dwAttribute = GetFileAttributes (szFullName);
-
-               if (dwAttribute != 0xFFFFFFFF)
-               {
-                       dwAttribute = (dwAttribute & ~dwMask) | dwAttrib;
-                       SetFileAttributes (szFullName, dwAttribute);
-               }
-       }
-       while (FindNextFile (hFind, &findData));
-       FindClose (hFind);
-}
-
-
-INT CommandAttrib (LPTSTR cmd, LPTSTR param)
-{
-       LPTSTR *arg;
-       INT    argc, i;
-       TCHAR  szPath[MAX_PATH];
-       TCHAR  szFileName [MAX_PATH];
-       BOOL   bRecurse = FALSE;
-       BOOL   bDirectories = FALSE;
-       DWORD  dwAttrib = 0;
-       DWORD  dwMask = 0;
-
-       /* initialize strings */
-       szPath[0] = _T('\0');
-       szFileName[0] = _T('\0');
-
-       /* print help */
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_ATTRIB_HELP);
-               return 0;
-       }
-
-  nErrorLevel = 0;
-
-       /* build parameter array */
-       arg = split (param, &argc, FALSE);
-
-       /* check for options */
-       for (i = 0; i < argc; i++)
-       {
-               if (_tcsicmp (arg[i], _T("/s")) == 0)
-                       bRecurse = TRUE;
-               else if (_tcsicmp (arg[i], _T("/d")) == 0)
-                       bDirectories = TRUE;
-       }
-
-       /* create attributes and mask */
-       for (i = 0; i < argc; i++)
-       {
-               if (*arg[i] == _T('+'))
-               {
-                       if (_tcslen (arg[i]) != 2)
-                       {
-                               error_invalid_parameter_format (arg[i]);
-                               freep (arg);
-                               return -1;
-                       }
-
-                       switch ((TCHAR)_totupper (arg[i][1]))
-                       {
-                               case _T('A'):
-                                       dwMask   |= FILE_ATTRIBUTE_ARCHIVE;
-                                       dwAttrib |= FILE_ATTRIBUTE_ARCHIVE;
-                                       break;
-
-                               case _T('H'):
-                                       dwMask   |= FILE_ATTRIBUTE_HIDDEN;
-                                       dwAttrib |= FILE_ATTRIBUTE_HIDDEN;
-                                       break;
-
-                               case _T('R'):
-                                       dwMask   |= FILE_ATTRIBUTE_READONLY;
-                                       dwAttrib |= FILE_ATTRIBUTE_READONLY;
-                                       break;
-
-                               case _T('S'):
-                                       dwMask   |= FILE_ATTRIBUTE_SYSTEM;
-                                       dwAttrib |= FILE_ATTRIBUTE_SYSTEM;
-                                       break;
-
-                               default:
-                                       error_invalid_parameter_format (arg[i]);
-                                       freep (arg);
-                                       return -1;
-                       }
-               }
-               else if (*arg[i] == _T('-'))
-               {
-                       if (_tcslen (arg[i]) != 2)
-                       {
-                               error_invalid_parameter_format (arg[i]);
-                               freep (arg);
-                               return -1;
-                       }
-
-                       switch ((TCHAR)_totupper (arg[i][1]))
-                       {
-                               case _T('A'):
-                                       dwMask   |= FILE_ATTRIBUTE_ARCHIVE;
-                                       dwAttrib &= ~FILE_ATTRIBUTE_ARCHIVE;
-                                       break;
-
-                               case _T('H'):
-                                       dwMask   |= FILE_ATTRIBUTE_HIDDEN;
-                                       dwAttrib &= ~FILE_ATTRIBUTE_HIDDEN;
-                                       break;
-
-                               case _T('R'):
-                                       dwMask   |= FILE_ATTRIBUTE_READONLY;
-                                       dwAttrib &= ~FILE_ATTRIBUTE_READONLY;
-                                       break;
-
-                               case _T('S'):
-                                       dwMask   |= FILE_ATTRIBUTE_SYSTEM;
-                                       dwAttrib &= ~FILE_ATTRIBUTE_SYSTEM;
-                                       break;
-
-                               default:
-                                       error_invalid_parameter_format (arg[i]);
-                                       freep (arg);
-                                       return -1;
-                       }
-               }
-       }
-
-       if (argc == 0)
-       {
-               DWORD len;
-
-               len = GetCurrentDirectory (MAX_PATH, szPath);
-               if (szPath[len-1] != _T('\\'))
-               {
-                       szPath[len] = _T('\\');
-                       szPath[len + 1] = 0;
-               }
-               _tcscpy (szFileName, _T("*.*"));
-               PrintAttribute (szPath, szFileName, bRecurse);
-               freep (arg);
-               return 0;
-       }
-
-       /* get full file name */
-       for (i = 0; i < argc; i++)
-       {
-               if ((*arg[i] != _T('+')) && (*arg[i] != _T('-')) && (*arg[i] != _T('/')))
-               {
-                       LPTSTR p;
-                       GetFullPathName (arg[i], MAX_PATH, szPath, NULL);
-                       p = _tcsrchr (szPath, _T('\\')) + 1;
-                       _tcscpy (szFileName, p);
-                       *p = _T('\0');
-
-                       if (dwMask == 0)
-                               PrintAttribute (szPath, szFileName, bRecurse);
-                       else
-                               ChangeAttribute (szPath, szFileName, dwMask,
-                                                dwAttrib, bRecurse, bDirectories);
-               }
-       }
-
-       freep (arg);
-       return 0;
-}
-
-#endif /* INCLUDE_CMD_ATTRIB */
diff --git a/reactos/subsys/system/cmd/batch.c b/reactos/subsys/system/cmd/batch.c
deleted file mode 100644 (file)
index f15547c..0000000
+++ /dev/null
@@ -1,459 +0,0 @@
-/*
- *  BATCH.C - batch file processor for CMD.EXE.
- *
- *
- *  History:
- *
- *    ??/??/?? (Evan Jeffrey)
- *        started.
- *
- *    15 Jul 1995 (Tim Norman)
- *        modes and bugfixes.
- *
- *    08 Aug 1995 (Matt Rains)
- *        i have cleaned up the source code. changes now bring this
- *        source into guidelines for recommended programming practice.
- *
- *        i have added some constants to help making changes easier.
- *
- *    29 Jan 1996 (Steffan Kaiser)
- *        made a few cosmetic changes
- *
- *    05 Feb 1996 (Tim Norman)
- *        changed to comply with new first/rest calling scheme
- *
- *    14 Jun 1997 (Steffen Kaiser)
- *        bug fixes.  added error level expansion %?.  ctrl-break handling
- *
- *    16 Jul 1998 (Hans B Pufal)
- *        Totally reorganised in conjunction with COMMAND.C (cf) to
- *        implement proper BATCH file nesting and other improvements.
- *
- *    16 Jul 1998 (John P Price <linux-guru@gcfl.net>)
- *        Seperated commands into individual files.
- *
- *    19 Jul 1998 (Hans B Pufal) [HBP_001]
- *        Preserve state of echo flag across batch calls.
- *
- *    19 Jul 1998 (Hans B Pufal) [HBP_002]
- *        Implementation of FOR command
- *
- *    20-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added error checking after malloc calls
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    02-Aug-1998 (Hans B Pufal) [HBP_003]
- *        Fixed bug in ECHO flag restoration at exit from batch file
- *
- *    26-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Replaced CRT io functions by Win32 io functions.
- *        Unicode safe!
- *
- *    23-Feb-2001 (Carl Nettelblad <cnettel@hem.passagen.es>)
- *        Fixes made to get "for" working.
- *
- *    02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-/* The stack of current batch contexts.
- * NULL when no batch is active
- */
-LPBATCH_CONTEXT bc = NULL;
-
-BOOL bEcho = TRUE;          /* The echo flag */
-
-
-
-/* Buffer for reading Batch file lines */
-TCHAR textline[BATCH_BUFFSIZE];
-
-
-/*
- * Returns a pointer to the n'th parameter of the current batch file.
- * If no such parameter exists returns pointer to empty string.
- * If no batch file is current, returns NULL
- *
- */
-
-LPTSTR FindArg (INT n)
-{
-       LPTSTR pp;
-
-#ifdef _DEBUG
-       DebugPrintf (_T("FindArg: (%d)\n"), n);
-#endif
-
-       if (bc == NULL)
-               return NULL;
-
-       n += bc->shiftlevel;
-       pp = bc->params;
-
-       /* Step up the strings till we reach the end */
-       /* or the one we want */
-       while (*pp && n--)
-               pp += _tcslen (pp) + 1;
-
-       return pp;
-}
-
-
-/*
- * Batch_params builds a parameter list in newlay allocated memory.
- * The parameters consist of null terminated strings with a final
- * NULL character signalling the end of the parameters.
- *
-*/
-
-LPTSTR BatchParams (LPTSTR s1, LPTSTR s2)
-{
-       LPTSTR dp = (LPTSTR)malloc ((_tcslen(s1) + _tcslen(s2) + 3) * sizeof (TCHAR));
-
-       /* JPP 20-Jul-1998 added error checking */
-       if (dp == NULL)
-       {
-               error_out_of_memory();
-               return NULL;
-       }
-
-       if (s1 && *s1)
-       {
-               s1 = _stpcpy (dp, s1);
-               *s1++ = _T('\0');
-       }
-       else
-               s1 = dp;
-
-       while (*s2)
-       {
-               if (_istspace (*s2) || _tcschr (_T(",;"), *s2))
-               {
-                       *s1++ = _T('\0');
-                       s2++;
-                       while (*s2 && _tcschr (_T(" ,;"), *s2))
-                               s2++;
-                       continue;
-               }
-
-               if ((*s2 == _T('"')) || (*s2 == _T('\'')))
-               {
-                       TCHAR st = *s2;
-
-                       do
-                               *s1++ = *s2++;
-                       while (*s2 && (*s2 != st));
-               }
-
-               *s1++ = *s2++;
-       }
-
-       *s1++ = _T('\0');
-       *s1 = _T('\0');
-
-       return dp;
-}
-
-
-/*
- * If a batch file is current, exits it, freeing the context block and
- * chaining back to the previous one.
- *
- * If no new batch context is found, sets ECHO back ON.
- *
- * If the parameter is non-null or not empty, it is printed as an exit
- * message
- */
-
-VOID ExitBatch (LPTSTR msg)
-{
-#ifdef _DEBUG
-       DebugPrintf (_T("ExitBatch: (\'%s\')\n"), msg);
-#endif
-
-       if (bc != NULL)
-       {
-               LPBATCH_CONTEXT t = bc;
-
-               if (bc->hBatchFile)
-               {
-                       CloseHandle (bc->hBatchFile);
-                       bc->hBatchFile = INVALID_HANDLE_VALUE;
-               }
-
-               if (bc->params)
-                       free(bc->params);
-
-               if (bc->forproto)
-                       free(bc->forproto);
-
-               if (bc->ffind)
-                       free(bc->ffind);
-
-               /* Preserve echo state across batch calls */
-               bEcho = bc->bEcho;
-
-               bc = bc->prev;
-               free(t);
-       }
-
-       if (msg && *msg)
-               ConOutPrintf (_T("%s\n"), msg);
-}
-
-
-/*
- * Start batch file execution
- *
- * The firstword parameter is the full filename of the batch file.
- *
- */
-
-BOOL Batch (LPTSTR fullname, LPTSTR firstword, LPTSTR param)
-{
-       HANDLE hFile;
-       SetLastError(0);
-       hFile = CreateFile (fullname, GENERIC_READ, FILE_SHARE_WRITE | FILE_SHARE_READ | FILE_SHARE_DELETE, NULL,
-                           OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL |
-                                FILE_FLAG_SEQUENTIAL_SCAN, NULL);      
-
-#ifdef _DEBUG
-       DebugPrintf (_T("Batch: (\'%s\', \'%s\', \'%s\')  hFile = %x\n"),
-                                fullname, firstword, param, hFile);
-#endif
-
-       if (hFile == INVALID_HANDLE_VALUE)
-       {
-               ConErrResPuts(STRING_BATCH_ERROR);
-               return FALSE;
-       }
-
-       /* Kill any and all FOR contexts */
-       while (bc && bc->forvar)
-               ExitBatch (NULL);
-
-       if (bc == NULL)
-       {
-               /* No curent batch file, create a new context */
-               LPBATCH_CONTEXT n = (LPBATCH_CONTEXT)malloc (sizeof(BATCH_CONTEXT));
-
-               if (n == NULL)
-               {
-                       error_out_of_memory ();
-                       return FALSE;
-               }
-
-               n->prev = bc;
-               bc = n;
-               bc->In[0] = _T('\0');
-               bc->Out[0] = _T('\0');
-               bc->Err[0] = _T('\0');
-       }
-       else if (bc->hBatchFile != INVALID_HANDLE_VALUE)
-       {
-               /* Then we are transferring to another batch */
-               CloseHandle (bc->hBatchFile);
-               bc->hBatchFile = INVALID_HANDLE_VALUE;
-               free (bc->params);
-       }
-
-       bc->hBatchFile = hFile;
-       SetFilePointer (bc->hBatchFile, 0, NULL, FILE_BEGIN); 
-       bc->bEcho = bEcho; /* Preserve echo across batch calls */
-       bc->shiftlevel = 0;
-
-       bc->ffind = NULL;
-       bc->forvar = _T('\0');
-       bc->forproto = NULL;
-       bc->params = BatchParams (firstword, param);
-
-#ifdef _DEBUG
-       DebugPrintf (_T("Batch: returns TRUE\n"));
-#endif
-
-       return TRUE;
-}
-
-VOID AddBatchRedirection(TCHAR * ifn, TCHAR * ofn, TCHAR * efn)
-{
-       if(!bc)
-               return;
-       if(_tcslen(ifn))
-               _tcscpy(bc->In,ifn);
-       if(_tcslen(ofn))
-               _tcscpy(bc->Out,ofn);
-       if(_tcslen(efn))
-               _tcscpy(bc->Err,efn);
-
-}
-
-/*
- * Read and return the next executable line form the current batch file
- *
- * If no batch file is current or no further executable lines are found
- * return NULL.
- *
- * Here we also look out for FOR bcontext structures which trigger the
- * FOR expansion code.
- *
- * Set eflag to 0 if line is not to be echoed else 1
- */
-
-LPTSTR ReadBatchLine (LPBOOL bLocalEcho)
-{
-       LPTSTR first;
-       LPTSTR ip;
-
-       /* No batch */
-       if (bc == NULL)
-               return NULL;
-
-#ifdef _DEBUG
-       DebugPrintf (_T("ReadBatchLine ()\n"));
-#endif
-
-       while (1)
-       {
-               /* User halt */
-               if (CheckCtrlBreak (BREAK_BATCHFILE))
-               {
-                       while (bc)
-                               ExitBatch (NULL);
-                       return NULL;
-               }
-
-               /* No batch */
-               if (bc == NULL)
-                       return NULL;
-
-               /* If its a FOR context... */
-               if (bc->forvar)
-               {
-                       LPTSTR sp = bc->forproto; /* pointer to prototype command */
-                       LPTSTR dp = textline;     /* Place to expand protoype */
-                       LPTSTR fv = FindArg (0);  /* Next list element */
-
-                       /* End of list so... */
-                       if ((fv == NULL) || (*fv == _T('\0')))
-                       {
-                               /* just exit this context */
-                               ExitBatch (NULL);
-                               continue;
-                       }
-
-                       if (_tcscspn (fv, _T("?*")) == _tcslen (fv))
-                       {
-                               /* element is wild file */
-                               bc->shiftlevel++;       /* No use it and shift list */
-                       }
-                       else
-                       {
-                               /* Wild file spec, find first (or next) file name */
-                               if (bc->ffind)
-                               {
-                                       /* First already done so do next */
-
-                                       fv = FindNextFile (bc->hFind, bc->ffind) ? bc->ffind->cFileName : NULL;
-                               }
-                               else
-                               {
-                                       /*  For first find, allocate a find first block */
-                                       if ((bc->ffind = (LPWIN32_FIND_DATA)malloc (sizeof (WIN32_FIND_DATA))) == NULL)
-                                       {
-                                               error_out_of_memory();
-                                               return NULL;
-                                       }
-
-                                       bc->hFind = FindFirstFile (fv, bc->ffind);
-
-                                       fv = !(bc->hFind==INVALID_HANDLE_VALUE) ? bc->ffind->cFileName : NULL;
-                               }
-
-                               if (fv == NULL)
-                               {
-                                       /* Null indicates no more files.. */
-                                       free (bc->ffind);      /* free the buffer */
-                                       bc->ffind = NULL;
-                                       bc->shiftlevel++;     /* On to next list element */
-                                       continue;
-                               }
-                       }
-
-                       /* At this point, fv points to parameter string */
-                       while (*sp)
-                       {
-                               if ((*sp == _T('%')) && (*(sp + 1) == bc->forvar))
-                               {
-                                       /* replace % var */
-                                       dp = _stpcpy (dp, fv);
-                                       sp += 2;
-                               }
-                               else
-                               {
-                                       /* Else just copy */
-                                       *dp++ = *sp++;
-                               }
-                       }
-
-                       *dp = _T('\0');
-
-                       *bLocalEcho = bEcho;
-
-                       return textline;
-               }
-
-               if (!FileGetString (bc->hBatchFile, textline, sizeof (textline) / sizeof (textline[0])))
-               {
-#ifdef _DEBUG
-                       DebugPrintf (_T("ReadBatchLine(): Reached EOF!\n"));
-#endif
-                       /* End of file.... */
-                       ExitBatch (NULL);
-
-                       if (bc == NULL)
-                               return NULL;
-
-                       continue;
-               }
-#ifdef _DEBUG
-               DebugPrintf (_T("ReadBatchLine(): textline: \'%s\'\n"), textline);
-#endif
-
-               /* Strip leading spaces and trailing space/control chars */
-               for (first = textline; _istspace (*first); first++)
-                       ;
-
-               for (ip = first + _tcslen (first) - 1; _istspace (*ip) || _istcntrl (*ip); ip--)
-                       ;
-
-               *++ip = _T('\0');
-
-               /* ignore labels and empty lines */
-               if (*first == _T(':') || *first == 0)
-                       continue;
-
-               if (*first == _T('@'))
-               {
-                       /* don't echo this line */
-                       do
-                               first++;
-                       while (_istspace (*first));
-
-                       *bLocalEcho = 0;
-               }
-               else
-                       *bLocalEcho = bEcho;
-
-               break;
-       }
-
-       return first;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/batch.h b/reactos/subsys/system/cmd/batch.h
deleted file mode 100644 (file)
index 9e68abb..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- *  BATCH.H - A structure to preserve the context of a batch file
- *
- *
- */
-
-#ifndef _BATCH_H_INCLUDED_
-#define _BATCH_H_INCLUDED_
-
-
-typedef struct tagBATCHCONTEXT
-{
-       struct tagBATCHCONTEXT *prev;
-       LPWIN32_FIND_DATA ffind;
-       HANDLE hBatchFile;
-       LPTSTR forproto;
-       LPTSTR params;
-       INT    shiftlevel;
-       BOOL   bEcho;        /* Preserve echo flag across batch calls */
-       HANDLE hFind;        /* Preserve find handle when doing a for */
-       TCHAR In[MAX_PATH];
-       TCHAR Out[MAX_PATH];
-       TCHAR Err[MAX_PATH];
-       TCHAR forvar;
-} BATCH_CONTEXT, *LPBATCH_CONTEXT;
-
-
-/*  The stack of current batch contexts.
- * NULL when no batch is active
- */
-extern LPBATCH_CONTEXT bc;
-
-extern BOOL bEcho;       /* The echo flag */
-
-#define BATCH_BUFFSIZE  2048
-
-extern TCHAR textline[BATCH_BUFFSIZE]; /* Buffer for reading Batch file lines */
-
-
-LPTSTR FindArg (INT);
-LPTSTR BatchParams (LPTSTR, LPTSTR);
-VOID   ExitBatch (LPTSTR);
-BOOL   Batch (LPTSTR, LPTSTR, LPTSTR);
-LPTSTR ReadBatchLine (LPBOOL);
-VOID AddBatchRedirection(TCHAR *, TCHAR *, TCHAR *);
-
-#endif /* _BATCH_H_INCLUDED_ */
diff --git a/reactos/subsys/system/cmd/beep.c b/reactos/subsys/system/cmd/beep.c
deleted file mode 100644 (file)
index 61537ed..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- *  BEEP.C - beep internal command.
- *
- *
- *  History:
- *
- *    16 Jul 1998 (Hans B Pufal)
- *        started.
- *
- *    16 Jul 1998 (John P Price)
- *        Separated commands into individual files.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    14-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("beep /?").
- *        Unicode ready!
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Redirection ready!
- *
- *    02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_BEEP
-
-
-INT cmd_beep (LPTSTR cmd, LPTSTR param)
-{
-       if (_tcsncmp (param, _T("/?"), 2) == 0)
-       {
-               ConOutResPaging(TRUE,STRING_BEEP_HELP);
-               return 0;
-       }
-
-#if 0
-       /* check if run in batch mode */
-       if (bc == NULL)
-               return 1;
-#endif
-       MessageBeep (-1);
-
-       return 0;
-}
-#endif
diff --git a/reactos/subsys/system/cmd/call.c b/reactos/subsys/system/cmd/call.c
deleted file mode 100644 (file)
index 08c10d1..0000000
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- *  CALL.C - call internal batch command.
- *
- *
- *  History:
- *
- *    16 Jul 1998 (Hans B Pufal)
- *        started.
- *
- *    16 Jul 1998 (John P Price)
- *        Seperated commands into individual files.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    04-Aug-1998 (Hans B Pufal)
- *        added lines to initialize for pointers (HBP004)  This fixed the
- *        lock-up that happened sometimes when calling a batch file from
- *        another batch file.
- *
- *    07-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("call /?") and cleaned up.
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection safe!
- *
- *    02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-/*
- * Perform CALL command.
- *
- * Allocate a new batch context and add it to the current chain.
- * Call parsecommandline passing in our param string
- * If No batch file was opened then remove our newly allocted
- * context block.
- */
-
-INT cmd_call (LPTSTR cmd, LPTSTR param)
-{
-       LPBATCH_CONTEXT n = NULL;
-
-#ifdef _DEBUG
-       DebugPrintf (_T("cmd_call: (\'%s\',\'%s\')\n"), cmd, param);
-#endif
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_CALL_HELP);
-               return 0;
-       }
-
-    nErrorLevel = 0;
-
-       n = (LPBATCH_CONTEXT)malloc (sizeof (BATCH_CONTEXT));
-
-       if (n == NULL)
-       {
-               error_out_of_memory ();
-               return 1;
-       }
-
-       n->prev = bc;
-       bc = n;
-
-       bc->hBatchFile = INVALID_HANDLE_VALUE;
-       bc->params = NULL;
-       bc->shiftlevel = 0;
-       bc->forvar = 0;        /* HBP004 */
-       bc->forproto = NULL;   /* HBP004 */
-       ParseCommandLine (param);
-       if (bc->prev)
-       {
-               _tcscpy(bc->In, bc->prev->In);
-               _tcscpy(bc->Out, bc->prev->Out);
-               _tcscpy(bc->Err, bc->prev->Err);
-       }
-       else
-       {
-               bc->In[0] = _T('\0');
-               bc->Out[0] = _T('\0');
-               bc->Err[0] = _T('\0');
-       }
-       
-
-       /* Wasn't a batch file so remove conext */
-       if (bc->hBatchFile == INVALID_HANDLE_VALUE)
-       {
-               bc = bc->prev;
-               free (n);
-       }
-
-       return 0;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/chcp.c b/reactos/subsys/system/cmd/chcp.c
deleted file mode 100644 (file)
index bf34ded..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- *  CHCP.C - chcp internal command.
- *
- *
- *  History:
- *
- *    23-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Started.
- *
- *    02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-
-#ifdef INCLUDE_CMD_CHCP
-
-INT CommandChcp (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       LPTSTR *arg;
-       INT    args;    
-       UINT uNewCodePage;
-
-       /* print help */
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_CHCP_HELP);
-               return 0;
-       }
-    
-       nErrorLevel = 0;
-
-       /* get parameters */
-       arg = split (param, &args, FALSE);
-
-       if (args == 0)
-       {
-               /* display active code page number */
-               LoadString(CMD_ModuleHandle, STRING_CHCP_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-               ConErrPrintf(szMsg, InputCodePage);
-               return 0;
-       }
-
-       if (args >= 2)
-       {
-               /* too many parameters */
-               LoadString(CMD_ModuleHandle, STRING_ERROR_INVALID_PARAM_FORMAT, szMsg, RC_STRING_MAX_SIZE);
-               ConErrPrintf(szMsg, param);
-               nErrorLevel = 1;
-               return 1;
-       }
-
-       uNewCodePage = (UINT)_ttoi(arg[0]);
-
-       if (uNewCodePage == 0)
-       {
-               LoadString(CMD_ModuleHandle, STRING_ERROR_INVALID_PARAM_FORMAT, szMsg, RC_STRING_MAX_SIZE);
-               ConErrPrintf(szMsg, arg[0]);
-               freep (arg);
-               nErrorLevel = 1;
-               return 1;
-       }
-
-       if (!SetConsoleCP(uNewCodePage))
-       {
-               ConErrResPuts(STRING_CHCP_ERROR4);
-       }
-       else
-       {
-
-               SetConsoleOutputCP (uNewCodePage);
-               InitLocale ();
-               InputCodePage= GetConsoleCP();
-       }
-
-       freep (arg);
-
-       return 0;
-}
-
-#endif /* INCLUDE_CMD_CHCP */
diff --git a/reactos/subsys/system/cmd/choice.c b/reactos/subsys/system/cmd/choice.c
deleted file mode 100644 (file)
index 095a6b5..0000000
+++ /dev/null
@@ -1,327 +0,0 @@
-/*
- *  CHOICE.C - internal command.
- *
- *
- *  History:
- *
- *    12 Aug 1999 (Eric Kohl)
- *        started.
- *
- *    01 Sep 1999 (Eric Kohl)
- *        Fixed help text.
- *
- *    26 Sep 1999 (Paolo Pantaleo)
- *        Fixed timeout.
- *
- *    02 Apr 2005 (Magnus Olsen
- *        Remove Hardcode string so
- *        they can be translate
- *
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_CHOICE
-
-
-#define GC_TIMEOUT     -1
-#define GC_NOKEY       0       //an event occurred but it wasn't a key pressed
-#define GC_KEYREAD     1       //a key has been read
-
-
-static INT
-GetCharacterTimeout (LPTCH ch, DWORD dwMilliseconds)
-{
-//--------------------------------------------
-//  Get a character from standard input but with a timeout.
-//  The function will wait a limited amount
-//  of time, then the function returns GC_TIMEOUT.
-//
-//     dwMilliseconds is the timeout value, that can
-//     be set to INFINITE, so the function works like
-//     stdio.h's getchar()
-
-       HANDLE hInput;
-       DWORD  dwRead;
-
-       INPUT_RECORD lpBuffer;
-
-       hInput = GetStdHandle (STD_INPUT_HANDLE);
-
-       //if the timeout experied return GC_TIMEOUT
-       if (WaitForSingleObject (hInput, dwMilliseconds) == WAIT_TIMEOUT)
-               return GC_TIMEOUT;
-
-       //otherwise get the event
-       ReadConsoleInput (hInput, &lpBuffer, 1, &dwRead);
-
-       //if the event is a key pressed
-       if ((lpBuffer.EventType == KEY_EVENT) &&
-               (lpBuffer.Event.KeyEvent.bKeyDown == TRUE))
-       {
-               //read the key
-#ifdef _UNICODE
-               *ch = lpBuffer.Event.KeyEvent.uChar.UnicodeChar;
-#else
-               *ch = lpBuffer.Event.KeyEvent.uChar.AsciiChar;
-#endif
-               return GC_KEYREAD;
-       }
-
-       //else return no key
-       return GC_NOKEY;
-}
-
-static INT
-IsKeyInString (LPTSTR lpString, TCHAR cKey, BOOL bCaseSensitive)
-{
-       LPTCH p = lpString;
-       INT val = 0;
-
-       while (*p)
-       {
-               if (bCaseSensitive)
-               {
-                       if (*p == cKey)
-                               return val;
-               }
-               else
-               {
-                       if (_totlower (*p) == _totlower (cKey))
-                               return val;
-               }
-
-               val++;
-               p++;
-       }
-
-       return -1;
-}
-
-
-INT
-CommandChoice (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       LPTSTR lpOptions;
-       TCHAR Options[6];
-       LPTSTR lpText    = NULL;
-       BOOL   bNoPrompt = FALSE;
-       BOOL   bCaseSensitive = FALSE;
-       BOOL   bTimeout = FALSE;
-       INT    nTimeout = 0;
-       TCHAR  cDefault = _T('\0');
-       INPUT_RECORD ir;
-       LPTSTR p, np;
-       LPTSTR *arg;
-       INT    argc;
-       INT    i;
-       INT    val;
-
-       INT GCret;
-       TCHAR Ch;
-       DWORD amount,clk;
-
-       LoadString(CMD_ModuleHandle, STRING_CHOICE_OPTION, Options, 4);
-       lpOptions = Options;
-
-       if (_tcsncmp (param, _T("/?"), 2) == 0)
-       {
-               ConOutResPaging(TRUE,STRING_CHOICE_HELP);
-               return 0;
-       }
-
-       /* retrieve text */
-       p = param;
-
-       while (TRUE)
-       {
-               if (*p == _T('\0'))
-                       break;
-
-               if (*p != _T('/'))
-               {
-                       lpText = p;
-                               break;
-               }
-               np = _tcschr (p, _T(' '));
-               if (!np)
-                       break;
-               p = np + 1;
-       }
-
-       /* build parameter array */
-       arg = split (param, &argc, FALSE);
-
-       /* evaluate arguments */
-       if (argc > 0)
-       {
-               for (i = 0; i < argc; i++)
-               {
-                       if (_tcsnicmp (arg[i], _T("/c"), 2) == 0)
-                       {
-                               if (arg[i][2] == _T(':'))
-                                       lpOptions = &arg[i][3];
-                               else
-                                       lpOptions = &arg[i][2];
-
-                               if (_tcslen (lpOptions) == 0)
-                               {
-                                       ConErrResPuts(STRING_CHOICE_ERROR);
-                                       freep (arg);
-                                       return 1;
-                               }
-                       }
-                       else if (_tcsnicmp (arg[i], _T("/n"), 2) == 0)
-                       {
-                               bNoPrompt = TRUE;
-                       }
-                       else if (_tcsnicmp (arg[i], _T("/s"), 2) == 0)
-                       {
-                               bCaseSensitive = TRUE;
-                       }
-                       else if (_tcsnicmp (arg[i], _T("/t"), 2) == 0)
-                       {
-                               LPTSTR s;
-
-                               if (arg[i][2] == _T(':'))
-                               {
-                                       cDefault = arg[i][3];
-                                       s = &arg[i][4];
-                               }
-                               else
-                               {
-                                       cDefault = arg[i][2];
-                                       s = &arg[i][3];
-                               }
-
-                               if (*s != _T(','))
-                               {
-                                       ConErrResPuts(STRING_CHOICE_ERROR_TXT);
-                                       freep (arg);
-                                       return 1;
-                               }
-
-                               s++;
-                               nTimeout = _ttoi(s);
-                               bTimeout = TRUE;
-                       }
-                       else if (arg[i][0] == _T('/'))
-                       {
-                               LoadString(CMD_ModuleHandle, STRING_CHOICE_ERROR_OPTION, szMsg, RC_STRING_MAX_SIZE);
-                               ConErrPrintf(szMsg, arg[i]);
-                               freep (arg);
-                               return 1;
-                       }
-               }
-       }
-
-       /* print text */
-       if (lpText)
-               ConOutPrintf (_T("%s"), lpText);
-
-       /* print options */
-       if (bNoPrompt == FALSE)
-       {
-               ConOutPrintf (_T("[%c"), lpOptions[0]);
-
-               for (i = 1; (unsigned)i < _tcslen (lpOptions); i++)
-                       ConOutPrintf (_T(",%c"), lpOptions[i]);
-     
-               ConOutPrintf (_T("]?"));
-       }
-
-       ConInFlush ();
-
-       if(!bTimeout)
-       {
-               while (TRUE)
-               {
-                       ConInKey (&ir);
-
-                       val = IsKeyInString (lpOptions,
-#ifdef _UNICODE
-                                            ir.Event.KeyEvent.uChar.UnicodeChar,
-#else
-                                            ir.Event.KeyEvent.uChar.AsciiChar,
-#endif
-                                            bCaseSensitive);
-
-                       if (val >= 0)
-                       {        
-                               ConOutPrintf (_T("%c\n"), lpOptions[val]);
-
-                               nErrorLevel = val + 1;
-
-                               break;
-                       }
-
-                       Beep (440, 50);
-               }
-
-               freep (arg);
-#ifdef _DEBUG
-               DebugPrintf (_T("ErrorLevel: %d\n"), nErrorLevel);
-#endif /* _DEBUG */
-               return 0;
-       }
-
-       clk = GetTickCount ();
-       amount = nTimeout*1000;
-
-loop:
-       GCret = GetCharacterTimeout (&Ch, amount - (GetTickCount () - clk));
-
-       switch (GCret)
-       {
-               case GC_TIMEOUT:
-#ifdef _DEBUG
-                       DebugPrintf (_T("GC_TIMEOUT\n"));
-                       DebugPrintf (_T("elapsed %d msecs\n"), GetTickCount () - clk);
-#endif /* _DEBUG */
-                       break;
-
-               case GC_NOKEY:
-#ifdef _DEBUG
-                       DebugPrintf(_T("GC_NOKEY\n"));
-                       DebugPrintf(_T("elapsed %d msecs\n"), GetTickCount () - clk);
-#endif /* _DEBUG */
-                       goto loop;
-
-               case GC_KEYREAD:
-#ifdef _DEBUG
-                       DebugPrintf(_T("GC_KEYREAD\n"));
-                       DebugPrintf(_T("elapsed %d msecs\n"), GetTickCount () - clk);
-                       DebugPrintf(_T("read %c"), Ch);
-#endif /* _DEBUG */
-                       if ((val=IsKeyInString(lpOptions,Ch,bCaseSensitive))==-1)
-                       {
-                               Beep (440, 50);
-                               goto loop;
-                       }
-                       cDefault=Ch;
-                       break;
-       }
-
-#ifdef _DEBUG
-       DebugPrintf(_T("exiting wait loop after %d msecs\n"),
-                   GetTickCount () - clk);
-#endif /* _DEBUG */
-
-       val = IsKeyInString (lpOptions, cDefault, bCaseSensitive);
-       ConOutPrintf (_T("%c\n"), lpOptions[val]);
-
-       nErrorLevel = val + 1;
-
-       freep (arg);
-
-#ifdef _DEBUG
-       DebugPrintf (_T("ErrorLevel: %d\n"), nErrorLevel);
-#endif /* _DEBUG */
-
-       return 0;
-}
-#endif /* INCLUDE_CMD_CHOICE */
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/cls.c b/reactos/subsys/system/cmd/cls.c
deleted file mode 100644 (file)
index b2e98d7..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- *  CLS.C - clear screen internal command.
- *
- *
- *  History:
- *
- *    07/27/1998 (John P. Price)
- *        started.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    04-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Changed to Win32 console app.
- *
- *    08-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("/?").
- *
- *    14-Jan-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode ready!
- *
- *    20-Jan-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Redirection ready!
- *
- *    02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_CLS
-
-INT cmd_cls (LPTSTR cmd, LPTSTR param)
-{
-       CONSOLE_SCREEN_BUFFER_INFO csbi;
-       COORD coPos;
-       DWORD dwWritten;
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_CLS_HELP);
-               return 0;
-       }
-
-       GetConsoleScreenBufferInfo(hConsole, &csbi);
-
-       coPos.X = 0;
-       coPos.Y = 0;
-       FillConsoleOutputAttribute(hConsole, wColor,
-                                  csbi.dwSize.X * csbi.dwSize.Y,
-                                  coPos, &dwWritten);
-       FillConsoleOutputCharacter(hConsole, _T(' '),
-                                  csbi.dwSize.X * csbi.dwSize.Y,
-                                  coPos, &dwWritten);
-       SetConsoleCursorPosition(hConsole, coPos);
-
-       bIgnoreEcho = TRUE;
-
-       return 0;
-}
-#endif
diff --git a/reactos/subsys/system/cmd/cmd.c b/reactos/subsys/system/cmd/cmd.c
deleted file mode 100644 (file)
index 2652447..0000000
+++ /dev/null
@@ -1,1865 +0,0 @@
-/*
- *  CMD.C - command-line interface.
- *
- *
- *  History:
- *
- *    17 Jun 1994 (Tim Norman)
- *        started.
- *
- *    08 Aug 1995 (Matt Rains)
- *        I have cleaned up the source code. changes now bring this source
- *        into guidelines for recommended programming practice.
- *
- *        A added the the standard FreeDOS GNU licence test to the
- *        initialize() function.
- *
- *        Started to replace puts() with printf(). this will help
- *        standardize output. please follow my lead.
- *
- *        I have added some constants to help making changes easier.
- *
- *    15 Dec 1995 (Tim Norman)
- *        major rewrite of the code to make it more efficient and add
- *        redirection support (finally!)
- *
- *    06 Jan 1996 (Tim Norman)
- *        finished adding redirection support!  Changed to use our own
- *        exec code (MUCH thanks to Svante Frey!!)
- *
- *    29 Jan 1996 (Tim Norman)
- *        added support for CHDIR, RMDIR, MKDIR, and ERASE, as per
- *        suggestion of Steffan Kaiser
- *
- *        changed "file not found" error message to "bad command or
- *        filename" thanks to Dustin Norman for noticing that confusing
- *        message!
- *
- *        changed the format to call internal commands (again) so that if
- *        they want to split their commands, they can do it themselves
- *        (none of the internal functions so far need that much power, anyway)
- *
- *    27 Aug 1996 (Tim Norman)
- *        added in support for Oliver Mueller's ALIAS command
- *
- *    14 Jun 1997 (Steffan Kaiser)
- *        added ctrl-break handling and error level
- *
- *    16 Jun 1998 (Rob Lake)
- *        Runs command.com if /P is specified in command line.  Command.com
- *        also stays permanent.  If /C is in the command line, starts the
- *        program next in the line.
- *
- *    21 Jun 1998 (Rob Lake)
- *        Fixed up /C so that arguments for the program
- *
- *    08-Jul-1998 (John P. Price)
- *        Now sets COMSPEC environment variable
- *        misc clean up and optimization
- *        added date and time commands
- *        changed to using spawnl instead of exec.  exec does not copy the
- *        environment to the child process!
- *
- *    14 Jul 1998 (Hans B Pufal)
- *        Reorganised source to be more efficient and to more closely
- *        follow MS-DOS conventions. (eg %..% environment variable
- *        replacement works form command line as well as batch file.
- *
- *        New organisation also properly support nested batch files.
- *
- *        New command table structure is half way towards providing a
- *        system in which COMMAND will find out what internal commands
- *        are loaded
- *
- *    24 Jul 1998 (Hans B Pufal) [HBP_003]
- *        Fixed return value when called with /C option
- *
- *    27 Jul 1998  John P. Price
- *        added config.h include
- *
- *    28 Jul 1998  John P. Price
- *        added showcmds function to show commands and options available
- *
- *    07-Aug-1998 (John P Price <linux-guru@gcfl.net>)
- *        Fixed carrage return output to better match MSDOS with echo
- *        on or off. (marked with "JPP 19980708")
- *
- *    07-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        First ReactOS release.
- *        Extended length of commandline buffers to 512.
- *
- *    13-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added COMSPEC environment variable.
- *        Added "/t" support (color) on cmd command line.
- *
- *    07-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("cmd /?").
- *
- *    25-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection safe!
- *        Fixed redirections and piping.
- *        Piping is based on temporary files, but basic support
- *        for anonymous pipes already exists.
- *
- *    27-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Replaced spawnl() by CreateProcess().
- *
- *    22-Oct-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added break handler.
- *
- *    15-Dec-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed current directory
- *
- *    28-Dec-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Restore window title after program/batch execution
- *
- *    03-Feb-2001 (Eric Kohl <ekohl@rz-online.de>)
- *        Workaround because argc[0] is NULL under ReactOS
- *
- *    23-Feb-2001 (Carl Nettelblad <cnettel@hem.passagen.se>)
- *        %envvar% replacement conflicted with for.
- *
- *    30-Apr-2004 (Filip Navara <xnavara@volny.cz>)
- *       Make MakeSureDirectoryPathExistsEx unicode safe.
- *
- *    28-Mai-2004
- *       Removed MakeSureDirectoryPathExistsEx.
- *       Use the current directory if GetTempPath fails.
- *
- *    12-Jul-2004 (Jens Collin <jens.collin@lakhei.com>)
- *       Added ShellExecute call when all else fails to be able to "launch" any file.
- *
- *    02-Apr-2005 (Magnus Olsen <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- *
- *    06-May-2005 (Klemens Friedl <frik85@gmail.com>)
- *        Add 'help' command (list all commands plus description)
- *
- *    06-jul-2005 (Magnus Olsen <magnus@greatlord.com>)
- *        translate '%errorlevel%' to the internal value.
- *        Add proper memmory alloc ProcessInput, the error
- *        handling for memmory handling need to be improve
- */
-
-#include <precomp.h>
-#include <malloc.h>
-#include "resource.h"
-
-#ifndef NT_SUCCESS
-#define NT_SUCCESS(StatCode)  ((NTSTATUS)(StatCode) >= 0)
-#endif
-
-typedef NTSTATUS (WINAPI *NtQueryInformationProcessProc)(HANDLE, PROCESSINFOCLASS,
-                                                          PVOID, ULONG, PULONG);
-typedef NTSTATUS (WINAPI *NtReadVirtualMemoryProc)(HANDLE, PVOID, PVOID, ULONG, PULONG);
-
-BOOL bExit = FALSE;       /* indicates EXIT was typed */
-BOOL bCanExit = TRUE;     /* indicates if this shell is exitable */
-BOOL bCtrlBreak = FALSE;  /* Ctrl-Break or Ctrl-C hit */
-BOOL bIgnoreEcho = FALSE; /* Ignore 'newline' before 'cls' */
-INT  nErrorLevel = 0;     /* Errorlevel of last launched external program */
-BOOL bChildProcessRunning = FALSE;
-DWORD dwChildProcessId = 0;
-OSVERSIONINFO osvi;
-HANDLE hIn;
-HANDLE hOut;
-HANDLE hConsole;
-HANDLE CMD_ModuleHandle;
-HMODULE NtDllModule;
-
-static NtQueryInformationProcessProc NtQueryInformationProcessPtr = NULL;
-static NtReadVirtualMemoryProc       NtReadVirtualMemoryPtr = NULL;
-
-#ifdef INCLUDE_CMD_COLOR
-WORD wColor;              /* current color */
-WORD wDefColor;           /* default color */
-#endif
-
-/*
- * convert
- *
- * insert commas into a number
- */
-INT
-ConvertULargeInteger (ULARGE_INTEGER num, LPTSTR des, INT len, BOOL bPutSeperator)
-{
-       TCHAR temp[32];
-       INT c = 0;
-       INT n = 0;
-
-       if (num.QuadPart == 0)
-       {
-               des[0] = _T('0');
-               des[1] = _T('\0');
-               n = 1;
-       }
-       else
-       {
-               temp[31] = 0;
-               while (num.QuadPart > 0)
-               {
-                       if ((((c + 1) % (nNumberGroups + 1)) == 0) && (bPutSeperator))
-                               temp[30 - c++] = cThousandSeparator;
-                        temp[30 - c++] = (TCHAR)(num.QuadPart % 10) + _T('0');
-                       num.QuadPart /= 10;
-               }
-
-               for (n = 0; n <= c; n++)
-                       des[n] = temp[31 - c + n];
-       }
-
-       return n;
-}
-
-/*
- * is character a delimeter when used on first word?
- *
- */
-static BOOL IsDelimiter (TCHAR c)
-{
-       return (c == _T('/') || c == _T('=') || c == _T('\0') || _istspace (c));
-}
-
-/*
- * Is a process a console process?
- */
-static BOOL IsConsoleProcess(HANDLE Process)
-{
-       NTSTATUS Status;
-       PROCESS_BASIC_INFORMATION Info;
-       PEB ProcessPeb;
-       ULONG BytesRead;
-
-       if (NULL == NtQueryInformationProcessPtr || NULL == NtReadVirtualMemoryPtr)
-       {
-               return TRUE;
-       }
-
-       Status = NtQueryInformationProcessPtr (
-               Process, ProcessBasicInformation,
-               &Info, sizeof(PROCESS_BASIC_INFORMATION), NULL);
-       if (! NT_SUCCESS(Status))
-       {
-#ifdef _DEBUG
-               DebugPrintf (_T("NtQueryInformationProcess failed with status %08x\n"), Status);
-#endif
-               return TRUE;
-       }
-       Status = NtReadVirtualMemoryPtr (
-               Process, Info.PebBaseAddress, &ProcessPeb,
-               sizeof(PEB), &BytesRead);
-       if (! NT_SUCCESS(Status) || sizeof(PEB) != BytesRead)
-       {
-#ifdef _DEBUG
-               DebugPrintf (_T("Couldn't read virt mem status %08x bytes read %lu\n"), Status, BytesRead);
-#endif
-               return TRUE;
-       }
-
-       return IMAGE_SUBSYSTEM_WINDOWS_CUI == ProcessPeb.ImageSubSystem;
-}
-
-
-
-#ifdef _UNICODE
-#define SHELLEXECUTETEXT       "ShellExecuteW"
-#else
-#define SHELLEXECUTETEXT       "ShellExecuteA"
-#endif
-
-typedef HINSTANCE (WINAPI *MYEX)(
-       HWND hwnd,
-       LPCTSTR lpOperation,
-       LPCTSTR lpFile,
-       LPCTSTR lpParameters,
-       LPCTSTR lpDirectory,
-       INT nShowCmd
-);
-
-
-
-static BOOL RunFile(LPTSTR filename)
-{
-       HMODULE     hShell32;
-       MYEX        hShExt;
-       HINSTANCE   ret;
-
-#ifdef _DEBUG
-       DebugPrintf (_T("RunFile(%s)\n"), filename);
-#endif
-       hShell32 = LoadLibrary(_T("SHELL32.DLL"));
-       if (!hShell32)
-       {
-#ifdef _DEBUG
-               DebugPrintf (_T("RunFile: couldn't load SHELL32.DLL!\n"));
-#endif
-               return FALSE;
-       }
-
-       hShExt = (MYEX)(FARPROC)GetProcAddress(hShell32, SHELLEXECUTETEXT);
-       if (!hShExt)
-       {
-#ifdef _DEBUG
-               DebugPrintf (_T("RunFile: couldn't find ShellExecuteA/W in SHELL32.DLL!\n"));
-#endif
-               FreeLibrary(hShell32);
-               return FALSE;
-       }
-
-#ifdef _DEBUG
-       DebugPrintf (_T("RunFile: ShellExecuteA/W is at %x\n"), hShExt);
-#endif
-
-       ret = (hShExt)(NULL, _T("open"), filename, NULL, NULL, SW_SHOWNORMAL);
-
-#ifdef _DEBUG
-       DebugPrintf (_T("RunFile: ShellExecuteA/W returned %d\n"), (DWORD)ret);
-#endif
-
-       FreeLibrary(hShell32);
-       return (((DWORD)ret) > 32);
-}
-
-
-
-/*
- * This command (in first) was not found in the command table
- *
- * Full  - whole command line
- * First - first word on command line
- * Rest  - rest of command line
- */
-
-static VOID
-Execute (LPTSTR Full, LPTSTR First, LPTSTR Rest)
-{
-       TCHAR *szFullName=NULL;
-       TCHAR *first = NULL;
-       TCHAR *rest = NULL;
-       TCHAR *full = NULL;
-       TCHAR *dot = NULL;
-       TCHAR szWindowTitle[MAX_PATH];
-       DWORD dwExitCode = 0;
-
-#ifdef _DEBUG
-       DebugPrintf (_T("Execute: \'%s\' \'%s\'\n"), first, rest);
-#endif
-
-       /* we need biger buffer that First, Rest, Full are already
-          need rewrite some code to use realloc when it need instead
-          of add 512bytes extra */
-
-       first = malloc ( (_tcslen(First) + 512) * sizeof(TCHAR));
-       if (first == NULL)
-       {
-               error_out_of_memory();
-                nErrorLevel = 1;
-               return ;
-       }
-
-       rest = malloc ( (_tcslen(Rest) + 512) * sizeof(TCHAR));
-       if (rest == NULL)
-       {
-               free (first);
-               error_out_of_memory();
-                nErrorLevel = 1;
-               return ;
-       }
-
-       full = malloc ( (_tcslen(Full) + 512) * sizeof(TCHAR));
-       if (full == NULL)
-       {
-               free (first);
-               free (rest);
-               error_out_of_memory();
-                nErrorLevel = 1;
-               return ;
-       }
-
-       szFullName = malloc ( (_tcslen(Full) + 512) * sizeof(TCHAR));
-       if (full == NULL)
-       {
-               free (first);
-               free (rest);
-               free (full);
-               error_out_of_memory();
-                nErrorLevel = 1;
-               return ;
-       }
-
-
-       /* Though it was already parsed once, we have a different set of rules
-          for parsing before we pass to CreateProccess */
-       if(!_tcschr(Full,_T('\"')))
-       {
-               _tcscpy(first,First);
-               _tcscpy(rest,Rest);
-               _tcscpy(full,Full);
-       }
-       else
-       {
-               UINT i = 0;
-               BOOL bInside = FALSE;
-               rest[0] = _T('\0');
-               full[0] = _T('\0');
-               first[0] = _T('\0');
-               _tcscpy(first,Full);
-               /* find the end of the command and start of the args */
-               for(i = 0; i < _tcslen(first); i++)
-               {
-                       if(!_tcsncmp(&first[i], _T("\""), 1))
-                               bInside = !bInside;
-                       if(!_tcsncmp(&first[i], _T(" "), 1) && !bInside)
-                       {
-                               _tcscpy(rest,&first[i]);
-                               first[i] = _T('\0');
-                               break;
-                       }
-
-               }
-               i = 0;
-               /* remove any slashes */
-               while(i < _tcslen(first))
-               {
-                       if(first[i] == _T('\"'))
-                               memmove(&first[i],&first[i + 1], _tcslen(&first[i]) * sizeof(TCHAR));
-                       else
-                               i++;
-               }
-               /* Drop quotes around it just in case there is a space */
-               _tcscpy(full,_T("\""));
-               _tcscat(full,first);
-               _tcscat(full,_T("\" "));
-               _tcscat(full,rest);
-       }
-
-       /* check for a drive change */
-       if ((_istalpha (first[0])) && (!_tcscmp (first + 1, _T(":"))))
-       {
-               BOOL working = TRUE;
-               if (!SetCurrentDirectory(first))
-               /* Guess they changed disc or something, handle that gracefully and get to root */
-               {
-                       TCHAR str[4];
-                       str[0]=first[0];
-                       str[1]=_T(':');
-                       str[2]=_T('\\');
-                       str[3]=0;
-                       working = SetCurrentDirectory(str);
-               }
-
-               if (!working) ConErrResPuts (STRING_FREE_ERROR1);
-
-               free (first);
-               free (rest);
-               free (full);
-               free (szFullName);
-                nErrorLevel = 1;
-               return;
-       }
-
-       /* get the PATH environment variable and parse it */
-       /* search the PATH environment variable for the binary */
-       if (!SearchForExecutable (first, szFullName))
-       {
-                       error_bad_command ();
-                       free (first);
-                       free (rest);
-                       free (full);
-                       free (szFullName);
-                        nErrorLevel = 1;
-                       return;
-
-       }
-
-       GetConsoleTitle (szWindowTitle, MAX_PATH);
-
-       /* check if this is a .BAT or .CMD file */
-       dot = _tcsrchr (szFullName, _T('.'));
-       if (dot && (!_tcsicmp (dot, _T(".bat")) || !_tcsicmp (dot, _T(".cmd"))))
-       {
-#ifdef _DEBUG
-               DebugPrintf (_T("[BATCH: %s %s]\n"), szFullName, rest);
-#endif
-               Batch (szFullName, first, rest);
-       }
-       else
-       {
-               /* exec the program */
-               PROCESS_INFORMATION prci;
-               STARTUPINFO stui;
-
-#ifdef _DEBUG
-               DebugPrintf (_T("[EXEC: %s %s]\n"), full, rest);
-#endif
-               /* build command line for CreateProcess() */
-
-               /* fill startup info */
-               memset (&stui, 0, sizeof (STARTUPINFO));
-               stui.cb = sizeof (STARTUPINFO);
-               stui.dwFlags = STARTF_USESHOWWINDOW;
-               stui.wShowWindow = SW_SHOWDEFAULT;
-
-               // return console to standard mode
-               SetConsoleMode (GetStdHandle(STD_INPUT_HANDLE),
-                               ENABLE_LINE_INPUT | ENABLE_PROCESSED_INPUT | ENABLE_ECHO_INPUT );
-
-               if (CreateProcess (szFullName,
-                                  full,
-                                  NULL,
-                                  NULL,
-                                  TRUE,
-                                  0,                   /* CREATE_NEW_PROCESS_GROUP */
-                                  NULL,
-                                  NULL,
-                                  &stui,
-                                  &prci))
-                                                  
-               {
-                       if (IsConsoleProcess(prci.hProcess))
-                       {
-                               /* FIXME: Protect this with critical section */
-                               bChildProcessRunning = TRUE;
-                               dwChildProcessId = prci.dwProcessId;
-
-                               WaitForSingleObject (prci.hProcess, INFINITE);
-
-                               /* FIXME: Protect this with critical section */
-                               bChildProcessRunning = FALSE;
-
-                               GetExitCodeProcess (prci.hProcess, &dwExitCode);
-                               nErrorLevel = (INT)dwExitCode;
-                       }
-                        else
-                        {
-                            nErrorLevel = 0;
-                        }
-                       CloseHandle (prci.hThread);
-                       CloseHandle (prci.hProcess);
-               }
-               else
-               {
-#ifdef _DEBUG
-                       DebugPrintf (_T("[ShellExecute: %s]\n"), full);
-#endif
-                       // See if we can run this with ShellExecute() ie myfile.xls
-                       if (!RunFile(full))
-                       {
-#ifdef _DEBUG
-                               DebugPrintf (_T("[ShellExecute failed!: %s]\n"), full);
-#endif
-                               error_bad_command ();
-                                nErrorLevel = 1;
-                       }
-                        else
-                        {
-                                nErrorLevel = 0;
-                        }
-               }
-               // restore console mode
-               SetConsoleMode (
-                       GetStdHandle( STD_INPUT_HANDLE ),
-                       ENABLE_PROCESSED_INPUT );
-       }
-
-       /* Get code page if it has been change */
-       InputCodePage= GetConsoleCP();
-       OutputCodePage = GetConsoleOutputCP();
-       SetConsoleTitle (szWindowTitle);
-
-       free(first);
-       free(rest);
-       free(full);
-       free (szFullName);
-}
-
-
-/*
- * look through the internal commands and determine whether or not this
- * command is one of them.  If it is, call the command.  If not, call
- * execute to run it as an external program.
- *
- * line - the command line of the program to run
- *
- */
-
-static VOID
-DoCommand (LPTSTR line)
-{
-       TCHAR *com = NULL;  /* the first word in the command */
-       TCHAR *cp = NULL;
-       LPTSTR cstart;
-       LPTSTR rest;   /* pointer to the rest of the command line */
-       INT cl;
-       LPCOMMAND cmdptr;
-
-#ifdef _DEBUG
-       DebugPrintf (_T("DoCommand: (\'%s\')\n"), line);
-#endif /* DEBUG */
-
-       com = malloc( (_tcslen(line) +512)*sizeof(TCHAR) );
-       if (com == NULL)
-       {
-               error_out_of_memory();
-               return;
-       }
-
-       cp = com;
-       /* Skip over initial white space */
-       while (_istspace (*line))
-               line++;
-       rest = line;
-
-       cstart = rest;
-
-       /* Anything to do ? */
-       if (*rest)
-       {
-               if (*rest == _T('"'))
-               {
-                       /* treat quoted words specially */
-
-                       rest++;
-
-                       while(*rest != _T('\0') && *rest != _T('"'))
-                               *cp++ = _totlower (*rest++);
-                       if (*rest == _T('"'))
-                               rest++;
-               }
-               else
-               {
-                       while (!IsDelimiter (*rest))
-                               *cp++ = _totlower (*rest++);
-               }
-
-
-               /* Terminate first word */
-               *cp = _T('\0');
-
-               /* Do not limit commands to MAX_PATH */
-               /*
-               if(_tcslen(com) > MAX_PATH)
-               {
-                       error_bad_command();
-                       free(com);
-                       return;
-               }
-               */
-
-               /* Skip over whitespace to rest of line, exclude 'echo' command */
-               if (_tcsicmp (com, _T("echo"))) 
-               {
-                       while (_istspace (*rest))
-                       rest++;
-               }
-
-               /* Scan internal command table */
-               for (cmdptr = cmds;; cmdptr++)
-               {
-                       /* If end of table execute ext cmd */
-                       if (cmdptr->name == NULL)
-                       {
-                               Execute (line, com, rest);
-                               break;
-                       }
-
-                       if (!_tcscmp (com, cmdptr->name))
-                       {
-                               cmdptr->func (com, rest);
-                               break;
-                       }
-
-                       /* The following code handles the case of commands like CD which
-                        * are recognised even when the command name and parameter are
-                        * not space separated.
-                        *
-                        * e.g dir..
-                        * cd\freda
-                        */
-
-                       /* Get length of command name */
-                       cl = _tcslen (cmdptr->name);
-
-                       if ((cmdptr->flags & CMD_SPECIAL) &&
-                           (!_tcsncmp (cmdptr->name, com, cl)) &&
-                           (_tcschr (_T("\\.-"), *(com + cl))))
-                       {
-                               /* OK its one of the specials...*/
-
-                               /* Terminate first word properly */
-                               com[cl] = _T('\0');
-
-                               /* Call with new rest */
-                               cmdptr->func (com, cstart + cl);
-                               break;
-                       }
-               }
-       }
-       free(com);
-}
-
-
-/*
- * process the command line and execute the appropriate functions
- * full input/output redirection and piping are supported
- */
-
-VOID ParseCommandLine (LPTSTR cmd)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       TCHAR cmdline[CMDLINE_LENGTH];
-       LPTSTR s;
-#ifdef FEATURE_REDIRECTION
-       TCHAR in[CMDLINE_LENGTH] = _T("");
-       TCHAR out[CMDLINE_LENGTH] = _T("");
-       TCHAR err[CMDLINE_LENGTH] = _T("");
-       TCHAR szTempPath[MAX_PATH] = _T(".\\");
-       TCHAR szFileName[2][MAX_PATH] = {_T(""), _T("")};
-       HANDLE hFile[2] = {INVALID_HANDLE_VALUE, INVALID_HANDLE_VALUE};
-       LPTSTR t = NULL;
-       INT  num = 0;
-       INT  nRedirFlags = 0;
-       INT  Length;
-       UINT Attributes;
-       BOOL bNewBatch = TRUE;
-       HANDLE hOldConIn;
-       HANDLE hOldConOut;
-       HANDLE hOldConErr;
-#endif /* FEATURE_REDIRECTION */
-
-       _tcscpy (cmdline, cmd);
-       s = &cmdline[0];
-
-#ifdef _DEBUG
-       DebugPrintf (_T("ParseCommandLine: (\'%s\')\n"), s);
-#endif /* DEBUG */
-
-#ifdef FEATURE_ALIASES
-       /* expand all aliases */
-       ExpandAlias (s, CMDLINE_LENGTH);
-#endif /* FEATURE_ALIAS */
-
-#ifdef FEATURE_REDIRECTION
-       /* find the temp path to store temporary files */
-       Length = GetTempPath (MAX_PATH, szTempPath);
-       if (Length > 0 && Length < MAX_PATH)
-       {
-               Attributes = GetFileAttributes(szTempPath);
-               if (Attributes == 0xffffffff ||
-                   !(Attributes & FILE_ATTRIBUTE_DIRECTORY))
-               {
-                       Length = 0;
-               }
-       }
-       if (Length == 0 || Length >= MAX_PATH)
-       {
-               _tcscpy(szTempPath, _T(".\\"));
-       }
-       if (szTempPath[_tcslen (szTempPath) - 1] != _T('\\'))
-               _tcscat (szTempPath, _T("\\"));
-
-       /* get the redirections from the command line */
-       num = GetRedirection (s, in, out, err, &nRedirFlags);
-
-       /* more efficient, but do we really need to do this? */
-       for (t = in; _istspace (*t); t++)
-               ;
-       _tcscpy (in, t);
-
-       for (t = out; _istspace (*t); t++)
-               ;
-       _tcscpy (out, t);
-
-       for (t = err; _istspace (*t); t++)
-               ;
-       _tcscpy (err, t);
-
-       if(bc && !_tcslen (in) && _tcslen (bc->In))
-               _tcscpy(in, bc->In);
-       if(bc && !out[0] && _tcslen(bc->Out))
-       {
-               nRedirFlags |= OUTPUT_APPEND;
-               _tcscpy(out, bc->Out);
-       }
-       if(bc && !_tcslen (err) && _tcslen (bc->Err))
-       {
-               nRedirFlags |= ERROR_APPEND;
-               _tcscpy(err, bc->Err);
-       }
-
-
-       /* Set up the initial conditions ... */
-       /* preserve STDIN, STDOUT and STDERR handles */
-       hOldConIn  = GetStdHandle (STD_INPUT_HANDLE);
-       hOldConOut = GetStdHandle (STD_OUTPUT_HANDLE);
-       hOldConErr = GetStdHandle (STD_ERROR_HANDLE);
-
-       /* redirect STDIN */
-       if (in[0])
-       {
-               HANDLE hFile;
-               SECURITY_ATTRIBUTES sa = {sizeof(SECURITY_ATTRIBUTES), NULL, TRUE};
-
-       /* we need make sure the LastError msg is zero before calling CreateFile */
-               SetLastError(0);
-
-       /* Set up pipe for the standard input handler */
-               hFile = CreateFile (in, GENERIC_READ, FILE_SHARE_READ, &sa, OPEN_EXISTING,
-                                   FILE_ATTRIBUTE_NORMAL, NULL);
-               if (hFile == INVALID_HANDLE_VALUE)
-               {
-                       LoadString(CMD_ModuleHandle, STRING_CMD_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-                       ConErrPrintf(szMsg, in);
-                       return;
-               }
-
-               if (!SetStdHandle (STD_INPUT_HANDLE, hFile))
-               {
-                       LoadString(CMD_ModuleHandle, STRING_CMD_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-                       ConErrPrintf(szMsg, in);
-                       return;
-               }
-#ifdef _DEBUG
-               DebugPrintf (_T("Input redirected from: %s\n"), in);
-#endif
-       }
-
-       /* Now do all but the last pipe command */
-       *szFileName[0] = _T('\0');
-       hFile[0] = INVALID_HANDLE_VALUE;
-
-       while (num-- > 1)
-       {
-               SECURITY_ATTRIBUTES sa = {sizeof(SECURITY_ATTRIBUTES), NULL, TRUE};
-
-               /* Create unique temporary file name */
-               GetTempFileName (szTempPath, _T("CMD"), 0, szFileName[1]);
-
-               /* we need make sure the LastError msg is zero before calling CreateFile */
-               SetLastError(0);
-
-               /* Set current stdout to temporary file */
-               hFile[1] = CreateFile (szFileName[1], GENERIC_WRITE, 0, &sa,
-                                      TRUNCATE_EXISTING, FILE_ATTRIBUTE_TEMPORARY, NULL);
-
-               if (hFile[1] == INVALID_HANDLE_VALUE)
-               {
-                       LoadString(CMD_ModuleHandle, STRING_CMD_ERROR2, szMsg, RC_STRING_MAX_SIZE);
-                       ConErrPrintf(szMsg);
-                       return;
-               }
-
-               SetStdHandle (STD_OUTPUT_HANDLE, hFile[1]);
-
-               DoCommand (s);
-
-               /* close stdout file */
-               SetStdHandle (STD_OUTPUT_HANDLE, hOldConOut);
-               if ((hFile[1] != INVALID_HANDLE_VALUE) && (hFile[1] != hOldConOut))
-               {
-                       CloseHandle (hFile[1]);
-                       hFile[1] = INVALID_HANDLE_VALUE;
-               }
-
-               /* close old stdin file */
-               SetStdHandle (STD_INPUT_HANDLE, hOldConIn);
-               if ((hFile[0] != INVALID_HANDLE_VALUE) && (hFile[0] != hOldConIn))
-               {
-                       /* delete old stdin file, if it is a real file */
-                       CloseHandle (hFile[0]);
-                       hFile[0] = INVALID_HANDLE_VALUE;
-                       DeleteFile (szFileName[0]);
-                       *szFileName[0] = _T('\0');
-               }
-
-               /* copy stdout file name to stdin file name */
-               _tcscpy (szFileName[0], szFileName[1]);
-               *szFileName[1] = _T('\0');
-
-               /* we need make sure the LastError msg is zero before calling CreateFile */
-               SetLastError(0);
-
-               /* open new stdin file */
-               hFile[0] = CreateFile (szFileName[0], GENERIC_READ, 0, &sa,
-                                      OPEN_EXISTING, FILE_ATTRIBUTE_TEMPORARY, NULL);
-               SetStdHandle (STD_INPUT_HANDLE, hFile[0]);
-
-               s = s + _tcslen (s) + 1;
-       }
-
-       /* Now set up the end conditions... */
-       /* redirect STDOUT */
-       if (out[0])
-       {
-               /* Final output to here */
-               HANDLE hFile;
-               SECURITY_ATTRIBUTES sa = {sizeof(SECURITY_ATTRIBUTES), NULL, TRUE};
-
-               /* we need make sure the LastError msg is zero before calling CreateFile */
-               SetLastError(0);
-
-               hFile = CreateFile (out, GENERIC_WRITE, FILE_SHARE_WRITE | FILE_SHARE_READ | FILE_SHARE_DELETE, &sa,
-                                   (nRedirFlags & OUTPUT_APPEND) ? OPEN_ALWAYS : CREATE_ALWAYS,
-                                   FILE_ATTRIBUTE_NORMAL | FILE_FLAG_WRITE_THROUGH, NULL);
-
-               if (hFile == INVALID_HANDLE_VALUE)
-               {
-                       INT size = _tcslen(out)-1;
-
-                       if (out[size] != _T(':'))
-                       {
-                               LoadString(CMD_ModuleHandle, STRING_CMD_ERROR3, szMsg, RC_STRING_MAX_SIZE);
-                               ConErrPrintf(szMsg, out);
-                               return;
-                       }
-
-                       out[size]=_T('\0');
-                       hFile = CreateFile (out, GENERIC_WRITE, FILE_SHARE_WRITE | FILE_SHARE_READ | FILE_SHARE_DELETE, &sa,
-                                           (nRedirFlags & OUTPUT_APPEND) ? OPEN_ALWAYS : CREATE_ALWAYS,
-                                           FILE_ATTRIBUTE_NORMAL | FILE_FLAG_WRITE_THROUGH, NULL);
-
-                       if (hFile == INVALID_HANDLE_VALUE)
-                       {
-                               LoadString(CMD_ModuleHandle, STRING_CMD_ERROR3, szMsg, RC_STRING_MAX_SIZE);
-                               ConErrPrintf(szMsg, out);
-                               return;
-                       }
-
-               }
-
-               if (!SetStdHandle (STD_OUTPUT_HANDLE, hFile))
-               {
-                       LoadString(CMD_ModuleHandle, STRING_CMD_ERROR3, szMsg, RC_STRING_MAX_SIZE);
-                       ConErrPrintf(szMsg, out);
-                       return;
-               }
-
-               if (nRedirFlags & OUTPUT_APPEND)
-               {
-                       LONG lHighPos = 0;
-
-                       if (GetFileType (hFile) == FILE_TYPE_DISK)
-                               SetFilePointer (hFile, 0, &lHighPos, FILE_END);
-               }
-#ifdef _DEBUG
-               DebugPrintf (_T("Output redirected to: %s\n"), out);
-#endif
-       }
-       else if (hOldConOut != INVALID_HANDLE_VALUE)
-       {
-               /* Restore original stdout */
-               HANDLE hOut = GetStdHandle (STD_OUTPUT_HANDLE);
-               SetStdHandle (STD_OUTPUT_HANDLE, hOldConOut);
-               if (hOldConOut != hOut)
-                       CloseHandle (hOut);
-               hOldConOut = INVALID_HANDLE_VALUE;
-       }
-
-       /* redirect STDERR */
-       if (err[0])
-       {
-               /* Final output to here */
-               HANDLE hFile;
-               SECURITY_ATTRIBUTES sa = {sizeof(SECURITY_ATTRIBUTES), NULL, TRUE};
-
-               if (!_tcscmp (err, out))
-               {
-#ifdef _DEBUG
-                       DebugPrintf (_T("Stdout and stderr will use the same file!!\n"));
-#endif
-                       DuplicateHandle (GetCurrentProcess (),
-                                        GetStdHandle (STD_OUTPUT_HANDLE),
-                                        GetCurrentProcess (),
-                                        &hFile, 0, TRUE, DUPLICATE_SAME_ACCESS);
-               }
-               else
-               {
-                       hFile = CreateFile (err,
-                                           GENERIC_WRITE,
-                                           FILE_SHARE_WRITE | FILE_SHARE_READ | FILE_SHARE_DELETE,
-                                           &sa,
-                                           (nRedirFlags & ERROR_APPEND) ? OPEN_ALWAYS : CREATE_ALWAYS,
-                                           FILE_ATTRIBUTE_NORMAL | FILE_FLAG_WRITE_THROUGH,
-                                           NULL);
-                       if (hFile == INVALID_HANDLE_VALUE)
-                       {
-                               LoadString(CMD_ModuleHandle, STRING_CMD_ERROR3, szMsg, RC_STRING_MAX_SIZE);
-                               ConErrPrintf(szMsg, err);
-                               return;
-                       }
-               }
-
-               if (!SetStdHandle (STD_ERROR_HANDLE, hFile))
-               {
-                       LoadString(CMD_ModuleHandle, STRING_CMD_ERROR3, szMsg, RC_STRING_MAX_SIZE);
-                       ConErrPrintf(szMsg, err);
-                       return;
-               }
-
-               if (nRedirFlags & ERROR_APPEND)
-               {
-                       LONG lHighPos = 0;
-
-                       if (GetFileType (hFile) == FILE_TYPE_DISK)
-                               SetFilePointer (hFile, 0, &lHighPos, FILE_END);
-               }
-#ifdef _DEBUG
-               DebugPrintf (_T("Error redirected to: %s\n"), err);
-#endif
-       }
-       else if (hOldConErr != INVALID_HANDLE_VALUE)
-       {
-               /* Restore original stderr */
-               HANDLE hErr = GetStdHandle (STD_ERROR_HANDLE);
-               SetStdHandle (STD_ERROR_HANDLE, hOldConErr);
-               if (hOldConErr != hErr)
-                       CloseHandle (hErr);
-               hOldConErr = INVALID_HANDLE_VALUE;
-       }
-
-       if(bc)
-               bNewBatch = FALSE;
-#endif
-
-       /* process final command */
-       DoCommand (s);
-
-#ifdef FEATURE_REDIRECTION
-       if(bNewBatch && bc)
-               AddBatchRedirection(in, out, err);
-       /* close old stdin file */
-#if 0  /* buggy implementation */
-       SetStdHandle (STD_INPUT_HANDLE, hOldConIn);
-       if ((hFile[0] != INVALID_HANDLE_VALUE) &&
-               (hFile[0] != hOldConIn))
-       {
-               /* delete old stdin file, if it is a real file */
-               CloseHandle (hFile[0]);
-               hFile[0] = INVALID_HANDLE_VALUE;
-               DeleteFile (szFileName[0]);
-               *szFileName[0] = _T('\0');
-       }
-
-       /* Restore original STDIN */
-       if (hOldConIn != INVALID_HANDLE_VALUE)
-       {
-               HANDLE hIn = GetStdHandle (STD_INPUT_HANDLE);
-               SetStdHandle (STD_INPUT_HANDLE, hOldConIn);
-               if (hOldConIn != hIn)
-                       CloseHandle (hIn);
-               hOldConIn = INVALID_HANDLE_VALUE;
-       }
-       else
-       {
-#ifdef _DEBUG
-               DebugPrintf (_T("Can't restore STDIN! Is invalid!!\n"), out);
-#endif
-       }
-#endif  /* buggy implementation */
-
-
-       if (hOldConIn != INVALID_HANDLE_VALUE)
-       {
-               HANDLE hIn = GetStdHandle (STD_INPUT_HANDLE);
-               SetStdHandle (STD_INPUT_HANDLE, hOldConIn);
-               if (hIn == INVALID_HANDLE_VALUE)
-               {
-#ifdef _DEBUG
-                       DebugPrintf (_T("Previous STDIN is invalid!!\n"));
-#endif
-               }
-               else
-               {
-                       if (GetFileType (hIn) == FILE_TYPE_DISK)
-                       {
-                               if (hFile[0] == hIn)
-                               {
-                                       CloseHandle (hFile[0]);
-                                       hFile[0] = INVALID_HANDLE_VALUE;
-                                       DeleteFile (szFileName[0]);
-                                       *szFileName[0] = _T('\0');
-                               }
-                               else
-                               {
-#ifdef _DEBUG
-                                       DebugPrintf (_T("hFile[0] and hIn dont match!!!\n"));
-#endif
-                               }
-                       }
-               }
-       }
-
-
-       /* Restore original STDOUT */
-       if (hOldConOut != INVALID_HANDLE_VALUE)
-       {
-               HANDLE hOut = GetStdHandle (STD_OUTPUT_HANDLE);
-               SetStdHandle (STD_OUTPUT_HANDLE, hOldConOut);
-               if (hOldConOut != hOut)
-                       CloseHandle (hOut);
-               hOldConOut = INVALID_HANDLE_VALUE;
-       }
-
-       /* Restore original STDERR */
-       if (hOldConErr != INVALID_HANDLE_VALUE)
-       {
-               HANDLE hErr = GetStdHandle (STD_ERROR_HANDLE);
-               SetStdHandle (STD_ERROR_HANDLE, hOldConErr);
-               if (hOldConErr != hErr)
-                       CloseHandle (hErr);
-               hOldConErr = INVALID_HANDLE_VALUE;
-       }
-#endif /* FEATURE_REDIRECTION */
-}
-
-BOOL
-GrowIfNecessary ( UINT needed, LPTSTR* ret, UINT* retlen )
-{
-       if ( *ret && needed < *retlen )
-               return TRUE;
-       *retlen = needed;
-       if ( *ret )
-               free ( *ret );
-       *ret = (LPTSTR)malloc ( *retlen * sizeof(TCHAR) );
-       if ( !*ret )
-               SetLastError ( ERROR_OUTOFMEMORY );
-       return *ret != NULL;
-}
-
-LPCTSTR
-GetEnvVarOrSpecial ( LPCTSTR varName )
-{
-       static LPTSTR ret = NULL;
-       static UINT retlen = 0;
-       UINT size;
-
-       size = GetEnvironmentVariable ( varName, ret, retlen );
-       if ( size > retlen )
-       {
-               if ( !GrowIfNecessary ( size, &ret, &retlen ) )
-                       return NULL;
-               size = GetEnvironmentVariable ( varName, ret, retlen );
-       }
-       if ( size )
-               return ret;
-
-       /* env var doesn't exist, look for a "special" one */
-       /* %CD% */
-       if (_tcsicmp(varName,_T("cd")) ==0)
-       {
-               size = GetCurrentDirectory ( retlen, ret );
-               if ( size > retlen )
-               {
-                       if ( !GrowIfNecessary ( size, &ret, &retlen ) )
-                               return NULL;
-                       size = GetCurrentDirectory ( retlen, ret );
-               }
-               if ( !size )
-                       return NULL;
-               return ret;
-       }
-       /* %TIME% */
-       else if (_tcsicmp(varName,_T("time")) ==0)
-       {
-               SYSTEMTIME t;
-               if ( !GrowIfNecessary ( MAX_PATH, &ret, &retlen ) )
-                       return NULL;
-               GetSystemTime(&t);
-               _sntprintf ( ret, retlen, _T("%02d%c%02d%c%02d%c%02d"),
-                       t.wHour, cTimeSeparator, t.wMinute, cTimeSeparator,
-                       t.wSecond, cDecimalSeparator, t.wMilliseconds );
-               return ret;
-       }
-       /* %DATE% */
-       else if (_tcsicmp(varName,_T("date")) ==0)
-       {
-               LPTSTR tmp;
-
-               if ( !GrowIfNecessary ( MAX_PATH, &ret, &retlen ) )
-                       return NULL;
-               size = GetDateFormat(LOCALE_USER_DEFAULT, 0, NULL, _T("ddd"), ret, retlen );
-               /* TODO FIXME - test whether GetDateFormat() can return a value indicating the buffer wasn't big enough */
-               if ( !size )
-                       return NULL;
-               tmp = ret + _tcslen(ret);
-               *tmp++ = _T(' ');
-               size = GetDateFormat(LOCALE_USER_DEFAULT, DATE_SHORTDATE, NULL, NULL, tmp, retlen-(tmp-ret));
-               /* TODO FIXME - test whether GetDateFormat() can return a value indicating the buffer wasn't big enough */
-               if ( !size )
-                       return NULL;
-               return ret;
-       }
-
-       /* %RANDOM% */
-       else if (_tcsicmp(varName,_T("random")) ==0)
-       {
-               if ( !GrowIfNecessary ( MAX_PATH, &ret, &retlen ) )
-                       return NULL;
-               /* Get random number */
-               _itot(rand(),ret,10);
-               return ret;
-       }
-
-       /* %CMDCMDLINE% */
-       else if (_tcsicmp(varName,_T("cmdcmdline")) ==0)
-       {
-               return GetCommandLine();
-       }
-
-       /* %CMDEXTVERSION% */
-       else if (_tcsicmp(varName,_T("cmdextversion")) ==0)
-       {
-               if ( !GrowIfNecessary ( MAX_PATH, &ret, &retlen ) )
-                       return NULL;
-               /* Set version number to 2 */
-               _itot(2,ret,10);
-               return ret;
-       }
-
-       /* %ERRORLEVEL% */
-       else if (_tcsicmp(varName,_T("errorlevel")) ==0)
-       {
-               if ( !GrowIfNecessary ( MAX_PATH, &ret, &retlen ) )
-                       return NULL;
-               _itot(nErrorLevel,ret,10);
-               return ret;
-       }
-
-       GrowIfNecessary(_tcslen(varName) + 2, &ret, &retlen);
-       _stprintf(ret,_T("%%%s%%"),varName);
-       return ret; /* not found - return orginal string */
-}
-
-LPCTSTR
-GetParsedEnvVar ( LPCTSTR varName, UINT* varNameLen, BOOL ModeSetA )
-{
-       static LPTSTR ret = NULL;
-       static UINT retlen = 0;
-       LPTSTR p, tmp;
-       UINT size;
-
-       if ( varNameLen )
-               *varNameLen = 0;
-       SetLastError(0);
-       if ( *varName++ != '%' )
-               return NULL;
-       switch ( *varName )
-       {
-       case _T('0'):
-       case _T('1'):
-       case _T('2'):
-       case _T('3'):
-       case _T('4'):
-       case _T('5'):
-       case _T('6'):
-       case _T('7'):
-       case _T('8'):
-       case _T('9'):
-               if ((tmp = FindArg (*varName - _T('0'))))
-               {
-                       if ( varNameLen )
-                               *varNameLen = 2;
-                       if ( !*tmp )
-                               return _T("");
-                       if ( !GrowIfNecessary ( _tcslen(tmp)+1, &ret, &retlen ) )
-                               return NULL;
-                       _tcscpy ( ret, tmp );
-                       return ret;
-               }
-               if ( !GrowIfNecessary ( 3, &ret, &retlen ) )
-                       return NULL;
-               ret[0] = _T('%');
-               ret[1] = *varName;
-               ret[2] = 0;
-               if ( varNameLen )
-                       *varNameLen = 2;
-               return ret;
-
-       case _T('%'):
-               if ( !GrowIfNecessary ( 2, &ret, &retlen ) )
-                       return NULL;
-               ret[0] = _T('%');
-               ret[1] = 0;
-               if ( varNameLen )
-                       *varNameLen = 2;
-               return ret;
-
-       case _T('?'):
-               /* TODO FIXME 10 is only max size for 32-bit */
-               if ( !GrowIfNecessary ( 11, &ret, &retlen ) )
-                       return NULL;
-               _sntprintf ( ret, retlen, _T("%u"), nErrorLevel);
-               ret[retlen-1] = 0;
-               if ( varNameLen )
-                       *varNameLen = 2;
-               return ret;
-       }
-       if ( ModeSetA )
-       {
-               /* HACK for set/a */
-               if ( !GrowIfNecessary ( 2, &ret, &retlen ) )
-                       return NULL;
-               ret[0] = _T('%');
-               ret[1] = 0;
-               if ( varNameLen )
-                       *varNameLen = 1;
-               return ret;
-       }
-       p = _tcschr ( varName, _T('%') );
-       if ( !p )
-       {
-               SetLastError ( ERROR_INVALID_PARAMETER );
-               return NULL;
-       }
-       size = p-varName;
-       if ( varNameLen )
-               *varNameLen = size + 2;
-       p = alloca ( (size+1) * sizeof(TCHAR) );
-       memmove ( p, varName, size * sizeof(TCHAR) );
-       p[size] = 0;
-       varName = p;
-       return GetEnvVarOrSpecial ( varName );
-}
-
-
-/*
- * do the prompt/input/process loop
- *
- */
-
-static INT
-ProcessInput (BOOL bFlag)
-{
-       TCHAR commandline[CMDLINE_LENGTH];
-       TCHAR readline[CMDLINE_LENGTH];
-       LPTSTR ip;
-       LPTSTR cp;
-       LPCTSTR tmp;
-       BOOL bEchoThisLine;
-       BOOL bModeSetA;
-        BOOL bIsBatch;
-
-       do
-       {
-               /* if no batch input then... */
-               if (!(ip = ReadBatchLine (&bEchoThisLine)))
-               {
-                       if (bFlag)
-                               return nErrorLevel;
-
-                       ReadCommand (readline, CMDLINE_LENGTH);
-                       ip = readline;
-                       bEchoThisLine = FALSE;
-            bIsBatch = FALSE;
-               }
-        else
-        {
-            bIsBatch = TRUE;
-        }
-
-               /* skip leading blanks */
-               while ( _istspace(*ip) )
-                       ++ip;
-
-               cp = commandline;
-               bModeSetA = FALSE;
-               while (*ip)
-               {
-                       if ( *ip == _T('%') )
-                       {
-                               UINT envNameLen;
-                               LPCTSTR envVal = GetParsedEnvVar ( ip, &envNameLen, bModeSetA );
-                               if ( envVal )
-                               {
-                                       ip += envNameLen;
-                                       cp = _stpcpy ( cp, envVal );
-                               }
-                       }
-
-                       if (_istcntrl (*ip))
-                               *ip = _T(' ');
-                       *cp++ = *ip++;
-
-                       /* HACK HACK HACK check whether bModeSetA needs to be toggled */
-                       *cp = 0;
-                       tmp = commandline;
-                       tmp += _tcsspn(tmp,_T(" \t"));
-                       /* first we find and skip and pre-redirections... */
-                       while (( tmp ) &&
-                               ( _tcschr(_T("<>"),*tmp)
-                               || !_tcsncmp(tmp,_T("1>"),2)
-                               || !_tcsncmp(tmp,_T("2>"),2) ))
-                       {
-                               if ( _istdigit(*tmp) )
-                                       tmp += 2;
-                               else
-                                       tmp++;
-                               tmp += _tcsspn(tmp,_T(" \t"));
-                               if ( *tmp == _T('\"') )
-                               {
-                                       tmp = _tcschr(tmp+1,_T('\"'));
-                                       if ( tmp )
-                                               ++tmp;
-                               }
-                               else
-                                       tmp = _tcspbrk(tmp,_T(" \t"));
-                               if ( tmp )
-                                       tmp += _tcsspn(tmp,_T(" \t"));
-                       }
-                       /* we should now be pointing to the actual command
-                        * (if there is one yet)*/
-                       if ( tmp )
-                       {
-                               /* if we're currently substituting ( which is default )
-                                * check to see if we've parsed out a set/a. if so, we
-                                * need to disable substitution until we come across a
-                                * redirection */
-                               if ( !bModeSetA )
-                               {
-                                       /* look for set /a */
-                                       if ( !_tcsnicmp(tmp,_T("set"),3) )
-                                       {
-                                               tmp += 3;
-                                               tmp += _tcsspn(tmp,_T(" \t"));
-                                               if ( !_tcsnicmp(tmp,_T("/a"),2) )
-                                                       bModeSetA = TRUE;
-                                       }
-                               }
-                               /* if we're not currently substituting, it means we're
-                                * already inside a set /a. now we need to look for
-                                * a redirection in order to turn redirection back on */
-                               else
-                               {
-                                       /* look for redirector of some kind after the command */
-                                       while ( (tmp = _tcspbrk ( tmp, _T("^<>|") )) )
-                                       {
-                                               if ( *tmp == _T('^') )
-                                               {
-                                                       if ( _tcschr(_T("<>|&"), *++tmp ) && *tmp )
-                                                               ++tmp;
-                                               }
-                                               else
-                                               {
-                                                       bModeSetA = FALSE;
-                                                       break;
-                                               }
-                                       }
-                               }
-                       }
-               }
-
-               *cp = _T('\0');
-
-               /* strip trailing spaces */
-               while ((--cp >= commandline) && _istspace (*cp));
-
-               *(cp + 1) = _T('\0');
-
-               /* JPP 19980807 */
-               /* Echo batch file line */
-               if (bEchoThisLine)
-               {
-                       PrintPrompt ();
-                       ConOutPuts (commandline);
-               }
-
-               if (!CheckCtrlBreak(BREAK_INPUT) && *commandline)
-               {
-                       ParseCommandLine (commandline);
-                       if (bEcho && !bIgnoreEcho && (!bIsBatch || bEchoThisLine))
-                               ConOutChar ('\n');
-                       bIgnoreEcho = FALSE;
-               }
-       }
-       while (!bCanExit || !bExit);
-
-       return nErrorLevel;
-}
-
-
-/*
- * control-break handler.
- */
-BOOL WINAPI BreakHandler (DWORD dwCtrlType)
-{
-
-       DWORD                   dwWritten;
-       INPUT_RECORD    rec;
-       static BOOL SelfGenerated = FALSE;
-    
-       if ((dwCtrlType != CTRL_C_EVENT) &&
-           (dwCtrlType != CTRL_BREAK_EVENT))
-       {
-               return FALSE;
-       }
-       else
-       {               
-               if(SelfGenerated)
-               {
-                       SelfGenerated = FALSE;
-                       return TRUE;
-               }
-       }
-       
-       if (bChildProcessRunning == TRUE)
-       {
-               SelfGenerated = TRUE;
-               GenerateConsoleCtrlEvent (dwCtrlType, 0);
-               return TRUE;
-       }
-
-    
-    rec.EventType = KEY_EVENT;
-    rec.Event.KeyEvent.bKeyDown = TRUE;
-    rec.Event.KeyEvent.wRepeatCount = 1;
-    rec.Event.KeyEvent.wVirtualKeyCode = _T('C');
-    rec.Event.KeyEvent.wVirtualScanCode = _T('C') - 35;
-    rec.Event.KeyEvent.uChar.AsciiChar = _T('C');
-    rec.Event.KeyEvent.uChar.UnicodeChar = _T('C');
-    rec.Event.KeyEvent.dwControlKeyState = RIGHT_CTRL_PRESSED; 
-
-    WriteConsoleInput(
-        hIn,
-        &rec,
-        1,
-               &dwWritten);
-        
-       bCtrlBreak = TRUE;
-       /* FIXME: Handle batch files */
-
-       //ConOutPrintf(_T("^C"));
-
-
-       return TRUE;
-}
-
-
-VOID AddBreakHandler (VOID)
-{
-       SetConsoleCtrlHandler ((PHANDLER_ROUTINE)BreakHandler, TRUE);
-}
-
-
-VOID RemoveBreakHandler (VOID)
-{
-       SetConsoleCtrlHandler ((PHANDLER_ROUTINE)BreakHandler, FALSE);
-}
-
-
-/*
- * show commands and options that are available.
- *
- */
-#if 0
-static VOID
-ShowCommands (VOID)
-{
-       /* print command list */
-       ConOutResPuts(STRING_CMD_HELP1);
-       PrintCommandList();
-
-       /* print feature list */
-       ConOutResPuts(STRING_CMD_HELP2);
-
-#ifdef FEATURE_ALIASES
-       ConOutResPuts(STRING_CMD_HELP3);
-#endif
-#ifdef FEATURE_HISTORY
-       ConOutResPuts(STRING_CMD_HELP4);
-#endif
-#ifdef FEATURE_UNIX_FILENAME_COMPLETION
-       ConOutResPuts(STRING_CMD_HELP5);
-#endif
-#ifdef FEATURE_DIRECTORY_STACK
-       ConOutResPuts(STRING_CMD_HELP6);
-#endif
-#ifdef FEATURE_REDIRECTION
-       ConOutResPuts(STRING_CMD_HELP7);
-#endif
-       ConOutChar(_T('\n'));
-}
-#endif
-
-/*
- * set up global initializations and process parameters
- *
- * argc - number of parameters to command.com
- * argv - command-line parameters
- *
- */
-static VOID
-Initialize (int argc, TCHAR* argv[])
-{
-       TCHAR commandline[CMDLINE_LENGTH];
-       TCHAR ModuleName[_MAX_PATH + 1];
-       INT i;
-       TCHAR lpBuffer[2];
-
-       //INT len;
-       //TCHAR *ptr, *cmdLine;
-
-       /* get version information */
-       osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
-       GetVersionEx (&osvi);
-
-       /* Some people like to run ReactOS cmd.exe on Win98, it helps in the
-        * build process. So don't link implicitly against ntdll.dll, load it
-        * dynamically instead */
-
-       if (osvi.dwPlatformId == VER_PLATFORM_WIN32_NT)
-       {
-               /* ntdll is always present on NT */
-               NtDllModule = GetModuleHandle(TEXT("ntdll.dll"));
-       }
-       else
-       {
-               /* not all 9x versions have a ntdll.dll, try to load it */
-               NtDllModule = LoadLibrary(TEXT("ntdll.dll"));
-       }
-
-       if (NtDllModule != NULL)
-       {
-               NtQueryInformationProcessPtr = (NtQueryInformationProcessProc)GetProcAddress(NtDllModule, "NtQueryInformationProcess");
-               NtReadVirtualMemoryPtr = (NtReadVirtualMemoryProc)GetProcAddress(NtDllModule, "NtReadVirtualMemory");
-       }
-
-
-#ifdef _DEBUG
-       DebugPrintf (_T("[command args:\n"));
-       for (i = 0; i < argc; i++)
-       {
-               DebugPrintf (_T("%d. %s\n"), i, argv[i]);
-       }
-       DebugPrintf (_T("]\n"));
-#endif
-
-       InitLocale ();
-
-       /* get default input and output console handles */
-       hOut = GetStdHandle (STD_OUTPUT_HANDLE);
-       hIn  = GetStdHandle (STD_INPUT_HANDLE);
-
-       /* Set EnvironmentVariable PROMPT if it does not exists any env value.
-          for you can change the EnvirommentVariable for prompt before cmd start
-          this patch are not 100% right, if it does not exists a PROMPT value cmd should use
-          $P$G as defualt not set EnvirommentVariable PROMPT to $P$G if it does not exists */
-       if (GetEnvironmentVariable(_T("PROMPT"),lpBuffer, sizeof(lpBuffer) / sizeof(lpBuffer[0])) == 0)
-           SetEnvironmentVariable (_T("PROMPT"), _T("$P$G"));
-
-
-       if (argc >= 2 && !_tcsncmp (argv[1], _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_CMD_HELP8);
-               ExitProcess(0);
-       }
-       SetConsoleMode (hIn, ENABLE_PROCESSED_INPUT);
-
-#ifdef INCLUDE_CMD_CHDIR
-       InitLastPath ();
-#endif
-
-#ifdef FATURE_ALIASES
-       InitializeAlias ();
-#endif
-
-       if (argc >= 2)
-       {
-               for (i = 1; i < argc; i++)
-               {
-                       if (!_tcsicmp (argv[i], _T("/p")))
-                       {
-                               if (!IsExistingFile (_T("\\autoexec.bat")))
-                               {
-#ifdef INCLUDE_CMD_DATE
-                                       cmd_date (_T(""), _T(""));
-#endif
-#ifdef INCLUDE_CMD_TIME
-                                       cmd_time (_T(""), _T(""));
-#endif
-                               }
-                               else
-                               {
-                                       ParseCommandLine (_T("\\autoexec.bat"));
-                               }
-                               bCanExit = FALSE;
-                       }
-                       else if (!_tcsicmp (argv[i], _T("/c")))
-                       {
-                               /* This just runs a program and exits */
-                               ++i;
-                               if (i < argc)
-                               {
-                                       _tcscpy (commandline, argv[i]);
-                                       while (++i < argc)
-                                       {
-                                               _tcscat (commandline, _T(" "));
-                                               _tcscat (commandline, argv[i]);
-                                       }
-
-                                       ParseCommandLine(commandline);
-                                       ExitProcess (ProcessInput (TRUE));
-                               }
-                               else
-                               {
-                                       ExitProcess (0);
-                               }
-                       }
-                       else if (!_tcsicmp (argv[i], _T("/k")))
-                       {
-                               /* This just runs a program and remains */
-                               ++i;
-                               if (i < argc)
-                               {
-                                       _tcscpy (commandline, _T("\""));
-                                       _tcscat (commandline, argv[i]);
-                                       _tcscat (commandline, _T("\""));
-                                       while (++i < argc)
-                                       {
-                                               _tcscat (commandline, _T(" "));
-                                               _tcscat (commandline, argv[i]);
-                                       }
-                                       ParseCommandLine(commandline);
-                               }
-                       }
-#ifdef INCLUDE_CMD_COLOR
-                       else if (!_tcsnicmp (argv[i], _T("/t:"), 3))
-                       {
-                               /* process /t (color) argument */
-                               wDefColor = (WORD)_tcstoul (&argv[i][3], NULL, 16);
-                               wColor = wDefColor;
-                               SetScreenColor (wColor, TRUE);
-                       }
-#endif
-               }
-       }
-
-       /* run cmdstart.bat */
-       if (IsExistingFile (_T("cmdstart.bat")))
-       {
-               ParseCommandLine (_T("cmdstart.bat"));
-       }
-       else if (IsExistingFile (_T("\\cmdstart.bat")))
-       {
-               ParseCommandLine (_T("\\cmdstart.bat"));
-       }
-
-#ifdef FEATURE_DIR_STACK
-       /* initialize directory stack */
-       InitDirectoryStack ();
-#endif
-
-
-#ifdef FEATURE_HISTORY
-       /*initialize history*/
-       InitHistory();
-#endif
-
-       /* Set COMSPEC environment variable */
-       if (0 != GetModuleFileName (NULL, ModuleName, _MAX_PATH + 1))
-       {
-               ModuleName[_MAX_PATH] = _T('\0');
-               SetEnvironmentVariable (_T("COMSPEC"), ModuleName);
-       }
-
-       /* add ctrl break handler */
-       AddBreakHandler ();
-}
-
-
-static VOID Cleanup (int argc, TCHAR *argv[])
-{
-       /* run cmdexit.bat */
-       if (IsExistingFile (_T("cmdexit.bat")))
-       {
-               ConErrResPuts(STRING_CMD_ERROR5);
-
-               ParseCommandLine (_T("cmdexit.bat"));
-       }
-       else if (IsExistingFile (_T("\\cmdexit.bat")))
-       {
-               ConErrResPuts (STRING_CMD_ERROR5);
-               ParseCommandLine (_T("\\cmdexit.bat"));
-       }
-
-#ifdef FEATURE_ALIASES
-       DestroyAlias ();
-#endif
-
-#ifdef FEATURE_DIECTORY_STACK
-       /* destroy directory stack */
-       DestroyDirectoryStack ();
-#endif
-
-#ifdef INCLUDE_CMD_CHDIR
-       FreeLastPath ();
-#endif
-
-#ifdef FEATURE_HISTORY
-       CleanHistory();
-#endif
-
-
-       /* remove ctrl break handler */
-       RemoveBreakHandler ();
-       SetConsoleMode( GetStdHandle( STD_INPUT_HANDLE ),
-                       ENABLE_LINE_INPUT | ENABLE_PROCESSED_INPUT | ENABLE_ECHO_INPUT );
-
-       if (NtDllModule != NULL)
-       {
-               FreeLibrary(NtDllModule);
-       }
-}
-
-/*
- * main function
- */
-#ifdef _UNICODE
-int _main(void)
-#else
-int _main (int argc, char *argv[])
-#endif
-{
-       TCHAR startPath[MAX_PATH];
-       CONSOLE_SCREEN_BUFFER_INFO Info;
-       INT nExitCode;
-#ifdef _UNICODE
-       PWCHAR * argv;
-       int argc=0;
-       argv = CommandLineToArgvW(GetCommandLineW(), &argc);
-#endif
-
-       GetCurrentDirectory(MAX_PATH,startPath);
-       _tchdir(startPath);
-
-       SetFileApisToOEM();
-       InputCodePage= 0;
-       OutputCodePage = 0;
-
-       hConsole = CreateFile(_T("CONOUT$"), GENERIC_READ|GENERIC_WRITE,
-               FILE_SHARE_READ|FILE_SHARE_WRITE, NULL,
-               OPEN_EXISTING, 0, NULL);
-       if (GetConsoleScreenBufferInfo(hConsole, &Info) == FALSE)
-       {
-               ConErrFormatMessage(GetLastError());
-               return(1);
-       }
-       wColor = Info.wAttributes;
-       wDefColor = wColor;
-
-       InputCodePage= GetConsoleCP();
-       OutputCodePage = GetConsoleOutputCP();
-       CMD_ModuleHandle = GetModuleHandle(NULL);
-
-       /* check switches on command-line */
-       Initialize(argc, argv);
-
-       /* call prompt routine */
-       nExitCode = ProcessInput(FALSE);
-
-       /* do the cleanup */
-       Cleanup(argc, argv);
-
-       return(nExitCode);
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/cmd.h b/reactos/subsys/system/cmd/cmd.h
deleted file mode 100644 (file)
index 5134f80..0000000
+++ /dev/null
@@ -1,405 +0,0 @@
-/*
- *  CMD.H - header file for the modules in CMD.EXE
- *
- *
- *  History:
- *
- *    7-15-95 Tim Norman
- *        started
- *
- *    06/29/98 (Rob Lake)
- *        Moved error messages in here
- *
- *    07/12/98 (Rob Lake)
- *        Moved more error messages here.
- *
- *    30-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        Added compile date to version.
- *
- *    26-Feb-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Introduced a new version string.
- *        Thanks to Emanuele Aliberti!
- */
-
-#ifndef _CMD_H_INCLUDED_
-#define _CMD_H_INCLUDED_
-
-#include "config.h"
-
-#include <windows.h>
-#include <tchar.h>
-
-#include "cmdver.h"
-
-#define BREAK_BATCHFILE 1
-#define BREAK_OUTOFBATCH 2
-#define BREAK_INPUT 3
-#define BREAK_IGNORE 4
-
-/* define some error messages */
-
-#define D_ON         _T("on")
-#define D_OFF        _T("off")
-
-
-/* command line buffer length */
-#define CMDLINE_LENGTH  8192
-
-/* global variables */
-extern HANDLE hOut;
-extern HANDLE hIn;
-extern HANDLE hConsole;
-extern WORD   wColor;
-extern WORD   wDefColor;
-extern BOOL   bCtrlBreak;
-extern BOOL   bIgnoreEcho;
-extern BOOL   bExit;
-extern INT    nErrorLevel;
-extern SHORT  maxx;
-extern SHORT  maxy;
-extern OSVERSIONINFO osvi;
-
-
-
-/* Prototypes for ALIAS.C */
-VOID InitializeAlias (VOID);
-VOID DestroyAlias (VOID);
-VOID ExpandAlias (LPTSTR, INT);
-INT CommandAlias (LPTSTR, LPTSTR);
-
-
-/* Prototypes for ATTRIB.C */
-INT CommandAttrib (LPTSTR, LPTSTR);
-
-
-/* Prototypes for BEEP.C */
-INT cmd_beep (LPTSTR, LPTSTR);
-
-
-/* Prototypes for CALL.C */
-INT cmd_call (LPTSTR, LPTSTR);
-
-
-/* Prototypes for CHCP.C */
-INT CommandChcp (LPTSTR, LPTSTR);
-
-
-/* Prototypes for CHOICE.C */
-INT CommandChoice (LPTSTR, LPTSTR);
-
-
-/* Prototypes for CLS.C */
-INT cmd_cls (LPTSTR, LPTSTR);
-
-
-/* Prototypes for CMD.C */
-INT ConvertULargeInteger (ULARGE_INTEGER num, LPTSTR des, INT len, BOOL bPutSeperator);
-VOID ParseCommandLine (LPTSTR);
-LPCTSTR GetEnvVarOrSpecial ( LPCTSTR varName );
-VOID AddBreakHandler (VOID);
-VOID RemoveBreakHandler (VOID);
-
-extern HANDLE CMD_ModuleHandle;
-
-
-/* Prototypes for CMDINPUT.C */
-VOID ReadCommand (LPTSTR, INT);
-
-
-/* Prototypes for CMDTABLE.C */
-#define CMD_SPECIAL     1
-#define CMD_BATCHONLY   2
-#define CMD_HIDE        4
-
-typedef struct tagCOMMAND
-{
-       LPTSTR name;
-       INT    flags;
-       INT    (*func) (LPTSTR, LPTSTR);
-} COMMAND, *LPCOMMAND;
-
-extern COMMAND cmds[];         /* The internal command table */
-
-VOID PrintCommandList (VOID);
-VOID PrintCommandListDetail (VOID);
-
-
-/* Prototypes for COLOR.C */
-VOID SetScreenColor(WORD wArgColor, BOOL bFill);
-INT CommandColor (LPTSTR, LPTSTR);
-
-
-/* Prototypes for CONSOLE.C */
-#ifdef _DEBUG
-VOID DebugPrintf (LPTSTR, ...);
-#endif /* _DEBUG */
-
-VOID ConInDummy (VOID);
-VOID ConInDisable (VOID);
-VOID ConInEnable (VOID);
-VOID ConInFlush (VOID);
-VOID ConInKey (PINPUT_RECORD);
-VOID ConInString (LPTSTR, DWORD);
-
-VOID ConOutChar (TCHAR);
-VOID ConOutPuts (LPTSTR);
-VOID ConOutPrintf (LPTSTR, ...);
-INT ConOutPrintfPaging (BOOL NewPage, LPTSTR, ...);
-VOID ConErrChar (TCHAR);
-VOID ConErrPuts (LPTSTR);
-VOID ConErrPrintf (LPTSTR, ...);
-VOID ConOutFormatMessage (DWORD MessageId, ...);
-VOID ConErrFormatMessage (DWORD MessageId, ...);
-
-SHORT GetCursorX  (VOID);
-SHORT GetCursorY  (VOID);
-VOID  GetCursorXY (PSHORT, PSHORT);
-VOID  SetCursorXY (SHORT, SHORT);
-
-VOID GetScreenSize (PSHORT, PSHORT);
-VOID SetCursorType (BOOL, BOOL);
-
-VOID ConOutResPuts (UINT resID);
-VOID ConErrResPuts (UINT resID);
-VOID ConOutResPaging(BOOL NewPage, UINT resID);
-
-/* Prototypes for COPY.C */
-INT cmd_copy (LPTSTR, LPTSTR);
-
-
-/* Prototypes for DATE.C */
-INT cmd_date (LPTSTR, LPTSTR);
-
-
-/* Prototypes for DEL.C */
-INT CommandDelete (LPTSTR, LPTSTR);
-
-
-/* Prototypes for DELAY.C */
-INT CommandDelay (LPTSTR, LPTSTR);
-
-
-/* Prototypes for DIR.C */
-INT CommandDir (LPTSTR, LPTSTR);
-
-
-/* Prototypes for DIRSTACK.C */
-VOID InitDirectoryStack (VOID);
-VOID DestroyDirectoryStack (VOID);
-INT  GetDirectoryStackDepth (VOID);
-INT  CommandPushd (LPTSTR, LPTSTR);
-INT  CommandPopd (LPTSTR, LPTSTR);
-INT  CommandDirs (LPTSTR, LPTSTR);
-
-
-/* Prototypes for ECHO.C */
-INT  CommandEcho (LPTSTR, LPTSTR);
-INT  CommandEchos (LPTSTR, LPTSTR);
-INT  CommandEchoerr (LPTSTR, LPTSTR);
-INT  CommandEchoserr (LPTSTR, LPTSTR);
-
-
-/* Prototypes for ERROR.C */
-VOID ErrorMessage (DWORD, LPTSTR, ...);
-
-VOID error_no_pipe (VOID);
-VOID error_bad_command (VOID);
-VOID error_invalid_drive (VOID);
-VOID error_req_param_missing (VOID);
-VOID error_sfile_not_found (LPTSTR);
-VOID error_file_not_found (VOID);
-VOID error_path_not_found (VOID);
-VOID error_too_many_parameters (LPTSTR);
-VOID error_parameter_format(TCHAR);
-VOID error_invalid_switch (TCHAR);
-VOID error_invalid_parameter_format (LPTSTR);
-VOID error_out_of_memory (VOID);
-VOID error_syntax (LPTSTR);
-
-VOID msg_pause (VOID);
-
-
-/* Prototypes for FILECOMP.C */
-#ifdef FEATURE_UNIX_FILENAME_COMPLETION
-VOID CompleteFilename (LPTSTR, UINT);
-INT  ShowCompletionMatches (LPTSTR, INT);
-#endif
-#ifdef FEATURE_4NT_FILENAME_COMPLETION
-VOID CompleteFilename (LPTSTR, BOOL, LPTSTR, UINT);
-#endif
-
-
-/* Prototypes for FOR.C */
-INT cmd_for (LPTSTR, LPTSTR);
-
-
-/* Prototypes for FREE.C */
-INT CommandFree (LPTSTR, LPTSTR);
-
-
-/* Prototypes for GOTO.C */
-INT cmd_goto (LPTSTR, LPTSTR);
-
-
-/* Prototypes for HISTORY.C */
-#ifdef FEATURE_HISTORY
-VOID History (INT, LPTSTR);/*add entries browse history*/
-VOID History_move_to_bottom(VOID);/*F3*/
-VOID InitHistory(VOID);
-VOID CleanHistory(VOID);
-VOID History_del_current_entry(LPTSTR str);/*CTRL-D*/
-INT CommandHistory (LPTSTR cmd, LPTSTR param);
-#endif
-
-
-/* Prototypes for INTERNAL.C */
-VOID InitLastPath (VOID);
-VOID FreeLastPath (VOID);
-INT  cmd_chdir (LPTSTR, LPTSTR);
-INT  cmd_mkdir (LPTSTR, LPTSTR);
-INT  cmd_rmdir (LPTSTR, LPTSTR);
-INT  CommandExit (LPTSTR, LPTSTR);
-INT  CommandRem (LPTSTR, LPTSTR);
-INT  CommandShowCommands (LPTSTR, LPTSTR);
-INT  CommandShowCommandsDetail (LPTSTR, LPTSTR);
-
-/* Prototypes for LABEL.C */
-INT cmd_label (LPTSTR, LPTSTR);
-
-
-/* Prototypes for LOCALE.C */
-extern TCHAR cDateSeparator;
-extern INT   nDateFormat;
-extern TCHAR cTimeSeparator;
-extern INT   nTimeFormat;
-extern TCHAR cThousandSeparator;
-extern TCHAR cDecimalSeparator;
-extern INT nNumberGroups;
-
-
-VOID InitLocale (VOID);
-VOID PrintDate (VOID);
-VOID PrintTime (VOID);
-
-/* cache codepage */
-extern UINT InputCodePage;
-extern UINT OutputCodePage;
-
-/* Prototypes for MEMORY.C */
-INT CommandMemory (LPTSTR, LPTSTR);
-
-
-/* Prototypes for MISC.C */
-INT GetRootPath(TCHAR *InPath,TCHAR *OutPath,INT size);
-BOOL SetRootPath(TCHAR *InPath);
-TCHAR  cgetchar (VOID);
-BOOL   CheckCtrlBreak (INT);
-BOOL add_entry (LPINT ac, LPTSTR **arg, LPCTSTR entry);
-LPTSTR *split (LPTSTR, LPINT, BOOL);
-VOID   freep (LPTSTR *);
-LPTSTR _stpcpy (LPTSTR, LPCTSTR);
-BOOL   IsValidPathName (LPCTSTR);
-BOOL   IsExistingFile (LPCTSTR);
-BOOL   IsExistingDirectory (LPCTSTR);
-BOOL   FileGetString (HANDLE, LPTSTR, INT);
-VOID   GetPathCase(TCHAR *, TCHAR *);
-
-#define PROMPT_NO    0
-#define PROMPT_YES   1
-#define PROMPT_ALL   2
-#define PROMPT_BREAK 3
-
-INT PagePrompt (VOID);
-INT FilePromptYN (LPTSTR, ...);
-INT FilePromptYNA (LPTSTR, ...);
-
-
-/* Prototypes for MOVE.C */
-INT cmd_move (LPTSTR, LPTSTR);
-
-
-/* Prototypes for MSGBOX.C */
-INT CommandMsgbox (LPTSTR, LPTSTR);
-
-
-/* Prototypes from PATH.C */
-INT cmd_path (LPTSTR, LPTSTR);
-
-
-/* Prototypes from PROMPT.C */
-VOID PrintPrompt (VOID);
-INT  cmd_prompt (LPTSTR, LPTSTR);
-
-
-/* Prototypes for REDIR.C */
-#define INPUT_REDIRECTION    1
-#define OUTPUT_REDIRECTION   2
-#define OUTPUT_APPEND        4
-#define ERROR_REDIRECTION    8
-#define ERROR_APPEND        16
-INT GetRedirection (LPTSTR, LPTSTR, LPTSTR, LPTSTR, LPINT);
-
-
-/* Prototypes for REN.C */
-INT cmd_rename (LPTSTR, LPTSTR);
-
-
-/* Prototypes for SCREEN.C */
-INT CommandScreen (LPTSTR, LPTSTR);
-
-
-/* Prototypes for SET.C */
-INT cmd_set (LPTSTR, LPTSTR);
-
-
-/* Prototypes for START.C */
-INT cmd_start (LPTSTR, LPTSTR);
-
-
-/* Prototypes for STRTOCLR.C */
-BOOL StringToColor (LPWORD, LPTSTR *);
-
-
-/* Prototypes for TIME.C */
-INT cmd_time (LPTSTR, LPTSTR);
-
-
-/* Prototypes for TIMER.C */
-INT CommandTimer (LPTSTR cmd, LPTSTR param);
-
-
-/* Prototypes for TITLE.C */
-INT cmd_title (LPTSTR, LPTSTR);
-
-
-/* Prototypes for TYPE.C */
-INT cmd_type (LPTSTR, LPTSTR);
-
-
-/* Prototypes for VER.C */
-VOID ShortVersion (VOID);
-INT  cmd_ver (LPTSTR, LPTSTR);
-
-
-/* Prototypes for VERIFY.C */
-INT cmd_verify (LPTSTR, LPTSTR);
-
-
-/* Prototypes for VOL.C */
-INT cmd_vol (LPTSTR, LPTSTR);
-
-
-/* Prototypes for WHERE.C */
-BOOL SearchForExecutable (LPCTSTR, LPTSTR);
-
-/* Prototypes for WINDOW.C */
-INT CommandActivate (LPTSTR, LPTSTR);
-INT CommandWindow (LPTSTR, LPTSTR);
-
-
-/* The MSDOS Batch Commands [MS-DOS 5.0 User's Guide and Reference p359] */
-int cmd_if(TCHAR *, TCHAR *);
-int cmd_pause(TCHAR *, TCHAR *);
-int cmd_shift(TCHAR *, TCHAR *);
-
-#endif /* _CMD_H_INCLUDED_ */
diff --git a/reactos/subsys/system/cmd/cmd.rc b/reactos/subsys/system/cmd/cmd.rc
deleted file mode 100644 (file)
index 9c6a262..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-#include <windows.h>
-#include "cmdver.h"
-
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS Command Processor\0"
-#define REACTOS_STR_INTERNAL_NAME      "cmd\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "cmd.exe\0"
-#define REACTOS_STR_ORIGINAL_COPYRIGHT "Copyright (C) 1994-1998 Tim Norman and others\0"
-#define REACTOS_STR_LEGAL_COPYRIGHT     "Copyright (C) 1998-2006 Eric Kohl and others\0"
-
-#include <reactos/version.rc>
-#include "En.rc"
-#include "Fr.rc"
-#include "De.rc"
-#include "Es.rc"
-#include "Ru.rc"
-#include "Ja.rc"
-#include "Hu.rc"
-
-
-STRINGTABLE DISCARDABLE
-{
-  STRING_FREEDOS_DEV, "    Tim Norman        Matt Rains\n\
-    Evan Jeffrey      Steffen Kaiser\n\
-    Svante Frey       Oliver Mueller\n\
-    Aaron Kaufman     Marc Desrochers\n\
-    Rob Lake          John P Price\n\
-    Hans B Pufal\n"
-
-  STRING_REACTOS_DEV,  "    Eric Kohl         Emanuele Aliberti\n\
-    Paolo Pantaleo    Phillip Susi\n\
-    Sylvain Petreolle\n"
-}
-
-1 ICON DISCARDABLE res/terminal.ico
-
-
-
-
-
diff --git a/reactos/subsys/system/cmd/cmd.xml b/reactos/subsys/system/cmd/cmd.xml
deleted file mode 100644 (file)
index a36da9f..0000000
+++ /dev/null
@@ -1,77 +0,0 @@
-<module name="cmd_base" type="objectlibrary">
-       <include base="ReactOS">include/wine</include>
-       <include base="cmd_base">.</include>
-       <define name="__USE_W32API" />
-       <define name="ANONYMOUSUNIONS" />
-       <define name="_WIN32_WINNT">0x0501</define>
-       <pch>precomp.h</pch>
-       <compilationunit name="unit.c">
-               <file>alias.c</file>
-               <file>attrib.c</file>
-               <file>batch.c</file>
-               <file>beep.c</file>
-               <file>call.c</file>
-               <file>chcp.c</file>
-               <file>choice.c</file>
-               <file>cls.c</file>
-               <file>cmd.c</file>
-               <file>cmdinput.c</file>
-               <file>cmdtable.c</file>
-               <file>color.c</file>
-               <file>console.c</file>
-               <file>copy.c</file>
-               <file>date.c</file>
-               <file>del.c</file>
-               <file>delay.c</file>
-               <file>dir.c</file>
-               <file>dirstack.c</file>
-               <file>echo.c</file>
-               <file>error.c</file>
-               <file>filecomp.c</file>
-               <file>for.c</file>
-               <file>free.c</file>
-               <file>goto.c</file>
-               <file>history.c</file>
-               <file>if.c</file>
-               <file>internal.c</file>
-               <file>label.c</file>
-               <file>locale.c</file>
-               <file>memory.c</file>
-               <file>misc.c</file>
-               <file>move.c</file>
-               <file>msgbox.c</file>
-               <file>path.c</file>
-               <file>pause.c</file>
-               <file>prompt.c</file>
-               <file>redir.c</file>
-               <file>ren.c</file>
-               <file>screen.c</file>
-               <file>set.c</file>
-               <file>shift.c</file>
-               <file>start.c</file>
-               <file>strtoclr.c</file>
-               <file>time.c</file>
-               <file>timer.c</file>
-               <file>title.c</file>
-               <file>type.c</file>
-               <file>ver.c</file>
-               <file>verify.c</file>
-               <file>vol.c</file>
-               <file>where.c</file>
-               <file>window.c</file>
-       </compilationunit>
-</module>
-<module name="cmd" type="win32cui" installbase="system32" installname="cmd.exe" usewrc="false">
-       <include base="ReactOS">include/wine</include>
-       <include base="cmd">.</include>
-       <define name="__USE_W32API" />
-       <define name="ANONYMOUSUNIONS" />
-       <define name="_WIN32_WINNT">0x0501</define>
-       <library>kernel32</library>
-       <library>cmd_base</library>
-       <file>main.c</file>
-       <file>cmd.rc</file>
-</module>
-<directory name="tests">
-       <xi:include href="tests/cmd_test.xml" />
-</directory>
diff --git a/reactos/subsys/system/cmd/cmdinput.c b/reactos/subsys/system/cmd/cmdinput.c
deleted file mode 100644 (file)
index 2bb36e3..0000000
+++ /dev/null
@@ -1,574 +0,0 @@
-/*
- *  CMDINPUT.C - handles command input (tab completion, history, etc.).
- *
- *
- *  History:
- *
- *    01/14/95 (Tim Norman)
- *        started.
- *
- *    08/08/95 (Matt Rains)
- *        i have cleaned up the source code. changes now bring this source
- *        into guidelines for recommended programming practice.
- *        i have added some constants to help making changes easier.
- *
- *    12/12/95 (Tim Norman)
- *        added findxy() function to get max x/y coordinates to display
- *        correctly on larger screens
- *
- *    12/14/95 (Tim Norman)
- *        fixed the Tab completion code that Matt Rains broke by moving local
- *        variables to a more global scope and forgetting to initialize them
- *        when needed
- *
- *    8/1/96 (Tim Norman)
- *        fixed a bug in tab completion that caused filenames at the beginning
- *        of the command-line to have their first letter truncated
- *
- *    9/1/96 (Tim Norman)
- *        fixed a silly bug using printf instead of fputs, where typing "%i"
- *        confused printf :)
- *
- *    6/14/97 (Steffan Kaiser)
- *        ctrl-break checking
- *
- *    6/7/97 (Marc Desrochers)
- *        recoded everything! now properly adjusts when text font is changed.
- *        removed findxy(), reposition(), and reprint(), as these functions
- *        were inefficient. added goxy() function as gotoxy() was buggy when
- *        the screen font was changed. the printf() problem with %i on the
- *        command line was fixed by doing printf("%s",str) instead of
- *        printf(str). Don't ask how I find em just be glad I do :)
- *
- *    7/12/97 (Tim Norman)
- *        Note: above changes pre-empted Steffan's ctrl-break checking.
- *
- *    7/7/97 (Marc Desrochers)
- *        rewrote a new findxy() because the new dir() used it.  This
- *        findxy() simply returns the values of *maxx *maxy.  In the
- *        future, please use the pointers, they will always be correct
- *        since they point to BIOS values.
- *
- *    7/8/97 (Marc Desrochers)
- *        once again removed findxy(), moved the *maxx, *maxy pointers
- *        global and included them as externs in command.h.  Also added
- *        insert/overstrike capability
- *
- *    7/13/97 (Tim Norman)
- *        added different cursor appearance for insert/overstrike mode
- *
- *    7/13/97 (Tim Norman)
- *        changed my code to use _setcursortype until I can figure out why
- *        my code is crashing on some machines.  It doesn't crash on mine :)
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    28-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        put ifdef's around filename completion code.
- *
- *    30-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        moved filename completion code to filecomp.c
- *        made second TAB display list of filename matches
- *
- *    31-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        Fixed bug where if you typed something, then hit HOME, then tried
- *        to type something else in insert mode, it crashed.
- *
- *    07-Aug-1998 (John P Price <linux-guru@gcfl.net>)
- *        Fixed carrage return output to better match MSDOS with echo
- *        on or off.(marked with "JPP 19980708")
- *
- *    13-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added insert/overwrite cursor.
- *
- *    25-Jan-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Replaced CRT io functions by Win32 console io functions.
- *        This can handle <Shift>-<Tab> for 4NT filename completion.
- *        Unicode and redirection safe!
- *
- *    04-Feb-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed input bug. A "line feed" character remained in the keyboard
- *        input queue when you pressed <RETURN>. This sometimes caused
- *        some very strange effects.
- *        Fixed some command line editing annoyances.
- *
- *    30-Apr-2004 (Filip Navara <xnavara@volny.cz>)
- *        Fixed problems when the screen was scrolled away.
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-SHORT maxx;
-SHORT maxy;
-
-/*
- * global command line insert/overwrite flag
- */
-static BOOL bInsert = TRUE;
-
-
-static VOID
-ClearCommandLine (LPTSTR str, INT maxlen, SHORT orgx, SHORT orgy)
-{
-       INT count;
-
-       SetCursorXY (orgx, orgy);
-       for (count = 0; count < (INT)_tcslen (str); count++)
-               ConOutChar (_T(' '));
-       _tcsnset (str, _T('\0'), maxlen);
-       SetCursorXY (orgx, orgy);
-}
-
-
-/* read in a command line */
-VOID ReadCommand (LPTSTR str, INT maxlen)
-{
-       SHORT orgx;                     /* origin x/y */
-       SHORT orgy;
-       SHORT curx;                     /*current x/y cursor position*/
-       SHORT cury;
-       SHORT tempscreen;
-       INT   count;            /*used in some for loops*/
-       INT   current = 0;      /*the position of the cursor in the string (str)*/
-       INT   charcount = 0;/*chars in the string (str)*/
-       INPUT_RECORD ir;
-       WORD   wLastKey = 0;
-       TCHAR  ch;
-       BOOL bContinue=FALSE;/*is TRUE the second case will not be executed*/
-    BOOL bReturn = FALSE;
-       TCHAR szPath[MAX_PATH];
-    BOOL bCharInput;
-
-       /* get screen size */
-       GetScreenSize (&maxx, &maxy);
-
-       /* JPP 19980807 - if echo off, don't print prompt */
-       if (bEcho)
-               PrintPrompt();
-
-       GetCursorXY (&orgx, &orgy);
-       GetCursorXY (&curx, &cury);
-
-       memset (str, 0, maxlen * sizeof (TCHAR));
-
-       SetCursorType (bInsert, TRUE);
-
-       do
-       {
-    
-        bReturn = FALSE;
-        
-               ConInKey (&ir);
-
-               if (ir.Event.KeyEvent.dwControlKeyState &
-                       (RIGHT_ALT_PRESSED|RIGHT_ALT_PRESSED|
-                       RIGHT_CTRL_PRESSED|LEFT_CTRL_PRESSED) )
-               {
-
-                       switch (ir.Event.KeyEvent.wVirtualKeyCode)
-                       {
-
-#ifdef FEATURE_HISTORY
-
-                               case 'K':
-                                       /*add the current command line to the history*/
-                                       if (ir.Event.KeyEvent.dwControlKeyState &
-                                               (LEFT_CTRL_PRESSED|RIGHT_CTRL_PRESSED))
-                                       {
-
-                                               if (str[0])
-                                                       History(0,str);
-
-                                               ClearCommandLine (str, maxlen, orgx, orgy);
-                                               current = charcount = 0;
-                                               curx = orgx;
-                                               cury = orgy;
-                                               bContinue=TRUE;
-                                               break;
-                                       }
-
-                               case 'D':
-                                       /*delete current history entry*/
-                                       if (ir.Event.KeyEvent.dwControlKeyState &
-                                               (LEFT_CTRL_PRESSED|RIGHT_CTRL_PRESSED))
-                                       {
-                                               ClearCommandLine (str, maxlen, orgx, orgy);
-                                               History_del_current_entry(str);
-                                               current = charcount = _tcslen (str);
-                                               ConOutPrintf (_T("%s"), str);
-                                               GetCursorXY (&curx, &cury);
-                                               bContinue=TRUE;
-                                               break;
-                                       }
-
-#endif/*FEATURE_HISTORY*/
-                       }
-
-
-
-
-               }
-
-               //if (bContinue)
-               //      continue;
-
-
-        bCharInput = FALSE;
-
-               switch (ir.Event.KeyEvent.wVirtualKeyCode)
-               {
-                       case VK_BACK:
-                               /* <BACKSPACE> - delete character to left of cursor */
-                               if (current > 0 && charcount > 0)
-                               {
-                                       if (current == charcount)
-                                       {
-                                               /* if at end of line */
-                                               str[current - 1] = _T('\0');
-                                               if (GetCursorX () != 0)
-                                               {
-                                                       ConOutPrintf (_T("\b \b"));
-                                                       curx--;
-                                               }
-                                               else
-                                               {
-                                                       SetCursorXY ((SHORT)(maxx - 1), (SHORT)(GetCursorY () - 1));
-                                                       ConOutChar (_T(' '));
-                                                       SetCursorXY ((SHORT)(maxx - 1), (SHORT)(GetCursorY () - 1));
-                                                       cury--;
-                                                       curx = maxx - 1;
-                                               }
-                                       }
-                                       else
-                                       {
-                                               for (count = current - 1; count < charcount; count++)
-                                                       str[count] = str[count + 1];
-                                               if (GetCursorX () != 0)
-                                               {
-                                                       SetCursorXY ((SHORT)(GetCursorX () - 1), GetCursorY ());
-                                                       curx--;
-                                               }
-                                               else
-                                               {
-                                                       SetCursorXY ((SHORT)(maxx - 1), (SHORT)(GetCursorY () - 1));
-                                                       cury--;
-                                                       curx = maxx - 1;
-                                               }
-                                               GetCursorXY (&curx, &cury);
-                                               ConOutPrintf (_T("%s "), &str[current - 1]);
-                                               SetCursorXY (curx, cury);
-                                       }
-                                       charcount--;
-                                       current--;
-                               }
-                               break;
-
-                       case VK_INSERT:
-                               /* toggle insert/overstrike mode */
-                               bInsert ^= TRUE;
-                               SetCursorType (bInsert, TRUE);
-                               break;
-
-                       case VK_DELETE:
-                               /* delete character under cursor */
-                               if (current != charcount && charcount > 0)
-                               {
-                                       for (count = current; count < charcount; count++)
-                                               str[count] = str[count + 1];
-                                       charcount--;
-                                       GetCursorXY (&curx, &cury);
-                                       ConOutPrintf (_T("%s "), &str[current]);
-                                       SetCursorXY (curx, cury);
-                               }
-                               break;
-
-                       case VK_HOME:
-                               /* goto beginning of string */
-                               if (current != 0)
-                               {
-                                       SetCursorXY (orgx, orgy);
-                                       curx = orgx;
-                                       cury = orgy;
-                                       current = 0;
-                               }
-                               break;
-
-                       case VK_END:
-                               /* goto end of string */
-                               if (current != charcount)
-                               {
-                                       SetCursorXY (orgx, orgy);
-                                       ConOutPrintf (_T("%s"), str);
-                                       GetCursorXY (&curx, &cury);
-                                       current = charcount;
-                               }
-                               break;
-
-                       case VK_TAB:
-#ifdef FEATURE_UNIX_FILENAME_COMPLETION
-                               /* expand current file name */
-                               if ((current == charcount) ||
-                                   (current == charcount - 1 &&
-                                    str[current] == _T('"'))) /* only works at end of line*/
-                               {
-                                       if (wLastKey != VK_TAB)
-                                       {
-                                               /* if first TAB, complete filename*/
-                                               tempscreen = charcount;
-                                               CompleteFilename (str, charcount);
-                                               charcount = _tcslen (str);
-                                               current = charcount;
-
-                                               SetCursorXY (orgx, orgy);
-                                               ConOutPrintf (_T("%s"), str);
-
-                                               if (tempscreen > charcount)
-                                               {
-                                                       GetCursorXY (&curx, &cury);
-                                                       for (count = tempscreen - charcount; count--; )
-                                                               ConOutChar (_T(' '));
-                                                       SetCursorXY (curx, cury);
-                                               }
-                                               else
-                                               {
-                                                       if (((charcount + orgx) / maxx) + orgy > maxy - 1)
-                                                               orgy += maxy - ((charcount + orgx) / maxx + orgy + 1);
-                                               }
-
-                                               /* set cursor position */
-                                               SetCursorXY ((orgx + current) % maxx,
-                                                            orgy + (orgx + current) / maxx);
-                                               GetCursorXY (&curx, &cury);
-                                       }
-                                       else
-                                       {
-                                               /*if second TAB, list matches*/
-                                               if (ShowCompletionMatches (str, charcount))
-                                               {
-                                                       PrintPrompt ();
-                                                       GetCursorXY (&orgx, &orgy);
-                                                       ConOutPrintf (_T("%s"), str);
-
-                                                       /* set cursor position */
-                                                       SetCursorXY ((orgx + current) % maxx,
-                                                                    orgy + (orgx + current) / maxx);
-                                                       GetCursorXY (&curx, &cury);
-                                               }
-
-                                       }
-                               }
-                               else
-                               {
-                                       MessageBeep (-1);
-                               }
-#endif
-#ifdef FEATURE_4NT_FILENAME_COMPLETION
-                               
-                               /* used to later see if we went down to the next line */
-                               tempscreen = charcount;
-                               szPath[0]=_T('\0');
-
-                               /* str is the whole things that is on the current line 
-                                  that is and and out.  arg 2 is weather it goes back
-                                       one file or forward one file */
-                               CompleteFilename(str, !(ir.Event.KeyEvent.dwControlKeyState & SHIFT_PRESSED), szPath, current);
-                               /* Attempt to clear the line */
-                               ClearCommandLine (str, maxlen, orgx, orgy);
-                               curx = orgx;
-                               cury = orgy;
-                               current = charcount = 0;                                
-        //str[0]=_T('\0');
-                               
-                               /* Everything is deleted, lets add it back in */
-                               _tcscpy(str,szPath);
-        
-                               /* Figure out where cusor is going to be after we print it */
-                               charcount = _tcslen (str);
-                               current = charcount;
-
-                               SetCursorXY (orgx, orgy);
-                               /* Print out what we have now */
-                               ConOutPrintf (_T("%s"), str);
-
-                               /* Move cursor accordingly */
-                               if(tempscreen > charcount)
-                               {
-                                       GetCursorXY (&curx, &cury);
-                                       for(count = tempscreen - charcount; count--; )
-                                               ConOutChar (_T(' '));
-                                       SetCursorXY (curx, cury);
-                               }
-                               else
-                               {
-                                       if(((charcount + orgx) / maxx) + orgy > maxy - 1)
-                                               orgy += maxy - ((charcount + orgx) / maxx + orgy + 1);
-                               }
-                               SetCursorXY((short)(((int)orgx + current) % maxx), (short)((int)orgy + ((int)orgx + current) / maxx));
-                               GetCursorXY(&curx, &cury);
-
-#endif
-                               break;
-            
-            case _T('M'):
-            case _T('C'):
-                /* ^M does the same as return */
-                bCharInput = TRUE;
-                if(!(ir.Event.KeyEvent.dwControlKeyState &
-                   (RIGHT_CTRL_PRESSED|LEFT_CTRL_PRESSED)))
-                {
-                    break;
-                }
-                    
-                       case VK_RETURN:
-                               /* end input, return to main */
-#ifdef FEATURE_HISTORY
-                               /* add to the history */
-                               if (str[0])
-                                       History (0, str);
-#endif
-                               ConInDummy ();
-                               ConOutChar (_T('\n'));
-                bReturn = TRUE;
-                               break;
-
-                       case VK_ESCAPE:
-                               /* clear str  Make this callable! */
-                               ClearCommandLine (str, maxlen, orgx, orgy);
-                               curx = orgx;
-                               cury = orgy;
-                               current = charcount = 0;
-                               break;
-
-#ifdef FEATURE_HISTORY
-                       case VK_F3:
-                               History_move_to_bottom();
-#endif
-                       case VK_UP:
-#ifdef FEATURE_HISTORY
-                               /* get previous command from buffer */
-                               ClearCommandLine (str, maxlen, orgx, orgy);
-                               History (-1, str);
-                               current = charcount = _tcslen (str);
-                               if (((charcount + orgx) / maxx) + orgy > maxy - 1)
-                                       orgy += maxy - ((charcount + orgx) / maxx + orgy + 1);
-                               ConOutPrintf (_T("%s"), str);
-                               GetCursorXY (&curx, &cury);
-#endif
-                               break;
-
-                       case VK_DOWN:
-#ifdef FEATURE_HISTORY
-                               /* get next command from buffer */
-                               ClearCommandLine (str, maxlen, orgx, orgy);
-                               History (1, str);
-                               current = charcount = _tcslen (str);
-                               if (((charcount + orgx) / maxx) + orgy > maxy - 1)
-                                       orgy += maxy - ((charcount + orgx) / maxx + orgy + 1);
-                               ConOutPrintf (_T("%s"), str);
-                               GetCursorXY (&curx, &cury);
-#endif
-                               break;
-
-                       case VK_LEFT:
-                               /* move cursor left */
-                               if (current > 0)
-                               {
-                                       current--;
-                                       if (GetCursorX () == 0)
-                                       {
-                                               SetCursorXY ((SHORT)(maxx - 1), (SHORT)(GetCursorY () - 1));
-                                               curx = maxx - 1;
-                                               cury--;
-                                       }
-                                       else
-                                       {
-                                               SetCursorXY ((SHORT)(GetCursorX () - 1), GetCursorY ());
-                                               curx--;
-                                       }
-                               }
-                               else
-                               {
-                                       MessageBeep (-1);
-                               }
-                               break;
-
-                       case VK_RIGHT:
-                               /* move cursor right */
-                               if (current != charcount)
-                               {
-                                       current++;
-                                       if (GetCursorX () == maxx - 1)
-                                       {
-                                               SetCursorXY (0, (SHORT)(GetCursorY () + 1));
-                                               curx = 0;
-                                               cury++;
-                                       }
-                                       else
-                                       {
-                                               SetCursorXY ((SHORT)(GetCursorX () + 1), GetCursorY ());
-                                               curx++;
-                                       }
-                               }
-                               break;
-
-            default:
-                /* This input is just a normal char */
-                bCharInput = TRUE;
-
-                       }
-#ifdef _UNICODE
-            ch = ir.Event.KeyEvent.uChar.UnicodeChar;
-            if ((ch >= 32 && (charcount != (maxlen - 2)) && bCharInput)
-#else
-            ch = ir.Event.KeyEvent.uChar.AsciiChar;
-            if ((UCHAR)ch >= 32 && (charcount != (maxlen - 2)) && bCharInput)
-#endif /* _UNICODE */
-            {
-                /* insert character into string... */
-                if (bInsert && current != charcount)
-                {
-                        /* If this character insertion will cause screen scrolling,
-                                                                 * adjust the saved origin of the command prompt. */
-                        tempscreen = _tcslen(str + current) + curx;
-                    if ((tempscreen % maxx) == (maxx - 1) &&
-                        (tempscreen / maxx) + cury == (maxy - 1))
-                    {
-                        orgy--;
-                        cury--;
-                    }
-
-                    for (count = charcount; count > current; count--)
-                        str[count] = str[count - 1];
-                    str[current++] = ch;
-                    if (curx == maxx - 1)
-                        curx = 0, cury++;
-                    else
-                        curx++;
-                    ConOutPrintf (_T("%s"), &str[current - 1]);
-                    SetCursorXY (curx, cury);
-                    charcount++;
-                }
-                else
-                {
-                    if (current == charcount)
-                        charcount++;
-                    str[current++] = ch;
-                    if (GetCursorX () == maxx - 1 && GetCursorY () == maxy - 1)
-                        orgy--, cury--;
-                    if (GetCursorX () == maxx - 1)
-                        curx = 0, cury++;
-                    else
-                        curx++;
-                    ConOutChar (ch);
-                }
-            }
-               
-               wLastKey = ir.Event.KeyEvent.wVirtualKeyCode;
-       }
-       while (!bReturn);
-
-       SetCursorType (bInsert, TRUE);
-}
diff --git a/reactos/subsys/system/cmd/cmdtable.c b/reactos/subsys/system/cmd/cmdtable.c
deleted file mode 100644 (file)
index 3af7443..0000000
+++ /dev/null
@@ -1,269 +0,0 @@
-/*
- *  CMDTABLE.C - table of internal commands.
- *
- *
- *  History:
- *
- *    16 Jul 1998 (Hans B Pufal)
- *        started.
- *        New file to keep the internal command table. I plan on
- *        getting rid of the table real soon now and replacing it
- *        with a dynamic mechnism.
- *
- *    27 Jul 1998  John P. Price
- *        added config.h include
- *
- *    21-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode ready!
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-/* a list of all the internal commands, associating their command names */
-/* to the functions to process them                                     */
-
-
-COMMAND cmds[] =
-{
-       {_T("?"), 0, CommandShowCommands},
-
-
-#ifdef INCLUDE_CMD_ACTIVATE
-       {_T("activate"), 0, CommandActivate},
-#endif
-
-#ifdef FEATURE_ALIASES
-       {_T("alias"), 0, CommandAlias},
-#endif
-
-#ifdef INCLUDE_CMD_ATTRIB
-       {_T("attrib"), 0, CommandAttrib},
-#endif
-
-#ifdef INCLUDE_CMD_BEEP
-       {_T("beep"),     0, cmd_beep},
-#endif
-
-       {_T("call"), CMD_BATCHONLY, cmd_call},
-
-#ifdef INCLUDE_CMD_CHDIR
-       {_T("cd"), CMD_SPECIAL, cmd_chdir},
-       {_T("chdir"), CMD_SPECIAL, cmd_chdir},
-#endif
-
-#ifdef INCLUDE_CMD_CHCP
-       {_T("chcp"), 0, CommandChcp},
-#endif
-
-#ifdef INCLUDE_CMD_CHOICE
-       {_T("choice"), 0, CommandChoice},
-#endif
-
-#ifdef INCLUDE_CMD_CLS
-       {_T("cls"), 0, cmd_cls},
-#endif
-
-#ifdef INCLUDE_CMD_COLOR
-       {_T("color"), 0, CommandColor},
-#endif
-
-#ifdef INCLUDE_CMD_COPY
-       {_T("copy"),     0, cmd_copy},
-#endif
-
-#ifdef INCLUDE_CMD_DATE
-       {_T("date"),     0, cmd_date},
-#endif
-
-#ifdef INCLUDE_CMD_DEL
-       {_T("del"), 0, CommandDelete},
-       {_T("delete"), 0, CommandDelete},
-#endif
-
-#ifdef INCLUDE_CMD_DELAY
-       {_T("delay"), 0, CommandDelay},
-#endif
-
-#ifdef INCLUDE_CMD_DIR
-       {_T("dir"), CMD_SPECIAL, CommandDir},
-#endif
-
-#ifdef FEATURE_DIRECTORY_STACK
-       {_T("dirs"), 0, CommandDirs},
-#endif
-
-       {_T("echo"), 0, CommandEcho},
-       {_T("echo."), CMD_HIDE, CommandEcho},
-       {_T("echos"), 0, CommandEchos},
-       {_T("echoerr"), 0, CommandEchoerr},
-       {_T("echoerr."), CMD_HIDE, CommandEchoerr},
-       {_T("echoserr"), 0, CommandEchoserr},
-
-#ifdef INCLUDE_CMD_DEL
-       {_T("erase"), 0, CommandDelete},
-#endif
-
-       {_T("exit"), 0, CommandExit},
-
-       {_T("for"), 0, cmd_for},
-
-#ifdef INCLUDE_CMD_FREE
-       {_T("free"), 0, CommandFree},
-#endif
-
-       {_T("goto"), CMD_BATCHONLY, cmd_goto},
-
-       {_T("help"), 0, CommandShowCommandsDetail},
-
-#ifdef FEATURE_HISTORY
-       {_T("history"), 0, CommandHistory},
-#endif
-
-       {_T("if"), 0, cmd_if},
-
-#ifdef INCLUDE_CMD_LABEL
-       {_T("label"), 0, cmd_label},
-#endif
-
-#ifdef INCLUDE_CMD_MEMORY
-       {_T("memory"), 0, CommandMemory},
-#endif
-
-#ifdef INCLUDE_CMD_MKDIR
-       {_T("md"), CMD_SPECIAL, cmd_mkdir},
-       {_T("mkdir"), CMD_SPECIAL, cmd_mkdir},
-#endif
-
-#ifdef INCLUDE_CMD_MOVE
-       {_T("move"), 0, cmd_move},
-#endif
-
-#ifdef INCLUDE_CMD_MSGBOX
-       {_T("msgbox"), 0, CommandMsgbox},
-#endif
-
-#ifdef INCLUDE_CMD_PATH
-       {_T("path"), 0, cmd_path},
-#endif
-
-#ifdef INCLUDE_CMD_PAUSE
-       {_T("pause"), 0, cmd_pause},
-#endif
-
-#ifdef FEATURE_DIRECTORY_STACK
-       {_T("popd"), 0, CommandPopd},
-#endif
-
-#ifdef INCLUDE_CMD_PROMPT
-       {_T("prompt"), 0, cmd_prompt},
-#endif
-
-#ifdef FEATURE_DIRECTORY_STACK
-       {_T("pushd"), 0, CommandPushd},
-#endif
-
-#ifdef INCLUDE_CMD_RMDIR
-       {_T("rd"), CMD_SPECIAL, cmd_rmdir},
-#endif
-
-#ifdef INCLUDE_CMD_REM
-       {_T("rem"), 0, CommandRem},
-#endif
-
-#ifdef INCLUDE_CMD_RENAME
-       {_T("ren"), 0, cmd_rename},
-       {_T("rename"), 0, cmd_rename},
-#endif
-
-#ifdef INCLUDE_CMD_RMDIR
-       {_T("rmdir"), CMD_SPECIAL, cmd_rmdir},
-#endif
-
-#ifdef INCLUDE_CMD_SCREEN
-       {_T("screen"), 0, CommandScreen},
-#endif
-
-#ifdef INCLUDE_CMD_SET
-       {_T("set"), 0, cmd_set},
-#endif
-
-       {_T("shift"), CMD_BATCHONLY, cmd_shift},
-
-#ifdef INCLUDE_CMD_START
-       {_T("start"), 0, cmd_start},
-#endif
-
-#ifdef INCLUDE_CMD_TIME
-       {_T("time"), 0, cmd_time},
-#endif
-
-#ifdef INCLUDE_CMD_TIMER
-       {_T("timer"), 0, CommandTimer},
-#endif
-
-#ifdef INCLUDE_CMD_TITLE
-       {_T("title"), 0, cmd_title},
-#endif
-
-#ifdef INCLUDE_CMD_TYPE
-       {_T("type"), 0, cmd_type},
-#endif
-
-#ifdef INCLUDE_CMD_VER
-       {_T("ver"), 0, cmd_ver},
-#endif
-
-#ifdef INCLUDE_CMD_VERIFY
-       {_T("verify"), 0, cmd_verify},
-#endif
-
-#ifdef INCLUDE_CMD_VOL
-       {_T("vol"), 0, cmd_vol},
-#endif
-
-#ifdef INCLUDE_CMD_WINDOW
-       {_T("window"), 0, CommandWindow},
-#endif
-
-       {NULL, 0, NULL}
-};
-
-
-VOID PrintCommandList (VOID)
-{
-       LPCOMMAND cmdptr;
-       INT y;
-
-       y = 0;
-       cmdptr = cmds;
-       while (cmdptr->name)
-       {
-               if (!(cmdptr->flags & CMD_HIDE))
-               {
-                       if (++y == 8)
-                       {
-                               ConOutPuts (cmdptr->name);
-                               y = 0;
-                       }
-                       else
-                       {
-                               ConOutPrintf (_T("%-10s"), cmdptr->name);
-                       }
-               }
-
-               cmdptr++;
-       }
-
-       if (y != 0)
-               ConOutChar ('\n');
-}
-
-VOID PrintCommandListDetail (VOID)
-{
-  ConOutResPaging(TRUE,STRING_HELP1);
-       ConOutResPaging(FALSE,STRING_HELP2);
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/cmdver.h b/reactos/subsys/system/cmd/cmdver.h
deleted file mode 100644 (file)
index 93ed1b8..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-#define CMD_VER      "0.1.2"
-#define CMD_VER_RC   CMD_VER"\0"
diff --git a/reactos/subsys/system/cmd/color.c b/reactos/subsys/system/cmd/color.c
deleted file mode 100644 (file)
index 8db6dc7..0000000
+++ /dev/null
@@ -1,137 +0,0 @@
-/*
- *  COLOR.C - color internal command.
- *
- *
- *  History:
- *
- *    13-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Started.
- *
- *    19-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode ready!
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Redirection ready!
- *
- *    14-Oct-1999 (Paolo Pantaleo <paolopan@freemail.it>)
- *        4nt's syntax implemented.
- *
- *    03-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Move all hardcoded strings to En.rc.
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_COLOR
-
-
-
-
-
-VOID SetScreenColor (WORD wColor, BOOL bNoFill)
-{
-       DWORD dwWritten;
-       CONSOLE_SCREEN_BUFFER_INFO csbi;
-       COORD coPos;
-
-
-       if ((wColor & 0xF) == (wColor &0xF0) >> 4)
-       {
-               ConErrResPuts(STRING_COLOR_ERROR1);
-       }
-       else
-       {
-               if (bNoFill != TRUE)
-               {
-                       GetConsoleScreenBufferInfo (hConsole, &csbi);
-
-                       coPos.X = 0;
-                       coPos.Y = 0;
-                       FillConsoleOutputAttribute (hConsole,
-                                                   (WORD)(wColor & 0x00FF),
-                                                   (csbi.dwSize.X)*(csbi.dwSize.Y),
-                                                   coPos,
-                                                   &dwWritten);
-               }
-               SetConsoleTextAttribute (hConsole, (WORD)(wColor & 0x00FF));
-       }
-}
-
-
-/*
- * color
- *
- * internal dir command
- */
-INT CommandColor (LPTSTR first, LPTSTR rest)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-
-       if (_tcsncmp (rest, _T("/?"), 2) == 0)
-       {
-               ConOutResPaging(TRUE,STRING_COLOR_HELP1);
-               return 0;
-       }
-
-       nErrorLevel = 0;
-
-       if (rest[0] == _T('\0'))
-       {
-               /* set default color */
-               wColor = wDefColor;
-               SetScreenColor (wColor, FALSE);
-               return 0;
-       }
-    
-       
-       if ( _tcslen(&rest[0])==1)
-       {        
-         if ( (_tcscmp(&rest[0], _T("0")) >=0 ) && (_tcscmp(&rest[0], _T("9")) <=0 ) )
-         {
-        SetConsoleTextAttribute (hConsole, (WORD)_ttoi(rest));
-               return 0;
-         }      
-         else if ( (_tcscmp(&rest[0], _T("a")) >=0 ) && (_tcscmp(&rest[0], _T("f")) <=0 ) )
-         {        
-       SetConsoleTextAttribute (hConsole, (WORD) (rest[0] + 10 - _T('a')) );
-          return 0;
-         }
-      else if ( (_tcscmp(&rest[0], _T("A")) >=0 ) && (_tcscmp(&rest[0], _T("F")) <=0 ) )
-         {        
-       SetConsoleTextAttribute (hConsole, (WORD) (rest[0] + 10 - _T('A')) );
-          return 0;
-         }
-         ConErrResPuts(STRING_COLOR_ERROR2);
-         nErrorLevel = 1;
-         return 1;
-       }
-
-       if (StringToColor(&wColor, &rest) == FALSE)
-       {       
-               ConErrResPuts(STRING_COLOR_ERROR2);
-               nErrorLevel = 1;
-               return 1;
-       }
-
-       LoadString(CMD_ModuleHandle, STRING_COLOR_ERROR3, szMsg, RC_STRING_MAX_SIZE);
-       ConErrPrintf(szMsg, wColor);
-
-       if ((wColor & 0xF) == (wColor &0xF0) >> 4)
-       {
-               LoadString(CMD_ModuleHandle, STRING_COLOR_ERROR4, szMsg, RC_STRING_MAX_SIZE);
-               ConErrPrintf(szMsg, wColor);
-               nErrorLevel = 1;
-               return 1;
-       }
-
-       /* set color */
-       SetScreenColor(wColor,
-                      (_tcsstr (rest,_T("/-F")) || _tcsstr (rest,_T("/-f"))));
-
-       return 0;
-}
-
-#endif /* INCLUDE_CMD_COLOR */
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/config.h b/reactos/subsys/system/cmd/config.h
deleted file mode 100644 (file)
index 356af14..0000000
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- *  CONFIG.H - Used to configure what will be compiled into the shell.
- *
- *
- *  History:
- *
- *    27 Jul 1998 - John P. Price
- *        started.
- *
- */
-
-/* Define only if used under ReactOS */
-#define __REACTOS__
-
-#ifndef _CONFIG_H_INCLUDED_
-#define _CONFIG_H_INCLUDED_
-
-/* Define to enable debugging code */
-//#define _DEBUG
-
-#define WIN32_LEAN_AND_MEAN
-
-//#define NT4_INTERNAL_COMMANDS
-
-/* Define to enable the alias command, and aliases.*/
-#define FEATURE_ALIASES
-
-
-/* Define to enable history */
-#define FEATURE_HISTORY
-
-/*Define to enable history wrap (4nt's style)*/
-#define WRAP_HISTORY
-
-
-/* Define one of these to enable filename completion */
-//#define FEATURE_UNIX_FILENAME_COMPLETION
-#define FEATURE_4NT_FILENAME_COMPLETION
-
-
-/* Define to enable the directory stack */
-#define FEATURE_DIRECTORY_STACK
-
-
-/* Define to activate redirections and piping */
-#define FEATURE_REDIRECTION
-
-
-/* Define one of these to select the used locale. */
-/*  (date and time formats etc.) used in DATE, TIME, */
-/*  DIR, PROMPT etc. */
-#define LOCALE_WINDOWS   /* System locale */
-/* #define LOCALE_GERMAN */    /* German locale */
-/* #define LOCALE_DEFAULT */   /* United States locale */
-
-#ifdef NT4_INTERNAL_COMMANDS
-#define INCLUDE_CMD_ACTIVATE
-#endif
-#define INCLUDE_CMD_ATTRIB
-#define INCLUDE_CMD_CHCP
-#define INCLUDE_CMD_CHDIR
-#define INCLUDE_CMD_CHOICE
-#define INCLUDE_CMD_CLS
-#define INCLUDE_CMD_COLOR
-#define INCLUDE_CMD_COPY
-#define INCLUDE_CMD_DATE
-#define INCLUDE_CMD_DEL
-#define INCLUDE_CMD_DELAY
-#define INCLUDE_CMD_DIR
-#define INCLUDE_CMD_FREE
-#define INCLUDE_CMD_LABEL
-#define INCLUDE_CMD_MEMORY
-#define INCLUDE_CMD_MKDIR
-#define INCLUDE_CMD_MOVE
-#ifdef NT4_INTERNAL_COMMANDS
-#define INCLUDE_CMD_MSGBOX
-#endif
-#define INCLUDE_CMD_PATH
-#define INCLUDE_CMD_PROMPT
-#define INCLUDE_CMD_RMDIR
-#define INCLUDE_CMD_RENAME
-#define INCLUDE_CMD_SCREEN
-#define INCLUDE_CMD_SET
-#define INCLUDE_CMD_START
-#define INCLUDE_CMD_TIME
-#define INCLUDE_CMD_TIMER
-#define INCLUDE_CMD_TITLE
-#define INCLUDE_CMD_TYPE
-#define INCLUDE_CMD_VER
-#define INCLUDE_CMD_REM
-#define INCLUDE_CMD_PAUSE
-#define INCLUDE_CMD_BEEP
-#define INCLUDE_CMD_VERIFY
-#define INCLUDE_CMD_VOL
-#ifdef NT4_INTERNAL_COMMANDS
-#define INCLUDE_CMD_WINDOW
-#endif
-
-#endif /* _CONFIG_H_INCLUDED_ */
diff --git a/reactos/subsys/system/cmd/console.c b/reactos/subsys/system/cmd/console.c
deleted file mode 100644 (file)
index 352a64e..0000000
+++ /dev/null
@@ -1,527 +0,0 @@
-/*
- *  CONSOLE.C - console input/output functions.
- *
- *
- *  History:
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        started
- *
- *    03-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- *
- *    01-Jul-2005 (Brandon Turner) <turnerb7@msu.edu>)
- *        Added ConPrintfPaging and ConOutPrintfPaging
- */
-#include <precomp.h>
-#include "resource.h"
-#define OUTPUT_BUFFER_SIZE  4096
-UINT InputCodePage;
-UINT OutputCodePage;
-VOID ConInDisable (VOID)
-{
-       HANDLE hInput = GetStdHandle (STD_INPUT_HANDLE);
-       DWORD dwMode;
-       GetConsoleMode (hInput, &dwMode);
-       dwMode &= ~ENABLE_PROCESSED_INPUT;
-       SetConsoleMode (hInput, dwMode);
-}
-VOID ConInEnable (VOID)
-{
-       HANDLE hInput = GetStdHandle (STD_INPUT_HANDLE);
-       DWORD dwMode;
-       GetConsoleMode (hInput, &dwMode);
-       dwMode |= ENABLE_PROCESSED_INPUT;
-       SetConsoleMode (hInput, dwMode);
-}
-VOID ConInDummy (VOID)
-{
-       HANDLE hInput = GetStdHandle (STD_INPUT_HANDLE);
-       INPUT_RECORD dummy;
-       DWORD  dwRead;
-#ifdef _DEBUG
-       if (hInput == INVALID_HANDLE_VALUE)
-               DebugPrintf (_T("Invalid input handle!!!\n"));
-#endif /* _DEBUG */
-       ReadConsoleInput (hInput, &dummy, 1, &dwRead);
-}
-VOID ConInFlush (VOID)
-{
-       FlushConsoleInputBuffer (GetStdHandle (STD_INPUT_HANDLE));
-}
-VOID ConInKey (PINPUT_RECORD lpBuffer)
-{
-       HANDLE hInput = GetStdHandle (STD_INPUT_HANDLE);
-       DWORD  dwRead;
-#ifdef _DEBUG
-       if (hInput == INVALID_HANDLE_VALUE)
-               DebugPrintf (_T("Invalid input handle!!!\n"));
-#endif /* _DEBUG */
-       do
-       {
-               ReadConsoleInput (hInput, lpBuffer, 1, &dwRead);
-               if ((lpBuffer->EventType == KEY_EVENT) &&
-                       (lpBuffer->Event.KeyEvent.bKeyDown == TRUE))
-                       break;
-       }
-       while (TRUE);
-}
-VOID ConInString (LPTSTR lpInput, DWORD dwLength)
-{
-       DWORD dwOldMode;
-       DWORD dwRead;
-       HANDLE hFile;
-       LPTSTR p;
-       DWORD  i;
-       PCHAR pBuf;
-#ifdef _UNICODE
-       pBuf = (PCHAR)malloc(dwLength);
-#else
-       pBuf = lpInput;
-#endif
-       ZeroMemory (lpInput, dwLength * sizeof(TCHAR));
-       hFile = GetStdHandle (STD_INPUT_HANDLE);
-       GetConsoleMode (hFile, &dwOldMode);
-       SetConsoleMode (hFile, ENABLE_LINE_INPUT | ENABLE_ECHO_INPUT);
-       ReadFile (hFile, (PVOID)pBuf, dwLength, &dwRead, NULL);
-#ifdef _UNICODE
-       MultiByteToWideChar(  InputCodePage, 0, pBuf, dwLength + 1, lpInput, dwLength + 1);
-#endif
-       p = lpInput;
-       for (i = 0; i < dwRead; i++, p++)
-       {
-               if (*p == _T('\x0d'))
-               {
-                       *p = _T('\0');
-                       break;
-               }
-       }
-#ifdef _UNICODE
-       free(pBuf);
-#endif
-       SetConsoleMode (hFile, dwOldMode);
-}
-static VOID ConChar(TCHAR c, DWORD nStdHandle)
-{
-       DWORD dwWritten;
-       CHAR cc;
-#ifdef _UNICODE
-       CHAR as[2];
-       WCHAR ws[2];
-       ws[0] = c;
-       ws[1] = 0;
-       WideCharToMultiByte( OutputCodePage, 0, ws, 2, as, 2, NULL, NULL);
-       cc = as[0];
-#else
-       cc = c;
-#endif
-       WriteFile (GetStdHandle (nStdHandle),
-                  &cc,
-                  1,
-                  &dwWritten,
-                  NULL);
-}
-VOID ConOutChar (TCHAR c)
-{
-       ConChar(c, STD_OUTPUT_HANDLE);
-}
-VOID ConPuts(LPTSTR szText, DWORD nStdHandle)
-{
-       DWORD dwWritten;
-       PCHAR pBuf;
-       INT len;
-       len = _tcslen(szText);
-#ifdef _UNICODE
-       pBuf = malloc(len + 1);
-       len = WideCharToMultiByte( OutputCodePage, 0, szText, len + 1, pBuf, len + 1, NULL, NULL) - 1;
-#else
-       pBuf = szText;
-#endif
-       WriteFile (GetStdHandle (nStdHandle),
-                  pBuf,
-                  len,
-                  &dwWritten,
-                  NULL);
-       WriteFile (GetStdHandle (nStdHandle),
-                  _T("\n"),
-                  1,
-                  &dwWritten,
-                  NULL);
-#ifdef UNICODE
-       free(pBuf);
-#endif
-}
-VOID ConOutResPaging(BOOL NewPage, UINT resID)
-{
-  TCHAR szMsg[RC_STRING_MAX_SIZE];
-  LoadString(CMD_ModuleHandle, resID, szMsg, RC_STRING_MAX_SIZE);
-  ConOutPrintfPaging(NewPage, szMsg);
-}
-VOID ConOutResPuts (UINT resID)
-{
-  TCHAR szMsg[RC_STRING_MAX_SIZE];
-  LoadString(CMD_ModuleHandle, resID, szMsg, RC_STRING_MAX_SIZE);
-  ConPuts(szMsg, STD_OUTPUT_HANDLE);
-}
-VOID ConOutPuts (LPTSTR szText)
-{
-       ConPuts(szText, STD_OUTPUT_HANDLE);
-}
-VOID ConPrintf(LPTSTR szFormat, va_list arg_ptr, DWORD nStdHandle)
-{
-       INT len;
-       PCHAR pBuf;
-       TCHAR szOut[OUTPUT_BUFFER_SIZE];
-       DWORD dwWritten;
-       len = _vstprintf (szOut, szFormat, arg_ptr);
-#ifdef _UNICODE
-       pBuf = malloc(len + 1);
-       len = WideCharToMultiByte( OutputCodePage, 0, szOut, len + 1, pBuf, len + 1, NULL, NULL) - 1;
-#else
-       pBuf = szOut;
-#endif
-       WriteFile (GetStdHandle (nStdHandle),
-                  pBuf,
-                  len,
-                  &dwWritten,
-                  NULL);
-#ifdef UNICODE
-       free(pBuf);
-#endif
-}
-INT ConPrintfPaging(BOOL NewPage, LPTSTR szFormat, va_list arg_ptr, DWORD nStdHandle)
-{
-       INT len;
-       PCHAR pBuf;
-       CONSOLE_SCREEN_BUFFER_INFO csbi;
-       TCHAR szOut[OUTPUT_BUFFER_SIZE];
-       DWORD dwWritten;
-  /* used to count number of lines since last pause */
-       static int LineCount = 0;
-  /* used to see how big the screen is */
-       int ScreenLines = 0;  
-  /* the number of chars in a roow */
-       int ScreenCol = 0;  
-  /* chars since end of line */
-       int CharEL = 0; 
-       int i = 0;
-       if(NewPage == TRUE)
-               LineCount = 0;
-  /* rest LineCount and return if no string have been given */
-        if (szFormat == NULL)
-                return 0;
-       //get the size of the visual screen that can be printed too
-       if (!GetConsoleScreenBufferInfo(hConsole, &csbi))
-        {
-                // we assuming its a file handle
-                ConPrintf(szFormat, arg_ptr, nStdHandle);
-                return 0;
-        }
-       //subtract 2 to account for "press any key..." and for the blank line at the end of PagePrompt()
-       ScreenLines = (csbi.srWindow.Bottom  - csbi.srWindow.Top) - 4;
-       ScreenCol = (csbi.srWindow.Right - csbi.srWindow.Left) + 1;
-       //make sure they didnt make the screen to small 
-       if(ScreenLines<4)
-        {
-               ConPrintf(szFormat, arg_ptr, nStdHandle);
-                return 0;
-        }
-       len = _vstprintf (szOut, szFormat, arg_ptr);
-#ifdef _UNICODE
-       pBuf = malloc(len + 1);
-       len = WideCharToMultiByte( OutputCodePage, 0, szOut, len + 1, pBuf, len + 1, NULL, NULL) - 1;
-#else
-       pBuf = szOut;
-#endif
-       for(i = 0; i < len; i++)
-       { 
-                if(pBuf[i] == _T('\n'))
-               {                               
-                       LineCount++; 
-                        CharEL=0;
-               }      
-                else
-                {      
-                        CharEL++;           
-                        if (CharEL>=ScreenCol)
-                        {        
-                                if (i+1<len)
-                                {
-                                        if(pBuf[i+1] != _T('\n')) LineCount++;          
-                                }
-                                CharEL=0;
-                        }
-                }
-                /* FIXME : write more that one char at time */
-                WriteFile (GetStdHandle (nStdHandle),&pBuf[i],sizeof(CHAR),&dwWritten,NULL);
-               if(LineCount >= ScreenLines)
-               {
-                        if(_tcsnicmp(&pBuf[i], _T("\n"), 2)!=0)
-                        WriteFile (GetStdHandle (nStdHandle),_T("\n"),sizeof(CHAR),&dwWritten,NULL); 
-                       if(PagePrompt() != PROMPT_YES)
-                       {
-                               return 1;
-                       }
-                       //reset the number of lines being printed         
-                       LineCount = 0;
-                        CharEL=0;
-               }
-       }
-#ifdef UNICODE
-       free(pBuf);
-#endif
-       return 0;
-}
-VOID ConErrFormatMessage (DWORD MessageId, ...)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       DWORD ret;
-       LPTSTR text;
-       va_list arg_ptr;
-       va_start (arg_ptr, MessageId);
-       ret = FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM,
-              NULL,
-              MessageId,
-              MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
-              (LPTSTR) &text,
-              0,
-              &arg_ptr);
-       va_end (arg_ptr);
-       if(ret > 0)
-       {
-               ConErrPuts (text);
-               LocalFree(text);
-       }
-       else
-       {
-               LoadString(CMD_ModuleHandle, STRING_CONSOLE_ERROR, szMsg, RC_STRING_MAX_SIZE);
-               ConErrPrintf(szMsg);
-       }
-}
-VOID ConOutFormatMessage (DWORD MessageId, ...)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       DWORD ret;
-       LPTSTR text;
-       va_list arg_ptr;
-       va_start (arg_ptr, MessageId);
-       ret = FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM,
-              NULL,
-              MessageId,
-              MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
-              (LPTSTR) &text,
-              0,
-              &arg_ptr);
-       va_end (arg_ptr);
-       if(ret > 0)
-       {
-               ConErrPuts (text);
-               LocalFree(text);
-       }
-       else
-       {
-               LoadString(CMD_ModuleHandle, STRING_CONSOLE_ERROR, szMsg, RC_STRING_MAX_SIZE);
-               ConErrPrintf(szMsg);
-       }
-}
-VOID ConOutPrintf (LPTSTR szFormat, ...)
-{
-       va_list arg_ptr;
-       va_start (arg_ptr, szFormat);
-       ConPrintf(szFormat, arg_ptr, STD_OUTPUT_HANDLE);
-       va_end (arg_ptr);
-}
-INT ConOutPrintfPaging (BOOL NewPage, LPTSTR szFormat, ...)
-{
-       INT iReturn;
-       va_list arg_ptr;
-       va_start (arg_ptr, szFormat);
-       iReturn = ConPrintfPaging(NewPage, szFormat, arg_ptr, STD_OUTPUT_HANDLE);
-       va_end (arg_ptr);
-       return iReturn;
-}
-VOID ConErrChar (TCHAR c)
-{
-       ConChar(c, STD_ERROR_HANDLE);
-}
-VOID ConErrResPuts (UINT resID)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-    LoadString(CMD_ModuleHandle, resID, szMsg, RC_STRING_MAX_SIZE);
-       ConPuts(szMsg, STD_ERROR_HANDLE);
-}
-VOID ConErrPuts (LPTSTR szText)
-{
-       ConPuts(szText, STD_ERROR_HANDLE);
-}
-VOID ConErrPrintf (LPTSTR szFormat, ...)
-{
-       va_list arg_ptr;
-       va_start (arg_ptr, szFormat);
-       ConPrintf(szFormat, arg_ptr, STD_ERROR_HANDLE);
-       va_end (arg_ptr);
-}
-#ifdef _DEBUG
-VOID DebugPrintf (LPTSTR szFormat, ...)
-{
-       va_list arg_ptr;
-       va_start (arg_ptr, szFormat);
-       ConPrintf(szFormat, arg_ptr, STD_ERROR_HANDLE);
-       va_end (arg_ptr);
-#if 0
-       TCHAR szOut[OUTPUT_BUFFER_SIZE];
-       va_start (arg_ptr, szFormat);
-       _vstprintf (szOut, szFormat, arg_ptr);
-       OutputDebugString (szOut);
-       va_end (arg_ptr);
-#endif
-}
-#endif /* _DEBUG */
-VOID SetCursorXY (SHORT x, SHORT y)
-{
-       COORD coPos;
-       coPos.X = x;
-       coPos.Y = y;
-       SetConsoleCursorPosition (GetStdHandle (STD_OUTPUT_HANDLE), coPos);
-}
-VOID GetCursorXY (PSHORT x, PSHORT y)
-{
-       CONSOLE_SCREEN_BUFFER_INFO csbi;
-       GetConsoleScreenBufferInfo (hConsole, &csbi);
-       *x = csbi.dwCursorPosition.X;
-       *y = csbi.dwCursorPosition.Y;
-}
-SHORT GetCursorX (VOID)
-{
-       CONSOLE_SCREEN_BUFFER_INFO csbi;
-       GetConsoleScreenBufferInfo (hConsole, &csbi);
-       return csbi.dwCursorPosition.X;
-}
-SHORT GetCursorY (VOID)
-{
-       CONSOLE_SCREEN_BUFFER_INFO csbi;
-       GetConsoleScreenBufferInfo (hConsole, &csbi);
-       return csbi.dwCursorPosition.Y;
-}
-VOID GetScreenSize (PSHORT maxx, PSHORT maxy)
-{
-       CONSOLE_SCREEN_BUFFER_INFO csbi;
-       GetConsoleScreenBufferInfo (hConsole, &csbi);
-       if (maxx)
-               *maxx = csbi.dwSize.X;
-       if (maxy)
-               *maxy = csbi.dwSize.Y;
-}
-VOID SetCursorType (BOOL bInsert, BOOL bVisible)
-{
-       CONSOLE_CURSOR_INFO cci;
-       cci.dwSize = bInsert ? 10 : 99;
-       cci.bVisible = bVisible;
-       SetConsoleCursorInfo (GetStdHandle (STD_OUTPUT_HANDLE), &cci);
-}
-/* EOF */
diff --git a/reactos/subsys/system/cmd/copy.c b/reactos/subsys/system/cmd/copy.c
deleted file mode 100644 (file)
index a54b875..0000000
+++ /dev/null
@@ -1,888 +0,0 @@
-/*
- *  COPY.C -- copy internal command.
- *
- *
- *  History:
- *
- *    01-Aug-98 (Rob Lake z63rrl@morgan.ucs.mun.ca)
- *        started
- *
- *    13-Aug-1998 (John P. Price)
- *        fixed memory leak problem in copy function.
- *        fixed copy function so it would work with wildcards in the source
- *
- *    13-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added COPY command to CMD.
- *
- *    26-Jan-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Replaced CRT io functions by Win32 io functions.
- *
- *    27-Oct-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Disabled prompting when used in batch mode.
- *
- *    03-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- *
- *    13-Jul-2005 (Brandon Turner) <turnerb7@msu.edu>)
- *        Rewrite to clean up copy and support wildcard.
- *
- *    20-Jul-2005 (Brandon Turner) <turnerb7@msu.edu>)
- *        Add touch syntax.  "copy arp.exe+,,"
- *        Copy command is now completed.
- */
-#include <precomp.h>
-#include "resource.h"
-#ifdef INCLUDE_CMD_COPY
-enum
-{
-       COPY_ASCII       = 0x001,   /* /A  */
-       COPY_DECRYPT     = 0x004,   /* /D  */
-       COPY_VERIFY      = 0x008,   /* /V  : Dummy, Never will be Impleneted */
-       COPY_SHORTNAME   = 0x010,   /* /N  : Dummy, Never will be Impleneted */
-       COPY_NO_PROMPT   = 0x020,   /* /Y  */
-       COPY_PROMPT      = 0x040,   /* /-Y */
-       COPY_RESTART     = 0x080,   /* /Z  */
-       COPY_BINARY      = 0x100,   /* /B  */
-};
-#define BUFF_SIZE 16384         /* 16k = max buffer size */
-INT 
-copy (TCHAR source[MAX_PATH], 
-         TCHAR dest[MAX_PATH], 
-         INT append, 
-         DWORD lpdwFlags, 
-         BOOL bTouch)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       FILETIME srctime,NewFileTime;
-       HANDLE hFileSrc;
-       HANDLE hFileDest;
-       LPBYTE buffer;
-       DWORD  dwAttrib;
-       DWORD  dwRead;
-       DWORD  dwWritten;
-       DWORD  i;
-       BOOL   bEof = FALSE;
-       TCHAR TrueDest[MAX_PATH];
-       TCHAR TempSrc[MAX_PATH];
-       TCHAR * FileName;
-       SYSTEMTIME CurrentTime;
-       /* Check Breaker */
-       if(CheckCtrlBreak(BREAK_INPUT))
-               return 0;
-
-#ifdef _DEBUG
-       DebugPrintf (_T("checking mode\n"));
-#endif
-       if(bTouch)
-       {
-       hFileSrc = CreateFile (source, GENERIC_WRITE, FILE_SHARE_READ,
-               NULL, OPEN_EXISTING, 0, NULL);
-       if (hFileSrc == INVALID_HANDLE_VALUE)
-       {
-               LoadString(CMD_ModuleHandle, STRING_COPY_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-               ConOutPrintf(szMsg, source);
-        nErrorLevel = 1;
-               return 0;
-       }
-
-               GetSystemTime(&CurrentTime);
-               SystemTimeToFileTime(&CurrentTime, &NewFileTime);
-               if(SetFileTime(hFileSrc,(LPFILETIME) NULL, (LPFILETIME) NULL, &NewFileTime))
-               {
-                       CloseHandle(hFileSrc);
-                       nErrorLevel = 1;
-                       return 1;
-
-               }
-               else
-               {
-                       CloseHandle(hFileSrc);
-                       return 0;
-               }
-       }
-
-       dwAttrib = GetFileAttributes (source);
-       hFileSrc = CreateFile (source, GENERIC_READ, FILE_SHARE_READ,
-               NULL, OPEN_EXISTING, 0, NULL);
-       if (hFileSrc == INVALID_HANDLE_VALUE)
-       {
-               LoadString(CMD_ModuleHandle, STRING_COPY_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-               ConOutPrintf(szMsg, source);
-        nErrorLevel = 1;
-               return 0;
-       }
-
-#ifdef _DEBUG
-       DebugPrintf (_T("getting time\n"));
-#endif
-       GetFileTime (hFileSrc, &srctime, NULL, NULL);
-#ifdef _DEBUG
-       DebugPrintf (_T("copy: flags has %s\n"),
-               lpdwFlags & COPY_ASCII ? "ASCII" : "BINARY");
-#endif
-       /* Check to see if /D or /Z are true, if so we need a middle
-          man to copy the file too to allow us to use CopyFileEx later */
-       if(lpdwFlags & COPY_DECRYPT)
-       {
-               GetEnvironmentVariable(_T("TEMP"),TempSrc,MAX_PATH);
-               _tcscat(TempSrc,_T("\\"));
-               FileName = _tcsrchr(source,_T('\\'));
-               FileName++;
-               _tcscat(TempSrc,FileName);
-               /* This is needed to be on the end to prevent an error
-                  if the user did "copy /D /Z foo bar then it would be copied
-                  too %TEMP%\foo here and when %TEMP%\foo when it sets it up
-                  for COPY_RESTART, this would mean it is copying to itself
-                  which would error when it tried to open the handles for ReadFile
-                  and WriteFile */
-               _tcscat(TempSrc,_T(".decrypt"));
-               if(!CopyFileEx(source, TempSrc, NULL, NULL, FALSE, COPY_FILE_ALLOW_DECRYPTED_DESTINATION))
-               {
-                  nErrorLevel = 1;
-                  return 0;
-               }
-               _tcscpy(source, TempSrc);
-       }
-
-
-       if(lpdwFlags & COPY_RESTART)
-       {
-               _tcscpy(TrueDest, dest);
-               GetEnvironmentVariable(_T("TEMP"),dest,MAX_PATH);
-               _tcscat(dest,_T("\\"));
-               FileName = _tcsrchr(TrueDest,_T('\\'));
-               FileName++;
-               _tcscat(dest,FileName);
-       }
-
-
-
-       if (!IsExistingFile (dest))
-       {
-#ifdef _DEBUG
-               DebugPrintf (_T("opening/creating\n"));
-#endif
-               hFileDest =
-                       CreateFile (dest, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, 0, NULL);
-       }
-       else if (!append)
-       {
-               if (!_tcscmp (dest, source))
-               {
-                       LoadString(CMD_ModuleHandle, STRING_COPY_ERROR2, szMsg, RC_STRING_MAX_SIZE);
-                       ConOutPrintf(szMsg, source);
-                       CloseHandle (hFileSrc);
-            nErrorLevel = 1;
-                       return 0;
-               }
-#ifdef _DEBUG
-               DebugPrintf (_T("SetFileAttributes (%s, FILE_ATTRIBUTE_NORMAL);\n"), dest);
-#endif
-               SetFileAttributes (dest, FILE_ATTRIBUTE_NORMAL);
-#ifdef _DEBUG
-               DebugPrintf (_T("DeleteFile (%s);\n"), dest);
-#endif
-               DeleteFile (dest);
-               hFileDest =     CreateFile (dest, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, 0, NULL);
-       }
-       else
-       {
-               LONG lFilePosHigh = 0;
-               if (!_tcscmp (dest, source))
-               {
-                       CloseHandle (hFileSrc);
-                       return 0;
-               }
-#ifdef _DEBUG
-               DebugPrintf (_T("opening/appending\n"));
-#endif
-               SetFileAttributes (dest, FILE_ATTRIBUTE_NORMAL);
-               hFileDest =
-                       CreateFile (dest, GENERIC_WRITE, 0, NULL, OPEN_EXISTING, 0, NULL);
-               /* Move to end of file to start writing */
-               SetFilePointer (hFileDest, 0, &lFilePosHigh,FILE_END);
-       }
-               if (hFileDest == INVALID_HANDLE_VALUE)
-       {
-               CloseHandle (hFileSrc);
-               ConOutResPuts(STRING_ERROR_PATH_NOT_FOUND);
-        nErrorLevel = 1;
-               return 0;
-       }
-       buffer = (LPBYTE)malloc (BUFF_SIZE);
-       if (buffer == NULL)
-       {
-               CloseHandle (hFileDest);
-               CloseHandle (hFileSrc);
-               ConOutResPuts(STRING_ERROR_OUT_OF_MEMORY);
-        nErrorLevel = 1;
-               return 0;
-       }
-       do
-       {
-
-               ReadFile (hFileSrc, buffer, BUFF_SIZE, &dwRead, NULL);
-               if (lpdwFlags & COPY_ASCII)
-               {
-                       for (i = 0; i < dwRead; i++)
-                       {
-                               /* we're dealing with ASCII files! */
-                               if (((LPSTR)buffer)[i] == 0x1A)
-                               {
-                                       bEof = TRUE;
-                                       break;
-                               }
-                       }
-                       dwRead = i;
-               }
-               if (dwRead == 0)
-                       break;
-               WriteFile (hFileDest, buffer, dwRead, &dwWritten, NULL);
-               if (dwWritten != dwRead || CheckCtrlBreak(BREAK_INPUT))
-               {
-                       ConOutResPuts(STRING_COPY_ERROR3);
-                       free (buffer);
-                       CloseHandle (hFileDest);
-                       CloseHandle (hFileSrc);
-                       nErrorLevel = 1;
-                       return 0;
-               }
-       }
-       while (dwRead && !bEof);
-#ifdef _DEBUG
-       DebugPrintf (_T("setting time\n"));
-#endif
-       SetFileTime (hFileDest, &srctime, NULL, NULL);
-       if (lpdwFlags & COPY_ASCII)
-       {
-               /* we're dealing with ASCII files! */
-               ((LPSTR)buffer)[0] = 0x1A;
-               ((LPSTR)buffer)[1] = '\0';
-#ifdef _DEBUG
-               DebugPrintf (_T("appending ^Z\n"));
-#endif
-               WriteFile (hFileDest, buffer, sizeof(CHAR), &dwWritten, NULL);
-       }
-       free (buffer);
-       CloseHandle (hFileDest);
-       CloseHandle (hFileSrc);
-#ifdef _DEBUG
-       DebugPrintf (_T("setting mode\n"));
-#endif
-       SetFileAttributes (dest, dwAttrib);
-       /* Now finish off the copy if needed with CopyFileEx */
-       if(lpdwFlags & COPY_RESTART)
-       {
-               if(!CopyFileEx(dest, TrueDest, NULL, NULL, FALSE, COPY_FILE_RESTARTABLE))
-               {
-                  nErrorLevel = 1;
-                  DeleteFile(dest);
-           return 0;                   
-               }
-               /* Take care of file in the temp folder */
-               DeleteFile(dest);
-
-       }
-
-       if(lpdwFlags & COPY_DECRYPT)
-          DeleteFile(TempSrc);
-
-
-
-       return 1;
-}
-static INT CopyOverwrite (LPTSTR fn)
-{
-       /*ask the user if they want to override*/
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       INT res;
-       LoadString(CMD_ModuleHandle, STRING_COPY_HELP1, szMsg, RC_STRING_MAX_SIZE);
-       ConOutPrintf(szMsg,fn);
-       res = FilePromptYNA (_T(""));
-       return res;
-}
-INT cmd_copy (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       LPTSTR *arg;
-       INT argc, i, nFiles, nOverwrite = 0, nSrc = -1, nDes = -1;
-       /* this is the path up to the folder of the src and dest ie C:\windows\ */
-       TCHAR szDestPath[MAX_PATH];
-       TCHAR szSrcPath[MAX_PATH];
-       DWORD dwFlags = 0;
-       /* If this is the type of copy where we are adding files */
-       BOOL bAppend = FALSE;
-       WIN32_FIND_DATA findBuffer;
-       HANDLE hFile;
-       BOOL bTouch = FALSE;
-       /* Used when something like "copy c*.exe d*.exe" during the process of
-          figuring out the new name */
-       TCHAR tmpName[MAX_PATH] = _T("");
-       /* Pointer to keep track of how far through the append input(file1+file2+file3) we are */
-       TCHAR  * appendPointer = _T("\0");
-       /* The full path to src and dest.  This has drive letter, folders, and filename */
-       TCHAR tmpDestPath[MAX_PATH];
-       TCHAR tmpSrcPath[MAX_PATH];
-       /* A bool on weather or not the destination name will be taking from the input */
-       BOOL bSrcName = FALSE;
-       /* Seems like a waste but it is a pointer used to copy from input to PreserveName */
-       TCHAR * UseThisName;
-       /* Stores the name( i.e. blah.txt or blah*.txt) which later we might need */
-       TCHAR PreserveName[MAX_PATH];
-   /* for CMDCOPY env */
-   TCHAR *evar;
-   int size;
-       TCHAR * szTouch;
-       BOOL bDone = FALSE;
-       
-  /*Show help/usage info*/
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE, STRING_COPY_HELP2);
-               return 0;
-       }
-  nErrorLevel = 0;
-
-  /* Get the envor value if it exists */
-  evar = malloc(512 * sizeof(TCHAR));
-  if (evar==NULL) size = 0;
-  else
-  {
-   size = GetEnvironmentVariable (_T("COPYCMD"), evar, 512);  
-  }
-  if (size > 512)
-  {
-    evar = realloc(evar,size * sizeof(TCHAR) );
-    if (evar!=NULL)
-    {             
-      size = GetEnvironmentVariable (_T("COPYCMD"), evar, size);
-      }
-    else 
-    {
-      size=0;
-    }
-  }
-
-  /* check see if we did get any env variable */
-  if (size !=0)
-  {
-    int t=0;
-    /* scan and set the flags */
-    for (t=0;t<size;t++)
-    {
-      if (_tcsncicmp(_T("/A"),&evar[t],2)==0) 
-      {
-        dwFlags |=COPY_ASCII;
-        t++;
-      }
-
-      else if (_tcsncicmp(_T("/B"),&evar[t],2)==0) 
-      {
-        dwFlags |= COPY_BINARY;
-        t++;
-      }
-      else if (_tcsncicmp(_T("/D"),&evar[t],2)==0) 
-      {
-        dwFlags |= COPY_DECRYPT;
-        t++;
-      }
-
-                       else if (_tcsncicmp(_T("/V"),&evar[t],2)==0) 
-      {
-        dwFlags |= COPY_VERIFY;
-        t++;
-      }
-
-                       else if (_tcsncicmp(_T("/N"),&evar[t],2)==0) 
-      {
-        dwFlags |= COPY_SHORTNAME;
-        t++;
-      }
-      else if (_tcsncicmp(_T("/Y"),&evar[t],2)==0) 
-      {
-        dwFlags |= COPY_NO_PROMPT;
-        t++;
-      }
-
-      else if (_tcsncicmp(_T("/-Y"),&evar[t],3)==0) 
-      {
-        dwFlags |= COPY_PROMPT;
-        t+=2;
-      }
-
-      else if (_tcsncicmp(_T("/Z"),&evar[t],2)==0) 
-      {
-        dwFlags |= COPY_PROMPT;
-        t++;
-      }
-    }
-  }
-  free(evar);
-
-
-  /*Split the user input into array*/
-       arg = split (param, &argc, FALSE);
-       nFiles = argc;
-       /*Read switches and count files*/
-       for (i = 0; i < argc; i++)
-       {
-               if (*arg[i] == _T('/'))
-               {
-                       if (_tcslen(arg[i]) >= 2)
-                       {
-                               switch (_totupper(arg[i][1]))
-                               {
-                               case _T('A'):
-                                       dwFlags |= COPY_ASCII;
-                                       break;
-                               case _T('B'):
-                                       dwFlags |= COPY_BINARY;
-                                       break;
-                               case _T('D'):
-                                       dwFlags |= COPY_DECRYPT;
-                                       break;
-                               case _T('V'):
-                                       dwFlags |= COPY_VERIFY;
-                                       break;
-                               case _T('N'):
-                                       dwFlags |= COPY_SHORTNAME;
-                                       break;
-                               case _T('Y'):
-                                       dwFlags |= COPY_NO_PROMPT;
-                                       dwFlags &= ~COPY_PROMPT;
-                                       break;
-                               case _T('-'):
-                                       if(_tcslen(arg[i]) >= 3)
-                                               if(_totupper(arg[i][2]) == _T('Y'))
-                                               {
-                                                       dwFlags &= ~COPY_NO_PROMPT;
-                                                       dwFlags |= COPY_PROMPT;
-                                               }
-                                               break;
-                               case _T('Z'):
-                                       dwFlags |= COPY_RESTART;
-                                       break;
-                               default:
-                                       /* invaild switch */
-                    LoadString(CMD_ModuleHandle, STRING_ERROR_INVALID_SWITCH, szMsg, RC_STRING_MAX_SIZE);
-                       ConOutPrintf(szMsg, _totupper(arg[i][1]));                                      
-                                       nErrorLevel = 1;
-                                       return 1;
-                                       break;
-                               }
-                       }
-                       /*If it was a switch, subtract from total arguments*/
-                       nFiles--;
-               }
-               else
-               {
-                       /*if it isnt a switch then it is the source or destination*/
-                       if(nSrc == -1)
-                       {
-                               nSrc = i;
-                       }
-                       else if(*arg[i] == _T('+') || *arg[i] == _T(','))
-                       {
-                               /* Add these onto the source string
-                                  this way we can do all checks
-                                       directly on source string later on */
-                               _tcscat(arg[nSrc],arg[i]);
-                               nFiles--;
-                       }                               
-                       else if(nDes == -1)
-                       {
-                               nDes = i;
-                       }
-               }
-       }
-       /* keep quiet within batch files */
-       if (bc != NULL)
-        {
-               dwFlags |= COPY_NO_PROMPT;
-               dwFlags &= ~COPY_PROMPT;
-        }
-
-       if(nFiles < 1)
-       {
-               /* There is not enough files, there has to be at least 1 */
-               ConOutResPuts(STRING_ERROR_REQ_PARAM_MISSING);
-               freep (arg);
-               return 1;
-       }
-       if(nFiles > 2)
-       {
-               /* there is too many file names in command */
-        LoadString(CMD_ModuleHandle, STRING_ERROR_TOO_MANY_PARAMETERS, szMsg, RC_STRING_MAX_SIZE);
-           ConErrPrintf(szMsg,_T(""));         
-        nErrorLevel = 1;
-               freep (arg);
-               return 1;
-       }
-       if(((_tcschr (arg[nSrc], _T('+')) != NULL) ||
-               (_tcschr (arg[nSrc], _T('*')) != NULL && _tcschr (arg[nDes], _T('*')) == NULL) ||
-               (IsExistingDirectory (arg[nSrc]) && (_tcschr (arg[nDes], _T('*')) == NULL && !IsExistingDirectory (arg[nDes])))
-               ))
-       {
-               /* There is a + in the source filename, this means
-               that there is more then one file being put into
-               one file. */
-               bAppend = TRUE;
-               if(_tcschr (arg[nSrc], _T('+')) != NULL)
-                  appendPointer = arg[nSrc];
-       }
-       /* Reusing the number of files variable */
-       nFiles = 0;
-       do
-       {
-       /* Set up the string that is the path to the destination */
-       if(nDes != -1)
-       {
-               if(_tcslen(arg[nDes]) == 2 && arg[nDes][1] == _T(':'))
-               {
-                       GetRootPath(arg[nDes],szDestPath,MAX_PATH);
-               }
-               else
-               /* If the user entered two file names then form the full string path*/
-               GetFullPathName (arg[nDes], MAX_PATH, szDestPath, NULL);
-       }
-       else
-       {
-               /* If no destination was entered then just use 
-               the current directory as the destination */
-               GetCurrentDirectory (MAX_PATH, szDestPath);
-       }
-       /* Get the full string of the path to the source file*/
-       if(_tcschr (arg[nSrc], _T('+')) != NULL)
-       {
-               _tcscpy(tmpName,_T("\0"));
-               /* Loop through the source file name and copy all
-               the chars one at a time until it gets too + */
-               while(TRUE)
-               {
-                       if(!_tcsncmp (appendPointer,_T("+"),1) || !_tcsncmp (appendPointer,_T("\0"),1))
-                       {
-                               /* Now that the pointer is on the + we 
-                                  need to go to the start of the next filename */
-                               if(!_tcsncmp (appendPointer,_T("+"),1))
-                                  appendPointer++;
-                               else
-                                       bDone = TRUE;
-                               break;
-
-                       }
-                       
-                       _tcsncat(tmpName,appendPointer,1);
-                       appendPointer++;
-
-               }
-               /* Finish the string off with a null char */
-               _tcsncat(tmpName,_T("\0"),1);
-                       
-               if(_tcschr (arg[nSrc], _T(',')) != NULL)
-                       {
-                               /* Only time there is a , in the source is when they are using touch
-                                  Cant have a destination and can only have on ,, at the end of the string 
-                                       Cant have more then one file name */
-                               szTouch = _tcsstr (arg[nSrc], _T("+"));
-                               if(_tcsncmp (szTouch,_T("+,,\0"),4) || nDes != -1)
-                               {
-                                       LoadString(CMD_ModuleHandle, STRING_ERROR_INVALID_PARAM_FORMAT, szMsg, RC_STRING_MAX_SIZE);
-                                       ConErrPrintf(szMsg,arg[nSrc]);          
-                                       nErrorLevel = 1;
-                                       freep (arg);
-                                       return 1;
-                               }
-                               bTouch = TRUE;
-                               bDone = TRUE;
-                       }
-
-               if(_tcslen(tmpName) == 2)
-               {
-                       if(tmpName[1] == _T(':'))
-                       {
-
-                               GetRootPath(tmpName,szSrcPath,MAX_PATH);
-                       }
-               }
-               else
-               /* Get the full path to first file in the string of file names */
-               GetFullPathName (tmpName, MAX_PATH, szSrcPath, NULL);   
-       }
-       else
-       {
-               bDone = TRUE;
-               if(_tcslen(arg[nSrc]) == 2 && arg[nSrc][1] == _T(':'))
-               {
-                       GetRootPath(arg[nSrc],szSrcPath,MAX_PATH);
-               }
-               else
-               /* Get the full path of the source file */
-               GetFullPathName (arg[nSrc], MAX_PATH, szSrcPath, NULL);
-       }
-       /* From this point on, we can assume that the shortest path is 3 letters long
-       and that would be [DriveLetter]:\ */
-       /* If there is no * in the path name and it is a folder
-       then we will need to add a wildcard to the pathname
-       so FindFirstFile comes up with all the files in that
-       folder */
-       if(_tcschr (szSrcPath, _T('*')) == NULL && 
-               IsExistingDirectory (szSrcPath))
-       {
-               /* If it doesnt have a \ at the end already then on needs to be added */
-               if(szSrcPath[_tcslen(szSrcPath) -  1] != _T('\\'))
-                       _tcscat (szSrcPath, _T("\\"));
-               /* Add a wildcard after the \ */
-               _tcscat (szSrcPath, _T("*"));
-       }
-       /* Make sure there is an ending slash to the path if the dest is a folder */
-       if(_tcschr (szDestPath, _T('*')) == NULL && 
-               IsExistingDirectory(szDestPath))
-       {
-               if(szDestPath[_tcslen(szDestPath) -  1] != _T('\\'))
-                       _tcscat (szDestPath, _T("\\"));
-       }
-       /* Get a list of all the files */
-       hFile = FindFirstFile (szSrcPath, &findBuffer);
-       
-       /* We need to figure out what the name of the file in the is going to be */
-       if((szDestPath[_tcslen(szDestPath) -  1] == _T('*') && szDestPath[_tcslen(szDestPath) -  2] == _T('\\')) ||
-               szDestPath[_tcslen(szDestPath) -  1] == _T('\\'))
-       {
-               /* In this case we will be using the same name as the source file
-               for the destination file because destination is a folder */
-               bSrcName = TRUE;
-       }
-       else
-       {
-               /* Save the name the user entered */
-               UseThisName = _tcsrchr(szDestPath,_T('\\'));
-               UseThisName++;
-               _tcscpy(PreserveName,UseThisName);
-       }
-       /* Strip the paths back to the folder they are in */
-       for(i = (_tcslen(szSrcPath) -  1); i > -1; i--)
-               if(szSrcPath[i] != _T('\\'))
-                       szSrcPath[i] = _T('\0');
-               else
-                       break;
-       for(i = (_tcslen(szDestPath) -  1); i > -1; i--)
-               if(szDestPath[i] != _T('\\'))
-                       szDestPath[i] = _T('\0');
-               else
-                       break;
-               do
-               {
-                       /* Check Breaker */
-                       if(CheckCtrlBreak(BREAK_INPUT))
-                       {
-                               freep(arg);
-                               return 1;
-                       }
-                       /* Set the override to yes each new file */
-                       nOverwrite = 1;
-                       /* If it couldnt open the file handle, print out the error */
-                       if(hFile == INVALID_HANDLE_VALUE)
-                       {                       
-                               ConOutFormatMessage (GetLastError(), szSrcPath);                        
-                               freep (arg);
-                               nErrorLevel = 1;
-                               return 1;
-                       }
-                       /* Ignore the . and .. files */
-                       if(!_tcscmp (findBuffer.cFileName, _T("."))  ||
-                               !_tcscmp (findBuffer.cFileName, _T(".."))||
-                               findBuffer.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                               continue;
-                       /* Copy the base folder over to a tmp string */
-                       _tcscpy(tmpDestPath,szDestPath);
-                       /* Can't put a file into a folder that isnt there */
-                       if(!IsExistingDirectory(szDestPath))
-                       {
-                               ConOutFormatMessage (GetLastError (), szSrcPath);                       
-                               freep (arg);
-                               nErrorLevel = 1;
-                               return 1;
-                       }
-                       /* Copy over the destination path name */
-                       if(bSrcName)
-                               _tcscat (tmpDestPath, findBuffer.cFileName);
-                       else
-                       {
-                               /* If there is no wildcard you can use the name the user entered */
-                               if(_tcschr (PreserveName, _T('*')) == NULL)
-                               {
-                                       _tcscat (tmpDestPath, PreserveName);
-                               }
-                               else
-                               {
-                                       /* The following lines of copy were written by someone else
-                                       (most likely Eric Khoul) and it was taken from ren.c */
-                                       LPTSTR p,q,r;
-                                       TCHAR DoneFile[MAX_PATH];
-                                       /* build destination file name */
-                                       p = findBuffer.cFileName;
-                                       q = PreserveName;
-                                       r = DoneFile;
-                                       while(*q != 0)
-                                       {
-                                               if (*q == '*')
-                                               {
-                                                       q++;
-                                                       while (*p != 0 && *p != *q)
-                                                       {
-                                                               *r = *p;
-                                                               p++;
-                                                               r++;
-                                                       }
-                                               }
-                                               else if (*q == '?')
-                                               {
-                                                       q++;
-                                                       if (*p != 0)
-                                                       {
-                                                               *r = *p;
-                                                               p++;
-                                                               r++;
-                                                       }
-                                               }
-                                               else
-                                               {
-                                                       *r = *q;
-                                                       if (*p != 0)
-                                                               p++;
-                                                       q++;
-                                                       r++;
-                                               }
-                                       }
-                                       *r = 0;
-                                       /* Add the filename to the tmp string path */
-                                       _tcscat (tmpDestPath, DoneFile);
-                               }
-                       }
-
-                       /* Build the string path to the source file */
-                       _tcscpy(tmpSrcPath,szSrcPath);
-                       _tcscat (tmpSrcPath, findBuffer.cFileName);
-
-                       /* Check to see if the file is the same file */
-                       if(!bTouch && !_tcscmp (tmpSrcPath, tmpDestPath))
-                               continue;
-
-                       /* Handle any overriding / prompting that needs to be done */
-                       if(((!(dwFlags & COPY_NO_PROMPT) && IsExistingFile (tmpDestPath)) || dwFlags & COPY_PROMPT) && !bTouch)
-                               nOverwrite = CopyOverwrite(tmpDestPath);
-                       if(nOverwrite == PROMPT_NO || nOverwrite == PROMPT_BREAK)
-                               continue;
-                       if(nOverwrite == PROMPT_ALL || (nOverwrite == PROMPT_YES && bAppend))
-                               dwFlags |= COPY_NO_PROMPT;
-
-                       /* Tell weather the copy was successful or not */
-                       if(copy(tmpSrcPath,tmpDestPath, bAppend, dwFlags, bTouch))
-                       {
-                               nFiles++;
-                               /* only print source name when more then one file */
-                               if(_tcschr (arg[nSrc], _T('+')) != NULL || _tcschr (arg[nSrc], _T('*')) != NULL)
-                                       ConOutPrintf(_T("%s\n"),findBuffer.cFileName);
-                               //LoadString(CMD_ModuleHandle, STRING_MOVE_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-                       }
-                       else
-                       {
-                               /* print out the error message */
-                               LoadString(CMD_ModuleHandle, STRING_COPY_ERROR3, szMsg, RC_STRING_MAX_SIZE);
-                               ConOutPrintf(szMsg);
-                               ConOutFormatMessage (GetLastError(), szSrcPath);
-                               nErrorLevel = 1;
-                       }
-
-               /* Loop through all wildcard files */
-               }while(FindNextFile (hFile, &findBuffer));
-       /* Loop through all files in src string with a + */
-       }while(!bDone);
-
-       /* print out the number of files copied */
-       LoadString(CMD_ModuleHandle, STRING_COPY_FILE, szMsg, RC_STRING_MAX_SIZE);
-       ConOutPrintf(szMsg, nFiles);
-       
-       CloseHandle(hFile);             
-  if (arg!=NULL) 
-      free(arg);
-
-       return 0;
-}
-#endif /* INCLUDE_CMD_COPY */
diff --git a/reactos/subsys/system/cmd/date.c b/reactos/subsys/system/cmd/date.c
deleted file mode 100644 (file)
index 3c71a4b..0000000
+++ /dev/null
@@ -1,273 +0,0 @@
-/*
- *  DATE.C - date internal command.
- *
- *
- *  History:
- *
- *    08 Jul 1998 (John P. Price)
- *        started.
- *
- *    20 Jul 1998 (John P. Price)
- *        corrected number of days for December from 30 to 31.
- *        (Thanx to Steffen Kaiser for bug report)
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    29-Jul-1998 (Rob Lake)
- *        fixed stand-alone mode.
- *        Added Pacific C compatible dos_getdate functions
- *
- *    09-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added locale support
- *
- *    23-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection safe!
- *
- *    04-Feb-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed date input bug.
- *
- *    03-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_DATE
-
-
-static WORD awMonths[2][13] =
-{
-       {0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31},
-       {0, 31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}
-};
-
-
-static VOID
-PrintDateString (VOID)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-
-       switch (nDateFormat)
-       {
-               case 0: /* mmddyy */
-               default:
-                       LoadString(CMD_ModuleHandle, STRING_DATE_HELP1, szMsg, RC_STRING_MAX_SIZE);
-                       ConOutPrintf(szMsg, cDateSeparator, cDateSeparator);
-                       break;
-
-               case 1: /* ddmmyy */
-                       LoadString(CMD_ModuleHandle, STRING_DATE_HELP2, szMsg, RC_STRING_MAX_SIZE);
-                       ConOutPrintf(szMsg, cDateSeparator, cDateSeparator);
-                       break;
-
-               case 2: /* yymmdd */
-                       LoadString(CMD_ModuleHandle, STRING_DATE_HELP3, szMsg, RC_STRING_MAX_SIZE);
-                       ConOutPrintf(szMsg, cDateSeparator, cDateSeparator);
-                       break;
-       }
-}
-
-
-static BOOL
-ReadNumber (LPTSTR *s, LPWORD lpwValue)
-{
-       if (_istdigit (**s))
-       {
-               while (_istdigit (**s))
-               {
-                       *lpwValue = *lpwValue * 10 + **s - _T('0');
-                       (*s)++;
-               }
-               return TRUE;
-       }
-       return FALSE;
-}
-
-
-static BOOL
-ReadSeparator (LPTSTR *s)
-{
-       if (**s == _T('/') || **s == _T('-') || **s == cDateSeparator)
-       {
-               (*s)++;
-               return TRUE;
-       }
-       return FALSE;
-}
-
-
-static BOOL
-ParseDate (LPTSTR s)
-{
-       SYSTEMTIME d;
-       unsigned char leap;
-       LPTSTR p = s;
-
-       if (!*s)
-               return TRUE;
-
-       GetLocalTime (&d);
-
-       d.wYear = 0;
-       d.wDay = 0;
-       d.wMonth = 0;
-
-       switch (nDateFormat)
-       {
-               case 0: /* mmddyy */
-               default:
-                       if (!ReadNumber (&p, &d.wMonth))
-                               return FALSE;
-                       if (!ReadSeparator (&p))
-                               return FALSE;
-                       if (!ReadNumber (&p, &d.wDay))
-                               return FALSE;
-                       if (!ReadSeparator (&p))
-                               return FALSE;
-                       if (!ReadNumber (&p, &d.wYear))
-                               return FALSE;
-                       break;
-
-               case 1: /* ddmmyy */
-                       if (!ReadNumber (&p, &d.wDay))
-                               return FALSE;
-                       if (!ReadSeparator (&p))
-                               return FALSE;
-                       if (!ReadNumber (&p, &d.wMonth))
-                               return FALSE;
-                       if (!ReadSeparator (&p))
-                               return FALSE;
-                       if (!ReadNumber (&p, &d.wYear))
-                               return FALSE;
-                       break;
-
-               case 2: /* yymmdd */
-                       if (!ReadNumber (&p, &d.wYear))
-                               return FALSE;
-                       if (!ReadSeparator (&p))
-                               return FALSE;
-                       if (!ReadNumber (&p, &d.wMonth))
-                               return FALSE;
-                       if (!ReadSeparator (&p))
-                               return FALSE;
-                       if (!ReadNumber (&p, &d.wDay))
-                               return FALSE;
-                       break;
-       }
-
-       /* if only entered two digits: */
-       /*   assume 2000's if value less than 80 */
-       /*   assume 1900's if value greater or equal 80 */
-       if (d.wYear <= 99)
-       {
-               if (d.wYear >= 80)
-                       d.wYear = 1900 + d.wYear;
-               else
-                       d.wYear = 2000 + d.wYear;
-       }
-
-       leap = (!(d.wYear % 4) && (d.wYear % 100)) || !(d.wYear % 400);
-
-       if ((d.wMonth >= 1 && d.wMonth <= 12) &&
-               (d.wDay >= 1 && d.wDay <= awMonths[leap][d.wMonth]) &&
-               (d.wYear >= 1980 && d.wYear <= 2099))
-       {
-               SetLocalTime (&d);
-               return TRUE;
-       }
-
-       return FALSE;
-}
-
-
-INT cmd_date (LPTSTR cmd, LPTSTR param)
-{
-       LPTSTR *arg;
-       INT    argc;
-       INT    i;
-       BOOL   bPrompt = TRUE;
-       INT    nDateString = -1;
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_DATE_HELP4);
-               return 0;
-       }
-  
-  nErrorLevel = 0;
-
-       /* build parameter array */
-       arg = split (param, &argc, FALSE);
-
-       /* check for options */
-       for (i = 0; i < argc; i++)
-       {
-               if (_tcsicmp (arg[i], _T("/t")) == 0)
-                       bPrompt = FALSE;
-               if ((*arg[i] != _T('/')) && (nDateString == -1))
-                       nDateString = i;
-       }
-
-       if (nDateString == -1)
-               PrintDate ();
-
-       if (!bPrompt)
-       {
-               freep (arg);
-               return 0;
-       }
-
-       if (nDateString == -1)
-       {
-               while (TRUE)  /* forever loop */
-               {
-                       TCHAR s[40];
-
-                       PrintDateString ();
-                       ConInString (s, 40);
-#ifdef _DEBUG
-                       DebugPrintf (_T("\'%s\'\n"), s);
-#endif
-                       while (*s && s[_tcslen (s) - 1] < _T(' '))
-                               s[_tcslen (s) - 1] = _T('\0');
-                       if (ParseDate (s))
-                       {
-                               freep (arg);
-                               return 0;
-                       }
-                       ConErrResPuts(STRING_DATE_ERROR);
-
-               }
-       }
-       else
-       {
-    if (!ParseDate (arg[nDateString]))
-    {
-      while (TRUE)  /* forever loop */
-                 {
-                         TCHAR s[40];        
-        ConErrResPuts(STRING_DATE_ERROR);
-        
-                         PrintDateString ();      
-                         ConInString (s, 40);
-        
-        while (*s && s[_tcslen (s) - 1] < _T(' '))
-                                 s[_tcslen (s) - 1] = _T('\0');
-                         if (ParseDate (s))
-                         {
-                                 freep (arg);
-                                 return 0;
-                         }        
-      }
-    }          
-       }
-
-       freep (arg);
-
-       return 0;
-}
-#endif /* INCLUDE_CMD_DATE */
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/del.c b/reactos/subsys/system/cmd/del.c
deleted file mode 100644 (file)
index b059e55..0000000
+++ /dev/null
@@ -1,570 +0,0 @@
-/*
-*  DEL.C - del internal command.
-*
-*
-*  History:
-*
-*    06/29/98 (Rob Lake rlake@cs.mun.ca)
-*        rewrote del to support wildcards
-*        added my name to the contributors
-*
-*    07/13/98 (Rob Lake)
-*        fixed bug that caused del not to delete file with out
-*        attribute. moved set, del, ren, and ver to there own files
-*
-*    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
-*        added config.h include
-*
-*    09-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeiung.de>)
-*        Fixed command line parsing bugs.
-*
-*    21-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeiung.de>)
-*        Started major rewrite using a new structure.
-*
-*    03-Feb-1999 (Eric Kohl <ekohl@abo.rhein-zeiung.de>)
-*        First working version.
-*
-*    30-Mar-1999 (Eric Kohl <ekohl@abo.rhein-zeiung.de>)
-*        Added quiet ("/Q"), wipe ("/W") and zap ("/Z") option.
-*
-*    06-Nov-1999 (Eric Kohl <ekohl@abo.rhein-zeiung.de>)
-*        Little fix to keep DEL quiet inside batch files.
-*
-*    28-Jan-2004 (Michael Fritscher <michael@fritscher.net>)
-*        Added prompt ("/P"), yes ("/Y") and wipe("/W") option.
-*
-*    22-Jun-2005 (Brandon Turner <turnerb7@msu.edu>)
-*        Added exclusive deletion "del * -abc.txt -text*.txt"
-*
-*    22-Jun-2005 (Brandon Turner <turnerb7@msu.edu>)
-*        Implemented /A   example "del /A:H /A:-R *.exe -ping.exe"
-*    
-*    07-Aug-2005
-*        Removed the exclusive deletion (see two comments above) because '-' is a valid file name character.
-*        Optimized the recursive deletion in directories.
-*        Preload some nice strings.
-*/
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_DEL
-
-
-enum
-{
-       DEL_ATTRIBUTES = 0x001,   /* /A */
-       DEL_NOTHING    = 0x004,   /* /N */
-       DEL_PROMPT     = 0x008,   /* /P */
-       DEL_QUIET      = 0x010,   /* /Q */
-       DEL_SUBDIR     = 0x020,   /* /S */
-       DEL_TOTAL      = 0x040,   /* /T */
-       DEL_WIPE       = 0x080,   /* /W */
-       DEL_EMPTYDIR   = 0x100,   /* /X : not implemented */
-       DEL_YES        = 0x200,   /* /Y */
-       DEL_FORCE      = 0x800    /* /F */
-};
-
-enum
-{
-       ATTR_ARCHIVE     = 0x001,   /* /A:A */
-       ATTR_HIDDEN      = 0x002,   /* /A:H */
-       ATTR_SYSTEM      = 0x004,   /* /A:S */
-       ATTR_READ_ONLY   = 0x008,   /* /A:R */
-       ATTR_N_ARCHIVE   = 0x010,   /* /A:-A */
-       ATTR_N_HIDDEN    = 0x020,   /* /A:-H */
-       ATTR_N_SYSTEM    = 0x040,   /* /A:-S */
-       ATTR_N_READ_ONLY = 0x080    /* /A:-R */
-};
-
-static TCHAR szDeleteWipe[RC_STRING_MAX_SIZE];
-static TCHAR szDelHelp2[RC_STRING_MAX_SIZE];
-static TCHAR szDelHelp3[RC_STRING_MAX_SIZE];
-static TCHAR szDelHelp4[RC_STRING_MAX_SIZE];
-static TCHAR szDelError5[RC_STRING_MAX_SIZE];
-static TCHAR szDelError6[RC_STRING_MAX_SIZE];
-static TCHAR szDelError7[RC_STRING_MAX_SIZE];
-static TCHAR CMDPath[MAX_PATH];
-
-static BOOLEAN StringsLoaded = FALSE;
-
-static VOID LoadStrings(VOID)
-{
-        LoadString( CMD_ModuleHandle, STRING_DELETE_WIPE, szDeleteWipe, RC_STRING_MAX_SIZE);
-        LoadString( CMD_ModuleHandle, STRING_DEL_HELP2, szDelHelp2, RC_STRING_MAX_SIZE);
-        LoadString( CMD_ModuleHandle, STRING_DEL_HELP3, szDelHelp3, RC_STRING_MAX_SIZE);
-        LoadString( CMD_ModuleHandle, STRING_DEL_HELP4, szDelHelp4, RC_STRING_MAX_SIZE);
-        LoadString( CMD_ModuleHandle, STRING_DEL_ERROR5, szDelError5, RC_STRING_MAX_SIZE);
-        LoadString( CMD_ModuleHandle, STRING_DEL_ERROR6, szDelError6, RC_STRING_MAX_SIZE);
-        LoadString( CMD_ModuleHandle, STRING_DEL_ERROR7, szDelError7, RC_STRING_MAX_SIZE);
-        GetModuleFileName(NULL, CMDPath, MAX_PATH);
-        StringsLoaded = TRUE;
-}
-
-static BOOL
-RemoveFile (LPTSTR lpFileName, DWORD dwFlags, WIN32_FIND_DATA* f)
-{
-       /*This function is called by CommandDelete and
-       does the actual process of deleting the single 
-       file*/
-               if(CheckCtrlBreak(BREAK_INPUT))
-                       return 1;
-
-        /*check to see if it is read only and if this is done based on /A
-          if it is done by file name, access is denied. However, if it is done 
-          using the /A switch you must un-read only the file and allow it to be
-          deleted*/
-        if((dwFlags & DEL_ATTRIBUTES) || (dwFlags & DEL_FORCE))
-        {
-                if(f->dwFileAttributes & FILE_ATTRIBUTE_READONLY)
-               {
-                       /*setting file to normal, not saving old attrs first
-                         because the file is going to be deleted anyways
-                         so the only thing that matters is that it isnt
-                         read only.*/
-                        SetFileAttributes(lpFileName,FILE_ATTRIBUTE_NORMAL);
-                }
-        }
-
-        if (dwFlags & DEL_WIPE)
-        {
-
-               HANDLE file;
-               DWORD temp;
-#define BufferSize 65536
-               BYTE buffer[BufferSize];
-               LONGLONG i;
-               LARGE_INTEGER FileSize;
-
-               FileSize.u.HighPart = f->nFileSizeHigh;
-                FileSize.u.LowPart = f->nFileSizeLow;
-
-               for(i = 0; i < BufferSize; i++)
-               {
-                       buffer[i]=rand() % 256;
-               }
-               file = CreateFile (lpFileName, GENERIC_WRITE, 0, NULL, OPEN_EXISTING,  FILE_FLAG_WRITE_THROUGH, NULL);
-                if (file != INVALID_HANDLE_VALUE)
-                {
-                        for(i = 0; i < (FileSize.QuadPart - BufferSize); i += BufferSize)
-                       {
-                               WriteFile (file, buffer, BufferSize, &temp, NULL);
-                               ConOutPrintf (_T("%I64d%% %s\r"),(i * (LONGLONG)100)/FileSize.QuadPart,szDeleteWipe);
-                       }
-                       WriteFile (file, buffer, (DWORD)(FileSize.QuadPart - i), &temp, NULL);
-                       ConOutPrintf (_T("100%% %s\n"),szDeleteWipe);
-                       CloseHandle (file);
-                }
-        }
-
-       return DeleteFile (lpFileName);
-}
-
-
-static DWORD
-DeleteFiles(LPTSTR FileName, DWORD* dwFlags, DWORD dwAttrFlags)
-{
-        TCHAR szFullPath[MAX_PATH];
-        TCHAR szFileName[MAX_PATH];
-        LPTSTR pFilePart;
-        HANDLE hFile;
-        WIN32_FIND_DATA f;
-        BOOL bExclusion;
-        INT res;
-        DWORD dwFiles = 0;
-
-        _tcscpy(szFileName, FileName);
-
-        if(_tcschr (szFileName, _T('*')) == NULL && 
-          IsExistingDirectory (szFileName))
-        {
-               /* If it doesnt have a \ at the end already then on needs to be added */
-               if(szFileName[_tcslen(szFileName) -  1] != _T('\\'))
-                        _tcscat (szFileName, _T("\\"));
-                /* Add a wildcard after the \ */
-                _tcscat (szFileName, _T("*"));
-        }
-
-       if(!_tcscmp (szFileName, _T("*")) ||
-           !_tcscmp (szFileName, _T("*.*")) ||
-           (szFileName[_tcslen(szFileName) -  2] == _T('\\') && szFileName[_tcslen(szFileName) -  1] == _T('*')))
-        {
-                /* well, the user wants to delete everything but if they didnt yes DEL_YES, DEL_QUIET, or DEL_PROMPT
-                  then we are going to want to make sure that in fact they want to do that.  */
-
-               if (!((*dwFlags & DEL_YES) || (*dwFlags & DEL_QUIET) || (*dwFlags & DEL_PROMPT)))
-               {
-                       res = FilePromptYNA (szDelHelp2);
-                       if ((res == PROMPT_NO) || (res == PROMPT_BREAK))
-                               return 0x80000000;
-                       if(res == PROMPT_ALL)
-                               *dwFlags |= DEL_YES;
-               }
-       }
-
-        GetFullPathName (szFileName,
-                         MAX_PATH,
-                         szFullPath,
-                         &pFilePart);
-
-        hFile = FindFirstFile(szFullPath, &f);
-        if (hFile != INVALID_HANDLE_VALUE)
-        {
-                do
-                {
-                        bExclusion = FALSE;
-
-                       /*if it is going to be excluded by - no need to check attrs*/
-                       if(*dwFlags & DEL_ATTRIBUTES && !bExclusion)
-                       {
-
-                               /*save if file attr check if user doesnt care about that attr anyways*/
-                               if(dwAttrFlags & ATTR_ARCHIVE && !(f.dwFileAttributes & FILE_ATTRIBUTE_ARCHIVE))
-                                       bExclusion = TRUE;
-                               if(dwAttrFlags & ATTR_HIDDEN && !(f.dwFileAttributes & FILE_ATTRIBUTE_HIDDEN))
-                                       bExclusion = TRUE;
-                               if(dwAttrFlags & ATTR_SYSTEM && !(f.dwFileAttributes & FILE_ATTRIBUTE_SYSTEM))
-                                       bExclusion = TRUE;
-                               if(dwAttrFlags & ATTR_READ_ONLY && !(f.dwFileAttributes & FILE_ATTRIBUTE_READONLY))
-                                       bExclusion = TRUE;
-                               if(dwAttrFlags & ATTR_N_ARCHIVE && (f.dwFileAttributes & FILE_ATTRIBUTE_ARCHIVE))
-                                       bExclusion = TRUE;
-                               if(dwAttrFlags & ATTR_N_HIDDEN && (f.dwFileAttributes & FILE_ATTRIBUTE_HIDDEN))
-                                       bExclusion = TRUE;
-                               if(dwAttrFlags & ATTR_N_SYSTEM && (f.dwFileAttributes & FILE_ATTRIBUTE_SYSTEM))
-                                       bExclusion = TRUE;
-                               if(dwAttrFlags & ATTR_N_READ_ONLY && (f.dwFileAttributes & FILE_ATTRIBUTE_READONLY))
-                                       bExclusion = TRUE;
-                       }
-
-                       if(bExclusion)
-                               continue;
-
-                       /* ignore directories */
-                       if (f.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                               continue;
-
-
-                       _tcscpy (pFilePart, f.cFileName);
-
-                       /* We cant delete ourselves */
-                       if(!_tcscmp (CMDPath,szFullPath))
-                               continue;
-
-
-#ifdef _DEBUG
-                       ConErrPrintf(_T("Full filename: %s\n"), szFullPath);
-#endif
-
-                       /* ask for deleting */
-                       if (*dwFlags & DEL_PROMPT)
-                       {
-                               ConErrPrintf(szDelError5, szFullPath);
-
-                               res = FilePromptYN (szDelError6);
-
-                               if ((res == PROMPT_NO) || (res == PROMPT_BREAK))
-                               {
-                                                                nErrorLevel = 0;
-                                       continue;
-                               }
-                       }
-
-                       /*user cant ask it to be quiet and tell you what it did*/
-                       if (!(*dwFlags & DEL_QUIET) && !(*dwFlags & DEL_TOTAL))
-                       {
-                               ConErrPrintf(szDelError7, szFullPath);
-                       }
-
-                       /* delete the file */
-                       if(*dwFlags & DEL_NOTHING)
-                               continue;
-
-                       if(RemoveFile (szFullPath, *dwFlags, &f))
-                               dwFiles++;
-                       else
-                        {              
-                               ErrorMessage (GetLastError(), _T(""));
-//                                FindClose(hFile);
-//                                return -1;
-                       }
-                }
-                while (FindNextFile (hFile, &f));
-               FindClose (hFile);
-        }
-        return dwFiles;
-}
-
-
-static DWORD 
-ProcessDirectory(LPTSTR FileName, DWORD* dwFlags, DWORD dwAttrFlags)
-{
-        TCHAR szFullPath[MAX_PATH];
-        LPTSTR pFilePart;
-        LPTSTR pSearchPart;
-        HANDLE hFile;
-        WIN32_FIND_DATA f;
-        DWORD dwFiles = 0;
-
-        GetFullPathName (FileName,
-                         MAX_PATH,
-                         szFullPath,
-                         &pFilePart);
-
-        dwFiles = DeleteFiles(szFullPath, dwFlags, dwAttrFlags);
-        if (dwFiles & 0x80000000)
-                return dwFiles;
-
-        if (*dwFlags & DEL_SUBDIR)
-        {
-               /* Get just the file name */
-               pSearchPart = _tcsrchr(FileName,_T('\\'));
-               if(pSearchPart != NULL)
-                       pSearchPart++;
-               else
-                       pSearchPart = FileName;
-
-               /* Get the full path to the file */
-               GetFullPathName (FileName,MAX_PATH,szFullPath,NULL);
-
-               /* strip the filename off of it */
-                pFilePart = _tcsrchr(szFullPath, _T('\\'));
-                if (pFilePart == NULL)
-                {
-                        pFilePart = szFullPath;
-                }
-                else
-                {
-                        pFilePart++;
-                }
-
-                _tcscpy(pFilePart, _T("*"));
-
-                hFile = FindFirstFile(szFullPath, &f);
-                if (hFile != INVALID_HANDLE_VALUE)
-                {
-                        do
-                        {
-                                       if (!(f.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) ||
-                                    !_tcscmp(f.cFileName, _T(".")) ||
-                                    !_tcscmp(f.cFileName, _T("..")))
-                                       continue;
-
-                                _tcscpy(pFilePart, f.cFileName);
-                                _tcscat(pFilePart, _T("\\"));
-                                _tcscat(pFilePart, pSearchPart);
-
-                                dwFiles +=ProcessDirectory(szFullPath, dwFlags, dwAttrFlags);
-                                if (dwFiles & 0x80000000)
-                                {
-                                    break;
-                                }
-                        }
-                        while (FindNextFile (hFile, &f));
-                       FindClose (hFile);
-                }
-        }
-        return dwFiles;
-}        
-
-
-
-INT CommandDelete (LPTSTR cmd, LPTSTR param)
-{
-       /*cmd is the command that was given, in this case it will always be "del" or "delete"
-       param is whatever is given after the command*/
-
-       LPTSTR *arg = NULL;
-       INT args;
-       INT i;
-       INT   nEvalArgs = 0; /* nunber of evaluated arguments */
-       DWORD dwFlags = 0;
-       DWORD dwAttrFlags = 0;
-       DWORD dwFiles = 0;
-       LONG ch;
-       TCHAR szOrginalArg[MAX_PATH];
-
-       /*checks the first two chars of param to see if it is /?
-       this however allows the following command to not show help
-       "del frog.txt /?" */
-
-        if (!StringsLoaded)
-        {
-                LoadStrings();
-        }
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_DEL_HELP1);
-               return 0;
-       }
-
-       nErrorLevel = 0;
-
-       arg = split (param, &args, FALSE);
-
-       if (args == 0)
-       {
-               /* only command given */
-               error_req_param_missing ();
-               freep (arg);
-               return 1;
-       }
-       /* check for options anywhere in command line */
-       for (i = 0; i < args; i++)
-       {
-               if (*arg[i] == _T('/'))
-               {
-                       /*found a command, but check to make sure it has something after it*/
-                       if (_tcslen (arg[i]) >= 2)
-                       {
-                               ch = _totupper (arg[i][1]);
-                               if (ch == _T('N'))
-                               {
-                                       dwFlags |= DEL_NOTHING;
-                               }
-                               else if (ch == _T('P'))
-                               {
-                                       dwFlags |= DEL_PROMPT;
-                               }
-                               else if (ch == _T('Q'))
-                               {
-                                       dwFlags |= DEL_QUIET;
-                               }
-                               else if (ch == _T('F'))
-                               {
-                                       dwFlags |= DEL_FORCE;
-                               }
-                               else if (ch == _T('S'))
-                               {
-                                       dwFlags |= DEL_SUBDIR;
-                               }
-                               else if (ch == _T('T'))
-                               {
-                                       dwFlags |= DEL_TOTAL;
-                               }
-                               else if (ch == _T('W'))
-                               {
-                                       dwFlags |= DEL_WIPE;
-                               }
-                               else if (ch == _T('Y'))
-                               {
-                                       dwFlags |= DEL_YES;
-                               }
-                               else if (ch == _T('A'))
-                               {
-
-                                       dwFlags |= DEL_ATTRIBUTES;
-                                       /*the proper syntax for /A has a min of 4 chars
-                                       i.e. /A:R or /A:-H */
-                                       if (_tcslen (arg[i]) < 4)
-                                       {
-                                               error_invalid_parameter_format(arg[i]);
-                                               return 0;
-                                       }
-                                       ch = _totupper (arg[i][3]);
-                                       if (_tcslen (arg[i]) == 4)
-                                       {                                               
-                                               if(ch == _T('A'))
-                                               {
-                                                       dwAttrFlags |= ATTR_ARCHIVE;
-                                               }
-                                               if(ch == _T('H'))
-                                               {
-                                                       dwAttrFlags |= ATTR_HIDDEN;
-                                               }
-                                               if(ch == _T('S'))
-                                               {
-                                                       dwAttrFlags |= ATTR_SYSTEM;
-                                               }
-                                               if(ch == _T('R'))
-                                               {
-                                                       dwAttrFlags |= ATTR_READ_ONLY;
-                                               }
-                                       }
-                                       if (_tcslen (arg[i]) == 5)
-                                       {
-                                               if(ch == _T('-'))
-                                               {
-                                                       ch = _totupper (arg[i][4]);
-                                                       if(ch == _T('A'))
-                                                       {
-                                                               dwAttrFlags |= ATTR_N_ARCHIVE;
-                                                       }
-                                                       if(ch == _T('H'))
-                                                       {
-                                                               dwAttrFlags |= ATTR_N_HIDDEN;
-                                                       }
-                                                       if(ch == _T('S'))
-                                                       {
-                                                               dwAttrFlags |= ATTR_N_SYSTEM;
-                                                       }
-                                                       if(ch == _T('R'))
-                                                       {
-                                                               dwAttrFlags |= ATTR_N_READ_ONLY;
-                                                       }
-                                               }
-                                       }
-                               }
-                       }
-
-                       nEvalArgs++;
-               }
-       }
-
-       /* there are only options on the command line --> error!!!
-       there is the same number of args as there is flags, so none of the args were filenames*/
-       if (args == nEvalArgs)
-       {
-               error_req_param_missing ();
-               freep (arg);
-               return 1;
-       }
-
-       /* keep quiet within batch files */
-       if (bc != NULL)
-               dwFlags |= DEL_QUIET;
-
-       /* check for filenames anywhere in command line */
-       for (i = 0; i < args && !(dwFiles & 0x80000000); i++)
-       {
-
-                /*this checks to see if it isnt a flag, if it isnt, we assume it is a file name*/
-               if((*arg[i] == _T('/')) || (*arg[i] == _T('-')))
-                       continue;
-
-               /* We want to make a copies of the argument */
-               if(_tcslen(arg[i]) == 2 && arg[i][1] == _T(':'))
-               {
-                       /* Check for C: D: ... */
-                       GetRootPath(arg[i],szOrginalArg,MAX_PATH);
-               }
-               else
-               {
-                       _tcscpy(szOrginalArg,arg[i]);
-               }
-                dwFiles += ProcessDirectory(szOrginalArg, &dwFlags, dwAttrFlags);
-
-        }
-       
-       freep (arg);
-
-       /*Based on MS cmd, we only tell what files are being deleted when /S is used */
-       if (dwFlags & DEL_TOTAL)
-       {
-                dwFiles &= 0x7fffffff;
-               if (dwFiles < 2)
-               {
-                        ConOutPrintf(szDelHelp3, dwFiles);
-               }
-               else
-               {
-                       ConOutPrintf(szDelHelp4, dwFiles);
-               }
-       }
-
-       return 0;
-}
-
-
-#endif
diff --git a/reactos/subsys/system/cmd/delay.c b/reactos/subsys/system/cmd/delay.c
deleted file mode 100644 (file)
index 4b38310..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * DELAY.C - internal command.
- *
- * clone from 4nt delay command
- *
- * 30 Aug 1999
- *     started - Paolo Pantaleo <paolopan@freemail.it>
- *
- *
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_DELAY
-
-
-INT CommandDelay (LPTSTR cmd, LPTSTR param)
-{
-       DWORD val;
-       DWORD mul=1000;
-
-       if (_tcsncmp (param, _T("/?"), 2) == 0)
-       {
-               ConOutResPaging(TRUE,STRING_DELAY_HELP);
-               return 0;
-       }
-
-       nErrorLevel = 0;
-
-       if (*param==0)
-       {
-               error_req_param_missing ();
-               return 1;
-       }
-
-       if (_tcsnicmp(param,_T("/m"),2) == 0)
-       {
-               mul = 1;
-               param += 2;
-       }
-
-       val = _ttoi(param);
-       Sleep(val * mul);
-
-       return 0;
-}
-
-#endif /* INCLUDE_CMD_DELAY */
diff --git a/reactos/subsys/system/cmd/dir.c b/reactos/subsys/system/cmd/dir.c
deleted file mode 100644 (file)
index e70e1bc..0000000
+++ /dev/null
@@ -1,2111 +0,0 @@
-/*
- *  DIR.C - dir internal command.
- *
- *
- *  History:
- *
- *    01/29/97 (Tim Norman)
- *        started.
- *
- *    06/13/97 (Tim Norman)
- *      Fixed code.
- *
- *    07/12/97 (Tim Norman)
- *        Fixed bug that caused the root directory to be unlistable
- *
- *    07/12/97 (Marc Desrochers)
- *        Changed to use maxx, maxy instead of findxy()
- *
- *    06/08/98 (Rob Lake)
- *        Added compatibility for /w in dir
- *
- *    06/09/98 (Rob Lake)
- *        Compatibility for dir/s started
- *        Tested that program finds directories off root fine
- *
- *    06/10/98 (Rob Lake)
- *        do_recurse saves the cwd and also stores it in Root
- *        build_tree adds the cwd to the beginning of its' entries
- *        Program runs fine, added print_tree -- works fine.. as EXE,
- *        program won't work properly as COM.
- *
- *    06/11/98 (Rob Lake)
- *        Found problem that caused COM not to work
- *
- *    06/12/98 (Rob Lake)
- *        debugged...
- *        added free mem routine
- *
- *    06/13/98 (Rob Lake)
- *        debugged the free mem routine
- *        debugged whole thing some more
- *        Notes:
- *        ReadDir stores Root name and _Read_Dir does the hard work
- *        PrintDir prints Root and _Print_Dir does the hard work
- *        KillDir kills Root _after_ _Kill_Dir does the hard work
- *        Integrated program into DIR.C(this file) and made some same
- *        changes throughout
- *
- *    06/14/98 (Rob Lake)
- *        Cleaned up code a bit, added comments
- *
- *    06/16/98 (Rob Lake)
- *        Added error checking to my previously added routines
- *
- *    06/17/98 (Rob Lake)
- *        Rewrote recursive functions, again! Most other recursive
- *        functions are now obsolete -- ReadDir, PrintDir, _Print_Dir,
- *        KillDir and _Kill_Dir.  do_recurse does what PrintDir did
- *        and _Read_Dir did what it did before along with what _Print_Dir
- *        did.  Makes /s a lot faster!
- *        Reports 2 more files/dirs that MS-DOS actually reports
- *        when used in root directory(is this because dir defaults
- *        to look for read only files?)
- *        Added support for /b, /a and /l
- *        Made error message similar to DOS error messages
- *        Added help screen
- *
- *    06/20/98 (Rob Lake)
- *        Added check for /-(switch) to turn off previously defined
- *        switches.
- *        Added ability to check for DIRCMD in environment and
- *        process it
- *
- *    06/21/98 (Rob Lake)
- *        Fixed up /B
- *        Now can dir *.ext/X, no spaces!
- *
- *    06/29/98 (Rob Lake)
- *        error message now found in command.h
- *
- *    07/08/1998 (John P. Price)
- *        removed extra returns; closer to MSDOS
- *        fixed wide display so that an extra return is not displayed
- *        when there is five filenames in the last line.
- *
- *    07/12/98 (Rob Lake)
- *        Changed error messages
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *
- *    04-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Converted source code to Win32, except recursive dir ("dir /s").
- *
- *    10-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed recursive dir ("dir /s").
- *
- *    14-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Converted to Win32 directory functions and
- *        fixed some output bugs. There are still some more ;)
- *
- *    10-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added "/N" and "/4" options, "/O" is a dummy.
- *        Added locale support.
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Redirection safe!
- *
- *    01-Mar-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Replaced all runtime io functions by their Win32 counterparts.
- *
- *    23-Feb-2001 (Carl Nettelblad <cnettel@hem.passagen.se>)
- *        dir /s now works in deeper trees
- *
- *    28-Jan-2004 (Michael Fritscher <michael@fritscher.net>)
- *        Fix for /p, so it is working under Windows in GUI-mode, too.
- *
- *    30-Apr-2004 (Filip Navara <xnavara@volny.cz>)
- *        Fix /w to print long names.
- *
- *    27-Feb-2005 (Konstantinos Paliouras <squarious@gmail.com>)
- *        Implemented all the switches that were missing, and made
- *        the ros dir very similar to windows dir. Major part of
- *        the code is rewritten. /p is removed, to be rewriten in
- *        the main cmd code.
- *
- *    1-Jul-2004 (Brandon Turner <turnerb7@msu.edu>)
- *        Added /p back in using ConOutPrintfPaging
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_DIR
-
-
-
-/* Time Field enumeration */
-enum ETimeField
-{
-       TF_CREATIONDATE         = 0,
-       TF_MODIFIEDDATE         = 1,
-       TF_LASTACCESSEDDATE     = 2
-};
-
-/* Ordered by enumeration */
-enum EOrderBy
-{
-       ORDER_NAME              = 0,
-       ORDER_SIZE              = 1,
-       ORDER_DIRECTORY = 2,
-       ORDER_EXTENSION = 3,
-       ORDER_TIME              = 4
-};
-
-/* The struct for holding the switches */
-typedef struct _DirSwitchesFlags
-{
-       BOOL bBareFormat;       /* Bare Format */
-       BOOL bTSeperator;       /* Thousands seperator */
-       BOOL bWideList;         /* Wide list format     */
-       BOOL bWideListColSort;  /* Wide list format but sorted by column */
-       BOOL bLowerCase;        /* Uses lower case */
-       BOOL bNewLongList;      /* New long list */
-       BOOL bPause;            /* Pause per page */
-       BOOL bUser;                     /* Displays the owner of file */
-       BOOL bRecursive;        /* Displays files in specified directory and all sub */
-       BOOL bShortName;        /* Displays the sort name of files if exist     */
-       BOOL b4Digit;           /* Four digit year      */
-       struct
-       {
-               DWORD dwAttribVal;      /* The desired state of attribute */
-               DWORD dwAttribMask;     /* Which attributes to check */
-               BOOL bUnSet;            /* A helper flag if "-" was given with the switch */
-               BOOL bParSetted;        /* A helper flag if parameters of switch were given */
-       } stAttribs;            /* Displays files with this attributes only */
-       struct
-       {
-               enum EOrderBy eCriteria[3];     /* Criterias used to order by */
-               BOOL bCriteriaRev[3];           /* If the criteria is in reversed order */
-               short sCriteriaCount;           /* The quantity of criterias */
-               BOOL bUnSet;                            /* A helper flag if "-" was given with the switch */
-               BOOL bParSetted;                        /* A helper flag if parameters of switch were given */
-       } stOrderBy;            /* Ordered by criterias */
-       struct
-       {
-               enum ETimeField eTimeField;     /* The time field that will be used for */
-               BOOL bUnSet;                            /* A helper flag if "-" was given with the switch */
-               BOOL bParSetted;                        /* A helper flag if parameters of switch were given */
-       } stTimeField;          /* The time field to display or use for sorting */
-} DIRSWITCHFLAGS, *LPDIRSWITCHFLAGS;
-
-
-typedef struct _DIRFINDLISTNODE
-{
-  WIN32_FIND_DATA stFindInfo;
-  struct _DIRFINDLISTNODE *ptrNext;
-} DIRFINDLISTNODE, *PDIRFINDLISTNODE;
-
-
-typedef BOOL
-(WINAPI *PGETFREEDISKSPACEEX)(LPCTSTR, PULARGE_INTEGER, PULARGE_INTEGER, PULARGE_INTEGER);
-
-
-/* Globally save the # of dirs, files and bytes,
- * probabaly later pass them to functions. Rob Lake  */
-static ULONG recurse_dir_cnt;
-static ULONG recurse_file_cnt;
-static ULARGE_INTEGER recurse_bytes;
-
-
-/*
- * help
- *
- * displays help screen for dir
- * Rob Lake
- */
-static VOID 
-DirHelp(VOID)
-{
-  ConOutResPaging(TRUE, STRING_DIR_HELP1);
-}
-
-
-
-/*
- * DirReadParameters
- *
- * Parse the parameters and switches of the command line and exports them
- */
-static BOOL 
-DirReadParam(LPTSTR Line,                              /* [IN] The line with the parameters & switches */
-                       LPTSTR** params,                        /* [OUT] The parameters after parsing */
-                       LPINT entries,                          /* [OUT] The number of parameters after parsing */
-                       LPDIRSWITCHFLAGS lpFlags)       /* [IN/OUT] The flags after calculating switches */
-{
-       TCHAR cCurSwitch;       /* The current switch */
-       TCHAR cCurChar;         /* Current examing character */
-       TCHAR cCurUChar;        /* Current upper examing character */
-       BOOL bNegative;         /* Negative switch */
-       BOOL bPNegative;        /* Negative switch parameter */
-       BOOL bIntoQuotes;       /* A flag showing if we are in quotes (") */
-       LPTSTR ptrStart;        /* A pointer to the first character of a parameter */
-       LPTSTR ptrEnd;          /* A pointer to the last character of a parameter */
-       LPTSTR temp;
-
-       /* Initialize parameter array */
-       *params = malloc(sizeof(LPTSTR));
-       if(!params)
-               return FALSE;
-       *params = NULL;
-       *entries = 0;
-       ptrStart = NULL;
-       ptrEnd = NULL;
-
-       /* Initialize variables; */
-       cCurSwitch = _T(' ');
-       bNegative = FALSE;
-       bPNegative = FALSE;
-       bIntoQuotes = FALSE;
-
-       /* We suppose that switch parameters
-          were given to avoid setting them to default
-          if the switch was not given */
-       lpFlags->stAttribs.bParSetted = TRUE;
-       lpFlags->stOrderBy.bParSetted = TRUE;
-       lpFlags->stTimeField.bParSetted = TRUE;
-
-       
-       /* Main Loop (see README_DIR.txt) */
-       /* scan the command line char per char, and we process its char */
-       while (*Line)
-       {
-               /* we save current character as it is and its upper case */
-               cCurChar = *Line;
-               cCurUChar = _totupper(*Line);
-
-               /* 1st section (see README_DIR.txt) */
-               /* When a switch is expecting */
-               if (cCurSwitch == _T('/'))
-               {
-                       if ((cCurUChar == _T('A')) ||(cCurUChar == _T('T')) || (cCurUChar == _T('O')))
-                       {
-                               cCurSwitch = cCurUChar;
-                               switch (cCurUChar)
-                               {
-                               case _T('A'):
-                                       lpFlags->stAttribs.bUnSet = bNegative;
-                                       lpFlags->stAttribs.bParSetted = FALSE;
-                                       break;
-                               case _T('T'):
-                                       lpFlags->stTimeField.bUnSet = bNegative;
-                                       lpFlags->stTimeField.bParSetted = FALSE;
-                                       break;
-                               case _T('O'):
-                                       lpFlags->stOrderBy.bUnSet = bNegative;
-                                       lpFlags->stOrderBy.bParSetted = FALSE;
-                                       break;
-                               }
-                       }
-                       else if (cCurUChar == _T('L'))
-                               lpFlags->bLowerCase = ! bNegative;
-                       else if (cCurUChar == _T('B'))
-                               lpFlags->bBareFormat = ! bNegative;
-                       else if (cCurUChar == _T('C'))
-                               lpFlags->bTSeperator = ! bNegative;
-                       else if (cCurUChar == _T('W'))
-                               lpFlags->bWideList = ! bNegative;
-                       else if (cCurUChar == _T('D'))
-                               lpFlags->bWideListColSort = ! bNegative;
-                       else if (cCurUChar == _T('N'))
-                               lpFlags->bNewLongList = ! bNegative;
-                       else if (cCurUChar == _T('P'))
-                               lpFlags->bPause = ! bNegative;
-                       else if (cCurUChar == _T('Q'))
-                               lpFlags->bUser = ! bNegative;
-                       else if (cCurUChar == _T('S'))
-                               lpFlags->bRecursive = ! bNegative;
-                       else if (cCurUChar == _T('X'))
-                               lpFlags->bShortName = ! bNegative;
-                       else if (cCurChar == _T('4'))
-                               lpFlags->b4Digit = ! bNegative;
-                       else if (cCurChar == _T('?'))
-                       {
-                               DirHelp();
-                               return FALSE;
-                       }
-                       else if (cCurChar ==  _T('-'))
-                       {
-                               bNegative = TRUE;
-                       }
-                       else
-                       {
-                               error_invalid_switch ((TCHAR)_totupper (*Line));
-                               return FALSE;
-                       }
-
-                       /* We check if we calculated the negative value and realese the flag */
-                       if ((cCurChar != _T('-')) && bNegative)
-                               bNegative = FALSE;
-
-                       /* if not a,o,t or - option then next parameter is not a switch */
-                       if ((cCurSwitch == _T('/')) && (!bNegative))
-                               cCurSwitch = _T(' ');
-
-               }
-               else if ((cCurSwitch == _T(' ')) || (cCurSwitch == _T('P')))
-               {
-                       /* 2nd section (see README_DIR.txt) */
-                       /* We are expecting parameter or the unknown */
-
-                       if (cCurChar == _T('/'))
-                               cCurSwitch = _T('/');
-
-                       /* Process a spacer */
-                       else if (cCurChar == _T(' '))
-                       {
-                               if (!bIntoQuotes)
-                               {
-                                       cCurSwitch = _T(' ');
-                                       if(ptrStart && ptrEnd)
-                                       {               
-                                               temp = malloc((ptrEnd - ptrStart) + 2 * sizeof (TCHAR));
-                                               if(!temp)
-                                                       return FALSE;
-                                               memcpy(temp, ptrStart, (ptrEnd - ptrStart) + 2 * sizeof (TCHAR));
-                                               temp[(ptrEnd - ptrStart + 1)] = _T('\0');
-                                               if(!add_entry(entries, params, temp))
-                                               {
-                                                       free(temp);
-                                                       freep(*params);
-                                                       return FALSE;
-                                               }
-
-                                               free(temp);
-
-                                               ptrStart = NULL;
-                                               ptrEnd = NULL;
-                                       }
-                               }
-
-                       }
-                       else if (cCurChar == _T('\"'))
-                       {
-                               /* Process a quote */
-                               bIntoQuotes = !bIntoQuotes;
-                               if(!bIntoQuotes)
-                                       ptrEnd = Line;
-                       }
-                       else
-                       {
-                               /* Process a character for parameter */
-                               if ((cCurSwitch == _T(' ')) && ptrStart && ptrEnd)
-                               {               
-                                       temp = malloc((ptrEnd - ptrStart) + 2 * sizeof (TCHAR));
-                                       if(!temp)
-                                               return FALSE;
-                                       memcpy(temp, ptrStart, (ptrEnd - ptrStart) + 2 * sizeof (TCHAR));
-                                       temp[(ptrEnd - ptrStart + 1)] = _T('\0');
-                                       if(!add_entry(entries, params, temp))
-                                       {
-                                               free(temp);
-                                               freep(*params);
-                                               return FALSE;
-                                       }
-
-                                       free(temp);
-
-                                       ptrStart = NULL;
-                                       ptrEnd = NULL;
-                               }
-                               cCurSwitch = _T('P');
-                               if(!ptrStart)
-                                       ptrStart = ptrEnd = Line;
-                               ptrEnd = Line;
-                       }
-               }
-               else
-               {
-                       /* 3rd section (see README_DIR.txt) */
-                       /* We are waiting for switch parameters */
-
-                       /* Check if there are no more switch parameters */
-                       if ((cCurChar == _T('/')) || ( cCurChar == _T(' ')))
-                       {
-                               /* Wrong desicion path, reprocess current character */
-                               cCurSwitch = cCurChar;
-                               continue;
-                       }
-                       /* Process parameter switch */
-                       switch(cCurSwitch)
-                       {
-                       case _T('A'):   /* Switch parameters for /A (attributes filter) */
-                               /* Ok a switch parameter was given */
-                               lpFlags->stAttribs.bParSetted = TRUE;
-
-                               if (cCurChar == _T(':'))
-                                       /* =V= dead command, used to make the "if" work */
-                                       cCurChar = cCurChar;
-                               else if(cCurChar == _T('-'))
-                                       bPNegative = TRUE;
-                               else if(cCurUChar == _T('D'))
-                               {
-                                       lpFlags->stAttribs.dwAttribMask |= FILE_ATTRIBUTE_DIRECTORY;
-                                       if (bPNegative)
-                                               lpFlags->stAttribs.dwAttribVal &= ~FILE_ATTRIBUTE_DIRECTORY;
-                                       else
-                                               lpFlags->stAttribs.dwAttribVal |= FILE_ATTRIBUTE_DIRECTORY;
-                               }
-                               else if(cCurUChar == _T('R'))
-                               {
-                                       lpFlags->stAttribs.dwAttribMask |= FILE_ATTRIBUTE_READONLY;
-                                       if (bPNegative)
-                                               lpFlags->stAttribs.dwAttribVal &= ~FILE_ATTRIBUTE_READONLY;
-                                       else
-                                               lpFlags->stAttribs.dwAttribVal |= FILE_ATTRIBUTE_READONLY;
-                               }
-                               else if(cCurUChar == _T('H'))
-                               {
-                                       lpFlags->stAttribs.dwAttribMask |= FILE_ATTRIBUTE_HIDDEN;
-                                       if (bPNegative)
-                                               lpFlags->stAttribs.dwAttribVal &= ~FILE_ATTRIBUTE_HIDDEN;
-                                       else
-                                               lpFlags->stAttribs.dwAttribVal |= FILE_ATTRIBUTE_HIDDEN;
-                               }
-                               else if(cCurUChar == _T('A'))
-                               {
-                                       lpFlags->stAttribs.dwAttribMask |= FILE_ATTRIBUTE_ARCHIVE;
-                                       if (bPNegative)
-                                               lpFlags->stAttribs.dwAttribVal &= ~FILE_ATTRIBUTE_ARCHIVE;
-                                       else
-                                               lpFlags->stAttribs.dwAttribVal |= FILE_ATTRIBUTE_ARCHIVE;
-                               }
-                               else if(cCurUChar == _T('S'))
-                               {
-                                       lpFlags->stAttribs.dwAttribMask |= FILE_ATTRIBUTE_SYSTEM;
-                                       if (bPNegative)
-                                               lpFlags->stAttribs.dwAttribVal &= ~FILE_ATTRIBUTE_SYSTEM;
-                                       else
-                                               lpFlags->stAttribs.dwAttribVal |= FILE_ATTRIBUTE_SYSTEM;
-                               }
-                               else
-                               {
-                                       error_parameter_format((TCHAR)_totupper (*Line));
-                                       return FALSE;
-                               }
-                               break;
-                       case _T('T'):   /* Switch parameters for /T (time field) */
-
-                               /* Ok a switch parameter was given */
-                               lpFlags->stTimeField.bParSetted = TRUE;
-
-                               if (cCurChar == _T(':'))
-                                       /* =V= dead command, used to make the "if" work */
-                                       cCurChar = cCurChar;
-                               else if(cCurUChar == _T('C'))
-                                       lpFlags->stTimeField.eTimeField= TF_CREATIONDATE ;
-                               else if(cCurUChar == _T('A'))
-                                       lpFlags->stTimeField.eTimeField= TF_LASTACCESSEDDATE ;
-                               else if(cCurUChar == _T('W'))
-                                       lpFlags->stTimeField.eTimeField= TF_MODIFIEDDATE  ;
-                               else
-                               {
-                                       error_parameter_format((TCHAR)_totupper (*Line));
-                                       return FALSE;
-                               }
-                               break;
-                       case _T('O'):   /* Switch parameters for /O (order) */
-                               /* Ok a switch parameter was given */
-                               lpFlags->stOrderBy.bParSetted = TRUE;
-
-                               if (cCurChar == _T(':'))
-                                       /* <== dead command, used to make the "if" work */
-                                       cCurChar = cCurChar;
-                               else if(cCurChar == _T('-'))
-                                       bPNegative = TRUE;
-                               else if(cCurUChar == _T('N'))
-                               {
-                                       if (lpFlags->stOrderBy.sCriteriaCount < 3) lpFlags->stOrderBy.sCriteriaCount++;
-                                       lpFlags->stOrderBy.bCriteriaRev[lpFlags->stOrderBy.sCriteriaCount - 1] = bPNegative;
-                                       lpFlags->stOrderBy.eCriteria[lpFlags->stOrderBy.sCriteriaCount - 1] = ORDER_NAME;
-                               }
-                               else if(cCurUChar == _T('S'))
-                               {
-                                       if (lpFlags->stOrderBy.sCriteriaCount < 3) lpFlags->stOrderBy.sCriteriaCount++;
-                                       lpFlags->stOrderBy.bCriteriaRev[lpFlags->stOrderBy.sCriteriaCount - 1] = bPNegative;
-                                       lpFlags->stOrderBy.eCriteria[lpFlags->stOrderBy.sCriteriaCount - 1] = ORDER_SIZE;
-                               }
-                               else if(cCurUChar == _T('G'))
-                               {
-                                       if (lpFlags->stOrderBy.sCriteriaCount < 3) lpFlags->stOrderBy.sCriteriaCount++;
-                                       lpFlags->stOrderBy.bCriteriaRev[lpFlags->stOrderBy.sCriteriaCount - 1] = bPNegative;
-                                       lpFlags->stOrderBy.eCriteria[lpFlags->stOrderBy.sCriteriaCount - 1] = ORDER_DIRECTORY;
-                               }
-                               else if(cCurUChar == _T('E'))
-                               {
-                                       if (lpFlags->stOrderBy.sCriteriaCount < 3) lpFlags->stOrderBy.sCriteriaCount++;
-                                       lpFlags->stOrderBy.bCriteriaRev[lpFlags->stOrderBy.sCriteriaCount - 1] = bPNegative;
-                                       lpFlags->stOrderBy.eCriteria[lpFlags->stOrderBy.sCriteriaCount - 1] = ORDER_EXTENSION;
-                               }
-                               else if(cCurUChar == _T('D'))
-                               {
-                                       if (lpFlags->stOrderBy.sCriteriaCount < 3) lpFlags->stOrderBy.sCriteriaCount++;
-                                       lpFlags->stOrderBy.bCriteriaRev[lpFlags->stOrderBy.sCriteriaCount - 1] = bPNegative;
-                                       lpFlags->stOrderBy.eCriteria[lpFlags->stOrderBy.sCriteriaCount - 1] = ORDER_TIME;
-                               }
-
-                               else
-                               {
-                                       error_parameter_format((TCHAR)_totupper (*Line));
-                                       return FALSE;
-                               }
-
-
-                       }
-                       /* We check if we calculated the negative value and realese the flag */
-                       if ((cCurChar != _T('-')) && bPNegative)
-                               bPNegative = FALSE;
-               }
-
-               Line++;
-       }
-       /* Terminate the parameters */
-       if(ptrStart && ptrEnd)
-       {               
-               temp = malloc((ptrEnd - ptrStart) + 2 * sizeof (TCHAR));
-               if(!temp)
-                       return FALSE;
-               memcpy(temp, ptrStart, (ptrEnd - ptrStart) + 2 * sizeof (TCHAR));
-               temp[(ptrEnd - ptrStart + 1)] = _T('\0');
-               if(!add_entry(entries, params, temp))
-               {
-                       free(temp);
-                       freep(*params);
-                       return FALSE;
-               }
-
-               free(temp);
-
-               ptrStart = NULL;
-               ptrEnd = NULL;
-       }
-
-       /* Calculate the switches with no switch paramater  */
-       if (!(lpFlags->stAttribs.bParSetted))
-       {
-               lpFlags->stAttribs.dwAttribVal = 0L;
-               lpFlags->stAttribs.dwAttribMask = lpFlags->stAttribs.dwAttribVal;
-       }
-       if (!(lpFlags->stOrderBy.bParSetted))
-       {
-               lpFlags->stOrderBy.sCriteriaCount = 1;
-               lpFlags->stOrderBy.eCriteria[0] = ORDER_NAME;
-               lpFlags->stOrderBy.bCriteriaRev[0] = FALSE;
-       }
-       if (!(lpFlags->stOrderBy.bParSetted))
-               lpFlags->stTimeField.eTimeField = TF_MODIFIEDDATE ;
-
-       /* Calculate the unsetted switches (the "-" prefixed)*/
-       if (lpFlags->stAttribs.bUnSet)
-       {
-               lpFlags->stAttribs.bUnSet = FALSE;
-               lpFlags->stAttribs.dwAttribVal = 0L;
-               lpFlags->stAttribs.dwAttribMask = FILE_ATTRIBUTE_HIDDEN | FILE_ATTRIBUTE_SYSTEM;
-       }
-       if (lpFlags->stOrderBy.bUnSet)
-       {
-               lpFlags->stOrderBy.bUnSet = FALSE;
-               lpFlags->stOrderBy.sCriteriaCount = 0;
-       }
-       if (lpFlags->stTimeField.bUnSet )
-       {
-               lpFlags->stTimeField.bUnSet = FALSE;
-               lpFlags->stTimeField.eTimeField = TF_MODIFIEDDATE;
-       }
-       return TRUE;
-}
-
-
-/*
- * ExtendFilespec
- *
- * extend the filespec, possibly adding wildcards
- */
-static VOID
-ExtendFilespec (LPTSTR file)
-{
-       INT len = 0;
-
-       if (!file)
-               return;
-
-
-       /* if no file spec, change to "*.*" */
-       if (*file == _T('\0'))
-       {
-               _tcscpy (file, _T("*.*"));
-               return;
-       }
-
-       // add support for *.
-       if ((file[0] == _T('*')) && (file[1] == _T('.') ))
-        {
-                return;
-        }
-
-       /* if starts with . add * in front */
-       if (*file == _T('.'))
-       {
-               memmove (&file[1], &file[0], (_tcslen (file) + 1) * sizeof(TCHAR));
-               file[0] = _T('*');
-       }
-
-       /* if no . add .* */
-       if (!_tcschr (file, _T('.')))
-       {
-               _tcscat (file, _T(".*"));
-               return;
-       }
-
-
-
-       /* if last character is '.' add '*' */
-       len = _tcslen (file);
-       if (file[len - 1] == _T('.'))
-       {
-               _tcscat (file, _T("*"));
-               return;
-       }
-}
-
-
-/*
- * dir_parse_pathspec
- *
- * split the pathspec into drive, directory, and filespec
- */
-static INT
-DirParsePathspec (LPTSTR szPathspec, LPTSTR szPath, LPTSTR szFilespec)
-{
-       TCHAR  szOrigPath[MAX_PATH];
-       LPTSTR start;
-       LPTSTR tmp;
-       INT    i;
-       BOOL   bWildcards = FALSE;
-
-       GetCurrentDirectory (MAX_PATH, szOrigPath);
-
-       /* get the drive and change to it */
-       if (szPathspec[1] == _T(':'))
-       {
-               TCHAR szRootPath[] = _T("A:");
-
-               szRootPath[0] = szPathspec[0];
-               start = szPathspec + 2;
-               if (!SetCurrentDirectory (szRootPath))
-               {
-                       ErrorMessage (GetLastError(), NULL);
-                       return 1;
-               }
-       }
-       else
-       {
-               start = szPathspec;
-       }
-
-
-       /* check for wildcards */
-       for (i = 0; szPathspec[i]; i++)
-       {
-               if (szPathspec[i] == _T('*') || szPathspec[i] == _T('?'))
-                       bWildcards = TRUE;
-       }
-
-       /* check if this spec is a directory */
-       if (!bWildcards)
-       {
-               if (SetCurrentDirectory (szPathspec))
-               {
-                       _tcscpy (szFilespec, _T("*.*"));
-
-                       if (!GetCurrentDirectory (MAX_PATH, szPath))
-                       {
-                               szFilespec[0] = _T('\0');
-                               SetCurrentDirectory (szOrigPath);
-                               error_out_of_memory();
-                               return 1;
-                       }
-
-                       SetCurrentDirectory (szOrigPath);
-                       return 0;
-               }
-       }
-
-       /* find the file spec */
-       tmp = _tcsrchr (start, _T('\\'));
-
-       /* if no path is specified */
-       if (!tmp)
-       {
-               _tcscpy (szFilespec, start);
-               ExtendFilespec (szFilespec);
-               if (!GetCurrentDirectory (MAX_PATH, szPath))
-               {
-                       szFilespec[0] = _T('\0');
-                       SetCurrentDirectory (szOrigPath);
-                       error_out_of_memory();
-                       return 1;
-               }
-
-               SetCurrentDirectory (szOrigPath);
-               return 0;
-       }
-
-       /* get the filename */
-       _tcscpy (szFilespec, tmp+1);
-       ExtendFilespec (szFilespec);
-
-       if (tmp == start)
-       {
-               /* change to the root directory */
-               if (!SetCurrentDirectory (_T("\\")))
-               {
-                       szFilespec[0] = _T('\0');
-                       SetCurrentDirectory (szOrigPath);
-                       error_path_not_found ();
-                       return 1;
-               }
-       }
-       else
-       {
-               *tmp = _T('\0');
-
-               /* change to this directory */
-               if (!SetCurrentDirectory (start))
-               {
-                       *tmp = _T('\\');
-                       szFilespec[0] = _T('\0');
-                       SetCurrentDirectory (szOrigPath);
-                       error_path_not_found ();
-                       return 1;
-               }
-       }
-
-       /* get the full name of the directory */
-       if (!GetCurrentDirectory (MAX_PATH, szPath))
-       {
-               *tmp = _T('\\');
-               szFilespec[0] = _T('\0');
-               SetCurrentDirectory (szOrigPath);
-               error_out_of_memory ();
-               return 1;
-       }
-
-       *tmp = _T('\\');
-
-       SetCurrentDirectory (szOrigPath);
-
-       return 0;
-}
-
-
-/*
- * incline
- *
- * increment our line if paginating, display message at end of screen
- */
-#if 0
-static BOOL
-IncLine (LPINT pLine, LPDIRSWITCHFLAGS lpFlags)
-{
-       BOOL bError;
-       CONSOLE_SCREEN_BUFFER_INFO lpConsoleScreenBufferInfo;
-       LONG WindowHeight;
-
-       bError = GetConsoleScreenBufferInfo(hConsole, &lpConsoleScreenBufferInfo);
-
-       WindowHeight = lpConsoleScreenBufferInfo.srWindow.Bottom - lpConsoleScreenBufferInfo.srWindow.Top;
-
-       /* That prevents bad behiour if WindowHeight could not be calculated */
-       if (!WindowHeight)
-       {
-                WindowHeight= 1000000;
-       }
-
-       if (!(lpFlags->bPause))
-               return FALSE;
-
-       (*pLine)++;
-
-       /*
-        * Because I don't know if WindowsHeight work in all cases,
-        * perhaps then maxy is the right value
-        */
-       if (*pLine >= (int)maxy - 2 || *pLine >= WindowHeight)
-       {
-               *pLine = 0;
-               return (PagePrompt () == PROMPT_BREAK);
-       }
-
-       return FALSE;
-}
-#endif
-
-/*
- * PrintDirectoryHeader
- *
- * print the header for the dir command
- */
-static BOOL
-PrintDirectoryHeader(LPTSTR szPath, LPINT pLine, LPDIRSWITCHFLAGS lpFlags)
-{
-  TCHAR szMsg[RC_STRING_MAX_SIZE];
-  TCHAR szRootName[MAX_PATH];
-  TCHAR szVolName[80];
-  DWORD dwSerialNr;
-  LPTSTR p;
-
-  if (lpFlags->bBareFormat)
-    return TRUE;
-
-  /* build usable root path */
-  if (szPath[1] == _T(':') && szPath[2] == _T('\\'))
-    {
-      /* normal path */
-      szRootName[0] = szPath[0];
-      szRootName[1] = _T(':');
-      szRootName[2] = _T('\\');
-      szRootName[3] = 0;
-    }
-  else if (szPath[0] == _T('\\') && szPath[1] == _T('\\'))
-    {
-      /* UNC path */
-      p = _tcschr(&szPath[2], _T('\\'));
-      if (p == NULL)
-       {
-         error_invalid_drive();
-         return(FALSE);
-       }
-      p = _tcschr(p+1, _T('\\'));
-      if (p == NULL)
-       {
-         _tcscpy(szRootName, szPath);
-         _tcscat(szRootName, _T("\\"));
-       }
-      else
-       {
-         *p = 0;
-         _tcscpy(szRootName, szPath);
-         _tcscat(szRootName, _T("\\"));
-         *p = _T('\\');
-       }
-    }
-  else
-    {
-      error_invalid_drive();
-      return(FALSE);
-    }
-
-  /* get the media ID of the drive */
-  if (!GetVolumeInformation(szRootName, szVolName, 80, &dwSerialNr,
-                           NULL, NULL, NULL, 0))
-    {
-      error_invalid_drive();
-      return(FALSE);
-    }
-
-  /* print drive info */
-  if (szVolName[0] != _T('\0'))
-    {
-      LoadString(CMD_ModuleHandle, STRING_DIR_HELP2, szMsg, RC_STRING_MAX_SIZE);
-      //needs to have first paramter as TRUE because
-         //this is the first output and need to clear the static
-         if(lpFlags->bPause)
-                ConOutPrintfPaging(TRUE,szMsg, szRootName[0], szVolName);
-         else
-                ConOutPrintf(szMsg, szRootName[0], szVolName);
-                
-    }
-  else
-    {
-      LoadString(CMD_ModuleHandle, STRING_DIR_HELP3, szMsg, RC_STRING_MAX_SIZE);
-       if(lpFlags->bPause)
-                ConOutPrintfPaging(TRUE,szMsg, szRootName[0]);
-       else
-                ConOutPrintf(szMsg, szRootName[0]);
-    }
-
-  /* print the volume serial number if the return was successful */
-  LoadString(CMD_ModuleHandle, STRING_DIR_HELP4, (LPTSTR) szMsg, RC_STRING_MAX_SIZE);
-  if(lpFlags->bPause)
-        ConOutPrintfPaging(FALSE,szMsg,
-               HIWORD(dwSerialNr),
-               LOWORD(dwSerialNr));
-  else
-        ConOutPrintf(szMsg,
-               HIWORD(dwSerialNr),
-               LOWORD(dwSerialNr));
-
-
-  return TRUE;
-}
-
-
-/*
- * convert
- *
- * insert commas into a number
- *
- */
-#if 0
-static INT
-ConvertULong (ULONG num, LPTSTR des, INT len)
-{
-       TCHAR temp[32];
-       INT c = 0;
-       INT n = 0;
-
-       if (num == 0)
-       {
-               des[0] = _T('0');
-               des[1] = _T('\0');
-               n = 1;
-       }
-       else
-       {
-               temp[31] = 0;
-               while (num > 0)
-               {
-                       if (((c + 1) % (nNumberGroups + 1)) == 0)
-                               temp[30 - c++] = cThousandSeparator;
-                       temp[30 - c++] = (TCHAR)(num % 10) + _T('0');
-                       num /= 10;
-               }
-
-               for (n = 0; n <= c; n++)
-                       des[n] = temp[31 - c + n];
-       }
-
-       return n;
-}
-#endif
-
-static VOID
-DirPrintFileDateTime(TCHAR *lpDate,
-                     TCHAR *lpTime,
-                     LPWIN32_FIND_DATA lpFile,
-                     LPDIRSWITCHFLAGS lpFlags)
-{
-       FILETIME ft;
-       SYSTEMTIME dt;
-       TCHAR szDate[30];
-       TCHAR szTime[30];
-       WORD wYear;
-
-       /* Select the right time field */
-       switch (lpFlags->stTimeField.eTimeField)
-       {
-               case TF_CREATIONDATE:
-                       if (!FileTimeToLocalFileTime(&lpFile->ftCreationTime, &ft))
-                               return;
-                       FileTimeToSystemTime(&ft, &dt);
-                       break;
-
-               case TF_LASTACCESSEDDATE :
-                       if (!FileTimeToLocalFileTime(&lpFile->ftLastAccessTime, &ft))
-                               return;
-                       FileTimeToSystemTime(&ft, &dt);
-                       break;
-
-               case TF_MODIFIEDDATE:
-                       if (!FileTimeToLocalFileTime(&lpFile->ftLastWriteTime, &ft))
-                               return;
-                       FileTimeToSystemTime(&ft, &dt);
-                       break;
-       }
-
-       /* Format date */
-       wYear = (lpFlags->b4Digit) ? dt.wYear : dt.wYear%100;
-       switch (nDateFormat)
-       {
-               case 0: /* mmddyy */
-               default:
-                       _stprintf (szDate, _T("%02d%c%02d%c%0*d"),
-                                       dt.wMonth, cDateSeparator,
-                                       dt.wDay, cDateSeparator,
-                                       lpFlags->b4Digit?4:2, wYear);
-                       break;
-
-               case 1: /* ddmmyy */
-                       _stprintf (szDate, _T("%02d%c%02d%c%0*d"),
-                                       dt.wDay, cDateSeparator, dt.wMonth,
-                                       cDateSeparator,lpFlags->b4Digit?4:2, wYear);
-                       break;
-
-               case 2: /* yymmdd */
-                       _stprintf (szDate, _T("%0*d%c%02d%c%02d"),
-                                       lpFlags->b4Digit?4:2, wYear, cDateSeparator,
-                                       dt.wMonth, cDateSeparator, dt.wDay);
-                       break;
-       }
-       /* Format Time */
-       switch (nTimeFormat)
-       {
-               case 0: /* 12 hour format */
-               default:
-                       _stprintf (szTime,_T("  %02d%c%02u%c"),
-                                       (dt.wHour == 0 ? 12 : (dt.wHour <= 12 ? dt.wHour : dt.wHour - 12)),
-                                       cTimeSeparator,
-                                        dt.wMinute, (dt.wHour <= 11 ? _T('a') : _T('p')));
-                       break;
-
-               case 1: /* 24 hour format */
-                       _stprintf (szTime, _T("  %02d%c%02u"),
-                                       dt.wHour, cTimeSeparator, dt.wMinute);
-                       break;
-       }
-       /* Copy results */
-       _tcscpy(lpDate, szDate);
-       _tcscpy(lpTime, szTime);
-}
-
-
-static VOID
-GetUserDiskFreeSpace(LPCTSTR lpRoot,
-                    PULARGE_INTEGER lpFreeSpace)
-{
-  PGETFREEDISKSPACEEX pGetFreeDiskSpaceEx;
-  HINSTANCE hInstance;
-  DWORD dwSecPerCl;
-  DWORD dwBytPerSec;
-  DWORD dwFreeCl;
-  DWORD dwTotCl;
-  ULARGE_INTEGER TotalNumberOfBytes, TotalNumberOfFreeBytes;
-
-  lpFreeSpace->QuadPart = 0;
-
-  hInstance = LoadLibrary(_T("KERNEL32"));
-  if (hInstance != NULL)
-    {
-      pGetFreeDiskSpaceEx = (PGETFREEDISKSPACEEX)GetProcAddress(hInstance,
-#ifdef _UNICODE
-                                                               "GetDiskFreeSpaceExW");
-#else
-                                                               "GetDiskFreeSpaceExA");
-#endif
-      if (pGetFreeDiskSpaceEx != NULL)
-       {
-         if (pGetFreeDiskSpaceEx(lpRoot, lpFreeSpace, &TotalNumberOfBytes, &TotalNumberOfFreeBytes) == TRUE)
-           return;
-       }
-      FreeLibrary(hInstance);
-    }
-
-  GetDiskFreeSpace(lpRoot,
-                  &dwSecPerCl,
-                  &dwBytPerSec,
-                  &dwFreeCl,
-                  &dwTotCl);
-
-  lpFreeSpace->QuadPart = dwSecPerCl * dwBytPerSec * dwFreeCl;
-}
-
-
-/*
- * print_summary: prints dir summary
- * Added by Rob Lake 06/17/98 to compact code
- * Just copied Tim's Code and patched it a bit
- *
- */
-static INT
-PrintSummary(LPTSTR szPath,
-            ULONG ulFiles,
-            ULONG ulDirs,
-            ULARGE_INTEGER u64Bytes,
-            LPINT pLine,
-            LPDIRSWITCHFLAGS lpFlags)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       TCHAR szBuffer[64];
-       ULARGE_INTEGER uliFree;
-       TCHAR szRoot[] = _T("A:\\");
-
-
-       /* Here we check if we didn't find anything */
-       if (!(ulFiles + ulDirs))
-       {
-               error_file_not_found();
-               return 1;
-       }
-
-
-       /* In bare format we don't print results */
-       if (lpFlags->bBareFormat)
-               return 0;
-
-       /* Print recursive specific results */
-       
-    /* Take this code offline to fix /S does not print duoble info */
-   if (lpFlags->bRecursive)
-   {
-      ConvertULargeInteger(u64Bytes, szBuffer, sizeof(szBuffer), lpFlags->bTSeperator);
-      LoadString(CMD_ModuleHandle, STRING_DIR_HELP5, szMsg, RC_STRING_MAX_SIZE);
-      if(lpFlags->bPause)
-         ConOutPrintfPaging(FALSE,szMsg,ulFiles, szBuffer);
-      else
-         ConOutPrintf(szMsg,ulFiles, szBuffer);
-   }
-   else
-   {
-
-      /* Print File Summary */
-      /* Condition to print summary is:
-      If we are not in bare format and if we have results! */
-      if (ulFiles > 0)
-      {
-         ConvertULargeInteger(u64Bytes, szBuffer, 20, lpFlags->bTSeperator);
-         LoadString(CMD_ModuleHandle, STRING_DIR_HELP8, szMsg, RC_STRING_MAX_SIZE);
-         if(lpFlags->bPause)
-            ConOutPrintfPaging(FALSE,szMsg,ulFiles, szBuffer);
-         else
-            ConOutPrintf(szMsg,ulFiles, szBuffer);
-
-      }
-
-   }
-       /* Print total directories and freespace */
-       szRoot[0] = szPath[0];
-       GetUserDiskFreeSpace(szRoot, &uliFree);
-       ConvertULargeInteger(uliFree, szBuffer, sizeof(szBuffer), lpFlags->bTSeperator);
-       LoadString(CMD_ModuleHandle, STRING_DIR_HELP6, (LPTSTR) szMsg, RC_STRING_MAX_SIZE);
-       if(lpFlags->bPause)
-          ConOutPrintfPaging(FALSE,szMsg,ulDirs, szBuffer);
-       else
-          ConOutPrintf(szMsg,ulDirs, szBuffer);
-
-       return 0;
-}
-
-/*
- * getExt
- *
- * Get the extension of a filename
- */
-TCHAR* getExt(const TCHAR* file)
-{
-        static TCHAR *NoExt = _T("");
-        TCHAR* lastdot = _tcsrchr(file, _T('.'));
-       return (lastdot != NULL ? lastdot + 1 : NoExt);
-}
-
-/*
- * getName
- *
- * Get the name of the file without extension
- */
-static LPTSTR 
-getName(const TCHAR* file, TCHAR * dest)
-{
-       int iLen;
-       LPTSTR end;
-
-       /* Check for "." and ".." folders */
-       if ((_tcscmp(file, _T(".")) == 0) ||
-           (_tcscmp(file, _T("..")) == 0))
-       {
-               _tcscpy(dest,file);
-               return dest;
-       }
-
-       end = _tcsrchr(file, _T('.'));
-       if (!end)
-               iLen = _tcslen(file);
-       else
-               iLen = (end - file);
-
-
-       _tcsncpy(dest, file, iLen);
-       *(dest + iLen) = _T('\0');
-
-       return dest;
-}
-
-
-/*
- *  DirPrintNewList
- *
- * The function that prints in new style
- */
-static VOID
-DirPrintNewList(LPWIN32_FIND_DATA ptrFiles[],  /* [IN]Files' Info */
-               DWORD dwCount,                  /* [IN] The quantity of files */
-               TCHAR *szCurPath,               /* [IN] Full path of current directory */
-               LPDIRSWITCHFLAGS lpFlags)       /* [IN] The flags used */
-{
-  DWORD i;
-  TCHAR szSize[30];
-  TCHAR szShortName[15];
-  TCHAR szDate[20];
-  TCHAR szTime[20];
-  INT iSizeFormat;
-  ULARGE_INTEGER u64FileSize;
-
-  for (i = 0;i < dwCount;i++)
-  {
-    /* Calculate size */
-    if (ptrFiles[i]->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-    {
-      /* Directory */
-      iSizeFormat = -14;
-      _tcscpy(szSize, _T("<DIR>"));
-    }
-    else
-    {
-      /* File */
-      iSizeFormat = 14;
-      u64FileSize.HighPart = ptrFiles[i]->nFileSizeHigh;
-      u64FileSize.LowPart = ptrFiles[i]->nFileSizeLow;
-      ConvertULargeInteger(u64FileSize, szSize, 20, lpFlags->bTSeperator);
-    }
-
-    /* Calculate short name */
-    szShortName[0] = _T('\0');
-    if (lpFlags->bShortName)
-      _stprintf(szShortName, _T(" %-12s"), ptrFiles[i]->cAlternateFileName);
-
-    /* Format date and time */
-    DirPrintFileDateTime(szDate, szTime, ptrFiles[i], lpFlags);
-
-    /* Print the line */
-    if(lpFlags->bPause)
-       {
-               if (ConOutPrintfPaging(FALSE,_T("%10s  %-8s    %*s%s %s\n"),
-                                                       szDate,
-                                                       szTime,
-                                                       iSizeFormat,
-                                                       szSize,
-                                                       szShortName,
-                                                       ptrFiles[i]->cFileName) == 1)
-                       return ;
-       }
-       else
-               ConOutPrintf(_T("%10s  %-8s    %*s%s %s\n"),
-                                                       szDate,
-                                                       szTime,
-                                                       iSizeFormat,
-                                                       szSize,
-                                                       szShortName,
-                                                       ptrFiles[i]->cFileName);
-  }
-}
-
-
-/*
- *  DirPrintWideList
- *
- * The function that prints in wide list
- */
-static VOID
-DirPrintWideList(LPWIN32_FIND_DATA ptrFiles[], /* [IN] Files' Info */
-                                DWORD dwCount,                 /* [IN] The quantity of files */
-                                TCHAR *szCurPath,              /* [IN] Full path of current directory */
-                                LPDIRSWITCHFLAGS lpFlags)      /* [IN] The flags used */
-{
-  SHORT iScreenWidth;
-  USHORT iColumns;
-  USHORT iLines;
-  UINT iLongestName;
-  TCHAR szTempFname[MAX_PATH];
-  DWORD i;
-  DWORD j;
-  DWORD temp;
-
-  /* Calculate longest name */
-  iLongestName = 1;
-  for (i = 0; i < dwCount; i++)
-  {
-    if (ptrFiles[i]->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-    {
-      /* Directories need 2 additinal characters for brackets */
-      if ((_tcslen(ptrFiles[i]->cFileName) + 2) > iLongestName)
-        iLongestName = _tcslen(ptrFiles[i]->cFileName) + 2;
-    }
-    else
-    {
-      if (_tcslen(ptrFiles[i]->cFileName) > iLongestName)
-        iLongestName = _tcslen(ptrFiles[i]->cFileName);
-    }
-  }
-
-  /* Count the highest number of columns */
-  GetScreenSize(&iScreenWidth, 0);
-  iColumns = iScreenWidth / iLongestName;
-
-  /* Check if there is enough space for spaces between names */
-  if (((iLongestName * iColumns) + iColumns) >= (UINT)iScreenWidth)
-    iColumns --;
-
-  /* A last check at iColumns to avoid division by zero */
-  if (!(iColumns))
-    iColumns = 1;
-
-  /* Print Column sorted */
-  if (lpFlags->bWideListColSort)
-  {
-    /* Calculate the lines that will be printed */
-//    iLines = ceil((float)dwCount/(float)iColumns);
-    iLines = (USHORT)(dwCount / iColumns);
-
-    for (i = 0;i < iLines;i++)
-    {
-      for (j = 0; j < iColumns; j++)
-      {
-        temp = (j * iLines) + i;
-        if (temp >= dwCount)
-           break;
-
-        if (ptrFiles[temp]->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-          _stprintf(szTempFname, _T("[%s]"), ptrFiles[temp]->cFileName);
-        else
-          _stprintf(szTempFname, _T("%s"), ptrFiles[temp]->cFileName);
-
-        if(lpFlags->bPause)
-                  ConOutPrintfPaging(FALSE,_T("%-*s"), iLongestName + 1 , szTempFname);
-               else
-                  ConOutPrintf(_T("%-*s"), iLongestName + 1 , szTempFname);
-      }
-
-      if(lpFlags->bPause)
-                ConOutPrintfPaging(FALSE,_T("\n"));
-         else
-                ConOutPrintf(_T("\n"));
-    }
-  }
-  else
-  {
-    /* Print Line sorted */
-    for (i = 0; i < dwCount; i++)
-    {
-      if (ptrFiles[i]->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-        _stprintf(szTempFname, _T("[%s]"), ptrFiles[i]->cFileName);
-      else
-        _stprintf(szTempFname, _T("%s"), ptrFiles[i]->cFileName);
-
-      if(lpFlags->bPause)
-                ConOutPrintfPaging(FALSE,_T("%-*s"), iLongestName + 1, szTempFname );
-         else
-                ConOutPrintf(_T("%-*s"), iLongestName + 1, szTempFname );
-
-      /*
-       * We print a new line at the end of each column
-       * except for the case that it is the last item.
-       */
-         if (!((i + 1) % iColumns) && (i < (dwCount - 1)))
-         {
-                 if(lpFlags->bPause)
-                        ConOutPrintfPaging(FALSE,_T("\n"));
-                 else
-                    ConOutPrintf(_T("\n"));
-         }
-    }
-
-    /* Add a new line after the last item */
-    if(lpFlags->bPause)
-          ConOutPrintfPaging(FALSE,_T("\n"));
-       else
-          ConOutPrintf(_T("\n"));
-  }
-}
-
-
-/*
- *  DirPrintOldList
- *
- * The function that prints in old style
- */
-static VOID
-DirPrintOldList(LPWIN32_FIND_DATA ptrFiles[],  /* [IN] Files' Info */
-                               DWORD dwCount,                                  /* [IN] The quantity of files */
-                               TCHAR * szCurPath,                              /* [IN] Full path of current directory */
-                               LPDIRSWITCHFLAGS lpFlags)               /* [IN] The flags used */
-{
-DWORD i;                                               /* An indexer for "for"s */
-TCHAR szName[10];                              /* The name of file */
-TCHAR szExt[5];                                        /* The extension of file */
-TCHAR szDate[30],szTime[30];   /* Used to format time and date */
-TCHAR szSize[30];                              /* The size of file */
-int iSizeFormat;                               /* The format of size field */
-ULARGE_INTEGER u64FileSize;            /* The file size */
-
-       for(i = 0;i < dwCount;i++)
-       {
-               /* Broke 8.3 format */
-               if (*ptrFiles[i]->cAlternateFileName )
-               {
-                       /* If the file is long named then we read the alter name */
-                       getName( ptrFiles[i]->cAlternateFileName, szName);
-                       _tcscpy(szExt, getExt( ptrFiles[i]->cAlternateFileName));
-               }
-               else
-               {
-                       /* If the file is not long name we read its original name */
-                       getName( ptrFiles[i]->cFileName, szName);
-                       _tcscpy(szExt, getExt( ptrFiles[i]->cFileName));
-               }
-
-               /* Calculate size */
-               if (ptrFiles[i]->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-               {
-                       /* Directory, no size it's a directory*/
-                       iSizeFormat = -17;
-                       _tcscpy(szSize, _T("<DIR>"));
-               }
-               else
-               {
-                       /* File */
-                       iSizeFormat = 17;
-                       u64FileSize.HighPart = ptrFiles[i]->nFileSizeHigh;
-                       u64FileSize.LowPart = ptrFiles[i]->nFileSizeLow;
-                       ConvertULargeInteger(u64FileSize, szSize, 20, lpFlags->bTSeperator);
-               }
-
-               /* Format date and time */
-               DirPrintFileDateTime(szDate,szTime,ptrFiles[i],lpFlags);
-
-               /* Print the line */
-               if(lpFlags->bPause)
-               {
-                  if (ConOutPrintfPaging(FALSE,_T("%-8s %-3s  %*s %s  %s\n"),
-                                                               szName,                 /* The file's 8.3 name */
-                                                               szExt,                  /* The file's 8.3 extension */
-                                                               iSizeFormat,    /* print format for size column */
-                                                               szSize,                 /* The size of file or "<DIR>" for dirs */
-                                                               szDate,                 /* The date of file/dir */
-                                                               szTime) == 1)           /* The time of file/dir */
-                       {
-                               return ;
-                       }
-               }
-               else
-                  ConOutPrintf(_T("%-8s %-3s  %*s %s  %s\n"),
-                                                               szName,                 /* The file's 8.3 name */
-                                                               szExt,                  /* The file's 8.3 extension */
-                                                               iSizeFormat,    /* print format for size column */
-                                                               szSize,                 /* The size of file or "<DIR>" for dirs */
-                                                               szDate,                 /* The date of file/dir */
-                                                               szTime);                /* The time of file/dir */
-       }
-}
-
-/*
- *  DirPrintBareList
- *
- * The function that prints in bare format
- */
-static VOID
-DirPrintBareList(LPWIN32_FIND_DATA ptrFiles[], /* [IN] Files' Info */
-                                DWORD dwCount,                 /* [IN] The number of files */
-                                LPTSTR lpCurPath,              /* [IN] Full path of current directory */
-                                LPDIRSWITCHFLAGS lpFlags)      /* [IN] The flags used */
-{
-       TCHAR szFullName[MAX_PATH];
-       DWORD i;
-
-       for (i = 0; i < dwCount; i++)
-       {
-               if ((_tcscmp(ptrFiles[i]->cFileName, _T(".")) == 0) ||
-                   (_tcscmp(ptrFiles[i]->cFileName, _T("..")) == 0))
-               {
-                       /* at bare format we don't print "." and ".." folder */
-                       continue;
-               }
-               if (lpFlags->bRecursive)
-               {
-                       /* at recursive mode we print full path of file */
-                       _tcscpy(szFullName, lpCurPath);
-                       _tcscat(szFullName, ptrFiles[i]->cFileName);
-                       if(lpFlags->bPause)
-                       {
-                          if (ConOutPrintfPaging(FALSE,_T("%s\n"), szFullName) == 1)
-                               {
-                                       return ;
-                               }
-                       }
-                       else
-                          ConOutPrintf(_T("%s\n"), szFullName);
-               }
-               else
-               {
-                       /* if we are not in recursive mode we print the file names */
-                       if(lpFlags->bPause)
-                       {
-                          if (ConOutPrintfPaging(FALSE,_T("%s\n"),ptrFiles[i]->cFileName) == 1)
-                               {
-                                       return ;
-                               }
-                       }
-                       else
-                          ConOutPrintf(_T("%s\n"),ptrFiles[i]->cFileName);
-               }
-       }
-}
-
-
-/*
- * DirPrintFiles
- *
- * The functions that prints the files list
- */
-static VOID
-DirPrintFiles(LPWIN32_FIND_DATA ptrFiles[],    /* [IN] Files' Info */
-                         DWORD dwCount,                        /* [IN] The quantity of files */
-                         TCHAR *szCurPath,                     /* [IN] Full path of current directory */
-                         LPDIRSWITCHFLAGS lpFlags)             /* [IN] The flags used */
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       TCHAR szTemp[MAX_PATH];                 /* A buffer to format the directory header */
-
-       /* Print directory header */
-       _tcscpy(szTemp, szCurPath);
-
-       /* We cut the trailing \ of the full path */
-       szTemp[_tcslen(szTemp)-1] = _T('\0');
-
-       /* Condition to print header:
-          We are not printing in bare format
-          and if we are in recursive mode... we must have results */
-       if (!(lpFlags->bBareFormat ) && !((lpFlags->bRecursive) && (dwCount <= 0)))
-       {
-               LoadString(CMD_ModuleHandle, STRING_DIR_HELP7, szMsg, RC_STRING_MAX_SIZE);
-               if(lpFlags->bPause)
-               {
-                  if (ConOutPrintfPaging(FALSE,szMsg, szTemp) == 1)
-                       {
-                               return ;
-                       }
-               }
-               else
-                  ConOutPrintf(szMsg, szTemp);
-       }
-
-       if (lpFlags->bBareFormat)
-       {
-               /* Bare format */
-               DirPrintBareList(ptrFiles, dwCount, szCurPath, lpFlags);
-       }
-       else if(lpFlags->bShortName)
-       {
-               /* New list style / Short names */
-               DirPrintNewList(ptrFiles, dwCount, szCurPath, lpFlags);
-       }
-       else if(lpFlags->bWideListColSort || lpFlags->bWideList)
-       {
-               /* Wide list */
-               DirPrintWideList(ptrFiles, dwCount, szCurPath, lpFlags);
-       }
-       else if (lpFlags->bNewLongList )
-       {
-               /* New list style*/
-               DirPrintNewList(ptrFiles, dwCount, szCurPath, lpFlags);
-       }
-       else
-       {
-               /* If nothing is selected old list is the default */
-               DirPrintOldList(ptrFiles, dwCount, szCurPath, lpFlags);
-       }
-}
-
-
-
-/*
- * CompareFiles
- *
- * Compares 2 files based on the order criteria
- */
-static BOOL
-CompareFiles(LPWIN32_FIND_DATA lpFile1,        /* [IN] A pointer to WIN32_FIND_DATA of file 1 */
-                        LPWIN32_FIND_DATA lpFile2,     /* [IN] A pointer to WIN32_FIND_DATA of file 2 */
-                        LPDIRSWITCHFLAGS lpFlags)      /* [IN] The flags that we use to list */
-{
-  ULARGE_INTEGER u64File1;
-  ULARGE_INTEGER u64File2;
-  int i;
-  long iComp = 0;                                      /* The comparison result */
-
-       /* Calculate critiries by order given from user */
-       for (i = 0;i < lpFlags->stOrderBy.sCriteriaCount;i++)
-       {
-
-               /* Calculate criteria */
-               switch(lpFlags->stOrderBy.eCriteria[i])
-               {
-               case ORDER_SIZE:                /* Order by size /o:s */
-                       /* concat the 32bit integers to a 64bit */
-                       u64File1.LowPart = lpFile1->nFileSizeLow;
-                       u64File1.HighPart = lpFile1->nFileSizeHigh;
-                       u64File2.LowPart = lpFile2->nFileSizeLow;
-                       u64File2.HighPart = lpFile2->nFileSizeHigh;
-
-                       /* In case that differnce is too big for a long */
-                       if (u64File1.QuadPart < u64File2.QuadPart)
-                               iComp = -1;
-                       else if (u64File1.QuadPart > u64File2.QuadPart)
-                               iComp = 1;
-                       else
-                               iComp = 0;
-                       break;
-
-               case ORDER_DIRECTORY:   /* Order by directory attribute /o:g */
-                       iComp = ((lpFile2->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)-
-                               (lpFile1->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY));
-                       break;
-
-               case ORDER_EXTENSION:   /* Order by extension name /o:e */
-                       iComp = _tcsicmp(getExt(lpFile1->cFileName),getExt(lpFile2->cFileName));
-                       break;
-
-               case ORDER_NAME:                /* Order by filename /o:n */
-                       iComp = _tcsicmp(lpFile1->cFileName, lpFile2->cFileName);
-                       break;
-
-               case ORDER_TIME:                /* Order by file's time /o:t */
-                       /* We compare files based on the time field selected by /t */
-                       switch(lpFlags->stTimeField.eTimeField)
-                       {
-                       case TF_CREATIONDATE:
-                               /* concat the 32bit integers to a 64bit */
-                               u64File1.LowPart = lpFile1->ftCreationTime.dwLowDateTime;
-                               u64File1.HighPart = lpFile1->ftCreationTime.dwHighDateTime ;
-                               u64File2.LowPart = lpFile2->ftCreationTime.dwLowDateTime;
-                               u64File2.HighPart = lpFile2->ftCreationTime.dwHighDateTime ;
-                               break;
-                       case TF_LASTACCESSEDDATE :
-                               /* concat the 32bit integers to a 64bit */
-                               u64File1.LowPart = lpFile1->ftLastAccessTime.dwLowDateTime;
-                               u64File1.HighPart = lpFile1->ftLastAccessTime.dwHighDateTime ;
-                               u64File2.LowPart = lpFile2->ftLastAccessTime.dwLowDateTime;
-                               u64File2.HighPart = lpFile2->ftLastAccessTime.dwHighDateTime ;
-                               break;
-                       case TF_MODIFIEDDATE:
-                               /* concat the 32bit integers to a 64bit */
-                               u64File1.LowPart = lpFile1->ftLastWriteTime.dwLowDateTime;
-                               u64File1.HighPart = lpFile1->ftLastWriteTime.dwHighDateTime ;
-                               u64File2.LowPart = lpFile2->ftLastWriteTime.dwLowDateTime;
-                               u64File2.HighPart = lpFile2->ftLastWriteTime.dwHighDateTime ;
-                               break;
-                       }
-
-                       /* In case that differnce is too big for a long */
-                       if (u64File1.QuadPart < u64File2.QuadPart)
-                               iComp = -1;
-                       else if (u64File1.QuadPart > u64File2.QuadPart)
-                               iComp = 1;
-                       else
-                               iComp = 0;
-                       break;
-               }
-
-               /* Reverse if desired */
-               if (lpFlags->stOrderBy.bCriteriaRev[i])
-                       iComp *= -1;
-
-               /* If that criteria was enough for distinguishing
-                  the files/dirs,there is no need to calculate the others*/
-               if (iComp != 0) break;
-       }
-
-       /* Translate the value of iComp to boolean */
-       if (iComp > 0)
-               return TRUE;
-       else
-               return FALSE;
-}
-
-/*
- * QsortFiles
- *
- * Sort files by the order criterias using quicksort method
- */
-static VOID
-QsortFiles(LPWIN32_FIND_DATA ptrArray[],       /* [IN/OUT] The array with file info pointers */
-          int i,                               /* [IN]     The index of first item in array */
-          int j,                               /* [IN]     The index to last item in array */
-          LPDIRSWITCHFLAGS lpFlags)            /* [IN]     The flags that we will use to sort */
-{
-       LPWIN32_FIND_DATA lpTemp;       /* A temporary pointer */
-       int First, Last, Temp;
-       BOOL Way;
-
-       if (i < j)
-       {
-               First = i;
-               Last = j;
-               Way = TRUE;
-               while (i != j)
-               {
-                       if (Way == CompareFiles(ptrArray[i], ptrArray[j], lpFlags))
-                       {
-                               /* Swap the pointers of the array */
-                               lpTemp = ptrArray[i];
-                               ptrArray[i]= ptrArray[j];
-                               ptrArray[j] = lpTemp;
-
-                               /* Swap the indexes for inverting sorting */
-                               Temp = i;
-                               i = j;
-                               j =Temp;
-
-                               Way = !Way;
-                       }
-
-                       j += (!Way - Way);
-               }
-
-               QsortFiles(ptrArray,First, i-1, lpFlags);
-               QsortFiles(ptrArray,i+1,Last, lpFlags);
-       }
-}
-
-
-
-/*
- * DirList
- *
- * The functions that does everything except for printing results
- */
-static INT
-DirList(LPTSTR szPath,                 /* [IN] The path that dir starts */
-               LPTSTR szFilespec,              /* [IN] The type of file that we are looking for */
-               LPINT pLine,                    /* FIXME: Maybe used for paginating */
-               LPDIRSWITCHFLAGS lpFlags)       /* [IN] The flags of the listing */
-{
-       HANDLE hSearch;                                                 /* The handle of the search */
-       HANDLE hRecSearch;                                              /* The handle for searching recursivly */
-       WIN32_FIND_DATA wfdFileInfo;                    /* The info of file that found */
-       LPWIN32_FIND_DATA * ptrFileArray;               /* An array of pointers with all the files */
-       PDIRFINDLISTNODE ptrStartNode;  /* The pointer to the first node */
-       PDIRFINDLISTNODE ptrNextNode;   /* A pointer used for relatives refernces */
-TCHAR szFullPath[MAX_PATH];                            /* The full path that we are listing with trailing \ */
-TCHAR szFullFileSpec[MAX_PATH];                        /* The full path with file specs that we ll request\ */
-DWORD dwCount;                                                 /* A counter of files found in directory */
-DWORD dwCountFiles;                                            /* Counter for files */
-DWORD dwCountDirs;                                             /* Counter for directories */
-ULARGE_INTEGER u64CountBytes;                  /* Counter for bytes */
-ULARGE_INTEGER u64Temp;                                        /* A temporary counter */
-
-       /* Initialize Variables */
-       ptrStartNode = NULL;
-       ptrNextNode = NULL;
-       dwCount = 0;
-       dwCountFiles = 0;
-       dwCountDirs = 0;
-       u64CountBytes.QuadPart = 0;
-
-       /* Create szFullPath and szFullFileSpec */
-       _tcscpy (szFullPath, szPath);
-       if (szFullPath[_tcslen(szFullPath) - 1] != _T('\\'))
-               _tcscat (szFullPath, _T("\\"));
-       _tcscpy (szFullFileSpec, szFullPath);
-       _tcscat (szFullFileSpec, szFilespec);
-
-       /* Prepare the linked list, first node is allocated */
-       ptrStartNode = malloc(sizeof(DIRFINDLISTNODE));
-       if (ptrStartNode == NULL)
-       {
-#ifdef _DEBUG
-               ConErrPrintf(_T("DEBUG: Cannot allocate memory for ptrStartNode!\n"));
-#endif
-               return 1;       /* Error cannot allocate memory for 1st object */
-       }
-       ptrNextNode = ptrStartNode;
-
-       /* Collect the results for the current folder */
-       hSearch = FindFirstFile(szFullFileSpec, &wfdFileInfo);
-       do
-       {
-               if (hSearch != INVALID_HANDLE_VALUE)
-               {
-                       /* Here we filter all the specified attributes */
-                       if ((wfdFileInfo.dwFileAttributes & lpFlags->stAttribs.dwAttribMask )
-                               == (lpFlags->stAttribs.dwAttribMask & lpFlags->stAttribs.dwAttribVal ))
-                       {
-                               ptrNextNode->ptrNext = malloc(sizeof(DIRFINDLISTNODE));
-                               if (ptrNextNode->ptrNext == NULL)
-                               {
-#ifdef _DEBUG
-                                       ConErrPrintf(_T("DEBUG: Cannot allocate memory for ptrNextNode->ptrNext!\n"));
-#endif
-                                       while (ptrStartNode)
-                                       {
-                                               ptrNextNode = ptrStartNode->ptrNext;
-                                               free(ptrStartNode);
-                                               ptrStartNode = ptrNextNode;
-                                               dwCount --;
-                                       }
-                                       return 1;
-                               }
-
-                               /* If malloc fails we go to next file in hope it works,
-                                  without braking the linked list! */
-                               if (ptrNextNode->ptrNext)
-                               {
-                                       /* Copy the info of search at linked list */
-                                       memcpy(&ptrNextNode->ptrNext->stFindInfo,
-                                              &wfdFileInfo,
-                                              sizeof(WIN32_FIND_DATA));
-
-                                       /* If lower case is selected do it here */
-                                       if (lpFlags->bLowerCase)
-                                       {
-                                               _tcslwr(ptrNextNode->ptrNext->stFindInfo.cAlternateFileName);
-                                               _tcslwr(ptrNextNode->ptrNext->stFindInfo.cFileName);
-                                       }
-
-                                       /* Continue at next node at linked list */
-                                       ptrNextNode = ptrNextNode->ptrNext;
-                                       dwCount ++;
-
-                                       /* Grab statistics */
-                                       if (wfdFileInfo.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                                       {
-                                               /* Directory */
-                                               dwCountDirs++;
-                                       }
-                                       else
-                                       {
-                                               /* File */
-                                               dwCountFiles++;
-                                               u64Temp.HighPart = wfdFileInfo.nFileSizeHigh;
-                                               u64Temp.LowPart = wfdFileInfo.nFileSizeLow;
-                                               u64CountBytes.QuadPart += u64Temp.QuadPart;
-                                       }
-                               }
-                       }
-               }
-       }while(FindNextFile(hSearch, &wfdFileInfo));
-       FindClose(hSearch);
-
-       /* Terminate list */
-       ptrNextNode->ptrNext = NULL;
-
-       /* Calculate and allocate space need for making an array of pointers */
-       ptrFileArray = malloc(sizeof(LPWIN32_FIND_DATA) * dwCount);
-       if (ptrFileArray == NULL)
-       {
-#ifdef _DEBUG
-               ConErrPrintf(_T("DEBUG: Cannot allocate memory for ptrFileArray!\n"));
-#endif
-               while (ptrStartNode)
-               {
-                       ptrNextNode = ptrStartNode->ptrNext;
-                       free(ptrStartNode);
-                       ptrStartNode = ptrNextNode;
-                       dwCount --;
-               }               
-               return 1;
-       }
-
-       /*
-        * Create an array of pointers from the linked list
-        * this will be used to sort and print data, rather than the list
-        */
-       ptrNextNode = ptrStartNode;
-       dwCount = 0;
-       while (ptrNextNode->ptrNext)
-       {
-               *(ptrFileArray + dwCount) = &ptrNextNode->ptrNext->stFindInfo;
-               ptrNextNode = ptrNextNode->ptrNext;
-               dwCount++;
-       }
-
-       /* Sort Data if requested*/
-       if (lpFlags->stOrderBy.sCriteriaCount > 0)
-               QsortFiles(ptrFileArray, 0, dwCount-1,lpFlags);
-
-       /* Print Data */
-       DirPrintFiles(ptrFileArray, dwCount, szFullPath, lpFlags);
-
-       /* Free array */
-       free(ptrFileArray);
-       if (CheckCtrlBreak(BREAK_INPUT))
-               return 1;
-
-
-       /* Add statistics to recursive statistics*/
-       recurse_dir_cnt += dwCountDirs;
-       recurse_file_cnt += dwCountFiles;
-       recurse_bytes.QuadPart += u64CountBytes.QuadPart;
-
-       /* Do the recursive job if requested
-          the recursive is be done on ALL(indepent of their attribs)
-          directoried of the current one.*/
-       if (lpFlags->bRecursive)
-       {
-               /* The new search is involving any *.* file */
-               _tcscpy(szFullFileSpec, szFullPath);
-               _tcscat(szFullFileSpec, _T("*.*"));
-               hRecSearch = FindFirstFile (szFullFileSpec, &wfdFileInfo);
-               do
-               {
-                       if (hRecSearch != INVALID_HANDLE_VALUE)
-                       {
-                               /* We search for directories other than "." and ".." */
-                               if ((_tcsicmp(wfdFileInfo.cFileName, _T(".")) != 0) &&
-                                   (_tcsicmp(wfdFileInfo.cFileName, _T("..")) != 0 ) &&
-                                   (wfdFileInfo.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY))
-                               {
-                                       /* Concat the path and the directory to do recursive */
-                                       _tcscpy(szFullFileSpec, szFullPath);
-                                       _tcscat(szFullFileSpec, wfdFileInfo.cFileName);
-                                       /* We do the same for tha folder */
-                                       if (DirList(szFullFileSpec, szFilespec, pLine,lpFlags) != 0)
-                                       {
-                                               return 1;
-                                       }
-                               }
-                       }
-               }while(FindNextFile(hRecSearch,&wfdFileInfo));
-               FindClose(hRecSearch);
-       }
-
-       /* Free linked list */
-       while (ptrStartNode)
-       {
-               ptrNextNode = ptrStartNode->ptrNext;
-               free(ptrStartNode);
-               ptrStartNode = ptrNextNode;
-               dwCount --;
-       }
-
-       return 0;
-}
-
-
-
-/*
- * dir
- *
- * internal dir command
- */
-INT 
-CommandDir(LPTSTR first, LPTSTR rest)
-{
-       TCHAR   dircmd[256];    /* A variable to store the DIRCMD enviroment variable */
-       TCHAR   cDrive;
-       TCHAR   szPath[MAX_PATH];
-       TCHAR   szFilespec[MAX_PATH];
-       LPTSTR* params;
-       INT             entries = 0;
-       INT             nLine = 0;
-       UINT    loop = 0;
-       DIRSWITCHFLAGS stFlags;
-
-       /* Initialize variables */
-       cDrive = 0;
-       recurse_dir_cnt = 0L;
-       recurse_file_cnt = 0L;
-       recurse_bytes.QuadPart = 0;
-
-       /* Initialize Switch Flags < Default switches are setted here!> */
-       stFlags.b4Digit = TRUE;
-       stFlags.bBareFormat = FALSE;
-       stFlags.bLowerCase = FALSE;
-       stFlags.bNewLongList = TRUE;
-       stFlags.bPause = FALSE;
-       stFlags.bRecursive = FALSE;
-       stFlags.bShortName = FALSE;
-       stFlags.bTSeperator = TRUE;
-       stFlags.bUser = FALSE;
-       stFlags.bWideList = FALSE;
-       stFlags.bWideListColSort = FALSE;
-       stFlags.stTimeField.eTimeField = TF_MODIFIEDDATE;
-       stFlags.stTimeField.bUnSet = FALSE;
-       stFlags.stAttribs.dwAttribMask = FILE_ATTRIBUTE_HIDDEN | FILE_ATTRIBUTE_SYSTEM;
-       stFlags.stAttribs.dwAttribVal = 0L;
-       stFlags.stAttribs.bUnSet = FALSE;
-       stFlags.stOrderBy.sCriteriaCount = 0;
-       stFlags.stOrderBy.bUnSet = FALSE;
-
-       nErrorLevel = 0;
-       
-       /* read the parameters from the DIRCMD environment variable */
-       if (GetEnvironmentVariable (_T("DIRCMD"), dircmd, 256))
-               if (!DirReadParam(dircmd, &params, &entries, &stFlags))
-               {
-                       nErrorLevel = 1;
-                       return 1;
-               }
-
-       /* read the parameters */
-       if (!DirReadParam(rest, &params, &entries, &stFlags) || CheckCtrlBreak(BREAK_INPUT))
-       {
-               nErrorLevel = 1;
-               return 1;
-       }
-
-       /* default to current directory */
-       if(entries == 0) {
-               if(!add_entry(&entries, &params, _T("."))) {
-                       nErrorLevel = 1;
-                       return 1;
-               }
-       }
-
-       for(loop = 0; loop < entries; loop++)
-       {
-               /* parse the directory info */
-               if (DirParsePathspec (params[loop], szPath, szFilespec) || CheckCtrlBreak(BREAK_INPUT))
-               {
-                       nErrorLevel = 1;
-                       return 1;
-               }
-
-       /* <Debug :>
-          Uncomment this to show the final state of switch flags*/
-       #ifdef _DEBUG
-               {
-                       int i;
-                       ConOutPrintf(_T("Attributes mask/value %x/%x\n"),stFlags.stAttribs.dwAttribMask,stFlags.stAttribs.dwAttribVal  );
-                       ConOutPrintf(_T("(B) Bare format : %i\n"), stFlags.bBareFormat );
-                       ConOutPrintf(_T("(C) Thousand : %i\n"), stFlags.bTSeperator );
-                       ConOutPrintf(_T("(W) Wide list : %i\n"), stFlags.bWideList );
-                       ConOutPrintf(_T("(D) Wide list sort by column : %i\n"), stFlags.bWideListColSort );
-                       ConOutPrintf(_T("(L) Lowercase : %i\n"), stFlags.bLowerCase );
-                       ConOutPrintf(_T("(N) New : %i\n"), stFlags.bNewLongList );
-                       ConOutPrintf(_T("(O) Order : %i\n"), stFlags.stOrderBy.sCriteriaCount );
-                       for (i =0;i<stFlags.stOrderBy.sCriteriaCount;i++)
-                               ConOutPrintf(_T(" Order Criteria [%i]: %i (Reversed: %i)\n"),i, stFlags.stOrderBy.eCriteria[i], stFlags.stOrderBy.bCriteriaRev[i] );
-                       ConOutPrintf(_T("(P) Pause : %i\n"), stFlags.bPause  );
-                       ConOutPrintf(_T("(Q) Owner : %i\n"), stFlags.bUser );
-                       ConOutPrintf(_T("(S) Recursive : %i\n"), stFlags.bRecursive );
-                       ConOutPrintf(_T("(T) Time field : %i\n"), stFlags.stTimeField.eTimeField );
-                       ConOutPrintf(_T("(X) Short names : %i\n"), stFlags.bShortName );
-                       ConOutPrintf(_T("Parameter : %s\n"), params[loop] );
-               }
-       #endif
-
-               /* Print the drive header if the drive changed */
-               if(cDrive != szPath[0] && !stFlags.bBareFormat) {
-                       if (!PrintDirectoryHeader (szPath, &nLine, &stFlags)) {
-                               nErrorLevel = 1;
-                               return 1;
-                       }
-
-                       cDrive = szPath[0];
-               }
-               
-
-               /* do the actual dir */
-               if (DirList (szPath, szFilespec, &nLine, &stFlags))
-               {
-                       nErrorLevel = 1;
-                       return 1;
-               }
-       }
-
-       /* print the footer */
-       PrintSummary(szPath,
-               recurse_file_cnt,
-               recurse_dir_cnt,
-               recurse_bytes,
-               &nLine,
-               &stFlags);
-       
-       return 0;
-}
-
-#endif
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/dirstack.c b/reactos/subsys/system/cmd/dirstack.c
deleted file mode 100644 (file)
index 8d6ad17..0000000
+++ /dev/null
@@ -1,235 +0,0 @@
-/*
- *  DIRSTACK.C - pushd / pop (directory stack) internal commands.
- *
- *
- *  History:
- *
- *    14-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Implemented PUSHD and POPD command.
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection safe!
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added DIRS command.
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef FEATURE_DIRECTORY_STACK
-
-typedef struct tagDIRENTRY
-{
-       struct tagDIRENTRY *prev;
-       struct tagDIRENTRY *next;
-       LPTSTR pszPath;
-} DIRENTRY, *LPDIRENTRY;
-
-
-static INT nStackDepth;
-static LPDIRENTRY lpStackTop;
-static LPDIRENTRY lpStackBottom;
-
-
-static INT
-PushDirectory (LPTSTR pszPath)
-{
-       LPDIRENTRY lpDir;
-
-       nErrorLevel = 0;
-
-       lpDir = (LPDIRENTRY)malloc (sizeof (DIRENTRY));
-       if (!lpDir)
-       {
-               error_out_of_memory ();
-               return -1;
-       }
-
-       lpDir->prev = NULL;
-       if (lpStackTop == NULL)
-       {
-               lpDir->next = NULL;
-               lpStackBottom = lpDir;
-       }
-       else
-       {
-               lpDir->next = lpStackTop;
-               lpStackTop->prev = lpDir;
-       }
-       lpStackTop = lpDir;
-
-       lpDir->pszPath = (LPTSTR)malloc ((_tcslen(pszPath)+1)*sizeof(TCHAR));
-       if (!lpDir->pszPath)
-       {
-               free (lpDir);
-               error_out_of_memory ();
-               return -1;
-       }
-
-       _tcscpy (lpDir->pszPath, pszPath);
-
-       nStackDepth++;
-
-       return 0;
-}
-
-
-static VOID
-PopDirectory (VOID)
-{
-       LPDIRENTRY lpDir;
-
-    nErrorLevel = 0;
-
-       if (nStackDepth == 0)
-               return;
-
-       lpDir = lpStackTop;
-       lpStackTop = lpDir->next;
-       if (lpStackTop != NULL)
-               lpStackTop->prev = NULL;
-       else
-               lpStackBottom = NULL;
-
-       free (lpDir->pszPath);
-       free (lpDir);
-
-       nStackDepth--;
-}
-
-
-static VOID
-GetDirectoryStackTop (LPTSTR pszPath)
-{
-       nErrorLevel = 0;
-
-       if (lpStackTop)
-               _tcsncpy (pszPath, lpStackTop->pszPath, MAX_PATH);
-       else
-               *pszPath = _T('\0');
-}
-
-
-/*
- * initialize directory stack
- */
-VOID InitDirectoryStack (VOID)
-{
-       nStackDepth = 0;
-       lpStackTop = NULL;
-       lpStackBottom = NULL;
-}
-
-
-/*
- * destroy directory stack
- */
-VOID DestroyDirectoryStack (VOID)
-{
-       while (nStackDepth)
-               PopDirectory ();
-}
-
-
-INT GetDirectoryStackDepth (VOID)
-{
-       return nStackDepth;
-}
-
-
-/*
- * pushd command
- */
-INT CommandPushd (LPTSTR first, LPTSTR rest)
-{
-       TCHAR curPath[MAX_PATH];
-       TCHAR newPath[MAX_PATH];
-       BOOL  bChangePath = FALSE;
-
-       if (!_tcsncmp (rest, _T("/?"), 2))
-       {
-               ConOutResPuts(STRING_DIRSTACK_HELP1);
-               return 0;
-       }
-
-       nErrorLevel = 0;
-
-       if (rest[0] != _T('\0'))
-       {
-               GetFullPathName (rest, MAX_PATH, newPath, NULL);
-               bChangePath = IsValidPathName (newPath);
-       }
-
-       GetCurrentDirectory (MAX_PATH, curPath);
-       if (PushDirectory (curPath))
-               return 0;
-
-       if (bChangePath)
-               SetCurrentDirectory (newPath);
-
-       return 0;
-}
-
-
-/*
- * popd command
- */
-INT CommandPopd (LPTSTR first, LPTSTR rest)
-{
-       TCHAR szPath[MAX_PATH];
-
-       if (!_tcsncmp(rest, _T("/?"), 2))
-       {
-               ConOutResPuts(STRING_DIRSTACK_HELP2);
-               return 0;
-       }
-
-       nErrorLevel = 0;
-
-       if (GetDirectoryStackDepth () == 0)
-               return 0;
-
-       GetDirectoryStackTop (szPath);
-       PopDirectory ();
-
-       SetCurrentDirectory (szPath);
-
-       return 0;
-}
-
-
-/*
- * dirs command
- */
-INT CommandDirs (LPTSTR first, LPTSTR rest)
-{
-       LPDIRENTRY lpDir;
-
-       if (!_tcsncmp(rest, _T("/?"), 2))
-       {
-               ConOutResPuts(STRING_DIRSTACK_HELP3);
-               return 0;
-       }
-
-    nErrorLevel = 0;
-
-       lpDir = lpStackBottom;
-
-       if (lpDir == NULL)
-       {
-               ConOutResPuts(STRING_DIRSTACK_HELP4);
-               return 0;
-       }
-
-       while (lpDir != NULL)
-       {
-               ConOutPuts (lpDir->pszPath);
-
-               lpDir = lpDir->prev;
-       }
-
-       return 0;
-}
-
-#endif /* FEATURE_DIRECTORY_STACK */
diff --git a/reactos/subsys/system/cmd/echo.c b/reactos/subsys/system/cmd/echo.c
deleted file mode 100644 (file)
index 0019c15..0000000
+++ /dev/null
@@ -1,181 +0,0 @@
-/*
- *  ECHO.C - internal echo commands.
- *
- *
- *  History:
- *
- *    16 Jul 1998 (Hans B Pufal)
- *        Started.
- *
- *    16 Jul 1998 (John P Price)
- *        Separated commands into individual files.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        Added config.h include
- *
- *    08-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("/?").
- *
- *    19-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection ready!
- *
- *    13-Jul-2000 (Eric Kohl <ekohl@rz-online.de>)
- *        Implemented 'echo.' and 'echoerr.'.
- *
- *    28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-INT CommandEcho (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-        LPTSTR p1, p2;
-
-#ifdef _DEBUG
-       DebugPrintf (_T("CommandEcho '%s' : '%s'\n"), cmd, param);
-#endif
-
-        if (_tcsicmp (cmd, _T("echo.")) == 0)
-       {
-               if (param[0] == 0)
-                       ConOutChar (_T('\n'));
-               else
-                       ConOutPuts (param);
-       }
-        else
-        {
-                /* skip the first delimiter */
-                if (_istspace(*param))
-                        param++;
-
-                /* skip all spaces for the check of '/?', 'ON' and 'OFF' */
-                p1 = param;
-                while(_istspace(*p1))
-                        p1++;
-
-               if (!_tcsncmp (p1, _T("/?"), 2))
-               {
-                       ConOutResPaging(TRUE,STRING_ECHO_HELP4);
-                       return 0;
-               }
-
-                if (_tcsnicmp (p1, D_OFF, sizeof(D_OFF)/sizeof(TCHAR) - 1) == 0)
-                {
-                        p2 = p1 + sizeof(D_OFF)/sizeof(TCHAR) - 1;
-                        while (_istspace(*p2))
-                                p2++;
-                        if (*p2 == _T('\0'))
-                        {
-                                bEcho = FALSE;
-                                return 0;
-                        }
-                }
-               else if (_tcsnicmp (p1, D_ON, sizeof(D_ON)/sizeof(TCHAR) - 1) == 0)
-                {
-                        p2 = p1 + sizeof(D_ON)/sizeof(TCHAR) - 1;
-                        while (_istspace(*p2))
-                                p2++;
-                        if (*p2 == _T('\0'))
-                        {
-                               bEcho = TRUE;
-                                return 0;
-                        }
-                }
-               if (*p1 != _T('\0'))
-               {
-                        p1 = param;
-                        while (NULL != (p1 = _tcschr(p1, _T('^'))))
-                        {
-                                memmove(p1, p1 + 1, (_tcslen(p1 + 1) + 1) * sizeof(TCHAR));
-                                if (*p1)
-                                {
-                                       //skip past the char being escaped
-                                        p1++;
-                                }
-                        }
-                       ConOutPuts (param);
-               }
-               else
-               {
-                       LoadString(CMD_ModuleHandle, STRING_ECHO_HELP5, szMsg, RC_STRING_MAX_SIZE);
-                       ConOutPrintf(szMsg, bEcho ? D_ON : D_OFF);
-               }
-       }
-
-       return 0;
-}
-
-
-INT CommandEchos (LPTSTR cmd, LPTSTR param)
-{
-
-#ifdef _DEBUG
-       DebugPrintf (_T("CommandEchos '%s' : '%s'\n"), cmd, param);
-#endif
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPuts(STRING_ECHO_HELP1);
-               return 0;
-       }
-
-       if (*param)
-               ConOutPrintf (_T("%s"), param);
-
-       return 0;
-}
-
-
-INT CommandEchoerr (LPTSTR cmd, LPTSTR param)
-{
-
-#ifdef _DEBUG
-       DebugPrintf (_T("CommandEchoerr '%s' : '%s'\n"), cmd, param);
-#endif
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPuts(STRING_ECHO_HELP2);
-               return 0;
-       }
-
-       if (_tcsicmp (cmd, _T("echoerr.")) == 0)
-       {
-               if (param[0] == 0)
-                       ConErrChar (_T('\n'));
-               else
-                       ConErrPuts (param);
-       }
-       else if (*param)
-       {
-               ConErrPuts (param);
-       }
-
-       return 0;
-}
-
-
-INT CommandEchoserr (LPTSTR cmd, LPTSTR param)
-{
-
-#ifdef _DEBUG
-       DebugPrintf (_T("CommandEchoserr '%s' : '%s'\n"), cmd, param);
-#endif
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPuts(STRING_ECHO_HELP3);
-               return 0;
-       }
-
-       if (*param)
-               ConOutPrintf (_T("%s"), param);
-
-       return 0;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/error.c b/reactos/subsys/system/cmd/error.c
deleted file mode 100644 (file)
index 9bbc13b..0000000
+++ /dev/null
@@ -1,179 +0,0 @@
-/*
- *  ERROR.C - error reporting functions.
- *
- *
- *  History:
- *
- *    07/12/98 (Rob Lake)
- *        started
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    24-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Redirection safe!
- *
- *    02-Feb-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Use FormatMessage() for error reports.
- *
- *    28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-VOID ErrorMessage (DWORD dwErrorCode, LPTSTR szFormat, ...)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       TCHAR  szMessage[1024];
-       LPTSTR szError;
-       va_list arg_ptr;
-
-       if (dwErrorCode == ERROR_SUCCESS)
-               return;
-
-  nErrorLevel = 1;
-
-       if (szFormat)
-       {
-               va_start (arg_ptr, szFormat);
-               _vstprintf (szMessage, szFormat, arg_ptr);
-               va_end (arg_ptr);
-       }
-
-       if (FormatMessage (FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_ALLOCATE_BUFFER,
-                                          NULL, dwErrorCode, MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
-                                          (LPTSTR)&szError, 0, NULL))
-       {
-               ConErrPrintf (_T("%s %s\n"), szError, szMessage);
-               if(szError)
-                       LocalFree (szError);
-               return;
-       }
-
-       /* Fall back just in case the error is not defined */
-       if (szFormat)
-               ConErrPrintf (_T("%s -- %s\n"), szMsg, szMessage);
-       else
-               ConErrPrintf (_T("%s\n"), szMsg);
-}
-
-VOID error_parameter_format(TCHAR ch)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-
-       LoadString(CMD_ModuleHandle, STRING_ERROR_PARAMETERF_ERROR, szMsg, RC_STRING_MAX_SIZE);
-       ConErrPrintf(szMsg, ch);
-  nErrorLevel = 1;
-}
-
-
-VOID error_invalid_switch (TCHAR ch)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-
-       LoadString(CMD_ModuleHandle, STRING_ERROR_INVALID_SWITCH, szMsg, RC_STRING_MAX_SIZE);
-       ConErrPrintf(szMsg, ch);
-  nErrorLevel = 1;
-}
-
-
-VOID error_too_many_parameters (LPTSTR s)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-
-       LoadString(CMD_ModuleHandle, STRING_ERROR_TOO_MANY_PARAMETERS, szMsg, RC_STRING_MAX_SIZE);
-       ConErrPrintf(szMsg, s);
-  nErrorLevel = 1;
-}
-
-
-VOID error_path_not_found (VOID)
-{
-       ConErrResPuts(STRING_ERROR_PATH_NOT_FOUND);
-       nErrorLevel = 1;
-}
-
-
-VOID error_file_not_found (VOID)
-{
-       ConErrResPuts(STRING_ERROR_FILE_NOT_FOUND);
-       nErrorLevel = 1;
-}
-
-
-VOID error_sfile_not_found (LPTSTR f)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-
-       LoadString(CMD_ModuleHandle, STRING_ERROR_FILE_NOT_FOUND, szMsg, RC_STRING_MAX_SIZE);
-       ConErrPrintf(_T("%s - %s\n"), szMsg, f);
-  nErrorLevel = 1;
-}
-
-
-VOID error_req_param_missing (VOID)
-{
-       ConErrResPuts(STRING_ERROR_REQ_PARAM_MISSING);
-  nErrorLevel = 1;
-}
-
-
-VOID error_invalid_drive (VOID)
-{
-       ConErrResPuts(STRING_ERROR_INVALID_DRIVE);
-  nErrorLevel = 1;
-}
-
-
-VOID error_bad_command (VOID)
-{
-       ConErrResPuts(STRING_ERROR_BADCOMMAND);
-       nErrorLevel = 9009;
-}
-
-
-VOID error_no_pipe (VOID)
-{
-       ConErrResPuts(STRING_ERROR_CANNOTPIPE);
-  nErrorLevel = 1;
-}
-
-
-VOID error_out_of_memory (VOID)
-{
-       ConErrResPuts(STRING_ERROR_OUT_OF_MEMORY);
-  nErrorLevel = 1;
-}
-
-
-VOID error_invalid_parameter_format (LPTSTR s)
-{
-       ConErrResPuts(STRING_ERROR_INVALID_PARAM_FORMAT);
-  nErrorLevel = 1;
-}
-
-
-VOID error_syntax (LPTSTR s)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-
-       LoadString(CMD_ModuleHandle, STRING_ERROR_ERROR2, szMsg, RC_STRING_MAX_SIZE);
-
-       if (s)
-               ConErrPrintf(_T("%s - %s\n"), szMsg, s);
-       else
-               ConErrPrintf(_T("%s.\n"), szMsg);
-
-  nErrorLevel = 1;
-}
-
-
-VOID msg_pause (VOID)
-{
-       ConOutResPuts(STRING_ERROR_D_PAUSEMSG);
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/filecomp.c b/reactos/subsys/system/cmd/filecomp.c
deleted file mode 100644 (file)
index 5ef7101..0000000
+++ /dev/null
@@ -1,751 +0,0 @@
-/*
- *  FILECOMP.C - handles filename completion.
- *
- *
- *  Comments:
- *
- *    30-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *       moved from command.c file
- *       made second TAB display list of filename matches
- *       made filename be lower case if last character typed is lower case
- *
- *    25-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *       Cleanup. Unicode safe!
- *
- *    30-Apr-2004 (Filip Navara <xnavara@volny.cz>)
- *       Make the file listing readable when there is a lot of long names.
- *
-
- *    05-Jul-2004 (Jens Collin <jens.collin@lakhei.com>)
- *       Now expands lfn even when trailing " is omitted.
- */
-
-#include <precomp.h>
-#include "cmd.h"
-
-#ifdef FEATURE_UNIX_FILENAME_COMPLETION
-
-VOID CompleteFilename (LPTSTR str, UINT charcount)
-{
-       WIN32_FIND_DATA file;
-       HANDLE hFile;
-       INT   curplace = 0;
-       INT   start;
-       INT   count;
-       INT step;
-       INT c = 0;
-       BOOL  found_dot = FALSE;
-       BOOL  perfectmatch = TRUE;
-       TCHAR path[MAX_PATH];
-       TCHAR fname[MAX_PATH];
-       TCHAR maxmatch[MAX_PATH] = _T("");
-       TCHAR directory[MAX_PATH];
-       LPCOMMAND cmds_ptr;
-
-       /* expand current file name */
-       count = charcount - 1;
-       if (count < 0)
-               count = 0;
-
-       /* find how many '"'s there is typed already.*/
-       step = count;
-       while (step > 0)
-       {
-               if (str[step] == _T('"'))
-                       c++;
-               step--;
-       }
-       /* if c is odd, then user typed " before name, else not.*/
-
-       /* find front of word */
-       if (str[count] == _T('"') || (c % 2))
-       {
-               count--;
-               while (count > 0 && str[count] != _T('"'))
-                       count--;
-       }
-       else
-       {
-               while (count > 0 && str[count] != _T(' '))
-                       count--;
-       }
-
-       /* if not at beginning, go forward 1 */
-       if (str[count] == _T(' '))
-               count++;
-
-       start = count;
-
-       if (str[count] == _T('"'))
-               count++;        /* don't increment start */
-
-       /* extract directory from word */
-       _tcscpy (directory, &str[count]);
-       curplace = _tcslen (directory) - 1;
-
-       if (curplace >= 0 && directory[curplace] == _T('"'))
-               directory[curplace--] = _T('\0');
-
-       _tcscpy (path, directory);
-
-       while (curplace >= 0 && directory[curplace] != _T('\\') &&
-                  directory[curplace] != _T(':'))
-       {
-               directory[curplace] = 0;
-               curplace--;
-       }
-
-       /* look for a '.' in the filename */
-       for (count = _tcslen (directory); path[count] != _T('\0'); count++)
-       {
-               if (path[count] == _T('.'))
-               {
-                       found_dot = TRUE;
-                       break;
-               }
-       }
-
-       if (found_dot)
-               _tcscat (path, _T("*"));
-       else
-               _tcscat (path, _T("*.*"));
-
-       /* current fname */
-       curplace = 0;
-
-       hFile = FindFirstFile (path, &file);
-       if (hFile != INVALID_HANDLE_VALUE)
-       {
-               /* find anything */
-               do
-               {
-                       /* ignore "." and ".." */
-                       if (!_tcscmp (file.cFileName, _T(".")) ||
-                               !_tcscmp (file.cFileName, _T("..")))
-                               continue;
-
-                       _tcscpy (fname, file.cFileName);
-
-                       if (file.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                               _tcscat (fname, _T("\\"));
-
-                       if (!maxmatch[0] && perfectmatch)
-                       {
-                               _tcscpy(maxmatch, fname);
-                       }
-                       else
-                       {
-                               for (count = 0; maxmatch[count] && fname[count]; count++)
-                               {
-                                       if (tolower(maxmatch[count]) != tolower(fname[count]))
-                                       {
-                                               perfectmatch = FALSE;
-                                               maxmatch[count] = 0;
-                                               break;
-                                       }
-                               }
-
-                               if (maxmatch[count] == _T('\0') &&
-                                   fname[count] != _T('\0'))
-                                       perfectmatch = FALSE;
-                       }
-               }
-               while (FindNextFile (hFile, &file));
-
-               FindClose (hFile);
-
-               /* only quote if the filename contains spaces */
-               if (_tcschr(directory, _T(' ')) ||
-                   _tcschr(maxmatch, _T(' ')))
-               {
-                       str[start] = _T('\"');
-                       _tcscpy (&str[start+1], directory);
-                       _tcscat (&str[start], maxmatch);
-                       _tcscat (&str[start], _T("\"") );
-               }
-               else
-               {
-                       _tcscpy (&str[start], directory);
-                       _tcscat (&str[start], maxmatch);
-               }
-
-               if(!perfectmatch)
-               {
-                       MessageBeep (-1);
-               }
-       }
-       else
-       {
-               /* no match found - search for internal command */
-               for (cmds_ptr = cmds; cmds_ptr->name; cmds_ptr++)
-               {
-                       if (!_tcsnicmp (&str[start], cmds_ptr->name,
-                               _tcslen (&str[start])))
-                       {
-                               /* return the mach only if it is unique */
-                               if (_tcsnicmp (&str[start], (cmds_ptr+1)->name, _tcslen (&str[start])))
-                                       _tcscpy (&str[start], cmds_ptr->name);
-                               break;
-                       }
-               }
-
-               MessageBeep (-1);
-       }
-}
-
-
-/*
- * returns 1 if at least one match, else returns 0
- */
-
-BOOL ShowCompletionMatches (LPTSTR str, INT charcount)
-{
-       WIN32_FIND_DATA file;
-       HANDLE hFile;
-       BOOL  found_dot = FALSE;
-       INT   curplace = 0;
-       INT   start;
-       UINT   count;
-       TCHAR path[MAX_PATH];
-       TCHAR fname[MAX_PATH];
-       TCHAR directory[MAX_PATH];
-       UINT   longestfname = 0;
-       SHORT screenwidth;
-
-       /* expand current file name */
-       count = charcount - 1;
-       if (count < 0)
-               count = 0;
-
-       /* find front of word */
-       if (str[count] == _T('"'))
-       {
-               count--;
-               while (count > 0 && str[count] != _T('"'))
-                       count--;
-       }
-       else
-       {
-               while (count > 0 && str[count] != _T(' '))
-                       count--;
-       }
-
-       /* if not at beginning, go forward 1 */
-       if (str[count] == _T(' '))
-               count++;
-
-       start = count;
-
-       if (str[count] == _T('"'))
-               count++;        /* don't increment start */
-
-       /* extract directory from word */
-       _tcscpy (directory, &str[count]);
-       curplace = _tcslen (directory) - 1;
-
-       if (curplace >= 0 && directory[curplace] == _T('"'))
-               directory[curplace--] = _T('\0');
-
-       _tcscpy (path, directory);
-
-       while (curplace >= 0 &&
-                  directory[curplace] != _T('\\') &&
-                  directory[curplace] != _T(':'))
-       {
-               directory[curplace] = 0;
-               curplace--;
-       }
-
-       /* look for a . in the filename */
-       for (count = _tcslen (directory); path[count] != _T('\0'); count++)
-       {
-               if (path[count] == _T('.'))
-               {
-                       found_dot = TRUE;
-                       break;
-               }
-       }
-
-       if (found_dot)
-               _tcscat (path, _T("*"));
-       else
-               _tcscat (path, _T("*.*"));
-
-       /* current fname */
-       curplace = 0;
-
-       hFile = FindFirstFile (path, &file);
-       if (hFile != INVALID_HANDLE_VALUE)
-       {
-               /* Get the size of longest filename first. */
-               do
-               {
-                       if (_tcslen(file.cFileName) > longestfname)
-                       {
-                               longestfname = _tcslen(file.cFileName);
-                               /* Directories get extra brackets around them. */
-                               if (file.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                                       longestfname += 2;
-                       }
-               }
-               while (FindNextFile (hFile, &file));
-               FindClose (hFile);
-
-               hFile = FindFirstFile (path, &file);
-
-               /* Count the highest number of columns */
-               GetScreenSize(&screenwidth, 0);
-
-               /* For counting columns of output */
-               count = 0;
-
-               /* Increase by the number of spaces behind file name */
-               longestfname += 3;
-
-               /* find anything */
-               ConOutChar (_T('\n'));
-               do
-               {
-                       /* ignore . and .. */
-                       if (!_tcscmp (file.cFileName, _T(".")) ||
-                               !_tcscmp (file.cFileName, _T("..")))
-                               continue;
-
-                       if (file.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                               _stprintf (fname, _T("[%s]"), file.cFileName);
-                       else
-                               _tcscpy (fname, file.cFileName);
-
-                       ConOutPrintf (_T("%*s"), - longestfname, fname);
-                       count++;
-                       /* output as much columns as fits on the screen */
-                       if (count >= (screenwidth / longestfname))
-                       {
-                               /* print the new line only if we aren't on the
-                                * last column, in this case it wraps anyway */
-                               if (count * longestfname != (UINT)screenwidth)
-                                       ConOutPrintf (_T("\n"));
-                               count = 0;
-                       }
-               }
-               while (FindNextFile (hFile, &file));
-
-               FindClose (hFile);
-
-               if (count)
-                       ConOutChar (_T('\n'));
-       }
-       else
-       {
-               /* no match found */
-               MessageBeep (-1);
-               return FALSE;
-       }
-
-       return TRUE;
-}
-#endif
-
-#ifdef FEATURE_4NT_FILENAME_COMPLETION
-
-typedef struct _FileName
-{
-       TCHAR Name[MAX_PATH];
-} FileName;
-
-VOID FindPrefixAndSuffix(LPTSTR strIN, LPTSTR szPrefix, LPTSTR szSuffix)
-{
-       /* String that is to be examined */
-       TCHAR str[MAX_PATH];
-       /* temp pointers to used to find needed parts */
-       TCHAR * szSearch;       
-       TCHAR * szSearch1;
-       TCHAR * szSearch2;
-       /* number of quotes in the string */
-       INT nQuotes = 0;
-       /* used in for loops */
-       UINT i;
-       /* Char number to break the string at */
-       INT PBreak = 0;
-       INT SBreak = 0;
-       /* when phrasing a string, this tells weather
-          you are inside quotes ot not. */
-       BOOL bInside = FALSE;
-       
-  szPrefix[0] = _T('\0');
-  szSuffix[0] = _T('\0');
-
-       /* Copy over the string to later be edited */
-       _tcscpy(str,strIN);
-
-       /* Count number of " */
-       for(i = 0; i < _tcslen(str); i++)
-               if(str[i] == _T('\"'))
-                       nQuotes++;
-
-       /* Find the prefix and suffix */
-       if(nQuotes % 2 && nQuotes >= 1)
-       {
-               /* Odd number of quotes.  Just start from the last " */
-               /* THis is the way MS does it, and is an easy way out */
-               szSearch = _tcsrchr(str, _T('\"'));
-               /* Move to the next char past the " */
-               szSearch++;
-               _tcscpy(szSuffix,szSearch);
-               /* Find the one closest to end */
-               szSearch1 = _tcsrchr(str, _T('\"'));
-               szSearch2 = _tcsrchr(str, _T('\\'));            
-               if(szSearch2 != NULL && _tcslen(szSearch1) > _tcslen(szSearch2))
-                       szSearch = szSearch2;
-               else
-                       szSearch = szSearch1;
-               /* Move one char past */
-               szSearch++;             
-    szSearch[0] = _T('\0');
-               _tcscpy(szPrefix,str);
-               return;
-       
-       }
-
-       if(!_tcschr(str, _T(' ')))
-       {
-               /* No spaces, everything goes to Suffix */
-               _tcscpy(szSuffix,str);
-               /* look for a slash just in case */
-               szSearch = _tcsrchr(str, _T('\\'));             
-               if(szSearch)
-               {
-                       szSearch++;                     
-      szSearch[0] = _T('\0');
-                       _tcscpy(szPrefix,str);
-               }
-               else
-               {
-                       szPrefix[0] = _T('\0');
-               }
-               return;
-       }
-
-       if(!nQuotes)
-       {
-               /* No quotes, and there is a space*/
-               /* Take it after the last space */
-               szSearch = _tcsrchr(str, _T(' '));
-               szSearch++;
-               _tcscpy(szSuffix,szSearch);
-               /* Find the closest to the end space or \ */
-               _tcscpy(str,strIN);
-               szSearch1 = _tcsrchr(str, _T(' '));
-               szSearch2 = _tcsrchr(str, _T('\\'));            
-               if(szSearch2 != NULL && _tcslen(szSearch1) > _tcslen(szSearch2))
-                       szSearch = szSearch2;
-               else
-                       szSearch = szSearch1;
-               szSearch++;             
-    szSearch[0] = _T('\0');
-               _tcscpy(szPrefix,str);          
-               return;
-       }
-       
-       /* All else fails and there is a lot of quotes, spaces and | 
-          Then we search through and find the last space or \ that is
-               not inside a quotes */
-       for(i = 0; i < _tcslen(str); i++)
-       {
-               if(str[i] == _T('\"'))
-                       bInside = !bInside;
-               if(str[i] == _T(' ') && !bInside)
-                       SBreak = i;
-               if((str[i] == _T(' ') || str[i] == _T('\\')) && !bInside)
-                       PBreak = i;
-
-       }
-       SBreak++;
-       PBreak++;
-       _tcscpy(szSuffix,&strIN[SBreak]);       
-  strIN[PBreak] = _T('\0');
-       _tcscpy(szPrefix,strIN);
-       if(szPrefix[_tcslen(szPrefix) - 2] == _T('\"'))
-       {
-               /* need to remove the " right before a \ at the end to
-                  allow the next stuff to stay inside one set of quotes
-                       otherwise you would have multiple sets of quotes*/
-               _tcscpy(&szPrefix[_tcslen(szPrefix) - 2],_T("\\"));
-
-       }
-
-}
- int __cdecl compare(const void *arg1,const void *arg2)
- {
-       FileName * File1;
-       FileName * File2;
-       INT ret;
-
-       File1 = malloc(sizeof(FileName));
-       File2 = malloc(sizeof(FileName));
-       if(!File1 || !File2)
-               return 0;
-
-       memcpy(File1,arg1,sizeof(FileName));
-       memcpy(File2,arg2,sizeof(FileName));
-
-        /* ret = _tcsicmp(File1->Name, File2->Name); */
-        ret = lstrcmpi(File1->Name, File2->Name);
-
-       free(File1);
-       free(File2);
-       return ret;
- }
-
-VOID CompleteFilename (LPTSTR strIN, BOOL bNext, LPTSTR strOut, UINT cusor)
-{
-       /* Length of string before we complete it */
-       INT StartLength;
-       /* Length of string after completed */
-       INT EndLength;
-       /* The number of chars added too it */
-       static INT DiffLength = 0;
-       /* Used to find and assemble the string that is returned */
-       TCHAR szBaseWord[MAX_PATH];
-       TCHAR szPrefix[MAX_PATH];
-       TCHAR szOrginal[MAX_PATH];
-       TCHAR szSearchPath[MAX_PATH];
-       /* Save the strings used last time, so if they hit tab again */
-       static TCHAR LastReturned[MAX_PATH];
-       static TCHAR LastSearch[MAX_PATH];
-       static TCHAR LastPrefix[MAX_PATH];
-       /* Used to search for files */
-       HANDLE hFile;
-       WIN32_FIND_DATA file;
-       /* List of all the files */
-       FileName * FileList = NULL;
-       /* Number of files */
-       INT FileListSize = 0;
-       /* Used for loops */
-       UINT i;
-       /* Editable string of what was passed in */
-       TCHAR str[MAX_PATH];
-       /* Keeps track of what element was last selected */
-       static INT Sel;
-       BOOL NeededQuote = FALSE;
-       BOOL ShowAll = TRUE;
-       TCHAR * line = strIN; 
-
-       strOut[0] = _T('\0');
-
-       while (_istspace (*line))
-                       line++; 
-       if(!_tcsnicmp (line, _T("rd "), 3) || !_tcsnicmp (line, _T("cd "), 3))
-               ShowAll = FALSE;
-
-       /* Copy the string, str can be edited and orginal should not be */
-       _tcscpy(str,strIN);
-       _tcscpy(szOrginal,strIN);
-
-       /* Look to see if the cusor is not at the end of the string */
-       if((cusor + 1) < _tcslen(str))
-               str[cusor] = _T('\0');
-
-       /* Look to see if they hit tab again, if so cut off the diff length */
-       if(_tcscmp(str,LastReturned) || !_tcslen(str))
-       {
-               /* We need to know how many chars we added from the start */
-               StartLength = _tcslen(str);
-
-               /* no string, we need all files in that directory */
-               if(!StartLength)
-               {
-                       _tcscat(str,_T("*"));
-               }
-
-               /* Zero it out first */
-               szBaseWord[0] = _T('\0');
-               szPrefix[0] = _T('\0');
-
-               /*What comes out of this needs to be:
-                       szBaseWord =  path no quotes to the object
-                       szPrefix = what leads up to the filename
-                       no quote at the END of the full name */
-               FindPrefixAndSuffix(str,szPrefix,szBaseWord);
-               /* Strip quotes */
-               for(i = 0; i < _tcslen(szBaseWord); )
-               {
-                       if(szBaseWord[i] == _T('\"'))
-                               memmove(&szBaseWord[i],&szBaseWord[i + 1], _tcslen(&szBaseWord[i]) * sizeof(TCHAR));
-                       else
-                               i++;
-               }
-
-               /* clear it out */
-               memset(szSearchPath, 0, sizeof(szSearchPath));
-
-               /* Start the search for all the files */
-               GetFullPathName(szBaseWord, MAX_PATH, szSearchPath, NULL);
-               if(StartLength > 0)
-    {
-                       _tcscat(szSearchPath,_T("*"));
-    }
-               _tcscpy(LastSearch,szSearchPath);
-               _tcscpy(LastPrefix,szPrefix);
-       }
-       else
-       {
-               _tcscpy(szSearchPath, LastSearch);
-               _tcscpy(szPrefix, LastPrefix);
-               StartLength = 0;
-       }
-       /* search for the files it might be */
-       hFile = FindFirstFile (szSearchPath, &file);
-       /* aseemble a list of all files names */
-       do
-       {
-               if(hFile == INVALID_HANDLE_VALUE)
-               {
-                       /* Assemble the orginal string and return */
-                       _tcscpy(strOut,szOrginal);
-                       CloseHandle(hFile);
-                       if(FileList != NULL) 
-                               free(FileList);
-                       return;
-               }
-               if(!_tcscmp (file.cFileName, _T(".")) ||
-                       !_tcscmp (file.cFileName, _T("..")))
-                       continue;
-               
-               /* Don't show files when they are doing 'cd' or 'rd' */
-               if(!ShowAll &&
-       file.dwFileAttributes != 0xFFFFFFFF &&
-       !(file.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY))
-               {
-                               continue;
-               }
-
-               /* Add the file to the list of files */
-      if(FileList == NULL) 
-      {
-                       FileListSize = 1;
-                       FileList = malloc(FileListSize * sizeof(FileName));
-      }
-      else
-      {
-                       FileListSize++;
-                       FileList = realloc(FileList, FileListSize * sizeof(FileName));
-      }
-               if(FileList == NULL) 
-               {
-                       /* Assemble the orginal string and return */
-                       _tcscpy(strOut,szOrginal);
-                       CloseHandle(hFile);
-                       ConOutFormatMessage (GetLastError());
-                       return;
-               }
-               /* Copies the file name into the struct */
-               _tcscpy(FileList[FileListSize-1].Name,file.cFileName);
-       }while(FindNextFile(hFile,&file));
-
-       /* Check the size of the list to see if we
-          found any matches */
-       if(FileListSize == 0)
-       {
-               _tcscpy(strOut,szOrginal);
-               CloseHandle(hFile);
-               if(FileList != NULL) 
-                       free(FileList);
-               return;
-
-       }
-       /* Sort the files */
-       qsort(FileList,FileListSize,sizeof(FileName), compare);
-
-       /* Find the next/previous */
-       if(!_tcscmp(szOrginal,LastReturned))
-       {
-               if(bNext)
-               {
-                       if(FileListSize - 1 == Sel)
-                               Sel = 0;
-                       else
-                               Sel++;
-               }
-               else
-               {
-                       if(!Sel)
-                               Sel = FileListSize - 1;
-                       else
-                               Sel--;
-               }
-       }
-       else
-       {
-               Sel = 0;
-       }
-
-       /* nothing found that matched last time 
-          so return the first thing in the list */
-       strOut[0] = _T('\0');
-       
-       /* space in the name */
-       if(_tcschr(FileList[Sel].Name, _T(' ')))
-       {
-               INT LastSpace;
-               BOOL bInside;
-               /* It needs a " at the end */
-               NeededQuote = TRUE;
-               LastSpace = -1;
-               bInside = FALSE;
-               /* Find the place to put the " at the start */
-               for(i = 0; i < _tcslen(szPrefix); i++)
-               {
-                       if(szPrefix[i] == _T('\"'))
-                               bInside = !bInside;
-                       if(szPrefix[i] == _T(' ') && !bInside)
-                               LastSpace = i;
-
-               }
-               /* insert the quoation and move things around */
-               if(szPrefix[LastSpace + 1] != _T('\"') && LastSpace != -1)
-               {
-                       memmove ( &szPrefix[LastSpace+1], &szPrefix[LastSpace], (_tcslen(szPrefix)-LastSpace+1) * sizeof(TCHAR) );
-                       
-                       if((UINT)(LastSpace + 1) == _tcslen(szPrefix))
-                       {
-                               _tcscat(szPrefix,_T("\""));
-                       }
-                               szPrefix[LastSpace + 1] = _T('\"');
-               }
-               else if(LastSpace == -1)
-               {
-                       _tcscpy(szBaseWord,_T("\""));
-                       _tcscat(szBaseWord,szPrefix);
-                       _tcscpy(szPrefix,szBaseWord);
-
-               }
-       }
-
-       _tcscpy(strOut,szPrefix);
-       _tcscat(strOut,FileList[Sel].Name);
-
-       /* check for odd number of quotes means we need to close them */
-       if(!NeededQuote)
-       {
-               for(i = 0; i < _tcslen(strOut); i++)
-                       if(strOut[i] == _T('\"'))
-                               NeededQuote = !NeededQuote;
-       }
-
-       if(szPrefix[_tcslen(szPrefix) - 1] == _T('\"') || NeededQuote)
-               _tcscat(strOut,_T("\""));
-
-       _tcscpy(LastReturned,strOut);
-       EndLength = _tcslen(strOut);
-       DiffLength = EndLength - StartLength;
-       CloseHandle(hFile);
-       if(FileList != NULL) 
-               free(FileList);
-       
-}
-#endif
diff --git a/reactos/subsys/system/cmd/files.txt b/reactos/subsys/system/cmd/files.txt
deleted file mode 100644 (file)
index 0004b4f..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-Archive Contents
-~~~~~~~~~~~~~~~~
-files.txt       This file list
-history.txt     History of revsions.  Not to date.  see svn.reactos.com for more info.
-license.txt     GNU license - applies to all files named here
-readme.txt      General shell info
-readme2.txt     Techincal shell info
-todo.txt        Things that need to be implmented or fixed(including bugs)
-
-alias.c         Alias code
-alias.h         Alias header file
-attrib.c        Implements attrib command
-batch.c         Batch file interpreter
-beep.c          Implements beep command
-call.c          Implements call command
-chcp.c          Implements chcp command
-choice.c        Implements choice command
-cls.c           Implements cls command
-cmdinput.c      Command-line input functions
-cmdtable.c      Table of available internal commands
-cmd.c           Main code for command-line interpreter
-cmd.h           Command header file
-color.c         Implements color command
-console.c       Windows console handling code
-copy.c          Implements copy command
-date.c          Implements date command
-del.c           Implements del command
-dir.c           Directory listing code
-dirstack.c      Directory stack code (PUSHD and POPD)
-echo.c          Implements echo command
-error.c         Error Message Routines
-filecomp.c      Filename completion functions
-for.c           Implements for command
-free.c          Implements free command
-goto.c          Implements goto command
-history.c       Command-line history handling
-if.c            Implements if command
-internal.c      Internal commands (DIR, RD, CD, etc)
-label.c         Implements label command
-locale.c        Locale handling code
-memory.c        Implements memory command
-misc.c          Misc. Functions
-msgbox.c        Implements msgbox command
-move.c          Implements move command
-path.c          Implements path command
-pause.c         Implements pause command
-prompt.c        Prompt handling functions
-redir.c         Redirection and piping parsing functions
-ren.c           Implements rename command
-set.c           Implements set command
-shift.c         Implements shift command
-time.c          Implements time command
-timer.c         Implements timer command
-type.c          Implements type command
-ver.c           Implements ver command
-where.c         Code to search path for executables
-verify.c        Implements verify command
diff --git a/reactos/subsys/system/cmd/for.c b/reactos/subsys/system/cmd/for.c
deleted file mode 100644 (file)
index b503a57..0000000
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
- *  FOR.C - for internal batch command.
- *
- *
- *  History:
- *
- *    16-Jul-1998 (Hans B Pufal)
- *        Started.
- *
- *    16-Jul-1998 (John P Price)
- *        Seperated commands into individual files.
- *
- *    19-Jul-1998 (Hans B Pufal)
- *        Implementation of FOR.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        Added config.h include.
- *
- *    20-Jan-1999 (Eric Kohl)
- *        Unicode and redirection safe!
- *
- *    01-Sep-1999 (Eric Kohl)
- *        Added help text.
- *
- *    23-Feb-2001 (Carl Nettelblad <cnettel@hem.passagen.se>)
- *        Implemented preservation of echo flag. Some other for related
- *        code in other files fixed, too.
- *
- *    28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-/*
- * Perform FOR command.
- *
- * First check syntax is correct : FOR %v IN ( <list> ) DO <command>
- *   v must be alphabetic, <command> must not be empty.
- *
- * If all is correct build a new bcontext structure which preserves
- *   the necessary information so that readbatchline can expand
- *   each the command prototype for each list element.
- *
- * You might look on a FOR as being a called batch file with one line
- *   per list element.
- */
-
-INT cmd_for (LPTSTR cmd, LPTSTR param)
-{      
-       LPBATCH_CONTEXT lpNew;
-       LPTSTR pp;
-       TCHAR  var;
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-
-#ifdef _DEBUG
-       DebugPrintf (_T("cmd_for (\'%s\', \'%s\'\n"), cmd, param);
-#endif
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_FOR_HELP1);
-               return 0;
-       }
-
-       /* Check that first element is % then an alpha char followed by space */
-       if ((*param != _T('%')) || !_istalpha (*(param + 1)) || !_istspace (*(param + 2)))
-       {
-               LoadString( CMD_ModuleHandle, STRING_FOR_ERROR, szMsg, RC_STRING_MAX_SIZE);
-               error_syntax (szMsg);
-               return 1;
-       }
-
-       param++;
-       var = *param++;               /* Save FOR var name */
-
-       while (_istspace (*param))
-               param++;
-
-       /* Check next element is 'IN' */
-       if ((_tcsnicmp (param, _T("in"), 2) != 0) || !_istspace (*(param + 2)))
-       {
-               LoadString(CMD_ModuleHandle, STRING_FOR_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-               error_syntax(szMsg);
-               return 1;
-       }
-
-       param += 2;
-       while (_istspace (*param))
-               param++;
-
-       /* Folowed by a '(', find also matching ')' */
-       if ((*param != _T('(')) || (NULL == (pp = _tcsrchr (param, _T(')')))))
-       {
-               LoadString(CMD_ModuleHandle, STRING_FOR_ERROR2, szMsg, RC_STRING_MAX_SIZE);
-               error_syntax(szMsg);
-               return 1;
-       }
-
-       *pp++ = _T('\0');
-       param++;                /* param now points at null terminated list */
-
-       while (_istspace (*pp))
-               pp++;
-
-       /* Check DO follows */
-       if ((_tcsnicmp (pp, _T("do"), 2) != 0) || !_istspace (*(pp + 2)))
-       {
-               LoadString(CMD_ModuleHandle, STRING_FOR_ERROR3, szMsg, RC_STRING_MAX_SIZE);
-               error_syntax(szMsg);
-               return 1;
-       }
-
-       pp += 2;
-       while (_istspace (*pp))
-               pp++;
-
-       /* Check that command tail is not empty */
-       if (*pp == _T('\0'))
-       {
-               LoadString(CMD_ModuleHandle, STRING_FOR_ERROR4, szMsg, RC_STRING_MAX_SIZE);
-               error_syntax(szMsg);
-               return 1;
-       }
-
-       /* OK all is correct, build a bcontext.... */
-       lpNew = (LPBATCH_CONTEXT)malloc (sizeof (BATCH_CONTEXT));
-
-       lpNew->prev = bc;
-       bc = lpNew;
-
-       bc->hBatchFile = INVALID_HANDLE_VALUE;
-       bc->ffind = NULL;
-       bc->params = BatchParams (_T(""), param); /* Split out list */
-       bc->shiftlevel = 0;
-       bc->forvar = var;
-       bc->forproto = _tcsdup (pp);
-       if (bc->prev)
-               bc->bEcho = bc->prev->bEcho;
-       else
-               bc->bEcho = bEcho;
-               bc->In[0] = _T('\0');
-               bc->Out[0] = _T('\0');
-               bc->Err[0] = _T('\0');
-
-
-       return 0;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/free.c b/reactos/subsys/system/cmd/free.c
deleted file mode 100644 (file)
index f739cd3..0000000
+++ /dev/null
@@ -1,124 +0,0 @@
-/*
- *  FREE.C - internal command.
- *
- *
- *  History:
- *
- *    01-Sep-1999 (Eric Kohl)
- *        Started.
- *
- *    28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_FREE
-
-static VOID
-PrintDiskInfo (LPTSTR szDisk)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       TCHAR szRootPath[4] = _T("A:\\");
-       TCHAR szDrive[2] = _T("A");
-       TCHAR szVolume[64];
-       TCHAR szSerial[10];
-       TCHAR szTotal[40];
-       TCHAR szUsed[40];
-       TCHAR szFree[40];
-       DWORD dwSerial;
-       ULARGE_INTEGER uliSize;
-       DWORD dwSecPerCl;
-       DWORD dwBytPerSec;
-       DWORD dwFreeCl;
-       DWORD dwTotCl;
-
-       if (_tcslen (szDisk) < 2 || szDisk[1] != _T(':'))
-       {
-               LoadString(CMD_ModuleHandle, STRING_FREE_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-               ConErrPrintf(szMsg);
-               return;
-       }
-
-       szRootPath[0] = szDisk[0];
-       szDrive[0] = _totupper (szRootPath[0]);
-
-       if (!GetVolumeInformation (szRootPath, szVolume, 64, &dwSerial,
-                                  NULL, NULL, NULL, 0))
-       {
-               LoadString(CMD_ModuleHandle, STRING_FREE_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-               ConErrPrintf(_T("%s %s:\n"), szMsg, szDrive);
-               return;
-       }
-
-       if (szVolume[0] == _T('\0'))
-       {
-
-               LoadString(CMD_ModuleHandle, STRING_FREE_ERROR2, szMsg, RC_STRING_MAX_SIZE);
-               _tcscpy (szVolume, szMsg);
-       }
-
-       _stprintf (szSerial,
-                  _T("%04X-%04X"),
-                  HIWORD(dwSerial),
-                  LOWORD(dwSerial));
-
-       if (!GetDiskFreeSpace (szRootPath, &dwSecPerCl,
-                              &dwBytPerSec, &dwFreeCl, &dwTotCl))
-       {
-               LoadString(CMD_ModuleHandle, STRING_FREE_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-               ConErrPrintf (_T("%s %s:\n"), szMsg, szDrive);
-               return;
-       }
-
-       uliSize.QuadPart = dwSecPerCl * dwBytPerSec * dwTotCl;
-       ConvertULargeInteger (uliSize, szTotal, 40, TRUE);
-
-       uliSize.QuadPart = dwSecPerCl * dwBytPerSec * (dwTotCl - dwFreeCl);
-       ConvertULargeInteger (uliSize, szUsed, 40, TRUE);
-
-       uliSize.QuadPart = dwSecPerCl * dwBytPerSec * dwFreeCl;
-       ConvertULargeInteger (uliSize, szFree, 40, TRUE);
-
-
-       LoadString(CMD_ModuleHandle, STRING_FREE_HELP1, szMsg, RC_STRING_MAX_SIZE);
-       ConOutPrintf(szMsg, szDrive, szVolume, szSerial, szTotal, szUsed, szFree);
-}
-
-
-INT CommandFree (LPTSTR cmd, LPTSTR param)
-{
-       LPTSTR szParam;
-       TCHAR  szDefPath[MAX_PATH];
-       INT argc, i;
-       LPTSTR *arg;
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_FREE_HELP2);
-               return 0;
-       }
-
-       if (!param || *param == _T('\0'))
-       {
-               GetCurrentDirectory (MAX_PATH, szDefPath);
-               szDefPath[2] = _T('\0');
-               szParam = szDefPath;
-       }
-       else
-               szParam = param;
-
-       arg = split (szParam, &argc, FALSE);
-
-       for (i = 0; i < argc; i++)
-               PrintDiskInfo (arg[i]);
-
-       freep (arg);
-
-       return 0;
-}
-
-#endif /* INCLUDE_CMD_FREE */
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/goto.c b/reactos/subsys/system/cmd/goto.c
deleted file mode 100644 (file)
index 4f2cf77..0000000
+++ /dev/null
@@ -1,127 +0,0 @@
-/*
- *  GOTO.C - goto internal batch command.
- *
- *  History:
- *
- *    16 Jul 1998 (Hans B Pufal)
- *        started.
- *
- *    16 Jul 1998 (John P Price)
- *        Seperated commands into individual files.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    28 Jul 1998 (Hans B Pufal) [HBP_003]
- *        Terminate label on first space character, use only first 8 chars of
- *        label string
- *
- *    24-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection safe!
- *
- *    27-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("/?").
- *
- *    28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-/*
- * Perform GOTO command.
- *
- * Only valid if batch file current.
- *
- */
-
-INT cmd_goto (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       LPTSTR tmp;
-       LONG   lNewPosHigh;
-
-#ifdef _DEBUG
-       DebugPrintf (_T("cmd_goto (\'%s\', \'%s\'\n"), cmd, param);
-#endif
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {               
-               ConOutResPaging(TRUE,STRING_GOTO_HELP1);
-               return 0;
-       }
-
-       /* if not in batch -- error!! */
-       if (bc == NULL)
-       {
-               return 1;
-       }
-
-       if (*param == _T('\0'))
-       {
-               LoadString(CMD_ModuleHandle, STRING_GOTO_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-               ExitBatch(szMsg);
-               return 1;
-       }
-
-       /* terminate label at first space char */
-       tmp = param+1;
-  while (!_istcntrl (*tmp) && !_istspace (*tmp) &&  (*tmp != _T(':')))  
-  tmp++;
-       *(tmp) = _T('\0');
-     
-       /* set file pointer to the beginning of the batch file */
-       lNewPosHigh = 0;
-          
-  /* jump to end of the file */
-  if ( _tcsicmp( param, _T(":eof"))==0) 
-  {      
-    SetFilePointer (bc->hBatchFile, 0, &lNewPosHigh, FILE_END);
-    return 0;
-  } 
-
-  /* jump to begin of the file */
-  SetFilePointer (bc->hBatchFile, 0, &lNewPosHigh, FILE_BEGIN);
-
-       while (FileGetString (bc->hBatchFile, textline, sizeof(textline) / sizeof(textline[0])))
-       {
-     int pos;
-     int size;     
-
-               /* Strip out any trailing spaces or control chars */
-               tmp = textline + _tcslen (textline) - 1;
-               
-    
-    while (_istcntrl (*tmp) || _istspace (*tmp) ||  (*tmp == _T(':')))
-                       tmp--;
-               *(tmp + 1) = _T('\0');
-                
-               /* Then leading spaces... */
-               tmp = textline;   
-               while (_istspace (*tmp))
-                       tmp++;
-
-    /* All space after leading space terminate the string */
-    size = _tcslen(tmp) -1;
-    pos=0;
-    while (tmp+pos < tmp+size)
-    {
-     if (_istspace(tmp[pos])) 
-         tmp[pos]=_T('\0');
-     pos++;
-    }          
-           
-               /* use whole label name */
-               if ((*tmp == _T(':')) && (_tcsicmp (++tmp, param) == 0))
-                       return 0;
-       }
-  
-       LoadString(CMD_ModuleHandle, STRING_GOTO_ERROR2, szMsg, RC_STRING_MAX_SIZE);
-       ConErrPrintf(szMsg, param);
-       ExitBatch(NULL);
-       return 1;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/history.c b/reactos/subsys/system/cmd/history.c
deleted file mode 100644 (file)
index aae395d..0000000
+++ /dev/null
@@ -1,486 +0,0 @@
-/*
- *  HISTORY.C - command line history.
- *
- *
- *  History:
- *
- *    14/01/95 (Tim Norman)
- *        started.
- *
- *    08/08/95 (Matt Rains)
- *        i have cleaned up the source code. changes now bring this source
- *        into guidelines for recommended programming practice.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    25-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Cleanup!
- *        Unicode and redirection safe!
- *
- *    25-Jan-1999 (Paolo Pantaleo <paolopan@freemail.it>)
- *        Added lots of comments (beginning studying the source)
- *        Added command.com's F3 support (see cmdinput.c)
- *
- */
-
-
-
-/*
- *  HISTORY.C - command line history. Second version
- *
- *
- *  History:
- *
- *    06/12/99 (Paolo Pantaleo <paolopan@freemail.it>)
- *        started.
- *
- */
-
-#include <precomp.h>
-
-#ifdef FEATURE_HISTORY
-
-typedef struct tagHISTORY
-{
-       struct tagHISTORY *prev;
-       struct tagHISTORY *next;
-       LPTSTR string;
-} HIST_ENTRY, * LPHIST_ENTRY;
-
-static INT size,
-       max_size=100;
-
-
-
-static LPHIST_ENTRY Top;
-static LPHIST_ENTRY Bottom;
-
-
-static LPHIST_ENTRY curr_ptr=0;
-
-
-VOID InitHistory(VOID);
-VOID History_move_to_bottom(VOID);
-VOID History (INT dir, LPTSTR commandline);
-VOID CleanHistory(VOID);
-VOID History_del_current_entry(LPTSTR str);
-
-/*service functions*/
-static VOID del(LPHIST_ENTRY item);
-static VOID add_at_bottom(LPTSTR string);
-/*VOID add_before_last(LPTSTR string);*/
-VOID set_size(INT new_size);
-
-
-
-INT CommandHistory (LPTSTR cmd, LPTSTR param)
-{
-       LPTSTR tmp;
-       INT tmp_int;
-       LPHIST_ENTRY h_tmp;
-       TCHAR szBuffer[2048];
-
-       tmp=_tcschr(param,_T('/'));
-
-       if (tmp)
-       {
-               param=tmp;
-               switch (_totupper(param[1]))
-               {
-                       case _T('F'):/*delete history*/
-                               CleanHistory();InitHistory();
-                               break;
-
-                       case _T('R'):/*read history from standard in*/
-                               //hIn=GetStdHandle (STD_INPUT_HANDLE);
-
-                               for(;;)
-                               {
-                                       ConInString(szBuffer,sizeof(szBuffer)/sizeof(TCHAR));
-                                       if (*szBuffer!=_T('\0'))
-                                               History(0,szBuffer);
-                                       else
-                                               break;
-                               }
-                               break;
-
-                       case _T('A'):/*add an antry*/
-                               History(0,param+2);
-                               break;
-
-                       case _T('S'):/*set history size*/
-                               if ((tmp_int=_ttoi(param+2)))
-                                       set_size(tmp_int);
-                               break;
-
-                       default:
-                               return 1;
-               }
-       }
-       else
-       {
-               for (h_tmp = Top->prev; h_tmp != Bottom; h_tmp = h_tmp->prev)
-                       ConErrPuts(h_tmp->string);
-       }
-       return 0;
-}
-
-VOID set_size(INT new_size)
-{
-       while (new_size<size)
-               del(Top->prev);
-
-       max_size=new_size;
-}
-
-
-VOID InitHistory(VOID)
-{
-       size=0;
-
-       Top = malloc(sizeof(HIST_ENTRY));
-       Bottom = malloc(sizeof(HIST_ENTRY));
-
-       Top->prev = Bottom;
-       Top->next = NULL;
-       Top->string = NULL;
-
-       Bottom->prev = NULL;
-       Bottom->next = Top;
-       Bottom->string = NULL;
-
-       curr_ptr=Bottom;
-}
-
-
-
-
-VOID CleanHistory(VOID)
-{
-       while (Bottom->next!=Top)
-               del(Bottom->next);
-
-       free(Top);
-       free(Bottom);
-}
-
-
-VOID History_del_current_entry(LPTSTR str)
-{
-       LPHIST_ENTRY tmp;
-
-       if (size == 0)
-               return;
-
-       if (curr_ptr == Bottom)
-               curr_ptr=Bottom->next;
-
-       if (curr_ptr == Top)
-               curr_ptr=Top->prev;
-
-
-       tmp = curr_ptr;
-       curr_ptr = curr_ptr->prev;
-       del(tmp);
-       History(-1, str);
-}
-
-
-static
-VOID del(LPHIST_ENTRY item)
-{
-       if (item==NULL || item==Top || item==Bottom)
-       {
-#ifdef _DEBUG
-               DebugPrintf(_T("del in ") _T(__FILE__)  _T(": retrning\n")
-                           _T("item is 0x%08x (Bottom is0x%08x)\n"),
-                           item, Bottom);
-#endif
-               return;
-       }
-
-
-
-       /*free string's mem*/
-       if (item->string)
-               free(item->string);
-
-       /*set links in prev and next item*/
-       item->next->prev=item->prev;
-       item->prev->next=item->next;
-
-       free(item);
-
-       size--;
-}
-
-
-#if 0
-static
-VOID add_before_last(LPTSTR string)
-{
-       LPHIST_ENTRY tmp,before,after;
-
-       /*delete first entry if maximum number of entries is reached*/
-       while(size>=max_size)
-               del(Top->prev);
-
-       while (_istspace(*string))
-               string++;
-
-       if (*string==_T('\0'))
-               return;
-
-       /*allocte entry and string*/
-       tmp=malloc(sizeof(HIST_ENTRY));
-       tmp->string=malloc((_tcslen(string)+1)*sizeof(TCHAR));
-       _tcscpy(tmp->string,string);
-
-       /*set links*/
-       before=Bottom->next;
-       after=before->next;
-
-       tmp->prev=before;
-       tmp->next=after;
-
-       after->prev=tmp;
-       before->next=tmp;
-
-       /*set new size*/
-       size++;
-
-
-}
-#endif/*0*/
-
-static
-VOID add_at_bottom(LPTSTR string)
-{
-
-
-       LPHIST_ENTRY tmp;
-
-
-       /*delete first entry if maximum number of entries is reached*/
-       while(size>=max_size)
-               del(Top->prev);
-
-       while (_istspace(*string))
-               string++;
-
-       if (*string==_T('\0'))
-               return;
-
-
-       /*if new entry is the same than the last do not add it*/
-       if(size)
-               if(_tcscmp(string,Bottom->next->string)==0)
-                       return;
-
-
-       /*fill bottom with string, it will become Bottom->next*/
-       Bottom->string=malloc((_tcslen(string)+1)*sizeof(TCHAR));
-       _tcscpy(Bottom->string,string);
-
-       /*save Bottom value*/
-       tmp=Bottom;
-
-
-       /*create new void Bottom*/
-       Bottom=malloc(sizeof(HIST_ENTRY));
-       Bottom->next=tmp;
-       Bottom->prev=NULL;
-       Bottom->string=NULL;
-
-       tmp->prev=Bottom;
-
-       /*set new size*/
-       size++;
-
-}
-
-
-
-VOID History_move_to_bottom(VOID)
-{
-       curr_ptr=Bottom;
-
-}
-
-
-VOID History (INT dir, LPTSTR commandline)
-{
-
-       if(dir==0)
-       {
-               add_at_bottom(commandline);
-               curr_ptr=Bottom;
-               return;
-       }
-
-       if (size==0)
-       {
-               commandline[0]=_T('\0');
-               return;
-       }
-
-
-       if(dir<0)/*key up*/
-       {
-               if (curr_ptr->next==Top || curr_ptr==Top)
-               {
-#ifdef WRAP_HISTORY
-                       curr_ptr=Bottom;
-#else
-                       curr_ptr=Top;
-                       commandline[0]=_T('\0');
-                       return;
-#endif
-               }
-
-
-               curr_ptr = curr_ptr->next;
-               if(curr_ptr->string)
-                       _tcscpy(commandline,curr_ptr->string);
-
-       }
-
-
-
-
-
-       if(dir>0)
-       {
-
-               if (curr_ptr->prev==Bottom || curr_ptr==Bottom)
-               {
-#ifdef WRAP_HISTORY
-                       curr_ptr=Top;
-#else
-                       curr_ptr=Bottom;
-                       commandline[0]=_T('\0');
-                       return;
-#endif
-               }
-
-               curr_ptr=curr_ptr->prev;
-               if(curr_ptr->string)
-                       _tcscpy(commandline,curr_ptr->string);
-
-       }
-}
-
-
-
-
-
-
-#if 0
-
-LPTSTR history = NULL; /*buffer to sotre all the lines*/
-LPTSTR lines[MAXLINES];        /*array of pointers to each line(entry)*/
-                                               /*located in history buffer*/
-
-INT curline = 0;               /*the last line recalled by user*/
-INT numlines = 0;              /*number of entries, included the last*/
-                                               /*empty one*/
-
-INT maxpos = 0;                        /*index of last byte of last entry*/
-
-
-
-VOID History (INT dir, LPTSTR commandline)
-{
-
-       INT count;                                              /*used in for loops*/
-       INT length;                                             /*used in the same loops of count*/
-                                                                       /*both to make room when is full
-                                                                       either history or lines*/
-
-       /*first time History is called allocate mem*/
-       if (!history)
-       {
-               history = malloc (history_size * sizeof (TCHAR));
-               lines[0] = history;
-               history[0] = 0;
-       }
-
-       if (dir > 0)
-       {
-               /* next command */
-               if (curline < numlines)
-               {
-                       curline++;
-               }
-
-               if (curline == numlines)
-               {
-                       commandline[0] = 0;
-               }
-               else
-               {
-                       _tcscpy (commandline, lines[curline]);
-               }
-       }
-       else if (dir < 0)
-       {
-               /* prev command */
-               if (curline > 0)
-               {
-                       curline--;
-               }
-
-               _tcscpy (commandline, lines[curline]);
-       }
-       else
-       {
-               /* add to history */
-               /* remove oldest string until there's enough room for next one */
-               /* strlen (commandline) must be less than history_size! */
-               while ((maxpos + (INT)_tcslen (commandline) + 1 > history_size) || (numlines >= MAXLINES))
-               {
-                       length = _tcslen (lines[0]) + 1;
-
-                       for (count = 0; count < maxpos && count + (lines[1] - lines[0]) < history_size; count++)
-                       {
-                               history[count] = history[count + length];
-                       }
-
-                       maxpos -= length;
-
-                       for (count = 0; count <= numlines && count < MAXLINES; count++)
-                       {
-                               lines[count] = lines[count + 1] - length;
-                       }
-
-                       numlines--;
-#ifdef DEBUG
-                       ConOutPrintf (_T("Reduced size:  %ld lines\n"), numlines);
-
-                       for (count = 0; count < numlines; count++)
-                       {
-                               ConOutPrintf (_T("%d: %s\n"), count, lines[count]);
-                       }
-#endif
-               }
-
-               /*copy entry in the history bufer*/
-               _tcscpy (lines[numlines], commandline);
-               numlines++;
-
-               /*set last lines[numlines] pointer next the end of last, valid,
-               just setted entry (the two lines above)*/
-               lines[numlines] = lines[numlines - 1] + _tcslen (commandline) + 1;
-               maxpos += _tcslen (commandline) + 1;
-               /* last line, empty */
-
-               curline = numlines;
-       }
-
-       return;
-}
-
-#endif
-
-#endif //#if 0
diff --git a/reactos/subsys/system/cmd/history.txt b/reactos/subsys/system/cmd/history.txt
deleted file mode 100644 (file)
index a0cac6f..0000000
+++ /dev/null
@@ -1,367 +0,0 @@
-FreeDOS Command Line Interface Development History
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-11/11/94 version 0.01
-~~~~~~~~~~~~~~~~~~~~~
-o  initial release.
-
-01/01/95 version 0.10
-~~~~~~~~~~~~~~~~~~~~~
-o  removed some scaffolding.
-o  modified CD.
-o  added tab file completion.
-o  added command line history.
-
-01/15/95 version 0.20
-~~~~~~~~~~~~~~~~~~~~~
-o  formatted all existing source modules.
-o  added prompt support.
-o  added drive selection.
-o  added dir command.
-o  started this development log.
-
-08/06/95 prerelease of version 0.30
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-o  reorganized code into separate source modules.
-o  added batch processing support (thanks to Evan Jeffrey).
-o  added exec code (thanks to Steffan Kaiser).
-o  removed environment handling (thanks again to Steffan Kaiser)
-
-        [ 08/08/95 -- Matt Rains ]
-o  formatted this development log.
-o  formatted all existing source modules so that they comply with recommended
-        programming practice.
-o  added MD command.
-o  added RD command.
-o  added VER command.
-o  replaced CD command.
-o  modified DIR command.
-o  DIR now called regardless of other DIR.??? files. this is done because of
-        exec() problems.
-
-12/10/95 version 0.30
-~~~~~~~~~~~~~~~~~~~~~
-o  used Borland's spawnve to fix exec problem
-o  fixed CD again so you don't need a space after it
-o  couple of spelling fixes
-
-12/14/95 version 0.31
-~~~~~~~~~~~~~~~~~~~~~
-o  modified cmdinput.c to work with non-standard screen sizes (see 28.com)
-o  fixed a bug in history.c that made it not work when you hit the up arrow
-   on the first line
-o  fixed DIR to work a little more like MS-DOS's DIR (see internal.c)
-o  fixed some code in where.c to make things a bit more efficient and nicer
-
-01/06/96 version 0.40  (never released)
-~~~~~~~~~~~~~~~~~~~~~
-o  added redirection and piping support!!!  (see redir.c and command.c)
-o  fixed a stupid pointer problem in where.c that was causing LOTS of
-   problems in the strangest places...
-o  added day of the week support to prompt.c (oops, that was already supposed
-   to be there! :)
-o  fixed and reorganized the EXEC code!!!  Thanks to Svante Frey!
-o  reorganized command.c and internal.c to handle parsing internal commands
-   more efficiently and consistently.
-o  changed the behavior of MD, CD, RD to work without spaces (e.g. CD\DOS)
-o  small changes here and there to make it work with redirection/piping
-   (e.g. DIR only pauses if you're not doing redirection)
-
-01/17/96 version 0.50
-~~~~~~~~~~~~~~~~~~~~~
-Version 0.40 was never released because I was home on Christmas vacation,
-and I couldn't upload it.  By the time I got back to school, I had the
-LOADHIGH patch from Svante Frey, so I decided to jump up to 0.50 without any
-release of 0.40...       - Tim Norman
-
-o  LOADHIGH/LOADFIX/LH support added!!!!  Many thanks go to Svante Frey!
-o  bug fixed in command parsing that didn't handle / switches correctly...
-o  removed debugging output from history.c
-
-07/26/96 version 0.60
-~~~~~~~~~~~~~~~~~~~~~
-Lots of internal changes here...  Not much added to the interface.
-
-o  Changed internals to use first,rest parameters instead of arrays of params
-o  Fixed some bugs
-o  Some other things I don't remember :)
-
-07/26/96 version 0.61
-~~~~~~~~~~~~~~~~~~~~~
-Bugfixes
-
-o  Added hook to the PATH command
-o  Fixed CD.. bug
-
-08/27/96 version 0.70
-~~~~~~~~~~~~~~~~~~~~~
-Finally added Oliver Mueller's ALIAS command!  Also numerous bug fixes.
-
-o  Added ALIAS command
-o  Removed support for - as a switch in LOADHIGH.C
-o  Bugfixes in BATCH.C.  %0 was returning garbage
-o  Removed lots of unused variables, reducing # of warnings when compiling
-o  Other miscellaneous code clean-ups
-o  Changed WHERE.C to use a little less memory
-
-06/14/97 version 0.71
-~~~~~~~~~~~~~~~~~~~~~
-Lots of bug fixes, plus some additional features.
-
-o  New DIR command.  Now more like MS-DOS's DIR.  /p supported, /s coming soon
-o  bug fix in internal.c - parse_firstarg
-o  Rewrote parser in batch.c (Steffan Kaiser)
-o  Ctrl-Break checking in various places (Steffan Kaiser)
-o  Error level setting/checking (%? in batch files) (Steffan Kaiser)
-o  bug fix in cmdinput.c ("%i" on command-line caused weird behavior)
-o  bug fix in where.c (first item in path wasn't searched)
-
-07/12/97 version 0.72
-~~~~~~~~~~~~~~~~~~~~~
-More bug fixes and code cleanup
-
-o  Rewrote cmdinput.c to be more efficient (Marc Desrochers)
-o  Added insert/overstrike modes (Marc Desrochers)
-o  Replaced findxy() with pointers into BIOS (maxx, maxy) (Marc Desrochers)
-o  Fixed bug that disallowed listing of root directories
-o  Fixed bug that didn't search the first path (again!)
-
-07/13/97 version 0.72b
-~~~~~~~~~~~~~~~~~~~~~~
-Disabled a feature that caused a crash on some machines.
-
-o  Replaced setcursor calls in cmdinput.c with _setcursortype
-o  Added dir.c to the distribution (was left out in 0.72)
-
-07/01/98 version 0.73 (Rob Lake)
-~~~~~~~~~~~~~~~~~~~~~~
-o New DIR commands supported: /S, /B, /L, /A and /W.
-  (/R changed to /S).  Also /? added.
-o Supports DIRCMD in environment.
-o Supports turning off commands with hyphen (ex. /-S
-  turns off recursive listing)
-o Changed error messages for DIR and DEL to more MS-DOS'ish
-o Moved error messages from DIR.C and DEL.C to COMMAND.H
-  (more may go there soon)
-o Fixed bug that caused dir *.ext/X not to work (no spaces
-  between filespec and slash)
-o Added wildcard support for DEL command
-o Added prompt and help switch for DEL command, /P and /?
-  respectively.
-o Added support for /C when envoking the shell
-o Added /P support when Kernel loads shell.  This means
-  the shell now is permanent and runs the autoexec.bat
-  (/E is not implemented)
-o Added my name (Rob Lake) to the developer listing
-o Changed version routine to print out copyright notice
-  with no args, and with appropriate switches, warranty
-  and redistribution notices and developer listing
-
-07/08/1998 version 0.74 (John P. Price (linux-guru@gcfl.net))
-~~~~~~~~~~~~~~~~~~~~~~~~
-COMMAND.C/COMMAND.H:
-o Now sets COMSPEC environment variable
-o misc clean up and optimization
-o added date, time and type commands
-o changed to using spawnl instead of exec.  exec does not copy the
-  environment to the child process!
-DIR.C
-o removed extra returns; closer to MSDOS
-o fixed wide display so that an extra return is not displayed when
-  there is five filenames in the last line.
-ENVIRON.C
-o commented out show_environment function.  Not used anymore.
-INTERAL.C
-o removed call to show_environment in set command.
-o moved test for syntax before allocating memory in set command.
-o misc clean up and optimization.
-
-o created DATE.C
-o created TIME.C
-o created TYPE.C
-
-07/08/1998 version 0.74b (John P. Price (linux-guru@gcfl.net))
-~~~~~~~~~~~~~~~~~~~~~~~~
-COMMAND.C
-o fixed call to spawnl so that it would pass command line arguments
-  correctly.
-
-07/12/98 version 0.74c (Rob Lake rlake@cs.mun.ca)
-~~~~~~~~~~~~~~~~~~~~~~
-Various Files:
-o removed redundant use of error message defines and moved
-  error printing calls to ERROR.C to reduced program size.
-
-o created MISC.C
-o created ERR_HAND.C/H
-o created ERROR.C
-
-07/13/98 version 0.74d (Rob Lake rlake@cs.mun.ca)
-~~~~~~~~~~~~~~~~~~~~~~
-INTERNAL.C
-o removed most of the commands and placed them in there own file
-  -- del, ren, set and ver
-o created DEL.C, REN.C SET.C and VER.C
-o fixed bug that caused del not to delete files with no attributes
-o the critical error handler count number of times called, autofails
-  at 5 calls
-
-
-16 Jul 1998 (Hans B Pufal <hansp@digiweb.com>)
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-batch.c
-  A new version, implements CALL, ECHO, GOT, IF, PAUSE, SHIFT and
-  BEEP. There is a stub for FOR but that's all.
-
-cmdtable.c
-  New file to keep the internal command table. I plan on getting rid
-  of the table real soon now and replacing it with a dynamic
-  mechanism.
-
-command.c
-  A new (improved ;) version. Conforms closely to MS-DOS specs.
-  Cleaned up (and fixed) the redirection handler.
-
-command.h
-  Version D with changes. Look for the HBP tag.
-
-redir.c
-  Modified file, now supports append redirects.
-
-
-16 Jul 1998 (Rob Lake rlake@cs.mun.ca)
-~~~~~~~~~~~~~~~~~~~~~~
-Added TRUENAME command.
-
-
-19 Jul 1998 (Hans B Pufal) <hansp@digiweb.com>)
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-o Preserve state of echo flag across batch calls.
-o Implementation of FOR command
-
-
-20 Jul 1998 (John P Price <linux-guru@gcfl.net>)
-~~~~~~~~~~~~~~~~~~~~~~
-o Fixed bug in DATE.C.
-o Fixed bug in LH.ASM.
-o Separated commands into individual files.
-
-
-28 Jul 1998 (John P Price <linux-guru@gcfl.net>)
-~~~~~~~~~~~~~~~~~~~~~~
-o Added CLS command.
-o Put ifdef's around all commands and added include file config.h
-  Now you can define exact what commands you want to include in
-  command.com.
-o Also added ifdefs for optional features: aliases, command history
-  and filename completion.
-o Added display of available internal commands and options at startup.
-
-
-29 Jul 1998 (Rob Lake rlake@cs.mun.ca)
-~~~~~~~~~~~~~~~~~~~~~~
-o changed date.c and time.c, and wrote datefunc.c and timefunc.c to
-  impliment _dos_getdate, _dos_setdate, _dos_gettime and _dos_settime.
-  This is the first of many steps to make the shell compatible under
-  Pacific C.
-
-30-Jul-1998 (John P Price <linux-guru@gcfl.net>)
-~~~~~~~~~~~~~~~~~~~~~~
-o Changed filename completion so that a second TAB displays a list of
-  matching filenames!
-o made filename be lower case if last character typed is lower case.
-o Moved filename completion code to filecomp.c.
-o Change ver command to display email address to report bugs, and the
-  web page address for updates.
-o fixed so that it find_which returns NULL if filename is not
-  executable (does not have .bat, .com, or .exe extension).  Before
-  command would to execute any file with any extension. (opps!)
-
-30-Jul-1998 (John P Price <linux-guru@gcfl.net>)
-~~~~~~~~~~~~~~~~~~~~~~
-o Fixed bug where if you typed something, then hit HOME, then tried to
-  type something else in insert mode, it locked up.
-o Changed default insert mode to on.  There should be a way to change
-  this.  Maybe options to doskey command.
-o Added VERIFY command
-
-02-Aug-1998 (Hans B Pufal) <hansp@digiweb.com>)
-~~~~~~~~~~~~~~~~~~~~~~
-o batch.c: Fixed bug in ECHO flag restoration at exit from batch file
-o command.c: Fixed return value when called with /C option
-o Terminate label on first space character, use only first 8 chars of
-  label string
-
-04-Aug-1998 (Hans B Pufal) <hansp@digiweb.com>)
-~~~~~~~~~~~~~~~~~~~~~~
-o call.c: added lines to initialize for pointers.  This fixed the
-  lock-up that happened sometimes when calling a batch file from
-  another batch file.
-
-07-Aug-1998 (John P Price <linux-guru@gcfl.net>)
-~~~~~~~~~~~~~~~~~~~~~~
-o Fixed carrage return output to better match MSDOS with echo on or off.
-
-
-07-Dec-1998 ReactOS CMD version 0.0.1 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-o First test release.
-o Added internal ATTRIB command.
-
-11-Dec-1998 ReactOS CMD version 0.0.2 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-o Fixed bug in ALIAS. CMD crashed when you tried to remove an alias.
-o Fixed bug in split(). Added freep(). This fixed the DEL command.
-o Improved ATTRIB command.
-o Added most help texts.
-o Fixed recursive DIR ("dir /s").
-o Fixed DATE and TIME command. Now they accept values when used
-  without parameter.
-o Implemented LABEL command.
-
-05-Jan-1999 ReactOS CMD version 0.0.3 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-o Added COLOR command and "/t" option.
-o Cursor shows insert/overwrite mode.
-o COMSPEC environment variable is set upon startup.
-o Started COPY command.
-o Started MOVE command.
-o Added directory stack (PUSHD and POPD commands).
-o Added support for file names or paths that contain spaces
-  (quoted paths / file names).
-o Added recursion to ATTRIB command.
-o Added locale support for DIR, DATE, TIME and PROMPT.
-o Fixed VERIFY.
-
-10-Feb-1999 ReactOS CMD version 0.0.4 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-o "?" lists all available commands.
-o Most commands are unicode and redirection aware now.
-o Input-, Output- and Error-Redirections works with most commands.
-o ATTRIB and DEL can handle multiple filenames now.
-o Fixed handling of environment variables.
-o Added CHCP command.
-o Fixed keyboard input bug.
-o Rewrote DEL and MOVE commands.
-
-28-Dec-1999 ReactOS CMD version 0.1 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-o Cleaned up DIR command.
-o Searching for executables in the right order.
-o Fixed some little but nasty bugs.
-o Added TITLE command. Thanks to Emanuele Aliberti!
-o Added "/Q", "/W" and "/Z" options to DEL command.
-o Added CHOICE, TIMER, FREE and MEMORY commands.
-o Added MSGBOX command (not available under ReactOS).
-o Added and fixed missing help texts.
-o Fixed bugs in MD and RD that crashed cmd when no directory was specified.
-o Improved history support.
-o Improved COLOR command.
-
-09-Apr-2000 ReactOS CMD version 0.1 (EricKohl <ekohl@rz-online.de>
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-o Fixed bug in COPY command. CMD crashed if source file didn't exist.
-
-13-Jul-2000 ReactOS CMD version 0.1.1 (EricKohl <ekohl@rz-online.de>
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-o Implemented 'ECHO.' and 'ECHOERR.' commands.
diff --git a/reactos/subsys/system/cmd/if.c b/reactos/subsys/system/cmd/if.c
deleted file mode 100644 (file)
index b040d1c..0000000
+++ /dev/null
@@ -1,213 +0,0 @@
-/*
- *  IF.C - if internal batch command.
- *
- *
- *  History:
- *
- *    16 Jul 1998 (Hans B Pufal)
- *        started.
- *
- *    16 Jul 1998 (John P Price)
- *        Seperated commands into individual files.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    07-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("if /?") and cleaned up.
- *
- *    21-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection ready!
- *
- *    01-Sep-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed help text.
- *
- *    17-Feb-2001 (ea)
- *        IF DEFINED variable command
- *
- *    28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- *
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-#define X_EXEC 1
-#define X_EMPTY 0x80
-
-INT cmd_if (LPTSTR cmd, LPTSTR param)
-{
-       INT x_flag = 0; /* when set cause 'then' clause to be executed */
-       LPTSTR pp;
-
-#ifdef _DEBUG
-       DebugPrintf (_T("cmd_if: (\'%s\', \'%s\')\n"), cmd, param);
-#endif
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_IF_HELP1);
-               return 0;
-       }
-
-       /* First check if param string begins with 'not' */
-       if (!_tcsnicmp (param, _T("not"), 3) && _istspace (*(param + 3)))
-       {
-               x_flag = X_EXEC;            /* Remember 'NOT' */
-               param += 3;                 /* Step over 'NOT' */
-               while (_istspace (*param))  /* And subsequent spaces */
-                       param++;
-       }
-
-       /* Check for 'exist' form */
-       if (!_tcsnicmp (param, _T("exist"), 5) && _istspace (*(param + 5)))
-       {
-               UINT i;
-               BOOL bInside = FALSE;
-
-               param += 5;
-               while (_istspace (*param))
-                       param++;
-
-               pp = param;
-
-               /* find the whole path to the file */
-               for(i = 0; i < _tcslen(param); i++)
-               {
-                       if(param[i] == _T('\"')) 
-                               bInside = !bInside;
-                       if((param[i] == _T(' ')) && !bInside)
-                       {                                       
-                               break;
-                       }
-                       pp++;
-               }
-               *pp++ = _T('\0');
-               i = 0;
-               /* remove quotes */
-               while(i < _tcslen(param))
-               {
-                       if(param[i] == _T('\"'))
-                               memmove(&param[i],&param[i + 1], _tcslen(&param[i]) * sizeof(TCHAR));
-                       else
-                               i++;
-               }
-
-               if (*pp)
-               {                       
-                       WIN32_FIND_DATA f;
-                       HANDLE hFind;
-                       
-                       hFind = FindFirstFile (param, &f);
-                       x_flag ^= (hFind == INVALID_HANDLE_VALUE) ? 0 : X_EXEC;
-                       if (hFind != INVALID_HANDLE_VALUE)
-                       {
-                               FindClose (hFind);
-                       }
-               }
-               else
-                       return 0;
-       }
-       else if (!_tcsnicmp (param, _T("defined"), 7) && _istspace (*(param + 7)))
-       {
-               /* Check for 'defined' form */
-               TCHAR Value [1];
-               INT   ValueSize = 0;
-
-               param += 7;
-               /* IF [NOT] DEFINED var COMMAND */
-               /*                 ^            */
-               while (_istspace (*param))
-                       param++;
-               /* IF [NOT] DEFINED var COMMAND */
-               /*                  ^           */
-               pp = param;
-               while (*pp && !_istspace (*pp))
-                       pp++;
-               /* IF [NOT] DEFINED var COMMAND */
-               /*                     ^        */
-               if (*pp)
-               {
-                       *pp++ = _T('\0');
-                       ValueSize = GetEnvironmentVariable(param, Value, sizeof(Value) / sizeof(Value[0]));
-                       x_flag ^= (0 == ValueSize)
-                                       ? 0
-                                       : X_EXEC;
-                       x_flag |= X_EMPTY;
-               }
-               else
-                       return 0;
-       }
-       else if (!_tcsnicmp (param, _T("errorlevel"), 10) && _istspace (*(param + 10)))
-       {
-               /* Check for 'errorlevel' form */
-               INT n = 0;
-
-               pp = param + 10;
-               while (_istspace (*pp))
-                       pp++;
-
-               while (_istdigit (*pp))
-                       n = n * 10 + (*pp++ - _T('0'));
-
-               x_flag ^= (nErrorLevel != n) ? 0 : X_EXEC;
-
-               x_flag |= X_EMPTY;          /* Syntax error if comd empty */
-       }
-       else
-       {
-               BOOL bInQuote = FALSE;
-               INT p1len;
-               pp = param;
-               while ( *pp && ( bInQuote || *pp != _T('=') ) )
-               {
-                       if ( *pp == _T('\"') )
-                               bInQuote = !bInQuote;
-                       ++pp;
-               }
-               p1len = pp-param;
-               /* check for "==" */
-               if ( *pp++ != _T('=') || *pp++ != _T('=') )
-               {
-                       error_syntax ( NULL );
-                       return 1;
-               }
-               while (_istspace (*pp)) /* Skip subsequent spaces */
-                       pp++;
-
-               /* are the two sides equal, and does the second end in the same place? */
-               if ( !_tcsncmp(param,pp,p1len) && _tcschr(_T(" ("),pp[p1len]) )
-                       x_flag ^= X_EXEC;
-               pp += p1len;
-
-               if ( x_flag )
-               {
-                       while (*pp && !_istspace (*pp))  /* Find first space, */
-                               pp++;
-                       x_flag |= X_EMPTY;
-               }
-       }
-
-       if (x_flag & X_EMPTY)
-       {
-               while (_istspace (*pp)) /* Then skip spaces */
-                       pp++;
-
-               if (*pp == _T('\0'))    /* If nothing left then syntax err */
-               {
-                       error_syntax (NULL);
-                       return 1;
-               }
-       }
-
-       if (x_flag & X_EXEC)
-       {
-               ParseCommandLine (pp);
-       }
-
-       return 0;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/internal.c b/reactos/subsys/system/cmd/internal.c
deleted file mode 100644 (file)
index 5c62a9b..0000000
+++ /dev/null
@@ -1,767 +0,0 @@
-/*
- *  INTERNAL.C - command.com internal commands.
- *
- *
- *  History:
- *
- *  17/08/94 (Tim Norman)
- *    started.
- *
- *  08/08/95 (Matt Rains)
- *    i have cleaned up the source code. changes now bring this source into
- *    guidelines for recommended programming practice.
- *
- *  cd()
- *    started.
- *
- *  dir()
- *    i have added support for file attributes to the DIR() function. the
- *    routine adds "d" (directory) and "r" (read only) output. files with the
- *    system attribute have the filename converted to lowercase. files with
- *    the hidden attribute are not displayed.
- *
- *    i have added support for directorys. now if the directory attribute is
- *    detected the file size if replaced with the string "<dir>".
- *
- *  ver()
- *    started.
- *
- *  md()
- *    started.
- *
- *  rd()
- *    started.
- *
- *  del()
- *    started.
- *
- *  does not support wildcard selection.
- *
- *  todo: add delete directory support.
- *        add recursive directory delete support.
- *
- *  ren()
- *    started.
- *
- *  does not support wildcard selection.
- *
- *    todo: add rename directory support.
- *
- *  a general structure has been used for the cd, rd and md commands. this
- *  will be better in the long run. it is too hard to maintain such diverse
- *  functions when you are involved in a group project like this.
- *
- *  12/14/95 (Tim Norman)
- *    fixed DIR so that it will stick \*.* if a directory is specified and
- *    that it will stick on .* if a file with no extension is specified or
- *    *.* if it ends in a \
- *
- *  1/6/96 (Tim Norman)
- *    added an isatty call to DIR so it won't prompt for keypresses unless
- *    stdin and stdout are the console.
- *
- *    changed parameters to be mutually consistent to make calling the
- *    functions easier
- *
- *  rem()
- *    started.
- *
- *  doskey()
- *    started.
- *
- *    01/22/96 (Oliver Mueller)
- *        error messages are now handled by perror.
- *
- *    02/05/96 (Tim Norman)
- *        converted all functions to accept first/rest parameters
- *
- *    07/26/96 (Tim Norman)
- *        changed return values to int instead of void
- *
- *        path() started.
- *
- *    12/23/96 (Aaron Kaufman)
- *        rewrote dir() to mimic MS-DOS's dir
- *
- *    01/28/97 (Tim Norman)
- *        cleaned up Aaron's DIR code
- *
- *    06/13/97 (Tim Norman)
- *        moved DIR code to dir.c
- *        re-implemented Aaron's DIR code
- *
- *    06/14/97 (Steffan Kaiser)
- *        ctrl-break handling
- *        bug fixes
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    03-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Replaced DOS calls by Win32 calls.
- *
- *    08-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help texts ("/?").
- *
- *    18-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added support for quoted arguments (cd "program files").
- *
- *    07-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Clean up.
- *
- *    26-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Replaced remaining CRT io functions by Win32 io functions.
- *        Unicode safe!
- *
- *    30-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added "cd -" feature. Changes to the previous directory.
- *
- *    15-Mar-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed bug in "cd -" feature. If the previous directory was a root
- *        directory, it was ignored.
- *
- *    23-Feb-2001 (Carl Nettelblad <cnettel@hem.passagen.se>)
- *        Improved chdir/cd command.
- *
- *    02-Apr-2004 (Magnus Olsen <magnus@greatlord.com>)
- *        Remove all hard code string so they can be
- *               translate to other langues.
- *
- *    19-jul-2005 (Brandon Turner <turnerb7@msu.edu)
- *        Rewrite the CD, it working as Windows 2000 CMD
- *             
- *    19-jul-2005 (Magnus Olsen <magnus@greatlord.com)
- *        Add SetRootPath and GetRootPath         
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_CHDIR
-
-static LPTSTR lpLastPath;
-
-
-VOID InitLastPath (VOID)
-{
-       lpLastPath = NULL;
-}
-
-
-VOID FreeLastPath (VOID)
-{
-       if (lpLastPath)
-               free (lpLastPath);
-}
-
-/* help functions for getting current path from drive 
-   without changing drive. Return code 0 = ok, 1 = fail.
-   INT GetRootPath("C:",outbuffer,chater size of outbuffer);
-   the first param can have any size, if the the two frist
-   letter are not a drive with : it will get Currentpath on
-   current drive exacly as GetCurrentDirectory does.
-   */
-
-INT GetRootPath(TCHAR *InPath,TCHAR *OutPath,INT size)
-{
-  INT retcode = 1;
-  
-  if (_tcslen(InPath)>1)
-  {
-    if (InPath[1]==_T(':'))    
-    {   
-      INT t=0;
-     
-      if ((InPath[0] >= _T('0')) && (InPath[0] <= _T('9')))
-      {
-          t = (InPath[0] - _T('0')) +28;
-      }
-      
-      if ((InPath[0] >= _T('a')) && (InPath[0] <= _T('z')))
-      {
-          t = (InPath[0] - _T('a')) +1;
-          InPath[0] = t + _T('A') - 1;
-      }
-
-       if ((InPath[0] >= _T('A')) && (InPath[0] <= _T('Z')))
-      {
-          t = (InPath[0] - _T('A')) +1;
-      }
-                
-      if (_tgetdcwd(t,OutPath,size) != NULL) 
-      {                 
-        return 0;          
-      }    
-     } 
-    }
-   
-  /* fail */
-  if (_tcslen(InPath)>1)
-  {
-    if (InPath[1]==_T(':'))
-       return 1;  
-  }
-
-  /* Get current directory */
-  retcode = GetCurrentDirectory(size,OutPath);     
-  if (retcode==0) 
-      return 1;
-
-  return 0;
-}
-  
-
-BOOL SetRootPath(TCHAR *InPath)
-{
-  TCHAR oldpath[MAX_PATH];
-  TCHAR OutPath[MAX_PATH];
-  TCHAR OutPathTemp[MAX_PATH];
-  TCHAR OutPathTemp2[MAX_PATH];
-  BOOL fail;
-  
-  
-  /* Get The current directory path and save it */
-  fail = GetCurrentDirectory(MAX_PATH,oldpath);
-  if (!fail)   
-      return 1;
-  
-  /* Get current drive directory path if C: was only pass down*/
-  
-  if (_tcsncicmp(&InPath[1],_T(":\\"),2)!=0)
-  {
-      if (!GetRootPath(InPath,OutPathTemp,MAX_PATH))
-         _tcscpy(OutPathTemp,InPath);
-  }
-  else 
-  {
-    _tcscpy(OutPathTemp,InPath);
-  }
-  
-   _tcsupr(OutPathTemp); 
-  /* The use of both of these together will correct the case of a path
-     where as one alone or GetFullPath will not.  Exameple:
-         c:\windows\SYSTEM32 => C:\WINDOWS\system32 */
-  GetFullPathName(OutPathTemp, MAX_PATH, OutPathTemp2, NULL);
-  GetPathCase(OutPathTemp2, OutPath);
-
-  fail = SetCurrentDirectory(OutPath);
-  if (!fail) 
-      return 1;
-
-  
-    
-  SetCurrentDirectory(OutPath);
-  GetCurrentDirectory(MAX_PATH,OutPath);
-  _tchdir(OutPath);
-
-  if (_tcsncicmp(OutPath,oldpath,2)!=0)      
-      SetCurrentDirectory(oldpath);   
-
- return 0;
-} 
-
-
-/*
- * CD / CHDIR
- *
- */
-INT cmd_chdir (LPTSTR cmd, LPTSTR param)
-{
-       WIN32_FIND_DATA f; 
-       HANDLE hFile;
-       BOOL bChangeDrive = FALSE;
-       TCHAR szPath[MAX_PATH];
-       TCHAR szFinalPath[MAX_PATH];
-       TCHAR * tmpPath;
-       TCHAR szCurrent[MAX_PATH];
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       INT i;
-       /* Filter out special cases first */
-       /* Print Help */
-       if (!_tcsncmp(param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_CD_HELP);
-               return 0;
-       }
-  /* Set Error Level to Success */
-       nErrorLevel = 0;
-
-       /* Input String Contains /D Switch */
-       if (!_tcsncicmp(param, _T("/D"), 2))
-       {
-               bChangeDrive = TRUE;
-               tmpPath = _tcsstr(param,_T(" "));
-               if(!tmpPath)
-               {
-                       /* Didnt find an directories */
-                       LoadString(CMD_ModuleHandle, STRING_ERROR_PATH_NOT_FOUND, szMsg, RC_STRING_MAX_SIZE);
-                       ConErrPrintf(szMsg);
-                       nErrorLevel = 1;
-                       return 1;
-               }
-               tmpPath++;
-               _tcscpy(szPath,tmpPath);
-       }
-       else
-       {
-               _tcscpy(szPath,param);
-       }
-       /* Print Current Directory on a disk */
-       if (_tcslen(szPath) == 2 && szPath[1] == _T(':'))
-       {               
-               if(GetRootPath(szPath,szCurrent,MAX_PATH))
-               {
-                       nErrorLevel = 1;
-                       return 1;
-               }
-               ConOutPuts(szCurrent);
-               return 0;
-       }
-       /* Get Current Directory */
-       GetRootPath(_T("."),szCurrent,MAX_PATH);
-   /* Remove " */
-       i = 0;
-       while(i < (INT)_tcslen(szPath))
-       {
-               if(szPath[i] == _T('\"'))
-                       memmove(&szPath[i],&szPath[i + 1], _tcslen(&szPath[i]) * sizeof(TCHAR));
-               else
-                       i++;
-       }
-       tmpPath = szPath;
-       while (_istspace (*tmpPath))
-                       tmpPath++;
-       _tcscpy(szPath,tmpPath);
-       if (szPath[0] == _T('\0')) 
-       {
-               ConOutPuts(szCurrent);
-               return 0;
-       }
-        
-
-       /* change to full path if relative path was given */
-       GetFullPathName(szPath,MAX_PATH,szFinalPath,NULL);
-       if(szFinalPath[_tcslen(szFinalPath) - 1] == _T('\\') && _tcslen(szFinalPath) > 3)
-               szFinalPath[_tcslen(szFinalPath) - 1] = _T('\0');
-       /* Handle Root Directory Alone*/
-       if (_tcslen(szFinalPath) == 3 && szFinalPath[1] == _T(':'))
-       {               
-               if(!SetRootPath(szFinalPath))
-               {
-                       /* Change prompt if it is one the same drive or /D */
-                       if(bChangeDrive || !_tcsncicmp(szFinalPath,szCurrent,1))
-                               SetCurrentDirectory(szFinalPath);
-                       return 0;
-               }
-               /* Didnt find an directories */
-               LoadString(CMD_ModuleHandle, STRING_ERROR_PATH_NOT_FOUND, szMsg, RC_STRING_MAX_SIZE);
-               ConErrPrintf(szMsg);
-               nErrorLevel = 1;
-               return 1;
-       }
-       /* Get a list of all the files */
-       hFile = FindFirstFile (szFinalPath, &f);
-       do
-       {
-               if(hFile == INVALID_HANDLE_VALUE)
-               {               
-                       ConErrFormatMessage (GetLastError(), szFinalPath);                      
-                       nErrorLevel = 1;
-                       return 1;
-               }
-               /* Strip the paths back to the folder they are in */
-               for(i = (_tcslen(szFinalPath) -  1); i > -1; i--)
-                       if(szFinalPath[i] != _T('\\'))
-                               szFinalPath[i] = _T('\0');
-                       else
-                               break;
-               _tcscat(szFinalPath,f.cFileName);      
-               
-               if ((f.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) ==  FILE_ATTRIBUTE_DIRECTORY)
-               {                      
-                       if(!SetRootPath(szFinalPath))
-                       {
-                               /* Change for /D */
-                               if(bChangeDrive)
-                               {   
-                                       _tcsupr(szFinalPath);   
-                                       GetPathCase(szFinalPath, szPath);
-                                       SetCurrentDirectory(szPath);
-                               }
-                               return 0;
-                       }
-
-               }
-       }while(FindNextFile (hFile, &f));
-       /* Didnt find an directories */
-       LoadString(CMD_ModuleHandle, STRING_ERROR_PATH_NOT_FOUND, szMsg, RC_STRING_MAX_SIZE);
-       ConErrPrintf(szMsg);
-       nErrorLevel = 1;
-       return 1;
-}
-
-#endif
-
-
-
-#ifdef INCLUDE_CMD_MKDIR
-
-/* Helper funtion for mkdir to make directories in a path.  
-Dont use the api to decrease depence on libs */
-BOOL 
-MakeFullPath(TCHAR * DirPath)
-{
-    TCHAR path[MAX_PATH];
-    TCHAR *p = DirPath;
-    INT  n;
-
-    if (p[0] && p[1] == _T(':')) 
-        p += 2;
-    while (*p == _T('\\')) 
-        p++; /* skip drive root */
-    while ((p = _tcschr(p, _T('\\'))) != NULL)
-    {
-       n = p - DirPath + 1;
-       memcpy(path, DirPath, n);
-       path[n] = _T('\0');
-       if( !CreateDirectory(path, NULL) &&
-           (GetLastError() != ERROR_ALREADY_EXISTS))
-           return FALSE;
-       p++;
-    }
-    if (GetLastError() == ERROR_ALREADY_EXISTS)
-       SetLastError(ERROR_SUCCESS);
-
-    return TRUE;
-}
-
-/*
- * MD / MKDIR
- *
- */
-INT cmd_mkdir (LPTSTR cmd, LPTSTR param)
-{
-       LPTSTR dir;             /* pointer to the directory to change to */
-       LPTSTR place;   /* used to search for the \ when no space is used */
-       LPTSTR *p = NULL;
-       INT argc;
-       nErrorLevel = 0;
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_MKDIR_HELP);
-               return 0;
-       }
-
-
-       /* check if there is no space between the command and the path */
-       if (param[0] == _T('\0'))
-       {
-               /* search for the \ or . so that both short & long names will work */
-               for (place = cmd; *place; place++)
-                       if (*place == _T('.') || *place == _T('\\'))
-                               break;
-
-               if (*place)
-                       dir = place;
-               else
-                       /* signal that there are no parameters */
-                       dir = NULL;
-       }
-       else
-       {
-               p = split (param, &argc, FALSE);
-               if (argc > 1)
-               {
-                       /*JPP 20-Jul-1998 use standard error message */
-                       error_too_many_parameters (param);
-                       freep (p);
-                       return 1;
-               }
-               else
-                       dir = p[0];
-       }
-
-       if (!dir)
-       {
-               ConErrResPuts (STRING_ERROR_REQ_PARAM_MISSING);
-               nErrorLevel = 1;
-               if(p != NULL)
-                       freep (p);
-               return 1;
-       }
-
-       /* Add a \ at the end of the path is there isnt on already */
-       if (dir[_tcslen (dir) - 1] != _T('\\'))
-               _tcscat(dir,_T("\\"));
-
-    if (!MakeFullPath(dir))
-    {
-        if(GetLastError() == ERROR_PATH_NOT_FOUND)
-        {
-            ConErrResPuts(STRING_MD_ERROR2);
-        }
-        else
-        {
-            ErrorMessage (GetLastError(), _T("MD"));
-        }
-        nErrorLevel = 1;
-        freep (p);
-        return 1;
-    }
-
-       freep (p);
-
-       return 0;
-}
-#endif
-
-
-#ifdef INCLUDE_CMD_RMDIR
-/*
- * RD / RMDIR
- *
- */
-BOOL DeleteFolder(LPTSTR FileName)
-{
-       TCHAR Base[MAX_PATH];
-       TCHAR TempFileName[MAX_PATH];
-       HANDLE hFile;
-    WIN32_FIND_DATA f;
-       _tcscpy(Base,FileName);
-       _tcscat(Base,_T("\\*"));
-       hFile = FindFirstFile(Base, &f);
-       Base[_tcslen(Base) - 1] = _T('\0');
-    if (hFile != INVALID_HANDLE_VALUE)
-    {
-        do
-        {
-                       if (!_tcscmp(f.cFileName, _T(".")) ||
-                !_tcscmp(f.cFileName, _T("..")))
-                       continue;
-                       _tcscpy(TempFileName,Base);
-                       _tcscat(TempFileName,f.cFileName);
-
-                       if(f.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                               DeleteFolder(TempFileName);
-                       else
-                       {
-                               SetFileAttributes(TempFileName,FILE_ATTRIBUTE_NORMAL);
-                               if(!DeleteFile(TempFileName))
-                                       return 0;
-                       }
-
-        }while (FindNextFile (hFile, &f));
-           FindClose (hFile);
-    }
-       return RemoveDirectory(FileName);
-}
-INT cmd_rmdir (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR dir[MAX_PATH];            /* pointer to the directory to change to */
-       char ch;
-       INT args;
-       LPTSTR *arg = NULL;
-       INT i;
-       BOOL RD_SUB = FALSE;
-       BOOL RD_QUIET = FALSE;
-       HANDLE hFile;
-       WIN32_FIND_DATA f;
-       INT res;
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       TCHAR szFullPath[MAX_PATH];
-       
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_RMDIR_HELP);
-               return 0;
-       }
-
-       nErrorLevel = 0;
-
-       arg = split (param, &args, FALSE);
-
-       if (args == 0)
-       {
-               /* only command given */
-               error_req_param_missing ();
-               freep (arg);
-               return 1;
-       }
-
-       dir[0] = 0;
-       /* check for options anywhere in command line */
-       for (i = 0; i < args; i++)
-       {
-               if (*arg[i] == _T('/'))
-               {
-                       /*found a command, but check to make sure it has something after it*/
-                       if (_tcslen (arg[i]) == 2)
-                       {
-                               ch = _totupper (arg[i][1]);
-                               if (ch == _T('S'))
-                               {
-                                       RD_SUB = TRUE;
-                               }
-                               else if (ch == _T('Q'))
-                               {
-                                       RD_QUIET = TRUE;
-                               }
-                       }
-               }
-               else
-               {
-                       /* get the folder name */
-                       _tcscpy(dir,arg[i]);
-               }
-       }
-       
-       if (dir[0] == _T('\0'))
-       {
-               /* No folder to remove */
-               ConErrResPuts(STRING_ERROR_REQ_PARAM_MISSING);
-               freep(arg);
-               return 1;
-       }
-
-       GetFullPathName(dir,MAX_PATH,szFullPath,NULL);
-       /* remove trailing \ if any, but ONLY if dir is not the root dir */
-       if (_tcslen (szFullPath) >= 2 && szFullPath[_tcslen (szFullPath) - 1] == _T('\\'))
-               szFullPath[_tcslen(szFullPath) - 1] = _T('\0');
-
-       if(RD_SUB)
-       {
-               /* ask if they want to delete evrything in the folder */
-               if (!RD_QUIET)
-               {
-                       LoadString( CMD_ModuleHandle, STRING_DEL_HELP2, szMsg, RC_STRING_MAX_SIZE);
-                       res = FilePromptYNA (szMsg);
-                       if ((res == PROMPT_NO) || (res == PROMPT_BREAK))
-                       {
-                               freep(arg);
-                               nErrorLevel = 1;
-                               return 1;
-                       }
-               }
-
-       }
-       else
-       {
-               /* check for files in the folder */
-               _tcscat(szFullPath,_T("\\*"));
-
-               hFile = FindFirstFile(szFullPath, &f);
-               if (hFile != INVALID_HANDLE_VALUE)
-               {
-                       do
-                       {
-                               if (!_tcscmp(f.cFileName,_T(".")) ||
-                                       !_tcscmp(f.cFileName,_T("..")))
-                                       continue;
-                               ConOutResPuts(STRING_RMDIR_HELP2);
-                               freep(arg);
-                               FindClose (hFile);
-                               nErrorLevel = 1;
-                               return 1;
-                       }while (FindNextFile (hFile, &f));
-                       FindClose (hFile);
-               }
-               /* reovme the \\* */
-               szFullPath[_tcslen(szFullPath) - 2] = _T('\0');
-       }
-
-       if (!DeleteFolder(szFullPath))
-       {
-               /* Couldnt delete the folder, clean up and print out the error */
-               ErrorMessage (GetLastError(), _T("RD"));
-               freep (arg);
-               nErrorLevel = 1;
-               return 1;
-       }
-
-       freep (arg);
-       return 0;
-}
-#endif
-
-
-/*
- * set the exitflag to true
- *
- */
-INT CommandExit (LPTSTR cmd, LPTSTR param)
-{
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_EXIT_HELP);
-               /* Just make sure */
-               bExit = FALSE;
-               /* Dont exit */
-               return 0;
-       }
-
-       if (bc != NULL && _tcsnicmp(param,_T("/b"),2) == 0)
-       {
-               param += 2;
-               while (_istspace (*param))
-                       param++;
-               if (_istdigit(*param))
-                       nErrorLevel = _ttoi(param);
-               ExitBatch (NULL);
-       }
-               
-       else
-               bExit = TRUE;
-
-       
-       return 0;
-
-}
-
-#ifdef INCLUDE_CMD_REM
-/*
- * does nothing
- *
- */
-INT CommandRem (LPTSTR cmd, LPTSTR param)
-{
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_REM_HELP);
-       }
-
-       return 0;
-}
-#endif /* INCLUDE_CMD_REM */
-
-
-INT CommandShowCommands (LPTSTR cmd, LPTSTR param)
-{
-       PrintCommandList ();
-       return 0;
-}
-
-INT CommandShowCommandsDetail (LPTSTR cmd, LPTSTR param)
-{
-       PrintCommandListDetail ();
-       return 0;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/label.c b/reactos/subsys/system/cmd/label.c
deleted file mode 100644 (file)
index 670e0b3..0000000
+++ /dev/null
@@ -1,129 +0,0 @@
-/*
- *  LABEL.C - label internal command.
- *
- *
- *  History:
- *
- *    10-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Started.
- *
- *    11-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Finished.
- *
- *    19-Jan-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode ready!
- *
- *    28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_LABEL
-
-
-INT cmd_label (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       TCHAR  szRootPath[] = _T("A:\\");
-       TCHAR  szLabel[80];
-       TCHAR  szOldLabel[80];
-       DWORD  dwSerialNr;
-       LPTSTR *arg;
-       INT    args;
-
-       /* set empty label string */
-       szLabel[0] = _T('\0');
-
-       /* print help */
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_LABEL_HELP1);
-               return 0;
-       }
-
-  nErrorLevel = 0;
-
-       /* get parameters */
-       arg = split (param, &args, FALSE);
-
-       if (args > 2)
-       {
-               /* too many parameters */
-               error_too_many_parameters (arg[args - 1]);
-               freep (arg);
-    nErrorLevel = 1;
-               return 1;
-       }
-
-       if (args == 0)
-       {
-               /* get label of current drive */
-               TCHAR szCurPath[MAX_PATH];
-               GetCurrentDirectory (MAX_PATH, szCurPath);
-               szRootPath[0] = szCurPath[0];
-       }
-       else
-       {
-               if ((_tcslen (arg[0]) >= 2) && (arg[0][1] == _T(':')))
-               {
-                       szRootPath[0] = toupper (*arg[0]);
-                       if (args == 2)
-                               _tcsncpy (szLabel, arg[1], 12);
-               }
-               else
-               {
-                       TCHAR szCurPath[MAX_PATH];
-                       GetCurrentDirectory (MAX_PATH, szCurPath);
-                       szRootPath[0] = szCurPath[0];
-                       _tcsncpy (szLabel, arg[0], 12);
-               }
-       }
-
-       /* check root path */
-       if (!IsValidPathName (szRootPath))
-       {
-               error_invalid_drive ();
-               freep (arg);
-    nErrorLevel = 1;
-               return 1;
-       }
-
-       GetVolumeInformation(szRootPath, szOldLabel, 80, &dwSerialNr,
-                             NULL, NULL, NULL, 0);
-
-       /* print drive info */
-       if (szOldLabel[0] != _T('\0'))
-       {
-               LoadString(CMD_ModuleHandle, STRING_LABEL_HELP2, szMsg, RC_STRING_MAX_SIZE);
-               ConOutPrintf(szMsg, _totupper(szRootPath[0]), szOldLabel);
-       }
-       else
-       {
-               LoadString(CMD_ModuleHandle, STRING_LABEL_HELP3, szMsg, RC_STRING_MAX_SIZE);
-               ConOutPrintf(szMsg, _totupper(szRootPath[0]));
-       }
-
-       /* print the volume serial number */
-       LoadString(CMD_ModuleHandle, STRING_LABEL_HELP4, szMsg, RC_STRING_MAX_SIZE);
-       ConOutPrintf(szMsg, HIWORD(dwSerialNr), LOWORD(dwSerialNr));
-
-       if (szLabel[0] == _T('\0'))
-       {
-               LoadString(CMD_ModuleHandle, STRING_LABEL_HELP5, szMsg, RC_STRING_MAX_SIZE);
-               ConOutResPuts(STRING_LABEL_HELP5);
-
-               ConInString(szLabel, 80);
-       }
-
-       SetVolumeLabel(szRootPath, szLabel);
-
-       freep(arg);
-
-       return 0;
-}
-
-#endif /* INCLUDE_CMD_LABEL */
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/license.txt b/reactos/subsys/system/cmd/license.txt
deleted file mode 100644 (file)
index c4fb365..0000000
+++ /dev/null
@@ -1,342 +0,0 @@
-
-                    GNU GENERAL PUBLIC LICENSE
-                       Version 2, June 1991
-
- Copyright (C) 1989, 1991 Free Software Foundation, Inc.
-                          675 Mass Ave, Cambridge, MA 02139, USA
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
-                            Preamble
-
-  The licenses for most software are designed to take away your
-freedom to share and change it.  By contrast, the GNU General Public
-License is intended to guarantee your freedom to share and change free
-software--to make sure the software is free for all its users.  This
-General Public License applies to most of the Free Software
-Foundation's software and to any other program whose authors commit to
-using it.  (Some other Free Software Foundation software is covered by
-the GNU Library General Public License instead.)  You can apply it to
-your programs, too.
-
-  When we speak of free software, we are referring to freedom, not
-price.  Our General Public Licenses are designed to make sure that you
-have the freedom to distribute copies of free software (and charge for
-this service if you wish), that you receive source code or can get it
-if you want it, that you can change the software or use pieces of it
-in new free programs; and that you know you can do these things.
-
-  To protect your rights, we need to make restrictions that forbid
-anyone to deny you these rights or to ask you to surrender the rights.
-These restrictions translate to certain responsibilities for you if you
-distribute copies of the software, or if you modify it.
-
-  For example, if you distribute copies of such a program, whether
-gratis or for a fee, you must give the recipients all the rights that
-you have.  You must make sure that they, too, receive or can get the
-source code.  And you must show them these terms so they know their
-rights.
-
-  We protect your rights with two steps: (1) copyright the software, and
-(2) offer you this license which gives you legal permission to copy,
-distribute and/or modify the software.
-
-  Also, for each author's protection and ours, we want to make certain
-that everyone understands that there is no warranty for this free
-software.  If the software is modified by someone else and passed on, we
-want its recipients to know that what they have is not the original, so
-that any problems introduced by others will not reflect on the original
-authors' reputations.
-
-  Finally, any free program is threatened constantly by software
-patents.  We wish to avoid the danger that redistributors of a free
-program will individually obtain patent licenses, in effect making the
-program proprietary.  To prevent this, we have made it clear that any
-patent must be licensed for everyone's free use or not licensed at all.
-
-  The precise terms and conditions for copying, distribution and
-modification follow.
-\f
-                    GNU GENERAL PUBLIC LICENSE
-   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
-
-  0. This License applies to any program or other work which contains
-a notice placed by the copyright holder saying it may be distributed
-under the terms of this General Public License.  The "Program", below,
-refers to any such program or work, and a "work based on the Program"
-means either the Program or any derivative work under copyright law:
-that is to say, a work containing the Program or a portion of it,
-either verbatim or with modifications and/or translated into another
-language.  (Hereinafter, translation is included without limitation in
-the term "modification".)  Each licensee is addressed as "you".
-
-Activities other than copying, distribution and modification are not
-covered by this License; they are outside its scope.  The act of
-running the Program is not restricted, and the output from the Program
-is covered only if its contents constitute a work based on the
-Program (independent of having been made by running the Program).
-Whether that is true depends on what the Program does.
-
-  1. You may copy and distribute verbatim copies of the Program's
-source code as you receive it, in any medium, provided that you
-conspicuously and appropriately publish on each copy an appropriate
-copyright notice and disclaimer of warranty; keep intact all the
-notices that refer to this License and to the absence of any warranty;
-and give any other recipients of the Program a copy of this License
-along with the Program.
-
-You may charge a fee for the physical act of transferring a copy, and
-you may at your option offer warranty protection in exchange for a fee.
-
-  2. You may modify your copy or copies of the Program or any portion
-of it, thus forming a work based on the Program, and copy and
-distribute such modifications or work under the terms of Section 1
-above, provided that you also meet all of these conditions:
-
-    a) You must cause the modified files to carry prominent notices
-    stating that you changed the files and the date of any change.
-
-    b) You must cause any work that you distribute or publish, that in
-    whole or in part contains or is derived from the Program or any
-    part thereof, to be licensed as a whole at no charge to all third
-    parties under the terms of this License.
-
-    c) If the modified program normally reads commands interactively
-    when run, you must cause it, when started running for such
-    interactive use in the most ordinary way, to print or display an
-    announcement including an appropriate copyright notice and a
-    notice that there is no warranty (or else, saying that you provide
-    a warranty) and that users may redistribute the program under
-    these conditions, and telling the user how to view a copy of this
-    License.  (Exception: if the Program itself is interactive but
-    does not normally print such an announcement, your work based on
-    the Program is not required to print an announcement.)
-\f
-These requirements apply to the modified work as a whole.  If
-identifiable sections of that work are not derived from the Program,
-and can be reasonably considered independent and separate works in
-themselves, then this License, and its terms, do not apply to those
-sections when you distribute them as separate works.  But when you
-distribute the same sections as part of a whole which is a work based
-on the Program, the distribution of the whole must be on the terms of
-this License, whose permissions for other licensees extend to the
-entire whole, and thus to each and every part regardless of who wrote it.
-
-Thus, it is not the intent of this section to claim rights or contest
-your rights to work written entirely by you; rather, the intent is to
-exercise the right to control the distribution of derivative or
-collective works based on the Program.
-
-In addition, mere aggregation of another work not based on the Program
-with the Program (or with a work based on the Program) on a volume of
-a storage or distribution medium does not bring the other work under
-the scope of this License.
-
-  3. You may copy and distribute the Program (or a work based on it,
-under Section 2) in object code or executable form under the terms of
-Sections 1 and 2 above provided that you also do one of the following:
-
-    a) Accompany it with the complete corresponding machine-readable
-    source code, which must be distributed under the terms of Sections
-    1 and 2 above on a medium customarily used for software interchange; or,
-
-    b) Accompany it with a written offer, valid for at least three
-    years, to give any third party, for a charge no more than your
-    cost of physically performing source distribution, a complete
-    machine-readable copy of the corresponding source code, to be
-    distributed under the terms of Sections 1 and 2 above on a medium
-    customarily used for software interchange; or,
-
-    c) Accompany it with the information you received as to the offer
-    to distribute corresponding source code.  (This alternative is
-    allowed only for noncommercial distribution and only if you
-    received the program in object code or executable form with such
-    an offer, in accord with Subsection b above.)
-
-The source code for a work means the preferred form of the work for
-making modifications to it.  For an executable work, complete source
-code means all the source code for all modules it contains, plus any
-associated interface definition files, plus the scripts used to
-control compilation and installation of the executable.  However, as a
-special exception, the source code distributed need not include
-anything that is normally distributed (in either source or binary
-form) with the major components (compiler, kernel, and so on) of the
-operating system on which the executable runs, unless that component
-itself accompanies the executable.
-
-If distribution of executable or object code is made by offering
-access to copy from a designated place, then offering equivalent
-access to copy the source code from the same place counts as
-distribution of the source code, even though third parties are not
-compelled to copy the source along with the object code.
-\f
-  4. You may not copy, modify, sublicense, or distribute the Program
-except as expressly provided under this License.  Any attempt
-otherwise to copy, modify, sublicense or distribute the Program is
-void, and will automatically terminate your rights under this License.
-However, parties who have received copies, or rights, from you under
-this License will not have their licenses terminated so long as such
-parties remain in full compliance.
-
-  5. You are not required to accept this License, since you have not
-signed it.  However, nothing else grants you permission to modify or
-distribute the Program or its derivative works.  These actions are
-prohibited by law if you do not accept this License.  Therefore, by
-modifying or distributing the Program (or any work based on the
-Program), you indicate your acceptance of this License to do so, and
-all its terms and conditions for copying, distributing or modifying
-the Program or works based on it.
-
-  6. Each time you redistribute the Program (or any work based on the
-Program), the recipient automatically receives a license from the
-original licensor to copy, distribute or modify the Program subject to
-these terms and conditions.  You may not impose any further
-restrictions on the recipients' exercise of the rights granted herein.
-You are not responsible for enforcing compliance by third parties to
-this License.
-
-  7. If, as a consequence of a court judgment or allegation of patent
-infringement or for any other reason (not limited to patent issues),
-conditions are imposed on you (whether by court order, agreement or
-otherwise) that contradict the conditions of this License, they do not
-excuse you from the conditions of this License.  If you cannot
-distribute so as to satisfy simultaneously your obligations under this
-License and any other pertinent obligations, then as a consequence you
-may not distribute the Program at all.  For example, if a patent
-license would not permit royalty-free redistribution of the Program by
-all those who receive copies directly or indirectly through you, then
-the only way you could satisfy both it and this License would be to
-refrain entirely from distribution of the Program.
-
-If any portion of this section is held invalid or unenforceable under
-any particular circumstance, the balance of the section is intended to
-apply and the section as a whole is intended to apply in other
-circumstances.
-
-It is not the purpose of this section to induce you to infringe any
-patents or other property right claims or to contest validity of any
-such claims; this section has the sole purpose of protecting the
-integrity of the free software distribution system, which is
-implemented by public license practices.  Many people have made
-generous contributions to the wide range of software distributed
-through that system in reliance on consistent application of that
-system; it is up to the author/donor to decide if he or she is willing
-to distribute software through any other system and a licensee cannot
-impose that choice.
-
-This section is intended to make thoroughly clear what is believed to
-be a consequence of the rest of this License.
-\f
-  8. If the distribution and/or use of the Program is restricted in
-certain countries either by patents or by copyrighted interfaces, the
-original copyright holder who places the Program under this License
-may add an explicit geographical distribution limitation excluding
-those countries, so that distribution is permitted only in or among
-countries not thus excluded.  In such case, this License incorporates
-the limitation as if written in the body of this License.
-
-  9. The Free Software Foundation may publish revised and/or new versions
-of the General Public License from time to time.  Such new versions will
-be similar in spirit to the present version, but may differ in detail to
-address new problems or concerns.
-
-Each version is given a distinguishing version number.  If the Program
-specifies a version number of this License which applies to it and "any
-later version", you have the option of following the terms and conditions
-either of that version or of any later version published by the Free
-Software Foundation.  If the Program does not specify a version number of
-this License, you may choose any version ever published by the Free Software
-Foundation.
-
-  10. If you wish to incorporate parts of the Program into other free
-programs whose distribution conditions are different, write to the author
-to ask for permission.  For software which is copyrighted by the Free
-Software Foundation, write to the Free Software Foundation; we sometimes
-make exceptions for this.  Our decision will be guided by the two goals
-of preserving the free status of all derivatives of our free software and
-of promoting the sharing and reuse of software generally.
-
-                            NO WARRANTY
-
-  11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
-FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
-OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
-PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
-OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
-MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS
-TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE
-PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
-REPAIR OR CORRECTION.
-
-  12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
-WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
-REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
-INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
-OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
-TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
-YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
-PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
-POSSIBILITY OF SUCH DAMAGES.
-
-                     END OF TERMS AND CONDITIONS
-\f
-        Appendix: How to Apply These Terms to Your New Programs
-
-  If you develop a new program, and you want it to be of the greatest
-possible use to the public, the best way to achieve this is to make it
-free software which everyone can redistribute and change under these terms.
-
-  To do so, attach the following notices to the program.  It is safest
-to attach them to the start of each source file to most effectively
-convey the exclusion of warranty; and each file should have at least
-the "copyright" line and a pointer to where the full notice is found.
-
-    <one line to give the program's name and a brief idea of what it does.>
-    Copyright (C) 19yy  <name of author>
-
-    This program is free software; you can redistribute it and/or modify
-    it under the terms of the GNU General Public License as published by
-    the Free Software Foundation; either version 2 of the License, or
-    (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-
-Also add information on how to contact you by electronic and paper mail.
-
-If the program is interactive, make it output a short notice like this
-when it starts in an interactive mode:
-
-    Gnomovision version 69, Copyright (C) 19yy name of author
-    Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
-    This is free software, and you are welcome to redistribute it
-    under certain conditions; type `show c' for details.
-
-The hypothetical commands `show w' and `show c' should show the appropriate
-parts of the General Public License.  Of course, the commands you use may
-be called something other than `show w' and `show c'; they could even be
-mouse-clicks or menu items--whatever suits your program.
-
-You should also get your employer (if you work as a programmer) or your
-school, if any, to sign a "copyright disclaimer" for the program, if
-necessary.  Here is a sample; alter the names:
-
-  Yoyodyne, Inc., hereby disclaims all copyright interest in the program
-  `Gnomovision' (which makes passes at compilers) written by James Hacker.
-
-  <signature of Ty Coon>, 1 April 1989
-  Ty Coon, President of Vice
-
-This General Public License does not permit incorporating your program into
-proprietary programs.  If your program is a subroutine library, you may
-consider it more useful to permit linking proprietary applications with the
-library.  If this is what you want to do, use the GNU Library General
-Public License instead of this License.
-
-
diff --git a/reactos/subsys/system/cmd/locale.c b/reactos/subsys/system/cmd/locale.c
deleted file mode 100644 (file)
index fe77f67..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- *  LOCALE.C - locale handling.
- *
- *
- *  History:
- *
- *    09-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Started.
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode safe!
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-TCHAR cDateSeparator;
-TCHAR cTimeSeparator;
-TCHAR cThousandSeparator;
-TCHAR cDecimalSeparator;
-INT   nDateFormat;
-INT   nTimeFormat;
-INT   nNumberGroups;
-
-
-VOID InitLocale (VOID)
-{
-       TCHAR szBuffer[256];
-
-       /* date settings */
-       GetLocaleInfo (LOCALE_USER_DEFAULT, LOCALE_SDATE, szBuffer, sizeof(szBuffer) / sizeof(szBuffer[0]));
-       cDateSeparator = szBuffer[0];
-       GetLocaleInfo (LOCALE_USER_DEFAULT, LOCALE_IDATE | LOCALE_RETURN_NUMBER, (LPTSTR)&nDateFormat, sizeof(nDateFormat) / sizeof(TCHAR));
-
-       /* time settings */
-       GetLocaleInfo (LOCALE_USER_DEFAULT, LOCALE_STIME, szBuffer, sizeof(szBuffer) / sizeof(szBuffer[0]));
-       cTimeSeparator = szBuffer[0];
-       GetLocaleInfo (LOCALE_USER_DEFAULT, LOCALE_ITIME | LOCALE_RETURN_NUMBER, (LPTSTR)&nTimeFormat, sizeof(nTimeFormat) / sizeof(TCHAR));
-
-       /* number settings */
-       GetLocaleInfo (LOCALE_USER_DEFAULT, LOCALE_STHOUSAND, szBuffer, sizeof(szBuffer) / sizeof(szBuffer[0]));
-       cThousandSeparator = szBuffer[0];
-       GetLocaleInfo (LOCALE_USER_DEFAULT, LOCALE_SDECIMAL, szBuffer, sizeof(szBuffer) / sizeof(szBuffer[0]));
-       cDecimalSeparator  = szBuffer[0];
-        GetLocaleInfo (LOCALE_USER_DEFAULT, LOCALE_SGROUPING, szBuffer, sizeof(szBuffer) / sizeof(szBuffer[0]));
-        nNumberGroups = _ttoi(szBuffer);
-#if 0
-       /* days of week */
-       for (i = 0; i < 7; i++)
-       {
-               GetLocaleInfo (LOCALE_USER_DEFAULT, LOCALE_SABBREVDAYNAME1 + i, szBuffer, sizeof(szBuffer) / sizeof(szBuffer[0]));
-               _tcscpy (aszDayNames[(i+1)%7], szBuffer); /* little hack */
-       }
-#endif
-}
-
-
-VOID PrintDate (VOID)
-{
-  TCHAR szDateDay[32];
-       TCHAR szDate[32];
-
-  GetDateFormat(LOCALE_USER_DEFAULT, 0, NULL, _T("ddd"), szDateDay, sizeof (szDateDay));
-               
-       GetDateFormat(LOCALE_USER_DEFAULT, DATE_SHORTDATE, NULL, NULL,szDate, sizeof (szDate));
-       ConOutPrintf(_T("%s %s"),szDateDay, szDate);
-}
-
-
-VOID PrintTime (VOID)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];        
-        SYSTEMTIME t;
-        GetLocalTime(&t); 
-  
-       LoadString(CMD_ModuleHandle, STRING_LOCALE_HELP1, szMsg, RC_STRING_MAX_SIZE);
-       ConOutPrintf(_T("%s: %02d%c%02d%c%02d%c%02d\n"), szMsg,  t.wHour, cTimeSeparator,
-                            t.wMinute , cTimeSeparator,
-                            t.wSecond , cDecimalSeparator, t.wMilliseconds );
-}
diff --git a/reactos/subsys/system/cmd/main.c b/reactos/subsys/system/cmd/main.c
deleted file mode 100644 (file)
index 85bb80b..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef _UNICODE
-extern int _main (void);
-#else
-extern int _main (int argc, char *argv[]);
-#endif
-
-/*
- * main function
- */
-#ifdef _UNICODE
-int main(void)
-#else
-int main (int argc, char *argv[])
-#endif
-{
-#ifdef _UNICODE
-  return _main();
-#else
-  return _main(argc, argv);
-#endif
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/memory.c b/reactos/subsys/system/cmd/memory.c
deleted file mode 100644 (file)
index 2a917ff..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- *  MEMORY.C - internal command.
- *
- *
- *  History:
- *
- *    01-Sep-1999 (Eric Kohl)
- *        Started.
- *
- *    28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_MEMORY
-
-
-/*
- * convert
- *
- * insert commas into a number
- */
-static INT
-ConvertDWord (DWORD num, LPTSTR des, INT len, BOOL bSeparator)
-{
-       TCHAR temp[32];
-       INT c = 0;
-       INT n = 0;
-
-       if (num == 0)
-       {
-               des[0] = _T('0');
-               des[1] = _T('\0');
-               n = 1;
-       }
-       else
-       {
-               temp[31] = 0;
-               while (num > 0)
-               {
-                       if (bSeparator && (((c + 1) % (nNumberGroups + 1)) == 0))
-                               temp[30 - c++] = cThousandSeparator;
-                       temp[30 - c++] = (TCHAR)(num % 10) + _T('0');
-                       num /= 10;
-               }
-
-               for (n = 0; n <= c; n++)
-                       des[n] = temp[31 - c + n];
-       }
-
-       return n;
-}
-
-
-INT CommandMemory (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       MEMORYSTATUS ms;
-       TCHAR szMemoryLoad[20];
-       TCHAR szTotalPhys[20];
-       TCHAR szAvailPhys[20];
-       TCHAR szTotalPageFile[20];
-       TCHAR szAvailPageFile[20];
-       TCHAR szTotalVirtual[20];
-       TCHAR szAvailVirtual[20];
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_MEMMORY_HELP1);
-               return 0;
-       }
-
-       ms.dwLength = sizeof(MEMORYSTATUS);
-
-       GlobalMemoryStatus (&ms);
-
-       ConvertDWord (ms.dwMemoryLoad, szMemoryLoad, 20, FALSE);
-       ConvertDWord (ms.dwTotalPhys, szTotalPhys, 20, TRUE);
-       ConvertDWord (ms.dwAvailPhys, szAvailPhys, 20, TRUE);
-       ConvertDWord (ms.dwTotalPageFile, szTotalPageFile, 20, TRUE);
-       ConvertDWord (ms.dwAvailPageFile, szAvailPageFile, 20, TRUE);
-       ConvertDWord (ms.dwTotalVirtual, szTotalVirtual, 20, TRUE);
-       ConvertDWord (ms.dwAvailVirtual, szAvailVirtual, 20, TRUE);
-
-       LoadString(CMD_ModuleHandle, STRING_MEMMORY_HELP2, szMsg, RC_STRING_MAX_SIZE);
-       ConOutPrintf(szMsg,
-                    szMemoryLoad, szTotalPhys, szAvailPhys, szTotalPageFile,
-                    szAvailPageFile, szTotalVirtual, szAvailVirtual);
-
-       return 0;
-}
-
-#endif /* INCLUDE_CMD_MEMORY */
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/misc.c b/reactos/subsys/system/cmd/misc.c
deleted file mode 100644 (file)
index 3884361..0000000
+++ /dev/null
@@ -1,659 +0,0 @@
-/*
- *  MISC.C - misc. functions.
- *
- *
- *  History:
- *
- *    07/12/98 (Rob Lake)
- *        started
- *
- *    07/13/98 (Rob Lake)
- *        moved functions in here
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    18-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Changed split() to accept quoted arguments.
- *        Removed parse_firstarg().
- *
- *    23-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed an ugly bug in split(). In rare cases (last character
- *        of the string is a space) it ignored the NULL character and
- *        tried to add the following to the argument list.
- *
- *    28-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        FileGetString() seems to be working now.
- *
- *    06-Nov-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added PagePrompt() and FilePrompt().
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-/*
- * get a character out-of-band and honor Ctrl-Break characters
- */
-TCHAR cgetchar (VOID)
-{
-       HANDLE hInput = GetStdHandle (STD_INPUT_HANDLE);
-       INPUT_RECORD irBuffer;
-       DWORD  dwRead;
-/*
-       do
-       {
-               ReadConsoleInput (hInput, &irBuffer, 1, &dwRead);
-               if ((irBuffer.EventType == KEY_EVENT) &&
-                       (irBuffer.Event.KeyEvent.bKeyDown == TRUE))
-               {
-                       if ((irBuffer.Event.KeyEvent.dwControlKeyState &
-                                (LEFT_CTRL_PRESSED | RIGHT_CTRL_PRESSED)) &
-                               (irBuffer.Event.KeyEvent.wVirtualKeyCode == 'C'))
-                               bCtrlBreak = TRUE;
-
-                       break;
-               }
-       }
-       while (TRUE);
-*/
-       do
-       {
-               ReadConsoleInput (hInput, &irBuffer, 1, &dwRead);
-               
-               if (irBuffer.EventType == KEY_EVENT)
-               {
-                       if (irBuffer.Event.KeyEvent.dwControlKeyState &
-                                (LEFT_CTRL_PRESSED | RIGHT_CTRL_PRESSED))
-                       {
-                               if (irBuffer.Event.KeyEvent.wVirtualKeyCode == 'C')
-                               {
-//                                     if (irBuffer.Event.KeyEvent.bKeyDown == TRUE)
-//                                     {
-                                               bCtrlBreak = TRUE;
-                                               break;
-//                                     }
-                               }
-                       }
-                       else if ((irBuffer.Event.KeyEvent.wVirtualKeyCode == VK_SHIFT) ||
-              (irBuffer.Event.KeyEvent.wVirtualKeyCode == VK_MENU) ||
-              (irBuffer.Event.KeyEvent.wVirtualKeyCode == VK_CONTROL))
-                       {
-                               ;
-                       }
-                       else
-                       {
-                               break;
-                       }
-               }
-       }
-       while (TRUE);
-
-#ifndef _UNICODE
-       return irBuffer.Event.KeyEvent.uChar.AsciiChar;
-#else
-       return irBuffer.Event.KeyEvent.uChar.UnicodeChar;
-#endif /* _UNICODE */
-}
-
-/*
- * Takes a path in and returns it with the correct case of the letters
- */
-VOID GetPathCase( TCHAR * Path, TCHAR * OutPath)
-{
-       INT i = 0;
-       TCHAR TempPath[MAX_PATH];  
-       WIN32_FIND_DATA FindFileData;
-       HANDLE hFind;
-       _tcscpy(TempPath, _T(""));
-       _tcscpy(OutPath, _T(""));
-
-       
-       for(i = 0; i < _tcslen(Path); i++)
-       {
-               if(Path[i] != _T('\\'))
-               {
-                       _tcsncat(TempPath, &Path[i], 1);
-                       if(i != _tcslen(Path) - 1)
-                               continue;
-               }
-               /* Handle the base part of the path different.
-                  Because if you put it into findfirstfile, it will
-                  return your current folder */
-               if(_tcslen(TempPath) == 2 && TempPath[1] == _T(':'))
-               {
-                       _tcscat(OutPath, TempPath);
-                       _tcscat(OutPath, _T("\\"));
-                       _tcscat(TempPath, _T("\\"));
-               }
-               else
-               {
-                       hFind = FindFirstFile(TempPath,&FindFileData);
-                       if(hFind == INVALID_HANDLE_VALUE)
-                       {
-                               _tcscpy(OutPath, Path);
-                               return;
-                       }
-                       _tcscat(TempPath, _T("\\"));
-                       _tcscat(OutPath, FindFileData.cFileName);
-                       _tcscat(OutPath, _T("\\"));
-                       CloseHandle(hFind);
-               }
-       }
-}
-
-/*
- * Check if Ctrl-Break was pressed during the last calls
- */
-
-BOOL CheckCtrlBreak (INT mode)
-{
-       static BOOL bLeaveAll = FALSE; /* leave all batch files */
-       TCHAR c;
-
-       switch (mode)
-       {
-               case BREAK_OUTOFBATCH:
-                       bLeaveAll = 0;
-                       return FALSE;
-
-               case BREAK_BATCHFILE:
-                       if (bLeaveAll)
-                               return TRUE;
-
-                       if (!bCtrlBreak)
-                               return FALSE;
-
-                       /* we need to be sure the string arrives on the screen! */
-                       do
-                               ConOutPuts (_T("\r\nCtrl-Break pressed.  Cancel batch file? (Yes/No/All) "));
-                       while (!_tcschr (_T("YNA\3"), c = _totupper (cgetchar())) || !c);
-
-                       ConOutPuts (_T("\r\n"));
-
-                       if (c == _T('N'))
-                               return bCtrlBreak = FALSE; /* ignore */
-
-                       /* leave all batch files */
-                       bLeaveAll = ((c == _T('A')) || (c == _T('\3')));
-                       break;
-
-               case BREAK_INPUT:
-                       if (!bCtrlBreak)
-                               return FALSE;
-                       break;
-       }
-
-       /* state processed */
-       bCtrlBreak = FALSE;
-       return TRUE;
-}
-
-/* add new entry for new argument */
-BOOL add_entry (LPINT ac, LPTSTR **arg, LPCTSTR entry)
-{
-       LPTSTR q;
-       LPTSTR *oldarg;
-
-       q = malloc ((_tcslen(entry) + 1) * sizeof (TCHAR));
-       if (NULL == q)
-       {
-               return FALSE;
-       }
-       _tcscpy (q, entry);
-
-       oldarg = *arg;
-       *arg = realloc (oldarg, (*ac + 2) * sizeof (LPTSTR));
-       if (NULL == *arg)
-       {
-               *arg = oldarg;
-               return FALSE;
-       }
-
-       /* save new entry */
-       (*arg)[*ac] = q;
-       (*arg)[++(*ac)] = NULL;
-
-       return TRUE;
-}
-
-static BOOL expand (LPINT ac, LPTSTR **arg, LPCTSTR pattern)
-{
-       HANDLE hFind;
-       WIN32_FIND_DATA FindData;
-       BOOL ok;
-       LPCTSTR pathend;
-       LPTSTR dirpart, fullname;
-
-       pathend = _tcsrchr (pattern, _T('\\'));
-       if (NULL != pathend)
-       {
-               dirpart = malloc((pathend - pattern + 2) * sizeof(TCHAR));
-               if (NULL == dirpart)
-               {
-                       return FALSE;
-               }
-               memcpy(dirpart, pattern, pathend - pattern + 1);
-               dirpart[pathend - pattern + 1] = _T('\0');
-       }
-       else
-       {
-               dirpart = NULL;
-       }
-       hFind = FindFirstFile (pattern, &FindData);
-       if (INVALID_HANDLE_VALUE != hFind)
-       {
-               do
-               {
-                       if (NULL != dirpart)
-                       {
-                               fullname = malloc((_tcslen(dirpart) + _tcslen(FindData.cFileName) + 1) * sizeof(TCHAR));
-                               if (NULL == fullname)
-                               {
-                                       ok = FALSE;
-                               }
-                               else
-                               {
-                                       _tcscat (_tcscpy (fullname, dirpart), FindData.cFileName);
-                                       ok = add_entry(ac, arg, fullname);
-                                       free (fullname);
-                               }
-                       }
-                       else
-                       {
-                               ok = add_entry(ac, arg, FindData.cFileName);
-                       }
-               } while (FindNextFile (hFind, &FindData) && ok);
-               FindClose (hFind);
-       }
-       else
-       {
-               ok = add_entry(ac, arg, pattern);
-       }
-
-       if (NULL != dirpart)
-       {
-               free (dirpart);
-       }
-
-       return ok;
-}
-
-/*
- * split - splits a line up into separate arguments, deliminators
- *         are spaces and slashes ('/').
- */
-
-LPTSTR *split (LPTSTR s, LPINT args, BOOL expand_wildcards)
-{
-       LPTSTR *arg;
-       LPTSTR start;
-       LPTSTR q;
-       INT  ac;
-       INT  len;
-       BOOL bQuoted = FALSE;
-
-       arg = malloc (sizeof (LPTSTR));
-       if (!arg)
-               return NULL;
-       *arg = NULL;
-
-       ac = 0;
-       while (*s)
-       {
-               /* skip leading spaces */
-               while (*s && (_istspace (*s) || _istcntrl (*s)))
-                       ++s;
-
-               /* if quote (") then set bQuoted */
-               if (*s == _T('\"'))
-               {
-                       ++s;
-                       bQuoted = TRUE;
-               }
-
-               start = s;
-
-               /* the first character can be '/' */
-               if (*s == _T('/'))
-                       ++s;
-
-               /* skip to next word delimiter or start of next option */
-               if (bQuoted)
-               {
-                       while (_istprint (*s) && (*s != _T('\"')) && (*s != _T('/')))
-                               ++s;
-               }
-               else
-               {
-                       while (_istprint (*s) && !_istspace (*s) && (*s != _T('/')))
-                               ++s;
-               }
-
-               /* a word was found */
-               if (s != start)
-               {
-                       q = malloc (((len = s - start) + 1) * sizeof (TCHAR));
-                       if (!q)
-                       {
-                               return NULL;
-                       }
-                       memcpy (q, start, len * sizeof (TCHAR));
-                       q[len] = _T('\0');
-                       if (expand_wildcards && _T('/') != *start &&
-                           (NULL != _tcschr(q, _T('*')) || NULL != _tcschr(q, _T('?'))))
-                       {
-                               if (! expand(&ac, &arg, q))
-                               {
-                                       free (q);
-                                       freep (arg);
-                                       return NULL;
-                               }
-                       }
-                       else
-                       {
-                               if (! add_entry(&ac, &arg, q))
-                               {
-                                       free (q);
-                                       freep (arg);
-                                       return NULL;
-                               }
-                       }
-                       free (q);
-               }
-
-               /* adjust string pointer if quoted (") */
-               if (bQuoted)
-               {
-      /* Check to make sure if there is no ending "
-       * we dont run over the null char */
-      if(*s == _T('\0'))
-      {
-        break;
-      }
-                       ++s;
-                       bQuoted = FALSE;
-               }
-       }
-
-       *args = ac;
-
-       return arg;
-}
-
-
-/*
- * freep -- frees memory used for a call to split
- *
- */
-VOID freep (LPTSTR *p)
-{
-       LPTSTR *q;
-
-       if (!p)
-               return;
-
-       q = p;
-       while (*q)
-               free(*q++);
-
-       free(p);
-}
-
-
-LPTSTR _stpcpy (LPTSTR dest, LPCTSTR src)
-{
-       _tcscpy (dest, src);
-       return (dest + _tcslen (src));
-}
-
-
-
-/*
- * Checks if a path is valid (accessible)
- */
-
-BOOL IsValidPathName (LPCTSTR pszPath)
-{
-       TCHAR szOldPath[MAX_PATH];
-       BOOL  bResult;
-
-       GetCurrentDirectory (MAX_PATH, szOldPath);
-       bResult = SetCurrentDirectory (pszPath);
-
-       SetCurrentDirectory (szOldPath);
-
-       return bResult;
-}
-
-
-/*
- * Checks if a file exists (accessible)
- */
-
-BOOL IsExistingFile (LPCTSTR pszPath)
-{
-       DWORD attr = GetFileAttributes (pszPath);
-       return (attr != 0xFFFFFFFF && (! (attr & FILE_ATTRIBUTE_DIRECTORY)) );
-}
-
-
-BOOL IsExistingDirectory (LPCTSTR pszPath)
-{
-       DWORD attr = GetFileAttributes (pszPath);
-       return (attr != 0xFFFFFFFF && (attr & FILE_ATTRIBUTE_DIRECTORY) );
-}
-
-
-BOOL FileGetString (HANDLE hFile, LPTSTR lpBuffer, INT nBufferLength)
-{
-       LPSTR lpString;
-       CHAR ch;
-       DWORD  dwRead;
-       INT len;
-#ifdef _UNICODE
-       lpString = malloc(nBufferLength);
-#else
-       lpString = lpBuffer;
-#endif
-       len = 0;
-       while ((--nBufferLength >  0) &&
-                  ReadFile(hFile, &ch, 1, &dwRead, NULL) && dwRead)
-       {
-        lpString[len++] = ch;
-        if ((ch == _T('\n')) || (ch == _T('\r')))
-               {
-                       /* break at new line*/
-                       break;
-               }
-       }
-
-       if (!dwRead && !len)
-               return FALSE;
-
-       lpString[len++] = _T('\0');
-#ifdef _UNICODE
-       MultiByteToWideChar(CP_ACP, 0, lpString, len, lpBuffer, len);
-       free(lpString);
-#endif
-       return TRUE;
-}
-
-INT PagePrompt (VOID)
-{
-       INPUT_RECORD ir;
-
-       ConOutResPuts(STRING_MISC_HELP1);
-
-       RemoveBreakHandler ();
-       ConInDisable ();
-
-       do
-       {
-               ConInKey (&ir);
-       }
-       while ((ir.Event.KeyEvent.wVirtualKeyCode == VK_SHIFT) ||
-              (ir.Event.KeyEvent.wVirtualKeyCode == VK_MENU) ||
-              (ir.Event.KeyEvent.wVirtualKeyCode == VK_CONTROL));
-
-       AddBreakHandler ();
-       ConInEnable ();
-
-       if ((ir.Event.KeyEvent.wVirtualKeyCode == VK_ESCAPE) ||
-           ((ir.Event.KeyEvent.wVirtualKeyCode == _T('C')) &&
-            (ir.Event.KeyEvent.dwControlKeyState & (LEFT_CTRL_PRESSED | RIGHT_CTRL_PRESSED))))
-       {
-               bCtrlBreak = TRUE;
-               return PROMPT_BREAK;
-       }
-
-       return PROMPT_YES;
-}
-
-
-INT FilePromptYN (LPTSTR szFormat, ...)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       TCHAR szOut[512];
-       va_list arg_ptr;
-//     TCHAR cKey = 0;
-//     LPTSTR szKeys = _T("yna");
-
-       TCHAR szIn[10];
-       LPTSTR p;
-
-       va_start (arg_ptr, szFormat);
-       _vstprintf (szOut, szFormat, arg_ptr);
-       va_end (arg_ptr);
-
-       ConOutPrintf (szFormat);
-
-       /* preliminary fix */
-       ConInString (szIn, 10);
-       ConOutPrintf (_T("\n"));
-
-       _tcsupr (szIn);
-       for (p = szIn; _istspace (*p); p++)
-               ;
-
-       LoadString(CMD_ModuleHandle, STRING_CHOICE_OPTION, szMsg, RC_STRING_MAX_SIZE);
-
-       if (_tcsncmp(p, &szMsg[0], 1) == 0)
-               return PROMPT_YES;
-       else if (_tcsncmp(p, &szMsg[1], 1) == 0)
-               return PROMPT_NO;
-#if 0
-       else if (*p == _T('\03'))
-               return PROMPT_BREAK;
-#endif
-
-       return PROMPT_NO;
-
-
-       /* unfinished sollution */
-#if 0
-       RemoveBreakHandler ();
-       ConInDisable ();
-
-       do
-       {
-               ConInKey (&ir);
-               cKey = _totlower (ir.Event.KeyEvent.uChar.AsciiChar);
-               if (_tcschr (szKeys, cKey[0]) == NULL)
-                       cKey = 0;
-
-
-       }
-       while ((ir.Event.KeyEvent.wVirtualKeyCode == VK_SHIFT) ||
-              (ir.Event.KeyEvent.wVirtualKeyCode == VK_MENU) ||
-              (ir.Event.KeyEvent.wVirtualKeyCode == VK_CONTROL));
-
-       AddBreakHandler ();
-       ConInEnable ();
-
-       if ((ir.Event.KeyEvent.wVirtualKeyCode == VK_ESCAPE) ||
-           ((ir.Event.KeyEvent.wVirtualKeyCode == 'C') &&
-            (ir.Event.KeyEvent.dwControlKeyState & (LEFT_CTRL_PRESSED | RIGHT_CTRL_PRESSED))))
-               return PROMPT_BREAK;
-
-       return PROMPT_YES;
-#endif
-}
-
-
-INT FilePromptYNA (LPTSTR szFormat, ...)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       TCHAR szOut[512];
-       va_list arg_ptr;
-//     TCHAR cKey = 0;
-//     LPTSTR szKeys = _T("yna");
-
-       TCHAR szIn[10];
-       LPTSTR p;
-
-       va_start (arg_ptr, szFormat);
-       _vstprintf (szOut, szFormat, arg_ptr);
-       va_end (arg_ptr);
-
-       ConOutPrintf (szFormat);
-
-       /* preliminary fix */
-       ConInString (szIn, 10);
-       ConOutPrintf (_T("\n"));
-
-       _tcsupr (szIn);
-       for (p = szIn; _istspace (*p); p++)
-               ;
-
-       LoadString( CMD_ModuleHandle, STRING_COPY_OPTION, szMsg, RC_STRING_MAX_SIZE);
-
-       if (_tcsncmp(p, &szMsg[0], 1) == 0)
-               return PROMPT_YES;
-       else if (_tcsncmp(p, &szMsg[1], 1) == 0)
-               return PROMPT_NO;
-       else if (_tcsncmp(p, &szMsg[2], 1) == 0)
-               return PROMPT_ALL;
-
-#if 0
-       else if (*p == _T('\03'))
-               return PROMPT_BREAK;
-#endif
-
-       return PROMPT_NO;
-
-
-/* unfinished sollution */
-#if 0
-       RemoveBreakHandler ();
-       ConInDisable ();
-
-       do
-       {
-               ConInKey (&ir);
-               cKey = _totlower (ir.Event.KeyEvent.uChar.AsciiChar);
-               if (_tcschr (szKeys, cKey[0]) == NULL)
-                       cKey = 0;
-       }
-       while ((ir.Event.KeyEvent.wVirtualKeyCode == VK_SHIFT) ||
-              (ir.Event.KeyEvent.wVirtualKeyCode == VK_MENU) ||
-              (ir.Event.KeyEvent.wVirtualKeyCode == VK_CONTROL));
-
-       AddBreakHandler ();
-       ConInEnable ();
-
-       if ((ir.Event.KeyEvent.wVirtualKeyCode == VK_ESCAPE) ||
-           ((ir.Event.KeyEvent.wVirtualKeyCode == _T('C')) &&
-            (ir.Event.KeyEvent.dwControlKeyState & (LEFT_CTRL_PRESSED | RIGHT_CTRL_PRESSED))))
-               return PROMPT_BREAK;
-
-       return PROMPT_YES;
-#endif
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/move.c b/reactos/subsys/system/cmd/move.c
deleted file mode 100644 (file)
index fe3e942..0000000
+++ /dev/null
@@ -1,556 +0,0 @@
-/*
-*  MOVE.C - move internal command.
-*
-*
-*  History:
-*
-*    14-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
-*        Started.
-*
-*    18-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
-*        Unicode safe!
-*        Preliminary version!!!
-*
-*    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
-*        Redirection safe!
-*
-*    27-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
-*        Added help text ("/?").
-*        Added more error checks.
-*
-*    03-Feb-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
-*        Added "/N" option.
-*
-*    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
-*        Remove all hardcode string to En.rc
-*
-*    24-Jun-2005 (Brandon Turner) <turnerb7@msu.edu>)
-*        Fixed bug to allow MS style wildcards + code clean up
-*        added /y and /-y
-*/
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_MOVE
-
-enum
-{
-       MOVE_NOTHING  = 0x001,   /* /N  */
-       MOVE_OVER_YES = 0x002,   /* /Y  */
-       MOVE_OVER_NO  = 0x004,   /* /-Y */
-};
-
-enum
-{      /* Move status flags */
-       MOVE_SOURCE_IS_DIR = 0x001,
-       MOVE_SOURCE_IS_FILE = 0x002,
-       MOVE_DEST_IS_DIR = 0x004,
-       MOVE_DEST_IS_FILE = 0x008,
-       MOVE_SOURCE_HAS_WILD = 0x010, /*  source has wildcard */
-       MOVE_SRC_CURRENT_IS_DIR = 0x020, /* source is file but at the current round we found a directory */
-       MOVE_DEST_EXISTS = 0x040,
-       MOVE_PATHS_ON_DIF_VOL = 0x080 /* source and destination paths are on different volume */
-};
-
-static INT MoveOverwrite (LPTSTR fn)
-{
-       /*ask the user if they want to override*/
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       INT res;
-       LoadString(CMD_ModuleHandle, STRING_MOVE_HELP1, szMsg, RC_STRING_MAX_SIZE);
-       ConOutPrintf(szMsg,fn);
-       res = FilePromptYNA (_T(""));
-       return res;
-}
-
-void GetDirectory (LPTSTR wholepath, LPTSTR directory, BOOL CheckExisting)
-{
-       /* returns only directory part of path with backslash */
-       /* TODO: make code unc aware */
-       /* Is there a better alternative to this? */
-       LPTSTR last;
-       if (CheckExisting && IsExistingDirectory(wholepath))
-       {
-               _tcscpy(directory, wholepath);
-       }
-       else if ((last = _tcsrchr(wholepath,_T('\\'))) != NULL)
-       {
-               _tcsncpy(directory, wholepath, last - wholepath + 1);
-               directory[last - wholepath + 1] = 0;
-       }
-       else
-       {
-               GetRootPath(wholepath,directory, MAX_PATH);
-       }
-}
-
-
-INT cmd_move (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       LPTSTR *arg;
-       INT argc, i, nFiles;
-       TCHAR szDestPath[MAX_PATH];
-       TCHAR szFullDestPath[MAX_PATH];
-       TCHAR szSrcDirPath[MAX_PATH];
-       TCHAR szSrcPath[MAX_PATH];
-       TCHAR szFullSrcPath[MAX_PATH];
-       DWORD dwFlags = 0;
-       INT nOverwrite = 0;
-       WIN32_FIND_DATA findBuffer;
-       HANDLE hFile;
-       
-       /* used only when source and destination  directories are on different volume*/
-       HANDLE hDestFile;
-       WIN32_FIND_DATA findDestBuffer;
-       TCHAR szMoveDest[MAX_PATH];
-       TCHAR szMoveSrc[MAX_PATH];
-       LPTSTR pszDestDirPointer;
-       LPTSTR pszSrcDirPointer;
-       INT nDirLevel = 0;
-       
-       LPTSTR pszFile;
-       BOOL OnlyOneFile;
-       BOOL FoundFile;
-       BOOL MoveStatus;
-       DWORD dwMoveFlags = 0;
-       DWORD dwMoveStatusFlags = 0;
-
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-#if 0
-               ConOutPuts (_T("Moves files and renames files and directories.\n\n"
-                       "To move one or more files:\n"
-                       "MOVE [/N][/Y|/-Y][drive:][path]filename1[,...] destination\n"
-                       "\n"
-                       "To rename a directory:\n"
-                       "MOVE [/N][/Y|/-Y][drive:][path]dirname1 dirname2\n"
-                       "\n"
-                       "  [drive:][path]filename1  Specifies the location and name of the file\n"
-                       "                           or files you want to move.\n"
-                       "  /N                       Nothing. Don everthing but move files or direcories.\n"
-                       "  /Y\n"
-                       "  /-Y\n"
-                       "..."));
-#else
-               ConOutResPaging(TRUE,STRING_MOVE_HELP2);
-#endif
-               return 0;
-       }
-
-       nErrorLevel = 0;
-       arg = split (param, &argc, FALSE);
-       nFiles = argc;
-
-       /* read options */
-       for (i = 0; i < argc; i++)
-       {
-               if (*arg[i] == _T('/'))
-               {
-                       if (_tcslen(arg[i]) >= 2)
-                       {
-                               switch (_totupper(arg[i][1]))
-                               {
-                               case _T('N'):
-                                       dwFlags |= MOVE_NOTHING;
-                                       break;
-                               
-                               case _T('Y'):
-                                       dwFlags |= MOVE_OVER_YES;
-                                       break;
-                               
-                               case _T('-'):
-                                       dwFlags |= MOVE_OVER_NO;
-                                       break;
-                               }
-                       }
-                       nFiles--;
-               }
-       }
-       
-       if (nFiles < 2)
-       {
-               /* there must be at least two pathspecs */
-               error_req_param_missing ();
-               return 1;
-       }
-       
-       /* check for wildcards in source and destination */
-       if (_tcschr (arg[argc - 1], _T('*')) != NULL || _tcschr (arg[argc - 1], _T('?')) != NULL)
-       {
-               /* '*'/'?' in dest, this doesnt happen.  give folder name instead*/
-               error_invalid_parameter_format(arg[argc - 1]);
-               return 1;
-       }
-       if (_tcschr (arg[argc - 2], _T('*')) != NULL || _tcschr (arg[argc - 2], _T('?')) != NULL)
-       {
-               dwMoveStatusFlags |= MOVE_SOURCE_HAS_WILD;
-       }
-       
-       
-       /* get destination */
-       GetFullPathName (arg[argc - 1], MAX_PATH, szDestPath, NULL);
-#ifdef _DEBUG
-       DebugPrintf (_T("Destination: %s\n"), szDestPath);
-#endif
-       
-       /* get source folder */
-       GetDirectory(arg[argc - 2], szSrcDirPath, 1);
-       GetFullPathName(szSrcDirPath, MAX_PATH, szSrcPath, &pszFile);
-       _tcscpy(szSrcDirPath,szSrcPath);
-       /* we need following check to see if source happens to be directly given directory
-       and if it is then rip off last directory part so that there won't be any clashes with codes after this point */
-       GetFullPathName(arg[argc - 2], MAX_PATH, szSrcPath, &pszFile);
-       if (_tcscmp(szSrcDirPath,szSrcPath) == 0)
-               szSrcDirPath[pszFile - szSrcPath] = _T('\0');
-#ifdef _DEBUG
-       DebugPrintf (_T("Source Folder: %s\n"), szSrcDirPath);
-#endif
-       
-       hFile = FindFirstFile (arg[argc - 2], &findBuffer);
-       if (hFile == INVALID_HANDLE_VALUE)
-       {
-               ErrorMessage (GetLastError (), arg[argc - 2]);
-               freep (arg);
-               return 1;
-               
-       }
-
-       /* check for special cases "." and ".." and if found skip them */
-       FoundFile = TRUE;
-       while(FoundFile &&
-                 (_tcscmp(findBuffer.cFileName,_T(".")) == 0 ||
-                  _tcscmp(findBuffer.cFileName,_T("..")) == 0))
-               FoundFile = FindNextFile (hFile, &findBuffer);
-       
-       if (!FoundFile)
-       {
-               /* what? we don't have anything to move? */
-               error_file_not_found();
-               FindClose(hFile);
-               freep(arg);
-               return 1;
-       }
-       
-       OnlyOneFile = TRUE;
-       _tcscpy(szSrcPath,szSrcDirPath);
-       /*check to see if there is an ending slash, if not add one*/
-       if(szSrcPath[_tcslen(szSrcPath) -  1] != _T('\\'))
-               _tcscat (szSrcPath, _T("\\"));
-       _tcscat(szSrcPath,findBuffer.cFileName);
-#ifdef _DEBUG
-       DebugPrintf (_T("Source Path: %s\n"), szSrcPath);
-#endif
-       /* check if there can be found files as files have first priority */
-       if (IsExistingFile(szSrcPath)) dwMoveStatusFlags |= MOVE_SOURCE_IS_FILE;
-       else dwMoveStatusFlags |= MOVE_SOURCE_IS_DIR;
-       while(OnlyOneFile && FindNextFile(hFile,&findBuffer))
-       {
-               _tcscpy(szSrcPath,szSrcDirPath);
-               if(szSrcPath[_tcslen(szSrcPath) -  1] != _T('\\'))
-                       _tcscat (szSrcPath, _T("\\"));
-               _tcscat(szSrcPath,findBuffer.cFileName);
-               if (IsExistingFile(szSrcPath))
-               {
-                       ConOutPrintf(_T(""));
-                       if (dwMoveStatusFlags & MOVE_SOURCE_IS_FILE) OnlyOneFile = FALSE;
-                       else
-                       {       /* this has been done this way so that we don't disturb other settings if they have been set before this */
-                               dwMoveStatusFlags |= MOVE_SOURCE_IS_FILE;
-                               dwMoveStatusFlags &= ~MOVE_SOURCE_IS_DIR;
-                       }
-               }
-       }
-       FindClose(hFile);
-
-#ifdef _DEBUG
-       DebugPrintf(_T("Do we have only one file: %s\n"), OnlyOneFile ? _T("TRUE") : _T("FALSE"));
-#endif
-       
-       /* we have to start again to be sure we don't miss any files or folders*/
-       hFile = FindFirstFile (arg[argc - 2], &findBuffer);
-       if (hFile == INVALID_HANDLE_VALUE)
-       {
-               ErrorMessage (GetLastError (), arg[argc - 2]);
-               freep (arg);
-               return 1;
-               
-       }
-       
-       /* check for special cases "." and ".." and if found skip them */
-       FoundFile = TRUE;
-       while(FoundFile &&
-                 (_tcscmp(findBuffer.cFileName,_T(".")) == 0 ||
-                  _tcscmp(findBuffer.cFileName,_T("..")) == 0))
-               FoundFile = FindNextFile (hFile, &findBuffer);
-       
-       if (!FoundFile)
-       {
-               /* huh? somebody removed files and/or folders which were there */
-               error_file_not_found();
-               FindClose(hFile);
-               freep(arg);
-               return 1;
-       }
-       
-       /* check if source and destination paths are on different volumes */
-       if (szSrcPath[0] != szDestPath[0])
-               dwMoveStatusFlags |= MOVE_PATHS_ON_DIF_VOL;
-       
-       /* move it */
-       do
-       {
-#ifdef _DEBUG
-               DebugPrintf (_T("Found file/directory: %s\n"), findBuffer.cFileName);
-#endif
-               nOverwrite = 1;
-               dwMoveFlags = 0;
-               dwMoveStatusFlags &= ~MOVE_DEST_IS_FILE &
-                                                       ~MOVE_DEST_IS_DIR &
-                                                       ~MOVE_SRC_CURRENT_IS_DIR &
-                                                       ~MOVE_DEST_EXISTS;
-               _tcscpy(szFullSrcPath,szSrcDirPath);
-               if(szFullSrcPath[_tcslen(szFullSrcPath) -  1] != _T('\\'))
-                       _tcscat (szFullSrcPath, _T("\\"));
-               _tcscat(szFullSrcPath,findBuffer.cFileName);
-               _tcscpy(szSrcPath, szFullSrcPath);
-               
-               if (IsExistingDirectory(szSrcPath))
-               {
-                       /* source is directory */
-                       
-                       if (dwMoveStatusFlags & MOVE_SOURCE_IS_FILE)
-                       {
-                               dwMoveStatusFlags |= MOVE_SRC_CURRENT_IS_DIR; /* source is file but at the current round we found a directory */
-                               continue;
-                       }
-#ifdef _DEBUG
-                       DebugPrintf (_T("Source is dir: %s\n"), szSrcPath);
-#endif
-                       dwMoveFlags = MOVEFILE_REPLACE_EXISTING | MOVEFILE_WRITE_THROUGH | MOVEFILE_COPY_ALLOWED;
-               }
-               
-               /* if source is file we don't need to do anything special */
-               
-               if (IsExistingDirectory(szDestPath))
-               {
-                       /* destination is existing directory */
-#ifdef _DEBUG
-                       DebugPrintf (_T("Destination is directory: %s\n"), szDestPath);
-#endif
-                       
-                       dwMoveStatusFlags |= MOVE_DEST_IS_DIR;
-                       
-                       /*build the dest string(accounts for *)*/
-                       _tcscpy (szFullDestPath, szDestPath);
-                       /*check to see if there is an ending slash, if not add one*/
-                       if(szFullDestPath[_tcslen(szFullDestPath) -  1] != _T('\\'))
-                               _tcscat (szFullDestPath, _T("\\"));
-                       _tcscat (szFullDestPath, findBuffer.cFileName);
-                       
-                       if (IsExistingFile(szFullDestPath) || IsExistingDirectory(szFullDestPath))
-                               dwMoveStatusFlags |= MOVE_DEST_EXISTS;
-                       
-                       dwMoveFlags |= MOVEFILE_REPLACE_EXISTING | MOVEFILE_WRITE_THROUGH | MOVEFILE_COPY_ALLOWED;
-                       
-               }
-               if (IsExistingFile(szDestPath))
-               {
-                       /* destination is a file */
-#ifdef _DEBUG
-                       DebugPrintf (_T("Destination is file: %s\n"), szDestPath);
-#endif
-                       
-                       dwMoveStatusFlags |= MOVE_DEST_IS_FILE | MOVE_DEST_EXISTS;
-                       _tcscpy (szFullDestPath, szDestPath);
-                       
-                       dwMoveFlags |= MOVEFILE_REPLACE_EXISTING | MOVEFILE_WRITE_THROUGH | MOVEFILE_COPY_ALLOWED;
-                       
-               }
-               
-#ifdef _DEBUG
-               DebugPrintf(_T("Move Status Flags: 0x%X\n"),dwMoveStatusFlags);
-#endif
-               
-               if (dwMoveStatusFlags & MOVE_SOURCE_IS_DIR &&
-                       dwMoveStatusFlags & MOVE_DEST_IS_DIR &&
-                       dwMoveStatusFlags & MOVE_SOURCE_HAS_WILD)
-               {
-                       /* We are not allowed to have existing source and destination dir when there is wildcard in source */
-                       error_syntax(NULL);
-                       FindClose(hFile);
-                       freep(arg);
-                       return 1;
-               }
-                       
-               if (!(dwMoveStatusFlags & (MOVE_DEST_IS_FILE | MOVE_DEST_IS_DIR)))
-               {
-                       /* destination doesn't exist */
-                       _tcscpy (szFullDestPath, szDestPath);
-                       if (dwMoveStatusFlags & MOVE_SOURCE_IS_FILE) dwMoveStatusFlags |= MOVE_DEST_IS_FILE;
-                       if (dwMoveStatusFlags & MOVE_SOURCE_IS_DIR) dwMoveStatusFlags |= MOVE_DEST_IS_DIR;
-                       
-                       dwMoveFlags |= MOVEFILE_REPLACE_EXISTING | MOVEFILE_WRITE_THROUGH | MOVEFILE_COPY_ALLOWED;
-               }
-               
-               if (dwMoveStatusFlags & MOVE_SOURCE_IS_FILE &&
-                       dwMoveStatusFlags & MOVE_DEST_IS_FILE &&
-                       !OnlyOneFile)
-               {
-                       /*source has many files but there is only one destination file*/
-                       error_invalid_parameter_format(arg[argc - 1]);
-                       FindClose(hFile);
-                       freep (arg);
-                       return 1;
-               }
-               
-               /*checks to make sure user wanted/wants the override*/
-               if((dwFlags & MOVE_OVER_NO) &&
-                  (dwMoveStatusFlags & MOVE_DEST_EXISTS))
-                       continue;
-               if(!(dwFlags & MOVE_OVER_YES) &&
-                   (dwMoveStatusFlags & MOVE_DEST_EXISTS))
-                       nOverwrite = MoveOverwrite (szFullDestPath);
-               if (nOverwrite == PROMPT_NO || nOverwrite == PROMPT_BREAK)
-                       continue;
-               if (nOverwrite == PROMPT_ALL)
-                       dwFlags |= MOVE_OVER_YES;
-               
-                       
-               ConOutPrintf (_T("%s => %s "), szSrcPath, szFullDestPath);
-               
-               /* are we really supposed to do something */
-               if (dwFlags & MOVE_NOTHING)
-                       continue;
-               
-               /*move the file*/
-               if (!(dwMoveStatusFlags & MOVE_SOURCE_IS_DIR &&
-                       dwMoveStatusFlags & MOVE_PATHS_ON_DIF_VOL))
-                       /* we aren't moving source folder to different drive */
-                       MoveStatus = MoveFileEx (szSrcPath, szFullDestPath, dwMoveFlags);
-               else
-               {       /* we are moving source folder to different drive */
-                       _tcscpy(szMoveDest, szFullDestPath);
-                       _tcscpy(szMoveSrc, szSrcPath);
-                       DeleteFile(szMoveDest);
-                       MoveStatus = CreateDirectory(szMoveDest, NULL); /* we use default security settings */
-                       if (MoveStatus)
-                       {
-                               _tcscat(szMoveDest,_T("\\"));
-                               _tcscat(szMoveSrc,_T("\\"));
-                               nDirLevel = 0;
-                               pszDestDirPointer = szMoveDest + _tcslen(szMoveDest);
-                               pszSrcDirPointer = szMoveSrc + _tcslen(szMoveSrc);
-                               _tcscpy(pszSrcDirPointer,_T("*.*"));
-                               hDestFile = FindFirstFile(szMoveSrc, &findDestBuffer);
-                               if (hDestFile == INVALID_HANDLE_VALUE)
-                                       MoveStatus = FALSE;
-                               else
-                               {
-                                       BOOL FirstTime = TRUE;
-                                       FoundFile = TRUE;
-                                       MoveStatus = FALSE;
-                                       while(FoundFile)
-                                       {
-                                               if (FirstTime)
-                                                       FirstTime = FALSE;
-                                               else
-                                                       FoundFile = FindNextFile (hDestFile, &findDestBuffer);
-                                               
-                                               if (!FoundFile)
-                                               {       /* Nothing to do in this folder so we stop working on it */
-                                                       FindClose(hDestFile);
-                                                       (pszSrcDirPointer)--;
-                                                       (pszDestDirPointer)--;
-                                                       _tcscpy(pszSrcDirPointer,_T(""));
-                                                       _tcscpy(pszDestDirPointer,_T(""));
-                                                       if (nDirLevel > 0)
-                                                       {
-                                                               TCHAR szTempPath[MAX_PATH];
-                                                               INT nDiff;
-
-                                                               FoundFile = TRUE; /* we need to continue our seek for files */
-                                                               nDirLevel--;
-                                                               RemoveDirectory(szMoveSrc);
-                                                               GetDirectory(szMoveSrc,szTempPath,0);
-                                                               nDiff = _tcslen(szMoveSrc) - _tcslen(szTempPath);
-                                                               pszSrcDirPointer = pszSrcDirPointer - nDiff;
-                                                               _tcscpy(pszSrcDirPointer,_T(""));
-                                                               GetDirectory(szMoveDest,szTempPath,0);
-                                                               nDiff = _tcslen(szMoveDest) - _tcslen(szTempPath);
-                                                               pszDestDirPointer = pszDestDirPointer - nDiff;
-                                                               _tcscpy(pszDestDirPointer,_T(""));
-                                                               if(szMoveSrc[_tcslen(szMoveSrc) -  1] != _T('\\'))
-                                                                       _tcscat (szMoveSrc, _T("\\"));
-                                                               if(szMoveDest[_tcslen(szMoveDest) -  1] != _T('\\'))
-                                                                       _tcscat (szMoveDest, _T("\\"));
-                                                               pszDestDirPointer = szMoveDest + _tcslen(szMoveDest);
-                                                               pszSrcDirPointer = szMoveSrc + _tcslen(szMoveSrc);
-                                                               _tcscpy(pszSrcDirPointer,_T("*.*"));
-                                                               hDestFile = FindFirstFile(szMoveSrc, &findDestBuffer);
-                                                               if (hDestFile == INVALID_HANDLE_VALUE)
-                                                                       continue;
-                                                               FirstTime = TRUE;
-                                                       }
-                                                       else
-                                                       {
-                                                               MoveStatus = TRUE; /* we moved everything so lets tell user about it */
-                                                               RemoveDirectory(szMoveSrc);
-                                                       }
-                                                       continue;
-                                               }
-                                               
-                                               /* if we find "." or ".." we'll skip them */
-                                               if (_tcscmp(findDestBuffer.cFileName,_T(".")) == 0 ||
-                                                       _tcscmp(findDestBuffer.cFileName,_T("..")) == 0)
-                                                       continue;
-                                       
-                                               _tcscpy(pszSrcDirPointer, findDestBuffer.cFileName);
-                                               _tcscpy(pszDestDirPointer, findDestBuffer.cFileName);
-                                               if (IsExistingFile(szMoveSrc))
-                                               {
-                                                       FoundFile = CopyFile(szMoveSrc, szMoveDest, FALSE);
-                                                       if (!FoundFile) continue;
-                                                       DeleteFile(szMoveSrc);
-                                               }
-                                               else
-                                               {
-                                                       FindClose(hDestFile);
-                                                       CreateDirectory(szMoveDest, NULL);
-                                                       _tcscat(szMoveDest,_T("\\"));
-                                                       _tcscat(szMoveSrc,_T("\\"));
-                                                       nDirLevel++;
-                                                       pszDestDirPointer = szMoveDest + _tcslen(szMoveDest);
-                                                       pszSrcDirPointer = szMoveSrc + _tcslen(szMoveSrc);
-                                                       _tcscpy(pszSrcDirPointer,_T("*.*"));
-                                                       hDestFile = FindFirstFile(szMoveSrc, &findDestBuffer);
-                                                       if (hDestFile == INVALID_HANDLE_VALUE)
-                                                       {
-                                                               FoundFile = FALSE;
-                                                               continue;
-                                                       }
-                                                       FirstTime = TRUE;
-                                               }
-                                       }
-                               }
-                       }
-               }
-               if (MoveStatus)
-                       LoadString(CMD_ModuleHandle, STRING_MOVE_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-               else
-                       LoadString(CMD_ModuleHandle, STRING_MOVE_ERROR2, szMsg, RC_STRING_MAX_SIZE);
-               
-               ConOutPrintf(szMsg);
-       }
-       while ((!OnlyOneFile || dwMoveStatusFlags & MOVE_SRC_CURRENT_IS_DIR ) &&
-                       !(dwMoveStatusFlags & MOVE_SOURCE_IS_DIR) &&
-                       FindNextFile (hFile, &findBuffer));
-       FindClose (hFile);
-       
-       freep (arg);
-       return 0;
-}
-
-#endif /* INCLUDE_CMD_MOVE */
diff --git a/reactos/subsys/system/cmd/msgbox.c b/reactos/subsys/system/cmd/msgbox.c
deleted file mode 100644 (file)
index f512bb7..0000000
+++ /dev/null
@@ -1,158 +0,0 @@
-/*
- * MSGBOX.C - msgbox internal command.
- *
- * clone from 4nt msgbox command
- *
- * 25 Aug 1999
- *     started - Paolo Pantaleo <paolopan@freemail.it>
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_MSGBOX
-
-
-#define U_TYPE_INIT 0
-
-//undefine it to allow to omit arguments
-//that will be replaced by default ones
-#define _SYNTAX_CHECK
-
-
-INT CommandMsgbox (LPTSTR cmd, LPTSTR param)
-{
-
-       //used to parse command line
-       LPTSTR tmp;
-
-       //used to find window title (used as messagebox title)
-       //and to find window handle to pass to MessageBox
-       HWND hWnd;
-       TCHAR buff[128];
-
-       //these are MessabeBox() parameters
-       LPTSTR title, prompt = "";
-       UINT uType = U_TYPE_INIT;
-
-       /* set default title to window title */
-       GetConsoleTitle(buff, 128);
-       title = buff;
-
-       if (_tcsncmp (param, _T("/?"), 2) == 0)
-       {
-               ConOutResPaging(TRUE,STRING_MSGBOX_HELP);
-               return 0;
-       }
-
-       //yes here things are quite massed up :)
-
-       //skip spaces
-       while(_istspace(*param))
-               param++;
-
-       //search for type of messagebox (ok, okcancel, ...)
-       if (_tcsnicmp(param, _T("ok "), 3) == 0)
-       {
-               uType |= MB_ICONEXCLAMATION | MB_OK;
-               param += 3;
-       }
-       else if (_tcsnicmp(param, _T("okcancel "), 9) == 0)
-       {
-               uType |= MB_ICONQUESTION | MB_OKCANCEL;
-               param += 9;
-       }
-       else if (_tcsnicmp(param, _T("yesno "), 6) == 0)
-       {
-               uType |= MB_ICONQUESTION | MB_YESNO;
-               param += 6;
-       }
-       else if (_tcsnicmp(param, _T("yesnocancel "), 12) == 0)
-       {
-               uType |= MB_ICONQUESTION | MB_YESNOCANCEL;
-               param += 12;
-       }
-       else
-       {
-#ifdef _SYNTAX_CHECK
-               error_req_param_missing ();
-               return 1;
-#else
-               uType |= MB_ICONEXCLAMATION | MB_OK;
-#endif
-       }
-
-
-       //skip spaces
-       while(_istspace(*param))
-               param++;
-
-#ifdef _SYNTAX_CHECK
-       //if reached end of string
-       //it is an error becuase we do not yet have prompt
-       if (*param == 0)
-       {
-               error_req_param_missing ();
-               return 1;
-       }
-#endif
-
-       //search for "title"
-       tmp = param;
-
-       if (*param == '"')
-       {
-               tmp = _tcschr(param + 1, '"');
-               if (tmp)
-               {
-                       *tmp = 0;
-                       title = param + 1;
-                       tmp++;
-                       param = tmp;
-               }
-       }
-
-       //skip spaces
-       while(_istspace(*param))
-               param++;
-
-#ifdef _SYNTAX_CHECK
-       //get prompt
-       if (*param == 0)
-       {
-               error_req_param_missing ();
-               return 1;
-       }
-#endif
-
-       prompt = param;
-
-       hWnd=GetConsoleWindow ();
-//     DebugPrintf("FindWindow hWnd = %d\n",hWnd);
-//     ConErrPrintf("FindWindow hWnd = %d\n",hWnd);
-
-       switch (MessageBox(hWnd, prompt, title, uType))
-       {
-               case IDYES:
-               case IDOK:
-                       nErrorLevel = 10;
-                       break;
-
-               case IDNO:
-                       nErrorLevel = 11;
-                       break;
-
-               case IDCANCEL:
-                       nErrorLevel = 12;
-                       break;
-       }
-
-       return 0;
-}
-
-#endif /* INCLUDE_CMD_MSGBOX */
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/path.c b/reactos/subsys/system/cmd/path.c
deleted file mode 100644 (file)
index 601863a..0000000
+++ /dev/null
@@ -1,91 +0,0 @@
-/*
- *  PATH.C - path internal command.
- *
- *
- *  History:
- *
- *    17 Jul 1998 (John P Price)
- *        Separated commands into individual files.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    09-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("/?").
- *
- *    18-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode ready!
- *
- *    18-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Redirection safe!
- *
- *    24-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed Win32 environment handling.
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_PATH
-
-/* size of environment variable buffer */
-#define ENV_BUFFER_SIZE 1024
-
-
-INT cmd_path (LPTSTR cmd, LPTSTR param)
-{
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_PATH_HELP1);
-               return 0;
-       }
-
-       nErrorLevel = 0;
-
-       /* if param is empty, display the PATH environment variable */
-       if (!param || !*param)
-       {
-               DWORD  dwBuffer;
-               LPTSTR pszBuffer;
-               TCHAR szMsg[RC_STRING_MAX_SIZE];
-
-               pszBuffer = (LPTSTR)malloc (ENV_BUFFER_SIZE * sizeof(TCHAR));
-               dwBuffer = GetEnvironmentVariable (_T("PATH"), pszBuffer, ENV_BUFFER_SIZE);
-               if (dwBuffer == 0)
-               {
-                       LoadString(CMD_ModuleHandle, STRING_VOL_HELP2, szMsg, RC_STRING_MAX_SIZE);
-                   ConOutPrintf(szMsg, _T("PATH"));
-                       return 0;
-               }
-               else if (dwBuffer > ENV_BUFFER_SIZE)
-               {
-                       pszBuffer = (LPTSTR)realloc (pszBuffer, dwBuffer * sizeof (TCHAR));
-                       GetEnvironmentVariable (_T("PATH"), pszBuffer, ENV_BUFFER_SIZE);
-               }
-
-               ConOutPrintf (_T("PATH=%s\n"), pszBuffer);
-               free (pszBuffer);
-
-               return 0;
-       }
-
-       /* skip leading '=' */
-       if (*param == _T('='))
-               param++;
-
-       /* set PATH environment variable */
-       if (!SetEnvironmentVariable (_T("PATH"), param))
-       {
-               nErrorLevel = 1;
-               return 1;
-       }
-
-       return 0;
-}
-
-#endif
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/pause.c b/reactos/subsys/system/cmd/pause.c
deleted file mode 100644 (file)
index 2002447..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- *  PAUSE.C - pause internal command.
- *
- *
- *  History:
- *
- *    16 Jul 1998 (Hans B Pufal)
- *        started.
- *
- *    16 Jul 1998 (John P Price)
- *        Seperated commands into individual files.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    18-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode ready!
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_PAUSE
-
-/*
- * Perform PAUSE command.
- *
- * FREEDOS extension : If parameter is specified use that as the pause
- *   message.
- *
- * ?? Extend to include functionality of CHOICE if switch chars
- *     specified.
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-INT cmd_pause (LPTSTR cmd, LPTSTR param)
-{
-
-#ifdef _DEBUG
-       DebugPrintf (_T("cmd_pause: \'%s\' : \'%s\')\n"), cmd, param);
-#endif
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_PAUSE_HELP1);
-               return 0;
-       }
-
-       if (*param)
-               ConOutPrintf (param);
-       else
-               msg_pause ();
-
-       cgetchar ();
-
-       return 0;
-}
-
-#endif
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/precomp.h b/reactos/subsys/system/cmd/precomp.h
deleted file mode 100644 (file)
index 3fd7e6b..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-#ifdef _MSC_VER
-#pragma warning ( disable : 4103 ) /* use #pragma pack to change alignment */
-#undef _CRT_SECURE_NO_DEPRECATE
-#define _CRT_SECURE_NO_DEPRECATE
-#endif//_MSC_VER
-
-#include <stdlib.h>
-#define WIN32_NO_STATUS
-#include <windows.h>
-#include <winnt.h>
-#include <shellapi.h>
-
-#include <tchar.h>
-#include <direct.h>
-
-#include <ctype.h>
-#include <string.h>
-#include <stdio.h>
-#include <stdarg.h>
-#include <math.h>
-#include <time.h>
-
-#define NTOS_MODE_USER
-#include <ndk/ntndk.h>
-
-#include "cmd.h"
-#include "config.h"
-#include "batch.h"
-
diff --git a/reactos/subsys/system/cmd/prompt.c b/reactos/subsys/system/cmd/prompt.c
deleted file mode 100644 (file)
index 4ef8814..0000000
+++ /dev/null
@@ -1,235 +0,0 @@
-/*
- *  PROMPT.C - prompt handling.
- *
- *
- *  History:
- *
- *    14/01/95 (Tim Normal)
- *        started.
- *
- *    08/08/95 (Matt Rains)
- *        i have cleaned up the source code. changes now bring this source
- *        into guidelines for recommended programming practice.
- *
- *    01/06/96 (Tim Norman)
- *        added day of the week printing (oops, forgot about that!)
- *
- *    08/07/96 (Steffan Kaiser)
- *        small changes for speed
- *
- *    20-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        removed redundant day strings. Use ones defined in date.c.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    28-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        moved cmd_prompt from internal.c to here
- *
- *    09-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("/?").
- *
- *    14-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added "$+" option.
- *
- *    09-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added "$A", "$C" and "$F" option.
- *        Added locale support.
- *        Fixed "$V" option.
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection safe!
- *
- *    24-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed Win32 environment handling.
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-#include <precomp.h>
-#include "resource.h"
-
-/*
- * print the command-line prompt
- */
-VOID PrintPrompt(VOID)
-{
-       static TCHAR default_pr[] = _T("$P$G");
-       TCHAR  szPrompt[256];
-       LPTSTR pr;
-
-       if (GetEnvironmentVariable (_T("PROMPT"), szPrompt, 256))
-               pr = szPrompt;
-       else
-               pr = default_pr;
-
-       while (*pr)
-       {
-               if (*pr != _T('$'))
-               {
-                       ConOutChar (*pr);
-               }
-               else
-               {
-                       pr++;
-
-                       switch (_totupper (*pr))
-                       {
-                               case _T('A'):
-                                       ConOutChar (_T('&'));
-                                       break;
-
-                               case _T('B'):
-                                       ConOutChar (_T('|'));
-                                       break;
-
-                               case _T('C'):
-                                       ConOutChar (_T('('));
-                                       break;
-
-                               case _T('D'):
-                                       PrintDate ();
-                                       break;
-
-                               case _T('E'):
-                                       ConOutChar (_T('\x1B'));
-                                       break;
-
-                               case _T('F'):
-                                       ConOutChar (_T(')'));
-                                       break;
-
-                               case _T('G'):
-                                       ConOutChar (_T('>'));
-                                       break;
-
-                               case _T('H'):
-                                       ConOutChar (_T('\x08'));
-          ConOutChar (_T(' '));
-          ConOutChar (_T('\x08'));
-                                       break;
-
-                               case _T('L'):
-                                       ConOutChar (_T('<'));
-                                       break;
-
-                               case _T('N'):
-                                       {
-                                               TCHAR szPath[MAX_PATH];
-                                               GetCurrentDirectory (MAX_PATH, szPath);
-                                               ConOutChar (szPath[0]);
-                                       }
-                                       break;
-
-                               case _T('P'):
-                                       {
-                                               TCHAR szPath[MAX_PATH];
-                                               GetCurrentDirectory (MAX_PATH, szPath);
-                                               ConOutPrintf (_T("%s"), szPath);
-                                       }
-                                       break;
-
-                               case _T('Q'):
-                                       ConOutChar (_T('='));
-                                       break;
-
-        case _T('S'):
-                                       ConOutChar (_T(' '));
-                                       break;
-
-                               case _T('T'):                                   
-          {          
-          SYSTEMTIME t;
-          GetSystemTime(&t); 
-          ConOutPrintf(_T("%02d%c%02d%c%02d%c%02d\n"),t.wHour, cTimeSeparator,t.wMinute , cTimeSeparator,
-                     t.wSecond , cDecimalSeparator, t.wMilliseconds );
-          }
-                                       break;
-          
-                               case _T('V'):
-                                       switch (osvi.dwPlatformId)
-                                       {
-                                               case VER_PLATFORM_WIN32_WINDOWS:
-                                                       if (osvi.dwMajorVersion == 4 &&
-                                                               osvi.dwMinorVersion == 1)
-                                                               ConOutPrintf (_T("Windows 98"));
-                                                       else
-                                                               ConOutPrintf (_T("Windows 95"));
-                                                       break;
-
-
-                                               case VER_PLATFORM_WIN32_NT:
-                                                       ConOutPrintf (_T("Windows NT Version %lu.%lu"),
-                                                                                 osvi.dwMajorVersion, osvi.dwMinorVersion);
-                                                       break;
-                                       }
-                                       break;
-
-                               case _T('_'):
-                                       ConOutChar (_T('\n'));
-                                       break;
-
-                               case '$':
-                                       ConOutChar (_T('$'));
-                                       break;
-
-#ifdef FEATURE_DIRECTORY_STACK
-                               case '+':
-                                       {
-                                               INT i;
-                                               for (i = 0; i < GetDirectoryStackDepth (); i++)
-                                                       ConOutChar (_T('+'));
-                                       }
-                                       break;
-#endif
-                       }
-               }
-               pr++;
-       }
-}
-
-
-#ifdef INCLUDE_CMD_PROMPT
-
-INT cmd_prompt (LPTSTR cmd, LPTSTR param)
-{              
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_PROMPT_HELP1);
-
-#ifdef FEATURE_DIRECTORY_STACK
-               ConOutResPaging(FALSE,STRING_PROMPT_HELP2);
-#endif
-               ConOutResPaging(FALSE,STRING_PROMPT_HELP3);
-               return 0;
-       }
-
-       /* if it is null, then it needs to set to default,
-          because that means the user entered "prompt" only.
-               so even if param is null you _must_ still set prompt
-               to the default.  There seems to be some kinda difference 
-               between winxp and 2k in this matter and this way will 
-               cover both. Do not use fixed size of szParam for param the buffer are 8192bytes
-               and will later change to dymatic buffer */
-
-       /* set PROMPT environment variable */
-       if (param[0] != _T('\0'))
-       {
-               if (!SetEnvironmentVariable (_T("PROMPT"), param))
-               return 1;
-       }
-       else
-       {
-               TCHAR szParam[5];
-               _tcscpy(szParam,_T("$P$G"));
-               if (!SetEnvironmentVariable (_T("PROMPT"),szParam))
-               return 1;       
-       }
-
-       
-                       
-       return 0;
-}
-#endif
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/readme.txt b/reactos/subsys/system/cmd/readme.txt
deleted file mode 100644 (file)
index 5ac2304..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-ReactOS command line interpreter CMD
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-The ReactOS command line interpreter CMD is derived from FreeCOM, the
-FreeDOS command line interpreter.
-
-We are shooting mainly to be just like 2000/XP cmd.exe.  They are very close and only a small number(none that i can recall off the top of my head, so maybe 0) differences have been found between those two.  It has been reported that ROS cmd.exe does not work on nt4 because of a missing api.  I'm hoping to fix this at some point.
-
-
-Compiling
-~~~~~~~~~
-ROS cmd used to depend on __REACTOS__ to provide two different ways to build cmd.  There is still code left in it for this but...  The __REACTOS__ = 0 has not been develped, maintained.  And therefore it does not even compile anymore.  __REACTOS__ = 1 works fine on both windows(nt). and someday i plan to remove all the __REACTOS__ = 0.
-
-Using rbuild you can compile cmd seperatly by "make cmd_install".  Also you can compile cmd using MSVC 6 and soon 7/8 hopefully.
-
-
-Current Features
-~~~~~~~~~~~~~~~~
- - environment handling with prompt and path support.
- - directory utilities.
- - command-line history with doskey-like features.
- - batch file processing.
- - input/output redirection and piping.
- - alias support.
- - filename completion (use TAB), both unix and windows style.
-
-
-Credits
-~~~~~~~
-FreeDOS developers:
-   normat@rpi.edu (Tim Norman)
-   mrains@apanix.apana.org.au (Matt Rains)
-   ejeffrey@iastate.edu (Evan Jeffrey)
-   Steffen.Kaiser@Informatik.TU-Chemnitz.DE (Steffen Kaiser)
-   Svante Frey (sfrey@kuai.se)
-   Oliver Mueller (ogmueller@t-online.de)
-   Aaron Kaufman (morgan@remarque.berkeley.edu)
-   Marc Desrochers (bitzero@hotmail.com)
-   Rob Lake (rlake@cs.mun.ca)
-   John P. Price <linux-guru@gcfl.net>
-   Hans B Pufal <hansp@digiweb.com>
-
-ReactOS developers:
-   Eric Kohl <ekohl@rz-online.de>
-   Emanuele Aliberti <ea@iol.it>
-   Paolo Pantaleo <paolopan@freemail.it>
-   Brandon Turner <turnerb7@msu.edu>
-
-
-
-Bugs
-~~~~
-There is still many bugs ;)
-Please report bugs to ReactOS team <ros-dev@reactos.org> or to bugzilla at www.reactos.org
-
diff --git a/reactos/subsys/system/cmd/readme2.txt b/reactos/subsys/system/cmd/readme2.txt
deleted file mode 100644 (file)
index a7e7dfe..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-General Overview of How THings Work
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-First it comes into _main in cmd.c(1811).  The command line params are taking in and if it is unicode it uses CommandLineToArgvW.  This can cause a problem on older machines and that is why we have our own custom _CommandLineToArgvW to help this along.  We pull in the launch directory as the inital dir and set that in _tchdir.  We make a handle to the default console out using CreateFile.  
-
-Then we call Initialize().  Here we need to load ntdll.dll if it isnt loaded(windows 9x machines).  We also setup some gloabl vars like default io handles and nErrorLevel and set %prompt% to $P$G.  This is where all command lines switches given to cmd on startup are done.
-
-From here main calls ProcessInput().  This is where cmd loops for getting input and doing the commands.  First it checks to see if there is a batch file(note: there is agolbal struct "bc" which is NULL when not processing a batch file) and if there is it will pull a new line from that file.  If not, thne it will wait for input.  Currently there is some stuff for set /a in there, which might stay there or see if we can find a better spot. 
-
-Once there is input taken in from the command line it is sent into ParseCommandLine().  In here we fist check for aliases and convert if need be.  THen we look for redirections using GetRedirection() which will remove any redirection symbols.  and pass back info about where to redirect.  from this info it will do some switching around with the handles for where things go and send them as need be.  personally i dont like this code and i tried to chnage it before but failed.  it is confusing to me and i dont understand why a lot of it is there but apparently it is needed.
-
-It sends the new string without any redirection info into DoCommand(). In this function we just look to see what should be done.  There is one of 2 things that could happen.  1) we fnd the matching command and send it off to that commands little section. 2) we dont find it so we send it to Execute() and see if it is a file that we can do something.
-
-Execute will try to launch the file using createprocess and falls back on shellexecute.  It calls a function called SearchForExecuteable() to find the full path name and looks in all the correct locations like PATH, curreent folder, windows folder.  If it cant find it, just fails and prints out a message.
-
-Some useful functions that are used a lot:
-split() - splits a string into an array of string on spaces that arent inside quotes. which you need to call freep() on later t clean up.
-IsValidPathName(), IsExistingFile(), IsExistingDirectory() - all do what you would expect.
-PagePrompt() -  ask them to hit a key to continue
-FilePromptYN[A]() - ask them a yes or no question
diff --git a/reactos/subsys/system/cmd/redir.c b/reactos/subsys/system/cmd/redir.c
deleted file mode 100644 (file)
index 21848c3..0000000
+++ /dev/null
@@ -1,279 +0,0 @@
-/*
- *  REDIR.C - redirection handling.
- *
- *
- *  History:
- *
- *    12/15/95 (Tim Norman)
- *        started.
- *
- *    12 Jul 98 (Hans B Pufal)
- *        Rewrote to make more efficient and to conform to new command.c
- *        and batch.c processing.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        Added config.h include
- *
- *    22-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode safe!
- *        Added new error redirection "2>" and "2>>".
- *
- *    26-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added new error AND output redirection "&>" and "&>>".
- *
- *    24-Jun-2005 (Brandon Turner <turnerb7@msu.edu>)
- *        simple check to fix > and | bug with 'rem'
- */
-
-#include <precomp.h>
-
-#ifdef FEATURE_REDIRECTION
-
-
-static BOOL
-IsRedirection (TCHAR c)
-{
-       return (c == _T('<')) || (c == _T('>')) || (c == _T('|'));
-}
-
-
-/*
- * Gets the redirection info from the command line and copies the
- * file names into ifn, ofn and efn removing them from the command
- * line.
- *
- * Converts remaining command line into a series of null terminated
- * strings defined by the pipe char '|'. Each string corresponds
- * to a single executable command. A double null terminates the
- * command strings.
- *
- * Return number of command strings found.
- *
- */
-
-INT GetRedirection (LPTSTR s, LPTSTR ifn, LPTSTR ofn, LPTSTR efn, LPINT lpnFlags)
-{
-       INT num = 1;
-       LPTSTR dp = s;
-       LPTSTR sp = s;
-
-#ifdef INCLUDE_CMD_REM
-
-       TCHAR * line = s;
-
-       while (_istspace (*line))
-                       line++;
-
-       /*first thing first.  check to see if this is "rem" and hope out*/
-       if(!_tcsncmp (line, _T("rem "), 4))
-       {
-               lpnFlags = 0;
-               *ifn=('\0');
-               *ofn=('\0');
-               *efn=_T('\0');    
-               return 1;
-       }  
-#endif
-       /* find and remove all the redirections first */
-       while (*sp)
-       {
-               if (*sp == _T('^'))
-               {
-                       *dp++ = *sp++;
-                       *dp++ = *sp++;
-                       continue;
-               }
-               if ((*sp == _T('"')) || (*sp == _T('\'')))
-               {
-                       /* No redirects inside quotes */
-                       TCHAR qc = *sp;
-
-                       do
-                               *dp++ = *sp++;
-                       while (*sp && *sp != qc);
-
-                       *dp++ = *sp++;
-               }
-               else if ((*sp == _T('<')) || (*sp == _T('>')) ||
-                                (*sp == _T('1')) || (*sp == _T('2')) || (*sp == _T('&')))
-               {
-                       /* MS-DOS ignores multiple redirection symbols and uses the last */
-                       /* redirection, so we'll emulate that and not check */
-
-                       if (*sp == _T('<'))
-                       {
-                               /* input redirection */
-                               *lpnFlags |= INPUT_REDIRECTION;
-                               do sp++;
-                               while( _istspace (*sp) );
-
-                               /* copy file name */
-                               while (*sp && !IsRedirection (*sp) && !_istspace (*sp))
-                                       *ifn++ = *sp++;
-                               *ifn = _T('\0');
-                       }
-                       else if (*sp == _T('>'))
-                       {
-                               /* output redirection */
-                               *lpnFlags |= OUTPUT_REDIRECTION;
-                               sp++;
-
-                               /* append request ? */
-                               if (*sp == _T('>'))
-                               {
-                                       *lpnFlags |= OUTPUT_APPEND;
-                                       sp++;
-                               }
-
-                               while (_istspace (*sp))
-                                       sp++;
-
-                               /* copy file name */
-                               while (*sp && !IsRedirection (*sp) && !_istspace (*sp))
-                                       *ofn++ = *sp++;
-                               *ofn = _T('\0');
-                       }
-
-                        else if (*sp == _T('1'))
-                       {
-                               /* output redirection */
-                               sp++;
-
-                               if (*sp == _T('>'))
-                               {
-                                       /* output redirection */
-                                       *lpnFlags |= OUTPUT_REDIRECTION;
-                                       sp++;
-
-                                       /* append request ? */
-                                       if (*sp == _T('>'))
-                                       {
-                                               *lpnFlags |= OUTPUT_APPEND;
-                                               sp++;
-                                       }
-                               }
-                               else
-                               {
-                                       /* no redirection!! copy the '1' character! */
-                                       sp--;
-                                       *dp++ = *sp++;
-                                       continue;
-                               }
-
-                               while (_istspace (*sp))
-                                       sp++;
-
-                               /* copy file name */
-                               while (*sp && !IsRedirection (*sp) && !_istspace (*sp))
-                                       *ofn++ = *sp++;
-                               *ofn = _T('\0');
-                       }
-
-                       else if (*sp == _T('2'))
-                       {
-                               /* error redirection */
-                               sp++;
-
-                               if (*sp == _T('>'))
-                               {
-                                       *lpnFlags |= ERROR_REDIRECTION;
-                                       sp++;
-
-                                       /* append request ? */
-                                       if (*sp == _T('>'))
-                                       {
-                                               *lpnFlags |= ERROR_APPEND;
-                                               sp++;
-                                       }
-                               }
-                               else
-                               {
-                                       /* no redirection!! copy the '2'  character! */
-                                       sp--;
-                                       *dp++ = *sp++;
-                                       continue;
-                               }
-
-                               while (_istspace (*sp))
-                                       sp++;
-
-                               /* copy file name */
-                               while (*sp && !IsRedirection (*sp) && !_istspace (*sp))
-                                       *efn++ = *sp++;
-                               *efn = _T('\0');
-                       }
-                       else if (*sp == _T('&'))
-                       {
-                               /* output AND error redirection */
-                               sp++;
-
-                               if (*sp == _T('>'))
-                               {
-                                       *lpnFlags |= (ERROR_REDIRECTION | OUTPUT_REDIRECTION);
-                                       sp++;
-
-                                       /* append request ? */
-                                       if (*sp == _T('>'))
-                                       {
-                                               *lpnFlags |= (ERROR_APPEND | OUTPUT_APPEND);
-                                               sp++;
-                                       }
-                               }
-                               else
-                               {
-                                       /* no redirection!! copy the '&' character! */
-                                       sp--;
-                                       *dp++ = *sp++;
-                                       continue;
-                               }
-
-                               while (_istspace (*sp))
-                                       sp++;
-
-                               /* copy file name */
-                               while (*sp && !IsRedirection (*sp) && !_istspace (*sp))
-                                       *ofn++ = *efn++ = *sp++;
-                               *ofn = *efn = _T('\0');
-                       }
-               }
-               else
-                       *dp++ = *sp++;
-       }
-
-       *dp++ = _T('\0');
-       *dp = _T('\0');
-
-       /* now go for the pipes */
-       sp = s;
-       while (*sp)
-       {
-               if (*sp == _T('^'))
-               {
-                       sp++;
-                       sp++;
-                       continue;
-               }
-               else if ((*sp == _T('"')) || (*sp == _T('\'')))
-               {
-                       TCHAR qc = *sp;
-
-                       do
-                               sp++;
-                       while (*sp && *sp != qc);
-
-                       sp++;
-               }
-               else if (*sp == _T('|'))
-               {
-                       *sp++ = _T('\0');
-                       num++;
-               }
-               else
-                       sp++;
-       }
-
-       return num;
-}
-
-#endif /* FEATURE_REDIRECTION */
diff --git a/reactos/subsys/system/cmd/ren.c b/reactos/subsys/system/cmd/ren.c
deleted file mode 100644 (file)
index b096fc8..0000000
+++ /dev/null
@@ -1,268 +0,0 @@
-/*
- *  REN.C - rename internal command.
- *
- *
- *  History:
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    18-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>
- *        Added support for quoted long file names with spaces.
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>
- *        Unicode and redirection safe!
- *
- *    17-Oct-2001 (Eric Kohl <ekohl@rz.online.de>
- *        Implemented basic rename code.
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_RENAME
-
-enum
-{
-  REN_ATTRIBUTES = 0x001,   /* /A : not implemented */
-  REN_ERROR      = 0x002,   /* /E */
-  REN_NOTHING    = 0x004,   /* /N */
-  REN_PROMPT     = 0x008,   /* /P : not implemented */
-  REN_QUIET      = 0x010,   /* /Q */
-  REN_SUBDIR     = 0x020,   /* /S */
-  REN_TOTAL      = 0x040,   /* /T */
-};
-
-
-/*
- *  file rename internal command.
- *
- */
-INT cmd_rename (LPTSTR cmd, LPTSTR param)
-{
-  TCHAR szMsg[RC_STRING_MAX_SIZE];
-  LPTSTR *arg = NULL;
-  INT args = 0;
-  INT nEvalArgs = 0; /* nunber of evaluated arguments */
-  DWORD dwFlags = 0;
-  DWORD dwFiles = 0; /* number of renamedd files */
-  INT i;
-  LPTSTR srcPattern = NULL;
-  LPTSTR dstPattern = NULL;
-  TCHAR dstFile[MAX_PATH];
-  BOOL bDstWildcard = FALSE;
-
-  LPTSTR p,q,r;
-
-  HANDLE hFile;
-  WIN32_FIND_DATA f;
-
-  if (!_tcsncmp(param, _T("/?"), 2))
-  {
-    ConOutResPaging(TRUE,STRING_REN_HELP1);
-    return 0;
-  }
-
-  nErrorLevel = 0;
-
-  /* split the argument list */
-  arg = split(param, &args, FALSE);
-
-  if (args < 2)
-    {
-      if (!(dwFlags & REN_ERROR))
-       error_req_param_missing();
-      freep(arg);
-      return 1;
-    }
-
-  /* read options */
-  for (i = 0; i < args; i++)
-    {
-      if (*arg[i] == _T('/'))
-       {
-         if (_tcslen(arg[i]) >= 2)
-           {
-             switch (_totupper(arg[i][1]))
-               {
-                 case _T('E'):
-                   dwFlags |= REN_ERROR;
-                   break;
-
-                 case _T('N'):
-                   dwFlags |= REN_NOTHING;
-                   break;
-
-                 case _T('P'):
-                   dwFlags |= REN_PROMPT;
-                   break;
-
-                 case _T('Q'):
-                   dwFlags |= REN_QUIET;
-                   break;
-
-                 case _T('S'):
-                   dwFlags |= REN_SUBDIR;
-                   break;
-
-                 case _T('T'):
-                   dwFlags |= REN_TOTAL;
-                   break;
-               }
-           }
-         nEvalArgs++;
-       }
-    }
-
-  /* keep quiet within batch files */
-  if (bc != NULL)
-    dwFlags |= REN_QUIET;
-
-  /* there are only options on the command line --> error!!! */
-  if (args < nEvalArgs + 2)
-    {
-      if (!(dwFlags & REN_ERROR))
-       error_req_param_missing();
-      freep(arg);
-      return 1;
-    }
-
-  /* get destination pattern */
-  for (i = 0; i < args; i++)
-    {
-      if (*arg[i] == _T('/'))
-       continue;
-      dstPattern = arg[i];
-    }
-
-  if (_tcschr(dstPattern, _T('*')) || _tcschr(dstPattern, _T('?')))
-    bDstWildcard = TRUE;
-
-  /* enumerate source patterns */
-  for (i = 0; i < args; i++)
-    {
-      if (*arg[i] == _T('/') || arg[i] == dstPattern)
-       continue;
-
-      srcPattern = arg[i];
-
-#ifdef _DEBUG
-      ConErrPrintf(_T("\n\nSourcePattern: %s\n"), srcPattern);
-      ConErrPrintf(_T("DestinationPattern: %s\n"), dstPattern);
-#endif
-
-      hFile = FindFirstFile(srcPattern, &f);
-      if (hFile == INVALID_HANDLE_VALUE)
-       {
-         if (!(dwFlags & REN_ERROR))
-           error_file_not_found();
-         continue;
-       }
-
-      do
-       {
-         /* ignore "." and ".." */
-         if (!_tcscmp (f.cFileName, _T(".")) ||
-             !_tcscmp (f.cFileName, _T("..")))
-           continue;
-
-         /* do not rename hidden or system files */
-         if (f.dwFileAttributes & (FILE_ATTRIBUTE_HIDDEN | FILE_ATTRIBUTE_SYSTEM))
-           continue;
-
-         /* do not rename directories when the destination pattern contains
-          * wildcards, unless option /S is used */
-         if ((f.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-             && bDstWildcard
-             && !(dwFlags & REN_SUBDIR))
-           continue;
-
-#ifdef _DEBUG
-         ConErrPrintf(_T("Found source name: %s\n"), f.cFileName);
-#endif
-
-         /* build destination file name */
-         p = f.cFileName;
-         q = dstPattern;
-         r = dstFile;
-         while(*q != 0)
-           {
-             if (*q == '*')
-               {
-                 q++;
-                 while (*p != 0 && *p != *q)
-                   {
-                     *r = *p;
-                     p++;
-                     r++;
-                   }
-               }
-             else if (*q == '?')
-               {
-                 q++;
-                 if (*p != 0)
-                   {
-                     *r = *p;
-                     p++;
-                     r++;
-                   }
-               }
-             else
-               {
-                 *r = *q;
-                 if (*p != 0)
-                   p++;
-                 q++;
-                 r++;
-               }
-           }
-         *r = 0;
-
-#ifdef _DEBUG
-         ConErrPrintf(_T("DestinationFile: %s\n"), dstFile);
-#endif
-
-         if (!(dwFlags & REN_QUIET) && !(dwFlags & REN_TOTAL))
-           ConOutPrintf(_T("%s -> %s\n"), f.cFileName, dstFile);
-
-         /* rename the file */
-         if (!(dwFlags & REN_NOTHING))
-           {
-             if (MoveFile(f.cFileName, dstFile))
-               {
-                 dwFiles++;
-               }
-             else
-               {
-                 if (!(dwFlags & REN_ERROR))
-                 {
-                   LoadString(CMD_ModuleHandle, STRING_REN_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-                   ConErrPrintf(szMsg, GetLastError());
-                 }
-               }
-           }
-       }
-      while (FindNextFile(hFile, &f));
-      FindClose(hFile);
-    }
-
-  if (!(dwFlags & REN_QUIET))
-  {
-    if (dwFiles == 1)
-      LoadString( CMD_ModuleHandle, STRING_REN_HELP2, szMsg, RC_STRING_MAX_SIZE);
-    else
-      LoadString( CMD_ModuleHandle, STRING_REN_HELP3, szMsg, RC_STRING_MAX_SIZE);
-    ConOutPrintf(szMsg,dwFiles);
-  }
-
-  freep(arg);
-
-  return 0;
-}
-
-#endif
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/res/terminal.ico b/reactos/subsys/system/cmd/res/terminal.ico
deleted file mode 100644 (file)
index f3252f6..0000000
Binary files a/reactos/subsys/system/cmd/res/terminal.ico and /dev/null differ
diff --git a/reactos/subsys/system/cmd/resource.h b/reactos/subsys/system/cmd/resource.h
deleted file mode 100644 (file)
index 7763708..0000000
+++ /dev/null
@@ -1,231 +0,0 @@
-
-
-#define RC_STRING_MAX_SIZE                 3072
-
-
-#define STRING_ERROR_PARAMETERF_ERROR      100
-#define STRING_ERROR_INVALID_SWITCH        101
-#define STRING_ERROR_TOO_MANY_PARAMETERS   102
-#define STRING_ERROR_PATH_NOT_FOUND        103
-#define STRING_ERROR_FILE_NOT_FOUND        104
-#define STRING_ERROR_REQ_PARAM_MISSING     105
-#define STRING_ERROR_INVALID_DRIVE         106
-#define STRING_ERROR_INVALID_PARAM_FORMAT  107
-#define STRING_ERROR_BADCOMMAND            108
-#define STRING_ERROR_OUT_OF_MEMORY         109
-#define STRING_ERROR_CANNOTPIPE            110
-#define STRING_ERROR_D_PAUSEMSG            111
-#define STRING_ERROR_DRIVER_NOT_READY      112
-
-#define STRING_CHOICE_OPTION               200
-#define STRING_COPY_OPTION                 201
-
-#define STRING_ALIAS_ERROR                 300
-#define STRING_BATCH_ERROR                 301
-#define STRING_CHCP_ERROR1                 302
-#define STRING_CHCP_ERROR4                 305
-#define STRING_CHOICE_ERROR                306
-#define STRING_CHOICE_ERROR_TXT            307
-#define STRING_CHOICE_ERROR_OPTION         308
-#define STRING_CMD_ERROR1                  309
-#define STRING_CMD_ERROR2                  310
-#define STRING_CMD_ERROR3                  311
-#define STRING_CMD_ERROR4                  312
-#define STRING_CMD_ERROR5                  313
-#define STRING_COLOR_ERROR1                314
-#define STRING_COLOR_ERROR2                315
-#define STRING_COLOR_ERROR3                316
-#define STRING_COLOR_ERROR4                317
-#define STRING_CONSOLE_ERROR               318
-#define STRING_COPY_ERROR1                 319
-#define STRING_COPY_ERROR2                 320
-#define STRING_COPY_ERROR3                 321
-#define STRING_COPY_ERROR4                 322
-#define STRING_DATE_ERROR                  323
-#define STRING_DEL_ERROR5                  328
-#define STRING_DEL_ERROR6                  329
-#define STRING_DEL_ERROR7                  330
-#define STRING_ERROR_ERROR1                332
-#define STRING_ERROR_ERROR2                333
-#define STRING_FOR_ERROR1                  334
-#define STRING_FOR_ERROR2                  335
-#define STRING_FOR_ERROR3                  336
-#define STRING_FOR_ERROR4                  337
-#define STRING_FREE_ERROR1                 338
-#define STRING_FREE_ERROR2                 339
-#define STRING_GOTO_ERROR1                 340
-#define STRING_GOTO_ERROR2                 341
-#define STRING_MOVE_ERROR1                 342
-#define STRING_MOVE_ERROR2                 343
-#define STRING_PATH_ERROR                  345
-#define STRING_REN_ERROR1                  346
-#define STRING_START_ERROR1                347
-#define STRING_TIME_ERROR1                 348
-#define STRING_TYPE_ERROR1                 349
-#define STRING_WINDOW_ERROR1               350
-
-
-
-#define STRING_ATTRIB_HELP                 600
-#define STRING_ALIAS_HELP                  601
-#define STRING_BEEP_HELP                   602
-#define STRING_CALL_HELP                   603
-#define STRING_CD_HELP                     604
-#define STRING_CHCP_HELP                   605
-#define STRING_CHOICE_HELP                 606
-#define STRING_CLS_HELP                    607
-#define STRING_CMD_HELP1                   608
-#define STRING_CMD_HELP2                   609
-#define STRING_CMD_HELP3                   610
-#define STRING_CMD_HELP4                   611
-#define STRING_CMD_HELP5                   612
-#define STRING_CMD_HELP6                   613
-#define STRING_CMD_HELP7                   614
-#define STRING_CMD_HELP8                   615 
-
-#define STRING_CMD_SHELLINFO               624
-
-#define STRING_COLOR_HELP1                 625
-#define STRING_COPY_HELP1                  626
-#define STRING_COPY_HELP2                  627
-
-#define STRING_DATE_HELP1                  628
-#define STRING_DATE_HELP2                  629
-#define STRING_DATE_HELP3                  630
-#define STRING_DATE_HELP4                  631
-#define STRING_DEL_HELP1                   632
-#define STRING_DEL_HELP2                   633
-#define STRING_DEL_HELP3                   634
-#define STRING_DEL_HELP4                   635
-#define STRING_DELAY_HELP                  636
-
-#define STRING_DIR_HELP1                   637
-#define STRING_DIR_HELP2                   638
-#define STRING_DIR_HELP3                   639
-#define STRING_DIR_HELP4                   640
-#define STRING_DIR_HELP5                   641
-#define STRING_DIR_HELP6                   642
-#define STRING_DIR_HELP7                   643
-#define STRING_DIR_HELP8                   644
-
-#define STRING_DIRSTACK_HELP1              645
-#define STRING_DIRSTACK_HELP2              646
-#define STRING_DIRSTACK_HELP3              647
-#define STRING_DIRSTACK_HELP4              648
-
-#define STRING_ECHO_HELP1                  649
-#define STRING_ECHO_HELP2                  650
-#define STRING_ECHO_HELP3                  651
-#define STRING_ECHO_HELP4                  652
-#define STRING_ECHO_HELP5                  653
-
-#define STRING_EXIT_HELP                   654
-
-#define STRING_FOR_HELP1                   655
-
-#define STRING_FREE_HELP1                  656
-#define STRING_FREE_HELP2                  657
-
-#define STRING_IF_HELP1                    658
-
-#define STRING_GOTO_HELP1                  659
-
-#define STRING_LABEL_HELP1                 660
-#define STRING_LABEL_HELP2                 661
-#define STRING_LABEL_HELP3                 662
-#define STRING_LABEL_HELP4                 663
-#define STRING_LABEL_HELP5                 664
-
-#define STRING_LOCALE_HELP1                665
-
-#define STRING_MKDIR_HELP                  666
-
-#define STRING_MEMMORY_HELP1               667
-#define STRING_MEMMORY_HELP2               668
-
-#define STRING_MISC_HELP1                  669
-
-#define STRING_MOVE_HELP1                  670
-#define STRING_MOVE_HELP2                  671
-
-#define STRING_MSGBOX_HELP                 672
-
-#define STRING_PATH_HELP1                  673
-
-#define STRING_PAUSE_HELP1                 674
-
-#define STRING_PROMPT_HELP1                675
-#define STRING_PROMPT_HELP2                676
-#define STRING_PROMPT_HELP3                677
-
-#define STRING_REM_HELP                    678
-
-#define STRING_REN_HELP1                   679
-#define STRING_REN_HELP2                   680
-#define STRING_REN_HELP3                   681
-
-#define STRING_RMDIR_HELP                  682
-
-#define STRING_SCREEN_HELP                 683
-
-#define STRING_SHIFT_HELP                  684
-
-#define STRING_SET_HELP                    685
-
-#define STRING_START_HELP1                 686
-
-#define STRING_TITLE_HELP                  687
-
-#define STRING_TIME_HELP1                  688
-#define STRING_TIME_HELP2                  689
-
-#define STRING_TIMER_HELP1                 690
-#define STRING_TIMER_HELP2                 691
-#define STRING_TIMER_HELP3                 692
-
-#define STRING_TYPE_HELP1                  693
-
-#define STRING_VERIFY_HELP1                694
-#define STRING_VERIFY_HELP2                695
-#define STRING_VERIFY_HELP3                696
-
-#define STRING_VERSION_HELP1               697
-#define STRING_VERSION_HELP2               698
-#define STRING_VERSION_HELP3               699
-#define STRING_VERSION_HELP4               700
-#define STRING_VERSION_HELP5               701
-#define STRING_VERSION_HELP6               702
-#define STRING_VERSION_HELP7               703
-#define STRING_VERSION_RUNVER              705
-
-#define STRING_VOL_HELP1                   706
-#define STRING_VOL_HELP2                   707
-#define STRING_VOL_HELP3                   708
-#define STRING_VOL_HELP4                   709
-
-#define STRING_WINDOW_HELP1                710
-#define STRING_WINDOW_HELP2                711
-
-#define STRING_COPY_FILE                   712
-#define STRING_DELETE_WIPE                 713
-#define STRING_FOR_ERROR                   714
-#define STRING_SCREEN_COL                  715
-#define STRING_SCREEN_ROW                  716
-#define STRING_TIMER_TIME                  717
-#define STRING_HELP1                       718
-#define STRING_HELP2                       719
-
-#define STRING_INVALID_OPERAND             720
-#define STRING_EXPECTED_CLOSE_PAREN        721
-#define STRING_EXPECTED_NUMBER_OR_VARIABLE 722
-#define STRING_SYNTAX_COMMAND_INCORRECT    723
-#define STRING_RMDIR_HELP2                                724
-#define STRING_MD_ERROR                                           725
-#define STRING_MD_ERROR2                                          726
-
-
-/* These strings are language independent (cmd.rc) */
-#define STRING_FREEDOS_DEV                 800
-#define STRING_REACTOS_DEV                 801
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/screen.c b/reactos/subsys/system/cmd/screen.c
deleted file mode 100644 (file)
index 315e7c8..0000000
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * SCREEN.C - screen internal command.
- *
- * clone from 4nt msgbox command
- *
- * 30 Aug 1999
- *     started - Paolo Pantaleo <paolopan@freemail.it>
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- *
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_SCREEN
-
-
-INT CommandScreen (LPTSTR cmd, LPTSTR param)
-{
-       SHORT x,y;
-       BOOL bSkipText = FALSE;
-
-       if (_tcsncmp (param, _T("/?"), 2) == 0)
-       {
-               ConOutResPaging(TRUE,STRING_SCREEN_HELP);
-               return 0;
-       }
-
-       nErrorLevel = 0;
-
-       //get row
-       while(_istspace(*param))
-               param++;
-
-       if(!(*param))
-       {
-               error_req_param_missing ();
-               return 1;
-       }
-
-       y = _ttoi(param);
-       if (y<0 || y>(maxy-1))
-       {
-               ConOutResPuts(STRING_SCREEN_ROW);
-               
-               return 1;
-       }
-
-       //get col
-       if(!(param = _tcschr(param,_T(' '))))
-       {
-               error_req_param_missing ();
-               return 1;
-       }
-
-       while(_istspace(*param))
-               param++;
-
-       if(!(*param))
-       {
-               error_req_param_missing ();
-               return 1;
-       }
-
-       x = _ttoi(param);
-       if (x<0 || x>(maxx-1))
-       {
-               ConErrResPuts(STRING_SCREEN_COL);
-               return 1;
-       }
-
-       //get text
-       if(!(param = _tcschr(param,_T(' '))))
-       {
-               bSkipText = TRUE;
-       }
-       else
-       {
-               while(_istspace(*param))
-                       param++;
-
-               if(!(*param))
-               {
-                       bSkipText = TRUE;
-               }
-       }
-
-       bIgnoreEcho = TRUE;
-
-       if(bSkipText)
-               x=0;
-
-
-       SetCursorXY(x,y);
-
-       if(!(bSkipText))
-               ConOutPuts(param);
-
-       return 0;
-}
-
-#endif /* INCLUDE_CMD_SCREEN */
diff --git a/reactos/subsys/system/cmd/set.c b/reactos/subsys/system/cmd/set.c
deleted file mode 100644 (file)
index e345360..0000000
+++ /dev/null
@@ -1,494 +0,0 @@
-/*
- *  SET.C - set internal command.
- *
- *
- *  History:
- *
- *    06/14/97 (Tim Norman)
- *        changed static var in set() to a malloc'd space to pass to putenv.
- *        need to find a better way to do this, since it seems it is wasting
- *        memory when variables are redefined.
- *
- *    07/08/1998 (John P. Price)
- *        removed call to show_environment in set command.
- *        moved test for syntax before allocating memory in set command.
- *        misc clean up and optimization.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    28-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added set_env function to set env. variable without needing set command
- *
- *    09-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("/?").
- *
- *    24-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed Win32 environment handling.
- *        Unicode and redirection safe!
- *
- *    25-Feb-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed little bug.
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include <malloc.h>
-#include <stdio.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_SET
-
-
-/* initial size of environment variable buffer */
-#define ENV_BUFFER_SIZE  1024
-
-static BOOL
-seta_eval ( LPCTSTR expr );
-
-static LPCTSTR
-skip_ws ( LPCTSTR p )
-{
-       return p + _tcsspn ( p, _T(" \t") );
-}
-
-INT cmd_set (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       INT i;
-       LPTSTR p;
-
-       if ( !_tcsncmp (param, _T("/?"), 2) )
-       {
-               ConOutResPaging(TRUE,STRING_SET_HELP);
-               return 0;
-       }
-
-       /* remove escapes */
-       if ( param[0] ) for ( i = 0; param[i+1]; i++ )
-       {
-               if ( param[i] == _T('^') )
-               {
-                       memmove ( &param[i], &param[i+1], _tcslen(&param[i]) * sizeof(TCHAR) );
-               }
-       }
-
-       /* if no parameters, show the environment */
-       if (param[0] == _T('\0'))
-       {
-               LPTSTR lpEnv;
-               LPTSTR lpOutput;
-               INT len;
-
-               lpEnv = (LPTSTR)GetEnvironmentStrings ();
-               if (lpEnv)
-               {
-                       lpOutput = lpEnv;
-                       while (*lpOutput)
-                       {
-                               len = _tcslen(lpOutput);
-                               if (len)
-                               {
-                                       if (*lpOutput != _T('='))
-                                               ConOutPuts (lpOutput);
-                                       lpOutput += (len + 1);
-                               }
-                       }
-                       FreeEnvironmentStrings (lpEnv);
-               }
-
-               return 0;
-       }
-
-       /* the /A does *NOT* have to be followed by a whitespace */
-       if ( !_tcsnicmp (param, _T("/A"), 2) )
-       {
-               BOOL Success = seta_eval ( skip_ws(param+2) );
-               if(!Success)
-               {
-                       /*might seem random but this is what windows xp does */
-                       nErrorLevel = 9165;
-               }
-               /* TODO FIXME - what are we supposed to return? */
-               return Success;
-       }
-
-       p = _tcschr (param, _T('='));
-       if (p)
-       {
-               /* set or remove environment variable */
-               *p = _T('\0');
-               p++;
-               if (*p == _T('\0'))
-               {
-                       p = NULL;
-               }
-               SetEnvironmentVariable (param, p);
-       }
-       else
-       {
-               /* display environment variable */
-               LPTSTR pszBuffer;
-               DWORD dwBuffer;
-
-               pszBuffer = (LPTSTR)malloc (ENV_BUFFER_SIZE * sizeof(TCHAR));
-               dwBuffer = GetEnvironmentVariable (param, pszBuffer, ENV_BUFFER_SIZE);
-               if (dwBuffer == 0)
-               {
-                       LoadString(CMD_ModuleHandle, STRING_PATH_ERROR, szMsg, RC_STRING_MAX_SIZE);
-                       ConErrPrintf (szMsg, param);
-                       return 0;
-               }
-               else if (dwBuffer > ENV_BUFFER_SIZE)
-               {
-                       pszBuffer = (LPTSTR)realloc (pszBuffer, dwBuffer * sizeof (TCHAR));
-                       GetEnvironmentVariable (param, pszBuffer, dwBuffer);
-               }
-               ConOutPrintf (_T("%s\n"), pszBuffer);
-
-               free (pszBuffer);
-
-               return 0;
-       }
-
-       return 0;
-}
-
-static INT
-ident_len ( LPCTSTR p )
-{
-       LPCTSTR p2 = p;
-       if ( __iscsymf(*p) )
-       {
-               ++p2;
-               while ( __iscsym(*p2) )
-                       ++p2;
-       }
-       return p2-p;
-}
-
-#define PARSE_IDENT(ident,identlen,p) \
-       identlen = ident_len(p); \
-       ident = (LPTSTR)alloca ( ( identlen + 1 ) * sizeof(TCHAR) ); \
-       memmove ( ident, p, identlen * sizeof(TCHAR) ); \
-       ident[identlen] = 0; \
-       p += identlen;
-
-static BOOL
-seta_identval ( LPCTSTR ident, INT* result )
-{
-       LPCTSTR identVal = GetEnvVarOrSpecial ( ident );
-       if ( !identVal )
-       {
-               /* TODO FIXME - what to do upon failure? */
-               *result = 0;
-               return FALSE;
-       }
-       *result = _ttoi ( identVal );
-       return TRUE;
-}
-
-static BOOL
-calc ( INT* lval, TCHAR op, INT rval )
-{
-       switch ( op )
-       {
-       case '*':
-               *lval *= rval;
-               break;
-       case '/':
-               *lval /= rval;
-               break;
-       case '%':
-               *lval %= rval;
-               break;
-       case '+':
-               *lval += rval;
-               break;
-       case '-':
-               *lval -= rval;
-               break;
-       case '&':
-               *lval &= rval;
-               break;
-       case '^':
-               *lval ^= rval;
-               break;
-       case '|':
-               *lval |= rval;
-               break;
-       default:
-               ConErrResPuts ( STRING_INVALID_OPERAND );
-               return FALSE;
-       }
-       return TRUE;
-}
-
-static BOOL
-seta_stmt ( LPCTSTR* p_, INT* result );
-
-static BOOL
-seta_unaryTerm ( LPCTSTR* p_, INT* result )
-{
-       LPCTSTR p = *p_;
-       if ( *p == _T('(') )
-       {
-               INT rval;
-               p = skip_ws ( p + 1 );
-               if ( !seta_stmt ( &p, &rval ) )
-                       return FALSE;
-               if ( *p != _T(')') )
-               {
-                       ConErrResPuts ( STRING_EXPECTED_CLOSE_PAREN );
-                       return FALSE;
-               }
-               *result = rval;
-               p = skip_ws ( p + 1 );
-       }
-       else if ( isdigit(*p) )
-       {
-               *result = _ttoi ( p );
-               p = skip_ws ( p + _tcsspn ( p, _T("1234567890") ) );
-       }
-       else if ( __iscsymf(*p) )
-       {
-               LPTSTR ident;
-               INT identlen;
-               PARSE_IDENT(ident,identlen,p);
-               if ( !seta_identval ( ident, result ) )
-                       return FALSE;
-       }
-       else
-       {
-               ConErrResPuts ( STRING_EXPECTED_NUMBER_OR_VARIABLE );
-               return FALSE;
-       }
-       *p_ = p;
-       return TRUE;
-}
-
-static BOOL
-seta_mulTerm ( LPCTSTR* p_, INT* result )
-{
-       LPCTSTR p = *p_;
-       TCHAR op = 0;
-       INT rval;
-       if ( _tcschr(_T("!~-"),*p) )
-       {
-               op = *p;
-               p = skip_ws ( p + 1 );
-       }
-       if ( !seta_unaryTerm ( &p, &rval ) )
-               return FALSE;
-       switch ( op )
-       {
-       case '!':
-               rval = !rval;
-               break;
-       case '~':
-               rval = ~rval;
-               break;
-       case '-':
-               rval = -rval;
-               break;
-       }
-
-       *result = rval;
-       *p_ = p;
-       return TRUE;
-}
-
-static BOOL
-seta_ltorTerm ( LPCTSTR* p_, INT* result, LPCTSTR ops, BOOL (*subTerm)(LPCTSTR*,INT*) )
-{
-       LPCTSTR p = *p_;
-       INT lval;
-       if ( !subTerm ( &p, &lval ) )
-               return FALSE;
-       while ( *p && _tcschr(ops,*p) )
-       {
-               INT rval;
-               TCHAR op = *p;
-
-               p = skip_ws ( p+1 );
-
-               if ( !subTerm ( &p, &rval ) )
-                       return FALSE;
-
-               if ( !calc ( &lval, op, rval ) )
-                       return FALSE;
-       }
-
-       *result = lval;
-       *p_ = p;
-       return TRUE;
-}
-
-static BOOL
-seta_addTerm ( LPCTSTR* p_, INT* result )
-{
-       return seta_ltorTerm ( p_, result, _T("*/%"), seta_mulTerm );
-}
-
-static BOOL
-seta_logShiftTerm ( LPCTSTR* p_, INT* result )
-{
-       return seta_ltorTerm ( p_, result, _T("+-"), seta_addTerm );
-}
-
-static BOOL
-seta_bitAndTerm ( LPCTSTR* p_, INT* result )
-{
-       LPCTSTR p = *p_;
-       INT lval;
-       if ( !seta_logShiftTerm ( &p, &lval ) )
-               return FALSE;
-       while ( *p && _tcschr(_T("<>"),*p) && p[0] == p[1] )
-       {
-               INT rval;
-               TCHAR op = *p;
-
-               p = skip_ws ( p+2 );
-
-               if ( !seta_logShiftTerm ( &p, &rval ) )
-                       return FALSE;
-
-               switch ( op )
-               {
-               case '<':
-                       lval <<= rval;
-                       break;
-               case '>':
-                       lval >>= rval;
-                       break;
-               default:
-                       ConErrResPuts ( STRING_INVALID_OPERAND );
-                       return FALSE;
-               }
-       }
-
-       *result = lval;
-       *p_ = p;
-       return TRUE;
-}
-
-static BOOL
-seta_bitExclOrTerm ( LPCTSTR* p_, INT* result )
-{
-       return seta_ltorTerm ( p_, result, _T("&"), seta_bitAndTerm );
-}
-
-static BOOL
-seta_bitOrTerm ( LPCTSTR* p_, INT* result )
-{
-       return seta_ltorTerm ( p_, result, _T("^"), seta_bitExclOrTerm );
-}
-
-static BOOL
-seta_expr ( LPCTSTR* p_, INT* result )
-{
-       return seta_ltorTerm ( p_, result, _T("|"), seta_bitOrTerm );
-}
-
-static BOOL
-seta_assignment ( LPCTSTR* p_, INT* result )
-{
-       LPCTSTR p = *p_;
-       LPTSTR ident;
-       TCHAR op = 0;
-       INT identlen, exprval;
-
-       PARSE_IDENT(ident,identlen,p);
-       if ( identlen )
-       {
-               if ( *p == _T('=') )
-                       op = *p, p = skip_ws(p+1);
-               else if ( _tcschr ( _T("*/%+-&^|"), *p ) && p[1] == _T('=') )
-                       op = *p, p = skip_ws(p+2);
-               else if ( _tcschr ( _T("<>"), *p ) && *p == p[1] && p[2] == _T('=') )
-                       op = *p, p = skip_ws(p+3);
-       }
-
-       /* allow to chain multiple assignments, such as: a=b=1 */
-       if ( ident && op )
-       {
-               INT identval;
-               LPTSTR buf;
-
-               if ( !seta_assignment ( &p, &exprval ) )
-                       return FALSE;
-
-               if ( !seta_identval ( ident, &identval ) )
-                       identval = 0;
-               switch ( op )
-               {
-               case '=':
-                       identval = exprval;
-                       break;
-               case '<':
-                       identval <<= exprval;
-                       break;
-               case '>':
-                       identval >>= exprval;
-                       break;
-               default:
-                       if ( !calc ( &identval, op, exprval ) )
-                               return FALSE;
-               }
-               buf = (LPTSTR)alloca ( 32 * sizeof(TCHAR) );
-               _sntprintf ( buf, 32, _T("%i"), identval );
-               SetEnvironmentVariable ( ident, buf ); // TODO FIXME - check return value
-               exprval = identval;
-       }
-       else
-       {
-               /* restore p in case we found an ident but not an op */
-               p = *p_;
-               if ( !seta_expr ( &p, &exprval ) )
-                       return FALSE;
-       }
-
-       *result = exprval;
-       *p_ = p;
-       return TRUE;
-}
-
-static BOOL
-seta_stmt ( LPCTSTR* p_, INT* result )
-{
-       LPCTSTR p = *p_;
-       INT rval;
-
-       if ( !seta_assignment ( &p, &rval ) )
-               return FALSE;
-       while ( *p == _T(',') )
-       {
-               p = skip_ws ( p+1 );
-
-               if ( !seta_assignment ( &p, &rval ) )
-                       return FALSE;
-       }
-
-       *result = rval;
-       *p_ = p;
-       return TRUE;
-}
-
-static BOOL
-seta_eval ( LPCTSTR p )
-{
-       INT rval;
-       if ( !*p )
-       {
-               ConErrResPuts ( STRING_SYNTAX_COMMAND_INCORRECT );
-               return FALSE;
-       }
-       if ( !seta_stmt ( &p, &rval ) )
-               return FALSE;
-       ConOutPrintf ( _T("%i"), rval );
-       return TRUE;
-}
-
-#endif
diff --git a/reactos/subsys/system/cmd/seta_test.cmd b/reactos/subsys/system/cmd/seta_test.cmd
deleted file mode 100644 (file)
index bb26e59..0000000
+++ /dev/null
@@ -1,116 +0,0 @@
-@echo off
-
-@rem the next line reexecutes the script without params if it was called with params, else we'll get false failures
-@if not "%1"=="" seta_test.cmd
-
-@rem the next two lines illustrate bug in existing if code
-if not "=="=="==" goto failure
-if "=="=="==" goto next1
-goto failure
-:next1
-if "1"=="2" goto failure
-if not "1"=="1" goto failure
-set /a a=1
-echo.
-if not "%a%"=="1" goto failure
-set /a b=a
-echo.
-if not "%b%"=="1" goto failure
-set /a a=!5
-echo.
-if not "%a%"=="0" goto failure
-set /a a=!a
-echo.
-if not "%a%"=="1" goto failure
-set /a a=~5
-echo.
-if not "%a%"=="-6" goto failure
-set /a a=5,a=-a
-echo.
-if not "%a%"=="-5" goto failure
-set /a a=5*7
-echo.
-if not "%a%"=="35" goto failure
-set /a a=2000/10
-echo.
-if not "%a%"=="200" goto failure
-set /a a=42%%9
-echo.
-if not "%a%"=="6" goto failure
-set /a a=5%2
-echo.
-if not "%a%"=="5" goto failure
-set /a a=42^%13
-echo.
-if not "%a%"=="423" goto failure
-set /a a=7+9
-echo.
-if not "%a%"=="16" goto failure
-set /a a=9-7
-echo.
-if not "%a%"=="2" goto failure
-set /a a=9^<^<2
-echo.
-if not "%a%"=="36" goto failure
-set /a a=36^>^>2
-echo.
-if not "%a%"=="9" goto failure
-set /a a=42^&9
-echo.
-if not "%a%"=="8" goto failure
-set /a a=32^9
-echo.
-if not "%a%"=="329" goto failure
-set /a a=32^^9
-echo.
-if not "%a%"=="41" goto failure
-set /a a=10^|22
-echo.
-if not "%a%"=="30" goto failure
-set /a a=2,a*=3
-echo.
-if not "%a%"=="6" goto failure
-set /a a=11,a/=2
-echo.
-if not "%a%"=="5" goto failure
-set /a a=42,a%%=9
-echo.
-if not "%a%"=="6" goto failure
-set /a a=7,a+=9
-echo.
-if not "%a%"=="16" goto failure
-set /a a=9,a-=7
-echo.
-if not "%a%"=="2" goto failure
-set /a a=42,a^&=9
-echo.
-if not "%a%"=="8" goto failure
-set /a a=32,a^^=9
-echo.
-if not "%a%"=="41" goto failure
-set /a a=10,a^|=22
-echo.
-if not "%a%"=="30" goto failure
-set /a a=9,a^<^<=2
-echo.
-if not "%a%"=="36" goto failure
-set /a a=36,a^>^>=2
-echo.
-if not "%a%"=="9" goto failure
-set /a a=1,2
-echo.
-if not "%a%"=="1" goto failure
-set /a a=(a=1,a+2)
-echo.
-if "%a%"=="3" goto success
-goto failure
-
-:success
-echo SUCCESS!
-echo.
-goto done
-
-:failure
-echo FAILURE! remove the echo off and see the last formula that executed before this line
-echo.
-:done
diff --git a/reactos/subsys/system/cmd/shift.c b/reactos/subsys/system/cmd/shift.c
deleted file mode 100644 (file)
index 82c1f39..0000000
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- *  SHIFT.C - shift internal batch command
- *
- *
- *  History:
- *
- *    16 Jul 1998 (Hans B Pufal)
- *        started.
- *
- *    16 Jul 1998 (John P Price)
- *        Separated commands into individual files.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    07-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("shift /?") and cleaned up.
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection safe!
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-
-/*
- *  Perform the SHIFT command.
- *
- * Only valid inside batch files.
- *
- * FREEDOS extension : optional parameter DOWN to allow shifting
- *   parameters backwards.
- *
- */
-
-INT cmd_shift (LPTSTR cmd, LPTSTR param)
-{
-
-#ifdef _DEBUG
-       DebugPrintf (_T("cmd_shift: (\'%s\', \'%s\')\n"), cmd, param);
-#endif
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_SHIFT_HELP);
-               return 0;
-       }
-
-       nErrorLevel = 0;
-
-       if (bc == NULL)
-       {
-               /* not in batch - error!! */
-               nErrorLevel = 1;
-               return 1;
-       }
-
-       if (!_tcsicmp (param, _T("down")))
-       {
-               if (bc->shiftlevel)
-                       bc->shiftlevel--;
-       }
-       else /* shift up */
-               bc->shiftlevel++;
-
-       return 0;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/start.c b/reactos/subsys/system/cmd/start.c
deleted file mode 100644 (file)
index 4899aa9..0000000
+++ /dev/null
@@ -1,279 +0,0 @@
-/*
- *  START.C - start internal command.
- *
- *
- *  History:
- *
- *    24-Jul-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Started.
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_START
-
-
-INT cmd_start (LPTSTR First, LPTSTR Rest)
-{
-       TCHAR szFullName[CMDLINE_LENGTH];
-       TCHAR first[CMDLINE_LENGTH];
-       TCHAR *rest = NULL; 
-       TCHAR *param = NULL;
-       INT size;
-       LPTSTR comspec;
-       BOOL bWait = FALSE;
-       BOOL bBat  = FALSE;
-       BOOL bCreate = FALSE;
-       TCHAR szFullCmdLine [CMDLINE_LENGTH];
-       PROCESS_INFORMATION prci;
-       STARTUPINFO stui;
-
-               
-       
-       if (_tcsncmp (Rest, _T("/?"), 2) == 0)
-       {
-               ConOutResPaging(TRUE,STRING_START_HELP1);
-               return 0;
-       }
-
-       /* get comspec */
-       comspec = malloc ( MAX_PATH * sizeof(TCHAR));
-       if (comspec == NULL)
-       {
-               error_out_of_memory();
-               return 1;
-       }
-       SetLastError(0);
-       size = GetEnvironmentVariable (_T("COMSPEC"), comspec, 512);
-       if(GetLastError() == ERROR_ENVVAR_NOT_FOUND)
-       {
-               Rest = _T("cmd");
-       }
-       else
-       {
-               if (size > MAX_PATH)
-               {
-                       comspec = realloc(comspec,size * sizeof(TCHAR) );
-                       if (comspec==NULL)
-                       {
-                               return 1;
-                       }
-                       size = GetEnvironmentVariable (_T("COMSPEC"), comspec, size);
-               }               
-       }
-
-       nErrorLevel = 0;
-
-       if( !*Rest )
-       {
-               _tcscpy(Rest,_T("\""));
-               _tcscat(Rest,comspec);
-               _tcscat(Rest,_T("\""));
-       }
-
-       rest = malloc ( _tcslen(Rest) + 1 * sizeof(TCHAR)); 
-       if (rest == NULL)
-       {
-        if(comspec != NULL)
-               free(comspec);
-        error_out_of_memory();
-        return 1;
-       }
-
-       param =malloc ( _tcslen(Rest) + 1 * sizeof(TCHAR)); 
-       if (rest == NULL)
-       {
-        if(comspec != NULL)
-               free(comspec);
-        free(rest);
-        error_out_of_memory();
-        return 1;
-       }
-
-       param[0] = _T('\0');
-
-
-       _tcscpy(rest,Rest);
-       
-       /* Parsing the command that gets called by start, and it's parameters */
-       if(!_tcschr(rest,_T('\"')))
-       {
-               INT i = 0;
-               INT count = _tcslen(rest);
-               
-               /* find the end of the command and start of the args */
-               for(i = 0; i < count; i++)
-               {
-                       if(rest[i] == _T(' '))
-                       {       
-                               
-                               _tcscpy(param,&rest[i]);
-                               rest[i] = _T('\0');
-                               break;
-                       }
-               }
-       }
-       else
-       {
-               INT i = 0;      
-               INT count = _tcslen(rest);              
-               BOOL bInside = FALSE;
-
-               /* find the end of the command and put the arguments in param */
-               for(i = 0; i < count; i++)
-               {
-                       if(rest[i] == _T('\"')) 
-                               bInside = !bInside;
-                       if((rest[i] == _T(' ')) && !bInside)
-                       {                                       
-                               _tcscpy(param,&rest[i]);
-                               rest[i] = _T('\0');
-                               break;
-                       }
-               }
-               i = 0;
-               /* remove any slashes */
-               while(i < count)
-               {
-                       if(rest[i] == _T('\"'))
-                               memmove(&rest[i],&rest[i + 1], _tcslen(&rest[i]) * sizeof(TCHAR));
-                       else
-                               i++;
-               }
-       }
-       
-       /* check for a drive change */
-       
-       if (!_tcscmp (first + 1, _T(":")) && _istalpha (*first))
-       {
-               TCHAR szPath[CMDLINE_LENGTH];
-
-               _tcscpy (szPath, _T("A:"));
-               szPath[0] = _totupper (*first);
-               SetCurrentDirectory (szPath);
-               GetCurrentDirectory (CMDLINE_LENGTH, szPath);
-               if (szPath[0] != (TCHAR)_totupper (*first))
-                       ConErrResPuts (STRING_FREE_ERROR1);
-
-               if (rest != NULL) 
-                   free(rest);
-
-           if (param != NULL) 
-                   free(param);
-                if (comspec != NULL)
-                        free(comspec);
-               return 0;
-       }
-       
-       /* get the PATH environment variable and parse it */
-       /* search the PATH environment variable for the binary */
-       if (!SearchForExecutable (rest, szFullName))
-       {
-               error_bad_command ();
-
-               if (rest != NULL) 
-                   free(rest);
-
-           if (param != NULL) 
-                   free(param);
-
-                if (comspec != NULL)
-                        free(comspec);
-               return 1;
-       }
-       
-
-       /* check if this is a .BAT or .CMD file */
-       if (!_tcsicmp (_tcsrchr (szFullName, _T('.')), _T(".bat")) ||
-           !_tcsicmp (_tcsrchr (szFullName, _T('.')), _T(".cmd")))
-       {
-               bBat = TRUE;                            
-               memset(szFullCmdLine,0,CMDLINE_LENGTH * sizeof(TCHAR));
-
-
-               _tcscpy(szFullCmdLine,comspec);
-
-               memcpy(&szFullCmdLine[_tcslen(szFullCmdLine)],_T("\" /K \""), 6 * sizeof(TCHAR));                               
-               memcpy(&szFullCmdLine[_tcslen(szFullCmdLine)], szFullName, _tcslen(szFullName) * sizeof(TCHAR));                
-               memcpy(&szFullCmdLine[1], &szFullCmdLine[0], _tcslen(szFullCmdLine) * sizeof(TCHAR)); 
-        szFullCmdLine[0] = _T('\"');                                   
-        szFullCmdLine[_tcslen(szFullCmdLine)] = _T('\"');
-       }
-
-#ifdef _DEBUG
-               DebugPrintf (_T("[BATCH: %s %s]\n"), szFullName, rest);
-#endif
-               
-
-#ifdef _DEBUG
-               DebugPrintf (_T("[EXEC: %s %s]\n"), szFullName, rest);
-#endif
-               /* build command line for CreateProcess() */
-               if (bBat == FALSE)
-               {
-                 _tcscpy (szFullCmdLine, first);
-                 if( param != NULL )
-                 {
-                        
-                   _tcscat(szFullCmdLine, _T(" ") );
-                   _tcscat (szFullCmdLine, param);
-                 }
-               }
-
-               /* fill startup info */
-               memset (&stui, 0, sizeof (STARTUPINFO));
-               stui.cb = sizeof (STARTUPINFO);
-               stui.dwFlags = STARTF_USESHOWWINDOW;
-               stui.wShowWindow = SW_SHOWDEFAULT;
-                       
-               if (bBat == TRUE)
-               {
-                bCreate = CreateProcess (NULL, szFullCmdLine, NULL, NULL, FALSE,
-                        CREATE_NEW_CONSOLE, NULL, NULL, &stui, &prci);
-               }
-               else
-               {
-                               bCreate = CreateProcess (szFullName, szFullCmdLine, NULL, NULL, FALSE,
-                                       CREATE_NEW_CONSOLE, NULL, NULL, &stui, &prci);
-               }
-               
-               if (bCreate)
-               {
-                       if (bWait)
-                       {
-                               DWORD dwExitCode;
-                               WaitForSingleObject (prci.hProcess, INFINITE);
-                               GetExitCodeProcess (prci.hProcess, &dwExitCode);
-                               nErrorLevel = (INT)dwExitCode;
-                       }
-                       CloseHandle (prci.hThread);
-                       CloseHandle (prci.hProcess);
-               /* Get New code page if it has change */
-               InputCodePage= GetConsoleCP();
-        OutputCodePage = GetConsoleOutputCP();
-               }
-               else
-               {
-                       ErrorMessage(GetLastError (),
-                                     _T("Error executing CreateProcess()!!\n"));
-               }
-
-
-       if (rest != NULL) 
-           free(rest);
-
-    if (param != NULL) 
-           free(param);
-
-        if (comspec != NULL)
-                free(comspec);
-       return 0;
-}
-
-#endif
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/strtoclr.c b/reactos/subsys/system/cmd/strtoclr.c
deleted file mode 100644 (file)
index b4601a5..0000000
+++ /dev/null
@@ -1,284 +0,0 @@
-/*
- *  STRTOCLR.C - read color (for color command and other)
- *
- *
- *  History:
- *
- *    07-Oct-1999 (Paolo Pantaleo)
- *        Started.
- *
- *
- */
-
-/*only
-BOOL StringToColor(LPWORD lpColor, LPTSTR*str)
-is to be called
-other are internal service functions*/
-
-
-#include <precomp.h>
-
-#define _B FOREGROUND_BLUE
-#define _G FOREGROUND_GREEN
-#define _R FOREGROUND_RED
-#define _I FOREGROUND_INTENSITY
-
-
-/*return values for chop_blank*/
-#define CP_OK                          0
-#define CP_BLANK_NOT_FOUND     1
-#define CP_END_OF_STRING       2
-
-#define SC_HEX 0x0100
-#define SC_TXT 0x0200
-
-
-
-typedef struct _CLRTABLE
-{
-       LPTSTR          name;
-       WORD            val;
-} CLRTABLE;
-
-
-CLRTABLE clrtable[] =
-{
-       {_T("bla")      ,0              },
-       {_T("blu")      ,_B             },
-       {_T("gre")      ,_G             },
-       {_T("cya")      ,_B|_G          },
-       {_T("red")      ,_R             },
-       {_T("mag")      ,_B|_R          },
-       {_T("yel")      ,_R|_G          },
-       {_T("whi")      ,_R|_G|_B       },
-       {_T("gra")      ,_I             },
-
-
-       {_T("0")        ,0              },
-       {_T("2")        ,_G             },
-       {_T("3")        ,_B|_G          },
-       {_T("4")        ,_R             },
-       {_T("5")        ,_B|_R          },
-       {_T("6")        ,_R|_G          },
-       {_T("7")        ,_R|_G|_B       },
-
-       {_T("8")        ,_I             },
-       {_T("9")        ,_I|_B          },
-       {_T("10")       ,_I|_G          },
-       {_T("11")       ,_I|_B|_G       },
-       {_T("12")       ,_I|_R          },
-       {_T("13")       ,_I|_B|_R       },
-       {_T("14")       ,_I|_R|_G       },
-       {_T("15")       ,_I|_R|_G|_B    },
-
-
-       /* note that 1 is at the end of list
-       to avoid to confuse it with 10-15*/
-       {_T("1")        ,_B             },
-
-       /*cyan synonimous*/
-       {_T("aqu")      ,_B|_G          },
-       /*magenta synonimous*/
-       {_T("pur")      ,_B|_R          },
-
-
-       {_T("")   ,0},
-};
-
-
-
-/*
-move string pointer to next word (skip all spaces)
-on erro retunr nonzero value
-*/
-static
-INT chop_blank(LPTSTR *arg_str)
-{
-
-       LPTSTR str;
-       str = _tcschr(*arg_str,_T(' '));
-       if(!str)
-       {
-               str = _tcschr (*arg_str, _T('\0'));
-               if(str != NULL)
-                       *arg_str=str;
-               return CP_BLANK_NOT_FOUND;
-       }
-
-
-
-       while(_istspace(*str))
-               str++;
-
-       if (*str == _T('\0'))
-       {
-               *arg_str=str;
-               return CP_END_OF_STRING;
-       }
-
-       *arg_str = str;
-
-       return CP_OK;
-}
-
-
-
-/*
-read a color value in hex (like win nt's cmd syntax)
-if an error occurs return -1
-*/
-static
-WORD hex_clr(LPTSTR str)
-{
-       WORD ret= (WORD)-1;
-       TCHAR ch;
-
-       ch = str[1];
-
-       if(_istdigit(ch))
-               ret = ch-_T('0');
-       else
-       {
-               ch=_totupper(ch);
-
-               if(  ch >= _T('A') && ch <= _T('F')  )
-                       ret = ch-_T('A')+10;
-               else
-                       return (WORD)-1;
-       }
-
-
-       ch = str[0];
-
-       if(_istdigit(ch))
-               ret |= (ch-_T('0')) << 4;
-       else
-       {
-               ch=_totupper(ch);
-
-               if(  ch >= _T('A') && ch <= _T('F')  )
-                       ret |= (ch-_T('A')+10) <<4;
-               else
-                       return (WORD)-1;
-       }
-
-       return ret;
-}
-
-
-/*
-read a color value from a string (like 4nt's syntax)
-if an error occurs return -1
-*/
-static
-WORD txt_clr(LPTSTR str)
-{
-       INT i;
-
-       for(i = 0; *(clrtable[i].name); i++)
-               if (_tcsnicmp(str, clrtable[i].name, _tcslen(clrtable[i].name)) == 0)
-                       return clrtable[i].val;
-
-       return (WORD)-1;
-}
-
-
-
-/*search for x on y*/
-static
-WORD str_to_color(LPTSTR* arg_str)
-{
-       LPTSTR str;
-       BOOL bBri;
-
-       WORD tmp_clr,ret_clr;
-
-       str = *arg_str;
-
-       if (!(*str))
-               return (WORD)-1;
-
-
-       /*foreground*/
-       bBri = FALSE;
-
-       if (_tcsnicmp(str,_T("bri"),3) == 0)
-       {
-               bBri = TRUE;
-
-               if (chop_blank(&str))
-                       return (WORD)-1;
-       }
-
-       if ((tmp_clr = txt_clr(str)) == (WORD)-1)
-       {
-               return (WORD)-1;
-       }
-
-       /*skip spaces and "on"*/
-       if (chop_blank(&str) || chop_blank(&str))
-               return (WORD)-1;
-
-       ret_clr = tmp_clr | (bBri << 3);
-
-       /*background*/
-       bBri = FALSE;
-
-       if(_tcsnicmp(str,_T("bri"),3) == 0 )
-       {
-               bBri = TRUE;
-
-               if(chop_blank(&str))
-                       return (WORD)-1;
-       }
-
-
-       if( (tmp_clr = txt_clr(str)) == (WORD)-1 )
-               return (WORD)-1;
-
-       chop_blank(&str);
-
-       *arg_str = str;
-
-       return SC_HEX | ret_clr | tmp_clr << 4 | bBri << 7;
-}
-
-
-
-/****main function****/
-/*
-the only parameter is arg_str, a pointer to a string.
-the string is modified so it will begin to first word after
-color specification
-(only the char* is moved, no chars in the string are modfied)
-
-
-it returns the color in the l.o. byte, plus two flags in the
-h.o. byte, they are:
-SC_HEX win nt's cmd syntax (for exampl a0)
-SC_TXT 4nt's syntax ( "bri gre on bla" or "10 on 0")
-
-if succedes also move the LPTSTR to end of
-string that specify color
-*/
-
-
-BOOL StringToColor(LPWORD lpColor, LPTSTR*str)
-{
-       WORD wRet;
-
-       wRet = str_to_color (str);
-       if (wRet == (WORD)-1)
-       {
-               wRet=hex_clr (*str);
-               chop_blank (str);
-               if (wRet == (WORD)-1)
-                       return FALSE;
-       }
-
-       *lpColor = wRet;
-
-       return TRUE;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/tests/cmd_test.xml b/reactos/subsys/system/cmd/tests/cmd_test.xml
deleted file mode 100644 (file)
index 13a4201..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-<module name="cmd_test" type="test">
-       <include base="rtshared">.</include>
-       <include base="ReactOS">include/wine</include>
-       <include base="cmd">.</include>
-       <define name="__USE_W32API" />
-       <define name="ANONYMOUSUNIONS" />
-       <define name="_WIN32_WINNT">0x0501</define>
-       <library>rtshared</library>
-       <library>regtests</library>
-       <library>cmd_base</library>
-       <library>pseh</library>
-       <library>ntdll</library>
-       <file>setup.c</file>
-       <xi:include href="stubs.xml" />
-</module>
diff --git a/reactos/subsys/system/cmd/tests/setup.c b/reactos/subsys/system/cmd/tests/setup.c
deleted file mode 100644 (file)
index 66e28a8..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * Copyright (C) 2005 Casper S. Hornstrup
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- */
-#include <windows.h>
-#include "regtests.h"
-
-_SetupOnce()
-{
-}
diff --git a/reactos/subsys/system/cmd/tests/stubs.xml b/reactos/subsys/system/cmd/tests/stubs.xml
deleted file mode 100644 (file)
index 1c964b3..0000000
+++ /dev/null
@@ -1,84 +0,0 @@
-<component name="kernel32.dll">
-       <symbol>FindFirstFileA@8</symbol>
-       <symbol>GetLastError@0</symbol>
-       <symbol>FindNextFileA@8</symbol>
-       <symbol>FindClose@4</symbol>
-       <symbol>GetFileAttributesA@4</symbol>
-       <symbol>GetCurrentDirectoryA@8</symbol>
-       <symbol>GetFullPathNameA@16</symbol>
-       <symbol>CloseHandle@4</symbol>
-       <symbol>CreateFileA@28</symbol>
-       <symbol>Beep@8</symbol>
-       <symbol>LoadStringA@16</symbol>
-       <symbol>SetConsoleCP@4</symbol>
-       <symbol>SetConsoleOutputCP@4</symbol>
-       <symbol>WaitForSingleObject@8</symbol>
-       <symbol>ReadConsoleInputA@16</symbol>
-       <symbol>GetTickCount@0</symbol>
-       <symbol>GetConsoleScreenBufferInfo@8</symbol>
-       <symbol>FillConsoleOutputAttribute@20</symbol>
-       <symbol>FillConsoleOutputCharacterA@20</symbol>
-       <symbol>SetConsoleCursorPosition@8</symbol>
-       <symbol>LoadLibraryA@4</symbol>
-       <symbol>GetProcAddress@8</symbol>
-       <symbol>SetCurrentDirectoryA@4</symbol>
-       <symbol>SetConsoleMode@8</symbol>
-       <symbol>CreateProcessA@40</symbol>
-       <symbol>GetExitCodeProcess@8</symbol>
-       <symbol>GetConsoleOutputCP@0</symbol>
-       <symbol>GetTempPathA@8</symbol>
-       <symbol>GetTempFileNameA@16</symbol>
-       <symbol>GetCurrentProcess@0</symbol>
-       <symbol>DuplicateHandle@28</symbol>
-       <symbol>GetFileType@4</symbol>
-       <symbol>SetFilePointer@16</symbol>
-       <symbol>GetTimeFormatA@24</symbol>
-       <symbol>GetDateFormatA@24</symbol>
-       <symbol>GetEnvironmentVariableA@12</symbol>
-       <symbol>GenerateConsoleCtrlEvent@8</symbol>
-       <symbol>SetConsoleCtrlHandler@8</symbol>
-       <symbol>GetVersionExA@4</symbol>
-       <symbol>ExitProcess@4</symbol>
-       <symbol>GetModuleFileNameA@12</symbol>
-       <symbol>SetEnvironmentVariableA@8</symbol>
-       <symbol>SetConsoleTextAttribute@8</symbol>
-       <symbol>FlushConsoleInputBuffer@4</symbol>
-       <symbol>WriteFile@20</symbol>
-       <symbol>FormatMessageA@28</symbol>
-       <symbol>LocalFree@4</symbol>
-       <symbol>GetConsoleCP@0</symbol>
-       <symbol>GetStdHandle@4</symbol>
-       <symbol>FreeLibrary@4</symbol>
-       <symbol>SetLastError@4</symbol>
-       <symbol>SetStdHandle@8</symbol>
-       <symbol>DeleteFileA@4</symbol>
-       <symbol>FileTimeToLocalFileTime@8</symbol>
-       <symbol>GetVolumeInformationA@32</symbol>
-       <symbol>RemoveDirectoryA@4</symbol>
-       <symbol>CreateDirectoryA@8</symbol>
-       <symbol>GetLocaleInfoA@16</symbol>
-       <symbol>GlobalMemoryStatus@4</symbol>
-       <symbol>GetEnvironmentStrings@0</symbol>
-       <symbol>FreeEnvironmentStringsA@4</symbol>
-       <symbol>LocalFree</symbol>
-       <symbol>SetLocalTime@4</symbol>
-       <symbol>GetLocalTime@4</symbol>
-       <symbol>SetFileAttributesA@8</symbol>
-       <symbol>SetFileApisToOEM@0</symbol>
-       <symbol>GetConsoleMode@8</symbol>
-       <symbol>SetConsoleCursorInfo@8</symbol>
-       <symbol>ReadFile@20</symbol>
-       <symbol>SetFileTime@16</symbol>
-       <symbol>FileTimeToSystemTime@8</symbol>
-       <symbol>GetDiskFreeSpaceA@20</symbol>
-       <symbol>SetVolumeLabelA@8</symbol>
-       <symbol>SetConsoleTitleA@4</symbol>
-       <symbol>MoveFileExA@12</symbol>
-       <symbol>GetFileTime@16</symbol>
-       <symbol>Sleep@4</symbol>
-       <symbol>MoveFileA@8</symbol>
-       <symbol>CreateSemaphoreA@16</symbol>
-       <symbol>InterlockedIncrement@4</symbol>
-       <symbol>InterlockedDecrement@4</symbol>
-       <symbol>ReleaseSemaphore@12</symbol>
-</component>
diff --git a/reactos/subsys/system/cmd/time.c b/reactos/subsys/system/cmd/time.c
deleted file mode 100644 (file)
index 13ef34b..0000000
+++ /dev/null
@@ -1,215 +0,0 @@
-/*
- *  TIME.C - time internal command.
- *
- *
- *  History:
- *
- *    07/08/1998 (John P. Price)
- *        started.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    09-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added locale support.
- *
- *    19-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection safe!
- *        Added "/t" option.
- *
- *    04-Feb-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Fixed time input bug.
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc.
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_TIME
-
-
-static BOOL ParseTime (LPTSTR s)
-{
-       SYSTEMTIME t;
-       LPTSTR p = s;
-
-       if (!*s)
-               return TRUE;
-
-       GetLocalTime (&t);
-       t.wHour = 0;
-       t.wMinute = 0;
-       t.wSecond = 0;
-       t.wMilliseconds = 0;
-
-       // first get hour
-       if (_istdigit(*p))
-       {
-               while (_istdigit(*p))
-               {
-                       t.wHour = t.wHour * 10 + *p - _T('0');
-                       p++;
-               }
-       }
-       else
-               return FALSE;
-
-       // get time separator
-       if (*p != cTimeSeparator)
-               return FALSE;
-       p++;
-
-       // now get minutes
-       if (_istdigit(*p))
-       {
-               while (_istdigit(*p))
-               {
-                       t.wMinute = t.wMinute * 10 + *p - _T('0');
-                       p++;
-               }
-       }
-       else
-               return FALSE;
-
-       // get time separator
-       if (*p != cTimeSeparator)
-               return FALSE;
-       p++;
-
-       // now get seconds
-       if (_istdigit(*p))
-       {
-               while (_istdigit(*p))
-               {
-                       t.wSecond = t.wSecond * 10 + *p - _T('0');
-                       p++;
-               }
-       }
-       else
-               return FALSE;
-
-       // get decimal separator
-       if (*p == cDecimalSeparator)
-       {
-               p++;
-
-               // now get hundreths
-               if (_istdigit(*p))
-               {
-                       while (_istdigit(*p))
-                       {
-//                             t.wMilliseconds = t.wMilliseconds * 10 + *p - _T('0');
-                               p++;
-                       }
-//                     t.wMilliseconds *= 10;
-               }
-       }
-
-       /* special case: 12 hour format */
-       if (nTimeFormat == 0)
-       {
-               if (_totupper(*s) == _T('P'))
-               {
-                       t.wHour += 12;
-               }
-
-               if ((_totupper(*s) == _T('A')) && (t.wHour == 12))
-               {
-                       t.wHour = 0;
-               }
-       }
-
-       if (t.wHour > 23 || t.wMinute > 60 || t.wSecond > 60 || t.wMilliseconds > 999)
-               return FALSE;
-
-       SetLocalTime (&t);
-
-       return TRUE;
-}
-
-
-INT cmd_time (LPTSTR cmd, LPTSTR param)
-{
-       LPTSTR *arg;
-       INT    argc;
-       INT    i;
-       BOOL   bPrompt = TRUE;
-       INT    nTimeString = -1;
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_TIME_HELP1);
-               return 0;
-       }
-
-  nErrorLevel = 0;
-
-       /* build parameter array */
-       arg = split (param, &argc, FALSE);
-
-       /* check for options */
-       for (i = 0; i < argc; i++)
-       {
-               if (_tcsicmp (arg[i], _T("/t")) == 0)
-                       bPrompt = FALSE;
-
-               if ((*arg[i] != _T('/')) && (nTimeString == -1))
-                       nTimeString = i;
-       }
-
-       if (nTimeString == -1)
-               PrintTime ();
-
-       if (!bPrompt)
-       {
-               freep (arg);
-               return 0;
-       }
-
-       while (1)
-       {
-               if (nTimeString == -1)
-               {
-                       TCHAR  s[40];
-
-                       ConOutResPuts(STRING_TIME_HELP2);
-
-                       ConInString (s, 40);
-
-#ifdef _DEBUG
-                       DebugPrintf (_T("\'%s\'\n"), s);
-#endif
-
-                       while (*s && s[_tcslen (s) - 1] < _T(' '))
-                               s[_tcslen(s) - 1] = _T('\0');
-
-                       if (ParseTime (s))
-                       {
-                               freep (arg);
-                               return 0;
-                       }
-               }
-               else
-               {
-                       if (ParseTime (arg[nTimeString]))
-                       {
-                               freep (arg);
-                               return 0;
-                       }
-
-                       /* force input the next time around. */
-                       nTimeString = -1;
-               }
-
-               ConErrResPuts(STRING_TIME_ERROR1);
-    nErrorLevel = 1;
-       }
-
-       freep (arg);
-
-       return 0;
-}
-
-#endif
diff --git a/reactos/subsys/system/cmd/timer.c b/reactos/subsys/system/cmd/timer.c
deleted file mode 100644 (file)
index 34567da..0000000
+++ /dev/null
@@ -1,233 +0,0 @@
-/*
- * TIMER.C - timer internal command.
- *
- * clone from 4nt timer command
- *
- * 20 Aug 1999
- *     started - Paolo Pantaleo <paolopan@freemail.it>
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_TIMER
-
-
-#define NCS_NOT_SPECIFIED -1
-#define NCS_ON 1
-#define NCS_OFF 0
-
-
-
-
-
-//print timer value
-#define PT(format) PrintElapsedTime(GetTickCount()-cT,format)
-
-
-//current timer Time (at wich started to count)
-#define cT clksT[clk_n]
-
-//current timer status
-#define cS clksS[clk_n]
-
-
-static VOID
-PrintElapsedTime (DWORD time,INT format)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       DWORD h,m,s,ms;
-
-#ifdef _DEBUG
-       DebugPrintf(_T("PrintTime(%d,%d)"),time,format);
-#endif
-
-       switch (format)
-       {
-       case 0:
-               LoadString(CMD_ModuleHandle, STRING_TIMER_HELP1, szMsg, RC_STRING_MAX_SIZE);
-               ConOutPrintf(szMsg, time);
-               break;
-
-       case 1:
-               ms = time % 1000;
-               time /= 1000;
-               s = time % 60;
-               time /=60;
-               m = time % 60;
-               h = time / 60;
-               LoadString( CMD_ModuleHandle, STRING_TIMER_HELP2, szMsg, RC_STRING_MAX_SIZE);
-               ConOutPrintf(szMsg,
-                            h, cTimeSeparator,
-                            m, cTimeSeparator,
-                            s, cDecimalSeparator, ms/10);
-               break;
-       }
-}
-
-
-INT CommandTimer (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-
-       // all timers are kept
-       static DWORD clksT[10];
-
-       // timers status
-       // set all the clocks off by default
-       static BOOL clksS[10]={FALSE,FALSE,FALSE,FALSE,
-               FALSE,FALSE,FALSE,FALSE,FALSE,FALSE};
-
-       // TRUE if /S in command line
-       BOOL bS = FALSE;
-
-       // avoid to set clk_n more than once
-       BOOL bCanNSet = TRUE;
-
-       INT NewClkStatus = NCS_NOT_SPECIFIED;
-
-       // the clock number specified on the command line
-       // 1 by default
-       INT clk_n=1;
-
-       // output format
-       INT iFormat=1;
-
-
-       // command line parsing variables
-       INT argc;
-       LPTSTR *p;
-
-       INT i;
-
-       if (_tcsncmp (param, _T("/?"), 2) == 0)
-       {
-               LoadString(CMD_ModuleHandle, STRING_TIMER_HELP3, szMsg, RC_STRING_MAX_SIZE);
-               ConOutPrintf(szMsg, cTimeSeparator, cTimeSeparator, cDecimalSeparator);
-               return 0;
-       }
-
-       nErrorLevel = 0;
-
-       LoadString( CMD_ModuleHandle, STRING_TIMER_TIME, szMsg, RC_STRING_MAX_SIZE);
-
-       p = split (param, &argc, FALSE);
-
-       //read options
-       for (i = 0; i < argc; i++)
-       {
-               //set timer on
-               if (!(_tcsicmp(&p[i][0],_T("on")))  && NewClkStatus == NCS_NOT_SPECIFIED)
-               {
-                       NewClkStatus = NCS_ON;
-                       continue;
-               }
-
-               //set timer off
-               if (!(_tcsicmp(&p[i][0],_T("off"))) && NewClkStatus == NCS_NOT_SPECIFIED)
-               {
-                       NewClkStatus = NCS_OFF;
-                       continue;
-               }
-
-               // other options
-               if (p[i][0] == _T('/'))
-               {
-                       // set timer number
-                       if (_istdigit(p[i][1]) && bCanNSet)
-                       {
-                               clk_n = p[i][1] - _T('0');
-                               bCanNSet = FALSE;
-                               continue;
-                       }
-
-                       // set s(plit) option
-                       if (_totupper(p[i][1]) == _T('S'))
-                       {
-                               bS = TRUE;
-                               continue;
-                       }
-
-                       // specify format
-                       if (_totupper(p[i][1]) == _T('F'))
-                       {
-                               iFormat = p[i][2] - _T('0');
-                               continue;
-                       }
-               }
-       }
-
-       // do stuff (start/stop/read timer)
-       if(NewClkStatus == NCS_ON)
-       {
-               cT=GetTickCount();
-               cS=TRUE;
-                   
-        ConOutPrintf (szMsg,clk_n,cS?_T("ON"):_T("OFF"));
-        PrintTime();
-               freep(p);
-               return 0;
-       }
-
-       if(bS)
-       {
-               if(cS)
-               {                       
-            ConOutPrintf (szMsg,clk_n,cS?_T("ON"):_T("OFF"));
-            PrintTime();
-                       PrintElapsedTime(GetTickCount()-cT, iFormat);
-                       freep(p);
-                       return 0;
-               }
-
-               cT=GetTickCount();
-               cS=TRUE;
-               ConOutPrintf (szMsg,clk_n,cS?_T("ON"):_T("OFF"));
-        PrintTime();
-               freep(p);
-               return 0;
-       }
-
-       if (NewClkStatus == NCS_NOT_SPECIFIED)
-       {
-               if (cS)
-               {
-                       cS=FALSE;
-                       ConOutPrintf (szMsg,clk_n,cS?_T("ON"):_T("OFF"));
-            PrintTime();
-                       PrintElapsedTime(GetTickCount()-cT, iFormat);
-                       freep(p);
-                       return 0;
-               }
-
-               cT=GetTickCount();
-               cS=TRUE;
-               ConOutPrintf (szMsg,clk_n,cS?_T("ON"):_T("OFF"));
-        PrintTime();
-               freep(p);
-               return 0;
-       }
-
-
-       if (NewClkStatus == NCS_OFF)
-       {
-               if (cS)
-               {
-                       cS=FALSE;
-                       ConOutPrintf (szMsg,clk_n,cS?_T("ON"):_T("OFF"));
-            PrintTime();
-                       PrintElapsedTime(GetTickCount()-cT, iFormat);
-                       freep(p);
-                       return 0;
-               }
-               ConOutPrintf (szMsg,clk_n,cS?_T("ON"):_T("OFF"));
-        PrintTime();
-               freep(p);
-               return 0;
-       }
-
-       freep(p);
-       return 0;
-}
-
-#endif /* INCLUDE_CMD_TIMER */
diff --git a/reactos/subsys/system/cmd/title.c b/reactos/subsys/system/cmd/title.c
deleted file mode 100644 (file)
index a82bb3c..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- *  title.c - title internal command.
- *
- *
- *  History:
- *     1999-02-11 Emanuele Aliberti
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_TITLE
-
-
-INT cmd_title (LPTSTR cmd, LPTSTR param)
-{
-
-       /* Do nothing if no args */
-       if (*param == _T('\0'))
-               return 0;
-
-       /* Asking help? */
-       if (!_tcsncmp(param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_TITLE_HELP);
-               return 0;
-       }
-
-       return SetConsoleTitle (param);
-}
-
-#endif /* def INCLUDE_CMD_TITLE */
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/todo.txt b/reactos/subsys/system/cmd/todo.txt
deleted file mode 100644 (file)
index b9895bd..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-Things to do
-~~~~~~~~~~~~
-*Implmenet Set /P
-This is pretty straight forward.  When doing this make sure to take into account the way MS handles "set /A /P foo=5" compared to "set /P /A foo=5".  
-
-*Compile as unicode
-Not sure what is wrong with it, put probably more then just one thing blocking this.  For sure pipes break when it is compiled as unicode.
-
-*Move.c code clean up
-It works, but it needs to be cleaned up, the code is long and overly complex for what it needs to do.  Also, we can remove the hack to cover for MoveFileEx bug as it isnt a bug anymore.
-
-*If rewrite
-It works decent but looks _awful_.  Very hard to maintain and/or understand what the hell is going on.
-
-*Remove Hardcoded buffers
-This is mostly done thanks to Greatlord(cmd.c is the hardest spot that is left).  ANytime when you are handling a string that is taken from the commandline there should be no limit to the size.
-
-*Implment & and &&
-& runs two commands no matter what.
-&& runs the 2nd command only if the first was a success
-Not sure where to put this code even
-
-*Reg Testing
-We need more batch files like the one Royce made for "set /a".  What out for if bugs when doing this... could lead to in the wrong direction when looking for a regression.
\ No newline at end of file
diff --git a/reactos/subsys/system/cmd/type.c b/reactos/subsys/system/cmd/type.c
deleted file mode 100644 (file)
index f0eca0f..0000000
+++ /dev/null
@@ -1,136 +0,0 @@
-/*
- *  TYPE.C - type internal command.
- *
- *  History:
- *
- *    07/08/1998 (John P. Price)
- *        started.
- *
- *    07/12/98 (Rob Lake)
- *        Changed error messages
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    07-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added support for quoted arguments (type "test file.dat").
- *        Cleaned up.
- *
- *    19-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection ready!
- *
- *    19-Jan-1999 (Paolo Pantaleo <paolopan@freemail.it>)
- *        Added multiple file support (copied from y.c)
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_TYPE
-
-
-INT cmd_type (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       TCHAR  buff[256];
-       HANDLE hFile, hConsoleOut;
-       BOOL   bRet;
-       INT    argc,i;
-       LPTSTR *argv;
-       LPTSTR errmsg;
-       BOOL bPaging = FALSE;
-       BOOL bFirstTime = TRUE;
-
-       hConsoleOut=GetStdHandle (STD_OUTPUT_HANDLE);
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_TYPE_HELP1);
-               return 0;
-       }       
-
-       if (!*param)
-       {
-               error_req_param_missing ();
-               return 1;
-       }
-
-       argv = split (param, &argc, TRUE);
-
-       for(i = 0; i < argc; i++)
-       {
-               if(*argv[i] == _T('/') && _tcslen(argv[i]) >= 2 && _totupper(argv[i][1]) == _T('P'))
-               {
-                       bPaging = TRUE;
-               }
-       }
-
-       for (i = 0; i < argc; i++)
-       {
-               if (_T('/') == argv[i][0] && _totupper(argv[i][1]) != _T('P'))
-               {
-                       LoadString(CMD_ModuleHandle, STRING_TYPE_ERROR1, szMsg, RC_STRING_MAX_SIZE);
-                       ConErrPrintf(szMsg, argv[i] + 1);
-                       continue;
-               }
-
-       nErrorLevel = 0;
-
-               hFile = CreateFile(argv[i],
-                       GENERIC_READ,
-                       FILE_SHARE_READ,NULL,
-                       OPEN_EXISTING,
-                       FILE_ATTRIBUTE_NORMAL,NULL);
-
-               if(hFile == INVALID_HANDLE_VALUE)
-               {
-                       FormatMessage (FORMAT_MESSAGE_ALLOCATE_BUFFER |
-                                      FORMAT_MESSAGE_IGNORE_INSERTS |
-                                      FORMAT_MESSAGE_FROM_SYSTEM,
-                                      NULL,
-                                      GetLastError(),
-                                      MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
-                                      (LPTSTR) &errmsg,
-                                      0,
-                                      NULL);
-                       ConErrPrintf (_T("%s - %s"), argv[i], errmsg);
-                       LocalFree (errmsg);
-      nErrorLevel = 1;
-                       continue;
-               }
-               
-               do
-               {
-                        bRet = FileGetString (hFile, buff, sizeof(buff) / sizeof(TCHAR));
-                       if(bPaging)
-                       {
-                               if(bRet)
-                               {
-                                       if (ConOutPrintfPaging(bFirstTime, buff) == 1)
-                                       {
-                                               bCtrlBreak = FALSE;
-                                               return 0;
-                                       }
-                               }
-                       }
-                       else
-                       {                               
-                               if(bRet)
-                                       ConOutPrintf(buff);
-                       }
-                       bFirstTime = FALSE;
-
-               } while(bRet);
-
-               CloseHandle(hFile);
-       }
-
-       freep (argv);
-
-       return 0;
-}
-
-#endif
diff --git a/reactos/subsys/system/cmd/ver.c b/reactos/subsys/system/cmd/ver.c
deleted file mode 100644 (file)
index 3216f7a..0000000
+++ /dev/null
@@ -1,135 +0,0 @@
-/*
- *  VER.C - ver internal command.
- *
- *
- *  History:
- *
- *    06/30/98 (Rob Lake)
- *        rewrote ver command to accept switches, now ver alone prints
- *        copyright notice only.
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    30-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added text about where to send bug reports and get updates.
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection safe!
- *
- *    26-Feb-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        New version info and some output changes.
- */
-
-#include <precomp.h>
-#include "resource.h"
-#include <reactos/resource.h>
-
-
-VOID ShortVersion (VOID)
-{
-       OSVERSIONINFO VersionInfo;
-       unsigned RosVersionLen;
-       LPTSTR RosVersion;
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       
-       ConOutResPuts (STRING_CMD_SHELLINFO );
-       VersionInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
-
-       ConOutPrintf(_T("Version %s %s"), _T(KERNEL_RELEASE_STR), _T(KERNEL_VERSION_BUILD_STR));
-
-       memset(VersionInfo.szCSDVersion, 0, sizeof(VersionInfo.szCSDVersion));
-       if (GetVersionEx(&VersionInfo))
-       {
-               RosVersion = VersionInfo.szCSDVersion + _tcslen(VersionInfo.szCSDVersion) + 1;
-               RosVersionLen = sizeof(VersionInfo.szCSDVersion) / sizeof(VersionInfo.szCSDVersion[0]) -
-                               (RosVersion - VersionInfo.szCSDVersion);
-               if (7 <= RosVersionLen && 0 == _tcsnicmp(RosVersion, _T("ReactOS"), 7))
-               {
-                       LoadString( CMD_ModuleHandle, STRING_VERSION_RUNVER, (LPTSTR) szMsg, RC_STRING_MAX_SIZE);
-                       ConOutPrintf (szMsg, RosVersion);
-               }
-       }
-       ConOutPuts (_T("\n"));
-}
-
-
-#ifdef INCLUDE_CMD_VER
-
-/*
- *  display shell version info internal command.
- *
- *
- */
-INT cmd_ver (LPTSTR cmd, LPTSTR param)
-{
-       INT i;
-
-  nErrorLevel = 0;
-
-       if (_tcsstr (param, _T("/?")) != NULL)
-       {
-               ConOutResPaging(TRUE,STRING_VERSION_HELP1);
-               return 0;
-       }
-
-       ShortVersion();
-       ConOutPuts (_T("Copyright (C) 1994-1998 Tim Norman and others."));
-       ConOutPuts (_T(RES_STR_LEGAL_COPYRIGHT));
-
-       /* Basic copyright notice */
-       if (param[0] == _T('\0'))
-       {
-               ConOutResPuts (STRING_CMD_SHELLINFO );
-               ConOutResPuts(STRING_VERSION_HELP2);
-       }
-       else
-       {
-               for (i = 0; param[i]; i++)
-               {
-                       /* skip spaces */
-                       if (param[i] == _T(' '))
-                               continue;
-
-                       if (param[i] == _T('/'))
-                       {
-                               /* is this a lone '/' ? */
-                               if (param[i + 1] == 0)
-                               {
-                                       error_invalid_switch (_T(' '));
-                                       return 1;
-                               }
-                               continue;
-                       }
-
-                       if (_totupper (param[i]) == _T('W'))
-                       {
-                               /* Warranty notice */
-                               ConOutResPuts(STRING_VERSION_HELP3);
-                       }
-                       else if (_totupper (param[i]) == _T('R'))
-                       {
-                               /* Redistribution notice */
-                               ConOutResPuts(STRING_VERSION_HELP4);
-                       }
-                       else if (_totupper (param[i]) == _T('C'))
-                       {
-                               /* Developer listing */
-                               ConOutResPuts(STRING_VERSION_HELP6);
-                               ConOutResPuts(STRING_FREEDOS_DEV);
-                               ConOutResPuts(STRING_VERSION_HELP7);
-                ConOutResPuts(STRING_REACTOS_DEV);
-                       }
-                       else
-                       {
-                               error_invalid_switch ((TCHAR)_totupper (param[i]));
-                               return 1;
-                       }
-               }
-       }
-
-       ConOutResPuts(STRING_VERSION_HELP5);
-       return 0;
-}
-
-#endif
diff --git a/reactos/subsys/system/cmd/verify.c b/reactos/subsys/system/cmd/verify.c
deleted file mode 100644 (file)
index 371993d..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- *  VERIFY.C - verify internal command.
- *
- *
- *  History:
- *
- *    31 Jul 1998 (John P Price)
- *        started.
- *
- *    18-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        VERIFY is just a dummy under Win32; it only exists
- *        for compatibility!!!
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode and redirection ready!
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_VERIFY
-
-
-/* global verify flag */
-static BOOL bVerify = FALSE;
-
-
-INT cmd_verify (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_VERIFY_HELP1);
-               return 0;
-       }
-
-  nErrorLevel = 0;
-
-       if (!*param)
-       {
-               LoadString(CMD_ModuleHandle, STRING_VERIFY_HELP2, szMsg, RC_STRING_MAX_SIZE);
-               ConOutPrintf(szMsg, bVerify ? D_ON : D_OFF);
-       }
-       else if (_tcsicmp (param, D_OFF) == 0)
-               bVerify = FALSE;
-       else if (_tcsicmp (param, D_ON) == 0)
-               bVerify = TRUE;
-       else
-       {
-               ConOutResPuts(STRING_VERIFY_HELP3);
-       }
-
-       return 0;
-}
-
-#endif
diff --git a/reactos/subsys/system/cmd/vol.c b/reactos/subsys/system/cmd/vol.c
deleted file mode 100644 (file)
index ac8a11a..0000000
+++ /dev/null
@@ -1,117 +0,0 @@
-/*
- *  VOL.C - vol internal command.
- *
- *
- *  History:
- *
- *    03-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Replaced DOS calls by Win32 calls.
- *
- *    08-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added help text ("/?").
- *
- *    07-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Cleanup.
- *
- *    18-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Unicode ready!
- *
- *    20-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Redirection ready!
- */
-
-#include <precomp.h>
-#include "resource.h"
-
-#ifdef INCLUDE_CMD_VOL
-
-
-static INT
-PrintVolumeHeader (LPTSTR pszRootPath)
-{
-       TCHAR szMsg[RC_STRING_MAX_SIZE];
-       TCHAR szVolName[80];
-       DWORD dwSerialNr;
-
-       /* get the volume information of the drive */
-       if(!GetVolumeInformation (pszRootPath,
-                                 szVolName,
-                                 80,
-                                 &dwSerialNr,
-                                 NULL,
-                                 NULL,
-                                 NULL,
-                                 0))
-       {
-               ErrorMessage (GetLastError (), _T(""));    
-               return 1;
-       }
-
-       /* print drive info */
-       if (szVolName[0] != '\0')
-       {
-               LoadString(CMD_ModuleHandle, STRING_VOL_HELP1, szMsg, RC_STRING_MAX_SIZE);
-               ConOutPrintf(szMsg, pszRootPath[0],szVolName);
-       }
-       else
-       {
-               LoadString(CMD_ModuleHandle, STRING_VOL_HELP2, szMsg, RC_STRING_MAX_SIZE);
-               ConOutPrintf(szMsg, pszRootPath[0]);
-       }
-
-       /* print the volume serial number */
-       LoadString(CMD_ModuleHandle, STRING_VOL_HELP3, szMsg, RC_STRING_MAX_SIZE);
-       ConOutPrintf(szMsg, HIWORD(dwSerialNr), LOWORD(dwSerialNr));
-       return 0;
-}
-
-
-INT cmd_vol (LPTSTR cmd, LPTSTR param)
-{
-       TCHAR szRootPath[] = _T("A:\\");
-       TCHAR szPath[MAX_PATH];
-
-       if (!_tcsncmp (param, _T("/?"), 2))
-       {
-               ConOutResPaging(TRUE,STRING_VOL_HELP4);
-               return 0;
-       }
-
-  nErrorLevel = 0;
-
-       if (param[0] == _T('\0'))
-       {
-               GetCurrentDirectory (MAX_PATH, szPath);
-               szRootPath[0] = szPath[0];
-       }
-       else
-       {
-               _tcsupr (param);
-               if (param[1] == _T(':'))
-                       szRootPath[0] = param[0];
-               else
-               {
-                       error_invalid_drive ();     
-      nErrorLevel = 1;
-                       return 1;
-               }
-       }
-
-       if (!IsValidPathName (szRootPath))
-       {
-               error_invalid_drive ();    
-     nErrorLevel = 1;
-               return 1;
-       }
-
-       /* print the header */
-       if (!PrintVolumeHeader (szRootPath))
-  {    
-           nErrorLevel = 1;
-               return 1;
-  }
-
-       return 0;
-}
-
-#endif
diff --git a/reactos/subsys/system/cmd/where.c b/reactos/subsys/system/cmd/where.c
deleted file mode 100644 (file)
index 3136f46..0000000
+++ /dev/null
@@ -1,273 +0,0 @@
-/*
- *  WHERE.C - file search functions.
- *
- *
- *  History:
- *
- *    07/15/95 (Tim Norman)
- *        started.
- *
- *    08/08/95 (Matt Rains)
- *        i have cleaned up the source code. changes now bring this source
- *        into guidelines for recommended programming practice.
- *
- *    12/12/95 (Steffan Kaiser & Tim Norman)
- *        added some patches to fix some things and make more efficient
- *
- *    1/6/96 (Tim Norman)
- *        fixed a stupid pointer mistake...
- *        Thanks to everyone who noticed it!
- *
- *    8/1/96 (Tim Norman)
- *        fixed a bug when getenv returns NULL
- *
- *    8/7/96 (Steffan Kaiser and Tim Norman)
- *        speed improvements and bug fixes
- *
- *    8/27/96 (Tim Norman)
- *        changed code to use pointers directly into PATH environment
- *        variable rather than making our own copy.  This saves some memory,
- *        but requires we write our own function to copy pathnames out of
- *        the variable.
- *
- *    12/23/96 (Aaron Kaufman)
- *        Fixed a bug in get_paths() that did not point to the first PATH
- *        in the environment variable.
- *
- *    7/12/97 (Tim Norman)
- *        Apparently, Aaron's bugfix got lost, so I fixed it again.
- *
- *    16 July 1998 (John P. Price)
- *        Added stand alone code.
- *
- *    17 July 1998 (John P. Price)
- *        Rewrote find_which to use searchpath function
- *
- *    24-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        fixed bug where didn't check all extensions when path was specified
- *
- *    27-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        added config.h include
- *
- *    30-Jul-1998 (John P Price <linux-guru@gcfl.net>)
- *        fixed so that it find_which returns NULL if filename is not
- *        executable (does not have .bat, .com, or .exe extention).
- *        Before command would to execute any file with any extension (opps!)
- *
- *    03-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Changed find_which().
- *
- *    07-Dec-1998 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Added ".CMD" extension.
- *        Replaced numeric constant by _NR_OF_EXTENSIONS.
- *
- *    26-Feb-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Replaced find_which() by SearchForExecutable().
- *        Now files are searched using the right extension order.
- *
- *    20-Apr-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
- *        Some minor changes and improvements.
- *
-
- *    10-Jul-2004 (Jens Collin <jens.collin@lakhei.com>)
- *        Fixed searxhing for files with specific extensions in PATHEXT order..
- *
- */
-
-#include <precomp.h>
-
-
-/* initial size of environment variable buffer */
-#define ENV_BUFFER_SIZE  1024
-
-
-/* searches for file using path info. */
-
-BOOL
-SearchForExecutableSingle (LPCTSTR pFileName, LPTSTR pFullName, LPTSTR pExtension)
-{
-       TCHAR  szPathBuffer[CMDLINE_LENGTH];
-       LPTSTR pszBuffer = NULL;
-       DWORD  dwBuffer, len;
-       LPTSTR s,f;
-       /* initialize full name buffer */
-       *pFullName = _T('\0');
-
-#ifdef _DEBUG
-       DebugPrintf (_T("SearchForExecutableSingle: \'%s\' with ext: \'%s\'\n"), pFileName, pExtension);
-#endif
-
-       /* Check if valid directly on specified path */
-       if (_tcschr (pFileName, _T('\\')) != NULL)
-       {
-               LPTSTR pFilePart;
-#ifdef _DEBUG
-               DebugPrintf (_T("Absolute or relative path is given.\n"));
-#endif
-
-               if (GetFullPathName (pFileName,
-                                    CMDLINE_LENGTH,
-                                    szPathBuffer,
-                                    &pFilePart)  ==0)
-                       return FALSE;
-
-               if(pFilePart == 0)
-                       return FALSE;
-               /* Add extension and test file: */
-               if (pExtension)
-                       _tcscat(szPathBuffer, pExtension);
-
-               if (IsExistingFile (szPathBuffer))
-               {
-#ifdef _DEBUG
-                       DebugPrintf (_T("Found: \'%s\'\n"), szPathBuffer);
-#endif
-                       _tcscpy (pFullName, szPathBuffer);
-                       return TRUE;
-               }
-               return FALSE;
-       }
-
-       /* search in current directory */
-       len = GetCurrentDirectory (CMDLINE_LENGTH, szPathBuffer);
-       if (szPathBuffer[len - 1] != _T('\\'))
-       {
-               szPathBuffer[len] = _T('\\');
-               szPathBuffer[len + 1] = _T('\0');
-       }
-       _tcscat (szPathBuffer, pFileName);
-
-       if (pExtension)
-               _tcscat (szPathBuffer, pExtension);
-
-       if (IsExistingFile (szPathBuffer))
-       {
-#ifdef _DEBUG
-               DebugPrintf (_T("Found: \'%s\'\n"), szPathBuffer);
-#endif
-               _tcscpy (pFullName, szPathBuffer);
-               return TRUE;
-       }
-
-
-
-       /* load environment varable PATH into buffer */
-       pszBuffer = (LPTSTR)malloc (ENV_BUFFER_SIZE * sizeof(TCHAR));
-       dwBuffer = GetEnvironmentVariable (_T("PATH"), pszBuffer, ENV_BUFFER_SIZE);
-       if (dwBuffer > ENV_BUFFER_SIZE)
-       {
-               pszBuffer = (LPTSTR)realloc (pszBuffer, dwBuffer * sizeof (TCHAR));
-               GetEnvironmentVariable (_T("PATH"), pszBuffer, dwBuffer);
-       }
-
-
-       /* search in PATH */
-       s = pszBuffer;
-       while (s && *s)
-       {
-               f = _tcschr (s, _T(';'));
-
-               if (f)
-               {
-                       _tcsncpy (szPathBuffer, s, (size_t)(f-s));
-                       szPathBuffer[f-s] = _T('\0');
-                       s = f + 1;
-               }
-               else
-               {
-                       _tcscpy (szPathBuffer, s);
-                       s = NULL;
-               }
-
-               len = _tcslen(szPathBuffer);
-               if (szPathBuffer[len - 1] != _T('\\'))
-               {
-                       szPathBuffer[len] = _T('\\');
-                       szPathBuffer[len + 1] = _T('\0');
-               }
-               _tcscat (szPathBuffer, pFileName);
-
-               if (pExtension)
-                       _tcscat (szPathBuffer, pExtension);
-
-               if (IsExistingFile (szPathBuffer))
-               {
-#ifdef _DEBUG
-                       DebugPrintf (_T("Found: \'%s\'\n"), szPathBuffer);
-#endif
-                       free (pszBuffer);
-                       _tcscpy (pFullName, szPathBuffer);
-                       return TRUE;
-               }
-       }
-       free (pszBuffer);
-       return FALSE;
-}
-
-
-BOOL
-SearchForExecutable (LPCTSTR pFileName, LPTSTR pFullName)
-{
-       static TCHAR pszDefaultPathExt[] = _T(".COM;.EXE;.BAT;.CMD");
-       LPTSTR pszBuffer = NULL;
-       LPTSTR pCh;
-       LPTSTR pExt;
-       DWORD  dwBuffer;
-#ifdef _DEBUG
-       DebugPrintf (_T("SearchForExecutable: \'%s\'\n"), pFileName);
-#endif
-       /* load environment varable PATHEXT */
-       pszBuffer = (LPTSTR)malloc (ENV_BUFFER_SIZE * sizeof(TCHAR));
-       dwBuffer = GetEnvironmentVariable (_T("PATHEXT"), pszBuffer, ENV_BUFFER_SIZE);
-       if (dwBuffer > ENV_BUFFER_SIZE)
-       {
-               pszBuffer = (LPTSTR)realloc (pszBuffer, dwBuffer * sizeof (TCHAR));
-               GetEnvironmentVariable (_T("PATHEXT"), pszBuffer, dwBuffer);
-       }
-       else if (0 == dwBuffer)
-       {
-               _tcscpy(pszBuffer, pszDefaultPathExt);
-       }
-
-#ifdef _DEBUG
-       DebugPrintf (_T("SearchForExecutable(): Loaded PATHEXT: %s\n"), pszBuffer);
-#endif
-
-       pExt = _tcsrchr(pFileName, _T('.'));
-       if (pExt != NULL)
-       {
-               LPTSTR pszBuffer2;
-               pszBuffer2 = _tcsdup(pszBuffer);
-               if (pszBuffer2)
-               {
-                       pCh = _tcstok(pszBuffer2, _T(";"));
-                       while (pCh)
-                       {
-                               if (0 == _tcsicmp(pCh, pExt))
-                               {
-                                       free(pszBuffer);
-                                       free(pszBuffer2);
-                                       return SearchForExecutableSingle(pFileName, pFullName, NULL);
-                               }
-                               pCh = _tcstok(NULL, _T(";"));
-                       }
-                       free(pszBuffer2);
-               }
-       }
-
-       pCh = _tcstok(pszBuffer, _T(";"));
-       while (pCh)
-       {
-               if (SearchForExecutableSingle(pFileName, pFullName, pCh))
-               {
-                       free(pszBuffer);
-                       return TRUE;
-               }
-               pCh = _tcstok(NULL, _T(";"));
-       }
-
-       free(pszBuffer);
-       return FALSE;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/cmd/window.c b/reactos/subsys/system/cmd/window.c
deleted file mode 100644 (file)
index 10ac14c..0000000
+++ /dev/null
@@ -1,231 +0,0 @@
-/* $Id$
- *
- * WINDOW.C - activate & window internal commands.
- *
- * clone from 4nt activate command
- *
- * 10 Sep 1999 (Paolo Pantaleo)
- *     started (window command in WINDOW.c)
- *
- * 29 Sep 1999 (Paolo Pantaleo)
- *     activate and window in a single file using mainly the same code
- *     (nice size optimization :)
- *
- *    30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
- *        Remove all hardcode string to En.rc
- */
-
-
-#include <precomp.h>
-#include "resource.h"
-
-#if (  defined(INCLUDE_CMD_WINDOW) ||  defined(INCLUDE_CMD_ACTIVATE)  )
-
-
-#define A_MIN          0x01
-#define A_MAX          0x02
-#define A_RESTORE      0x04
-#define A_POS          0x08
-#define A_SIZE         0x10
-#define A_CLOSE                0x20
-
-
-/*service funciton to perform actions on windows
-
- param is a string to parse for options/actions
- hWnd is the handle of window on wich perform actions
-
-*/
-
-static INT ServiceActivate (LPTSTR param, HWND hWnd)
-{
-       LPTSTR *p = 0, p_tmp;
-       INT argc = 0, i;
-       INT iAction = 0;
-       LPTSTR title = 0;
-       WINDOWPLACEMENT wp;
-       RECT pos;
-       LPTSTR tmp;
-
-
-       if (*param)
-               p = split(param, &argc, FALSE);
-
-       for (i = 0; i < argc; i++)
-       {
-               p_tmp = p[i];
-               if (*p_tmp == _T('/'))
-                       p_tmp++;
-
-               if (_tcsicmp(p_tmp, _T("min")) == 0)
-               {
-                       iAction |= A_MIN;
-                       continue;
-               }
-
-               if (_tcsicmp(p_tmp, _T("max")) == 0)
-               {
-                       iAction |= A_MAX;
-                       continue;
-               }
-
-               if (_tcsicmp(p_tmp, _T("restore")) == 0)
-               {
-                       iAction |= A_RESTORE;
-                       continue;
-               }
-
-               if (_tcsicmp(p_tmp, _T("close")) == 0)
-               {
-                       iAction |= A_CLOSE;
-                       continue;
-               }
-
-               if (_tcsnicmp(p_tmp, _T("pos"), 3) == 0)
-               {
-                       iAction |= A_POS;
-                       tmp = p_tmp+3;
-                       if (*tmp == _T('='))
-                               tmp++;
-
-                       pos.left= _ttoi(tmp);
-                       if(!(tmp=_tcschr(tmp, _T(','))))
-                       {
-                               error_invalid_parameter_format(p[i]);
-                               freep(p);
-                               return 1;
-                       }
-
-                       pos.top = _ttoi (++tmp);
-                       if(!(tmp=_tcschr(tmp, _T(','))))
-                       {
-                               error_invalid_parameter_format(p[i]);
-                               freep(p);
-                               return 1;
-                       }
-
-                       pos.right = _ttoi(++tmp) + pos.left;
-                       if (!(tmp = _tcschr(tmp, _T(','))))
-                       {
-                               error_invalid_parameter_format(p[i]);
-                               freep(p);
-                               return 1;
-                       }
-                       pos.bottom = _ttoi(++tmp) + pos.top;
-                       continue;
-               }
-
-               if (_tcsnicmp(p_tmp, _T("size"), 4)==0)
-               {
-                       iAction |=A_SIZE;
-                       continue;
-               }
-
-               /* none of them=window title */
-               if (title)
-               {
-                       error_invalid_parameter_format(p[i]);
-                       freep(p);
-                       return 1;
-               }
-
-               if (p_tmp[0] == _T('"'))
-               {
-                       title = (p_tmp + 1);
-                       *_tcschr(p_tmp + 1, _T('"')) = 0;
-                       continue;
-               }
-               title = p_tmp;
-       }
-
-       if (title)
-               SetWindowText(hWnd, title);
-
-       wp.length = sizeof(WINDOWPLACEMENT);
-       GetWindowPlacement(hWnd, &wp);
-
-       if (iAction & A_POS)
-               wp.rcNormalPosition = pos;
-
-       if (iAction & A_MIN)
-               wp.showCmd = SW_MINIMIZE;
-
-       if (iAction & A_MAX)
-               wp.showCmd = SW_SHOWMAXIMIZED;
-
-       /*if no actions are specified default is SW_RESTORE*/
-       if ((iAction & A_RESTORE) || (!iAction))
-               wp.showCmd = SW_RESTORE;
-
-       if (iAction & A_CLOSE)
-       {
-#ifdef _DEBUG
-               ConErrPrintf(_T("!!!FIXME:  CLOSE Not implemented!!!\n"));
-#endif
-       }
-
-       wp.length = sizeof(WINDOWPLACEMENT);
-       SetWindowPlacement(hWnd, &wp);
-
-       if (p)
-               freep(p);
-
-       return 0;
-}
-
-
-
-
-INT CommandWindow (LPTSTR cmd, LPTSTR param)
-{
-       HWND hwnd;
-
-       if (_tcsncmp (param, _T("/?"), 2) == 0)
-       {
-    ConOutResPaging(TRUE,STRING_WINDOW_HELP1);
-               return 0;
-       }
-
-       hwnd = GetConsoleWindow();
-       Sleep(0);
-       return ServiceActivate(param, hwnd);
-}
-
-
-INT CommandActivate (LPTSTR cmd, LPTSTR param)
-{
-       HWND hwnd;
-       LPTSTR *arg;
-       INT argc;
-
-       if (_tcsncmp (param, _T("/?"), 2) == 0)
-       {
-               ConOutResPaging(TRUE,STRING_WINDOW_HELP2);
-               return 0;
-       }
-
-       if(!(*param))
-               return 1;
-
-       /*Split the user input into array*/
-       arg = split (param, &argc, FALSE);
-       if(argc < 2)
-       {
-               if(arg != NULL)
-                       freep(arg);
-       }
-       hwnd = FindWindow(NULL, arg[0]);
-       if (hwnd == NULL)
-       {
-               if(arg != NULL)
-                       freep(arg);
-               ConErrResPuts(STRING_WINDOW_ERROR1);
-               return 1;
-       }
-       if(arg != NULL)
-               freep(arg);
-
-       return ServiceActivate(param, hwnd);
-}
-
-#endif /* (  defined(INCLUDE_CMD_WINDOW) ||  defined(INCLUDE_CMD_ACTIVATE)  ) */
diff --git a/reactos/subsys/system/devmgr/devmgr.c b/reactos/subsys/system/devmgr/devmgr.c
deleted file mode 100644 (file)
index 0b2bf6e..0000000
+++ /dev/null
@@ -1,723 +0,0 @@
-/* Device manager
- * (C) 2005 - Hervé Poussineau (hpoussin@reactos.org)
- * GUI: Michael Fritscher (michael@fritscher.net)
- *
- */
-
-#define INITGUID
-#include <windows.h>
-#include <setupapi.h>
-#include <stdio.h>
-#include <tchar.h>
-#include <commctrl.h>
-#include <windows.h>
-#include <commctrl.h>
-#if defined (__GNUC__)
-#include <winioctl.h>
-#endif
-
-/* FIXME: should be in cfgmgr32.h */
-typedef DWORD               CONFIGRET;
-typedef DWORD               DEVINST, *PDEVINST;
-#define CM_DRP_DEVICEDESC   0x00000001
-#define MAX_DEVICE_ID_LEN   200
-#define MAX_CLASS_NAME_LEN  32
-#define CR_SUCCESS          0x00000000
-#define CR_NO_SUCH_DEVINST  0x0000000D
-#define CR_NO_SUCH_VALUE    0x00000025
-#ifdef _UNICODE
-typedef WCHAR               *DEVINSTID_W;
-CONFIGRET WINAPI CM_Get_DevNode_Registry_PropertyW(DEVINST, ULONG, PULONG, PVOID, PULONG, ULONG);
-CONFIGRET WINAPI CM_Locate_DevNodeW(PDEVINST, DEVINSTID_W, ULONG);
-#define CM_Get_DevNode_Registry_Property CM_Get_DevNode_Registry_PropertyW
-#define CM_Locate_DevNode                CM_Locate_DevNodeW
-#else
-typedef CHAR                *DEVINSTID_A;
-CONFIGRET WINAPI CM_Get_DevNode_Registry_PropertyA(DEVINST, ULONG, PULONG, PVOID, PULONG, ULONG);
-CONFIGRET WINAPI CM_Locate_DevNodeA(PDEVINST, DEVINSTID_A, ULONG);
-#define CM_Get_DevNode_Registry_Property CM_Get_DevNode_Registry_PropertyA
-#define CM_Locate_DevNode                CM_Locate_DevNodeA
-#endif
-CONFIGRET WINAPI CM_Enumerate_Classes(ULONG, LPGUID, ULONG);
-CONFIGRET WINAPI CM_Get_Child(PDEVINST, DEVINST, ULONG);
-CONFIGRET WINAPI CM_Get_Sibling(PDEVINST, DEVINST, ULONG);
-/* end of cfgmgr32.h */
-
-/**************************************************************************
-   Function Prototypes
-**************************************************************************/
-
-BOOL InitApplication(HINSTANCE);
-BOOL InitInstance(HINSTANCE, int);
-LRESULT CALLBACK MainWndProc(HWND, UINT, WPARAM, LPARAM);
-void CreateListView(HINSTANCE, HWND);
-void ResizeListView(HWND);
-BOOL InitListView();
-void InsertIntoListView(int, LPTSTR, LPTSTR);
-
-
-LRESULT ListViewNotify(HWND, LPARAM);
-void SwitchView(HWND, DWORD);
-BOOL DoContextMenu(HWND, WPARAM, LPARAM);
-void UpdateMenu(HWND, HMENU);
-BOOL InsertListViewItems();
-void PositionHeader();
-
-void CreateButtons();
-void ListByClass();
-
-/**************************************************************************
-   Global Variables
-**************************************************************************/
-
-HINSTANCE   g_hInst;
-TCHAR       g_szClassName[] = TEXT("VListVwClass");
-HWND        hWnd;
-HWND        hwndListView;
-HWND        hwndButtonListByClass;
-HWND        hwndButtonListByConnection;
-HWND        hwndButtonListByInterface;
-HWND        hwndButtonExit;
-TCHAR       temp [255];
-HDC         hDC;
-TCHAR       empty [255] = TEXT("                                                                                                                            ");
-
-void ListByClass()
-{
-       GUID ClassGuid;
-       TCHAR ClassDescription[MAX_PATH];
-       TCHAR ClassName[MAX_CLASS_NAME_LEN];
-       TCHAR PropertyBuffer[256];
-       HKEY KeyClass;
-       HDEVINFO hDevInfo;
-       SP_DEVINFO_DATA DeviceInfoData;
-       int i = 0, j;
-       long Size;
-       long rc;
-
-       SendMessage(hwndListView, WM_SETREDRAW, FALSE, 0);
-
-       ListView_DeleteAllItems(hwndListView);
-       while (1)
-       {
-               CONFIGRET res;
-               res = CM_Enumerate_Classes(i, &ClassGuid, 0);
-               if (res == CR_NO_SUCH_VALUE)
-                       break;
-
-               i++;
-               ClassName[0] = '\0';
-               if (!SetupDiClassNameFromGuid(
-                       &ClassGuid,
-                       ClassName,
-                       sizeof(ClassName) / sizeof(ClassName[0]),
-                       NULL))
-               {
-                       _tprintf(_T("SetupDiClassNameFromGuid() failed with status 0x%lx\n"), GetLastError());
-                       continue;
-               }
-
-               /* Get class description */
-               KeyClass = SetupDiOpenClassRegKey(
-                       &ClassGuid,
-                       KEY_READ);
-               if (KeyClass == INVALID_HANDLE_VALUE)
-               {
-                       _tprintf(_T("SetupDiOpenClassRegKey() failed with status 0x%lx\n"), GetLastError());
-                       continue;
-               }
-               Size = sizeof(ClassDescription);
-               rc = RegQueryValue(KeyClass, NULL, ClassDescription, &Size);
-               if (rc == ERROR_SUCCESS)
-               {
-                       InsertIntoListView(i,ClassDescription,ClassName);
-                       TextOut(hDC, 200, 40, empty, strlen(empty));
-                       TextOut(hDC, 200, 40, ClassDescription, strlen(ClassDescription));
-                       _tprintf(_T("%d %s (%s)\n"), i, ClassName, ClassDescription);
-               }
-               else
-                       _tprintf(_T("RegQueryValue() failed with status 0x%lx\n"), rc);
-               RegCloseKey(KeyClass);
-
-               /* Enumerate devices in the class */
-               hDevInfo = SetupDiGetClassDevs(
-                       &ClassGuid,
-                       NULL, /* Enumerator */
-                       NULL, /* hWnd parent */
-                       DIGCF_PRESENT);
-               if (hDevInfo == INVALID_HANDLE_VALUE)
-                       continue;
-
-               j = 0;
-               while (1)
-               {
-                       DeviceInfoData.cbSize = sizeof(SP_DEVINFO_DATA);
-                       if (!SetupDiEnumDeviceInfo(
-                               hDevInfo,
-                               j,
-                               &DeviceInfoData))
-                       {
-                               break;
-                       }
-                       j++;
-                       if (SetupDiGetDeviceRegistryProperty(
-                               hDevInfo,
-                               &DeviceInfoData,
-                               SPDRP_DEVICEDESC,
-                               NULL, /* Property reg data type */
-                               (PBYTE)PropertyBuffer,
-                               sizeof(PropertyBuffer),
-                               NULL) /* Required size */)
-                       {
-                               _tprintf(_T("- %s\n"), PropertyBuffer);
-                               InsertIntoListView(0,PropertyBuffer," ");
-                       }
-                       else if (SetupDiGetDeviceRegistryProperty(
-                               hDevInfo,
-                               &DeviceInfoData,
-                               SPDRP_PHYSICAL_DEVICE_OBJECT_NAME,
-                               NULL, /* Property reg data type */
-                               (PBYTE)PropertyBuffer,
-                               sizeof(PropertyBuffer),
-                               NULL) /* Required size */)
-                       {
-                               _tprintf(_T("- %s\n"), PropertyBuffer);
-                               InsertIntoListView(0,PropertyBuffer," ");
-                               TextOut(hDC, 200, 40, empty, strlen(empty));
-                               TextOut(hDC, 200, 40, PropertyBuffer, strlen(PropertyBuffer));
-                       }
-                       else
-                               _tprintf(_T("SetupDiGetDeviceRegistryProperty() failed with status 0x%lx\n"), GetLastError());
-               }
-               SetupDiDestroyDeviceInfoList(hDevInfo);
-       }
-       SendMessage(hwndListView, WM_SETREDRAW, TRUE, 0);
-}
-
-CONFIGRET GetDeviceName(DEVINST DevInst, LPTSTR Buffer, DWORD BufferLength)
-{
-       ULONG BufferSize = BufferLength * sizeof(TCHAR);
-       CONFIGRET cr;
-       cr = CM_Get_DevNode_Registry_Property(DevInst, CM_DRP_DEVICEDESC, NULL, Buffer, &BufferSize, 0);
-       if (cr != CR_SUCCESS)
-       {
-               _tprintf(_T("CM_Get_DevNode_Registry_Property() failed, cr= 0x%lx\n"), cr);
-       }
-       return cr;
-}
-
-CONFIGRET ListSubNodes(DEVINST parent, DWORD Level)
-{
-       CONFIGRET cr;
-       DEVINST child;
-
-       cr = CM_Get_Child(&child, parent, 0);
-       if (cr == CR_NO_SUCH_DEVINST)
-               return CR_SUCCESS;
-       else if (cr != CR_SUCCESS)
-       {
-               _tprintf(_T("CM_Get_Child() failed, cr= 0x%lx\n"), cr);
-               return cr;
-       }
-
-       do
-       {
-#define DISPLAY_LENGTH (MAX_PATH + MAX_DEVICE_ID_LEN)
-               DWORD DisplayLength = DISPLAY_LENGTH;
-               TCHAR DisplayName[DISPLAY_LENGTH];
-               ULONG i = Level;
-               TCHAR LevelSpaces [ 255 ];
-               cr = GetDeviceName(child, DisplayName, DisplayLength);
-               LevelSpaces[0] = '\0';
-               while (i-- != 0)
-               {
-                       _tprintf(_T("   "));
-                       sprintf(LevelSpaces,"%s%s",LevelSpaces,"    ");
-               }
-               if (cr == CR_SUCCESS)
-               {
-                       _tprintf(_T("%s\n"), DisplayName);
-                       sprintf(temp,"%s%s",LevelSpaces,DisplayName);
-                       InsertIntoListView(0,temp," ");
-                       TextOut(hDC, 200, 40, empty, strlen(empty));
-                       TextOut(hDC, 200, 40, DisplayName, strlen(DisplayName));
-               }
-               else
-               {
-                       _tprintf(_T("(unknown device)\n"));
-                       sprintf(temp,"%s%s",LevelSpaces,"(unknown device)");
-                       InsertIntoListView(0,temp," ");
-                       TextOut(hDC, 200, 40, empty, strlen(empty));
-                       TextOut(hDC, 200, 40, "(unknown device)", strlen("(unknown device)"));
-               }
-               cr = ListSubNodes(child, Level + 1);
-               if (cr != CR_SUCCESS)
-                       return cr;
-               cr = CM_Get_Sibling(&child, child, 0);
-               if (cr != CR_SUCCESS && cr != CR_NO_SUCH_DEVINST)
-               {
-                       _tprintf(_T("CM_Get_Sibling() failed, cr= 0x%lx\n"), cr);
-                       return cr;
-               }
-       } while (cr == CR_SUCCESS);
-       return CR_SUCCESS;
-}
-
-int ListByConnection()
-{
-       CONFIGRET cr;
-       DEVINST root;
-       ListView_DeleteAllItems(hwndListView);
-
-       cr = CM_Locate_DevNode(&root, NULL, 0);
-
-       if (cr != CR_SUCCESS)
-       {
-               _tprintf(_T("CM_Locate_DevNode() failed, cr= 0x%lx\n"), cr);
-               return 1;
-       }
-       SendMessage(hwndListView, WM_SETREDRAW, FALSE, 0);
-       cr = ListSubNodes(root, 0);
-       SendMessage(hwndListView, WM_SETREDRAW, TRUE, 0);
-       if (cr != CR_SUCCESS)
-               return 2;
-       return 0;
-}
-
-int ListByInterface(const GUID* guid)
-{
-       HDEVINFO hDevInfo;
-       CHAR Buffer[sizeof(SP_DEVICE_INTERFACE_DETAIL_DATA) + 0x100];
-       PSP_DEVICE_INTERFACE_DETAIL_DATA DeviceInterfaceDetailData;
-       DWORD i;
-       SP_DEVICE_INTERFACE_DATA DeviceInterfaceData;
-
-       ListView_DeleteAllItems(hwndListView);
-
-       DeviceInterfaceDetailData = (PSP_DEVICE_INTERFACE_DETAIL_DATA)Buffer;
-       DeviceInterfaceDetailData->cbSize = sizeof(SP_DEVICE_INTERFACE_DETAIL_DATA);
-
-       hDevInfo = SetupDiGetClassDevs(
-               guid,
-               NULL, /* Enumerator */
-               NULL, /* hwndParent */
-               DIGCF_DEVICEINTERFACE);
-       if (hDevInfo == INVALID_HANDLE_VALUE)
-       {
-               printf("SetupDiGetClassDevs() failed with status 0x%lx\n", GetLastError());
-               return 1;
-       }
-
-       i = 0;
-       DeviceInterfaceData.cbSize = sizeof(SP_DEVICE_INTERFACE_DATA);
-       SendMessage(hwndListView, WM_SETREDRAW, FALSE, 0);
-       while (TRUE)
-       {
-               if (!SetupDiEnumDeviceInterfaces(
-                       hDevInfo,
-                       NULL,
-                       guid,
-                       i,
-                       &DeviceInterfaceData))
-               {
-                       if (GetLastError() != ERROR_NO_MORE_ITEMS)
-                               printf("SetupDiEnumDeviceInterfaces() failed with status 0x%lx\n", GetLastError());
-                       break;
-               }
-               i++;
-               if (SetupDiGetDeviceInterfaceDetail(hDevInfo, &DeviceInterfaceData, DeviceInterfaceDetailData, sizeof(Buffer), NULL, NULL))
-               {
-                       _tprintf(_T("- device %-2ld: %s\n"), i, DeviceInterfaceDetailData->DevicePath);
-                       TextOut(hDC, 200, 40, empty, strlen(empty));
-                       TextOut(hDC, 200, 40, DeviceInterfaceDetailData->DevicePath, strlen(DeviceInterfaceDetailData->DevicePath));
-                       InsertIntoListView(i,DeviceInterfaceDetailData->DevicePath," ");
-               }
-               else
-               {
-                       _tprintf(_T("- device %ld\n"), i);
-                       InsertIntoListView(i," "," ");
-               }
-
-       }
-       SendMessage(hwndListView, WM_SETREDRAW, TRUE, 0);
-       SetupDiDestroyDeviceInfoList(hDevInfo);
-       return 0;
-}
-
-/*int main(void)
-{
-       ListByClass();
-       ListByInterface(&GUID_DEVINTERFACE_SERENUM_BUS_ENUMERATOR);
-       ListByConnection();
-       return 0;
-}*/
-
-
-
-//GUI
-int WINAPI WinMain(  HINSTANCE hInstance,
-                     HINSTANCE hPrevInstance,
-                     LPSTR lpCmdLine,
-                     int nCmdShow)
-{
-MSG  msg;
-
-g_hInst = hInstance;
-
-if(!hPrevInstance)
-   if(!InitApplication(hInstance))
-      return FALSE;
-
-//required to use the common controls
-InitCommonControls();
-
-/* Perform initializations that apply to a specific instance */
-
-if (!InitInstance(hInstance, nCmdShow))
-   return FALSE;
-
-/* Acquire and dispatch messages until a WM_QUIT uMessage is received. */
-
-while(GetMessage( &msg, NULL, 0x00, 0x00))
-   {
-   TranslateMessage(&msg);
-   DispatchMessage(&msg);
-   }
-
-return (int)msg.wParam;
-}
-
-BOOL InitApplication(HINSTANCE hInstance)
-{
-WNDCLASSEX  wcex;
-ATOM        aReturn;
-
-wcex.cbSize          = sizeof(WNDCLASSEX);
-wcex.style           = 0;
-wcex.lpfnWndProc     = (WNDPROC)MainWndProc;
-wcex.cbClsExtra      = 0;
-wcex.cbWndExtra      = 0;
-wcex.hInstance       = hInstance;
-wcex.hCursor         = LoadCursor(NULL, IDC_ARROW);
-wcex.hbrBackground   = (HBRUSH)(COLOR_WINDOW );
-wcex.lpszMenuName    = 0;
-wcex.lpszClassName   = g_szClassName;
-wcex.hIcon           = 0;
-wcex.hIconSm         = 0;
-
-aReturn = RegisterClassEx(&wcex);
-
-if(0 == aReturn)
-   {
-   WNDCLASS wc;
-
-   wc.style          = 0;
-   wc.lpfnWndProc    = (WNDPROC)MainWndProc;
-   wc.cbClsExtra     = 0;
-   wc.cbWndExtra     = 0;
-   wc.hInstance      = hInstance;
-   wc.hIcon          = 0;
-   wc.hCursor        = 0;
-   wc.hbrBackground  = (HBRUSH)(COLOR_WINDOW);
-   wc.lpszMenuName   = 0;
-   wc.lpszClassName  = g_szClassName;
-
-   aReturn = RegisterClass(&wc);
-   }
-
-return aReturn;
-}
-
-BOOL InitInstance(   HINSTANCE hInstance,
-                     int nCmdShow)
-{
-HWND     hWnd;
-TCHAR    szTitle[MAX_PATH] = TEXT("Device viewer");
-
-g_hInst = hInstance;
-
-/* Create a main window for this application instance.  */
-hWnd = CreateWindowEx(  0,
-                        g_szClassName,
-                        szTitle,
-                        WS_OVERLAPPEDWINDOW,
-                        CW_USEDEFAULT,
-                        CW_USEDEFAULT,
-                        CW_USEDEFAULT,
-                        CW_USEDEFAULT,
-                        NULL,
-                        NULL,
-                        hInstance,
-                        NULL);
-
-/* If window could not be created, return "failure" */
-
-if (!hWnd)
-   return FALSE;
-
-/* Make the window visible; update its client area; and return "success" */
-
-ShowWindow(hWnd, nCmdShow);
-UpdateWindow(hWnd);
-hDC = GetDC(hWnd);
-return TRUE;
-
-}
-
-LRESULT CALLBACK MainWndProc( HWND hWnd,
-                              UINT uMessage,
-                              WPARAM wParam,
-                              LPARAM lParam)
-{
-
-
-switch (uMessage)
-   {
-   case WM_CREATE:
-      // create the TreeView control
-      CreateListView(g_hInst, hWnd);
-
-      //initialize the TreeView control
-      InitListView();
-
-      CreateButtons(g_hInst, hWnd);
-      TextOut(hDC, 200, 40, empty, strlen(empty));
-      break;
-
-
-   case WM_SIZE:
-      ResizeListView(hWnd);
-      break;
-   case WM_DESTROY:
-      ReleaseDC(hWnd, hDC);
-      PostQuitMessage(0);
-      break;
-   case WM_COMMAND:
-      if (HIWORD(wParam) == BN_CLICKED &&
-         (HWND) lParam == hwndButtonListByClass)
-      {
-        ListByClass();
-      }
-      if (HIWORD(wParam) == BN_CLICKED &&
-         (HWND) lParam == hwndButtonListByConnection)
-      {
-          ListByConnection();
-      }
-      if (HIWORD(wParam) == BN_CLICKED &&
-         (HWND) lParam == hwndButtonListByInterface)
-      {
-         ListByInterface(&GUID_DEVINTERFACE_SERENUM_BUS_ENUMERATOR);
-      }
-      if (HIWORD(wParam) == BN_CLICKED &&
-         (HWND) lParam == hwndButtonExit)
-      {
-          /* Close the window. */
-          DestroyWindow (hWnd);
-      }      return 0;
-      break;
-   default:
-      break;
-   }
-return DefWindowProc(hWnd, uMessage, wParam, lParam);
-}
-
-void CreateListView(HINSTANCE hInstance, HWND hwndParent)
-{
-DWORD       dwStyle;
-
-dwStyle =   WS_TABSTOP |
-            WS_CHILD |
-            WS_BORDER |
-            WS_VISIBLE |
-            LVS_AUTOARRANGE |
-            LVS_REPORT ;//|
-            //LVS_OWNERDATA;
-
-hwndListView = CreateWindowEx(   WS_EX_CLIENTEDGE,          // ex style
-                                 WC_LISTVIEW,               // class name - defined in commctrl.h
-                                 TEXT(""),                        // dummy text
-                                 dwStyle,                   // style
-                                 0,                         // x position
-                                 0,                         // y position
-                                 0,                         // width
-                                 0,                         // height
-                                 hwndParent,                // parent
-                                 0,//(HMENU)ID_LISTVIEW,        // ID
-                                 g_hInst,                   // instance
-                                 NULL);                     // no extra data
-
-
-ResizeListView(hwndParent);
-}
-
-void ResizeListView(HWND hwndParent)
-{
-RECT  rc;
-
-GetClientRect(hwndParent, &rc);
-
-MoveWindow( hwndListView,
-            rc.left,
-            rc.top+60,
-            rc.right - rc.left,
-            rc.bottom - rc.top-60,
-            TRUE);
-}
-
-void PositionHeader()
-{
-HWND  hwndHeader = GetWindow(hwndListView, GW_CHILD);
-DWORD dwStyle = GetWindowLong(hwndListView, GWL_STYLE);
-
-/*To ensure that the first item will be visible, create the control without
-the LVS_NOSCROLL style and then add it here*/
-dwStyle |= LVS_NOSCROLL;
-SetWindowLong(hwndListView, GWL_STYLE, dwStyle);
-
-//only do this if we are in report view and were able to get the header hWnd
-if(((dwStyle & LVS_TYPEMASK) == LVS_REPORT) && hwndHeader)
-   {
-   RECT        rc;
-   HD_LAYOUT   hdLayout;
-   WINDOWPOS   wpos;
-
-   GetClientRect(hwndListView, &rc);
-   hdLayout.prc = &rc;
-   hdLayout.pwpos = &wpos;
-
-   Header_Layout(hwndHeader, &hdLayout);
-
-   SetWindowPos(  hwndHeader,
-                  wpos.hwndInsertAfter,
-                  wpos.x,
-                  wpos.y,
-                  wpos.cx,
-                  wpos.cy,
-                  wpos.flags | SWP_SHOWWINDOW);
-
-   ListView_EnsureVisible(hwndListView, 0, FALSE);
-   }
-}
-
-BOOL InitListView()
-{
-LV_COLUMN   lvColumn;
-int         i;
-TCHAR       szString[3][20] = {TEXT("#"), TEXT("Name"), TEXT("Intern name")};
-
-//empty the list
-ListView_DeleteAllItems(hwndListView);
-
-//initialize the columns
-lvColumn.mask = LVCF_FMT | LVCF_WIDTH | LVCF_TEXT | LVCF_SUBITEM;
-lvColumn.fmt = LVCFMT_LEFT;
-i=0;
-lvColumn.cx = 20;
-lvColumn.pszText = szString[i];
-ListView_InsertColumn(hwndListView, i, &lvColumn);
-i=1;
-lvColumn.cx = 400;
-lvColumn.pszText = szString[i];
-ListView_InsertColumn(hwndListView, i, &lvColumn);
-i=2;
-lvColumn.cx = 150;
-lvColumn.pszText = szString[i];
-ListView_InsertColumn(hwndListView, i, &lvColumn);
-
-
-return TRUE;
-}
-
-typedef struct tagLINE_INFO
-{
-    DWORD dwValType;
-    LPTSTR name;
-    void* val;
-    size_t val_len;
-} LINE_INFO, *PLINE_INFO;
-
-void InsertIntoListView(int typ, LPTSTR name, LPTSTR intern_name)
-{
-   //MessageBox(hWnd, "You just pressed Ctrl+a", "Hotkey", MB_OK | MB_ICONINFORMATION);
-    TCHAR temp[ 255 ];
-    //LINE_INFO* linfo;
-    LVITEM item;
-    int index;
-    //linfo->name = Name;
-    item.mask = LVIF_TEXT;
-    item.iItem = 9999;
-    item.iSubItem = 0;
-    item.state = 0;
-    //item.statemask = 0;
-    item.pszText=malloc(10);
-    if (typ>=1)
-    {
-       sprintf(temp,"%i",typ);
-       item.pszText = temp;
-    }
-    else
-       item.pszText = "";
-    item.cchTextMax = _tcslen(item.pszText);
-    if (item.cchTextMax == 0)
-        item.pszText = LPSTR_TEXTCALLBACK;
-    item.iImage = 0;
-    //item.iIdent = 0;
-    //item.iGroupId = 0;
-    //item.cColumns = 0 ;
-    //item.puColumns = 0;
-    //item.lParam = (LPARAM)linfo;
-    index = ListView_InsertItem(hwndListView, &item);
-    ListView_SetItemText(hwndListView, index, 1, name);
-    ListView_SetItemText(hwndListView, index, 2, intern_name);
-}
-
-
-
-void CreateButtons(HINSTANCE hInstance, HWND hwndParent)
-{
-
-         hwndButtonListByClass = CreateWindowEx (
-                 0,
-                 "button",         /* Builtin button class */
-                 "List by Class",
-                 WS_CHILD | WS_VISIBLE | BS_PUSHBUTTON,
-                 0, 0, 190, 30,
-                 hwndParent,             /* Parent is this window. */
-                 0,        /* Control ID: 1 */
-                 g_hInst,
-                 NULL
-                 );
-         hwndButtonListByConnection = CreateWindowEx (
-                 0,
-                 "button",         /* Builtin button class */
-                 "List by Connection",
-                 WS_CHILD | WS_VISIBLE | BS_PUSHBUTTON,
-                 200, 0, 190, 30,
-                 hwndParent,             /* Parent is this window. */
-                 0,        /* Control ID: 1 */
-                 g_hInst,
-                 NULL
-                 );
-         hwndButtonListByInterface = CreateWindowEx (
-                 0,
-                 "button",         /* Builtin button class */
-                 "List by Interface",
-                 WS_CHILD | WS_VISIBLE | BS_PUSHBUTTON,
-                 400, 0, 190, 30,
-                 hwndParent,             /* Parent is this window. */
-                 0,        /* Control ID: 1 */
-                 g_hInst,
-                 NULL
-                 );
-         hwndButtonExit = CreateWindowEx (
-                 0,
-                 "button",         /* Builtin button class */
-                 "Exit",
-                 WS_CHILD | WS_VISIBLE | BS_PUSHBUTTON,
-                 0, 30, 190, 30,
-                 hwndParent,             /* Parent is this window. */
-                 0,        /* Control ID: 1 */
-                 g_hInst,
-                 NULL
-                 );
-}
diff --git a/reactos/subsys/system/devmgr/devmgr.rc b/reactos/subsys/system/devmgr/devmgr.rc
deleted file mode 100644 (file)
index 0ff0c3f..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-/* $Id$ */
-
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS W32 Device Manager Utility\0"
-#define REACTOS_STR_INTERNAL_NAME      "devmgr\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "devmgr.exe\0"
-#include <reactos/version.rc>
diff --git a/reactos/subsys/system/devmgr/devmgrapp.xml b/reactos/subsys/system/devmgr/devmgrapp.xml
deleted file mode 100644 (file)
index e938087..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-<module name="devmgrapp" type="win32cui" installbase="system32" installname="devmgr.exe">
-       <define name="__USE_W32API" />
-       <define name="DEFINE_GUID" />
-       <library>ntdll</library>
-       <library>setupapi</library>
-       <library>gdi32</library>
-       <library>kernel32</library>
-       <library>user32</library>
-       <library>comctl32</library>
-       <file>devmgr.c</file>
-       <efile>devmgr.rc</efile>
-</module>
diff --git a/reactos/subsys/system/explorer/Doxyfile b/reactos/subsys/system/explorer/Doxyfile
deleted file mode 100644 (file)
index 1ffba21..0000000
+++ /dev/null
@@ -1,1169 +0,0 @@
-# Doxyfile 1.3.9.1
-
-# This file describes the settings to be used by the documentation system
-# doxygen (www.doxygen.org) for a project
-#
-# All text after a hash (#) is considered a comment and will be ignored
-# The format is:
-#       TAG = value [value, ...]
-# For lists items can also be appended using:
-#       TAG += value [value, ...]
-# Values that contain spaces should be placed between quotes (" ")
-
-#---------------------------------------------------------------------------
-# Project related configuration options
-#---------------------------------------------------------------------------
-
-# The PROJECT_NAME tag is a single word (or a sequence of words surrounded 
-# by quotes) that should identify the project.
-
-PROJECT_NAME           = "ROS Explorer"
-
-# The PROJECT_NUMBER tag can be used to enter a project or revision number. 
-# This could be handy for archiving the generated documentation or 
-# if some version control system is used.
-
-PROJECT_NUMBER         = 
-
-# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) 
-# base path where the generated documentation will be put. 
-# If a relative path is entered, it will be relative to the location 
-# where doxygen was started. If left blank the current directory will be used.
-
-OUTPUT_DIRECTORY       = doxy-doc
-
-# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create 
-# 4096 sub-directories (in 2 levels) under the output directory of each output 
-# format and will distribute the generated files over these directories. 
-# Enabling this option can be useful when feeding doxygen a huge amount of source 
-# files, where putting all generated files in the same directory would otherwise 
-# cause performance problems for the file system.
-
-CREATE_SUBDIRS         = NO
-
-# The OUTPUT_LANGUAGE tag is used to specify the language in which all 
-# documentation generated by doxygen is written. Doxygen will use this 
-# information to generate all constant output in the proper language. 
-# The default language is English, other supported languages are: 
-# Brazilian, Catalan, Chinese, Chinese-Traditional, Croatian, Czech, Danish, 
-# Dutch, Finnish, French, German, Greek, Hungarian, Italian, Japanese, 
-# Japanese-en (Japanese with English messages), Korean, Korean-en, Norwegian, 
-# Polish, Portuguese, Romanian, Russian, Serbian, Slovak, Slovene, Spanish, 
-# Swedish, and Ukrainian.
-
-OUTPUT_LANGUAGE        = English
-
-# This tag can be used to specify the encoding used in the generated output. 
-# The encoding is not always determined by the language that is chosen, 
-# but also whether or not the output is meant for Windows or non-Windows users. 
-# In case there is a difference, setting the USE_WINDOWS_ENCODING tag to YES 
-# forces the Windows encoding (this is the default for the Windows binary), 
-# whereas setting the tag to NO uses a Unix-style encoding (the default for 
-# all platforms other than Windows).
-
-USE_WINDOWS_ENCODING   = YES
-
-# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will 
-# include brief member descriptions after the members that are listed in 
-# the file and class documentation (similar to JavaDoc). 
-# Set to NO to disable this.
-
-BRIEF_MEMBER_DESC      = YES
-
-# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend 
-# the brief description of a member or function before the detailed description. 
-# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the 
-# brief descriptions will be completely suppressed.
-
-REPEAT_BRIEF           = YES
-
-# This tag implements a quasi-intelligent brief description abbreviator 
-# that is used to form the text in various listings. Each string 
-# in this list, if found as the leading text of the brief description, will be 
-# stripped from the text and the result after processing the whole list, is used 
-# as the annotated text. Otherwise, the brief description is used as-is. If left 
-# blank, the following values are used ("$name" is automatically replaced with the 
-# name of the entity): "The $name class" "The $name widget" "The $name file" 
-# "is" "provides" "specifies" "contains" "represents" "a" "an" "the"
-
-ABBREVIATE_BRIEF       = 
-
-# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then 
-# Doxygen will generate a detailed section even if there is only a brief 
-# description.
-
-ALWAYS_DETAILED_SEC    = NO
-
-# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all inherited 
-# members of a class in the documentation of that class as if those members were 
-# ordinary class members. Constructors, destructors and assignment operators of 
-# the base classes will not be shown.
-
-INLINE_INHERITED_MEMB  = NO
-
-# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full 
-# path before files name in the file list and in the header files. If set 
-# to NO the shortest path that makes the file name unique will be used.
-
-FULL_PATH_NAMES        = NO
-
-# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag 
-# can be used to strip a user-defined part of the path. Stripping is 
-# only done if one of the specified strings matches the left-hand part of 
-# the path. The tag can be used to show relative paths in the file list. 
-# If left blank the directory from which doxygen is run is used as the 
-# path to strip.
-
-STRIP_FROM_PATH        = 
-
-# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of 
-# the path mentioned in the documentation of a class, which tells 
-# the reader which header file to include in order to use a class. 
-# If left blank only the name of the header file containing the class 
-# definition is used. Otherwise one should specify the include paths that 
-# are normally passed to the compiler using the -I flag.
-
-STRIP_FROM_INC_PATH    = 
-
-# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter 
-# (but less readable) file names. This can be useful is your file systems 
-# doesn't support long names like on DOS, Mac, or CD-ROM.
-
-SHORT_NAMES            = NO
-
-# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen 
-# will interpret the first line (until the first dot) of a JavaDoc-style 
-# comment as the brief description. If set to NO, the JavaDoc 
-# comments will behave just like the Qt-style comments (thus requiring an 
-# explicit @brief command for a brief description.
-
-JAVADOC_AUTOBRIEF      = YES
-
-# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen 
-# treat a multi-line C++ special comment block (i.e. a block of //! or /// 
-# comments) as a brief description. This used to be the default behaviour. 
-# The new default is to treat a multi-line C++ comment block as a detailed 
-# description. Set this tag to YES if you prefer the old behaviour instead.
-
-MULTILINE_CPP_IS_BRIEF = NO
-
-# If the DETAILS_AT_TOP tag is set to YES then Doxygen 
-# will output the detailed description near the top, like JavaDoc.
-# If set to NO, the detailed description appears after the member 
-# documentation.
-
-DETAILS_AT_TOP         = NO
-
-# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented 
-# member inherits the documentation from any documented member that it 
-# re-implements.
-
-INHERIT_DOCS           = YES
-
-# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC 
-# tag is set to YES, then doxygen will reuse the documentation of the first 
-# member in the group (if any) for the other members of the group. By default 
-# all members of a group must be documented explicitly.
-
-DISTRIBUTE_GROUP_DOC   = NO
-
-# The TAB_SIZE tag can be used to set the number of spaces in a tab. 
-# Doxygen uses this value to replace tabs by spaces in code fragments.
-
-TAB_SIZE               = 8
-
-# This tag can be used to specify a number of aliases that acts 
-# as commands in the documentation. An alias has the form "name=value". 
-# For example adding "sideeffect=\par Side Effects:\n" will allow you to 
-# put the command \sideeffect (or @sideeffect) in the documentation, which 
-# will result in a user-defined paragraph with heading "Side Effects:". 
-# You can put \n's in the value part of an alias to insert newlines.
-
-ALIASES                = 
-
-# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources 
-# only. Doxygen will then generate output that is more tailored for C. 
-# For instance, some of the names that are used will be different. The list 
-# of all members will be omitted, etc.
-
-OPTIMIZE_OUTPUT_FOR_C  = NO
-
-# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java sources 
-# only. Doxygen will then generate output that is more tailored for Java. 
-# For instance, namespaces will be presented as packages, qualified scopes 
-# will look different, etc.
-
-OPTIMIZE_OUTPUT_JAVA   = NO
-
-# Set the SUBGROUPING tag to YES (the default) to allow class member groups of 
-# the same type (for instance a group of public functions) to be put as a 
-# subgroup of that type (e.g. under the Public Functions section). Set it to 
-# NO to prevent subgrouping. Alternatively, this can be done per class using 
-# the \nosubgrouping command.
-
-SUBGROUPING            = YES
-
-#---------------------------------------------------------------------------
-# Build related configuration options
-#---------------------------------------------------------------------------
-
-# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in 
-# documentation are documented, even if no documentation was available. 
-# Private class members and static file members will be hidden unless 
-# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES
-
-EXTRACT_ALL            = NO
-
-# If the EXTRACT_PRIVATE tag is set to YES all private members of a class 
-# will be included in the documentation.
-
-EXTRACT_PRIVATE        = NO
-
-# If the EXTRACT_STATIC tag is set to YES all static members of a file 
-# will be included in the documentation.
-
-EXTRACT_STATIC         = NO
-
-# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) 
-# defined locally in source files will be included in the documentation. 
-# If set to NO only classes defined in header files are included.
-
-EXTRACT_LOCAL_CLASSES  = YES
-
-# This flag is only useful for Objective-C code. When set to YES local 
-# methods, which are defined in the implementation section but not in 
-# the interface are included in the documentation. 
-# If set to NO (the default) only methods in the interface are included.
-
-EXTRACT_LOCAL_METHODS  = NO
-
-# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all 
-# undocumented members of documented classes, files or namespaces. 
-# If set to NO (the default) these members will be included in the 
-# various overviews, but no documentation section is generated. 
-# This option has no effect if EXTRACT_ALL is enabled.
-
-HIDE_UNDOC_MEMBERS     = NO
-
-# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all 
-# undocumented classes that are normally visible in the class hierarchy. 
-# If set to NO (the default) these classes will be included in the various 
-# overviews. This option has no effect if EXTRACT_ALL is enabled.
-
-HIDE_UNDOC_CLASSES     = NO
-
-# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all 
-# friend (class|struct|union) declarations. 
-# If set to NO (the default) these declarations will be included in the 
-# documentation.
-
-HIDE_FRIEND_COMPOUNDS  = NO
-
-# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any 
-# documentation blocks found inside the body of a function. 
-# If set to NO (the default) these blocks will be appended to the 
-# function's detailed documentation block.
-
-HIDE_IN_BODY_DOCS      = NO
-
-# The INTERNAL_DOCS tag determines if documentation 
-# that is typed after a \internal command is included. If the tag is set 
-# to NO (the default) then the documentation will be excluded. 
-# Set it to YES to include the internal documentation.
-
-INTERNAL_DOCS          = NO
-
-# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate 
-# file names in lower-case letters. If set to YES upper-case letters are also 
-# allowed. This is useful if you have classes or files whose names only differ 
-# in case and if your file system supports case sensitive file names. Windows 
-# and Mac users are advised to set this option to NO.
-
-CASE_SENSE_NAMES       = YES
-
-# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen 
-# will show members with their full class and namespace scopes in the 
-# documentation. If set to YES the scope will be hidden.
-
-HIDE_SCOPE_NAMES       = NO
-
-# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen 
-# will put a list of the files that are included by a file in the documentation 
-# of that file.
-
-SHOW_INCLUDE_FILES     = YES
-
-# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] 
-# is inserted in the documentation for inline members.
-
-INLINE_INFO            = YES
-
-# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen 
-# will sort the (detailed) documentation of file and class members 
-# alphabetically by member name. If set to NO the members will appear in 
-# declaration order.
-
-SORT_MEMBER_DOCS       = YES
-
-# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the 
-# brief documentation of file, namespace and class members alphabetically 
-# by member name. If set to NO (the default) the members will appear in 
-# declaration order.
-
-SORT_BRIEF_DOCS        = NO
-
-# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be 
-# sorted by fully-qualified names, including namespaces. If set to 
-# NO (the default), the class list will be sorted only by class name, 
-# not including the namespace part. 
-# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES.
-# Note: This option applies only to the class list, not to the 
-# alphabetical list.
-
-SORT_BY_SCOPE_NAME     = NO
-
-# The GENERATE_TODOLIST tag can be used to enable (YES) or 
-# disable (NO) the todo list. This list is created by putting \todo 
-# commands in the documentation.
-
-GENERATE_TODOLIST      = YES
-
-# The GENERATE_TESTLIST tag can be used to enable (YES) or 
-# disable (NO) the test list. This list is created by putting \test 
-# commands in the documentation.
-
-GENERATE_TESTLIST      = YES
-
-# The GENERATE_BUGLIST tag can be used to enable (YES) or 
-# disable (NO) the bug list. This list is created by putting \bug 
-# commands in the documentation.
-
-GENERATE_BUGLIST       = YES
-
-# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or 
-# disable (NO) the deprecated list. This list is created by putting 
-# \deprecated commands in the documentation.
-
-GENERATE_DEPRECATEDLIST= YES
-
-# The ENABLED_SECTIONS tag can be used to enable conditional 
-# documentation sections, marked by \if sectionname ... \endif.
-
-ENABLED_SECTIONS       = 
-
-# The MAX_INITIALIZER_LINES tag determines the maximum number of lines 
-# the initial value of a variable or define consists of for it to appear in 
-# the documentation. If the initializer consists of more lines than specified 
-# here it will be hidden. Use a value of 0 to hide initializers completely. 
-# The appearance of the initializer of individual variables and defines in the 
-# documentation can be controlled using \showinitializer or \hideinitializer 
-# command in the documentation regardless of this setting.
-
-MAX_INITIALIZER_LINES  = 30
-
-# Set the SHOW_USED_FILES tag to NO to disable the list of files generated 
-# at the bottom of the documentation of classes and structs. If set to YES the 
-# list will mention the files that were used to generate the documentation.
-
-SHOW_USED_FILES        = YES
-
-# If the sources in your project are distributed over multiple directories 
-# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy 
-# in the documentation.
-
-SHOW_DIRECTORIES       = YES
-
-#---------------------------------------------------------------------------
-# configuration options related to warning and progress messages
-#---------------------------------------------------------------------------
-
-# The QUIET tag can be used to turn on/off the messages that are generated 
-# by doxygen. Possible values are YES and NO. If left blank NO is used.
-
-QUIET                  = NO
-
-# The WARNINGS tag can be used to turn on/off the warning messages that are 
-# generated by doxygen. Possible values are YES and NO. If left blank 
-# NO is used.
-
-WARNINGS               = NO
-
-# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings 
-# for undocumented members. If EXTRACT_ALL is set to YES then this flag will 
-# automatically be disabled.
-
-WARN_IF_UNDOCUMENTED   = NO
-
-# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for 
-# potential errors in the documentation, such as not documenting some 
-# parameters in a documented function, or documenting parameters that 
-# don't exist or using markup commands wrongly.
-
-WARN_IF_DOC_ERROR      = YES
-
-# The WARN_FORMAT tag determines the format of the warning messages that 
-# doxygen can produce. The string should contain the $file, $line, and $text 
-# tags, which will be replaced by the file and line number from which the 
-# warning originated and the warning text.
-
-WARN_FORMAT            = "$file:$line: $text"
-
-# The WARN_LOGFILE tag can be used to specify a file to which warning 
-# and error messages should be written. If left blank the output is written 
-# to stderr.
-
-WARN_LOGFILE           = 
-
-#---------------------------------------------------------------------------
-# configuration options related to the input files
-#---------------------------------------------------------------------------
-
-# The INPUT tag can be used to specify the files and/or directories that contain 
-# documented source files. You may enter file names like "myfile.cpp" or 
-# directories like "/usr/src/myproject". Separate the files or directories 
-# with spaces.
-
-INPUT                  = . \
-                         desktop \
-                         dialogs \
-                         shell \
-                         taskbar \
-                         utility
-
-# If the value of the INPUT tag contains directories, you can use the 
-# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp 
-# and *.h) to filter out the source-files in the directories. If left 
-# blank the following patterns are tested: 
-# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx *.hpp 
-# *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm
-
-FILE_PATTERNS          = *.cpp \
-                         *.c \
-                         *.hpp \
-                         *.h
-
-# The RECURSIVE tag can be used to turn specify whether or not subdirectories 
-# should be searched for input files as well. Possible values are YES and NO. 
-# If left blank NO is used.
-
-RECURSIVE              = NO
-
-# The EXCLUDE tag can be used to specify files and/or directories that should 
-# excluded from the INPUT source files. This way you can easily exclude a 
-# subdirectory from a directory tree whose root is specified with the INPUT tag.
-
-EXCLUDE                = 
-
-# The EXCLUDE_SYMLINKS tag can be used select whether or not files or directories 
-# that are symbolic links (a Unix filesystem feature) are excluded from the input.
-
-EXCLUDE_SYMLINKS       = NO
-
-# If the value of the INPUT tag contains directories, you can use the 
-# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude 
-# certain files from those directories.
-
-EXCLUDE_PATTERNS       = 
-
-# The EXAMPLE_PATH tag can be used to specify one or more files or 
-# directories that contain example code fragments that are included (see 
-# the \include command).
-
-EXAMPLE_PATH           = 
-
-# If the value of the EXAMPLE_PATH tag contains directories, you can use the 
-# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp 
-# and *.h) to filter out the source-files in the directories. If left 
-# blank all files are included.
-
-EXAMPLE_PATTERNS       = 
-
-# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be 
-# searched for input files to be used with the \include or \dontinclude 
-# commands irrespective of the value of the RECURSIVE tag. 
-# Possible values are YES and NO. If left blank NO is used.
-
-EXAMPLE_RECURSIVE      = NO
-
-# The IMAGE_PATH tag can be used to specify one or more files or 
-# directories that contain image that are included in the documentation (see 
-# the \image command).
-
-IMAGE_PATH             = 
-
-# The INPUT_FILTER tag can be used to specify a program that doxygen should 
-# invoke to filter for each input file. Doxygen will invoke the filter program 
-# by executing (via popen()) the command <filter> <input-file>, where <filter> 
-# is the value of the INPUT_FILTER tag, and <input-file> is the name of an 
-# input file. Doxygen will then use the output that the filter program writes 
-# to standard output.  If FILTER_PATTERNS is specified, this tag will be 
-# ignored.
-
-INPUT_FILTER           = 
-
-# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern 
-# basis.  Doxygen will compare the file name with each pattern and apply the 
-# filter if there is a match.  The filters are a list of the form: 
-# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further 
-# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER 
-# is applied to all files.
-
-FILTER_PATTERNS        = 
-
-# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using 
-# INPUT_FILTER) will be used to filter the input files when producing source 
-# files to browse (i.e. when SOURCE_BROWSER is set to YES).
-
-FILTER_SOURCE_FILES    = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to source browsing
-#---------------------------------------------------------------------------
-
-# If the SOURCE_BROWSER tag is set to YES then a list of source files will 
-# be generated. Documented entities will be cross-referenced with these sources. 
-# Note: To get rid of all source code in the generated output, make sure also 
-# VERBATIM_HEADERS is set to NO.
-
-SOURCE_BROWSER         = YES
-
-# Setting the INLINE_SOURCES tag to YES will include the body 
-# of functions and classes directly in the documentation.
-
-INLINE_SOURCES         = YES
-
-# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct 
-# doxygen to hide any special comment blocks from generated source code 
-# fragments. Normal C and C++ comments will always remain visible.
-
-STRIP_CODE_COMMENTS    = YES
-
-# If the REFERENCED_BY_RELATION tag is set to YES (the default) 
-# then for each documented function all documented 
-# functions referencing it will be listed.
-
-REFERENCED_BY_RELATION = YES
-
-# If the REFERENCES_RELATION tag is set to YES (the default) 
-# then for each documented function all documented entities 
-# called/used by that function will be listed.
-
-REFERENCES_RELATION    = YES
-
-# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen 
-# will generate a verbatim copy of the header file for each class for 
-# which an include is specified. Set to NO to disable this.
-
-VERBATIM_HEADERS       = YES
-
-#---------------------------------------------------------------------------
-# configuration options related to the alphabetical class index
-#---------------------------------------------------------------------------
-
-# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index 
-# of all compounds will be generated. Enable this if the project 
-# contains a lot of classes, structs, unions or interfaces.
-
-ALPHABETICAL_INDEX     = YES
-
-# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then 
-# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns 
-# in which this list will be split (can be a number in the range [1..20])
-
-COLS_IN_ALPHA_INDEX    = 5
-
-# In case all classes in a project start with a common prefix, all 
-# classes will be put under the same header in the alphabetical index. 
-# The IGNORE_PREFIX tag can be used to specify one or more prefixes that 
-# should be ignored while generating the index headers.
-
-IGNORE_PREFIX          = 
-
-#---------------------------------------------------------------------------
-# configuration options related to the HTML output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_HTML tag is set to YES (the default) Doxygen will 
-# generate HTML output.
-
-GENERATE_HTML          = YES
-
-# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `html' will be used as the default path.
-
-HTML_OUTPUT            = html
-
-# The HTML_FILE_EXTENSION tag can be used to specify the file extension for 
-# each generated HTML page (for example: .htm,.php,.asp). If it is left blank 
-# doxygen will generate files with .html extension.
-
-HTML_FILE_EXTENSION    = .html
-
-# The HTML_HEADER tag can be used to specify a personal HTML header for 
-# each generated HTML page. If it is left blank doxygen will generate a 
-# standard header.
-
-HTML_HEADER            = 
-
-# The HTML_FOOTER tag can be used to specify a personal HTML footer for 
-# each generated HTML page. If it is left blank doxygen will generate a 
-# standard footer.
-
-HTML_FOOTER            = doxy-footer.html
-
-# The HTML_STYLESHEET tag can be used to specify a user-defined cascading 
-# style sheet that is used by each HTML page. It can be used to 
-# fine-tune the look of the HTML output. If the tag is left blank doxygen 
-# will generate a default style sheet. Note that doxygen will try to copy 
-# the style sheet file to the HTML output directory, so don't put your own 
-# stylesheet in the HTML output directory as well, or it will be erased!
-
-HTML_STYLESHEET        = 
-
-# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, 
-# files or namespaces will be aligned in HTML using tables. If set to 
-# NO a bullet list will be used.
-
-HTML_ALIGN_MEMBERS     = YES
-
-# If the GENERATE_HTMLHELP tag is set to YES, additional index files 
-# will be generated that can be used as input for tools like the 
-# Microsoft HTML help workshop to generate a compressed HTML help file (.chm) 
-# of the generated HTML documentation.
-
-GENERATE_HTMLHELP      = YES
-
-# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can 
-# be used to specify the file name of the resulting .chm file. You 
-# can add a path in front of the file if the result should not be 
-# written to the html output directory.
-
-CHM_FILE               = 
-
-# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can 
-# be used to specify the location (absolute path including file name) of 
-# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run 
-# the HTML help compiler on the generated index.hhp.
-
-HHC_LOCATION           = 
-
-# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag 
-# controls if a separate .chi index file is generated (YES) or that 
-# it should be included in the master .chm file (NO).
-
-GENERATE_CHI           = NO
-
-# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag 
-# controls whether a binary table of contents is generated (YES) or a 
-# normal table of contents (NO) in the .chm file.
-
-BINARY_TOC             = NO
-
-# The TOC_EXPAND flag can be set to YES to add extra items for group members 
-# to the contents of the HTML help documentation and to the tree view.
-
-TOC_EXPAND             = NO
-
-# The DISABLE_INDEX tag can be used to turn on/off the condensed index at 
-# top of each HTML page. The value NO (the default) enables the index and 
-# the value YES disables it.
-
-DISABLE_INDEX          = NO
-
-# This tag can be used to set the number of enum values (range [1..20]) 
-# that doxygen will group on one line in the generated HTML documentation.
-
-ENUM_VALUES_PER_LINE   = 4
-
-# If the GENERATE_TREEVIEW tag is set to YES, a side panel will be
-# generated containing a tree-like index structure (just like the one that 
-# is generated for HTML Help). For this to work a browser that supports 
-# JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+, 
-# Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are 
-# probably better off using the HTML help feature.
-
-GENERATE_TREEVIEW      = YES
-
-# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be 
-# used to set the initial width (in pixels) of the frame in which the tree 
-# is shown.
-
-TREEVIEW_WIDTH         = 240
-
-#---------------------------------------------------------------------------
-# configuration options related to the LaTeX output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will 
-# generate Latex output.
-
-GENERATE_LATEX         = NO
-
-# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `latex' will be used as the default path.
-
-LATEX_OUTPUT           = latex
-
-# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be 
-# invoked. If left blank `latex' will be used as the default command name.
-
-LATEX_CMD_NAME         = latex
-
-# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to 
-# generate index for LaTeX. If left blank `makeindex' will be used as the 
-# default command name.
-
-MAKEINDEX_CMD_NAME     = makeindex
-
-# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact 
-# LaTeX documents. This may be useful for small projects and may help to 
-# save some trees in general.
-
-COMPACT_LATEX          = NO
-
-# The PAPER_TYPE tag can be used to set the paper type that is used 
-# by the printer. Possible values are: a4, a4wide, letter, legal and 
-# executive. If left blank a4wide will be used.
-
-PAPER_TYPE             = a4wide
-
-# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX 
-# packages that should be included in the LaTeX output.
-
-EXTRA_PACKAGES         = 
-
-# The LATEX_HEADER tag can be used to specify a personal LaTeX header for 
-# the generated latex document. The header should contain everything until 
-# the first chapter. If it is left blank doxygen will generate a 
-# standard header. Notice: only use this tag if you know what you are doing!
-
-LATEX_HEADER           = 
-
-# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated 
-# is prepared for conversion to pdf (using ps2pdf). The pdf file will 
-# contain links (just like the HTML output) instead of page references 
-# This makes the output suitable for online browsing using a pdf viewer.
-
-PDF_HYPERLINKS         = NO
-
-# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of 
-# plain latex in the generated Makefile. Set this option to YES to get a 
-# higher quality PDF documentation.
-
-USE_PDFLATEX           = NO
-
-# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. 
-# command to the generated LaTeX files. This will instruct LaTeX to keep 
-# running if errors occur, instead of asking the user for help. 
-# This option is also used when generating formulas in HTML.
-
-LATEX_BATCHMODE        = NO
-
-# If LATEX_HIDE_INDICES is set to YES then doxygen will not 
-# include the index chapters (such as File Index, Compound Index, etc.) 
-# in the output.
-
-LATEX_HIDE_INDICES     = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the RTF output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output 
-# The RTF output is optimized for Word 97 and may not look very pretty with 
-# other RTF readers or editors.
-
-GENERATE_RTF           = NO
-
-# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `rtf' will be used as the default path.
-
-RTF_OUTPUT             = rtf
-
-# If the COMPACT_RTF tag is set to YES Doxygen generates more compact 
-# RTF documents. This may be useful for small projects and may help to 
-# save some trees in general.
-
-COMPACT_RTF            = YES
-
-# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated 
-# will contain hyperlink fields. The RTF file will 
-# contain links (just like the HTML output) instead of page references. 
-# This makes the output suitable for online browsing using WORD or other 
-# programs which support those fields. 
-# Note: wordpad (write) and others do not support links.
-
-RTF_HYPERLINKS         = YES
-
-# Load stylesheet definitions from file. Syntax is similar to doxygen's 
-# config file, i.e. a series of assignments. You only have to provide 
-# replacements, missing definitions are set to their default value.
-
-RTF_STYLESHEET_FILE    = 
-
-# Set optional variables used in the generation of an rtf document. 
-# Syntax is similar to doxygen's config file.
-
-RTF_EXTENSIONS_FILE    = 
-
-#---------------------------------------------------------------------------
-# configuration options related to the man page output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_MAN tag is set to YES (the default) Doxygen will 
-# generate man pages
-
-GENERATE_MAN           = NO
-
-# The MAN_OUTPUT tag is used to specify where the man pages will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `man' will be used as the default path.
-
-MAN_OUTPUT             = man
-
-# The MAN_EXTENSION tag determines the extension that is added to 
-# the generated man pages (default is the subroutine's section .3)
-
-MAN_EXTENSION          = .3
-
-# If the MAN_LINKS tag is set to YES and Doxygen generates man output, 
-# then it will generate one additional man file for each entity 
-# documented in the real man page(s). These additional files 
-# only source the real man page, but without them the man command 
-# would be unable to find the correct page. The default is NO.
-
-MAN_LINKS              = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the XML output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_XML tag is set to YES Doxygen will 
-# generate an XML file that captures the structure of 
-# the code including all documentation.
-
-GENERATE_XML           = NO
-
-# The XML_OUTPUT tag is used to specify where the XML pages will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `xml' will be used as the default path.
-
-XML_OUTPUT             = xml
-
-# The XML_SCHEMA tag can be used to specify an XML schema, 
-# which can be used by a validating XML parser to check the 
-# syntax of the XML files.
-
-XML_SCHEMA             = 
-
-# The XML_DTD tag can be used to specify an XML DTD, 
-# which can be used by a validating XML parser to check the 
-# syntax of the XML files.
-
-XML_DTD                = 
-
-# If the XML_PROGRAMLISTING tag is set to YES Doxygen will 
-# dump the program listings (including syntax highlighting 
-# and cross-referencing information) to the XML output. Note that 
-# enabling this will significantly increase the size of the XML output.
-
-XML_PROGRAMLISTING     = YES
-
-#---------------------------------------------------------------------------
-# configuration options for the AutoGen Definitions output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will 
-# generate an AutoGen Definitions (see autogen.sf.net) file 
-# that captures the structure of the code including all 
-# documentation. Note that this feature is still experimental 
-# and incomplete at the moment.
-
-GENERATE_AUTOGEN_DEF   = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the Perl module output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_PERLMOD tag is set to YES Doxygen will 
-# generate a Perl module file that captures the structure of 
-# the code including all documentation. Note that this 
-# feature is still experimental and incomplete at the 
-# moment.
-
-GENERATE_PERLMOD       = NO
-
-# If the PERLMOD_LATEX tag is set to YES Doxygen will generate 
-# the necessary Makefile rules, Perl scripts and LaTeX code to be able 
-# to generate PDF and DVI output from the Perl module output.
-
-PERLMOD_LATEX          = NO
-
-# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be 
-# nicely formatted so it can be parsed by a human reader.  This is useful 
-# if you want to understand what is going on.  On the other hand, if this 
-# tag is set to NO the size of the Perl module output will be much smaller 
-# and Perl will parse it just the same.
-
-PERLMOD_PRETTY         = YES
-
-# The names of the make variables in the generated doxyrules.make file 
-# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. 
-# This is useful so different doxyrules.make files included by the same 
-# Makefile don't overwrite each other's variables.
-
-PERLMOD_MAKEVAR_PREFIX = 
-
-#---------------------------------------------------------------------------
-# Configuration options related to the preprocessor   
-#---------------------------------------------------------------------------
-
-# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will 
-# evaluate all C-preprocessor directives found in the sources and include 
-# files.
-
-ENABLE_PREPROCESSING   = YES
-
-# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro 
-# names in the source code. If set to NO (the default) only conditional 
-# compilation will be performed. Macro expansion can be done in a controlled 
-# way by setting EXPAND_ONLY_PREDEF to YES.
-
-MACRO_EXPANSION        = NO
-
-# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES 
-# then the macro expansion is limited to the macros specified with the 
-# PREDEFINED and EXPAND_AS_PREDEFINED tags.
-
-EXPAND_ONLY_PREDEF     = NO
-
-# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files 
-# in the INCLUDE_PATH (see below) will be search if a #include is found.
-
-SEARCH_INCLUDES        = YES
-
-# The INCLUDE_PATH tag can be used to specify one or more directories that 
-# contain include files that are not input files but should be processed by 
-# the preprocessor.
-
-INCLUDE_PATH           = 
-
-# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard 
-# patterns (like *.h and *.hpp) to filter out the header-files in the 
-# directories. If left blank, the patterns specified with FILE_PATTERNS will 
-# be used.
-
-INCLUDE_FILE_PATTERNS  = 
-
-# The PREDEFINED tag can be used to specify one or more macro names that 
-# are defined before the preprocessor is started (similar to the -D option of 
-# gcc). The argument of the tag is a list of macros of the form: name 
-# or name=definition (no spaces). If the definition and the = are 
-# omitted =1 is assumed. To prevent a macro definition from being 
-# undefined via #undef or recursively expanded use the := operator 
-# instead of the = operator.
-
-PREDEFINED             = __cplusplus
-
-# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then 
-# this tag can be used to specify a list of macro names that should be expanded. 
-# The macro definition that is found in the sources will be used. 
-# Use the PREDEFINED tag if you want to use a different macro definition.
-
-EXPAND_AS_DEFINED      = 
-
-# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then 
-# doxygen's preprocessor will remove all function-like macros that are alone 
-# on a line, have an all uppercase name, and do not end with a semicolon. Such 
-# function macros are typically used for boiler-plate code, and will confuse the 
-# parser if not removed.
-
-SKIP_FUNCTION_MACROS   = YES
-
-#---------------------------------------------------------------------------
-# Configuration::additions related to external references   
-#---------------------------------------------------------------------------
-
-# The TAGFILES option can be used to specify one or more tagfiles. 
-# Optionally an initial location of the external documentation 
-# can be added for each tagfile. The format of a tag file without 
-# this location is as follows: 
-#   TAGFILES = file1 file2 ... 
-# Adding location for the tag files is done as follows: 
-#   TAGFILES = file1=loc1 "file2 = loc2" ... 
-# where "loc1" and "loc2" can be relative or absolute paths or 
-# URLs. If a location is present for each tag, the installdox tool 
-# does not have to be run to correct the links.
-# Note that each tag file must have a unique name
-# (where the name does NOT include the path)
-# If a tag file is not located in the directory in which doxygen 
-# is run, you must also specify the path to the tagfile here.
-
-TAGFILES               = 
-
-# When a file name is specified after GENERATE_TAGFILE, doxygen will create 
-# a tag file that is based on the input files it reads.
-
-GENERATE_TAGFILE       = 
-
-# If the ALLEXTERNALS tag is set to YES all external classes will be listed 
-# in the class index. If set to NO only the inherited external classes 
-# will be listed.
-
-ALLEXTERNALS           = NO
-
-# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed 
-# in the modules index. If set to NO, only the current project's groups will 
-# be listed.
-
-EXTERNAL_GROUPS        = YES
-
-# The PERL_PATH should be the absolute path and name of the perl script 
-# interpreter (i.e. the result of `which perl').
-
-PERL_PATH              = /usr/bin/perl
-
-#---------------------------------------------------------------------------
-# Configuration options related to the dot tool   
-#---------------------------------------------------------------------------
-
-# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will 
-# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base or 
-# super classes. Setting the tag to NO turns the diagrams off. Note that this 
-# option is superseded by the HAVE_DOT option below. This is only a fallback. It is 
-# recommended to install and use dot, since it yields more powerful graphs.
-
-CLASS_DIAGRAMS         = YES
-
-# If set to YES, the inheritance and collaboration graphs will hide 
-# inheritance and usage relations if the target is undocumented 
-# or is not a class.
-
-HIDE_UNDOC_RELATIONS   = NO
-
-# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is 
-# available from the path. This tool is part of Graphviz, a graph visualization 
-# toolkit from AT&T and Lucent Bell Labs. The other options in this section 
-# have no effect if this option is set to NO (the default)
-
-HAVE_DOT               = YES
-
-# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen 
-# will generate a graph for each documented class showing the direct and 
-# indirect inheritance relations. Setting this tag to YES will force the 
-# the CLASS_DIAGRAMS tag to NO.
-
-CLASS_GRAPH            = YES
-
-# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen 
-# will generate a graph for each documented class showing the direct and 
-# indirect implementation dependencies (inheritance, containment, and 
-# class references variables) of the class with other documented classes.
-
-COLLABORATION_GRAPH    = YES
-
-# If the UML_LOOK tag is set to YES doxygen will generate inheritance and 
-# collaboration diagrams in a style similar to the OMG's Unified Modeling 
-# Language.
-
-UML_LOOK               = NO
-
-# If set to YES, the inheritance and collaboration graphs will show the 
-# relations between templates and their instances.
-
-TEMPLATE_RELATIONS     = NO
-
-# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT 
-# tags are set to YES then doxygen will generate a graph for each documented 
-# file showing the direct and indirect include dependencies of the file with 
-# other documented files.
-
-INCLUDE_GRAPH          = YES
-
-# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and 
-# HAVE_DOT tags are set to YES then doxygen will generate a graph for each 
-# documented header file showing the documented files that directly or 
-# indirectly include this file.
-
-INCLUDED_BY_GRAPH      = YES
-
-# If the CALL_GRAPH and HAVE_DOT tags are set to YES then doxygen will 
-# generate a call dependency graph for every global function or class method. 
-# Note that enabling this option will significantly increase the time of a run. 
-# So in most cases it will be better to enable call graphs for selected 
-# functions only using the \callgraph command.
-
-CALL_GRAPH             = YES
-
-# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen 
-# will graphical hierarchy of all classes instead of a textual one.
-
-GRAPHICAL_HIERARCHY    = YES
-
-# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images 
-# generated by dot. Possible values are png, jpg, or gif
-# If left blank png will be used.
-
-DOT_IMAGE_FORMAT       = png
-
-# The tag DOT_PATH can be used to specify the path where the dot tool can be 
-# found. If left blank, it is assumed the dot tool can be found on the path.
-
-DOT_PATH               = 
-
-# The DOTFILE_DIRS tag can be used to specify one or more directories that 
-# contain dot files that are included in the documentation (see the 
-# \dotfile command).
-
-DOTFILE_DIRS           = 
-
-# The MAX_DOT_GRAPH_WIDTH tag can be used to set the maximum allowed width 
-# (in pixels) of the graphs generated by dot. If a graph becomes larger than 
-# this value, doxygen will try to truncate the graph, so that it fits within 
-# the specified constraint. Beware that most browsers cannot cope with very 
-# large images.
-
-MAX_DOT_GRAPH_WIDTH    = 1024
-
-# The MAX_DOT_GRAPH_HEIGHT tag can be used to set the maximum allows height 
-# (in pixels) of the graphs generated by dot. If a graph becomes larger than 
-# this value, doxygen will try to truncate the graph, so that it fits within 
-# the specified constraint. Beware that most browsers cannot cope with very 
-# large images.
-
-MAX_DOT_GRAPH_HEIGHT   = 1024
-
-# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the 
-# graphs generated by dot. A depth value of 3 means that only nodes reachable 
-# from the root by following a path via at most 3 edges will be shown. Nodes that 
-# lay further from the root node will be omitted. Note that setting this option to 
-# 1 or 2 may greatly reduce the computation time needed for large code bases. Also 
-# note that a graph may be further truncated if the graph's image dimensions are 
-# not sufficient to fit the graph (see MAX_DOT_GRAPH_WIDTH and MAX_DOT_GRAPH_HEIGHT). 
-# If 0 is used for the depth value (the default), the graph is not depth-constrained.
-
-MAX_DOT_GRAPH_DEPTH    = 0
-
-# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will 
-# generate a legend page explaining the meaning of the various boxes and 
-# arrows in the dot generated graphs.
-
-GENERATE_LEGEND        = YES
-
-# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will 
-# remove the intermediate dot files that are used to generate 
-# the various graphs.
-
-DOT_CLEANUP            = YES
-
-#---------------------------------------------------------------------------
-# Configuration::additions related to the search engine   
-#---------------------------------------------------------------------------
-
-# The SEARCHENGINE tag specifies whether or not a search engine should be 
-# used. If set to NO the values of all tags below this one will be ignored.
-
-SEARCHENGINE           = YES
diff --git a/reactos/subsys/system/explorer/Doxyfile-all b/reactos/subsys/system/explorer/Doxyfile-all
deleted file mode 100644 (file)
index 42b61db..0000000
+++ /dev/null
@@ -1,1169 +0,0 @@
-# Doxyfile 1.3.9.1
-
-# This file describes the settings to be used by the documentation system
-# doxygen (www.doxygen.org) for a project
-#
-# All text after a hash (#) is considered a comment and will be ignored
-# The format is:
-#       TAG = value [value, ...]
-# For lists items can also be appended using:
-#       TAG += value [value, ...]
-# Values that contain spaces should be placed between quotes (" ")
-
-#---------------------------------------------------------------------------
-# Project related configuration options
-#---------------------------------------------------------------------------
-
-# The PROJECT_NAME tag is a single word (or a sequence of words surrounded 
-# by quotes) that should identify the project.
-
-PROJECT_NAME           = "ROS Explorer"
-
-# The PROJECT_NUMBER tag can be used to enter a project or revision number. 
-# This could be handy for archiving the generated documentation or 
-# if some version control system is used.
-
-PROJECT_NUMBER         = 
-
-# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) 
-# base path where the generated documentation will be put. 
-# If a relative path is entered, it will be relative to the location 
-# where doxygen was started. If left blank the current directory will be used.
-
-OUTPUT_DIRECTORY       = doxy-doc
-
-# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create 
-# 4096 sub-directories (in 2 levels) under the output directory of each output 
-# format and will distribute the generated files over these directories. 
-# Enabling this option can be useful when feeding doxygen a huge amount of source 
-# files, where putting all generated files in the same directory would otherwise 
-# cause performance problems for the file system.
-
-CREATE_SUBDIRS         = NO
-
-# The OUTPUT_LANGUAGE tag is used to specify the language in which all 
-# documentation generated by doxygen is written. Doxygen will use this 
-# information to generate all constant output in the proper language. 
-# The default language is English, other supported languages are: 
-# Brazilian, Catalan, Chinese, Chinese-Traditional, Croatian, Czech, Danish, 
-# Dutch, Finnish, French, German, Greek, Hungarian, Italian, Japanese, 
-# Japanese-en (Japanese with English messages), Korean, Korean-en, Norwegian, 
-# Polish, Portuguese, Romanian, Russian, Serbian, Slovak, Slovene, Spanish, 
-# Swedish, and Ukrainian.
-
-OUTPUT_LANGUAGE        = English
-
-# This tag can be used to specify the encoding used in the generated output. 
-# The encoding is not always determined by the language that is chosen, 
-# but also whether or not the output is meant for Windows or non-Windows users. 
-# In case there is a difference, setting the USE_WINDOWS_ENCODING tag to YES 
-# forces the Windows encoding (this is the default for the Windows binary), 
-# whereas setting the tag to NO uses a Unix-style encoding (the default for 
-# all platforms other than Windows).
-
-USE_WINDOWS_ENCODING   = YES
-
-# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will 
-# include brief member descriptions after the members that are listed in 
-# the file and class documentation (similar to JavaDoc). 
-# Set to NO to disable this.
-
-BRIEF_MEMBER_DESC      = YES
-
-# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend 
-# the brief description of a member or function before the detailed description. 
-# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the 
-# brief descriptions will be completely suppressed.
-
-REPEAT_BRIEF           = YES
-
-# This tag implements a quasi-intelligent brief description abbreviator 
-# that is used to form the text in various listings. Each string 
-# in this list, if found as the leading text of the brief description, will be 
-# stripped from the text and the result after processing the whole list, is used 
-# as the annotated text. Otherwise, the brief description is used as-is. If left 
-# blank, the following values are used ("$name" is automatically replaced with the 
-# name of the entity): "The $name class" "The $name widget" "The $name file" 
-# "is" "provides" "specifies" "contains" "represents" "a" "an" "the"
-
-ABBREVIATE_BRIEF       = 
-
-# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then 
-# Doxygen will generate a detailed section even if there is only a brief 
-# description.
-
-ALWAYS_DETAILED_SEC    = NO
-
-# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all inherited 
-# members of a class in the documentation of that class as if those members were 
-# ordinary class members. Constructors, destructors and assignment operators of 
-# the base classes will not be shown.
-
-INLINE_INHERITED_MEMB  = NO
-
-# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full 
-# path before files name in the file list and in the header files. If set 
-# to NO the shortest path that makes the file name unique will be used.
-
-FULL_PATH_NAMES        = NO
-
-# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag 
-# can be used to strip a user-defined part of the path. Stripping is 
-# only done if one of the specified strings matches the left-hand part of 
-# the path. The tag can be used to show relative paths in the file list. 
-# If left blank the directory from which doxygen is run is used as the 
-# path to strip.
-
-STRIP_FROM_PATH        = 
-
-# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of 
-# the path mentioned in the documentation of a class, which tells 
-# the reader which header file to include in order to use a class. 
-# If left blank only the name of the header file containing the class 
-# definition is used. Otherwise one should specify the include paths that 
-# are normally passed to the compiler using the -I flag.
-
-STRIP_FROM_INC_PATH    = 
-
-# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter 
-# (but less readable) file names. This can be useful is your file systems 
-# doesn't support long names like on DOS, Mac, or CD-ROM.
-
-SHORT_NAMES            = NO
-
-# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen 
-# will interpret the first line (until the first dot) of a JavaDoc-style 
-# comment as the brief description. If set to NO, the JavaDoc 
-# comments will behave just like the Qt-style comments (thus requiring an 
-# explicit @brief command for a brief description.
-
-JAVADOC_AUTOBRIEF      = YES
-
-# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen 
-# treat a multi-line C++ special comment block (i.e. a block of //! or /// 
-# comments) as a brief description. This used to be the default behaviour. 
-# The new default is to treat a multi-line C++ comment block as a detailed 
-# description. Set this tag to YES if you prefer the old behaviour instead.
-
-MULTILINE_CPP_IS_BRIEF = NO
-
-# If the DETAILS_AT_TOP tag is set to YES then Doxygen 
-# will output the detailed description near the top, like JavaDoc.
-# If set to NO, the detailed description appears after the member 
-# documentation.
-
-DETAILS_AT_TOP         = NO
-
-# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented 
-# member inherits the documentation from any documented member that it 
-# re-implements.
-
-INHERIT_DOCS           = YES
-
-# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC 
-# tag is set to YES, then doxygen will reuse the documentation of the first 
-# member in the group (if any) for the other members of the group. By default 
-# all members of a group must be documented explicitly.
-
-DISTRIBUTE_GROUP_DOC   = NO
-
-# The TAB_SIZE tag can be used to set the number of spaces in a tab. 
-# Doxygen uses this value to replace tabs by spaces in code fragments.
-
-TAB_SIZE               = 8
-
-# This tag can be used to specify a number of aliases that acts 
-# as commands in the documentation. An alias has the form "name=value". 
-# For example adding "sideeffect=\par Side Effects:\n" will allow you to 
-# put the command \sideeffect (or @sideeffect) in the documentation, which 
-# will result in a user-defined paragraph with heading "Side Effects:". 
-# You can put \n's in the value part of an alias to insert newlines.
-
-ALIASES                = 
-
-# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources 
-# only. Doxygen will then generate output that is more tailored for C. 
-# For instance, some of the names that are used will be different. The list 
-# of all members will be omitted, etc.
-
-OPTIMIZE_OUTPUT_FOR_C  = NO
-
-# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java sources 
-# only. Doxygen will then generate output that is more tailored for Java. 
-# For instance, namespaces will be presented as packages, qualified scopes 
-# will look different, etc.
-
-OPTIMIZE_OUTPUT_JAVA   = NO
-
-# Set the SUBGROUPING tag to YES (the default) to allow class member groups of 
-# the same type (for instance a group of public functions) to be put as a 
-# subgroup of that type (e.g. under the Public Functions section). Set it to 
-# NO to prevent subgrouping. Alternatively, this can be done per class using 
-# the \nosubgrouping command.
-
-SUBGROUPING            = YES
-
-#---------------------------------------------------------------------------
-# Build related configuration options
-#---------------------------------------------------------------------------
-
-# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in 
-# documentation are documented, even if no documentation was available. 
-# Private class members and static file members will be hidden unless 
-# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES
-
-EXTRACT_ALL            = YES
-
-# If the EXTRACT_PRIVATE tag is set to YES all private members of a class 
-# will be included in the documentation.
-
-EXTRACT_PRIVATE        = NO
-
-# If the EXTRACT_STATIC tag is set to YES all static members of a file 
-# will be included in the documentation.
-
-EXTRACT_STATIC         = NO
-
-# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) 
-# defined locally in source files will be included in the documentation. 
-# If set to NO only classes defined in header files are included.
-
-EXTRACT_LOCAL_CLASSES  = YES
-
-# This flag is only useful for Objective-C code. When set to YES local 
-# methods, which are defined in the implementation section but not in 
-# the interface are included in the documentation. 
-# If set to NO (the default) only methods in the interface are included.
-
-EXTRACT_LOCAL_METHODS  = NO
-
-# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all 
-# undocumented members of documented classes, files or namespaces. 
-# If set to NO (the default) these members will be included in the 
-# various overviews, but no documentation section is generated. 
-# This option has no effect if EXTRACT_ALL is enabled.
-
-HIDE_UNDOC_MEMBERS     = NO
-
-# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all 
-# undocumented classes that are normally visible in the class hierarchy. 
-# If set to NO (the default) these classes will be included in the various 
-# overviews. This option has no effect if EXTRACT_ALL is enabled.
-
-HIDE_UNDOC_CLASSES     = NO
-
-# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all 
-# friend (class|struct|union) declarations. 
-# If set to NO (the default) these declarations will be included in the 
-# documentation.
-
-HIDE_FRIEND_COMPOUNDS  = NO
-
-# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any 
-# documentation blocks found inside the body of a function. 
-# If set to NO (the default) these blocks will be appended to the 
-# function's detailed documentation block.
-
-HIDE_IN_BODY_DOCS      = NO
-
-# The INTERNAL_DOCS tag determines if documentation 
-# that is typed after a \internal command is included. If the tag is set 
-# to NO (the default) then the documentation will be excluded. 
-# Set it to YES to include the internal documentation.
-
-INTERNAL_DOCS          = NO
-
-# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate 
-# file names in lower-case letters. If set to YES upper-case letters are also 
-# allowed. This is useful if you have classes or files whose names only differ 
-# in case and if your file system supports case sensitive file names. Windows 
-# and Mac users are advised to set this option to NO.
-
-CASE_SENSE_NAMES       = YES
-
-# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen 
-# will show members with their full class and namespace scopes in the 
-# documentation. If set to YES the scope will be hidden.
-
-HIDE_SCOPE_NAMES       = NO
-
-# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen 
-# will put a list of the files that are included by a file in the documentation 
-# of that file.
-
-SHOW_INCLUDE_FILES     = YES
-
-# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] 
-# is inserted in the documentation for inline members.
-
-INLINE_INFO            = YES
-
-# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen 
-# will sort the (detailed) documentation of file and class members 
-# alphabetically by member name. If set to NO the members will appear in 
-# declaration order.
-
-SORT_MEMBER_DOCS       = YES
-
-# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the 
-# brief documentation of file, namespace and class members alphabetically 
-# by member name. If set to NO (the default) the members will appear in 
-# declaration order.
-
-SORT_BRIEF_DOCS        = NO
-
-# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be 
-# sorted by fully-qualified names, including namespaces. If set to 
-# NO (the default), the class list will be sorted only by class name, 
-# not including the namespace part. 
-# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES.
-# Note: This option applies only to the class list, not to the 
-# alphabetical list.
-
-SORT_BY_SCOPE_NAME     = NO
-
-# The GENERATE_TODOLIST tag can be used to enable (YES) or 
-# disable (NO) the todo list. This list is created by putting \todo 
-# commands in the documentation.
-
-GENERATE_TODOLIST      = YES
-
-# The GENERATE_TESTLIST tag can be used to enable (YES) or 
-# disable (NO) the test list. This list is created by putting \test 
-# commands in the documentation.
-
-GENERATE_TESTLIST      = YES
-
-# The GENERATE_BUGLIST tag can be used to enable (YES) or 
-# disable (NO) the bug list. This list is created by putting \bug 
-# commands in the documentation.
-
-GENERATE_BUGLIST       = YES
-
-# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or 
-# disable (NO) the deprecated list. This list is created by putting 
-# \deprecated commands in the documentation.
-
-GENERATE_DEPRECATEDLIST= YES
-
-# The ENABLED_SECTIONS tag can be used to enable conditional 
-# documentation sections, marked by \if sectionname ... \endif.
-
-ENABLED_SECTIONS       = 
-
-# The MAX_INITIALIZER_LINES tag determines the maximum number of lines 
-# the initial value of a variable or define consists of for it to appear in 
-# the documentation. If the initializer consists of more lines than specified 
-# here it will be hidden. Use a value of 0 to hide initializers completely. 
-# The appearance of the initializer of individual variables and defines in the 
-# documentation can be controlled using \showinitializer or \hideinitializer 
-# command in the documentation regardless of this setting.
-
-MAX_INITIALIZER_LINES  = 30
-
-# Set the SHOW_USED_FILES tag to NO to disable the list of files generated 
-# at the bottom of the documentation of classes and structs. If set to YES the 
-# list will mention the files that were used to generate the documentation.
-
-SHOW_USED_FILES        = YES
-
-# If the sources in your project are distributed over multiple directories 
-# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy 
-# in the documentation.
-
-SHOW_DIRECTORIES       = YES
-
-#---------------------------------------------------------------------------
-# configuration options related to warning and progress messages
-#---------------------------------------------------------------------------
-
-# The QUIET tag can be used to turn on/off the messages that are generated 
-# by doxygen. Possible values are YES and NO. If left blank NO is used.
-
-QUIET                  = YES
-
-# The WARNINGS tag can be used to turn on/off the warning messages that are 
-# generated by doxygen. Possible values are YES and NO. If left blank 
-# NO is used.
-
-WARNINGS               = NO
-
-# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings 
-# for undocumented members. If EXTRACT_ALL is set to YES then this flag will 
-# automatically be disabled.
-
-WARN_IF_UNDOCUMENTED   = NO
-
-# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for 
-# potential errors in the documentation, such as not documenting some 
-# parameters in a documented function, or documenting parameters that 
-# don't exist or using markup commands wrongly.
-
-WARN_IF_DOC_ERROR      = YES
-
-# The WARN_FORMAT tag determines the format of the warning messages that 
-# doxygen can produce. The string should contain the $file, $line, and $text 
-# tags, which will be replaced by the file and line number from which the 
-# warning originated and the warning text.
-
-WARN_FORMAT            = "$file:$line: $text"
-
-# The WARN_LOGFILE tag can be used to specify a file to which warning 
-# and error messages should be written. If left blank the output is written 
-# to stderr.
-
-WARN_LOGFILE           = 
-
-#---------------------------------------------------------------------------
-# configuration options related to the input files
-#---------------------------------------------------------------------------
-
-# The INPUT tag can be used to specify the files and/or directories that contain 
-# documented source files. You may enter file names like "myfile.cpp" or 
-# directories like "/usr/src/myproject". Separate the files or directories 
-# with spaces.
-
-INPUT                  = . \
-                         desktop \
-                         dialogs \
-                         shell \
-                         taskbar \
-                         utility
-
-# If the value of the INPUT tag contains directories, you can use the 
-# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp 
-# and *.h) to filter out the source-files in the directories. If left 
-# blank the following patterns are tested: 
-# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx *.hpp 
-# *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm
-
-FILE_PATTERNS          = *.cpp \
-                         *.c \
-                         *.hpp \
-                         *.h
-
-# The RECURSIVE tag can be used to turn specify whether or not subdirectories 
-# should be searched for input files as well. Possible values are YES and NO. 
-# If left blank NO is used.
-
-RECURSIVE              = NO
-
-# The EXCLUDE tag can be used to specify files and/or directories that should 
-# excluded from the INPUT source files. This way you can easily exclude a 
-# subdirectory from a directory tree whose root is specified with the INPUT tag.
-
-EXCLUDE                = 
-
-# The EXCLUDE_SYMLINKS tag can be used select whether or not files or directories 
-# that are symbolic links (a Unix filesystem feature) are excluded from the input.
-
-EXCLUDE_SYMLINKS       = NO
-
-# If the value of the INPUT tag contains directories, you can use the 
-# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude 
-# certain files from those directories.
-
-EXCLUDE_PATTERNS       = 
-
-# The EXAMPLE_PATH tag can be used to specify one or more files or 
-# directories that contain example code fragments that are included (see 
-# the \include command).
-
-EXAMPLE_PATH           = 
-
-# If the value of the EXAMPLE_PATH tag contains directories, you can use the 
-# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp 
-# and *.h) to filter out the source-files in the directories. If left 
-# blank all files are included.
-
-EXAMPLE_PATTERNS       = 
-
-# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be 
-# searched for input files to be used with the \include or \dontinclude 
-# commands irrespective of the value of the RECURSIVE tag. 
-# Possible values are YES and NO. If left blank NO is used.
-
-EXAMPLE_RECURSIVE      = NO
-
-# The IMAGE_PATH tag can be used to specify one or more files or 
-# directories that contain image that are included in the documentation (see 
-# the \image command).
-
-IMAGE_PATH             = 
-
-# The INPUT_FILTER tag can be used to specify a program that doxygen should 
-# invoke to filter for each input file. Doxygen will invoke the filter program 
-# by executing (via popen()) the command <filter> <input-file>, where <filter> 
-# is the value of the INPUT_FILTER tag, and <input-file> is the name of an 
-# input file. Doxygen will then use the output that the filter program writes 
-# to standard output.  If FILTER_PATTERNS is specified, this tag will be 
-# ignored.
-
-INPUT_FILTER           = 
-
-# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern 
-# basis.  Doxygen will compare the file name with each pattern and apply the 
-# filter if there is a match.  The filters are a list of the form: 
-# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further 
-# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER 
-# is applied to all files.
-
-FILTER_PATTERNS        = 
-
-# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using 
-# INPUT_FILTER) will be used to filter the input files when producing source 
-# files to browse (i.e. when SOURCE_BROWSER is set to YES).
-
-FILTER_SOURCE_FILES    = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to source browsing
-#---------------------------------------------------------------------------
-
-# If the SOURCE_BROWSER tag is set to YES then a list of source files will 
-# be generated. Documented entities will be cross-referenced with these sources. 
-# Note: To get rid of all source code in the generated output, make sure also 
-# VERBATIM_HEADERS is set to NO.
-
-SOURCE_BROWSER         = YES
-
-# Setting the INLINE_SOURCES tag to YES will include the body 
-# of functions and classes directly in the documentation.
-
-INLINE_SOURCES         = YES
-
-# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct 
-# doxygen to hide any special comment blocks from generated source code 
-# fragments. Normal C and C++ comments will always remain visible.
-
-STRIP_CODE_COMMENTS    = YES
-
-# If the REFERENCED_BY_RELATION tag is set to YES (the default) 
-# then for each documented function all documented 
-# functions referencing it will be listed.
-
-REFERENCED_BY_RELATION = YES
-
-# If the REFERENCES_RELATION tag is set to YES (the default) 
-# then for each documented function all documented entities 
-# called/used by that function will be listed.
-
-REFERENCES_RELATION    = YES
-
-# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen 
-# will generate a verbatim copy of the header file for each class for 
-# which an include is specified. Set to NO to disable this.
-
-VERBATIM_HEADERS       = YES
-
-#---------------------------------------------------------------------------
-# configuration options related to the alphabetical class index
-#---------------------------------------------------------------------------
-
-# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index 
-# of all compounds will be generated. Enable this if the project 
-# contains a lot of classes, structs, unions or interfaces.
-
-ALPHABETICAL_INDEX     = YES
-
-# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then 
-# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns 
-# in which this list will be split (can be a number in the range [1..20])
-
-COLS_IN_ALPHA_INDEX    = 5
-
-# In case all classes in a project start with a common prefix, all 
-# classes will be put under the same header in the alphabetical index. 
-# The IGNORE_PREFIX tag can be used to specify one or more prefixes that 
-# should be ignored while generating the index headers.
-
-IGNORE_PREFIX          = 
-
-#---------------------------------------------------------------------------
-# configuration options related to the HTML output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_HTML tag is set to YES (the default) Doxygen will 
-# generate HTML output.
-
-GENERATE_HTML          = YES
-
-# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `html' will be used as the default path.
-
-HTML_OUTPUT            = html
-
-# The HTML_FILE_EXTENSION tag can be used to specify the file extension for 
-# each generated HTML page (for example: .htm,.php,.asp). If it is left blank 
-# doxygen will generate files with .html extension.
-
-HTML_FILE_EXTENSION    = .html
-
-# The HTML_HEADER tag can be used to specify a personal HTML header for 
-# each generated HTML page. If it is left blank doxygen will generate a 
-# standard header.
-
-HTML_HEADER            = 
-
-# The HTML_FOOTER tag can be used to specify a personal HTML footer for 
-# each generated HTML page. If it is left blank doxygen will generate a 
-# standard footer.
-
-HTML_FOOTER            = doxy-footer.html
-
-# The HTML_STYLESHEET tag can be used to specify a user-defined cascading 
-# style sheet that is used by each HTML page. It can be used to 
-# fine-tune the look of the HTML output. If the tag is left blank doxygen 
-# will generate a default style sheet. Note that doxygen will try to copy 
-# the style sheet file to the HTML output directory, so don't put your own 
-# stylesheet in the HTML output directory as well, or it will be erased!
-
-HTML_STYLESHEET        = 
-
-# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, 
-# files or namespaces will be aligned in HTML using tables. If set to 
-# NO a bullet list will be used.
-
-HTML_ALIGN_MEMBERS     = YES
-
-# If the GENERATE_HTMLHELP tag is set to YES, additional index files 
-# will be generated that can be used as input for tools like the 
-# Microsoft HTML help workshop to generate a compressed HTML help file (.chm) 
-# of the generated HTML documentation.
-
-GENERATE_HTMLHELP      = YES
-
-# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can 
-# be used to specify the file name of the resulting .chm file. You 
-# can add a path in front of the file if the result should not be 
-# written to the html output directory.
-
-CHM_FILE               = 
-
-# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can 
-# be used to specify the location (absolute path including file name) of 
-# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run 
-# the HTML help compiler on the generated index.hhp.
-
-HHC_LOCATION           = 
-
-# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag 
-# controls if a separate .chi index file is generated (YES) or that 
-# it should be included in the master .chm file (NO).
-
-GENERATE_CHI           = NO
-
-# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag 
-# controls whether a binary table of contents is generated (YES) or a 
-# normal table of contents (NO) in the .chm file.
-
-BINARY_TOC             = NO
-
-# The TOC_EXPAND flag can be set to YES to add extra items for group members 
-# to the contents of the HTML help documentation and to the tree view.
-
-TOC_EXPAND             = NO
-
-# The DISABLE_INDEX tag can be used to turn on/off the condensed index at 
-# top of each HTML page. The value NO (the default) enables the index and 
-# the value YES disables it.
-
-DISABLE_INDEX          = NO
-
-# This tag can be used to set the number of enum values (range [1..20]) 
-# that doxygen will group on one line in the generated HTML documentation.
-
-ENUM_VALUES_PER_LINE   = 4
-
-# If the GENERATE_TREEVIEW tag is set to YES, a side panel will be
-# generated containing a tree-like index structure (just like the one that 
-# is generated for HTML Help). For this to work a browser that supports 
-# JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+, 
-# Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are 
-# probably better off using the HTML help feature.
-
-GENERATE_TREEVIEW      = YES
-
-# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be 
-# used to set the initial width (in pixels) of the frame in which the tree 
-# is shown.
-
-TREEVIEW_WIDTH         = 240
-
-#---------------------------------------------------------------------------
-# configuration options related to the LaTeX output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will 
-# generate Latex output.
-
-GENERATE_LATEX         = NO
-
-# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `latex' will be used as the default path.
-
-LATEX_OUTPUT           = latex
-
-# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be 
-# invoked. If left blank `latex' will be used as the default command name.
-
-LATEX_CMD_NAME         = latex
-
-# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to 
-# generate index for LaTeX. If left blank `makeindex' will be used as the 
-# default command name.
-
-MAKEINDEX_CMD_NAME     = makeindex
-
-# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact 
-# LaTeX documents. This may be useful for small projects and may help to 
-# save some trees in general.
-
-COMPACT_LATEX          = NO
-
-# The PAPER_TYPE tag can be used to set the paper type that is used 
-# by the printer. Possible values are: a4, a4wide, letter, legal and 
-# executive. If left blank a4wide will be used.
-
-PAPER_TYPE             = a4wide
-
-# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX 
-# packages that should be included in the LaTeX output.
-
-EXTRA_PACKAGES         = 
-
-# The LATEX_HEADER tag can be used to specify a personal LaTeX header for 
-# the generated latex document. The header should contain everything until 
-# the first chapter. If it is left blank doxygen will generate a 
-# standard header. Notice: only use this tag if you know what you are doing!
-
-LATEX_HEADER           = 
-
-# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated 
-# is prepared for conversion to pdf (using ps2pdf). The pdf file will 
-# contain links (just like the HTML output) instead of page references 
-# This makes the output suitable for online browsing using a pdf viewer.
-
-PDF_HYPERLINKS         = NO
-
-# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of 
-# plain latex in the generated Makefile. Set this option to YES to get a 
-# higher quality PDF documentation.
-
-USE_PDFLATEX           = NO
-
-# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. 
-# command to the generated LaTeX files. This will instruct LaTeX to keep 
-# running if errors occur, instead of asking the user for help. 
-# This option is also used when generating formulas in HTML.
-
-LATEX_BATCHMODE        = NO
-
-# If LATEX_HIDE_INDICES is set to YES then doxygen will not 
-# include the index chapters (such as File Index, Compound Index, etc.) 
-# in the output.
-
-LATEX_HIDE_INDICES     = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the RTF output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output 
-# The RTF output is optimized for Word 97 and may not look very pretty with 
-# other RTF readers or editors.
-
-GENERATE_RTF           = NO
-
-# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `rtf' will be used as the default path.
-
-RTF_OUTPUT             = rtf
-
-# If the COMPACT_RTF tag is set to YES Doxygen generates more compact 
-# RTF documents. This may be useful for small projects and may help to 
-# save some trees in general.
-
-COMPACT_RTF            = YES
-
-# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated 
-# will contain hyperlink fields. The RTF file will 
-# contain links (just like the HTML output) instead of page references. 
-# This makes the output suitable for online browsing using WORD or other 
-# programs which support those fields. 
-# Note: wordpad (write) and others do not support links.
-
-RTF_HYPERLINKS         = YES
-
-# Load stylesheet definitions from file. Syntax is similar to doxygen's 
-# config file, i.e. a series of assignments. You only have to provide 
-# replacements, missing definitions are set to their default value.
-
-RTF_STYLESHEET_FILE    = 
-
-# Set optional variables used in the generation of an rtf document. 
-# Syntax is similar to doxygen's config file.
-
-RTF_EXTENSIONS_FILE    = 
-
-#---------------------------------------------------------------------------
-# configuration options related to the man page output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_MAN tag is set to YES (the default) Doxygen will 
-# generate man pages
-
-GENERATE_MAN           = NO
-
-# The MAN_OUTPUT tag is used to specify where the man pages will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `man' will be used as the default path.
-
-MAN_OUTPUT             = man
-
-# The MAN_EXTENSION tag determines the extension that is added to 
-# the generated man pages (default is the subroutine's section .3)
-
-MAN_EXTENSION          = .3
-
-# If the MAN_LINKS tag is set to YES and Doxygen generates man output, 
-# then it will generate one additional man file for each entity 
-# documented in the real man page(s). These additional files 
-# only source the real man page, but without them the man command 
-# would be unable to find the correct page. The default is NO.
-
-MAN_LINKS              = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the XML output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_XML tag is set to YES Doxygen will 
-# generate an XML file that captures the structure of 
-# the code including all documentation.
-
-GENERATE_XML           = NO
-
-# The XML_OUTPUT tag is used to specify where the XML pages will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `xml' will be used as the default path.
-
-XML_OUTPUT             = xml
-
-# The XML_SCHEMA tag can be used to specify an XML schema, 
-# which can be used by a validating XML parser to check the 
-# syntax of the XML files.
-
-XML_SCHEMA             = 
-
-# The XML_DTD tag can be used to specify an XML DTD, 
-# which can be used by a validating XML parser to check the 
-# syntax of the XML files.
-
-XML_DTD                = 
-
-# If the XML_PROGRAMLISTING tag is set to YES Doxygen will 
-# dump the program listings (including syntax highlighting 
-# and cross-referencing information) to the XML output. Note that 
-# enabling this will significantly increase the size of the XML output.
-
-XML_PROGRAMLISTING     = YES
-
-#---------------------------------------------------------------------------
-# configuration options for the AutoGen Definitions output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will 
-# generate an AutoGen Definitions (see autogen.sf.net) file 
-# that captures the structure of the code including all 
-# documentation. Note that this feature is still experimental 
-# and incomplete at the moment.
-
-GENERATE_AUTOGEN_DEF   = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the Perl module output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_PERLMOD tag is set to YES Doxygen will 
-# generate a Perl module file that captures the structure of 
-# the code including all documentation. Note that this 
-# feature is still experimental and incomplete at the 
-# moment.
-
-GENERATE_PERLMOD       = NO
-
-# If the PERLMOD_LATEX tag is set to YES Doxygen will generate 
-# the necessary Makefile rules, Perl scripts and LaTeX code to be able 
-# to generate PDF and DVI output from the Perl module output.
-
-PERLMOD_LATEX          = NO
-
-# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be 
-# nicely formatted so it can be parsed by a human reader.  This is useful 
-# if you want to understand what is going on.  On the other hand, if this 
-# tag is set to NO the size of the Perl module output will be much smaller 
-# and Perl will parse it just the same.
-
-PERLMOD_PRETTY         = YES
-
-# The names of the make variables in the generated doxyrules.make file 
-# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. 
-# This is useful so different doxyrules.make files included by the same 
-# Makefile don't overwrite each other's variables.
-
-PERLMOD_MAKEVAR_PREFIX = 
-
-#---------------------------------------------------------------------------
-# Configuration options related to the preprocessor   
-#---------------------------------------------------------------------------
-
-# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will 
-# evaluate all C-preprocessor directives found in the sources and include 
-# files.
-
-ENABLE_PREPROCESSING   = YES
-
-# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro 
-# names in the source code. If set to NO (the default) only conditional 
-# compilation will be performed. Macro expansion can be done in a controlled 
-# way by setting EXPAND_ONLY_PREDEF to YES.
-
-MACRO_EXPANSION        = NO
-
-# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES 
-# then the macro expansion is limited to the macros specified with the 
-# PREDEFINED and EXPAND_AS_PREDEFINED tags.
-
-EXPAND_ONLY_PREDEF     = NO
-
-# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files 
-# in the INCLUDE_PATH (see below) will be search if a #include is found.
-
-SEARCH_INCLUDES        = YES
-
-# The INCLUDE_PATH tag can be used to specify one or more directories that 
-# contain include files that are not input files but should be processed by 
-# the preprocessor.
-
-INCLUDE_PATH           = 
-
-# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard 
-# patterns (like *.h and *.hpp) to filter out the header-files in the 
-# directories. If left blank, the patterns specified with FILE_PATTERNS will 
-# be used.
-
-INCLUDE_FILE_PATTERNS  = 
-
-# The PREDEFINED tag can be used to specify one or more macro names that 
-# are defined before the preprocessor is started (similar to the -D option of 
-# gcc). The argument of the tag is a list of macros of the form: name 
-# or name=definition (no spaces). If the definition and the = are 
-# omitted =1 is assumed. To prevent a macro definition from being 
-# undefined via #undef or recursively expanded use the := operator 
-# instead of the = operator.
-
-PREDEFINED             = __cplusplus
-
-# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then 
-# this tag can be used to specify a list of macro names that should be expanded. 
-# The macro definition that is found in the sources will be used. 
-# Use the PREDEFINED tag if you want to use a different macro definition.
-
-EXPAND_AS_DEFINED      = 
-
-# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then 
-# doxygen's preprocessor will remove all function-like macros that are alone 
-# on a line, have an all uppercase name, and do not end with a semicolon. Such 
-# function macros are typically used for boiler-plate code, and will confuse the 
-# parser if not removed.
-
-SKIP_FUNCTION_MACROS   = YES
-
-#---------------------------------------------------------------------------
-# Configuration::additions related to external references   
-#---------------------------------------------------------------------------
-
-# The TAGFILES option can be used to specify one or more tagfiles. 
-# Optionally an initial location of the external documentation 
-# can be added for each tagfile. The format of a tag file without 
-# this location is as follows: 
-#   TAGFILES = file1 file2 ... 
-# Adding location for the tag files is done as follows: 
-#   TAGFILES = file1=loc1 "file2 = loc2" ... 
-# where "loc1" and "loc2" can be relative or absolute paths or 
-# URLs. If a location is present for each tag, the installdox tool 
-# does not have to be run to correct the links.
-# Note that each tag file must have a unique name
-# (where the name does NOT include the path)
-# If a tag file is not located in the directory in which doxygen 
-# is run, you must also specify the path to the tagfile here.
-
-TAGFILES               = 
-
-# When a file name is specified after GENERATE_TAGFILE, doxygen will create 
-# a tag file that is based on the input files it reads.
-
-GENERATE_TAGFILE       = 
-
-# If the ALLEXTERNALS tag is set to YES all external classes will be listed 
-# in the class index. If set to NO only the inherited external classes 
-# will be listed.
-
-ALLEXTERNALS           = NO
-
-# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed 
-# in the modules index. If set to NO, only the current project's groups will 
-# be listed.
-
-EXTERNAL_GROUPS        = YES
-
-# The PERL_PATH should be the absolute path and name of the perl script 
-# interpreter (i.e. the result of `which perl').
-
-PERL_PATH              = /usr/bin/perl
-
-#---------------------------------------------------------------------------
-# Configuration options related to the dot tool   
-#---------------------------------------------------------------------------
-
-# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will 
-# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base or 
-# super classes. Setting the tag to NO turns the diagrams off. Note that this 
-# option is superseded by the HAVE_DOT option below. This is only a fallback. It is 
-# recommended to install and use dot, since it yields more powerful graphs.
-
-CLASS_DIAGRAMS         = YES
-
-# If set to YES, the inheritance and collaboration graphs will hide 
-# inheritance and usage relations if the target is undocumented 
-# or is not a class.
-
-HIDE_UNDOC_RELATIONS   = NO
-
-# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is 
-# available from the path. This tool is part of Graphviz, a graph visualization 
-# toolkit from AT&T and Lucent Bell Labs. The other options in this section 
-# have no effect if this option is set to NO (the default)
-
-HAVE_DOT               = YES
-
-# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen 
-# will generate a graph for each documented class showing the direct and 
-# indirect inheritance relations. Setting this tag to YES will force the 
-# the CLASS_DIAGRAMS tag to NO.
-
-CLASS_GRAPH            = YES
-
-# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen 
-# will generate a graph for each documented class showing the direct and 
-# indirect implementation dependencies (inheritance, containment, and 
-# class references variables) of the class with other documented classes.
-
-COLLABORATION_GRAPH    = YES
-
-# If the UML_LOOK tag is set to YES doxygen will generate inheritance and 
-# collaboration diagrams in a style similar to the OMG's Unified Modeling 
-# Language.
-
-UML_LOOK               = NO
-
-# If set to YES, the inheritance and collaboration graphs will show the 
-# relations between templates and their instances.
-
-TEMPLATE_RELATIONS     = NO
-
-# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT 
-# tags are set to YES then doxygen will generate a graph for each documented 
-# file showing the direct and indirect include dependencies of the file with 
-# other documented files.
-
-INCLUDE_GRAPH          = YES
-
-# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and 
-# HAVE_DOT tags are set to YES then doxygen will generate a graph for each 
-# documented header file showing the documented files that directly or 
-# indirectly include this file.
-
-INCLUDED_BY_GRAPH      = YES
-
-# If the CALL_GRAPH and HAVE_DOT tags are set to YES then doxygen will 
-# generate a call dependency graph for every global function or class method. 
-# Note that enabling this option will significantly increase the time of a run. 
-# So in most cases it will be better to enable call graphs for selected 
-# functions only using the \callgraph command.
-
-CALL_GRAPH             = YES
-
-# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen 
-# will graphical hierarchy of all classes instead of a textual one.
-
-GRAPHICAL_HIERARCHY    = YES
-
-# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images 
-# generated by dot. Possible values are png, jpg, or gif
-# If left blank png will be used.
-
-DOT_IMAGE_FORMAT       = png
-
-# The tag DOT_PATH can be used to specify the path where the dot tool can be 
-# found. If left blank, it is assumed the dot tool can be found on the path.
-
-DOT_PATH               = 
-
-# The DOTFILE_DIRS tag can be used to specify one or more directories that 
-# contain dot files that are included in the documentation (see the 
-# \dotfile command).
-
-DOTFILE_DIRS           = 
-
-# The MAX_DOT_GRAPH_WIDTH tag can be used to set the maximum allowed width 
-# (in pixels) of the graphs generated by dot. If a graph becomes larger than 
-# this value, doxygen will try to truncate the graph, so that it fits within 
-# the specified constraint. Beware that most browsers cannot cope with very 
-# large images.
-
-MAX_DOT_GRAPH_WIDTH    = 1024
-
-# The MAX_DOT_GRAPH_HEIGHT tag can be used to set the maximum allows height 
-# (in pixels) of the graphs generated by dot. If a graph becomes larger than 
-# this value, doxygen will try to truncate the graph, so that it fits within 
-# the specified constraint. Beware that most browsers cannot cope with very 
-# large images.
-
-MAX_DOT_GRAPH_HEIGHT   = 1024
-
-# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the 
-# graphs generated by dot. A depth value of 3 means that only nodes reachable 
-# from the root by following a path via at most 3 edges will be shown. Nodes that 
-# lay further from the root node will be omitted. Note that setting this option to 
-# 1 or 2 may greatly reduce the computation time needed for large code bases. Also 
-# note that a graph may be further truncated if the graph's image dimensions are 
-# not sufficient to fit the graph (see MAX_DOT_GRAPH_WIDTH and MAX_DOT_GRAPH_HEIGHT). 
-# If 0 is used for the depth value (the default), the graph is not depth-constrained.
-
-MAX_DOT_GRAPH_DEPTH    = 0
-
-# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will 
-# generate a legend page explaining the meaning of the various boxes and 
-# arrows in the dot generated graphs.
-
-GENERATE_LEGEND        = YES
-
-# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will 
-# remove the intermediate dot files that are used to generate 
-# the various graphs.
-
-DOT_CLEANUP            = YES
-
-#---------------------------------------------------------------------------
-# Configuration::additions related to the search engine   
-#---------------------------------------------------------------------------
-
-# The SEARCHENGINE tag specifies whether or not a search engine should be 
-# used. If set to NO the values of all tags below this one will be ignored.
-
-SEARCHENGINE           = YES
diff --git a/reactos/subsys/system/explorer/Jamfile b/reactos/subsys/system/explorer/Jamfile
deleted file mode 100644 (file)
index 0938167..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-#
-# Jamfile for Explorer to be used with Boost Build V2
-#
-
-
-# import rc ;
-import rc-mingw ;
-
-
-EXPAT_INC = [ modules.peek : EXPAT_INC ] ;
-
-exe explorer :
-       explorer.cpp
-       explorer_intres.rc
-       shell/entries.cpp
-       shell/filechild.cpp
-       shell/mainframe.cpp
-       shell/pane.cpp
-       shell/shellbrowser.cpp
-       shell/shellfs.cpp
-       shell/unixfs.cpp
-       shell/winfs.cpp
-       shell/ntobjfs.cpp
-       shell/regfs.cpp
-       shell/fatfs.cpp
-       shell/webchild.cpp
-       services/startup.c
-       services/shellservices.cpp
-       taskbar/desktopbar.cpp
-       taskbar/quicklaunch.cpp
-       taskbar/startmenu.cpp
-       taskbar/taskbar.cpp
-       taskbar/traynotify.cpp
-       taskbar/favorites.cpp
-       desktop/desktop.cpp
-#      utility/splitpath.c
-       utility/dragdropimpl.cpp
-       utility/shellbrowserimpl.cpp
-       utility/shellclasses.cpp
-       utility/utility.cpp
-       utility/window.cpp
-       utility/xmlstorage.cpp
-       dialogs/searchprogram.cpp
-       dialogs/settings.cpp
-       i386-stub-win32.c
- :     <define>WIN32 <define>_WIN32_IE=0x0600 <define>_WIN32_WINNT=0x0501 <define>WINVER=0x0500
-       <include>. <include>$(EXPAT_INC)
-# only for GCC:        <cxxflags>-fexceptions <cxxflags>-Wall <cxxflags>-Wno-unused-value
-       <find-shared-library>gdi32
-       <find-shared-library>ole32
-       <find-shared-library>comctl32
-       <find-shared-library>uuid
-       <find-shared-library>wsock32
-       <find-shared-library>oleaut32
-       <find-shared-library>msimg32
-#      <find-shared-library>expat
-       <linkflags>notifyhook.dll
-       <linkflags>libexpat.dll
- ;
-
diff --git a/reactos/subsys/system/explorer/Make-rosshell.MinGW b/reactos/subsys/system/explorer/Make-rosshell.MinGW
deleted file mode 100644 (file)
index 6d20a9c..0000000
+++ /dev/null
@@ -1,92 +0,0 @@
-#\r
-#  ReactOS shell\r
-#\r
-#  Makefile.PCH\r
-#\r
-#  MinGW Makefile with precompiled header support\r
-#\r
-\r
-CC = gcc\r
-CXX = g++\r
-LINK = g++\r
-\r
-CFLAGS = -DWIN32 -DROSSHELL -D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 -fexceptions -Wall -I. -I$(EXPAT_INC)\r
-RCFLAGS        = -DWIN32 -DROSSHELL -D__WINDRES__\r
-LFLAGS = -Wl,--subsystem,windows\r
-\r
-ifdef DEBUG\r
-CFLAGS += -D_DEBUG -g\r
-RCFLAGS        += -D_DEBUG\r
-LFLAGS += -g\r
-else\r
-CFLAGS += -DNDEBUG -Os #-march=pentium4\r
-RCFLAGS        += -DNDEBUG\r
-LFLAGS += -s\r
-endif\r
-\r
-ifndef UNICODE\r
-UNICODE = 1\r
-endif\r
-\r
-ifeq ($(UNICODE),1)\r
-CFLAGS += -DUNICODE\r
-# LFLAGS+= -Wl,--entry,_wWinMain@16\r
-RCFLAGS += -DUNICODE\r
-endif\r
-\r
-CXXFLAGS = $(CFLAGS)\r
-\r
-EXEC_SUFFIX = .exe\r
-RES_SUFFIX = .coff\r
-\r
-VPATH = shell utility taskbar desktop dialogs services\r
-\r
-PROGRAM = rosshell\r
-\r
-TARGET = $(PROGRAM)$(EXEC_SUFFIX)\r
-\r
-OBJECTS = \\r
-       startup.o \\r
-       shellclasses.o \\r
-       utility.o \\r
-       window.o \\r
-       dragdropimpl.o \\r
-       shellbrowserimpl.o \\r
-       explorer.o \\r
-       entries.o \\r
-       winfs.o \\r
-       shellfs.o \\r
-       pane.o \\r
-       desktop.o \\r
-       desktopbar.o \\r
-       taskbar.o \\r
-       startmenu.o \\r
-       shellservices.o \\r
-       traynotify.o \\r
-       quicklaunch.o \\r
-       favorites.o \\r
-       searchprogram.o \\r
-       settings.o \\r
-       i386-stub-win32.o \\r
-       xmlstorage.o\r
-\r
-LIBS = gdi32 comctl32 msimg32 ole32 uuid\r
-DELAYIMPORTS = oleaut32 wsock32\r
-\r
-all: precomp.h.gch $(TARGET)\r
-\r
-precomp.h.gch: *.h utility/*.h shell/*.h desktop/*.h\r
-       $(CXX) $(CFLAGS) precomp.h\r
-\r
-$(TARGET): $(OBJECTS) $(PROGRAM)$(RES_SUFFIX) notifyhook.dll libexpat.dll\r
-       $(LINK) $(LFLAGS) -o $@ $^ $(addprefix -l,$(LIBS)) $(addprefix -l,$(DELAYIMPORTS))\r
-\r
-$(PROGRAM)$(RES_SUFFIX): explorer_intres.rc res/*.bmp res/*.ico\r
-       windres $(RCFLAGS) -o $@ explorer_intres.rc\r
-\r
-notifyhook.dll: notifyhook/notifyhook.c notifyhook/notifyhook.h\r
-       $(CC) -D_WIN32_IE=0x0600 -Wall -D_NOTIFYHOOK_IMPL -Os -s notifyhook/notifyhook.c -shared -o $@\r
-\r
-clean:\r
-       rm -f $(TARGET) $(OBJECTS) $(PROGRAM)$(RES_SUFFIX) precomp.h.gch \\r
-       desktop/*.o dialogs/*.o shell/*.o taskbar/*.o utility/*.o\r
diff --git a/reactos/subsys/system/explorer/Make-rosshell.mak b/reactos/subsys/system/explorer/Make-rosshell.mak
deleted file mode 100644 (file)
index fa428b1..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-#\r
-#  ReactOS shell\r
-#\r
-#  Makefile\r
-#\r
-\r
-PATH_TO_TOP := ../../..\r
-\r
-TARGET_TYPE := program\r
-\r
-TARGET_APPTYPE := windows\r
-\r
-TARGET_NAME := rosshell\r
-\r
-TARGET_INSTALLDIR := .\r
-\r
-TARGET_CFLAGS := \\r
-       -D__USE_W32API -DWIN32 -D_ROS_ \\r
-       -D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 \\r
-       -DUNICODE -fexceptions -Wall -g \\r
-       -I../../../include/expat\r
-\r
-TARGET_CPPFLAGS := $(TARGET_CFLAGS)\r
-\r
-TARGET_RCFLAGS := -D__USE_W32API -DWIN32 -D_ROS_ -D__WINDRES__\r
-\r
-TARGET_SDKLIBS := \\r
-       gdi32.a user32.a comctl32.a ole32.a oleaut32.a shell32.a expat.a \\r
-       notifyhook.a ws2_32.a msimg32.a\r
-\r
-TARGET_GCCLIBS := stdc++ uuid\r
-\r
-TARGET_OBJECTS := \\r
-       explorer.o \\r
-       i386-stub-win32.o \\r
-       desktop/desktop.o \\r
-       dialogs/searchprogram.o \\r
-       dialogs/settings.o \\r
-       shell/entries.o \\r
-       shell/shellfs.o \\r
-       shell/pane.o \\r
-       shell/winfs.o \\r
-       services/startup.o \\r
-       services/shellservices.o \\r
-       taskbar/desktopbar.o \\r
-       taskbar/taskbar.o \\r
-       taskbar/startmenu.o \\r
-       taskbar/traynotify.o \\r
-       taskbar/quicklaunch.o \\r
-       taskbar/favorites.o \\r
-       utility/shellclasses.o \\r
-       utility/utility.o \\r
-       utility/window.o \\r
-       utility/dragdropimpl.o \\r
-       utility/shellbrowserimpl.o \\r
-       utility/xmlstorage.o\r
-\r
-TARGET_CPPAPP := yes\r
-\r
-TARGET_PCH := precomp.h\r
-\r
-SUBDIRS := notifyhook\r
-\r
-DEP_OBJECTS := $(TARGET_OBJECTS)\r
-\r
-include $(PATH_TO_TOP)/rules.mak\r
-include $(TOOLS_PATH)/helper.mk\r
-include $(TOOLS_PATH)/depend.mk\r
diff --git a/reactos/subsys/system/explorer/Makefile.MinGW b/reactos/subsys/system/explorer/Makefile.MinGW
deleted file mode 100644 (file)
index 678fe28..0000000
+++ /dev/null
@@ -1,96 +0,0 @@
-#
-#  ReactOS explorer
-#
-#  Makefile.MinGW
-#
-
-CC = gcc
-CXX = g++
-LINK = g++
-
-# -D_NO_ALPHABLEND for builds without msimg32.dll dependency
-CFLAGS = -DWIN32 -D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 -fexceptions -Wall -I. -I$(EXPAT_INC)
-RCFLAGS        = -DWIN32 -D__WINDRES__
-LFLAGS = -Wl,--subsystem,windows
-
-ifdef DEBUG
-CFLAGS += -D_DEBUG -g
-RCFLAGS        += -D_DEBUG
-LFLAGS += -g
-else
-CFLAGS += -DNDEBUG -Os
-RCFLAGS        += -DNDEBUG
-LFLAGS += -s
-endif
-
-ifndef UNICODE
-UNICODE = 1
-endif
-
-ifeq ($(UNICODE),1)
-CFLAGS += -DUNICODE
-# LFLAGS+= -Wl,--entry,_wWinMain@16
-RCFLAGS += -DUNICODE
-endif
-
-CXXFLAGS = $(CFLAGS)
-
-EXEC_SUFFIX = .exe
-RES_SUFFIX = .coff
-
-VPATH = shell utility taskbar desktop dialogs services
-
-PROGRAM = explorer
-
-TARGET = $(PROGRAM)$(EXEC_SUFFIX)
-
-OBJECTS = \
-       startup.o \
-       shellclasses.o \
-       utility.o \
-       window.o \
-       dragdropimpl.o \
-       shellbrowserimpl.o \
-       shellservices.o \
-       explorer.o \
-       entries.o \
-       winfs.o \
-       unixfs.o \
-       shellfs.o \
-       ntobjfs.o \
-       regfs.o \
-       fatfs.o \
-       webchild.o \
-       mainframe.o \
-       filechild.o \
-       pane.o \
-       shellbrowser.o \
-       desktop.o \
-       desktopbar.o \
-       taskbar.o \
-       startmenu.o \
-       traynotify.o \
-       quicklaunch.o \
-       favorites.o \
-       searchprogram.o \
-       settings.o \
-       i386-stub-win32.o \
-       xmlstorage.o
-
-LIBS = gdi32 comctl32 msimg32 ole32 uuid
-DELAYIMPORTS = oleaut32 wsock32
-
-all: $(TARGET)
-
-$(TARGET): $(OBJECTS) $(PROGRAM)$(RES_SUFFIX) notifyhook.dll libexpat.dll
-       $(LINK) $(LFLAGS) -o $@ $^ $(addprefix -l,$(LIBS)) $(addprefix -l,$(DELAYIMPORTS))
-
-$(PROGRAM)$(RES_SUFFIX): $(PROGRAM)_intres.rc res/*.bmp res/*.ico
-       windres $(RCFLAGS) -o $@ $(PROGRAM)_intres.rc
-
-notifyhook.dll: notifyhook/notifyhook.c notifyhook/notifyhook.h
-       $(CC) -D_WIN32_IE=0x0600 -Wall -D_NOTIFYHOOK_IMPL -Os -s notifyhook/notifyhook.c -shared -o $@
-
-clean:
-       rm -f $(TARGET) $(OBJECTS) $(PROGRAM)$(RES_SUFFIX) \
-       desktop/*.o dialogs/*.o shell/*.o taskbar/*.o utility/*.o
diff --git a/reactos/subsys/system/explorer/Makefile.PCH b/reactos/subsys/system/explorer/Makefile.PCH
deleted file mode 100644 (file)
index a301d6a..0000000
+++ /dev/null
@@ -1,100 +0,0 @@
-#
-#  ReactOS explorer
-#
-#  Makefile.PCH
-#
-#  MinGW Makefile with precompiled header support
-#
-
-CC = gcc
-CXX = g++
-LINK = g++
-
-CFLAGS = -DWIN32 -D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 -fexceptions -Wall -I. -I$(EXPAT_INC)
-RCFLAGS        = -DWIN32 -D__WINDRES__
-LFLAGS = -Wl,--subsystem,windows
-
-ifdef DEBUG
-CFLAGS += -D_DEBUG -g
-RCFLAGS        += -D_DEBUG
-LFLAGS += -g
-else
-CFLAGS += -DNDEBUG -Os #-march=pentium4
-RCFLAGS        += -DNDEBUG
-LFLAGS += -s
-endif
-
-ifndef UNICODE
-UNICODE = 1
-endif
-
-ifeq ($(UNICODE),1)
-CFLAGS += -DUNICODE
-# LFLAGS+= -Wl,--entry,_wWinMain@16
-RCFLAGS += -DUNICODE
-endif
-
-CXXFLAGS = $(CFLAGS)
-
-EXEC_SUFFIX = .exe
-RES_SUFFIX = .coff
-
-VPATH = shell utility taskbar desktop dialogs services
-
-PROGRAM = explorer
-
-TARGET = $(PROGRAM)$(EXEC_SUFFIX)
-
-OBJECTS = \
-       startup.o \
-       shellclasses.o \
-       utility.o \
-       window.o \
-       dragdropimpl.o \
-       shellbrowserimpl.o \
-       shellservices.o \
-       explorer.o \
-       entries.o \
-       winfs.o \
-       unixfs.o \
-       shellfs.o \
-       ntobjfs.o \
-       regfs.o \
-       fatfs.o \
-       webchild.o \
-       mainframe.o \
-       filechild.o \
-       pane.o \
-       shellbrowser.o \
-       desktop.o \
-       desktopbar.o \
-       taskbar.o \
-       startmenu.o \
-       traynotify.o \
-       quicklaunch.o \
-       favorites.o \
-       searchprogram.o \
-       settings.o \
-       i386-stub-win32.o \
-       xmlstorage.o
-
-LIBS = gdi32 comctl32 msimg32 ole32 uuid
-DELAYIMPORTS = oleaut32 wsock32
-
-all: precomp.h.gch $(TARGET)
-
-precomp.h.gch: *.h utility/*.h shell/*.h desktop/*.h
-       $(CXX) $(CFLAGS) precomp.h
-
-$(TARGET): $(OBJECTS) $(PROGRAM)$(RES_SUFFIX) notifyhook.dll libexpat.dll
-       $(LINK) $(LFLAGS) -o $@ $^ $(addprefix -l,$(LIBS)) $(addprefix -l,$(DELAYIMPORTS))
-
-$(PROGRAM)$(RES_SUFFIX): explorer_intres.rc res/*.bmp res/*.ico
-       windres $(RCFLAGS) -o $@ explorer_intres.rc
-
-notifyhook.dll: notifyhook/notifyhook.c notifyhook/notifyhook.h
-       $(CC) -D_WIN32_IE=0x0600 -Wall -D_NOTIFYHOOK_IMPL -Os -s notifyhook/notifyhook.c -shared -o $@
-
-clean:
-       rm -f $(TARGET) $(OBJECTS) $(PROGRAM)$(RES_SUFFIX) precomp.h.gch \
-       desktop/*.o dialogs/*.o shell/*.o taskbar/*.o utility/*.o
diff --git a/reactos/subsys/system/explorer/Makefile.Wine b/reactos/subsys/system/explorer/Makefile.Wine
deleted file mode 100644 (file)
index c4d51b3..0000000
+++ /dev/null
@@ -1,400 +0,0 @@
-TOPSRCDIR = ../..
-TOPOBJDIR = ../..
-SRCDIR    = .
-
-MODULE    = explorer.exe
-APPMODE   = gui
-IMPORTS   = shell32 comctl32 msimg32 ole32 user32 gdi32 kernel32 advapi32 oleaut32
-EXTRADEFS = -D__WINE__ -D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 -D__MINGW32__ -DCINTERFACE
-EXTRA_OBJS = notifyhook.dll libexpat.dll
-EXTRALIBS = $(LIBUUID)
-
-C_SRCS = \
-       services/startup.c \
-       utility/splitpath.c
-
-CPP_SRCS = \
-       explorer.cpp \
-       desktop/desktop.cpp \
-       utility/shellclasses.cpp \
-       utility/utility.cpp \
-       utility/window.cpp \
-       utility/dragdropimpl.cpp \
-       utility/shellbrowserimpl.cpp \
-       utility/xmlstorage.cpp \
-       shell/entries.cpp \
-       shell/winfs.cpp \
-       shell/unixfs.cpp \
-       shell/shellfs.cpp \
-       shell/mainframe.cpp \
-       shell/filechild.cpp \
-       shell/pane.cpp \
-       shell/shellbrowser.cpp \
-       shell/ntobjfs.cpp \
-       shell/regfs.cpp \
-       shell/fatfs.cpp \
-       shell/webchild.cpp \
-       services/shellservices.cpp \
-       taskbar/desktopbar.cpp \
-       taskbar/taskbar.cpp \
-       taskbar/startmenu.cpp \
-       taskbar/traynotify.cpp \
-       taskbar/quicklaunch.cpp \
-       taskbar/favorites.cpp \
-       dialogs/searchprogram.cpp \
-       dialogs/settings.cpp
-
-RC_SRCS = explorer_intres.rc
-EXTRARCFLAGS = -D__WRC__ -D_WIN32
-
-
-# Global rules for building a Winelib program     -*-Makefile-*-
-#
-# Each individual makefile should define the following variables:
-# MODULE       : name of the main module being built
-# APPMODE      : program mode (cui,gui,cuiw,guiw)
-# EXTRALIBS    : extra libraries to link in (optional)
-# EXTRADEFS    : extra symbol definitions, like -DWINELIB (optional)
-#
-# plus all variables required by the global Make.rules.in
-#
-
-DEFS        = -D_REENTRANT -fPIC $(EXTRADEFS)
-LDDLLFLAGS  = -Wl,-Bsymbolic,-z,defs
-ALL_OBJS    = $(OBJS) $(MODULE).dbg.o
-ALL_LIBS    = $(LIBWINE) $(EXTRALIBS) $(LIBPORT) $(LDFLAGS) $(LIBS)
-BASEMODULE  = $(MODULE:.exe=)
-TESTIMPORTS = $(DELAYIMPORTS) $(IMPORTS)
-RUNTESTFLAGS= -q -P wine -T $(TOPOBJDIR) $(PLTESTPROGRAM:%=-p %)
-
-
-# Global rules shared by all makefiles     -*-Makefile-*-
-#
-# Each individual makefile must define the following variables:
-# TOPSRCDIR    : top-level source directory
-# TOPOBJDIR    : top-level object directory
-# SRCDIR       : source directory for this module
-# MODULE       : name of the module being built
-#
-# Each individual makefile may define the following additional variables:
-# C_SRCS       : C sources for the module
-# CPP_SRCS     : C++ sources for the module
-# C_SRCS16     : 16-bit C sources for the module
-# RC_SRCS      : resource source files
-# EXTRA_SRCS   : extra source files for make depend
-# EXTRA_OBJS   : extra object files
-# IMPORTS      : dlls to import
-# DELAYIMPORTS : dlls to import in delayed mode
-# SUBDIRS      : subdirectories that contain a Makefile
-# EXTRASUBDIRS : subdirectories that do not contain a Makefile
-# INSTALLSUBDIRS : subdirectories to run make install/uninstall into
-
-# First some useful definitions
-
-SHELL     = /bin/sh
-CC        = gcc
-CXX       = g++
-CPP       = gcc -E
-#CFLAGS    = -g -O2
-CFLAGS    = -g
-CPPFLAGS  = 
-LIBS      = -lm -lstdc++
-YACC      = bison -y
-LEX       = flex
-LEXLIB    = -lfl
-EXEEXT    = 
-OBJEXT    = o
-LIBEXT    = so
-DLLEXT    = .so
-IMPLIBEXT = def
-LDSHARED  = $(CC) -shared $(SONAME:%=-Wl,-soname,%)
-DLLTOOL   = false
-DLLWRAP   = 
-AR        = ar rc
-RANLIB    = ranlib
-STRIP     = strip
-WINDRES   = mingw32-windres
-LN        = ln
-LN_S      = ln -s
-TOOLSDIR  = $(TOPOBJDIR)
-AS        = as
-LD        = ld
-LDFLAGS   = 
-LDCOMBINE = $(LD) -r
-RM        = rm -f
-MV        = mv
-LINT      = 
-LINTFLAGS = 
-INCLUDES     = -I$(SRCDIR) -I. -I$(TOPSRCDIR)/include -I$(TOPOBJDIR)/include $(EXTRAINCL)
-EXTRACFLAGS  = -mpreferred-stack-boundary=2 -fno-strict-aliasing -gstabs+ -Wpointer-arith
-ALLCFLAGS    = $(INCLUDES) $(DEFS) $(EXTRACFLAGS) $(CPPFLAGS) $(CFLAGS)
-ALLLINTFLAGS = $(INCLUDES) $(DEFS) $(LINTFLAGS)
-MKINSTALLDIRS= $(TOPSRCDIR)/tools/mkinstalldirs -m 755
-WINAPI_CHECK = $(TOPSRCDIR)/tools/winapi_check/winapi_check
-WINEWRAPPER  = $(TOPSRCDIR)/tools/winewrapper
-C2MAN        = $(TOPSRCDIR)/tools/c2man.pl
-RUNTEST      = $(TOPSRCDIR)/tools/runtest
-WINEBUILD    = $(TOOLSDIR)/tools/winebuild/winebuild
-MAKEDEP      = $(TOOLSDIR)/tools/makedep
-WRC          = $(TOOLSDIR)/tools/wrc/wrc
-WMC          = $(TOOLSDIR)/tools/wmc/wmc
-WIDL         = $(TOOLSDIR)/tools/widl/widl
-RC           = $(WRC)
-RC16         = $(WRC)
-RCFLAGS      = --nostdinc $(INCLUDES) $(EXTRARCFLAGS)
-RC16FLAGS    = -O res16 $(RCFLAGS)
-LDPATH       = LD_LIBRARY_PATH="$(TOOLSDIR)/libs/unicode:$$LD_LIBRARY_PATH"
-DLLDIR       = $(TOPOBJDIR)/dlls
-LIBDIR       = $(TOPOBJDIR)/libs
-LIBPORT      = -L$(TOPOBJDIR)/libs/port -lwine_port
-LIBUNICODE   = -L$(TOPOBJDIR)/libs/unicode -lwine_unicode
-LIBUUID      = -L$(TOPOBJDIR)/libs/uuid -lwine_uuid
-LIBWINE      = -L$(TOPOBJDIR)/libs/wine -lwine
-
-
-
-# Installation infos
-
-INSTALL         = /usr/bin/install -c $(INSTALL_FLAGS)
-INSTALL_PROGRAM = ${INSTALL} $(INSTALL_PROGRAM_FLAGS)
-INSTALL_SCRIPT  = ${INSTALL} $(INSTALL_SCRIPT_FLAGS)
-INSTALL_DATA    = ${INSTALL} -m 644 $(INSTALL_DATA_FLAGS)
-prefix          = /usr/local
-exec_prefix     = ${prefix}
-bindir          = ${exec_prefix}/bin
-libdir          = ${exec_prefix}/lib
-datadir         = ${prefix}/share
-infodir         = ${prefix}/info
-mandir          = ${prefix}/man
-sysconfdir      = ${prefix}/etc
-includedir      = ${prefix}/include/wine
-dlldir          = ${exec_prefix}/lib/wine
-prog_manext     = 1
-api_manext      = 3w
-conf_manext     = 5
-CLEAN_FILES     = *.o *.a *.so *.ln *.$(LIBEXT) \\\#*\\\# *~ *% .\\\#* *.bak *.orig *.rej \
-                  *.flc *.spec.c *.spec.def *.dbg.c y.tab.c y.tab.h lex.yy.c core */*.o
-
-OBJS = $(C_SRCS:.c=.o) $(CPP_SRCS:.cpp=.o) $(EXTRA_OBJS)
-
-RCOBJS = $(RC_SRCS:.rc=.res.o)
-LINTS  = $(C_SRCS:.c=.ln) $(CPP_SRCS:.cpp=.ln)
-
-# Implicit rules
-
-.SUFFIXES: .mc .rc .mc.rc .res .res.o .coff .spec .spec.c .spec.def .ok
-
-.c.o:
-       $(CC) -c $(ALLCFLAGS) -o $@ $<
-
-.cpp.o:
-       $(CXX) -c $(ALLCFLAGS) -o $@ $<
-
-.s.o:
-       $(AS) -o $@ $<
-
-.mc.mc.rc:
-       $(LDPATH) $(WMC) -i -U -H /dev/null -o $@ $<
-
-.rc.res:
-       $(LDPATH) $(RC) $(RCFLAGS) -fo$@ $<
-
-.res.res.o:
-       $(WINDRES) -i $< -o $@
-
-.rc.coff:
-       $(WINDRES) -i $<  -o $@
-
-.spec.spec.c:
-       $(WINEBUILD) $(DEFS) -o $@ --main-module $(MODULE) --spec $<
-
-.spec.spec.def:
-       $(WINEBUILD) $(DEFS) -o $@ --def $<
-
-.c.ln:
-       $(LINT) -c $(ALLLINTFLAGS) $< || ( $(RM) $@ && exit 1 )
-
-.c.ok:
-       $(RUNTEST) $(RUNTESTFLAGS) $< && touch $@
-
-# 'all' target first in case the enclosing Makefile didn't define any target
-
-all: Makefile
-
-filter:
-       @$(TOPSRCDIR)/tools/winapi/make_filter --make $(MAKE) all
-
-.PHONY: all filter
-
-# Rule for main module debug channels
-
-$(MODULE).dbg.c: $(C_SRCS) $(CPP_SRCS) $(C_SRCS16) $(WINEBUILD)
-       $(WINEBUILD) $(DEFS) -o $@ --debug -C$(SRCDIR) $(C_SRCS) $(CPP_SRCS) $(C_SRCS16)
-
-# Rule to rebuild the tools
-
-$(MAKEDEP):
-       cd $(TOOLSDIR)/tools && $(MAKE) `basename $@`
-
-# Rules for makefile
-
-Makefile: Makefile.in $(TOPSRCDIR)/configure
-       @echo Makefile is older than $?, please rerun $(TOPSRCDIR)/configure
-       @exit 1
-
-# Rule for linting
-
-$(MODULE).ln : $(LINTS)
-       if test "$(LINTS)" ; \
-       then \
-               $(LINT) $(ALLLINTFLAGS) -o$(MODULE) $(LINTS) ; \
-               $(MV) llib-l$(MODULE).ln $(MODULE).ln ; \
-       else \
-               $(LINT) $(ALLLINTFLAGS) -C$(MODULE) /dev/null ; \
-       fi
-
-lint:: $(MODULE).ln
-
-# Rules for Windows API checking
-
-winapi_check:: dummy
-       $(WINAPI_CHECK) $(WINAPI_CHECK_FLAGS) $(WINAPI_CHECK_EXTRA_FLAGS) .
-
-.PHONY: winapi_check
-
-# Rules for dependencies
-
-$(SUBDIRS:%=%/__depend__): $(MAKEDEP) dummy
-       cd `dirname $@` && $(MAKE) depend
-
-depend: $(MAKEDEP) $(SUBDIRS:%=%/__depend__)
-       $(MAKEDEP) $(INCLUDES) -C$(SRCDIR) $(C_SRCS) $(CPP_SRCS) $(C_SRCS16) $(RC_SRCS) $(RC_SRCS16) $(MC_SRCS) $(IDL_SRCS) $(EXTRA_SRCS)
-
-.PHONY: depend $(SUBDIRS:%=%/__depend__)
-
-# Rules for cleaning
-
-$(SUBDIRS:%=%/__clean__): dummy
-       cd `dirname $@` && $(MAKE) clean
-
-$(SUBDIRS:%=%/__testclean__): dummy
-       cd `dirname $@` && $(MAKE) testclean
-
-$(EXTRASUBDIRS:%=%/__clean__): dummy
-       -cd `dirname $@` && $(RM) $(CLEAN_FILES)
-
-testclean:: $(SUBDIRS:%=%/__testclean__)
-
-clean:: $(SUBDIRS:%=%/__clean__) $(EXTRASUBDIRS:%=%/__clean__)
-       $(RM) $(CLEAN_FILES) $(RC_SRCS:.rc=.res) $(RC_SRCS16:.rc=.res) $(MC_SRCS:.mc=.mc.rc) $(PROGRAMS)
-
-.PHONY: clean testclean $(SUBDIRS:%=%/__clean__) $(SUBDIRS:%=%/__testclean__) $(EXTRASUBDIRS:%=%/__clean__)
-
-# Rules for installing
-
-$(SUBDIRS:%=%/__install__): dummy
-       cd `dirname $@` && $(MAKE) install
-
-$(SUBDIRS:%=%/__install-lib__): dummy
-       cd `dirname $@` && $(MAKE) install-lib
-
-$(SUBDIRS:%=%/__install-dev__): dummy
-       cd `dirname $@` && $(MAKE) install-dev
-
-$(SUBDIRS:%=%/__uninstall__): dummy
-       cd `dirname $@` && $(MAKE) uninstall
-
-install:: $(INSTALLSUBDIRS:%=%/__install__)
-
-uninstall:: $(INSTALLSUBDIRS:%=%/__uninstall__)
-
-.PHONY: install install-lib install-dev uninstall \
-       $(SUBDIRS:%=%/__install__) $(SUBDIRS:%=%/__uninstall__) \
-       $(SUBDIRS:%=%/__install-lib__) $(SUBDIRS:%=%/__install-dev__)
-
-# Rules for checking that no imports are missing
-
-$(SUBDIRS:%=%/__checklink__): dummy
-       @cd `dirname $@` && $(MAKE) checklink
-
-.PHONY: checklink $(SUBDIRS:%=%/__checklink__)
-
-# Rules for testing
-
-$(SUBDIRS:%=%/__test__): dummy
-       @cd `dirname $@` && $(MAKE) test
-
-$(SUBDIRS:%=%/__crosstest__): dummy
-       @cd `dirname $@` && $(MAKE) crosstest
-
-.PHONY: check test crosstest $(SUBDIRS:%=%/__test__) $(SUBDIRS:%=%/__crosstest__)
-
-# Misc. rules
-
-$(RC_SRCS:.rc=.res) $(RC_SRCS16:.rc=.res): $(WRC)
-
-$(MC_SRCS:.mc=.mc.rc): $(WMC)
-
-$(IDL_SRCS:.idl=.h): $(WIDL)
-
-$(SUBDIRS): dummy
-       @cd $@ && $(MAKE)
-
-dummy:
-
-.PHONY: dummy $(SUBDIRS)
-
-# End of global rules
-
-all: $(MODULE)$(DLLEXT) $(BASEMODULE)$(EXEEXT)
-
-# Rule for main module spec file
-
-$(MODULE).spec.c: $(RC_SRCS:.rc=.res) $(ALL_OBJS) $(WINEBUILD)
-       $(WINEBUILD) $(DEFS) -o $@ --exe $(MODULE) $(APPMODE:%=--exe-mode %) $(RC_SRCS:.rc=.res) $(ALL_OBJS) -L$(DLLDIR) $(DELAYIMPORTS:%=-d%) $(IMPORTS:%=-l%)
-
-# Rules for .so main module
-
-$(MODULE).so: $(MODULE).spec.o $(ALL_OBJS) Makefile.in
-       $(LDSHARED) $(LDDLLFLAGS) $(MODULE).spec.o $(ALL_OBJS) -o $@ $(ALL_LIBS) -lc
-
-$(BASEMODULE): $(WINEWRAPPER)
-       $(RM) $@ && $(LN_S) $(WINEWRAPPER) $@
-
-# Rules for .exe main module
-
-$(MODULE): $(ALL_OBJS) $(RCOBJS) Makefile.in
-       $(CC) $(ALL_OBJS) $(RCOBJS) -o $@ $(DELAYIMPORTS:%=-l%) $(IMPORTS:%=-l%) $(ALL_LIBS)
-
-# Rules for testing
-
-check test:: $(SUBDIRS:%=%/__test__)
-
-$(TESTRESULTS): $(MODULE)$(DLLEXT)
-
-# Rules for installation
-
-.PHONY: install_prog install_prog.so uninstall_prog uninstall_prog.so
-
-install_prog.so: $(MODULE).so dummy
-       $(MKINSTALLDIRS) $(dlldir)
-       $(INSTALL_PROGRAM) $(MODULE).so $(dlldir)/$(MODULE).so
-
-install_prog: $(MODULE) dummy
-       $(MKINSTALLDIRS) $(bindir)
-       $(INSTALL_PROGRAM) $(MODULE) $(bindir)/$(MODULE)
-
-uninstall_prog.so: dummy
-       $(RM) $(dlldir)/$(MODULE).so
-
-uninstall_prog: dummy
-       $(RM) $(bindir)/$(MODULE)
-
-install:: install_prog$(DLLEXT)
-
-uninstall:: uninstall_prog$(DLLEXT)
-
-clean::
-       $(RM) $(BASEMODULE) $(MODULE)
-
-### Dependencies:
diff --git a/reactos/subsys/system/explorer/desktop/desktop.cpp b/reactos/subsys/system/explorer/desktop/desktop.cpp
deleted file mode 100644 (file)
index a3d0215..0000000
+++ /dev/null
@@ -1,840 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // desktop.cpp
- //
- // Martin Fuchs, 09.08.2003
- //
-
-
-#include <precomp.h>
-
-#include "../resource.h"
-
-#include "../taskbar/desktopbar.h"
-#include "../taskbar/taskbar.h"        // for PM_GET_LAST_ACTIVE
-
-
-static BOOL (WINAPI*SetShellWindow)(HWND);
-static BOOL (WINAPI*SetShellWindowEx)(HWND, HWND);
-
-
-#ifdef _USE_HDESK
-
-Desktop::Desktop(HDESK hdesktop/*, HWINSTA hwinsta*/)
- :     _hdesktop(hdesktop)
-//     _hwinsta(hwinsta)
-{
-}
-
-Desktop::~Desktop()
-{
-       if (_hdesktop)
-               CloseDesktop(_hdesktop);
-
-//     if (_hwinsta)
-//             CloseWindowStation(_hwinsta);
-
-       if (_pThread.get()) {
-               _pThread->Stop();
-               _pThread.release();
-       }
-}
-
-#endif
-
-
-Desktops::Desktops()
- :     _current_desktop(0)
-{
-}
-
-Desktops::~Desktops()
-{
-        // show all hidden windows
-       for(iterator it_dsk=begin(); it_dsk!=end(); ++it_dsk)
-               for(WindowSet::iterator it=it_dsk->_windows.begin(); it!=it_dsk->_windows.end(); ++it)
-                       ShowWindowAsync(*it, SW_SHOW);
-}
-
-void Desktops::init()
-{
-       resize(DESKTOP_COUNT);
-
-#ifdef _USE_HDESK
-       DesktopPtr& desktop = (*this)[0];
-
-       desktop = DesktopPtr(new Desktop(OpenInputDesktop(0, FALSE, DESKTOP_SWITCHDESKTOP)));
-#endif
-}
-
-#ifdef _USE_HDESK
-
-void Desktops::SwitchToDesktop(int idx)
-{
-       if (_current_desktop == idx)
-               return;
-
-       DesktopPtr& desktop = (*this)[idx];
-
-       DesktopThread* pThread = NULL;
-
-       if (desktop.get()) {
-               if (desktop->_hdesktop)
-                       if (!SwitchDesktop(desktop->_hdesktop))
-                               return;
-       } else {
-               FmtString desktop_name(TEXT("Desktop %d"), idx);
-
-               SECURITY_ATTRIBUTES saAttr = {sizeof(SECURITY_ATTRIBUTES), 0, TRUE};
-/*
-               HWINSTA hwinsta = CreateWindowStation(TEXT("ExplorerWinStation"), 0, GENERIC_ALL, &saAttr);
-
-               if (!SetProcessWindowStation(hwinsta))
-                       return;
-*/
-               HDESK hdesktop = CreateDesktop(desktop_name, NULL, NULL, 0, GENERIC_ALL, &saAttr);
-               if (!hdesktop)
-                       return;
-
-               desktop = DesktopPtr(new Desktop(hdesktop/*, hwinsta*/));
-
-               pThread = new DesktopThread(*desktop);
-       }
-
-       _current_desktop = idx;
-
-       if (pThread) {
-               desktop->_pThread = DesktopThreadPtr(pThread);
-               pThread->Start();
-       }
-}
-
-int DesktopThread::Run()
-{
-       if (!SetThreadDesktop(_desktop._hdesktop))
-               return -1;
-
-       HDESK hDesk_old = OpenInputDesktop(0, FALSE, DESKTOP_SWITCHDESKTOP);
-
-       if (!SwitchDesktop(_desktop._hdesktop))
-               return -1;
-
-       if (!_desktop._hwndDesktop)
-               _desktop._hwndDesktop = DesktopWindow::Create();
-
-       int ret = Window::MessageLoop();
-
-       SwitchDesktop(hDesk_old);
-
-       return ret;
-}
-
-#else // _USE_HDESK
-
-static BOOL CALLBACK SwitchDesktopEnumFct(HWND hwnd, LPARAM lparam)
-{
-       WindowSet& windows = *(WindowSet*)lparam;
-
-       if (hwnd!=g_Globals._hwndDesktopBar && hwnd!=g_Globals._hwndDesktop)
-               if (IsWindowVisible(hwnd))
-                       windows.insert(hwnd);
-
-       return TRUE;
-}
-
-void Desktops::SwitchToDesktop(int idx)
-{
-       if (_current_desktop == idx)
-               return;
-
-       Desktop& old_desktop = (*this)[_current_desktop];
-       WindowSet& windows = old_desktop._windows;
-       Desktop& desktop = (*this)[idx];
-
-       windows.clear();
-
-        // collect window handles of all other desktops
-       WindowSet other_wnds;
-       for(const_iterator it1=begin(); it1!=end(); ++it1)
-               for(WindowSet::const_iterator it2=it1->_windows.begin(); it2!=it1->_windows.end(); ++it2)
-                       other_wnds.insert(*it2);
-
-        // save currently visible application windows
-       EnumWindows(SwitchDesktopEnumFct, (LPARAM)&windows);
-
-       old_desktop._hwndForeground = (HWND)SendMessage(g_Globals._hwndDesktopBar, PM_GET_LAST_ACTIVE, 0, 0);
-
-        // hide all windows of the previous desktop
-       for(WindowSet::iterator it=windows.begin(); it!=windows.end(); ++it)
-               ShowWindowAsync(*it, SW_HIDE);
-
-        // show all windows of the new desktop
-       for(WindowSet::iterator it=desktop._windows.begin(); it!=desktop._windows.end(); ++it)
-               ShowWindowAsync(*it, SW_SHOW);
-
-       if (desktop._hwndForeground)
-               SetForegroundWindow(desktop._hwndForeground);
-
-        // remove the window handles of the other desktops from what we found on the previous desktop
-       for(WindowSet::const_iterator it=other_wnds.begin(); it!=other_wnds.end(); ++it)
-               windows.erase(*it);
-
-        // We don't need to store the window handles of what's now visible the now current desktop.
-       desktop._windows.clear();
-
-       _current_desktop = idx;
-}
-
-#endif // _USE_HDESK
-
-
-static BOOL CALLBACK MinimizeDesktopEnumFct(HWND hwnd, LPARAM lparam)
-{
-       list<MinimizeStruct>& minimized = *(list<MinimizeStruct>*)lparam;
-
-       if (hwnd!=g_Globals._hwndDesktopBar && hwnd!=g_Globals._hwndDesktop)
-               if (IsWindowVisible(hwnd) && !IsIconic(hwnd)) {
-                       RECT rect;
-
-                       if (GetWindowRect(hwnd,&rect))
-                               if (rect.right>0 && rect.bottom>0 &&
-                                       rect.right>rect.left && rect.bottom>rect.top) {
-                               minimized.push_back(MinimizeStruct(hwnd, GetWindowStyle(hwnd)));
-                               ShowWindowAsync(hwnd, SW_MINIMIZE);
-                       }
-               }
-
-       return TRUE;
-}
-
- /// minimize/restore all windows on the desktop
-void Desktops::ToggleMinimize()
-{
-       list<MinimizeStruct>& minimized = (*this)[_current_desktop]._minimized;
-
-       if (minimized.empty()) {
-               EnumWindows(MinimizeDesktopEnumFct, (LPARAM)&minimized);
-       } else {
-               for(list<MinimizeStruct>::const_iterator it=minimized.begin(); it!=minimized.end(); ++it)
-                       ShowWindowAsync(it->first, it->second&WS_MAXIMIZE? SW_MAXIMIZE: SW_RESTORE);
-
-               minimized.clear();
-       }
-}
-
-
-BOOL IsAnyDesktopRunning()
-{
-       HINSTANCE hUser32 = GetModuleHandle(TEXT("user32"));
-
-       SetShellWindow = (BOOL(WINAPI*)(HWND)) GetProcAddress(hUser32, "SetShellWindow");
-       SetShellWindowEx = (BOOL(WINAPI*)(HWND,HWND)) GetProcAddress(hUser32, "SetShellWindowEx");
-
-       return GetShellWindow() != 0;
-}
-
-
-BackgroundWindow::BackgroundWindow(HWND hwnd)
- :     super(hwnd)
-{
-        // set background brush for the short moment of displaying the
-        // background color while moving foreground windows
-       SetClassLong(hwnd, GCL_HBRBACKGROUND, COLOR_BACKGROUND+1);
-
-       _display_version = RegGetDWORDValue(HKEY_CURRENT_USER, TEXT("Control Panel\\Desktop"), TEXT("PaintDesktopVersion"), 1);
-}
-
-LRESULT BackgroundWindow::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_ERASEBKGND:
-               DrawDesktopBkgnd((HDC)wparam);
-               return TRUE;
-
-         case WM_MBUTTONDBLCLK:
-               /* Imagelist icons are missing if MainFrame::Create() is called directly from here!
-               explorer_show_frame(SW_SHOWNORMAL); */
-               PostMessage(g_Globals._hwndDesktop, nmsg, wparam, lparam);
-               break;
-
-         case PM_DISPLAY_VERSION:
-               if (lparam || wparam) {
-                       DWORD or_mask = wparam;
-                       DWORD reset_mask = LOWORD(lparam);
-                       DWORD xor_mask = HIWORD(lparam);
-                       _display_version = ((_display_version&~reset_mask) | or_mask) ^ xor_mask;
-                       RegSetDWORDValue(HKEY_CURRENT_USER, TEXT("Control Panel\\Desktop"), TEXT("PaintDesktopVersion"), _display_version);
-                       ///@todo Changing the PaintDesktopVersion-Flag needs a restart of the shell -> display a message box
-                       InvalidateRect(_hwnd, NULL, TRUE);
-               }
-               return _display_version;
-
-         default:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-void BackgroundWindow::DrawDesktopBkgnd(HDC hdc)
-{
-       PaintDesktop(hdc);
-
-/* special solid background
-       HBRUSH bkgndBrush = CreateSolidBrush(RGB(0,32,160));    // dark blue
-       FillRect(hdc, &rect, bkgndBrush);
-       DeleteBrush(bkgndBrush);
-*/
-}
-
-
-DesktopWindow::DesktopWindow(HWND hwnd)
- :     super(hwnd)
-{
-       _pShellView = NULL;
-}
-
-DesktopWindow::~DesktopWindow()
-{
-       if (_pShellView)
-               _pShellView->Release();
-}
-
-
-HWND DesktopWindow::Create()
-{
-       static IconWindowClass wcDesktop(TEXT("Progman"), IDI_REACTOS, CS_DBLCLKS);
-       /* (disabled because of small ugly temporary artefacts when hiding start menu)
-       wcDesktop.hbrBackground = (HBRUSH)(COLOR_BACKGROUND+1); */
-
-       int width = GetSystemMetrics(SM_CXSCREEN);
-       int height = GetSystemMetrics(SM_CYSCREEN);
-
-       HWND hwndDesktop = Window::Create(WINDOW_CREATOR(DesktopWindow),
-                                       WS_EX_TOOLWINDOW, wcDesktop, TEXT("Program Manager"), WS_POPUP|WS_VISIBLE,      //|WS_CLIPCHILDREN for SDI frames
-                                       0, 0, width, height, 0);
-
-        // work around to display desktop bar in Wine
-       ShowWindow(GET_WINDOW(DesktopWindow, hwndDesktop)->_desktopBar, SW_SHOW);
-
-        // work around for Windows NT, Win 98, ...
-        // Without this the desktop has mysteriously only a size of 800x600 pixels.
-       MoveWindow(hwndDesktop, 0, 0, width, height, TRUE);
-
-       return hwndDesktop;
-}
-
-
-LRESULT        DesktopWindow::Init(LPCREATESTRUCT pcs)
-{
-       if (super::Init(pcs))
-               return 1;
-
-       HRESULT hr = GetDesktopFolder()->CreateViewObject(_hwnd, IID_IShellView, (void**)&_pShellView);
-/* also possible:
-       SFV_CREATE sfv_create;
-
-       sfv_create.cbSize = sizeof(SFV_CREATE);
-       sfv_create.pshf = GetDesktopFolder();
-       sfv_create.psvOuter = NULL;
-       sfv_create.psfvcb = NULL;
-
-       HRESULT hr = SHCreateShellFolderView(&sfv_create, &_pShellView);
-*/
-       HWND hWndView = 0;
-
-       if (SUCCEEDED(hr)) {
-               FOLDERSETTINGS fs;
-
-               fs.ViewMode = FVM_ICON;
-               fs.fFlags = FWF_DESKTOP|FWF_NOCLIENTEDGE|FWF_NOSCROLL|FWF_BESTFITWINDOW|FWF_SNAPTOGRID; //|FWF_AUTOARRANGE;
-
-               ClientRect rect(_hwnd);
-
-               hr = _pShellView->CreateViewWindow(NULL, &fs, this, &rect, &hWndView);
-
-               ///@todo use IShellBrowser::GetViewStateStream() to restore previous view state -> see SHOpenRegStream()
-
-               if (SUCCEEDED(hr)) {
-                       g_Globals._hwndShellView = hWndView;
-
-                        // subclass shellview window
-                       new DesktopShellView(hWndView, _pShellView);
-
-                       _pShellView->UIActivate(SVUIA_ACTIVATE_FOCUS);
-
-               /*
-                       IShellView2* pShellView2;
-
-                       hr = _pShellView->QueryInterface(IID_IShellView2, (void**)&pShellView2);
-
-                       SV2CVW2_PARAMS params;
-                       params.cbSize = sizeof(SV2CVW2_PARAMS);
-                       params.psvPrev = _pShellView;
-                       params.pfs = &fs;
-                       params.psbOwner = this;
-                       params.prcView = &rect;
-                       params.pvid = params.pvid;//@@
-
-                       hr = pShellView2->CreateViewWindow2(&params);
-                       params.pvid;
-               */
-
-               /*
-                       IFolderView* pFolderView;
-
-                       hr = _pShellView->QueryInterface(IID_IFolderView, (void**)&pFolderView);
-
-                       if (SUCCEEDED(hr)) {
-                               hr = pFolderView->GetAutoArrange();
-                               hr = pFolderView->SetCurrentViewMode(FVM_DETAILS);
-                       }
-               */
-               }
-       }
-
-       if (hWndView && SetShellWindowEx)
-               SetShellWindowEx(_hwnd, hWndView);
-       else if (SetShellWindow)
-               SetShellWindow(_hwnd);
-
-        // create the explorer bar
-       _desktopBar = DesktopBar::Create();
-       g_Globals._hwndDesktopBar = _desktopBar;
-
-       return 0;
-}
-
-
-LRESULT DesktopWindow::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_LBUTTONDBLCLK:
-         case WM_RBUTTONDBLCLK:
-         case WM_MBUTTONDBLCLK:
-               explorer_show_frame(SW_SHOWNORMAL);
-               break;
-
-         case WM_GETISHELLBROWSER:
-               return (LRESULT)static_cast<IShellBrowser*>(this);
-
-         case WM_DESTROY:
-
-               ///@todo use IShellBrowser::GetViewStateStream() and _pShellView->SaveViewState() to store view state
-
-               if (SetShellWindow)
-                       SetShellWindow(0);
-               break;
-
-         case WM_CLOSE:
-               ShowExitWindowsDialog(_hwnd);
-               break;
-
-         case WM_SYSCOMMAND:
-               if (wparam == SC_TASKLIST) {
-                       if (_desktopBar)
-                               SendMessage(_desktopBar, nmsg, wparam, lparam);
-               }
-               goto def;
-
-         default: def:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-
-HRESULT DesktopWindow::OnDefaultCommand(LPIDA pida)
-{
-#ifndef ROSSHELL       // in shell-only-mode fall through and let shell32 handle the command
-       if (MainFrameBase::OpenShellFolders(pida, 0))
-               return S_OK;
-#endif
-
-       return E_NOTIMPL;
-}
-
-
-DesktopShellView::DesktopShellView(HWND hwnd, IShellView* pShellView)
- :     super(hwnd),
-       _pShellView(pShellView)
-{
-       _hwndListView = ::GetNextWindow(hwnd, GW_CHILD);
-
-       SetWindowStyle(_hwndListView, GetWindowStyle(_hwndListView)&~LVS_ALIGNMASK);//|LVS_ALIGNTOP|LVS_AUTOARRANGE);
-
-        // work around for Windows NT, Win 98, ...
-        // Without this the desktop has mysteriously only a size of 800x600 pixels.
-       ClientRect rect(hwnd);
-       MoveWindow(_hwndListView, 0, 0, rect.right, rect.bottom, TRUE);
-
-        // subclass background window
-       new BackgroundWindow(_hwndListView);
-
-       _icon_algo = 1; // default icon arrangement
-
-       PositionIcons();
-       InitDragDrop();
-}
-
-bool DesktopShellView::InitDragDrop()
-{
-       CONTEXT("DesktopShellView::InitDragDrop()");
-
-       _pDropTarget = new DesktopDropTarget(_hwnd);
-
-       if (!_pDropTarget)
-               return false;
-
-       _pDropTarget->AddRef();
-
-       if (FAILED(RegisterDragDrop(_hwnd, _pDropTarget))) {
-               _pDropTarget->Release();
-               _pDropTarget = NULL;
-               return false;
-       }
-       else
-               _pDropTarget->Release();
-
-       FORMATETC ftetc;
-
-       ftetc.dwAspect = DVASPECT_CONTENT;
-       ftetc.lindex = -1;
-       ftetc.tymed = TYMED_HGLOBAL;
-       ftetc.cfFormat = CF_HDROP;
-
-       _pDropTarget->AddSuportedFormat(ftetc);
-
-       return true;
-}
-
-LRESULT DesktopShellView::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_CONTEXTMENU:
-               if (!DoContextMenu(GET_X_LPARAM(lparam), GET_Y_LPARAM(lparam)))
-                       DoDesktopContextMenu(GET_X_LPARAM(lparam), GET_Y_LPARAM(lparam));
-               break;
-
-         case PM_SET_ICON_ALGORITHM:
-               _icon_algo = wparam;
-               PositionIcons();
-               break;
-
-         case PM_GET_ICON_ALGORITHM:
-               return _icon_algo;
-
-         case PM_DISPLAY_VERSION:
-               return SendMessage(_hwndListView, nmsg, wparam, lparam);
-
-         default:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-int DesktopShellView::Command(int id, int code)
-{
-       return super::Command(id, code);
-}
-
-int DesktopShellView::Notify(int id, NMHDR* pnmh)
-{
-       return super::Notify(id, pnmh);
-}
-
-bool DesktopShellView::DoContextMenu(int x, int y)
-{
-       IDataObject* selection;
-
-       HRESULT hr = _pShellView->GetItemObject(SVGIO_SELECTION, IID_IDataObject, (void**)&selection);
-       if (FAILED(hr))
-               return false;
-
-       PIDList pidList;
-
-       hr = pidList.GetData(selection);
-       if (FAILED(hr)) {
-               selection->Release();
-               //CHECKERROR(hr);
-               return false;
-       }
-
-       LPIDA pida = pidList;
-       if (!pida->cidl) {
-               selection->Release();
-               return false;
-       }
-
-       LPCITEMIDLIST parent_pidl = (LPCITEMIDLIST) ((LPBYTE)pida+pida->aoffset[0]);
-
-       LPCITEMIDLIST* apidl = (LPCITEMIDLIST*) alloca(pida->cidl*sizeof(LPCITEMIDLIST));
-
-       for(int i=pida->cidl; i>0; --i)
-               apidl[i-1] = (LPCITEMIDLIST) ((LPBYTE)pida+pida->aoffset[i]);
-
-       hr = ShellFolderContextMenu(ShellFolder(parent_pidl), _hwnd, pida->cidl, apidl, x, y, _cm_ifs);
-
-       selection->Release();
-
-       CHECKERROR(hr);
-
-       return true;
-}
-
-HRESULT DesktopShellView::DoDesktopContextMenu(int x, int y)
-{
-       IContextMenu* pcm;
-
-       HRESULT hr = DesktopFolder()->GetUIObjectOf(_hwnd, 0, NULL, IID_IContextMenu, NULL, (LPVOID*)&pcm);
-
-       if (SUCCEEDED(hr)) {
-               pcm = _cm_ifs.query_interfaces(pcm);
-
-               HMENU hmenu = CreatePopupMenu();
-
-               if (hmenu) {
-                       hr = pcm->QueryContextMenu(hmenu, 0, FCIDM_SHVIEWFIRST, FCIDM_SHVIEWLAST-1, CMF_NORMAL|CMF_EXPLORE);
-
-                       if (SUCCEEDED(hr)) {
-                               AppendMenu(hmenu, MF_SEPARATOR, 0, NULL);
-                               AppendMenu(hmenu, 0, FCIDM_SHVIEWLAST-1, ResString(IDS_ABOUT_EXPLORER));
-
-                               UINT idCmd = TrackPopupMenu(hmenu, TPM_LEFTALIGN|TPM_RETURNCMD|TPM_RIGHTBUTTON, x, y, 0, _hwnd, NULL);
-
-                               _cm_ifs.reset();
-
-                               if (idCmd == FCIDM_SHVIEWLAST-1) {
-                                       explorer_about(_hwnd);
-                               } else if (idCmd) {
-                                 CMINVOKECOMMANDINFO cmi;
-
-                                 cmi.cbSize = sizeof(CMINVOKECOMMANDINFO);
-                                 cmi.fMask = 0;
-                                 cmi.hwnd = _hwnd;
-                                 cmi.lpVerb = (LPCSTR)(INT_PTR)(idCmd - FCIDM_SHVIEWFIRST);
-                                 cmi.lpParameters = NULL;
-                                 cmi.lpDirectory = NULL;
-                                 cmi.nShow = SW_SHOWNORMAL;
-                                 cmi.dwHotKey = 0;
-                                 cmi.hIcon = 0;
-
-                                 hr = pcm->InvokeCommand(&cmi);
-                               }
-                       } else
-                               _cm_ifs.reset();
-               }
-
-               pcm->Release();
-       }
-
-       return hr;
-}
-
-
-#define        ARRANGE_BORDER_DOWN      8
-#define        ARRANGE_BORDER_HV        9
-#define        ARRANGE_ROUNDABOUT      10
-
-static const POINTS s_align_start[] = {
-       {0, 0}, // left/top
-       {0, 0},
-       {1, 0}, // right/top
-       {1, 0},
-       {0, 1}, // left/bottom
-       {0, 1},
-       {1, 1}, // right/bottom
-       {1, 1},
-
-       {0, 0}, // left/top
-       {0, 0},
-       {0, 0}
-};
-
-static const POINTS s_align_dir1[] = {
-       { 0, +1},       // down
-       {+1,  0},       // right
-       {-1,  0},       // left
-       { 0, +1},       // down
-       { 0, -1},       // up
-       {+1,  0},       // right
-       {-1,  0},       // left
-       { 0, -1},       // up
-
-       { 0, +1},       // down
-       {+1,  0},       // right
-       {+1,  0}        // right
-};
-
-static const POINTS s_align_dir2[] = {
-       {+1,  0},       // right
-       { 0, +1},       // down
-       { 0, +1},       // down
-       {-1,  0},       // left
-       {+1,  0},       // right
-       { 0, -1},       // up
-       { 0, -1},       // up
-       {-1,  0},       // left
-
-       {+1,  0},       // right
-       { 0, +1},       // down
-       { 0, +1}        // down
-};
-
-typedef pair<int,int> IconPos;
-typedef map<IconPos, int> IconMap;
-
-void DesktopShellView::PositionIcons(int dir)
-{
-       DWORD spacing = ListView_GetItemSpacing(_hwndListView, FALSE);
-
-       RECT work_area;
-       SystemParametersInfo(SPI_GETWORKAREA, 0, &work_area, 0);
-
-       const POINTS& dir1 = s_align_dir1[_icon_algo];
-       const POINTS& dir2 = s_align_dir2[_icon_algo];
-       const POINTS& start_pos = s_align_start[_icon_algo];
-
-       int dir_x1 = dir1.x;
-       int dir_y1 = dir1.y;
-       int dir_x2 = dir2.x;
-       int dir_y2 = dir2.y;
-
-       int cx = LOWORD(spacing);
-       int cy = HIWORD(spacing);
-
-       int dx1 = dir_x1 * cx;
-       int dy1 = dir_y1 * cy;
-       int dx2 = dir_x2 * cx;
-       int dy2 = dir_y2 * cy;
-
-       int xoffset = (cx-32)/2;
-       int yoffset = 4/*(cy-32)/2*/;
-
-       int start_x = start_pos.x * (work_area.right - cx) + xoffset;
-       int start_y = start_pos.y * (work_area.bottom - cy) + yoffset;
-
-       int x = start_x;
-       int y = start_y;
-
-       int all = ListView_GetItemCount(_hwndListView);
-       int i1, i2;
-
-       if (dir > 0) {
-               i1 = 0;
-               i2 = all;
-       } else {
-               i1 = all-1;
-               i2 = -1;
-       }
-
-       IconMap pos_idx;
-       int cnt = 0;
-       int xhv = start_x;
-       int yhv = start_y;
-
-       for(int idx=i1; idx!=i2; idx+=dir) {
-               pos_idx[IconPos(y, x)] = idx;
-
-               if (_icon_algo == ARRANGE_BORDER_DOWN) {
-                       if (++cnt & 1)
-                               x = work_area.right - x - cx + 2*xoffset;
-                       else {
-                               y += dy1;
-
-                               if (y + cy - 2 * yoffset > work_area.bottom) {
-                                       y = start_y;
-                                       start_x += dx2;
-                                       x = start_x;
-                               }
-                       }
-
-                       continue;
-               }
-               else if (_icon_algo == ARRANGE_BORDER_HV) {
-                       if (++cnt & 1)
-                               x = work_area.right - x - cx + 2*xoffset;
-                       else if (cnt & 2) {
-                               yhv += cy;
-                               y = yhv;
-                               x = start_x;
-
-                               if (y + cy - 2 * yoffset > work_area.bottom) {
-                                       start_x += cx;
-                                       xhv = start_x;
-                                       x = xhv;
-                                       start_y += cy;
-                                       yhv = start_y;
-                                       y = yhv;
-                               }
-                       } else {
-                               xhv += cx;
-                               x = xhv;
-                               y = start_y;
-
-                               if (x + cx - 2 * xoffset > work_area.right) {
-                                       start_x += cx;
-                                       xhv = start_x;
-                                       x = xhv;
-                                       start_y += cy;
-                                       yhv = start_y;
-                                       y = yhv;
-                               }
-                       }
-
-                       continue;
-               }
-               else if (_icon_algo == ARRANGE_ROUNDABOUT) {
-
-                       ///@todo
-
-               }
-
-               x += dx1;
-               y += dy1;
-
-               if (x<0 || x+cx-2*xoffset>work_area.right) {
-                       x = start_x;
-                       y += dy2;
-               } else if (y<0 || y+cy-2*yoffset>work_area.bottom) {
-                       y = start_y;
-                       x += dx2;
-               }
-       }
-
-        // use a little trick to get the icons where we want them to be...
-
-       for(IconMap::const_iterator it=pos_idx.end(); --it!=pos_idx.begin(); ) {
-               const IconPos& pos = it->first;
-
-               ListView_SetItemPosition32(_hwndListView, it->second, pos.second, pos.first);
-       }
-
-       for(IconMap::const_iterator it=pos_idx.begin(); it!=pos_idx.end(); ++it) {
-               const IconPos& pos = it->first;
-
-               ListView_SetItemPosition32(_hwndListView, it->second, pos.second, pos.first);
-       }
-}
diff --git a/reactos/subsys/system/explorer/desktop/desktop.h b/reactos/subsys/system/explorer/desktop/desktop.h
deleted file mode 100644 (file)
index 00e9dca..0000000
+++ /dev/null
@@ -1,190 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // desktop.h
- //
- // Martin Fuchs, 09.08.2003
- //
-
-
-#define        PM_SET_ICON_ALGORITHM   (WM_APP+0x19)
-#define        PM_GET_ICON_ALGORITHM   (WM_APP+0x1A)
-#define        PM_DISPLAY_VERSION              (WM_APP+0x24)
-
-
- /// subclassed Background window behind the visible desktop window
-struct BackgroundWindow : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       BackgroundWindow(HWND hwnd);
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       void    DrawDesktopBkgnd(HDC hdc);
-
-       int             _display_version;
-};
-
-
- /// Implementation of the Explorer desktop window
-struct DesktopWindow : public Window, public IShellBrowserImpl
-{
-       typedef Window super;
-
-       DesktopWindow(HWND hwnd);
-       ~DesktopWindow();
-
-       static HWND Create();
-
-       virtual HRESULT STDMETHODCALLTYPE GetWindow(HWND* lphwnd)
-       {
-               *lphwnd = _hwnd;
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE QueryActiveShellView(IShellView** ppshv)
-       {
-               _pShellView->AddRef();
-               *ppshv = _pShellView;
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE GetControlWindow(UINT id, HWND* lphwnd)
-       {
-               return E_NOTIMPL;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE SendControlMsg(UINT id, UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* pret)
-       {
-               return E_NOTIMPL;
-       }
-
-protected:
-       LRESULT Init(LPCREATESTRUCT pcs);
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       IShellView*     _pShellView;
-       WindowHandle _desktopBar;
-
-       virtual HRESULT OnDefaultCommand(LPIDA pida);
-};
-
-
- /// OLE drop target for the desktop window
-class DesktopDropTarget : public IDropTargetImpl
-{
-       typedef IDropTargetImpl super;
-
-public:
-       DesktopDropTarget(HWND hTargetWnd) : super(hTargetWnd) {}
-
-       virtual bool OnDrop(FORMATETC* pFmtEtc, STGMEDIUM& medium, DWORD *pdwEffect)
-       {
-               if (pFmtEtc->cfFormat==CF_HDROP && medium.tymed==TYMED_HGLOBAL) {
-                       HDROP hDrop = (HDROP)GlobalLock(medium.hGlobal);
-
-                       if (hDrop) {
-                               TCHAR szFileName[MAX_PATH];
-
-                               UINT cFiles = DragQueryFile(hDrop, 0xFFFFFFFF, NULL, 0);
-
-                               for(UINT i=0; i<cFiles; ++i) {
-                                       DragQueryFile(hDrop, i, szFileName, sizeof(szFileName));
-
-                                       if (DROPEFFECT_COPY & *pdwEffect) {
-                                                // copy the file or dir
-
-                                               ///@todo Add the code to handle Copy
-
-                                       } else if (DROPEFFECT_MOVE & *pdwEffect) {
-                                                // move the file or dir
-
-                                               ///@todo Add the code to handle Move
-
-                                       }
-                               }
-                               //DragFinish(hDrop); // base class calls ReleaseStgMedium
-                       }
-
-                       GlobalUnlock(medium.hGlobal);
-               }
-
-               //@@TreeView_SelectDropTarget(m_hTargetWnd, NULL);
-
-               return true; //let base free the medium
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE DragOver(
-        /* [in] */ DWORD grfKeyState,
-        /* [in] */ POINTL pt,
-        /* [out][in] */ DWORD __RPC_FAR *pdwEffect)
-       {
-               TVHITTESTINFO hit;
-               hit.pt = (POINT&)pt;
-               ScreenToClient(m_hTargetWnd, &hit.pt);
-               hit.flags = TVHT_ONITEM;
-
-               /*@@
-               HTREEITEM hItem = TreeView_HitTest(m_hTargetWnd,&hit);
-
-               if (hItem != NULL)
-                       TreeView_SelectDropTarget(m_hTargetWnd, hItem);
-               */
-
-               return super::DragOver(grfKeyState, pt, pdwEffect);
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE DragLeave(void)
-       {
-               //@@ TreeView_SelectDropTarget(m_hTargetWnd, NULL);
-
-               return super::DragLeave();
-       }
-};
-
-
- /// subclassed ShellView window
-struct DesktopShellView : public ExtContextMenuHandlerT<SubclassedWindow>
-{
-       typedef ExtContextMenuHandlerT<SubclassedWindow> super;
-
-       DesktopShellView(HWND hwnd, IShellView* pShellView);
-
-       bool    InitDragDrop();
-
-protected:
-       IShellView* _pShellView;
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Command(int id, int code);
-       int             Notify(int id, NMHDR* pnmh);
-
-       bool    DoContextMenu(int x, int y);
-       HRESULT DoDesktopContextMenu(int x, int y);
-       void    PositionIcons(int dir=1);
-
-       DesktopDropTarget* _pDropTarget;
-       HWND    _hwndListView;
-       int             _icon_algo;
-};
diff --git a/reactos/subsys/system/explorer/dialogs/searchprogram.cpp b/reactos/subsys/system/explorer/dialogs/searchprogram.cpp
deleted file mode 100644 (file)
index 55c8c03..0000000
+++ /dev/null
@@ -1,418 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // dialogs/searchprogram.cpp
- //
- // Explorer dialogs
- //
- // Martin Fuchs, 02.10.2003
- //
-
-
-#include <precomp.h>
-
-#include "../resource.h"
-
-#include "searchprogram.h"
-
-
-int CollectProgramsThread::Run()
-{
-       try {
-               collect_programs(SpecialFolderPath(CSIDL_COMMON_PROGRAMS, _hwnd));
-       } catch(COMException&) {
-       }
-
-       if (_alive)
-               try {
-                       collect_programs(SpecialFolderPath(CSIDL_PROGRAMS, _hwnd));
-               } catch(COMException&) {
-               }
-
-       if (_alive)
-               _cache_valid = true;
-
-       return 0;
-}
-
-void CollectProgramsThread::collect_programs(const ShellPath& path)
-{
-       ShellDirectory* dir = new ShellDirectory(GetDesktopFolder(), path, 0);
-       _dirs.push(dir);
-
-       dir->smart_scan(SORT_NONE);
-
-       for(Entry*entry=dir->_down; _alive && entry; entry=entry->_next) {
-               if (entry->_shell_attribs & SFGAO_HIDDEN)
-                       continue;
-
-               if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                       collect_programs(entry->create_absolute_pidl());
-               else if (entry->_shell_attribs & SFGAO_LINK)
-                       if (_alive)
-                               _callback(entry, _para);
-       }
-}
-
-void CollectProgramsThread::free_dirs()
-{
-       while(!_dirs.empty()) {
-               ShellDirectory* dir = _dirs.top();
-               dir->free_subentries();
-               _dirs.pop();
-       }
-}
-
-
-#ifdef _MSC_VER
-#pragma warning(disable: 4355)
-#endif
-
-FindProgramDlg::FindProgramDlg(HWND hwnd)
- :     super(hwnd),
-       _list_ctrl(GetDlgItem(hwnd, IDC_PROGRAMS_FOUND)),
-       _thread(collect_programs_callback, hwnd, this),
-       _sort(_list_ctrl, CompareFunc/*, (LPARAM)this*/)
-{
-       SetWindowIcon(hwnd, IDI_SEARCH);
-
-       _resize_mgr.Add(IDC_FILTER,                     RESIZE_X);
-       _resize_mgr.Add(IDC_CHECK_ENTRIES,      MOVE_X);
-       _resize_mgr.Add(IDC_PROGRAMS_FOUND,     RESIZE);
-
-       _resize_mgr.Resize(+520, +300);
-
-       _haccel = LoadAccelerators(g_Globals._hInstance, MAKEINTRESOURCE(IDA_SEARCH_PROGRAM));
-
-       (void)ListView_SetImageList(_list_ctrl, g_Globals._icon_cache.get_sys_imagelist(), LVSIL_SMALL);
-
-       LV_COLUMN column = {LVCF_FMT|LVCF_WIDTH|LVCF_TEXT, LVCFMT_LEFT, 250};
-
-       column.pszText = _T("Name");
-       ListView_InsertColumn(_list_ctrl, 0, &column);
-
-       column.cx = 300;
-       column.pszText = _T("Path");
-       ListView_InsertColumn(_list_ctrl, 1, &column);
-
-       column.cx = 400;
-       column.pszText = _T("Menu Path");
-       ListView_InsertColumn(_list_ctrl, 2, &column);
-
-       ListView_SetExtendedListViewStyleEx(_list_ctrl, LVS_EX_FULLROWSELECT, LVS_EX_FULLROWSELECT);
-
-       _common_programs = SpecialFolderFSPath(CSIDL_COMMON_PROGRAMS, hwnd);
-       if (!_common_programs.empty())
-               _common_programs.append(_T("\\"));
-
-       _user_programs = SpecialFolderFSPath(CSIDL_PROGRAMS, hwnd);
-       if (!_user_programs.empty())
-               _user_programs.append(_T("\\"));
-
-       CenterWindow(hwnd);
-
-       Refresh();
-
-       register_pretranslate(hwnd);
-}
-
-FindProgramDlg::~FindProgramDlg()
-{
-       _thread.Stop();
-
-       unregister_pretranslate(_hwnd);
-}
-
-
-void FindProgramDlg::Refresh(bool delete_cache)
-{
-       WaitCursor wait;
-
-       _thread.Stop();
-
-       TCHAR buffer[1024];
-       GetWindowText(GetDlgItem(_hwnd, IDC_FILTER), buffer, COUNTOF(buffer));
-       CharLower(buffer);
-       _lwr_filter = buffer;
-
-       HiddenWindow hide_listctrl(_list_ctrl);
-
-       ListView_DeleteAllItems(_list_ctrl);
-
-       if (delete_cache || !_thread._cache_valid) {
-               _thread.free_dirs();
-               _thread.Start();
-       } else {
-               for(FPDCache::const_iterator it=_cache.begin(); it!=_cache.end(); ++it)
-                       add_entry(*it);
-       }
-}
-
-void FindProgramDlg::collect_programs_callback(Entry* entry, void* param)
-{
-       FindProgramDlg* pThis = (FindProgramDlg*) param;
-
-       IShellLink* pShellLink;
-       HRESULT hr = entry->GetUIObjectOf(pThis->_hwnd, IID_IShellLink, (LPVOID*)&pShellLink);
-
-       if (SUCCEEDED(hr)) {
-               ShellLinkPtr shell_link(pShellLink);
-
-               shell_link->Release();
-
-               /*hr = pShellLink->Resolve(pThis->_hwnd, SLR_NO_UI);
-               if (SUCCEEDED(hr))*/ {
-                       WIN32_FIND_DATA wfd;
-                       TCHAR path[MAX_PATH];
-
-                       hr = pShellLink->GetPath(path, COUNTOF(path)-1, &wfd, SLGP_UNCPRIORITY);
-
-                       if (SUCCEEDED(hr)) {
-                               TCHAR entry_path[MAX_PATH];
-
-                               entry->get_path(entry_path, COUNTOF(entry_path));
-
-                               String menu_path;
-
-                               int len = pThis->_common_programs.size();
-
-                               if (len && !_tcsnicmp(entry_path, pThis->_common_programs, len))
-                                       menu_path = ResString(IDS_ALL_USERS) + (String(entry_path)+len);
-                               else if ((len=pThis->_user_programs.size()) && !_tcsnicmp(entry_path, pThis->_user_programs, len))
-                                       menu_path = String(entry_path)+len;
-
-                                // store info in cache
-                               FPDEntry new_entry;
-
-                               new_entry._entry = entry;
-                               new_entry._menu_path = menu_path;
-                               new_entry._path = path;
-                               new_entry._idxIcon = I_IMAGECALLBACK;
-
-                               pThis->_cache.push_front(new_entry);
-                               FPDEntry& cache_entry = pThis->_cache.front();
-
-                               Lock lock(pThis->_thread._crit_sect);
-
-                                // resolve deadlocks while executing Thread::Stop()
-                               if (!pThis->_thread.is_alive())
-                                       return;
-
-                               pThis->add_entry(cache_entry);
-                       }
-               }
-       }
-}
-
-void FindProgramDlg::add_entry(const FPDEntry& cache_entry)
-{
-       String lwr_path = cache_entry._path;
-       String lwr_name = cache_entry._entry->_display_name;
-
-       lwr_path.toLower();
-       lwr_name.toLower();
-
-       if (_lwr_filter.empty())
-               if (_tcsstr(lwr_name, _T("uninstal")) || _tcsstr(lwr_name, _T("deinstal")))     // filter out deinstallation links
-                       return;
-
-       if (!_tcsstr(lwr_path, _lwr_filter) && !_tcsstr(lwr_name, _lwr_filter))
-               return;
-
-       LV_ITEM item = {LVIF_TEXT|LVIF_IMAGE|LVIF_PARAM, INT_MAX};
-
-       item.pszText = cache_entry._entry->_display_name;
-       item.iImage = cache_entry._idxIcon;
-       item.lParam = (LPARAM) &cache_entry;
-       item.iItem = ListView_InsertItem(_list_ctrl, &item);    // We could use the information in _sort to enable manual sorting while populating the list.
-
-       item.mask = LVIF_TEXT;
-
-       item.iSubItem = 1;
-       item.pszText = (LPTSTR)(LPCTSTR)cache_entry._path;
-       ListView_SetItem(_list_ctrl, &item);
-
-       item.iSubItem = 2;
-       item.pszText = (LPTSTR)(LPCTSTR)cache_entry._menu_path;
-       ListView_SetItem(_list_ctrl, &item);
-}
-
-LRESULT FindProgramDlg::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_CLOSE:
-               (void)ListView_SetImageList(_list_ctrl, 0, LVSIL_SMALL);        // detach system image list
-               goto def;
-
-         case PM_TRANSLATE_MSG: {
-               MSG* pmsg = (MSG*) lparam;
-
-               if (TranslateAccelerator(_hwnd, _haccel, pmsg))
-                       return TRUE;
-
-               return FALSE;}
-
-         default: def:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-int FindProgramDlg::Command(int id, int code)
-{
-       if (code == BN_CLICKED) {
-               switch(id) {
-                 case ID_REFRESH:
-                       Refresh(true);
-                       break;
-
-                 case IDOK:
-                       LaunchSelected();
-                       break;
-
-                 case IDC_CHECK_ENTRIES:
-                       CheckEntries();
-                       break;
-
-                 default:
-                       return super::Command(id, code);
-               }
-
-               return 0;
-       }
-       else if (code == EN_CHANGE) {
-               switch(id) {
-                 case IDC_FILTER:
-                       Refresh();
-                       break;
-               }
-
-               return 0;
-       }
-
-       return 1;
-}
-
-void FindProgramDlg::LaunchSelected()
-{
-       Lock lock(_thread._crit_sect);
-
-       int count = ListView_GetSelectedCount(_list_ctrl);
-
-       if (count > 1)
-               if (MessageBox(_hwnd, ResString(IDS_LAUNCH_MANY_PROGRAMS), ResString(IDS_TITLE), MB_OKCANCEL) != IDOK)
-                       return;
-
-       for(int idx=-1; (idx=ListView_GetNextItem(_list_ctrl, idx, LVNI_SELECTED))!=-1; ) {
-               LPARAM lparam = ListView_GetItemData(_list_ctrl, idx);
-
-               if (lparam) {
-                       FPDEntry& cache_entry = *(FPDEntry*)lparam;
-                       cache_entry._entry->launch_entry(_hwnd);
-               }
-       }
-}
-
-int FindProgramDlg::Notify(int id, NMHDR* pnmh)
-{
-       switch(pnmh->code) {
-         case LVN_GETDISPINFO: {
-               LV_DISPINFO* pDispInfo = (LV_DISPINFO*) pnmh;
-
-               if (pnmh->hwndFrom == _list_ctrl) {
-                       if (pDispInfo->item.mask & LVIF_IMAGE) {
-                               FPDEntry& cache_entry = *(FPDEntry*)pDispInfo->item.lParam;
-                               Entry* entry = cache_entry._entry;
-
-                               if (entry->_icon_id == ICID_UNKNOWN)
-                                       entry->_icon_id = entry->extract_icon(ICF_SYSCACHE);
-
-                               pDispInfo->item.iImage = g_Globals._icon_cache.get_icon(entry->_icon_id).get_sysiml_idx();
-                               pDispInfo->item.mask |= LVIF_DI_SETITEM;
-
-                               return 1;
-                       }
-               }}
-               break;
-
-         case NM_DBLCLK:
-               if (pnmh->hwndFrom == _list_ctrl)
-                       LaunchSelected();
-               /*{
-                       Lock lock(_thread._crit_sect);
-
-                       LPNMLISTVIEW pnmv = (LPNMLISTVIEW) pnmh;
-                       LPARAM lparam = ListView_GetItemData(pnmh->hwndFrom, pnmv->iItem);
-
-                       if (lparam) {
-                               FPDEntry& cache_entry = *(FPDEntry*)lparam;
-                               cache_entry._entry->launch_entry(_hwnd);
-                       }
-               }*/
-               break;
-
-         case HDN_ITEMCLICK: {
-               WaitCursor wait;
-               NMHEADER* phdr = (NMHEADER*)pnmh;
-
-               if (GetParent(pnmh->hwndFrom) == _list_ctrl) {
-                       if (_thread._cache_valid) {     // disable manual sorting while populating the list
-                               _sort.toggle_sort(phdr->iItem);
-                               _sort.sort();
-                       }
-               }
-               break;}
-       }
-
-       return 0;
-}
-
-int CALLBACK FindProgramDlg::CompareFunc(LPARAM lparam1, LPARAM lparam2, LPARAM lparamSort)
-{
-       ListSort* sort = (ListSort*)lparamSort;
-
-       FPDEntry& a = *(FPDEntry*)lparam1;
-       FPDEntry& b = *(FPDEntry*)lparam2;
-
-       int cmp = 0;
-
-       switch(sort->_sort_crit) {
-         case 0:
-               cmp = _tcsicoll(a._entry->_display_name, b._entry->_display_name);
-               break;
-
-         case 1:
-               cmp = _tcsicoll(a._path, b._path);
-               break;
-
-         case 2:
-               cmp = _tcsicoll(a._menu_path, b._menu_path);
-       }
-
-       return sort->_direction? -cmp: cmp;
-}
-
-void FindProgramDlg::CheckEntries()
-{
-       ///@todo check all entries for existing targets, display a list of not working entries and ask the user for permission to delete them
-}
diff --git a/reactos/subsys/system/explorer/dialogs/searchprogram.h b/reactos/subsys/system/explorer/dialogs/searchprogram.h
deleted file mode 100644 (file)
index bc39b3b..0000000
+++ /dev/null
@@ -1,108 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // dialogs/searchprogram.h
- //
- // Explorer dialogs
- //
- // Martin Fuchs, 02.10.2003
- //
-
-
-typedef void (*COLLECT_CALLBACK)(Entry* entry, void* param);
-typedef stack<ShellDirectory*> ShellDirectoryStack;
-
- /// Thread for collecting start menu entries
-struct CollectProgramsThread : public Thread
-{
-       CollectProgramsThread(COLLECT_CALLBACK callback, HWND hwnd, void* para)
-        :      _cache_valid(false),
-               _callback(callback),
-               _hwnd(hwnd),
-               _para(para)
-       {
-       }
-
-       ~CollectProgramsThread()
-       {
-               free_dirs();
-       }
-
-       int             Run();
-       void    free_dirs();
-
-       bool    _cache_valid;
-
-protected:
-       COLLECT_CALLBACK _callback;
-       HWND    _hwnd;
-       void*   _para;
-       ShellDirectoryStack _dirs;
-
-       void    collect_programs(const ShellPath& path);
-};
-
-
- /// entry for the list in "find program" dialogs
-struct FPDEntry
-{
-       Entry*  _entry;
-       int             _idxIcon;
-       String  _menu_path;
-       String  _path;
-};
-
-typedef list<FPDEntry> FPDCache;
-
-
- /// Dialog to work with the complete list of start menu entries
-struct FindProgramDlg : public ResizeController<Dialog>
-{
-       typedef ResizeController<Dialog> super;
-
-       FindProgramDlg(HWND hwnd);
-       ~FindProgramDlg();
-
-protected:
-       HWND    _list_ctrl;
-       HACCEL  _haccel;
-       String  _lwr_filter;
-
-       CollectProgramsThread _thread;
-       FPDCache _cache;
-
-       String  _common_programs, _user_programs;
-
-       ListSort _sort;
-
-       virtual LRESULT WndProc(UINT, WPARAM, LPARAM);
-       virtual int     Command(int id, int code);
-       virtual int     Notify(int id, NMHDR* pnmh);
-
-       void    Refresh(bool delete_cache=false);
-       void    add_entry(const FPDEntry& cache_entry);
-       void    LaunchSelected();
-       void    CheckEntries();
-
-       static void collect_programs_callback(Entry* entry, void* param);
-       static int CALLBACK CompareFunc(LPARAM lparam1, LPARAM lparam2, LPARAM lparamSort);
-};
diff --git a/reactos/subsys/system/explorer/dialogs/settings.cpp b/reactos/subsys/system/explorer/dialogs/settings.cpp
deleted file mode 100644 (file)
index 0b80458..0000000
+++ /dev/null
@@ -1,273 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // dialogs/settings.cpp
- //
- // Explorer dialogs
- //
- // Martin Fuchs, 18.01.2004
- //
-
-
-#include <precomp.h>
-
-#include "../resource.h"
-
-#include "../taskbar/traynotify.h"
-#include "settings.h"
-
-
-void ExplorerPropertySheet(HWND hparent)
-{
-       PropertySheetDialog ps(hparent);
-
-       ps.dwFlags |= PSH_USEICONID | PSH_PROPTITLE;
-       ps.pszIcon = MAKEINTRESOURCE(IDI_REACTOS);
-       ps.pszCaption = TEXT("Explorer");
-
-       PropSheetPage psp1(IDD_DESKBAR_DESKTOP, WINDOW_CREATOR(DesktopSettingsDlg));
-       psp1.dwFlags |= PSP_USETITLE;
-       psp1.pszTitle = MAKEINTRESOURCE(IDS_DESKTOP);
-       ps.add(psp1);
-
-       PropSheetPage psp2(IDD_DESKBAR_TASKBAR, WINDOW_CREATOR(TaskbarSettingsDlg));
-       psp2.dwFlags |= PSP_USETITLE;
-       psp2.pszTitle = MAKEINTRESOURCE(IDS_TASKBAR);
-       ps.add(psp2);
-
-       PropSheetPage psp3(IDD_DESKBAR_STARTMENU, WINDOW_CREATOR(StartmenuSettingsDlg));
-       psp3.dwFlags |= PSP_USETITLE;
-       psp3.pszTitle = MAKEINTRESOURCE(IDS_STARTMENU);
-       ps.add(psp3);
-
-       ps.DoModal();
-}
-
-
-DesktopSettingsDlg::DesktopSettingsDlg(HWND hwnd)
- :     super(hwnd),
-       _bmp0(IDB_ICON_ALIGN_0),
-       _bmp1(IDB_ICON_ALIGN_1),
-       _bmp2(IDB_ICON_ALIGN_2),
-       _bmp3(IDB_ICON_ALIGN_3),
-       _bmp4(IDB_ICON_ALIGN_4),
-       _bmp5(IDB_ICON_ALIGN_5),
-       _bmp6(IDB_ICON_ALIGN_6),
-       _bmp7(IDB_ICON_ALIGN_7),
-       _bmp8(IDB_ICON_ALIGN_8),
-       _bmp9(IDB_ICON_ALIGN_9),
-       _bmp10(IDB_ICON_ALIGN_10)
-{
-       new PictureButton(_hwnd, IDC_ICON_ALIGN_0, _bmp0);
-       new PictureButton(_hwnd, IDC_ICON_ALIGN_1, _bmp1);
-       new PictureButton(_hwnd, IDC_ICON_ALIGN_2, _bmp2);
-       new PictureButton(_hwnd, IDC_ICON_ALIGN_3, _bmp3);
-       new PictureButton(_hwnd, IDC_ICON_ALIGN_4, _bmp4);
-       new PictureButton(_hwnd, IDC_ICON_ALIGN_5, _bmp5);
-       new PictureButton(_hwnd, IDC_ICON_ALIGN_6, _bmp6);
-       new PictureButton(_hwnd, IDC_ICON_ALIGN_7, _bmp7);
-       new PictureButton(_hwnd, IDC_ICON_ALIGN_8, _bmp8);
-       new PictureButton(_hwnd, IDC_ICON_ALIGN_9, _bmp9);
-       new PictureButton(_hwnd, IDC_ICON_ALIGN_10, _bmp10);
-
-       _alignment_cur = SendMessage(g_Globals._hwndShellView, PM_GET_ICON_ALGORITHM, 0, 0);
-       _alignment_tmp = _alignment_cur;
-
-       _display_version_org = SendMessage(g_Globals._hwndShellView, PM_DISPLAY_VERSION, 0, MAKELONG(0,0));
-       CheckDlgButton(hwnd, ID_DESKTOP_VERSION, _display_version_org? BST_CHECKED: BST_UNCHECKED);
-}
-
-#ifndef PSN_QUERYINITIALFOCUS  // currently (as of 18.01.2004) missing in MinGW headers
-#define PSN_QUERYINITIALFOCUS (-213)
-#endif
-
-int DesktopSettingsDlg::Notify(int id, NMHDR* pnmh)
-{
-       switch(pnmh->code) {
-         case PSN_QUERYINITIALFOCUS:
-               SetWindowLong(_hwnd, DWL_MSGRESULT, (LPARAM)GetDlgItem(_hwnd, IDC_ICON_ALIGN_0+_alignment_cur));
-               break;
-
-         case PSN_APPLY:
-               _alignment_cur = _alignment_tmp;
-               _display_version_org = SendMessage(g_Globals._hwndShellView, PM_DISPLAY_VERSION, 0, MAKELONG(0,0));
-               break;
-
-         case PSN_RESET:
-               if (_alignment_tmp != _alignment_cur)
-                       SendMessage(g_Globals._hwndShellView, PM_SET_ICON_ALGORITHM, _alignment_cur, 0);
-               SendMessage(g_Globals._hwndShellView, PM_DISPLAY_VERSION, _display_version_org, MAKELONG(1,0));
-               break;
-
-         default:
-               return super::Notify(id, pnmh);
-       }
-
-       return 0;
-}
-
-int    DesktopSettingsDlg::Command(int id, int code)
-{
-       if (id>=IDC_ICON_ALIGN_0 && id<=IDC_ICON_ALIGN_10) {
-               int alignment = id - IDC_ICON_ALIGN_0;
-
-               if (alignment != _alignment_tmp) {
-                       _alignment_tmp = alignment;
-
-                       PropSheet_Changed(GetParent(_hwnd), _hwnd);
-
-                       SendMessage(g_Globals._hwndShellView, PM_SET_ICON_ALGORITHM, alignment, 0);
-               }
-
-               return 0;
-       }
-
-       switch(id) {
-         case ID_DESKTOP_VERSION:
-               SendMessage(g_Globals._hwndShellView, PM_DISPLAY_VERSION, 0, MAKELONG(0,1));    // toggle version display flag
-               PropSheet_Changed(GetParent(_hwnd), _hwnd);
-               break;
-
-         default:
-               return 1;
-       }
-
-       return 0;
-}
-
-
-TaskbarSettingsDlg::TaskbarSettingsDlg(HWND hwnd)
- :     super(hwnd),
-       _cfg_org(g_Globals._cfg)
-{
-       XMLPos options = g_Globals.get_cfg("desktopbar/options");
-
-       CheckDlgButton(hwnd, ID_SHOW_CLOCK, XMLBool(options, "show-clock", true)? BST_CHECKED: BST_UNCHECKED);
-       CheckDlgButton(hwnd, ID_HIDE_INACTIVE_ICONS, XMLBool(options, "hide-inactive", true)? BST_CHECKED: BST_UNCHECKED);
-}
-
-int TaskbarSettingsDlg::Notify(int id, NMHDR* pnmh)
-{
-       switch(pnmh->code) {
-         case PSN_APPLY:
-               _cfg_org = g_Globals._cfg;
-               break;
-
-         case PSN_RESET:
-               g_Globals._cfg = _cfg_org;
-               SendMessage(g_Globals._hwndDesktopBar, PM_REFRESH_CONFIG, 0, 0);
-               break;
-
-         default:
-               return super::Notify(id, pnmh);
-       }
-
-       return 0;
-}
-
-int    TaskbarSettingsDlg::Command(int id, int code)
-{
-       switch(id) {
-         case ID_CONFIG_NOTIFYAREA:
-               Dialog::DoModal(IDD_NOTIFYAREA, WINDOW_CREATOR(TrayNotifyDlg), _hwnd);
-               break;
-
-         case ID_SHOW_CLOCK: {
-               XMLBoolRef boolRef1(XMLPos(g_Globals.get_cfg("desktopbar/options")), "show-clock", true);
-               boolRef1.toggle();
-               SendMessage(g_Globals._hwndDesktopBar, PM_REFRESH_CONFIG, 0, 0);
-               PropSheet_Changed(GetParent(_hwnd), _hwnd);
-               break;}
-
-         case ID_HIDE_INACTIVE_ICONS: {
-               XMLBoolRef boolRef2(XMLPos(g_Globals.get_cfg("notify-icons/options")), "hide-inactive", true);
-        boolRef2.toggle();
-               SendMessage(g_Globals._hwndDesktopBar, PM_REFRESH_CONFIG, 0, 0);
-               PropSheet_Changed(GetParent(_hwnd), _hwnd);
-               break;}
-
-         default:
-               return 1;
-       }
-
-       return 0;
-}
-
-
-StartmenuSettingsDlg::StartmenuSettingsDlg(HWND hwnd)
- :     super(hwnd)
-{
-}
-
-int    StartmenuSettingsDlg::Command(int id, int code)
-{
-/*
-       switch(id) {
-         case ID_CONFIG_NOTIFYAREA:
-               Dialog::DoModal(IDD_NOTIFYAREA, WINDOW_CREATOR(TrayNotifyDlg), _hwnd);
-               return 0;
-       }
-*/
-       return 1;
-}
-
-
-MdiSdiDlg::MdiSdiDlg(HWND hwnd)
- :     super(hwnd)
-{
-       CenterWindow(hwnd);
-
-       XMLPos explorer_options = g_Globals.get_cfg("general/explorer");
-       bool mdi = XMLBool(explorer_options, "mdi", true);
-       bool separateFolders = XMLBool(explorer_options, "separate-folders", true);
-
-       int id = mdi? IDC_MDI: IDC_SDI;
-       CheckDlgButton(hwnd, id, BST_CHECKED);
-       SetFocus(GetDlgItem(hwnd, id));
-
-       CheckDlgButton(hwnd, IDC_SEPARATE_SUBFOLDERS, separateFolders?BST_CHECKED:BST_UNCHECKED);
-}
-
-int    MdiSdiDlg::Command(int id, int code)
-{      
-       if (code == BN_CLICKED) {
-               switch(id) {
-                 case IDOK: {
-                       bool mdi = IsDlgButtonChecked(_hwnd, IDC_MDI)==BST_CHECKED;
-                       bool separateFolders = IsDlgButtonChecked(_hwnd, IDC_SEPARATE_SUBFOLDERS)==BST_CHECKED;
-
-                       XMLPos explorer_options = g_Globals.get_cfg("general/explorer");
-
-                       XMLBoolRef(explorer_options, "mdi") = mdi;
-                       XMLBoolRef(explorer_options, "separate-folders") = separateFolders;
-                 } // fall through
-
-                 case IDCANCEL:
-                       EndDialog(_hwnd, id);
-                       break;
-               }
-
-               return 0;
-       }
-
-       return 1;
-}
diff --git a/reactos/subsys/system/explorer/dialogs/settings.h b/reactos/subsys/system/explorer/dialogs/settings.h
deleted file mode 100644 (file)
index a717101..0000000
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * Copyright 2004, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // dialogs/settings.h
- //
- // Explorer dialogs
- //
- // Martin Fuchs, 18.01.2004
- //
-
-
-void ExplorerPropertySheet(HWND hparent);
-
-
- /// "Desktopbar Settings" Property Sheet Dialog
-struct DesktopSettingsDlg : public OwnerDrawParent<PropSheetPageDlg>
-{
-       typedef OwnerDrawParent<PropSheetPageDlg> super;
-
-       DesktopSettingsDlg(HWND hwnd);
-
-protected:
-       ResBitmap       _bmp0;
-       ResBitmap       _bmp1;
-       ResBitmap       _bmp2;
-       ResBitmap       _bmp3;
-       ResBitmap       _bmp4;
-       ResBitmap       _bmp5;
-       ResBitmap       _bmp6;
-       ResBitmap       _bmp7;
-       ResBitmap       _bmp8;
-       ResBitmap       _bmp9;
-       ResBitmap       _bmp10;
-
-       int     _alignment_cur;
-       int     _alignment_tmp;
-
-       int     _display_version_org;
-
-       virtual int Command(int id, int code);
-       virtual int Notify(int id, NMHDR* pnmh);
-};
-
-
- /// "Taskbar Settings" Property Sheet Dialog
-struct TaskbarSettingsDlg : public PropSheetPageDlg
-{
-       typedef PropSheetPageDlg super;
-
-       TaskbarSettingsDlg(HWND hwnd);
-
-       virtual int     Command(int id, int code);
-       virtual int Notify(int id, NMHDR* pnmh);
-
-protected:
-       XMLDoc  _cfg_org;
-};
-
-
- /// "Startmenu Settings" Property Sheet Dialog
-struct StartmenuSettingsDlg : public PropSheetPageDlg
-{
-       typedef PropSheetPageDlg super;
-
-       StartmenuSettingsDlg(HWND hwnd);
-
-       virtual int     Command(int id, int code);
-};
-
-
- /// configuration dialog to choose between MDI and SDI mode
-struct MdiSdiDlg : public ResizeController<Dialog>
-{
-       typedef ResizeController<Dialog> super;
-
-       MdiSdiDlg(HWND hwnd);
-
-protected:
-       virtual int     Command(int id, int code);
-};
diff --git a/reactos/subsys/system/explorer/doc/TODO.txt b/reactos/subsys/system/explorer/doc/TODO.txt
deleted file mode 100644 (file)
index ef35cab..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-- rewrite autostart code and include all possible autostart locations
-- read "DESCRIPT.ION" files to display file descriptions
-- detect display mode changes and adjust desktop bar size
-- handling of full screen applications
-- implement additional deskbands
-- Drag Drop and file renaming on the desktop does not work.
-- implement Drag Drop from the tree view.
-- activate accelerator keys like <DEL> in shell view folders
-- program manager "progman" DDE server
-- Windows-key combos
-- Application Desktop Toolbars
-- hide CVS subdirectories, may be even implement a CVS managment plugin
-- printer and RAS connection icons in desktop notification area
-- use multi threading for launching of programs and filling start menu subdirectories
-- close start start menu when resizing explorer bar
-- adjust already open windows of all running applications when resizing explorer bar
-- implement blink effect in task bar for SetForegoundWindow() requests
-- Execute selected programs with additional command line options ("Run" dialog with pre-filled edit field)
-- switch background images with desktop switcher
-- Desktop Manager: Desktop Names; Speicherung der Verteilung von Applikations-Fenstern auf die verschiedenen Desktops -> config file
-- autostart doesn't work on NT4 ?
-- hide desktop bar when showing full screen applications
-- new start menu entry "Filemanager" close to "Explore" -> display C: and D: drive in MDI window
-- Startmenu: You can open the start menu by pressing Win-key, but can't close with another hit of Win-key.
-- Export von Bookmarks für IE (+ Mozilla)
-
-- Search Programs -> performance monitor.msc -> Abort
-
-
-<Nonvo> Martin, I would have a whish concerning explorer: I often want to start a program and give it some parameters. So nice featue: "Start with param..."
-<tinus_> Nonvo: shell extension
-<m-fuchs> tinus: we should think about installing some default shell extensions
-<tinus_> m-fuchs: perhaps, but it'd be nice if they actually were shell extensions
-
diff --git a/reactos/subsys/system/explorer/doc/changes.txt b/reactos/subsys/system/explorer/doc/changes.txt
deleted file mode 100644 (file)
index 372642f..0000000
+++ /dev/null
@@ -1,170 +0,0 @@
-You will find only major changes in this file.
-Small bug fixes and developments steps are not listet here.
-If you search for more information, look into the Subversion repository.
-
-14.10.2002     m. fuchs        Korrektur der Anpassungen durch Übernahme in wine: Anzeige der Verzeichnisnamen in Tree Pane
-                       m. fuchs        Wieder-Anpassung an natives Übersetzen unter WIN32 mit VC++
-
-15.10.2002     m. fuchs        Entfernung der Warnungsmeldung durch SetWindowText(0, ...)
-                       m. fuchs        korrekte Anzeige der Header Control-Texte (nicht Unicode -> dlls/comctl32/header.c)
-
-15.10.2002     m. fuchs        sofortige Anzeige der Dateiliste beim Starten und Öffnen neuer Fenster
-15.10.2002     m. fuchs        Programmaufruf über Doppelklick in der Dateiliste
-
-07.06.2003     m. fuchs        integration with ROS desktop window
-21.07.2003     m. fuchs        extension of winefile for shell namespace
-04.08.2003     m. fuchs        C++ explorer with architecture like MS Explorer:
-                                               usage of IShellView C++, implementation of IShellBrowser, ...
-09.08.2003     m. fuchs        class DesktopWindow for shell view on the desktop
-11.08.2003     m. fuchs        class BackgroundWindow for painting of desktop background
-                                               open child folders by double click in ShellBrowserChild
-13.08.2003     m. fuchs        make explorer bar look more like windows taskbar bar
-16.08.2003     m. fuchs        first draft of working task bar
-18.08.2003     m. fuchs        first draft of explorer start menu
-21.08.2003     m. fuchs        working start menu; beginning of tray notification area
-                                               Start menu popup is now closed when clicking in another window.
-22.08.2003     m. fuchs        implemented clock display in tray notification area
-                                               implemented quick launch bar
-23.08.2003     m. fuchs        implemented "Run..." dialog by calling shell32.dll
-                                               fixed memory and GDI handle leaks
-                                               implemented context menus for task bar
-                                               tool tips for quick launch bar
-24.08.2003     m. fuchs        added reactos logo to startmenu
-                                               added romanian translation of Ciobanu Alexander
-26.08.2003     m. fuchs        implemented tooltips and launching of date/time control panel applet for clock display
-27.08.2003     m. fuchs        partly implemented control panel window
-28.08.2003     m. fuchs        control panel window in cabinet view mode
-29.09.2003     m. fuchs        Now we handle start menu popups via StartMenuRoot::TrackStartmenu().
-30.09.2003     m. fuchs        compatibility to building as Winelib application
-10.09.2003     m. fuchs        compatibility changes for correct desktop windows size on Windows NT
-19.09.2003     m. fuchs        compatibility changes for correct start menu subentries on Windows 9x
-27.09.2003     m. fuchs        moved start menu entries for control panel, etc. into new settings submenu
-                                               created a Makefile for compiling as standalone project using MinGW
-                                               eliminated all warnings displayed when using -Wall
-                                               activated option for compiling as UNICODE version
-                                               merged start menus of the same name (e.g. "All Users\Startup" with "<User>\Startup")
-28.09.2003     m. fuchs        open cabinet windows then clicking on desktop folders
-18.10.2003     m. fuchs        Program search dialog with interactive filtering and sorting does now work.
-19.10.2003     m. fuchs        implemented floating start menus
-29.11.2003     m. fuchs        implemented GDB stub for remote debugging
-06.12.2003     m. fuchs        basic support to display NTFS streams in winefile windows
-20.12.2003     m. fuchs        context menu implementation for desktop window 
-01.01.2004     m. fuchs        integrated icons of Everaldo (http://www.everaldo.com) into the start menu.
-02.01.2004     m. fuchs        reimplemented start menu as light weight version
-03.01.2004     m. fuchs        lazy icon extraction for start menu
-                                               direct file system access for start menu
-04.01.2004     m. fuchs        implemented icon cache
-11.01.2004     m. fuchs        keyboard navigation in start menu
-14.01.2004     m. fuchs        automatically adjusted size of notification area and quicklaunch bar in desktop bar
-18.01.2004     m. fuchs        explorer/desktop settings property sheet
-31.01.2004     m. fuchs        included NT Object namespace as virtual file system
-31.01.2004     m. fuchs        included Registry as virtual file system
-02.02.2004     m. fuchs        reading of FAT image files
-07.02.2004     m. fuchs        included IE/Mozilla as Active X control
-08.02.2004     m. fuchs        desktop switching
-16.02.2004     m. fuchs        lean explorer version without additional bells and whistles -> see CVS branch "lean-explorer"
-23.02.2004     m. fuchs        start menu navigation using first characters of entry names
-                                               fixes for leaking GDI handles
-25.02.2004     m. fuchs        rebar control for desktop bar
-28.02.2004     m. fuchs        "minimize all" functionality
-                                               various fixes for notification icons, task bar and desktop switching
-12.03.2004     m. fuchs        automatic adjustment start button to text size
-15.03.2004     m. fuchs        implementation of volume control tray icon
-20.03.2004     m. fuchs        context menu for notification area
-21.03.2004     m. fuchs        configuration dialog for notification icons
-                                               XML storage for configuration options
-28.03.2004     m. fuchs        configuration options for showing/hiding clock, ...
-04.04.2004     m. fuchs        import of IE bookmarks; explorer sidebar with bookmark display
-09.04.2004     m. fuchs        changed favorites start menu implementation to work with internal bookmarks
-
-12.04.2004     m. fuchs        ShellBrowserChild: jump to addressbar target
-17.05.2004     m. fuchs        use precompiled headers for VC++ builds
-01.06.2004     m. fuchs        integrate optional SDI mode into main explorer branch
-15.07.2004     m. fuchs        fix root path for folders opened from the desktop
-18.07.2004     m. fuchs        precompiled header support for GCC 3.4.1
-31.07.2004     m. fuchs        use same startmenu entries height as MS explorer
-02.08.2004     m. fuchs        context menus for start menus and quick launch bar
-03.08.2004     m. fuchs        get version number to display from RES_STR_PRODUCT_VERSION
-16.08.2004     m. fuchs        display version information in about dialog and on the desktop
-15.09.2004     m. fuchs        remove direct version output from desktop; instead store the activation flag into the registry
-17.09.2004     m. fuchs        handle "." and ".." as special direcory names and move them at the very first beginning of directory listings
-23.09.2004     m. fuchs        configuration dialog to choose between MDI and SDI mode with persistent storage
-20.11.2004     m. fuchs        display notification icon change times
-                                               notification area button to toggle hidden icons
-                       m. fuchs        alpha-blend hidden notification icons
-                       m. fuchs        fix UTF8 conversion for the bookmarks list
-                       m. fuchs        decode HTML-encoded bookmark names
-                       m. fuchs        work around GCC's wide string constant bug when compiling inline functions
-27.12.2004     m. fuchs        fix GPF for clicks in the favorites folder
-09.01.2005     frik85  update for german resource scripts
-10.01.2005     m. fuchs        new _NO_ALPHABLEND compiler switch
-21.01.2005     tamlin  Fix crashing browsing NT object namespace with non-zero-terminated UNICODE_STRING.
-27.01.2005     m. fuchs        fixes for command line handling 
-06.02.2005     m. fuchs        support for owner drawn context menus at various places
-08.02.2005     gvg     Prefer SEE_MASK_IDLIST, since that one is actually implemented in shell32
-20.02.2005     m. fuchs        updates for Expat and XMLStorage files
-21.02.2005     m. fuchs        move public expat headers into common include folder
-27.02.2005     frik85  Add support for explorer to load the desk.cpl when right clicking on background. 
-04.03.2005     fireball        New StartMenu and ReactOS icons by Mindflyer
-05.03.2005     m. fuchs        case insensitive startmenu merging
-                       m. fuchs        update ROS icon in about dialog and start menu side bar
-14.03.2005     gvg     tinus: Use RegisterShellHookWindow()
-19.03.2005     m. fuchs        register ourselves as task manager window to make the RegisterShellHookWindow() call working [thanks to Filip :)]
-21.03.2005     fireball        Nice "About Explorer" icon by Mindflyer
-27.03.2005     m. fuchs        hide login screen to make the login on XP faster
-                       m. fuchs        launch shell DDE server
-                       m. fuchs        make Shell Hook Messages really work in Windows
-27.03.2005     greatlrd        New Explorer icon from Mindflyer
-28.03.2005     m. fuchs        launch all registered Shell Service Objects (Systray, network icons, ...)
-                       m. fuchs        enable multiline tooltips
-01.04.2005     greatlrd        David Nordenberg: fixed minor things in swedish translation
-02.04.2005     m. fuchs        terminate shell service objects thread if there is nothing to do
-                       m. fuchs        switch to search icon in search dialog
-                       m. fuchs        fix tray icon config dialog for the first icon
-                       m. fuchs        "minimize all": only minimize windows with valid positions
-                       m. fuchs        fix termination of "search program" dialog
-03.04.2005     m. fuchs        fix SDI shell browser
-                       m. fuchs        display "log off" dialog, add "terminate" menu entry
-                       m. fuchs        show logoff dialog in lean explorer
-                       m. fuchs        activate printer folder menu
-14.04.2005     m. fuchs        charn: step-wise taskbar resizing
-01.05.2005     m. fuchs        merge ROS Shell without integrated explorer part into trunk
-03.05.2005     m. fuchs        display custom folders in start menu root
-03.05.2005     m. fuchs        rosshell: printer and network folder in start menu
-04.05.2005     greatlrd        Fixes for Swedish resource script
-20.05.2005     navaraf Luk "denzil" Frolka: partial Czech translation of Explorer
-02.06.2005     fireball        First version of Explorer's translation into Russian. Done by Dmitry Philippov, checked by me, DarkHobbit and others
-03.06.2005     m. fuchs        split the big explorer resource file into smaller language specific rescource scripts
-05.06.2005     hpoussin        Include French resources in explorer
-15.07.2005     greatlrd        update swedish .rc and rename it from sw to sv, remove the german part in swedish rc
-16.07.2005     greatlrd        crop the startmenu side bar logo to 30x280
-17.07.2005     m. fuchs        add explorer-ro.rc
-26.08.2005     navaraf Make the explorer taskbar look a bit nicer
-12.09.2005     royce   security audit of explorer code: strcpy -> lstrcpyn, ...
-19.09.2005     navaraf Fix the taskbar button resizing to account for button spacing.
-21.09.2005     m. fuchs        XMLStorage update, Bugfix for UTF-8 strings
-                       m. fuchs        use size_t for buffer/string lengths instead of int, define COUNTOF if not defined already
-25.09.2005     navaraf Patricio Martínez Ros: Update spanish translation
-25.09.2005     m. fuchs        new tool bar icons for the drive bar
-                       m. fuchs        refactor all IUnknown implementations using IComSrvBase
-30.09.2005     m. fuchs        Fix of Bugzilla Bug 676: dynamic explorer start menu sidebar size
-01.10.2005     greatlrd        new, smaller startmenu pictures using the dynamic explorer start menu sidebar feature
-01.10.2005     m. fuchs        MDI/SDI option dialog: pictures for illustration, remove resizable flag
-02.10.2005     m. fuchs        new option to open explorer subfolders in separate windows
-                       m. fuchs        fix enabling of split border
-                       m. fuchs        fix directory traversing in explorer SDI windows
-                       m. fuchs        fix tree list image loading: work around GCC's wide string constant bug
-04.10.2005     m. fuchs        complete german resources for explorer
-04.10.2005     m. fuchs        "execute" menu entry
-                       m. fuchs        activate execution from command bar
-05.10.2005     m. fuchs        fix UNICODE control panel calls to handle double clicks on the task bar clock
-                       m. fuchs        one-click activation of "Start" button
-                       m. fuchs        use GET_X_LPARAM macro in WM_MOUSEMOVE handlers
-                       m. fuchs        leave TrackStartmenu() function when executing any start menu command
-06.10.2005     m. fuchs        implemented command line parser for Explorer
-09.10.2005     m. fuchs        Fix for Bugzilla Entry 330: Correctly handle WM_COMMAND messages in web windows without web control
-                       m. fuchs        replace "search computer" start menu entry by a "not yet implemented" message
-01.11.2005     m. fuchs        String::str(), String::toLower() to allow conventient and WINE compatible string conversions
-29.11.2005     m. fuchs        Adjustments for Visual Studio 2005: use new secure CT functions, COUNTOF for buffer sizes
-28.12.2005     m. fuchs        display icon overlays in Explorer tree view
-31.12.2005     m. fuchs        handle "/root" command line parameter
diff --git a/reactos/subsys/system/explorer/doc/readme.txt b/reactos/subsys/system/explorer/doc/readme.txt
deleted file mode 100644 (file)
index 0324dd1..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-
-For information on how to compile and install the ReactOS Explorer please look at the FAQ web page:
-
-http://www.sky.franken.de/explorer/
-
-
-
-Desktop Example
----------------
-
-This program doesn't do much, apart from create a window which could be
-used as a desktop.
-
-It's pretty straightforward. It creates a window the size of the screen,
-displays some text in the corner, and then disables ALT+F4.
-
-Ideally, this would be incorporated into some other part of ReactOS, where
-it could be closed in a controlled manner (ie, when the user wishes to exit
-the GUI.)
-
-Hope someone finds it of some use. I think it should run before the
-explorer clone (taskbar) to get the wallpaper displayed (since when
-explorer crashes on Windows, the wallpaper is always displayed, and there
-is always a desktop, even with no icons, when the login window is shown.)
-
-It obviously is in need of some improvement, such as wallpaper actually
-being drawn (stretch, center/centre and tile...)
-
-So, feel free to play around with it.
-
-Andrew "Silver Blade" Greenwood
-silverblade_uk@hotmail.com
-
-
-Explorer Bar Example
---------------------
-
-I have merged in Alexander Ciobanu's Explorer bar code as a example starting
-for the start menu. Its very simple at this point and just loads a window with 
-buttons. 
-
-The loading of this module was based on a patch by Martin Fuchs.
-
-Steven Edwards 
-Steven_Ed4153@yahoo.com
diff --git a/reactos/subsys/system/explorer/doxy-footer.html b/reactos/subsys/system/explorer/doxy-footer.html
deleted file mode 100644 (file)
index 1ed7376..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-<hr size="1">
-<table border="0" width="100%" cellspacing="0">
-  <tr>
-    <td><address style="align: right;"><small>
-ROS Explorer Source Code Documentation
-<br>generated on 21.11.2004 by <a href="http://www.doxygen.org/index.html">
-<img src="doxygen.png" alt="doxygen" align="middle" border=0>
-       </small></address>
-       </td>
-    <td>
-      <p align="right"><a href="http://www.sky.franken.de/explorer/" target="_parent">ROS Explorer Homepage</a>
-      </td>
-  </tr>
-</table>
-</body>
-</html>
diff --git a/reactos/subsys/system/explorer/doxy-footer.htmt b/reactos/subsys/system/explorer/doxy-footer.htmt
deleted file mode 100644 (file)
index 53f33c8..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-<hr size="1">
-<table border="0" width="100%" cellspacing="0">
-  <tr>
-    <td><address style="align: right;"><small>
-ROS Explorer Source Code Documentation
-<br>@GEN@ by <a href="http://www.doxygen.org/index.html">
-<img src="doxygen.png" alt="doxygen" align="middle" border=0>
-       </small></address>
-       </td>
-    <td>
-      <p align="right"><a href="http://www.sky.franken.de/explorer/" target="_parent">ROS Explorer Homepage</a>
-      </td>
-  </tr>
-</table>
-</body>
-</html>
diff --git a/reactos/subsys/system/explorer/expat.license b/reactos/subsys/system/explorer/expat.license
deleted file mode 100644 (file)
index 5c5d524..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-Copyright (c) 1998, 1999, 2000 Thai Open Source Software Center Ltd
-                               and Clark Cooper
-Copyright (c) 2001, 2002, 2003 Expat maintainers.
-
-Permission is hereby granted, free of charge, to any person obtaining
-a copy of this software and associated documentation files (the
-"Software"), to deal in the Software without restriction, including
-without limitation the rights to use, copy, modify, merge, publish,
-distribute, sublicense, and/or sell copies of the Software, and to
-permit persons to whom the Software is furnished to do so, subject to
-the following conditions:
-
-The above copyright notice and this permission notice shall be included
-in all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/reactos/subsys/system/explorer/explorer-cfg-template.xml b/reactos/subsys/system/explorer/explorer-cfg-template.xml
deleted file mode 100644 (file)
index 9597e12..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<explorer-cfg>
-  <general>
-    <look-and-feel name="classic"/>
-       <explorer mdi="true" separate-folders="true"/>
-       <language name="EN"/>
-  </general>
-
-  <desktop>
-    <icon-alignment algorithm="simple" start="left-top" direction="horizontal"/>
-  </desktop>
-  <desktopbar>
-    <options show-clock="true"/>
-    <positions>
-         <bar name="quicklaunch" left="10" top="2" width="250" height="22"/>
-         <bar name="taskbar" left="300" top="2" width="400" height="22"/>
-       </positions>
-  </desktopbar>
-
-  <taskbar>
-  </taskbar>
-
-  <notify-icons>
-    <options hide-inactive="true" show-button="true" show-hidden="false"/>
-    <icon name="Volume Control" text="Volume" show="show"/>
-  </notify-icons>
-
-  <startmenu>
-    <order>
-       </order>
-  </startmenu>
-
-  <quicklaunch>
-    <order>
-       </order>
-  </quicklaunch>
-
-  <launchbar>
-    <entry type="startmenu"/>
-
-    <entry type="programs">
-    </entry>
-
-    <entry type="settings"/>
-    <entry type="desktops"/>
-    <entry type="notify-area"/>
-    <entry type="clock"/>
-  </launchbar>
-</explorer-cfg>
diff --git a/reactos/subsys/system/explorer/explorer-cn.rc b/reactos/subsys/system/explorer/explorer-cn.rc
deleted file mode 100644 (file)
index 7b36104..0000000
Binary files a/reactos/subsys/system/explorer/explorer-cn.rc and /dev/null differ
diff --git a/reactos/subsys/system/explorer/explorer-cz.rc b/reactos/subsys/system/explorer/explorer-cz.rc
deleted file mode 100644 (file)
index 42c129d..0000000
+++ /dev/null
@@ -1,401 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include "resource.h"
-#define APSTUDIO_HIDDEN_SYMBOLS
-#include "windows.h"
-#undef APSTUDIO_HIDDEN_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// Czech resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CSY)
-#ifdef _WIN32
-LANGUAGE LANG_CZECH, SUBLANG_DEFAULT
-#pragma code_page(1250)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_MDIFRAME MENU PRELOAD DISCARDABLE 
-BEGIN
-    POPUP "&Soubor"
-    BEGIN
-        MENUITEM "&Spustit...",                 ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Ukonèit",                    ID_FILE_EXIT
-    END
-    POPUP "&Zobrazení"
-    BEGIN
-        MENUITEM "&Li\9ata nástrojù",             ID_VIEW_TOOL_BAR
-        MENUITEM "&Extra Bar",                  ID_VIEW_EXTRA_BAR
-        MENUITEM "L&i\9ata diskù",                ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "&Boèní li\9ata",                ID_VIEW_SIDE_BAR
-        MENUITEM "&Status Bar",                 ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Aktualizovat\tF5",           ID_REFRESH
-        MENUITEM "&Celá obrazovka\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-        MENUITEM "SDI",                         ID_VIEW_SDI
-    END
-    POPUP "&Okno"
-    BEGIN
-        MENUITEM "&Nové Okno",                  ID_WINDOW_NEW
-        MENUITEM "&Kaskádovat\tShift+F5",       ID_WINDOW_CASCADE
-        MENUITEM "&Uspoøádat vodorovnì",        ID_WINDOW_TILE_HORZ
-        MENUITEM "U&spoøádat svisle\tShift+F4", ID_WINDOW_TILE_VERT
-        MENUITEM "Us&poøádat automaticky",      ID_WINDOW_AUTOSORT
-        MENUITEM "Usp&oøádat symboly",          ID_WINDOW_ARRANGE
-    END
-    POPUP "&Nástroje"
-    BEGIN
-        MENUITEM "&Nastavení",                  ID_TOOLS_OPTIONS
-    END
-    POPUP "&Pomoc"
-    BEGIN
-        MENUITEM "&Prùzkumník &FAQ...",         ID_EXPLORER_FAQ
-        MENUITEM "O p&rùzkumníku...",           ID_ABOUT_EXPLORER
-        MENUITEM "&O OS...",                    ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_DESKTOPBAR MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Nastavení...",               ID_DESKTOPBAR_SETTINGS
-        MENUITEM "&Správce úloh...",            ID_TASKMGR
-        MENUITEM SEPARATOR
-        MENUITEM "&O Exploreru...",             ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_VOLUME MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Otevøít ovládání hlasitosti", ID_TRAY_VOLUME
-        MENUITEM "&Upravit vlastnosti zvuku",   ID_VOLUME_PROPERTIES
-    END
-END
-
-IDM_NOTIFYAREA MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Zobrazit skryté ikony",      ID_SHOW_HIDDEN_ICONS
-        MENUITEM "Z&obrazit ikonu tlaèítka",    ID_SHOW_ICON_BUTTON
-        MENUITEM "&Nastavit upozornìní...",     ID_CONFIG_NOTIFYAREA
-        MENUITEM "N&astavit datum a èas...",    ID_CONFIG_TIME
-        MENUITEM SEPARATOR
-        MENUITEM "&O prùzkuníku...",            ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_SDIFRAME MENU PRELOAD DISCARDABLE 
-BEGIN
-    POPUP "&Soubor"
-    BEGIN
-        MENUITEM "&Spustit...",                 ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Ukonèit",                    ID_FILE_EXIT
-    END
-    POPUP "&Zobrazení"
-    BEGIN
-        MENUITEM "&Li\9ata nástrojù",             ID_VIEW_TOOL_BAR
-        MENUITEM "&Boèní li\9ata",                ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "&Status li\9ata",               ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Aktualizovat\tF5",           ID_REFRESH
-        MENUITEM "Celá obrazovka\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-        MENUITEM "&MDI",                        ID_VIEW_MDI
-    END
-    POPUP "&Nástroje"
-    BEGIN
-        MENUITEM "&Nastavení",                  ID_TOOLS_OPTIONS
-    END
-    POPUP "&Pomoc"
-    BEGIN
-        MENUITEM "Prùzkumník &FAQ...",          ID_EXPLORER_FAQ
-        MENUITEM "O &prùzkumníku...",           ID_ABOUT_EXPLORER
-        MENUITEM "O &OS...",                    ID_ABOUT_WINDOWS
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_EXECUTE DIALOG FIXED IMPURE  15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Spustit"
-FONT 8, "MS Shell Dlg"
-BEGIN
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,162,10
-    CONTROL         "&Command:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,
-                    18,60,10
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL
-    CONTROL         "As &Symbol",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,3,
-                    45,71,12
-    DEFPUSHBUTTON   "&Spustit",1,158,6,47,14
-    PUSHBUTTON      "&Zru\9ait",2,158,23,47,14
-    PUSHBUTTON      "&Pomoc",254,158,43,47,14
-END
-
-IDD_SEARCH_PROGRAM DIALOGEX 0, 0, 200, 65
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Hledat program v nabídce Start"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "&Filter:",IDC_STATIC,7,9,18,8
-    EDITTEXT        IDC_FILTER,34,7,100,14,ES_AUTOHSCROLL
-    CONTROL         "List1",IDC_PROGRAMS_FOUND,"SysListView32",LVS_REPORT | 
-                    LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | 
-                    WS_TABSTOP,7,25,186,33
-    PUSHBUTTON      "&Vyhledat",IDC_CHECK_ENTRIES,143,7,50,14
-END
-
-IDD_DESKBAR_DESKTOP DIALOG DISCARDABLE  0, 0, 212, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Vlastnosti plochy"
-FONT 8, "MS Sans Serif"
-BEGIN
-    LTEXT           "Prosím zvolte si zpùsob zarovnání ikon:",IDC_STATIC,7,7,
-                    166,8
-    CONTROL         "left/top dwn",IDC_ICON_ALIGN_0,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,25,46,44
-    CONTROL         "left/top right",IDC_ICON_ALIGN_1,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,25,46,44
-    CONTROL         "right/top left",IDC_ICON_ALIGN_2,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,25,46,44
-    CONTROL         "rig./top dwn",IDC_ICON_ALIGN_3,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,25,46,44
-    CONTROL         "left/bot. up",IDC_ICON_ALIGN_4,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,73,46,44
-    CONTROL         "left/bot. right",IDC_ICON_ALIGN_5,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,73,46,44
-    CONTROL         "right/bot. left",IDC_ICON_ALIGN_6,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,73,46,44
-    CONTROL         "rig./bot. dwn",IDC_ICON_ALIGN_7,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,73,46,44
-    CONTROL         "border down",IDC_ICON_ALIGN_8,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,121,46,44
-    CONTROL         "border H/V",IDC_ICON_ALIGN_9,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,121,46,44
-    CONTROL         "round about",IDC_ICON_ALIGN_10,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,121,46,44
-    CONTROL         "",IDC_ICON_ALIGN_11,"Button",BS_OWNERDRAW | BS_BOTTOM | 
-                    WS_TABSTOP,159,121,46,44
-    CONTROL         "Zobrazit verzi",ID_DESKTOP_VERSION,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,177,91,10
-END
-
-IDD_DESKBAR_TASKBAR DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Vlastnosti panelu úloh"
-FONT 8, "MS Sans Serif"
-BEGIN
-    CONTROL         "&Zobrazit èas",ID_SHOW_CLOCK,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,152,52,10
-    CONTROL         "&Skrýt neaktivní ikony",ID_HIDE_INACTIVE_ICONS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,174,111,10
-    PUSHBUTTON      "&Upozornìní...",ID_CONFIG_NOTIFYAREA,153,173,50,14
-END
-
-IDD_DESKBAR_STARTMENU DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Vlastnosti nabídky Start"
-FONT 8, "MS Sans Serif"
-BEGIN
-END
-
-IDD_NOTIFYAREA DIALOGEX 0, 0, 208, 174
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Nastavení ikon v oblasti upozoròování"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    CONTROL         "Tree1",IDC_NOTIFY_ICONS,"SysTreeView32",TVS_HASLINES | 
-                    TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,194,31
-    LTEXT           "&Tooltip Text:",IDC_LABEL1,7,44,40,8
-    EDITTEXT        IDC_NOTIFY_TOOLTIP,58,42,143,14,ES_AUTOHSCROLL
-    LTEXT           "W&indow Title:",IDC_LABEL2,7,63,44,8
-    EDITTEXT        IDC_NOTIFY_TITLE,58,60,143,14,ES_AUTOHSCROLL
-    LTEXT           "&Module Path:",IDC_LABEL3,7,81,43,8
-    EDITTEXT        IDC_NOTIFY_MODULE,58,78,143,14,ES_AUTOHSCROLL
-    GROUPBOX        "&Display Mode",IDC_LABEL4,7,96,157,28
-    CONTROL         "&show",IDC_NOTIFY_SHOW,"Button",BS_AUTORADIOBUTTON | 
-                    WS_TABSTOP,15,108,33,10
-    CONTROL         "&hide",IDC_NOTIFY_HIDE,"Button",BS_AUTORADIOBUTTON,66,
-                    108,29,10
-    CONTROL         "a&utohide",IDC_NOTIFY_AUTOHIDE,"Button",
-                    BS_AUTORADIOBUTTON,112,108,43,10
-    ICON            "",IDC_PICTURE,173,101,21,20
-    LTEXT           "&Last Change:",IDC_LABEL6,7,132,43,8
-    EDITTEXT        IDC_LAST_CHANGE,59,129,105,14,ES_AUTOHSCROLL | 
-                    ES_READONLY
-    CONTROL         "sho&w hidden",ID_SHOW_HIDDEN_ICONS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,154,56,10
-    DEFPUSHBUTTON   "&Nastavit",IDOK,91,153,50,14,WS_GROUP
-    PUSHBUTTON      "&Zru\9ait",IDCANCEL,151,153,50,14
-END
-
-IDD_MDI_SDI DIALOGEX 0, 0, 194, 157
-STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Volba MDI / SDI módu"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "Prosím zvolte si Vámi upøednostòovaný zpùsob zobrazení oken prùzkumníka:",
-                    IDC_STATIC,7,7,160,8
-    CONTROL         "&MDI (Mnoho dokumentový interface)",IDC_MDI,"Button",
-                    BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,7,31,121,10
-    CONTROL         "&SDI (Jedno dokumentový interface)",IDC_SDI,"Button",
-                    BS_AUTORADIOBUTTON,7,62,115,10
-    CONTROL         170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13
-    CONTROL         171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13
-    CONTROL         "Open Subfolders in s&eparate windows",
-                    IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,90,135,10
-    LTEXT           "Toto nastavení bude pou\9eito jako implicitní pro v\9aechny okna prùzkumníka.",
-                    IDC_STATIC,7,111,174,22
-    DEFPUSHBUTTON   "&Nastavit",IDOK,29,136,50,14,WS_GROUP
-    PUSHBUTTON      "&Zru\9ait",IDCANCEL,106,136,50,14
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "Reactos prùzkumník"
-    IDS_START               "Start"
-    IDS_LOGOFF              "Odhlásit se..."
-    IDS_SHUTDOWN            "Vypnout..."
-    IDS_LAUNCH              "Spustit..."
-    IDS_START_HELP          "Pomoc"
-    IDS_SEARCH_FILES        "Hledat..."
-    IDS_DOCUMENTS           "Dokumenty"
-    IDS_FAVORITES           "Oblíbené"
-    IDS_PROGRAMS            "Programy"
-    IDS_SETTINGS            "Nastavení"
-    IDS_EXPLORE             "Prozkoumat"
-    IDS_EMPTY               "(Prázdné)"
-    IDS_RECENT              "Nedávné dokumenty"
-    IDS_ADMIN               "Administrace"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_STARTMENU           "Nabídka Start"
-    IDS_MINIMIZE_ALL        "minimalizovat v\9aechna okna"
-    IDS_DESKTOP_NUM         "Plocha %d"
-    IDS_VOLUME              "Hlasitost"
-    IDS_ITEMS_CUR           "souèasné polo\9eky"
-    IDS_ITEMS_CONFIGURED    "nastavení"
-    IDS_ITEMS_VISIBLE       "viditelné"
-    IDS_ITEMS_HIDDEN        "skryté"
-    IDS_NOTIFY_SHOW         "zobrazit"
-    IDS_NOTIFY_HIDE         "skrýt"
-    IDS_NOTIFY_AUTOHIDE     "skrývat automaticky"
-    IDS_SHOW_HIDDEN_ICONS   "Zobrazit skryté ikony"
-    IDS_HIDE_ICONS          "Skrýt ikony"
-    IDS_TERMINATE           "Ukonèit ReactOS prùzkumník"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_NETWORK             "Sí\8d"
-    IDS_CONNECTIONS         "Sí\9dové spojení"
-    IDS_DRIVES              "Disky"
-    IDS_SEARCH_COMPUTER     "Hledat..."
-    IDS_SETTINGS_MENU       "Nastavení"
-    IDS_CONTROL_PANEL       "Ovládací panel"
-    IDS_PRINTERS            "Tiskárny"
-    IDS_BROWSE              "Prohlí\9eet soubory"
-    IDS_SEARCH_PRG          "Search Program..."
-    IDS_ALL_USERS           "V\9aichni u\9eivatelé\\"
-    IDS_SEARCH              "Hledat"
-    IDS_ABOUT_EXPLORER      "&O prùzkumníku..."
-    IDS_LAUNCH_MANY_PROGRAMS 
-                            "Spustili jste více ne\9e jeden program.\nJste si jisti, \9ee je chcete spustit v\9aechny?"
-    IDS_DESKTOPBAR_SETTINGS "Nastavení plochy"
-    IDS_DESKTOP             "Plocha"
-    IDS_TASKBAR             "Panel úloh"
-END
-
-#endif    // Czech resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-/////////////////////////////////////////////////////////////////////////////
-// German (Germany) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)
-#ifdef _WIN32
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-#pragma code_page(1252)
-#endif //_WIN32
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#include ""resource.h""\r\n"
-    "#define APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "#include ""windows.h""\r\n"
-    "#undef APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-#endif    // German (Germany) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/explorer-de.rc b/reactos/subsys/system/explorer/explorer-de.rc
deleted file mode 100644 (file)
index 34ab5f6..0000000
+++ /dev/null
@@ -1,405 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include "resource.h"
-#define APSTUDIO_HIDDEN_SYMBOLS
-#include "windows.h"
-#undef APSTUDIO_HIDDEN_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// German (Germany) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)
-#ifdef _WIN32
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-#pragma code_page(1252)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_MDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Datei"
-    BEGIN
-        MENUITEM "&Ausführen...",               ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Beenden",                    ID_FILE_EXIT
-    END
-    POPUP "&Ansicht"
-    BEGIN
-        MENUITEM "&Toolbar",                    ID_VIEW_TOOL_BAR
-        MENUITEM "&Extra Bar",                  ID_VIEW_EXTRA_BAR
-        MENUITEM "Lauf&werkleiste",             ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "S&ide Bar",                   ID_VIEW_SIDE_BAR
-        MENUITEM "&Status Bar",                 ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Aktualisieren\tF5",          ID_REFRESH
-        MENUITEM "&Vollbild\tCtrl+Shift+S",     ID_VIEW_FULLSCREEN
-        MENUITEM "SDI",                         ID_VIEW_SDI
-    END
-    POPUP "&Fenster"
-    BEGIN
-        MENUITEM "Neues &Fenster",              ID_WINDOW_NEW
-        MENUITEM "Über&lappend\tUmschalt+F5",   ID_WINDOW_CASCADE
-        MENUITEM "&Untereinander",              ID_WINDOW_TILE_HORZ
-        MENUITEM "&Nebeneinander\tUmschalt+F4", ID_WINDOW_TILE_VERT
-        MENUITEM "au&tomatisch anordnen",       ID_WINDOW_AUTOSORT
-        MENUITEM "&Symbole anordnen",           ID_WINDOW_ARRANGE
-    END
-    POPUP "&Extras"
-    BEGIN
-        MENUITEM "&Optionen",                   ID_TOOLS_OPTIONS
-    END
-    POPUP "&Hilfe"
-    BEGIN
-        MENUITEM "Explorer &FAQ...",            ID_EXPLORER_FAQ
-        MENUITEM "&Über ReactOS Explorer...",   ID_ABOUT_EXPLORER
-        MENUITEM "Über React&OS...",            ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_SDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Datei"
-    BEGIN
-        MENUITEM "&Ausführen...",               ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Schliessen",                 ID_FILE_EXIT
-    END
-    POPUP "&Ansicht"
-    BEGIN
-        MENUITEM "&Toolbar",                    ID_VIEW_TOOL_BAR
-        MENUITEM "S&ide Bar",                   ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "&Status Bar",                 ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Aktualisieren\tF5",          ID_REFRESH
-        MENUITEM "&Vollbild\tCtrl+Shift+S",     ID_VIEW_FULLSCREEN
-        MENUITEM "&MDI",                        ID_VIEW_MDI
-    END
-    POPUP "&Extras"
-    BEGIN
-        MENUITEM "&Optionen",                   ID_TOOLS_OPTIONS
-    END
-    POPUP "&Hilfe"
-    BEGIN
-        MENUITEM "Explorer &FAQ...",            ID_EXPLORER_FAQ
-        MENUITEM "&Über Explorer...",          ID_ABOUT_EXPLORER
-        MENUITEM "Über &OS...",                ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_DESKTOPBAR MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Einstellungen...",           ID_DESKTOPBAR_SETTINGS
-        MENUITEM "&Task Manager...",            ID_TASKMGR
-        MENUITEM SEPARATOR
-        MENUITEM "&Über Explorer...",           ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_NOTIFYAREA MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Zeige versteckte Icons",     ID_SHOW_HIDDEN_ICONS
-        MENUITEM "Zeige Icon-&Button",          ID_SHOW_ICON_BUTTON
-        MENUITEM "&Konfiguriere Benachrichtigungen...", ID_CONFIG_NOTIFYAREA
-        MENUITEM "Einstellen von &Datum/Zeit...", ID_CONFIG_TIME
-        MENUITEM SEPARATOR
-        MENUITEM "&Über Explorer...",           ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_VOLUME MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "Öffne &Lautstärkeregler",     ID_TRAY_VOLUME
-        MENUITEM "Editieren der Audio-&Einstellungen", ID_VOLUME_PROPERTIES
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_EXECUTE DIALOG DISCARDABLE  15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Ausführen"
-FONT 8, "MS Shell Dlg"
-BEGIN
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,162,10
-    CONTROL         "Befehls&zeile:",-1,"Static",SS_LEFTNOWORDWRAP | 
-                    WS_GROUP,3,18,60,10
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL
-    CONTROL         "Als &Symbol",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,
-                    3,45,71,12
-    DEFPUSHBUTTON   "&OK",1,158,6,47,14
-    PUSHBUTTON      "A&bbrechen",2,158,23,47,14
-    PUSHBUTTON      "&Hilfe",254,158,43,47,14
-END
-
-IDD_ABOUT_EXPLORER DIALOG DISCARDABLE  0, 0, 199, 106
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Über ReactOS Explorer"
-FONT 10, "MS Sans Serif"
-BEGIN
-    LTEXT           "ReactOS Explorer",IDC_ROS_EXPLORER,91,13,104,11
-    LTEXT           "V 0.9",IDC_VERSION_TXT,91,27,104,8
-    LTEXT           "(c) 2003-2005 Martin Fuchs",IDC_STATIC,91,42,104,8
-    LTEXT           "",IDC_WIN_VERSION,91,58,98,22
-    LTEXT           "http://www.sky.franken.de/explorer/",IDC_WWW,17,84,129,
-                    8
-    CONTROL         "&OK",IDOK,"Button",BS_OWNERDRAW | BS_FLAT | WS_GROUP,
-                    154,90,38,12
-END
-
-IDD_DESKBAR_DESKTOP DIALOG DISCARDABLE  0, 0, 212, 204
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Desktop-Einstellungen"
-FONT 8, "MS Sans Serif"
-BEGIN
-    LTEXT           "Bitte wählen Sie den gewünschten Platzierungs-Algorithmus für die Desktop-Icons aus:",
-                    IDC_STATIC,7,7,197,23
-    CONTROL         "left/top dwn",IDC_ICON_ALIGN_0,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,35,46,44
-    CONTROL         "left/top right",IDC_ICON_ALIGN_1,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,35,46,44
-    CONTROL         "right/top left",IDC_ICON_ALIGN_2,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,35,46,44
-    CONTROL         "rig./top dwn",IDC_ICON_ALIGN_3,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,35,46,44
-    CONTROL         "left/bot. up",IDC_ICON_ALIGN_4,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,83,46,44
-    CONTROL         "left/bot. right",IDC_ICON_ALIGN_5,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,83,46,44
-    CONTROL         "right/bot. left",IDC_ICON_ALIGN_6,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,83,46,44
-    CONTROL         "rig./bot. dwn",IDC_ICON_ALIGN_7,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,83,46,44
-    CONTROL         "border down",IDC_ICON_ALIGN_8,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,131,46,44
-    CONTROL         "border H/V",IDC_ICON_ALIGN_9,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,131,46,44
-    CONTROL         "round about",IDC_ICON_ALIGN_10,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,131,46,44
-    CONTROL         "",IDC_ICON_ALIGN_11,"Button",BS_OWNERDRAW | BS_BOTTOM | 
-                    WS_TABSTOP,159,131,46,44
-    CONTROL         "Anzeige der &Versionsnummer",ID_DESKTOP_VERSION,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,187,107,10
-END
-
-IDD_DESKBAR_STARTMENU DIALOG DISCARDABLE  0, 0, 210, 204
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Startmenü-Einstellungen"
-FONT 8, "MS Sans Serif"
-BEGIN
-END
-
-IDD_DESKBAR_TASKBAR DIALOG DISCARDABLE  0, 0, 210, 204
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Taskbar-Einstellungen"
-FONT 8, "MS Sans Serif"
-BEGIN
-    CONTROL         "Anzeigen der &Uhr",ID_SHOW_CLOCK,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,152,71,10
-    CONTROL         "&verstecke inaktive Notification-Icons",
-                    ID_HIDE_INACTIVE_ICONS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,174,131,10
-    PUSHBUTTON      "&Notifications...",ID_CONFIG_NOTIFYAREA,153,173,50,14
-END
-
-IDD_MDI_SDI DIALOGEX 0, 0, 194, 157
-STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Auswahl des Explorerfenster-Modus"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "Please select your prefered explorer user interface:",
-                    IDC_STATIC,7,7,160,8
-    CONTROL         "&MDI (Multiple Document Interface)",IDC_MDI,"Button",
-                    BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,7,31,124,10
-    CONTROL         "&SDI (Single Document Interface)",IDC_SDI,"Button",
-                    BS_AUTORADIOBUTTON,7,62,118,10
-    CONTROL         170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13
-    CONTROL         171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13
-    CONTROL         "Öffne Unterverzeichnisses in &neuen Fenstern",
-                    IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,90,157,10
-    LTEXT           "Diese Auswahl wird künftig für alle Explorer-Fenster verwendet werden.",
-                    IDC_STATIC,7,111,174,22
-    DEFPUSHBUTTON   "&OK",IDOK,29,136,50,14,WS_GROUP
-    PUSHBUTTON      "A&bbrechen",IDCANCEL,106,136,50,14
-END
-
-IDD_NOTIFYAREA DIALOGEX 0, 0, 208, 174
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Konfiguration der Benachrichtigungs-Icons"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    CONTROL         "Tree1",IDC_NOTIFY_ICONS,"SysTreeView32",TVS_HASLINES | 
-                    TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,194,31
-    LTEXT           "&Tooltip-Text:",IDC_LABEL1,7,44,40,8
-    EDITTEXT        IDC_NOTIFY_TOOLTIP,58,42,143,14,ES_AUTOHSCROLL
-    LTEXT           "&Fenster-Titel:",IDC_LABEL2,7,63,42,8
-    EDITTEXT        IDC_NOTIFY_TITLE,58,60,143,14,ES_AUTOHSCROLL
-    LTEXT           "&Modulpfad:",IDC_LABEL3,7,81,36,8
-    EDITTEXT        IDC_NOTIFY_MODULE,58,78,143,14,ES_AUTOHSCROLL
-    GROUPBOX        "&Anzeigemodus",IDC_LABEL4,7,96,157,28
-    CONTROL         "&zeigen",IDC_NOTIFY_SHOW,"Button",BS_AUTORADIOBUTTON | 
-                    WS_TABSTOP,15,108,37,10
-    CONTROL         "&verstecken",IDC_NOTIFY_HIDE,"Button",
-                    BS_AUTORADIOBUTTON,55,108,51,10
-    CONTROL         "a&utomatisch",IDC_NOTIFY_AUTOHIDE,"Button",
-                    BS_AUTORADIOBUTTON,110,108,54,10
-    ICON            "",IDC_PICTURE,173,101,20,20
-    LTEXT           "&Letzte Änderung:",IDC_LABEL6,7,132,55,8
-    EDITTEXT        IDC_LAST_CHANGE,66,129,98,14,ES_AUTOHSCROLL | 
-                    ES_READONLY
-    CONTROL         "zei&ge versteckte",ID_SHOW_HIDDEN_ICONS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,154,68,10
-    DEFPUSHBUTTON   "&OK",IDOK,91,153,50,14,WS_GROUP
-    PUSHBUTTON      "A&bbrechen",IDCANCEL,151,153,50,14
-END
-
-IDD_SEARCH_PROGRAM DIALOGEX 0, 0, 200, 65
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Programmsuche im Startmenü"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "&Filter:",IDC_STATIC,7,9,18,8
-    EDITTEXT        IDC_FILTER,34,7,96,14,ES_AUTOHSCROLL
-    CONTROL         "List1",IDC_PROGRAMS_FOUND,"SysListView32",LVS_REPORT | 
-                    LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | 
-                    WS_TABSTOP,7,25,186,33
-    PUSHBUTTON      "Alle über&prüfen",IDC_CHECK_ENTRIES,138,7,55,14
-END
-
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#include ""resource.h""\r\n"
-    "#define APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "#include ""windows.h""\r\n"
-    "#undef APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "Reactos Explorer"
-    IDS_START               "Start"
-    IDS_LOGOFF              "Abmelden..."
-    IDS_SHUTDOWN            "Herunterfahren..."
-    IDS_LAUNCH              "Starten..."
-    IDS_START_HELP          "Hilfe"
-    IDS_SEARCH_FILES        "Suche Dateien..."
-    IDS_DOCUMENTS           "Dokumente"
-    IDS_FAVORITES           "Bookmarks"
-    IDS_PROGRAMS            "Programme"
-    IDS_SETTINGS            "Einstellungen"
-    IDS_EXPLORE             "Explore"
-    IDS_EMPTY               "(Empty)"
-    IDS_RECENT              "Aktuelle Dokumente"
-    IDS_ADMIN               "Verwaltung"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_STARTMENU           "Startmenü"
-    IDS_MINIMIZE_ALL        "alle Fenster minimieren"
-    IDS_DESKTOP_NUM         "Desktop %d"
-    IDS_VOLUME              "Lautstärke"
-    IDS_ITEMS_CUR           "aktuelle Icons"
-    IDS_ITEMS_CONFIGURED    "Konfiguratrion"
-    IDS_ITEMS_VISIBLE       "sichtbar"
-    IDS_ITEMS_HIDDEN        "unsichtbar"
-    IDS_NOTIFY_SHOW         "sichtbar"
-    IDS_NOTIFY_HIDE         "versteckt"
-    IDS_NOTIFY_AUTOHIDE     "automatisch"
-    IDS_SHOW_HIDDEN_ICONS   "Zeige versteckte Icons"
-    IDS_HIDE_ICONS          "Verstecke Icons"
-    IDS_TERMINATE           "ROS Explorer beenden"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_NETWORK             "Netzwerk"
-    IDS_CONNECTIONS         "Netzwerk-Verbindungen"
-    IDS_DRIVES              "Verzeichnisse"
-    IDS_SEARCH_COMPUTER     "Suche Computer..."
-    IDS_SETTINGS_MENU       "Einstellungen-Menu"
-    IDS_CONTROL_PANEL       "Systemsteuerung"
-    IDS_PRINTERS            "Drucker"
-    IDS_BROWSE              "Dateien"
-    IDS_SEARCH_PRG          "Suche Programm..."
-    IDS_ALL_USERS           "Alle Benutzer\\"
-    IDS_SEARCH              "Suche"
-    IDS_ABOUT_EXPLORER      "&Über Explorer..."
-    IDS_LAUNCH_MANY_PROGRAMS 
-                            "Sie haben mehrere Programme ausgewählt.\nSind Sie sicher, daß sie diese alle starten wollen?"
-    IDS_DESKTOPBAR_SETTINGS "Desktop-Einstellungen"
-    IDS_DESKTOP             "Desktop"
-    IDS_TASKBAR             "Taskbar"
-END
-
-#endif    // German (Germany) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/explorer-en.rc b/reactos/subsys/system/explorer/explorer-en.rc
deleted file mode 100644 (file)
index 1324948..0000000
+++ /dev/null
@@ -1,399 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include <windows.h>
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// English (U.S.) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
-#ifdef _WIN32
-LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
-#pragma code_page(1252)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_MDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&File"
-    BEGIN
-        MENUITEM "&Execute...",                 ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "E&xit",                       ID_FILE_EXIT
-    END
-    POPUP "&View"
-    BEGIN
-        MENUITEM "&Toolbar",                    ID_VIEW_TOOL_BAR
-        MENUITEM "&Extra Bar",                  ID_VIEW_EXTRA_BAR
-        MENUITEM "&Drivebar",                   ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "S&ide Bar",                   ID_VIEW_SIDE_BAR
-        MENUITEM "&Status Bar",                 ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Refresh\tF5",                ID_REFRESH
-        MENUITEM "F&ull Screen\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-        MENUITEM "SDI",                         ID_VIEW_SDI
-    END
-    POPUP "&Window"
-    BEGIN
-        MENUITEM "New &Window",                 ID_WINDOW_NEW
-        MENUITEM "Cascading\tShift+F5",         ID_WINDOW_CASCADE
-        MENUITEM "Tile &Horizontally",          ID_WINDOW_TILE_HORZ
-        MENUITEM "Tile &Vertically\tShift+F4",  ID_WINDOW_TILE_VERT
-        MENUITEM "Arrange Automatically",       ID_WINDOW_AUTOSORT
-        MENUITEM "Arrange &Symbols",            ID_WINDOW_ARRANGE
-    END
-    POPUP "&Tools"
-    BEGIN
-        MENUITEM "&Options",                    ID_TOOLS_OPTIONS
-    END
-    POPUP "&Help"
-    BEGIN
-        MENUITEM "Explorer &FAQ...",            ID_EXPLORER_FAQ
-        MENUITEM "&About Explorer...",          ID_ABOUT_EXPLORER
-        MENUITEM "About &OS...",                ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_DESKTOPBAR MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Settings...",                ID_DESKTOPBAR_SETTINGS
-        MENUITEM "&Task Manager...",            ID_TASKMGR
-        MENUITEM SEPARATOR
-        MENUITEM "&About Explorer...",          ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_VOLUME MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "Open Volume Control",         ID_TRAY_VOLUME
-        MENUITEM "Adjust Audio Properties",     ID_VOLUME_PROPERTIES
-    END
-END
-
-IDM_NOTIFYAREA MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Show hidden icons",          ID_SHOW_HIDDEN_ICONS
-        MENUITEM "Show Icon &Button",           ID_SHOW_ICON_BUTTON
-        MENUITEM "&Configure Notifications...", ID_CONFIG_NOTIFYAREA
-        MENUITEM "Adjust Date/&Time...",        ID_CONFIG_TIME
-        MENUITEM SEPARATOR
-        MENUITEM "&About Explorer...",          ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_SDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&File"
-    BEGIN
-        MENUITEM "&Execute...",                 ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Close",                      ID_FILE_EXIT
-    END
-    POPUP "&View"
-    BEGIN
-        MENUITEM "&Toolbar",                    ID_VIEW_TOOL_BAR
-        MENUITEM "S&ide Bar",                   ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "&Status Bar",                 ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Refresh\tF5",                ID_REFRESH
-        MENUITEM "F&ull Screen\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-        MENUITEM "&MDI",                        ID_VIEW_MDI
-    END
-    POPUP "&Tools"
-    BEGIN
-        MENUITEM "&Options",                    ID_TOOLS_OPTIONS
-    END
-    POPUP "&Help"
-    BEGIN
-        MENUITEM "Explorer &FAQ...",            ID_EXPLORER_FAQ
-        MENUITEM "&About Explorer...",          ID_ABOUT_EXPLORER
-        MENUITEM "About &OS...",                ID_ABOUT_WINDOWS
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_EXECUTE DIALOG DISCARDABLE  15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Execute"
-FONT 8, "MS Shell Dlg"
-BEGIN
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,150,10
-    CONTROL         "&Command:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,
-                    18,60,10
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL
-    CONTROL         "As &Symbol",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,3,
-                    45,71,12
-    DEFPUSHBUTTON   "&OK",1,158,6,47,14
-    PUSHBUTTON      "&Cancel",2,158,23,47,14
-    PUSHBUTTON      "&Help",254,158,43,47,14
-END
-
-IDD_SEARCH_PROGRAM DIALOGEX 0, 0, 200, 65
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Search Program in Startmenu"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "&Filter:",IDC_STATIC,7,9,18,8
-    EDITTEXT        IDC_FILTER,34,7,100,14,ES_AUTOHSCROLL
-    CONTROL         "List1",IDC_PROGRAMS_FOUND,"SysListView32",LVS_REPORT | 
-                    LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | 
-                    WS_TABSTOP,7,25,186,33
-    PUSHBUTTON      "&Check Entries",IDC_CHECK_ENTRIES,143,7,50,14
-END
-
-IDD_DESKBAR_DESKTOP DIALOG DISCARDABLE  0, 0, 212, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Desktop Properties"
-FONT 8, "MS Sans Serif"
-BEGIN
-    LTEXT           "Please select your prefered icon alignment algorithm:",
-                    IDC_STATIC,7,7,166,8
-    CONTROL         "left/top dwn",IDC_ICON_ALIGN_0,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,25,46,44
-    CONTROL         "left/top right",IDC_ICON_ALIGN_1,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,25,46,44
-    CONTROL         "right/top left",IDC_ICON_ALIGN_2,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,25,46,44
-    CONTROL         "rig./top dwn",IDC_ICON_ALIGN_3,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,25,46,44
-    CONTROL         "left/bot. up",IDC_ICON_ALIGN_4,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,73,46,44
-    CONTROL         "left/bot. right",IDC_ICON_ALIGN_5,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,73,46,44
-    CONTROL         "right/bot. left",IDC_ICON_ALIGN_6,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,73,46,44
-    CONTROL         "rig./bot. dwn",IDC_ICON_ALIGN_7,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,73,46,44
-    CONTROL         "border down",IDC_ICON_ALIGN_8,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,121,46,44
-    CONTROL         "border H/V",IDC_ICON_ALIGN_9,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,121,46,44
-    CONTROL         "round about",IDC_ICON_ALIGN_10,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,121,46,44
-    CONTROL         "",IDC_ICON_ALIGN_11,"Button",BS_OWNERDRAW | BS_BOTTOM | 
-                    WS_TABSTOP,159,121,46,44
-    CONTROL         "Display &Version Number",ID_DESKTOP_VERSION,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,177,91,10
-END
-
-IDD_DESKBAR_TASKBAR DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Taskbar Properties"
-FONT 8, "MS Sans Serif"
-BEGIN
-    CONTROL         "show &clock",ID_SHOW_CLOCK,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,152,52,10
-    CONTROL         "&hide inactive notification icons",
-                    ID_HIDE_INACTIVE_ICONS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,174,111,10
-    PUSHBUTTON      "&Notifications...",ID_CONFIG_NOTIFYAREA,153,173,50,14
-END
-
-IDD_DESKBAR_STARTMENU DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Startmenu Properties"
-FONT 8, "MS Sans Serif"
-BEGIN
-END
-
-IDD_NOTIFYAREA DIALOGEX 0, 0, 208, 174
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Configure Notification Icons"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    CONTROL         "Tree1",IDC_NOTIFY_ICONS,"SysTreeView32",TVS_HASLINES | 
-                    TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,194,31
-    LTEXT           "&Tooltip Text:",IDC_LABEL1,7,44,40,8
-    EDITTEXT        IDC_NOTIFY_TOOLTIP,58,42,143,14,ES_AUTOHSCROLL
-    LTEXT           "W&indow Title:",IDC_LABEL2,7,63,44,8
-    EDITTEXT        IDC_NOTIFY_TITLE,58,60,143,14,ES_AUTOHSCROLL
-    LTEXT           "&Module Path:",IDC_LABEL3,7,81,43,8
-    EDITTEXT        IDC_NOTIFY_MODULE,58,78,143,14,ES_AUTOHSCROLL
-    GROUPBOX        "&Display Mode",IDC_LABEL4,7,96,157,28
-    CONTROL         "&show",IDC_NOTIFY_SHOW,"Button",BS_AUTORADIOBUTTON | 
-                    WS_TABSTOP,15,108,33,10
-    CONTROL         "&hide",IDC_NOTIFY_HIDE,"Button",BS_AUTORADIOBUTTON,66,
-                    108,29,10
-    CONTROL         "a&utohide",IDC_NOTIFY_AUTOHIDE,"Button",
-                    BS_AUTORADIOBUTTON,112,108,43,10
-    ICON            "",IDC_PICTURE,173,101,21,20
-    LTEXT           "&Last Change:",IDC_LABEL6,7,132,43,8
-    EDITTEXT        IDC_LAST_CHANGE,59,129,105,14,ES_AUTOHSCROLL | 
-                    ES_READONLY
-    CONTROL         "sho&w hidden",ID_SHOW_HIDDEN_ICONS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,154,56,10
-    DEFPUSHBUTTON   "&OK",IDOK,91,153,50,14,WS_GROUP
-    PUSHBUTTON      "&Cancel",IDCANCEL,151,153,50,14
-END
-
-IDD_MDI_SDI DIALOGEX 0, 0, 194, 157
-STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Choose Explorer window mode"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "Please select your prefered explorer user interface:",
-                    IDC_STATIC,7,7,160,8
-    CONTROL         "&MDI (Multiple Document Interface)",IDC_MDI,"Button",
-                    BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,7,31,124,10
-    CONTROL         "&SDI (Single Document Interface)",IDC_SDI,"Button",
-                    BS_AUTORADIOBUTTON,7,62,118,10
-    CONTROL         170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13
-    CONTROL         171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13
-    CONTROL         "Open Subfolders in s&eparate windows",
-                    IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,90,135,10
-    LTEXT           "This setting will be used as default for all explorer windows in the future.",
-                    IDC_STATIC,7,111,174,22
-    DEFPUSHBUTTON   "&OK",IDOK,29,136,50,14,WS_GROUP
-    PUSHBUTTON      "&Cancel",IDCANCEL,106,136,50,14
-END
-
-IDD_ABOUT_EXPLORER DIALOG DISCARDABLE  0, 0, 199, 106
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "About ReactOS Explorer"
-FONT 10, "MS Sans Serif"
-BEGIN
-    LTEXT           "ReactOS Explorer",IDC_ROS_EXPLORER,91,13,104,11
-    LTEXT           "V 0.9",IDC_VERSION_TXT,91,27,104,8
-    LTEXT           "(c) 2003-2005 Martin Fuchs",IDC_STATIC,91,42,104,8
-    LTEXT           "",IDC_WIN_VERSION,91,58,98,22
-    LTEXT           "http://www.sky.franken.de/explorer/",IDC_WWW,17,84,129,
-                    8
-    CONTROL         "&OK",IDOK,"Button",BS_OWNERDRAW | BS_FLAT | WS_GROUP,
-                    154,90,38,12
-END
-
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "#include <windows.h>\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "Reactos Explorer"
-    IDS_START               "Start"
-    IDS_LOGOFF              "Log Off..."
-    IDS_SHUTDOWN            "Turn Off..."
-    IDS_LAUNCH              "Run..."
-    IDS_START_HELP          "Help"
-    IDS_SEARCH_FILES        "Search..."
-    IDS_DOCUMENTS           "My Documents"
-    IDS_FAVORITES           "Favorites"
-    IDS_PROGRAMS            "Programs"
-    IDS_SETTINGS            "Settings"
-    IDS_EXPLORE             "Explore"
-    IDS_EMPTY               "(Empty)"
-    IDS_RECENT              "Recent Documents"
-    IDS_ADMIN               "Administration"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_STARTMENU           "Startmenu"
-    IDS_MINIMIZE_ALL        "minimize all windows"
-    IDS_DESKTOP_NUM         "Desktop %d"
-    IDS_VOLUME              "Volume"
-    IDS_ITEMS_CUR           "current items"
-    IDS_ITEMS_CONFIGURED    "configuration"
-    IDS_ITEMS_VISIBLE       "visible"
-    IDS_ITEMS_HIDDEN        "hidden"
-    IDS_NOTIFY_SHOW         "show"
-    IDS_NOTIFY_HIDE         "hide"
-    IDS_NOTIFY_AUTOHIDE     "autohide"
-    IDS_SHOW_HIDDEN_ICONS   "Show hidden icons"
-    IDS_HIDE_ICONS          "Hide icons"
-    IDS_TERMINATE           "Terminate ROS Explorer"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_NETWORK             "Network"
-    IDS_CONNECTIONS         "Network Connections"
-    IDS_DRIVES              "Drives"
-    IDS_SEARCH_COMPUTER     "Search Computer..."
-    IDS_SETTINGS_MENU       "Settings Menu"
-    IDS_CONTROL_PANEL       "Control Panel"
-    IDS_PRINTERS            "Printers"
-    IDS_BROWSE              "Browse Files"
-    IDS_SEARCH_PRG          "Search Program..."
-    IDS_ALL_USERS           "All Users\\"
-    IDS_SEARCH              "Search"
-    IDS_ABOUT_EXPLORER      "&About Explorer..."
-    IDS_LAUNCH_MANY_PROGRAMS 
-                            "You have selected more than one program.\nAre you sure you want to launch all of them?"
-    IDS_DESKTOPBAR_SETTINGS "Desktop Settings"
-    IDS_DESKTOP             "Desktop"
-    IDS_TASKBAR             "Taskbar"
-END
-
-#endif    // English (U.S.) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/explorer-es.rc b/reactos/subsys/system/explorer/explorer-es.rc
deleted file mode 100644 (file)
index 07220b9..0000000
+++ /dev/null
@@ -1,384 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include <windows.h>
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// Spanish (Castilian) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ESP)
-#ifdef _WIN32
-LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL
-#pragma code_page(1252)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_MDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Archivo"
-    BEGIN
-        MENUITEM "E&jecutar...",                ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Salir",                      ID_FILE_EXIT
-    END
-    POPUP "&Ver"
-    BEGIN
-        MENUITEM "&Herramientas",               ID_VIEW_TOOL_BAR
-        MENUITEM "Barra &Extra",                ID_VIEW_EXTRA_BAR
-        MENUITEM "Barra de &Unidades",          ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "Barra &Lateral",              ID_VIEW_SIDE_BAR
-        MENUITEM "Barra de &Estado",            ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Actualizar\tF5",             ID_REFRESH
-        MENUITEM "P&antalla Completa\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-        MENUITEM "&SDI",                        ID_VIEW_SDI
-    END
-    POPUP "&Ventana"
-    BEGIN
-        MENUITEM "Nueva &Ventana",              ID_WINDOW_NEW
-        MENUITEM "Cascada\tShift+F5",           ID_WINDOW_CASCADE
-        MENUITEM "Mosaico &Horizontal",         ID_WINDOW_TILE_HORZ
-        MENUITEM "Mosaico &Vertical\tShift+F4", ID_WINDOW_TILE_VERT
-        MENUITEM "Agrupar Automaticamente",     ID_WINDOW_AUTOSORT
-        MENUITEM "Agrupar &Símbolos",           ID_WINDOW_ARRANGE
-    END
-    POPUP "&Tools"
-    BEGIN
-        MENUITEM "&Options",                    ID_TOOLS_OPTIONS
-    END
-    POPUP "A&yuda"
-    BEGIN
-        MENUITEM "Explorer &FAQ...",            ID_EXPLORER_FAQ
-        MENUITEM "&Acerca de Explorer...",      ID_ABOUT_EXPLORER
-        MENUITEM "Acerca de &OS...",            ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_DESKTOPBAR MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Configuracion...",           ID_DESKTOPBAR_SETTINGS
-        MENUITEM "&Administrador de Tareas...", ID_TASKMGR
-        MENUITEM SEPARATOR
-        MENUITEM "&Acerca de Explorer...",      ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_VOLUME MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "Abrir Control de Volumen",    ID_TRAY_VOLUME
-        MENUITEM "Ajustar Propiedades de Audio", ID_VOLUME_PROPERTIES
-    END
-END
-
-IDM_NOTIFYAREA MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Mostrar iconos ocultos",     ID_SHOW_HIDDEN_ICONS
-        MENUITEM "Mostrar &Botón de Icono",     ID_SHOW_ICON_BUTTON
-        MENUITEM "&Configurar Notificaciones...", ID_CONFIG_NOTIFYAREA
-        MENUITEM "Ajustar Fecha/&Hora...",      ID_CONFIG_TIME
-        MENUITEM SEPARATOR
-        MENUITEM "&Acerca de Explorer...",      ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_SDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Archivo"
-    BEGIN
-        MENUITEM "E&jecutar...",                ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "S&alir",                      ID_FILE_EXIT
-    END
-    POPUP "&Ver"
-    BEGIN
-        MENUITEM "&Barra de Herramientas",      ID_VIEW_TOOL_BAR
-        MENUITEM "Barra &Lateral",              ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "Barra de &Estado",            ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Actualizar\tF5",             ID_REFRESH
-        MENUITEM "P&antalla Completa\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-        MENUITEM "&MDI",                        ID_VIEW_MDI
-    END
-    POPUP "Herramientas"
-    BEGIN
-        MENUITEM "&Opciones",                   ID_TOOLS_OPTIONS
-    END
-    POPUP "&Ayuda"
-    BEGIN
-        MENUITEM "Explorer &FAQ...",            ID_EXPLORER_FAQ
-        MENUITEM "&Acerca de Explorer...",      ID_ABOUT_EXPLORER
-        MENUITEM "Acerca de &OS...",            ID_ABOUT_WINDOWS
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_EXECUTE DIALOG DISCARDABLE  15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Ejecutar"
-FONT 8, "MS Shell Dlg"
-BEGIN
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,150,10
-    CONTROL         "Orden:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,18,
-                    60,10
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL
-    CONTROL         "Como &Símbolo",214,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,3,45,71,12
-    DEFPUSHBUTTON   "&Aceptar",1,158,6,47,14
-    PUSHBUTTON      "&Cancelar",2,158,23,47,14
-    PUSHBUTTON      "&Ayuda",254,158,43,47,14
-END
-
-IDD_SEARCH_PROGRAM DIALOGEX 0, 0, 200, 65
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Buscar Programa en el menu Inicio"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "&Filtro:",IDC_STATIC,7,9,23,8
-    EDITTEXT        IDC_FILTER,34,7,100,14,ES_AUTOHSCROLL
-    CONTROL         "List1",IDC_PROGRAMS_FOUND,"SysListView32",LVS_REPORT | 
-                    LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | 
-                    WS_TABSTOP,7,25,186,33
-    PUSHBUTTON      "&Marcar Entradas",IDC_CHECK_ENTRIES,136,7,57,14
-END
-
-IDD_DESKBAR_DESKTOP DIALOG DISCARDABLE  0, 0, 212, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Propiedades de Pantalla"
-FONT 8, "MS Sans Serif"
-BEGIN
-    LTEXT           "Por favor seleccione su algoritmo de alineamiento preferido:",
-                    IDC_STATIC,7,7,195,8
-    CONTROL         "izquierda/arriba abajo",IDC_ICON_ALIGN_0,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,7,25,46,44
-    CONTROL         "izquierda/arriba derecha",IDC_ICON_ALIGN_1,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,57,25,46,44
-    CONTROL         "derecha/arriba izquierda",IDC_ICON_ALIGN_2,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,110,25,46,44
-    CONTROL         "derecha/arriba abajo",IDC_ICON_ALIGN_3,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,159,25,46,44
-    CONTROL         "derecha/abajo arriba",IDC_ICON_ALIGN_4,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,7,73,46,44
-    CONTROL         "izquierda/abajo derecha",IDC_ICON_ALIGN_5,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,57,73,46,44
-    CONTROL         "derecha/abajo izquierda",IDC_ICON_ALIGN_6,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,110,73,46,44
-    CONTROL         "derecha/abajo",IDC_ICON_ALIGN_7,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,73,46,44
-    CONTROL         "borde inferior",IDC_ICON_ALIGN_8,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,121,46,44
-    CONTROL         "borde H/V",IDC_ICON_ALIGN_9,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,121,46,44
-    CONTROL         "aproximado",IDC_ICON_ALIGN_10,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,121,46,44
-    CONTROL         "",IDC_ICON_ALIGN_11,"Button",BS_OWNERDRAW | BS_BOTTOM | 
-                    WS_TABSTOP,159,121,46,44
-    CONTROL         "Mostrar &Version",ID_DESKTOP_VERSION,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,177,91,10
-END
-
-IDD_DESKBAR_TASKBAR DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Propiedades de la Barra de Tareas"
-FONT 8, "MS Sans Serif"
-BEGIN
-    CONTROL         "Mostrar &Reloj",ID_SHOW_CLOCK,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,152,56,10
-    CONTROL         "&Ocultar iconos de notificacion inactivos",
-                    ID_HIDE_INACTIVE_ICONS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,174,136,10
-    PUSHBUTTON      "&Notificaciones...",ID_CONFIG_NOTIFYAREA,145,173,64,14
-END
-
-IDD_DESKBAR_STARTMENU DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Propiedades del Menú Inicio"
-FONT 8, "MS Sans Serif"
-BEGIN
-END
-
-IDD_NOTIFYAREA DIALOGEX 0, 0, 208, 174
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Configurar Iconos de Notificaciones"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    CONTROL         "Tree1",IDC_NOTIFY_ICONS,"SysTreeView32",TVS_HASLINES | 
-                    TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,194,31
-    LTEXT           "&Texto de Info:",IDC_LABEL1,8,44,51,8
-    EDITTEXT        IDC_NOTIFY_TOOLTIP,82,42,117,14,ES_AUTOHSCROLL
-    LTEXT           "Título de la V&entana:",IDC_LABEL2,8,63,70,8
-    EDITTEXT        IDC_NOTIFY_TITLE,82,60,117,14,ES_AUTOHSCROLL
-    LTEXT           "&Parche del Módulo:",IDC_LABEL3,8,81,65,8
-    EDITTEXT        IDC_NOTIFY_MODULE,82,78,117,14,ES_AUTOHSCROLL
-    GROUPBOX        "Modo de &Display",IDC_LABEL4,7,96,157,28
-    CONTROL         "&Mostrar",IDC_NOTIFY_SHOW,"Button",BS_AUTORADIOBUTTON | 
-                    WS_TABSTOP,15,108,38,10
-    CONTROL         "&Ocultar",IDC_NOTIFY_HIDE,"Button",BS_AUTORADIOBUTTON,
-                    66,108,36,10
-    CONTROL         "A&utoocultar",IDC_NOTIFY_AUTOHIDE,"Button",
-                    BS_AUTORADIOBUTTON,112,108,50,10
-    ICON            "",IDC_PICTURE,173,101,21,20
-    LTEXT           "Último cambio:",IDC_LABEL6,7,132,50,8
-    EDITTEXT        IDC_LAST_CHANGE,59,129,105,14,ES_AUTOHSCROLL | 
-                    ES_READONLY
-    CONTROL         "Mostrar Ocu&ltos",ID_SHOW_HIDDEN_ICONS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,154,64,10
-    DEFPUSHBUTTON   "&Aceptar",IDOK,91,153,50,14,WS_GROUP
-    PUSHBUTTON      "&Cancelar",IDCANCEL,151,153,50,14
-END
-
-IDD_MDI_SDI DIALOGEX 0, 0, 194, 157
-STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Elegir modo MDI / SDI"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "Por favor, seleccione su interfaz de usuario preferida para el explorador:",
-                    IDC_STATIC,7,7,170,18
-    CONTROL         "&MDI (Multiple Document Interface)",IDC_MDI,"Button",
-                    BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,7,31,123,10
-    CONTROL         "&SDI (Single Document Interface)",IDC_SDI,"Button",
-                    BS_AUTORADIOBUTTON,7,62,116,10
-    CONTROL         170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13
-    CONTROL         171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13
-    CONTROL         "Open Subfolders in s&eparate windows",
-                    IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,90,135,10
-    LTEXT           "Esta configuración se usará por defecto y apartir de ahora para todas las ventanas del explorador.",
-                    IDC_STATIC,7,111,174,22
-    DEFPUSHBUTTON   "&Aceptar",IDOK,29,136,50,14,WS_GROUP
-    PUSHBUTTON      "&Cancelar",IDCANCEL,106,136,50,14
-END
-
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "#include <windows.h>\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "ReactOS Explorer"
-    IDS_START               "Iniciar"
-    IDS_LOGOFF              "Salir..."
-    IDS_SHUTDOWN            "Apagar..."
-    IDS_LAUNCH              "Ejecutar..."
-    IDS_START_HELP          "Ayuda"
-    IDS_SEARCH_FILES        "Buscar..."
-    IDS_DOCUMENTS           "Documentos"
-    IDS_FAVORITES           "Favoritos"
-    IDS_PROGRAMS            "Programas"
-    IDS_SETTINGS            "Configuración"
-    IDS_EXPLORE             "Explorar"
-    IDS_EMPTY               "(Vacío)"
-    IDS_RECENT              "Documentos Recientes"
-    IDS_ADMIN               "Administracion"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_STARTMENU           "Menú Inicio"
-    IDS_MINIMIZE_ALL        "mimimizar todas las ventanas"
-    IDS_DESKTOP_NUM         "Escritorio %d"
-    IDS_VOLUME              "Volumen"
-    IDS_ITEMS_CUR           "Objetos Actuales"
-    IDS_ITEMS_CONFIGURED    "configuración"
-    IDS_ITEMS_VISIBLE       "visible"
-    IDS_ITEMS_HIDDEN        "oculto"
-    IDS_NOTIFY_SHOW         "mostrar"
-    IDS_NOTIFY_HIDE         "ocultar"
-    IDS_NOTIFY_AUTOHIDE     "autoocultar"
-    IDS_SHOW_HIDDEN_ICONS   "Mostrar iconos ocultos"
-    IDS_HIDE_ICONS          "Ocultar iconos"
-    IDS_TERMINATE           "Finalizar ROS Explorer"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_NETWORK             "Red"
-    IDS_CONNECTIONS         "Conexiones de Red"
-    IDS_DRIVES              "Unidades"
-    IDS_SEARCH_COMPUTER     "Buscar PC..."
-    IDS_SETTINGS_MENU       "Menús de Configuración"
-    IDS_CONTROL_PANEL       "Panel de Control"
-    IDS_PRINTERS            "Impresoras"
-    IDS_BROWSE              "Explorar Archivos"
-    IDS_SEARCH_PRG          "Buscar Programas..."
-    IDS_ALL_USERS           "Todos los Usuarios\\"
-    IDS_SEARCH              "Buscar"
-    IDS_ABOUT_EXPLORER      "&Acerca de Explorer..."
-    IDS_LAUNCH_MANY_PROGRAMS 
-                            "Ha seleccionado más de un programa.\n¿Está seguro de que desea ejecutarlos todos?"
-    IDS_DESKTOPBAR_SETTINGS "Configuracion del Escritorio"
-    IDS_DESKTOP             "Escritorio"
-    IDS_TASKBAR             "Barra de Tareas"
-END
-
-#endif    // Spanish (Castilian) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/explorer-fr.rc b/reactos/subsys/system/explorer/explorer-fr.rc
deleted file mode 100644 (file)
index 4ef5f3e..0000000
+++ /dev/null
@@ -1,416 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include "resource.h"
-#define APSTUDIO_HIDDEN_SYMBOLS
-#include "windows.h"
-#undef APSTUDIO_HIDDEN_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// German (Germany) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)
-#ifdef _WIN32
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-#pragma code_page(1252)
-#endif //_WIN32
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#include ""resource.h""\r\n"
-    "#define APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "#include ""windows.h""\r\n"
-    "#undef APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-#endif    // German (Germany) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-/////////////////////////////////////////////////////////////////////////////
-// French (France) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_FRA)
-#ifdef _WIN32
-LANGUAGE LANG_FRENCH, SUBLANG_FRENCH
-#pragma code_page(1252)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_MDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Fichier"
-    BEGIN
-        MENUITEM "E&xécuter...",                ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Fermer",                     ID_FILE_EXIT
-    END
-    POPUP "&Affichage"
-    BEGIN
-        MENUITEM "Barre d'&outils",             ID_VIEW_TOOL_BAR
-        MENUITEM "&Extra Bar",                  ID_VIEW_EXTRA_BAR
-        MENUITEM "&Barre des lecteurs",         ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "S&ide Bar",                   ID_VIEW_SIDE_BAR
-        MENUITEM "Barre d'&état",               ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "A&ctualiser\tF5",             ID_REFRESH
-        MENUITEM "&Plein écran\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-        MENUITEM "SDI",                         ID_VIEW_SDI
-    END
-    POPUP "&Fenêtre"
-    BEGIN
-        MENUITEM "Nouvelle &fenêtre",           ID_WINDOW_NEW
-        MENUITEM "Cascade\tShift+F5",           ID_WINDOW_CASCADE
-        MENUITEM "Mosaïque &horizontale",       ID_WINDOW_TILE_HORZ
-        MENUITEM "Mosaïque &verticale\tCtrl+Shift+S", ID_WINDOW_TILE_VERT
-        MENUITEM "Organisation automatique",    ID_WINDOW_AUTOSORT
-        MENUITEM "&Organisation des symboles",  ID_WINDOW_ARRANGE
-    END
-    POPUP "&Outils"
-    BEGIN
-        MENUITEM "&Options",                    ID_TOOLS_OPTIONS
-    END
-    POPUP "&Aide"
-    BEGIN
-        MENUITEM "&FAQ de l'explorateur...",    ID_EXPLORER_FAQ
-        MENUITEM "&A propos de l'explorateur...", ID_ABOUT_EXPLORER
-        MENUITEM "A propos de l'&OS...",        ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_DESKTOPBAR MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Paramètres...",              ID_DESKTOPBAR_SETTINGS
-        MENUITEM "&Gestionnaire de tâches...",  ID_TASKMGR
-        MENUITEM SEPARATOR
-        MENUITEM "&A propos de l'explorateur...", ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_VOLUME MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "Ouvrir le contrôle du volume", ID_TRAY_VOLUME
-        MENUITEM "Ajuster les propriétés audio", ID_VOLUME_PROPERTIES
-    END
-END
-
-IDM_NOTIFYAREA MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Afficher les icônes cachés", ID_SHOW_HIDDEN_ICONS
-        MENUITEM "Afficher l'icône &Boutton",   ID_SHOW_ICON_BUTTON
-        MENUITEM "&Configurer les Notifications...", ID_CONFIG_NOTIFYAREA
-        MENUITEM "Ajuster Date/&Heure...",      ID_CONFIG_TIME
-        MENUITEM SEPARATOR
-        MENUITEM "&A propos de l'explorateur...", ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_SDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Fichier"
-    BEGIN
-        MENUITEM "&Exécuter...",                ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Fermer",                     ID_FILE_EXIT
-    END
-    POPUP "&Affichage"
-    BEGIN
-        MENUITEM "&Barre d'outils",             ID_VIEW_TOOL_BAR
-        MENUITEM "S&ide Bar",                   ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "&Barre d'état",               ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "A&ctualiser\tF5",             ID_REFRESH
-        MENUITEM "&Plein écran\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-        MENUITEM "&MDI",                        ID_VIEW_MDI
-    END
-    POPUP "&Outils"
-    BEGIN
-        MENUITEM "&Options",                    ID_TOOLS_OPTIONS
-    END
-    POPUP "&Aide"
-    BEGIN
-        MENUITEM "&FAQ de l'explorateur...",    ID_EXPLORER_FAQ
-        MENUITEM "&A propos de l'explorateur...", ID_ABOUT_EXPLORER
-        MENUITEM "A propos de l'&OS...",        ID_ABOUT_WINDOWS
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_EXECUTE DIALOG DISCARDABLE  15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Exécuter"
-FONT 8, "MS Shell Dlg"
-BEGIN
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,150,10
-    CONTROL         "&Commande:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,
-                    18,60,10
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL
-    CONTROL         "Comme &Symbole",214,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,3,45,71,12
-    DEFPUSHBUTTON   "&OK",1,158,6,47,14
-    PUSHBUTTON      "&Annuler",2,158,23,47,14
-    PUSHBUTTON      "&Aide",254,158,43,47,14
-END
-
-IDD_SEARCH_PROGRAM DIALOGEX 0, 0, 200, 65
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Rechercher un programme dans le menu démarrer"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "&Filtre:",IDC_STATIC,7,9,18,8
-    EDITTEXT        IDC_FILTER,34,7,100,14,ES_AUTOHSCROLL
-    CONTROL         "List1",IDC_PROGRAMS_FOUND,"SysListView32",LVS_REPORT | 
-                    LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | 
-                    WS_TABSTOP,7,25,186,33
-    PUSHBUTTON      "&Vérifier les entrées",IDC_CHECK_ENTRIES,143,7,50,14
-END
-
-IDD_DESKBAR_DESKTOP DIALOG DISCARDABLE  0, 0, 212, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Propriétés du bureau"
-FONT 8, "MS Sans Serif"
-BEGIN
-    LTEXT           "Please select your prefered icon alignment algorithm:",
-                    IDC_STATIC,7,7,166,8
-    CONTROL         "gauche/haut descend",IDC_ICON_ALIGN_0,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,7,25,46,44
-    CONTROL         "gauche/haut droite",IDC_ICON_ALIGN_1,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,57,25,46,44
-    CONTROL         "droite/haut left",IDC_ICON_ALIGN_2,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,110,25,46,44
-    CONTROL         "droite/haut descend",IDC_ICON_ALIGN_3,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,159,25,46,44
-    CONTROL         "gauche/fond monte",IDC_ICON_ALIGN_4,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,7,73,46,44
-    CONTROL         "gauche/fond right",IDC_ICON_ALIGN_5,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,57,73,46,44
-    CONTROL         "droite/fond gauche",IDC_ICON_ALIGN_6,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,110,73,46,44
-    CONTROL         "rdroite/fond. descend",IDC_ICON_ALIGN_7,"Button",
-                    BS_OWNERDRAW | BS_BOTTOM | WS_TABSTOP,159,73,46,44
-    CONTROL         "bord descend",IDC_ICON_ALIGN_8,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,121,46,44
-    CONTROL         "bord H/V",IDC_ICON_ALIGN_9,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,121,46,44
-    CONTROL         "faire le tour",IDC_ICON_ALIGN_10,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,121,46,44
-    CONTROL         "",IDC_ICON_ALIGN_11,"Button",BS_OWNERDRAW | BS_BOTTOM | 
-                    WS_TABSTOP,159,121,46,44
-    CONTROL         "Afficher le numéro de la &version",ID_DESKTOP_VERSION,
-                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,177,91,10
-END
-
-IDD_DESKBAR_TASKBAR DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Propriétés de la barre de tâches"
-FONT 8, "MS Sans Serif"
-BEGIN
-    CONTROL         "afficher l'&heure",ID_SHOW_CLOCK,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,152,52,10
-    CONTROL         "&masquer les icônes inactives",ID_HIDE_INACTIVE_ICONS,
-                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,174,111,10
-    PUSHBUTTON      "&Notifications...",ID_CONFIG_NOTIFYAREA,153,173,50,14
-END
-
-IDD_DESKBAR_STARTMENU DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Propriétés du menu démarrer"
-FONT 8, "MS Sans Serif"
-BEGIN
-END
-
-IDD_NOTIFYAREA DIALOGEX 0, 0, 208, 174
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Configurer Icônes de Notification"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    CONTROL         "Tree1",IDC_NOTIFY_ICONS,"SysTreeView32",TVS_HASLINES | 
-                    TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,194,31
-    LTEXT           "&Texte conseil:",IDC_LABEL1,7,44,40,8
-    EDITTEXT        IDC_NOTIFY_TOOLTIP,58,42,143,14,ES_AUTOHSCROLL
-    LTEXT           "Titre de la &fenêtre:",IDC_LABEL2,7,63,44,8
-    EDITTEXT        IDC_NOTIFY_TITLE,58,60,143,14,ES_AUTOHSCROLL
-    LTEXT           "&Repertoire du module:",IDC_LABEL3,7,81,43,8
-    EDITTEXT        IDC_NOTIFY_MODULE,58,78,143,14,ES_AUTOHSCROLL
-    GROUPBOX        "&Mode d'affichage",IDC_LABEL4,7,96,157,28
-    CONTROL         "&afficher",IDC_NOTIFY_SHOW,"Button",BS_AUTORADIOBUTTON | 
-                    WS_TABSTOP,15,108,33,10
-    CONTROL         "&cacher",IDC_NOTIFY_HIDE,"Button",BS_AUTORADIOBUTTON,66,
-                    108,29,10
-    CONTROL         "&cacher automatiquement",IDC_NOTIFY_AUTOHIDE,"Button",
-                    BS_AUTORADIOBUTTON,112,108,43,10
-    ICON            "",IDC_PICTURE,173,101,21,20
-    LTEXT           "&Dernier changement:",IDC_LABEL6,7,132,43,8
-    EDITTEXT        IDC_LAST_CHANGE,59,129,105,14,ES_AUTOHSCROLL | 
-                    ES_READONLY
-    CONTROL         "afficher les cac&hés",ID_SHOW_HIDDEN_ICONS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,154,56,10
-    DEFPUSHBUTTON   "&OK",IDOK,91,153,50,14,WS_GROUP
-    PUSHBUTTON      "&Annuler",IDCANCEL,151,153,50,14
-END
-
-IDD_MDI_SDI DIALOGEX 0, 0, 194, 157
-STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Veuillez choisir un mode de fenêtres pour explorateur"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "Veuillez sélectionner l'interface que vous préférez pour l'explorateur:",
-                    IDC_STATIC,7,7,160,8
-    CONTROL         "&MDI (Multiple Document Interface)",IDC_MDI,"Button",
-                    BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,7,31,124,10
-    CONTROL         "&SDI (Single Document Interface)",IDC_SDI,"Button",
-                    BS_AUTORADIOBUTTON,7,62,118,10
-    CONTROL         170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13
-    CONTROL         171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13
-    CONTROL         "Ouvrir les sous-dossiers dans des fenêtres s&éparrées",
-                    IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,90,135,10
-    LTEXT           "Ce paramètre sera utilisé par défaut.",IDC_STATIC,7,111,
-                    174,22
-    DEFPUSHBUTTON   "&OK",IDOK,29,136,50,14,WS_GROUP
-    PUSHBUTTON      "&Annuler",IDCANCEL,106,136,50,14
-END
-
-IDD_ABOUT_EXPLORER DIALOG DISCARDABLE  0, 0, 199, 106
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "A propos de ReactOS Explorer"
-FONT 10, "MS Sans Serif"
-BEGIN
-    LTEXT           "ReactOS Explorer",IDC_ROS_EXPLORER,91,13,104,11
-    LTEXT           "V 0.9",IDC_VERSION_TXT,91,27,104,8
-    LTEXT           "(c) 2003-2005 Martin Fuchs",IDC_STATIC,91,42,104,8
-    LTEXT           "",IDC_WIN_VERSION,91,58,98,22
-    LTEXT           "http://www.sky.franken.de/explorer/",IDC_WWW,17,84,129,
-                    8
-    CONTROL         "&OK",IDOK,"Button",BS_OWNERDRAW | BS_FLAT | WS_GROUP,
-                    154,90,38,12
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "Reactos Explorer"
-    IDS_START               "Démarrer"
-    IDS_LOGOFF              "Se déconnecter..."
-    IDS_SHUTDOWN            "Arrêter..."
-    IDS_LAUNCH              "Exécuter..."
-    IDS_START_HELP          "Aide"
-    IDS_SEARCH_FILES        "Rechercher..."
-    IDS_DOCUMENTS           "Documents"
-    IDS_FAVORITES           "Favoris"
-    IDS_PROGRAMS            "Programmes"
-    IDS_SETTINGS            "Paramètres"
-    IDS_EXPLORE             "Explorer"
-    IDS_EMPTY               "(Vide)"
-    IDS_RECENT              "Documents récents"
-    IDS_ADMIN               "Administration"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_STARTMENU           "Menu démarrer"
-    IDS_MINIMIZE_ALL        "mimimiser toutes les fenêtres"
-    IDS_DESKTOP_NUM         "Bureau %d"
-    IDS_VOLUME              "Volume"
-    IDS_ITEMS_CUR           "abjets actuels"
-    IDS_ITEMS_CONFIGURED    "configuration"
-    IDS_ITEMS_VISIBLE       "visible"
-    IDS_ITEMS_HIDDEN        "caché"
-    IDS_NOTIFY_SHOW         "afficher"
-    IDS_NOTIFY_HIDE         "cacher"
-    IDS_NOTIFY_AUTOHIDE     "cacher automatiquement"
-    IDS_SHOW_HIDDEN_ICONS   "Afficher les icones cachés"
-    IDS_HIDE_ICONS          "Cacher les icones"
-    IDS_TERMINATE           "Fermer ROS Explorer"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_NETWORK             "Réseaux"
-    IDS_CONNECTIONS         "Connections Réseaux"
-    IDS_DRIVES              "Drives"
-    IDS_SEARCH_COMPUTER     "Rechercher un ordinateur..."
-    IDS_SETTINGS_MENU       "Paramètres du menu"
-    IDS_CONTROL_PANEL       "Panneau de configuration"
-    IDS_PRINTERS            "Imprimantes"
-    IDS_BROWSE              "Parcourir"
-    IDS_SEARCH_PRG          "Rechercher un programme..."
-    IDS_ALL_USERS           "Tous les utilisateurs\\"
-    IDS_SEARCH              "Rechercher"
-    IDS_ABOUT_EXPLORER      "&A propos de l'explorateur..."
-    IDS_LAUNCH_MANY_PROGRAMS 
-                            "Vous avez selectionné plus d'un programme.\nEtes vous sur de vouloir tous les lancer?"
-    IDS_DESKTOPBAR_SETTINGS "Paramètres du bureau"
-    IDS_DESKTOP             "Bureau"
-    IDS_TASKBAR             "Barre de tâches"
-END
-
-#endif    // French (France) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/explorer-hu.rc b/reactos/subsys/system/explorer/explorer-hu.rc
deleted file mode 100644 (file)
index 74eefb9..0000000
+++ /dev/null
@@ -1,399 +0,0 @@
-//Microsoft Developer Studio generated resource script.\r
-//\r
-#include "resource.h"\r
-\r
-#define APSTUDIO_READONLY_SYMBOLS\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 2 resource.\r
-//\r
-#include <windows.h>\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-#undef APSTUDIO_READONLY_SYMBOLS\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-// Hungarian (unknown sub-lang: 0x0) resources\r
-\r
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_HUN)\r
-#ifdef _WIN32\r
-LANGUAGE LANG_HUNGARIAN, 0x0\r
-#pragma code_page(1250)\r
-#endif //_WIN32\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Menu\r
-//\r
-\r
-IDM_MDIFRAME MENU DISCARDABLE \r
-BEGIN\r
-    POPUP "&File"\r
-    BEGIN\r
-        MENUITEM "&Futtatás...",                ID_EXECUTE\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Kilépés",                    ID_FILE_EXIT\r
-    END\r
-    POPUP "&Nézet"\r
-    BEGIN\r
-        MENUITEM "&Eszköztár",                  ID_VIEW_TOOL_BAR\r
-        MENUITEM "&Extra Bar",                  ID_VIEW_EXTRA_BAR\r
-        MENUITEM "&Drivebar",                   ID_VIEW_DRIVE_BAR, CHECKED\r
-        MENUITEM "S&ide Bar",                   ID_VIEW_SIDE_BAR\r
-        MENUITEM "&Állapot sor",                ID_VIEW_STATUSBAR\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Frissít\tF5",                ID_REFRESH\r
-        MENUITEM "T&eljes képernyõ\tCtrl+Shift+S", ID_VIEW_FULLSCREEN\r
-        MENUITEM "SDI",                         ID_VIEW_SDI\r
-    END\r
-    POPUP "&Ablak"\r
-    BEGIN\r
-        MENUITEM "Új &Ablak",                   ID_WINDOW_NEW\r
-        MENUITEM "Lépcsõzetes\tShift+F5",       ID_WINDOW_CASCADE\r
-        MENUITEM "Tile &Horizontally",          ID_WINDOW_TILE_HORZ\r
-        MENUITEM "Tile &Vertically\tShift+F4",  ID_WINDOW_TILE_VERT\r
-        MENUITEM "Arrange Automatically",       ID_WINDOW_AUTOSORT\r
-        MENUITEM "Arrange &Symbols",            ID_WINDOW_ARRANGE\r
-    END\r
-    POPUP "&Eszközök"\r
-    BEGIN\r
-        MENUITEM "&Beállítások",                ID_TOOLS_OPTIONS\r
-    END\r
-    POPUP "&Súgóó"\r
-    BEGIN\r
-        MENUITEM "Explorer &GYIK...",           ID_EXPLORER_FAQ\r
-        MENUITEM "Explorer &névjegye...",       ID_ABOUT_EXPLORER\r
-        MENUITEM "Az &OS névjegye...",          ID_ABOUT_WINDOWS\r
-    END\r
-END\r
-\r
-IDM_DESKTOPBAR MENU DISCARDABLE \r
-BEGIN\r
-    POPUP ""\r
-    BEGIN\r
-        MENUITEM "&Beállítások...",             ID_DESKTOPBAR_SETTINGS\r
-        MENUITEM "&Feladatkezelõ...",           ID_TASKMGR\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Explorer névjegye...",       ID_ABOUT_EXPLORER\r
-    END\r
-END\r
-\r
-IDM_VOLUME MENU DISCARDABLE \r
-BEGIN\r
-    POPUP ""\r
-    BEGIN\r
-        MENUITEM "Hangerõ beállítások",         ID_TRAY_VOLUME\r
-        MENUITEM "Hangrendszer tulajdonságai",  ID_VOLUME_PROPERTIES\r
-    END\r
-END\r
-\r
-IDM_NOTIFYAREA MENU DISCARDABLE \r
-BEGIN\r
-    POPUP ""\r
-    BEGIN\r
-        MENUITEM "&Rejtett ikonok megjelenítése", ID_SHOW_HIDDEN_ICONS\r
-        MENUITEM "Show Icon &Button",           ID_SHOW_ICON_BUTTON\r
-        MENUITEM "&Configure Notifications...", ID_CONFIG_NOTIFYAREA\r
-        MENUITEM "Dátum és idõ beállításai...", ID_CONFIG_TIME\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Explorer névjegye...",       ID_ABOUT_EXPLORER\r
-    END\r
-END\r
-\r
-IDM_SDIFRAME MENU DISCARDABLE \r
-BEGIN\r
-    POPUP "&File"\r
-    BEGIN\r
-        MENUITEM "&Futtatás...",                ID_EXECUTE\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Bezárás",                    ID_FILE_EXIT\r
-    END\r
-    POPUP "&Nézet"\r
-    BEGIN\r
-        MENUITEM "&Eszköztár",                  ID_VIEW_TOOL_BAR\r
-        MENUITEM "S&ide Bar",                   ID_VIEW_SIDE_BAR, GRAYED\r
-        MENUITEM "&Állapot sor",                ID_VIEW_STATUSBAR\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Frissítés\tF5",              ID_REFRESH\r
-        MENUITEM "T&eljes képernyõ\tCtrl+Shift+S", ID_VIEW_FULLSCREEN\r
-        MENUITEM "&MDI",                        ID_VIEW_MDI\r
-    END\r
-    POPUP "&Eszközök"\r
-    BEGIN\r
-        MENUITEM "&Beállítások",                ID_TOOLS_OPTIONS\r
-    END\r
-    POPUP "&Súgóó"\r
-    BEGIN\r
-        MENUITEM "Explorer &GYIK...",           ID_EXPLORER_FAQ\r
-        MENUITEM "&Az Explorer névjegye...",    ID_ABOUT_EXPLORER\r
-        MENUITEM "Az &OS névjegye...",          ID_ABOUT_WINDOWS\r
-    END\r
-END\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Dialog\r
-//\r
-\r
-IDD_EXECUTE DIALOG DISCARDABLE  15, 13, 210, 63\r
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "Futtatás"\r
-FONT 8, "MS Shell Dlg"\r
-BEGIN\r
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,150,10\r
-    CONTROL         "&Parancs:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,\r
-                    18,60,10\r
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL\r
-    CONTROL         "As &Symbol",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,3,\r
-                    45,71,12\r
-    DEFPUSHBUTTON   "&OK",1,158,6,47,14\r
-    PUSHBUTTON      "&Mégse",2,158,23,47,14\r
-    PUSHBUTTON      "&Súgó",254,158,43,47,14\r
-END\r
-\r
-IDD_SEARCH_PROGRAM DIALOGEX 0, 0, 200, 65\r
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | \r
-    WS_SYSMENU | WS_THICKFRAME\r
-EXSTYLE WS_EX_APPWINDOW\r
-CAPTION "Search Program in Startmenu"\r
-FONT 8, "MS Sans Serif", 0, 0, 0x1\r
-BEGIN\r
-    LTEXT           "&Filter:",IDC_STATIC,7,9,18,8\r
-    EDITTEXT        IDC_FILTER,34,7,100,14,ES_AUTOHSCROLL\r
-    CONTROL         "List1",IDC_PROGRAMS_FOUND,"SysListView32",LVS_REPORT | \r
-                    LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | \r
-                    WS_TABSTOP,7,25,186,33\r
-    PUSHBUTTON      "&Check Entries",IDC_CHECK_ENTRIES,143,7,50,14\r
-END\r
-\r
-IDD_DESKBAR_DESKTOP DIALOG DISCARDABLE  0, 0, 212, 194\r
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION\r
-CAPTION "Asztal beállításai"\r
-FONT 8, "MS Sans Serif"\r
-BEGIN\r
-    LTEXT           "Please select your prefered icon alignment algorithm:",\r
-                    IDC_STATIC,7,7,166,8\r
-    CONTROL         "left/top dwn",IDC_ICON_ALIGN_0,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,7,25,46,44\r
-    CONTROL         "left/top right",IDC_ICON_ALIGN_1,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,57,25,46,44\r
-    CONTROL         "right/top left",IDC_ICON_ALIGN_2,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,110,25,46,44\r
-    CONTROL         "rig./top dwn",IDC_ICON_ALIGN_3,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,159,25,46,44\r
-    CONTROL         "left/bot. up",IDC_ICON_ALIGN_4,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,7,73,46,44\r
-    CONTROL         "left/bot. right",IDC_ICON_ALIGN_5,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,57,73,46,44\r
-    CONTROL         "right/bot. left",IDC_ICON_ALIGN_6,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,110,73,46,44\r
-    CONTROL         "rig./bot. dwn",IDC_ICON_ALIGN_7,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,159,73,46,44\r
-    CONTROL         "border down",IDC_ICON_ALIGN_8,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,7,121,46,44\r
-    CONTROL         "border H/V",IDC_ICON_ALIGN_9,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,57,121,46,44\r
-    CONTROL         "round about",IDC_ICON_ALIGN_10,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,110,121,46,44\r
-    CONTROL         "",IDC_ICON_ALIGN_11,"Button",BS_OWNERDRAW | BS_BOTTOM | \r
-                    WS_TABSTOP,159,121,46,44\r
-    CONTROL         "Display &Version Number",ID_DESKTOP_VERSION,"Button",\r
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,177,91,10\r
-END\r
-\r
-IDD_DESKBAR_TASKBAR DIALOG DISCARDABLE  0, 0, 210, 194\r
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION\r
-CAPTION "Taskbar Properties"\r
-FONT 8, "MS Sans Serif"\r
-BEGIN\r
-    CONTROL         "show &clock",ID_SHOW_CLOCK,"Button",BS_AUTOCHECKBOX | \r
-                    WS_TABSTOP,7,152,52,10\r
-    CONTROL         "&hide inactive notification icons",\r
-                    ID_HIDE_INACTIVE_ICONS,"Button",BS_AUTOCHECKBOX | \r
-                    WS_TABSTOP,7,174,111,10\r
-    PUSHBUTTON      "&Notifications...",ID_CONFIG_NOTIFYAREA,153,173,50,14\r
-END\r
-\r
-IDD_DESKBAR_STARTMENU DIALOG DISCARDABLE  0, 0, 210, 194\r
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION\r
-CAPTION "Startmenu Properties"\r
-FONT 8, "MS Sans Serif"\r
-BEGIN\r
-END\r
-\r
-IDD_NOTIFYAREA DIALOGEX 0, 0, 208, 174\r
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | \r
-    WS_SYSMENU | WS_THICKFRAME\r
-EXSTYLE WS_EX_APPWINDOW\r
-CAPTION "Configure Notification Icons"\r
-FONT 8, "MS Sans Serif", 0, 0, 0x1\r
-BEGIN\r
-    CONTROL         "Tree1",IDC_NOTIFY_ICONS,"SysTreeView32",TVS_HASLINES | \r
-                    TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,194,31\r
-    LTEXT           "&Tooltip Text:",IDC_LABEL1,7,44,40,8\r
-    EDITTEXT        IDC_NOTIFY_TOOLTIP,58,42,143,14,ES_AUTOHSCROLL\r
-    LTEXT           "W&indow Title:",IDC_LABEL2,7,63,44,8\r
-    EDITTEXT        IDC_NOTIFY_TITLE,58,60,143,14,ES_AUTOHSCROLL\r
-    LTEXT           "&Module Path:",IDC_LABEL3,7,81,43,8\r
-    EDITTEXT        IDC_NOTIFY_MODULE,58,78,143,14,ES_AUTOHSCROLL\r
-    GROUPBOX        "&Display Mode",IDC_LABEL4,7,96,157,28\r
-    CONTROL         "&show",IDC_NOTIFY_SHOW,"Button",BS_AUTORADIOBUTTON | \r
-                    WS_TABSTOP,15,108,33,10\r
-    CONTROL         "&hide",IDC_NOTIFY_HIDE,"Button",BS_AUTORADIOBUTTON,66,\r
-                    108,29,10\r
-    CONTROL         "a&utohide",IDC_NOTIFY_AUTOHIDE,"Button",\r
-                    BS_AUTORADIOBUTTON,112,108,43,10\r
-    ICON            "",IDC_PICTURE,173,101,21,20\r
-    LTEXT           "&Last Change:",IDC_LABEL6,7,132,43,8\r
-    EDITTEXT        IDC_LAST_CHANGE,59,129,105,14,ES_AUTOHSCROLL | \r
-                    ES_READONLY\r
-    CONTROL         "sho&w hidden",ID_SHOW_HIDDEN_ICONS,"Button",\r
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,154,56,10\r
-    DEFPUSHBUTTON   "&OK",IDOK,91,153,50,14,WS_GROUP\r
-    PUSHBUTTON      "&Mégse",IDCANCEL,151,153,50,14\r
-END\r
-\r
-IDD_MDI_SDI DIALOGEX 0, 0, 194, 157\r
-STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU\r
-EXSTYLE WS_EX_APPWINDOW\r
-CAPTION "Choose Explorer window mode"\r
-FONT 8, "MS Sans Serif", 0, 0, 0x1\r
-BEGIN\r
-    LTEXT           "Please select your prefered explorer user interface:",\r
-                    IDC_STATIC,7,7,160,8\r
-    CONTROL         "&MDI (Multiple Document Interface)",IDC_MDI,"Button",\r
-                    BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,7,31,124,10\r
-    CONTROL         "&SDI (Single Document Interface)",IDC_SDI,"Button",\r
-                    BS_AUTORADIOBUTTON,7,62,118,10\r
-    CONTROL         170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13\r
-    CONTROL         171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13\r
-    CONTROL         "Open Subfolders in s&eparate windows",\r
-                    IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX | \r
-                    WS_TABSTOP,7,90,135,10\r
-    LTEXT           "This setting will be used as default for all explorer windows in the future.",\r
-                    IDC_STATIC,7,111,174,22\r
-    DEFPUSHBUTTON   "&OK",IDOK,29,136,50,14,WS_GROUP\r
-    PUSHBUTTON      "&Mégse",IDCANCEL,106,136,50,14\r
-END\r
-\r
-IDD_ABOUT_EXPLORER DIALOG DISCARDABLE  0, 0, 199, 106\r
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "About ReactOS Explorer"\r
-FONT 10, "MS Sans Serif"\r
-BEGIN\r
-    LTEXT           "ReactOS Explorer",IDC_ROS_EXPLORER,91,13,104,11\r
-    LTEXT           "V 0.9",IDC_VERSION_TXT,91,27,104,8\r
-    LTEXT           "(c) 2003-2005 Martin Fuchs",IDC_STATIC,91,42,104,8\r
-    LTEXT           "",IDC_WIN_VERSION,91,58,98,22\r
-    LTEXT           "http://www.sky.franken.de/explorer/",IDC_WWW,17,84,129,\r
-                    8\r
-    CONTROL         "&OK",IDOK,"Button",BS_OWNERDRAW | BS_FLAT | WS_GROUP,\r
-                    154,90,38,12\r
-END\r
-\r
-\r
-#ifdef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// TEXTINCLUDE\r
-//\r
-\r
-1 TEXTINCLUDE MOVEABLE PURE \r
-BEGIN\r
-    "resource.h\0"\r
-END\r
-\r
-2 TEXTINCLUDE MOVEABLE PURE \r
-BEGIN\r
-    "#include <windows.h>\r\n"\r
-    "\0"\r
-END\r
-\r
-3 TEXTINCLUDE MOVEABLE PURE \r
-BEGIN\r
-    "\r\n"\r
-    "\0"\r
-END\r
-\r
-#endif    // APSTUDIO_INVOKED\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// String Table\r
-//\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_TITLE               "Reactos Explorer"\r
-    IDS_START               "Start"\r
-    IDS_LOGOFF              "Kijelentkezés..."\r
-    IDS_SHUTDOWN            "Kikapcsolás..."\r
-    IDS_LAUNCH              "Futtatás..."\r
-    IDS_START_HELP          "Súgó"\r
-    IDS_SEARCH_FILES        "Keresés..."\r
-    IDS_DOCUMENTS           "Dokumentumok"\r
-    IDS_FAVORITES           "Kedvencek"\r
-    IDS_PROGRAMS            "Programok"\r
-    IDS_SETTINGS            "Beállítások"\r
-    IDS_EXPLORE             "Böngészés"\r
-    IDS_EMPTY               "(Üres)"\r
-    IDS_RECENT              "Recent Documents"\r
-    IDS_ADMIN               "Felügyelet"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_STARTMENU           "Startmenu"\r
-    IDS_MINIMIZE_ALL        "mimimize all windows"\r
-    IDS_DESKTOP_NUM         "%d. asztal"\r
-    IDS_VOLUME              "Hangerõ"\r
-    IDS_ITEMS_CUR           "current items"\r
-    IDS_ITEMS_CONFIGURED    "configuration"\r
-    IDS_ITEMS_VISIBLE       "visible"\r
-    IDS_ITEMS_HIDDEN        "Rejtett"\r
-    IDS_NOTIFY_SHOW         "show"\r
-    IDS_NOTIFY_HIDE         "hide"\r
-    IDS_NOTIFY_AUTOHIDE     "autohide"\r
-    IDS_SHOW_HIDDEN_ICONS   "Show hidden icons"\r
-    IDS_HIDE_ICONS          "Hide icons"\r
-    IDS_TERMINATE           "Kilépés a ROS Explorerbõl"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_NETWORK             "Hálózat"\r
-    IDS_CONNECTIONS         "Hálózati kapcsolatok"\r
-    IDS_DRIVES              "Meghajtók"\r
-    IDS_SEARCH_COMPUTER     "Számítógép keresése..."\r
-    IDS_SETTINGS_MENU       "Settings Menu"\r
-    IDS_CONTROL_PANEL       "Vezérlõpult"\r
-    IDS_PRINTERS            "Nyomtatók"\r
-    IDS_BROWSE              "Állományok böngészése"\r
-    IDS_SEARCH_PRG          "Search Program..."\r
-    IDS_ALL_USERS           "All Users\\"\r
-    IDS_SEARCH              "Keresés"\r
-    IDS_ABOUT_EXPLORER      "Az &Explorer névjegye..."\r
-    IDS_LAUNCH_MANY_PROGRAMS \r
-                            "Több programot választottál ki.\nBiztosan szeretnéd mindegyiket futtatni?"\r
-    IDS_DESKTOPBAR_SETTINGS "Asztal beállításai"\r
-    IDS_DESKTOP             "Asztal"\r
-    IDS_TASKBAR             "Taskbar"\r
-END\r
-\r
-#endif    // Hungarian (unknown sub-lang: 0x0) resources\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-\r
-\r
-#ifndef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 3 resource.\r
-//\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-#endif    // not APSTUDIO_INVOKED\r
-\r
diff --git a/reactos/subsys/system/explorer/explorer-jp.rc b/reactos/subsys/system/explorer/explorer-jp.rc
deleted file mode 100644 (file)
index 37a728d..0000000
+++ /dev/null
@@ -1,399 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include <windows.h>
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// Japanese resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_JPN)
-#ifdef _WIN32
-LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT
-#pragma code_page(932)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_MDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "\83t\83@\83C\83\8b(&F)"
-    BEGIN
-        MENUITEM "\8eÀ\8ds(&E)...",                 ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "\8fI\97¹(&X)",                    ID_FILE_EXIT
-    END
-    POPUP "\95\\\8e¦(&V)"
-    BEGIN
-        MENUITEM "\83c\81[\83\8b \83o\81[(&T)",             ID_VIEW_TOOL_BAR
-        MENUITEM "\83G\83L\83X\83g\83\89 \83o\81[(&E)",         ID_VIEW_EXTRA_BAR
-        MENUITEM "\83h\83\89\83C\83u\83o\81[(&D)",            ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "\83T\83C\83\83o\81[(&I)",             ID_VIEW_SIDE_BAR
-        MENUITEM "\83X\83e\81[\83^\83\83o\81[(&S)",         ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "\8dÅ\90V\82Ì\8fî\95ñ\82É\8dX\90V(&R)\tF5",    ID_REFRESH
-        MENUITEM "\91S\89æ\96Ê\95\\\8e¦(&U)\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-        MENUITEM "SDI",                         ID_VIEW_SDI
-    END
-    POPUP "\83E\83B\83\93\83h\83E(&W)"
-    BEGIN
-        MENUITEM "\90V\82µ\82¢\83E\83B\83\93\83h\83E(&W)",        ID_WINDOW_NEW
-        MENUITEM "\8fd\82Ë\82Ä\95\\\8e¦\tShift+F5",        ID_WINDOW_CASCADE
-        MENUITEM "\90\85\95½\82É\95À\82×\82Ä\95\\\8e¦(&H)",        ID_WINDOW_TILE_HORZ
-        MENUITEM "\90\82\92¼\82É\95À\82×\82Ä\95\\\8e¦(&V)\tShift+F4", ID_WINDOW_TILE_VERT
-        MENUITEM "\8e©\93®\90®\97ñ",                    ID_WINDOW_AUTOSORT
-        MENUITEM "\8dÅ\8f¬\89»\82³\82ê\82½\8eq\83E\83B\83\93\83h\83E\82ð\90®\97ñ(&S)", ID_WINDOW_ARRANGE
-    END
-    POPUP "\83c\81[\83\8b(&T)"
-    BEGIN
-        MENUITEM "\83I\83v\83V\83\87\83\93(&O)",              ID_TOOLS_OPTIONS
-    END
-    POPUP "\83w\83\8b\83v(&H)"
-    BEGIN
-        MENUITEM "Explorer FAQ (&F)...",            ID_EXPLORER_FAQ
-        MENUITEM "Explorer \82É\82Â\82¢\82Ä(&A)...",    ID_ABOUT_EXPLORER
-        MENUITEM "OS \82É\82Â\82¢\82Ä(&O)...",          ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_DESKTOPBAR MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "\90Ý\92è(&S)...",                 ID_DESKTOPBAR_SETTINGS
-        MENUITEM "\83^\83X\83\83}\83l\81[\83W\83\83(&T)...",    ID_TASKMGR
-        MENUITEM SEPARATOR
-        MENUITEM "Explorer \82É\82Â\82¢\82Ä(&A)...",    ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_VOLUME MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "\83{\83\8a\83\85\81[\83\80 \83R\83\93\83g\83\8d\81[\83\8b\82ð\8aJ\82­", ID_TRAY_VOLUME
-        MENUITEM "\83I\81[\83f\83B\83\83v\83\8d\83p\83e\83B\82Ì\92²\90®", ID_VOLUME_PROPERTIES
-    END
-END
-
-IDM_NOTIFYAREA MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "\89B\82³\82ê\82½\83A\83C\83R\83\93\82ð\95\\\8e¦\82·\82é(&S)", ID_SHOW_HIDDEN_ICONS
-        MENUITEM "\83A\83C\83R\83\93 \83{\83^\83\93\82ð\95\\\8e¦\82·\82é(&B)",  ID_SHOW_ICON_BUTTON
-        MENUITEM "\92Ê\92m\82Ì\83J\83X\83^\83}\83C\83Y(&C)...",   ID_CONFIG_NOTIFYAREA
-        MENUITEM "\93ú\95t\82Æ\8e\9e\8d\8f\82Ì\92²\90®(&T)...",     ID_CONFIG_TIME
-        MENUITEM SEPARATOR
-        MENUITEM "Explorer \82É\82Â\82¢\82Ä(&A)...",    ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_SDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "\83t\83@\83C\83\8b(&F)"
-    BEGIN
-        MENUITEM "\8eÀ\8ds(&E)...",                 ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "\95Â\82\82é(&C)",                  ID_FILE_EXIT
-    END
-    POPUP "\95\\\8e¦(&V)"
-    BEGIN
-        MENUITEM "\83c\81[\83\8b \83o\81[(&T)",             ID_VIEW_TOOL_BAR
-        MENUITEM "\83T\83C\83\83o\81[(&I)",             ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "\83X\83e\81[\83^\83\83o\81[(&S)",         ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "\8dÅ\90V\82Ì\8fî\95ñ\82É\8dX\90V(&R)\tF5",    ID_REFRESH
-        MENUITEM "\91S\89æ\96Ê\95\\\8e¦(&U)\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-        MENUITEM "MDI (&M)",                        ID_VIEW_MDI
-    END
-    POPUP "\83c\81[\83\8b(&T)"
-    BEGIN
-        MENUITEM "\83I\83v\83V\83\87\83\93(&O)",              ID_TOOLS_OPTIONS
-    END
-    POPUP "\83w\83\8b\83v(&H)"
-    BEGIN
-        MENUITEM "Explorer FAQ (&F)...",            ID_EXPLORER_FAQ
-        MENUITEM "Explorer \82É\82Â\82¢\82Ä(&A)...",    ID_ABOUT_EXPLORER
-        MENUITEM "OS \82É\82Â\82¢\82Ä(&O)...",          ID_ABOUT_WINDOWS
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_EXECUTE DIALOG DISCARDABLE  15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "\8eÀ\8ds"
-FONT 9, "MS UI Gothic"
-BEGIN
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,150,10
-    CONTROL         "\83R\83}\83\93\83h(&C):",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,
-                    18,60,10
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL
-    CONTROL         "\8dÅ\8f¬\89»\82µ\82½\8fó\91Ô\82Å\8eÀ\8ds(&S)",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,3,
-                    45,71,12
-    DEFPUSHBUTTON   "OK (&O)",1,158,6,47,14
-    PUSHBUTTON      "\83L\83\83\83\93\83Z\83\8b(&C)",2,158,23,47,14
-    PUSHBUTTON      "\83w\83\8b\83v(&H)",254,158,43,47,14
-END
-
-IDD_SEARCH_PROGRAM DIALOGEX 0, 0, 200, 65
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "\83X\83^\81[\83g\83\81\83j\83\85\81[\82©\82ç\83v\83\8d\83O\83\89\83\80\82ð\8c\9f\8dõ"
-FONT 9, "MS UI Gothic", 0, 0, 0x1
-BEGIN
-    LTEXT           "\83t\83B\83\8b\83^(&F):",IDC_STATIC,7,9,18,8
-    EDITTEXT        IDC_FILTER,34,7,100,14,ES_AUTOHSCROLL
-    CONTROL         "List1",IDC_PROGRAMS_FOUND,"SysListView32",LVS_REPORT | 
-                    LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | 
-                    WS_TABSTOP,7,25,186,33
-    PUSHBUTTON      "\93o\98^\82ð\83`\83F\83b\83N\82·\82é(&C)",IDC_CHECK_ENTRIES,143,7,50,14
-END
-
-IDD_DESKBAR_DESKTOP DIALOG DISCARDABLE  0, 0, 212, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "\83f\83X\83N\83g\83b\83v\82Ì\83v\83\8d\83p\83e\83B"
-FONT 9, "MS UI Gothic"
-BEGIN
-    LTEXT           "\8eg\97p\82µ\82½\82¢\83A\83C\83R\83\93\82Ì\94z\92u\82ð\91I\91ð\82µ\82Ä\82­\82¾\82³\82¢:",
-                    IDC_STATIC,7,7,166,8
-    CONTROL         "\8d\8fã\82©\82ç\89º\82Ö",IDC_ICON_ALIGN_0,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,25,46,44
-    CONTROL         "\8d\8fã\82©\82ç\89E\82Ö",IDC_ICON_ALIGN_1,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,25,46,44
-    CONTROL         "\89E\8fã\82©\82ç\8d\82Ö",IDC_ICON_ALIGN_2,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,25,46,44
-    CONTROL         "\89E\8fã\82©\82ç\89º\82Ö",IDC_ICON_ALIGN_3,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,25,46,44
-    CONTROL         "\8d\89º\82©\82ç\8fã\82Ö",IDC_ICON_ALIGN_4,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,73,46,44
-    CONTROL         "\8d\89º\82©\82ç\89E\82Ö",IDC_ICON_ALIGN_5,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,73,46,44
-    CONTROL         "\89E\89º\82©\82ç\8d\82Ö",IDC_ICON_ALIGN_6,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,73,46,44
-    CONTROL         "\89E\89º\82©\82ç\89º\82Ö",IDC_ICON_ALIGN_7,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,73,46,44
-    CONTROL         "\8d\89E\82ð\89º\82Ö",IDC_ICON_ALIGN_8,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,121,46,44
-    CONTROL         "\8fã\82Æ\8d\89E\82Ì\92[",IDC_ICON_ALIGN_9,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,121,46,44
-    CONTROL         "\97Ö\82É\82È\82é\82æ\82¤\82É",IDC_ICON_ALIGN_10,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,121,46,44
-    CONTROL         "",IDC_ICON_ALIGN_11,"Button",BS_OWNERDRAW | BS_BOTTOM | 
-                    WS_TABSTOP,159,121,46,44
-    CONTROL         "\83f\83X\83N\83g\83b\83v\82É\83o\81[\83W\83\87\83\93\82ð\95\\\8e¦\82·\82é(&V)",ID_DESKTOP_VERSION,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,177,91,10
-END
-
-IDD_DESKBAR_TASKBAR DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "\83^\83X\83\83o\81[\82Ì\83v\83\8d\83p\83e\83B"
-FONT 9, "MS UI Gothic"
-BEGIN
-    CONTROL         "\8e\9e\8cv\82ð\95\\\8e¦\82·\82é(&C)",ID_SHOW_CLOCK,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,152,52,10
-    CONTROL         "\83A\83N\83e\83B\83u\82Å\82È\82¢\92Ê\92m\83A\83C\83R\83\93\82ð\89B\82·(&H)",
-                    ID_HIDE_INACTIVE_ICONS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,174,111,10
-    PUSHBUTTON      "\92Ê\92m\83A\83C\83R\83\93(&N)...",ID_CONFIG_NOTIFYAREA,153,173,50,14
-END
-
-IDD_DESKBAR_STARTMENU DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "\83X\83^\81[\83g\83\81\83j\83\85\81[\82Ì\83v\83\8d\83p\83e\83B"
-FONT 9, "MS UI Gothic"
-BEGIN
-END
-
-IDD_NOTIFYAREA DIALOGEX 0, 0, 208, 174
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "\92Ê\92m\83A\83C\83R\83\93\82Ì\90Ý\92è"
-FONT 9, "MS UI Gothic", 0, 0, 0x1
-BEGIN
-    CONTROL         "Tree1",IDC_NOTIFY_ICONS,"SysTreeView32",TVS_HASLINES | 
-                    TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,194,31
-    LTEXT           "\83c\81[\83\8b \83`\83b\83v\82Ì\93à\97e(&T):",IDC_LABEL1,7,44,40,8
-    EDITTEXT        IDC_NOTIFY_TOOLTIP,58,42,143,14,ES_AUTOHSCROLL
-    LTEXT           "\83E\83B\83\93\83h\83E\82Ì\83^\83C\83g\83\8b(&I):",IDC_LABEL2,7,63,44,8
-    EDITTEXT        IDC_NOTIFY_TITLE,58,60,143,14,ES_AUTOHSCROLL
-    LTEXT           "\83\82\83W\83\85\81[\83\8b\82Ì\8fê\8f\8a(&M):",IDC_LABEL3,7,81,43,8
-    EDITTEXT        IDC_NOTIFY_MODULE,58,78,143,14,ES_AUTOHSCROLL
-    GROUPBOX        "\95\\\8e¦\83\82\81[\83h(&D)",IDC_LABEL4,7,96,157,28
-    CONTROL         "\95\\\8e¦\82·\82é(&S)",IDC_NOTIFY_SHOW,"Button",BS_AUTORADIOBUTTON | 
-                    WS_TABSTOP,15,108,33,10
-    CONTROL         "\89B\82·(&H)",IDC_NOTIFY_HIDE,"Button",BS_AUTORADIOBUTTON,66,
-                    108,29,10
-    CONTROL         "\8e©\93®\93I\82É\89B\82·(&U)",IDC_NOTIFY_AUTOHIDE,"Button",
-                    BS_AUTORADIOBUTTON,112,108,43,10
-    ICON            "",IDC_PICTURE,173,101,21,20
-    LTEXT           "\8dÅ\8fI\95Ï\8dX(&L):",IDC_LABEL6,7,132,43,8
-    EDITTEXT        IDC_LAST_CHANGE,59,129,105,14,ES_AUTOHSCROLL | 
-                    ES_READONLY
-    CONTROL         "\89B\82ê\82½\83A\83C\83R\83\93\82à\95\\\8e¦(&W)",ID_SHOW_HIDDEN_ICONS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,154,56,10
-    DEFPUSHBUTTON   "OK (&O)",IDOK,91,153,50,14,WS_GROUP
-    PUSHBUTTON      "\83L\83\83\83\93\83Z\83\8b(&C)",IDCANCEL,151,153,50,14
-END
-
-IDD_MDI_SDI DIALOGEX 0, 0, 194, 138
-STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "\83G\83N\83X\83v\83\8d\81[\83\89\82Ì\83E\83B\83\93\83h\83\83\82\81[\83h\82Ì\91I\91ð"
-FONT 9, "MS UI Gothic", 0, 0, 0x1
-BEGIN
-    LTEXT           "\8eg\97p\82µ\82½\82¢\83\86\81[\83U\81\83C\83\93\83^\81[\83t\83F\81[\83X\82ð\91I\91ð\82µ\82Ä\82­\82¾\82³\82¢:",
-                    IDC_STATIC,7,7,160,8
-    CONTROL         "MDI (Multiple Document Interface)(&M)",IDC_MDI,"Button",
-                    BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,7,31,124,10
-    CONTROL         "SDI (Single Document Interface)(&S)",IDC_SDI,"Button",
-                    BS_AUTORADIOBUTTON,7,62,118,10
-    CONTROL         170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13
-    CONTROL         171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13
-    CONTROL         "\83T\83u\83t\83H\83\8b\83_\82ð\90V\82µ\82¢\83E\83B\83\93\83h\83E\82Å\8aJ\82­(&E)",
-                    IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,90,135,10
-    LTEXT           "\82±\82ê\82æ\82è\82±\82Ì\90Ý\92è\82ª\81A\82·\82×\82Ä\82Ì Explorer \83E\83B\83\93\83h\83E\82Ì\83f\83t\83H\83\8b\83g\82É\82È\82è\82Ü\82·\81B",
-                    IDC_STATIC,7,111,174,22
-    DEFPUSHBUTTON   "OK (&O)",IDOK,29,136,50,14,WS_GROUP
-    PUSHBUTTON      "\83L\83\83\83\93\83Z\83\8b(&C)",IDCANCEL,106,136,50,14
-END
-
-IDD_ABOUT_EXPLORER DIALOG DISCARDABLE  0, 0, 199, 106
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "ReactOS Explorer \82É\82Â\82¢\82Ä"
-FONT 10, "MS UI Gothic"
-BEGIN
-    LTEXT           "ReactOS Explorer",IDC_ROS_EXPLORER,91,13,104,11
-    LTEXT           "V 0.9",IDC_VERSION_TXT,91,27,104,8
-    LTEXT           "(c) 2003-2005 Martin Fuchs",IDC_STATIC,91,42,104,8
-    LTEXT           "",IDC_WIN_VERSION,91,58,98,22
-    LTEXT           "http://www.sky.franken.de/explorer/",IDC_WWW,17,84,129,
-                    8
-    CONTROL         "OK (&O)",IDOK,"Button",BS_OWNERDRAW | BS_FLAT | WS_GROUP,
-                    154,90,38,12
-END
-
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "#include <windows.h>\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "ReactOS Explorer"
-    IDS_START               "½À°Ä"
-    IDS_LOGOFF              "\83\8d\83O\83I\83t..."
-    IDS_SHUTDOWN            "\83V\83\83\83b\83g\83_\83E\83\93..."
-    IDS_LAUNCH              "\83t\83@\83C\83\8b\96¼\82ð\8ew\92è\82µ\82Ä\8eÀ\8ds..."
-    IDS_START_HELP          "\83w\83\8b\83v"
-    IDS_SEARCH_FILES        "\83t\83@\83C\83\8b\82â\83t\83H\83\8b\83_..."
-    IDS_DOCUMENTS           "\83}\83C\83h\83L\83\85\83\81\83\93\83g"
-    IDS_FAVORITES           "\82¨\8bC\82É\93ü\82è"
-    IDS_PROGRAMS            "\83v\83\8d\83O\83\89\83\80"
-    IDS_SETTINGS            "\90Ý\92è"
-    IDS_EXPLORE             "\83G\83N\83X\83v\83\8d\81[\83\89"
-    IDS_EMPTY               "(\82È\82µ)"
-    IDS_RECENT              "\8dÅ\8bß\8eg\82Á\82½\83t\83@\83C\83\8b"
-    IDS_ADMIN               "\8aÇ\97\9d\83c\81[\83\8b"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_STARTMENU           "\83X\83^\81[\83g\83\81\83j\83\85\81["
-    IDS_MINIMIZE_ALL        "\91S\83E\83B\83\93\83h\83E\82ð\8dÅ\8f¬\89»"
-    IDS_DESKTOP_NUM         "\83f\83X\83N\83g\83b\83v %d"
-    IDS_VOLUME              "\89¹\97Ê"
-    IDS_ITEMS_CUR           "\8c»\8dÝ\82Ì\83A\83C\83R\83\93"
-    IDS_ITEMS_CONFIGURED    "\90Ý\92è"
-    IDS_ITEMS_VISIBLE       "\95\\\8e¦"
-    IDS_ITEMS_HIDDEN        "\94ñ\95\\\8e¦"
-    IDS_NOTIFY_SHOW         "\95\\\8e¦\82·\82é"
-    IDS_NOTIFY_HIDE         "\89B\82·"
-    IDS_NOTIFY_AUTOHIDE     "\8e©\93®\93I\82É\89B\82·"
-    IDS_SHOW_HIDDEN_ICONS   "\89B\82ê\82Ä\82¢\82é\83A\83C\83R\83\93\82à\95\\\8e¦\82·\82é"
-    IDS_HIDE_ICONS          "\83A\83C\83R\83\93\82ð\89B\82·"
-    IDS_TERMINATE           "ROS Explorer \82ð\8fI\97¹\82·\82é"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_NETWORK             "\83l\83b\83g\83\8f\81[\83N"
-    IDS_CONNECTIONS         "\83l\83b\83g\83\8f\81[\83N\90Ú\91±"
-    IDS_DRIVES              "\83\8d\81[\83J\83\8b\83f\83B\83X\83N"
-    IDS_SEARCH_COMPUTER     "\83R\83\93\83s\83\85\81[\83^\82Ì\8c\9f\8dõ..."
-    IDS_SETTINGS_MENU       "\90Ý\92è\83\81\83j\83\85\81["
-    IDS_CONTROL_PANEL       "\83R\83\93\83g\83\8d\81[\83\8b \83p\83l\83\8b"
-    IDS_PRINTERS            "\83v\83\8a\83\93\83^"
-    IDS_BROWSE              "\83t\83@\83C\83\8b\82Ì\83u\83\89\83E\83Y"
-    IDS_SEARCH_PRG          "\83v\83\8d\83O\83\89\83\80\82ð\8c\9f\8dõ..."
-    IDS_ALL_USERS           "All Users\\"
-    IDS_SEARCH              "\8c\9f\8dõ"
-    IDS_ABOUT_EXPLORER      "Explorer \82É\82Â\82¢\82Ä(&A)..."
-    IDS_LAUNCH_MANY_PROGRAMS 
-                            "\93ñ\82Â\88È\8fã\82Ì\83v\83\8d\83O\83\89\83\80\82ª\91I\91ð\82³\82ê\82Ü\82µ\82½\81B\n\82·\82×\82Ä\82Ì\83v\83\8d\83O\83\89\83\80\82ð\8eÀ\8ds\82µ\82Ü\82·\82©?"
-    IDS_DESKTOPBAR_SETTINGS "\83f\83X\83N\83g\83b\83v\82Ì\90Ý\92è"
-    IDS_DESKTOP             "\83f\83X\83N\83g\83b\83v"
-    IDS_TASKBAR             "\83^\83X\83N\83o\81["
-END
-
-#endif    // Japanese resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/explorer-pl.rc b/reactos/subsys/system/explorer/explorer-pl.rc
deleted file mode 100644 (file)
index 591f0d7..0000000
+++ /dev/null
@@ -1,399 +0,0 @@
-//Microsoft Developer Studio generated resource script.\r
-//\r
-#include "resource.h"\r
-\r
-#define APSTUDIO_READONLY_SYMBOLS\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 2 resource.\r
-//\r
-#include <windows.h>\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-#undef APSTUDIO_READONLY_SYMBOLS\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-// Polish (PL) resources\r
-\r
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)\r
-#ifdef _WIN32\r
-LANGUAGE LANG_POLISH, SUBLANG_NEUTRAL\r
-#pragma code_page(1250)\r
-#endif //_WIN32\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Menu\r
-//\r
-\r
-IDM_MDIFRAME MENU DISCARDABLE \r
-BEGIN\r
-    POPUP "&Plik"\r
-    BEGIN\r
-        MENUITEM "Urucho&m...",                        ID_EXECUTE\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Za&koñcz",                           ID_FILE_EXIT\r
-    END\r
-    POPUP "&Widok"\r
-    BEGIN\r
-        MENUITEM "Przyciski &standardowe",              ID_VIEW_TOOL_BAR\r
-        MENUITEM "P&rzyciski dodatkowe",                ID_VIEW_EXTRA_BAR\r
-        MENUITEM "Pasek &dysków",                      ID_VIEW_DRIVE_BAR, CHECKED\r
-        MENUITEM "Pasek &boczny",                      ID_VIEW_SIDE_BAR\r
-        MENUITEM "Pasek sta&nu",                               ID_VIEW_STATUSBAR\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Od\9cwie¿\tF5",                       ID_REFRESH\r
-        MENUITEM "P&e³ny ekran\tCtrl+Shift+S",         ID_VIEW_FULLSCREEN\r
-        MENUITEM "SDI",                                ID_VIEW_SDI\r
-    END\r
-    POPUP "&Okna"\r
-    BEGIN\r
-        MENUITEM "Nowe &okno",                                 ID_WINDOW_NEW\r
-        MENUITEM "&Kaskada\tShift+F5",                         ID_WINDOW_CASCADE\r
-        MENUITEM "&S¹siaduj¹co poziomo",               ID_WINDOW_TILE_HORZ\r
-        MENUITEM "S¹siaduj¹co &pionowo\tShift+F4",     ID_WINDOW_TILE_VERT\r
-        MENUITEM "&Autorozmieszczenie",                ID_WINDOW_AUTOSORT\r
-        MENUITEM "Rozmie\9cæ wed³ug &nazwy",             ID_WINDOW_ARRANGE\r
-    END\r
-    POPUP "&Narzêdzia"\r
-    BEGIN\r
-        MENUITEM "&Opcje",                             ID_TOOLS_OPTIONS\r
-    END\r
-    POPUP "Pomo&c"\r
-    BEGIN\r
-        MENUITEM "Explorer &FAQ",                      ID_EXPLORER_FAQ\r
-        MENUITEM "ReactOS Explorer - &Informacje",      ID_ABOUT_EXPLORER\r
-        MENUITEM "ReactOS - I&nformacje",               ID_ABOUT_WINDOWS\r
-    END\r
-END\r
-\r
-IDM_DESKTOPBAR MENU DISCARDABLE \r
-BEGIN\r
-    POPUP ""\r
-    BEGIN\r
-        MENUITEM "&W³a\9cciwo\9cci",                               ID_DESKTOPBAR_SETTINGS\r
-        MENUITEM "Mened¿er &zadañ",                    ID_TASKMGR\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "ReactOS Explorer - &Informacje",     ID_ABOUT_EXPLORER\r
-    END\r
-END\r
-\r
-IDM_VOLUME MENU DISCARDABLE \r
-BEGIN\r
-    POPUP ""\r
-    BEGIN\r
-        MENUITEM "&Otwórz regulacje g³o\9cno\9cci",        ID_TRAY_VOLUME\r
-        MENUITEM "&Ustaw w³a\9cciwo\9cci audio",           ID_VOLUME_PROPERTIES\r
-    END\r
-END\r
-\r
-IDM_NOTIFYAREA MENU DISCARDABLE \r
-BEGIN\r
-    POPUP ""\r
-    BEGIN\r
-        MENUITEM "&Poka¿ ukryte ikony",                ID_SHOW_HIDDEN_ICONS\r
-        MENUITEM "&Ukrywaj nieu¿ywane ikony",          ID_SHOW_ICON_BUTTON\r
-        MENUITEM "&Konfiguruj powiadomienia",          ID_CONFIG_NOTIFYAREA\r
-        MENUITEM "Ustaw &datê/godzinê",                ID_CONFIG_TIME\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "ReactOS Explorer - &Informacje",      ID_ABOUT_EXPLORER\r
-    END\r
-END\r
-\r
-IDM_SDIFRAME MENU DISCARDABLE \r
-BEGIN\r
-    POPUP "&Plik"\r
-    BEGIN\r
-        MENUITEM "Urucho&m...",                        ID_EXECUTE\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Za&koñcz",                           ID_FILE_EXIT\r
-    END\r
-    POPUP "&Widok"\r
-    BEGIN\r
-        MENUITEM "Przyciski &standardowe",             ID_VIEW_TOOL_BAR\r
-        MENUITEM "Pasek &boczny",                      ID_VIEW_SIDE_BAR, GRAYED\r
-        MENUITEM "Pasek sta&nu",                       ID_VIEW_STATUSBAR\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Od\9cwie¿\tF5",                       ID_REFRESH\r
-        MENUITEM "P&e³ny ekran\tCtrl+Shift+S",         ID_VIEW_FULLSCREEN\r
-        MENUITEM "&MDI",                               ID_VIEW_MDI\r
-    END\r
-    POPUP "&Narzêdzia"\r
-    BEGIN\r
-        MENUITEM "&Opcje",                             ID_TOOLS_OPTIONS\r
-    END\r
-    POPUP "Pomo&c"\r
-    BEGIN\r
-        MENUITEM "Explorer &FAQ",                      ID_EXPLORER_FAQ\r
-        MENUITEM "ReactOS Explorer - &Informacje",      ID_ABOUT_EXPLORER\r
-        MENUITEM "ReactOS - I&nformacje",              ID_ABOUT_WINDOWS\r
-    END\r
-END\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Dialog\r
-//\r
-\r
-IDD_EXECUTE DIALOG DISCARDABLE  15, 13, 210, 63\r
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "Uruchom"\r
-FONT 8, "MS Shell Dlg"\r
-BEGIN\r
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,150,10\r
-    CONTROL         "&Polecenie:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,\r
-                    18,60,10\r
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL\r
-    CONTROL         "Jako &symbol",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,3,\r
-                    45,71,12\r
-    DEFPUSHBUTTON   "&OK",1,158,6,47,14\r
-    PUSHBUTTON      "&Anuluj",2,158,23,47,14\r
-    PUSHBUTTON      "Pomo&c",254,158,43,47,14\r
-END\r
-\r
-IDD_SEARCH_PROGRAM DIALOGEX 0, 0, 200, 65\r
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | \r
-    WS_SYSMENU | WS_THICKFRAME\r
-EXSTYLE WS_EX_APPWINDOW\r
-CAPTION "Szukaj programu w menu start"\r
-FONT 8, "MS Sans Serif", 0, 0, 0x1\r
-BEGIN\r
-    LTEXT           "&Filtry:",IDC_STATIC,7,9,18,8\r
-    EDITTEXT        IDC_FILTER,34,7,100,14,ES_AUTOHSCROLL\r
-    CONTROL         "List1",IDC_PROGRAMS_FOUND,"SysListView32",LVS_REPORT | \r
-                    LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | \r
-                    WS_TABSTOP,7,25,186,33\r
-    PUSHBUTTON      "&Szukaj nazwy",IDC_CHECK_ENTRIES,143,7,50,14\r
-END\r
-\r
-IDD_DESKBAR_DESKTOP DIALOG DISCARDABLE  0, 0, 212, 194\r
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION\r
-CAPTION "W³a\9cciwo\9cci pulpitu"\r
-FONT 8, "MS Sans Serif"\r
-BEGIN\r
-    LTEXT           "Wybierz sposób uk³adania ikon:",\r
-                    IDC_STATIC,7,7,166,8\r
-    CONTROL         "left/top dwn",IDC_ICON_ALIGN_0,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,7,25,46,44\r
-    CONTROL         "left/top right",IDC_ICON_ALIGN_1,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,57,25,46,44\r
-    CONTROL         "right/top left",IDC_ICON_ALIGN_2,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,110,25,46,44\r
-    CONTROL         "rig./top dwn",IDC_ICON_ALIGN_3,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,159,25,46,44\r
-    CONTROL         "left/bot. up",IDC_ICON_ALIGN_4,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,7,73,46,44\r
-    CONTROL         "left/bot. right",IDC_ICON_ALIGN_5,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,57,73,46,44\r
-    CONTROL         "right/bot. left",IDC_ICON_ALIGN_6,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,110,73,46,44\r
-    CONTROL         "rig./bot. dwn",IDC_ICON_ALIGN_7,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,159,73,46,44\r
-    CONTROL         "border down",IDC_ICON_ALIGN_8,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,7,121,46,44\r
-    CONTROL         "border H/V",IDC_ICON_ALIGN_9,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,57,121,46,44\r
-    CONTROL         "round about",IDC_ICON_ALIGN_10,"Button",BS_OWNERDRAW | \r
-                    BS_BOTTOM | WS_TABSTOP,110,121,46,44\r
-    CONTROL         "",IDC_ICON_ALIGN_11,"Button",BS_OWNERDRAW | BS_BOTTOM | \r
-                    WS_TABSTOP,159,121,46,44\r
-    CONTROL         "Wy\9cwietlaj &numer wersji",ID_DESKTOP_VERSION,"Button",\r
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,177,91,10\r
-END\r
-\r
-IDD_DESKBAR_TASKBAR DIALOG DISCARDABLE  0, 0, 210, 194\r
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION\r
-CAPTION "W³a\9cciwo\9cci paska zadañ"\r
-FONT 8, "MS Sans Serif"\r
-BEGIN\r
-    CONTROL         "Poka¿ &zegar",ID_SHOW_CLOCK,"Button",BS_AUTOCHECKBOX | \r
-                    WS_TABSTOP,7,152,52,10\r
-    CONTROL         "&Ukrywaj nieaktywne ikony",\r
-                    ID_HIDE_INACTIVE_ICONS,"Button",BS_AUTOCHECKBOX | \r
-                    WS_TABSTOP,7,174,111,10\r
-    PUSHBUTTON      "&Dostosuj",ID_CONFIG_NOTIFYAREA,153,173,50,14\r
-END\r
-\r
-IDD_DESKBAR_STARTMENU DIALOG DISCARDABLE  0, 0, 210, 194\r
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION\r
-CAPTION "W³a\9cciwo\9cci Menu Start"\r
-FONT 8, "MS Sans Serif"\r
-BEGIN\r
-END\r
-\r
-IDD_NOTIFYAREA DIALOGEX 0, 0, 208, 174\r
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | \r
-    WS_SYSMENU | WS_THICKFRAME\r
-EXSTYLE WS_EX_APPWINDOW\r
-CAPTION "Konfiguracja ikon powiadomieñ"\r
-FONT 8, "MS Sans Serif", 0, 0, 0x1\r
-BEGIN\r
-    CONTROL         "Tree1",IDC_NOTIFY_ICONS,"SysTreeView32",TVS_HASLINES | \r
-                    TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,194,31\r
-    LTEXT           "&Podpowied\9f:",IDC_LABEL1,7,44,40,8\r
-    EDITTEXT        IDC_NOTIFY_TOOLTIP,58,42,143,14,ES_AUTOHSCROLL\r
-    LTEXT           "&Tytu³ okna:",IDC_LABEL2,7,63,44,8\r
-    EDITTEXT        IDC_NOTIFY_TITLE,58,60,143,14,ES_AUTOHSCROLL\r
-    LTEXT           "\8ccie¿ka:",IDC_LABEL3,7,81,43,8\r
-    EDITTEXT        IDC_NOTIFY_MODULE,58,78,143,14,ES_AUTOHSCROLL\r
-    GROUPBOX        "&Sposób wy\9cwietlania",IDC_LABEL4,7,96,157,28\r
-    CONTROL         "&widoczny",IDC_NOTIFY_SHOW,"Button",BS_AUTORADIOBUTTON | \r
-                    WS_TABSTOP,15,108,33,10\r
-    CONTROL         "&ukryty",IDC_NOTIFY_HIDE,"Button",BS_AUTORADIOBUTTON,66,\r
-                    108,29,10\r
-    CONTROL         "&autoukrywanie",IDC_NOTIFY_AUTOHIDE,"Button",\r
-                    BS_AUTORADIOBUTTON,112,108,43,10\r
-    ICON            "",IDC_PICTURE,173,101,21,20\r
-    LTEXT           "&Zmodyfikowany:",IDC_LABEL6,7,132,43,8\r
-    EDITTEXT        IDC_LAST_CHANGE,59,129,105,14,ES_AUTOHSCROLL | \r
-                    ES_READONLY\r
-    CONTROL         "Po&ka¿ wszystkie",ID_SHOW_HIDDEN_ICONS,"Button",\r
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,154,56,10\r
-    DEFPUSHBUTTON   "&OK",IDOK,91,153,50,14,WS_GROUP\r
-    PUSHBUTTON      "&Anuluj",IDCANCEL,151,153,50,14\r
-END\r
-\r
-IDD_MDI_SDI DIALOGEX 0, 0, 194, 157\r
-STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU\r
-EXSTYLE WS_EX_APPWINDOW\r
-CAPTION "Tryb wy\9cwietlania okien"\r
-FONT 8, "MS Sans Serif", 0, 0, 0x1\r
-BEGIN\r
-    LTEXT           "Wybierz tryb wy\9cwietlania okien:",\r
-                    IDC_STATIC,7,7,160,8\r
-    CONTROL         "&MDI (Otwieraj w jednym oknie)",IDC_MDI,"Button",\r
-                    BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,7,31,124,10\r
-    CONTROL         "&SDI (Otwieraj we w³asnym oknie)",IDC_SDI,"Button",\r
-                    BS_AUTORADIOBUTTON,7,62,118,10\r
-    CONTROL         170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13\r
-    CONTROL         171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13\r
-    CONTROL         "&Otwieraj podkatalogi w nowych oknach",\r
-                    IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX | \r
-                    WS_TABSTOP,7,90,135,10\r
-    LTEXT           "Te opcje bêd¹ stosowane w przysz³o\9cci do wszystkich okien.",\r
-                    IDC_STATIC,7,111,174,22\r
-    DEFPUSHBUTTON   "&OK",IDOK,29,136,50,14,WS_GROUP\r
-    PUSHBUTTON      "&Anuluj",IDCANCEL,106,136,50,14\r
-END\r
-\r
-IDD_ABOUT_EXPLORER DIALOG DISCARDABLE  0, 0, 199, 106\r
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "ReactOS Explorer - &Informacje"\r
-FONT 10, "MS Sans Serif"\r
-BEGIN\r
-    LTEXT           "ReactOS Explorer",IDC_ROS_EXPLORER,91,13,104,11\r
-    LTEXT           "V 0.9",IDC_VERSION_TXT,91,27,104,8\r
-    LTEXT           "(c) 2003-2005 Martin Fuchs",IDC_STATIC,91,42,104,8\r
-    LTEXT           "",IDC_WIN_VERSION,91,58,98,22\r
-    LTEXT           "http://www.sky.franken.de/explorer/",IDC_WWW,17,84,129,\r
-                    8\r
-    CONTROL         "&OK",IDOK,"Button",BS_OWNERDRAW | BS_FLAT | WS_GROUP,\r
-                    154,90,38,12\r
-END\r
-\r
-\r
-#ifdef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// TEXTINCLUDE\r
-//\r
-\r
-1 TEXTINCLUDE MOVEABLE PURE \r
-BEGIN\r
-    "resource.h\0"\r
-END\r
-\r
-2 TEXTINCLUDE MOVEABLE PURE \r
-BEGIN\r
-    "#include <windows.h>\r\n"\r
-    "\0"\r
-END\r
-\r
-3 TEXTINCLUDE MOVEABLE PURE \r
-BEGIN\r
-    "\r\n"\r
-    "\0"\r
-END\r
-\r
-#endif    // APSTUDIO_INVOKED\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// String Table\r
-//\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_TITLE               "Reactos Explorer"\r
-    IDS_START               "Start"\r
-    IDS_LOGOFF              "Wyloguj..."\r
-    IDS_SHUTDOWN            "Zamknij system..."\r
-    IDS_LAUNCH              "Uruchom..."\r
-    IDS_START_HELP          "Pomoc"\r
-    IDS_SEARCH_FILES        "Szukaj..."\r
-    IDS_DOCUMENTS           "Dokumenty"\r
-    IDS_FAVORITES           "Ulubione"\r
-    IDS_PROGRAMS            "Programy"\r
-    IDS_SETTINGS            "Ustawienia"\r
-    IDS_EXPLORE             "Eksploruj"\r
-    IDS_EMPTY               "(pusty)"\r
-    IDS_RECENT              "Ostatnio otwarte"\r
-    IDS_ADMIN               "Administracja"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_STARTMENU           "Menu start"\r
-    IDS_MINIMIZE_ALL        "Minimalizuj wszystko"\r
-    IDS_DESKTOP_NUM         "Pulpit %d"\r
-    IDS_VOLUME              "G³o\9cno\9cæ"\r
-    IDS_ITEMS_CUR           "Aktualne pozycje"\r
-    IDS_ITEMS_CONFIGURED    "ustawienia"\r
-    IDS_ITEMS_VISIBLE       "widoczne"\r
-    IDS_ITEMS_HIDDEN        "ukryte"\r
-    IDS_NOTIFY_SHOW         "poka¿"\r
-    IDS_NOTIFY_HIDE         "ukryj"\r
-    IDS_NOTIFY_AUTOHIDE     "autoukrywanie"\r
-    IDS_SHOW_HIDDEN_ICONS   "Poka¿ ukryte ikony"\r
-    IDS_HIDE_ICONS          "Ukryj ikony"\r
-    IDS_TERMINATE           "Zakoñcz dzia³anie ROS Explorer"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_NETWORK             "Sieæ"\r
-    IDS_CONNECTIONS         "Po³¹czenia sieciowe"\r
-    IDS_DRIVES              "Dysk"\r
-    IDS_SEARCH_COMPUTER     "Znajd\9f komputar..."\r
-    IDS_SETTINGS_MENU       "Settings menu"\r
-    IDS_CONTROL_PANEL       "Panel sterowania"\r
-    IDS_PRINTERS            "Drukarki"\r
-    IDS_BROWSE              "Przegl¹daj"\r
-    IDS_SEARCH_PRG          "Znajd\9f progarm..."\r
-    IDS_ALL_USERS           "All Users\\"\r
-    IDS_SEARCH              "Szukaj"\r
-    IDS_ABOUT_EXPLORER      "ReactOS Explorer - &Informacje"\r
-    IDS_LAUNCH_MANY_PROGRAMS \r
-                            "Zaznaczy³e\9c wiêcej ni¿ jeden program.\nCzy chcesz uruchomiæ je jednocze\9cnie?"\r
-    IDS_DESKTOPBAR_SETTINGS "W³a\9cciwo\9cci pulpitu"\r
-    IDS_DESKTOP             "Pulpit"\r
-    IDS_TASKBAR             "Pasek zadañ"\r
-END\r
-\r
-#endif    // Polish (PL) resources\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-\r
-\r
-#ifndef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 3 resource.\r
-//\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-#endif    // not APSTUDIO_INVOKED\r
-\r
diff --git a/reactos/subsys/system/explorer/explorer-pt.rc b/reactos/subsys/system/explorer/explorer-pt.rc
deleted file mode 100644 (file)
index bf48273..0000000
+++ /dev/null
@@ -1,167 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include "resource.h"
-#define APSTUDIO_HIDDEN_SYMBOLS
-#include "windows.h"
-#undef APSTUDIO_HIDDEN_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// German (Germany) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)
-#ifdef _WIN32
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-#pragma code_page(1252)
-#endif //_WIN32
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#include ""resource.h""\r\n"
-    "#define APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "#include ""windows.h""\r\n"
-    "#undef APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-#endif    // German (Germany) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-/////////////////////////////////////////////////////////////////////////////
-// Portuguese (Portugal) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_PTG)
-#ifdef _WIN32
-LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE
-#pragma code_page(1252)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_EXECUTE DIALOG DISCARDABLE  15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Executar"
-FONT 8, "MS Shell Dlg"
-BEGIN
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,162,10
-    CONTROL         "Co&mando:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,
-                    18,60,10
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL
-    CONTROL         "Como &Símbolo",214,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,3,45,71,12
-    DEFPUSHBUTTON   "&OK",1,158,6,47,14
-    PUSHBUTTON      "&Cancelar",2,158,23,47,14
-    PUSHBUTTON      "&Ajuda",254,158,43,47,14
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "Explorador do Reactos"
-    IDS_START               "Iniciar"
-    IDS_LOGOFF              "Terminar sessão..."
-    IDS_SHUTDOWN            "Desligar..."
-    IDS_LAUNCH              "Executar..."
-    IDS_START_HELP          "Ajuda"
-    IDS_SEARCH_FILES        "Procurar..."
-    IDS_DOCUMENTS           "Documentos"
-    IDS_FAVORITES           "Favoritos"
-    IDS_PROGRAMS            "Programas"
-    IDS_SETTINGS            "Definições"
-    IDS_EXPLORE             "Explorar"
-    IDS_EMPTY               "(Vazio)"
-    IDS_RECENT              "Documentos recentes"
-    IDS_ADMIN               "Administrar"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_STARTMENU           "Startmenu"
-    IDS_MINIMIZE_ALL        "mimimize all windows"
-    IDS_DESKTOP_NUM         "Desktop %d"
-    IDS_VOLUME              "Volume"
-    IDS_ITEMS_CUR           "current items"
-    IDS_ITEMS_CONFIGURED    "configuration"
-    IDS_ITEMS_VISIBLE       "visible"
-    IDS_ITEMS_HIDDEN        "hidden"
-    IDS_NOTIFY_SHOW         "show"
-    IDS_NOTIFY_HIDE         "hide"
-    IDS_NOTIFY_AUTOHIDE     "autohide"
-    IDS_SHOW_HIDDEN_ICONS   "Show hidden icons"
-    IDS_HIDE_ICONS          "Hide icons"
-    IDS_TERMINATE           "Terminar ROS Explorador"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_NETWORK             "Rede"
-    IDS_CONNECTIONS         "Conecções da rede"
-    IDS_DRIVES              "Drives"
-    IDS_SEARCH_COMPUTER     "Procurar computador..."
-    IDS_SETTINGS_MENU       "Menu das definições"
-    IDS_CONTROL_PANEL       "Painel de controle"
-    IDS_PRINTERS            "Impressora"
-    IDS_BROWSE              "Vasculhar Ficheiros"
-    IDS_SEARCH_PRG          "Procurar programa..."
-    IDS_ALL_USERS           "Todos utilizadores\\"
-    IDS_SEARCH              "Procurar"
-    IDS_ABOUT_EXPLORER      "Sobre o Explorador..."
-    IDS_LAUNCH_MANY_PROGRAMS 
-                            "You have selected more than one program.\nAre you sure you want to launch all of them?"
-    IDS_DESKTOPBAR_SETTINGS "Desktop Settings"
-    IDS_DESKTOP             "Desktop"
-    IDS_TASKBAR             "Taskbar"
-END
-
-#endif    // Portuguese (Portugal) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/explorer-ro.rc b/reactos/subsys/system/explorer/explorer-ro.rc
deleted file mode 100644 (file)
index f14141e..0000000
+++ /dev/null
@@ -1,244 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include "resource.h"
-#define APSTUDIO_HIDDEN_SYMBOLS
-#include "windows.h"
-#undef APSTUDIO_HIDDEN_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// Romanian resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ROM)
-#ifdef _WIN32
-LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL
-#pragma code_page(1250)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_MDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Fiºier"
-    BEGIN
-        MENUITEM "&Execute...",                 ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Ieºire",                     ID_FILE_EXIT
-    END
-    POPUP "&Prezentare"
-    BEGIN
-        MENUITEM "&Bara cu instrumente",        ID_VIEW_TOOL_BAR
-        MENUITEM "&Extra Bar",                  ID_VIEW_EXTRA_BAR
-        MENUITEM "&Drivebar",                   ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "&Bara de stare",              ID_VIEW_STATUSBAR
-        MENUITEM "&Side Bar",                   ID_VIEW_SIDE_BAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Resetare\tF5",               ID_REFRESH
-        MENUITEM "F&ull Screen\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-        MENUITEM "&SDI",                        ID_VIEW_SDI
-    END
-    POPUP "&Fereastrã"
-    BEGIN
-        MENUITEM "&Fereastrã Nouã",             ID_WINDOW_NEW
-        MENUITEM "Cascading\tShift+F5",         ID_WINDOW_CASCADE
-        MENUITEM "Aliniazã &Orizontal",         ID_WINDOW_TILE_HORZ
-        MENUITEM "Aliniazã &Vertical\tShift+F4", ID_WINDOW_TILE_VERT
-        MENUITEM "Aranjeazã automat",           ID_WINDOW_AUTOSORT
-        MENUITEM "Aranjeazã &Simbolurile",      ID_WINDOW_ARRANGE
-    END
-    POPUP "&Tools"
-    BEGIN
-        MENUITEM "&Options",                    ID_TOOLS_OPTIONS
-    END
-    POPUP "&Ajutor"
-    BEGIN
-        MENUITEM "Explorer &FAQ...",            ID_EXPLORER_FAQ
-        MENUITEM "&Despre Explorer...",         ID_ABOUT_EXPLORER
-        MENUITEM "Despre &OS...",               ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_SDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Fiºier"
-    BEGIN
-        MENUITEM "&Execute...",                 ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Ieºire",                     ID_FILE_EXIT
-    END
-    POPUP "&Prezentare"
-    BEGIN
-        MENUITEM "&Bara cu instrumente",        ID_VIEW_TOOL_BAR
-        MENUITEM "&Side Bar",                   ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "&Bara de stare",              ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Resetare\tF5",               ID_REFRESH
-        MENUITEM "F&ull Screen\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-        MENUITEM "&MDI",                        ID_VIEW_MDI
-    END
-    POPUP "&Tools"
-    BEGIN
-        MENUITEM "&Options",                    ID_TOOLS_OPTIONS
-    END
-    POPUP "&Ajutor"
-    BEGIN
-        MENUITEM "Explorer &FAQ...",            ID_EXPLORER_FAQ
-        MENUITEM "&Despre Explorer...",         ID_ABOUT_EXPLORER
-        MENUITEM "Despre &OS...",               ID_ABOUT_WINDOWS
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_EXECUTE DIALOG DISCARDABLE  15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Execute"
-FONT 8, "MS Shell Dlg"
-BEGIN
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,162,10
-    CONTROL         "&Comanda:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,
-                    18,60,10
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL
-    CONTROL         "Ca &Simbol",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,3,
-                    45,71,12
-    DEFPUSHBUTTON   "&OK",1,158,6,47,14
-    PUSHBUTTON      "A&nulare",2,158,23,47,14
-    PUSHBUTTON      "&Ajutor",254,158,43,47,14
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "ReactOS Explorer"
-    IDS_START               "Începe"
-    IDS_LOGOFF              "Închide sesiunea ..."
-    IDS_SHUTDOWN            "Oprire calculator ..."
-    IDS_LAUNCH              "Pornire ..."
-    IDS_START_HELP          "Ajutor"
-    IDS_SEARCH_FILES        "Cãutare Files..."
-    IDS_DOCUMENTS           "Documente"
-    IDS_FAVORITES           "Preferinþe"
-    IDS_PROGRAMS            "Programe"
-    IDS_SETTINGS            "Setãri"
-    IDS_EXPLORE             "Explorare"
-    IDS_EMPTY               "(Empty)"
-    IDS_RECENT              "Documente Recente"
-    IDS_ADMIN               "Administrare"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_STARTMENU           "Startmenu"
-    IDS_MINIMIZE_ALL        "mimimize all windows"
-    IDS_DESKTOP_NUM         "Desktop %d"
-    IDS_VOLUME              "Volume"
-    IDS_ITEMS_CUR           "current items"
-    IDS_ITEMS_CONFIGURED    "configuration"
-    IDS_ITEMS_VISIBLE       "visible"
-    IDS_ITEMS_HIDDEN        "hidden"
-    IDS_NOTIFY_SHOW         "show"
-    IDS_NOTIFY_HIDE         "hide"
-    IDS_NOTIFY_AUTOHIDE     "autohide"
-    IDS_SHOW_HIDDEN_ICONS   "Show hidden icons"
-    IDS_HIDE_ICONS          "Hide icons"
-    IDS_TERMINATE           "Închide sesiunea"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_NETWORK             "Reþea"
-    IDS_CONNECTIONS         "Conecþii"
-    IDS_DRIVES              "Discuri"
-    IDS_SEARCH_COMPUTER     "Search Computer..."
-    IDS_SETTINGS_MENU       "Settings Menu"
-    IDS_CONTROL_PANEL       "Control Panel"
-    IDS_PRINTERS            "Printers"
-    IDS_BROWSE              "Browse Files"
-    IDS_SEARCH_PRG          "Search Programm..."
-    IDS_ALL_USERS           "All Users\\"
-    IDS_SEARCH              "Cãutare..."
-    IDS_ABOUT_EXPLORER      "&Despre Explorer..."
-    IDS_LAUNCH_MANY_PROGRAMS 
-                            "You have selected more than one program.\nAre you sure you want to launch all of them?"
-    IDS_DESKTOPBAR_SETTINGS "Desktop Settings"
-    IDS_DESKTOP             "Desktop"
-    IDS_TASKBAR             "Taskbar"
-END
-
-#endif    // Romanian resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-/////////////////////////////////////////////////////////////////////////////
-// German (Germany) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)
-#ifdef _WIN32
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-#pragma code_page(1252)
-#endif //_WIN32
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#include ""resource.h""\r\n"
-    "#define APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "#include ""windows.h""\r\n"
-    "#undef APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-#endif    // German (Germany) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/explorer-ru.rc b/reactos/subsys/system/explorer/explorer-ru.rc
deleted file mode 100644 (file)
index 4771a71..0000000
+++ /dev/null
@@ -1,416 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include "resource.h"
-#define APSTUDIO_HIDDEN_SYMBOLS
-#include "windows.h"
-#undef APSTUDIO_HIDDEN_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// Russian resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_RUS)
-#ifdef _WIN32
-LANGUAGE LANG_RUSSIAN, SUBLANG_NEUTRAL
-#pragma code_page(1251)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_DESKTOPBAR MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Íàñòðîéêè...",               ID_DESKTOPBAR_SETTINGS
-        MENUITEM "&Äèñïåò÷åð Çàäà÷...",         ID_TASKMGR
-        MENUITEM SEPARATOR
-        MENUITEM "&ΠÏðîâîäíèêå...",            ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_MDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Ôàéë"
-    BEGIN
-        MENUITEM "&Çàïóñòèòü...",               ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "Â&ûõîä",                      ID_FILE_EXIT
-    END
-    POPUP "&Âèä"
-    BEGIN
-        MENUITEM "&Ïàíåëü èíñòðóìåíòîâ",        ID_VIEW_TOOL_BAR
-        MENUITEM "&Äîïîëíèòåëüíàÿ ïàíåëü",      ID_VIEW_EXTRA_BAR
-        MENUITEM "&Äèñêè",                      ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "È&çáðàííîå",                  ID_VIEW_SIDE_BAR
-        MENUITEM "&Ñòðîêà ñîñòîÿíèÿ",           ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Îáíîâèòü\tF5",               ID_REFRESH
-        MENUITEM "Ïî&ëíûé ýêðàí\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-        MENUITEM "SDI",                         ID_VIEW_SDI
-    END
-    POPUP "Î&êíà"
-    BEGIN
-        MENUITEM "Íîâîå î&êíî",                 ID_WINDOW_NEW
-        MENUITEM "Ðàñïîëîæèòü êàñêàäîì\tShift+F5", ID_WINDOW_CASCADE
-        MENUITEM "&Ãîðèçîíòàëüíî",              ID_WINDOW_TILE_HORZ
-        MENUITEM "&Âåðòèêàëüíî\tShift+F4",      ID_WINDOW_TILE_VERT
-        MENUITEM "Óïîðÿäî÷èòü àâòîìàòè÷åñêè",   ID_WINDOW_AUTOSORT
-        MENUITEM "Óïîðÿäî÷èòü &çíà÷êè",         ID_WINDOW_ARRANGE
-    END
-    POPUP "&Èíñòðóìåíòû"
-    BEGIN
-        MENUITEM "&Îïöèè",                      ID_TOOLS_OPTIONS
-    END
-    POPUP "Ïî&ìîùü"
-    BEGIN
-        MENUITEM "&FAQ(×àÂî) ïî Ïðîâîäíèêó...", ID_EXPLORER_FAQ
-        MENUITEM "Π&Ïðîâîäíèêå...",            ID_ABOUT_EXPLORER
-        MENUITEM "Îá &ÎÑ...",                   ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_NOTIFYAREA MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Ïîêàçûâàòü ñêðûòûå çíà÷êè",  ID_SHOW_HIDDEN_ICONS
-        MENUITEM "Ïîêàçûâàòü çíà÷êè íà &êíîïêàõ", ID_SHOW_ICON_BUTTON
-        MENUITEM "&Íàñòðîéêà óâåäîìëåíèé...",   ID_CONFIG_NOTIFYAREA
-        MENUITEM "Íàñòðîéêà äàòû/&âðåìåíè",     ID_CONFIG_TIME
-        MENUITEM SEPARATOR
-        MENUITEM "&ΠÏðîâîäíèêå...",            ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_SDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Ôàéë"
-    BEGIN
-        MENUITEM "&Çàïóñòèòü...",               ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "Â&ûõîä",                      ID_FILE_EXIT
-    END
-    POPUP "&Âèä"
-    BEGIN
-        MENUITEM "&Ïàíåëü èíñòðóìåíòîâ",        ID_VIEW_TOOL_BAR
-        MENUITEM "È&çáðàííîå",                  ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "&Ñòðîêà ñîñòîÿíèÿ",           ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Îáíîâèòü\tF5",               ID_REFRESH
-        MENUITEM "Ïî&ëíûé ýêðàí\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-        MENUITEM "&MDI",                        ID_VIEW_MDI
-    END
-    POPUP "&Èíñòðóìåíòû"
-    BEGIN
-        MENUITEM "&Îïöèè",                      ID_TOOLS_OPTIONS
-    END
-    POPUP "&Ñïðàâêà"
-    BEGIN
-        MENUITEM "&FAQ(×àÂÎ) ïî Ïðîâîäíèêó...", ID_EXPLORER_FAQ
-        MENUITEM "Π&Ïðîâîäíèêå...",            ID_ABOUT_EXPLORER
-        MENUITEM "Îá &ÎÑ...",                   ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_VOLUME MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "Ãðîìêîñòü",                   ID_TRAY_VOLUME
-        MENUITEM "Ñâîéñòâà çâóêà",              ID_VOLUME_PROPERTIES
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_ABOUT_EXPLORER DIALOGEX 0, 0, 199, 106
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "ΠÏðîâîäíèêå ReactOS"
-FONT 10, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "Ïðîâîäíèê ReactOS",IDC_ROS_EXPLORER,91,13,104,11
-    LTEXT           "V 0.9",IDC_VERSION_TXT,91,27,104,8
-    LTEXT           "(c) 2003-2005 Martin Fuchs",IDC_STATIC,91,42,104,8
-    LTEXT           "",IDC_WIN_VERSION,91,58,98,22
-    LTEXT           "http://www.sky.franken.de/explorer/",IDC_WWW,17,84,129,
-                    8
-    CONTROL         "&OK",IDOK,"Button",BS_OWNERDRAW | BS_FLAT | WS_GROUP,
-                    154,90,38,12
-END
-
-IDD_DESKBAR_DESKTOP DIALOGEX 0, 0, 212, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Ñâîéñòâà Ðàáî÷åãî Ñòîëà"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "Âûáåðèòå, íàèáîëåå ïðåäïî÷òèòåëüíûé äëÿ âàñ, \nñïîñîá âûðàâíèâàíèÿ çíà÷êîâ",
-                    IDC_STATIC,7,7,195,18
-    CONTROL         "left/top dwn",IDC_ICON_ALIGN_0,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,25,46,44
-    CONTROL         "left/top right",IDC_ICON_ALIGN_1,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,25,46,44
-    CONTROL         "right/top left",IDC_ICON_ALIGN_2,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,25,46,44
-    CONTROL         "rig./top dwn",IDC_ICON_ALIGN_3,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,25,46,44
-    CONTROL         "left/bot. up",IDC_ICON_ALIGN_4,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,73,46,44
-    CONTROL         "left/bot. right",IDC_ICON_ALIGN_5,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,73,46,44
-    CONTROL         "right/bot. left",IDC_ICON_ALIGN_6,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,73,46,44
-    CONTROL         "rig./bot. dwn",IDC_ICON_ALIGN_7,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,73,46,44
-    CONTROL         "border down",IDC_ICON_ALIGN_8,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,121,46,44
-    CONTROL         "border H/V",IDC_ICON_ALIGN_9,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,121,46,44
-    CONTROL         "round about",IDC_ICON_ALIGN_10,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,121,46,44
-    CONTROL         "",IDC_ICON_ALIGN_11,"Button",BS_OWNERDRAW | BS_BOTTOM | 
-                    WS_TABSTOP,159,121,46,44
-    CONTROL         "Ïîêàçûâàòü Íîìåð &Âåðñèè",ID_DESKTOP_VERSION,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,177,109,10
-END
-
-IDD_DESKBAR_STARTMENU DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Ñâîéòñâà ìåíþ Ïóñê"
-FONT 8, "MS Sans Serif"
-BEGIN
-END
-
-IDD_DESKBAR_TASKBAR DIALOGEX 0, 0, 227, 202
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Ñâîéñòâà ïàíåëè çàäà÷"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    CONTROL         "Îòîáðàæàòü &÷àñû",ID_SHOW_CLOCK,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,17,161,76,10
-    CONTROL         "&Ñêðûâàòü íåèñïîëüçóåìûå çíà÷êè",ID_HIDE_INACTIVE_ICONS,
-                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,178,135,10
-    PUSHBUTTON      "&Óâåäîìëåíèÿ...",ID_CONFIG_NOTIFYAREA,156,174,63,14
-END
-
-IDD_EXECUTE DIALOGEX 15, 13, 210, 63
-STYLE DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Âûïîëíèòü"
-FONT 8, "MS Shell Dlg", 0, 0, 0x1
-BEGIN
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,150,10
-    CONTROL         "&Êîìàíäà:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,
-                    18,60,10
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL
-    CONTROL         "As &Symbol",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,3,
-                    45,71,12
-    DEFPUSHBUTTON   "&OK",1,158,6,47,14
-    PUSHBUTTON      "&Îòìåíà",2,158,24,47,14
-    PUSHBUTTON      "&Ñïðàâêà",254,158,42,47,14
-END
-
-IDD_MDI_SDI DIALOGEX 0, 0, 194, 157
-STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Âûáåðèòå ðåæèì MDI / SDI"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "Âûáåðèòå íàèáîëåå ïðåäïî÷òèòåëüíûé äëÿ âàñ\nâèä ïðîâîäíèêà:",
-                    IDC_STATIC,7,7,171,17
-    CONTROL         "&MDI (ìíîãîäîêóìåíòíûé íòåðôåéñ)",IDC_MDI,"Button",
-                    BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,7,31,136,10
-    CONTROL         "&SDI (îäíîäîêóìåíòíûé èíòåðôåéñ)",IDC_SDI,"Button",
-                    BS_AUTORADIOBUTTON,7,62,134,10
-    CONTROL         170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13
-    CONTROL         171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13
-    CONTROL         "Open Subfolders in s&eparate windows",
-                    IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,90,135,10
-    LTEXT           "Ýòè íàñòðîéêè áóäóò èñïîëüçîâàííû, êàê çíà÷åíèå ïî óìîë÷àíèþ äëÿ âñåõ îêîí ïðîâîäíèêà â áóäóùåì.",
-                    IDC_STATIC,7,107,174,26
-    DEFPUSHBUTTON   "&OK",IDOK,29,136,50,14,WS_GROUP
-    PUSHBUTTON      "&Cancel",IDCANCEL,106,136,50,14
-END
-
-IDD_NOTIFYAREA DIALOGEX 0, 0, 208, 174
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Êîíôèãóðàöèÿ çíà÷êîâ"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    CONTROL         "Tree1",IDC_NOTIFY_ICONS,"SysTreeView32",TVS_HASLINES | 
-                    TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,194,31
-    LTEXT           "&Òåêñò Ïîäñêàçêè:",IDC_LABEL1,7,44,62,8
-    EDITTEXT        IDC_NOTIFY_TOOLTIP,76,42,125,14,ES_AUTOHSCROLL
-    LTEXT           "Çàãîëîâîê Î&êíà:",IDC_LABEL2,7,63,58,8
-    EDITTEXT        IDC_NOTIFY_TITLE,76,60,125,14,ES_AUTOHSCROLL
-    LTEXT           "&Ïóòü ê Ìîäóëþ:",IDC_LABEL3,7,81,54,8
-    EDITTEXT        IDC_NOTIFY_MODULE,76,78,125,14,ES_AUTOHSCROLL
-    GROUPBOX        "&Ðåæèì Îòîáðàæåíèÿ",IDC_LABEL4,7,96,169,28
-    CONTROL         "&ïîêàçàòü",IDC_NOTIFY_SHOW,"Button",BS_AUTORADIOBUTTON | 
-                    WS_TABSTOP,15,108,47,10
-    CONTROL         "&ñêðûòü",IDC_NOTIFY_HIDE,"Button",BS_AUTORADIOBUTTON,66,
-                    108,41,10
-    CONTROL         "à&âòîñêðûòèå",IDC_NOTIFY_AUTOHIDE,"Button",
-                    BS_AUTORADIOBUTTON,112,108,60,10
-    ICON            "",IDC_PICTURE,181,101,20,20
-    LTEXT           "&Ïîñëåäíèå\nÈçìåíåíèÿ",IDC_LABEL6,7,129,40,19
-    EDITTEXT        IDC_LAST_CHANGE,59,129,105,14,ES_AUTOHSCROLL | 
-                    ES_READONLY
-    CONTROL         "ïîêà&çàòü ñêðûòîå",ID_SHOW_HIDDEN_ICONS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,154,78,10
-    DEFPUSHBUTTON   "&OK",IDOK,91,153,50,14,WS_GROUP
-    PUSHBUTTON      "&Îòìåíà",IDCANCEL,151,153,50,14
-END
-
-IDD_SEARCH_PROGRAM DIALOGEX 0, 0, 200, 65
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Ïîèñê ïðîãðàììû â Ïñóêå"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "&Ôèëüòð:",IDC_STATIC,7,9,30,8
-    EDITTEXT        IDC_FILTER,40,7,94,14,ES_AUTOHSCROLL
-    CONTROL         "List1",IDC_PROGRAMS_FOUND,"SysListView32",LVS_REPORT | 
-                    LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | 
-                    WS_TABSTOP,7,25,186,33
-    PUSHBUTTON      "&Ïðîâåðèòü",IDC_CHECK_ENTRIES,143,7,50,14
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "Ïðîâîäíèê Reactos"
-    IDS_START               "Ïóñê"
-    IDS_LOGOFF              "Âûõîä èç ñèñòåìû..."
-    IDS_SHUTDOWN            "Âûêëþ÷èòü..."
-    IDS_LAUNCH              "Âûïîëíèòü..."
-    IDS_START_HELP          "Ñïðàâêà"
-    IDS_SEARCH_FILES        "Ïîèñê..."
-    IDS_DOCUMENTS           "Äîêóìåíòû"
-    IDS_FAVORITES           "Èçáðàííîå"
-    IDS_PROGRAMS            "Ïðîãðàììû"
-    IDS_SETTINGS            "Íàñòðîéêè"
-    IDS_EXPLORE             "Îáçîð"
-    IDS_EMPTY               "(Ïóñòî)"
-    IDS_RECENT              "Íåäàâíèå äîêóìåíòû"
-    IDS_ADMIN               "Àäìèíèñòðèðîâàíèå"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_NETWORK             "Ñåòü"
-    IDS_CONNECTIONS         "Ñåòåâûå ïîäêëþ÷åíèÿ"
-    IDS_DRIVES              "Äèñêè"
-    IDS_SEARCH_COMPUTER     "Íàéòè êîìïüþòåð..."
-    IDS_SETTINGS_MENU       "Íàñòðîéêà ìåíþ"
-    IDS_CONTROL_PANEL       "Ïàíåëü óïðàâëåíèÿ"
-    IDS_PRINTERS            "Ïðèíòåðû"
-    IDS_BROWSE              "Îáçîð ôàéëîâ"
-    IDS_SEARCH_PRG          "Íàéòè ïðîãðàììó..."
-    IDS_ALL_USERS           "Âñå ïîëüçîâàòåëè\\"
-    IDS_SEARCH              "Ïîèñê"
-    IDS_ABOUT_EXPLORER      "&ΠÏðîâîäíèêå..."
-    IDS_LAUNCH_MANY_PROGRAMS 
-                            "Âû âûáðàëè áîëåå îäíîé ïðîãðàììû.\nÂû óâåðåíû, ÷òî õîòèòå âûïîëíèòü èõ âñå?"
-    IDS_DESKTOPBAR_SETTINGS "Íàñòðîéêè ðàáî÷åãî ñòîëà"
-    IDS_DESKTOP             "Ðàáî÷èé Ñòîë"
-    IDS_TASKBAR             "Ïàíåëü çàäà÷"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_STARTMENU           "Ìåíþ Ïóñêà"
-    IDS_MINIMIZE_ALL        "ñâåðíóòü âñå îêíà"
-    IDS_DESKTOP_NUM         "Ðàáî÷èé Ñòîë %d"
-    IDS_VOLUME              "Îáú¸ì"
-    IDS_ITEMS_CUR           "òåêóùåé ýëåìåíò"
-    IDS_ITEMS_CONFIGURED    "êîíôèãóðàöèÿ"
-    IDS_ITEMS_VISIBLE       "âèäèìûé"
-    IDS_ITEMS_HIDDEN        "ñêðûòûé"
-    IDS_NOTIFY_SHOW         "ïîêàçàòü"
-    IDS_NOTIFY_HIDE         "ñêðûòü"
-    IDS_NOTIFY_AUTOHIDE     "àâòîñêðûòèå"
-    IDS_SHOW_HIDDEN_ICONS   "Ïîêàçàòü ñêðûòûå çíà÷êè"
-    IDS_HIDE_ICONS          "Ñêðûòü çíà÷êè"
-    IDS_TERMINATE           "Çàâåðøèòü ðàáîòó Ïðîâîäíèêà"
-END
-
-#endif    // Russian resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-/////////////////////////////////////////////////////////////////////////////
-// German (Germany) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)
-#ifdef _WIN32
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-#pragma code_page(1252)
-#endif //_WIN32
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#include ""resource.h""\r\n"
-    "#define APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "#include ""windows.h""\r\n"
-    "#undef APSTUDIO_HIDDEN_SYMBOLS\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-#endif    // German (Germany) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/explorer-sv.rc b/reactos/subsys/system/explorer/explorer-sv.rc
deleted file mode 100644 (file)
index cb82147..0000000
+++ /dev/null
@@ -1,394 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include <windows.h>
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// German (Germany) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)
-#ifdef _WIN32
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-#pragma code_page(1252)
-#endif //_WIN32
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "#include <windows.h>\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-#endif    // German (Germany) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-/////////////////////////////////////////////////////////////////////////////
-// Swedish resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_SVE)
-#ifdef _WIN32
-LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL
-#pragma code_page(1252)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_MDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Arkiv"
-    BEGIN
-        MENUITEM "&Kör...",                     ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Avsluta",                    ID_FILE_EXIT
-    END
-    POPUP "&Visa"
-    BEGIN
-        MENUITEM "&Verktygsfält",               ID_VIEW_TOOL_BAR
-        MENUITEM "&Extrafält",                  ID_VIEW_EXTRA_BAR
-        MENUITEM "E&nhetsfält",                 ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "S&idfält",                    ID_VIEW_SIDE_BAR
-        MENUITEM "&Statusfält",                 ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Uppdatera\tF5",              ID_REFRESH
-        MENUITEM "F&ullskärm\tCtrl+Shift+S",    ID_VIEW_FULLSCREEN
-        MENUITEM "SDI",                         ID_VIEW_SDI
-    END
-    POPUP "&Fönster"
-    BEGIN
-        MENUITEM "Nytt &fönster",               ID_WINDOW_NEW
-        MENUITEM "Överlappande\tShift+F5",      ID_WINDOW_CASCADE
-        MENUITEM "Ordna &horizontellt",         ID_WINDOW_TILE_HORZ
-        MENUITEM "Ordna &vertikalt\tShift+F4",  ID_WINDOW_TILE_VERT
-        MENUITEM "Ordna automatiskt",           ID_WINDOW_AUTOSORT
-        MENUITEM "Ordna &symboler",             ID_WINDOW_ARRANGE
-    END
-    POPUP "&Verktyg"
-    BEGIN
-        MENUITEM "&Alternativ",                 ID_TOOLS_OPTIONS
-    END
-    POPUP "&Hjälp"
-    BEGIN
-        MENUITEM "Explorer &FAQ...",            ID_EXPLORER_FAQ
-        MENUITEM "Om &Explorer...",             ID_ABOUT_EXPLORER
-        MENUITEM "Om &OS...",                   ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_DESKTOPBAR MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Inställningar...",           ID_DESKTOPBAR_SETTINGS
-        MENUITEM "&Aktivitetshanteraren...",    ID_TASKMGR
-        MENUITEM SEPARATOR
-        MENUITEM "&Om Explorer...",             ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_VOLUME MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "Öppna volymkontroll",         ID_TRAY_VOLUME
-        MENUITEM "Justera ljudinställningar",   ID_VOLUME_PROPERTIES
-    END
-END
-
-IDM_NOTIFYAREA MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Visa dolda ikoner",          ID_SHOW_HIDDEN_ICONS
-        MENUITEM "Visa &ikonknapp",             ID_SHOW_ICON_BUTTON
-        MENUITEM "&Konfigurera meddelanden...", ID_CONFIG_NOTIFYAREA
-        MENUITEM "Justera &datum och &tid...",  ID_CONFIG_TIME
-        MENUITEM SEPARATOR
-        MENUITEM "&Om Explorer...",             ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_SDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Arkiv"
-    BEGIN
-        MENUITEM "&Kör...",                     ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "&Avsluta",                    ID_FILE_EXIT
-    END
-    POPUP "&Visa"
-    BEGIN
-        MENUITEM "&Verktygsfält",               ID_VIEW_TOOL_BAR
-        MENUITEM "&Sidfält",                    ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "&Statusfält",                 ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Uppdatera\tF5",              ID_REFRESH
-        MENUITEM "&Fullskärm\tCtrl+Shift+S",    ID_VIEW_FULLSCREEN
-        MENUITEM "&MDI",                        ID_VIEW_MDI
-    END
-    POPUP "&Verktyg"
-    BEGIN
-        MENUITEM "&Alternativ",                 ID_TOOLS_OPTIONS
-    END
-    POPUP "&Hjälp"
-    BEGIN
-        MENUITEM "Explorer &FAQ...",            ID_EXPLORER_FAQ
-        MENUITEM "&Om Explorer...",             ID_ABOUT_EXPLORER
-        MENUITEM "Om &operativsystemet...",     ID_ABOUT_WINDOWS
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_EXECUTE DIALOG DISCARDABLE  15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Kör"
-FONT 8, "MS Shell Dlg"
-BEGIN
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,162,10
-    CONTROL         "&Kommando:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,
-                    18,60,10
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL
-    CONTROL         "&Som symbol",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,
-                    3,45,71,12
-    DEFPUSHBUTTON   "&OK",1,158,6,47,14
-    PUSHBUTTON      "&Avbryt",2,158,23,47,14
-    PUSHBUTTON      "&Hjälp",254,158,43,47,14
-END
-
-IDD_SEARCH_PROGRAM DIALOGEX 0, 0, 200, 65
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Sök program på startmenyn"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "&Filter:",IDC_STATIC,7,9,18,8
-    EDITTEXT        IDC_FILTER,34,7,100,14,ES_AUTOHSCROLL
-    CONTROL         "List1",IDC_PROGRAMS_FOUND,"SysListView32",LVS_REPORT | 
-                    LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | 
-                    WS_TABSTOP,7,25,186,33
-    PUSHBUTTON      "&Kontrollera poster",IDC_CHECK_ENTRIES,143,7,50,14
-END
-
-IDD_DESKBAR_DESKTOP DIALOG DISCARDABLE  0, 0, 212, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Skrivbordsinställningar"
-FONT 8, "MS Sans Serif"
-BEGIN
-    LTEXT           "Välj från vilket hörn och åt vilket håll du föredrar att rada upp ikonerna:",
-                    IDC_STATIC,7,7,166,8
-    CONTROL         "vä. och neråt",IDC_ICON_ALIGN_0,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,25,46,44
-    CONTROL         "övre åt hö.",IDC_ICON_ALIGN_1,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,25,46,44
-    CONTROL         "övre åt vä.",IDC_ICON_ALIGN_2,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,25,46,44
-    CONTROL         "hö. och neråt",IDC_ICON_ALIGN_3,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,25,46,44
-    CONTROL         "vä. och uppåt",IDC_ICON_ALIGN_4,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,73,46,44
-    CONTROL         "nedre åt hö.",IDC_ICON_ALIGN_5,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,73,46,44
-    CONTROL         "nedre åt vä.",IDC_ICON_ALIGN_6,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,73,46,44
-    CONTROL         "hö. och uppåt",IDC_ICON_ALIGN_7,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,73,46,44
-    CONTROL         "sidor och ner",IDC_ICON_ALIGN_8,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,121,46,44
-    CONTROL         "kanter",IDC_ICON_ALIGN_9,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,121,46,44
-    CONTROL         "runt om",IDC_ICON_ALIGN_10,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,121,46,44
-    CONTROL         "",IDC_ICON_ALIGN_11,"Button",BS_OWNERDRAW | BS_BOTTOM | 
-                    WS_TABSTOP,159,121,46,44
-    CONTROL         "Visa &versionsnummer",ID_DESKTOP_VERSION,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,177,91,10
-END
-
-IDD_DESKBAR_TASKBAR DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Aktivitetsfältsinställningar"
-FONT 8, "MS Sans Serif"
-BEGIN
-    CONTROL         "visa &klockan",ID_SHOW_CLOCK,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,152,52,10
-    CONTROL         "&Göm inaktiva meddelandeikoner",ID_HIDE_INACTIVE_ICONS,
-                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,174,111,10
-    PUSHBUTTON      "&Meddelanden...",ID_CONFIG_NOTIFYAREA,153,173,50,14
-END
-
-IDD_DESKBAR_STARTMENU DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Startmenyinställningar"
-FONT 8, "MS Sans Serif"
-BEGIN
-END
-
-IDD_NOTIFYAREA DIALOGEX 0, 0, 208, 174
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Inställningar för meddelandeikoner"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    CONTROL         "Tree1",IDC_NOTIFY_ICONS,"SysTreeView32",TVS_HASLINES | 
-                    TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,194,31
-    LTEXT           "&Hjälptext:",IDC_LABEL1,7,44,40,8
-    EDITTEXT        IDC_NOTIFY_TOOLTIP,58,42,143,14,ES_AUTOHSCROLL
-    LTEXT           "&Fönstertitel:",IDC_LABEL2,7,63,44,8
-    EDITTEXT        IDC_NOTIFY_TITLE,58,60,143,14,ES_AUTOHSCROLL
-    LTEXT           "&Modulsökväg:",IDC_LABEL3,7,81,43,8
-    EDITTEXT        IDC_NOTIFY_MODULE,58,78,143,14,ES_AUTOHSCROLL
-    GROUPBOX        "&Visningsläge",IDC_LABEL4,7,96,157,28
-    CONTROL         "v&isa",IDC_NOTIFY_SHOW,"Button",BS_AUTORADIOBUTTON | 
-                    WS_TABSTOP,15,108,33,10
-    CONTROL         "&dölj",IDC_NOTIFY_HIDE,"Button",BS_AUTORADIOBUTTON,66,
-                    108,29,10
-    CONTROL         "dölj a&utomatiskt",IDC_NOTIFY_AUTOHIDE,"Button",
-                    BS_AUTORADIOBUTTON,112,108,43,10
-    ICON            "",IDC_PICTURE,173,101,21,20
-    LTEXT           "&Senast ändrad:",IDC_LABEL6,7,132,43,8
-    EDITTEXT        IDC_LAST_CHANGE,59,129,105,14,ES_AUTOHSCROLL | 
-                    ES_READONLY
-    CONTROL         "visa d&olda",ID_SHOW_HIDDEN_ICONS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,154,56,10
-    DEFPUSHBUTTON   "&OK",IDOK,91,153,50,14,WS_GROUP
-    PUSHBUTTON      "&Avbryt",IDCANCEL,151,153,50,14
-END
-
-IDD_MDI_SDI DIALOGEX 0, 0, 194, 157
-STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Välj MDI / SDI Läge"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "Välj det gränssnitt du föredrar:",IDC_STATIC,7,7,160,8
-    CONTROL         "&MDI (multiple document interface)",IDC_MDI,"Button",
-                    BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,7,31,121,10
-    CONTROL         "&SDI (single document interface)",IDC_SDI,"Button",
-                    BS_AUTORADIOBUTTON,7,62,115,10
-    CONTROL         170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13
-    CONTROL         171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13
-    CONTROL         "Open Subfolders in s&eparate windows",
-                    IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,90,135,10
-    LTEXT           "Den här inställningen kommer att gälla som standard i alla nya explorer-fönster.",
-                    IDC_STATIC,7,107,174,22
-    DEFPUSHBUTTON   "&OK",IDOK,29,136,50,14,WS_GROUP
-    PUSHBUTTON      "&Avbryt",IDCANCEL,106,136,50,14
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "Reactos Explorer"
-    IDS_START               "Start"
-    IDS_LOGOFF              "Logga ut..."
-    IDS_SHUTDOWN            "Stäng av..."
-    IDS_LAUNCH              "Kör..."
-    IDS_START_HELP          "Hjälp"
-    IDS_SEARCH_FILES        "Sök..."
-    IDS_DOCUMENTS           "Dokument"
-    IDS_FAVORITES           "Favoriter"
-    IDS_PROGRAMS            "Program"
-    IDS_SETTINGS            "Inställningar"
-    IDS_EXPLORE             "Utforska"
-    IDS_EMPTY               "(tom)"
-    IDS_RECENT              "Senaste dokumenten"
-    IDS_ADMIN               "Administration"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_STARTMENU           "Startmeny"
-    IDS_MINIMIZE_ALL        "minimera alla fönster"
-    IDS_DESKTOP_NUM         "Skrivbord %d"
-    IDS_VOLUME              "Volym"
-    IDS_ITEMS_CUR           "aktuella meddelanden"
-    IDS_ITEMS_CONFIGURED    "konfiguration"
-    IDS_ITEMS_VISIBLE       "synlig"
-    IDS_ITEMS_HIDDEN        "dold"
-    IDS_NOTIFY_SHOW         "visa"
-    IDS_NOTIFY_HIDE         "dölj"
-    IDS_NOTIFY_AUTOHIDE     "dölj automatiskt"
-    IDS_SHOW_HIDDEN_ICONS   "Visa dolda ikoner"
-    IDS_HIDE_ICONS          "Dölj ikoner"
-    IDS_TERMINATE           "Avsluta Explorer"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_NETWORK             "Nätverk"
-    IDS_CONNECTIONS         "Nätverksanslutningar"
-    IDS_DRIVES              "Enheter"
-    IDS_SEARCH_COMPUTER     "Sök dator..."
-    IDS_SETTINGS_MENU       "Inställningsmeny"
-    IDS_CONTROL_PANEL       "Kontrollpanelen"
-    IDS_PRINTERS            "Skrivare"
-    IDS_BROWSE              "Utforska filer"
-    IDS_SEARCH_PRG          "Sök program..."
-    IDS_ALL_USERS           "Alla användare\\"
-    IDS_SEARCH              "Sök"
-    IDS_ABOUT_EXPLORER      "&Om Explorer..."
-    IDS_LAUNCH_MANY_PROGRAMS 
-                            "Du har valt fler än ett program.\nÄr du säker på att du vill öppna dem alla?"
-    IDS_DESKTOPBAR_SETTINGS "Skrivbordsinställningar"
-    IDS_DESKTOP             "Skrivbord"
-    IDS_TASKBAR             "Aktivitetsfält"
-END
-
-#endif    // Swedish resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/explorer-uk.rc b/reactos/subsys/system/explorer/explorer-uk.rc
deleted file mode 100644 (file)
index 482bbfe..0000000
+++ /dev/null
@@ -1,399 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include <windows.h>
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// Ukrainian resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_UKR)
-#ifdef _WIN32
-LANGUAGE LANG_UKRAINIAN, SUBLANG_DEFAULT
-#pragma code_page(1251)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_MDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Ôàéë"
-    BEGIN
-        MENUITEM "&Âèêîíàòè...",                ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "Â&èõ³ä",                      ID_FILE_EXIT
-    END
-    POPUP "&Âèãëÿä"
-    BEGIN
-        MENUITEM "&Ïàíåëü ³íñòðóìåíò³â",        ID_VIEW_TOOL_BAR
-        MENUITEM "&Äîäàòêîâà ïàíåëü",           ID_VIEW_EXTRA_BAR
-        MENUITEM "Ä&èñêè",                      ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "&Âèáðàíå",                    ID_VIEW_SIDE_BAR
-        MENUITEM "&Ðÿäîê ñòàíó",                ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Îíîâèòè\tF5",                ID_REFRESH
-        MENUITEM "Ïîâíèé &åêðàí\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-        MENUITEM "SDI",                         ID_VIEW_SDI
-    END
-    POPUP "Â&³êíà"
-    BEGIN
-        MENUITEM "&Íîâå â³êíî",                 ID_WINDOW_NEW
-        MENUITEM "&Êàñêàäîì\tShift+F5",         ID_WINDOW_CASCADE
-        MENUITEM "&Ãîðèçîíòàëüíî",              ID_WINDOW_TILE_HORZ
-        MENUITEM "&Âåðòèêàëüíî\tShift+F4",      ID_WINDOW_TILE_VERT
-        MENUITEM "Óïîðÿäêóâàòè àâòîìàòè÷íî",    ID_WINDOW_AUTOSORT
-        MENUITEM "Óïîðÿäêóâàòè &çíà÷êè",        ID_WINDOW_ARRANGE
-    END
-    POPUP "&²íñòðóìåíòè"
-    BEGIN
-        MENUITEM "&Îïö³¿",                      ID_TOOLS_OPTIONS
-    END
-    POPUP "&Äîâ³äêà"
-    BEGIN
-        MENUITEM "&FAQ(×àÏè) ïî Ïðîâ³äíèêó...", ID_EXPLORER_FAQ
-        MENUITEM "Ïðî &Ïðîâ³äíèê...",           ID_ABOUT_EXPLORER
-        MENUITEM "Ïðî &ÎÑ...",                  ID_ABOUT_WINDOWS
-    END
-END
-
-IDM_DESKTOPBAR MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&Íàñòðîéêè...",               ID_DESKTOPBAR_SETTINGS
-        MENUITEM "Ä&èñïåò÷åð çàâäàíü...",       ID_TASKMGR
-        MENUITEM SEPARATOR
-        MENUITEM "&Ïðî Ïðîâ³äíèê...",           ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_VOLUME MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "Ãó÷í³ñòü",                    ID_TRAY_VOLUME
-        MENUITEM "&Âëàñòèâîñò³ çâóêó",          ID_VOLUME_PROPERTIES
-    END
-END
-
-IDM_NOTIFYAREA MENU DISCARDABLE 
-BEGIN
-    POPUP ""
-    BEGIN
-        MENUITEM "&³äîáðàæàòè ïðèõîâàí³ çíà÷êè",  ID_SHOW_HIDDEN_ICONS
-        MENUITEM "³äîáðàæàòè çíà÷êè íà &êíîïêàõ", ID_SHOW_ICON_BUTTON
-        MENUITEM "&Í&àñòðîéêà ñïîâ³ùåíü...",       ID_CONFIG_NOTIFYAREA
-        MENUITEM "&Íàñòðîéêà äàòè é ÷àñó...",      ID_CONFIG_TIME
-        MENUITEM SEPARATOR
-        MENUITEM "&Ïðî Ïðîâ³äíèê...",              ID_ABOUT_EXPLORER
-    END
-END
-
-IDM_SDIFRAME MENU DISCARDABLE 
-BEGIN
-    POPUP "&Ôàéë"
-    BEGIN
-        MENUITEM "&Âèêîíàòè...",                ID_EXECUTE
-        MENUITEM SEPARATOR
-        MENUITEM "Â&èõ³ä",                      ID_FILE_EXIT
-    END
-    POPUP "&Âèãëÿä"
-    BEGIN
-        MENUITEM "&Ïàíåëü ³íñòðóìåíò³â",        ID_VIEW_TOOL_BAR
-        MENUITEM "&Âèáðàíå",                    ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "&Ðÿäîê ñòàíó",                ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Îíîâèòè\tF5",                ID_REFRESH
-        MENUITEM "Ïîâíèé &åêðàí\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-        MENUITEM "&MDI",                        ID_VIEW_MDI
-    END
-    POPUP "&²íñòðóìåíòè"
-    BEGIN
-        MENUITEM "&Îïö³¿",                      ID_TOOLS_OPTIONS
-    END
-    POPUP "&Äîâ³äêà"
-    BEGIN
-        MENUITEM "&FAQ(×àÏè) ïî Ïðîâ³äíèêó...", ID_EXPLORER_FAQ
-        MENUITEM "Ïðî &Ïðîâ³äíèê...",           ID_ABOUT_EXPLORER
-        MENUITEM "Ïðî &ÎÑ...",                  ID_ABOUT_WINDOWS
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_EXECUTE DIALOG DISCARDABLE  15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Âèêîíàòè"
-FONT 8, "MS Shell Dlg"
-BEGIN
-    CONTROL         "",101,"Static",SS_SIMPLE | SS_NOPREFIX,3,6,150,10
-    CONTROL         "&Êîìàíäà:",-1,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,3,
-                    18,60,10
-    EDITTEXT        201,3,29,134,12,ES_AUTOHSCROLL
-    CONTROL         "As &Symbol",214,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,3,
-                    45,71,12
-    DEFPUSHBUTTON   "&OK",1,158,6,47,14
-    PUSHBUTTON      "&Ñêàñóâàòè",2,158,23,47,14
-    PUSHBUTTON      "&Äîâ³äêà",254,158,43,47,14
-END
-
-IDD_SEARCH_PROGRAM DIALOGEX 0, 0, 200, 65
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Ïîøóê ïðîãðàìè â ìåíþ Ïóñê"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "&Ô³ëüòð:",IDC_STATIC,7,9,18,8
-    EDITTEXT        IDC_FILTER,34,7,100,14,ES_AUTOHSCROLL
-    CONTROL         "List1",IDC_PROGRAMS_FOUND,"SysListView32",LVS_REPORT | 
-                    LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | 
-                    WS_TABSTOP,7,25,186,33
-    PUSHBUTTON      "&Ïåðåâ³ðèòè",IDC_CHECK_ENTRIES,143,7,50,14
-END
-
-IDD_DESKBAR_DESKTOP DIALOG DISCARDABLE  0, 0, 212, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Âëàñòèâîñò³ ðîáî÷îãî ñòîëà"
-FONT 8, "MS Sans Serif"
-BEGIN
-    LTEXT           "Îáåð³òü íàéá³ëüø çðó÷íèé äëÿ âàñ àëãîðèòì âèð³âíþâàííÿ çíà÷ê³â:",
-                    IDC_STATIC,7,7,166,8
-    CONTROL         "left/top dwn",IDC_ICON_ALIGN_0,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,25,46,44
-    CONTROL         "left/top right",IDC_ICON_ALIGN_1,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,25,46,44
-    CONTROL         "right/top left",IDC_ICON_ALIGN_2,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,25,46,44
-    CONTROL         "rig./top dwn",IDC_ICON_ALIGN_3,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,25,46,44
-    CONTROL         "left/bot. up",IDC_ICON_ALIGN_4,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,73,46,44
-    CONTROL         "left/bot. right",IDC_ICON_ALIGN_5,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,73,46,44
-    CONTROL         "right/bot. left",IDC_ICON_ALIGN_6,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,73,46,44
-    CONTROL         "rig./bot. dwn",IDC_ICON_ALIGN_7,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,159,73,46,44
-    CONTROL         "border down",IDC_ICON_ALIGN_8,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,7,121,46,44
-    CONTROL         "border H/V",IDC_ICON_ALIGN_9,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,57,121,46,44
-    CONTROL         "round about",IDC_ICON_ALIGN_10,"Button",BS_OWNERDRAW | 
-                    BS_BOTTOM | WS_TABSTOP,110,121,46,44
-    CONTROL         "",IDC_ICON_ALIGN_11,"Button",BS_OWNERDRAW | BS_BOTTOM | 
-                    WS_TABSTOP,159,121,46,44
-    CONTROL         "³äîáðàæàòè Íîìåð &Âåðñ³¿",ID_DESKTOP_VERSION,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,177,91,10
-END
-
-IDD_DESKBAR_TASKBAR DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Âëàñòèâîñò³ ïàíåë³ çàâäàíü"
-FONT 8, "MS Sans Serif"
-BEGIN
-    CONTROL         "³äîáðà&æàòè ãîäèííèê",ID_SHOW_CLOCK,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,152,52,10
-    CONTROL         "Ïðè&õîâóâàòè íåâèêîðèñòîâóâàí³ çíà÷êè",
-                    ID_HIDE_INACTIVE_ICONS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,174,111,10
-    PUSHBUTTON      "&Ñïîâ³ùåííÿ...",ID_CONFIG_NOTIFYAREA,153,173,50,14
-END
-
-IDD_DESKBAR_STARTMENU DIALOG DISCARDABLE  0, 0, 210, 194
-STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
-CAPTION "Âëàñòèâîñò³ ìåíþ Ïóñê"
-FONT 8, "MS Sans Serif"
-BEGIN
-END
-
-IDD_NOTIFYAREA DIALOGEX 0, 0, 208, 174
-STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_VISIBLE | WS_CAPTION | 
-    WS_SYSMENU | WS_THICKFRAME
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Êîíô³ãóðàö³ÿ çíà÷ê³â ñïîâ³ùåíü"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    CONTROL         "Tree1",IDC_NOTIFY_ICONS,"SysTreeView32",TVS_HASLINES | 
-                    TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,7,7,194,31
-    LTEXT           "&Òåêñò Ï³äêàçêè:",IDC_LABEL1,7,44,40,8
-    EDITTEXT        IDC_NOTIFY_TOOLTIP,58,42,143,14,ES_AUTOHSCROLL
-    LTEXT           "Çàãîëîâîê Â&³êíà:",IDC_LABEL2,7,63,44,8
-    EDITTEXT        IDC_NOTIFY_TITLE,58,60,143,14,ES_AUTOHSCROLL
-    LTEXT           "&Øëÿõ äî Ìîäóëÿ:",IDC_LABEL3,7,81,43,8
-    EDITTEXT        IDC_NOTIFY_MODULE,58,78,143,14,ES_AUTOHSCROLL
-    GROUPBOX        "&Ðåæèì Â³äîáðàæåííÿ",IDC_LABEL4,7,96,157,28
-    CONTROL         "&ïîêàçàòè",IDC_NOTIFY_SHOW,"Button",BS_AUTORADIOBUTTON | 
-                    WS_TABSTOP,15,108,33,10
-    CONTROL         "&ñõîâàòè",IDC_NOTIFY_HIDE,"Button",BS_AUTORADIOBUTTON,66,
-                    108,29,10
-    CONTROL         "à&âòîïðèõîâàííÿ",IDC_NOTIFY_AUTOHIDE,"Button",
-                    BS_AUTORADIOBUTTON,112,108,43,10
-    ICON            "",IDC_PICTURE,173,101,21,20
-    LTEXT           "&Îñòàííÿ çì³íà:",IDC_LABEL6,7,132,43,8
-    EDITTEXT        IDC_LAST_CHANGE,59,129,105,14,ES_AUTOHSCROLL | 
-                    ES_READONLY
-    CONTROL         "ïîêà&çàòè ïðèõîâàíå",ID_SHOW_HIDDEN_ICONS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,7,154,56,10
-    DEFPUSHBUTTON   "&OK",IDOK,91,153,50,14,WS_GROUP
-    PUSHBUTTON      "&Ñêàñóâàòè",IDCANCEL,151,153,50,14
-END
-
-IDD_MDI_SDI DIALOGEX 0, 0, 194, 157
-STYLE WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
-EXSTYLE WS_EX_APPWINDOW
-CAPTION "Îáåð³òü ðåæèì â³êîí Ïðîâ³äíèêà"
-FONT 8, "MS Sans Serif", 0, 0, 0x1
-BEGIN
-    LTEXT           "Îáåð³òü íàéá³ëüø çðó÷íèé äëÿ âàñ ³íòåðôåéñ ïðîâ³äíèêà:",
-                    IDC_STATIC,7,7,160,8
-    CONTROL         "&MDI (áàãàòîäîêóìåíòíèé ³íòåðôåéñ)",IDC_MDI,"Button",
-                    BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,7,31,124,10
-    CONTROL         "&SDI (îäíîäîêóìåíòíèé ³íòåðôåéñ)",IDC_SDI,"Button",
-                    BS_AUTORADIOBUTTON,7,62,118,10
-    CONTROL         170,IDC_STATIC,"Static",SS_BITMAP,145,23,15,13
-    CONTROL         171,IDC_STATIC,"Static",SS_BITMAP,145,57,15,13
-    CONTROL         "³äêðèâàòè ï³äïàïêè â î&êðåìèõ â³êíàõ",
-                    IDC_SEPARATE_SUBFOLDERS,"Button",BS_AUTOCHECKBOX | 
-                    WS_TABSTOP,7,90,135,10
-    LTEXT           "Ö³ íàñòðîéêè áóäóòü âèêîðèñòàí³ ÿê çíà÷åííÿ çà çàìîâ÷óâàííÿì äëÿ âñ³õ â³êîí ïðîâ³äíèêà â ìàéáóòíüîìó.",
-                    IDC_STATIC,7,111,174,22
-    DEFPUSHBUTTON   "&OK",IDOK,29,136,50,14,WS_GROUP
-    PUSHBUTTON      "&Ñêàñóâàòè",IDCANCEL,106,136,50,14
-END
-
-IDD_ABOUT_EXPLORER DIALOG DISCARDABLE  0, 0, 199, 106
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Ïðî Ïðîâ³äíèê ReactOS"
-FONT 10, "MS Sans Serif"
-BEGIN
-    LTEXT           "Ïðîâ³äíèê ReactOS",IDC_ROS_EXPLORER,91,13,104,11
-    LTEXT           "V 0.9",IDC_VERSION_TXT,91,27,104,8
-    LTEXT           "(c) 2003-2005 Martin Fuchs",IDC_STATIC,91,42,104,8
-    LTEXT           "",IDC_WIN_VERSION,91,58,98,22
-    LTEXT           "http://www.sky.franken.de/explorer/",IDC_WWW,17,84,129,
-                    8
-    CONTROL         "&OK",IDOK,"Button",BS_OWNERDRAW | BS_FLAT | WS_GROUP,
-                    154,90,38,12
-END
-
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "#include <windows.h>\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "Ïðîâ³äíèê Reactos"
-    IDS_START               "Ïóñê"
-    IDS_LOGOFF              "Âèõ³ä ³ç ñèñòåìè..."
-    IDS_SHUTDOWN            "Âèìêíåííÿ..."
-    IDS_LAUNCH              "Âèêîíàòè..."
-    IDS_START_HELP          "Äîâ³äêà"
-    IDS_SEARCH_FILES        "Ïîøóê..."
-    IDS_DOCUMENTS           "Äîêóìåíòè"
-    IDS_FAVORITES           "Âèáðàíå"
-    IDS_PROGRAMS            "Ïðîãðàìè"
-    IDS_SETTINGS            "Íàñòðîéêè"
-    IDS_EXPLORE             "Îãëÿä"
-    IDS_EMPTY               "(Ïîðîæíüî)"
-    IDS_RECENT              "Íåäàâí³ äîêóìåíòè"
-    IDS_ADMIN               "Àäì³í³ñòðóâàííÿ"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_STARTMENU           "Ìåíþ Ïóñê"
-    IDS_MINIMIZE_ALL        "çãîðíóòè âñ³ â³êíà"
-    IDS_DESKTOP_NUM         "Ðîáî÷èé Ñò³ë %d"
-    IDS_VOLUME              "Ãó÷í³ñòü"
-    IDS_ITEMS_CUR           "ïîòî÷í³ åëåìåíòè"
-    IDS_ITEMS_CONFIGURED    "êîíô³ãóðàö³ÿ"
-    IDS_ITEMS_VISIBLE       "âèäèìèé"
-    IDS_ITEMS_HIDDEN        "ïðèõîâàíèé"
-    IDS_NOTIFY_SHOW         "ïîêàçàòè"
-    IDS_NOTIFY_HIDE         "ñõîâàòè"
-    IDS_NOTIFY_AUTOHIDE     "àâòîïðèõîâàííÿ"
-    IDS_SHOW_HIDDEN_ICONS   "Ïîêàçàòè ïðèõîâàí³ çíà÷êè"
-    IDS_HIDE_ICONS          "Ñõîâàòè çíà÷êè"
-    IDS_TERMINATE           "Çàâåðøèòè ðîáîòó Ïðîâ³äíèêà"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_NETWORK             "Ìåðåæà"
-    IDS_CONNECTIONS         "Ìåðåæí³ ï³äêëþ÷åííÿ"
-    IDS_DRIVES              "Äèñêè"
-    IDS_SEARCH_COMPUTER     "Ïîøóê êîìï\92þòåðà..."
-    IDS_SETTINGS_MENU       "Ìåíþ Íàñòðîéêà"
-    IDS_CONTROL_PANEL       "Ïàíåëü êåðóâàííÿ"
-    IDS_PRINTERS            "Ïðèíòåðè"
-    IDS_BROWSE              "Îãëÿä ôàéë³â"
-    IDS_SEARCH_PRG          "Ïîøóê ïðîãðàìè..."
-    IDS_ALL_USERS           "Âñ³ êîðèñòóâà÷³\\"
-    IDS_SEARCH              "Ïîøóê"
-    IDS_ABOUT_EXPLORER      "&Ïðî Ïðîâ³äíèê..."
-    IDS_LAUNCH_MANY_PROGRAMS 
-                            "Âè îáðàëè á³ëüøå îäí³º¿ ïðîãðàìè.\nÂè âïåâíåí³, ùî õî÷åòå çàïóñòèòè ¿õ âñ³?"
-    IDS_DESKTOPBAR_SETTINGS "Íàñòðîéêè ðîáî÷îãî ñòîëà"
-    IDS_DESKTOP             "Ðîáî÷èé Ñò³ë"
-    IDS_TASKBAR             "Ïàíåëü çàâäàíü"
-END
-
-#endif    // Ukrainian resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/explorer.cpp b/reactos/subsys/system/explorer/explorer.cpp
deleted file mode 100644 (file)
index eb386be..0000000
+++ /dev/null
@@ -1,1150 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // explorer.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
- // Credits: Thanks to Leon Finker for his explorer cabinet window example
- //
-
-
-#include <precomp.h>   // <precomp.h> instead of "precomp.h" because the ROS build system needs this to find the precompiled header file (*.gch) in the output directory tree
-
-#include "resource.h"
-
-#include <locale.h>    // for setlocale()
-
-#ifndef __WINE__
-#include <io.h>                // for dup2()
-#include <fcntl.h>     // for _O_RDONLY
-#endif
-
-#include "dialogs/settings.h"  // for MdiSdiDlg
-
-#include "services/shellservices.h"
-
-
-extern "C" int initialize_gdb_stub();  // start up GDB stub
-
-
-DynamicLoadLibFct<void(__stdcall*)(BOOL)> g_SHDOCVW_ShellDDEInit(TEXT("SHDOCVW"), 118);
-
-
-ExplorerGlobals g_Globals;
-
-
-ExplorerGlobals::ExplorerGlobals()
-{
-       _hInstance = 0;
-       _cfStrFName = 0;
-
-#ifndef ROSSHELL
-       _hframeClass = 0;
-       _hMainWnd = 0;
-       _desktop_mode = false;
-       _prescan_nodes = false;
-#endif
-
-       _log = NULL;
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       _SHRestricted = 0;
-#endif
-       _hwndDesktopBar = 0;
-       _hwndShellView = 0;
-       _hwndDesktop = 0;
-}
-
-
-void ExplorerGlobals::init(HINSTANCE hInstance)
-{
-       _hInstance = hInstance;
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       _SHRestricted = (DWORD(STDAPICALLTYPE*)(RESTRICTIONS)) GetProcAddress(GetModuleHandle(TEXT("SHELL32")), "SHRestricted");
-#endif
-
-       _icon_cache.init();
-}
-
-
-void ExplorerGlobals::read_persistent()
-{
-        // read configuration file
-       _cfg_dir.printf(TEXT("%s\\ReactOS"), (LPCTSTR)SpecialFolderFSPath(CSIDL_APPDATA,0));
-       _cfg_path.printf(TEXT("%s\\ros-explorer-cfg.xml"), _cfg_dir.c_str());
-
-       if (!_cfg.read(_cfg_path)) {
-               if (_cfg._last_error != XML_ERROR_NO_ELEMENTS)
-                       MessageBox(g_Globals._hwndDesktop, String(_cfg._last_error_msg.c_str()),
-                                               TEXT("ROS Explorer - reading user settings"), MB_OK);
-
-               _cfg.read(TEXT("explorer-cfg-template.xml"));
-       }
-
-        // read bookmarks
-       _favorites_path.printf(TEXT("%s\\ros-explorer-bookmarks.xml"), _cfg_dir.c_str());
-
-       if (!_favorites.read(_favorites_path)) {
-               _favorites.import_IE_favorites(0);
-               _favorites.write(_favorites_path);
-       }
-}
-
-void ExplorerGlobals::write_persistent()
-{
-        // write configuration file
-       RecursiveCreateDirectory(_cfg_dir);
-
-       _cfg.write(_cfg_path);
-       _favorites.write(_favorites_path);
-}
-
-
-XMLPos ExplorerGlobals::get_cfg()
-{
-       XMLPos cfg_pos(&_cfg);
-
-       cfg_pos.smart_create("explorer-cfg");
-
-       return cfg_pos;
-}
-
-XMLPos ExplorerGlobals::get_cfg(const char* path)
-{
-       XMLPos cfg_pos(&_cfg);
-
-       cfg_pos.smart_create("explorer-cfg");
-       cfg_pos.create_relative(path);
-
-       return cfg_pos;
-}
-
-
-void _log_(LPCTSTR txt)
-{
-       FmtString msg(TEXT("%s\n"), txt);
-
-       if (g_Globals._log)
-               _fputts(msg, g_Globals._log);
-
-       OutputDebugString(msg);
-}
-
-
-bool FileTypeManager::is_exe_file(LPCTSTR ext)
-{
-       static const LPCTSTR s_executable_extensions[] = {
-               TEXT("COM"),
-               TEXT("EXE"),
-               TEXT("BAT"),
-               TEXT("CMD"),
-               TEXT("CMM"),
-               TEXT("BTM"),
-               TEXT("AWK"),
-               0
-       };
-
-       TCHAR ext_buffer[_MAX_EXT];
-       const LPCTSTR* p;
-       LPCTSTR s;
-       LPTSTR d;
-
-       for(s=ext+1,d=ext_buffer; (*d=toupper(*s)); s++)
-               ++d;
-
-       for(p=s_executable_extensions; *p; p++)
-               if (!lstrcmp(ext_buffer, *p))
-                       return true;
-
-       return false;
-}
-
-
-const FileTypeInfo& FileTypeManager::operator[](String ext)
-{
-       ext.toLower();
-
-       iterator found = find(ext);
-       if (found != end())
-               return found->second;
-
-       FileTypeInfo& ftype = super::operator[](ext);
-
-       ftype._neverShowExt = false;
-
-       HKEY hkey;
-       TCHAR value[MAX_PATH], display_name[MAX_PATH];
-       LONG valuelen = sizeof(value);
-
-       if (!RegQueryValue(HKEY_CLASSES_ROOT, ext, value, &valuelen)) {
-               ftype._classname = value;
-
-               valuelen = sizeof(display_name);
-               if (!RegQueryValue(HKEY_CLASSES_ROOT, ftype._classname, display_name, &valuelen))
-                       ftype._displayname = display_name;
-
-               if (!RegOpenKey(HKEY_CLASSES_ROOT, ftype._classname, &hkey)) {
-                       if (!RegQueryValueEx(hkey, TEXT("NeverShowExt"), 0, NULL, NULL, NULL))
-                               ftype._neverShowExt = true;
-
-                       RegCloseKey(hkey);
-               }
-       }
-
-       return ftype;
-}
-
-LPCTSTR FileTypeManager::set_type(Entry* entry, bool dont_hide_ext)
-{
-       LPCTSTR ext = _tcsrchr(entry->_data.cFileName, TEXT('.'));
-
-       if (ext) {
-               const FileTypeInfo& type = (*this)[ext];
-
-               if (!type._displayname.empty())
-                       entry->_type_name = _tcsdup(type._displayname);
-
-                // hide some file extensions
-               if (type._neverShowExt && !dont_hide_ext) {
-                       int len = ext - entry->_data.cFileName;
-                       entry->_display_name = (LPTSTR) malloc((len+1)*sizeof(TCHAR));
-                       lstrcpyn(entry->_display_name, entry->_data.cFileName, len + 1);
-               }
-
-               if (is_exe_file(ext))
-                       entry->_data.dwFileAttributes |= ATTRIBUTE_EXECUTABLE;
-       }
-
-       return ext;
-}
-
-
-Icon::Icon()
- :     _id(ICID_UNKNOWN),
-       _itype(IT_STATIC),
-       _hicon(0)
-{
-}
-
-Icon::Icon(ICON_ID id, UINT nid)       //, int cx, int cy
- :     _id(id),
-       _itype(IT_STATIC),
-       _hicon(ResIcon(nid))    // ResIconEx(nid, cx, cy)
-{
-}
-
-Icon::Icon(ICON_ID id, UINT nid, int icon_size)
- :     _id(id),
-       _itype(IT_STATIC),
-       _hicon(ResIconEx(nid, icon_size, icon_size))
-{
-}
-
-Icon::Icon(ICON_TYPE itype, int id, HICON hIcon)
- :     _id((ICON_ID)id),
-       _itype(itype),
-       _hicon(hIcon)
-{
-}
-
-Icon::Icon(ICON_TYPE itype, int id, int sys_idx)
- :     _id((ICON_ID)id),
-       _itype(itype),
-       _sys_idx(sys_idx)
-{
-}
-
-void Icon::draw(HDC hdc, int x, int y, int cx, int cy, COLORREF bk_color, HBRUSH bk_brush) const
-{
-       if (_itype == IT_SYSCACHE)
-               ImageList_DrawEx(g_Globals._icon_cache.get_sys_imagelist(), _sys_idx, hdc, x, y, cx, cy, bk_color, CLR_DEFAULT, ILD_NORMAL);
-       else
-               DrawIconEx(hdc, x, y, _hicon, cx, cy, 0, bk_brush, DI_NORMAL);
-}
-
-HBITMAP        Icon::create_bitmap(COLORREF bk_color, HBRUSH hbrBkgnd, HDC hdc_wnd) const
-{
-       if (_itype == IT_SYSCACHE) {
-               HIMAGELIST himl = g_Globals._icon_cache.get_sys_imagelist();
-
-               int cx, cy;
-               ImageList_GetIconSize(himl, &cx, &cy);
-
-               HBITMAP hbmp = CreateCompatibleBitmap(hdc_wnd, cx, cy);
-               HDC hdc = CreateCompatibleDC(hdc_wnd);
-               HBITMAP hbmp_old = SelectBitmap(hdc, hbmp);
-               ImageList_DrawEx(himl, _sys_idx, hdc, 0, 0, cx, cy, bk_color, CLR_DEFAULT, ILD_NORMAL);
-               SelectBitmap(hdc, hbmp_old);
-               DeleteDC(hdc);
-
-               return hbmp;
-       } else
-               return create_bitmap_from_icon(_hicon, hbrBkgnd, hdc_wnd);
-}
-
-
-int Icon::add_to_imagelist(HIMAGELIST himl, HDC hdc_wnd, COLORREF bk_color, HBRUSH bk_brush) const
-{
-       int ret;
-
-       if (_itype == IT_SYSCACHE) {
-               HIMAGELIST himl = g_Globals._icon_cache.get_sys_imagelist();
-
-               int cx, cy;
-               ImageList_GetIconSize(himl, &cx, &cy);
-
-               HBITMAP hbmp = CreateCompatibleBitmap(hdc_wnd, cx, cy);
-               HDC hdc = CreateCompatibleDC(hdc_wnd);
-               HBITMAP hbmp_old = SelectBitmap(hdc, hbmp);
-               ImageList_DrawEx(himl, _sys_idx, hdc, 0, 0, cx, cy, bk_color, CLR_DEFAULT, ILD_NORMAL);
-               SelectBitmap(hdc, hbmp_old);
-               DeleteDC(hdc);
-
-               ret = ImageList_Add(himl, hbmp, 0);
-
-               DeleteObject(hbmp);
-       } else
-               ret = ImageList_AddAlphaIcon(himl, _hicon, bk_brush, hdc_wnd);
-
-       return ret;
-}
-
-HBITMAP create_bitmap_from_icon(HICON hIcon, HBRUSH hbrush_bkgnd, HDC hdc_wnd/*, int icon_size*/)
-{
-       int cx = ICON_SIZE_SMALL;
-       int cy = ICON_SIZE_SMALL;
-       HBITMAP hbmp = CreateCompatibleBitmap(hdc_wnd, cx, cy);
-
-       MemCanvas canvas;
-       BitmapSelection sel(canvas, hbmp);
-
-       RECT rect = {0, 0, cx, cy};
-       FillRect(canvas, &rect, hbrush_bkgnd);
-
-       DrawIconEx(canvas, 0, 0, hIcon, cx, cy, 0, hbrush_bkgnd, DI_NORMAL);
-
-       return hbmp;
-}
-
-HBITMAP create_small_bitmap_from_icon(HICON hIcon, HBRUSH hbrush_bkgnd, HDC hdc_wnd)
-{
-       int cx = GetSystemMetrics(SM_CXSMICON);
-       int cy = GetSystemMetrics(SM_CYSMICON);
-       HBITMAP hbmp = CreateCompatibleBitmap(hdc_wnd, cx, cy);
-
-       MemCanvas canvas;
-       BitmapSelection sel(canvas, hbmp);
-
-       RECT rect = {0, 0, cx, cy};
-       FillRect(canvas, &rect, hbrush_bkgnd);
-
-       DrawIconEx(canvas, 0, 0, hIcon, cx, cy, 0, hbrush_bkgnd, DI_NORMAL);
-
-       return hbmp;
-}
-
-int ImageList_AddAlphaIcon(HIMAGELIST himl, HICON hIcon, HBRUSH hbrush_bkgnd, HDC hdc_wnd)
-{
-       HBITMAP hbmp = create_bitmap_from_icon(hIcon, hbrush_bkgnd, hdc_wnd);
-
-       int ret = ImageList_Add(himl, hbmp, 0);
-
-       DeleteObject(hbmp);
-
-       return ret;
-}
-
-
-int IconCache::s_next_id = ICID_DYNAMIC;
-
-
-void IconCache::init()
-{
-       int icon_size = STARTMENUROOT_ICON_SIZE;
-
-       _icons[ICID_NONE]               = Icon(IT_STATIC, ICID_NONE, (HICON)0);
-
-       _icons[ICID_FOLDER]             = Icon(ICID_FOLDER,             IDI_FOLDER);
-       //_icons[ICID_DOCUMENT] = Icon(ICID_DOCUMENT,   IDI_DOCUMENT);
-       _icons[ICID_EXPLORER]   = Icon(ICID_EXPLORER,   IDI_EXPLORER);
-//     _icons[ICID_APP]                = Icon(ICID_APP,                IDI_APPICON);
-
-       _icons[ICID_CONFIG]             = Icon(ICID_CONFIG,             IDI_CONFIG,             icon_size);
-       _icons[ICID_DOCUMENTS]  = Icon(ICID_DOCUMENTS,  IDI_DOCUMENTS,  icon_size);
-       _icons[ICID_FAVORITES]  = Icon(ICID_FAVORITES,  IDI_FAVORITES,  icon_size);
-       _icons[ICID_INFO]               = Icon(ICID_INFO,               IDI_INFO,               icon_size);
-       _icons[ICID_APPS]               = Icon(ICID_APPS,               IDI_APPS,               icon_size);
-       _icons[ICID_SEARCH]     = Icon(ICID_SEARCH,     IDI_SEARCH,             icon_size);
-       _icons[ICID_ACTION]     = Icon(ICID_ACTION,     IDI_ACTION,             icon_size);
-       _icons[ICID_SEARCH_DOC] = Icon(ICID_SEARCH_DOC, IDI_SEARCH_DOC, icon_size);
-       _icons[ICID_PRINTER]    = Icon(ICID_PRINTER,    IDI_PRINTER,    icon_size);
-       _icons[ICID_NETWORK]    = Icon(ICID_NETWORK,    IDI_NETWORK,    icon_size);
-       _icons[ICID_COMPUTER]   = Icon(ICID_COMPUTER,   IDI_COMPUTER,   icon_size);
-       _icons[ICID_LOGOFF]     = Icon(ICID_LOGOFF,     IDI_LOGOFF,             icon_size);
-       _icons[ICID_SHUTDOWN]   = Icon(ICID_SHUTDOWN,   IDI_SHUTDOWN,   icon_size);
-       _icons[ICID_BOOKMARK]   = Icon(ICID_BOOKMARK,   IDI_DOT_TRANS,  icon_size);
-       _icons[ICID_MINIMIZE]   = Icon(ICID_MINIMIZE,   IDI_MINIMIZE,   icon_size);
-       _icons[ICID_CONTROLPAN] = Icon(ICID_CONTROLPAN, IDI_CONTROLPAN, icon_size);
-       _icons[ICID_DESKSETTING]= Icon(ICID_DESKSETTING,IDI_DESKSETTING,icon_size);
-       _icons[ICID_NETCONNS]   = Icon(ICID_NETCONNS,   IDI_NETCONNS,   icon_size);
-       _icons[ICID_ADMIN]              = Icon(ICID_ADMIN,              IDI_ADMIN,              icon_size);
-       _icons[ICID_RECENT]     = Icon(ICID_RECENT,     IDI_RECENT,             icon_size);
-}
-
-
-const Icon& IconCache::extract(LPCTSTR path, ICONCACHE_FLAGS flags)
-{
-        // search for matching icon with unchanged flags in the cache
-       CacheKey mapkey(path, flags);
-       PathCacheMap::iterator found = _pathCache.find(mapkey);
-
-       if (found != _pathCache.end())
-               return _icons[found->second];
-
-        // search for matching icon with handle
-       CacheKey mapkey_hicon(path, flags|ICF_HICON);
-       if (flags != mapkey_hicon.second) {
-               found = _pathCache.find(mapkey_hicon);
-
-               if (found != _pathCache.end())
-                       return _icons[found->second];
-       }
-
-        // search for matching icon in the system image list cache
-       CacheKey mapkey_syscache(path, flags|ICF_SYSCACHE);
-       if (flags != mapkey_syscache.second) {
-               found = _pathCache.find(mapkey_syscache);
-
-               if (found != _pathCache.end())
-                       return _icons[found->second];
-       }
-
-       SHFILEINFO sfi;
-
-       int shgfi_flags = 0;
-
-       if (flags & ICF_OPEN)
-               shgfi_flags |= SHGFI_OPENICON;
-
-       if ((flags&(ICF_LARGE|ICF_MIDDLE|ICF_OVERLAYS|ICF_HICON)) && !(flags&ICF_SYSCACHE)) {
-               shgfi_flags |= SHGFI_ICON;
-
-               if (!(flags & (ICF_LARGE|ICF_MIDDLE)))
-                       shgfi_flags |= SHGFI_SMALLICON;
-
-               if (flags & ICF_OVERLAYS)
-                       shgfi_flags |= SHGFI_ADDOVERLAYS;
-
-                // get small/big icons with/without overlays
-               if (SHGetFileInfo(path, 0, &sfi, sizeof(sfi), shgfi_flags)) {
-                       const Icon& icon = add(sfi.hIcon, IT_CACHED);
-
-                       ///@todo limit cache size
-                       _pathCache[mapkey_hicon] = icon;
-
-                       return icon;
-               }
-       } else {
-               assert(!(flags&ICF_OVERLAYS));
-
-               shgfi_flags |= SHGFI_SYSICONINDEX|SHGFI_SMALLICON;
-
-                // use system image list - the "search program dialog" needs it
-               HIMAGELIST himlSys_small = (HIMAGELIST) SHGetFileInfo(path, 0, &sfi, sizeof(sfi), shgfi_flags);
-
-               if (himlSys_small) {
-                       _himlSys_small = himlSys_small;
-
-                       const Icon& icon = add(sfi.iIcon/*, IT_SYSCACHE*/);
-
-                       ///@todo limit cache size
-                       _pathCache[mapkey_syscache] = icon;
-
-                       return icon;
-               }
-       }
-
-       return _icons[ICID_NONE];
-}
-
-const Icon& IconCache::extract(LPCTSTR path, int icon_idx, ICONCACHE_FLAGS flags)
-{
-       IdxCacheKey key(path, make_pair(icon_idx, (flags|ICF_HICON)&~ICF_SYSCACHE));
-
-       key.first.toLower();
-
-       IdxCacheMap::iterator found = _idxCache.find(key);
-
-       if (found != _idxCache.end())
-               return _icons[found->second];
-
-       HICON hIcon;
-
-       if ((int)ExtractIconEx(path, icon_idx, NULL, &hIcon, 1) > 0) {
-               const Icon& icon = add(hIcon, IT_CACHED);
-
-               _idxCache[key] = icon;
-
-               return icon;
-       } else {
-
-               ///@todo retreive "http://.../favicon.ico" format icons
-
-               return _icons[ICID_NONE];
-       }
-}
-
-const Icon& IconCache::extract(IExtractIcon* pExtract, LPCTSTR path, int icon_idx, ICONCACHE_FLAGS flags)
-{
-       HICON hIconLarge = 0;
-       HICON hIcon;
-
-       int icon_size = ICON_SIZE_FROM_ICF(flags);
-       HRESULT hr = pExtract->Extract(path, icon_idx, &hIconLarge, &hIcon, MAKELONG(GetSystemMetrics(SM_CXICON), icon_size));
-
-       if (hr == NOERROR) {    //@@ oder SUCCEEDED(hr) ?
-               if (icon_size > ICON_SIZE_SMALL) {      //@@ OK?
-                       if (hIcon)
-                               DestroyIcon(hIcon);
-
-                       hIcon = hIconLarge;
-               } else {
-                       if (hIconLarge)
-                               DestroyIcon(hIconLarge);
-               }
-
-               if (hIcon)
-                       return add(hIcon);      //@@ When do we want not to free this icons?
-       }
-
-       return _icons[ICID_NONE];
-}
-
-const Icon& IconCache::add(HICON hIcon, ICON_TYPE type)
-{
-       int id = ++s_next_id;
-
-       return _icons[id] = Icon(type, id, hIcon);
-}
-
-const Icon&    IconCache::add(int sys_idx/*, ICON_TYPE type=IT_SYSCACHE*/)
-{
-       int id = ++s_next_id;
-
-       return _icons[id] = SysCacheIcon(id, sys_idx);
-}
-
-const Icon& IconCache::get_icon(int id)
-{
-       return _icons[id];
-}
-
-void IconCache::free_icon(int icon_id)
-{
-       IconMap::iterator found = _icons.find(icon_id);
-
-       if (found != _icons.end()) {
-               Icon& icon = found->second;
-
-               if (icon.destroy())
-                       _icons.erase(found);
-       }
-}
-
-
-ResString::ResString(UINT nid)
-{
-       TCHAR buffer[BUFFER_LEN];
-
-       int len = LoadString(g_Globals._hInstance, nid, buffer, sizeof(buffer)/sizeof(TCHAR));
-
-       super::assign(buffer, len);
-}
-
-
-ResIcon::ResIcon(UINT nid)
-{
-       _hicon = LoadIcon(g_Globals._hInstance, MAKEINTRESOURCE(nid));
-}
-
-SmallIcon::SmallIcon(UINT nid)
-{
-       _hicon = (HICON)LoadImage(g_Globals._hInstance, MAKEINTRESOURCE(nid), IMAGE_ICON, GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), LR_SHARED);
-}
-
-ResIconEx::ResIconEx(UINT nid, int w, int h)
-{
-       _hicon = (HICON)LoadImage(g_Globals._hInstance, MAKEINTRESOURCE(nid), IMAGE_ICON, w, h, LR_SHARED);
-}
-
-
-void SetWindowIcon(HWND hwnd, UINT nid)
-{
-       HICON hIcon = ResIcon(nid);
-       (void)Window_SetIcon(hwnd, ICON_BIG, hIcon);
-
-       HICON hIconSmall = SmallIcon(nid);
-       (void)Window_SetIcon(hwnd, ICON_SMALL, hIconSmall);
-}
-
-
-ResBitmap::ResBitmap(UINT nid)
-{
-       _hBmp = LoadBitmap(g_Globals._hInstance, MAKEINTRESOURCE(nid));
-}
-
-
-#ifndef ROSSHELL
-
-void explorer_show_frame(int cmdShow, LPTSTR lpCmdLine)
-{
-       ExplorerCmd cmd;
-
-       if (g_Globals._hMainWnd) {
-               if (IsIconic(g_Globals._hMainWnd))
-                       ShowWindow(g_Globals._hMainWnd, SW_RESTORE);
-               else
-                       SetForegroundWindow(g_Globals._hMainWnd);
-
-               return;
-       }
-
-       g_Globals._prescan_nodes = false;
-
-       XMLPos explorer_options = g_Globals.get_cfg("general/explorer");
-       XS_String mdiStr = XMLString(explorer_options, "mdi");
-
-        // If there isn't yet the "mdi" setting in the configuration, display MDI/SDI dialog.
-       if (mdiStr.empty())
-               Dialog::DoModal(IDD_MDI_SDI, WINDOW_CREATOR(MdiSdiDlg), g_Globals._hwndDesktop);
-
-        // Now read the MDI attribute again and interpret it as boolean value.
-       cmd._mdi = XMLBool(explorer_options, "mdi", true);
-
-       cmd._cmdShow = cmdShow;
-
-        // parse command line options, which may overwrite the MDI flag
-       if (lpCmdLine)
-               cmd.ParseCmdLine(lpCmdLine);
-
-        // create main window
-       MainFrameBase::Create(cmd);
-}
-
-bool ExplorerCmd::ParseCmdLine(LPCTSTR lpCmdLine)
-{
-       bool ok = true;
-
-       LPCTSTR b = lpCmdLine;
-       LPCTSTR p = b;
-
-       while(*b) {
-                // remove leading space
-               while(_istspace((unsigned)*b))
-                       ++b;
-
-               p = b;
-
-               bool quote = false;
-
-                // options are separated by ','
-               for(; *p; ++p) {
-                       if (*p == '"')  // Quote characters may appear at any position in the command line.
-                               quote = !quote;
-                       else if (*p==',' && !quote)
-                               break;
-               }
-
-               if (p > b) {
-                       int l = p - b;
-
-                        // remove trailing space
-                       while(l>0 && _istspace((unsigned)b[l-1]))
-                               --l;
-
-                       if (!EvaluateOption(String(b, l)))
-                               ok = false;
-
-                       if (*p)
-                               ++p;
-
-                       b = p;
-               }
-       }
-
-       return ok;
-}
-
-bool ExplorerCmd::EvaluateOption(LPCTSTR option)
-{
-       String opt_str;
-
-        // Remove quote characters, as they are evaluated at this point.
-       for(; *option; ++option)
-               if (*option != '"')
-                       opt_str += *option;
-
-       option = opt_str;
-
-       if (option[0] == '/') {
-               ++option;
-
-                // option /e for windows in explorer mode
-               if (!_tcsicmp(option, TEXT("e")))
-                       _flags |= OWM_EXPLORE;
-                // option /root for rooted explorer windows
-               else if (!_tcsicmp(option, TEXT("root")))
-                       _flags |= OWM_ROOTED;
-                // non-standard options: /mdi, /sdi
-               else if (!_tcsicmp(option, TEXT("mdi")))
-                       _mdi = true;
-               else if (!_tcsicmp(option, TEXT("sdi")))
-                       _mdi = false;
-               else
-                       return false;
-       } else {
-               if (!_path.empty())
-                       return false;
-
-               _path = opt_str;
-       }
-
-       return true;
-}
-
-bool ExplorerCmd::IsValidPath() const
-{
-       if (!_path.empty()) {
-               DWORD attribs = GetFileAttributes(_path);
-
-               if (attribs!=INVALID_FILE_ATTRIBUTES && (attribs&FILE_ATTRIBUTE_DIRECTORY))
-                       return true;    // file system path
-               else if (*_path==':' && _path.at(1)==':')
-                       return true;    // text encoded IDL
-       }
-
-       return false;
-}
-
-#else
-
-void explorer_show_frame(int cmdShow, LPTSTR lpCmdLine)
-{
-       if (!lpCmdLine)
-               lpCmdLine = TEXT("explorer.exe");
-
-       launch_file(GetDesktopWindow(), lpCmdLine, cmdShow);
-}
-
-#endif
-
-
-PopupMenu::PopupMenu(UINT nid)
-{
-       HMENU hMenu = LoadMenu(g_Globals._hInstance, MAKEINTRESOURCE(nid));
-       _hmenu = GetSubMenu(hMenu, 0);
-}
-
-
- /// "About Explorer" Dialog
-struct ExplorerAboutDlg : public
-                       CtlColorParent<
-                               OwnerDrawParent<Dialog>
-                       >
-{
-       typedef CtlColorParent<
-                               OwnerDrawParent<Dialog>
-                       > super;
-
-       ExplorerAboutDlg(HWND hwnd)
-        :      super(hwnd)
-       {
-               SetWindowIcon(hwnd, IDI_REACTOS);
-
-               new FlatButton(hwnd, IDOK);
-
-               _hfont = CreateFont(20, 0, 0, 0, FW_BOLD, TRUE, 0, 0, 0, 0, 0, 0, 0, TEXT("Sans Serif"));
-               new ColorStatic(hwnd, IDC_ROS_EXPLORER, RGB(32,32,128), 0, _hfont);
-
-               new HyperlinkCtrl(hwnd, IDC_WWW);
-
-               FmtString ver_txt(ResString(IDS_EXPLORER_VERSION_STR), (LPCTSTR)ResString(IDS_VERSION_STR));
-               SetWindowText(GetDlgItem(hwnd, IDC_VERSION_TXT), ver_txt);
-
-               HWND hwnd_winver = GetDlgItem(hwnd, IDC_WIN_VERSION);
-               SetWindowText(hwnd_winver, get_windows_version_str());
-               SetWindowFont(hwnd_winver, GetStockFont(DEFAULT_GUI_FONT), FALSE);
-
-               CenterWindow(hwnd);
-       }
-
-       ~ExplorerAboutDlg()
-       {
-               DeleteObject(_hfont);
-       }
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               switch(nmsg) {
-                 case WM_PAINT:
-                       Paint();
-                       break;
-
-                 default:
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-
-               return 0;
-       }
-
-       void Paint()
-       {
-               PaintCanvas canvas(_hwnd);
-
-               HICON hicon = (HICON) LoadImage(g_Globals._hInstance, MAKEINTRESOURCE(IDI_REACTOS_BIG), IMAGE_ICON, 0, 0, LR_SHARED);
-
-               DrawIconEx(canvas, 20, 10, hicon, 0, 0, 0, 0, DI_NORMAL);
-       }
-
-protected:
-       HFONT   _hfont;
-};
-
-void explorer_about(HWND hwndParent)
-{
-       Dialog::DoModal(IDD_ABOUT_EXPLORER, WINDOW_CREATOR(ExplorerAboutDlg), hwndParent);
-}
-
-
-static void InitInstance(HINSTANCE hInstance)
-{
-       CONTEXT("InitInstance");
-
-       setlocale(LC_COLLATE, "");      // set collating rules to local settings for compareName
-
-#ifndef ROSSHELL
-        // register frame window class
-       g_Globals._hframeClass = IconWindowClass(CLASSNAME_FRAME,IDI_EXPLORER);
-
-        // register child window class
-       WindowClass(CLASSNAME_CHILDWND, CS_CLASSDC|CS_DBLCLKS|CS_VREDRAW).Register();
-
-        // register tree window class
-       WindowClass(CLASSNAME_WINEFILETREE, CS_CLASSDC|CS_DBLCLKS|CS_VREDRAW).Register();
-#endif
-
-       g_Globals._cfStrFName = RegisterClipboardFormat(CFSTR_FILENAME);
-}
-
-
-int explorer_main(HINSTANCE hInstance, LPTSTR lpCmdLine, int cmdShow)
-{
-       CONTEXT("explorer_main");
-
-        // initialize Common Controls library
-       CommonControlInit usingCmnCtrl;
-
-       try {
-               InitInstance(hInstance);
-       } catch(COMException& e) {
-               HandleException(e, GetDesktopWindow());
-               return -1;
-       }
-
-#ifndef ROSSHELL
-       if (cmdShow != SW_HIDE) {
-/*     // don't maximize if being called from the ROS desktop
-               if (cmdShow == SW_SHOWNORMAL)
-                               ///@todo read window placement from registry
-                       cmdShow = SW_MAXIMIZE;
-*/
-
-               explorer_show_frame(cmdShow, lpCmdLine);
-       }
-#endif
-
-       return Window::MessageLoop();
-}
-
-
- // MinGW does not provide a Unicode startup routine, so we have to implement an own.
-#if defined(__MINGW32__) && defined(UNICODE)
-
-#define _tWinMain wWinMain
-int WINAPI wWinMain(HINSTANCE, HINSTANCE, LPWSTR, int);
-
-int main(int argc, char* argv[])
-{
-       CONTEXT("main");
-
-       STARTUPINFO startupinfo;
-       int nShowCmd = SW_SHOWNORMAL;
-
-       GetStartupInfo(&startupinfo);
-
-       if (startupinfo.dwFlags & STARTF_USESHOWWINDOW)
-               nShowCmd = startupinfo.wShowWindow;
-
-       LPWSTR cmdline = GetCommandLineW();
-
-       while(*cmdline && !_istspace((unsigned)*cmdline))
-               ++cmdline;
-
-       while(_istspace((unsigned)*cmdline))
-               ++cmdline;
-
-       return wWinMain(GetModuleHandle(NULL), 0, cmdline, nShowCmd);
-}
-
-#endif // __MINGW && UNICODE
-
-
-static bool SetShellReadyEvent(LPCTSTR evtName)
-{
-       HANDLE hEvent = OpenEvent(EVENT_MODIFY_STATE, FALSE, evtName);
-       if (!hEvent)
-               return false;
-
-       SetEvent(hEvent);
-       CloseHandle(hEvent);
-
-       return true;
-}
-
-
-int WINAPI _tWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPTSTR lpCmdLine, int nShowCmd)
-{
-       CONTEXT("WinMain()");
-
-       BOOL any_desktop_running = IsAnyDesktopRunning();
-
-       BOOL startup_desktop;
-
-        // strip extended options from the front of the command line
-       String ext_options;
-
-       while(*lpCmdLine == '-') {
-               while(*lpCmdLine && !_istspace((unsigned)*lpCmdLine))
-                       ext_options += *lpCmdLine++;
-
-               while(_istspace((unsigned)*lpCmdLine))
-                       ++lpCmdLine;
-       }
-
-        // command line option "-install" to replace previous shell application with ROS Explorer
-       if (_tcsstr(ext_options,TEXT("-install"))) {
-                // install ROS Explorer into the registry
-               TCHAR path[MAX_PATH];
-
-               int l = GetModuleFileName(0, path, COUNTOF(path));
-               if (l) {
-                       HKEY hkey;
-
-                       if (!RegOpenKey(HKEY_LOCAL_MACHINE, TEXT("SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Winlogon"), &hkey)) {
-
-                               ///@todo save previous shell application in config file
-
-                               RegSetValueEx(hkey, TEXT("Shell"), 0, REG_SZ, (LPBYTE)path, l*sizeof(TCHAR));
-                               RegCloseKey(hkey);
-                       }
-
-                       if (!RegOpenKey(HKEY_CURRENT_USER, TEXT("SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Winlogon"), &hkey)) {
-
-                               ///@todo save previous shell application in config file
-
-                               RegSetValueEx(hkey, TEXT("Shell"), 0, REG_SZ, (LPBYTE)TEXT(""), l*sizeof(TCHAR));
-                               RegCloseKey(hkey);
-                       }
-               }
-
-               HWND shellWindow = GetShellWindow();
-
-               if (shellWindow) {
-                       DWORD pid;
-
-                        // terminate shell process for NT like systems
-                       GetWindowThreadProcessId(shellWindow, &pid);
-                       HANDLE hProcess = OpenProcess(PROCESS_ALL_ACCESS, FALSE, pid);
-
-                        // On Win 9x it's sufficient to destroy the shell window.
-                       DestroyWindow(shellWindow);
-
-                       if (TerminateProcess(hProcess, 0))
-                               WaitForSingleObject(hProcess, INFINITE);
-
-                       CloseHandle(hProcess);
-               }
-
-               startup_desktop = TRUE;
-       } else {
-                // create desktop window and task bar only, if there is no other shell and we are
-                // the first explorer instance
-                // MS Explorer looks additionally into the registry entry HKCU\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\shell,
-                // to decide wether it is currently configured as shell application.
-               startup_desktop = !any_desktop_running;
-       }
-
-
-       bool autostart = !any_desktop_running;
-
-        // disable autostart if the SHIFT key is pressed
-       if (GetAsyncKeyState(VK_SHIFT) < 0)
-               autostart = false;
-
-#ifdef _DEBUG  //MF: disabled for debugging
-       autostart = false;
-#endif
-
-        // If there is given the command line option "-desktop", create desktop window anyways
-       if (_tcsstr(ext_options,TEXT("-desktop")))
-               startup_desktop = TRUE;
-#ifndef ROSSHELL
-       else if (_tcsstr(ext_options,TEXT("-nodesktop")))
-               startup_desktop = FALSE;
-
-        // Don't display cabinet window in desktop mode
-       if (startup_desktop && !_tcsstr(ext_options,TEXT("-explorer")))
-               nShowCmd = SW_HIDE;
-#endif
-
-       if (_tcsstr(ext_options,TEXT("-noautostart")))
-               autostart = false;
-       else if (_tcsstr(ext_options,TEXT("-autostart")))
-               autostart = true;
-
-#ifndef __WINE__
-       if (_tcsstr(ext_options,TEXT("-console"))) {
-               AllocConsole();
-
-               _dup2(_open_osfhandle((long)GetStdHandle(STD_INPUT_HANDLE), _O_RDONLY), 0);
-               _dup2(_open_osfhandle((long)GetStdHandle(STD_OUTPUT_HANDLE), 0), 1);
-               _dup2(_open_osfhandle((long)GetStdHandle(STD_ERROR_HANDLE), 0), 2);
-
-               g_Globals._log = _fdopen(1, "w");
-               setvbuf(g_Globals._log, 0, _IONBF, 0);
-
-               LOG(TEXT("starting explorer debug log\n"));
-       }
-#endif
-
-
-       if (startup_desktop) {
-                // hide the XP login screen (Credit to Nicolas Escuder)
-                // another undocumented event: "Global\\msgina: ReturnToWelcome"
-               if (!SetShellReadyEvent(TEXT("msgina: ShellReadyEvent")))
-                       SetShellReadyEvent(TEXT("Global\\msgina: ShellReadyEvent"));
-       }
-#ifdef ROSSHELL
-       else
-               return 0;       // no shell to launch, so exit immediatelly
-#endif
-
-
-       if (!any_desktop_running) {
-                // launch the shell DDE server
-               if (g_SHDOCVW_ShellDDEInit)
-                       (*g_SHDOCVW_ShellDDEInit)(TRUE);
-       }
-
-
-       bool use_gdb_stub = false;      // !IsDebuggerPresent();
-
-       if (_tcsstr(ext_options,TEXT("-debug")))
-               use_gdb_stub = true;
-
-       if (_tcsstr(ext_options,TEXT("-break"))) {
-               LOG(TEXT("debugger breakpoint"));
-#ifdef _MSC_VER
-               __asm int 3
-#else
-               asm("int3");
-#endif
-       }
-
-        // activate GDB remote debugging stub if no other debugger is running
-       if (use_gdb_stub) {
-               LOG(TEXT("waiting for debugger connection...\n"));
-
-               initialize_gdb_stub();
-       }
-
-       g_Globals.init(hInstance);
-
-        // initialize COM and OLE before creating the desktop window
-       OleInit usingCOM;
-
-        // init common controls library
-       CommonControlInit usingCmnCtrl;
-
-       g_Globals.read_persistent();
-
-       if (startup_desktop) {
-               WaitCursor wait;
-
-               g_Globals._desktops.init();
-
-               g_Globals._hwndDesktop = DesktopWindow::Create();
-#ifdef _USE_HDESK
-               g_Globals._desktops.get_current_Desktop()->_hwndDesktop = g_Globals._hwndDesktop;
-#endif
-       }
-
-       Thread* pSSOThread = NULL;
-
-       if (startup_desktop) {
-                // launch SSO thread to allow message processing independent from the explorer main thread
-               pSSOThread = new SSOThread;
-               pSSOThread->Start();
-       }
-
-       /**TODO launching autostart programs can be moved into a background thread. */
-       if (autostart) {
-               char* argv[] = {"", "s"};       // call startup routine in SESSION_START mode
-               startup(2, argv);
-       }
-
-#ifndef ROSSHELL
-       if (g_Globals._hwndDesktop)
-               g_Globals._desktop_mode = true;
-#endif
-
-
-       int ret = explorer_main(hInstance, lpCmdLine, nShowCmd);
-
-
-        // write configuration file
-       g_Globals.write_persistent();
-
-       if (pSSOThread) {
-               pSSOThread->Stop();
-               delete pSSOThread;
-       }
-
-       if (!any_desktop_running) {
-                // shutdown the shell DDE server
-               if (g_SHDOCVW_ShellDDEInit)
-                       (*g_SHDOCVW_ShellDDEInit)(FALSE);
-       }
-
-       return ret;
-}
diff --git a/reactos/subsys/system/explorer/explorer.dsp b/reactos/subsys/system/explorer/explorer.dsp
deleted file mode 100644 (file)
index 283e5a3..0000000
+++ /dev/null
@@ -1,872 +0,0 @@
-# Microsoft Developer Studio Project File - Name="explorer" - Package Owner=<4>\r
-# Microsoft Developer Studio Generated Build File, Format Version 6.00\r
-# ** DO NOT EDIT **\r
-\r
-# TARGTYPE "Win32 (x86) Console Application" 0x0103\r
-\r
-CFG=explorer - Win32 WineDll\r
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,\r
-!MESSAGE use the Export Makefile command and run\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "explorer.mak".\r
-!MESSAGE \r
-!MESSAGE You can specify a configuration when running NMAKE\r
-!MESSAGE by defining the macro CFG on the command line. For example:\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "explorer.mak" CFG="explorer - Win32 WineDll"\r
-!MESSAGE \r
-!MESSAGE Possible choices for configuration are:\r
-!MESSAGE \r
-!MESSAGE "explorer - Win32 Release" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "explorer - Win32 Debug" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "explorer - Win32 Debug Release" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "explorer - Win32 Unicode Release" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "explorer - Win32 Unicode Debug" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "explorer - Win32" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "explorer - Win32 WineRelease" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "explorer - Win32 WineDll" (based on "Win32 (x86) Console Application")\r
-!MESSAGE \r
-\r
-# Begin Project\r
-# PROP AllowPerConfigDependencies 0\r
-# PROP Scc_ProjName ""\r
-# PROP Scc_LocalPath ""\r
-CPP=cl.exe\r
-RSC=rc.exe\r
-\r
-!IF  "$(CFG)" == "explorer - Win32 Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "Release"\r
-# PROP BASE Intermediate_Dir "Release"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "Release"\r
-# PROP Intermediate_Dir "Release"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c\r
-# ADD CPP /nologo /MD /W3 /GR /GX /O1 /D "NDEBUG" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /Yu"precomp.h" /FD /c\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386\r
-# ADD LINK32 shell32.lib comctl32.lib gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /machine:I386 /libpath:"Release" /delayload:oleaut32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "explorer - Win32 Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c\r
-# ADD CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /FR /Yu"precomp.h" /FD /GZ /c\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 kernel32.lib shell32.lib comctl32.lib gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept /libpath:"Debug" /delayload:oleaut32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "explorer - Win32 Debug Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "DRelease"\r
-# PROP BASE Intermediate_Dir "DRelease"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "DRelease"\r
-# PROP Intermediate_Dir "DRelease"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "_ROS_" /YX /FD /c\r
-# ADD CPP /nologo /MD /W3 /GR /GX /Zi /O2 /D "NDEBUG" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /FR /Yu"precomp.h" /FD /c\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib /nologo /subsystem:console /machine:I386\r
-# ADD LINK32 shell32.lib comctl32.lib gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /debug /machine:I386 /delayload:oleaut32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "explorer - Win32 Unicode Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "URelease"\r
-# PROP BASE Intermediate_Dir "URelease"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "URelease"\r
-# PROP Intermediate_Dir "URelease"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "UNICODE" /D "_ROS_" /YX /FD /c\r
-# ADD CPP /nologo /MD /W3 /GR /GX /O2 /D "NDEBUG" /D "UNICODE" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /Yu"precomp.h" /FD /c\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG" /d "UNICODE"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib /nologo /subsystem:console /machine:I386\r
-# ADD LINK32 shell32.lib comctl32.lib gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /machine:I386 /libpath:"Release" /delayload:oleaut32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "explorer - Win32 Unicode Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "UDebug"\r
-# PROP BASE Intermediate_Dir "UDebug"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "UDebug"\r
-# PROP Intermediate_Dir "UDebug"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "UNICODE" /D "_ROS_" /FR /YX /FD /GZ /c\r
-# ADD CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Od /D "_DEBUG" /D "UNICODE" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /FR /Yu"precomp.h" /FD /GZ /c\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG" /d "UNICODE"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 shell32.lib comctl32.lib gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept /libpath:"Debug" /delayload:oleaut32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "explorer - Win32"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Win32"\r
-# PROP BASE Intermediate_Dir "Win32"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Win32"\r
-# PROP Intermediate_Dir "Win32"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_ROS_" /D _WIN32_IE=0x0501 /D _WIN32_WINNT=0x0501 /FR /YX /FD /GZ /c\r
-# ADD CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Od /D "_DEBUG" /D "UNICODE" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /FR /Yu"precomp.h" /FD /GZ /c\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib ole32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept\r
-# SUBTRACT BASE LINK32 /pdb:none\r
-# ADD LINK32 gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /debug /machine:I386 /out:"Win32/wexplorer.exe" /pdbtype:sept /delayload:oleaut32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "explorer - Win32 WineRelease"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "explorer___Win32_WineRelease"\r
-# PROP BASE Intermediate_Dir "explorer___Win32_WineRelease"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "WineRelease"\r
-# PROP Intermediate_Dir "WineRelease"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Od /D "_DEBUG" /D "UNICODE" /D "WIN32" /D "_ROS_" /D _WIN32_IE=0x0501 /D _WIN32_WINNT=0x0501 /FR /YX /FD /GZ /c\r
-# ADD CPP /nologo /MT /W3 /GR /GX /O2 /D "NDEBUG" /D "UNICODE" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /Yu"precomp.h" /FD /c\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib ole32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept\r
-# SUBTRACT BASE LINK32 /pdb:none\r
-# ADD LINK32 gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /incremental:no /machine:I386 /out:"WineRelease/wexplorer.exe" /pdbtype:sept /delayload:oleaut32.dll /delayload:wsock32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "explorer - Win32 WineDll"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "explorer___Win32_WineDll"\r
-# PROP BASE Intermediate_Dir "explorer___Win32_WineDll"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "WineDll"\r
-# PROP Intermediate_Dir "WineDll"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /MT /W3 /GR /GX /O2 /D "NDEBUG" /D "UNICODE" /D "WIN32" /D "_ROS_" /D _WIN32_IE=0x0501 /D _WIN32_WINNT=0x0501 /FD /c\r
-# ADD CPP /nologo /MD /W3 /GR /GX /O2 /D "NDEBUG" /D "UNICODE" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /Yu"precomp.h" /FD /c\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib ole32.lib /nologo /subsystem:windows /machine:I386 /pdbtype:sept\r
-# SUBTRACT BASE LINK32 /pdb:none /debug\r
-# ADD LINK32 gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /machine:I386 /out:"WineDll/wexplorer.exe" /pdbtype:sept /delayload:oleaut32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ENDIF \r
-\r
-# Begin Target\r
-\r
-# Name "explorer - Win32 Release"\r
-# Name "explorer - Win32 Debug"\r
-# Name "explorer - Win32 Debug Release"\r
-# Name "explorer - Win32 Unicode Release"\r
-# Name "explorer - Win32 Unicode Debug"\r
-# Name "explorer - Win32"\r
-# Name "explorer - Win32 WineRelease"\r
-# Name "explorer - Win32 WineDll"\r
-# Begin Group "utility"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\dragdropimpl.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\dragdropimpl.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\shellbrowserimpl.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\shellbrowserimpl.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\shellclasses.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\shellclasses.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\treedroptarget.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\utility.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\utility.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\window.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\window.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\xmlstorage.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\xmlstorage.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "resources"\r
-\r
-# PROP Default_Filter "bmp,ico"\r
-# Begin Source File\r
-\r
-SOURCE=.\res\action.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\administration.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\appicon.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\apps.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\arrow.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\arrow_dwn.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\arrow_up.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\arrowsel.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\computer.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\config.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\res\control-panel.ico"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\res\desktop-settings.ico"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\documents.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\dot.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\dot_red.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\dot_trans.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\drivebar.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-cz.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-de.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-en.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-es.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-fr.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-hu.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-jp.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-pl.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-pt.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-ro.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-ru.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-sv.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-uk.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\explorer.exe.manifest\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\explorer.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\explorer_intres.rc\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\favorites.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\floating.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\folder.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoali10.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig0.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig1.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig2.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig3.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig4.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig5.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig6.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig7.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig8.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig9.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\images.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\info.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\logoff.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\logov.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\logov16.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\logov256.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\mdi.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\minimize.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\res\network-conns.ico"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\network.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\notify_l.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\notify_r.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\printer.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\reactos.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\res\recent-documents.ico"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\resource.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\res\ros-big.ico"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\sdi.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\res\search-doc.ico"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\search.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\shutdown.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\speaker.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\startmenu.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\toolbar.bmp\r
-# End Source File\r
-# End Group\r
-# Begin Group "taskbar"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\desktopbar.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\desktopbar.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\favorites.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\favorites.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\notifyhook\notifyhook.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\quicklaunch.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\quicklaunch.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\startmenu.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\startmenu.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\taskbar.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\taskbar.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\traynotify.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\traynotify.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "desktop"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\desktop\desktop.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\desktop\desktop.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "doc"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\doc\changes.txt\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\doc\readme.txt\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\doc\TODO.txt\r
-# End Source File\r
-# End Group\r
-# Begin Group "shell"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\entries.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\entries.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\fatfs.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\fatfs.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\filechild.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\filechild.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\mainframe.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\mainframe.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\ntobjfs.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\ntobjfs.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\pane.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\pane.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\regfs.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\regfs.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\shellbrowser.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\shellbrowser.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\shellfs.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\shellfs.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\unixfs.cpp\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\unixfs.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\webchild.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\webchild.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\winfs.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\winfs.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "dialogs"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\dialogs\searchprogram.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\dialogs\searchprogram.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\dialogs\settings.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\dialogs\settings.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "main"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\explorer.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\explorer.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\externals.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\globals.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\i386-stub-win32.c"\r
-# SUBTRACT CPP /YX /Yc /Yu\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\precomp.cpp\r
-# ADD CPP /Yc"precomp.h"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\precomp.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "services"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\services\shellservices.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\services\shellservices.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\services\startup.c\r
-# SUBTRACT CPP /YX /Yc /Yu\r
-# End Source File\r
-# End Group\r
-# End Target\r
-# End Project\r
diff --git a/reactos/subsys/system/explorer/explorer.dsw b/reactos/subsys/system/explorer/explorer.dsw
deleted file mode 100644 (file)
index d212f18..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-Microsoft Developer Studio Workspace File, Format Version 6.00\r
-# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!\r
-\r
-###############################################################################\r
-\r
-Project: "explorer"=.\explorer.dsp - Package Owner=<4>\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<4>\r
-{{{\r
-    Begin Project Dependency\r
-    Project_Dep_Name notifyhook\r
-    End Project Dependency\r
-}}}\r
-\r
-###############################################################################\r
-\r
-Project: "make_explorer"=.\make_explorer.dsp - Package Owner=<4>\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<4>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
-Project: "notifyhook"=.\notifyhook\notifyhook.dsp - Package Owner=<4>\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<4>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
-Global:\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<3>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
diff --git a/reactos/subsys/system/explorer/explorer.exe.manifest b/reactos/subsys/system/explorer/explorer.exe.manifest
deleted file mode 100644 (file)
index 5df0dd3..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r
-<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">\r
-<assemblyIdentity\r
-    version="1.0.0.0"\r
-    processorArchitecture="X86"\r
-    name="ReactOS.Explorer"\r
-    type="win32"\r
-/>\r
-<description>ROS Explorer</description>\r
-<dependency>\r
-    <dependentAssembly>\r
-        <assemblyIdentity\r
-            type="win32"\r
-            name="Microsoft.Windows.Common-Controls"\r
-            version="6.0.0.0"\r
-            processorArchitecture="X86"\r
-            publicKeyToken="6595b64144ccf1df"\r
-            language="*"\r
-        />\r
-    </dependentAssembly>\r
-</dependency>\r
-</assembly>\r
diff --git a/reactos/subsys/system/explorer/explorer.h b/reactos/subsys/system/explorer/explorer.h
deleted file mode 100644 (file)
index 6c508ff..0000000
+++ /dev/null
@@ -1,122 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // explorer.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#define _LIGHT_STARTMENU
-#define _LAZY_ICONEXTRACT
-#define _SINGLE_ICONEXTRACT
-//#define _NO_WIN_FS
-
-
-#include "utility/shellclasses.h"
-
-#include "shell/entries.h"
-
-#ifndef _NO_WIN_FS
-#include "shell/winfs.h"
-#endif
-
-#include "shell/shellfs.h"
-
-#ifndef ROSSHELL
-#include "shell/unixfs.h"
-#endif
-
-#include "utility/window.h"
-
-
-#define        IDW_STATUSBAR                   0x100
-#define        IDW_TOOLBAR                             0x101
-#define        IDW_EXTRABAR                    0x102
-#define        IDW_DRIVEBAR                    0x103
-#define        IDW_ADDRESSBAR                  0x104
-#define        IDW_COMMANDBAR                  0x105
-#define        IDW_SIDEBAR                             0x106
-#define        IDW_FIRST_CHILD                 0xC000  /*0x200*/
-
-
-#define        PM_GET_FILEWND_PTR              (WM_APP+0x05)
-#define        PM_GET_SHELLBROWSER_PTR (WM_APP+0x06)
-
-#define        PM_GET_CONTROLWINDOW    (WM_APP+0x16)
-
-#define        PM_RESIZE_CHILDREN              (WM_APP+0x17)
-#define        PM_GET_WIDTH                    (WM_APP+0x18)
-
-#define        PM_REFRESH                              (WM_APP+0x1B)
-#define        PM_REFRESH_CONFIG               (WM_APP+0x1C)
-
-
-#define        CLASSNAME_FRAME                 TEXT("CabinetWClass")   // same class name for frame window as in MS Explorer
-
-#define        CLASSNAME_CHILDWND              TEXT("WFS_Child")
-#define        CLASSNAME_WINEFILETREE  TEXT("WFS_Tree")
-
-
-#include "shell/pane.h"
-#include "shell/filechild.h"
-#include "shell/shellbrowser.h"
-
-
-#ifndef ROSSHELL
-
- /// Explorer command line parser
- // for commands like "/e,/root,c:\"
- // or "::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\::{21EC2020-3AEA-1069-A2DD-08002B30309D}" (launch of control panel)
-struct ExplorerCmd
-{
-       ExplorerCmd()
-        :      _flags(0),
-               _cmdShow(SW_SHOWNORMAL),
-               _mdi(false),
-               _valid_path(false)
-       {
-       }
-
-       ExplorerCmd(LPCTSTR url, bool mdi)
-        :      _path(url),
-               _flags(0),
-               _cmdShow(SW_SHOWNORMAL),
-               _mdi(mdi),
-               _valid_path(true)       //@@
-       {
-       }
-
-       bool    ParseCmdLine(LPCTSTR lpCmdLine);
-       bool    EvaluateOption(LPCTSTR option);
-       bool    IsValidPath() const;
-
-       String  _path;
-       int             _flags; // OPEN_WINDOW_MODE
-       int             _cmdShow;
-       bool    _mdi;
-       bool    _valid_path;
-};
-
-#include "shell/mainframe.h"
-
-#endif
diff --git a/reactos/subsys/system/explorer/explorer.rc b/reactos/subsys/system/explorer/explorer.rc
deleted file mode 100644 (file)
index ed27319..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-/* $Id: explorer.rc 17951 2005-09-20 19:51:27Z mf $ */
-
-#include "explorer_intres.rc"
-
-#define REACTOS_STR_FILE_DESCRIPTION    "ReactOS Explorer\0"
-#define REACTOS_STR_INTERNAL_NAME       "explorer\0"
-#define REACTOS_STR_ORIGINAL_FILENAME   "explorer.exe\0"
-#include <reactos/version.rc>
-
-LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
-
-#define IDS_VERSION_STR             5000
-#define IDS_EXPLORER_VERSION_STR    5001
-
-LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_VERSION_STR REACTOS_STR_PRODUCT_VERSION
-    IDS_EXPLORER_VERSION_STR "ReactOS %s Explorer"
-END
diff --git a/reactos/subsys/system/explorer/explorer.sln b/reactos/subsys/system/explorer/explorer.sln
deleted file mode 100644 (file)
index 4f01e36..0000000
+++ /dev/null
@@ -1,79 +0,0 @@
-\r
-Microsoft Visual Studio Solution File, Format Version 9.00\r
-# Visual C++ Express 2005\r
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "explorer", "explorer.vcproj", "{BFBAE588-8C68-4303-9BF6-C830087D8F25}"\r
-       ProjectSection(ProjectDependencies) = postProject\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162} = {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}\r
-       EndProjectSection\r
-EndProject\r
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "make_explorer", "make_explorer.vcproj", "{E132A04B-8BC6-4D18-81F2-F0156B809871}"\r
-EndProject\r
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "notifyhook", "notifyhook\notifyhook.vcproj", "{F28B575D-7DBA-44DE-AAEF-FA0D065E5162}"\r
-EndProject\r
-Global\r
-       GlobalSection(SolutionConfigurationPlatforms) = preSolution\r
-               bjam|Win32 = bjam|Win32\r
-               Debug Release|Win32 = Debug Release|Win32\r
-               Debug|Win32 = Debug|Win32\r
-               doxy docu|Win32 = doxy docu|Win32\r
-               Release|Win32 = Release|Win32\r
-               Unicode Debug|Win32 = Unicode Debug|Win32\r
-               Unicode Release|Win32 = Unicode Release|Win32\r
-               WineDll|Win32 = WineDll|Win32\r
-               WineRelease|Win32 = WineRelease|Win32\r
-       EndGlobalSection\r
-       GlobalSection(ProjectConfigurationPlatforms) = postSolution\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.bjam|Win32.ActiveCfg = WineDll|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.bjam|Win32.Build.0 = WineDll|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.Debug Release|Win32.ActiveCfg = Debug|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.Debug Release|Win32.Build.0 = Debug|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.Debug|Win32.ActiveCfg = Debug|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.Debug|Win32.Build.0 = Debug|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.doxy docu|Win32.ActiveCfg = Debug|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.doxy docu|Win32.Build.0 = Debug|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.Release|Win32.ActiveCfg = Release|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.Release|Win32.Build.0 = Release|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.Unicode Debug|Win32.ActiveCfg = Unicode Debug|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.Unicode Debug|Win32.Build.0 = Unicode Debug|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.Unicode Release|Win32.ActiveCfg = Unicode Release|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.Unicode Release|Win32.Build.0 = Unicode Release|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.WineDll|Win32.ActiveCfg = WineDll|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.WineDll|Win32.Build.0 = WineDll|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.WineRelease|Win32.ActiveCfg = WineRelease|Win32\r
-               {BFBAE588-8C68-4303-9BF6-C830087D8F25}.WineRelease|Win32.Build.0 = WineRelease|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.bjam|Win32.ActiveCfg = bjam|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.bjam|Win32.Build.0 = bjam|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.Debug Release|Win32.ActiveCfg = Debug|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.Debug|Win32.ActiveCfg = Debug|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.doxy docu|Win32.ActiveCfg = doxy docu|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.doxy docu|Win32.Build.0 = doxy docu|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.Release|Win32.ActiveCfg = Release|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.Unicode Debug|Win32.ActiveCfg = Unicode Debug|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.Unicode Release|Win32.ActiveCfg = Unicode Release|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.WineDll|Win32.ActiveCfg = Debug|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.WineDll|Win32.Build.0 = Debug|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.WineRelease|Win32.ActiveCfg = Release|Win32\r
-               {E132A04B-8BC6-4D18-81F2-F0156B809871}.WineRelease|Win32.Build.0 = Release|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.bjam|Win32.ActiveCfg = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.bjam|Win32.Build.0 = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.Debug Release|Win32.ActiveCfg = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.Debug Release|Win32.Build.0 = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.Debug|Win32.ActiveCfg = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.Debug|Win32.Build.0 = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.doxy docu|Win32.ActiveCfg = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.doxy docu|Win32.Build.0 = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.Release|Win32.ActiveCfg = Release|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.Release|Win32.Build.0 = Release|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.Unicode Debug|Win32.ActiveCfg = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.Unicode Debug|Win32.Build.0 = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.Unicode Release|Win32.ActiveCfg = Release|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.Unicode Release|Win32.Build.0 = Release|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.WineDll|Win32.ActiveCfg = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.WineDll|Win32.Build.0 = Debug|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.WineRelease|Win32.ActiveCfg = Release|Win32\r
-               {F28B575D-7DBA-44DE-AAEF-FA0D065E5162}.WineRelease|Win32.Build.0 = Release|Win32\r
-       EndGlobalSection\r
-       GlobalSection(SolutionProperties) = preSolution\r
-               HideSolutionNode = FALSE\r
-       EndGlobalSection\r
-EndGlobal\r
diff --git a/reactos/subsys/system/explorer/explorer.vcproj b/reactos/subsys/system/explorer/explorer.vcproj
deleted file mode 100644 (file)
index 79428d6..0000000
+++ /dev/null
@@ -1,3788 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>\r
-<VisualStudioProject\r
-       ProjectType="Visual C++"\r
-       Version="8,00"\r
-       Name="explorer"\r
-       ProjectGUID="{BFBAE588-8C68-4303-9BF6-C830087D8F25}"\r
-       RootNamespace="explorer"\r
-       >\r
-       <Platforms>\r
-               <Platform\r
-                       Name="Win32"\r
-               />\r
-       </Platforms>\r
-       <ToolFiles>\r
-       </ToolFiles>\r
-       <Configurations>\r
-               <Configuration\r
-                       Name="Unicode Debug|Win32"\r
-                       OutputDirectory=".\UDebug"\r
-                       IntermediateDirectory=".\UDebug"\r
-                       ConfigurationType="1"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCPreBuildEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCCustomBuildTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXMLDataGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebServiceProxyGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCMIDLTool"\r
-                               TypeLibraryName=".\UDebug/explorer.tlb"\r
-                               HeaderFileName=""\r
-                       />\r
-                       <Tool\r
-                               Name="VCCLCompilerTool"\r
-                               Optimization="0"\r
-                               PreprocessorDefinitions="_DEBUG;UNICODE;WIN32;_WIN32_IE=0x0600;_WIN32_WINNT=0x0501,_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES,_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES_COUNT"\r
-                               MinimalRebuild="true"\r
-                               BasicRuntimeChecks="3"\r
-                               RuntimeLibrary="3"\r
-                               RuntimeTypeInfo="true"\r
-                               UsePrecompiledHeader="2"\r
-                               PrecompiledHeaderThrough="precomp.h"\r
-                               PrecompiledHeaderFile=".\UDebug/explorer.pch"\r
-                               AssemblerListingLocation=".\UDebug/"\r
-                               ObjectFile=".\UDebug/"\r
-                               ProgramDataBaseFileName=".\UDebug/"\r
-                               BrowseInformation="1"\r
-                               WarningLevel="3"\r
-                               SuppressStartupBanner="true"\r
-                               DebugInformationFormat="4"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManagedResourceCompilerTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCResourceCompilerTool"\r
-                               PreprocessorDefinitions="_DEBUG,UNICODE"\r
-                               Culture="1031"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPreLinkEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCLinkerTool"\r
-                               AdditionalDependencies="shell32.lib advapi32.lib gdi32.lib user32.lib comctl32.lib"\r
-                               OutputFile=".\UDebug/explorer.exe"\r
-                               LinkIncremental="2"\r
-                               SuppressStartupBanner="true"\r
-                               AdditionalLibraryDirectories="Debug"\r
-                               DelayLoadDLLs="oleaut32.dll,wsock32.dll"\r
-                               GenerateDebugInformation="true"\r
-                               ProgramDatabaseFile=".\UDebug/explorer.pdb"\r
-                               SubSystem="2"\r
-                               TargetMachine="1"\r
-                       />\r
-                       <Tool\r
-                               Name="VCALinkTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManifestTool"\r
-                               AdditionalManifestFiles="explorer.exe.manifest"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXDCMakeTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCBscMakeTool"\r
-                               SuppressStartupBanner="true"\r
-                               OutputFile=".\UDebug/explorer.bsc"\r
-                       />\r
-                       <Tool\r
-                               Name="VCFxCopTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCAppVerifierTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebDeploymentTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPostBuildEventTool"\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="Unicode Release|Win32"\r
-                       OutputDirectory=".\URelease"\r
-                       IntermediateDirectory=".\URelease"\r
-                       ConfigurationType="1"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCPreBuildEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCCustomBuildTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXMLDataGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebServiceProxyGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCMIDLTool"\r
-                               TypeLibraryName=".\URelease/explorer.tlb"\r
-                               HeaderFileName=""\r
-                       />\r
-                       <Tool\r
-                               Name="VCCLCompilerTool"\r
-                               Optimization="2"\r
-                               InlineFunctionExpansion="1"\r
-                               PreprocessorDefinitions="NDEBUG;UNICODE;WIN32;_WIN32_IE=0x0600;_WIN32_WINNT=0x0501,_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES,_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES_COUNT"\r
-                               StringPooling="true"\r
-                               RuntimeLibrary="2"\r
-                               EnableFunctionLevelLinking="true"\r
-                               RuntimeTypeInfo="true"\r
-                               UsePrecompiledHeader="2"\r
-                               PrecompiledHeaderThrough="precomp.h"\r
-                               PrecompiledHeaderFile=".\URelease/explorer.pch"\r
-                               AssemblerListingLocation=".\URelease/"\r
-                               ObjectFile=".\URelease/"\r
-                               ProgramDataBaseFileName=".\URelease/"\r
-                               WarningLevel="3"\r
-                               SuppressStartupBanner="true"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManagedResourceCompilerTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCResourceCompilerTool"\r
-                               PreprocessorDefinitions="NDEBUG,UNICODE"\r
-                               Culture="1031"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPreLinkEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCLinkerTool"\r
-                               AdditionalDependencies="shell32.lib advapi32.lib gdi32.lib user32.lib comctl32.lib"\r
-                               OutputFile=".\URelease/explorer.exe"\r
-                               LinkIncremental="1"\r
-                               SuppressStartupBanner="true"\r
-                               AdditionalLibraryDirectories="Release"\r
-                               DelayLoadDLLs="oleaut32.dll,wsock32.dll"\r
-                               ProgramDatabaseFile=".\URelease/explorer.pdb"\r
-                               SubSystem="2"\r
-                               TargetMachine="1"\r
-                       />\r
-                       <Tool\r
-                               Name="VCALinkTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManifestTool"\r
-                               AdditionalManifestFiles="explorer.exe.manifest"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXDCMakeTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCBscMakeTool"\r
-                               SuppressStartupBanner="true"\r
-                               OutputFile=".\URelease/explorer.bsc"\r
-                       />\r
-                       <Tool\r
-                               Name="VCFxCopTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCAppVerifierTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebDeploymentTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPostBuildEventTool"\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="WineRelease|Win32"\r
-                       OutputDirectory=".\WineRelease"\r
-                       IntermediateDirectory=".\WineRelease"\r
-                       ConfigurationType="1"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCPreBuildEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCCustomBuildTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXMLDataGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebServiceProxyGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCMIDLTool"\r
-                               TypeLibraryName=".\WineRelease/explorer.tlb"\r
-                               HeaderFileName=""\r
-                       />\r
-                       <Tool\r
-                               Name="VCCLCompilerTool"\r
-                               Optimization="2"\r
-                               InlineFunctionExpansion="1"\r
-                               PreprocessorDefinitions="NDEBUG;UNICODE;WIN32;_WIN32_IE=0x0600;_WIN32_WINNT=0x0501"\r
-                               StringPooling="true"\r
-                               RuntimeLibrary="0"\r
-                               EnableFunctionLevelLinking="true"\r
-                               RuntimeTypeInfo="true"\r
-                               UsePrecompiledHeader="2"\r
-                               PrecompiledHeaderThrough="precomp.h"\r
-                               PrecompiledHeaderFile=".\WineRelease/explorer.pch"\r
-                               AssemblerListingLocation=".\WineRelease/"\r
-                               ObjectFile=".\WineRelease/"\r
-                               ProgramDataBaseFileName=".\WineRelease/"\r
-                               WarningLevel="3"\r
-                               SuppressStartupBanner="true"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManagedResourceCompilerTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCResourceCompilerTool"\r
-                               PreprocessorDefinitions="_DEBUG"\r
-                               Culture="1031"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPreLinkEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCLinkerTool"\r
-                               AdditionalDependencies="shell32.lib advapi32.lib gdi32.lib user32.lib comctl32.lib"\r
-                               OutputFile="WineRelease/wexplorer.exe"\r
-                               LinkIncremental="1"\r
-                               SuppressStartupBanner="true"\r
-                               DelayLoadDLLs="oleaut32.dll,wsock32.dll"\r
-                               ProgramDatabaseFile=".\WineRelease/wexplorer.pdb"\r
-                               SubSystem="2"\r
-                               TargetMachine="1"\r
-                       />\r
-                       <Tool\r
-                               Name="VCALinkTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManifestTool"\r
-                               AdditionalManifestFiles="explorer.exe.manifest"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXDCMakeTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCBscMakeTool"\r
-                               SuppressStartupBanner="true"\r
-                               OutputFile=".\WineRelease/explorer.bsc"\r
-                       />\r
-                       <Tool\r
-                               Name="VCFxCopTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCAppVerifierTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebDeploymentTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPostBuildEventTool"\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="Debug Release|Win32"\r
-                       OutputDirectory=".\DRelease"\r
-                       IntermediateDirectory=".\DRelease"\r
-                       ConfigurationType="1"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCPreBuildEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCCustomBuildTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXMLDataGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebServiceProxyGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCMIDLTool"\r
-                               TypeLibraryName=".\DRelease/explorer.tlb"\r
-                               HeaderFileName=""\r
-                       />\r
-                       <Tool\r
-                               Name="VCCLCompilerTool"\r
-                               Optimization="2"\r
-                               InlineFunctionExpansion="1"\r
-                               PreprocessorDefinitions="NDEBUG;WIN32;_WIN32_IE=0x0600;_WIN32_WINNT=0x0501"\r
-                               StringPooling="true"\r
-                               RuntimeLibrary="2"\r
-                               EnableFunctionLevelLinking="true"\r
-                               RuntimeTypeInfo="true"\r
-                               UsePrecompiledHeader="2"\r
-                               PrecompiledHeaderThrough="precomp.h"\r
-                               PrecompiledHeaderFile=".\DRelease/explorer.pch"\r
-                               AssemblerListingLocation=".\DRelease/"\r
-                               ObjectFile=".\DRelease/"\r
-                               ProgramDataBaseFileName=".\DRelease/"\r
-                               BrowseInformation="1"\r
-                               WarningLevel="3"\r
-                               SuppressStartupBanner="true"\r
-                               DebugInformationFormat="3"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManagedResourceCompilerTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCResourceCompilerTool"\r
-                               PreprocessorDefinitions="NDEBUG"\r
-                               Culture="1031"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPreLinkEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCLinkerTool"\r
-                               AdditionalDependencies="shell32.lib advapi32.lib gdi32.lib user32.lib comctl32.lib"\r
-                               OutputFile=".\DRelease/explorer.exe"\r
-                               LinkIncremental="1"\r
-                               SuppressStartupBanner="true"\r
-                               DelayLoadDLLs="oleaut32.dll,wsock32.dll"\r
-                               GenerateDebugInformation="true"\r
-                               ProgramDatabaseFile=".\DRelease/explorer.pdb"\r
-                               SubSystem="2"\r
-                               TargetMachine="1"\r
-                       />\r
-                       <Tool\r
-                               Name="VCALinkTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManifestTool"\r
-                               AdditionalManifestFiles="explorer.exe.manifest"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXDCMakeTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCBscMakeTool"\r
-                               SuppressStartupBanner="true"\r
-                               OutputFile=".\DRelease/explorer.bsc"\r
-                       />\r
-                       <Tool\r
-                               Name="VCFxCopTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCAppVerifierTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebDeploymentTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPostBuildEventTool"\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="Debug|Win32"\r
-                       OutputDirectory=".\Debug"\r
-                       IntermediateDirectory=".\Debug"\r
-                       ConfigurationType="1"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCPreBuildEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCCustomBuildTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXMLDataGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebServiceProxyGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCMIDLTool"\r
-                               TypeLibraryName=".\Debug/explorer.tlb"\r
-                               HeaderFileName=""\r
-                       />\r
-                       <Tool\r
-                               Name="VCCLCompilerTool"\r
-                               Optimization="0"\r
-                               PreprocessorDefinitions="_DEBUG;WIN32;_WIN32_IE=0x0600;_WIN32_WINNT=0x0501,_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES,_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES_COUNT"\r
-                               MinimalRebuild="true"\r
-                               BasicRuntimeChecks="3"\r
-                               RuntimeLibrary="3"\r
-                               RuntimeTypeInfo="true"\r
-                               UsePrecompiledHeader="2"\r
-                               PrecompiledHeaderThrough="precomp.h"\r
-                               PrecompiledHeaderFile=".\Debug/explorer.pch"\r
-                               AssemblerListingLocation=".\Debug/"\r
-                               ObjectFile=".\Debug/"\r
-                               ProgramDataBaseFileName=".\Debug/"\r
-                               BrowseInformation="1"\r
-                               WarningLevel="3"\r
-                               SuppressStartupBanner="true"\r
-                               DebugInformationFormat="4"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManagedResourceCompilerTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCResourceCompilerTool"\r
-                               PreprocessorDefinitions="_DEBUG"\r
-                               Culture="1031"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPreLinkEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCLinkerTool"\r
-                               AdditionalDependencies="shell32.lib advapi32.lib gdi32.lib user32.lib comctl32.lib"\r
-                               OutputFile=".\Debug/explorer.exe"\r
-                               LinkIncremental="2"\r
-                               SuppressStartupBanner="true"\r
-                               AdditionalLibraryDirectories="Debug"\r
-                               DelayLoadDLLs="oleaut32.dll,wsock32.dll"\r
-                               GenerateDebugInformation="true"\r
-                               ProgramDatabaseFile=".\Debug/explorer.pdb"\r
-                               SubSystem="2"\r
-                               TargetMachine="1"\r
-                       />\r
-                       <Tool\r
-                               Name="VCALinkTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManifestTool"\r
-                               AdditionalManifestFiles="explorer.exe.manifest"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXDCMakeTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCBscMakeTool"\r
-                               SuppressStartupBanner="true"\r
-                               OutputFile=".\Debug/explorer.bsc"\r
-                       />\r
-                       <Tool\r
-                               Name="VCFxCopTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCAppVerifierTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebDeploymentTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPostBuildEventTool"\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="Release|Win32"\r
-                       OutputDirectory=".\Release"\r
-                       IntermediateDirectory=".\Release"\r
-                       ConfigurationType="1"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCPreBuildEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCCustomBuildTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXMLDataGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebServiceProxyGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCMIDLTool"\r
-                               TypeLibraryName=".\Release/explorer.tlb"\r
-                               HeaderFileName=""\r
-                       />\r
-                       <Tool\r
-                               Name="VCCLCompilerTool"\r
-                               Optimization="1"\r
-                               InlineFunctionExpansion="1"\r
-                               PreprocessorDefinitions="NDEBUG;WIN32;_WIN32_IE=0x0600;_WIN32_WINNT=0x0501;_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES,_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES_COUNT"\r
-                               StringPooling="true"\r
-                               RuntimeLibrary="2"\r
-                               EnableFunctionLevelLinking="true"\r
-                               RuntimeTypeInfo="true"\r
-                               UsePrecompiledHeader="2"\r
-                               PrecompiledHeaderThrough="precomp.h"\r
-                               PrecompiledHeaderFile=".\Release/explorer.pch"\r
-                               AssemblerListingLocation=".\Release/"\r
-                               ObjectFile=".\Release/"\r
-                               ProgramDataBaseFileName=".\Release/"\r
-                               WarningLevel="3"\r
-                               SuppressStartupBanner="true"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManagedResourceCompilerTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCResourceCompilerTool"\r
-                               PreprocessorDefinitions="NDEBUG"\r
-                               Culture="1031"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPreLinkEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCLinkerTool"\r
-                               AdditionalDependencies="shell32.lib advapi32.lib gdi32.lib user32.lib comctl32.lib"\r
-                               OutputFile=".\Release/explorer.exe"\r
-                               LinkIncremental="1"\r
-                               SuppressStartupBanner="true"\r
-                               AdditionalLibraryDirectories="Release"\r
-                               DelayLoadDLLs="oleaut32.dll,wsock32.dll"\r
-                               ProgramDatabaseFile=".\Release/explorer.pdb"\r
-                               SubSystem="2"\r
-                               TargetMachine="1"\r
-                       />\r
-                       <Tool\r
-                               Name="VCALinkTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManifestTool"\r
-                               AdditionalManifestFiles="explorer.exe.manifest"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXDCMakeTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCBscMakeTool"\r
-                               SuppressStartupBanner="true"\r
-                               OutputFile=".\Release/explorer.bsc"\r
-                       />\r
-                       <Tool\r
-                               Name="VCFxCopTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCAppVerifierTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebDeploymentTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPostBuildEventTool"\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="WineDll|Win32"\r
-                       OutputDirectory=".\WineDll"\r
-                       IntermediateDirectory=".\WineDll"\r
-                       ConfigurationType="1"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCPreBuildEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCCustomBuildTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXMLDataGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebServiceProxyGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCMIDLTool"\r
-                               TypeLibraryName=".\WineDll/explorer.tlb"\r
-                               HeaderFileName=""\r
-                       />\r
-                       <Tool\r
-                               Name="VCCLCompilerTool"\r
-                               Optimization="2"\r
-                               InlineFunctionExpansion="1"\r
-                               PreprocessorDefinitions="NDEBUG;UNICODE;WIN32;_WIN32_IE=0x0600;_WIN32_WINNT=0x0501"\r
-                               StringPooling="true"\r
-                               RuntimeLibrary="2"\r
-                               EnableFunctionLevelLinking="true"\r
-                               RuntimeTypeInfo="true"\r
-                               UsePrecompiledHeader="2"\r
-                               PrecompiledHeaderThrough="precomp.h"\r
-                               PrecompiledHeaderFile=".\WineDll/explorer.pch"\r
-                               AssemblerListingLocation=".\WineDll/"\r
-                               ObjectFile=".\WineDll/"\r
-                               ProgramDataBaseFileName=".\WineDll/"\r
-                               WarningLevel="3"\r
-                               SuppressStartupBanner="true"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManagedResourceCompilerTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCResourceCompilerTool"\r
-                               PreprocessorDefinitions="_DEBUG"\r
-                               Culture="1031"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPreLinkEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCLinkerTool"\r
-                               AdditionalDependencies="shell32.lib advapi32.lib gdi32.lib user32.lib comctl32.lib"\r
-                               OutputFile="WineDll/wexplorer.exe"\r
-                               LinkIncremental="2"\r
-                               SuppressStartupBanner="true"\r
-                               DelayLoadDLLs="oleaut32.dll,wsock32.dll"\r
-                               ProgramDatabaseFile=".\WineDll/wexplorer.pdb"\r
-                               SubSystem="2"\r
-                               TargetMachine="1"\r
-                       />\r
-                       <Tool\r
-                               Name="VCALinkTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManifestTool"\r
-                               AdditionalManifestFiles="explorer.exe.manifest"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXDCMakeTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCBscMakeTool"\r
-                               SuppressStartupBanner="true"\r
-                               OutputFile=".\WineDll/explorer.bsc"\r
-                       />\r
-                       <Tool\r
-                               Name="VCFxCopTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCAppVerifierTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebDeploymentTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPostBuildEventTool"\r
-                       />\r
-               </Configuration>\r
-       </Configurations>\r
-       <References>\r
-       </References>\r
-       <Files>\r
-               <Filter\r
-                       Name="utility"\r
-                       >\r
-                       <File\r
-                               RelativePath="utility\dragdropimpl.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\dragdropimpl.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\shellbrowserimpl.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\shellbrowserimpl.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\shellclasses.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\shellclasses.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\treedroptarget.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\utility.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\utility.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\window.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\window.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\xmlstorage.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="utility\xmlstorage.h"\r
-                               >\r
-                       </File>\r
-               </Filter>\r
-               <Filter\r
-                       Name="resources"\r
-                       Filter="bmp,ico"\r
-                       >\r
-                       <File\r
-                               RelativePath="res\action.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath=".\res\administration.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\appicon.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\apps.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\arrow.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\arrow_dwn.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\arrow_up.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\arrowsel.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\computer.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\config.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath=".\res\control-panel.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath=".\res\desktop-settings.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\documents.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\dot.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\dot_red.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\dot_trans.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\drivebar.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer-cz.rc"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer-de.rc"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer-en.rc"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer-es.rc"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer-fr.rc"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer-jp.rc"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer-pt.rc"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer-ro.rc"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer-ru.rc"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer-sv.rc"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\explorer.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer_intres.rc"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCResourceCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\favorites.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\floating.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\folder.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\icoali10.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\icoalig0.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\icoalig1.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\icoalig2.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\icoalig3.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\icoalig4.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\icoalig5.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\icoalig6.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\icoalig7.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\icoalig8.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\icoalig9.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\images.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\info.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\logoff.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\logov.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\logov16.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\logov256.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\mdi.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath=".\res\minimize.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath=".\res\network-conns.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\network.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\notify_l.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\notify_r.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\printer.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\reactos.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath=".\res\recent-documents.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="resource.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\ros-big.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\sdi.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\search-doc.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\search.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath=".\res\shutdown.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\speaker.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\startmenu.ico"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="res\toolbar.bmp"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath=".\res\winefile.ico"\r
-                               >\r
-                       </File>\r
-               </Filter>\r
-               <Filter\r
-                       Name="taskbar"\r
-                       >\r
-                       <File\r
-                               RelativePath="taskbar\desktopbar.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="taskbar\desktopbar.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="taskbar\favorites.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="taskbar\favorites.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="notifyhook\notifyhook.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="taskbar\quicklaunch.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="taskbar\quicklaunch.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="taskbar\startmenu.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="taskbar\startmenu.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="taskbar\taskbar.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="taskbar\taskbar.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="taskbar\traynotify.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="taskbar\traynotify.h"\r
-                               >\r
-                       </File>\r
-               </Filter>\r
-               <Filter\r
-                       Name="desktop"\r
-                       >\r
-                       <File\r
-                               RelativePath="desktop\desktop.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="desktop\desktop.h"\r
-                               >\r
-                       </File>\r
-               </Filter>\r
-               <Filter\r
-                       Name="doc"\r
-                       >\r
-                       <File\r
-                               RelativePath="doc\changes.txt"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="doc\readme.txt"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="doc\TODO.txt"\r
-                               >\r
-                       </File>\r
-               </Filter>\r
-               <Filter\r
-                       Name="shell"\r
-                       >\r
-                       <File\r
-                               RelativePath="shell\entries.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\entries.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\fatfs.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\fatfs.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\filechild.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\filechild.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\mainframe.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\mainframe.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\ntobjfs.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\ntobjfs.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\pane.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\pane.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\regfs.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\regfs.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\shellbrowser.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\shellbrowser.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\shellfs.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\shellfs.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\unixfs.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       ExcludedFromBuild="true"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\unixfs.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\webchild.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\webchild.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\winfs.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="shell\winfs.h"\r
-                               >\r
-                       </File>\r
-               </Filter>\r
-               <Filter\r
-                       Name="dialogs"\r
-                       >\r
-                       <File\r
-                               RelativePath="dialogs\searchprogram.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="dialogs\searchprogram.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="dialogs\settings.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="dialogs\settings.h"\r
-                               >\r
-                       </File>\r
-               </Filter>\r
-               <Filter\r
-                       Name="main"\r
-                       >\r
-                       <File\r
-                               RelativePath="explorer.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer.exe.manifest"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="explorer.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="externals.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="globals.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="i386-stub-win32.c"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="precomp.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="1"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="1"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="1"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="1"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="1"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="1"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="1"\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="precomp.h"\r
-                               >\r
-                       </File>\r
-               </Filter>\r
-               <Filter\r
-                       Name="services"\r
-                       >\r
-                       <File\r
-                               RelativePath="services\shellservices.cpp"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-                       <File\r
-                               RelativePath="services\shellservices.h"\r
-                               >\r
-                       </File>\r
-                       <File\r
-                               RelativePath="services\startup.c"\r
-                               >\r
-                               <FileConfiguration\r
-                                       Name="Unicode Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Unicode Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineRelease|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Debug|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="Release|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                               <FileConfiguration\r
-                                       Name="WineDll|Win32"\r
-                                       >\r
-                                       <Tool\r
-                                               Name="VCCLCompilerTool"\r
-                                               PreprocessorDefinitions=""\r
-                                               UsePrecompiledHeader="0"\r
-                                       />\r
-                               </FileConfiguration>\r
-                       </File>\r
-               </Filter>\r
-       </Files>\r
-       <Globals>\r
-       </Globals>\r
-</VisualStudioProject>\r
diff --git a/reactos/subsys/system/explorer/explorer.xml b/reactos/subsys/system/explorer/explorer.xml
deleted file mode 100644 (file)
index 0385fab..0000000
+++ /dev/null
@@ -1,74 +0,0 @@
-<module name="explorer" type="win32gui" installname="explorer.exe" allowwarnings ="true">
-       <linkerflag>-luuid</linkerflag>
-       <linkerflag>-lstdc++</linkerflag>
-       <linkerflag>-fexceptions</linkerflag>
-       <include base="explorer">.</include>
-       <define name="__USE_W32API" />
-       <define name="UNICODE" />
-       <define name="WIN32" />
-       <define name="_ROS_" />
-       <define name="_WIN32_IE">0x0600</define>
-       <define name="_WIN32_WINNT">0x0501</define>
-       <define name="WINVER">0x0500</define>
-       <define name="__WINDRES__" />
-       <library>kernel32</library>
-       <library>gdi32</library>
-       <library>user32</library>
-       <library>ws2_32</library>
-       <library>msimg32</library>
-       <library>comctl32</library>
-       <library>ole32</library>
-       <library>oleaut32</library>
-       <library>shell32</library>
-       <library>expat</library>
-       <library>notifyhook</library>
-       <pch>precomp.h</pch>
-       <directory name="desktop">
-               <file>desktop.cpp</file>
-       </directory>
-       <directory name="dialogs">
-               <file>searchprogram.cpp</file>
-               <file>settings.cpp</file>
-       </directory>
-       <directory name="shell">
-               <file>entries.cpp</file>
-               <file>fatfs.cpp</file>
-               <file>filechild.cpp</file>
-               <file>shellfs.cpp</file>
-               <file>mainframe.cpp</file>
-               <file>ntobjfs.cpp</file>
-               <file>pane.cpp</file>
-               <file>regfs.cpp</file>
-               <file>shellbrowser.cpp</file>
-               <file>unixfs.cpp</file>
-               <file>webchild.cpp</file>
-               <file>winfs.cpp</file>
-       </directory>
-       <directory name="services">
-               <file>shellservices.cpp</file>
-               <file>startup.c</file>
-       </directory>
-       <directory name="taskbar">
-               <file>desktopbar.cpp</file>
-               <file>favorites.cpp</file>
-               <file>taskbar.cpp</file>
-               <file>startmenu.cpp</file>
-               <file>traynotify.cpp</file>
-               <file>quicklaunch.cpp</file>
-       </directory>
-       <directory name="utility">
-               <file>shellclasses.cpp</file>
-               <file>utility.cpp</file>
-               <file>window.cpp</file>
-               <file>dragdropimpl.cpp</file>
-               <file>shellbrowserimpl.cpp</file>
-               <file>xmlstorage.cpp</file>
-       </directory>
-       <file>explorer.cpp</file>
-       <file>i386-stub-win32.c</file>
-       <file>explorer.rc</file>
-</module>
-<installfile base=".">explorer-cfg-template.xml</installfile>
-<directory name="notifyhook">
-       <xi:include href="notifyhook/notifyhook.xml" />
-</directory>
diff --git a/reactos/subsys/system/explorer/explorer_intres.rc b/reactos/subsys/system/explorer/explorer_intres.rc
deleted file mode 100644 (file)
index 06be918..0000000
+++ /dev/null
@@ -1,223 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include <windows.h>
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// Neutral resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_NEU)
-#ifdef _WIN32
-LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
-#pragma code_page(1252)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Bitmap
-//
-
-IDB_DRIVEBAR            BITMAP  MOVEABLE PURE   "res/drivebar.bmp"
-IDB_LOGOV               BITMAP  MOVEABLE PURE   "res/logov.bmp"
-IDB_LOGOV256            BITMAP  MOVEABLE PURE   "res/logov256.bmp"
-IDB_LOGOV16             BITMAP  MOVEABLE PURE   "res/logov16.bmp"
-IDB_ICON_ALIGN_0        BITMAP  MOVEABLE PURE   "res/icoalig0.bmp"
-IDB_ICON_ALIGN_1        BITMAP  MOVEABLE PURE   "res/icoalig1.bmp"
-IDB_ICON_ALIGN_2        BITMAP  MOVEABLE PURE   "res/icoalig2.bmp"
-IDB_ICON_ALIGN_3        BITMAP  MOVEABLE PURE   "res/icoalig3.bmp"
-IDB_ICON_ALIGN_4        BITMAP  MOVEABLE PURE   "res/icoalig4.bmp"
-IDB_ICON_ALIGN_5        BITMAP  MOVEABLE PURE   "res/icoalig5.bmp"
-IDB_ICON_ALIGN_6        BITMAP  MOVEABLE PURE   "res/icoalig6.bmp"
-IDB_ICON_ALIGN_7        BITMAP  MOVEABLE PURE   "res/icoalig7.bmp"
-IDB_ICON_ALIGN_8        BITMAP  MOVEABLE PURE   "res/icoalig8.bmp"
-IDB_ICON_ALIGN_9        BITMAP  MOVEABLE PURE   "res/icoalig9.bmp"
-IDB_ICON_ALIGN_10       BITMAP  MOVEABLE PURE   "res/icoali10.bmp"
-IDB_MDI                 BITMAP  MOVEABLE PURE   "res/mdi.bmp"
-IDB_SDI                 BITMAP  MOVEABLE PURE   "res/sdi.bmp"
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Accelerator
-//
-
-IDA_EXPLORER ACCELERATORS MOVEABLE PURE 
-BEGIN
-    "X",            ID_FILE_EXIT,           VIRTKEY, ALT, NOINVERT
-    "S",            ID_VIEW_FULLSCREEN,     VIRTKEY, SHIFT, CONTROL, 
-                                                    NOINVERT
-END
-
-IDA_SEARCH_PROGRAM ACCELERATORS MOVEABLE PURE 
-BEGIN
-    VK_F5,          ID_REFRESH,             VIRTKEY, NOINVERT
-END
-
-IDA_TRAYNOTIFY ACCELERATORS MOVEABLE PURE 
-BEGIN
-    VK_F5,          ID_REFRESH,             VIRTKEY, NOINVERT
-END
-
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "#include <windows.h>\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE MOVEABLE PURE 
-BEGIN
-    "#ifndef ROSSHELL\r\n"
-    "IDB_IMAGES BITMAP DISCARDABLE ""res/images.bmp""\r\n"
-    "IDB_TOOLBAR BITMAP DISCARDABLE ""res/toolbar.bmp""\r\n"
-    "#endif\r\n"
-    "#ifndef _ROS_\r\n"
-    "LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL\r\n"
-    "STRINGTABLE DISCARDABLE \r\n"
-    "BEGIN\r\n"
-    "IDS_VERSION_STR """"\r\n"
-    "#ifdef UNICODE\r\n"
-    "IDS_EXPLORER_VERSION_STR ""ROS Explorer%0s""\r\n"
-    "#else\r\n"
-    "IDS_EXPLORER_VERSION_STR ""ROS Explorer Ansi%0s""\r\n"
-    "#endif\r\n"
-    "END\r\n"
-    "#endif\r\n"
-    "#ifndef _DEBUG\r\n"
-    "CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST DISCARDABLE PURE ""explorer.exe.manifest""\r\n"
-    "#endif\r\n"
-    "\r\n"
-    "#include ""explorer-en.rc""\r\n"
-    "#include ""explorer-de.rc""\r\n"
-    "#include ""explorer-es.rc""\r\n"
-    "#include ""explorer-sv.rc""\r\n"
-    "#include ""explorer-pl.rc""\r\n"
-    "#include ""explorer-pt.rc""\r\n"
-    "#include ""explorer-cz.rc""\r\n"
-    "#include ""explorer-ro.rc""\r\n"
-    "#include ""explorer-ru.rc""\r\n"
-    "#include ""explorer-jp.rc""\r\n"
-    "#include ""explorer-hu.rc""\r\n"
-    "#include ""explorer-uk.rc""\r\n"
-    "\r\n"
-    "#ifndef __WINDRES__\r\n"
-    "#include ""explorer-cn.rc""\r\n"
-    "#endif\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Icon
-//
-
-// Icon with lowest ID value placed first to ensure application icon
-// remains consistent on all systems.
-IDI_REACTOS             ICON    DISCARDABLE     "res/reactos.ico"
-IDI_EXPLORER            ICON    DISCARDABLE     "res/explorer.ico"
-IDI_STARTMENU           ICON    DISCARDABLE     "res/startmenu.ico"
-IDI_LOGOFF              ICON    DISCARDABLE     "res/logoff.ico"
-IDI_SHUTDOWN            ICON    DISCARDABLE     "res/shutdown.ico"
-IDI_ARROW               ICON    DISCARDABLE     "res/arrow.ico"
-IDI_ARROW_SELECTED      ICON    DISCARDABLE     "res/arrowsel.ico"
-IDI_APPICON             ICON    DISCARDABLE     "res/appicon.ico"
-IDI_FLOATING            ICON    DISCARDABLE     "res/floating.ico"
-IDI_REACTOS_BIG         ICON    DISCARDABLE     "res/ros-big.ico"
-IDI_CONFIG              ICON    DISCARDABLE     "res/config.ico"
-IDI_DOCUMENTS           ICON    DISCARDABLE     "res/documents.ico"
-IDI_FAVORITES           ICON    DISCARDABLE     "res/favorites.ico"
-IDI_INFO                ICON    DISCARDABLE     "res/info.ico"
-IDI_APPS                ICON    DISCARDABLE     "res/apps.ico"
-IDI_SEARCH              ICON    DISCARDABLE     "res/search.ico"
-IDI_ACTION              ICON    DISCARDABLE     "res/action.ico"
-IDI_FOLDER              ICON    DISCARDABLE     "res/folder.ico"
-IDI_SEARCH_DOC          ICON    DISCARDABLE     "res/search-doc.ico"
-IDI_PRINTER             ICON    DISCARDABLE     "res/printer.ico"
-IDI_NETWORK             ICON    DISCARDABLE     "res/network.ico"
-IDI_COMPUTER            ICON    DISCARDABLE     "res/computer.ico"
-IDI_SPEAKER             ICON    DISCARDABLE     "res/speaker.ico"
-IDI_DOT                 ICON    DISCARDABLE     "res/dot.ico"
-IDI_DOT_TRANS           ICON    DISCARDABLE     "res/dot_trans.ico"
-IDI_DOT_RED             ICON    DISCARDABLE     "res/dot_red.ico"
-IDI_ARROW_UP            ICON    DISCARDABLE     "res/arrow_up.ico"
-IDI_ARROW_DOWN          ICON    DISCARDABLE     "res/arrow_dwn.ico"
-IDI_NOTIFY_L            ICON    DISCARDABLE     "res/notify_l.ico"
-IDI_NOTIFY_R            ICON    DISCARDABLE     "res/notify_r.ico"
-IDI_MINIMIZE            ICON    DISCARDABLE     "res/minimize.ico"
-IDI_CONTROLPAN          ICON    DISCARDABLE     "res/control-panel.ico"
-IDI_DESKSETTING         ICON    DISCARDABLE     "res/desktop-settings.ico"
-IDI_NETCONNS            ICON    DISCARDABLE     "res/network-conns.ico"
-IDI_ADMIN               ICON    DISCARDABLE     "res/administration.ico"
-IDI_RECENT              ICON    DISCARDABLE     "res/recent-documents.ico"
-#endif    // Neutral resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-#ifndef ROSSHELL
-IDB_IMAGES BITMAP DISCARDABLE "res/images.bmp"
-IDB_TOOLBAR BITMAP DISCARDABLE "res/toolbar.bmp"
-#endif
-#ifndef _ROS_
-LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
-STRINGTABLE DISCARDABLE 
-BEGIN
-IDS_VERSION_STR ""
-#ifdef UNICODE
-IDS_EXPLORER_VERSION_STR "ROS Explorer%0s"
-#else
-IDS_EXPLORER_VERSION_STR "ROS Explorer Ansi%0s"
-#endif
-END
-#endif
-#ifndef _DEBUG
-CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST DISCARDABLE PURE "explorer.exe.manifest"
-#endif
-
-#include "explorer-en.rc"
-#include "explorer-de.rc"
-#include "explorer-es.rc"
-#include "explorer-sv.rc"
-#include "explorer-pl.rc"
-#include "explorer-pt.rc"
-#include "explorer-cz.rc"
-#include "explorer-ro.rc"
-#include "explorer-ru.rc"
-#include "explorer-jp.rc"
-#include "explorer-hu.rc"
-#include "explorer-uk.rc"
-
-#ifndef __WINDRES__
-#include "explorer-cn.rc"
-#endif
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/explorer/externals.h b/reactos/subsys/system/explorer/externals.h
deleted file mode 100644 (file)
index 50e7650..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // externals.h
- //
- // Martin Fuchs, 07.06.2003
- //
-
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
- // explorer main routine
-extern int explorer_main(HINSTANCE hinstance, LPTSTR lpCmdLine, int cmdshow);
-
- // display explorer/file manager window
-extern void explorer_show_frame(int cmdshow, LPTSTR lpCmdLine=NULL);
-
- // display explorer "About" dialog
-extern void explorer_about(HWND hwndParent);
-
- // test for already running desktop instance
-extern BOOL IsAnyDesktopRunning();
-
- // show shutdown dialog
-extern void ShowExitWindowsDialog(HWND hwndOwner);
-
-#ifdef __cplusplus
-} // extern "C"
-#endif
-
diff --git a/reactos/subsys/system/explorer/globals.h b/reactos/subsys/system/explorer/globals.h
deleted file mode 100644 (file)
index 63cd373..0000000
+++ /dev/null
@@ -1,348 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // globals.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include "utility/xmlstorage.h"
-
-using namespace XMLStorage;
-
-#include "taskbar/favorites.h"
-
-
- /// management of file types
-struct FileTypeInfo {
-       String  _classname;
-       String  _displayname;
-       bool    _neverShowExt;
-};
-
-struct FileTypeManager : public map<String, FileTypeInfo>
-{
-       typedef map<String, FileTypeInfo> super;
-
-       const FileTypeInfo& operator[](String ext);
-
-       static bool is_exe_file(LPCTSTR ext);
-
-       LPCTSTR set_type(struct Entry* entry, bool dont_hide_ext=false);
-};
-
-
-enum ICON_TYPE {
-       IT_STATIC,
-       IT_CACHED,
-       IT_DYNAMIC,
-       IT_SYSCACHE
-};
-
-enum ICON_ID {
-       ICID_UNKNOWN,
-       ICID_NONE,
-
-       ICID_FOLDER,
-       //ICID_DOCUMENT,
-       ICID_APP,
-       ICID_EXPLORER,
-
-       ICID_CONFIG,
-       ICID_DOCUMENTS,
-       ICID_FAVORITES,
-       ICID_INFO,
-       ICID_APPS,
-       ICID_SEARCH,
-       ICID_ACTION,
-       ICID_SEARCH_DOC,
-       ICID_PRINTER,
-       ICID_NETWORK,
-       ICID_COMPUTER,
-       ICID_LOGOFF,
-    ICID_SHUTDOWN,
-       ICID_BOOKMARK,
-    ICID_MINIMIZE,
-    ICID_CONTROLPAN,
-    ICID_DESKSETTING,
-    ICID_NETCONNS,
-    ICID_ADMIN,
-    ICID_RECENT,
-
-       ICID_DYNAMIC
-};
-
-struct Icon {
-       Icon();
-       Icon(ICON_ID id, UINT nid);
-       Icon(ICON_ID id, UINT nid, int icon_size);
-       Icon(ICON_TYPE itype, int id, HICON hIcon);
-       Icon(ICON_TYPE itype, int id, int sys_idx);
-
-       operator ICON_ID() const {return _id;}
-
-       void    draw(HDC hdc, int x, int y, int cx, int cy, COLORREF bk_color, HBRUSH bk_brush) const;
-       HBITMAP create_bitmap(COLORREF bk_color, HBRUSH hbrBkgnd, HDC hdc_wnd) const;
-       int             add_to_imagelist(HIMAGELIST himl, HDC hdc_wnd, COLORREF bk_color=GetSysColor(COLOR_WINDOW), HBRUSH bk_brush=GetSysColorBrush(COLOR_WINDOW)) const;
-
-       int             get_sysiml_idx() const {return _itype==IT_SYSCACHE? _sys_idx: -1;}
-       HICON   get_hicon() const {return _itype!=IT_SYSCACHE? _hicon: 0;}
-
-       bool    destroy() {if (_itype == IT_DYNAMIC) {DestroyIcon(_hicon); return true;} else return false;}
-
-protected:
-       ICON_ID _id;
-       ICON_TYPE _itype;
-       HICON   _hicon;
-       int             _sys_idx;
-};
-
-struct SysCacheIcon : public Icon {
-       SysCacheIcon(int id, int sys_idx)
-        :      Icon(IT_SYSCACHE, id, sys_idx) {}
-};
-
-struct IconCache {
-       IconCache() : _himlSys_small(0) {}
-
-       void    init();
-
-       const Icon&     extract(LPCTSTR path, ICONCACHE_FLAGS flags=ICF_NORMAL);
-       const Icon&     extract(LPCTSTR path, int icon_idx, ICONCACHE_FLAGS flags=ICF_HICON);
-       const Icon&     extract(IExtractIcon* pExtract, LPCTSTR path, int icon_idx, ICONCACHE_FLAGS flags=ICF_HICON);
-
-       const Icon&     add(HICON hIcon, ICON_TYPE type=IT_DYNAMIC);
-       const Icon&     add(int sys_idx/*, ICON_TYPE type=IT_SYSCACHE*/);
-
-       const Icon&     get_icon(int icon_id);
-
-       HIMAGELIST get_sys_imagelist() const {return _himlSys_small;}
-
-       void    free_icon(int icon_id);
-
-protected:
-       static int s_next_id;
-
-       typedef map<int, Icon> IconMap;
-       IconMap _icons;
-
-       typedef pair<String,int/*ICONCACHE_FLAGS*/> CacheKey;
-       typedef map<CacheKey, ICON_ID> PathCacheMap;
-       PathCacheMap _pathCache;
-
-       typedef pair<String,pair<int,int/*ICONCACHE_FLAGS*/> > IdxCacheKey;
-       typedef map<IdxCacheKey, ICON_ID> IdxCacheMap;
-       IdxCacheMap _idxCache;
-
-       HIMAGELIST _himlSys_small;
-};
-
-
-#define ICON_SIZE_SMALL                16      // GetSystemMetrics(SM_CXSMICON)
-#define ICON_SIZE_MIDDLE       24      // special size for start menu root icons
-#define ICON_SIZE_LARGE                32      // GetSystemMetrics(SM_CXICON)
-
-#define STARTMENUROOT_ICON_SIZE                ICON_SIZE_MIDDLE        // ICON_SIZE_LARGE
-
-#define ICON_SIZE_FROM_ICF(flags)      (flags&ICF_LARGE? ICON_SIZE_LARGE: flags&ICF_MIDDLE? ICON_SIZE_MIDDLE: ICON_SIZE_SMALL)
-#define ICF_FROM_ICON_SIZE(size)       (size>=ICON_SIZE_LARGE? ICF_LARGE: size>=ICON_SIZE_MIDDLE? ICF_MIDDLE: ICF_NORMAL)
-
-
- /// create a bitmap from an icon
-extern HBITMAP create_bitmap_from_icon(HICON hIcon, HBRUSH hbrush_bkgnd, HDC hdc_wnd/*, int icon_size*/);
-
- /// add icon with alpha channel to imagelist using the specified background color
-extern int ImageList_AddAlphaIcon(HIMAGELIST himl, HICON hIcon, HBRUSH hbrush_bkgnd, HDC hdc_wnd);
-
- /// retrieve icon from window
-extern HICON get_window_icon_small(HWND hwnd);
-extern HICON get_window_icon_big(HWND hwnd, bool allow_from_class=true);
-
-
- /// desktop management
-#ifdef _USE_HDESK
-
-typedef auto_ptr<struct DesktopThread> DesktopThreadPtr;
-
-struct Desktop
-{
-       HDESK   _hdesktop;
-//     HWINSTA _hwinsta;
-       DesktopThreadPtr _pThread;
-       WindowHandle _hwndDesktop;
-
-       Desktop(HDESK hdesktop=0/*, HWINSTA hwinsta=0*/);
-       ~Desktop();
-};
-
-typedef auto_ptr<Desktop> DesktopPtr;
-typedef DesktopPtr DesktopRef;
-
- /// Thread class for additional desktops
-struct DesktopThread : public Thread
-{
-       DesktopThread(Desktop& desktop)
-        :      _desktop(desktop)
-       {
-       }
-
-       int     Run();
-
-protected:
-       Desktop&        _desktop;
-};
-
-#else
-
-typedef pair<HWND, DWORD> MinimizeStruct;
-
-struct Desktop
-{
-       set<HWND> _windows;
-       WindowHandle _hwndForeground;
-       list<MinimizeStruct> _minimized;
-};
-typedef Desktop DesktopRef;
-
-#endif
-
-
-#define        DESKTOP_COUNT   4
-
-struct Desktops : public vector<DesktopRef>
-{
-       Desktops();
-       ~Desktops();
-
-       void    init();
-       void    SwitchToDesktop(int idx);
-       void    ToggleMinimize();
-
-#ifdef _USE_HDESK
-       DesktopRef& get_current_Desktop() {return (*this)[_current_desktop];}
-#endif
-
-       int             _current_desktop;
-};
-
-
- /// structure containing global variables of Explorer
-extern struct ExplorerGlobals
-{
-       ExplorerGlobals();
-
-       void    init(HINSTANCE hInstance);
-
-       void    read_persistent();
-       void    write_persistent();
-
-       XMLPos  get_cfg();
-       XMLPos  get_cfg(const char* path);
-
-       HINSTANCE       _hInstance;
-       UINT            _cfStrFName;
-
-#ifndef ROSSHELL
-       ATOM            _hframeClass;
-       HWND            _hMainWnd;
-       bool            _desktop_mode;
-       bool            _prescan_nodes;
-#endif
-
-       FILE*           _log;
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       DWORD(STDAPICALLTYPE* _SHRestricted)(RESTRICTIONS);
-#endif
-
-       FileTypeManager _ftype_mgr;
-       IconCache       _icon_cache;
-
-       HWND            _hwndDesktopBar;
-       HWND            _hwndShellView;
-       HWND            _hwndDesktop;
-
-       Desktops        _desktops;
-
-       XMLDoc          _cfg;
-       String          _cfg_dir;
-       String          _cfg_path;
-
-       Favorites       _favorites;
-       String          _favorites_path;
-} g_Globals;
-
-
- /// convenient loading of string resources
-struct ResString : public String
-{
-       ResString(UINT nid);
-};
-
- /// convenient loading of standard (32x32) icon resources
-struct ResIcon
-{
-       ResIcon(UINT nid);
-
-       operator HICON() const {return _hicon;}
-
-protected:
-       HICON   _hicon;
-};
-
- /// convenient loading of small (16x16) icon resources
-struct SmallIcon
-{
-       SmallIcon(UINT nid);
-
-       operator HICON() const {return _hicon;}
-
-protected:
-       HICON   _hicon;
-};
-
- /// convenient loading of icon resources with specified sizes
-struct ResIconEx
-{
-       ResIconEx(UINT nid, int w, int h);
-
-       operator HICON() const {return _hicon;}
-
-protected:
-       HICON   _hicon;
-};
-
- /// set big and small icons out of the resources for a window
-extern void SetWindowIcon(HWND hwnd, UINT nid);
-
- /// convenient loading of bitmap resources
-struct ResBitmap
-{
-       ResBitmap(UINT nid);
-       ~ResBitmap() {DeleteObject(_hBmp);}
-
-       operator HBITMAP() const {return _hBmp;}
-
-protected:
-       HBITMAP _hBmp;
-};
diff --git a/reactos/subsys/system/explorer/i386-stub-win32.c b/reactos/subsys/system/explorer/i386-stub-win32.c
deleted file mode 100644 (file)
index 3587612..0000000
+++ /dev/null
@@ -1,1278 +0,0 @@
-/****************************************************************************
-
-                               THIS SOFTWARE IS NOT COPYRIGHTED
-
-   HP offers the following for use in the public domain.  HP makes no
-   warranty with regard to the software or it's performance and the
-   user accepts the software "AS IS" with all faults.
-
-   HP DISCLAIMS ANY WARRANTIES, EXPRESS OR IMPLIED, WITH REGARD
-   TO THIS SOFTWARE INCLUDING BUT NOT LIMITED TO THE WARRANTIES
-   OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-
-****************************************************************************/
-
-/****************************************************************************
- *     Header: remcom.c,v 1.34 91/03/09 12:29:49 glenne Exp $
- *
- *     Module name: remcom.c $
- *     Revision: 1.34 $
- *     Date: 91/03/09 12:29:49 $
- *     Contributor:     Lake Stevens Instrument Division$
- *
- *     Description:     low level support for gdb debugger. $
- *
- *     Considerations:  only works on target hardware $
- *
- *     Written by:      Glenn Engel $
- *     ModuleState:     Experimental $
- *
- *     NOTES:                   See Below $
- *
- *     Modified for 386 by Jim Kingdon, Cygnus Support.
- *
- *     To enable debugger support, two things need to happen.  One, a
- *     call to set_debug_traps() is necessary in order to allow any breakpoints
- *     or error conditions to be properly intercepted and reported to gdb.
- *     Two, a breakpoint needs to be generated to begin communication.  This
- *     is most easily accomplished by a call to breakpoint().  Breakpoint()
- *     simulates a breakpoint by executing a trap #1.
- *
- *     The external function exceptionHandler() is
- *     used to attach a specific handler to a specific 386 vector number.
- *     It should use the same privilege level it runs at.      It should
- *     install it as an interrupt gate so that interrupts are masked
- *     while the handler runs.
- *
- *     Because gdb will sometimes write to the stack area to execute function
- *     calls, this program cannot rely on using the supervisor stack so it
- *     uses it's own stack area reserved in the int array remcomStack.
- *
- *************
- *
- *       The following gdb commands are supported:
- *
- * command                     function                                                           Return value
- *
- *       g                     return the value of the CPU registers  hex data or ENN
- *       G                     set the value of the CPU registers         OK or ENN
- *
- *       mAA..AA,LLLL  Read LLLL bytes at address AA..AA          hex data or ENN
- *       MAA..AA,LLLL: Write LLLL bytes at address AA.AA          OK or ENN
- *
- *       c                     Resume at current address                          SNN   ( signal NN)
- *       cAA..AA               Continue at address AA..AA                         SNN
- *
- *       s                     Step one instruction                               SNN
- *       sAA..AA               Step one instruction from AA..AA           SNN
- *
- *       k                     kill
- *
- *       ?                     What was the last sigval ?                         SNN   (signal NN)
- *
- * All commands and responses are sent with a packet which includes a
- * checksum.  A packet consists of
- *
- * $<packet info>#<checksum>.
- *
- * where
- * <packet info> :: <characters representing the command or response>
- * <checksum>   :: < two hex digits computed as modulo 256 sum of <packetinfo>>
- *
- * When a packet is received, it is first acknowledged with either '+' or '-'.
- * '+' indicates a successful transfer.  '-' indicates a failed transfer.
- *
- * Example:
- *
- * Host:                                 Reply:
- * $m0,10#2a                      +$00010203040506070809101112131415#42
- *
- ****************************************************************************/
-
-#include <stdio.h>
-#include <string.h>
-
-#include "utility/utility.h"   // for strcpy_s()
-
-/************************************************************************
- *
- * external low-level support routines
- */
-
-extern void putDebugChar();    /* write a single character      */
-extern int getDebugChar();             /* read and return a single char */
-extern void exceptionHandler(); /* assign an exception handler  */
-
-/************************************************************************/
-/* BUFMAX defines the maximum number of characters in inbound/outbound buffers*/
-/* at least NUMREGBYTES*2 are needed for register packets */
-#define BUFMAX 400
-
-static char initialized;  /* boolean flag. != 0 means we've been initialized */
-
-int    remote_debug;
-/*     debug >  0 prints ill-formed commands in valid packets & checksum errors */
-
-static const char hexchars[]="0123456789abcdef";
-
-/* Number of registers.  */
-#define NUMREGS 16
-
-/* Number of bytes of registers.  */
-#define NUMREGBYTES (NUMREGS * 4)
-
-enum regnames {EAX, ECX, EDX, EBX, ESP, EBP, ESI, EDI,
-                          PC /* also known as eip */,
-                          PS /* also known as eflags */,
-                          CS, SS, DS, ES, FS, GS};
-
-/*
- * these should not be static cuz they can be used outside this module
- */
-int registers[NUMREGS];
-
-#ifndef WIN32 //MF
-
-#define STACKSIZE 10000
-int remcomStack[STACKSIZE/sizeof(int)];
-static int* stackPtr = &remcomStack[STACKSIZE/sizeof(int) - 1];
-
-/***************************  ASSEMBLY CODE MACROS *************************/
-/*                                                                                                                                                */
-
-extern void
-return_to_prog ();
-
-/* Restore the program's registers (including the stack pointer, which
-   means we get the right stack and don't have to worry about popping our
-   return address and any stack frames and so on) and return.  */
-asm(".text");
-asm(".globl _return_to_prog");
-asm("_return_to_prog:");
-asm("        movw _registers+44, %ss");
-asm("        movl _registers+16, %esp");
-asm("        movl _registers+4, %ecx");
-asm("        movl _registers+8, %edx");
-asm("        movl _registers+12, %ebx");
-asm("        movl _registers+20, %ebp");
-asm("        movl _registers+24, %esi");
-asm("        movl _registers+28, %edi");
-asm("        movw _registers+48, %ds");
-asm("        movw _registers+52, %es");
-asm("        movw _registers+56, %fs");
-asm("        movw _registers+60, %gs");
-asm("        movl _registers+36, %eax");
-asm("        pushl %eax");     /* saved eflags */
-asm("        movl _registers+40, %eax");
-asm("        pushl %eax");     /* saved cs */
-asm("        movl _registers+32, %eax");
-asm("        pushl %eax");     /* saved eip */
-asm("        movl _registers, %eax");
-
-asm("ret");    //MF
-
-/* use iret to restore pc and flags together so
-   that trace flag works right.  */
-asm("        iret");
-
-
-#ifdef WIN32 //MF
-asm(".data"); //MF
-#endif
-
-/* Put the error code here just in case the user cares.  */
-int gdb_i386errcode;
-/* Likewise, the vector number here (since GDB only gets the signal
-   number through the usual means, and that's not very specific).  */
-int gdb_i386vector = -1;
-
-/* GDB stores segment registers in 32-bit words (that's just the way
-   m-i386v.h is written).  So zero the appropriate areas in registers. */
-#define SAVE_REGISTERS1() \
-  asm ("movl %eax, _registers");                                                                                 \
-  asm ("movl %ecx, _registers+4");                                                                                      \
-  asm ("movl %edx, _registers+8");                                                                                      \
-  asm ("movl %ebx, _registers+12");                                                                             \
-  asm ("movl %ebp, _registers+20");                                                                             \
-  asm ("movl %esi, _registers+24");                                                                             \
-  asm ("movl %edi, _registers+28");                                                                             \
-  asm ("movw $0, %ax");                                                                                                         \
-  asm ("movw %ds, _registers+48");                                                                                      \
-  asm ("movw %ax, _registers+50");                                                                                      \
-  asm ("movw %es, _registers+52");                                                                                      \
-  asm ("movw %ax, _registers+54");                                                                                      \
-  asm ("movw %fs, _registers+56");                                                                                      \
-  asm ("movw %ax, _registers+58");                                                                                      \
-  asm ("movw %gs, _registers+60");                                                                                      \
-  asm ("movw %ax, _registers+62");
-#define SAVE_ERRCODE() \
-  asm ("popl %ebx");                                                             \
-  asm ("movl %ebx, _gdb_i386errcode");
-#define SAVE_REGISTERS2() \
-  asm ("popl %ebx"); /* old eip */                                                                                      \
-  asm ("movl %ebx, _registers+32");                                                                             \
-  asm ("popl %ebx");    /* old cs */                                                                            \
-  asm ("movl %ebx, _registers+40");                                                                             \
-  asm ("movw %ax, _registers+42");                                                                                      \
-  asm ("popl %ebx");    /* old eflags */                                                                        \
-  asm ("movl %ebx, _registers+36");                                                                             \
-  /* Now that we've done the pops, we can save the stack pointer.");  */   \
-  asm ("movw %ss, _registers+44");                                                                                      \
-  asm ("movw %ax, _registers+46");                                                                                      \
-  asm ("movl %esp, _registers+16");
-
-/* See if mem_fault_routine is set, if so just IRET to that address.  */
-#define CHECK_FAULT() \
-  asm ("cmpl $0, _mem_fault_routine");                                                                    \
-  asm ("jne mem_fault");
-
-asm (".text");
-asm ("mem_fault:");
-/* OK to clobber temp registers; we're just going to end up in set_mem_err.  */
-/* Pop error code from the stack and save it.  */
-asm ("     popl %eax");
-asm ("     movl %eax, _gdb_i386errcode");
-
-asm ("     popl %eax"); /* eip */
-/* We don't want to return there, we want to return to the function
-   pointed to by mem_fault_routine instead.  */
-asm ("     movl _mem_fault_routine, %eax");
-asm ("     popl %ecx"); /* cs (low 16 bits; junk in hi 16 bits).  */
-asm ("     popl %edx"); /* eflags */
-
-/* Remove this stack frame; when we do the iret, we will be going to
-   the start of a function, so we want the stack to look just like it
-   would after a "call" instruction.  */
-asm ("     leave");
-
-/* Push the stuff that iret wants.     */
-asm ("     pushl %edx"); /* eflags */
-asm ("     pushl %ecx"); /* cs */
-asm ("     pushl %eax"); /* eip */
-
-/* Zero mem_fault_routine.     */
-asm ("     movl $0, %eax");
-asm ("     movl %eax, _mem_fault_routine");
-
-asm ("iret");
-
-
-#define CALL_HOOK() asm("call _remcomHandler");
-
-/* This function is called when a i386 exception occurs.  It saves
- * all the cpu regs in the _registers array, munges the stack a bit,
- * and invokes an exception handler (remcom_handler).
- *
- * stack on entry:                                              stack on exit:
- *      old eflags                                              vector number
- *      old cs (zero-filled to 32 bits)
- *      old eip
- *
- */
-extern void _catchException3();
-asm(".text");
-asm(".globl __catchException3");
-asm("__catchException3:");
-SAVE_REGISTERS1();
-SAVE_REGISTERS2();
-asm ("pushl $3");
-CALL_HOOK();
-
-/* Same thing for exception 1. */
-extern void _catchException1();
-asm(".text");
-asm(".globl __catchException1");
-asm("__catchException1:");
-SAVE_REGISTERS1();
-SAVE_REGISTERS2();
-asm ("pushl $1");
-CALL_HOOK();
-
-/* Same thing for exception 0. */
-extern void _catchException0();
-asm(".text");
-asm(".globl __catchException0");
-asm("__catchException0:");
-SAVE_REGISTERS1();
-SAVE_REGISTERS2();
-asm ("pushl $0");
-CALL_HOOK();
-
-/* Same thing for exception 4. */
-extern void _catchException4();
-asm(".text");
-asm(".globl __catchException4");
-asm("__catchException4:");
-SAVE_REGISTERS1();
-SAVE_REGISTERS2();
-asm ("pushl $4");
-CALL_HOOK();
-
-/* Same thing for exception 5. */
-extern void _catchException5();
-asm(".text");
-asm(".globl __catchException5");
-asm("__catchException5:");
-SAVE_REGISTERS1();
-SAVE_REGISTERS2();
-asm ("pushl $5");
-CALL_HOOK();
-
-/* Same thing for exception 6. */
-extern void _catchException6();
-asm(".text");
-asm(".globl __catchException6");
-asm("__catchException6:");
-SAVE_REGISTERS1();
-SAVE_REGISTERS2();
-asm ("pushl $6");
-CALL_HOOK();
-
-/* Same thing for exception 7. */
-extern void _catchException7();
-asm(".text");
-asm(".globl __catchException7");
-asm("__catchException7:");
-SAVE_REGISTERS1();
-SAVE_REGISTERS2();
-asm ("pushl $7");
-CALL_HOOK();
-
-/* Same thing for exception 8. */
-extern void _catchException8();
-asm(".text");
-asm(".globl __catchException8");
-asm("__catchException8:");
-SAVE_REGISTERS1();
-SAVE_ERRCODE();
-SAVE_REGISTERS2();
-asm ("pushl $8");
-CALL_HOOK();
-
-/* Same thing for exception 9. */
-extern void _catchException9();
-asm(".text");
-asm(".globl __catchException9");
-asm("__catchException9:");
-SAVE_REGISTERS1();
-SAVE_REGISTERS2();
-asm ("pushl $9");
-CALL_HOOK();
-
-/* Same thing for exception 10.  */
-extern void _catchException10();
-asm(".text");
-asm(".globl __catchException10");
-asm("__catchException10:");
-SAVE_REGISTERS1();
-SAVE_ERRCODE();
-SAVE_REGISTERS2();
-asm ("pushl $10");
-CALL_HOOK();
-
-/* Same thing for exception 12.  */
-extern void _catchException12();
-asm(".text");
-asm(".globl __catchException12");
-asm("__catchException12:");
-SAVE_REGISTERS1();
-SAVE_ERRCODE();
-SAVE_REGISTERS2();
-asm ("pushl $12");
-CALL_HOOK();
-
-/* Same thing for exception 16.  */
-extern void _catchException16();
-asm(".text");
-asm(".globl __catchException16");
-asm("__catchException16:");
-SAVE_REGISTERS1();
-SAVE_REGISTERS2();
-asm ("pushl $16");
-CALL_HOOK();
-
-/* For 13, 11, and 14 we have to deal with the CHECK_FAULT stuff.  */
-
-/* Same thing for exception 13.  */
-extern void _catchException13 ();
-asm (".text");
-asm (".globl __catchException13");
-asm ("__catchException13:");
-CHECK_FAULT();
-SAVE_REGISTERS1();
-SAVE_ERRCODE();
-SAVE_REGISTERS2();
-asm ("pushl $13");
-CALL_HOOK();
-
-/* Same thing for exception 11.  */
-extern void _catchException11 ();
-asm (".text");
-asm (".globl __catchException11");
-asm ("__catchException11:");
-CHECK_FAULT();
-SAVE_REGISTERS1();
-SAVE_ERRCODE();
-SAVE_REGISTERS2();
-asm ("pushl $11");
-CALL_HOOK();
-
-/* Same thing for exception 14.  */
-extern void _catchException14 ();
-asm (".text");
-asm (".globl __catchException14");
-asm ("__catchException14:");
-CHECK_FAULT();
-SAVE_REGISTERS1();
-SAVE_ERRCODE();
-SAVE_REGISTERS2();
-asm ("pushl $14");
-CALL_HOOK();
-
-/*
- * remcomHandler is a front end for handle_exception.  It moves the
- * stack pointer into an area reserved for debugger use.
- */
-asm("_remcomHandler:");
-asm("           popl %eax");           /* pop off return address         */
-asm("           popl %eax");     /* get the exception number   */
-asm("          movl _stackPtr, %esp"); /* move to remcom stack area  */
-asm("          pushl %eax");    /* push exception onto stack  */
-asm("          call  _handle_exception");        /* this never returns */
-
-
-void
-_returnFromException ()
-{
-  return_to_prog ();
-}
-
-#endif // !WIN32
-
-
-#ifdef _MSC_VER //MF
-#define BREAKPOINT() __asm int 3;
-#else
-#define BREAKPOINT() asm("   int $3");
-#endif
-
-
-#ifdef WIN32 //MF
-
-#define WIN32_LEAN_AND_MEAN
-#include <windows.h>
-
-void handle_exception(int exceptionVector);
-
-void win32_exception_handler(EXCEPTION_POINTERS* exc_info)
-{
-  PCONTEXT ctx = exc_info->ContextRecord;
-
-  registers[EAX] = ctx->Eax;
-  registers[ECX] = ctx->Ecx;
-  registers[EDX] = ctx->Edx;
-  registers[EBX] = ctx->Ebx;
-  registers[ESP] = ctx->Esp;
-  registers[EBP] = ctx->Ebp;
-  registers[ESI] = ctx->Esi;
-  registers[EDI] = ctx->Edi;
-   registers[PC] = ctx->Eip;
-   registers[PS] = ctx->EFlags;
-  registers[CS] = ctx->SegCs;
-  registers[SS] = ctx->SegSs;
-  registers[DS] = ctx->SegDs;
-  registers[ES] = ctx->SegEs;
-  registers[FS] = ctx->SegFs;
-  registers[GS] = ctx->SegGs;
-
-  handle_exception(exc_info->ExceptionRecord->ExceptionCode & 0xFFFF);
-
-  ctx->Eax = registers[EAX];
-  ctx->Ecx = registers[ECX];
-  ctx->Edx = registers[EDX];
-  ctx->Ebx = registers[EBX];
-  ctx->Esp = registers[ESP];
-  ctx->Ebp = registers[EBP];
-  ctx->Esi = registers[ESI];
-  ctx->Edi = registers[EDI];
-   ctx->Eip = registers[PC];
-   ctx->EFlags = registers[PS];
-  ctx->SegCs = registers[CS];
-  ctx->SegSs = registers[SS];
-  ctx->SegDs = registers[DS];
-  ctx->SegEs = registers[ES];
-  ctx->SegFs = registers[FS];
-  ctx->SegGs = registers[GS];
-}
-
-#endif // WIN32
-
-
-int
-hex (ch)
-        char ch;
-{
-  if ((ch >= 'a') && (ch <= 'f'))
-       return (ch - 'a' + 10);
-  if ((ch >= '0') && (ch <= '9'))
-       return (ch - '0');
-  if ((ch >= 'A') && (ch <= 'F'))
-       return (ch - 'A' + 10);
-  return (-1);
-}
-
-static char remcomInBuffer[BUFMAX];
-static char remcomOutBuffer[BUFMAX];
-
-/* scan for the sequence $<data>#<checksum>    */
-
-char *
-getpacket (void)
-{
-  char *buffer = &remcomInBuffer[0];
-  unsigned char checksum;
-  unsigned char xmitcsum;
-  int count;
-  char ch;
-
-  while (1)
-       {
-         /* wait around for the start character, ignore all other characters */
-         while ((ch = getDebugChar ()) != '$')
-               ;
-
-       retry:
-         checksum = 0;
-         xmitcsum = -1;
-         count = 0;
-
-         /* now, read until a # or end of buffer is found */
-         while (count < BUFMAX)
-               {
-                 ch = getDebugChar ();
-                 if (ch == '$')
-                       goto retry;
-                 if (ch == '#')
-                       break;
-                 checksum = checksum + ch;
-                 buffer[count] = ch;
-                 count = count + 1;
-               }
-         buffer[count] = 0;
-
-         if (ch == '#')
-               {
-                 ch = getDebugChar ();
-                 xmitcsum = hex (ch) << 4;
-                 ch = getDebugChar ();
-                 xmitcsum += hex (ch);
-
-                 if (checksum != xmitcsum)
-                       {
-                         if (remote_debug)
-                               {
-                                 fprintf (stderr,
-                                                  "bad checksum.  My count = 0x%x, sent=0x%x. buf=%s\n",
-                                                  checksum, xmitcsum, buffer);
-                               }
-                         putDebugChar ('-');           /* failed checksum */
-                       }
-                 else
-                       {
-                         putDebugChar ('+');           /* successful transfer */
-
-                         /* if a sequence char is present, reply the sequence ID */
-                         if (buffer[2] == ':')
-                               {
-                                 putDebugChar (buffer[0]);
-                                 putDebugChar (buffer[1]);
-
-                                 return &buffer[3];
-                               }
-
-                         return &buffer[0];
-                       }
-               }
-       }
-}
-
-/* send the packet in buffer.  */
-
-void
-putpacket (char *buffer)
-{
-  unsigned char checksum;
-  int count;
-  char ch;
-
-  /*  $<packet info>#<checksum>. */
-  do
-       {
-         putDebugChar ('$');
-         checksum = 0;
-         count = 0;
-
-         while ((ch = buffer[count]) != 0)
-               {
-                 putDebugChar (ch);
-                 checksum += ch;
-                 count += 1;
-               }
-
-         putDebugChar ('#');
-         putDebugChar (hexchars[checksum >> 4]);
-         putDebugChar (hexchars[checksum % 16]);
-
-       }
-  while (getDebugChar () != '+');
-}
-
-void debug_error (char* format/*, char* parm*/)
-{
-  if (remote_debug)
-    fprintf (stderr, format/*, parm*/);
-}
-
-/* Address of a routine to RTE to if we get a memory fault.  */
-static void (*volatile mem_fault_routine) () = NULL;
-
-/* Indicate to caller of mem2hex or hex2mem that there has been an
-   error.  */
-static volatile int mem_err = 0;
-
-void
-set_mem_err (void)
-{
-  mem_err = 1;
-}
-
-/* These are separate functions so that they are so short and sweet
-   that the compiler won't save any registers (if there is a fault
-   to mem_fault, they won't get restored, so there better not be any
-   saved).     */
-int
-get_char (char *addr)
-{
-  return *addr;
-}
-
-void
-set_char (char *addr, int val)
-{
-  *addr = val;
-}
-
-/* convert the memory pointed to by mem into hex, placing result in buf */
-/* return a pointer to the last char put in buf (null) */
-/* If MAY_FAULT is non-zero, then we should set mem_err in response to
-   a fault; if zero treat a fault like any other fault in the stub.  */
-char *
-mem2hex (mem, buf, count, may_fault)
-        char *mem;
-        char *buf;
-        int count;
-        int may_fault;
-{
-  int i;
-  unsigned char ch;
-
-#ifdef WIN32 //MF
-  if (IsBadReadPtr(mem, count))
-       return mem;
-#else
-  if (may_fault)
-       mem_fault_routine = set_mem_err;
-#endif
-  for (i = 0; i < count; i++)
-       {
-         ch = get_char (mem++);
-         if (may_fault && mem_err)
-               return (buf);
-         *buf++ = hexchars[ch >> 4];
-         *buf++ = hexchars[ch % 16];
-       }
-  *buf = 0;
-#ifndef WIN32 //MF
-  if (may_fault)
-       mem_fault_routine = NULL;
-#endif
-  return (buf);
-}
-
-/* convert the hex array pointed to by buf into binary to be placed in mem */
-/* return a pointer to the character AFTER the last byte written */
-char *
-hex2mem (buf, mem, count, may_fault)
-        char *buf;
-        char *mem;
-        int count;
-        int may_fault;
-{
-  int i;
-  unsigned char ch;
-
-#ifdef WIN32 //MF
-   // MinGW does not support structured exception handling, so let's
-   // go safe and make memory writable by default
-  DWORD old_protect;
-
-  VirtualProtect(mem, count, PAGE_EXECUTE_READWRITE, &old_protect);
-#else
-  if (may_fault)
-       mem_fault_routine = set_mem_err;
-#endif
-
-  for (i = 0; i < count; i++)
-       {
-         ch = hex (*buf++) << 4;
-         ch = ch + hex (*buf++);
-         set_char (mem++, ch);
-         if (may_fault && mem_err)
-               return (mem);
-       }
-
-#ifndef WIN32 //MF
-  if (may_fault)
-       mem_fault_routine = NULL;
-#endif
-
-  return (mem);
-}
-
-/* this function takes the 386 exception vector and attempts to
-   translate this number into a unix compatible signal value */
-int
-computeSignal (int exceptionVector)
-{
-  int sigval;
-  switch (exceptionVector)
-       {
-       case 0:
-         sigval = 8;
-         break;                                        /* divide by zero */
-       case 1:
-         sigval = 5;
-         break;                                        /* debug exception */
-       case 3:
-         sigval = 5;
-         break;                                        /* breakpoint */
-       case 4:
-         sigval = 16;
-         break;                                        /* into instruction (overflow) */
-       case 5:
-         sigval = 16;
-         break;                                        /* bound instruction */
-       case 6:
-         sigval = 4;
-         break;                                        /* Invalid opcode */
-       case 7:
-         sigval = 8;
-         break;                                        /* coprocessor not available */
-       case 8:
-         sigval = 7;
-         break;                                        /* double fault */
-       case 9:
-         sigval = 11;
-         break;                                        /* coprocessor segment overrun */
-       case 10:
-         sigval = 11;
-         break;                                        /* Invalid TSS */
-       case 11:
-         sigval = 11;
-         break;                                        /* Segment not present */
-       case 12:
-         sigval = 11;
-         break;                                        /* stack exception */
-       case 13:
-         sigval = 11;
-         break;                                        /* general protection */
-       case 14:
-         sigval = 11;
-         break;                                        /* page fault */
-       case 16:
-         sigval = 7;
-         break;                                        /* coprocessor error */
-       default:
-         sigval = 7;                           /* "software generated" */
-       }
-  return (sigval);
-}
-
-/**********************************************/
-/* WHILE WE FIND NICE HEX CHARS, BUILD AN INT */
-/* RETURN NUMBER OF CHARS PROCESSED              */
-/**********************************************/
-int
-hexToInt (char **ptr, int *intValue)
-{
-  int numChars = 0;
-  int hexValue;
-
-  *intValue = 0;
-
-  while (**ptr)
-       {
-         hexValue = hex (**ptr);
-         if (hexValue >= 0)
-               {
-                 *intValue = (*intValue << 4) | hexValue;
-                 numChars++;
-               }
-         else
-               break;
-
-         (*ptr)++;
-       }
-
-  return (numChars);
-}
-
-/*
- * This function does all command procesing for interfacing to gdb.
- */
-void
-handle_exception (int exceptionVector)
-{
-  int sigval, stepping;
-  int addr, length;
-  char *ptr;
-  int newPC;
-
-#ifndef WIN32 //MF
-  gdb_i386vector = exceptionVector;
-#endif
-
-  if (remote_debug)
-       {
-         printf ("vector=%d, sr=0x%x, pc=0x%x\n",
-                         exceptionVector, registers[PS], registers[PC]);
-       }
-
-  /* reply to host that an exception has occurred */
-  sigval = computeSignal (exceptionVector);
-
-  ptr = remcomOutBuffer;
-
-  *ptr++ = 'T';                                /* notify gdb with signo, PC, FP and SP */
-  *ptr++ = hexchars[sigval >> 4];
-  *ptr++ = hexchars[sigval & 0xf];
-
-  *ptr++ = hexchars[ESP];
-  *ptr++ = ':';
-  ptr = mem2hex((char *)&registers[ESP], ptr, 4, 0);   /* SP */
-  *ptr++ = ';';
-
-  *ptr++ = hexchars[EBP];
-  *ptr++ = ':';
-  ptr = mem2hex((char *)&registers[EBP], ptr, 4, 0);   /* FP */
-  *ptr++ = ';';
-
-  *ptr++ = hexchars[PC];
-  *ptr++ = ':';
-  ptr = mem2hex((char *)&registers[PC], ptr, 4, 0);    /* PC */
-  *ptr++ = ';';
-
-  *ptr = '\0';
-
-  putpacket (remcomOutBuffer);
-
-  stepping = 0;
-
-  while (1 == 1)
-       {
-         remcomOutBuffer[0] = 0;
-         ptr = getpacket ();
-
-         switch (*ptr++)
-               {
-               case '?':
-                 remcomOutBuffer[0] = 'S';
-                 remcomOutBuffer[1] = hexchars[sigval >> 4];
-                 remcomOutBuffer[2] = hexchars[sigval % 16];
-                 remcomOutBuffer[3] = 0;
-                 break;
-               case 'd':
-                 remote_debug = !(remote_debug);               /* toggle debug flag */
-                 break;
-               case 'g':                               /* return the value of the CPU registers */
-                 mem2hex ((char *) registers, remcomOutBuffer, NUMREGBYTES, 0);
-                 break;
-               case 'G':                               /* set the value of the CPU registers - return OK */
-                 hex2mem (ptr, (char *) registers, NUMREGBYTES, 0);
-                 strcpy_s(remcomOutBuffer, BUFMAX, "OK");
-                 break;
-               case 'P':                               /* set the value of a single CPU register - return OK */
-                 {
-                       int regno;
-
-                       if (hexToInt (&ptr, &regno) && *ptr++ == '=')
-                         if (regno >= 0 && regno < NUMREGS)
-                               {
-                                 hex2mem (ptr, (char *) &registers[regno], 4, 0);
-                                 strcpy_s(remcomOutBuffer, BUFMAX, "OK");
-                                 break;
-                               }
-
-                       strcpy_s(remcomOutBuffer, BUFMAX, "E01");
-                       break;
-                 }
-
-                 /* mAA..AA,LLLL  Read LLLL bytes at address AA..AA */
-               case 'm':
-                 /* TRY TO READ %x,%x.  IF SUCCEED, SET PTR = 0 */
-                 if (hexToInt (&ptr, &addr))
-                       if (*(ptr++) == ',')
-                         if (hexToInt (&ptr, &length))
-                               {
-                                 ptr = 0;
-                                 mem_err = 0;
-                                 mem2hex ((char *) addr, remcomOutBuffer, length, 1);
-                                 if (mem_err)
-                                       {
-                                         strcpy_s(remcomOutBuffer, BUFMAX, "E03");
-                                         debug_error ("memory fault");
-                                       }
-                               }
-
-                 if (ptr)
-                       {
-                         strcpy_s(remcomOutBuffer, BUFMAX, "E01");
-                       }
-                 break;
-
-                 /* MAA..AA,LLLL: Write LLLL bytes at address AA.AA return OK */
-               case 'M':
-                 /* TRY TO READ '%x,%x:'.      IF SUCCEED, SET PTR = 0 */
-                 if (hexToInt (&ptr, &addr))
-                       if (*(ptr++) == ',')
-                         if (hexToInt (&ptr, &length))
-                               if (*(ptr++) == ':')
-                                 {
-                                       mem_err = 0;
-                                       hex2mem (ptr, (char *) addr, length, 1);
-
-                                       if (mem_err)
-                                         {
-                                               strcpy_s(remcomOutBuffer, BUFMAX, "E03");
-                                               debug_error ("memory fault");
-                                         }
-                                       else
-                                         {
-                                               strcpy_s(remcomOutBuffer, BUFMAX, "OK");
-                                         }
-
-                                       ptr = 0;
-                                 }
-                 if (ptr)
-                       {
-                         strcpy_s(remcomOutBuffer, BUFMAX, "E02");
-                       }
-                 break;
-
-                 /* cAA..AA    Continue at address AA..AA(optional) */
-                 /* sAA..AA   Step one instruction from AA..AA(optional) */
-               case 's':
-                 stepping = 1;
-               case 'c':
-                 /* try to read optional parameter, pc unchanged if no parm */
-                 if (hexToInt (&ptr, &addr))
-                       registers[PC] = addr;
-
-                 newPC = registers[PC];
-
-                 /* clear the trace bit */
-                 registers[PS] &= 0xfffffeff;
-
-                 /* set the trace bit if we're stepping */
-                 if (stepping)
-                       registers[PS] |= 0x100;
-
-#ifdef WIN32 //MF
-                 return;
-#else
-                 _returnFromException ();              /* this is a jump */
-#endif
-                 break;
-
-                 /* kill the program */
-               case 'k':                               /* do nothing */
-#if 0
-                 /* Huh? This doesn't look like "nothing".
-                        m68k-stub.c and sparc-stub.c don't have it.  */
-                 BREAKPOINT ();
-#endif
-                 break;
-               }                                               /* switch */
-
-         /* reply to the request */
-         putpacket (remcomOutBuffer);
-       }
-}
-
-/* this function is used to set up exception handlers for tracing and
-   breakpoints */
-void
-set_debug_traps (void)
-{
-#ifndef WIN32 //MF
-  stackPtr = &remcomStack[STACKSIZE / sizeof (int) - 1];
-
-  exceptionHandler (0, _catchException0);
-  exceptionHandler (1, _catchException1);
-  exceptionHandler (3, _catchException3);
-  exceptionHandler (4, _catchException4);
-  exceptionHandler (5, _catchException5);
-  exceptionHandler (6, _catchException6);
-  exceptionHandler (7, _catchException7);
-  exceptionHandler (8, _catchException8);
-  exceptionHandler (9, _catchException9);
-  exceptionHandler (10, _catchException10);
-  exceptionHandler (11, _catchException11);
-  exceptionHandler (12, _catchException12);
-  exceptionHandler (13, _catchException13);
-  exceptionHandler (14, _catchException14);
-  exceptionHandler (16, _catchException16);
-#endif // WIN32
-
-  initialized = 1;
-}
-
-/* This function will generate a breakpoint exception. It is used at the
-   beginning of a program to sync up with a debugger and can be used
-   otherwise as a quick means to stop program execution and "break" into
-   the debugger. */
-
-void
-breakpoint (void)
-{
-  if (initialized)
-       BREAKPOINT ();
-}
-
-
-
- //
- // debugger stub implementation for WIN32 applications
- // M. Fuchs, 29.11.2003
- //
-
-#ifdef WIN32
-
-#include <stdlib.h>
-#include <errno.h>
-
-#include "utility/utility.h"
-
-
-int s_initial_breakpoint = 0;
-
-
-#ifdef DEBUG_SERIAL
-
-FILE* ser_port = NULL;
-
-int init_gdb_connect()
-{
-                //TODO: set up connection using serial communication port
-
-               ser_port = fopen("COM1:", "rwb");
-
-               return 1;
-}
-
-int getDebugChar()
-{
-               return fgetc(ser_port);
-}
-
-void putDebugChar(int c)
-{
-               fputc(c, ser_port);
-}
-
-
-#else // DEBUG_SERIAL
-
-
-static LPTOP_LEVEL_EXCEPTION_FILTER s_prev_exc_handler = 0;
-
-
-#define I386_EXCEPTION_CNT             17
-
-LONG WINAPI exc_protection_handler(EXCEPTION_POINTERS* exc_info)
-{
-               int exc_nr = exc_info->ExceptionRecord->ExceptionCode & 0xFFFF;
-
-               if (exc_nr < I386_EXCEPTION_CNT) {
-                               //LOG(FmtString(TEXT("exc_protection_handler: Exception %x"), exc_nr));
-
-                               if (exc_nr==11 || exc_nr==13 || exc_nr==14) {
-                                               if (mem_fault_routine)
-                                                               mem_fault_routine();
-                               }
-
-                               ++exc_info->ContextRecord->Eip;
-               }
-
-               return EXCEPTION_CONTINUE_EXECUTION;
-}
-
-LONG WINAPI exc_handler(EXCEPTION_POINTERS* exc_info)
-{
-               int exc_nr = exc_info->ExceptionRecord->ExceptionCode & 0xFFFF;
-
-               if (exc_nr < I386_EXCEPTION_CNT) {
-                               //LOG(FmtString("Exception %x", exc_nr));
-                               //LOG(FmtString("EIP=%08X EFLAGS=%08X", exc_info->ContextRecord->Eip, exc_info->ContextRecord->EFlags));
-
-                                // step over initial breakpoint
-                               if (s_initial_breakpoint) {
-                                               s_initial_breakpoint = 0;
-                                               ++exc_info->ContextRecord->Eip;
-                               }
-
-                               SetUnhandledExceptionFilter(exc_protection_handler);
-
-                               win32_exception_handler(exc_info);
-                               //LOG(FmtString("EIP=%08X EFLAGS=%08X", exc_info->ContextRecord->Eip, exc_info->ContextRecord->EFlags));
-
-                               SetUnhandledExceptionFilter(exc_handler);
-
-                               return EXCEPTION_CONTINUE_EXECUTION;
-               }
-
-               return EXCEPTION_CONTINUE_SEARCH;
-}
-
-/* not needed because we use win32_exception_handler() instead of catchExceptionX()
-void exceptionHandler(int exc_nr, void* exc_addr)
-{
-               if (exc_nr>=0 && exc_nr<I386_EXCEPTION_CNT)
-                               exc_handlers[exc_nr] = exc_addr;
-}
-*/
-
-void disable_debugging()
-{
-               if (s_prev_exc_handler) {
-                               SetUnhandledExceptionFilter(s_prev_exc_handler);
-                               s_prev_exc_handler = 0;
-               }
-}
-
-
-#include <winsock.h>
-#ifdef _MSC_VER
-#pragma comment(lib, "wsock32")
-#endif
-
-static int s_rem_fd = -1;
-
-int init_gdb_connect()
-{
-               SOCKADDR_IN srv_addr = {0};
-               SOCKADDR_IN rem_addr;
-               WSADATA wsa_data;
-               int srv_socket, rem_len;
-
-               s_prev_exc_handler = SetUnhandledExceptionFilter(exc_handler);
-
-               if (WSAStartup(MAKEWORD(2,2), &wsa_data)) {
-                               fprintf(stderr, "WSAStartup() failed");
-                               return 0;
-               }
-
-               srv_addr.sin_family = AF_INET;
-               srv_addr.sin_addr.s_addr = htonl(INADDR_ANY);
-               srv_addr.sin_port = htons(9999);
-
-               srv_socket = socket(PF_INET, SOCK_STREAM, 0);
-               if (srv_socket == -1) {
-                               perror("socket()");
-                               return 0;
-               }
-
-               if (bind(srv_socket, (struct sockaddr*) &srv_addr, sizeof(srv_addr)) == -1) {
-                               perror("bind()");
-                               return 0;
-               }
-
-               if (listen(srv_socket, 4) == -1) {
-                               perror("listen()");
-                               return 0;
-               }
-
-               rem_len = sizeof(rem_addr);
-
-               for(;;) {
-                               s_rem_fd = accept(srv_socket, (struct sockaddr*)&rem_addr, &rem_len);
-
-                               if (s_rem_fd < 0) {
-                                               if (errno == EINTR)
-                                                               continue;
-
-                                               perror("accept()");
-                                               return 0;
-                               }
-
-                               break;
-               }
-
-               return 1;
-}
-
-#endif // DEBUG_SERIAL
-
-
-int getDebugChar()
-{
-               char buffer[1024];
-               int r;
-
-               if (s_rem_fd == -1)
-                               return EOF;
-
-               r = recv(s_rem_fd, buffer, 1, 0);
-               if (r == -1) {
-                               perror("recv()");
-                               LOG(TEXT("debugger connection broken"));
-                               s_rem_fd = -1;
-                               return EOF;
-               }
-
-               if (!r)
-                               return EOF;
-
-               return buffer[0];
-}
-
-void putDebugChar(int c)
-{
-               if (s_rem_fd != -1) {
-                               const char buffer[] = {c};
-
-                               if (!send(s_rem_fd, buffer, 1, 0)) {
-                                               perror("send()");
-                                               LOG(TEXT("debugger connection broken"));
-                                               exit(-1);
-                               }
-               }
-}
-
-
- // start up GDB stub interface
-
-int initialize_gdb_stub()
-{
-               if (!init_gdb_connect())
-                               return 0;
-
-               set_debug_traps();
-
-               s_initial_breakpoint = 1;
-               breakpoint();
-
-               return 1;
-}
-
-#endif // WIN32
diff --git a/reactos/subsys/system/explorer/make-docu.sh b/reactos/subsys/system/explorer/make-docu.sh
deleted file mode 100755 (executable)
index 7894b44..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-sed 's/@GEN@/generated on '`date +%d.%m.%Y`/ <doxy-footer.htmt >doxy-footer.html
-doxygen Doxyfile
diff --git a/reactos/subsys/system/explorer/make-full-docu.bat b/reactos/subsys/system/explorer/make-full-docu.bat
deleted file mode 100755 (executable)
index e4a7b41..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-doxygen Doxyfile
-cmd /c start /b /low /wait hhc doxy-doc\html\index.hhp
-cmd /c move /y doxy-doc\html\index.chm ros-explorer.chm
-
-doxygen Doxyfile-all
-cmd /c start /b /low /wait hhc doxy-doc\html\index.hhp
-cmd /c move /y doxy-doc\html\index.chm ros-explorer-full.chm
diff --git a/reactos/subsys/system/explorer/make_explorer.dsp b/reactos/subsys/system/explorer/make_explorer.dsp
deleted file mode 100644 (file)
index ad36411..0000000
+++ /dev/null
@@ -1,205 +0,0 @@
-# Microsoft Developer Studio Project File - Name="make_explorer" - Package Owner=<4>\r
-# Microsoft Developer Studio Generated Build File, Format Version 6.00\r
-# ** DO NOT EDIT **\r
-\r
-# TARGTYPE "Win32 (x86) External Target" 0x0106\r
-\r
-CFG=make_explorer - Win32 bjam\r
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,\r
-!MESSAGE use the Export Makefile command and run\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "make_explorer.mak".\r
-!MESSAGE \r
-!MESSAGE You can specify a configuration when running NMAKE\r
-!MESSAGE by defining the macro CFG on the command line. For example:\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "make_explorer.mak" CFG="make_explorer - Win32 bjam"\r
-!MESSAGE \r
-!MESSAGE Possible choices for configuration are:\r
-!MESSAGE \r
-!MESSAGE "make_explorer - Win32 Release" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_explorer - Win32 Debug" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_explorer - Win32 Unicode Debug" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_explorer - Win32 Unicode Release" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_explorer - Win32 doxy docu" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_explorer - Win32 bjam" (based on "Win32 (x86) External Target")\r
-!MESSAGE \r
-\r
-# Begin Project\r
-# PROP AllowPerConfigDependencies 0\r
-# PROP Scc_ProjName ""\r
-# PROP Scc_LocalPath ""\r
-\r
-!IF  "$(CFG)" == "make_explorer - Win32 Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "Release"\r
-# PROP BASE Intermediate_Dir "Release"\r
-# PROP BASE Cmd_Line "NMAKE /f make_explorer.mak"\r
-# PROP BASE Rebuild_Opt "/a"\r
-# PROP BASE Target_File "make_explorer.exe"\r
-# PROP BASE Bsc_Name "make_explorer.bsc"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "Release"\r
-# PROP Intermediate_Dir "Release"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.PCH UNICODE=0"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "explorer.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_explorer - Win32 Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Cmd_Line "NMAKE /f make_explorer.mak"\r
-# PROP BASE Rebuild_Opt "/a"\r
-# PROP BASE Target_File "make_explorer.exe"\r
-# PROP BASE Bsc_Name "make_explorer.bsc"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.PCH UNICODE=0 DEBUG=1"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "explorer.exe"\r
-# PROP Bsc_Name "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=0 DEBUG=1"\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_explorer - Win32 Unicode Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "UDebug"\r
-# PROP BASE Intermediate_Dir "UDebug"\r
-# PROP BASE Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=1 DEBUG=1"\r
-# PROP BASE Rebuild_Opt "clean all"\r
-# PROP BASE Target_File "explorer.exe"\r
-# PROP BASE Bsc_Name ""\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "UDebug"\r
-# PROP Intermediate_Dir "UDebug"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=1 DEBUG=1"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "explorer.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_explorer - Win32 Unicode Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "URelease"\r
-# PROP BASE Intermediate_Dir "URelease"\r
-# PROP BASE Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=1"\r
-# PROP BASE Rebuild_Opt "clean all"\r
-# PROP BASE Target_File "explorer.exe"\r
-# PROP BASE Bsc_Name ""\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "URelease"\r
-# PROP Intermediate_Dir "URelease"\r
-# PROP Cmd_Line "msdevfilt -gcc make -f Makefile.PCH UNICODE=1"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "explorer.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_explorer - Win32 doxy docu"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW DEBUG=1"\r
-# PROP BASE Rebuild_Opt "clean all"\r
-# PROP BASE Target_File "explorer.exe"\r
-# PROP BASE Bsc_Name ""\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Cmd_Line "msdevfilt -java make docu"\r
-# PROP Rebuild_Opt "full-docu"\r
-# PROP Target_File "explorer.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_explorer - Win32 bjam"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW DEBUG=1"\r
-# PROP BASE Rebuild_Opt "clean all"\r
-# PROP BASE Target_File "explorer.exe"\r
-# PROP BASE Bsc_Name ""\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" bjam"\r
-# PROP Rebuild_Opt "clean&bjam release"\r
-# PROP Target_File "explorer.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ENDIF \r
-\r
-# Begin Target\r
-\r
-# Name "make_explorer - Win32 Release"\r
-# Name "make_explorer - Win32 Debug"\r
-# Name "make_explorer - Win32 Unicode Debug"\r
-# Name "make_explorer - Win32 Unicode Release"\r
-# Name "make_explorer - Win32 doxy docu"\r
-# Name "make_explorer - Win32 bjam"\r
-\r
-!IF  "$(CFG)" == "make_explorer - Win32 Release"\r
-\r
-!ELSEIF  "$(CFG)" == "make_explorer - Win32 Debug"\r
-\r
-!ELSEIF  "$(CFG)" == "make_explorer - Win32 Unicode Debug"\r
-\r
-!ELSEIF  "$(CFG)" == "make_explorer - Win32 Unicode Release"\r
-\r
-!ELSEIF  "$(CFG)" == "make_explorer - Win32 doxy docu"\r
-\r
-!ELSEIF  "$(CFG)" == "make_explorer - Win32 bjam"\r
-\r
-!ENDIF \r
-\r
-# Begin Source File\r
-\r
-SOURCE=.\Jamfile\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Makefile\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Makefile.MinGW\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Makefile.PCH\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Makefile.Wine\r
-# End Source File\r
-# End Target\r
-# End Project\r
diff --git a/reactos/subsys/system/explorer/make_explorer.vcproj b/reactos/subsys/system/explorer/make_explorer.vcproj
deleted file mode 100644 (file)
index bdb57eb..0000000
+++ /dev/null
@@ -1,186 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>\r
-<VisualStudioProject\r
-       ProjectType="Visual C++"\r
-       Version="8,00"\r
-       Name="make_explorer"\r
-       ProjectGUID="{E132A04B-8BC6-4D18-81F2-F0156B809871}"\r
-       Keyword="MakeFileProj"\r
-       >\r
-       <Platforms>\r
-               <Platform\r
-                       Name="Win32"\r
-               />\r
-       </Platforms>\r
-       <ToolFiles>\r
-       </ToolFiles>\r
-       <Configurations>\r
-               <Configuration\r
-                       Name="Unicode Release|Win32"\r
-                       OutputDirectory=".\URelease"\r
-                       IntermediateDirectory=".\URelease"\r
-                       ConfigurationType="0"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCNMakeTool"\r
-                               BuildCommandLine="msdevfilt -gcc make -f Makefile.PCH UNICODE=1"\r
-                               ReBuildCommandLine="msdevfilt -gcc make -f Makefile.PCH UNICODE=1 clean all"\r
-                               CleanCommandLine=""\r
-                               Output="explorer.exe"\r
-                               PreprocessorDefinitions=""\r
-                               IncludeSearchPath=""\r
-                               ForcedIncludes=""\r
-                               AssemblySearchPath=""\r
-                               ForcedUsingAssemblies=""\r
-                               CompileAsManaged=""\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="bjam|Win32"\r
-                       OutputDirectory=".\Debug"\r
-                       IntermediateDirectory=".\Debug"\r
-                       ConfigurationType="0"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCNMakeTool"\r
-                               BuildCommandLine="msdevfilt -gcc -pipe &quot;perl d:\tools\gSTLFilt.pl&quot; bjam"\r
-                               ReBuildCommandLine="msdevfilt -gcc -pipe &quot;perl d:\tools\gSTLFilt.pl&quot; bjam clean&amp;bjam release"\r
-                               CleanCommandLine=""\r
-                               Output="explorer.exe"\r
-                               PreprocessorDefinitions=""\r
-                               IncludeSearchPath=""\r
-                               ForcedIncludes=""\r
-                               AssemblySearchPath=""\r
-                               ForcedUsingAssemblies=""\r
-                               CompileAsManaged=""\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="Release|Win32"\r
-                       OutputDirectory=".\Release"\r
-                       IntermediateDirectory=".\Release"\r
-                       ConfigurationType="0"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCNMakeTool"\r
-                               BuildCommandLine="msdevfilt -gcc -pipe &quot;perl d:\tools\gSTLFilt.pl&quot; make -f Makefile.PCH UNICODE=0"\r
-                               ReBuildCommandLine="msdevfilt -gcc -pipe &quot;perl d:\tools\gSTLFilt.pl&quot; make -f Makefile.PCH UNICODE=0 clean all"\r
-                               CleanCommandLine=""\r
-                               Output="explorer.exe"\r
-                               PreprocessorDefinitions=""\r
-                               IncludeSearchPath=""\r
-                               ForcedIncludes=""\r
-                               AssemblySearchPath=""\r
-                               ForcedUsingAssemblies=""\r
-                               CompileAsManaged=""\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="doxy docu|Win32"\r
-                       OutputDirectory=".\Debug"\r
-                       IntermediateDirectory=".\Debug"\r
-                       ConfigurationType="0"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCNMakeTool"\r
-                               BuildCommandLine="msdevfilt -java make docu"\r
-                               ReBuildCommandLine="msdevfilt -java make docu full-docu"\r
-                               CleanCommandLine=""\r
-                               Output="explorer.exe"\r
-                               PreprocessorDefinitions=""\r
-                               IncludeSearchPath=""\r
-                               ForcedIncludes=""\r
-                               AssemblySearchPath=""\r
-                               ForcedUsingAssemblies=""\r
-                               CompileAsManaged=""\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="Unicode Debug|Win32"\r
-                       OutputDirectory=".\UDebug"\r
-                       IntermediateDirectory=".\UDebug"\r
-                       ConfigurationType="0"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCNMakeTool"\r
-                               BuildCommandLine="msdevfilt -gcc -pipe &quot;perl d:\tools\gSTLFilt.pl&quot; make -f Makefile.MinGW UNICODE=1 DEBUG=1"\r
-                               ReBuildCommandLine="msdevfilt -gcc -pipe &quot;perl d:\tools\gSTLFilt.pl&quot; make -f Makefile.MinGW UNICODE=1 DEBUG=1 clean all"\r
-                               CleanCommandLine=""\r
-                               Output="explorer.exe"\r
-                               PreprocessorDefinitions=""\r
-                               IncludeSearchPath=""\r
-                               ForcedIncludes=""\r
-                               AssemblySearchPath=""\r
-                               ForcedUsingAssemblies=""\r
-                               CompileAsManaged=""\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="Debug|Win32"\r
-                       OutputDirectory=".\Debug"\r
-                       IntermediateDirectory=".\Debug"\r
-                       ConfigurationType="0"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCNMakeTool"\r
-                               BuildCommandLine="msdevfilt -gcc -pipe &quot;perl d:\tools\gSTLFilt.pl&quot; make -f Makefile.PCH UNICODE=0 DEBUG=1"\r
-                               ReBuildCommandLine="msdevfilt -gcc -pipe &quot;perl d:\tools\gSTLFilt.pl&quot; make -f Makefile.PCH UNICODE=0 DEBUG=1 clean all"\r
-                               CleanCommandLine=""\r
-                               Output="explorer.exe"\r
-                               PreprocessorDefinitions=""\r
-                               IncludeSearchPath=""\r
-                               ForcedIncludes=""\r
-                               AssemblySearchPath=""\r
-                               ForcedUsingAssemblies=""\r
-                               CompileAsManaged=""\r
-                       />\r
-               </Configuration>\r
-       </Configurations>\r
-       <References>\r
-       </References>\r
-       <Files>\r
-               <File\r
-                       RelativePath="msdevfilt -gcc -pipe &quot;perl d:\tools\gSTLFilt.pl&quot; make -f Makefile.MinGW UNICODE=0 DEBUG=1"\r
-                       >\r
-               </File>\r
-               <File\r
-                       RelativePath="Jamfile"\r
-                       >\r
-               </File>\r
-               <File\r
-                       RelativePath="Makefile"\r
-                       >\r
-               </File>\r
-               <File\r
-                       RelativePath="Makefile.MinGW"\r
-                       >\r
-               </File>\r
-               <File\r
-                       RelativePath="Makefile.PCH"\r
-                       >\r
-               </File>\r
-               <File\r
-                       RelativePath="Makefile.Wine"\r
-                       >\r
-               </File>\r
-       </Files>\r
-       <Globals>\r
-       </Globals>\r
-</VisualStudioProject>\r
diff --git a/reactos/subsys/system/explorer/make_rosshell.dsp b/reactos/subsys/system/explorer/make_rosshell.dsp
deleted file mode 100644 (file)
index b6787e3..0000000
+++ /dev/null
@@ -1,155 +0,0 @@
-# Microsoft Developer Studio Project File - Name="make_rosshell" - Package Owner=<4>\r
-# Microsoft Developer Studio Generated Build File, Format Version 6.00\r
-# ** DO NOT EDIT **\r
-\r
-# TARGTYPE "Win32 (x86) External Target" 0x0106\r
-\r
-CFG=make_rosshell - Win32 Release\r
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,\r
-!MESSAGE use the Export Makefile command and run\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "make_rosshell.mak".\r
-!MESSAGE \r
-!MESSAGE You can specify a configuration when running NMAKE\r
-!MESSAGE by defining the macro CFG on the command line. For example:\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "make_rosshell.mak" CFG="make_rosshell - Win32 Release"\r
-!MESSAGE \r
-!MESSAGE Possible choices for configuration are:\r
-!MESSAGE \r
-!MESSAGE "make_rosshell - Win32 Release" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_rosshell - Win32 Debug" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_rosshell - Win32 Unicode Debug" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_rosshell - Win32 Unicode Release" (based on "Win32 (x86) External Target")\r
-!MESSAGE \r
-\r
-# Begin Project\r
-# PROP AllowPerConfigDependencies 0\r
-# PROP Scc_ProjName ""\r
-# PROP Scc_LocalPath ""\r
-\r
-!IF  "$(CFG)" == "make_rosshell - Win32 Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "Release"\r
-# PROP BASE Intermediate_Dir "Release"\r
-# PROP BASE Cmd_Line "NMAKE /f make_rosshell.mak"\r
-# PROP BASE Rebuild_Opt "/a"\r
-# PROP BASE Target_File "make_rosshell.exe"\r
-# PROP BASE Bsc_Name "make_rosshell.bsc"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "Release"\r
-# PROP Intermediate_Dir "Release"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Make-rosshell.MinGW UNICODE=0"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "rosshell.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_rosshell - Win32 Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Cmd_Line "NMAKE /f make_rosshell.mak"\r
-# PROP BASE Rebuild_Opt "/a"\r
-# PROP BASE Target_File "make_rosshell.exe"\r
-# PROP BASE Bsc_Name "make_rosshell.bsc"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Make-rosshell.MinGW UNICODE=0 DEBUG=1"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "rosshell.exe"\r
-# PROP Bsc_Name "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=0 DEBUG=1"\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_rosshell - Win32 Unicode Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "UDebug"\r
-# PROP BASE Intermediate_Dir "UDebug"\r
-# PROP BASE Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=1 DEBUG=1"\r
-# PROP BASE Rebuild_Opt "clean all"\r
-# PROP BASE Target_File "rosshell.exe"\r
-# PROP BASE Bsc_Name ""\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "UDebug"\r
-# PROP Intermediate_Dir "UDebug"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=1 DEBUG=1"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "rosshell.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_rosshell - Win32 Unicode Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "URelease"\r
-# PROP BASE Intermediate_Dir "URelease"\r
-# PROP BASE Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=1"\r
-# PROP BASE Rebuild_Opt "clean all"\r
-# PROP BASE Target_File "rosshell.exe"\r
-# PROP BASE Bsc_Name ""\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "URelease"\r
-# PROP Intermediate_Dir "URelease"\r
-# PROP Cmd_Line "msdevfilt -gcc make -f Make-rosshell.MinGW UNICODE=1"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "rosshell.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ENDIF \r
-\r
-# Begin Target\r
-\r
-# Name "make_rosshell - Win32 Release"\r
-# Name "make_rosshell - Win32 Debug"\r
-# Name "make_rosshell - Win32 Unicode Debug"\r
-# Name "make_rosshell - Win32 Unicode Release"\r
-\r
-!IF  "$(CFG)" == "make_rosshell - Win32 Release"\r
-\r
-!ELSEIF  "$(CFG)" == "make_rosshell - Win32 Debug"\r
-\r
-!ELSEIF  "$(CFG)" == "make_rosshell - Win32 Unicode Debug"\r
-\r
-!ELSEIF  "$(CFG)" == "make_rosshell - Win32 Unicode Release"\r
-\r
-!ENDIF \r
-\r
-# Begin Source File\r
-\r
-SOURCE=.\Jamfile\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\Make-rosshell.MinGW"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Makefile\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Makefile.MinGW\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Makefile.Wine\r
-# End Source File\r
-# End Target\r
-# End Project\r
diff --git a/reactos/subsys/system/explorer/notifyhook/notifyhook.c b/reactos/subsys/system/explorer/notifyhook/notifyhook.c
deleted file mode 100644 (file)
index 20267b0..0000000
+++ /dev/null
@@ -1,116 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // NotifyHook DLL for ROS Explorer
- //
- // notifyhook.cpp
- //
- // Martin Fuchs, 17.03.2004
- //
-
-
-#include "../utility/utility.h"
-
-#include "notifyhook.h"
-
-
-static HINSTANCE s_hInstance;
-static UINT WM_GETMODULEPATH;
-static HHOOK s_hNotifyHook;
-
-
-BOOL APIENTRY DllMain(HINSTANCE hInst, DWORD dwReason, LPVOID param)
-{
-       switch(dwReason) {
-         case DLL_PROCESS_ATTACH:
-               s_hInstance = hInst;
-               DisableThreadLibraryCalls(hInst);
-               WM_GETMODULEPATH = RegisterWindowMessageA("WM_GETMODULEPATH");
-               break;
-       }
-
-    return TRUE;
-}
-
-
-struct COPYDATA_STRUCT {
-       HWND    _hwnd;
-       int             _len;
-       char    _path[MAX_PATH];
-};
-
-LRESULT CALLBACK NotifyHookProc(int code, WPARAM wparam, LPARAM lparam)
-{
-       MSG* pmsg = (MSG*)lparam;
-
-       if (pmsg->message == WM_GETMODULEPATH) {
-               struct COPYDATA_STRUCT cds;
-               COPYDATASTRUCT data;
-
-               cds._hwnd = pmsg->hwnd;
-               cds._len = GetWindowModuleFileNameA(pmsg->hwnd, cds._path, COUNTOF(cds._path));
-
-               data.dwData = WM_GETMODULEPATH;
-               data.cbData = sizeof(cds);
-               data.lpData = &cds;
-
-               SendMessage((HWND)pmsg->wParam, WM_COPYDATA, (WPARAM)pmsg->hwnd, (LPARAM)&data);
-
-               return 0;
-       }
-
-       return CallNextHookEx(s_hNotifyHook, code, wparam, lparam);
-}
-
-
-UINT InstallNotifyHook()
-{
-       s_hNotifyHook = SetWindowsHookEx(WH_GETMESSAGE, NotifyHookProc, s_hInstance, 0);
-
-       return WM_GETMODULEPATH;
-}
-
-void DeinstallNotifyHook()
-{
-       UnhookWindowsHookEx(s_hNotifyHook);
-       s_hNotifyHook = 0;
-}
-
-
-void GetWindowModulePath(HWND hwnd)
-{
-       SendMessage(hwnd, WM_GETMODULEPATH, 0, 0);
-}
-
- // retrieve module path by receiving WM_COPYDATA message
-DECL_NOTIFYHOOK int GetWindowModulePathCopyData(LPARAM lparam, HWND* phwnd, LPSTR buffer, int size)
-{
-       PCOPYDATASTRUCT data = (PCOPYDATASTRUCT) lparam;
-
-       if (data->dwData == WM_GETMODULEPATH) {
-               struct COPYDATA_STRUCT* cds = (struct COPYDATA_STRUCT*) data->lpData;
-
-               *phwnd = cds->_hwnd;
-               lstrcpyn(buffer, cds->_path, size);
-
-               return cds->_len;
-       } else
-               return 0;
-}
diff --git a/reactos/subsys/system/explorer/notifyhook/notifyhook.def b/reactos/subsys/system/explorer/notifyhook/notifyhook.def
deleted file mode 100644 (file)
index ffbd225..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-EXPORTS
-DeinstallNotifyHook
-GetWindowModulePath
-GetWindowModulePathCopyData
-InstallNotifyHook
diff --git a/reactos/subsys/system/explorer/notifyhook/notifyhook.dsp b/reactos/subsys/system/explorer/notifyhook/notifyhook.dsp
deleted file mode 100644 (file)
index dac7f27..0000000
+++ /dev/null
@@ -1,132 +0,0 @@
-# Microsoft Developer Studio Project File - Name="notifyhook" - Package Owner=<4>\r
-# Microsoft Developer Studio Generated Build File, Format Version 6.00\r
-# ** DO NOT EDIT **\r
-\r
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102\r
-\r
-CFG=notifyhook - Win32\r
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,\r
-!MESSAGE use the Export Makefile command and run\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "notifyhook.mak".\r
-!MESSAGE \r
-!MESSAGE You can specify a configuration when running NMAKE\r
-!MESSAGE by defining the macro CFG on the command line. For example:\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "notifyhook.mak" CFG="notifyhook - Win32"\r
-!MESSAGE \r
-!MESSAGE Possible choices for configuration are:\r
-!MESSAGE \r
-!MESSAGE "notifyhook - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")\r
-!MESSAGE "notifyhook - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")\r
-!MESSAGE "notifyhook - Win32" (based on "Win32 (x86) Dynamic-Link Library")\r
-!MESSAGE \r
-\r
-# Begin Project\r
-# PROP AllowPerConfigDependencies 0\r
-# PROP Scc_ProjName ""\r
-# PROP Scc_LocalPath ""\r
-CPP=cl.exe\r
-MTL=midl.exe\r
-RSC=rc.exe\r
-\r
-!IF  "$(CFG)" == "notifyhook - Win32 Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "shellhook___Win32_Release"\r
-# PROP BASE Intermediate_Dir "shellhook___Win32_Release"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "..\Release"\r
-# PROP Intermediate_Dir "Release"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c\r
-# ADD CPP /nologo /MT /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "_NOTIFYHOOK_IMPL" /FD /c\r
-# SUBTRACT CPP /YX\r
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32\r
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /dll /machine:I386\r
-# ADD LINK32 user32.lib /nologo /subsystem:windows /dll /machine:I386\r
-\r
-!ELSEIF  "$(CFG)" == "notifyhook - Win32 Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Win32"\r
-# PROP BASE Intermediate_Dir "Win32"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "..\Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /FD /GZ /c\r
-# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_NOTIFYHOOK_IMPL" /FR /FD /GZ /c\r
-# SUBTRACT CPP /YX\r
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32\r
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 user32.lib /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept\r
-\r
-!ELSEIF  "$(CFG)" == "notifyhook - Win32"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Win32"\r
-# PROP BASE Intermediate_Dir "Win32"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Win32"\r
-# PROP Intermediate_Dir "Win32"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_NOTIFYHOOK_IMPL" /FR /FD /GZ /c\r
-# SUBTRACT BASE CPP /YX\r
-# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_NOTIFYHOOK_IMPL" /FR /FD /GZ /c\r
-# SUBTRACT CPP /YX\r
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32\r
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 user32.lib /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept\r
-\r
-!ENDIF \r
-\r
-# Begin Target\r
-\r
-# Name "notifyhook - Win32 Release"\r
-# Name "notifyhook - Win32 Debug"\r
-# Name "notifyhook - Win32"\r
-# Begin Source File\r
-\r
-SOURCE=.\notifyhook.c\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\notifyhook.h\r
-# End Source File\r
-# End Target\r
-# End Project\r
diff --git a/reactos/subsys/system/explorer/notifyhook/notifyhook.h b/reactos/subsys/system/explorer/notifyhook/notifyhook.h
deleted file mode 100644 (file)
index 11ebd8c..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // NotifyHook DLL for ROS Explorer
- //
- // notifyhook.h
- //
- // Martin Fuchs, 17.03.2004
- //
-
-
-#ifdef _NOTIFYHOOK_IMPL
-#define        DECL_NOTIFYHOOK __declspec(dllexport)
-#else
-#define        DECL_NOTIFYHOOK __declspec(dllimport)
-#ifdef _MSC_VER
-#pragma comment(lib, "notifyhook")
-#endif
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-DECL_NOTIFYHOOK UINT InstallNotifyHook();
-DECL_NOTIFYHOOK void DeinstallNotifyHook();
-
-DECL_NOTIFYHOOK void GetWindowModulePath(HWND hwnd);
-DECL_NOTIFYHOOK int GetWindowModulePathCopyData(LPARAM lparam, HWND* phwnd, LPSTR buffer, int size);
-
-#ifdef __cplusplus
-};
-#endif
diff --git a/reactos/subsys/system/explorer/notifyhook/notifyhook.rc b/reactos/subsys/system/explorer/notifyhook/notifyhook.rc
deleted file mode 100644 (file)
index 096ed22..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-/* $Id$ */
-
-#define REACTOS_VERSION_DLL
-#define REACTOS_STR_FILE_DESCRIPTION   "NotifyHook DLL for ROS Explorer\0"
-#define REACTOS_STR_INTERNAL_NAME      "notifyhook\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "notifyhook.dll\0"
-#include <reactos/version.rc>
-
-/* EOF */
diff --git a/reactos/subsys/system/explorer/notifyhook/notifyhook.vcproj b/reactos/subsys/system/explorer/notifyhook/notifyhook.vcproj
deleted file mode 100644 (file)
index 2682748..0000000
+++ /dev/null
@@ -1,237 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>\r
-<VisualStudioProject\r
-       ProjectType="Visual C++"\r
-       Version="8,00"\r
-       Name="notifyhook"\r
-       ProjectGUID="{F28B575D-7DBA-44DE-AAEF-FA0D065E5162}"\r
-       >\r
-       <Platforms>\r
-               <Platform\r
-                       Name="Win32"\r
-               />\r
-       </Platforms>\r
-       <ToolFiles>\r
-       </ToolFiles>\r
-       <Configurations>\r
-               <Configuration\r
-                       Name="Release|Win32"\r
-                       OutputDirectory=".\..\Release"\r
-                       IntermediateDirectory=".\Release"\r
-                       ConfigurationType="2"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCPreBuildEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCCustomBuildTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXMLDataGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebServiceProxyGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCMIDLTool"\r
-                               PreprocessorDefinitions="NDEBUG"\r
-                               MkTypLibCompatible="true"\r
-                               SuppressStartupBanner="true"\r
-                               TargetEnvironment="1"\r
-                               TypeLibraryName=".\..\Release/notifyhook.tlb"\r
-                               HeaderFileName=""\r
-                       />\r
-                       <Tool\r
-                               Name="VCCLCompilerTool"\r
-                               Optimization="2"\r
-                               InlineFunctionExpansion="1"\r
-                               PreprocessorDefinitions="NDEBUG;WIN32;_NOTIFYHOOK_IMPL"\r
-                               StringPooling="true"\r
-                               RuntimeLibrary="0"\r
-                               EnableFunctionLevelLinking="true"\r
-                               PrecompiledHeaderFile=".\Release/notifyhook.pch"\r
-                               AssemblerListingLocation=".\Release/"\r
-                               ObjectFile=".\Release/"\r
-                               ProgramDataBaseFileName=".\Release/"\r
-                               WarningLevel="3"\r
-                               SuppressStartupBanner="true"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManagedResourceCompilerTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCResourceCompilerTool"\r
-                               PreprocessorDefinitions="NDEBUG"\r
-                               Culture="1031"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPreLinkEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCLinkerTool"\r
-                               AdditionalDependencies="user32.lib"\r
-                               OutputFile=".\..\Release/notifyhook.dll"\r
-                               LinkIncremental="1"\r
-                               SuppressStartupBanner="true"\r
-                               ProgramDatabaseFile=".\..\Release/notifyhook.pdb"\r
-                               SubSystem="2"\r
-                               ImportLibrary=".\..\Release/notifyhook.lib"\r
-                               TargetMachine="1"\r
-                       />\r
-                       <Tool\r
-                               Name="VCALinkTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManifestTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXDCMakeTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCBscMakeTool"\r
-                               SuppressStartupBanner="true"\r
-                               OutputFile=".\..\Release/notifyhook.bsc"\r
-                       />\r
-                       <Tool\r
-                               Name="VCFxCopTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCAppVerifierTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebDeploymentTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPostBuildEventTool"\r
-                       />\r
-               </Configuration>\r
-               <Configuration\r
-                       Name="Debug|Win32"\r
-                       OutputDirectory=".\..\Debug"\r
-                       IntermediateDirectory=".\Debug"\r
-                       ConfigurationType="2"\r
-                       InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC60.vsprops"\r
-                       UseOfMFC="0"\r
-                       ATLMinimizesCRunTimeLibraryUsage="false"\r
-                       >\r
-                       <Tool\r
-                               Name="VCPreBuildEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCCustomBuildTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXMLDataGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebServiceProxyGeneratorTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCMIDLTool"\r
-                               PreprocessorDefinitions="_DEBUG"\r
-                               MkTypLibCompatible="true"\r
-                               SuppressStartupBanner="true"\r
-                               TargetEnvironment="1"\r
-                               TypeLibraryName=".\..\Debug/notifyhook.tlb"\r
-                               HeaderFileName=""\r
-                       />\r
-                       <Tool\r
-                               Name="VCCLCompilerTool"\r
-                               Optimization="0"\r
-                               PreprocessorDefinitions="_DEBUG;WIN32;_NOTIFYHOOK_IMPL"\r
-                               MinimalRebuild="true"\r
-                               BasicRuntimeChecks="3"\r
-                               RuntimeLibrary="1"\r
-                               PrecompiledHeaderFile=".\Debug/notifyhook.pch"\r
-                               AssemblerListingLocation=".\Debug/"\r
-                               ObjectFile=".\Debug/"\r
-                               ProgramDataBaseFileName=".\Debug/"\r
-                               BrowseInformation="1"\r
-                               WarningLevel="3"\r
-                               SuppressStartupBanner="true"\r
-                               DebugInformationFormat="4"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManagedResourceCompilerTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCResourceCompilerTool"\r
-                               PreprocessorDefinitions="_DEBUG"\r
-                               Culture="1031"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPreLinkEventTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCLinkerTool"\r
-                               AdditionalDependencies="user32.lib"\r
-                               OutputFile=".\..\Debug/notifyhook.dll"\r
-                               LinkIncremental="2"\r
-                               SuppressStartupBanner="true"\r
-                               GenerateDebugInformation="true"\r
-                               ProgramDatabaseFile=".\..\Debug/notifyhook.pdb"\r
-                               SubSystem="2"\r
-                               ImportLibrary=".\..\Debug/notifyhook.lib"\r
-                               TargetMachine="1"\r
-                       />\r
-                       <Tool\r
-                               Name="VCALinkTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCManifestTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCXDCMakeTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCBscMakeTool"\r
-                               SuppressStartupBanner="true"\r
-                               OutputFile=".\..\Debug/notifyhook.bsc"\r
-                       />\r
-                       <Tool\r
-                               Name="VCFxCopTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCAppVerifierTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCWebDeploymentTool"\r
-                       />\r
-                       <Tool\r
-                               Name="VCPostBuildEventTool"\r
-                       />\r
-               </Configuration>\r
-       </Configurations>\r
-       <References>\r
-       </References>\r
-       <Files>\r
-               <File\r
-                       RelativePath="notifyhook.c"\r
-                       >\r
-                       <FileConfiguration\r
-                               Name="Release|Win32"\r
-                               >\r
-                               <Tool\r
-                                       Name="VCCLCompilerTool"\r
-                                       PreprocessorDefinitions=""\r
-                               />\r
-                       </FileConfiguration>\r
-                       <FileConfiguration\r
-                               Name="Debug|Win32"\r
-                               >\r
-                               <Tool\r
-                                       Name="VCCLCompilerTool"\r
-                                       PreprocessorDefinitions=""\r
-                               />\r
-                       </FileConfiguration>\r
-               </File>\r
-               <File\r
-                       RelativePath="notifyhook.h"\r
-                       >\r
-               </File>\r
-       </Files>\r
-       <Globals>\r
-       </Globals>\r
-</VisualStudioProject>\r
diff --git a/reactos/subsys/system/explorer/notifyhook/notifyhook.xml b/reactos/subsys/system/explorer/notifyhook/notifyhook.xml
deleted file mode 100644 (file)
index db8f81d..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-<module name="notifyhook" type="win32dll" baseaddress="${BASEADDRESS_NOTIFYHOOK}" installbase="system32" installname="notifyhook.dll">
-       <importlibrary definition="notifyhook.def" />
-       <include base="notifyhook">.</include>
-       <define name="__USE_W32API" />
-       <define name="_WIN32_IE">0x0600</define>
-       <define name="_NOTIFYHOOK_IMPL" />
-       <library>kernel32</library>
-       <file>notifyhook.c</file>
-       <file>notifyhook.rc</file>
-</module>
diff --git a/reactos/subsys/system/explorer/precomp.cpp b/reactos/subsys/system/explorer/precomp.cpp
deleted file mode 100644 (file)
index f8e7255..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone - precompiled header support
- //
- // precomp.h
- //
- // Martin Fuchs, 17.05.2004
- //
-
-#include "precomp.h"
diff --git a/reactos/subsys/system/explorer/precomp.h b/reactos/subsys/system/explorer/precomp.h
deleted file mode 100644 (file)
index 8c68b84..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone - precompiled header support
- //
- // precomp.h
- //
- // Martin Fuchs, 17.05.2004
- //
-
-#define _CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES                        1
-#define _CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES_COUNT  1
-
-#include "utility/utility.h"
-
-#include "explorer.h"
-#include "desktop/desktop.h"
-
-#include "globals.h"
-#include "externals.h"
diff --git a/reactos/subsys/system/explorer/project-root.jam b/reactos/subsys/system/explorer/project-root.jam
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/reactos/subsys/system/explorer/rc-mingw.jam b/reactos/subsys/system/explorer/rc-mingw.jam
deleted file mode 100644 (file)
index 62f8f96..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-import type ;
-import generators ;
-import feature ;
-
-type.register RC : rc ;
-
-rule init ( )
-{
-}
-
-rule resource-compile ( target : sources * : properties * )
-{
-#    local OS = [ feature.get-values <os> : $(properties) ] ;
-    resource-compile-mingw $(target) : $(sources[1]) ;
-#    switch $(OS)
-#    {
-#        case "NT" :
-#            resource-compile-nt $(target) : $(sources[1]) ;
-#        case "CYGWIN" :
-#            resource-compile-cygwin $(target) : $(sources[1]) ;
-#        case "FREEBSD" :
-#            create-empty-object $(target) : $(sources[1]) ;
-#        case "*" :
-#            errors.error "Cannot process RC files for OS=$(OS)" ;
-#    }
-}
-
-
-actions quietly resource-compile-nt
-{
-    rc /i "$(>:D)" /fo "$(<)" "$(>)"
-}
-
-actions quietly resource-compile-mingw
-{
-    windres -D__WINDRES__ -o "$(<)" -i "$(>)"
-}
-
-actions quietly resource-compile-cygwin
-{
-    windres -D__WINDRES__ --include-dir "$(>:D)" -o "$(<)" -i "$(>)"
-}
-
-actions quietly create-empty-object
-{
-    as /dev/null -o "$(<)"
-}
-
-# Since it's a common practice to write
-# exe hello : hello.cpp hello.rc
-# we change the name of object created from RC file, to
-# avoid conflict with hello.cpp.
-generators.register-standard rc-mingw.resource-compile : RC : OBJ(%_res) ;
diff --git a/reactos/subsys/system/explorer/res/action.ico b/reactos/subsys/system/explorer/res/action.ico
deleted file mode 100644 (file)
index 233a137..0000000
Binary files a/reactos/subsys/system/explorer/res/action.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/administration.ico b/reactos/subsys/system/explorer/res/administration.ico
deleted file mode 100644 (file)
index 9a92baf..0000000
Binary files a/reactos/subsys/system/explorer/res/administration.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/appicon.ico b/reactos/subsys/system/explorer/res/appicon.ico
deleted file mode 100644 (file)
index 233a137..0000000
Binary files a/reactos/subsys/system/explorer/res/appicon.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/apps.ico b/reactos/subsys/system/explorer/res/apps.ico
deleted file mode 100644 (file)
index 4c9cbe1..0000000
Binary files a/reactos/subsys/system/explorer/res/apps.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/arrow.ico b/reactos/subsys/system/explorer/res/arrow.ico
deleted file mode 100644 (file)
index f170de0..0000000
Binary files a/reactos/subsys/system/explorer/res/arrow.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/arrow_dwn.ico b/reactos/subsys/system/explorer/res/arrow_dwn.ico
deleted file mode 100644 (file)
index 0932f7f..0000000
Binary files a/reactos/subsys/system/explorer/res/arrow_dwn.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/arrow_up.ico b/reactos/subsys/system/explorer/res/arrow_up.ico
deleted file mode 100644 (file)
index 9e2ee4c..0000000
Binary files a/reactos/subsys/system/explorer/res/arrow_up.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/arrowsel.ico b/reactos/subsys/system/explorer/res/arrowsel.ico
deleted file mode 100644 (file)
index 4235911..0000000
Binary files a/reactos/subsys/system/explorer/res/arrowsel.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/computer.ico b/reactos/subsys/system/explorer/res/computer.ico
deleted file mode 100644 (file)
index d62870d..0000000
Binary files a/reactos/subsys/system/explorer/res/computer.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/config.ico b/reactos/subsys/system/explorer/res/config.ico
deleted file mode 100644 (file)
index 0a131f1..0000000
Binary files a/reactos/subsys/system/explorer/res/config.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/control-panel.ico b/reactos/subsys/system/explorer/res/control-panel.ico
deleted file mode 100644 (file)
index e95d360..0000000
Binary files a/reactos/subsys/system/explorer/res/control-panel.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/desktop-settings.ico b/reactos/subsys/system/explorer/res/desktop-settings.ico
deleted file mode 100644 (file)
index 2723c47..0000000
Binary files a/reactos/subsys/system/explorer/res/desktop-settings.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/documents.ico b/reactos/subsys/system/explorer/res/documents.ico
deleted file mode 100644 (file)
index 2902e4b..0000000
Binary files a/reactos/subsys/system/explorer/res/documents.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/dot.ico b/reactos/subsys/system/explorer/res/dot.ico
deleted file mode 100644 (file)
index 9ddbb8a..0000000
Binary files a/reactos/subsys/system/explorer/res/dot.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/dot_red.ico b/reactos/subsys/system/explorer/res/dot_red.ico
deleted file mode 100644 (file)
index 4d176ee..0000000
Binary files a/reactos/subsys/system/explorer/res/dot_red.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/dot_trans.ico b/reactos/subsys/system/explorer/res/dot_trans.ico
deleted file mode 100644 (file)
index d5ede5a..0000000
Binary files a/reactos/subsys/system/explorer/res/dot_trans.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/drivebar.bmp b/reactos/subsys/system/explorer/res/drivebar.bmp
deleted file mode 100644 (file)
index 8fb0972..0000000
Binary files a/reactos/subsys/system/explorer/res/drivebar.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/explorer.ico b/reactos/subsys/system/explorer/res/explorer.ico
deleted file mode 100644 (file)
index 09e4a52..0000000
Binary files a/reactos/subsys/system/explorer/res/explorer.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/favorites.ico b/reactos/subsys/system/explorer/res/favorites.ico
deleted file mode 100644 (file)
index 54ec557..0000000
Binary files a/reactos/subsys/system/explorer/res/favorites.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/floating.ico b/reactos/subsys/system/explorer/res/floating.ico
deleted file mode 100644 (file)
index bbb1960..0000000
Binary files a/reactos/subsys/system/explorer/res/floating.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/folder.ico b/reactos/subsys/system/explorer/res/folder.ico
deleted file mode 100644 (file)
index 11ac83d..0000000
Binary files a/reactos/subsys/system/explorer/res/folder.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/icoali10.bmp b/reactos/subsys/system/explorer/res/icoali10.bmp
deleted file mode 100644 (file)
index eb29b24..0000000
Binary files a/reactos/subsys/system/explorer/res/icoali10.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/icoalig0.bmp b/reactos/subsys/system/explorer/res/icoalig0.bmp
deleted file mode 100644 (file)
index 0fb9e32..0000000
Binary files a/reactos/subsys/system/explorer/res/icoalig0.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/icoalig1.bmp b/reactos/subsys/system/explorer/res/icoalig1.bmp
deleted file mode 100644 (file)
index 3ae3648..0000000
Binary files a/reactos/subsys/system/explorer/res/icoalig1.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/icoalig2.bmp b/reactos/subsys/system/explorer/res/icoalig2.bmp
deleted file mode 100644 (file)
index f506442..0000000
Binary files a/reactos/subsys/system/explorer/res/icoalig2.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/icoalig3.bmp b/reactos/subsys/system/explorer/res/icoalig3.bmp
deleted file mode 100644 (file)
index 34fe98f..0000000
Binary files a/reactos/subsys/system/explorer/res/icoalig3.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/icoalig4.bmp b/reactos/subsys/system/explorer/res/icoalig4.bmp
deleted file mode 100644 (file)
index 2ceaf8b..0000000
Binary files a/reactos/subsys/system/explorer/res/icoalig4.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/icoalig5.bmp b/reactos/subsys/system/explorer/res/icoalig5.bmp
deleted file mode 100644 (file)
index 5d38cd3..0000000
Binary files a/reactos/subsys/system/explorer/res/icoalig5.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/icoalig6.bmp b/reactos/subsys/system/explorer/res/icoalig6.bmp
deleted file mode 100644 (file)
index 654da49..0000000
Binary files a/reactos/subsys/system/explorer/res/icoalig6.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/icoalig7.bmp b/reactos/subsys/system/explorer/res/icoalig7.bmp
deleted file mode 100644 (file)
index 8e09420..0000000
Binary files a/reactos/subsys/system/explorer/res/icoalig7.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/icoalig8.bmp b/reactos/subsys/system/explorer/res/icoalig8.bmp
deleted file mode 100644 (file)
index 03c49b0..0000000
Binary files a/reactos/subsys/system/explorer/res/icoalig8.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/icoalig9.bmp b/reactos/subsys/system/explorer/res/icoalig9.bmp
deleted file mode 100644 (file)
index 0e8fb8a..0000000
Binary files a/reactos/subsys/system/explorer/res/icoalig9.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/images.bmp b/reactos/subsys/system/explorer/res/images.bmp
deleted file mode 100644 (file)
index ff9f97a..0000000
Binary files a/reactos/subsys/system/explorer/res/images.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/info.ico b/reactos/subsys/system/explorer/res/info.ico
deleted file mode 100644 (file)
index 1a3f642..0000000
Binary files a/reactos/subsys/system/explorer/res/info.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/logoff.ico b/reactos/subsys/system/explorer/res/logoff.ico
deleted file mode 100644 (file)
index dbaefab..0000000
Binary files a/reactos/subsys/system/explorer/res/logoff.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/logov.bmp b/reactos/subsys/system/explorer/res/logov.bmp
deleted file mode 100644 (file)
index 0d251b6..0000000
Binary files a/reactos/subsys/system/explorer/res/logov.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/logov16.bmp b/reactos/subsys/system/explorer/res/logov16.bmp
deleted file mode 100644 (file)
index 1fb37cd..0000000
Binary files a/reactos/subsys/system/explorer/res/logov16.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/logov256.bmp b/reactos/subsys/system/explorer/res/logov256.bmp
deleted file mode 100644 (file)
index 87ad7f2..0000000
Binary files a/reactos/subsys/system/explorer/res/logov256.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/mdi.bmp b/reactos/subsys/system/explorer/res/mdi.bmp
deleted file mode 100644 (file)
index 92e550a..0000000
Binary files a/reactos/subsys/system/explorer/res/mdi.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/minimize.ico b/reactos/subsys/system/explorer/res/minimize.ico
deleted file mode 100644 (file)
index 949cf0c..0000000
Binary files a/reactos/subsys/system/explorer/res/minimize.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/network-conns.ico b/reactos/subsys/system/explorer/res/network-conns.ico
deleted file mode 100644 (file)
index 300f234..0000000
Binary files a/reactos/subsys/system/explorer/res/network-conns.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/network.ico b/reactos/subsys/system/explorer/res/network.ico
deleted file mode 100644 (file)
index 3965e61..0000000
Binary files a/reactos/subsys/system/explorer/res/network.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/notify_l.ico b/reactos/subsys/system/explorer/res/notify_l.ico
deleted file mode 100644 (file)
index b50d1e7..0000000
Binary files a/reactos/subsys/system/explorer/res/notify_l.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/notify_r.ico b/reactos/subsys/system/explorer/res/notify_r.ico
deleted file mode 100644 (file)
index e4900ac..0000000
Binary files a/reactos/subsys/system/explorer/res/notify_r.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/printer.ico b/reactos/subsys/system/explorer/res/printer.ico
deleted file mode 100644 (file)
index e30b700..0000000
Binary files a/reactos/subsys/system/explorer/res/printer.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/reactos.ico b/reactos/subsys/system/explorer/res/reactos.ico
deleted file mode 100644 (file)
index 16cebc5..0000000
Binary files a/reactos/subsys/system/explorer/res/reactos.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/recent-documents.ico b/reactos/subsys/system/explorer/res/recent-documents.ico
deleted file mode 100644 (file)
index 26d1b25..0000000
Binary files a/reactos/subsys/system/explorer/res/recent-documents.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/ros-big.ico b/reactos/subsys/system/explorer/res/ros-big.ico
deleted file mode 100644 (file)
index 4c9642e..0000000
Binary files a/reactos/subsys/system/explorer/res/ros-big.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/sdi.bmp b/reactos/subsys/system/explorer/res/sdi.bmp
deleted file mode 100644 (file)
index 2de2710..0000000
Binary files a/reactos/subsys/system/explorer/res/sdi.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/search-doc.ico b/reactos/subsys/system/explorer/res/search-doc.ico
deleted file mode 100644 (file)
index 7ae5791..0000000
Binary files a/reactos/subsys/system/explorer/res/search-doc.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/search.ico b/reactos/subsys/system/explorer/res/search.ico
deleted file mode 100644 (file)
index 36ff3f5..0000000
Binary files a/reactos/subsys/system/explorer/res/search.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/shutdown.ico b/reactos/subsys/system/explorer/res/shutdown.ico
deleted file mode 100644 (file)
index b6831c1..0000000
Binary files a/reactos/subsys/system/explorer/res/shutdown.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/speaker.ico b/reactos/subsys/system/explorer/res/speaker.ico
deleted file mode 100644 (file)
index d7f7cc4..0000000
Binary files a/reactos/subsys/system/explorer/res/speaker.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/startmenu.ico b/reactos/subsys/system/explorer/res/startmenu.ico
deleted file mode 100644 (file)
index 52411bf..0000000
Binary files a/reactos/subsys/system/explorer/res/startmenu.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/toolbar.bmp b/reactos/subsys/system/explorer/res/toolbar.bmp
deleted file mode 100644 (file)
index c3001a7..0000000
Binary files a/reactos/subsys/system/explorer/res/toolbar.bmp and /dev/null differ
diff --git a/reactos/subsys/system/explorer/res/winefile.ico b/reactos/subsys/system/explorer/res/winefile.ico
deleted file mode 100644 (file)
index 51cb8b2..0000000
Binary files a/reactos/subsys/system/explorer/res/winefile.ico and /dev/null differ
diff --git a/reactos/subsys/system/explorer/resource.h b/reactos/subsys/system/explorer/resource.h
deleted file mode 100644 (file)
index 6087298..0000000
+++ /dev/null
@@ -1,233 +0,0 @@
-//{{NO_DEPENDENCIES}}
-// Microsoft Developer Studio generated include file.
-// Used by explorer_intres.rc
-//
-#define IDS_TITLE                       1
-#define MANIFEST_RESOURCE_ID            1
-#define IDS_START                       2
-#define IDS_LOGOFF                      3
-#define IDS_SHUTDOWN                    4
-#define IDS_LAUNCH                      5
-#define IDS_START_HELP                  6
-#define IDS_SEARCH_FILES                7
-#define IDS_DOCUMENTS                   8
-#define IDS_FAVORITES                   9
-#define IDS_PROGRAMS                    10
-#define IDS_SETTINGS                    11
-#define IDS_EXPLORE                     12
-#define IDS_EMPTY                       13
-#define IDS_RECENT                      14
-#define IDS_ADMIN                       15
-#define IDS_NETWORK                     16
-#define IDS_CONNECTIONS                 17
-#define IDS_DRIVES                      18
-#define IDS_SEARCH_COMPUTER             19
-#define IDS_SETTINGS_MENU               20
-#define IDS_CONTROL_PANEL               21
-#define IDS_PRINTERS                    22
-#define IDS_BROWSE                      23
-#define IDS_SEARCH_PRG                  24
-#define IDS_ALL_USERS                   25
-#define IDS_SEARCH                      26
-#define IDS_ABOUT_EXPLORER              27
-#define IDS_LAUNCH_MANY_PROGRAMS        28
-#define IDS_DESKTOPBAR_SETTINGS         29
-#define IDS_DESKTOP                     30
-#define IDS_TASKBAR                     31
-#define IDS_STARTMENU                   32
-#define IDS_MINIMIZE_ALL                33
-#define IDS_DESKTOP_NUM                 34
-#define IDS_VOLUME                      35
-#define IDS_ITEMS_CUR                   36
-#define IDS_ITEMS_CONFIGURED            37
-#define IDS_ITEMS_VISIBLE               38
-#define IDS_ITEMS_HIDDEN                39
-#define IDS_NOTIFY_SHOW                 40
-#define IDS_NOTIFY_HIDE                 41
-#define IDS_NOTIFY_AUTOHIDE             42
-#define IDS_SHOW_HIDDEN_ICONS           43
-#define IDS_HIDE_ICONS                  44
-#define IDS_TERMINATE                   45
-#define IDI_REACTOS                     100
-#define IDI_EXPLORER                    101
-#define IDI_STARTMENU                   102
-#define IDB_TOOLBAR                     103
-#define IDA_EXPLORER                    104
-#define ID_ACTIVATE                     105
-#define IDD_SEARCH_PROGRAM              105
-#define IDB_DRIVEBAR                    106
-#define IDD_DESKBAR_DESKTOP             106
-#define IDB_IMAGES                      107
-#define IDD_EXECUTE                     108
-#define IDR_MAINFRAME                   109
-#define IDM_MDIFRAME                    110
-#define ID_EXECUTE                      111
-#define IDM_SDIFRAME                    113
-#define IDI_LOGOFF                      124
-#define IDI_FOLDERARROW                 125
-#define IDI_ARROW                       125
-#define IDI_ARROW_SELECTED              126
-#define IDI_SHUTDOWN                    127
-#define IDB_LOGOV                       129
-#define IDB_LOGOV256                    130
-#define IDA_SEARCH_PROGRAM              133
-#define IDI_APPICON                     134
-#define IDA_TRAYNOTIFY                  134
-#define IDI_FLOATING                    135
-#define IDD_ABOUT_EXPLORER              135
-#define IDI_REACTOS_BIG                 137
-#define IDI_DOCUMENTS                   138
-#define IDI_CONFIG                      139
-#define IDI_FAVORITES                   140
-#define IDI_INFO                        141
-#define IDI_APPS                        142
-#define IDI_SEARCH                      143
-#define IDI_ACTION                      144
-#define IDI_FOLDER                      145
-#define IDI_SEARCH_DOC                  146
-#define IDI_PRINTER                     147
-#define IDI_NETWORK                     148
-#define IDI_COMPUTER                    149
-#define IDM_DESKTOPBAR                  150
-#define IDM_VOLUME                      151
-#define IDM_NOTIFYAREA                  152
-#define IDD_DESKBAR_TASKBAR             153
-#define IDB_ICON_ALIGN_0                153
-#define IDD_DESKBAR_STARTMENU           154
-#define IDB_ICON_ALIGN_1                154
-#define IDB_ICON_ALIGN_2                155
-#define IDD_NOTIFYAREA                  155
-#define IDB_ICON_ALIGN_3                156
-#define IDD_MDI_SDI                     156
-#define IDB_ICON_ALIGN_4                157
-#define IDB_ICON_ALIGN_5                158
-#define IDB_ICON_ALIGN_6                159
-#define IDB_ICON_ALIGN_7                160
-#define IDB_ICON_ALIGN_8                161
-#define IDB_ICON_ALIGN_9                162
-#define IDI_SPEAKER                     162
-#define IDB_ICON_ALIGN_10               163
-#define IDI_DOT                         163
-#define IDB_LOGOV16                     164
-#define IDI_DOT_TRANS                   164
-#define IDI_DOT_RED                     165
-#define IDI_ARROW_UP                    166
-#define IDI_ARROW_DOWN                  167
-#define IDI_NOTIFY_L                    168
-#define IDI_NOTIFY_R                    169
-#define IDB_MDI                         170
-#define IDB_SDI                         171
-#define IDI_MINIMIZE                    172
-#define IDI_CONTROLPAN                  173
-#define IDI_DESKSETTING                 174
-#define IDI_NETCONNS                    175
-#define IDI_ADMIN                       176
-#define IDI_RECENT                      178
-#define ID_VIEW_NAME                    401
-#define ID_VIEW_ALL_ATTRIBUTES          402
-#define ID_VIEW_SELECTED_ATTRIBUTES     403
-#define ID_VIEW_STATUSBAR               503
-#define ID_VIEW_DRIVE_BAR               507
-#define ID_VIEW_TOOL_BAR                508
-#define ID_VIEW_EXTRA_BAR               509
-#define ID_VIEW_SIDE_BAR                510
-#define IDC_ROS_EXPLORER                1000
-#define IDC_ICON_ALIGN_0                1002
-#define IDC_ICON_ALIGN_1                1003
-#define IDC_NOTIFY_ICONS                1003
-#define IDC_ICON_ALIGN_2                1004
-#define IDC_ICON_ALIGN_3                1005
-#define IDC_ICON_ALIGN_4                1006
-#define IDC_NOTIFY_TOOLTIP              1006
-#define IDC_ICON_ALIGN_5                1007
-#define IDC_NOTIFY_TITLE                1007
-#define IDC_ICON_ALIGN_6                1008
-#define IDC_NOTIFY_MODULE               1008
-#define IDC_ICON_ALIGN_7                1009
-#define IDC_LABEL1                      1009
-#define IDC_ICON_ALIGN_8                1010
-#define IDC_LABEL2                      1010
-#define IDC_ICON_ALIGN_9                1011
-#define IDC_LABEL3                      1011
-#define IDC_ICON_ALIGN_10               1012
-#define IDC_WWW                         1012
-#define IDC_LABEL6                      1012
-#define IDC_ICON_ALIGN_11               1013
-#define IDC_LAST_CHANGE                 1013
-#define IDC_FILTER                      1017
-#define IDC_PROGRAMS_FOUND              1018
-#define IDC_PICTURE                     1019
-#define IDC_NOTIFY_SHOW                 1020
-#define IDC_NOTIFY_HIDE                 1021
-#define IDC_NOTIFY_AUTOHIDE             1022
-#define IDC_LABEL4                      1023
-#define ID_HIDE_INACTIVE_ICONS          1025
-#define ID_SHOW_CLOCK                   1026
-#define ID_DESKTOP_VERSION              1027
-#define IDC_BUTTON1                     1028
-#define IDC_CHECK_ENTRIES               1028
-#define IDC_VERSION_TXT                 1029
-#define IDC_WIN_VERSION                 1030
-#define IDC_MDI                         1030
-#define IDC_SDI                         1031
-#define IDC_SEPARATE_SUBFOLDERS         1034
-#define ID_REFRESH                      1704
-#define IDS_VERSION_STR                 5000
-#define IDS_EXPLORER_VERSION_STR        5001
-#define IDC_FILETREE                    10001
-#define ID_EXPLORER_FAQ                 10002
-#define ID_WEB_WINDOW                   10003
-#define ID_WINDOW_AUTOSORT              0x8003
-#define ID_VIEW_FULLSCREEN              0x8004
-#define ID_PREFERED_SIZES               0x8005
-#define ID_DRIVE_DESKTOP                0x9000
-#define ID_DRIVE_SHELL_NS               0x9001
-#define ID_DRIVE_UNIX_FS                0x9002
-#define ID_DRIVE_NTOBJ_NS               0x9003
-#define ID_DRIVE_REGISTRY               0x9004
-#define ID_DRIVE_FAT                    0x9005
-#define ID_DRIVE_FIRST                  0x9006
-#define ID_ABOUT_WINDOWS                40002
-#define ID_ABOUT_EXPLORER               40003
-#define ID_DESKTOPBAR_SETTINGS          40004
-#define ID_GO_BACK                      40005
-#define ID_GO_FORWARD                   40006
-#define ID_GO_HOME                      40007
-#define ID_GO_SEARCH                    40008
-#define ID_GO_UP                        40009
-#define ID_STOP                         40010
-#define ID_MINIMIZE_ALL                 40011
-#define ID_EXPLORE                      40012
-#define ID_TASKMGR                      40013
-#define ID_TRAY_VOLUME                  40014
-#define ID_VOLUME_PROPERTIES            40015
-#define ID_SHOW_HIDDEN_ICONS            40016
-#define ID_CONFIG_NOTIFYAREA            40017
-#define ID_CONFIG_TIME                  40018
-#define ID_VIEW_MDI                     40019
-#define ID_VIEW_SDI                     40020
-#define ID_TOOLS_OPTIONS                40021
-#define ID_SHOW_ICON_BUTTON             40023
-#define ID_SWITCH_DESKTOP_1             50000
-#define ID_WINDOW_NEW                   0xE130
-#define ID_WINDOW_ARRANGE               0xE131
-#define ID_WINDOW_CASCADE               0xE132
-#define ID_WINDOW_TILE_HORZ             0xE133
-#define ID_WINDOW_TILE_VERT             0xE134
-#define ID_WINDOW_SPLIT                 0xE135
-#define ID_EDIT_PROPERTIES              57656
-#define ID_FILE_EXIT                    0xE141
-#define ID_HELP_USING                   0xE144
-#define ID_HELP                         0xE146
-#define IDC_STATIC                      -1
-
-// Next default values for new objects
-// 
-#ifdef APSTUDIO_INVOKED
-#ifndef APSTUDIO_READONLY_SYMBOLS
-#define _APS_NEXT_RESOURCE_VALUE        169
-#define _APS_NEXT_COMMAND_VALUE         40024
-#define _APS_NEXT_CONTROL_VALUE         1035
-#define _APS_NEXT_SYMED_VALUE           101
-#endif
-#endif
diff --git a/reactos/subsys/system/explorer/rosshell.dsp b/reactos/subsys/system/explorer/rosshell.dsp
deleted file mode 100644 (file)
index 9130737..0000000
+++ /dev/null
@@ -1,608 +0,0 @@
-# Microsoft Developer Studio Project File - Name="rosshell" - Package Owner=<4>\r
-# Microsoft Developer Studio Generated Build File, Format Version 6.00\r
-# ** DO NOT EDIT **\r
-\r
-# TARGTYPE "Win32 (x86) Console Application" 0x0103\r
-\r
-CFG=rosshell - Win32 Debug\r
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,\r
-!MESSAGE use the Export Makefile command and run\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "rosshell.mak".\r
-!MESSAGE \r
-!MESSAGE You can specify a configuration when running NMAKE\r
-!MESSAGE by defining the macro CFG on the command line. For example:\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "rosshell.mak" CFG="rosshell - Win32 Debug"\r
-!MESSAGE \r
-!MESSAGE Possible choices for configuration are:\r
-!MESSAGE \r
-!MESSAGE "rosshell - Win32 Release" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "rosshell - Win32 Debug" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "rosshell - Win32 Debug Release" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "rosshell - Win32 Unicode Release" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "rosshell - Win32 Unicode Debug" (based on "Win32 (x86) Console Application")\r
-!MESSAGE \r
-\r
-# Begin Project\r
-# PROP AllowPerConfigDependencies 0\r
-# PROP Scc_ProjName ""\r
-# PROP Scc_LocalPath ""\r
-CPP=cl.exe\r
-RSC=rc.exe\r
-\r
-!IF  "$(CFG)" == "rosshell - Win32 Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "Release"\r
-# PROP BASE Intermediate_Dir "Release"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "Release"\r
-# PROP Intermediate_Dir "Release"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c\r
-# ADD CPP /nologo /MD /W3 /GR /GX /O1 /D "NDEBUG" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /D "ROSSHELL" /Yu"precomp.h" /FD /c\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386\r
-# ADD LINK32 shell32.lib comctl32.lib gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /machine:I386 /libpath:"Release" /delayload:oleaut32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "rosshell - Win32 Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c\r
-# ADD CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /D "ROSSHELL" /FR /Yu"precomp.h" /FD /GZ /c\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 kernel32.lib shell32.lib comctl32.lib gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept /libpath:"Debug" /delayload:oleaut32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "rosshell - Win32 Debug Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "DRelease"\r
-# PROP BASE Intermediate_Dir "DRelease"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "DRelease"\r
-# PROP Intermediate_Dir "DRelease"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "_ROS_" /YX /FD /c\r
-# ADD CPP /nologo /MD /W3 /GR /GX /Zi /O2 /D "NDEBUG" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /D "ROSSHELL" /FR /Yu"precomp.h" /FD /c\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib /nologo /subsystem:console /machine:I386\r
-# ADD LINK32 shell32.lib comctl32.lib gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /debug /machine:I386 /delayload:oleaut32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "rosshell - Win32 Unicode Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "URelease"\r
-# PROP BASE Intermediate_Dir "URelease"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "URelease"\r
-# PROP Intermediate_Dir "URelease"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "UNICODE" /D "_ROS_" /YX /FD /c\r
-# ADD CPP /nologo /MD /W3 /GR /GX /O2 /D "NDEBUG" /D "UNICODE" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /D "ROSSHELL" /Yu"precomp.h" /FD /c\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib /nologo /subsystem:console /machine:I386\r
-# ADD LINK32 shell32.lib comctl32.lib gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /machine:I386 /libpath:"Release" /delayload:oleaut32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "rosshell - Win32 Unicode Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "UDebug"\r
-# PROP BASE Intermediate_Dir "UDebug"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "UDebug"\r
-# PROP Intermediate_Dir "UDebug"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "UNICODE" /D "_ROS_" /FR /YX /FD /GZ /c\r
-# ADD CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Od /D "_DEBUG" /D "UNICODE" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /D "ROSSHELL" /FR /Yu"precomp.h" /FD /GZ /c\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 shell32.lib comctl32.lib gdi32.lib user32.lib advapi32.lib ole32.lib delayimp.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept /libpath:"Debug" /delayload:oleaut32.dll /delayload:wsock32.dll\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ENDIF \r
-\r
-# Begin Target\r
-\r
-# Name "rosshell - Win32 Release"\r
-# Name "rosshell - Win32 Debug"\r
-# Name "rosshell - Win32 Debug Release"\r
-# Name "rosshell - Win32 Unicode Release"\r
-# Name "rosshell - Win32 Unicode Debug"\r
-# Begin Group "utility"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\dragdropimpl.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\dragdropimpl.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\shellbrowserimpl.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\shellbrowserimpl.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\shellclasses.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\shellclasses.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\treedroptarget.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\utility.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\utility.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\window.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\window.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\xmlstorage.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\xmlstorage.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "resources"\r
-\r
-# PROP Default_Filter "bmp,ico"\r
-# Begin Source File\r
-\r
-SOURCE=.\res\action.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\appicon.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\apps.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\arrow.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\arrow_dwn.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\arrow_up.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\arrowsel.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\computer.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\config.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\documents.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\dot.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\dot_red.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\dot_trans.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\drivebar.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\explorer-jp.rc"\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\explorer.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\resource.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\explorer_intres.rc\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\favorites.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\floating.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\folder.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoali10.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig0.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig1.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig2.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig3.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig4.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig5.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig6.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig7.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig8.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\icoalig9.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\images.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\info.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\logoff.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\logov.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\logov16.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\logov256.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\network.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\notify_l.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\notify_r.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\printer.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\reactos.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\res\ros-big.ico"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\res\search-doc.ico"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\search.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\speaker.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\startmenu.ico\r
-# End Source File\r
-# End Group\r
-# Begin Group "taskbar"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\desktopbar.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\desktopbar.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\favorites.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\favorites.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\notifyhook\notifyhook.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\quicklaunch.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\quicklaunch.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\startmenu.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\startmenu.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\taskbar.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\taskbar.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\traynotify.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\taskbar\traynotify.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "desktop"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\desktop\desktop.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\desktop\desktop.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "shell"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\entries.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\entries.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\filechild.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\pane.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\pane.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\shellbrowser.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\shellfs.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\shellfs.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\winfs.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shell\winfs.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "dialogs"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\dialogs\searchprogram.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\dialogs\searchprogram.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\dialogs\settings.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\dialogs\settings.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "main"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\explorer.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\explorer.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\externals.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\globals.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=".\i386-stub-win32.c"\r
-# SUBTRACT CPP /YX /Yc /Yu\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\precomp.cpp\r
-# ADD CPP /Yc"precomp.h"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\precomp.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "services"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\services\shellservices.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\services\shellservices.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\services\startup.c\r
-# SUBTRACT CPP /YX /Yc /Yu\r
-# End Source File\r
-# End Group\r
-# End Target\r
-# End Project\r
diff --git a/reactos/subsys/system/explorer/rosshell.dsw b/reactos/subsys/system/explorer/rosshell.dsw
deleted file mode 100644 (file)
index a4b2104..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-Microsoft Developer Studio Workspace File, Format Version 6.00\r
-# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!\r
-\r
-###############################################################################\r
-\r
-Project: "rosshell"=.\rosshell.dsp - Package Owner=<4>\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<4>\r
-{{{\r
-    Begin Project Dependency\r
-    Project_Dep_Name notifyhook\r
-    End Project Dependency\r
-}}}\r
-\r
-###############################################################################\r
-\r
-Project: "make_rosshell"=.\make_rosshell.dsp - Package Owner=<4>\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<4>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
-Project: "notifyhook"=.\notifyhook\notifyhook.dsp - Package Owner=<4>\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<4>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
-Global:\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<3>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
diff --git a/reactos/subsys/system/explorer/services/shellservices.cpp b/reactos/subsys/system/explorer/services/shellservices.cpp
deleted file mode 100644 (file)
index 48b3caa..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * Copyright 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // shellservices.cpp
- //
- // Martin Fuchs, 28.03.2005
- //
-
-
-#include <precomp.h>
-
-#include "shellservices.h"
-
-
-int SSOThread::Run()
-{
-       ComInit usingCOM(COINIT_APARTMENTTHREADED|COINIT_DISABLE_OLE1DDE|COINIT_SPEED_OVER_MEMORY);
-
-       HKEY hkey;
-       CLSID clsid;
-       WCHAR name[MAX_PATH], value[MAX_PATH];
-
-       typedef vector<SIfacePtr<IOleCommandTarget>*> SSOVector;
-       SSOVector sso_ptrs;
-
-       if (!RegOpenKey(HKEY_LOCAL_MACHINE, TEXT("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\ShellServiceObjectDelayLoad"), &hkey)) {
-               for(int idx=0; ; ++idx) {
-                       DWORD name_len = MAX_PATH;
-                       DWORD value_len = sizeof(value);
-
-                       if (RegEnumValueW(hkey, idx, name, &name_len, 0, NULL, (LPBYTE)&value, &value_len))
-                               break;
-
-                       if (!_alive)
-                               break;
-
-                       SIfacePtr<IOleCommandTarget>* sso_ptr = new SIfacePtr<IOleCommandTarget>;
-
-                       if (CLSIDFromString(value, &clsid) == NOERROR) {
-                               if (SUCCEEDED(sso_ptr->CreateInstance(clsid, IID_IOleCommandTarget))) {
-                                       if (SUCCEEDED((*sso_ptr)->Exec(&CGID_ShellServiceObject, OLECMDID_NEW, OLECMDEXECOPT_DODEFAULT, NULL, NULL)))
-                                               sso_ptrs.push_back(sso_ptr);
-                               }
-                       }
-               }
-
-               RegCloseKey(hkey);
-       }
-
-       if (!sso_ptrs.empty()) {
-               MSG msg;
-
-               while(_alive) {
-                       if (MsgWaitForMultipleObjects(1, &_evtFinish, FALSE, INFINITE, QS_ALLINPUT) == WAIT_OBJECT_0+0)
-                               break;  // _evtFinish has been set.
-
-                       while(_alive) {
-                               if (!PeekMessage(&msg, 0, 0, 0, PM_REMOVE))
-                                       break;
-
-                               if (msg.message == WM_QUIT)
-                                       break;
-
-                               TranslateMessage(&msg);
-                               DispatchMessage(&msg);
-                       }
-               }
-
-                // shutdown all running Shell Service Objects
-               for(SSOVector::iterator it=sso_ptrs.begin(); it!=sso_ptrs.end(); ++it) {
-                       SIfacePtr<IOleCommandTarget>* sso_ptr = *it;
-                       (*sso_ptr)->Exec(&CGID_ShellServiceObject, OLECMDID_SAVE, OLECMDEXECOPT_DODEFAULT, NULL, NULL);
-                       delete sso_ptr;
-               }
-       }
-
-       return 0;
-}
diff --git a/reactos/subsys/system/explorer/services/shellservices.h b/reactos/subsys/system/explorer/services/shellservices.h
deleted file mode 100644 (file)
index ecda281..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // shellservices.h
- //
- // Martin Fuchs, 28.03.2005
- //
-
-
- // launch start programs
-extern "C" int startup(int argc, char *argv[]);
-
- // load Shell Service Objects (volume control, printer/network icons, ...)
-struct SSOThread : public Thread
-{
-       int     Run();
-};
diff --git a/reactos/subsys/system/explorer/services/startup.c b/reactos/subsys/system/explorer/services/startup.c
deleted file mode 100644 (file)
index ec0e422..0000000
+++ /dev/null
@@ -1,485 +0,0 @@
-/*
- * Copyright (C) 2002 Andreas Mohr
- * Copyright (C) 2002 Shachar Shemesh
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-/* Based on the Wine "bootup" handler application
- *
- * This app handles the various "hooks" windows allows for applications to perform
- * as part of the bootstrap process. Theses are roughly devided into three types.
- * Knowledge base articles that explain this are 137367, 179365, 232487 and 232509.
- * Also, 119941 has some info on grpconv.exe
- * The operations performed are (by order of execution):
- *
- * Preboot (prior to fully loading the Windows kernel):
- * - wininit.exe (rename operations left in wininit.ini - Win 9x only)
- * - PendingRenameOperations (rename operations left in the registry - Win NT+ only)
- *
- * Startup (before the user logs in)
- * - Services (NT, ?semi-synchronous?, not implemented yet)
- * - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunServicesOnce (9x, asynch)
- * - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunServices (9x, asynch)
- *
- * After log in
- * - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunOnce (all, synch)
- * - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run (all, asynch)
- * - HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run (all, asynch)
- * - Startup folders (all, ?asynch?, no imp)
- * - HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\RunOnce (all, asynch)
- *
- * Somewhere in there is processing the RunOnceEx entries (also no imp)
- *
- * Bugs:
- * - If a pending rename registry does not start with \??\ the entry is
- *   processed anyways. I'm not sure that is the Windows behaviour.
- * - Need to check what is the windows behaviour when trying to delete files
- *   and directories that are read-only
- * - In the pending rename registry processing - there are no traces of the files
- *   processed (requires translations from Unicode to Ansi).
- */
-
-#include <stdio.h>
-#include <windows.h>
-#include <ctype.h>
-
-/**
- * Performs the rename operations dictated in %SystemRoot%\Wininit.ini.
- * Returns FALSE if there was an error, or otherwise if all is ok.
- */
-static BOOL wininit()
-{
-    return TRUE;
-}
-
-static BOOL pendingRename()
-{
-    static const WCHAR ValueName[] = {'P','e','n','d','i','n','g',
-                                      'F','i','l','e','R','e','n','a','m','e',
-                                      'O','p','e','r','a','t','i','o','n','s',0};
-    static const WCHAR SessionW[] = { 'S','y','s','t','e','m','\\',
-                                     'C','u','r','r','e','n','t','C','o','n','t','r','o','l','S','e','t','\\',
-                                     'C','o','n','t','r','o','l','\\',
-                                     'S','e','s','s','i','o','n',' ','M','a','n','a','g','e','r',0};
-    WCHAR *buffer=NULL;
-    const WCHAR *src=NULL, *dst=NULL;
-    DWORD dataLength=0;
-    HKEY hSession=NULL;
-    DWORD res;
-
-    printf("Entered\n");
-
-    if ((res=RegOpenKeyExW(HKEY_LOCAL_MACHINE, SessionW, 0, KEY_ALL_ACCESS, &hSession))
-            !=ERROR_SUCCESS)
-    {
-        if (res==ERROR_FILE_NOT_FOUND)
-        {
-            printf("The key was not found - skipping\n");
-            res=TRUE;
-        }
-        else
-        {
-            printf("Couldn't open key, error %ld\n", res);
-            res=FALSE;
-        }
-
-        goto end;
-    }
-
-    res=RegQueryValueExW(hSession, ValueName, NULL, NULL /* The value type does not really interest us, as it is not
-                                                             truely a REG_MULTI_SZ anyways */,
-            NULL, &dataLength);
-    if (res==ERROR_FILE_NOT_FOUND)
-    {
-        /* No value - nothing to do. Great! */
-        printf("Value not present - nothing to rename\n");
-        res=TRUE;
-        goto end;
-    }
-
-    if (res!=ERROR_SUCCESS)
-    {
-        printf("Couldn't query value's length (%ld)\n", res);
-        res=FALSE;
-        goto end;
-    }
-
-    buffer=malloc(dataLength);
-    if (buffer==NULL)
-    {
-        printf("Couldn't allocate %lu bytes for the value\n", dataLength);
-        res=FALSE;
-        goto end;
-    }
-
-    res=RegQueryValueExW(hSession, ValueName, NULL, NULL, (LPBYTE)buffer, &dataLength);
-    if (res!=ERROR_SUCCESS)
-    {
-        printf("Couldn't query value after successfully querying before (%lu),\n"
-                "please report to wine-devel@winehq.org\n", res);
-        res=FALSE;
-        goto end;
-    }
-
-    /* Make sure that the data is long enough and ends with two NULLs. This
-     * simplifies the code later on.
-     */
-    if (dataLength<2*sizeof(buffer[0]) ||
-            buffer[dataLength/sizeof(buffer[0])-1]!='\0' ||
-            buffer[dataLength/sizeof(buffer[0])-2]!='\0')
-    {
-        printf("Improper value format - doesn't end with NULL\n");
-        res=FALSE;
-        goto end;
-    }
-
-    for(src=buffer; (src-buffer)*sizeof(src[0])<dataLength && *src!='\0';
-            src=dst+lstrlenW(dst)+1)
-    {
-        DWORD dwFlags=0;
-
-        printf("processing next command\n");
-
-        dst=src+lstrlenW(src)+1;
-
-        /* We need to skip the \??\ header */
-        if (src[0]=='\\' && src[1]=='?' && src[2]=='?' && src[3]=='\\')
-            src+=4;
-
-        if (dst[0]=='!')
-        {
-            dwFlags|=MOVEFILE_REPLACE_EXISTING;
-            dst++;
-        }
-
-        if (dst[0]=='\\' && dst[1]=='?' && dst[2]=='?' && dst[3]=='\\')
-            dst+=4;
-
-        if (*dst!='\0')
-        {
-            /* Rename the file */
-            MoveFileExW(src, dst, dwFlags);
-        } else
-        {
-            /* Delete the file or directory */
-                       res = GetFileAttributesW (src);
-            if (res != (DWORD)-1)
-            {
-                if ((res&FILE_ATTRIBUTE_DIRECTORY)==0)
-                {
-                    /* It's a file */
-                    DeleteFileW(src);
-                } else
-                {
-                    /* It's a directory */
-                    RemoveDirectoryW(src);
-                }
-            } else
-            {
-                printf("couldn't get file attributes (%ld)\n", GetLastError());
-            }
-        }
-    }
-
-    if ((res=RegDeleteValueW(hSession, ValueName))!=ERROR_SUCCESS)
-    {
-        printf("Error deleting the value (%lu)\n", GetLastError());
-        res=FALSE;
-    } else
-        res=TRUE;
-
-end:
-    if (buffer!=NULL)
-        free(buffer);
-
-    if (hSession!=NULL)
-        RegCloseKey(hSession);
-
-    return res;
-}
-
-enum runkeys {
-    RUNKEY_RUN, RUNKEY_RUNONCE, RUNKEY_RUNSERVICES, RUNKEY_RUNSERVICESONCE
-};
-
-const WCHAR runkeys_names[][30]=
-{
-    {'R','u','n',0},
-    {'R','u','n','O','n','c','e',0},
-    {'R','u','n','S','e','r','v','i','c','e','s',0},
-    {'R','u','n','S','e','r','v','i','c','e','s','O','n','c','e',0}
-};
-
-#define INVALID_RUNCMD_RETURN -1
-/**
- * This function runs the specified command in the specified dir.
- * [in,out] cmdline - the command line to run. The function may change the passed buffer.
- * [in] dir - the dir to run the command in. If it is NULL, then the current dir is used.
- * [in] wait - whether to wait for the run program to finish before returning.
- * [in] minimized - Whether to ask the program to run minimized.
- *
- * Returns:
- * If running the process failed, returns INVALID_RUNCMD_RETURN. Use GetLastError to get the error code.
- * If wait is FALSE - returns 0 if successful.
- * If wait is TRUE - returns the program's return value.
- */
-static int runCmd(LPWSTR cmdline, LPCWSTR dir, BOOL wait, BOOL minimized)
-{
-    STARTUPINFOW si;
-    PROCESS_INFORMATION info;
-    DWORD exit_code=0;
-
-    memset(&si, 0, sizeof(si));
-    si.cb=sizeof(si);
-    if (minimized)
-    {
-        si.dwFlags=STARTF_USESHOWWINDOW;
-        si.wShowWindow=SW_MINIMIZE;
-    }
-    memset(&info, 0, sizeof(info));
-
-    if (!CreateProcessW(NULL, cmdline, NULL, NULL, FALSE, 0, NULL, dir, &si, &info))
-    {
-        printf("Failed to run command (%ld)\n", GetLastError());
-
-        return INVALID_RUNCMD_RETURN;
-    }
-
-    printf("Successfully ran command\n"); //%s - Created process handle %p\n",
-               //wine_dbgstr_w(cmdline), info.hProcess);
-
-    if (wait)
-    {   /* wait for the process to exit */
-        WaitForSingleObject(info.hProcess, INFINITE);
-        GetExitCodeProcess(info.hProcess, &exit_code);
-    }
-
-    CloseHandle(info.hProcess);
-
-    return exit_code;
-}
-
-/**
- * Process a "Run" type registry key.
- * hkRoot is the HKEY from which "Software\Microsoft\Windows\CurrentVersion" is
- *      opened.
- * szKeyName is the key holding the actual entries.
- * bDelete tells whether we should delete each value right before executing it.
- * bSynchronous tells whether we should wait for the prog to complete before
- *      going on to the next prog.
- */
-static BOOL ProcessRunKeys(HKEY hkRoot, LPCWSTR szKeyName, BOOL bDelete,
-        BOOL bSynchronous)
-{
-    static const WCHAR WINKEY_NAME[]={'S','o','f','t','w','a','r','e','\\',
-        'M','i','c','r','o','s','o','f','t','\\','W','i','n','d','o','w','s','\\',
-        'C','u','r','r','e','n','t','V','e','r','s','i','o','n',0};
-    HKEY hkWin=NULL, hkRun=NULL;
-    LONG res=ERROR_SUCCESS;
-    DWORD i, nMaxCmdLine=0, nMaxValue=0;
-    WCHAR *szCmdLine=NULL;
-    WCHAR *szValue=NULL;
-
-    if (hkRoot==HKEY_LOCAL_MACHINE)
-        wprintf(L"processing %s entries under HKLM\n", szKeyName);
-    else
-        wprintf(L"processing %s entries under HKCU\n", szKeyName);
-
-    if ((res=RegOpenKeyExW(hkRoot, WINKEY_NAME, 0, KEY_READ, &hkWin))!=ERROR_SUCCESS)
-    {
-        printf("RegOpenKey failed on Software\\Microsoft\\Windows\\CurrentVersion (%ld)\n",
-                res);
-
-        goto end;
-    }
-
-    if ((res=RegOpenKeyExW(hkWin, szKeyName, 0, bDelete?KEY_ALL_ACCESS:KEY_READ, &hkRun))!=
-            ERROR_SUCCESS)
-    {
-        if (res==ERROR_FILE_NOT_FOUND)
-        {
-            printf("Key doesn't exist - nothing to be done\n");
-
-            res=ERROR_SUCCESS;
-        }
-        else
-            printf("RegOpenKey failed on run key (%ld)\n", res);
-
-        goto end;
-    }
-
-    if ((res=RegQueryInfoKeyW(hkRun, NULL, NULL, NULL, NULL, NULL, NULL, &i, &nMaxValue,
-                    &nMaxCmdLine, NULL, NULL))!=ERROR_SUCCESS)
-    {
-        printf("Couldn't query key info (%ld)\n", res);
-
-        goto end;
-    }
-
-    if (i==0)
-    {
-        printf("No commands to execute.\n");
-
-        res=ERROR_SUCCESS;
-        goto end;
-    }
-
-    if ((szCmdLine=malloc(nMaxCmdLine))==NULL)
-    {
-        printf("Couldn't allocate memory for the commands to be executed\n");
-
-        res=ERROR_NOT_ENOUGH_MEMORY;
-        goto end;
-    }
-
-    if ((szValue=malloc((++nMaxValue)*sizeof(*szValue)))==NULL)
-    {
-        printf("Couldn't allocate memory for the value names\n");
-
-        res=ERROR_NOT_ENOUGH_MEMORY;
-        goto end;
-    }
-
-    while(i>0)
-    {
-        DWORD nValLength=nMaxValue, nDataLength=nMaxCmdLine;
-        DWORD type;
-
-        --i;
-
-        if ((res=RegEnumValueW(hkRun, i, szValue, &nValLength, 0, &type,
-                        (LPBYTE)szCmdLine, &nDataLength))!=ERROR_SUCCESS)
-        {
-            printf("Couldn't read in value %ld - %ld\n", i, res);
-
-            continue;
-        }
-
-        if (bDelete && (res=RegDeleteValueW(hkRun, szValue))!=ERROR_SUCCESS)
-        {
-            printf("Couldn't delete value - %ld, %ld. Running command anyways.\n", i, res);
-        }
-
-        if (type!=REG_SZ)
-        {
-            printf("Incorrect type of value #%ld (%ld)\n", i, type);
-
-            continue;
-        }
-
-        if ((res=runCmd(szCmdLine, NULL, bSynchronous, FALSE))==INVALID_RUNCMD_RETURN)
-        {
-            printf("Error running cmd #%ld (%ld)\n", i, GetLastError());
-        }
-
-        printf("Done processing cmd #%ld\n", i);
-    }
-
-    res=ERROR_SUCCESS;
-
-end:
-    if (hkRun!=NULL)
-        RegCloseKey(hkRun);
-    if (hkWin!=NULL)
-        RegCloseKey(hkWin);
-
-    printf("done\n");
-
-    return res==ERROR_SUCCESS?TRUE:FALSE;
-}
-
- /// structure holding startup flags
-struct op_mask {
-    BOOL w9xonly; /* Perform only operations done on Windows 9x */
-    BOOL ntonly; /* Perform only operations done on Windows NT */
-    BOOL startup; /* Perform the operations that are performed every boot */
-    BOOL preboot; /* Perform file renames typically done before the system starts */
-    BOOL prelogin; /* Perform the operations typically done before the user logs in */
-    BOOL postlogin; /* Operations done after login */
-};
-
-static const struct op_mask
-       SESSION_START   = {FALSE, FALSE, TRUE, TRUE, TRUE, TRUE},
-    SETUP                      = {FALSE, FALSE, FALSE, TRUE, TRUE, TRUE};
-#define DEFAULT SESSION_START
-
-int startup(int argc, char *argv[])
-{
-    struct op_mask ops; /* Which of the ops do we want to perform? */
-    /* First, set the current directory to SystemRoot */
-    TCHAR gen_path[MAX_PATH];
-    DWORD res;
-
-    res = GetWindowsDirectory(gen_path, sizeof(gen_path));
-
-    if (res==0)
-    {
-               printf("Couldn't get the windows directory - error %ld\n",
-                       GetLastError());
-
-               return 100;
-    }
-
-    if (res>=sizeof(gen_path))
-    {
-               printf("Windows path too long (%ld)\n", res);
-
-               return 100;
-    }
-
-    if (!SetCurrentDirectory(gen_path))
-    {
-        wprintf(L"Cannot set the dir to %s (%ld)\n", gen_path, GetLastError());
-
-        return 100;
-    }
-
-    if (argc>1)
-    {
-        switch(argv[1][0])
-        {
-        case 'r': /* Restart */
-            ops=SETUP;
-            break;
-        case 's': /* Full start */
-            ops=SESSION_START;
-            break;
-        default:
-            ops=DEFAULT;
-            break;
-        }
-    } else
-        ops=DEFAULT;
-
-    /* Perform the ops by order, stopping if one fails, skipping if necessary */
-    /* Shachar: Sorry for the perl syntax */
-    res=(ops.ntonly || !ops.preboot || wininit()) &&
-        (ops.w9xonly || !ops.preboot || pendingRename()) &&
-        (ops.ntonly || !ops.prelogin ||
-         ProcessRunKeys(HKEY_LOCAL_MACHINE, runkeys_names[RUNKEY_RUNSERVICESONCE], TRUE, FALSE)) &&
-        (ops.ntonly || !ops.prelogin || !ops.startup ||
-         ProcessRunKeys(HKEY_LOCAL_MACHINE, runkeys_names[RUNKEY_RUNSERVICES], FALSE, FALSE)) &&
-        (!ops.postlogin ||
-         ProcessRunKeys(HKEY_LOCAL_MACHINE, runkeys_names[RUNKEY_RUNONCE], TRUE, TRUE)) &&
-        (!ops.postlogin || !ops.startup ||
-         ProcessRunKeys(HKEY_LOCAL_MACHINE, runkeys_names[RUNKEY_RUN], FALSE, FALSE)) &&
-        (!ops.postlogin || !ops.startup ||
-         ProcessRunKeys(HKEY_CURRENT_USER, runkeys_names[RUNKEY_RUN], FALSE, FALSE));
-
-    printf("Operation done\n");
-
-    return res?0:101;
-}
diff --git a/reactos/subsys/system/explorer/shell/entries.cpp b/reactos/subsys/system/explorer/shell/entries.cpp
deleted file mode 100644 (file)
index 562eeb7..0000000
+++ /dev/null
@@ -1,800 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // entries.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include <precomp.h>
-
-//#include "entries.h"
-
-
- // allocate and initialise a directory entry
-Entry::Entry(ENTRY_TYPE etype)
- :     _etype(etype)
-{
-       _up = NULL;
-       _next = NULL;
-       _down = NULL;
-       _expanded = false;
-       _scanned = false;
-       _bhfi_valid = false;
-       _level = 0;
-       _icon_id = ICID_UNKNOWN;
-       _display_name = _data.cFileName;
-       _type_name = NULL;
-       _content = NULL;
-}
-
-Entry::Entry(Entry* parent, ENTRY_TYPE etype)
- :     _up(parent),
-       _etype(etype)
-{
-       _next = NULL;
-       _down = NULL;
-       _expanded = false;
-       _scanned = false;
-       _bhfi_valid = false;
-       _level = 0;
-       _icon_id = ICID_UNKNOWN;
-       _shell_attribs = 0;
-       _display_name = _data.cFileName;
-       _type_name = NULL;
-       _content = NULL;
-}
-
-Entry::Entry(const Entry& other)
-{
-       _next = NULL;
-       _down = NULL;
-       _up = NULL;
-
-       assert(!other._next);
-       assert(!other._down);
-       assert(!other._up);
-
-       _expanded = other._expanded;
-       _scanned = other._scanned;
-       _level = other._level;
-
-       _data = other._data;
-
-       _shell_attribs = other._shell_attribs;
-       _display_name = other._display_name==other._data.cFileName? _data.cFileName: _tcsdup(other._display_name);
-       _type_name = other._type_name? _tcsdup(other._type_name): NULL;
-       _content = other._content? _tcsdup(other._content): NULL;
-
-       _etype = other._etype;
-       _icon_id = other._icon_id;
-
-       _bhfi = other._bhfi;
-       _bhfi_valid = other._bhfi_valid;
-}
-
- // free a directory entry
-Entry::~Entry()
-{
-       if (_icon_id > ICID_NONE)
-               g_Globals._icon_cache.free_icon(_icon_id);
-
-       if (_display_name != _data.cFileName)
-               free(_display_name);
-
-       if (_type_name)
-               free(_type_name);
-
-       if (_content)
-               free(_content);
-}
-
-
- // read directory tree and expand to the given location
-Entry* Entry::read_tree(const void* path, SORT_ORDER sortOrder, int scan_flags)
-{
-       CONTEXT("Entry::read_tree()");
-
-       WaitCursor wait;
-
-       Entry* entry = this;
-
-       for(const void*p=path; p && entry; ) {
-               entry->smart_scan(sortOrder, scan_flags);
-
-               if (entry->_down)
-                       entry->_expanded = true;
-
-               Entry* found = entry->find_entry(p);
-               p = entry->get_next_path_component(p);
-
-               entry = found;
-       }
-
-       return entry;
-}
-
-
-void Entry::read_directory_base(SORT_ORDER sortOrder, int scan_flags)
-{
-       CONTEXT("Entry::read_directory_base()");
-
-        // call into subclass
-       read_directory(scan_flags);
-
-#ifndef ROSSHELL
-       if (g_Globals._prescan_nodes) { //@todo _prescan_nodes should not be used for reading the start menu.
-               for(Entry*entry=_down; entry; entry=entry->_next)
-                       if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-                               entry->read_directory(scan_flags);
-                               entry->sort_directory(sortOrder);
-                       }
-       }
-#endif
-
-       sort_directory(sortOrder);
-}
-
-
-Root::Root()
-{
-       memset(this, 0, sizeof(Root));
-}
-
-Root::~Root()
-{
-       if (_entry) {
-               _entry->free_subentries();
-               delete _entry;
-       }
-}
-
-
- // sort order for different directory/file types
-enum TYPE_ORDER {
-       TO_DIR,
-       TO_DOT,
-       TO_DOTDOT,
-       TO_OTHER_DIR,
-       TO_VIRTUAL_FOLDER,
-       TO_FILE
-};
-
- // distinguish between ".", ".." and any other directory names
-static TYPE_ORDER TypeOrderFromDirname(LPCTSTR name)
-{
-       if (name[0] == '.') {
-               if (name[1] == '\0')
-                       return TO_DOT;          // "."
-
-               if (name[1]=='.' && name[2]=='\0')
-                       return TO_DOTDOT;       // ".."
-       }
-
-       return TO_OTHER_DIR;            // any other directory
-}
-
- // directories first...
-static int compareType(const Entry* entry1, const Entry* entry2)
-{
-       const WIN32_FIND_DATA* fd1 = &entry1->_data;
-       const WIN32_FIND_DATA* fd2 = &entry2->_data;
-
-       TYPE_ORDER order1 = fd1->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY? TO_DIR: TO_FILE;
-       TYPE_ORDER order2 = fd2->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY? TO_DIR: TO_FILE;
-
-        // Handle "." and ".." as special case and move them at the very first beginning.
-       if (order1==TO_DIR && order2==TO_DIR) {
-               order1 = TypeOrderFromDirname(fd1->cFileName);
-               order2 = TypeOrderFromDirname(fd2->cFileName);
-
-                // Move virtual folders after physical folders
-               if (!(entry1->_shell_attribs & SFGAO_FILESYSTEM))
-                       order1 = TO_VIRTUAL_FOLDER;
-
-               if (!(entry2->_shell_attribs & SFGAO_FILESYSTEM))
-                       order2 = TO_VIRTUAL_FOLDER;
-       }
-
-       return order2==order1? 0: order1<order2? -1: 1;
-}
-
-
-static int compareNothing(const void* arg1, const void* arg2)
-{
-       return -1;
-}
-
-static int compareName(const void* arg1, const void* arg2)
-{
-       const Entry* entry1 = *(const Entry**)arg1;
-       const Entry* entry2 = *(const Entry**)arg2;
-
-       int cmp = compareType(entry1, entry2);
-       if (cmp)
-               return cmp;
-
-       return lstrcmpi(entry1->_data.cFileName, entry2->_data.cFileName);
-}
-
-static int compareExt(const void* arg1, const void* arg2)
-{
-       const Entry* entry1 = *(const Entry**)arg1;
-       const Entry* entry2 = *(const Entry**)arg2;
-       const TCHAR *name1, *name2, *ext1, *ext2;
-
-       int cmp = compareType(entry1, entry2);
-       if (cmp)
-               return cmp;
-
-       name1 = entry1->_data.cFileName;
-       name2 = entry2->_data.cFileName;
-
-       ext1 = _tcsrchr(name1, TEXT('.'));
-       ext2 = _tcsrchr(name2, TEXT('.'));
-
-       if (ext1)
-               ++ext1;
-       else
-               ext1 = TEXT("");
-
-       if (ext2)
-               ++ext2;
-       else
-               ext2 = TEXT("");
-
-       cmp = lstrcmpi(ext1, ext2);
-       if (cmp)
-               return cmp;
-
-       return lstrcmpi(name1, name2);
-}
-
-static int compareSize(const void* arg1, const void* arg2)
-{
-       const Entry* entry1 = *(const Entry**)arg1;
-       const Entry* entry2 = *(const Entry**)arg2;
-
-       int cmp = compareType(entry1, entry2);
-       if (cmp)
-               return cmp;
-
-       cmp = entry2->_data.nFileSizeHigh - entry1->_data.nFileSizeHigh;
-
-       if (cmp < 0)
-               return -1;
-       else if (cmp > 0)
-               return 1;
-
-       cmp = entry2->_data.nFileSizeLow - entry1->_data.nFileSizeLow;
-
-       return cmp<0? -1: cmp>0? 1: 0;
-}
-
-static int compareDate(const void* arg1, const void* arg2)
-{
-       const Entry* entry1 = *(const Entry**)arg1;
-       const Entry* entry2 = *(const Entry**)arg2;
-
-       int cmp = compareType(entry1, entry2);
-       if (cmp)
-               return cmp;
-
-       return CompareFileTime(&entry2->_data.ftLastWriteTime, &entry1->_data.ftLastWriteTime);
-}
-
-
-static int (*sortFunctions[])(const void* arg1, const void* arg2) = {
-       compareNothing, // SORT_NONE
-       compareName,    // SORT_NAME
-       compareExt,     // SORT_EXT
-       compareSize,    // SORT_SIZE
-       compareDate     // SORT_DATE
-};
-
-
-void Entry::sort_directory(SORT_ORDER sortOrder)
-{
-       if (sortOrder != SORT_NONE) {
-               Entry* entry = _down;
-               Entry** array, **p;
-               int len;
-
-               len = 0;
-               for(entry=_down; entry; entry=entry->_next)
-                       ++len;
-
-               if (len) {
-                       array = (Entry**) alloca(len*sizeof(Entry*));
-
-                       p = array;
-                       for(entry=_down; entry; entry=entry->_next)
-                               *p++ = entry;
-
-                        // call qsort with the appropriate compare function
-                       qsort(array, len, sizeof(array[0]), sortFunctions[sortOrder]);
-
-                       _down = array[0];
-
-                       for(p=array; --len; p++)
-                               (*p)->_next = p[1];
-
-                       (*p)->_next = 0;
-               }
-       }
-}
-
-
-void Entry::smart_scan(SORT_ORDER sortOrder, int scan_flags)
-{
-       CONTEXT("Entry::smart_scan()");
-
-       if (!_scanned) {
-               free_subentries();
-               read_directory_base(sortOrder, scan_flags);     ///@todo We could use IShellFolder2::GetDefaultColumn to determine sort order.
-       }
-}
-
-
-
-int Entry::extract_icon(ICONCACHE_FLAGS flags)
-{
-       TCHAR path[MAX_PATH];
-
-       ICON_ID icon_id = ICID_NONE;
-
-       if (_etype!=ET_SHELL && get_path(path, COUNTOF(path)))  // not for ET_SHELL to display the correct desktop icon
-               if (!(flags & ICF_MIDDLE))      // not for ICF_MIDDLE to extract 24x24 icons because SHGetFileInfo() doesn't support this icon size
-                       icon_id = g_Globals._icon_cache.extract(path, flags);
-
-       if (icon_id == ICID_NONE) {
-               if (!(flags & ICF_OVERLAYS)) {
-                       IExtractIcon* pExtract;
-                       if (SUCCEEDED(GetUIObjectOf(0, IID_IExtractIcon, (LPVOID*)&pExtract))) {
-                               unsigned gil_flags;
-                               int idx;
-
-                               if (flags & ICF_OPEN)
-                                       gil_flags |= GIL_OPENICON;
-
-                               if (SUCCEEDED(pExtract->GetIconLocation(GIL_FORSHELL, path, COUNTOF(path), &idx, &gil_flags))) {
-                                       if (gil_flags & GIL_NOTFILENAME)
-                                               icon_id = g_Globals._icon_cache.extract(pExtract, path, idx, flags);
-                                       else {
-                                               if (idx == -1)
-                                                       idx = 0;        // special case for some control panel applications ("System")
-
-                                               icon_id = g_Globals._icon_cache.extract(path, idx, flags);
-                                       }
-
-                               /* using create_absolute_pidl() [see below] results in more correct icons for some control panel applets (NVidia display driver).
-                                       if (icon_id == ICID_NONE) {
-                                               SHFILEINFO sfi;
-
-                                               if (SHGetFileInfo(path, 0, &sfi, sizeof(sfi), SHGFI_ICON|SHGFI_SMALLICON))
-                                                       icon_id = g_Globals._icon_cache.add(sfi.hIcon)._id;
-                                       } */
-                               /*
-                                       if (icon_id == ICID_NONE) {
-                                               LPBYTE b = (LPBYTE) alloca(0x10000);
-                                               SHFILEINFO sfi;
-
-                                               FILE* file = fopen(path, "rb");
-                                               if (file) {
-                                                       int l = fread(b, 1, 0x10000, file);
-                                                       fclose(file);
-
-                                                       if (l)
-                                                               icon_id = g_Globals._icon_cache.add(CreateIconFromResourceEx(b, l, TRUE, 0x00030000, 16, 16, LR_DEFAULTCOLOR));
-                                               }
-                                       } */
-                               }
-                       }
-               }
-
-               if (icon_id == ICID_NONE) {
-                       SHFILEINFO sfi;
-
-                       const ShellPath& pidl_abs = create_absolute_pidl();
-                       LPCITEMIDLIST pidl = pidl_abs;
-
-                       int shgfi_flags = SHGFI_PIDL;
-
-                       if (!(flags & (ICF_LARGE|ICF_MIDDLE)))
-                               shgfi_flags |= SHGFI_SMALLICON;
-
-                       if (flags & ICF_OPEN)
-                               shgfi_flags |= SHGFI_OPENICON;
-
-                       if (flags & ICF_SYSCACHE) {
-                               assert(!(flags&ICF_OVERLAYS));
-
-                               HIMAGELIST himlSys = (HIMAGELIST) SHGetFileInfo((LPCTSTR)pidl, 0, &sfi, sizeof(sfi), SHGFI_SYSICONINDEX|shgfi_flags);
-                               if (himlSys)
-                                       icon_id = g_Globals._icon_cache.add(sfi.iIcon);
-                       } else {
-                               if (flags & ICF_OVERLAYS)
-                                       shgfi_flags |= SHGFI_ADDOVERLAYS;
-
-                               if (SHGetFileInfo((LPCTSTR)pidl, 0, &sfi, sizeof(sfi), SHGFI_ICON|shgfi_flags))
-                                       icon_id = g_Globals._icon_cache.add(sfi.hIcon);
-                       }
-               }
-       }
-
-       return icon_id;
-}
-
-int Entry::safe_extract_icon(ICONCACHE_FLAGS flags)
-{
-       try {
-               return extract_icon(flags);
-       } catch(COMException&) {
-               // ignore unexpected exceptions while extracting icons
-       }
-
-       return ICID_NONE;
-}
-
-
-BOOL Entry::launch_entry(HWND hwnd, UINT nCmdShow)
-{
-       TCHAR cmd[MAX_PATH];
-
-       if (!get_path(cmd, COUNTOF(cmd)))
-               return FALSE;
-
-        // add path to the recent file list
-       SHAddToRecentDocs(SHARD_PATH, cmd);
-
-         // start program, open document...
-       return launch_file(hwnd, cmd, nCmdShow);
-}
-
-
- // local replacement implementation for SHBindToParent()
- // (derived from http://www.geocities.com/SiliconValley/2060/articles/shell-helpers.html)
-static HRESULT my_SHBindToParent(LPCITEMIDLIST pidl, REFIID riid, VOID** ppv, LPCITEMIDLIST* ppidlLast)
-{
-       HRESULT hr;
-
-       if (!ppv)
-               return E_POINTER;
-
-       // There must be at least one item ID.
-       if (!pidl || !pidl->mkid.cb)
-               return E_INVALIDARG;
-
-        // Get the desktop folder as root.
-       ShellFolder desktop;
-/*     IShellFolderPtr desktop;
-       hr = SHGetDesktopFolder(&desktop);
-       if (FAILED(hr))
-               return hr; */
-
-       // Walk to the penultimate item ID.
-       LPCITEMIDLIST marker = pidl;
-       for (;;)
-       {
-               LPCITEMIDLIST next = reinterpret_cast<LPCITEMIDLIST>(
-                       marker->mkid.abID - sizeof(marker->mkid.cb) + marker->mkid.cb);
-               if (!next->mkid.cb)
-                       break;
-               marker = next;
-       }
-
-       if (marker == pidl)
-       {
-               // There was only a single item ID, so bind to the root folder.
-               hr = desktop->QueryInterface(riid, ppv);
-       }
-       else
-       {
-               // Copy the ID list, truncating the last item.
-               int length = marker->mkid.abID - pidl->mkid.abID;
-               if (LPITEMIDLIST parent_id = reinterpret_cast<LPITEMIDLIST>(
-                       malloc(length + sizeof(pidl->mkid.cb))))
-               {
-                       LPBYTE raw_data = reinterpret_cast<LPBYTE>(parent_id);
-                       memcpy(raw_data, pidl, length);
-                       memset(raw_data + length, 0, sizeof(pidl->mkid.cb));
-                       hr = desktop->BindToObject(parent_id, 0, riid, ppv);
-                       free(parent_id);
-               }
-               else
-                       return E_OUTOFMEMORY;
-       }
-
-       // Return a pointer to the last item ID.
-       if (ppidlLast)
-               *ppidlLast = marker;
-
-       return hr;
-}
-#define USE_MY_SHBINDTOPARENT
-
-HRESULT Entry::do_context_menu(HWND hwnd, const POINT& pos, CtxMenuInterfaces& cm_ifs)
-{
-       ShellPath shell_path = create_absolute_pidl();
-       LPCITEMIDLIST pidl_abs = shell_path;
-
-       if (!pidl_abs)
-               return S_FALSE; // no action for registry entries, etc.
-
-#ifdef USE_MY_SHBINDTOPARENT
-       IShellFolder* parentFolder;
-       LPCITEMIDLIST pidlLast;
-
-        // get and use the parent folder to display correct context menu in all cases -> correct "Properties" dialog for directories, ...
-       HRESULT hr = my_SHBindToParent(pidl_abs, IID_IShellFolder, (LPVOID*)&parentFolder, &pidlLast);
-
-       if (SUCCEEDED(hr)) {
-               hr = ShellFolderContextMenu(parentFolder, hwnd, 1, &pidlLast, pos.x, pos.y, cm_ifs);
-
-               parentFolder->Release();
-       }
-
-       return hr;
-#else
-       static DynamicFct<HRESULT(WINAPI*)(LPCITEMIDLIST, REFIID, LPVOID*, LPCITEMIDLIST*)> SHBindToParent(TEXT("SHELL32"), "SHBindToParent");
-
-       if (SHBindToParent) {
-               IShellFolder* parentFolder;
-               LPCITEMIDLIST pidlLast;
-
-                // get and use the parent folder to display correct context menu in all cases -> correct "Properties" dialog for directories, ...
-               HRESULT hr = (*SHBindToParent)(pidl_abs, IID_IShellFolder, (LPVOID*)&parentFolder, &pidlLast);
-
-               if (SUCCEEDED(hr)) {
-                       hr = ShellFolderContextMenu(parentFolder, hwnd, 1, &pidlLast, pos.x, pos.y, cm_ifs);
-
-                       parentFolder->Release();
-               }
-
-               return hr;
-       } else {
-               /**@todo use parent folder instead of desktop folder
-               Entry* dir = _up;
-
-               ShellPath parent_path;
-
-               if (dir)
-                       parent_path = dir->create_absolute_pidl();
-               else
-                       parent_path = DesktopFolderPath();
-
-               ShellPath shell_path = create_relative_pidl(parent_path);
-               LPCITEMIDLIST pidl = shell_path;
-
-               ShellFolder parent_folder = parent_path;
-               return ShellFolderContextMenu(parent_folder, hwnd, 1, &pidl, pos.x, pos.y);
-               */
-               return ShellFolderContextMenu(GetDesktopFolder(), hwnd, 1, &pidl_abs, pos.x, pos.y, cm_ifs);
-       }
-#endif
-}
-
-
-HRESULT Entry::GetUIObjectOf(HWND hWnd, REFIID riid, LPVOID* ppvOut)
-{
-       TCHAR path[MAX_PATH];
-/*
-       if (!get_path(path, COUNTOF(path)))
-               return E_FAIL;
-
-       ShellPath shell_path(path);
-
-       IShellFolder* pFolder;
-       LPCITEMIDLIST pidl_last = NULL;
-
-       static DynamicFct<HRESULT(WINAPI*)(LPCITEMIDLIST, REFIID, LPVOID*, LPCITEMIDLIST*)> SHBindToParent(TEXT("SHELL32"), "SHBindToParent");
-
-       if (!SHBindToParent)
-               return E_NOTIMPL;
-
-       HRESULT hr = (*SHBindToParent)(shell_path, IID_IShellFolder, (LPVOID*)&pFolder, &pidl_last);
-       if (FAILED(hr))
-               return hr;
-
-       ShellFolder shell_folder(pFolder);
-
-       shell_folder->Release();
-
-       return shell_folder->GetUIObjectOf(hWnd, 1, &pidl_last, riid, NULL, ppvOut);
-*/
-       if (!_up)
-               return E_INVALIDARG;
-
-       if (!_up->get_path(path, COUNTOF(path)))
-               return E_FAIL;
-
-       ShellPath shell_path(path);
-       ShellFolder shell_folder(shell_path);
-
-#ifdef UNICODE
-       LPWSTR wname = _data.cFileName;
-#else
-       WCHAR wname[MAX_PATH];
-       MultiByteToWideChar(CP_ACP, 0, _data.cFileName, -1, wname, COUNTOF(wname));
-#endif
-
-       LPITEMIDLIST pidl_last = NULL;
-       HRESULT hr = shell_folder->ParseDisplayName(hWnd, NULL, wname, NULL, &pidl_last, NULL);
-
-       if (FAILED(hr))
-               return hr;
-
-       hr = shell_folder->GetUIObjectOf(hWnd, 1, (LPCITEMIDLIST*)&pidl_last, riid, NULL, ppvOut);
-
-       ShellMalloc()->Free((void*)pidl_last);
-
-       return hr;
-}
-
-
- // get full path of specified directory entry
-bool Entry::get_path_base ( PTSTR path, size_t path_count, ENTRY_TYPE etype ) const
-{
-       int level = 0;
-       size_t len = 0;
-       size_t l = 0;
-       LPCTSTR name = NULL;
-       TCHAR buffer[MAX_PATH];
-
-       if (!path || path_count==0)
-               return false;
-
-       const Entry* entry;
-       if ( path_count > 1 )
-       {
-               for(entry=this; entry; level++) {
-                       l = 0;
-
-                       if (entry->_etype == etype) {
-                               name = entry->_data.cFileName;
-
-                               for(LPCTSTR s=name; *s && *s!=TEXT('/') && *s!=TEXT('\\'); s++)
-                                       ++l;
-
-                               if (!entry->_up)
-                                       break;
-                       } else {
-                               if (entry->get_path(buffer, COUNTOF(buffer))) {
-                                       l = _tcslen(buffer);
-                                       name = buffer;
-
-                                       /* special handling of drive names */
-                                       if (l>0 && buffer[l-1]=='\\' && path[0]=='\\')
-                                               --l;
-
-                                       if ( len+l >= path_count )
-                                       {
-                                               if ( l + 1 > path_count )
-                                                       len = 0;
-                                               else
-                                                       len = path_count - l - 1;
-                                       }
-                                       memmove(path+l, path, len*sizeof(TCHAR));
-                                       if ( l+1 >= path_count )
-                                               l = path_count - 1;
-                                       memcpy(path, name, l*sizeof(TCHAR));
-                                       len += l;
-                               }
-
-                               entry = NULL;
-                               break;
-                       }
-
-                       if (l > 0) {
-                               if ( len+l+1 >= path_count )
-                               {
-                                       /* compare to 2 here because of terminator plus the '\\' we prepend */
-                                       if ( l + 2 > path_count )
-                                               len = 0;
-                                       else
-                                               len = path_count - l - 2;
-                               }
-                               memmove(path+l+1, path, len*sizeof(TCHAR));
-                               /* compare to 2 here because of terminator plus the '\\' we prepend */
-                               if ( l+2 >= path_count )
-                                       l = path_count - 2;
-                               memcpy(path+1, name, l*sizeof(TCHAR));
-                               len += l+1;
-
-#ifndef _NO_WIN_FS
-                               if (etype == ET_WINDOWS && entry->_up && !(entry->_up->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY))      // a NTFS stream?
-                                       path[0] = TEXT(':');
-                               else
-#endif
-                                       path[0] = TEXT('\\');
-                       }
-
-                       entry = entry->_up;
-               }
-
-               if (entry) {
-                       if ( len+l >= path_count )
-                       {
-                               if ( l + 1 > path_count )
-                                       len = 0;
-                               else
-                                       len = path_count - l - 1;
-                       }
-                       memmove(path+l, path, len*sizeof(TCHAR));
-                       if ( l+1 >= path_count )
-                               l = path_count - 1;
-                       memcpy(path, name, l*sizeof(TCHAR));
-                       len += l;
-               }
-
-               if ( !level && (len+1 < path_count) )
-                       path[len++] = TEXT('\\');
-       }
-
-       path[len] = TEXT('\0');
-
-       return true;
-}
-
- // recursively free all child entries
-void Entry::free_subentries()
-{
-       Entry *entry, *next=_down;
-
-       if (next) {
-               _down = 0;
-
-               do {
-                       entry = next;
-                       next = entry->_next;
-
-                       entry->free_subentries();
-                       delete entry;
-               } while(next);
-       }
-}
-
-
-Entry* Root::read_tree(LPCTSTR path, int scan_flags)
-{
-       Entry* entry;
-
-       if (path && *path)
-               entry = _entry->read_tree(path, _sort_order);
-       else {
-               entry = _entry->read_tree(NULL, _sort_order);
-
-               _entry->smart_scan();
-
-               if (_entry->_down)
-                       _entry->_expanded = true;
-       }
-
-       return entry;
-}
-
-
-Entry* Root::read_tree(LPCITEMIDLIST pidl, int scan_flags)
-{
-       return _entry->read_tree(pidl, _sort_order);
-}
diff --git a/reactos/subsys/system/explorer/shell/entries.h b/reactos/subsys/system/explorer/shell/entries.h
deleted file mode 100644 (file)
index b0f162e..0000000
+++ /dev/null
@@ -1,162 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // entries.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-enum ENTRY_TYPE {
-       ET_UNKNOWN,
-#ifndef _NO_WIN_FS
-       ET_WINDOWS,
-#endif
-#ifdef __WINE__
-       ET_UNIX,
-#endif
-       ET_SHELL,
-       ET_NTOBJS,
-       ET_REGISTRY,
-       ET_FAT,
-       ET_WEB
-};
-
-enum SORT_ORDER {
-       SORT_NONE,
-       SORT_NAME,
-       SORT_EXT,
-       SORT_SIZE,
-       SORT_DATE
-};
-
-enum SCAN_FLAGS {
-       SCAN_DONT_EXTRACT_ICONS = 1,
-       SCAN_DONT_ACCESS                = 2,
-       SCAN_NO_FILESYSTEM              = 4
-};
-
-#ifndef ATTRIBUTE_SYMBOLIC_LINK
-#define        ATTRIBUTE_LONGNAME                      0x08000000
-#define        ATTRIBUTE_VOLNAME                       0x10000000
-#define        ATTRIBUTE_ERASED                        0x20000000
-#define ATTRIBUTE_SYMBOLIC_LINK                0x40000000
-#define        ATTRIBUTE_EXECUTABLE            0x80000000
-#endif
-
-enum ICONCACHE_FLAGS {
-       ICF_NORMAL       =  0,
-       ICF_MIDDLE       =  1,
-       ICF_LARGE        =  2,
-       ICF_OPEN         =  4,
-       ICF_OVERLAYS =  8,
-       ICF_HICON        = 16,
-       ICF_SYSCACHE = 32
-};
-
-#ifndef SHGFI_ADDOVERLAYS // missing in MinGW (as of 28.12.2005)
-#define SHGFI_ADDOVERLAYS 0x000000020
-#endif
-
-
- /// base of all file and directory entries
-struct Entry
-{
-protected:
-       Entry(ENTRY_TYPE etype);
-       Entry(Entry* parent, ENTRY_TYPE etype);
-       Entry(const Entry&);
-
-public:
-       virtual ~Entry();
-
-       Entry*          _next;
-       Entry*          _down;
-       Entry*          _up;
-
-       bool            _expanded;
-       bool            _scanned;
-       int             _level;
-
-       WIN32_FIND_DATA _data;
-
-       SFGAOF          _shell_attribs;
-       LPTSTR          _display_name;
-       LPTSTR          _type_name;
-       LPTSTR          _content;
-
-       ENTRY_TYPE      _etype;
-       int /*ICON_ID*/ _icon_id;
-
-       BY_HANDLE_FILE_INFORMATION _bhfi;
-       bool            _bhfi_valid;
-
-       void    free_subentries();
-
-       void    read_directory_base(SORT_ORDER sortOrder=SORT_NAME, int scan_flags=0);
-       Entry*  read_tree(const void* path, SORT_ORDER sortOrder=SORT_NAME, int scan_flags=0);
-       void    sort_directory(SORT_ORDER sortOrder);
-       void    smart_scan(SORT_ORDER sortOrder=SORT_NAME, int scan_flags=0);
-       int             extract_icon(ICONCACHE_FLAGS flags=ICF_NORMAL);
-       int             safe_extract_icon(ICONCACHE_FLAGS flags=ICF_NORMAL);
-
-       virtual void            read_directory(int scan_flags=0) {}
-       virtual const void*     get_next_path_component(const void*) const {return NULL;}
-       virtual Entry*          find_entry(const void*) {return NULL;}
-       virtual bool            get_path(PTSTR path, size_t path_count) const = 0;
-       virtual ShellPath       create_absolute_pidl() const {return (LPCITEMIDLIST)NULL;}
-       virtual HRESULT         GetUIObjectOf(HWND hWnd, REFIID riid, LPVOID* ppvOut);
-       virtual ShellFolder get_shell_folder() const;
-       virtual BOOL            launch_entry(HWND hwnd, UINT nCmdShow=SW_SHOWNORMAL);
-       virtual HRESULT         do_context_menu(HWND hwnd, const POINT& pos, CtxMenuInterfaces& cm_ifs);
-
-protected:
-       bool    get_path_base(PTSTR path, size_t path_count, ENTRY_TYPE etype) const;
-};
-
-
- /// base for all directory entries
-struct Directory {
-protected:
-       Directory() : _path(NULL) {}
-       virtual ~Directory() {}
-
-       void*   _path;
-};
-
-
- /// root entry for file system trees
-struct Root {
-       Root();
-       ~Root();
-
-       Entry*  _entry;
-       TCHAR   _path[MAX_PATH];
-       TCHAR   _volname[_MAX_FNAME];
-       TCHAR   _fs[_MAX_DIR];
-       DWORD   _drive_type;
-       DWORD   _fs_flags;
-       SORT_ORDER _sort_order;
-
-       Entry*  read_tree(LPCTSTR path, int scan_flags=0);
-       Entry*  read_tree(LPCITEMIDLIST pidl, int scan_flags=0);
-};
diff --git a/reactos/subsys/system/explorer/shell/fatfs.cpp b/reactos/subsys/system/explorer/shell/fatfs.cpp
deleted file mode 100644 (file)
index 8750637..0000000
+++ /dev/null
@@ -1,634 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // fatfs.cpp
- //
- // Martin Fuchs, 01.02.2004
- //
-
-
-#include <precomp.h>
-
-#include "fatfs.h"
-
-
-static union DEntry* link_dir_entries(struct dirent* dir, struct Kette* K, int cnt)
-{
-       union DEntry* Ent = (union DEntry*) dir;
-       struct Kette* L = NULL;
-
-       for(; cnt; cnt--) {
-               K->Rueck = L;
-               (L=K)->Ent = Ent;
-               AddP(K, sizeof(struct Kette));
-               L->Vorw = K;
-               AddP(Ent, sizeof(union DEntry));
-       }
-
-       L->Vorw = NULL;
-
-       return Ent;
-}
-
-void FATDirectory::read_directory(int scan_flags)
-{
-       CONTEXT("FATDirectory::read_directory()");
-
-       read_dir();
-
-       union DEntry* p = (union DEntry*) _dir;
-       int i = 0;
-
-       do {
-/*             if (!IS_LNAME(p->E.attr) && p->E.name[0]!=FAT_DEL_CHAR)
-                       gesBytes += p->E.size;
-*/
-
-               AddP(p, sizeof(union DEntry));
-       } while(++i<_ents && p->E.name[0]);
-
-       _alloc = (struct Kette*) malloc((size_t)((_ents=i)+8)*sizeof(struct Kette));
-       if (!_alloc)
-               return;
-
-       link_dir_entries(_dir, _alloc, i);
-
-       Entry* first_entry = NULL;
-       int level = _level + 1;
-
-       Entry* last = NULL;
-
-       WIN32_FIND_DATA w32fd;
-       FAT_attribute attr;
-       String long_name;
-
-       TCHAR buffer[MAX_PATH];
-
-       _tcscpy(buffer, (LPCTSTR)_path);
-       LPTSTR pname = buffer + _tcslen(buffer);
-       int plen = COUNTOF(buffer) - _tcslen(buffer);
-
-       *pname++ = '\\';
-       --plen;
-
-       for(Kette*p=_alloc; p; p=p->Vorw) {
-               memset(&w32fd, 0, sizeof(WIN32_FIND_DATA));
-
-               DEntry_E& e = p->Ent->E;
-
-                // get file/directory attributes
-               attr.b = e.attr;
-
-               if (attr.b & (_A_DELETED | _A_ILLEGAL))
-                       attr.b |= _A_ILLEGAL;
-
-               const char* s = e.name;
-               LPTSTR d = w32fd.cFileName;
-
-               if (!IS_LNAME(attr.b) || e.name[0]==FAT_DEL_CHAR) {
-                       if (e.name[0] == FAT_DEL_CHAR)
-                               w32fd.dwFileAttributes |= ATTRIBUTE_ERASED;
-                       else if (IS_LNAME(attr.b))
-                               w32fd.dwFileAttributes |= ATTRIBUTE_LONGNAME;
-                       else if (attr.a.directory)
-                               w32fd.dwFileAttributes |= FILE_ATTRIBUTE_DIRECTORY;
-                       else if (attr.a.volume)
-                               w32fd.dwFileAttributes |= ATTRIBUTE_VOLNAME;    //@@ -> in Volume-Name der Root kopieren
-
-                        // get file name
-                       *d++ = *s==FAT_DEL_CHAR? '?': *s;
-                       ++s;
-
-                       for(i=0; i<7; ++i)
-                               *d++ = *s++;
-
-                       while(d>w32fd.cFileName && d[-1]==' ')
-                               --d;
-
-                       *d++ = '.';
-
-                       for(; i<10; ++i)
-                               *d++ = *s++;
-
-                       while(d>w32fd.cFileName && d[-1]==' ')
-                               --d;
-
-                       if (d>w32fd.cFileName && d[-1]=='.')
-                               --d;
-
-                       *d = '\0';
-               } else {
-                        // read long file name
-                       TCHAR lname[] = {s[1], s[3], s[5], s[7], s[9], s[14], s[16], s[18], s[20], s[22], s[24], s[28], s[30]};
-
-                       long_name = String(lname, 13) + long_name;
-               }
-
-               if (!IS_LNAME(attr.b) && !attr.a.volume) {
-                        // get file size
-                       w32fd.nFileSizeLow = e.size;
-
-                        // convert date/time attribute into FILETIME
-                       const fdate& date = e.date;
-                       const ftime& time = e.time;
-                       SYSTEMTIME stime;
-                       FILETIME ftime;
-
-                       stime.wYear = date.year + 1980;
-                       stime.wMonth = date.month;
-                       stime.wDayOfWeek = (WORD)-1;
-                       stime.wDay = date.day;
-                       stime.wHour = time.hour;
-                       stime.wMinute = time.min;
-                       stime.wSecond = time.sec2 * 2;
-                       stime.wMilliseconds = 0;
-
-                       if (SystemTimeToFileTime(&stime, &ftime))
-                               LocalFileTimeToFileTime(&ftime, &w32fd.ftLastWriteTime);
-
-                       if (!(w32fd.dwFileAttributes & ATTRIBUTE_ERASED)) { //@@
-                               Entry* entry;
-
-                               if (w32fd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-                                       _tcscpy_s(pname, plen, w32fd.cFileName);
-                                       entry = new FATDirectory(_drive, this, buffer, e.fclus);
-                               } else
-                                       entry = new FATEntry(this, e.fclus);
-
-                               memcpy(&entry->_data, &w32fd, sizeof(WIN32_FIND_DATA));
-
-                               if (!long_name.empty()) {
-                                       entry->_content = _tcsdup(long_name);
-                                       long_name.erase();
-                               }
-
-                               if (!first_entry)
-                                       first_entry = entry;
-
-                               if (last)
-                                       last->_next = entry;
-
-                               entry->_level = level;
-
-                               last = entry;
-                       }
-               }
-       }
-
-       if (last)
-               last->_next = NULL;
-
-       _down = first_entry;
-       _scanned = true;
-}
-
-
-const void* FATDirectory::get_next_path_component(const void* p) const
-{
-       LPCTSTR s = (LPCTSTR) p;
-
-       while(*s && *s!=TEXT('\\') && *s!=TEXT('/'))
-               ++s;
-
-       while(*s==TEXT('\\') || *s==TEXT('/'))
-               ++s;
-
-       if (!*s)
-               return NULL;
-
-       return s;
-}
-
-
-Entry* FATDirectory::find_entry(const void* p)
-{
-       LPCTSTR name = (LPCTSTR)p;
-
-       for(Entry*entry=_down; entry; entry=entry->_next) {
-               LPCTSTR p = name;
-               LPCTSTR q = entry->_data.cFileName;
-
-               do {
-                       if (!*p || *p==TEXT('\\') || *p==TEXT('/'))
-                               return entry;
-               } while(tolower(*p++) == tolower(*q++));
-
-               p = name;
-               q = entry->_data.cAlternateFileName;
-
-               do {
-                       if (!*p || *p==TEXT('\\') || *p==TEXT('/'))
-                               return entry;
-               } while(tolower(*p++) == tolower(*q++));
-       }
-
-       return NULL;
-}
-
-
- // get full path of specified directory entry
-bool FATEntry::get_path(PTSTR path, size_t path_count) const
-{
-       return get_path_base ( path, path_count, ET_FAT );
-}
-
-ShellPath FATEntry::create_absolute_pidl() const
-{
-       CONTEXT("WinEntry::create_absolute_pidl()");
-
-       return (LPCITEMIDLIST)NULL;
-/* prepend root path if the drive is currently actually mounted in the file system -> return working PIDL
-       TCHAR path[MAX_PATH];
-
-       if (get_path(path, COUNTOF(path)))
-               return ShellPath(path);
-
-       return ShellPath();
-*/
-}
-
-
-FATDirectory::FATDirectory(FATDrive& drive, LPCTSTR root_path)
- :     FATEntry(),
-       _drive(drive)
-{
-       _path = _tcsdup(root_path);
-
-       _secarr         = NULL;
-       _cur_bufs       = 0;
-       _ents           = 0;
-       _dir            = NULL;
-       _cluster        = 0;
-}
-
-FATDirectory::FATDirectory(FATDrive& drive, Entry* parent, LPCTSTR path, unsigned cluster)
- :     FATEntry(parent, cluster),
-       _drive(drive)
-{
-       _path = _tcsdup(path);
-
-       _secarr         = NULL;
-       _cur_bufs       = 0;
-       _ents           = 0;
-       _dir            = NULL;
-}
-
-FATDirectory::~FATDirectory()
-{
-       free(_path);
-       _path = NULL;
-}
-
-bool FATDirectory::read_dir()
-{
-       int i;
-
-       if (_cluster == 0) {
-               if (!_drive._boot_sector.SectorsPerFAT) {       // FAT32? [boot_sector32->reserved0==0]
-                       BootSector32* boot_sector32 = (BootSector32*) &_drive._boot_sector;
-                       DWORD sect = _drive._boot_sector.ReservedSectors + _drive._boot_sector.NumberFATs*boot_sector32->SectorsPerFAT32;  // lese Root-Directory ein
-                       int RootEntries = boot_sector32->RootSectors * 32;      //@@
-
-                       _secarr = (struct dirsecz*)malloc(sizeof(DWORD) * (_cur_bufs = (int)((_ents=RootEntries)/_drive._bufents)));
-
-                       for(i=0; i<_cur_bufs; i++)
-                               _secarr->s[i] = sect+i;
-
-                       _dir = (struct dirent*)malloc((size_t)(_ents+16)*sizeof(union DEntry));
-                       if (!_dir)
-                               return false;
-
-                       if (!(_drive.read_sector(*_secarr->s,(Buffer*)_dir,_cur_bufs)))
-                               return false;
-               } else {
-                       DWORD sect = _drive._boot_sector.ReservedSectors + _drive._boot_sector.NumberFATs*_drive._boot_sector.SectorsPerFAT;  // read in root directory
-
-                       _secarr = (struct dirsecz*)malloc(sizeof(DWORD) * (_cur_bufs = (int)((_ents=_drive._boot_sector.RootEntries)/_drive._bufents)));
-
-                       for(i=0; i<_cur_bufs; i++)
-                               _secarr->s[i] = sect+i;
-
-                       _dir = (struct dirent*)malloc((size_t)(_ents+16)*sizeof(union DEntry));
-                       if (!_dir)
-                               return false;
-
-                       if (!_drive.read_sector(*_secarr->s,(Buffer*)_dir,_cur_bufs))
-                               return false;
-               }
-       } else {
-               Buffer* buf;
-               bool ok;
-
-               DWORD h = _cluster;
-
-               _cur_bufs = 0;
-
-               do {
-                       h = _drive.read_FAT(h, ok);
-
-                       if (!ok)
-                               return false;
-
-                       _cur_bufs++;
-               } while (h<0x0ffffff0 && h);
-
-               _secarr = (struct dirsecz*) malloc(sizeof(DWORD) * _cur_bufs);
-
-               if (!_secarr)
-                       return false;
-
-               _ents = _drive._bufents * (size_t)_cur_bufs * _drive._SClus;
-
-               if ((buf=(Buffer*)(_dir=(struct dirent*)malloc((size_t) (_ents+16)*sizeof(union DEntry)))) == NULL)
-                       return false;
-
-               h = _cluster;
-
-               DWORD fdatsec;
-
-               if (!_drive._boot_sector.SectorsPerFAT) {       // FAT32 ?
-                       BootSector32* boot_sector32 = (BootSector32*) &_drive._boot_sector;
-                       //int RootEntries = boot_sector32->RootSectors * 32;    //@@
-                       //fdatsec = _drive._boot_sector.ReservedSectors + _drive._boot_sector.NumberFATs*boot_sector32->SectorsPerFAT32 + RootEntries*sizeof(DEntry)/_drive._boot_sector.BytesPerSector;        // dpb.fdirsec
-                       fdatsec = _drive._boot_sector.ReservedSectors +
-                                               _drive._boot_sector.NumberFATs*boot_sector32->SectorsPerFAT32 + boot_sector32->RootSectors;
-               } else
-                       fdatsec = _drive._boot_sector.ReservedSectors +
-                                               _drive._boot_sector.NumberFATs*_drive._boot_sector.SectorsPerFAT +
-                                               _drive._boot_sector.RootEntries*sizeof(DEntry)/_drive._boot_sector.BytesPerSector;      // dpb.fdirsec
-
-                       for(i=0; i<_cur_bufs; i++) {
-                               _secarr->s[i] = fdatsec + (DWORD)_drive._SClus*(h-2);
-
-                               h = _drive.read_FAT(h, ok);
-
-                               if (!ok)
-                                       return false;
-                       }
-
-                       for(i=0; i<_cur_bufs; i++) {
-                               if ((ok = (_drive.read_sector(_secarr->s[i], buf, _drive._SClus))) == true)
-                                       AddP(buf, _drive._bufl*_drive._SClus)
-                               else {
-                                       //@@FPara = _secarr->s[i];
-                                       return false;
-                               }
-                       }
-
-               buf->dat[0] = 0;         // Endekennzeichen für Rekurs setzen
-       }
-
-       return true;
-}
-
-
-#ifdef _MSC_VER
-#pragma warning(disable: 4355)
-#endif
-
-FATDrive::FATDrive(LPCTSTR path)
- :     FATDirectory(*this, TEXT("\\"))
-{
-       _bufl = 0;
-       _bufents = 0;
-       _SClus = 0;
-       _FATCache = NULL;
-       _CacheCount = 0;
-       _CacheSec = NULL;
-       _CacheCnt = NULL;
-       _CacheDty = NULL;
-       _Caches = 0;
-
-       _hDrive = CreateFile(path, GENERIC_READ|GENERIC_WRITE, FILE_SHARE_READ|FILE_SHARE_WRITE, NULL, OPEN_EXISTING, 0, 0);
-
-       if (_hDrive != INVALID_HANDLE_VALUE) {
-               _boot_sector.BytesPerSector = 512;
-
-               if (read_sector(0, (Buffer*)&_boot_sector, 1)) {
-                       _bufl = _boot_sector.BytesPerSector;
-                       _SClus = _boot_sector.SectorsPerCluster;
-                       _bufents = _bufl / sizeof(union DEntry);
-               }
-
-               small_cache();
-       }
-}
-
-FATDrive::~FATDrive()
-{
-       if (_hDrive != INVALID_HANDLE_VALUE)
-               CloseHandle(_hDrive);
-
-       free(_path);
-       _path = NULL;
-}
-
-void FATDrive::small_cache()
-{
-       if (_FATCache)
-               free(_FATCache);
-
-       if (_CacheSec) {
-               free(_CacheSec), _CacheSec = NULL;
-               free(_CacheCnt);
-               free(_CacheDty);
-       }
-
-       _Caches = CACHE_SIZE_LOW;
-       _FATCache = (struct Cache *) malloc((_Caches+1) * _drive._bufl);
-
-       reset_cache();
-}
-
-void FATDrive::reset_cache()   // mark cache as empty
-{
-       int i;
-
-       if (!_CacheSec) {
-               _CacheSec = (DWORD*) malloc(_Caches * sizeof(DWORD));
-               _CacheCnt = (int*) malloc(_Caches * sizeof(int));
-               _CacheDty = (bool*) malloc(_Caches * sizeof(bool));
-       } else {
-               _CacheSec = (DWORD*) realloc(_CacheSec, _Caches * sizeof(DWORD));
-               _CacheCnt = (int*) realloc(_CacheCnt, _Caches * sizeof(int));
-               _CacheDty = (bool*) realloc(_CacheDty, _Caches * sizeof(bool));
-       }
-
-       for(i=0; i<_Caches; i++)
-               _CacheSec[i] = 0;
-
-       _read_ahead = (_Caches+1) / 2;
-}
-
-bool FATDrive::read_sector(DWORD sec, Buffer* buf, int len)
-{
-       sec += 63;      //@@ jump to first partition
-
-       if (SetFilePointer(_hDrive, sec*_drive._boot_sector.BytesPerSector, 0, 0) == INVALID_SET_FILE_POINTER)
-               return false;
-
-       DWORD read;
-
-       if (!ReadFile(_hDrive, buf, len*_drive._boot_sector.BytesPerSector, &read, 0))
-               return false;
-
-       return true;
-}
-
-DWORD FATDrive::read_FAT(DWORD cluster, bool& ok)      //@@ use exception handling
-{
-       DWORD nClus;
-       Buffer* FATBuf;
-
-       DWORD nclus = (_boot_sector.Sectors32? _boot_sector.Sectors32: _boot_sector.Sectors16) / _boot_sector.SectorsPerCluster;        ///@todo cache result
-
-       if (cluster > nclus) {
-               ok = false;
-               return (DWORD)-1;
-       }
-
-       if (nclus >= 65536) {           // FAT32
-               DWORD FATsec = cluster / (_boot_sector.BytesPerSector/4);
-               DWORD z = (cluster - _boot_sector.BytesPerSector/4 * FATsec)*4;
-               FATsec += _boot_sector.ReservedSectors;
-               if (!read_cache(FATsec, &FATBuf))
-                       ok = false;
-               nClus = dpeek(&FATBuf->dat[z]);
-       } else if (nclus >= 4096) {     // 16 Bit-FAT
-               DWORD FATsec = cluster / (_boot_sector.BytesPerSector/2);
-               DWORD z = (cluster - _boot_sector.BytesPerSector/2 * FATsec)*2;
-               FATsec += _boot_sector.ReservedSectors;
-               if (!read_cache(FATsec, &FATBuf))
-                       ok = false;
-               nClus = wpeek(&FATBuf->dat[z]);
-
-               if (nClus >= 0xfff0)
-                       nClus |= 0x0fff0000;
-       } else {                                                // 12 Bit-FAT
-               DWORD FATsec = cluster*3 / (_boot_sector.BytesPerSector*2);
-               DWORD z = (cluster*3 - _boot_sector.BytesPerSector*2*FATsec)/2;
-               FATsec += _boot_sector.ReservedSectors;
-               if (!read_cache(FATsec,&FATBuf))
-                       ok = false;
-               BYTE a = FATBuf->dat[z++];
-
-               if (z >= _boot_sector.BytesPerSector)
-                       if (!read_cache(FATsec+1,&FATBuf))
-                               ok = false;
-               z = 0;
-
-               BYTE b = FATBuf->dat[z];
-
-               if (cluster & 1)
-                       nClus = (a>>4) | (b<<4);
-               else
-                       nClus = a | ((b & 0xf)<<8);
-
-               if (nClus >= 0xff0)
-                       nClus |= 0x0ffff000;
-       }
-
-       return nClus;
-}
-
-bool FATDrive::read_cache(DWORD sec, Buffer** bufptr)
-{
- int i, C, anz;
-
- if (_boot_sector.BytesPerSector != BufLen)  // no standard sector size?
-  return read_sector(sec, *bufptr=(Buffer*)&_FATCache[0], 1);
-
- _CacheCount++;
-
- for(i=0; _CacheSec[i]!=sec && i<_Caches; )
-  ++i;
-
- if (i < _Caches)
-  {
-   *bufptr = (Buffer*) &_FATCache[i];   // FAT-Sektor schon gepuffert
-   _CacheCnt[i]++;
-   return true;
-  }
-
- i = get_cache_buffer();
-
- if (_cache_empty)             // von get_cache_buffer() gesetzt
-  {
-   C = _CacheCount-1;
-   anz = _boot_sector.SectorsPerFAT*_boot_sector.NumberFATs - sec;
-
-   if (anz > _read_ahead)
-       anz = _read_ahead;
-
-   for(i=0; i<anz; i++) {
-       _CacheSec[i] = sec++;
-       _CacheCnt[i] = C;
-       _CacheDty[i] = 0;
-   }
-
-   _CacheCnt[0] = _CacheCount;
-
-   return read_sector(_CacheSec[0], *bufptr=(Buffer*) &_FATCache[0], anz);
-  }
- else
-  {
-   _CacheDty[i] = 0;
-   _CacheCnt[i] = _CacheCount;
-
-   return read_sector(_CacheSec[i]=sec, *bufptr=(Buffer*) &_FATCache[i], 1);
-  }
-}
-
-int FATDrive::get_cache_buffer()       // search for free cache buffer
-{
- int i, j, minCnt;
-
- for(i=0; i<_Caches; i++)
-  if (_CacheSec[i])
-   break;
-
- _cache_empty = i==_Caches? true: false;
-
- for(i=0; _CacheSec[i] && i<_Caches; )
-  ++i;
-
- if (i < _Caches)
-  j = i;
- else
-  {
-   minCnt = 0;                 // search for least used buffer
-
-   for(j=i=0; i<_Caches; i++)
-       if (minCnt < _CacheCnt[i]) {
-        minCnt = _CacheCnt[i];
-        j = i;
-       }
-
-/**@todo enable write back
-   if (CacheDty[j])    // Dirty-Flag gesetzt?
-       if (writesec(_CacheSec[j], (Buffer*) &_FATCache[j], 1))
-        FPara = _CacheSec[j], Frag(SecWriteErr);
-*/
-  }
-
- return j;
-}
diff --git a/reactos/subsys/system/explorer/shell/fatfs.h b/reactos/subsys/system/explorer/shell/fatfs.h
deleted file mode 100644 (file)
index cf97630..0000000
+++ /dev/null
@@ -1,260 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // fatfs.h
- //
- // Martin Fuchs, 01.02.2004
- //
-
-
- /// FAT file system file-entry
-struct FATEntry : public Entry
-{
-       FATEntry(Entry* parent, unsigned cluster) : Entry(parent, ET_FAT), _cluster(cluster) {}
-
-protected:
-       FATEntry() : Entry(ET_FAT) {}
-
-       virtual bool get_path(PTSTR path, size_t path_count) const;
-       virtual ShellPath create_absolute_pidl() const;
-
-       DWORD   _cluster;
-};
-
-
-struct FATDrive;
-
- /// FAT file system directory-entry
-struct FATDirectory : public FATEntry, public Directory
-{
-       FATDirectory(FATDrive& drive, LPCTSTR root_path);
-       FATDirectory(FATDrive& drive, Entry* parent, LPCTSTR path, unsigned cluster);
-       ~FATDirectory();
-
-       virtual void read_directory(int scan_flags=0);
-       virtual const void* get_next_path_component(const void*) const;
-       virtual Entry* find_entry(const void*);
-
-protected:
-       FATDrive&       _drive;
-
-       struct dirsecz* _secarr;
-       int     _cur_bufs;
-       int     _ents;
-       struct dirent* _dir;
-       struct Kette* _alloc;
-
-       bool    read_dir();
-};
-
-
-#pragma pack(push, 1)
-
-struct BootSector {
-       BYTE    jmp[3];
-       char    OEM[8];
-       WORD    BytesPerSector;         // dpb.bsec
-       BYTE    SectorsPerCluster;      // dpb.sclus + 1
-       WORD    ReservedSectors;        // dpb.ffatsec
-       BYTE    NumberFATs;
-       WORD    RootEntries;            // dpb.ndir
-       WORD    Sectors16;
-       BYTE    MediaDescr;
-       WORD    SectorsPerFAT;
-       WORD    SectorsPerTrack;
-       WORD    Heads;
-       DWORD   HiddenSectors;
-       DWORD   Sectors32;
-       BYTE    DriveUnit;
-       WORD    ExtBootFlag;
-       DWORD   SerialNr;
-       char    Label[11];
-       char    FileSystem[8];
-       BYTE    BootCode[448];
-       BYTE    BootSignature[2];
-};
-
-struct BootSector32 {
-       BYTE    jmp[3];
-       char    OEM[8];
-       WORD    BytesPerSector;
-       BYTE    SectorsPerCluster;
-       WORD    ReservedSectors;
-       BYTE    NumberFATs;
-       WORD    reserved1;      // immer 0 für FAT32
-       WORD    Sectors16;
-       BYTE    MediaDescr;
-       WORD    reserved2;      // immer 0 für FAT32
-       WORD    SectorsPerTrack;
-       WORD    Heads;
-       DWORD   HiddenSectors;
-       DWORD   Sectors32;
-       DWORD   SectorsPerFAT32;
-       DWORD   unknown1;
-       DWORD   RootSectors; // correct?
-       char    unknown2[6];
-       char    FileSystem[8];
-       BYTE    BootCode[448];
-       BYTE    BootSignature[2];
-};
-
-
-struct ftime {
-       WORD    sec2    : 5;
-       WORD    min     : 6;
-       WORD    hour    : 5;
-};
-
-struct fdate {
-       WORD    day     : 5;
-       WORD    month   : 4;
-       WORD    year    : 7;
-};
-
-typedef struct {
-       unsigned readonly       : 1;
-       unsigned hidden         : 1;
-       unsigned system         : 1;
-       unsigned volume         : 1;
-       unsigned directory      : 1;
-       unsigned archived       : 1;
-       unsigned deleted        : 1;
-} fattr;
-
-typedef union {
-       char    b;
-       fattr  a;
-} FAT_attribute;
-
-struct DEntry_E {
-       char                    name[8];
-       char                    ext[3];
-       char                    attr;
-       char                    rsrvd[10];
-       struct ftime    time;
-       struct fdate    date;
-       WORD                    fclus;
-       DWORD                   size;
-};
-
-union DEntry {
-       DEntry_E E;
-       BYTE B[8+3+1+10+sizeof(struct ftime)+sizeof(struct fdate)+sizeof(WORD)+sizeof(DWORD)];
-};
-
-#pragma pack(pop)
-
-
-#define BufLen 512
-
-struct Buffer {
- BYTE  dat[BufLen];
-};
-
-struct Cache {
- BYTE  dat[BufLen];
-};
-
-struct dskrwblk {
- DWORD                 sec;
- WORD                  anz;
- struct buffer far *buf;
-};
-
-#define RONLY                  0x01
-#define HIDDEN                 0x02
-#define SYSTEM                 0x04
-#define VOLUME                 0x08
-#define DIRENT                 0x10
-#define ARCHIVE                0x20
-
-#define _A_DELETED             0x40
-#define _A_ILLEGAL             0x80
-#define IS_LNAME(a) ((a&0xFF)==0x0F)   // "& 0xFF" correct?
-
-#define FAT_DEL_CHAR   (char)0xe5
-
-#define AddP(p,s)  {(int&)p += s;}
-
-struct dirent {
-       union DEntry  ent[1];
-};
-
-struct dirsecz {
-       DWORD  s[32];  // 32 only as placeholder
-};
-
-struct Kette {
- struct Kette* Vorw;
- struct Kette* Rueck;
- union DEntry* Ent;
-};
-
-
-#define        MK_P(ofs)               ((void*) ((size_t)(ofs)))
-#define        MK_LONG(l,h)    ((DWORD)WORD(l)|((DWORD)WORD(h)<<16))
-
-#define        spoke(ofs,w)    (*((BYTE*)MK_P(ofs)) = (BYTE)(w))
-#define        wpoke(ofs,w)    (*((WORD*)MK_P(ofs)) = (WORD)(w))
-#define        dpoke(ofs,w)    (*((DWORD*)MK_P(ofs)) = (DWORD)(w))
-#define        speek(ofs)              (*((BYTE*)MK_P(ofs)))
-#define        wpeek(ofs)              (*((WORD*)MK_P(ofs)))
-#define        dpeek(p)                (*((DWORD*)MK_P(p)))
-
-
- /// FAT drive root entry
-struct FATDrive : public FATDirectory
-{
-       FATDrive(LPCTSTR path);
-/*
-       FATDrive(Entry* parent, LPCTSTR path)
-        :      FATEntry(parent)
-       {
-               _path = _tcsdup(path);
-       }
-*/
-       ~FATDrive();
-
-       HANDLE  _hDrive;
-       BootSector      _boot_sector;
-       int     _bufl;
-       int     _bufents;
-       int     _SClus;
-
-#define        CACHE_SIZE_LOW  32
-       Cache*  _FATCache;
-       int             _CacheCount;
-       DWORD*  _CacheSec;      // numbers of buffered cache sectors
-       int*    _CacheCnt;      // counters for cache usage
-       bool*   _CacheDty;      // dirty flags for cache
-       int             _Caches;
-       bool    _cache_empty;
-       int             _read_ahead;
-
-       bool    read_sector(DWORD sec, Buffer* buf, int len);
-       DWORD   read_FAT(DWORD Clus, bool& ok);
-
-       void    small_cache();
-       void    reset_cache();
-       bool    read_cache(DWORD sec, Buffer** bufptr);
-       int             get_cache_buffer();
-};
diff --git a/reactos/subsys/system/explorer/shell/filechild.cpp b/reactos/subsys/system/explorer/shell/filechild.cpp
deleted file mode 100644 (file)
index 98a074a..0000000
+++ /dev/null
@@ -1,720 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // filechild.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include <precomp.h>
-
-#include "ntobjfs.h"
-#include "regfs.h"
-#include "fatfs.h"
-
-#include "../resource.h"
-
-
-FileChildWndInfo::FileChildWndInfo(HWND hmdiclient, LPCTSTR path, ENTRY_TYPE etype)
- :     super(hmdiclient),
-       _etype(etype)
-{
-#ifndef _NO_WIN_FS
-       if (etype == ET_UNKNOWN)
-#ifdef __WINE__
-               if (*path == '/')
-                       _etype = ET_UNIX;
-               else
-#endif
-                       _etype = ET_WINDOWS;
-#endif
-
-       _path = path;
-
-       _pos.length = sizeof(WINDOWPLACEMENT);
-       _pos.flags = 0;
-       _pos.showCmd = SW_SHOWNORMAL;
-       _pos.rcNormalPosition.left = CW_USEDEFAULT;
-       _pos.rcNormalPosition.top = CW_USEDEFAULT;
-       _pos.rcNormalPosition.right = CW_USEDEFAULT;
-       _pos.rcNormalPosition.bottom = CW_USEDEFAULT;
-
-       _open_mode = OWM_EXPLORE|OWM_DETAILS;
-}
-
-
-ShellChildWndInfo::ShellChildWndInfo(HWND hmdiclient, LPCTSTR path, const ShellPath& root_shell_path)
- :     FileChildWndInfo(hmdiclient, path, ET_SHELL),
-       _shell_path(path&&*path? path: root_shell_path),
-       _root_shell_path(root_shell_path)
-{
-}
-
-
-NtObjChildWndInfo::NtObjChildWndInfo(HWND hmdiclient, LPCTSTR path)
- :     FileChildWndInfo(hmdiclient, path, ET_NTOBJS)
-{
-}
-
-
-RegistryChildWndInfo::RegistryChildWndInfo(HWND hmdiclient, LPCTSTR path)
- :     FileChildWndInfo(hmdiclient, path, ET_REGISTRY)
-{
-}
-
-
-FATChildWndInfo::FATChildWndInfo(HWND hmdiclient, LPCTSTR path)
- :     FileChildWndInfo(hmdiclient, path, ET_FAT)
-{
-}
-
-
-WebChildWndInfo::WebChildWndInfo(HWND hmdiclient, LPCTSTR url)
- :     FileChildWndInfo(hmdiclient, url, ET_WEB)
-{
-}
-
-
-INT_PTR CALLBACK ExecuteDialog::WndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       static struct ExecuteDialog* dlg;
-
-       switch(nmsg) {
-         case WM_INITDIALOG:
-               dlg = (struct ExecuteDialog*) lparam;
-               return 1;
-
-         case WM_COMMAND: {
-               int id = (int)wparam;
-
-               if (id == IDOK) {
-                       GetWindowText(GetDlgItem(hwnd, 201), dlg->cmd, COUNTOF(dlg->cmd));
-                       dlg->cmdshow = Button_GetState(GetDlgItem(hwnd,214))&BST_CHECKED?
-                                                                                       SW_SHOWMINIMIZED: SW_SHOWNORMAL;
-                       EndDialog(hwnd, id);
-               } else if (id == IDCANCEL)
-                       EndDialog(hwnd, id);
-
-               return 1;}
-       }
-
-       return 0;
-}
-
-
- // FileChildWindow
-
-FileChildWindow::FileChildWindow(HWND hwnd, const FileChildWndInfo& info)
- :     super(hwnd, info)
-{
-       CONTEXT("FileChildWindow::FileChildWindow()");
-
-       TCHAR drv[_MAX_DRIVE+1];
-       Entry* entry = NULL;
-
-       _left = NULL;
-       _right = NULL;
-
-       switch(info._etype) {
-#ifdef __WINE__
-         case ET_UNIX:
-               _root._drive_type = GetDriveType(info._path);
-               _root._sort_order = SORT_NAME;
-
-               _tsplitpath(info._path, drv, NULL, NULL, NULL);
-               lstrcat(drv, TEXT("/"));
-               lstrcpy(_root._volname, TEXT("root fs"));
-               _root._fs_flags = 0;
-               lstrcpy(_root._fs, TEXT("unixfs"));
-               lstrcpy(_root._path, TEXT("/"));
-               _root._entry = new UnixDirectory(_root._path);
-               entry = _root.read_tree(info._path+_tcslen(_root._path));
-               break;
-#endif
-
-         case ET_NTOBJS:
-               _root._drive_type = DRIVE_UNKNOWN;
-               _root._sort_order = SORT_NAME;
-
-               _tsplitpath_s(info._path, drv, COUNTOF(drv), NULL, 0, NULL, 0, NULL, 0);
-               lstrcat(drv, TEXT("\\"));
-               lstrcpy(_root._volname, TEXT("NT Object Namespace"));
-               lstrcpy(_root._fs, TEXT("NTOBJ"));
-               lstrcpy(_root._path, drv);
-               _root._entry = new NtObjDirectory(_root._path);
-               entry = _root.read_tree(info._path+_tcslen(_root._path));
-               break;
-
-         case ET_REGISTRY:
-               _root._drive_type = DRIVE_UNKNOWN;
-               _root._sort_order = SORT_NONE;
-
-               _tsplitpath_s(info._path, drv, COUNTOF(drv), NULL, 0, NULL, 0, NULL, 0);
-               lstrcat(drv, TEXT("\\"));
-               lstrcpy(_root._volname, TEXT("Registry"));
-               lstrcpy(_root._fs, TEXT("Registry"));
-               lstrcpy(_root._path, drv);
-               _root._entry = new RegistryRoot();
-               entry = _root.read_tree(info._path+_tcslen(_root._path));
-               break;
-
-         case ET_FAT: {
-               _root._drive_type = DRIVE_UNKNOWN;
-               _root._sort_order = SORT_NONE;
-
-               _tsplitpath_s(info._path, drv, COUNTOF(drv), NULL, 0, NULL, 0, NULL, 0);
-               lstrcat(drv, TEXT("\\"));
-               lstrcpy(_root._volname, TEXT("FAT XXX"));       //@@
-               lstrcpy(_root._fs, TEXT("FAT"));
-               lstrcpy(_root._path, drv);
-               FATDrive* drive = new FATDrive(TEXT("c:/reactos-emu/c.img"));   //TEXT("\\\\.\\F:"));   //@@
-
-               if (drive->_hDrive != INVALID_HANDLE_VALUE) {
-                       _root._entry = drive;
-                       entry = _root.read_tree(info._path+_tcslen(_root._path));
-               }
-               break;}
-
-#ifndef _NO_WIN_FS
-         default:      // ET_WINDOWS
-               _root._drive_type = GetDriveType(info._path);
-               _root._sort_order = SORT_NAME;
-
-               _tsplitpath_s(info._path, drv, COUNTOF(drv), NULL, 0, NULL, 0, NULL, 0);
-               lstrcat(drv, TEXT("\\"));
-               GetVolumeInformation(drv, _root._volname, _MAX_FNAME, 0, 0, &_root._fs_flags, _root._fs, COUNTOF(_root._fs));
-               lstrcpy(_root._path, drv);
-               _root._entry = new WinDirectory(_root._path);
-               entry = _root.read_tree(info._path+_tcslen(_root._path));
-               break;
-#else
-       default:
-#endif
-
-         case ET_SHELL: {      //@@ separate FileChildWindow into ShellChildWindow, WinChildWindow, UnixChildWindow ?
-               _root._drive_type = DRIVE_UNKNOWN;
-               _root._sort_order = SORT_NAME;
-
-               lstrcpy(drv, TEXT("\\"));
-               lstrcpy(_root._volname, TEXT("Desktop"));
-               _root._fs_flags = 0;
-               lstrcpy(_root._fs, TEXT("Shell"));
-
-               _root._entry = new ShellDirectory(GetDesktopFolder(), DesktopFolderPath(), hwnd);
-               const ShellChildWndInfo& shell_info = static_cast<const ShellChildWndInfo&>(info);
-               entry = _root.read_tree(&*shell_info._shell_path);
-               break;}
-       }
-
-       if (_root._entry) {
-               if (info._etype != ET_SHELL)
-                       wsprintf(_root._entry->_data.cFileName, TEXT("%s - %s"), drv, _root._fs);
-       /*@@else
-                       lstrcpy(_root._entry->_data.cFileName, TEXT("GetDesktopFolder"));*/
-
-               _root._entry->_data.dwFileAttributes = FILE_ATTRIBUTE_DIRECTORY;
-
-
-               ///@todo use OWM_ROOTED flag
-
-               if (info._open_mode & OWM_EXPLORE)      ///@todo Is not-explore-mode for FileChildWindow completely implemented?
-                       _left_hwnd = *(_left=new Pane(_hwnd, IDW_TREE_LEFT, IDW_HEADER_LEFT, _root._entry, true, COL_CONTENT));
-
-               _right_hwnd = *(_right=new Pane(_hwnd, IDW_TREE_RIGHT, IDW_HEADER_RIGHT, NULL, false,
-                                                                               COL_TYPE|COL_SIZE|COL_DATE|COL_TIME|COL_ATTRIBUTES|COL_INDEX|COL_LINKS|COL_CONTENT));
-       }
-
-       _header_wdths_ok = false;
-
-       if (entry)
-               set_curdir(entry);
-       else
-               set_curdir(_root._entry);
-
-       if (_left_hwnd) {
-               int idx = ListBox_FindItemData(_left_hwnd, ListBox_GetCurSel(_left_hwnd), _left->_cur);
-               ListBox_SetCurSel(_left_hwnd, idx);
-               //SetFocus(_left_hwnd);
-       }
-
-        // store path into history
-       if (info._path && *info._path)
-               _url_history.push(info._path);
-}
-
-
-void FileChildWindow::set_curdir(Entry* entry)
-{
-       CONTEXT("FileChildWindow::set_curdir()");
-
-       _path[0] = TEXT('\0');
-
-       _left->_cur = entry;
-       _right->_root = entry&&entry->_down? entry->_down: entry;
-       _right->_cur = entry;
-
-       if (entry) {
-               WaitCursor wait;
-
-               if (!entry->_scanned)
-                       scan_entry(entry);
-               else {
-                       HiddenWindow hide(_right_hwnd);
-
-                       ListBox_ResetContent(_right_hwnd);
-                       _right->insert_entries(entry->_down);
-
-                       _right->calc_widths(false);     ///@todo make configurable (This call takes really _very_ long compared to all other processing!)
-
-                       _right->set_header();
-               }
-
-               entry->get_path(_path, COUNTOF(_path));
-       }
-
-       if (_hwnd)      // only change window title if the window already exists
-               SetWindowText(_hwnd, _path);
-
-       if (_path[0])
-               if (SetCurrentDirectory(_path))
-                       set_url(_path); //set_url(FmtString(TEXT("file://%s"), _path));
-               else
-                       _path[0] = TEXT('\0');
-}
-
-
- // expand a directory entry
-
-bool FileChildWindow::expand_entry(Entry* dir)
-{
-       int idx;
-       Entry* p;
-
-       if (!dir || dir->_expanded || !dir->_down)
-               return false;
-
-       p = dir->_down;
-
-       if (p->_data.cFileName[0]=='.' && p->_data.cFileName[1]=='\0' && p->_next) {
-               p = p->_next;
-
-               if (p->_data.cFileName[0]=='.' && p->_data.cFileName[1]=='.' &&
-                               p->_data.cFileName[2]=='\0' && p->_next)
-                       p = p->_next;
-       }
-
-        // no subdirectories ?
-       if (!(p->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) &&  // not a directory?
-               !p->_down)      // not a file with NTFS sub-streams?
-               return FALSE;
-
-       idx = ListBox_FindItemData(_left_hwnd, 0, dir);
-
-       dir->_expanded = true;
-
-        // insert entries in left pane
-       HiddenWindow hide(_left_hwnd);
-
-       _left->insert_entries(p, idx);
-
-       if (!_header_wdths_ok) {
-               if (_left->calc_widths(false)) {
-                       _left->set_header();
-
-                       _header_wdths_ok = true;
-               }
-       }
-
-       return true;
-}
-
-
-void FileChildWindow::collapse_entry(Pane* pane, Entry* dir)
-{
-       int idx = ListBox_FindItemData(*pane, 0, dir);
-
-       SendMessage(*pane, WM_SETREDRAW, FALSE, 0);     //ShowWindow(*pane, SW_HIDE);
-
-        // hide sub entries
-       for(;;) {
-               LRESULT res = ListBox_GetItemData(*pane, idx+1);
-               Entry* sub = (Entry*) res;
-
-               if (res==LB_ERR || !sub || sub->_level<=dir->_level)
-                       break;
-
-               ListBox_DeleteString(*pane, idx+1);
-       }
-
-       dir->_expanded = false;
-
-       SendMessage(*pane, WM_SETREDRAW, TRUE, 0);      //ShowWindow(*pane, SW_SHOW);
-}
-
-
-FileChildWindow* FileChildWindow::create(const FileChildWndInfo& info)
-{
-       CONTEXT("FileChildWindow::create()");
-
-       MDICREATESTRUCT mcs;
-
-       mcs.szClass = CLASSNAME_WINEFILETREE;
-       mcs.szTitle = (LPTSTR)info._path;
-       mcs.hOwner      = g_Globals._hInstance;
-       mcs.x           = info._pos.rcNormalPosition.left;
-       mcs.y           = info._pos.rcNormalPosition.top;
-       mcs.cx          = info._pos.rcNormalPosition.right - info._pos.rcNormalPosition.left;
-       mcs.cy          = info._pos.rcNormalPosition.bottom - info._pos.rcNormalPosition.top;
-       mcs.style       = 0;
-       mcs.lParam      = 0;
-
-       FileChildWindow* child = static_cast<FileChildWindow*>(
-               create_mdi_child(info, mcs, WINDOW_CREATOR_INFO(FileChildWindow,FileChildWndInfo)));
-
-       return child;
-}
-
-
-void FileChildWindow::resize_children(int cx, int cy)
-{
-       HDWP hdwp = BeginDeferWindowPos(4);
-       RECT rt;
-
-       rt.left   = 0;
-       rt.top    = 0;
-       rt.right  = cx;
-       rt.bottom = cy;
-
-       cx = _split_pos + SPLIT_WIDTH/2;
-
-       if (_left && _right) {
-               WINDOWPOS wp;
-               HD_LAYOUT hdl;
-
-               hdl.prc   = &rt;
-               hdl.pwpos = &wp;
-
-               Header_Layout(_left->_hwndHeader, &hdl);
-
-               hdwp = DeferWindowPos(hdwp, _left->_hwndHeader, wp.hwndInsertAfter,
-                                                       wp.x-1, wp.y, _split_pos-SPLIT_WIDTH/2+1, wp.cy, wp.flags);
-
-               hdwp = DeferWindowPos(hdwp, _right->_hwndHeader, wp.hwndInsertAfter,
-                                                               rt.left+cx+1, wp.y, wp.cx-cx+2, wp.cy, wp.flags);
-       }
-
-       if (_left_hwnd)
-               hdwp = DeferWindowPos(hdwp, _left_hwnd, 0, rt.left, rt.top, _split_pos-SPLIT_WIDTH/2-rt.left, rt.bottom-rt.top, SWP_NOZORDER|SWP_NOACTIVATE);
-
-       if (_right_hwnd)
-               hdwp = DeferWindowPos(hdwp, _right_hwnd, 0, rt.left+cx+1, rt.top, rt.right-cx, rt.bottom-rt.top, SWP_NOZORDER|SWP_NOACTIVATE);
-
-       EndDeferWindowPos(hdwp);
-}
-
-
-LRESULT FileChildWindow::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-               case WM_DRAWITEM: {
-                       LPDRAWITEMSTRUCT dis = (LPDRAWITEMSTRUCT)lparam;
-                       Entry* entry = (Entry*) dis->itemData;
-
-                       if (dis->CtlID == IDW_TREE_LEFT) {
-                               _left->draw_item(dis, entry);
-                               return TRUE;
-                       } else if (dis->CtlID == IDW_TREE_RIGHT) {
-                               _right->draw_item(dis, entry);
-                               return TRUE;
-                       }
-
-                       goto def;}
-
-               case WM_SIZE:
-                       if (wparam != SIZE_MINIMIZED)
-                               resize_children(LOWORD(lparam), HIWORD(lparam));
-                       return DefMDIChildProc(_hwnd, nmsg, wparam, lparam);
-
-               case PM_GET_FILEWND_PTR:
-                       return (LRESULT)this;
-
-               case WM_SETFOCUS: {
-                       TCHAR path[MAX_PATH];
-
-                       if (_left && _left->_cur) {
-                               _left->_cur->get_path(path, COUNTOF(path));
-                               SetCurrentDirectory(path);
-                       }
-
-                       SetFocus(_focus_pane? _right_hwnd: _left_hwnd);
-                       goto def;}
-
-               case PM_DISPATCH_COMMAND: {
-                       Pane* pane = GetFocus()==_left_hwnd? _left: _right;
-
-                       switch(LOWORD(wparam)) {
-                         case ID_WINDOW_NEW: {CONTEXT("FileChildWindow PM_DISPATCH_COMMAND ID_WINDOW_NEW");
-                               if (_root._entry->_etype == ET_SHELL)
-                                       FileChildWindow::create(ShellChildWndInfo(GetParent(_hwnd)/*_hmdiclient*/, _path, DesktopFolderPath()));
-                               else
-                                       FileChildWindow::create(FileChildWndInfo(GetParent(_hwnd)/*_hmdiclient*/, _path));
-                               break;}
-
-                         case ID_REFRESH: {CONTEXT("ID_REFRESH");
-                               WaitCursor wait;
-                               bool expanded = _left->_cur->_expanded;
-
-                               scan_entry(_left->_cur);
-
-                               if (expanded)
-                                       expand_entry(_left->_cur);
-                               break;}
-
-                         case ID_ACTIVATE: {CONTEXT("ID_ACTIVATE");
-                               activate_entry(pane);
-                               break;}
-
-                         default:
-                               if (pane->command(LOWORD(wparam)))
-                                       return TRUE;
-                               else
-                                       return super::WndProc(nmsg, wparam, lparam);
-                       }
-
-                       return TRUE;}
-
-               case WM_CONTEXTMENU: {
-                        // first select the current item in the listbox
-                       HWND hpanel = (HWND) wparam;
-                       const POINTS& pos = MAKEPOINTS(lparam);
-                       POINT pt; POINTSTOPOINT(pt, pos);
-                       POINT pt_screen = pt;
-                       ScreenToClient(hpanel, &pt);
-                       SendMessage(hpanel, WM_LBUTTONDOWN, 0, MAKELONG(pt.x, pt.y));
-                       SendMessage(hpanel, WM_LBUTTONUP, 0, MAKELONG(pt.x, pt.y));
-
-                        // now create the popup menu using shell namespace and IContextMenu
-                       Pane* pane = GetFocus()==_left_hwnd? _left: _right;
-                       int idx = ListBox_GetCurSel(*pane);
-                       if (idx != -1) {
-                               Entry* entry = (Entry*) ListBox_GetItemData(*pane, idx);
-
-                               CHECKERROR(entry->do_context_menu(_hwnd, pt_screen, _cm_ifs));
-                       }
-                       break;}
-
-               default: def:
-                       return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-
-int FileChildWindow::Command(int id, int code)
-{
-       Pane* pane = GetFocus()==_left_hwnd? _left: _right;
-
-       switch(code) {
-         case LBN_SELCHANGE: {
-               int idx = ListBox_GetCurSel(*pane);
-               Entry* entry = (Entry*) ListBox_GetItemData(*pane, idx);
-
-               if (pane == _left)
-                       set_curdir(entry);
-               else
-                       pane->_cur = entry;
-               break;}
-
-         case LBN_DBLCLK:
-               activate_entry(pane);
-               break;
-       }
-
-       return 0;
-}
-
-
-void FileChildWindow::activate_entry(Pane* pane)       ///@todo enable using RETURN key accelerator
-{
-       Entry* entry = pane->_cur;
-
-       if (!entry)
-               return;
-
-       WaitCursor wait;
-
-       if ((entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) ||       // a directory?
-               entry->_down)   // a file with NTFS sub-streams?
-       {
-               int scanned_old = entry->_scanned;
-
-               if (!scanned_old)
-                       scan_entry(entry);
-
-               if (entry->_data.cFileName[0]==TEXT('.') && entry->_data.cFileName[1]==TEXT('\0'))
-                       return;
-
-               if (entry->_data.cFileName[0]==TEXT('.') && entry->_data.cFileName[1]==TEXT('.') && entry->_data.cFileName[2]==TEXT('\0')) {
-                       entry = _left->_cur->_up;
-                       collapse_entry(_left, entry);
-                       goto focus_entry;
-               } else if (entry->_expanded)
-                       collapse_entry(pane, _left->_cur);
-               else {
-                       expand_entry(_left->_cur);
-
-                       if (!pane->_treePane) focus_entry: {
-                               int idx = ListBox_FindItemData(_left_hwnd, ListBox_GetCurSel(_left_hwnd), entry);
-                               ListBox_SetCurSel(_left_hwnd, idx);
-
-                               set_curdir(entry);
-                       }
-               }
-
-               if (!scanned_old) {
-                       pane->calc_widths(false);
-
-                       pane->set_header();
-               }
-       } else {
-               entry->launch_entry(_hwnd);
-       }
-}
-
-
-void FileChildWindow::scan_entry(Entry* entry)
-{
-       CONTEXT("FileChildWindow::scan_entry()");
-
-       int idx = ListBox_GetCurSel(_left_hwnd);
-
-        // delete sub entries in left pane
-       for(;;) {
-               LRESULT res = ListBox_GetItemData(_left_hwnd, idx+1);
-               Entry* sub = (Entry*) res;
-
-               if (res==LB_ERR || !sub || sub->_level<=entry->_level)
-                       break;
-
-               ListBox_DeleteString(_left_hwnd, idx+1);
-       }
-
-        // empty right pane
-       ListBox_ResetContent(_right_hwnd);
-
-        // release memory
-       entry->free_subentries();
-       entry->_expanded = false;
-
-        // read contents from disk
-       entry->read_directory_base(_root._sort_order);  ///@todo use modifyable sort order instead of fixed file system default
-
-        // insert found entries in right pane
-       HiddenWindow hide(_right_hwnd);
-       _right->insert_entries(entry->_down);
-
-       _right->calc_widths(false);
-       _right->set_header();
-
-       _header_wdths_ok = false;
-}
-
-
-int FileChildWindow::Notify(int id, NMHDR* pnmh)
-{
-       return (pnmh->idFrom==IDW_HEADER_LEFT? _left: _right)->Notify(id, pnmh);
-}
-
-
-String FileChildWindow::jump_to_int(LPCTSTR url)
-{
-       String dir, fname;
-
-       if (SplitFileSysURL(url, dir, fname)) {
-               Entry* entry = NULL;
-
-                // call read_tree() to iterate through the hierarchy and open all folders to reach dir
-               if (_root._entry)
-                       switch(_root._entry->_etype) {
-                         case ET_SHELL: {      //@@ separate into FileChildWindow in ShellChildWindow, WinChildWindow, UnixChildWindow ?
-                               ShellPath shell_path(dir);
-                               entry = _root.read_tree(&*shell_path);
-                               break;}
-
-#ifdef __WINE__
-                         case ET_UNIX: {
-                               LPCTSTR path = dir;
-
-                               if (!_tcsicmp(path, _root._path, _tcslen(_root._path)))
-                                       path += _tcslen(_root._path);
-
-                               entry = _root.read_tree(path);
-                               break;}
-#endif
-
-                         default: { // ET_NTOBJS, ET_REGISTRY, ET_FAT, ET_WINDOWS
-                               LPCTSTR path = dir;
-
-                               if (!_tcsnicmp(path, _root._path, _tcslen(_root._path)))
-                                       path += _tcslen(_root._path);
-
-                               entry = _root.read_tree(path);
-                               break;}
-                       }
-
-                       if (entry) {
-                                // refresh left pane entries
-                               HiddenWindow hide(_left_hwnd);
-
-                               ListBox_ResetContent(_left_hwnd);
-
-                               _left->insert_entries(_root._entry);
-
-                               if (!_header_wdths_ok) {
-                                       if (_left->calc_widths(false)) {
-                                               _left->set_header();
-
-                                               _header_wdths_ok = true;
-                                       }
-                               }
-
-                               set_curdir(entry);
-
-                               if (_left_hwnd) {
-                                       int idx = ListBox_FindItemData(_left_hwnd, -1, entry);
-
-                                       if (idx != -1) { // The item should always be found.
-                                               ListBox_SetCurSel(_left_hwnd, idx);
-                                               SetFocus(_left_hwnd);
-                                       }
-                               }
-
-                               ///@todo use fname
-
-                               return dir;     //FmtString(TEXT("file://%s"), (LPCTSTR)dir);
-                       }
-       }
-
-       return String();
-}
diff --git a/reactos/subsys/system/explorer/shell/filechild.h b/reactos/subsys/system/explorer/shell/filechild.h
deleted file mode 100644 (file)
index a81ea0d..0000000
+++ /dev/null
@@ -1,136 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // filechild.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
- /// information structure for creation of FileChildWindow
-struct FileChildWndInfo : public ChildWndInfo
-{
-       typedef ChildWndInfo super;
-
-       FileChildWndInfo(HWND hmdiclient, LPCTSTR path, ENTRY_TYPE etype=ET_UNKNOWN);
-
-       ENTRY_TYPE      _etype;
-       LPCTSTR         _path;
-
-       WINDOWPLACEMENT _pos;
-       int                     _open_mode;     //OPEN_WINDOW_MODE
-};
-
- /// information structure for creation of MDIShellBrowserChild
-struct ShellChildWndInfo : public FileChildWndInfo
-{
-       typedef FileChildWndInfo super;
-
-       ShellChildWndInfo(HWND hmdiclient, LPCTSTR path, const ShellPath& root_shell_path);
-
-       ShellPath       _shell_path;
-       ShellPath       _root_shell_path;
-};
-
- /// information structure for creation of FileChildWindow for NT object namespace
-struct NtObjChildWndInfo : public FileChildWndInfo
-{
-       typedef FileChildWndInfo super;
-
-       NtObjChildWndInfo(HWND hmdiclient, LPCTSTR path);
-};
-
- /// information structure for creation of FileChildWindow for the Registry
-struct RegistryChildWndInfo : public FileChildWndInfo
-{
-       typedef FileChildWndInfo super;
-
-       RegistryChildWndInfo(HWND hmdiclient, LPCTSTR path);
-};
-
- /// information structure for creation of FileChildWindow
-struct FATChildWndInfo : public FileChildWndInfo
-{
-       typedef FileChildWndInfo super;
-
-       FATChildWndInfo(HWND hmdiclient, LPCTSTR path);
-};
-
- /// information structure for creation of WebChildWindow
-struct WebChildWndInfo : public FileChildWndInfo
-{
-       typedef FileChildWndInfo super;
-
-       WebChildWndInfo(HWND hmdiclient, LPCTSTR url);
-};
-
-
- /// MDI child window displaying file lists
-struct FileChildWindow : public ExtContextMenuHandlerT<ChildWindow>
-{
-       typedef ExtContextMenuHandlerT<ChildWindow> super;
-
-       FileChildWindow(HWND hwnd, const FileChildWndInfo& info);
-
-       static FileChildWindow* create(const FileChildWndInfo& info);
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Command(int id, int code);
-       int             Notify(int id, NMHDR* pnmh);
-
-       virtual void resize_children(int cx, int cy);
-       virtual String jump_to_int(LPCTSTR url);
-
-       void    scan_entry(Entry* entry);
-
-       bool    expand_entry(Entry* dir);
-       static void collapse_entry(Pane* pane, Entry* dir);
-
-       void    set_curdir(Entry* entry);
-       void    activate_entry(Pane* pane);
-
-protected:
-       Root    _root;
-       Pane*   _left;
-       Pane*   _right;
-       TCHAR   _path[MAX_PATH];
-       bool    _header_wdths_ok;
-
-public:
-       const Root& get_root() const {return _root;}
-
-       void    set_focus_pane(Pane* pane)
-               {_focus_pane = pane==_right? 1: 0;}
-
-       void    switch_focus_pane()
-               {SetFocus(_focus_pane? *_left: *_right);}
-};
-
-
- /// The "Execute..."-dialog lets the user enter a command line to launch.
-struct ExecuteDialog { ///@todo use class Dialog
-       TCHAR   cmd[MAX_PATH];
-       int             cmdshow;
-
-       static INT_PTR CALLBACK WndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-};
diff --git a/reactos/subsys/system/explorer/shell/mainframe.cpp b/reactos/subsys/system/explorer/shell/mainframe.cpp
deleted file mode 100644 (file)
index 117689d..0000000
+++ /dev/null
@@ -1,1748 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // mainframe.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include <precomp.h>
-
-/* We can't include webchild.h here - otherwise MinGW produces errors like: "multiple definition of `QACONTAINERFLAGS'"
-#include "webchild.h"
-*/
-extern HWND create_webchildwindow(const WebChildWndInfo& info);
-
-#include "../resource.h"
-
-#include "../dialogs/settings.h"       // for MdiSdiDlg
-
-
-HWND MainFrameBase::Create(const ExplorerCmd& cmd)
-{
-       HWND hFrame;
-
-#ifndef _NO_MDI
-       if (cmd._mdi)
-               hFrame = MDIMainFrame::Create();
-       else
-#endif
-               hFrame = SDIMainFrame::Create();
-
-       if (hFrame) {
-               HWND hwndOld = g_Globals._hMainWnd;
-
-               g_Globals._hMainWnd = hFrame;
-
-               if (hwndOld)
-                       DestroyWindow(hwndOld);
-
-               ShowWindow(hFrame, cmd._cmdShow);
-               UpdateWindow(hFrame);
-
-                // Open the first child window after initializing the application
-               if (cmd.IsValidPath()) {
-                        // We use the static s_path variable to store the path string in order 
-                        // to avoid accessing prematurely freed memory in the PostMessage handlers.
-                       static String s_path = cmd._path;
-
-                       PostMessage(hFrame, PM_OPEN_WINDOW, cmd._flags, (LPARAM)(LPCTSTR)s_path);
-               } else
-                       PostMessage(hFrame, PM_OPEN_WINDOW, OWM_EXPLORE|OWM_DETAILS, 0);
-       }
-
-       return hFrame;
-}
-
-
-int MainFrameBase::OpenShellFolders(LPIDA pida, HWND hFrameWnd)
-{
-       int cnt = 0;
-
-       LPCITEMIDLIST parent_pidl = (LPCITEMIDLIST) ((LPBYTE)pida+pida->aoffset[0]);
-       ShellFolder folder(parent_pidl);
-       LOG(FmtString(TEXT("MainFrameBase::OpenShellFolders(): parent_pidl=%s"), (LPCTSTR)FileSysShellPath(parent_pidl)));
-
-       for(int i=pida->cidl; i>0; --i) {
-               LPCITEMIDLIST pidl = (LPCITEMIDLIST) ((LPBYTE)pida+pida->aoffset[i]);
-
-               SFGAOF attribs = SFGAO_FOLDER;
-               HRESULT hr = folder->GetAttributesOf(1, &pidl, &attribs);
-
-               if (SUCCEEDED(hr))
-                       if (attribs & SFGAO_FOLDER) {
-                               try {
-                                       XMLPos explorer_options = g_Globals.get_cfg("general/explorer");
-
-                                       bool mdi = XMLBool(explorer_options, "mdi", true);
-                                       bool separateFolders = XMLBool(explorer_options, "separate-folders", true);
-
-                                       ShellPath pidl_abs = ShellPath(pidl).create_absolute_pidl(parent_pidl);
-                                       LOG(FmtString(TEXT("MainFrameBase::OpenShellFolders(): pidl_abs=%s"), (LPCTSTR)FileSysShellPath(pidl_abs)));
-
-                                       if (hFrameWnd && (mdi || !separateFolders)) {
-                                               int flags = OWM_PIDL;
-
-                                               if (separateFolders)
-                                                       flags |= OWM_SEPARATE;
-
-                                               if (SendMessage(hFrameWnd, PM_OPEN_WINDOW, flags, (LPARAM)(LPCITEMIDLIST)pidl_abs))
-                                                       ++cnt;
-                                       } else {
-                                               HWND hwnd;
-#ifndef _NO_MDI
-                                               if (mdi)
-                                                       hwnd = MDIMainFrame::Create(pidl_abs, 0);
-                                               else
-#endif
-                                                       hwnd = SDIMainFrame::Create(pidl_abs, 0);
-
-                                               if (hwnd)
-                                                       ++cnt;
-                                       }
-                               } catch(COMException& e) {
-                                       HandleException(e, g_Globals._hMainWnd);
-                               }
-                       }/*TEST
-                       else { // !(attribs & SFGAO_FOLDER))
-                               SHELLEXECUTEINFOA shexinfo;
-
-                               shexinfo.cbSize = sizeof(SHELLEXECUTEINFOA);
-                               shexinfo.fMask = SEE_MASK_INVOKEIDLIST;
-                               shexinfo.hwnd = NULL;
-                               shexinfo.lpVerb = NULL;
-                               shexinfo.lpFile = NULL;
-                               shexinfo.lpParameters = NULL;
-                               shexinfo.lpDirectory = NULL;
-                               shexinfo.nShow = SW_NORMAL;
-                               shexinfo.lpIDList = ILCombine(parent_pidl, pidl);
-
-                               if (ShellExecuteExA(&shexinfo))
-                                       ++cnt;
-
-                               ILFree((LPITEMIDLIST)shexinfo.lpIDList);
-                       }*/
-       }
-
-       return cnt;
-}
-
-
-MainFrameBase::MainFrameBase(HWND hwnd)
- :     super(hwnd)
-{
-       _himl = ImageList_Create(GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), ILC_MASK|ILC_COLOR24, 2, 0);
-
-       _hMenuFrame = GetMenu(hwnd);
-       _hMenuWindow = GetSubMenu(_hMenuFrame, GetMenuItemCount(_hMenuFrame)-3);
-
-       _menu_info._hMenuView = GetSubMenu(_hMenuFrame, 1);
-
-       _hAccel = LoadAccelerators(g_Globals._hInstance, MAKEINTRESOURCE(IDA_EXPLORER));
-
-
-       TBBUTTON toolbarBtns[] = {
-#ifdef _NO_REBAR
-               {0, 0, 0, BTNS_SEP, {0, 0}, 0, 0},
-#endif
-               {7, ID_GO_BACK, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {8, ID_GO_FORWARD, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {9, ID_GO_UP, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {10, ID_GO_HOME, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {11, ID_GO_SEARCH, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {12, ID_REFRESH, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {13, ID_STOP, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0}
-       };
-
-       _htoolbar = CreateToolbarEx(hwnd, 
-#ifndef _NO_REBAR
-               CCS_NOPARENTALIGN|CCS_NORESIZE|CCS_NODIVIDER|
-#endif
-               WS_CHILD|TBSTYLE_FLAT|WS_VISIBLE, IDW_TOOLBAR, 2, g_Globals._hInstance, IDB_TOOLBAR,
-               toolbarBtns, sizeof(toolbarBtns)/sizeof(TBBUTTON),
-               16, 15, 16, 15, sizeof(TBBUTTON));
-
-       CheckMenuItem(_menu_info._hMenuView, ID_VIEW_TOOL_BAR, MF_BYCOMMAND|MF_CHECKED);
-
-
-        // address & command bar
-       WindowCanvas canvas(hwnd);
-       RECT rect = {0, 0, 0, 0};
-       DrawText(canvas, TEXT("My"), -1, &rect, DT_SINGLELINE|DT_NOPREFIX|DT_CALCRECT);
-       HFONT hfont = GetStockFont(DEFAULT_GUI_FONT);
-
-       _haddressedit = CreateWindow(TEXT("EDIT"), NULL, WS_CHILD|WS_VISIBLE, 0, 0, 0, rect.bottom,
-                                                       hwnd, (HMENU)IDW_ADDRESSBAR, g_Globals._hInstance, 0);
-       SetWindowFont(_haddressedit, hfont, FALSE);
-       new EditController(_haddressedit);
-
-       _hcommandedit = CreateWindow(TEXT("EDIT"), TEXT("> "), WS_CHILD|WS_VISIBLE, 0, 0, 0, rect.bottom,
-                                                       hwnd, (HMENU)IDW_COMMANDBAR, g_Globals._hInstance, 0);
-       SetWindowFont(_hcommandedit, hfont, FALSE);
-       new EditController(_hcommandedit);
-
-       /* CreateStatusWindow does not accept WS_BORDER
-               _hstatusbar = CreateWindowEx(WS_EX_NOPARENTNOTIFY, STATUSCLASSNAME, 0,
-                                               WS_CHILD|WS_VISIBLE|WS_CLIPSIBLINGS|WS_BORDER|CCS_NODIVIDER, 0,0,0,0,
-                                               hwnd, (HMENU)IDW_STATUSBAR, g_Globals._hInstance, 0);*/
-
-       _hstatusbar = CreateStatusWindow(WS_CHILD|WS_VISIBLE, 0, hwnd, IDW_STATUSBAR);
-       CheckMenuItem(_menu_info._hMenuView, ID_VIEW_STATUSBAR, MF_BYCOMMAND|MF_CHECKED);
-
-       _hsidebar = CreateWindowEx(WS_EX_STATICEDGE, WC_TREEVIEW, TEXT("Sidebar"),
-                                       WS_CHILD|WS_TABSTOP|WS_BORDER|/*WS_VISIBLE|*/WS_CHILD|TVS_HASLINES|TVS_HASBUTTONS|TVS_SHOWSELALWAYS|TVS_INFOTIP,
-                                       -1, -1, 200, 0, _hwnd, (HMENU)IDW_SIDEBAR, g_Globals._hInstance, 0);
-
-       _himl_old = TreeView_SetImageList(_hsidebar, _himl, TVSIL_NORMAL);
-
-       CheckMenuItem(_menu_info._hMenuView, ID_VIEW_SIDE_BAR, MF_BYCOMMAND|MF_UNCHECKED/*MF_CHECKED*/);
-
-
-        // create rebar window to manage toolbar and drivebar
-#ifndef _NO_REBAR
-       _hwndrebar = CreateWindowEx(WS_EX_TOOLWINDOW, REBARCLASSNAME, NULL,
-                                       WS_CHILD|WS_VISIBLE|WS_CLIPSIBLINGS|WS_CLIPCHILDREN|
-                                       RBS_VARHEIGHT|RBS_DBLCLKTOGGLE|
-                                       WS_BORDER|RBS_AUTOSIZE|RBS_BANDBORDERS,
-                                       0, 0, 0, 0, _hwnd, 0, g_Globals._hInstance, 0);
-
-       int btn_hgt = HIWORD(SendMessage(_htoolbar, TB_GETBUTTONSIZE, 0, 0));
-
-       REBARBANDINFO rbBand;
-
-       rbBand.cbSize = sizeof(REBARBANDINFO);
-       rbBand.fMask  = RBBIM_TEXT|RBBIM_STYLE|RBBIM_CHILD|RBBIM_CHILDSIZE|RBBIM_SIZE;
-#ifndef RBBS_HIDETITLE // missing in MinGW headers as of 25.02.2004
-#define RBBS_HIDETITLE 0x400
-#endif
-       rbBand.fStyle = RBBS_CHILDEDGE|RBBS_GRIPPERALWAYS|RBBS_HIDETITLE;
-
-       rbBand.cxMinChild = 0;
-       rbBand.cyMinChild = 0;
-       rbBand.cyChild = 0;
-       rbBand.cyMaxChild = 0;
-       rbBand.cyIntegral = btn_hgt;
-
-       rbBand.lpText = NULL;//TEXT("Toolbar");
-       rbBand.hwndChild = _htoolbar;
-       rbBand.cxMinChild = 0;
-       rbBand.cyMinChild = btn_hgt;
-       rbBand.cx = 284;
-       SendMessage(_hwndrebar, RB_INSERTBAND, (WPARAM)-1, (LPARAM)&rbBand);
-#endif
-}
-
-
-MainFrameBase::~MainFrameBase()
-{
-       (void)TreeView_SetImageList(_hsidebar, _himl_old, TVSIL_NORMAL);
-       ImageList_Destroy(_himl);
-
-        // don't exit desktop when closing file manager window
-       if (!g_Globals._desktop_mode)
-               if (g_Globals._hMainWnd == _hwnd)       // don't quit when switching between MDI and SDI mode
-                       PostQuitMessage(0);
-}
-
-
-LRESULT MainFrameBase::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       LRESULT res;
-
-       if (ProcessMessage(nmsg, wparam, lparam, &res))
-               return res;
-       else
-               return super::WndProc(nmsg, wparam, lparam);
-}
-
-bool MainFrameBase::ProcessMessage(UINT nmsg, WPARAM wparam, LPARAM lparam, LRESULT* pres)
-{
-       switch(nmsg) {
-         case PM_TRANSLATE_MSG:
-               *pres = TranslateMsg((MSG*)lparam);
-               return true;
-
-         case WM_SHOWWINDOW:
-               if (wparam) {   // trigger child resizing after window creation - now we can succesfully call IsWindowVisible()
-            int height = SendMessage(_hwndrebar, RB_GETBARHEIGHT, 0, 0);
-               MoveWindow(_hwndrebar, 0, 0, LOWORD(lparam), height, TRUE);
-                       resize_frame_client();
-        }
-               return false; // goto def;
-
-         case WM_CLOSE:
-               DestroyWindow(_hwnd);
-               g_Globals._hMainWnd = 0;
-               break;
-
-         case WM_DESTROY:
-               break;
-
-         case WM_SIZE: {
-#ifdef _ROS_   ///@todo Work around to display rebar in ROS (with flickering) as long as the control isn't fixed
-               int height = SendMessage(_hwndrebar, RB_GETBARHEIGHT, 0, 0);
-               MoveWindow(_hwndrebar, 0, 0, LOWORD(lparam), height, TRUE);
-#else
-               resize_frame(LOWORD(lparam), HIWORD(lparam));
-#endif
-               } break;        // do not pass message to DefFrameProc
-
-         case WM_GETMINMAXINFO: {
-               LPMINMAXINFO lpmmi = (LPMINMAXINFO)lparam;
-
-               lpmmi->ptMaxTrackSize.x <<= 1;/*2*GetSystemMetrics(SM_CXSCREEN) / SM_CXVIRTUALSCREEN */
-               lpmmi->ptMaxTrackSize.y <<= 1;/*2*GetSystemMetrics(SM_CYSCREEN) / SM_CYVIRTUALSCREEN */
-               break;}
-
-         case PM_FRM_CALC_CLIENT:
-               frame_get_clientspace((PRECT)lparam);
-               *pres = TRUE;
-               return true;
-
-         case PM_FRM_GET_MENUINFO:
-               *pres = (LPARAM)&_menu_info;
-               return true;
-
-         case PM_GET_CONTROLWINDOW:
-               if (wparam == FCW_STATUS) {
-                       *pres = (LRESULT)(HWND)_hstatusbar;
-                       return true;
-               }
-               break;
-
-         case PM_SETSTATUSTEXT:
-               SendMessage(_hstatusbar, SB_SETTEXT, 0, lparam);
-               break;
-
-         case PM_URL_CHANGED:
-               SetWindowText(_haddressedit, (LPCTSTR)lparam);
-               break;
-
-         default:
-               return false;
-       }
-
-       *pres = 0;
-       return true;
-}
-
-BOOL MainFrameBase::TranslateMsg(MSG* pmsg)
-{
-       if (TranslateAccelerator(_hwnd, _hAccel, pmsg))
-               return TRUE;
-
-       return FALSE;
-}
-
-
-int MainFrameBase::Command(int id, int code)
-{
-       CONTEXT("MainFrameBase::Command()");
-
-       switch(id) {
-         case ID_FILE_EXIT:
-               SendMessage(_hwnd, WM_CLOSE, 0, 0);
-               break;
-
-         case ID_VIEW_TOOL_BAR:
-               toggle_child(_hwnd, id, _htoolbar, 0);
-               break;
-
-         case ID_VIEW_STATUSBAR:
-               toggle_child(_hwnd, id, _hstatusbar);
-               break;
-
-         case ID_VIEW_SIDE_BAR:
-                // lazy initialization
-               if (!TreeView_GetCount(_hsidebar))
-                       FillBookmarks();
-
-               toggle_child(_hwnd, id, _hsidebar);
-               break;
-
-         case ID_EXECUTE: {
-               ExecuteDialog dlg = {{0}, 0};
-
-               if (DialogBoxParam(g_Globals._hInstance, MAKEINTRESOURCE(IDD_EXECUTE), _hwnd, ExecuteDialog::WndProc, (LPARAM)&dlg) == IDOK) {
-                       CONTEXT("ID_EXECUTE - ShellExecute()");
-
-                       HINSTANCE hinst = ShellExecute(_hwnd, NULL/*operation*/, dlg.cmd/*file*/, NULL/*parameters*/, NULL/*dir*/, dlg.cmdshow);
-
-                       if ((int)hinst <= 32)
-                               display_error(_hwnd, GetLastError());
-               }
-               break;}
-
-         case ID_HELP:
-               WinHelp(_hwnd, TEXT("explorer")/*file explorer.hlp*/, HELP_INDEX, 0);
-               break;
-
-         case ID_VIEW_FULLSCREEN:
-               CheckMenuItem(_menu_info._hMenuView, id, toggle_fullscreen()?MF_CHECKED:0);
-               break;
-
-         case ID_TOOLS_OPTIONS:
-               Dialog::DoModal(IDD_MDI_SDI, WINDOW_CREATOR(MdiSdiDlg), _hwnd);
-               break;
-
-         case ID_ABOUT_WINDOWS:
-               ShellAbout(_hwnd, ResString(IDS_TITLE), NULL, 0);
-               break;
-
-         case ID_ABOUT_EXPLORER:
-               explorer_about(_hwnd);
-               break;
-
-         case ID_EXPLORER_FAQ:
-               launch_file(_hwnd, TEXT("http://www.sky.franken.de/explorer/"), SW_SHOW);
-               break;
-
-         case IDW_ADDRESSBAR:
-               if (code == 1) {
-                       TCHAR url[BUFFER_LEN];
-
-                       if (GetWindowText(_haddressedit, url, BUFFER_LEN))
-                               go_to(url, false);
-               }
-               break;
-
-         case IDW_COMMANDBAR:
-               if (code == 1)
-                       ExecuteCommandbar(NULL);
-               break;
-
-         default:
-               return 1;       // no command handlers in Window::Command()
-       }
-
-       return 0;
-}
-
-
-void MainFrameBase::ExecuteCommandbar(LPCTSTR dir)
-{
-       TCHAR cmd[BUFFER_LEN];
-
-       if (GetWindowText(_hcommandedit, cmd, BUFFER_LEN)) {
-               CONTEXT("ExecuteCommandbar - ShellExecute()");
-
-                // remove command prompt from 'cmd' string
-               LPCTSTR p = cmd;
-
-               if (*p == '>')
-                       ++p;
-
-               while(*p == ' ')
-                       ++p;
-
-               if (dir) {
-                        // remove "file://" from directory URL
-                       if (!_tcsnicmp(dir, TEXT("file://"), 7))
-                               dir += 7;
-               }
-
-               ///@todo use SHGetFileInfo() with SHGFI_EXETYPE flag to determine EXE type and open console window
-
-               HINSTANCE hinst = ShellExecute(_hwnd, NULL, p, NULL, dir, SW_SHOWNORMAL);
-
-               if ((int)hinst <= 32)
-                       display_error(_hwnd, GetLastError());
-       }
-}
-
-
-int MainFrameBase::Notify(int id, NMHDR* pnmh)
-{
-       switch(pnmh->code) {
-                // resize children windows when the rebar size changes
-
-      case RBN_AUTOSIZE:
-               resize_frame_client();
-               break;
-
-         case TVN_GETINFOTIP: {
-               NMTVGETINFOTIP* pnmgit = (NMTVGETINFOTIP*)pnmh;
-
-               if (pnmgit->lParam) {
-                       const BookmarkNode& node = *(BookmarkNode*)pnmgit->lParam;
-
-                       if (node._type == BookmarkNode::BMNT_FOLDER) {
-                                // display tooltips for bookmark folders
-                               if (!node._pfolder->_description.empty())
-                                       lstrcpyn(pnmgit->pszText, node._pfolder->_description.c_str(), pnmgit->cchTextMax);
-                       } else if (node._type == BookmarkNode::BMNT_BOOKMARK) {
-                                // display tooltips for bookmark folders
-                               String txt = node._pbookmark->_description;
-
-                               if (!node._pbookmark->_url.empty()) {
-                                       if (!txt.empty())
-                                               txt += TEXT("  -  ");
-
-                                       txt += node._pbookmark->_url;
-                               }
-
-                               lstrcpyn(pnmgit->pszText, txt.c_str(), pnmgit->cchTextMax);
-                       }
-               }
-               break;}
-
-         case NM_DBLCLK: {
-               HTREEITEM hitem = TreeView_GetSelection(_hsidebar);
-               LPARAM lparam = TreeView_GetItemData(_hsidebar, hitem);
-
-               if (lparam) {
-                       const BookmarkNode& node = *(BookmarkNode*)lparam;
-
-                       if (node._type == BookmarkNode::BMNT_BOOKMARK) {
-                               bool new_window = GetAsyncKeyState(VK_SHIFT)<0;
-
-                               go_to(node._pbookmark->_url, new_window);
-                       }
-               }
-               break;}
-       }
-
-       return 0;
-}
-
-
-void MainFrameBase::resize_frame(int cx, int cy)
-{
-       if (cy <= 0)
-               return; // avoid resizing children when receiving RBN_AUTOSIZE while getting minimized
-
-       RECT rect = {0, 0, cx, cy};
-
-       if (_hwndrebar) {
-        int height = SendMessage(_hwndrebar, RB_GETBARHEIGHT, 0, 0);     
-               rect.top += height;
-        rect.top += 5;
-       } else {
-               if (IsWindowVisible(_htoolbar)) {
-                       SendMessage(_htoolbar, WM_SIZE, 0, 0);
-                       WindowRect rt(_htoolbar);
-                       rect.top = rt.bottom;
-               //      rect.bottom -= rt.bottom;
-               }
-       }
-
-       if (IsWindowVisible(_hstatusbar)) {
-               int parts[] = {300, 500};
-
-               SendMessage(_hstatusbar, WM_SIZE, 0, 0);
-               SendMessage(_hstatusbar, SB_SETPARTS, 2, (LPARAM)&parts);
-               ClientRect rt(_hstatusbar);
-               rect.bottom -= rt.bottom;
-       }
-
-       if (IsWindowVisible(_haddressedit) || IsWindowVisible(_hcommandedit)) {
-               ClientRect rt(_haddressedit);
-               rect.bottom -= rt.bottom;
-
-               int mid = (rect.right-rect.left) / 2;   ///@todo use split bar
-               SetWindowPos(_haddressedit, 0, 0, rect.bottom, mid, rt.bottom, SWP_NOACTIVATE|SWP_NOZORDER);
-               SetWindowPos(_hcommandedit, 0, mid+1, rect.bottom, rect.right-(mid+1), rt.bottom, SWP_NOACTIVATE|SWP_NOZORDER);
-       }
-
-       if (IsWindowVisible(_hsidebar)) {
-               WindowRect rt(_hsidebar);
-               rect.left += rt.right-rt.left;
-
-               SetWindowPos(_hsidebar, 0, -1, rect.top-1, rt.right-rt.left, rect.bottom-rect.top+1, SWP_NOACTIVATE|SWP_NOZORDER);
-       }
-}
-
-void MainFrameBase::resize_frame_client()
-{
-       ClientRect rect(_hwnd);
-
-       resize_frame(rect.right, rect.bottom);
-}
-
-void MainFrameBase::frame_get_clientspace(PRECT prect)
-{
-       if (!IsIconic(_hwnd))
-               GetClientRect(_hwnd, prect);
-       else {
-               WINDOWPLACEMENT wp;
-
-               GetWindowPlacement(_hwnd, &wp);
-
-               prect->left = prect->top = 0;
-               prect->right = wp.rcNormalPosition.right-wp.rcNormalPosition.left-
-                                               2*(GetSystemMetrics(SM_CXSIZEFRAME)+GetSystemMetrics(SM_CXEDGE));
-               prect->bottom = wp.rcNormalPosition.bottom-wp.rcNormalPosition.top-
-                                               2*(GetSystemMetrics(SM_CYSIZEFRAME)+GetSystemMetrics(SM_CYEDGE))-
-                                               GetSystemMetrics(SM_CYCAPTION)-GetSystemMetrics(SM_CYMENUSIZE);
-       }
-
-       if (IsWindowVisible(_htoolbar)) {
-               ClientRect rt(_htoolbar);
-               prect->top += rt.bottom+2;
-       }
-
-       if (IsWindowVisible(_hstatusbar)) {
-               ClientRect rt(_hstatusbar);
-               prect->bottom -= rt.bottom;
-       }
-}
-
-BOOL MainFrameBase::toggle_fullscreen()
-{
-       RECT rt;
-
-       if ((_fullscreen._mode=!_fullscreen._mode)) {
-               GetWindowRect(_hwnd, &_fullscreen._orgPos);
-               _fullscreen._wasZoomed = IsZoomed(_hwnd);
-
-               Frame_CalcFrameClient(_hwnd, &rt);
-               ClientToScreen(_hwnd, (LPPOINT)&rt.left);
-               ClientToScreen(_hwnd, (LPPOINT)&rt.right);
-
-               rt.left = _fullscreen._orgPos.left-rt.left;
-               rt.top = _fullscreen._orgPos.top-rt.top;
-               rt.right = GetSystemMetrics(SM_CXSCREEN)+_fullscreen._orgPos.right-rt.right;
-               rt.bottom = GetSystemMetrics(SM_CYSCREEN)+_fullscreen._orgPos.bottom-rt.bottom;
-
-               MoveWindow(_hwnd, rt.left, rt.top, rt.right-rt.left, rt.bottom-rt.top, TRUE);
-       } else {
-               MoveWindow(_hwnd, _fullscreen._orgPos.left, _fullscreen._orgPos.top,
-                                                       _fullscreen._orgPos.right-_fullscreen._orgPos.left,
-                                                       _fullscreen._orgPos.bottom-_fullscreen._orgPos.top, TRUE);
-
-               if (_fullscreen._wasZoomed)
-                       ShowWindow(_hwnd, WS_MAXIMIZE);
-       }
-
-       return _fullscreen._mode;
-}
-
-void MainFrameBase::fullscreen_move()
-{
-       RECT rt, pos;
-       GetWindowRect(_hwnd, &pos);
-
-       Frame_CalcFrameClient(_hwnd, &rt);
-       ClientToScreen(_hwnd, (LPPOINT)&rt.left);
-       ClientToScreen(_hwnd, (LPPOINT)&rt.right);
-
-       rt.left = pos.left-rt.left;
-       rt.top = pos.top-rt.top;
-       rt.right = GetSystemMetrics(SM_CXSCREEN)+pos.right-rt.right;
-       rt.bottom = GetSystemMetrics(SM_CYSCREEN)+pos.bottom-rt.bottom;
-
-       MoveWindow(_hwnd, rt.left, rt.top, rt.right-rt.left, rt.bottom-rt.top, TRUE);
-}
-
-
-void MainFrameBase::toggle_child(HWND hwnd, UINT cmd, HWND hchild, int band_idx)
-{
-       BOOL vis = IsWindowVisible(hchild);
-
-       CheckMenuItem(_menu_info._hMenuView, cmd, vis?MF_BYCOMMAND:MF_BYCOMMAND|MF_CHECKED);
-
-       if (band_idx != -1)
-               SendMessage(_hwndrebar, RB_SHOWBAND, band_idx, !vis);
-       else
-               ShowWindow(hchild, vis? SW_HIDE: SW_SHOW);
-
-       if (_fullscreen._mode)
-               fullscreen_move();
-
-       resize_frame_client();
-}
-
-void MainFrameBase::FillBookmarks()
-{
-       HiddenWindow hide(_hsidebar);
-       WindowCanvas canvas(_hwnd);
-
-       TreeView_DeleteAllItems(_hsidebar);
-
-       g_Globals._icon_cache.get_icon(ICID_FAVORITES).add_to_imagelist(_himl, canvas);
-       g_Globals._icon_cache.get_icon(ICID_BOOKMARK).add_to_imagelist(_himl, canvas);
-       ImageList_AddAlphaIcon(_himl, SmallIcon(IDI_DOT), GetStockBrush(WHITE_BRUSH), canvas);
-       g_Globals._icon_cache.get_icon(ICID_FOLDER).add_to_imagelist(_himl, canvas);
-       g_Globals._icon_cache.get_icon(ICID_FOLDER).add_to_imagelist(_himl, canvas);
-
-       TV_INSERTSTRUCT tvi;
-
-       tvi.hParent = TVI_ROOT;
-       tvi.hInsertAfter = TVI_LAST;
-       tvi.item.mask = TVIF_TEXT|TVIF_IMAGE|TVIF_SELECTEDIMAGE;
-       ResString sFavorites(IDS_FAVORITES);
-       tvi.item.pszText = sFavorites.str();
-       tvi.item.iSelectedImage = tvi.item.iImage = 0;
-
-       HTREEITEM hitem_bookmarks = TreeView_InsertItem(_hsidebar, &tvi);
-
-       g_Globals._favorites.fill_tree(_hsidebar, hitem_bookmarks, _himl, canvas);
-
-       TreeView_Expand(_hsidebar, hitem_bookmarks, TVE_EXPAND);
-}
-
-
-bool MainFrameBase::go_to(LPCTSTR url, bool new_window)
-{
-       ///@todo SDI implementation
-
-       return false;
-}
-
-
-#ifndef _NO_MDI
-
-MDIMainFrame::MDIMainFrame(HWND hwnd)
- :     super(hwnd)
-{
-       TBBUTTON mdiBtns[] = {
-               {0, 0, 0, BTNS_SEP, {0, 0}, 0, 0},
-               {0, ID_WINDOW_NEW, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {1, ID_WINDOW_CASCADE, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {2, ID_WINDOW_TILE_HORZ, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {3, ID_WINDOW_TILE_VERT, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0}
-       };
-
-       SendMessage(_htoolbar, TB_ADDBUTTONS, sizeof(mdiBtns)/sizeof(TBBUTTON), (LPARAM)&mdiBtns);
-
-       CLIENTCREATESTRUCT ccs;
-
-       ccs.hWindowMenu = _hMenuWindow;
-       ccs.idFirstChild = IDW_FIRST_CHILD;
-
-       _hmdiclient = CreateWindowEx(WS_EX_CLIENTEDGE, TEXT("MDICLIENT"), NULL,
-                                       WS_CHILD|WS_CLIPCHILDREN|WS_VSCROLL|WS_HSCROLL|WS_VISIBLE|WS_BORDER,
-                                       0, 0, 0, 0,
-                                       hwnd, 0, g_Globals._hInstance, &ccs);
-
-       TBBUTTON extraBtns = {0, 0, TBSTATE_ENABLED, BTNS_SEP, {0, 0}, 0, 0};
-
-#ifndef _NO_REBAR
-       _hextrabar = CreateToolbarEx(hwnd,
-                               CCS_NOPARENTALIGN|CCS_NORESIZE|CCS_NODIVIDER|
-                               WS_CHILD|TBSTYLE_FLAT|WS_VISIBLE|CCS_NOMOVEY|TBSTYLE_LIST,
-                               IDW_EXTRABAR, 2, g_Globals._hInstance, IDB_DRIVEBAR, NULL, 0,
-                               16, 15, 16, 15, sizeof(TBBUTTON));
-#else
-       _hextrabar = CreateToolbarEx(hwnd,
-                               WS_CHILD|WS_VISIBLE|CCS_NOMOVEY|TBSTYLE_LIST,CCS_NODIVIDER|
-                               IDW_EXTRABAR, 2, g_Globals._hInstance, IDB_DRIVEBAR, &extraBtns, 1,
-                               16, 13, 16, 13, sizeof(TBBUTTON));
-#endif
-
-       CheckMenuItem(_menu_info._hMenuView, ID_VIEW_EXTRA_BAR, MF_BYCOMMAND|MF_CHECKED);
-
-
-       extraBtns.fsStyle = BTNS_BUTTON;
-
-#ifdef __WINE__
-        // insert unix file system button
-       extraBtns.iString = SendMessage(_hextrabar, TB_ADDSTRING, 0, (LPARAM)TEXT("/\0"));
-       extraBtns.idCommand = ID_DRIVE_UNIX_FS;
-       SendMessage(_hextrabar, TB_INSERTBUTTON, INT_MAX, (LPARAM)&extraBtns);
-#endif
-
-        // insert explorer window button
-       extraBtns.iString = SendMessage(_hextrabar, TB_ADDSTRING, 0, (LPARAM)TEXT("Explore\0"));
-       extraBtns.idCommand = ID_DRIVE_DESKTOP;
-       SendMessage(_hextrabar, TB_INSERTBUTTON, INT_MAX, (LPARAM)&extraBtns);
-
-        // insert shell namespace button
-       extraBtns.iString = SendMessage(_hextrabar, TB_ADDSTRING, 0, (LPARAM)TEXT("Shell\0"));
-       extraBtns.idCommand = ID_DRIVE_SHELL_NS;
-       extraBtns.iBitmap = 6;
-       SendMessage(_hextrabar, TB_INSERTBUTTON, INT_MAX, (LPARAM)&extraBtns);
-
-        // insert web control button
-       extraBtns.iString = SendMessage(_hextrabar, TB_ADDSTRING, 0, (LPARAM)TEXT("Web\0"));
-       extraBtns.idCommand = ID_WEB_WINDOW;
-       extraBtns.iBitmap = 7;
-       SendMessage(_hextrabar, TB_INSERTBUTTON, INT_MAX, (LPARAM)&extraBtns);
-
-       if ((HIWORD(GetVersion())>>14) == W_VER_NT) {
-                // insert NT object namespace button
-               extraBtns.iString = SendMessage(_hextrabar, TB_ADDSTRING, 0, (LPARAM)TEXT("NT Obj\0"));
-               extraBtns.idCommand = ID_DRIVE_NTOBJ_NS;
-               extraBtns.iBitmap = 8;
-               SendMessage(_hextrabar, TB_INSERTBUTTON, INT_MAX, (LPARAM)&extraBtns);
-       }
-
-        // insert Registry button
-       extraBtns.iString = SendMessage(_hextrabar, TB_ADDSTRING, 0, (LPARAM)TEXT("Reg.\0"));
-       extraBtns.idCommand = ID_DRIVE_REGISTRY;
-       extraBtns.iBitmap = 9;
-       SendMessage(_hextrabar, TB_INSERTBUTTON, INT_MAX, (LPARAM)&extraBtns);
-
-#ifdef _DEBUG
-        // insert FAT direct file system access button
-       extraBtns.iString = SendMessage(_hextrabar, TB_ADDSTRING, 0, (LPARAM)TEXT("FAT\0"));
-       extraBtns.idCommand = ID_DRIVE_FAT;
-       extraBtns.iBitmap = 10;
-       SendMessage(_hextrabar, TB_INSERTBUTTON, INT_MAX, (LPARAM)&extraBtns);
-#endif
-
-
-       TBBUTTON drivebarBtn = {0, 0, TBSTATE_ENABLED, BTNS_SEP, {0, 0}, 0, 0};
-#ifndef _NO_WIN_FS
-       PTSTR p;
-
-#ifndef _NO_REBAR
-       _hdrivebar = CreateToolbarEx(hwnd,
-                               CCS_NOPARENTALIGN|CCS_NORESIZE|CCS_NODIVIDER|
-                               WS_CHILD|WS_VISIBLE|TBSTYLE_FLAT|CCS_NOMOVEY|TBSTYLE_LIST,
-                               IDW_DRIVEBAR, 2, g_Globals._hInstance, IDB_DRIVEBAR, NULL, 0,
-                               16, 15, 16, 15, sizeof(TBBUTTON));
-#else
-       _hdrivebar = CreateToolbarEx(hwnd,
-                               WS_CHILD|WS_VISIBLE|CCS_NOMOVEY|TBSTYLE_LIST|CCS_NODIVIDER,
-                               IDW_DRIVEBAR, 2, g_Globals._hInstance, IDB_DRIVEBAR, &drivebarBtn, 1,
-                               16, 13, 16, 13, sizeof(TBBUTTON));
-#endif
-#endif
-
-       CheckMenuItem(_menu_info._hMenuView, ID_VIEW_DRIVE_BAR, MF_BYCOMMAND|MF_CHECKED);
-
-
-#ifndef _NO_WIN_FS
-       GetLogicalDriveStrings(BUFFER_LEN, _drives);
-
-        // register windows drive root strings
-       SendMessage(_hdrivebar, TB_ADDSTRING, 0, (LPARAM)_drives);
-
-       drivebarBtn.fsStyle = BTNS_BUTTON;
-       drivebarBtn.idCommand = ID_DRIVE_FIRST;
-
-       for(p=_drives; *p; ) {
-               switch(GetDriveType(p)) {
-                       case DRIVE_REMOVABLE:   drivebarBtn.iBitmap = 1;        break;
-                       case DRIVE_CDROM:               drivebarBtn.iBitmap = 3;        break;
-                       case DRIVE_REMOTE:              drivebarBtn.iBitmap = 4;        break;
-                       case DRIVE_RAMDISK:     drivebarBtn.iBitmap = 5;        break;
-                       default:/*DRIVE_FIXED*/ drivebarBtn.iBitmap = 2;
-               }
-
-               SendMessage(_hdrivebar, TB_INSERTBUTTON, INT_MAX, (LPARAM)&drivebarBtn);
-               ++drivebarBtn.idCommand;
-               ++drivebarBtn.iString;
-
-               while(*p++);
-       }
-#endif
-
-
-#ifndef _NO_REBAR
-       int btn_hgt = HIWORD(SendMessage(_htoolbar, TB_GETBUTTONSIZE, 0, 0));
-
-       REBARBANDINFO rbBand;
-
-       rbBand.cbSize = sizeof(REBARBANDINFO);
-       rbBand.fMask  = RBBIM_TEXT|RBBIM_STYLE|RBBIM_CHILD|RBBIM_CHILDSIZE|RBBIM_SIZE;
-#ifndef RBBS_HIDETITLE // missing in MinGW headers as of 25.02.2004
-#define RBBS_HIDETITLE 0x400
-#endif
-       rbBand.fStyle = RBBS_CHILDEDGE|RBBS_GRIPPERALWAYS|RBBS_HIDETITLE;
-
-       rbBand.lpText = TEXT("Extras");
-       rbBand.hwndChild = _hextrabar;
-       rbBand.cxMinChild = 0;
-       rbBand.cyMinChild = btn_hgt;
-       rbBand.cx = 284;
-       SendMessage(_hwndrebar, RB_INSERTBAND, (WPARAM)-1, (LPARAM)&rbBand);
-
-#ifndef _NO_WIN_FS
-       rbBand.fStyle |= RBBS_BREAK;
-       rbBand.lpText = TEXT("Drives");
-       rbBand.hwndChild = _hdrivebar;
-       rbBand.cxMinChild = 0;
-       rbBand.cyMinChild = btn_hgt;
-       rbBand.cx = 400;
-       SendMessage(_hwndrebar, RB_INSERTBAND, (WPARAM)-1, (LPARAM)&rbBand);
-#endif
-#endif
-}
-
-
-HWND MDIMainFrame::Create()
-{
-       HMENU hMenuFrame = LoadMenu(g_Globals._hInstance, MAKEINTRESOURCE(IDM_MDIFRAME));
-
-       return Window::Create(WINDOW_CREATOR(MDIMainFrame), 0,
-                               (LPCTSTR)(int)g_Globals._hframeClass, ResString(IDS_TITLE), WS_OVERLAPPEDWINDOW,
-                               CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT,
-                               0/*hwndDesktop*/, hMenuFrame);
-}
-
-HWND MDIMainFrame::Create(LPCTSTR path, int mode)
-{
-       HWND hFrame = Create();
-       if (!hFrame)
-               return 0;
-
-       ShowWindow(hFrame, SW_SHOW);
-
-       MDIMainFrame* pMainFrame = GET_WINDOW(MDIMainFrame, hFrame);
-
-       if (pMainFrame)
-               pMainFrame->CreateChild(path, mode);
-
-       return hFrame;
-}
-
-HWND MDIMainFrame::Create(LPCITEMIDLIST pidl, int mode)
-{
-       HWND hFrame = Create();
-       if (!hFrame)
-               return 0;
-
-       ShowWindow(hFrame, SW_SHOW);
-
-       MDIMainFrame* pMainFrame = GET_WINDOW(MDIMainFrame, hFrame);
-
-       if (pMainFrame)
-               pMainFrame->CreateChild(pidl, mode);
-
-       return hFrame;
-}
-
-
-ChildWindow* MDIMainFrame::CreateChild(LPCTSTR path, int mode)
-{
-       return reinterpret_cast<ChildWindow*>(SendMessage(_hwnd, PM_OPEN_WINDOW, mode, (LPARAM)path));
-}
-
-ChildWindow* MDIMainFrame::CreateChild(LPCITEMIDLIST pidl, int mode)
-{
-       return reinterpret_cast<ChildWindow*>(SendMessage(_hwnd, PM_OPEN_WINDOW, mode|OWM_PIDL, (LPARAM)pidl));
-}
-
-
-BOOL MDIMainFrame::TranslateMsg(MSG* pmsg)
-{
-       if (_hmdiclient && TranslateMDISysAccel(_hmdiclient, pmsg))
-               return TRUE;
-
-       return super::TranslateMsg(pmsg);
-}
-
-LRESULT MDIMainFrame::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case PM_OPEN_WINDOW: {
-               CONTEXT("MDIMainFrame PM_OPEN_WINDOW");
-
-               TCHAR buffer[MAX_PATH];
-               LPCTSTR path;
-               ShellPath shell_path = DesktopFolderPath();
-
-               if (lparam) {
-                       if (wparam & OWM_PIDL) {
-                                // take over PIDL from lparam
-                               shell_path.assign((LPCITEMIDLIST)lparam);       // create as "rooted" window
-                               FileSysShellPath fsp(shell_path);
-                               path = fsp;
-
-                               if (path) {
-                                       LOG(FmtString(TEXT("MDIMainFrame PM_OPEN_WINDOW: path=%s"), path));
-                                       lstrcpy(buffer, path);
-                                       path = buffer;
-                               }
-                       } else {
-                                // take over path from lparam
-                               path = (LPCTSTR)lparam;
-                               shell_path = path;      // create as "rooted" window
-                       }
-               } else {
-                       ///@todo read paths and window placements from registry
-                       if (!GetCurrentDirectory(MAX_PATH, buffer))
-                               *buffer = '\0';
-
-                       path = buffer;
-               }
-
-               if (path && _tcsstr(path, TEXT("://"))) {       // "http://...", "ftp://", ...
-                       OBJ_CONTEXT("create WebChild window", path);
-
-                       return (LRESULT)GET_WINDOW(ChildWindow, create_webchildwindow(WebChildWndInfo(_hmdiclient, path)));
-               } else {
-                       OBJ_CONTEXT("create ShellChildWndInfo", path);
-
-                        // Shell Namespace as default view
-                       ShellChildWndInfo create_info(_hmdiclient, path, shell_path);
-
-                       if (wparam & OWM_ROOTED)
-                               create_info._root_shell_path = shell_path;
-                       else
-                               create_info._root_shell_path = DesktopFolderPath();     //SpecialFolderPath(CSIDL_DRIVES, _hwnd);
-
-                       create_info._pos.showCmd = wparam&OWM_SEPARATE? SW_SHOWNORMAL: SW_SHOWMAXIMIZED;
-                       create_info._pos.rcNormalPosition.left = CW_USEDEFAULT;
-                       create_info._pos.rcNormalPosition.top = CW_USEDEFAULT;
-                       create_info._pos.rcNormalPosition.right = CW_USEDEFAULT;
-                       create_info._pos.rcNormalPosition.bottom = CW_USEDEFAULT;
-
-                       create_info._open_mode = wparam;
-
-               //      FileChildWindow::create(_hmdiclient, create_info);
-                       return (LRESULT)MDIShellBrowserChild::create(create_info);
-               }
-               return TRUE;}   // success
-
-         default: {
-               LRESULT res;
-
-               if (super::ProcessMessage(nmsg, wparam, lparam, &res))
-                       return res;
-               else
-                       return DefFrameProc(_hwnd, _hmdiclient, nmsg, wparam, lparam);
-         }
-       }
-
-       return 0;
-}
-
-int MDIMainFrame::Command(int id, int code)
-{
-       CONTEXT("MDIMainFrame::Command()");
-
-       HWND hwndClient = (HWND) SendMessage(_hmdiclient, WM_MDIGETACTIVE, 0, 0);
-
-       if (hwndClient)
-               if (SendMessage(hwndClient, PM_DISPATCH_COMMAND, MAKELONG(id,code), 0))
-                       return 0;
-
-#ifndef _NO_WIN_FS
-       if (id>=ID_DRIVE_FIRST && id<=ID_DRIVE_FIRST+0xFF) {
-               TCHAR drv[_MAX_DRIVE], path[MAX_PATH];
-               LPCTSTR root = _drives;
-
-               for(int i=id-ID_DRIVE_FIRST; i--; root++)
-                       while(*root)
-                               ++root;
-
-               if (activate_drive_window(root))
-                       return 0;
-
-               _tsplitpath_s(root, drv, COUNTOF(drv), NULL, 0, NULL, 0, NULL, 0);
-
-               if (!SetCurrentDirectory(drv)) {
-                       display_error(_hwnd, GetLastError());
-                       return 0;
-               }
-
-               GetCurrentDirectory(MAX_PATH, path); ///@todo store last directory per drive
-
-               FileChildWindow::create(FileChildWndInfo(_hmdiclient, path));
-
-               return 1;
-       }
-#endif
-
-       switch(id) {
-         case ID_WINDOW_NEW: {
-               TCHAR path[MAX_PATH];
-
-               GetCurrentDirectory(MAX_PATH, path);
-
-               FileChildWindow::create(FileChildWndInfo(_hmdiclient, path));
-               break;}
-
-         case ID_WINDOW_CASCADE:
-               SendMessage(_hmdiclient, WM_MDICASCADE, 0, 0);
-               break;
-
-         case ID_WINDOW_TILE_HORZ:
-               SendMessage(_hmdiclient, WM_MDITILE, MDITILE_HORIZONTAL, 0);
-               break;
-
-         case ID_WINDOW_TILE_VERT:
-               SendMessage(_hmdiclient, WM_MDITILE, MDITILE_VERTICAL, 0);
-               break;
-
-         case ID_WINDOW_ARRANGE:
-               SendMessage(_hmdiclient, WM_MDIICONARRANGE, 0, 0);
-               break;
-
-         case ID_VIEW_EXTRA_BAR:
-               toggle_child(_hwnd, id, _hextrabar, 1);
-               break;
-
-#ifndef _NO_WIN_FS
-         case ID_VIEW_DRIVE_BAR:
-               toggle_child(_hwnd, id, _hdrivebar, 2);
-               break;
-#endif
-
-#ifdef __WINE__
-         case ID_DRIVE_UNIX_FS: {
-               TCHAR path[MAX_PATH];
-               FileChildWindow* child;
-
-               getcwd(path, COUNTOF(path));
-
-               if (activate_child_window(TEXT("unixfs")))
-                       break;
-
-               FileChildWindow::create(_hmdiclient, FileChildWndInfo(path));
-               break;}
-#endif
-
-         case ID_DRIVE_DESKTOP: {
-               TCHAR path[MAX_PATH];
-
-               if (activate_child_window(TEXT("Desktop")))
-                       break;
-
-               GetCurrentDirectory(MAX_PATH, path);
-
-               MDIShellBrowserChild::create(ShellChildWndInfo(_hmdiclient, path, DesktopFolderPath()));
-               break;}
-
-         case ID_DRIVE_SHELL_NS: {
-               TCHAR path[MAX_PATH];
-               GetCurrentDirectory(MAX_PATH, path);
-
-               if (activate_child_window(TEXT("Shell")))
-                       break;
-
-               FileChildWindow::create(ShellChildWndInfo(_hmdiclient, path, DesktopFolderPath()));
-               break;}
-
-         case ID_DRIVE_NTOBJ_NS: {
-               if (activate_child_window(TEXT("NTOBJ")))
-                       break;
-
-               FileChildWindow::create(NtObjChildWndInfo(_hmdiclient, TEXT("\\")));
-         break;}
-
-         case ID_DRIVE_REGISTRY: {
-               if (activate_child_window(TEXT("Registry")))
-                       break;
-
-               FileChildWindow::create(RegistryChildWndInfo(_hmdiclient, TEXT("\\")));
-         break;}
-
-         case ID_DRIVE_FAT: {
-
-               ///@todo prompt for image file
-
-               if (activate_child_window(TEXT("FAT")))
-                       break;
-
-               FileChildWindow::create(FATChildWndInfo(_hmdiclient, TEXT("FAT Image")));       //@@
-         break;}
-
-         case ID_WEB_WINDOW:
-#ifdef _DEBUG
-               create_webchildwindow(WebChildWndInfo(_hmdiclient, TEXT("http://localhost")));
-#else
-               create_webchildwindow(WebChildWndInfo(_hmdiclient, TEXT("http://www.reactos.org")));
-#endif
-               break;
-
-         case ID_EXPLORER_FAQ:
-               create_webchildwindow(WebChildWndInfo(_hmdiclient, TEXT("http://www.sky.franken.de/explorer/")));
-               break;
-
-         case ID_VIEW_SDI:
-               MainFrameBase::Create(ExplorerCmd());
-               break;
-
-         case IDW_COMMANDBAR:
-               if (code == 1) {
-                       TCHAR url[BUFFER_LEN];
-                       LPCTSTR dir;
-
-                       if (GetWindowText(_haddressedit, url, BUFFER_LEN))
-                               dir = url;
-                       else
-                               dir = NULL;
-
-                       ExecuteCommandbar(dir);
-               }
-               break;
-
-       ///@todo There are even more menu items!
-
-         default:
-               if (super::Command(id, code) == 0)
-                       return 0;
-               else
-                       return DefFrameProc(_hwnd, _hmdiclient, WM_COMMAND, MAKELONG(id,code), 0);
-       }
-
-       return 0;
-}
-
-
-void MDIMainFrame::frame_get_clientspace(PRECT prect)
-{
-       super::frame_get_clientspace(prect);
-
-#ifndef _NO_WIN_FS
-       if (IsWindowVisible(_hdrivebar)) {
-               ClientRect rt(_hdrivebar);
-               prect->top += rt.bottom+2;
-       }
-#endif
-}
-
-void MDIMainFrame::resize_frame(int cx, int cy)
-{
-       if (cy <= 0)
-               return; // avoid resizing children when receiving RBN_AUTOSIZE while getting minimized
-
-       RECT rect = {0, 0, cx, cy};
-
-       if (_hwndrebar) {
-        int height = SendMessage(_hwndrebar, RB_GETBARHEIGHT, 0, 0);
-               rect.top += height;
-        rect.top += 5;
-       } else {
-               if (IsWindowVisible(_htoolbar)) {
-                       SendMessage(_htoolbar, WM_SIZE, 0, 0);
-                       WindowRect rt(_htoolbar);
-                       rect.top = rt.bottom;
-               //      rect.bottom -= rt.bottom;
-               }
-
-               if (IsWindowVisible(_hextrabar)) {
-                       SendMessage(_hextrabar, WM_SIZE, 0, 0);
-                       WindowRect rt(_hextrabar);
-                       int new_top = --rect.top + rt.bottom;
-                       MoveWindow(_hextrabar, 0, rect.top, rt.right, new_top, TRUE);
-                       rect.top = new_top;
-               //      rect.bottom -= rt.bottom;
-               }
-
-#ifndef _NO_WIN_FS
-               if (IsWindowVisible(_hdrivebar)) {
-                       SendMessage(_hdrivebar, WM_SIZE, 0, 0);
-                       WindowRect rt(_hdrivebar);
-                       int new_top = --rect.top + rt.bottom;
-                       MoveWindow(_hdrivebar, 0, rect.top, rt.right, new_top, TRUE);
-                       rect.top = new_top;
-               //      rect.bottom -= rt.bottom;
-               }
-#endif
-       }
-
-       if (IsWindowVisible(_hstatusbar)) {
-               int parts[] = {300, 500};
-
-               SendMessage(_hstatusbar, WM_SIZE, 0, 0);
-               SendMessage(_hstatusbar, SB_SETPARTS, 2, (LPARAM)&parts);
-               ClientRect rt(_hstatusbar);
-               rect.bottom -= rt.bottom;
-       }
-
-       if (IsWindowVisible(_haddressedit) || IsWindowVisible(_hcommandedit)) {
-               ClientRect rt(_haddressedit);
-               rect.bottom -= rt.bottom;
-
-               int mid = (rect.right-rect.left) / 2;   ///@todo use split bar
-               SetWindowPos(_haddressedit, 0, 0, rect.bottom, mid, rt.bottom, SWP_NOACTIVATE|SWP_NOZORDER);
-               SetWindowPos(_hcommandedit, 0, mid+1, rect.bottom, rect.right-(mid+1), rt.bottom, SWP_NOACTIVATE|SWP_NOZORDER);
-       }
-
-       if (IsWindowVisible(_hsidebar)) {
-               WindowRect rt(_hsidebar);
-               rect.left += rt.right-rt.left;
-
-               SetWindowPos(_hsidebar, 0, -1, rect.top-1, rt.right-rt.left, rect.bottom-rect.top+1, SWP_NOACTIVATE|SWP_NOZORDER);
-       }
-
-       MoveWindow(_hmdiclient, rect.left-1, rect.top-1, rect.right-rect.left+1, rect.bottom-rect.top+1, TRUE);
-}
-
-bool MDIMainFrame::activate_drive_window(LPCTSTR path)
-{
-       TCHAR drv1[_MAX_DRIVE], drv2[_MAX_DRIVE];
-       HWND child_wnd;
-
-       _tsplitpath_s(path, drv1, COUNTOF(drv1), NULL, 0, NULL, 0, NULL, 0);
-
-        // search for a already open window for the same drive
-       for(child_wnd=::GetNextWindow(_hmdiclient,GW_CHILD); child_wnd; child_wnd=::GetNextWindow(child_wnd, GW_HWNDNEXT)) {
-               FileChildWindow* child = (FileChildWindow*) SendMessage(child_wnd, PM_GET_FILEWND_PTR, 0, 0);
-
-               if (child) {
-                       _tsplitpath_s(child->get_root()._path, drv2, COUNTOF(drv2), NULL, 0, NULL, 0, NULL, 0);
-
-                       if (!lstrcmpi(drv2, drv1)) {
-                               SendMessage(_hmdiclient, WM_MDIACTIVATE, (WPARAM)child_wnd, 0);
-
-                               if (IsMinimized(child_wnd))
-                                       ShowWindow(child_wnd, SW_SHOWNORMAL);
-
-                               return true;
-                       }
-               }
-       }
-
-       return false;
-}
-
-bool MDIMainFrame::activate_child_window(LPCTSTR filesys)
-{
-       HWND child_wnd;
-
-        // search for a already open window of the given file system name
-       for(child_wnd=::GetNextWindow(_hmdiclient,GW_CHILD); child_wnd; child_wnd=::GetNextWindow(child_wnd, GW_HWNDNEXT)) {
-               FileChildWindow* child = (FileChildWindow*) SendMessage(child_wnd, PM_GET_FILEWND_PTR, 0, 0);
-
-               if (child) {
-                       if (!lstrcmpi(child->get_root()._fs, filesys)) {
-                               SendMessage(_hmdiclient, WM_MDIACTIVATE, (WPARAM)child_wnd, 0);
-
-                               if (IsMinimized(child_wnd))
-                                       ShowWindow(child_wnd, SW_SHOWNORMAL);
-
-                               return true;
-                       }
-               } else {
-                       ShellBrowser* shell_child = (ShellBrowser*) SendMessage(child_wnd, PM_GET_SHELLBROWSER_PTR, 0, 0);
-
-                       if (shell_child) {
-                               if (!lstrcmpi(shell_child->get_root()._fs, filesys)) {
-                                       SendMessage(_hmdiclient, WM_MDIACTIVATE, (WPARAM)child_wnd, 0);
-
-                                       if (IsMinimized(child_wnd))
-                                               ShowWindow(child_wnd, SW_SHOWNORMAL);
-
-                                       return true;
-                               }
-                       }
-               }
-       }
-
-       return false;
-}
-
-bool MDIMainFrame::go_to(LPCTSTR url, bool new_window)
-{
-       if (!new_window) {
-               HWND hwndClient = (HWND) SendMessage(_hmdiclient, WM_MDIGETACTIVE, 0, 0);
-
-               if (hwndClient)
-                       if (SendMessage(hwndClient, PM_JUMP_TO_URL, 0, (LPARAM)url))
-                               return true;
-       }
-
-       if (CreateChild(url))
-               return true;
-
-       return super::go_to(url, new_window);
-}
-
-#endif // _NO_MDI
-
-
-SDIMainFrame::SDIMainFrame(HWND hwnd)
- :     super(hwnd)
-{
-       _split_pos = DEFAULT_SPLIT_POS;
-       _last_split = DEFAULT_SPLIT_POS;
-
-       /* wait for PM_OPEN_WINDOW message before creating a shell view
-       update_shell_browser();*/
-}
-
-HWND SDIMainFrame::Create()
-{
-       HMENU hMenuFrame = LoadMenu(g_Globals._hInstance, MAKEINTRESOURCE(IDM_SDIFRAME));
-
-       return Window::Create(WINDOW_CREATOR(SDIMainFrame), 0,
-                               (LPCTSTR)(int)g_Globals._hframeClass, ResString(IDS_TITLE), WS_OVERLAPPEDWINDOW,
-                               CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT,
-                               0/*hwndDesktop*/, hMenuFrame);
-}
-
-HWND SDIMainFrame::Create(LPCITEMIDLIST pidl, int mode)
-{
-       HWND hFrame = Create();
-       if (!hFrame)
-               return 0;
-
-       ShowWindow(hFrame, SW_SHOW);
-
-       SDIMainFrame* pFrame = GET_WINDOW(SDIMainFrame, hFrame);
-
-       if (pFrame)
-               pFrame->jump_to(pidl, mode);
-
-       return hFrame;
-}
-
-HWND SDIMainFrame::Create(LPCTSTR path, int mode)
-{
-       HWND hFrame = Create();
-       if (!hFrame)
-               return 0;
-
-       ShowWindow(hFrame, SW_SHOW);
-
-       MDIMainFrame* pMainFrame = GET_WINDOW(MDIMainFrame, hFrame);
-
-       if (pMainFrame)
-               pMainFrame->CreateChild(path, mode);
-
-       return hFrame;
-}
-
-LRESULT SDIMainFrame::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_SIZE:
-               resize_frame(LOWORD(lparam), HIWORD(lparam));
-               break;
-
-         case WM_PAINT: {
-               PaintCanvas canvas(_hwnd);
-
-               if (_left_hwnd) {
-                       ClientRect rt(_hwnd);
-                       rt.left = _split_pos-SPLIT_WIDTH/2;
-                       rt.right = _split_pos+SPLIT_WIDTH/2+1;
-
-                       if (_right_hwnd) {
-                               WindowRect right_rect(_right_hwnd);
-                               ScreenToClient(_hwnd, &right_rect);
-                               rt.top = right_rect.top;
-                               rt.bottom = right_rect.bottom;
-                       }
-
-                       HBRUSH lastBrush = SelectBrush(canvas, GetStockBrush(COLOR_SPLITBAR));
-                       Rectangle(canvas, rt.left, rt.top-1, rt.right, rt.bottom+1);
-                       SelectObject(canvas, lastBrush);
-               }
-               break;}
-
-         case WM_SETCURSOR:
-               if (_left_hwnd)
-                       if (LOWORD(lparam) == HTCLIENT) {
-                               POINT pt;
-                               GetCursorPos(&pt);
-                               ScreenToClient(_hwnd, &pt);
-
-                               if (pt.x>=_split_pos-SPLIT_WIDTH/2 && pt.x<_split_pos+SPLIT_WIDTH/2+1) {
-                                       SetCursor(LoadCursor(0, IDC_SIZEWE));
-                                       return TRUE;
-                               }
-                       }
-               goto def;
-
-         case WM_LBUTTONDOWN:
-               if (_left_hwnd) {
-                       int x = GET_X_LPARAM(lparam);
-
-                       ClientRect rt(_hwnd);
-
-                       if (x>=_split_pos-SPLIT_WIDTH/2 && x<_split_pos+SPLIT_WIDTH/2+1) {
-                               _last_split = _split_pos;
-                               SetCapture(_hwnd);
-                       }
-               }
-               break;
-
-         case WM_LBUTTONUP:
-               if (GetCapture() == _hwnd)
-                       ReleaseCapture();
-               break;
-
-         case WM_KEYDOWN:
-               if (wparam == VK_ESCAPE)
-                       if (GetCapture() == _hwnd) {
-                               _split_pos = _last_split;
-                               resize_children();
-                               _last_split = -1;
-                               ReleaseCapture();
-                               SetCursor(LoadCursor(0, IDC_ARROW));
-                       }
-               break;
-
-         case WM_MOUSEMOVE:
-               if (GetCapture() == _hwnd) {
-                       int x = GET_X_LPARAM(lparam);
-
-                       ClientRect rt(_hwnd);
-
-                       if (x>=0 && x<rt.right) {
-                               _split_pos = x;
-                               resize_children();
-                               rt.left = x-SPLIT_WIDTH/2;
-                               rt.right = x+SPLIT_WIDTH/2+1;
-                               InvalidateRect(_hwnd, &rt, FALSE);
-                               UpdateWindow(_left_hwnd);
-                               UpdateWindow(_hwnd);
-                               UpdateWindow(_right_hwnd);
-                       }
-               }
-               break;
-
-         case PM_OPEN_WINDOW: {
-               CONTEXT("SDIMainFrame PM_OPEN_WINDOW");
-
-               TCHAR buffer[MAX_PATH];
-               LPCTSTR path;
-               ShellPath shell_path = DesktopFolderPath();
-
-               if (lparam) {
-                       if (wparam & OWM_PIDL) {
-                                // take over PIDL from lparam
-                               shell_path.assign((LPCITEMIDLIST)lparam);       // create as "rooted" window
-                               FileSysShellPath fsp(shell_path);
-                               path = fsp;
-
-                               if (path) {
-                                       LOG(FmtString(TEXT("SDIMainFrame PM_OPEN_WINDOW: path=%s"), path));
-                                       lstrcpy(buffer, path);
-                                       path = buffer;
-                               }
-                       } else {
-                                // take over path from lparam
-                               path = (LPCTSTR)lparam;
-                               shell_path = path;      // create as "rooted" window
-                       }
-               } else {
-                       ///@todo read paths and window placements from registry
-                       if (!GetCurrentDirectory(MAX_PATH, buffer))
-                               *buffer = '\0';
-
-                       path = buffer;
-                       shell_path = path;
-               }
-
-               if (wparam & OWM_ROOTED)
-                       _shellpath_info._root_shell_path = shell_path;
-               else
-                       _shellpath_info._root_shell_path = DesktopFolderPath(); //SpecialFolderPath(CSIDL_DRIVES, _hwnd);
-
-               jump_to(shell_path, wparam);    //@todo content of 'path' not used any more
-               return TRUE;}   // success
-
-         default: def:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-int SDIMainFrame::Command(int id, int code)
-{
-       switch(id) {
-         case ID_VIEW_MDI:
-               MainFrameBase::Create(ExplorerCmd(_url, true));
-               break;
-
-         case IDW_COMMANDBAR:
-               if (code == 1)
-                       ExecuteCommandbar(_url);
-               break;
-
-         default:
-               return super::Command(id, code);
-       }
-
-       return 0;
-}
-
-void SDIMainFrame::resize_frame(int cx, int cy)
-{
-       if (cy <= 0)
-               return; // avoid resizing children when receiving RBN_AUTOSIZE while getting minimized
-
-       RECT rect = {0, 0, cx, cy};
-
-       if (_hwndrebar) {
-               int height = ClientRect(_hwndrebar).bottom;
-               rect.top += height;
-        rect.top += 5;
-       } else {
-               if (IsWindowVisible(_htoolbar)) {
-                       SendMessage(_htoolbar, WM_SIZE, 0, 0);
-                       WindowRect rt(_htoolbar);
-                       rect.top = rt.bottom;
-               //      rect.bottom -= rt.bottom;
-               }
-       }
-
-       if (IsWindowVisible(_hstatusbar)) {
-               int parts[] = {300, 500};
-
-               SendMessage(_hstatusbar, WM_SIZE, 0, 0);
-               SendMessage(_hstatusbar, SB_SETPARTS, 2, (LPARAM)&parts);
-               ClientRect rt(_hstatusbar);
-               rect.bottom -= rt.bottom;
-       }
-
-       if (IsWindowVisible(_haddressedit) || IsWindowVisible(_hcommandedit)) {
-               ClientRect rt(_haddressedit);
-               rect.bottom -= rt.bottom;
-
-               int mid = (rect.right-rect.left) / 2;   ///@todo use split bar
-               SetWindowPos(_haddressedit, 0, 0, rect.bottom, mid, rt.bottom, SWP_NOACTIVATE|SWP_NOZORDER);
-               SetWindowPos(_hcommandedit, 0, mid+1, rect.bottom, rect.right-(mid+1), rt.bottom, SWP_NOACTIVATE|SWP_NOZORDER);
-       }
-
-       if (IsWindowVisible(_hsidebar)) {
-               WindowRect rt(_hsidebar);
-               rect.left += rt.right-rt.left;
-
-               SetWindowPos(_hsidebar, 0, -1, rect.top-1, rt.right-rt.left, rect.bottom-rect.top+1, SWP_NOACTIVATE|SWP_NOZORDER);
-       }
-
-       _clnt_rect = rect;
-
-       resize_children();
-}
-
-void SDIMainFrame::resize_children()
-{
-       HDWP hdwp = BeginDeferWindowPos(2);
-
-       int cx = _clnt_rect.left;
-
-       if (_left_hwnd) {
-               cx = _split_pos + SPLIT_WIDTH/2;
-
-               hdwp = DeferWindowPos(hdwp, _left_hwnd, 0, _clnt_rect.left, _clnt_rect.top, _split_pos-SPLIT_WIDTH/2-_clnt_rect.left, _clnt_rect.bottom-_clnt_rect.top, SWP_NOZORDER|SWP_NOACTIVATE);
-       } else {
-               //_split_pos = -1;
-               cx = 0;
-       }
-
-       if (_right_hwnd)
-               hdwp = DeferWindowPos(hdwp, _right_hwnd, 0, _clnt_rect.left+cx+1, _clnt_rect.top, _clnt_rect.right-cx, _clnt_rect.bottom-_clnt_rect.top, SWP_NOZORDER|SWP_NOACTIVATE);
-
-       EndDeferWindowPos(hdwp);
-}
-
-void SDIMainFrame::update_clnt_rect()
-{
-       ClientRect rect(_hwnd);
-
-       resize_frame(rect.right, rect.bottom);
-}
-
-void SDIMainFrame::update_shell_browser()
-{
-       int split_pos = DEFAULT_SPLIT_POS;
-
-       if (_shellBrowser.get()) {
-               split_pos = _split_pos;
-               delete _shellBrowser.release();
-       }
-
-        // create explorer treeview
-       if (_shellpath_info._open_mode & OWM_EXPLORE) {
-               if (!_left_hwnd) {
-                       ClientRect rect(_hwnd);
-
-                       _left_hwnd = CreateWindowEx(WS_EX_CLIENTEDGE, WC_TREEVIEW, NULL,
-                                                       WS_CHILD|WS_TABSTOP|WS_VISIBLE|TVS_HASLINES|TVS_LINESATROOT|TVS_HASBUTTONS|TVS_NOTOOLTIPS|TVS_SHOWSELALWAYS,
-                                                       0, rect.top, split_pos-SPLIT_WIDTH/2, rect.bottom-rect.top,
-                                                       _hwnd, (HMENU)IDC_FILETREE, g_Globals._hInstance, 0);
-
-                        // display tree window as long as the shell view is not yet visible
-                       resize_frame(rect.right, rect.bottom);
-                       MoveWindow(_left_hwnd, rect.left, rect.top, rect.right-rect.left, rect.bottom-rect.top, TRUE);
-               }
-       } else {
-               if (_left_hwnd) {
-                       DestroyWindow(_left_hwnd);
-                       _left_hwnd = 0;
-               }
-       }
-
-       _shellBrowser = auto_ptr<ShellBrowser>(new ShellBrowser(_hwnd, _hwnd, _left_hwnd, _right_hwnd,
-                                                                                               _shellpath_info, this, _cm_ifs));
-
-       if (_left_hwnd)
-               _shellBrowser->Init();
-
-        // update _clnt_rect and set size of new created shell view windows
-       update_clnt_rect();
-}
-
-void SDIMainFrame::entry_selected(Entry* entry)
-{
-       if (_left_hwnd)
-               _shellBrowser->select_folder(entry, false);
-
-       _shellBrowser->UpdateFolderView(entry->get_shell_folder());
-
-        // set size of new created shell view windows
-       resize_children();
-
-       TCHAR path[MAX_PATH];
-
-       if (entry->get_path(path, COUNTOF(path))) {
-               String url;
-
-               if (path[0] == ':')
-                       url.printf(TEXT("shell://%s"), path);
-               else
-                       url.printf(TEXT("file://%s"), path);
-
-               set_url(url);
-       }
-}
-
-void SDIMainFrame::set_url(LPCTSTR url)
-{
-       if (_url != url) {
-               _url = url;
-
-               SetWindowText(_haddressedit, url); //SendMessage(_hwndFrame, PM_URL_CHANGED, 0, (LPARAM)url);
-       }
-}
-
-void SDIMainFrame::jump_to(LPCTSTR path, int mode)
-{/*@@todo
-       if (_shellBrowser.get() && (_shellpath_info._open_mode&~OWM_PIDL)==(mode&~OWM_PIDL)) {
-               _shellBrowser->jump_to(path);
-
-               _shellpath_info._shell_path = path;
-       } else */{
-               _shellpath_info._open_mode = mode;
-               _shellpath_info._shell_path = path;
-
-               update_shell_browser();
-       }
-}
-
-void SDIMainFrame::jump_to(LPCITEMIDLIST path, int mode)
-{
-       if (_shellBrowser.get() && (_shellpath_info._open_mode&~OWM_PIDL)==(mode&~OWM_PIDL)) {
-               ShellPath shell_path = path;
-
-               _shellBrowser->jump_to(shell_path);
-
-               _shellpath_info._shell_path = shell_path;
-       } else {
-               _shellpath_info._open_mode = mode;
-               _shellpath_info._shell_path = path;
-
-               update_shell_browser();
-       }
-}
diff --git a/reactos/subsys/system/explorer/shell/mainframe.h b/reactos/subsys/system/explorer/shell/mainframe.h
deleted file mode 100644 (file)
index 93f534b..0000000
+++ /dev/null
@@ -1,186 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // mainframe.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#define        PM_OPEN_WINDOW                  (WM_APP+0x07)
-
-enum OPEN_WINDOW_MODE {
-       OWM_EXPLORE=1,  /// window in explore mode
-       OWM_ROOTED=2,   /// "rooted" window with special shell namespace root
-       OWM_DETAILS=4,  /// view files in detail mode
-       OWM_PIDL=8,             /// path is given as PIDL, otherwise as LPCTSTR
-       OWM_SEPARATE=16 /// open separate subfolder windows
-};
-
-
- /// Explorer frame window base class
-struct MainFrameBase : public PreTranslateWindow
-{
-       typedef PreTranslateWindow super;
-
-       MainFrameBase(HWND hwnd);
-       ~MainFrameBase();
-
-       static HWND Create(const ExplorerCmd& cmd);
-       static int OpenShellFolders(LPIDA pida, HWND hFrameWnd);
-
-       WindowHandle _hwndrebar;
-
-       WindowHandle _htoolbar;
-       WindowHandle _hstatusbar;
-
-       WindowHandle _haddressedit;
-       WindowHandle _hcommandedit;
-
-       WindowHandle _hsidebar;
-       HIMAGELIST      _himl;
-
-       HMENU           _hMenuFrame;
-       HMENU           _hMenuWindow;
-
-       MenuInfo        _menu_info;
-
-protected:
-       FullScreenParameters _fullscreen;
-
-       HACCEL          _hAccel;
-       HIMAGELIST      _himl_old;
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       bool    ProcessMessage(UINT nmsg, WPARAM wparam, LPARAM lparam, LRESULT* pres);
-       int             Command(int id, int code);
-       int             Notify(int id, NMHDR* pnmh);
-
-       virtual BOOL TranslateMsg(MSG* pmsg);
-
-       void    toggle_child(HWND hwnd, UINT cmd, HWND hchild, int band_idx=-1);
-
-       void    resize_frame_client();
-       virtual void resize_frame(int cx, int cy);
-       virtual void frame_get_clientspace(PRECT prect);
-
-       BOOL    toggle_fullscreen();
-       void    fullscreen_move();
-
-       void    FillBookmarks();
-       virtual bool go_to(LPCTSTR url, bool new_window);
-
-       void    ExecuteCommandbar(LPCTSTR dir);
-};
-
-
-#ifndef _NO_MDI
-
-struct MDIMainFrame : public MainFrameBase
-{
-       typedef MainFrameBase super;
-
-       MDIMainFrame(HWND hwnd);
-
-       static HWND Create();
-       static HWND Create(LPCTSTR path, int mode=OWM_EXPLORE|OWM_DETAILS);
-       static HWND Create(LPCITEMIDLIST pidl, int mode=OWM_EXPLORE|OWM_DETAILS|OWM_PIDL);
-
-       ChildWindow* CreateChild(LPCTSTR path=NULL, int mode=OWM_EXPLORE|OWM_DETAILS);
-       ChildWindow* CreateChild(LPCITEMIDLIST pidl, int mode=OWM_EXPLORE|OWM_DETAILS|OWM_PIDL);
-
-protected:
-       HWND    _hmdiclient;
-
-       WindowHandle _hextrabar;
-#ifndef _NO_WIN_FS
-       WindowHandle _hdrivebar;
-#endif
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Command(int id, int code);
-
-       virtual BOOL TranslateMsg(MSG* pmsg);
-
-       bool    activate_drive_window(LPCTSTR path);
-       bool    activate_child_window(LPCTSTR filesys);
-
-       virtual void resize_frame(int cx, int cy);
-       virtual void frame_get_clientspace(PRECT prect);
-
-       virtual bool go_to(LPCTSTR url, bool new_window);
-
-#ifndef _NO_WIN_FS
-       TCHAR   _drives[BUFFER_LEN];
-#endif
-};
-
-#endif
-
-
-struct SDIMainFrame : public ExtContextMenuHandlerT<
-                               ShellBrowserChildT<MainFrameBase>
-                       >
-{
-       typedef ExtContextMenuHandlerT<
-                               ShellBrowserChildT<MainFrameBase>
-                       > super;
-
-       SDIMainFrame(HWND hwnd);
-
-       static HWND Create();
-       static HWND Create(LPCTSTR path, int mode=OWM_EXPLORE|OWM_DETAILS);
-       static HWND Create(LPCITEMIDLIST pidl, int mode=OWM_EXPLORE|OWM_DETAILS|OWM_PIDL);
-
-protected:
-       ShellPathInfo _shellpath_info;
-
-       WindowHandle _left_hwnd;
-       WindowHandle _right_hwnd;
-
-/**@todo focus handling for TAB switching
-       int     _focus_pane;            // 0: left      1: right
-*/
-
-       int     _split_pos;
-       int             _last_split;
-       RECT    _clnt_rect;
-
-       String  _url;
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Command(int id, int code);
-
-       void    resize_frame(int cx, int cy);
-       void    resize_children();
-       void    update_clnt_rect();
-
-       void    update_shell_browser();
-       void    jump_to(LPCTSTR path, int mode);
-       void    jump_to(LPCITEMIDLIST path, int mode);
-
-        // interface BrowserCallback
-       virtual void    entry_selected(Entry* entry);
-
-       void    set_url(LPCTSTR url);
-};
diff --git a/reactos/subsys/system/explorer/shell/ntobjfs.cpp b/reactos/subsys/system/explorer/shell/ntobjfs.cpp
deleted file mode 100644 (file)
index e22d9ec..0000000
+++ /dev/null
@@ -1,392 +0,0 @@
-/*
- * Copyright 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // ntobjfs.cpp
- //
- // Martin Fuchs, 31.01.2004
- //
-
-
-#include <precomp.h>
-
-#include "ntobjfs.h"
-//#include "winfs.h"
-#include "regfs.h"
-
-
-#define        CONSTRUCT_NTDLLFCT(x) x(TEXT("NTDLL"), #x)
-
-typedef DWORD (__stdcall* NTOBJECTOPENFUNCTIONS)(HANDLE*, DWORD, OpenStruct*);
-
-struct NTDLL {
-       NTDLL()
-        :      CONSTRUCT_NTDLLFCT(RtlInitAnsiString),
-               CONSTRUCT_NTDLLFCT(RtlInitUnicodeString),
-               CONSTRUCT_NTDLLFCT(RtlFreeAnsiString),
-               CONSTRUCT_NTDLLFCT(RtlFreeUnicodeString),
-               CONSTRUCT_NTDLLFCT(RtlAnsiStringToUnicodeString),
-               CONSTRUCT_NTDLLFCT(RtlUnicodeStringToAnsiString),
-               CONSTRUCT_NTDLLFCT(NtOpenDirectoryObject),
-               CONSTRUCT_NTDLLFCT(NtQueryDirectoryObject),
-               CONSTRUCT_NTDLLFCT(NtOpenFile),
-               CONSTRUCT_NTDLLFCT(NtOpenSymbolicLinkObject),
-               CONSTRUCT_NTDLLFCT(NtQuerySymbolicLinkObject),
-               CONSTRUCT_NTDLLFCT(NtQueryObject),
-               CONSTRUCT_NTDLLFCT(NtOpenMutant),
-               CONSTRUCT_NTDLLFCT(NtOpenSection),
-               CONSTRUCT_NTDLLFCT(NtOpenEvent),
-               CONSTRUCT_NTDLLFCT(NtOpenEventPair),
-               CONSTRUCT_NTDLLFCT(NtOpenIoCompletion),
-               CONSTRUCT_NTDLLFCT(NtOpenSemaphore),
-               CONSTRUCT_NTDLLFCT(NtOpenTimer),
-               CONSTRUCT_NTDLLFCT(NtOpenKey),
-               CONSTRUCT_NTDLLFCT(NtClose),
-               CONSTRUCT_NTDLLFCT(NtOpenProcess),
-               CONSTRUCT_NTDLLFCT(NtOpenThread)
-       {
-               NTOBJECTOPENFUNCTIONS* p = _ObjectOpenFunctions;
-
-               *p++ = *NtOpenDirectoryObject;
-               *p++ = *NtOpenSymbolicLinkObject;
-               *p++ = *NtOpenMutant;
-               *p++ = *NtOpenSection;
-               *p++ = *NtOpenEvent;
-               *p++ = *NtOpenSemaphore;
-               *p++ = *NtOpenTimer;
-               *p++ = *NtOpenKey;
-               *p++ = *NtOpenEventPair;
-               *p++ = *NtOpenIoCompletion;
-               *p++ = 0/*Device Object*/;
-               *p++ = 0/*NtOpenFile*/;
-               *p++ = 0/*CONTROLLER_OBJECT*/;
-               *p++ = 0/*PROFILE_OBJECT*/;
-               *p++ = 0/*TYPE_OBJECT*/;
-               *p++ = 0/*DESKTOP_OBJECT*/;
-               *p++ = 0/*WINDOWSTATION_OBJECT*/;
-               *p++ = 0/*DRIVER_OBJECT*/;
-               *p++ = 0/*TOKEN_OBJECT*/;
-               *p++ = 0/*PROCESS_OBJECT*/;
-               *p++ = 0/*THREAD_OBJECT*/;
-               *p++ = 0/*ADAPTER_OBJECT*/;
-               *p++ = 0/*PORT_OBJECT*/;
-       }
-
-       NTOBJECTOPENFUNCTIONS _ObjectOpenFunctions[23];
-       static const LPCWSTR s_ObjectTypes[];
-
-       DynamicFct<void (__stdcall*)(RtlAnsiString*, LPCSTR)> RtlInitAnsiString;
-       DynamicFct<void (__stdcall*)(RtlUnicodeString*, LPCWSTR)> RtlInitUnicodeString;
-       DynamicFct<DWORD (__stdcall*)(RtlAnsiString*)> RtlFreeAnsiString;
-       DynamicFct<DWORD (__stdcall*)(RtlUnicodeString*)> RtlFreeUnicodeString;
-       DynamicFct<DWORD (__stdcall*)(RtlUnicodeString*, const RtlAnsiString*, BOOL)> RtlAnsiStringToUnicodeString;
-       DynamicFct<DWORD (__stdcall*)(RtlAnsiString*, const RtlUnicodeString*, BOOL)> RtlUnicodeStringToAnsiString;
-
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenDirectoryObject;
-       DynamicFct<DWORD (__stdcall*)(HANDLE, NtObjectInfo*, DWORD size, BOOL, BOOL, void*, void*)> NtQueryDirectoryObject;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, void*, DWORD*, DWORD, OpenStruct*)> NtOpenFile;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenSymbolicLinkObject;
-       DynamicFct<DWORD (__stdcall*)(HANDLE, RtlUnicodeString*, DWORD*)> NtQuerySymbolicLinkObject;
-       DynamicFct<DWORD (__stdcall*)(HANDLE, DWORD, NtObject*, DWORD size, DWORD* read)> NtQueryObject;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenMutant;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenSection;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenEvent;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenEventPair;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenIoCompletion;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenSemaphore;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenTimer;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenKey;
-       DynamicFct<DWORD (__stdcall*)(HANDLE)> NtClose;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenProcess;
-       DynamicFct<DWORD (__stdcall*)(HANDLE*, DWORD, OpenStruct*)> NtOpenThread;
-};
-
-const LPCWSTR NTDLL::s_ObjectTypes[] = {
-       L"Directory", L"SymbolicLink",
-       L"Mutant", L"Section", L"Event", L"Semaphore",
-       L"Timer", L"Key", L"EventPair", L"IoCompletion",
-       L"Device", L"File", L"Controller", L"Profile",
-       L"Type", L"Desktop", L"WindowStatiom", L"Driver",
-       L"Token", L"Process", L"Thread", L"Adapter", L"Port",
-       0
-};
-
-NTDLL* g_NTDLL = NULL;
-
-
-struct UnicodeString : public RtlUnicodeString {
-       UnicodeString(LPCWSTR str)
-       {
-               (*g_NTDLL->RtlInitUnicodeString)(this, str);
-       }
-
-       UnicodeString(size_t len, LPWSTR buffer)
-       {
-               alloc_len = len;
-               string_ptr = buffer;
-       }
-
-       operator LPCWSTR() const {return string_ptr;}
-};
-
-
-static DWORD NtOpenObject(OBJECT_TYPE type, HANDLE* phandle, DWORD access, LPCWSTR path/*, BOOL xflag=FALSE*/)
-{
-       UnicodeString ustr(path);
-       OpenStruct open_struct = {sizeof(OpenStruct), 0x00, &ustr, 0x40};
-
-       if (type==DIRECTORY_OBJECT || type==SYMBOLICLINK_OBJECT)
-               access |= FILE_LIST_DIRECTORY;
-
-       /* if (xflag)
-               access |= GENERIC_READ; */
-
-       DWORD ioStatusBlock[2]; // IO_STATUS_BLOCK
-
-       if (type>=DIRECTORY_OBJECT && type<=IOCOMPLETITION_OBJECT)
-               return g_NTDLL->_ObjectOpenFunctions[type](phandle, access|STANDARD_RIGHTS_READ, &open_struct);
-       else if (type == FILE_OBJECT)
-               return (*g_NTDLL->NtOpenFile)(phandle, access, &open_struct, ioStatusBlock, FILE_SHARE_READ|FILE_SHARE_WRITE|FILE_SHARE_DELETE, 0/*OpenOptions*/);
-       else
-               return ERROR_INVALID_FUNCTION;
-}
-
-
-void NtObjDirectory::read_directory(int scan_flags)
-{
-       CONTEXT("NtObjDirectory::read_directory()");
-
-       if (!g_NTDLL)
-               g_NTDLL = new NTDLL();
-
-       Entry* first_entry = NULL;
-       int level = _level + 1;
-
-       LPCTSTR path = (LPCTSTR)_path;
-
-       TCHAR buffer[MAX_PATH], *p=buffer;
-#ifndef UNICODE
-       WCHAR wbuffer[MAX_PATH], *w=wbuffer;
-#endif
-
-       do {
-               *p++ = *path;
-#ifndef UNICODE
-               *w++ = *path;
-#endif
-       } while(*path++);
-       --p;
-#ifndef UNICODE
-       --w;
-#endif
-
-       DWORD idx;
-       HANDLE dir_handle;
-
-#ifdef UNICODE
-       if (NtOpenObject(_type, &dir_handle, 0, buffer))
-#else
-       if (NtOpenObject(_type, &dir_handle, 0, wbuffer))
-#endif
-               return;
-
-#ifdef UNICODE
-       if (p[-1] != '\\')
-               *p++ = '\\';
-#else
-       if (w[-1] != '\\')
-               *w++ = '\\';
-#endif
-
-       NtObjectInfo* info = (NtObjectInfo*)alloca(2048);
-
-       if (!(*g_NTDLL->NtQueryDirectoryObject)(dir_handle, info, 2048, TRUE, TRUE, &idx, NULL)) {
-               WIN32_FIND_DATA w32fd;
-               Entry* last = NULL;
-               Entry* entry;
-
-               do {
-                       memset(&w32fd, 0, sizeof(WIN32_FIND_DATA));
-
-#ifdef UNICODE
-                       if (info->name.string_ptr) {
-                               info->name.string_ptr[info->name.string_len / sizeof(WCHAR)] = 0;
-                       } else {
-                               info->name.string_ptr = TEXT("");
-                       }
-                       if (info->type.string_ptr) {
-                               info->type.string_ptr[info->type.string_len / sizeof(WCHAR)] = 0;
-                       } else {
-                               info->type.string_ptr = TEXT("");
-                       }
-                       lstrcpynW(p, info->name.string_ptr, COUNTOF(buffer));
-#else
-                       WideCharToMultiByte(CP_ACP, 0, info->name.string_ptr, info->name.string_len, p, COUNTOF(buffer), 0, 0);
-#endif
-
-                       lstrcpyn(w32fd.cFileName, p, sizeof(w32fd.cFileName) / sizeof(0[w32fd.cFileName]));
-
-                       const LPCWSTR* tname = NTDLL::s_ObjectTypes;
-                       OBJECT_TYPE type = UNKNOWN_OBJECT_TYPE;
-
-                       for(; *tname; tname++)
-                               if (!wcsncmp(info->type.string_ptr, *tname, 32))
-                                       {type=OBJECT_TYPE(tname-NTDLL::s_ObjectTypes); break;}
-
-                       if (type == DIRECTORY_OBJECT) {
-                               w32fd.dwFileAttributes |= FILE_ATTRIBUTE_DIRECTORY;
-
-                               entry = new NtObjDirectory(this, buffer);
-                       }
-
-                       else if (type == SYMBOLICLINK_OBJECT) {
-                               w32fd.dwFileAttributes |= ATTRIBUTE_SYMBOLIC_LINK;
-
-                               entry = NULL;
-
-#ifndef _NO_WIN_FS
-                               if (*w32fd.cFileName>='A' &&*w32fd.cFileName<='Z' && w32fd.cFileName[1]==':')
-                                       if (!_tcsncmp(buffer,TEXT("\\??\\"),4) ||               // NT4
-                                               !_tcsncmp(buffer,TEXT("\\GLOBAL??"),9)) {       // XP
-                                               w32fd.dwFileAttributes |= FILE_ATTRIBUTE_DIRECTORY;
-                                               entry = new WinDirectory(this, w32fd.cFileName);
-                                       }
-#endif
-
-                               if (!entry)
-                                       entry = new NtObjDirectory(this, buffer);
-                       }
-
-                       else if (type == KEY_OBJECT) {
-                               w32fd.dwFileAttributes |= FILE_ATTRIBUTE_DIRECTORY;
-
-                               entry = new RegistryRoot(this, buffer);
-                       }
-                       else
-                               entry = new NtObjEntry(this, type);
-
-                       HANDLE handle;
-
-#ifdef UNICODE
-                       lstrcpyW(p, info->name.string_ptr);
-                       if (!NtOpenObject(type, &handle, 0, buffer))
-#else
-                       lstrcpyW(w, info->name.string_ptr);
-                       if (!NtOpenObject(type, &handle, 0, wbuffer))
-#endif
-                       {
-                               NtObject object;
-                               DWORD read;
-
-                               if (!(*g_NTDLL->NtQueryObject)(handle, 0/*ObjectBasicInformation*/, &object, sizeof(NtObject), &read)) {
-                                       memcpy(&w32fd.ftCreationTime, &object.creation_time, sizeof(FILETIME));
-
-                                       memset(&entry->_bhfi, 0, sizeof(BY_HANDLE_FILE_INFORMATION));
-                                       entry->_bhfi.nNumberOfLinks = object.reference_count - 1;
-                                       entry->_bhfi_valid = true;
-                               }
-
-                               if (type == SYMBOLICLINK_OBJECT) {
-                                       WCHAR wbuffer[_MAX_PATH];
-                                       UnicodeString link(_MAX_PATH, wbuffer);
-
-                                       if (!(*g_NTDLL->NtQuerySymbolicLinkObject)(handle, &link, NULL)) {
-                                               int len = link.string_len/sizeof(WCHAR);
-                                               entry->_content = (LPTSTR) malloc((len+1)*sizeof(TCHAR));
-#ifdef UNICODE
-                                               wcsncpy_s(entry->_content, len+1, link, len);
-#else
-                                               U2nA(link, entry->_content, len);
-#endif
-                                               entry->_content[len] = '\0';
-                                       }
-                               }
-
-                               (*g_NTDLL->NtClose)(handle);
-                       }
-
-                       memcpy(&entry->_data, &w32fd, sizeof(WIN32_FIND_DATA));
-
-#ifdef UNICODE
-                       entry->_type_name = _wcsdup(info->type.string_ptr);
-#else
-                       char type_name[32];
-                       WideCharToMultiByte(CP_ACP, 0, info->type.string_ptr, info->type.string_len, type_name, 32, 0, 0);
-                       entry->_type_name = _strdup(type_name);
-#endif
-
-                       if (!first_entry)
-                               first_entry = entry;
-
-                       if (last)
-                               last->_next = entry;
-
-                       entry->_level = level;
-
-                       last = entry;
-               } while(!(*g_NTDLL->NtQueryDirectoryObject)(dir_handle, info, 2048, TRUE, FALSE, &idx, NULL));
-
-               last->_next = NULL;
-       }
-
-       (*g_NTDLL->NtClose)(dir_handle);
-
-       _down = first_entry;
-       _scanned = true;
-}
-
-
-Entry* NtObjDirectory::find_entry(const void* p)
-{
-       LPCTSTR name = (LPCTSTR)p;
-
-       for(Entry*entry=_down; entry; entry=entry->_next) {
-               LPCTSTR p = name;
-               LPCTSTR q = entry->_data.cFileName;
-
-               do {
-                       if (!*p || *p==TEXT('\\') || *p==TEXT('/'))
-                               return entry;
-               } while(tolower(*p++) == tolower(*q++));
-
-               p = name;
-               q = entry->_data.cAlternateFileName;
-
-               do {
-                       if (!*p || *p==TEXT('\\') || *p==TEXT('/'))
-                               return entry;
-               } while(tolower(*p++) == tolower(*q++));
-       }
-
-       return NULL;
-}
-
-
- // get full path of specified directory entry
-bool NtObjEntry::get_path(PTSTR path, size_t path_count) const
-{
-       return get_path_base ( path, path_count, ET_NTOBJS );
-}
-
-BOOL NtObjEntry::launch_entry(HWND hwnd, UINT nCmdShow)
-{
-       return FALSE;
-}
diff --git a/reactos/subsys/system/explorer/shell/ntobjfs.h b/reactos/subsys/system/explorer/shell/ntobjfs.h
deleted file mode 100644 (file)
index fe5c4b2..0000000
+++ /dev/null
@@ -1,122 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // ntobjfs.h
- //
- // Martin Fuchs, 31.01.2004
- //
-
-
-enum OBJECT_TYPE {
-       DIRECTORY_OBJECT, SYMBOLICLINK_OBJECT,
-       MUTANT_OBJECT, SECTION_OBJECT, EVENT_OBJECT, SEMAPHORE_OBJECT,
-       TIMER_OBJECT, KEY_OBJECT, EVENTPAIR_OBJECT, IOCOMPLETITION_OBJECT,
-       DEVICE_OBJECT, FILE_OBJECT, CONTROLLER_OBJECT, PROFILE_OBJECT,
-       TYPE_OBJECT, DESKTOP_OBJECT, WINDOWSTATION_OBJECT, DRIVER_OBJECT,
-       TOKEN_OBJECT, PROCESS_OBJECT, THREAD_OBJECT, ADAPTER_OBJECT, PORT_OBJECT,
-
-       UNKNOWN_OBJECT_TYPE=-1
-};
-
-struct RtlAnsiString {
-       WORD    string_len;
-       WORD    alloc_len;
-       LPSTR   string_ptr;
-};
-
-struct RtlUnicodeString {
-       WORD    string_len;
-       WORD    alloc_len;
-       LPWSTR  string_ptr;
-};
-
-struct NtObjectInfo {
-       RtlUnicodeString name;
-       RtlUnicodeString type;
-       BYTE    padding[16];
-};
-
-struct OpenStruct {
-       DWORD   size;
-       DWORD   _1;
-       RtlUnicodeString* string;
-       DWORD   _3;
-       DWORD   _4;
-       DWORD   _5;
-};
-
-struct NtObject {
-       DWORD   _0;
-       DWORD   _1;
-       DWORD   handle_count;
-       DWORD   reference_count;
-       DWORD   _4;
-       DWORD   _5;
-       DWORD   _6;
-       DWORD   _7;
-       DWORD   _8;
-       DWORD   _9;
-       DWORD   _A;
-       DWORD   _B;
-       FILETIME creation_time;
-};
-
-
- /// NtObj file system file-entry
-struct NtObjEntry : public Entry
-{
-       NtObjEntry(Entry* parent, OBJECT_TYPE type) : Entry(parent, ET_NTOBJS), _type(type) {}
-
-       OBJECT_TYPE     _type;
-
-protected:
-       NtObjEntry(OBJECT_TYPE type) : Entry(ET_NTOBJS), _type(type) {}
-
-       virtual bool get_path(PTSTR path, size_t path_count) const;
-       virtual BOOL launch_entry(HWND hwnd, UINT nCmdShow);
-};
-
-
- /// NtObj file system directory-entry
-struct NtObjDirectory : public NtObjEntry, public Directory
-{
-       NtObjDirectory(LPCTSTR root_path)
-        :      NtObjEntry(DIRECTORY_OBJECT)
-       {
-               _path = _tcsdup(root_path);
-       }
-
-       NtObjDirectory(Entry* parent, LPCTSTR path)
-        :      NtObjEntry(parent, DIRECTORY_OBJECT)
-       {
-               _path = _tcsdup(path);
-       }
-
-       ~NtObjDirectory()
-       {
-               free(_path);
-               _path = NULL;
-       }
-
-       virtual void read_directory(int scan_flags=0);
-       virtual Entry* find_entry(const void*);
-};
diff --git a/reactos/subsys/system/explorer/shell/pane.cpp b/reactos/subsys/system/explorer/shell/pane.cpp
deleted file mode 100644 (file)
index a3fe36f..0000000
+++ /dev/null
@@ -1,993 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // pane.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include <precomp.h>
-
-#include "../resource.h"
-
-
-enum IMAGE {
-       IMG_NONE=-1,    IMG_FILE=0,             IMG_DOCUMENT,   IMG_EXECUTABLE,
-       IMG_FOLDER,     IMG_OPEN_FOLDER,        IMG_FOLDER_PLUS,IMG_OPEN_PLUS,  IMG_OPEN_MINUS,
-       IMG_FOLDER_UP,  IMG_FOLDER_CUR
-};
-
-
-#define IMAGE_WIDTH            16
-#define IMAGE_HEIGHT           13
-
-
-static const LPTSTR g_pos_names[COLUMNS] = {
-       TEXT(""),                       /* symbol */
-       TEXT("Name"),
-       TEXT("Type"),
-       TEXT("Size"),
-       TEXT("CDate"),
-       TEXT("ADate"),
-       TEXT("MDate"),
-       TEXT("Index/Inode"),
-       TEXT("Links"),
-       TEXT("Attributes"),
-       TEXT("Security"),
-       TEXT("Content")
-};
-
-static const int g_pos_align[] = {
-       0,
-       HDF_LEFT,       /* Name */
-       HDF_LEFT,       /* Type */
-       HDF_RIGHT,      /* Size */
-       HDF_LEFT,       /* CDate */
-       HDF_LEFT,       /* ADate */
-       HDF_LEFT,       /* MDate */
-       HDF_LEFT,       /* Index */
-       HDF_RIGHT,      /* Links */
-       HDF_CENTER,     /* Attributes */
-       HDF_LEFT,       /* Security */
-       HDF_LEFT        /* Content / Description */
-};
-
-
-Pane::Pane(HWND hparent, int id, int id_header, Entry* root, bool treePane, int visible_cols)
- :     super(CreateWindow(TEXT("ListBox"), TEXT(""), WS_CHILD|WS_VISIBLE|WS_HSCROLL|WS_VSCROLL|
-                       LBS_DISABLENOSCROLL|LBS_NOINTEGRALHEIGHT|LBS_OWNERDRAWFIXED|LBS_NOTIFY,
-                       0, 0, 0, 0, hparent, (HMENU)id, g_Globals._hInstance, 0)),
-       _root(root),
-       _visible_cols(visible_cols),
-       _treePane(treePane)
-{
-        // insert entries into listbox
-       Entry* entry = _root;
-
-       if (entry)
-               insert_entries(entry);
-
-       init();
-
-       create_header(hparent, id_header);
-}
-
-Pane::~Pane()
-{
-       ImageList_Destroy(_himl);
-}
-
-
-LRESULT Pane::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_HSCROLL:
-               set_header();
-               break;
-
-         case WM_SETFOCUS: {
-               FileChildWindow* child = (FileChildWindow*) SendMessage(GetParent(_hwnd), PM_GET_FILEWND_PTR, 0, 0);
-
-               child->set_focus_pane(this);
-               ListBox_SetSel(_hwnd, TRUE, 1);
-               /*@todo check menu items */
-               break;}
-
-         case WM_KEYDOWN: {
-               FileChildWindow* child = (FileChildWindow*) SendMessage(GetParent(_hwnd), PM_GET_FILEWND_PTR, 0, 0);
-
-               if (wparam == VK_TAB) {
-                       /*@todo SetFocus(g_Globals.hdrivebar) */
-                       child->switch_focus_pane();
-               }
-               break;}
-       }
-
-       return super::WndProc(nmsg, wparam, lparam);
-}
-
-
-bool Pane::create_header(HWND hparent, int id)
-{
-       HWND hwnd = CreateWindow(WC_HEADER, 0, WS_CHILD|WS_VISIBLE|HDS_HORZ/*@todo |HDS_BUTTONS + sort orders*/,
-                                                               0, 0, 0, 0, hparent, (HMENU)id, g_Globals._hInstance, 0);
-       if (!hwnd)
-               return false;
-
-       SetWindowFont(hwnd, GetStockFont(DEFAULT_GUI_FONT), FALSE);
-
-       HD_ITEM hdi;
-
-       hdi.mask = HDI_TEXT|HDI_WIDTH|HDI_FORMAT;
-
-       for(int idx=0; idx<COLUMNS; idx++) {
-               hdi.pszText = g_pos_names[idx];
-               hdi.fmt = HDF_STRING | g_pos_align[idx];
-               hdi.cxy = _widths[idx];
-               Header_InsertItem(hwnd, idx, &hdi);
-       }
-
-       _hwndHeader = hwnd;
-
-       return true;
-}
-
-
-void Pane::init()
-{
-       _himl = ImageList_LoadBitmap(g_Globals._hInstance, MAKEINTRESOURCE(IDB_IMAGES), 16, 0, RGB(0,255,0));
-
-       SetWindowFont(_hwnd, _out_wrkr._hfont, FALSE);
-
-        // read the color for compressed files from registry
-       HKEY hkeyExplorer = 0;
-       DWORD len = sizeof(_clrCompressed);
-
-       if (RegOpenKey(HKEY_CURRENT_USER, TEXT("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Explorer"), &hkeyExplorer) ||
-               RegQueryValueEx(hkeyExplorer, TEXT("AltColor"), 0, NULL, (LPBYTE)&_clrCompressed, &len) || len!=sizeof(_clrCompressed))
-               _clrCompressed = RGB(0,0,255);
-
-       if (hkeyExplorer)
-               RegCloseKey(hkeyExplorer);
-
-        // calculate column widths
-       _out_wrkr.init_output(_hwnd);
-       calc_widths(true);
-}
-
-
- // calculate prefered width for all visible columns
-
-bool Pane::calc_widths(bool anyway)
-{
-       int col, x, cx, spc=3*_out_wrkr._spaceSize.cx;
-       int entries = ListBox_GetCount(_hwnd);
-       int orgWidths[COLUMNS];
-       int orgPositions[COLUMNS+1];
-       HFONT hfontOld;
-       HDC hdc;
-       int cnt;
-
-       if (!anyway) {
-               memcpy(orgWidths, _widths, sizeof(orgWidths));
-               memcpy(orgPositions, _positions, sizeof(orgPositions));
-       }
-
-       for(col=0; col<COLUMNS; col++)
-               _widths[col] = 0;
-
-       hdc = GetDC(_hwnd);
-       hfontOld = SelectFont(hdc, _out_wrkr._hfont);
-
-       for(cnt=0; cnt<entries; cnt++) {
-               Entry* entry = (Entry*) ListBox_GetItemData(_hwnd, cnt);
-
-               DRAWITEMSTRUCT dis;
-
-               dis.CtlType               = 0;
-               dis.CtlID                 = 0;
-               dis.itemID                = 0;
-               dis.itemAction    = 0;
-               dis.itemState     = 0;
-               dis.hwndItem      = _hwnd;
-               dis.hDC                   = hdc;
-               dis.rcItem.left   = 0;
-               dis.rcItem.top    = 0;
-               dis.rcItem.right  = 0;
-               dis.rcItem.bottom = 0;
-               /*dis.itemData    = 0; */
-
-               draw_item(&dis, entry, COLUMNS);
-       }
-
-       SelectObject(hdc, hfontOld);
-       ReleaseDC(_hwnd, hdc);
-
-       x = 0;
-       for(col=0; col<COLUMNS; col++) {
-               _positions[col] = x;
-               cx = _widths[col];
-
-               if (cx) {
-                       cx += spc;
-
-                       if (cx < IMAGE_WIDTH)
-                               cx = IMAGE_WIDTH;
-
-                       _widths[col] = cx;
-               }
-
-               x += cx;
-       }
-
-       _positions[COLUMNS] = x;
-
-       ListBox_SetHorizontalExtent(_hwnd, x);
-
-        // no change?
-       if (!memcmp(orgWidths, _widths, sizeof(orgWidths)))
-               return FALSE;
-
-        // don't move, if only collapsing an entry
-       if (!anyway && _widths[0]<orgWidths[0] &&
-               !memcmp(orgWidths+1, _widths+1, sizeof(orgWidths)-sizeof(int))) {
-               _widths[0] = orgWidths[0];
-               memcpy(_positions, orgPositions, sizeof(orgPositions));
-
-               return FALSE;
-       }
-
-       InvalidateRect(_hwnd, 0, TRUE);
-
-       return TRUE;
-}
-
-
-static void format_date(const FILETIME* ft, TCHAR* buffer, int visible_cols)
-{
-       SYSTEMTIME systime;
-       FILETIME lft;
-       int len = 0;
-
-       *buffer = TEXT('\0');
-
-       if (!ft->dwLowDateTime && !ft->dwHighDateTime)
-               return;
-
-       if (!FileTimeToLocalFileTime(ft, &lft))
-               {err: lstrcpy(buffer,TEXT("???")); return;}
-
-       if (!FileTimeToSystemTime(&lft, &systime))
-               goto err;
-
-       if (visible_cols & COL_DATE) {
-               len = GetDateFormat(LOCALE_USER_DEFAULT, 0, &systime, 0, buffer, BUFFER_LEN);
-               if (!len)
-                       goto err;
-       }
-
-       if (visible_cols & COL_TIME) {
-               if (len)
-                       buffer[len-1] = ' ';
-
-               buffer[len++] = ' ';
-
-               if (!GetTimeFormat(LOCALE_USER_DEFAULT, 0, &systime, 0, buffer+len, BUFFER_LEN-len))
-                       buffer[len] = TEXT('\0');
-       }
-}
-
-
-void Pane::draw_item(LPDRAWITEMSTRUCT dis, Entry* entry, int calcWidthCol)
-{
-       TCHAR buffer[BUFFER_LEN];
-       DWORD attrs;
-       int visible_cols = _visible_cols;
-       COLORREF bkcolor, textcolor;
-       RECT focusRect = dis->rcItem;
-       enum IMAGE img;
-       int img_pos, cx;
-       int col = 0;
-
-       if (entry) {
-               attrs = entry->_data.dwFileAttributes;
-
-               if (attrs & FILE_ATTRIBUTE_DIRECTORY) {
-                       if (entry->_data.cFileName[0]==TEXT('.') && entry->_data.cFileName[1]==TEXT('.')
-                                       && entry->_data.cFileName[2]==TEXT('\0'))
-                               img = IMG_FOLDER_UP;
-                       else if (entry->_data.cFileName[0]==TEXT('.') && entry->_data.cFileName[1]==TEXT('\0'))
-                               img = IMG_FOLDER_CUR;
-                       else if ((_treePane && (dis->itemState&ODS_FOCUS)))
-                               img = IMG_OPEN_FOLDER;
-                       else
-                               img = IMG_FOLDER;
-               } else {
-                       if (attrs & ATTRIBUTE_EXECUTABLE)
-                               img = IMG_EXECUTABLE;
-                       else if (entry->_type_name)
-                               img = IMG_DOCUMENT;
-                       else
-                               img = IMG_FILE;
-               }
-       } else {
-               attrs = 0;
-               img = IMG_NONE;
-       }
-
-       if (_treePane) {
-               if (entry) {
-                       img_pos = dis->rcItem.left + entry->_level*(IMAGE_WIDTH+_out_wrkr._spaceSize.cx);
-
-                       if (calcWidthCol == -1) {
-                               int x;
-                               int y = dis->rcItem.top + IMAGE_HEIGHT/2;
-                               Entry* up;
-                               RECT rt_clip;
-                               HRGN hrgn_org = CreateRectRgn(0, 0, 0, 0);
-                               HRGN hrgn;
-
-                               rt_clip.left   = dis->rcItem.left;
-                               rt_clip.top    = dis->rcItem.top;
-                               rt_clip.right  = dis->rcItem.left+_widths[col];
-                               rt_clip.bottom = dis->rcItem.bottom;
-
-                               hrgn = CreateRectRgnIndirect(&rt_clip);
-
-                               if (!GetClipRgn(dis->hDC, hrgn_org)) {
-                                       DeleteObject(hrgn_org);
-                                       hrgn_org = 0;
-                               }
-
-                               //HGDIOBJ holdPen = SelectObject(dis->hDC, GetStockObject(BLACK_PEN));
-                               ExtSelectClipRgn(dis->hDC, hrgn, RGN_AND);
-                               DeleteObject(hrgn);
-
-                               if ((up=entry->_up) != NULL) {
-                                       MoveToEx(dis->hDC, img_pos-IMAGE_WIDTH/2, y, 0);
-                                       LineTo(dis->hDC, img_pos-2, y);
-
-                                       x = img_pos - IMAGE_WIDTH/2;
-
-                                       do {
-                                               x -= IMAGE_WIDTH+_out_wrkr._spaceSize.cx;
-
-                                               if (up->_next) {
-#ifndef _LEFT_FILES
-                                                       bool following_child = (up->_next->_data.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY)!=0; // a directory?
-
-                                                       if (!following_child)
-                                                               for(Entry*n=up->_next; n; n=n->_next)
-                                                                       if (n->_down) { // any file with NTFS sub-streams?
-                                                                               following_child = true;
-                                                                               break;
-                                                                       }
-
-                                                       if (following_child)
-#endif
-                                                       {
-                                                               MoveToEx(dis->hDC, x, dis->rcItem.top, 0);
-                                                               LineTo(dis->hDC, x, dis->rcItem.bottom);
-                                                       }
-                                               }
-                                       } while((up=up->_up) != NULL);
-                               }
-
-                               x = img_pos - IMAGE_WIDTH/2;
-
-                               MoveToEx(dis->hDC, x, dis->rcItem.top, 0);
-                               LineTo(dis->hDC, x, y);
-
-                               if (entry->_next) {
-#ifndef _LEFT_FILES
-                                       bool following_child = (entry->_next->_data.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY)!=0;      // a directory?
-
-                                       if (!following_child)
-                                               for(Entry*n=entry->_next; n; n=n->_next)
-                                                       if (n->_down) { // any file with NTFS sub-streams?
-                                                               following_child = true;
-                                                               break;
-                                                       }
-
-                                       if (following_child)
-#endif
-                                               LineTo(dis->hDC, x, dis->rcItem.bottom);
-                               }
-
-                               if (entry->_down && entry->_expanded) {
-                                       x += IMAGE_WIDTH + _out_wrkr._spaceSize.cx;
-                                       MoveToEx(dis->hDC, x, dis->rcItem.top+IMAGE_HEIGHT, 0);
-                                       LineTo(dis->hDC, x, dis->rcItem.bottom);
-                               }
-
-                               SelectClipRgn(dis->hDC, hrgn_org);
-                               if (hrgn_org) DeleteObject(hrgn_org);
-                               //SelectObject(dis->hDC, holdPen);
-                       } else if (calcWidthCol==col || calcWidthCol==COLUMNS) {
-                               int right = img_pos + IMAGE_WIDTH - _out_wrkr._spaceSize.cx;
-
-                               if (right > _widths[col])
-                                       _widths[col] = right;
-                       }
-               } else  {
-                       img_pos = dis->rcItem.left;
-               }
-       } else {
-               img_pos = dis->rcItem.left;
-
-               if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       _widths[col] = IMAGE_WIDTH;
-       }
-
-       if (calcWidthCol == -1) {
-               focusRect.left = img_pos -2;
-
-               if (attrs & FILE_ATTRIBUTE_COMPRESSED)
-                       textcolor = _clrCompressed;
-               else
-                       textcolor = RGB(0,0,0);
-
-               if (dis->itemState & ODS_FOCUS) {
-                       textcolor = GetSysColor(COLOR_HIGHLIGHTTEXT);
-                       bkcolor = GetSysColor(COLOR_HIGHLIGHT);
-               } else {
-                       bkcolor = GetSysColor(COLOR_WINDOW);
-               }
-
-               HBRUSH hbrush = CreateSolidBrush(bkcolor);
-               FillRect(dis->hDC, &focusRect, hbrush);
-               DeleteObject(hbrush);
-
-               SetBkMode(dis->hDC, TRANSPARENT);
-               SetTextColor(dis->hDC, textcolor);
-
-               cx = _widths[col];
-
-               if (cx && img!=IMG_NONE) {
-                       if (cx > IMAGE_WIDTH)
-                               cx = IMAGE_WIDTH;
-
-                       if (entry->_icon_id > ICID_NONE)
-                               g_Globals._icon_cache.get_icon(entry->_icon_id).draw(dis->hDC, img_pos, dis->rcItem.top, cx, GetSystemMetrics(SM_CYSMICON), bkcolor, 0);
-                       else
-                               ImageList_DrawEx(_himl, img, dis->hDC,
-                                                                img_pos, dis->rcItem.top, cx,
-                                                                IMAGE_HEIGHT, bkcolor, CLR_DEFAULT, ILD_NORMAL);
-               }
-       }
-
-       if (!entry)
-               return;
-
-       ++col;
-
-        // output file name
-       if (calcWidthCol == -1)
-               _out_wrkr.output_text(dis, _positions, col, entry->_display_name, 0);
-       else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-               calc_width(dis, col, entry->_display_name);
-       ++col;
-
-        // output type/class name
-       if (visible_cols & COL_TYPE) {
-               if (calcWidthCol == -1)
-                       _out_wrkr.output_text(dis, _positions, col, entry->_type_name? entry->_type_name: TEXT(""), 0);
-               else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       calc_width(dis, col, entry->_type_name? entry->_type_name: TEXT(""));
-       }
-       ++col;
-
-        // display file size
-       if (visible_cols & COL_SIZE) {
-               ULONGLONG size = ((ULONGLONG)entry->_data.nFileSizeHigh << 32) | entry->_data.nFileSizeLow;
-
-               _stprintf(buffer, TEXT("%") LONGLONGARG TEXT("d"), size);
-
-               if (calcWidthCol == -1)
-                       _out_wrkr.output_number(dis, _positions, col, buffer);
-               else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       calc_width(dis, col, buffer);   ///@todo not in every case time enough
-       }
-       ++col;
-
-        // display file date
-       if (visible_cols & (COL_DATE|COL_TIME)) {
-               format_date(&entry->_data.ftCreationTime, buffer, visible_cols);
-               if (calcWidthCol == -1)
-                       _out_wrkr.output_text(dis, _positions, col, buffer, 0);
-               else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       calc_width(dis, col, buffer);
-               ++col;
-
-               format_date(&entry->_data.ftLastAccessTime, buffer, visible_cols);
-               if (calcWidthCol == -1)
-                       _out_wrkr.output_text(dis,_positions,  col, buffer, 0);
-               else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       calc_width(dis, col, buffer);
-               ++col;
-
-               format_date(&entry->_data.ftLastWriteTime, buffer, visible_cols);
-               if (calcWidthCol == -1)
-                       _out_wrkr.output_text(dis, _positions, col, buffer, 0);
-               else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       calc_width(dis, col, buffer);
-               ++col;
-       } else
-               col += 3;
-
-       if (entry->_bhfi_valid) {
-               ULONGLONG index = ((ULONGLONG)entry->_bhfi.nFileIndexHigh << 32) | entry->_bhfi.nFileIndexLow;
-
-               if (visible_cols & COL_INDEX) {
-                       _stprintf(buffer, TEXT("%") LONGLONGARG TEXT("X"), index);
-
-                       if (calcWidthCol == -1)
-                               _out_wrkr.output_text(dis, _positions, col, buffer, DT_RIGHT);
-                       else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                               calc_width(dis, col, buffer);
-
-                       ++col;
-               }
-
-               if (visible_cols & COL_LINKS) {
-                       wsprintf(buffer, TEXT("%d"), entry->_bhfi.nNumberOfLinks);
-
-                       if (calcWidthCol == -1)
-                               _out_wrkr.output_text(dis, _positions, col, buffer, DT_RIGHT);
-                       else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                               calc_width(dis, col, buffer);
-
-                       ++col;
-               }
-       } else
-               col += 2;
-
-        // show file attributes
-       if (visible_cols & COL_ATTRIBUTES) {
-               lstrcpy(buffer, TEXT(" \t \t \t \t \t \t \t \t \t \t \t \t \t \t "));
-
-               if (attrs & FILE_ATTRIBUTE_NORMAL)                                      buffer[ 0] = 'N';
-               else {
-                       if (attrs & FILE_ATTRIBUTE_READONLY)                    buffer[ 2] = 'R';
-                       if (attrs & FILE_ATTRIBUTE_HIDDEN)                              buffer[ 4] = 'H';
-                       if (attrs & FILE_ATTRIBUTE_SYSTEM)                              buffer[ 6] = 'S';
-                       if (attrs & FILE_ATTRIBUTE_ARCHIVE)                     buffer[ 8] = 'A';
-                       if (attrs & FILE_ATTRIBUTE_COMPRESSED)                  buffer[10] = 'C';
-                       if (attrs & FILE_ATTRIBUTE_DIRECTORY)                   buffer[12] = 'D';
-                       if (attrs & FILE_ATTRIBUTE_ENCRYPTED)                   buffer[14] = 'E';
-                       if (attrs & FILE_ATTRIBUTE_TEMPORARY)                   buffer[16] = 'T';
-                       if (attrs & FILE_ATTRIBUTE_SPARSE_FILE)                 buffer[18] = 'P';
-                       if (attrs & FILE_ATTRIBUTE_REPARSE_POINT)               buffer[20] = 'Q';
-                       if (attrs & FILE_ATTRIBUTE_OFFLINE)                     buffer[22] = 'O';
-                       if (attrs & FILE_ATTRIBUTE_NOT_CONTENT_INDEXED) buffer[24] = 'X';
-                       if (attrs & ATTRIBUTE_EXECUTABLE)                               buffer[26] = 'x';
-                       if (attrs & ATTRIBUTE_SYMBOLIC_LINK)                    buffer[28] = 'L';
-               }
-
-               if (calcWidthCol == -1)
-                       _out_wrkr.output_tabbed_text(dis, _positions, col, buffer);
-               else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       calc_tabbed_width(dis, col, buffer);
-       }
-       ++col;
-
-/*TODO
-       if (flags.security) {
-               DWORD rights = get_access_mask();
-
-               tcscpy(buffer, TEXT(" \t \t \t  \t  \t \t \t  \t  \t \t \t "));
-
-               if (rights & FILE_READ_DATA)                    buffer[ 0] = 'R';
-               if (rights & FILE_WRITE_DATA)                   buffer[ 2] = 'W';
-               if (rights & FILE_APPEND_DATA)                  buffer[ 4] = 'A';
-               if (rights & FILE_READ_EA)                              {buffer[6] = 'entry'; buffer[ 7] = 'R';}
-               if (rights & FILE_WRITE_EA)                     {buffer[9] = 'entry'; buffer[10] = 'W';}
-               if (rights & FILE_EXECUTE)                              buffer[12] = 'X';
-               if (rights & FILE_DELETE_CHILD)                 buffer[14] = 'D';
-               if (rights & FILE_READ_ATTRIBUTES)              {buffer[16] = 'a'; buffer[17] = 'R';}
-               if (rights & FILE_WRITE_ATTRIBUTES)     {buffer[19] = 'a'; buffer[20] = 'W';}
-               if (rights & WRITE_DAC)                                 buffer[22] = 'C';
-               if (rights & WRITE_OWNER)                               buffer[24] = 'O';
-               if (rights & SYNCHRONIZE)                               buffer[26] = 'S';
-
-               output_text(dis, col++, buffer, DT_LEFT, 3, psize);
-       }
-
-       if (flags.description) {
-               get_description(buffer);
-               output_text(dis, col++, buffer, 0, psize);
-       }
-*/
-       ++col;
-
-        // output content / symbolic link target / comment
-       if (visible_cols & COL_CONTENT) {
-               if (calcWidthCol == -1)
-                       _out_wrkr.output_text(dis, _positions, col, entry->_content? entry->_content: TEXT(""), 0);
-               else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       calc_width(dis, col, entry->_content? entry->_content: TEXT(""));
-       }
-}
-
-
-void Pane::calc_width(LPDRAWITEMSTRUCT dis, int col, LPCTSTR str)
-{
-       RECT rt = {0, 0, 0, 0};
-
-       DrawText(dis->hDC, (LPTSTR)str, -1, &rt, DT_CALCRECT|DT_SINGLELINE|DT_NOPREFIX);
-
-       if (rt.right > _widths[col])
-               _widths[col] = rt.right;
-}
-
-void Pane::calc_tabbed_width(LPDRAWITEMSTRUCT dis, int col, LPCTSTR str)
-{
-       RECT rt = {0, 0, 0, 0};
-
-/*     DRAWTEXTPARAMS dtp = {sizeof(DRAWTEXTPARAMS), 2};
-       DrawTextEx(dis->hDC, (LPTSTR)str, -1, &rt, DT_CALCRECT|DT_SINGLELINE|DT_NOPREFIX|DT_EXPANDTABS|DT_TABSTOP, &dtp);*/
-
-       DrawText(dis->hDC, (LPTSTR)str, -1, &rt, DT_CALCRECT|DT_SINGLELINE|DT_EXPANDTABS|DT_TABSTOP|(2<<8));
-
-       if (rt.right > _widths[col])
-               _widths[col] = rt.right;
-}
-
-
- // insert listbox entries after index idx
-
-int Pane::insert_entries(Entry* dir, int idx)
-{
-       Entry* entry = dir;
-
-       if (!entry)
-               return idx;
-
-       for(; entry; entry=entry->_next) {
-#ifndef _LEFT_FILES
-               if (_treePane &&
-                       !(entry->_data.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY) &&    // not a directory?
-                       !entry->_down)  // not a file with NTFS sub-streams?
-                       continue;
-#endif
-
-                // don't display entries "." and ".." in the left pane
-               if (_treePane && (entry->_data.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY)
-                               && entry->_data.cFileName[0]==TEXT('.'))
-                       if (entry->_data.cFileName[1]==TEXT('\0') ||
-                               (entry->_data.cFileName[1]==TEXT('.') && entry->_data.cFileName[2]==TEXT('\0')))
-                               continue;
-
-               if (idx != -1)
-                       ++idx;
-
-               ListBox_InsertItemData(_hwnd, idx, entry);
-
-               if (_treePane && entry->_expanded)
-                       idx = insert_entries(entry->_down, idx);
-       }
-
-       return idx;
-}
-
-
-void Pane::set_header()
-{
-       HD_ITEM item;
-       int scroll_pos = GetScrollPos(_hwnd, SB_HORZ);
-       int i=0, x=0;
-
-       item.mask = HDI_WIDTH;
-       item.cxy = 0;
-
-       for(; x+_widths[i]<scroll_pos && i<COLUMNS; i++) {
-               x += _widths[i];
-               Header_SetItem(_hwndHeader, i, &item);
-       }
-
-       if (i < COLUMNS) {
-               x += _widths[i];
-               item.cxy = x - scroll_pos;
-               Header_SetItem(_hwndHeader, i++, &item);
-
-               for(; i<COLUMNS; i++) {
-                       item.cxy = _widths[i];
-                       x += _widths[i];
-                       Header_SetItem(_hwndHeader, i, &item);
-               }
-       }
-}
-
-
- // calculate one prefered column width
-
-void Pane::calc_single_width(int col)
-{
-       HFONT hfontOld;
-       int x, cx;
-       int cnt;
-       HDC hdc;
-
-       int entries = ListBox_GetCount(_hwnd);
-
-       _widths[col] = 0;
-
-       hdc = GetDC(_hwnd);
-       hfontOld = SelectFont(hdc, _out_wrkr._hfont);
-
-       for(cnt=0; cnt<entries; cnt++) {
-               Entry* entry = (Entry*) ListBox_GetItemData(_hwnd, cnt);
-
-               DRAWITEMSTRUCT dis;
-
-               dis.CtlType               = 0;
-               dis.CtlID                 = 0;
-               dis.itemID                = 0;
-               dis.itemAction    = 0;
-               dis.itemState     = 0;
-               dis.hwndItem      = _hwnd;
-               dis.hDC                   = hdc;
-               dis.rcItem.left   = 0;
-               dis.rcItem.top    = 0;
-               dis.rcItem.right  = 0;
-               dis.rcItem.bottom = 0;
-               /*dis.itemData    = 0; */
-
-               draw_item(&dis, entry, col);
-       }
-
-       SelectObject(hdc, hfontOld);
-       ReleaseDC(_hwnd, hdc);
-
-       cx = _widths[col];
-
-       if (cx) {
-               cx += 3*_out_wrkr._spaceSize.cx;
-
-               if (cx < IMAGE_WIDTH)
-                       cx = IMAGE_WIDTH;
-       }
-
-       _widths[col] = cx;
-
-       x = _positions[col] + cx;
-
-       for(; col<COLUMNS; ) {
-               _positions[++col] = x;
-               x += _widths[col];
-       }
-
-       ListBox_SetHorizontalExtent(_hwnd, x);
-}
-
-
-int Pane::Notify(int id, NMHDR* pnmh)
-{
-       switch(pnmh->code) {
-               case HDN_TRACK:
-               case HDN_ENDTRACK: {
-                       HD_NOTIFY* phdn = (HD_NOTIFY*) pnmh;
-                       int idx = phdn->iItem;
-                       int dx = phdn->pitem->cxy - _widths[idx];
-                       int i;
-
-                       ClientRect clnt(_hwnd);
-
-                        // move immediate to simulate HDS_FULLDRAG (for now [04/2000] not realy needed with WINELIB)
-                       Header_SetItem(_hwndHeader, idx, phdn->pitem);
-
-                       _widths[idx] += dx;
-
-                       for(i=idx; ++i<=COLUMNS; )
-                               _positions[i] += dx;
-
-                       {
-                               int scroll_pos = GetScrollPos(_hwnd, SB_HORZ);
-                               RECT rt_scr;
-                               RECT rt_clip;
-
-                               rt_scr.left   = _positions[idx+1]-scroll_pos;
-                               rt_scr.top    = 0;
-                               rt_scr.right  = clnt.right;
-                               rt_scr.bottom = clnt.bottom;
-
-                               rt_clip.left   = _positions[idx]-scroll_pos;
-                               rt_clip.top    = 0;
-                               rt_clip.right  = clnt.right;
-                               rt_clip.bottom = clnt.bottom;
-
-                               if (rt_scr.left < 0) rt_scr.left = 0;
-                               if (rt_clip.left < 0) rt_clip.left = 0;
-
-                               ScrollWindowEx(_hwnd, dx, 0, &rt_scr, &rt_clip, 0, 0, SW_INVALIDATE);
-
-                               rt_clip.right = _positions[idx+1];
-                               RedrawWindow(_hwnd, &rt_clip, 0, RDW_INVALIDATE|RDW_UPDATENOW);
-
-                               if (pnmh->code == HDN_ENDTRACK) {
-                                       ListBox_SetHorizontalExtent(_hwnd, _positions[COLUMNS]);
-
-                                       if (GetScrollPos(_hwnd, SB_HORZ) != scroll_pos)
-                                               set_header();
-                               }
-                       }
-
-                       return 0;
-               }
-
-               case HDN_DIVIDERDBLCLICK: {
-                       HD_NOTIFY* phdn = (HD_NOTIFY*) pnmh;
-                       HD_ITEM item;
-
-                       calc_single_width(phdn->iItem);
-                       item.mask = HDI_WIDTH;
-                       item.cxy = _widths[phdn->iItem];
-
-                       Header_SetItem(_hwndHeader, phdn->iItem, &item);
-                       InvalidateRect(_hwnd, 0, TRUE);
-                       break;}
-
-               default:
-                       return super::Notify(id, pnmh);
-       }
-
-       return 0;
-}
-
-
-OutputWorker::OutputWorker()
-{
-       _hfont = CreateFont(-MulDiv(8,GetDeviceCaps(WindowCanvas(0),LOGPIXELSY),72), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, TEXT("MS Sans Serif"));
-}
-
-void OutputWorker::init_output(HWND hwnd)
-{
-       TCHAR b[16];
-
-       WindowCanvas canvas(hwnd);
-
-       if (GetNumberFormat(LOCALE_USER_DEFAULT, 0, TEXT("1000"), 0, b, 16) > 4)
-               _num_sep = b[1];
-       else
-               _num_sep = TEXT('.');
-
-       FontSelection font(canvas, _hfont);
-       GetTextExtentPoint32(canvas, TEXT(" "), 1, &_spaceSize);
-}
-
-
-void OutputWorker::output_text(LPDRAWITEMSTRUCT dis, int* positions, int col, LPCTSTR str, DWORD flags)
-{
-       int x = dis->rcItem.left;
-       RECT rt;
-
-       rt.left   = x+positions[col]+_spaceSize.cx;
-       rt.top    = dis->rcItem.top;
-       rt.right  = x+positions[col+1]-_spaceSize.cx;
-       rt.bottom = dis->rcItem.bottom;
-
-       DrawText(dis->hDC, (LPTSTR)str, -1, &rt, DT_SINGLELINE|DT_NOPREFIX|flags);
-}
-
-void OutputWorker::output_tabbed_text(LPDRAWITEMSTRUCT dis, int* positions, int col, LPCTSTR str)
-{
-       int x = dis->rcItem.left;
-       RECT rt;
-
-       rt.left   = x+positions[col]+_spaceSize.cx;
-       rt.top    = dis->rcItem.top;
-       rt.right  = x+positions[col+1]-_spaceSize.cx;
-       rt.bottom = dis->rcItem.bottom;
-
-/*     DRAWTEXTPARAMS dtp = {sizeof(DRAWTEXTPARAMS), 2};
-       DrawTextEx(dis->hDC, (LPTSTR)str, -1, &rt, DT_SINGLELINE|DT_NOPREFIX|DT_EXPANDTABS|DT_TABSTOP, &dtp);*/
-
-       DrawText(dis->hDC, (LPTSTR)str, -1, &rt, DT_SINGLELINE|DT_EXPANDTABS|DT_TABSTOP|(2<<8));
-}
-
-void OutputWorker::output_number(LPDRAWITEMSTRUCT dis, int* positions, int col, LPCTSTR str)
-{
-       int x = dis->rcItem.left;
-       RECT rt;
-       LPCTSTR s = str;
-       TCHAR b[128];
-       LPTSTR d = b;
-       int pos;
-
-       rt.left   = x+positions[col]+_spaceSize.cx;
-       rt.top    = dis->rcItem.top;
-       rt.right  = x+positions[col+1]-_spaceSize.cx;
-       rt.bottom = dis->rcItem.bottom;
-
-       if (*s)
-               *d++ = *s++;
-
-        // insert number separator characters
-       pos = lstrlen(s) % 3;
-
-       while(*s)
-               if (pos--)
-                       *d++ = *s++;
-               else {
-                       *d++ = _num_sep;
-                       pos = 3;
-               }
-
-       DrawText(dis->hDC, b, d-b, &rt, DT_RIGHT|DT_SINGLELINE|DT_NOPREFIX|DT_END_ELLIPSIS);
-}
-
-
-BOOL Pane::command(UINT cmd)
-{
-       switch(cmd) {
-               case ID_VIEW_NAME:
-                       if (_visible_cols) {
-                               _visible_cols = 0;
-                               calc_widths(true);
-                               set_header();
-                               InvalidateRect(_hwnd, 0, TRUE);
-                               MenuInfo* menu_info = Frame_GetMenuInfo(GetParent(_hwnd));
-                               if (menu_info) {
-                                       CheckMenuItem(menu_info->_hMenuView, ID_VIEW_NAME, MF_BYCOMMAND|MF_CHECKED);
-                                       CheckMenuItem(menu_info->_hMenuView, ID_VIEW_ALL_ATTRIBUTES, MF_BYCOMMAND);
-                                       CheckMenuItem(menu_info->_hMenuView, ID_VIEW_SELECTED_ATTRIBUTES, MF_BYCOMMAND);
-                               }
-                       }
-                       break;
-
-               case ID_VIEW_ALL_ATTRIBUTES:
-                       if (_visible_cols != COL_ALL) {
-                               _visible_cols = COL_ALL;
-                               calc_widths(true);
-                               set_header();
-                               InvalidateRect(_hwnd, 0, TRUE);
-                               MenuInfo* menu_info = Frame_GetMenuInfo(GetParent(_hwnd));
-                               if (menu_info) {
-                                       CheckMenuItem(menu_info->_hMenuView, ID_VIEW_NAME, MF_BYCOMMAND);
-                                       CheckMenuItem(menu_info->_hMenuView, ID_VIEW_ALL_ATTRIBUTES, MF_BYCOMMAND|MF_CHECKED);
-                                       CheckMenuItem(menu_info->_hMenuView, ID_VIEW_SELECTED_ATTRIBUTES, MF_BYCOMMAND);
-                               }
-                       }
-                       break;
-
-               case ID_PREFERED_SIZES: {
-                       calc_widths(true);
-                       set_header();
-                       InvalidateRect(_hwnd, 0, TRUE);
-                       break;}
-
-                       /*@todo more command ids... */
-
-               default:
-                       return FALSE;
-       }
-
-       return TRUE;
-}
-
-MainFrameBase* Pane::get_frame()
-{
-       HWND owner = GetParent(_hwnd);
-
-       return (MainFrameBase*)owner;
-}
diff --git a/reactos/subsys/system/explorer/shell/pane.h b/reactos/subsys/system/explorer/shell/pane.h
deleted file mode 100644 (file)
index 7ec88d0..0000000
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // pane.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#define IDW_TREE_LEFT          3
-#define IDW_TREE_RIGHT         6
-#define IDW_HEADER_LEFT                2
-#define IDW_HEADER_RIGHT       5
-
-
-enum COLUMN_FLAGS {
-       COL_TYPE                = 0x0001,
-       COL_SIZE                = 0x0002,
-       COL_DATE                = 0x0004,
-       COL_TIME                = 0x0008,
-       COL_ATTRIBUTES  = 0x0010,
-       COL_DOSNAMES    = 0x0020,
-       COL_INDEX               = 0x0040,
-       COL_LINKS               = 0x0080,
-       COL_CONTENT             = 0x0100,
-       COL_ALL = COL_TYPE|COL_SIZE|COL_DATE|COL_TIME|COL_ATTRIBUTES|COL_DOSNAMES|COL_INDEX|COL_LINKS|COL_CONTENT
-};
-
-
- /// Worker for drawing contents of file lists in child pane
-struct OutputWorker
-{
-       OutputWorker();
-
-       void    init_output(HWND hwnd);
-       void    output_text(LPDRAWITEMSTRUCT dis, int* positions, int col, LPCTSTR str, DWORD flags);
-       void    output_tabbed_text(LPDRAWITEMSTRUCT dis, int* positions, int col, LPCTSTR str);
-       void    output_number(LPDRAWITEMSTRUCT dis, int* positions, int col, LPCTSTR str);
-
-       SIZE    _spaceSize;
-       TCHAR   _num_sep;
-       HFONT   _hfont;
-};
-
-
- /// child window pane for displaying file lists
-struct Pane : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       Pane(HWND hparent, int id, int id_header, Entry* rool, bool treePane, int visible_cols);
-       ~Pane();
-
-#define COLUMNS 12
-       int     _widths[COLUMNS];
-       int     _positions[COLUMNS+1];
-
-       WindowHandle _hwndHeader;
-
-       Entry*  _root;
-       Entry*  _cur;
-
-       COLORREF _clrCompressed;
-
-       int     _visible_cols;
-       bool    _treePane;
-
-       void    init();
-       void    set_header();
-       bool    create_header(HWND parent, int id);
-
-       bool    calc_widths(bool anyway);
-       void    calc_single_width(int col);
-       void    draw_item(LPDRAWITEMSTRUCT dis, Entry* entry, int calcWidthCol=-1);
-
-       int             insert_entries(Entry* dir, int idx=-1);
-       BOOL    command(UINT cmd);
-       int             Notify(int id, NMHDR* pnmh);
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       void    calc_width(LPDRAWITEMSTRUCT dis, int col, LPCTSTR str);
-       void    calc_tabbed_width(LPDRAWITEMSTRUCT dis, int col, LPCTSTR str);
-       struct MainFrameBase* get_frame();
-
-protected:
-       HIMAGELIST      _himl;
-       OutputWorker _out_wrkr;
-};
-
diff --git a/reactos/subsys/system/explorer/shell/regfs.cpp b/reactos/subsys/system/explorer/shell/regfs.cpp
deleted file mode 100644 (file)
index 32567b6..0000000
+++ /dev/null
@@ -1,309 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // ntobjfs.cpp
- //
- // Martin Fuchs, 31.01.2004
- //
-
-
-#include <precomp.h>
-
-#include "regfs.h"
-
-
-void RegDirectory::read_directory(int scan_flags)
-{
-       CONTEXT("RegDirectory::read_directory()");
-
-       Entry* first_entry = NULL;
-       int level = _level + 1;
-
-       TCHAR buffer[MAX_PATH];
-
-       _tcscpy(buffer, (LPCTSTR)_path);
-       LPTSTR pname = buffer + _tcslen(buffer);
-       int plen = MAX_PATH - _tcslen(buffer);
-
-       HKEY hkey;
-
-       if (!RegOpenKeyEx(_hKeyRoot, *buffer=='\\'?buffer+1:buffer, 0, STANDARD_RIGHTS_READ|KEY_QUERY_VALUE|KEY_ENUMERATE_SUB_KEYS, &hkey)) {
-               if (pname[-1] != '\\')
-                       *pname++ = '\\', plen--;
-
-               TCHAR name[MAX_PATH], class_name[MAX_PATH];
-               WIN32_FIND_DATA w32fd;
-               Entry* last = NULL;
-               RegEntry* entry;
-
-               for(int idx=0; ; ++idx) {
-                       memset(&w32fd, 0, sizeof(WIN32_FIND_DATA));
-
-                       DWORD name_len = MAX_PATH;
-                       DWORD class_len = MAX_PATH;
-
-                       if (RegEnumKeyEx(hkey, idx, name, &name_len, 0, class_name, &class_len, &w32fd.ftLastWriteTime))
-                               break;
-
-                       w32fd.dwFileAttributes |= FILE_ATTRIBUTE_DIRECTORY;
-                       _tcsncpy(w32fd.cFileName, name, name_len);
-
-                       _tcscpy_s(pname, plen, name);
-                       entry = new RegDirectory(this, buffer, _hKeyRoot);
-
-                       memcpy(&entry->_data, &w32fd, sizeof(WIN32_FIND_DATA));
-
-                       if (class_len)
-                               entry->_type_name = _tcsdup(String(class_name, class_len));
-
-                       if (!first_entry)
-                               first_entry = entry;
-
-                       if (last)
-                               last->_next = entry;
-
-                       entry->_level = level;
-
-                       last = entry;
-               }
-/*
-               TCHAR value[MAX_PATH];
-               LONG value_len = sizeof(value);
-
-               if (!RegQueryValue(hkey, NULL, value, &value_len) && value_len>1) {
-                       memset(&w32fd, 0, sizeof(WIN32_FIND_DATA));
-
-                       lstrcpy(w32fd.cFileName, TEXT("(Default)"));
-
-                       entry = new RegEntry(this);
-
-                       memcpy(&entry->_data, &w32fd, sizeof(WIN32_FIND_DATA));
-
-                       entry->_content = _tcsdup(value);
-
-                       if (!first_entry)
-                               first_entry = entry;
-
-                       if (last)
-                               last->_next = entry;
-
-                       entry->_level = level;
-
-                       last = entry;
-               }
-*/
-               DWORD type;
-               for(int idx=0; ; ++idx) {
-                       DWORD name_len = MAX_PATH;
-
-                       if (RegEnumValue(hkey, idx, name, &name_len, 0, &type, NULL, NULL))
-                               break;
-
-                       memset(&w32fd, 0, sizeof(WIN32_FIND_DATA));
-
-                       if (name[0])
-                               lstrcpy(w32fd.cFileName, name);
-                       else
-                               lstrcpy(w32fd.cFileName, TEXT("(Default)"));
-
-                       entry = new RegEntry(this);
-
-                       memcpy(&entry->_data, &w32fd, sizeof(WIN32_FIND_DATA));
-
-                       switch(type) {
-                         case REG_NONE:                                                entry->_type_name = _tcsdup(TEXT("REG_NONE"));                                          break;
-                         case REG_SZ:                                                  entry->_type_name = _tcsdup(TEXT("REG_SZ"));                                            break;
-                         case REG_EXPAND_SZ:                                   entry->_type_name = _tcsdup(TEXT("REG_EXPAND_SZ"));                                     break;
-                         case REG_BINARY:                                              entry->_type_name = _tcsdup(TEXT("REG_BINARY"));                                        break;
-                         case REG_DWORD:                                               entry->_type_name = _tcsdup(TEXT("REG_DWORD"));                                         break;
-                         case REG_DWORD_BIG_ENDIAN:                    entry->_type_name = _tcsdup(TEXT("REG_DWORD_BIG_ENDIAN"));                      break;
-                         case REG_LINK:                                                entry->_type_name = _tcsdup(TEXT("REG_LINK"));                                          break;
-                         case REG_MULTI_SZ:                                    entry->_type_name = _tcsdup(TEXT("REG_MULTI_SZ"));                                      break;
-                         case REG_RESOURCE_LIST:                               entry->_type_name = _tcsdup(TEXT("REG_RESOURCE_LIST"));                         break;
-                         case REG_FULL_RESOURCE_DESCRIPTOR:    entry->_type_name = _tcsdup(TEXT("REG_FULL_RESOURCE_DESCRIPTOR"));      break;
-                         case REG_RESOURCE_REQUIREMENTS_LIST:  entry->_type_name = _tcsdup(TEXT("REG_RESOURCE_REQUIREMENTS_LIST"));break;
-                         case REG_QWORD:                                               entry->_type_name = _tcsdup(TEXT("REG_QWORD"));                                         break;
-                       }
-
-                        ///@todo This can also be done in the RegEnumValue() call if we dynamically adjust the return buffer size.
-                       TCHAR value[MAX_PATH];
-                       DWORD value_len = sizeof(value);
-
-                       if (!RegQueryValueEx(hkey, name, NULL, NULL, (LPBYTE)value, &value_len)) {
-                               if (type==REG_SZ || type==REG_EXPAND_SZ || type==REG_LINK)
-                                       entry->_content = _tcsdup(value);
-                               else if (type == REG_DWORD) {
-                                       TCHAR b[32];
-                                       _stprintf(b, TEXT("%ld"), *(DWORD*)&value);
-                                       entry->_content = _tcsdup(b);
-                               }
-                       }
-
-                       if (!first_entry)
-                               first_entry = entry;
-
-                       if (last)
-                               last->_next = entry;
-
-                       entry->_level = level;
-
-                       last = entry;
-               }
-
-               if (last)
-                       last->_next = NULL;
-
-               RegCloseKey(hkey);
-       }
-
-       _down = first_entry;
-       _scanned = true;
-}
-
-
-const void* RegDirectory::get_next_path_component(const void* p) const
-{
-       LPCTSTR s = (LPCTSTR) p;
-
-       while(*s && *s!=TEXT('\\'))
-               ++s;
-
-       while(*s==TEXT('\\'))
-               ++s;
-
-       if (!*s)
-               return NULL;
-
-       return s;
-}
-
-
-Entry* RegDirectory::find_entry(const void* p)
-{
-       LPCTSTR name = (LPCTSTR)p;
-
-       for(Entry*entry=_down; entry; entry=entry->_next) {
-               LPCTSTR p = name;
-               LPCTSTR q = entry->_data.cFileName;
-
-               do {
-                       if (!*p || *p==TEXT('\\') || *p==TEXT('/'))
-                               return entry;
-               } while(tolower(*p++) == tolower(*q++));
-
-               p = name;
-               q = entry->_data.cAlternateFileName;
-
-               do {
-                       if (!*p || *p==TEXT('\\') || *p==TEXT('/'))
-                               return entry;
-               } while(tolower(*p++) == tolower(*q++));
-       }
-
-       return NULL;
-}
-
-
- // get full path of specified registry entry
-bool RegEntry::get_path(PTSTR path, size_t path_count) const
-{
-       return get_path_base ( path, path_count, ET_REGISTRY );
-}
-
-BOOL RegEntry::launch_entry(HWND hwnd, UINT nCmdShow)
-{
-       return FALSE;
-}
-
-
-RegDirectory::RegDirectory(Entry* parent, LPCTSTR path, HKEY hKeyRoot)
- :     RegEntry(parent),
-       _hKeyRoot(hKeyRoot)
-{
-       _path = _tcsdup(path);
-
-       memset(&_data, 0, sizeof(WIN32_FIND_DATA));
-       _data.dwFileAttributes |= FILE_ATTRIBUTE_DIRECTORY;
-}
-
-
-void RegistryRoot::read_directory(int scan_flags)
-{
-       Entry *entry, *last, *first_entry;
-       int level = _level + 1;
-
-       _data.dwFileAttributes |= FILE_ATTRIBUTE_DIRECTORY;
-
-       entry = new RegDirectory(this, TEXT("\\"), HKEY_CURRENT_USER);
-       _tcscpy(entry->_data.cFileName, TEXT("HKEY_CURRENT_USER"));
-       entry->_level = level;
-
-       first_entry = entry;
-       last = entry;
-
-       entry = new RegDirectory(this, TEXT("\\"), HKEY_LOCAL_MACHINE);
-       _tcscpy(entry->_data.cFileName, TEXT("HKEY_LOCAL_MACHINE"));
-       entry->_level = level;
-
-       last->_next = entry;
-       last = entry;
-
-       entry = new RegDirectory(this, TEXT("\\"), HKEY_CLASSES_ROOT);
-       _tcscpy(entry->_data.cFileName, TEXT("HKEY_CLASSES_ROOT"));
-       entry->_level = level;
-
-       last->_next = entry;
-       last = entry;
-
-       entry = new RegDirectory(this, TEXT("\\"), HKEY_USERS);
-       _tcscpy(entry->_data.cFileName, TEXT("HKEY_USERS"));
-       entry->_level = level;
-
-       last->_next = entry;
-       last = entry;
-/*
-       entry = new RegDirectory(this, TEXT("\\"), HKEY_PERFORMANCE_DATA);
-       _tcscpy(entry->_data.cFileName, TEXT("HKEY_PERFORMANCE_DATA"));
-       entry->_level = level;
-
-       last->_next = entry;
-       last = entry;
-*/
-       entry = new RegDirectory(this, TEXT("\\"), HKEY_CURRENT_CONFIG);
-       _tcscpy(entry->_data.cFileName, TEXT("HKEY_CURRENT_CONFIG"));
-       entry->_level = level;
-
-       last->_next = entry;
-       last = entry;
-/*
-       entry = new RegDirectory(this, TEXT("\\"), HKEY_DYN_DATA);
-       _tcscpy(entry->_data.cFileName, TEXT("HKEY_DYN_DATA"));
-       entry->_level = level;
-
-       last->_next = entry;
-       last = entry;
-*/
-       last->_next = NULL;
-
-       _down = first_entry;
-       _scanned = true;
-}
diff --git a/reactos/subsys/system/explorer/shell/regfs.h b/reactos/subsys/system/explorer/shell/regfs.h
deleted file mode 100644 (file)
index 44598fc..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // regfs.h
- //
- // Martin Fuchs, 31.01.2004
- //
-
-
- /// Registry entry
-struct RegEntry : public Entry
-{
-       RegEntry(Entry* parent) : Entry(parent, ET_REGISTRY) {}
-
-protected:
-       RegEntry() : Entry(ET_REGISTRY) {}
-
-       virtual bool get_path(PTSTR path, size_t path_count) const;
-       virtual BOOL launch_entry(HWND hwnd, UINT nCmdShow);
-};
-
-
- /// Registry key entry
-struct RegDirectory : public RegEntry, public Directory
-{
-       RegDirectory(Entry* parent, LPCTSTR path, HKEY hKeyRoot);
-
-       ~RegDirectory()
-       {
-               free(_path);
-               _path = NULL;
-       }
-
-       virtual void read_directory(int scan_flags=0);
-       virtual const void* get_next_path_component(const void*) const;
-       virtual Entry* find_entry(const void*);
-
-protected:
-       HKEY    _hKeyRoot;
-};
-
-
- /// Registry key entry
-struct RegistryRoot : public RegEntry, public Directory
-{
-       RegistryRoot()
-       {
-       }
-
-       RegistryRoot(Entry* parent, LPCTSTR path)
-        :      RegEntry(parent)
-       {
-               _path = _tcsdup(path);
-       }
-
-       ~RegistryRoot()
-       {
-               free(_path);
-               _path = NULL;
-       }
-
-       virtual void read_directory(int scan_flags=0);
-};
diff --git a/reactos/subsys/system/explorer/shell/shellbrowser.cpp b/reactos/subsys/system/explorer/shell/shellbrowser.cpp
deleted file mode 100644 (file)
index 09904e2..0000000
+++ /dev/null
@@ -1,751 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005, 2006 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // shellbrowser.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include <precomp.h>
-
-#include "../resource.h"
-
-
- // work around GCC's wide string constant bug
-#ifdef __GNUC__
-const LPCTSTR C_DRIVE = C_DRIVE_STR;
-#endif
-
-
-ShellBrowser::ShellBrowser(HWND hwnd, HWND hwndFrame, HWND left_hwnd, WindowHandle& right_hwnd, ShellPathInfo& create_info,
-                                                       BrowserCallback* cb, CtxMenuInterfaces& cm_ifs)
-#ifndef __MINGW32__    // IShellFolderViewCB missing in MinGW (as of 25.09.2005)
- :     super(IID_IShellFolderViewCB),
-#else
- :     
-#endif
-       _hwnd(hwnd),
-       _hwndFrame(hwndFrame),
-       _left_hwnd(left_hwnd),
-       _right_hwnd(right_hwnd),
-       _create_info(create_info),
-       _callback(cb),
-       _cm_ifs(cm_ifs)
-{
-       _pShellView = NULL;
-       _pDropTarget = NULL;
-       _last_sel = 0;
-
-       _cur_dir = NULL;
-
-       _himl = ImageList_Create(GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), ILC_MASK|ILC_COLOR24, 2, 0);
-       ImageList_SetBkColor(_himl, GetSysColor(COLOR_WINDOW));
-}
-
-ShellBrowser::~ShellBrowser()
-{
-       (void)TreeView_SetImageList(_left_hwnd, _himl_old, TVSIL_NORMAL);
-       ImageList_Destroy(_himl);
-
-       if (_pShellView)
-               _pShellView->Release();
-
-       if (_pDropTarget) {
-               _pDropTarget->Release();
-               _pDropTarget = NULL;
-       }
-
-       if (_right_hwnd) {
-               DestroyWindow(_right_hwnd);
-               _right_hwnd = 0;
-       }
-}
-
-
-void ShellBrowser::Init()
-{
-       CONTEXT("ShellBrowser::Init()");
-
-       const String& root_name = GetDesktopFolder().get_name(_create_info._root_shell_path, SHGDN_FORADDRESSBAR);
-
-       _root._drive_type = DRIVE_UNKNOWN;
-       lstrcpy(_root._volname, root_name);
-       _root._fs_flags = 0;
-       lstrcpy(_root._fs, TEXT("Desktop"));
-
-       _root._entry = new ShellDirectory(GetDesktopFolder(), _create_info._root_shell_path, _hwnd);
-
-       _root._entry->read_directory(SCAN_DONT_ACCESS|SCAN_NO_FILESYSTEM);      // avoid to handle desktop root folder as file system directory
-
-       if (_left_hwnd) {
-               InitializeTree();
-               InitDragDrop();
-       }
-
-       jump_to(_create_info._shell_path);
-
-       /* already filled by ShellDirectory constructor
-       lstrcpy(_root._entry->_data.cFileName, TEXT("Desktop")); */
-}
-
-void ShellBrowser::jump_to(LPCITEMIDLIST pidl)
-{
-       Entry* entry = NULL;
-
-       if (!_cur_dir)
-               _cur_dir = static_cast<ShellDirectory*>(_root._entry);
-
-       //LOG(FmtString(TEXT("ShellBrowser::jump_to(): pidl=%s"), (LPCTSTR)FileSysShellPath(pidl)));
-
-        // We could call read_tree() here to iterate through the hierarchy and open all folders
-        // from _create_info._root_shell_path (_cur_dir) to _create_info._shell_path (pidl).
-        // To make it easier we just use ILFindChild() instead.
-       if (_cur_dir) {
-               static DynamicFct<LPITEMIDLIST(WINAPI*)(LPCITEMIDLIST, LPCITEMIDLIST)> ILFindChild(TEXT("SHELL32"), 24);
-
-               if (ILFindChild) {
-                       for(;;) {
-                               LPCITEMIDLIST child_pidl = (*ILFindChild)(_cur_dir->create_absolute_pidl(), pidl);
-                               if (!child_pidl || !child_pidl->mkid.cb)
-                                       break;
-
-                               _cur_dir->smart_scan(SORT_NAME, SCAN_DONT_ACCESS);
-
-                               entry = _cur_dir->find_entry(child_pidl);
-                               if (!entry)
-                                       break;
-
-                               _cur_dir = static_cast<ShellDirectory*>(entry);
-                               _callback->entry_selected(entry);
-                       }
-               } else {
-                       _cur_dir->smart_scan(SORT_NAME, SCAN_DONT_ACCESS);
-
-                       entry = _cur_dir->find_entry(pidl);     // This is not correct in the common case, but works on the desktop level.
-
-                       if (entry) {
-                               _cur_dir = static_cast<ShellDirectory*>(entry);
-                               _callback->entry_selected(entry);
-                       }
-               }
-       }
-
-        // If not already called, now directly call UpdateFolderView() using pidl
-       if (!entry)
-               UpdateFolderView(ShellFolder(pidl));
-}
-
-
-void ShellBrowser::InitializeTree()
-{
-       CONTEXT("ShellBrowserChild::InitializeTree()");
-
-       _himl_old = TreeView_SetImageList(_left_hwnd, _himl, TVSIL_NORMAL);
-       TreeView_SetScrollTime(_left_hwnd, 100);
-
-       TV_INSERTSTRUCT tvInsert;
-       TV_ITEM& tvItem = tvInsert.item;
-
-       tvInsert.hParent = 0;
-       tvInsert.hInsertAfter = TVI_LAST;
-
-       tvItem.mask = TVIF_PARAM | TVIF_TEXT | TVIF_IMAGE | TVIF_SELECTEDIMAGE | TVIF_CHILDREN;
-       tvItem.lParam = (LPARAM)_root._entry;
-       tvItem.pszText = _root._volname; //LPSTR_TEXTCALLBACK;
-       tvItem.iImage = tvItem.iSelectedImage = I_IMAGECALLBACK;
-       tvItem.cChildren = 1;
-
-       HTREEITEM hItem = TreeView_InsertItem(_left_hwnd, &tvInsert);
-       TreeView_SelectItem(_left_hwnd, hItem);
-       TreeView_Expand(_left_hwnd, hItem, TVE_EXPAND);
-}
-
-bool ShellBrowser::InitDragDrop()
-{
-       CONTEXT("ShellBrowser::InitDragDrop()");
-
-       _pDropTarget = new TreeDropTarget(_left_hwnd);
-
-       if (!_pDropTarget)
-               return false;
-
-       _pDropTarget->AddRef();
-
-       if (FAILED(RegisterDragDrop(_left_hwnd, _pDropTarget))) {//calls addref
-               _pDropTarget->Release(); // free TreeDropTarget
-               _pDropTarget = NULL;
-               return false;
-       } else
-               _pDropTarget->Release();
-
-       FORMATETC ftetc;
-
-       ftetc.dwAspect = DVASPECT_CONTENT;
-       ftetc.lindex = -1;
-       ftetc.tymed = TYMED_HGLOBAL;
-       ftetc.cfFormat = CF_HDROP;
-
-       _pDropTarget->AddSuportedFormat(ftetc);
-
-       return true;
-}
-
-
-void ShellBrowser::OnTreeGetDispInfo(int idCtrl, LPNMHDR pnmh)
-{
-       CONTEXT("ShellBrowser::OnTreeGetDispInfo()");
-
-       LPNMTVDISPINFO lpdi = (LPNMTVDISPINFO)pnmh;
-       ShellEntry* entry = (ShellEntry*)lpdi->item.lParam;
-
-       if (entry) {
-               if (lpdi->item.mask & TVIF_TEXT)
-                       lpdi->item.pszText = entry->_display_name;
-
-               if (lpdi->item.mask & (TVIF_IMAGE|TVIF_SELECTEDIMAGE)) {
-                       if (lpdi->item.mask & TVIF_IMAGE)
-                               lpdi->item.iImage = get_image_idx(
-                                               entry->safe_extract_icon((ICONCACHE_FLAGS)(ICF_HICON|ICF_OVERLAYS)));
-
-                       if (lpdi->item.mask & TVIF_SELECTEDIMAGE)
-                               lpdi->item.iSelectedImage = get_image_idx(
-                                               entry->safe_extract_icon((ICONCACHE_FLAGS)(ICF_HICON|ICF_OVERLAYS|ICF_OPEN)));
-               }
-       }
-}
-
-int ShellBrowser::get_image_idx(int icon_id)
-{
-       if (icon_id != ICID_NONE) {
-               map<int,int>::const_iterator found = _image_map.find(icon_id);
-
-               if (found != _image_map.end())
-                       return found->second;
-
-               int idx = ImageList_AddIcon(_himl, g_Globals._icon_cache.get_icon(icon_id).get_hicon());
-
-               _image_map[icon_id] = idx;
-
-               return idx;
-       } else
-               return -1;
-}
-
-void ShellBrowser::invalidate_cache()
-{
-       (void)TreeView_SetImageList(_left_hwnd, _himl_old, TVSIL_NORMAL);
-       ImageList_Destroy(_himl);
-
-       _himl_old = TreeView_SetImageList(_left_hwnd, _himl, TVSIL_NORMAL);
-       _himl = ImageList_Create(GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), ILC_MASK|ILC_COLOR24, 2, 0);
-
-       for(map<int,int>::const_iterator it=_image_map.begin(); it!=_image_map.end(); ++it)
-               g_Globals._icon_cache.free_icon(it->first);
-
-       _image_map.clear();
-}
-
-
-void ShellBrowser::OnTreeItemExpanding(int idCtrl, LPNMTREEVIEW pnmtv)
-{
-       CONTEXT("ShellBrowser::OnTreeItemExpanding()");
-
-       if (pnmtv->action == TVE_COLLAPSE)
-        TreeView_Expand(_left_hwnd, pnmtv->itemNew.hItem, TVE_COLLAPSE|TVE_COLLAPSERESET);
-    else if (pnmtv->action == TVE_EXPAND) {
-               ShellDirectory* entry = (ShellDirectory*)TreeView_GetItemData(_left_hwnd, pnmtv->itemNew.hItem);
-
-               if (entry)
-                       if (!InsertSubitems(pnmtv->itemNew.hItem, entry, entry->_folder)) {
-                               entry->_shell_attribs &= ~SFGAO_HASSUBFOLDER;
-
-                                // remove subitem "+"
-                               TV_ITEM tvItem;
-
-                               tvItem.mask = TVIF_CHILDREN;
-                               tvItem.hItem = pnmtv->itemNew.hItem;
-                               tvItem.cChildren = 0;
-
-                               TreeView_SetItem(_left_hwnd, &tvItem);
-                       }
-       }
-}
-
-int ShellBrowser::InsertSubitems(HTREEITEM hParentItem, Entry* entry, IShellFolder* pParentFolder)
-{
-       CONTEXT("ShellBrowser::InsertSubitems()");
-
-       WaitCursor wait;
-
-       int cnt = 0;
-
-       SendMessage(_left_hwnd, WM_SETREDRAW, FALSE, 0);
-
-       try {
-               entry->smart_scan(SORT_NAME, SCAN_DONT_ACCESS);
-       } catch(COMException& e) {
-               HandleException(e, g_Globals._hMainWnd);
-       }
-
-        // remove old children items
-       HTREEITEM hchild, hnext;
-
-       hnext = TreeView_GetChild(_left_hwnd, hParentItem);
-
-       while((hchild=hnext) != 0) {
-               hnext = TreeView_GetNextSibling(_left_hwnd, hchild);
-               TreeView_DeleteItem(_left_hwnd, hchild);
-       }
-
-       TV_ITEM tvItem;
-       TV_INSERTSTRUCT tvInsert;
-
-       for(entry=entry->_down; entry; entry=entry->_next) {
-#ifndef _LEFT_FILES
-               if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-#endif
-               {
-                        // ignore hidden directories
-                       if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_HIDDEN)
-                               continue;
-
-                        // ignore directory entries "." and ".."
-                       if (entry->_data.cFileName[0]==TEXT('.') &&
-                               (entry->_data.cFileName[1]==TEXT('\0') ||
-                               (entry->_data.cFileName[1]==TEXT('.') && entry->_data.cFileName[2]==TEXT('\0'))))
-                               continue;
-
-                       ZeroMemory(&tvItem, sizeof(tvItem));
-
-                       tvItem.mask = TVIF_PARAM | TVIF_TEXT | TVIF_IMAGE | TVIF_SELECTEDIMAGE | TVIF_CHILDREN;
-                       tvItem.pszText = LPSTR_TEXTCALLBACK;
-                       tvItem.iImage = tvItem.iSelectedImage = I_IMAGECALLBACK;
-                       tvItem.lParam = (LPARAM)entry;
-                       tvItem.cChildren = entry->_shell_attribs & SFGAO_HASSUBFOLDER? 1: 0;
-
-                       if (entry->_shell_attribs & SFGAO_SHARE) {
-                               tvItem.mask |= TVIF_STATE;
-                               tvItem.stateMask |= TVIS_OVERLAYMASK;
-                               tvItem.state |= INDEXTOOVERLAYMASK(1);
-                       }
-
-                       tvInsert.item = tvItem;
-                       tvInsert.hInsertAfter = TVI_LAST;
-                       tvInsert.hParent = hParentItem;
-
-                       (void)TreeView_InsertItem(_left_hwnd, &tvInsert);
-
-                       ++cnt;
-               }
-       }
-
-       SendMessage(_left_hwnd, WM_SETREDRAW, TRUE, 0);
-
-       return cnt;
-}
-
-
-void ShellBrowser::OnTreeItemSelected(int idCtrl, LPNMTREEVIEW pnmtv)
-{
-       CONTEXT("ShellBrowser::OnTreeItemSelected()");
-
-       Entry* entry = (Entry*)pnmtv->itemNew.lParam;
-
-       _last_sel = pnmtv->itemNew.hItem;
-
-       if (entry)
-               _callback->entry_selected(entry);
-}
-
-
-void ShellBrowser::OnTreeItemRClick(int idCtrl, LPNMHDR pnmh)
-{
-       CONTEXT("ShellBrowser::OnTreeItemRClick()");
-
-       TVHITTESTINFO tvhti;
-
-       GetCursorPos(&tvhti.pt);
-       ScreenToClient(_left_hwnd, &tvhti.pt);
-
-       tvhti.flags = LVHT_NOWHERE;
-       (void)TreeView_HitTest(_left_hwnd, &tvhti);
-
-       if (TVHT_ONITEM & tvhti.flags) {
-               LPARAM itemData = TreeView_GetItemData(_left_hwnd, tvhti.hItem);
-
-               if (itemData) {
-                       Entry* entry = (Entry*)itemData;
-                       ClientToScreen(_left_hwnd, &tvhti.pt);
-
-                       CHECKERROR(entry->do_context_menu(_hwnd, tvhti.pt, _cm_ifs));
-               }
-       }
-}
-
-
-void ShellBrowser::UpdateFolderView(IShellFolder* folder)
-{
-       CONTEXT("ShellBrowser::UpdateFolderView()");
-
-       FOLDERSETTINGS fs;
-       IShellView* pLastShellView = _pShellView;
-
-       _folder = folder;
-
-       if (pLastShellView)
-               pLastShellView->GetCurrentInfo(&fs);
-       else {
-               fs.ViewMode = _create_info._open_mode&OWM_DETAILS? FVM_DETAILS: FVM_ICON;
-               fs.fFlags = FWF_NOCLIENTEDGE|FWF_BESTFITWINDOW;
-       }
-
-#ifndef __MINGW32__    // IShellFolderViewCB missing in MinGW (as of 25.09.2005)
-       SFV_CREATE sfv_create;
-
-       sfv_create.cbSize = sizeof(SFV_CREATE);
-       sfv_create.pshf = folder;
-       sfv_create.psvOuter = NULL;
-       sfv_create.psfvcb = this;
-
-       HRESULT hr = SHCreateShellFolderView(&sfv_create, &_pShellView);
-#else
-       HRESULT hr = folder->CreateViewObject(_hwnd, IID_IShellView, (void**)&_pShellView);
-#endif
-
-       if (FAILED(hr)) {
-               _pShellView = NULL;
-               return;
-       }
-
-       RECT rect = {CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT};
-       hr = _pShellView->CreateViewWindow(pLastShellView, &fs, static_cast<IShellBrowser*>(this), &rect, &_right_hwnd/*&m_hWndListView*/);
-
-       if (pLastShellView) {
-               pLastShellView->GetCurrentInfo(&fs);
-               pLastShellView->UIActivate(SVUIA_DEACTIVATE);
-               pLastShellView->DestroyViewWindow();
-               pLastShellView->Release();
-       }
-
-       _pShellView->UIActivate(SVUIA_ACTIVATE_NOFOCUS);
-}
-
-
-#ifndef __MINGW32__    // IShellFolderViewCB missing in MinGW (as of 25.09.2005)
-
- /// shell view callback
-HRESULT STDMETHODCALLTYPE ShellBrowser::MessageSFVCB(UINT uMsg, WPARAM wParam, LPARAM lParam)
-{
-       if (uMsg == SFVM_INITMENUPOPUP) {
-               //@todo never reached
-               InsertMenu((HMENU)lParam, 0, MF_BYPOSITION, 12345, TEXT("TEST ENTRY"));
-               return S_OK;
-       }
-
-       return E_NOTIMPL;
-}
-
-#endif
-
-
-HRESULT ShellBrowser::OnDefaultCommand(LPIDA pida)
-{
-       CONTEXT("ShellBrowser::OnDefaultCommand()");
-
-       if (pida->cidl >= 1) {
-               if (_left_hwnd) {       // explorer mode
-                       if (_last_sel) {
-                               ShellDirectory* parent = (ShellDirectory*)TreeView_GetItemData(_left_hwnd, _last_sel);
-
-                               if (parent) {
-                                       try {
-                                               parent->smart_scan(SORT_NAME, SCAN_DONT_ACCESS);
-                                       } catch(COMException& e) {
-                                               return e.Error();
-                                       }
-
-                                       UINT firstOffset = pida->aoffset[1];
-                                       LPITEMIDLIST pidl = (LPITEMIDLIST)((LPBYTE)pida+firstOffset);
-
-                                       Entry* entry = parent->find_entry(pidl);
-
-                                       if (entry && (entry->_data.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY))
-                                               if (entry->_etype == ET_SHELL)
-                                                       if (_last_sel && select_entry(_last_sel, entry))
-                                                               return S_OK;
-
-                                       //@todo look for hidden or new subfolders and refresh/add new entry instead of opening a new window
-                                       return E_NOTIMPL;
-                               }
-                       }
-               } else { // no tree control
-                       if (MainFrameBase::OpenShellFolders(pida, _hwndFrame))
-                               return S_OK;
-
-/* create new Frame Window
-                       if (MainFrame::OpenShellFolders(pida, 0))
-                               return S_OK;
-*/
-               }
-       }
-
-       return E_NOTIMPL;
-}
-
-
-HTREEITEM ShellBrowser::select_entry(HTREEITEM hitem, Entry* entry, bool expand)
-{
-       CONTEXT("ShellBrowser::select_entry()");
-
-       if (expand && !TreeView_Expand(_left_hwnd, hitem, TVE_EXPAND))
-               return 0;
-
-       for(hitem=TreeView_GetChild(_left_hwnd,hitem); hitem; hitem=TreeView_GetNextSibling(_left_hwnd,hitem)) {
-               if ((Entry*)TreeView_GetItemData(_left_hwnd,hitem) == entry) {
-                       if (TreeView_SelectItem(_left_hwnd, hitem)) {
-                               if (expand)
-                                       TreeView_Expand(_left_hwnd, hitem, TVE_EXPAND);
-
-                               return hitem;
-                       }
-
-                       break;
-               }
-       }
-
-       return 0;
-}
-
-
-bool ShellBrowser::jump_to_pidl(LPCITEMIDLIST pidl)
-{
-       if (!_root._entry)
-               return false;
-
-        // iterate through the hierarchy and open all folders to reach pidl
-       WaitCursor wait;
-
-       HTREEITEM hitem = TreeView_GetRoot(_left_hwnd);
-       Entry* entry = _root._entry;
-
-       for(const void*p=pidl;;) {
-               if (!p)
-                       return true;
-
-               if (!entry || !hitem)
-                       break;
-
-               entry->smart_scan(SORT_NAME, SCAN_DONT_ACCESS);
-
-               Entry* found = entry->find_entry(p);
-               p = entry->get_next_path_component(p);
-
-               if (found)
-                       hitem = select_entry(hitem, found);
-
-               entry = found;
-       }
-
-       return false;
-}
-
-
-bool ShellBrowser::select_folder(Entry* entry, bool expand)
-{
-       CONTEXT("ShellBrowser::expand_folder()");
-
-       if (!_last_sel)
-               return false;
-
-       if (!TreeView_Expand(_left_hwnd, _last_sel, TVE_EXPAND))
-               return false;
-
-       for(HTREEITEM hitem=TreeView_GetChild(_left_hwnd,_last_sel); hitem; hitem=TreeView_GetNextSibling(_left_hwnd,hitem)) {
-               if ((ShellDirectory*)TreeView_GetItemData(_left_hwnd,hitem) == entry) {
-                       if (TreeView_SelectItem(_left_hwnd, hitem)) {
-                               if (expand)
-                                       if (!TreeView_Expand(_left_hwnd, hitem, TVE_EXPAND))
-                                               return false;
-
-                               return true;
-                       }
-
-                       break;
-               }
-       }
-
-       return false;
-}
-
-
-#ifndef _NO_MDI
-
-MDIShellBrowserChild::MDIShellBrowserChild(HWND hwnd, const ShellChildWndInfo& info)
- :     super(hwnd, info),
-       _create_info(info),
-       _shellpath_info(info)   //@@ copies info -> no reference to _create_info !
-{
-/**todo Conversion of shell path into path string -> store into URL history
-       const String& path = GetDesktopFolder().get_name(info._shell_path, SHGDN_FORADDRESSBAR);
-       const String& parsingpath = GetDesktopFolder().get_name(info._shell_path, SHGDN_FORPARSING);
-
-        // store path into history
-       if (info._path && *info._path)
-               _url_history.push(info._path);
-*/
-}
-
-
-MDIShellBrowserChild* MDIShellBrowserChild::create(const ShellChildWndInfo& info)
-{
-       ChildWindow* child = ChildWindow::create(info, info._pos.rcNormalPosition,
-               WINDOW_CREATOR_INFO(MDIShellBrowserChild,ShellChildWndInfo), CLASSNAME_CHILDWND, NULL, info._pos.showCmd==SW_SHOWMAXIMIZED? WS_MAXIMIZE: 0);
-
-       return static_cast<MDIShellBrowserChild*>(child);
-}
-
-
-LRESULT MDIShellBrowserChild::Init(LPCREATESTRUCT pcs)
-{
-       CONTEXT("MDIShellBrowserChild::Init()");
-
-       if (super::Init(pcs))
-               return 1;
-
-       update_shell_browser();
-
-       return 0;
-}
-
-
-LRESULT MDIShellBrowserChild::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case PM_DISPATCH_COMMAND: {
-               switch(LOWORD(wparam)) {
-                 case ID_WINDOW_NEW: {CONTEXT("MDIShellBrowserChild PM_DISPATCH_COMMAND ID_WINDOW_NEW");
-                       MDIShellBrowserChild::create(_create_info);
-                       break;}
-
-                 case ID_REFRESH:
-                       //@todo refresh shell child
-                       _shellBrowser->invalidate_cache();
-                       break;
-
-                 case ID_VIEW_SDI:
-                       MainFrameBase::Create(ExplorerCmd(_url, false));
-                       break;
-
-                 default:
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-               return TRUE;}
-       
-         default:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-void MDIShellBrowserChild::update_shell_browser()
-{
-       int split_pos = DEFAULT_SPLIT_POS;
-
-       if (_shellBrowser.get()) {
-               split_pos = _split_pos;
-               delete _shellBrowser.release();
-       }
-
-        // create explorer treeview
-       if (_create_info._open_mode & OWM_EXPLORE) {
-               if (!_left_hwnd) {
-                       ClientRect rect(_hwnd);
-
-                       _left_hwnd = CreateWindowEx(0, WC_TREEVIEW, NULL,
-                                                       WS_CHILD|WS_TABSTOP|WS_VISIBLE|TVS_HASLINES|TVS_LINESATROOT|TVS_HASBUTTONS|TVS_SHOWSELALWAYS,//|TVS_NOTOOLTIPS
-                                                       0, rect.top, split_pos-SPLIT_WIDTH/2, rect.bottom-rect.top,
-                                                       _hwnd, (HMENU)IDC_FILETREE, g_Globals._hInstance, 0);
-               }
-       } else {
-               if (_left_hwnd) {
-                       DestroyWindow(_left_hwnd);
-                       _left_hwnd = 0;
-               }
-       }
-
-       _shellBrowser = auto_ptr<ShellBrowser>(new ShellBrowser(_hwnd, _hwndFrame, _left_hwnd, _right_hwnd,
-                                                                                               _shellpath_info, this, _cm_ifs));
-
-       _shellBrowser->Init();
-}
-
-
-String MDIShellBrowserChild::jump_to_int(LPCTSTR url)
-{
-       String dir, fname;
-
-       if (!_tcsnicmp(url, TEXT("shell://"), 8)) {
-               if (_shellBrowser->jump_to_pidl(ShellPath(url+8)))
-                       return url;
-       }
-
-       if (SplitFileSysURL(url, dir, fname)) {
-
-               ///@todo use fname
-
-               if (_shellBrowser->jump_to_pidl(ShellPath(dir)))
-                       return FmtString(TEXT("file://%s"), (LPCTSTR)dir);
-       }
-       
-       return String();
-}
-
-
-void MDIShellBrowserChild::entry_selected(Entry* entry)
-{
-       if (_left_hwnd)
-               _shellBrowser->select_folder(entry, false);
-
-       _shellBrowser->UpdateFolderView(entry->get_shell_folder());
-
-        // set size of new created shell view windows
-       ClientRect rt(_hwnd);
-       resize_children(rt.right, rt.bottom);
-
-        // set new URL
-       TCHAR path[MAX_PATH];
-
-       if (entry->get_path(path, COUNTOF(path))) {
-               String url;
-
-               if (path[0] == ':')
-                       url.printf(TEXT("shell://%s"), path);
-               else
-                       url.printf(TEXT("file://%s"), path);
-
-               set_url(url);
-       }
-}
-
-#endif
diff --git a/reactos/subsys/system/explorer/shell/shellbrowser.h b/reactos/subsys/system/explorer/shell/shellbrowser.h
deleted file mode 100644 (file)
index 1de9369..0000000
+++ /dev/null
@@ -1,274 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // shellbrowser.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-#include "../utility/treedroptarget.h"
-#include "../utility/shellbrowserimpl.h"
-
-
- /// information structure to hold current shell folder information
-struct ShellPathInfo
-{
-       ShellPathInfo(int mode=0) : _open_mode(mode) {}
-
-       ShellPathInfo(const ShellChildWndInfo& info)
-        :      _shell_path(info._shell_path),
-               _root_shell_path(info._root_shell_path),
-               _open_mode(info._open_mode)
-       {
-       }
-
-       ShellPath       _shell_path;
-       ShellPath       _root_shell_path;
-
-       int                     _open_mode;     //OPEN_WINDOW_MODE
-};
-
-
-struct BrowserCallback
-{
-       virtual ~BrowserCallback() {}
-       virtual void entry_selected(Entry* entry) = 0;
-};
-
-
- /// Implementation of IShellBrowserImpl interface in explorer child windows
-struct ShellBrowser : public IShellBrowserImpl
-#ifndef __MINGW32__    // IShellFolderViewCB missing in MinGW (as of 25.09.2005)
-       ,       public IComSrvBase<IShellFolderViewCB, ShellBrowser>, public SimpleComObject
-#endif
-{
-       ShellBrowser(HWND hwnd, HWND hwndFrame, HWND left_hwnd, WindowHandle& right_hwnd, ShellPathInfo& create_info,
-                                       BrowserCallback* cb, CtxMenuInterfaces& cm_ifs);
-       virtual ~ShellBrowser();
-
-       //IOleWindow
-       virtual HRESULT STDMETHODCALLTYPE GetWindow(HWND* lphwnd)
-       {
-               *lphwnd = _hwnd;
-               return S_OK;
-       }
-
-       //IShellBrowser
-       virtual HRESULT STDMETHODCALLTYPE QueryActiveShellView(IShellView** ppshv)
-       {
-               _pShellView->AddRef();
-               *ppshv = _pShellView;
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE GetControlWindow(UINT id, HWND* lphwnd)
-       {
-               if (!lphwnd)
-                       return E_POINTER;
-
-               if (id == FCW_TREE) {
-                       *lphwnd = _left_hwnd;
-                       return S_OK;
-               }
-
-               HWND hwnd = (HWND)SendMessage(_hwndFrame, PM_GET_CONTROLWINDOW, id, 0);
-
-               if (hwnd) {
-                       *lphwnd = hwnd;
-                       return S_OK;
-               }
-
-               return E_NOTIMPL;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE SendControlMsg(UINT id, UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* pret)
-       {
-               if (!pret)
-                       return E_POINTER;
-
-               HWND hstatusbar = (HWND)SendMessage(_hwndFrame, PM_GET_CONTROLWINDOW, id, 0);
-
-               if (hstatusbar) {
-                       *pret = ::SendMessage(hstatusbar, uMsg, wParam, lParam);
-                       return S_OK;
-               }
-
-               return E_NOTIMPL;
-       }
-
-       const Root& get_root() const {return _root;}
-
-       void    OnTreeGetDispInfo(int idCtrl, LPNMHDR pnmh);
-       void    OnTreeItemExpanding(int idCtrl, LPNMTREEVIEW pnmtv);
-       void    OnTreeItemRClick(int idCtrl, LPNMHDR pnmh);
-       void    OnTreeItemSelected(int idCtrl, LPNMTREEVIEW pnmtv);
-
-       void    Init();
-
-       int             InsertSubitems(HTREEITEM hParentItem, Entry* entry, IShellFolder* pParentFolder);
-
-       bool    jump_to_pidl(LPCITEMIDLIST pidl);
-
-       HRESULT OnDefaultCommand(LPIDA pida);
-
-       void    UpdateFolderView(IShellFolder* folder);
-       HTREEITEM select_entry(HTREEITEM hitem, Entry* entry, bool expand=true);
-
-       bool    select_folder(Entry* entry, bool expand);
-
-        // for SDIMainFrame
-       void    jump_to(LPCITEMIDLIST pidl);
-
-       void    invalidate_cache();
-
-protected:
-       HWND                    _hwnd;
-       HWND                    _hwndFrame;
-       HWND                    _left_hwnd;
-       WindowHandle&   _right_hwnd;
-       ShellPathInfo&  _create_info;
-       HIMAGELIST              _himl;
-       HIMAGELIST              _himl_old;
-       BrowserCallback* _callback;
-
-       ShellFolder             _folder;
-
-       IShellView*             _pShellView;    // current hosted shellview
-       TreeDropTarget* _pDropTarget;
-
-       HTREEITEM               _last_sel;
-
-       Root                    _root;
-       ShellDirectory* _cur_dir;
-
-       CtxMenuInterfaces& _cm_ifs;
-
-       void    InitializeTree();
-       bool    InitDragDrop();
-
-#ifndef __MINGW32__    // IShellFolderViewCB missing in MinGW (as of 25.09.2005)
-       typedef IComSrvBase<IShellFolderViewCB, ShellBrowser> super;
-
-        // IShellFolderViewCB
-       virtual HRESULT STDMETHODCALLTYPE MessageSFVCB(UINT uMsg, WPARAM wParam, LPARAM lParam);
-#endif
-
-       map<int, int> _image_map;
-
-       int             get_image_idx(int icon_id);
-};
-
-
-#define        C_DRIVE_STR TEXT("C:\\")
-
- // work around GCC's wide string constant bug
-#ifdef __GNUC__
-extern const LPCTSTR C_DRIVE;
-#else
-#define        C_DRIVE C_DRIVE_STR
-#endif
-
-template<typename BASE> struct ShellBrowserChildT
- : public BASE, public BrowserCallback
-{
-       typedef BASE super;
-
-        // constructor for SDIMainFrame
-       ShellBrowserChildT(HWND hwnd)
-        :      super(hwnd)
-       {
-       }
-
-        // constructor for MDIShellBrowserChild
-       ShellBrowserChildT(HWND hwnd, const ShellChildWndInfo& info)
-        :      super(hwnd, info)
-       {
-       }
-
-protected:
-       auto_ptr<ShellBrowser> _shellBrowser;
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               switch(nmsg) {
-                 case PM_GET_SHELLBROWSER_PTR:
-                       return (LRESULT)&*_shellBrowser;
-
-                 case WM_GETISHELLBROWSER:     // for Registry Explorer Plugin
-                       return (LRESULT)static_cast<IShellBrowser*>(&*_shellBrowser);
-
-                 default:
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-
-               return 0;
-       }
-
-       int Notify(int id, NMHDR* pnmh)
-       {
-               if (_shellBrowser.get())
-                       switch(pnmh->code) {
-                         case TVN_GETDISPINFO:         _shellBrowser->OnTreeGetDispInfo(id, pnmh);                                     break;
-                         case TVN_SELCHANGED:          _shellBrowser->OnTreeItemSelected(id, (LPNMTREEVIEW)pnmh);      break;
-                         case TVN_ITEMEXPANDING:       _shellBrowser->OnTreeItemExpanding(id, (LPNMTREEVIEW)pnmh);     break;
-                         case NM_RCLICK:                       _shellBrowser->OnTreeItemRClick(id, pnmh);                                      break;
-                         default:                                      return super::Notify(id, pnmh);
-                       }
-               else
-                       return super::Notify(id, pnmh);
-
-               return 0;
-       }
-};
-
-
-#ifndef _NO_MDI
-
-struct MDIShellBrowserChild : public ExtContextMenuHandlerT<
-                               ShellBrowserChildT<ChildWindow>
-                       >
-{
-       typedef ExtContextMenuHandlerT<
-                               ShellBrowserChildT<ChildWindow>
-                       > super;
-
-       MDIShellBrowserChild(HWND hwnd, const ShellChildWndInfo& info);
-
-       static MDIShellBrowserChild* create(const ShellChildWndInfo& info);
-
-       LRESULT Init(LPCREATESTRUCT);
-
-       virtual String jump_to_int(LPCTSTR url);
-
-protected:
-       ShellChildWndInfo _create_info;
-       ShellPathInfo   _shellpath_info;
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       void    update_shell_browser();
-
-        // interface BrowserCallback
-       virtual void entry_selected(Entry* entry);
-};
-
-#endif
diff --git a/reactos/subsys/system/explorer/shell/shellfs.cpp b/reactos/subsys/system/explorer/shell/shellfs.cpp
deleted file mode 100644 (file)
index 01018ff..0000000
+++ /dev/null
@@ -1,536 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005, 2006 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // shellfs.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include <precomp.h>
-
-//#include "shellfs.h"
-//#include "winfs.h"
-
-#include <shlwapi.h>
-
-
-bool ShellDirectory::fill_w32fdata_shell(LPCITEMIDLIST pidl, SFGAOF attribs, WIN32_FIND_DATA* pw32fdata, BY_HANDLE_FILE_INFORMATION* pbhfi, bool do_access)
-{
-       CONTEXT("ShellDirectory::fill_w32fdata_shell()");
-
-       bool bhfi_valid = false;
-
-       if (do_access && !( (attribs&SFGAO_FILESYSTEM) && SUCCEEDED(
-                               SHGetDataFromIDList(_folder, pidl, SHGDFIL_FINDDATA, pw32fdata, sizeof(WIN32_FIND_DATA))) )) {
-               WIN32_FILE_ATTRIBUTE_DATA fad;
-               IDataObject* pDataObj;
-
-               STGMEDIUM medium = {0, {0}, 0};
-               FORMATETC fmt = {g_Globals._cfStrFName, 0, DVASPECT_CONTENT, -1, TYMED_HGLOBAL};
-
-               HRESULT hr = _folder->GetUIObjectOf(0, 1, &pidl, IID_IDataObject, 0, (LPVOID*)&pDataObj);
-
-               if (SUCCEEDED(hr)) {
-                       hr = pDataObj->GetData(&fmt, &medium);
-
-                       pDataObj->Release();
-
-                       if (SUCCEEDED(hr)) {
-                               LPCTSTR path = (LPCTSTR)GlobalLock(medium.UNION_MEMBER(hGlobal));
-
-                               if (path) {
-                                        // fill with drive names "C:", ...
-                                       assert(_tcslen(path) < GlobalSize(medium.UNION_MEMBER(hGlobal)));
-                                       _tcscpy(pw32fdata->cFileName, path);
-
-                                       UINT sem_org = SetErrorMode(SEM_FAILCRITICALERRORS);
-
-                                       if (GetFileAttributesEx(path, GetFileExInfoStandard, &fad)) {
-                                               pw32fdata->dwFileAttributes = fad.dwFileAttributes;
-                                               pw32fdata->ftCreationTime = fad.ftCreationTime;
-                                               pw32fdata->ftLastAccessTime = fad.ftLastAccessTime;
-                                               pw32fdata->ftLastWriteTime = fad.ftLastWriteTime;
-
-                                               if (!(fad.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)) {
-                                                        // copy file size
-                                                       pw32fdata->nFileSizeLow = fad.nFileSizeLow;
-                                                       pw32fdata->nFileSizeHigh = fad.nFileSizeHigh;
-                                               } else {
-                                                        // ignore FILE_ATTRIBUTE_HIDDEN attribute of NTFS drives - this would hide those drives in ShellBrowser
-                                                       if (pw32fdata->dwFileAttributes & FILE_ATTRIBUTE_HIDDEN) {
-                                                               if (path[1]==':' && path[2]=='\\' && !path[3])  // Is it a drive path?
-                                                                       pw32fdata->dwFileAttributes &= ~FILE_ATTRIBUTE_HIDDEN;
-                                                       }
-                                               }
-                                       }
-
-                                       HANDLE hFile = CreateFile(path, GENERIC_READ, FILE_SHARE_READ|FILE_SHARE_WRITE|FILE_SHARE_DELETE,
-                                                                                               0, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, 0);
-
-                                       if (hFile != INVALID_HANDLE_VALUE) {
-                                               if (GetFileInformationByHandle(hFile, pbhfi))
-                                                       bhfi_valid = true;
-
-                                               CloseHandle(hFile);
-                                       }
-
-                                       SetErrorMode(sem_org);
-
-                                       GlobalUnlock(medium.UNION_MEMBER(hGlobal));
-                                       GlobalFree(medium.UNION_MEMBER(hGlobal));
-                               }
-                       }
-               }
-       }
-
-       if (!do_access || !(attribs&SFGAO_FILESYSTEM))  // Archiv files should not be displayed as folders in explorer view.
-               if (attribs & (SFGAO_FOLDER|SFGAO_HASSUBFOLDER))
-                       pw32fdata->dwFileAttributes |= FILE_ATTRIBUTE_DIRECTORY;
-
-       if (attribs & SFGAO_READONLY)
-               pw32fdata->dwFileAttributes |= FILE_ATTRIBUTE_READONLY;
-
-       if (attribs & SFGAO_COMPRESSED)
-               pw32fdata->dwFileAttributes |= FILE_ATTRIBUTE_COMPRESSED;
-
-       return bhfi_valid;
-}
-
-
-ShellPath ShellEntry::create_absolute_pidl() const
-{
-       CONTEXT("ShellEntry::create_absolute_pidl()");
-
-       if (_up)
-               if (_up->_etype == ET_SHELL) {
-                       ShellDirectory* dir = static_cast<ShellDirectory*>(_up);
-
-                       if (dir->_pidl->mkid.cb)        // Caching of absolute PIDLs could enhance performance.
-                               return _pidl.create_absolute_pidl(dir->create_absolute_pidl());
-               } else
-                       return _pidl.create_absolute_pidl(_up->create_absolute_pidl());
-
-       return _pidl;
-}
-
-
- // get full path of a shell entry
-bool ShellEntry::get_path(PTSTR path, size_t path_count) const
-{
-       if (!path || path_count==0)
-               return false;
-/*
-       path[0] = TEXT('\0');
-
-       if (FAILED(path_from_pidl(get_parent_folder(), &*_pidl, path, path_count)))
-               return false;
-*/
-       FileSysShellPath fs_path(create_absolute_pidl());
-       LPCTSTR ret = fs_path;
-
-       if (ret) {
-               lstrcpyn(path, ret, path_count);
-               return true;
-       } else
-               return false;
-}
-
-
- // get full path of a shell folder
-bool ShellDirectory::get_path(PTSTR path, size_t path_count) const
-{
-       CONTEXT("ShellDirectory::get_path()");
-
-       if (!path || path_count==0)
-               return false;
-
-       path[0] = TEXT('\0');
-
-       if (_folder.empty())
-               return false;
-
-       SFGAOF attribs = SFGAO_FILESYSTEM;
-
-       if (FAILED(const_cast<ShellFolder&>(_folder)->GetAttributesOf(1, (LPCITEMIDLIST*)&_pidl, &attribs)))
-               return false;
-
-       if (!(attribs & SFGAO_FILESYSTEM))
-               return false;
-
-       if (FAILED(path_from_pidl(get_parent_folder(), &*_pidl, path, path_count)))
-               return false;
-
-       return true;
-}
-
-
-BOOL ShellEntry::launch_entry(HWND hwnd, UINT nCmdShow)
-{
-       CONTEXT("ShellEntry::launch_entry()");
-
-       SHELLEXECUTEINFO shexinfo;
-
-       shexinfo.cbSize = sizeof(SHELLEXECUTEINFO);
-       shexinfo.fMask = SEE_MASK_INVOKEIDLIST; // SEE_MASK_IDLIST is also possible.
-       shexinfo.hwnd = hwnd;
-       shexinfo.lpVerb = NULL;
-       shexinfo.lpFile = NULL;
-       shexinfo.lpParameters = NULL;
-       shexinfo.lpDirectory = NULL;
-       shexinfo.nShow = nCmdShow;
-
-       ShellPath shell_path = create_absolute_pidl();
-       shexinfo.lpIDList = &*shell_path;
-
-        // add PIDL to the recent file list
-       SHAddToRecentDocs(SHARD_PIDL, shexinfo.lpIDList);
-
-       BOOL ret = TRUE;
-
-       if (!ShellExecuteEx(&shexinfo)) {
-               display_error(hwnd, GetLastError());
-               ret = FALSE;
-       }
-
-       return ret;
-}
-
-
-HRESULT ShellEntry::do_context_menu(HWND hwnd, LPPOINT pptScreen, CtxMenuInterfaces& cm_ifs)
-{
-       ShellDirectory* dir = static_cast<ShellDirectory*>(_up);
-
-       ShellFolder folder = dir? dir->_folder: GetDesktopFolder();
-       LPCITEMIDLIST pidl = _pidl;
-
-       return ShellFolderContextMenu(folder, hwnd, 1, &pidl, pptScreen->x, pptScreen->y, cm_ifs);
-}
-
-
-HRESULT ShellEntry::GetUIObjectOf(HWND hWnd, REFIID riid, LPVOID* ppvOut)
-{
-       LPCITEMIDLIST pidl = _pidl;
-
-       return get_parent_folder()->GetUIObjectOf(hWnd, 1, &pidl, riid, NULL, ppvOut);
-}
-
-
-ShellFolder Entry::get_shell_folder() const
-{
-       return ShellFolder(create_absolute_pidl());
-}
-
-ShellFolder ShellEntry::get_shell_folder() const
-{
-       return get_parent_folder();
-}
-
-ShellFolder ShellDirectory::get_shell_folder() const
-{
-       return _folder;
-}
-
-
-void ShellDirectory::read_directory(int scan_flags)
-{
-       CONTEXT("ShellDirectory::read_directory()");
-
-       int level = _level + 1;
-
-       Entry* first_entry = NULL;
-       Entry* last = NULL;
-
-       /*if (_folder.empty())
-               return;*/
-
-#ifndef _NO_WIN_FS
-       TCHAR buffer[_MAX_PATH+_MAX_FNAME];
-
-       if (!(scan_flags&SCAN_NO_FILESYSTEM) && get_path(buffer, COUNTOF(buffer)) && _tcsncmp(buffer,TEXT("::{"),3)) {
-               Entry* entry = NULL;    // eliminate useless GCC warning by initializing entry
-
-               LPTSTR p = buffer + _tcslen(buffer);
-
-               lstrcpy(p, TEXT("\\*"));
-
-               WIN32_FIND_DATA w32fd;
-               HANDLE hFind = FindFirstFile(buffer, &w32fd);
-
-               if (hFind != INVALID_HANDLE_VALUE) {
-                       do {
-                                // ignore hidden files (usefull in the start menu)
-                               if (w32fd.dwFileAttributes & FILE_ATTRIBUTE_HIDDEN)
-                                       continue;
-
-                                // ignore directory entries "." and ".."
-                               if ((w32fd.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY) &&
-                                       w32fd.cFileName[0]==TEXT('.') &&
-                                       (w32fd.cFileName[1]==TEXT('\0') ||
-                                       (w32fd.cFileName[1]==TEXT('.') && w32fd.cFileName[2]==TEXT('\0'))))
-                                       continue;
-
-                               lstrcpy(p+1, w32fd.cFileName);
-
-                               if (w32fd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                                       entry = new WinDirectory(this, buffer);
-                               else
-                                       entry = new WinEntry(this);
-
-                               if (!first_entry)
-                                       first_entry = entry;
-
-                               if (last)
-                                       last->_next = entry;
-
-                               memcpy(&entry->_data, &w32fd, sizeof(WIN32_FIND_DATA));
-
-                               entry->_level = level;
-
-                               if (!(scan_flags & SCAN_DONT_ACCESS)) {
-                                       HANDLE hFile = CreateFile(buffer, GENERIC_READ, FILE_SHARE_READ|FILE_SHARE_WRITE|FILE_SHARE_DELETE,
-                                                                                               0, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, 0);
-
-                                       if (hFile != INVALID_HANDLE_VALUE) {
-                                               if (GetFileInformationByHandle(hFile, &entry->_bhfi))
-                                                       entry->_bhfi_valid = true;
-
-                                               if (ScanNTFSStreams(entry, hFile))
-                                                       entry->_scanned = true; // There exist named NTFS sub-streams in this file.
-
-                                               CloseHandle(hFile);
-                                       }
-                               }
-
-                                // set file type name
-                               LPCTSTR ext = g_Globals._ftype_mgr.set_type(entry);
-
-                               DWORD attribs = SFGAO_FILESYSTEM;
-
-                               if (w32fd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                                       attribs |= SFGAO_FOLDER|SFGAO_HASSUBFOLDER;
-
-                               if (w32fd.dwFileAttributes & FILE_ATTRIBUTE_READONLY)
-                                       attribs |= SFGAO_READONLY;
-
-                               //if (w32fd.dwFileAttributes & FILE_ATTRIBUTE_HIDDEN)
-                               //      attribs |= SFGAO_HIDDEN;
-
-                               if (w32fd.dwFileAttributes & FILE_ATTRIBUTE_COMPRESSED)
-                                       attribs |= SFGAO_COMPRESSED;
-
-                               if (ext && !_tcsicmp(ext, _T(".lnk"))) {
-                                       attribs |= SFGAO_LINK;
-                                       w32fd.dwFileAttributes |= ATTRIBUTE_SYMBOLIC_LINK;
-                               }
-
-                               entry->_shell_attribs = attribs;
-
-                               if (w32fd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                                       entry->_icon_id = ICID_FOLDER;
-                               else if (!(scan_flags & SCAN_DONT_EXTRACT_ICONS))
-                                       entry->_icon_id = entry->safe_extract_icon();   // Assume small icon, we can extract the large icon later on demand.
-
-                               last = entry;
-                       } while(FindNextFile(hFind, &w32fd));
-
-                       FindClose(hFind);
-               }
-       }
-       else // SCAN_NO_FILESYSTEM
-#endif
-       {
-               ShellItemEnumerator enumerator(_folder, SHCONTF_FOLDERS|SHCONTF_NONFOLDERS|SHCONTF_INCLUDEHIDDEN|SHCONTF_SHAREABLE|SHCONTF_STORAGE);
-
-               TCHAR name[MAX_PATH];
-               TCHAR path[MAX_PATH];
-               HRESULT hr_next = S_OK;
-
-               do {
-#define FETCH_ITEM_COUNT       32
-                       LPITEMIDLIST pidls[FETCH_ITEM_COUNT];
-                       ULONG cnt = 0;
-
-                       memset(pidls, 0, sizeof(pidls));
-
-                       hr_next = enumerator->Next(FETCH_ITEM_COUNT, pidls, &cnt);
-
-                       /* don't break yet now: Registry Explorer Plugin returns E_FAIL!
-                       if (!SUCCEEDED(hr_next))
-                               break; */
-
-                       if (hr_next == S_FALSE)
-                               break;
-
-                       for(ULONG n=0; n<cnt; ++n) {
-                               WIN32_FIND_DATA w32fd;
-                               BY_HANDLE_FILE_INFORMATION bhfi;
-                               bool bhfi_valid = false;
-
-                               memset(&w32fd, 0, sizeof(WIN32_FIND_DATA));
-
-                               SFGAOF attribs_before = ~SFGAO_READONLY & ~SFGAO_VALIDATE;
-                               SFGAOF attribs = attribs_before;
-                               HRESULT hr = _folder->GetAttributesOf(1, (LPCITEMIDLIST*)&pidls[n], &attribs);
-                               bool removeable = false;
-
-                               if (SUCCEEDED(hr) && attribs!=attribs_before) {
-                                        // avoid accessing floppy drives when browsing "My Computer"
-                                       if (attribs & SFGAO_REMOVABLE) {
-                                               attribs |= SFGAO_HASSUBFOLDER;
-                                               removeable = true;
-                                       } else if (!(scan_flags & SCAN_DONT_ACCESS)) {
-                                               DWORD attribs2 = SFGAO_READONLY;
-
-                                               HRESULT hr = _folder->GetAttributesOf(1, (LPCITEMIDLIST*)&pidls[n], &attribs2);
-
-                                               if (SUCCEEDED(hr))
-                                                       attribs |= attribs2;
-                                       }
-                               } else
-                                       attribs = 0;
-
-                               bhfi_valid = fill_w32fdata_shell(pidls[n], attribs, &w32fd, &bhfi,
-                                                                                                !(scan_flags&SCAN_DONT_ACCESS) && !removeable);
-
-                               try {
-                                       Entry* entry = NULL;    // eliminate useless GCC warning by initializing entry
-
-                                       if (w32fd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                                               entry = new ShellDirectory(this, pidls[n], _hwnd);
-                                       else
-                                               entry = new ShellEntry(this, pidls[n]);
-
-                                       if (!first_entry)
-                                               first_entry = entry;
-
-                                       if (last)
-                                               last->_next = entry;
-
-                                       memcpy(&entry->_data, &w32fd, sizeof(WIN32_FIND_DATA));
-
-                                       if (bhfi_valid)
-                                               memcpy(&entry->_bhfi, &bhfi, sizeof(BY_HANDLE_FILE_INFORMATION));
-
-                                        // store path in entry->_data.cFileName in case fill_w32fdata_shell() didn't already fill it
-                                       if (!entry->_data.cFileName[0])
-                                               if (SUCCEEDED(path_from_pidl(_folder, pidls[n], path, COUNTOF(path))))
-                                                       _tcscpy(entry->_data.cFileName, path);
-
-                                       if (SUCCEEDED(name_from_pidl(_folder, pidls[n], name, COUNTOF(name), SHGDN_INFOLDER|0x2000/*0x2000=SHGDN_INCLUDE_NONFILESYS*/))) {
-                                               if (!entry->_data.cFileName[0])
-                                                       _tcscpy(entry->_data.cFileName, name);
-                                               else if (_tcscmp(entry->_display_name, name))
-                                                       entry->_display_name = _tcsdup(name);   // store display name separate from file name; sort display by file name
-                                       }
-
-                                       if (attribs & SFGAO_LINK)
-                                               w32fd.dwFileAttributes |= ATTRIBUTE_SYMBOLIC_LINK;
-
-                                       entry->_level = level;
-                                       entry->_shell_attribs = attribs;
-                                       entry->_bhfi_valid = bhfi_valid;
-
-                                        // set file type name
-                                       g_Globals._ftype_mgr.set_type(entry);
-
-                                        // get icons for files and virtual objects
-                                       if (!(entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) ||
-                                               !(attribs & SFGAO_FILESYSTEM)) {
-                                               if (!(scan_flags & SCAN_DONT_EXTRACT_ICONS))
-                                                       entry->_icon_id = entry->safe_extract_icon();   // Assume small icon, we can extract the large icon later on demand.
-                                       } else if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                                               entry->_icon_id = ICID_FOLDER;
-                                       else
-                                               entry->_icon_id = ICID_NONE;    // don't try again later
-
-                                       last = entry;
-                               } catch(COMException& e) {
-                                       HandleException(e, _hwnd);
-                               }
-                       }
-               } while(SUCCEEDED(hr_next));
-       }
-
-       if (last)
-               last->_next = NULL;
-
-       _down = first_entry;
-       _scanned = true;
-}
-
-const void* ShellDirectory::get_next_path_component(const void* p) const
-{
-       LPITEMIDLIST pidl = (LPITEMIDLIST)p;
-
-       if (!pidl || !pidl->mkid.cb)
-               return NULL;
-
-        // go to next element
-       pidl = (LPITEMIDLIST)((LPBYTE)pidl+pidl->mkid.cb);
-
-       return pidl;
-}
-
-Entry* ShellDirectory::find_entry(const void* p)
-{
-       LPITEMIDLIST pidl = (LPITEMIDLIST) p;
-
-        // handle special case of empty trailing id list entry
-       if (!pidl->mkid.cb)
-               return this;
-
-       for(Entry*entry=_down; entry; entry=entry->_next)
-               if (entry->_etype == ET_SHELL) {
-                       ShellEntry* se = static_cast<ShellEntry*>(entry);
-
-                       if (se->_pidl && se->_pidl->mkid.cb==pidl->mkid.cb && !memcmp(se->_pidl, pidl, se->_pidl->mkid.cb))
-                               return entry;
-               } else {
-                       const ShellPath& sp = entry->create_absolute_pidl();
-                       static DynamicFct<LPITEMIDLIST(WINAPI*)(LPCITEMIDLIST)> ILFindLastID(TEXT("SHELL32"), "ILFindLastID");
-
-                       if (ILFindLastID) {
-                               LPCITEMIDLIST entry_pidl = (*ILFindLastID)(sp);
-
-                               if (entry_pidl && entry_pidl->mkid.cb==pidl->mkid.cb && !memcmp(entry_pidl, pidl, entry_pidl->mkid.cb))
-                                       return entry;
-                       }
-               }
-
-       return NULL;
-}
-
-int ShellDirectory::extract_icons(ICONCACHE_FLAGS flags)
-{
-       int cnt = 0;
-
-       for(Entry*entry=_down; entry; entry=entry->_next)
-               if (entry->_icon_id == ICID_UNKNOWN) {
-                       entry->_icon_id = entry->extract_icon(flags);
-
-                       if (entry->_icon_id != ICID_NONE)
-                               ++cnt;
-               }
-
-       return cnt;
-}
diff --git a/reactos/subsys/system/explorer/shell/shellfs.h b/reactos/subsys/system/explorer/shell/shellfs.h
deleted file mode 100644 (file)
index 979c58e..0000000
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // shellfs.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
- /// shell file/directory entry
-struct ShellEntry : public Entry
-{
-       ShellEntry(Entry* parent, LPITEMIDLIST shell_path) : Entry(parent, ET_SHELL), _pidl(shell_path) {}
-       ShellEntry(Entry* parent, const ShellPath& shell_path) : Entry(parent, ET_SHELL), _pidl(shell_path) {}
-
-       virtual bool            get_path(PTSTR path, size_t path_count) const;
-       virtual ShellPath       create_absolute_pidl() const;
-       virtual HRESULT         GetUIObjectOf(HWND hWnd, REFIID riid, LPVOID* ppvOut);
-       virtual BOOL            launch_entry(HWND hwnd, UINT nCmdShow=SW_SHOWNORMAL);
-       virtual HRESULT         do_context_menu(HWND hwnd, LPPOINT pptScreen, CtxMenuInterfaces& cm_ifs);
-       virtual ShellFolder     get_shell_folder() const;
-
-       IShellFolder*           get_parent_folder() const;
-
-       ShellPath       _pidl;  // parent relative PIDL
-
-protected:
-       ShellEntry(LPITEMIDLIST shell_path) : Entry(ET_SHELL), _pidl(shell_path) {}
-       ShellEntry(const ShellPath& shell_path) : Entry(ET_SHELL), _pidl(shell_path) {}
-};
-
-
- /// shell folder entry
-struct ShellDirectory : public ShellEntry, public Directory
-{
-       ShellDirectory(ShellFolder& root_folder, const ShellPath& shell_path, HWND hwnd)
-        :      ShellEntry(shell_path),
-               _folder(root_folder, shell_path),
-               _hwnd(hwnd)
-       {
-               CONTEXT("ShellDirectory::ShellDirectory()");
-
-               lstrcpy(_data.cFileName, root_folder.get_name(shell_path, SHGDN_FORADDRESSBAR));
-               _data.dwFileAttributes = FILE_ATTRIBUTE_DIRECTORY;
-               _shell_attribs = SFGAO_FOLDER;
-
-               ShellFolder subfolder(root_folder, shell_path);
-               IShellFolder* pFolder = subfolder;
-               pFolder->AddRef();
-               _path = pFolder;
-       }
-
-       explicit ShellDirectory(ShellDirectory* parent, LPITEMIDLIST shell_path, HWND hwnd)
-        :      ShellEntry(parent, shell_path),
-               _folder(parent->_folder, shell_path),
-               _hwnd(hwnd)
-       {
-               /* not neccessary - the caller will fill the info
-               lstrcpy(_data.cFileName, _folder.get_name(shell_path));
-               _data.dwFileAttributes = FILE_ATTRIBUTE_DIRECTORY;
-               _shell_attribs = SFGAO_FOLDER; */
-
-               _folder->AddRef();
-               _path = _folder;
-       }
-
-       ShellDirectory(const ShellDirectory& other)
-        :      ShellEntry(other),
-               Directory(other),
-               _folder(other._folder),
-               _hwnd(other._hwnd)
-       {
-               IShellFolder* pFolder = (IShellFolder*)_path;
-               pFolder->AddRef();
-       }
-
-       ~ShellDirectory()
-       {
-               IShellFolder* pFolder = (IShellFolder*)_path;
-               _path = NULL;
-               pFolder->Release();
-       }
-
-       virtual void read_directory(int scan_flags=0);
-       virtual const void* get_next_path_component(const void*) const;
-       virtual Entry* find_entry(const void*);
-
-       virtual bool get_path(PTSTR path, size_t path_count) const;
-       virtual ShellFolder     get_shell_folder() const;
-
-       int     extract_icons(ICONCACHE_FLAGS flags);
-
-       ShellFolder _folder;
-       HWND    _hwnd;
-
-protected:
-       bool    fill_w32fdata_shell(LPCITEMIDLIST pidl, SFGAOF attribs, WIN32_FIND_DATA*, BY_HANDLE_FILE_INFORMATION*, bool do_access=true);
-};
-
-
-inline IShellFolder* ShellEntry::get_parent_folder() const
-{
-       if (_up)
-               return static_cast<ShellDirectory*>(_up)->_folder;
-       else
-               return GetDesktopFolder();
-}
diff --git a/reactos/subsys/system/explorer/shell/unixfs.cpp b/reactos/subsys/system/explorer/shell/unixfs.cpp
deleted file mode 100644 (file)
index ae616ed..0000000
+++ /dev/null
@@ -1,223 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // unixfs.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#ifdef __WINE__
-
-#include <precomp.h>
-
-//#include "unixfs.h"
-
- // for UnixDirectory::read_directory()
-#include <dirent.h>
-#include <sys/stat.h>
-#include <time.h>
-
-
-void UnixDirectory::read_directory()
-{
-       Entry* first_entry = NULL;
-       Entry* last = NULL;
-       Entry* entry;
-
-       int level = _level + 1;
-
-       LPCTSTR path = (LPCTSTR)_path;
-       DIR* pdir = opendir(path);
-
-       if (pdir) {
-               struct stat st;
-               struct dirent* ent;
-               TCHAR buffer[MAX_PATH], *p;
-
-               for(p=buffer; *path; )
-                       *p++ = *path++;
-
-               if (p==buffer || p[-1]!='/')
-                       *p++ = '/';
-
-               while((ent=readdir(pdir))) {
-                       int statres = stat(buffer, &st);
-
-                       if (!statres && S_ISDIR(st.st_mode))
-                               entry = new UnixDirectory(this, buffer);
-                       else
-                               entry = new UnixEntry(this);
-
-                       if (!first_entry)
-                               first_entry = entry;
-
-                       if (last)
-                               last->_next = entry;
-
-                       lstrcpy(entry->_data.cFileName, ent->d_name);
-                       entry->_data.dwFileAttributes = ent->d_name[0]=='.'? FILE_ATTRIBUTE_HIDDEN: 0;
-
-                       strcpy(p, ent->d_name);
-
-                       if (!statres) {
-                               if (S_ISDIR(st.st_mode))
-                                       entry->_data.dwFileAttributes |= FILE_ATTRIBUTE_DIRECTORY;
-
-                               entry->_data.nFileSizeLow = st.st_size & 0xFFFFFFFF;
-                               entry->_data.nFileSizeHigh = st.st_size >> 32;
-
-                               memset(&entry->_data.ftCreationTime, 0, sizeof(FILETIME));
-                               time_to_filetime(&st.st_atime, &entry->_data.ftLastAccessTime);
-                               time_to_filetime(&st.st_mtime, &entry->_data.ftLastWriteTime);
-
-                               entry->_bhfi.nFileIndexLow = ent->d_ino;
-                               entry->_bhfi.nFileIndexHigh = 0;
-
-                               entry->_bhfi.nNumberOfLinks = st.st_nlink;
-
-                               entry->_bhfi_valid = TRUE;
-                       } else {
-                               entry->_data.nFileSizeLow = 0;
-                               entry->_data.nFileSizeHigh = 0;
-                               entry->_bhfi_valid = FALSE;
-                       }
-
-                       entry->_up = this;
-                       entry->_expanded = FALSE;
-                       entry->_scanned = FALSE;
-                       entry->_level = level;
-
-                       last = entry;
-               }
-
-               last->_next = NULL;
-
-               closedir(pdir);
-       }
-
-       _down = first_entry;
-       _scanned = true;
-}
-
-
-const void* UnixDirectory::get_next_path_component(const void* p)
-{
-       LPCTSTR s = (LPCTSTR) p;
-
-       while(*s && *s!=TEXT('/'))
-               ++s;
-
-       while(*s == TEXT('/'))
-               ++s;
-
-       if (!*s)
-               return NULL;
-
-       return s;
-}
-
-
-Entry* UnixDirectory::find_entry(const void* p)
-{
-       LPCTSTR name = (LPCTSTR)p;
-
-       for(Entry*entry=_down; entry; entry=entry->_next) {
-               LPCTSTR p = name;
-               LPCTSTR q = entry->_data.cFileName;
-
-               do {
-                       if (!*p || *p==TEXT('/'))
-                               return entry;
-               } while(*p++ == *q++);
-       }
-
-       return NULL;
-}
-
-
- // get full path of specified directory entry
-bool UnixEntry::get_path(PTSTR path, size_t path_count) const
-{
-       int level = 0;
-       size_t len = 0;
-
-       if (!path || path_count==0)
-               return false;
-
-       if ( path_count > 1 )
-       {
-               for(const Entry* entry=this; entry; level++) {
-                       LPCTSTR name = entry->_data.cFileName;
-                       size_t l = 0;
-
-                       for(LPCTSTR s=name; *s && *s!=TEXT('/'); s++)
-                               ++l;
-
-                       if (entry->_up) {
-                               if (l > 0) {
-                                       if ( len+l+1 >= path_count )
-                                       {
-                                               /* compare to 2 here because of terminator plus the '\\' we prepend */
-                                               if ( l + 2 > path_count )
-                                                       len = 0;
-                                               else
-                                                       len = path_count - l - 2;
-                                       }
-                                       memmove(path+l+1, path, len*sizeof(TCHAR));
-                                       /* compare to 2 here because of terminator plus the '\\' we prepend */
-                                       if ( l+2 >= path_count )
-                                               l = path_count - 2;
-                                       memcpy(path+1, name, l*sizeof(TCHAR));
-                                       len += l+1;
-
-                                       path[0] = TEXT('/');
-                               }
-
-                               entry = entry->_up;
-                       } else {
-                               if ( len+l >= path_count )
-                               {
-                                       if ( l + 1 > path_count )
-                                               len = 0;
-                                       else
-                                               len = path_count - l - 1;
-                               }
-                               memmove(path+l, path, len*sizeof(TCHAR));
-                               if ( l+1 >= path_count )
-                                       l = path_count - 1;
-                               memcpy(path, name, l*sizeof(TCHAR));
-                               len += l;
-                               break;
-                       }
-               }
-
-               if ( !level && (len+1 < path_count) )
-                       path[len++] = TEXT('/');
-       }
-
-       path[len] = TEXT('\0');
-
-       return true;
-}
-
-#endif // __WINE__
diff --git a/reactos/subsys/system/explorer/shell/unixfs.h b/reactos/subsys/system/explorer/shell/unixfs.h
deleted file mode 100644 (file)
index 91bdc0b..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright 2003 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // unixfs.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#ifdef __WINE__
-
-struct UnixEntry : public Entry
-{
-       UnixEntry(Entry* parent) : Entry(parent) {}
-
-protected:
-       UnixEntry() : Entry(ET_UNIX) {}
-
-       virtual bool get_path(PTSTR path, size_t path_count) const;
-};
-
-struct UnixDirectory : public UnixEntry, public Directory
-{
-       UnixDirectory(LPCTSTR root_path)
-        :      UnixEntry()
-       {
-               _path = _tcsdup(root_path);
-       }
-
-       UnixDirectory(UnixDirectory* parent, LPCTSTR path)
-        :      UnixEntry(parent)
-       {
-               _path = _tcsdup(path);
-       }
-
-       ~UnixDirectory()
-       {
-               free(_path);
-               _path = NULL;
-       }
-
-       virtual void read_directory();
-       virtual const void* get_next_path_component(const void*);
-       virtual Entry* find_entry(const void*);
-};
-
-#endif
diff --git a/reactos/subsys/system/explorer/shell/webchild.cpp b/reactos/subsys/system/explorer/shell/webchild.cpp
deleted file mode 100644 (file)
index a4e4033..0000000
+++ /dev/null
@@ -1,309 +0,0 @@
-/*
- * Copyright 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // webchild.cpp
- //
- // Martin Fuchs, 08.02.2004
- //
-
-
-#include <precomp.h>
-
-#include "../resource.h"
-
-#include "webchild.h"
-
-
-#ifdef _MSC_VER
-
-#if _MSC_VER>=1300     // vtMissing for VS.Net
-#include <comutil.h>
-#pragma comment(lib, "comsupp")
-#endif
-
-#else
-
-#ifdef __MINGW32__     // MinGW is lacking vtMissing (as of 07.02.2004)
-static Variant vtMissing;
-#endif
-
-#endif
-
-//#include <mshtml.h>
-
-
-Variant::Variant(const VARIANT& var)
-{
-       VariantInit(this);
-       CheckError(VariantCopy(this, const_cast<VARIANT*>(&var)));
-}
-
-Variant::Variant(const VARIANT* var)
-{
-       VariantInit(this);
-       CheckError(VariantCopy(this, const_cast<VARIANT*>(var)));
-}
-
-Variant::~Variant()
-{
-       VariantClear(this);
-}
-
-
-Variant::operator long() const
-{
-       Variant v;
-       CheckError(VariantChangeType(&v, (VARIANT*)this, 0, VT_I4));
-       return V_I4(&v);
-}
-
-Variant::operator bool() const
-{
-       Variant v;
-       CheckError(VariantChangeType(&v, (VARIANT*)this, 0, VT_BOOL));
-       return V_BOOL(&v)? true: false;
-}
-
-Variant::operator IDispatch*() const
-{
-       Variant v;
-       CheckError(VariantChangeType(&v, (VARIANT*)this, 0, VT_DISPATCH));
-       return V_DISPATCH(&v);
-}
-
-Variant::operator VARIANT_BOOL() const
-{
-       Variant v;
-       CheckError(VariantChangeType(&v, (VARIANT*)this, 0, VT_BOOL));
-       return V_BOOL(&v);
-}
-
-
-void BStr::assign(BSTR s)
-{
-       if (!SysReAllocString(&_p, s))
-               THROW_EXCEPTION(E_OUTOFMEMORY);
-}
-
-void BStr::assign(const VARIANT& var)
-{
-       if (V_VT(&var) == VT_BSTR)
-               assign(V_BSTR(&var));
-       else {
-               Variant v;
-               CheckError(VariantChangeType(&v, const_cast<VARIANT*>(&var), 0, VT_BSTR));
-               assign(V_BSTR(&v));
-       }
-}
-
-
-BrowserNavigator::BrowserNavigator()
- :     _browser_initialized(false)
-{
-}
-
-void BrowserNavigator::attach(IWebBrowser* browser)
-{
-       _browser = browser;
-}
-
-void BrowserNavigator::goto_url(LPCTSTR url)
-{
-       if (_browser_initialized)
-               _browser->Navigate(BStr(url), NULL, NULL, NULL, NULL);
-       else {
-               _new_url = url;
-
-               _browser->Navigate(L"about:blank", NULL, NULL, NULL, NULL);
-       }
-}
-
-void BrowserNavigator::set_html_page(const String& html_txt)
-{
-       _new_html_txt = html_txt;
-
-       goto_url(TEXT("about:blank"));
-}
-
-void T2nA_binary(LPCTSTR s, LPSTR d, int len)
-{
-       while(len-- > 0)
-               *d++ = (unsigned char)*s++;
-}
-
-void BrowserNavigator::navigated(LPCTSTR url)
-{
-       _browser_initialized = true;
-
-       bool nav = false;
-
-       if (!_new_url.empty()) {
-               if (!_tcscmp(url,TEXT("about:blank")) && _new_url!=TEXT("about:blank")) {
-                       _browser->Navigate(BStr(_new_url), NULL, NULL, NULL, NULL);
-                       ++nav;
-               }
-
-               _new_url.erase();
-       }
-
-       if (!nav && !_new_html_txt.empty()) {   ///@todo move this into DocumentComplete() ?
-               int len = _new_html_txt.length();
-               HGLOBAL hHtmlText = GlobalAlloc(GPTR, len);
-
-               if (!hHtmlText) {
-                       T2nA_binary(_new_html_txt, (char*)hHtmlText, len);
-                       _new_html_txt.erase();
-
-                       SIfacePtr<IStream> pStream;
-                       HRESULT hr = CreateStreamOnHGlobal(hHtmlText, TRUE, &pStream);
-
-                       if (SUCCEEDED(hr)) {
-                               SIfacePtr<IDispatch> pHtmlDoc;
-                               CheckError(_browser->get_Document(&pHtmlDoc));
-
-                               SIfacePtr<IPersistStreamInit> pPersistStreamInit;
-                               pHtmlDoc.QueryInterface(IID_IPersistStreamInit, &pPersistStreamInit);
-
-                               CheckError(pPersistStreamInit->InitNew());
-                               CheckError(pPersistStreamInit->Load(pStream));
-                       } else
-                               GlobalFree(hHtmlText);
-               }
-       }
-}
-
-
-HWND create_webchildwindow(const WebChildWndInfo& info)
-{
-       WebChildWindow* pWnd = WebChildWindow::create(info);
-
-       if (!pWnd)
-               return 0;
-
-       return *pWnd;
-}
-
-static const CLSID CLSID_MozillaBrowser =
-       {0x1339B54C, 0x3453, 0x11D2, {0x93, 0xB9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}};
-
-
-WebChildWindow::WebChildWindow(HWND hwnd, const WebChildWndInfo& info)
- :     super(hwnd, info),
-       web_super(_navigator)
-{
-        // first try to create a web control with MS IE's CLASSID
-       HRESULT hr = create_control(hwnd, CLSID_WebBrowser, IID_IWebBrowser2);
-
-        // If this failed, try to use Mozilla's web control
-       if (FAILED(hr))
-               hr = create_control(hwnd, CLSID_MozillaBrowser, IID_IWebBrowser2);
-
-       if (SUCCEEDED(hr)) {
-               _navigator.attach(_control);
-
-               _connector = auto_ptr<EventConnector>(new EventConnector(_control, DIID_DWebBrowserEvents2, this));
-
-               _control->Navigate(BStr(info._path), &vtMissing, &vtMissing, &vtMissing, &vtMissing);
-               //browser->Navigate2(&Variant(info._path), &vtMissing, &vtMissing, &vtMissing, &vtMissing);
-       }
-}
-
-LRESULT WebChildWindow::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       try {
-               switch(nmsg) {
-                 case WM_ERASEBKGND:
-                       if (!_control) {
-                               HDC hdc = (HDC)wparam;
-                               ClientRect rect(_hwnd);
-
-                               HBRUSH hbrush = CreateSolidBrush(RGB(200,200,235));
-                               BkMode mode(hdc, TRANSPARENT);
-                               TextColor color(hdc, RGB(200,40,40));
-                               FillRect(hdc, &rect, hbrush);
-                               DrawText(hdc, TEXT("Sorry - no web browser control could be loaded."), -1, &rect, DT_CENTER|DT_VCENTER|DT_SINGLELINE);
-                               DeleteObject(hbrush);
-                       }
-
-                       return TRUE;
-
-                 case PM_DISPATCH_COMMAND: {
-                       if (!_control)
-                               return FALSE;
-
-                       HRESULT hr = E_FAIL;
-
-                       switch(LOWORD(wparam)) {
-                         case ID_GO_BACK:
-                               hr = _control->GoBack();
-                               break;
-
-                         case ID_GO_FORWARD:
-                               hr = _control->GoForward();
-                               break;
-
-                         case ID_GO_UP:
-                               ///@todo
-                               break;
-
-                         case ID_GO_HOME:
-                               hr = _control->GoHome();
-                               break;
-
-                         case ID_GO_SEARCH:
-                               hr = _control->GoSearch();
-                               break;
-
-                         case ID_REFRESH:
-                               hr = _control->Refresh();
-                               break;
-
-                         case ID_STOP:
-                               hr = _control->Stop();
-                               break;
-
-                         default:
-                               return super::WndProc(nmsg, wparam, lparam);
-                       }
-
-                       if (FAILED(hr) && hr!=E_FAIL)
-                               THROW_EXCEPTION(hr);
-
-                       return TRUE;}
-
-                 default:
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-       } catch(COMException& e) {
-               HandleException(e, _hwnd);
-       }
-
-       return 0;
-}
-
-
-String WebChildWindow::jump_to_int(LPCTSTR url)
-{
-       _navigator.goto_url(url);
-
-       return url;
-}
diff --git a/reactos/subsys/system/explorer/shell/webchild.h b/reactos/subsys/system/explorer/shell/webchild.h
deleted file mode 100644 (file)
index 4347dc7..0000000
+++ /dev/null
@@ -1,1013 +0,0 @@
-/*
- * Copyright 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // webchild.h
- //
- // Martin Fuchs, 08.02.2004
- //
-
-
-#ifndef _MSC_VER
-#include <exdisp.h>            // for IConnectionPointContainer
-#include <exdispid.h>  // for DWebBrowserEvents2 IDs
-#endif
-
-#ifndef DISPID_BEFORENAVIGATE  // missing in MinGW (as of 07.02.2004)
-#define DISPID_BEFORENAVIGATE                  100
-#define DISPID_NAVIGATECOMPLETE                        101
-#define DISPID_STATUSTEXTCHANGE                        102
-#define DISPID_QUIT                                            103
-#define DISPID_DOWNLOADCOMPLETE                        104
-#define DISPID_COMMANDSTATECHANGE              105
-#define DISPID_DOWNLOADBEGIN                   106
-#define DISPID_NEWWINDOW                               107
-#define DISPID_PROGRESSCHANGE                  108
-#define DISPID_WINDOWMOVE                              109
-#define DISPID_WINDOWRESIZE                            110
-#define DISPID_WINDOWACTIVATE                  111
-#define DISPID_PROPERTYCHANGE                  112
-#define DISPID_TITLECHANGE                             113
-#define DISPID_TITLEICONCHANGE                 114
-#define DISPID_FRAMEBEFORENAVIGATE             200
-#define DISPID_FRAMENAVIGATECOMPLETE   201
-#define DISPID_FRAMENEWWINDOW                  204
-
-#define DISPID_NAVIGATECOMPLETE2               252
-#define DISPID_ONQUIT                                  253
-#define DISPID_ONVISIBLE                               254
-#define DISPID_ONTOOLBAR                               255
-#define DISPID_ONMENUBAR                               256
-#define DISPID_ONSTATUSBAR                             257
-#define DISPID_ONFULLSCREEN                            258
-#define DISPID_DOCUMENTCOMPLETE                        259
-#define DISPID_ONTHEATERMODE                   260
-#define DISPID_ONADDRESSBAR                            261
-#define DISPID_WINDOWSETRESIZABLE              262
-#define DISPID_WINDOWCLOSING                   263
-#define DISPID_WINDOWSETLEFT                   264
-#define DISPID_WINDOWSETTOP                            265
-#define DISPID_WINDOWSETWIDTH                  266
-#define DISPID_WINDOWSETHEIGHT                 267
-#define DISPID_CLIENTTOHOSTWINDOW              268
-#define DISPID_SETSECURELOCKICON               269
-#define DISPID_FILEDOWNLOAD                            270
-#define DISPID_NAVIGATEERROR                   271
-#define DISPID_PRIVACYIMPACTEDSTATECHANGE 272
-#endif
-
-#ifndef V_INT  // missing in MinGW (as of 07.02.2004)
-#define        V_INT(x) V_UNION(x, intVal)
-#endif
-
-#ifdef _MSC_VER
-#pragma warning(disable: 4355) // use of 'this' for initialization of _connector
-#endif
-
-
-template<typename T> struct ConnectionPoint : public SIfacePtr<T>
-{
-       ConnectionPoint(IConnectionPointContainer* pCPC, REFIID riid)
-       {
-               CheckError(pCPC->FindConnectionPoint(riid, &this->_p));
-       }
-};
-
-struct EventConnection
-{
-       EventConnection(IConnectionPoint* connectionpoint, IUnknown* sink)
-       {
-               CheckError(connectionpoint->Advise(sink, &_cookie));
-               _connectionpoint = connectionpoint;
-       }
-
-       template<typename T> EventConnection(T& connectionpoint, IUnknown* sink)
-       {
-               CheckError(connectionpoint->Advise(sink, &_cookie));
-               _connectionpoint = connectionpoint;
-       }
-
-/*     template<typename T> EventConnection(SIfacePtr<T>& connectionpoint, IUnknown* sink)
-       {
-               CheckError(connectionpoint->Advise(sink, &_cookie));
-               _connectionpoint = connectionpoint.GetPtr();
-       } */
-
-/*     template<typename T> EventConnection(T& connectionpoint, IUnknown* sink)
-       {
-               CheckError(connectionpoint->Advise(sink, &_cookie));
-               _connectionpoint = connectionpoint;
-       } */
-
-       ~EventConnection()
-       {
-               if (_connectionpoint)
-                       _connectionpoint->Unadvise(_cookie);
-       }
-
-protected:
-       SIfacePtr<IConnectionPoint> _connectionpoint;
-       DWORD   _cookie;
-};
-
-struct EventConnector : public EventConnection
-{
-       EventConnector(IUnknown* unknown, REFIID riid, IUnknown* sink)
-        :      EventConnection(ConnectionPoint<IConnectionPoint>(
-                               SIfacePtr<IConnectionPointContainer>(unknown, IID_IConnectionPointContainer), riid), sink)
-       {
-       }
-};
-
-
-struct OleInPlaceClient : public SimpleComObject,
-                                                       public IOleClientSite,
-                                                       public IOleInPlaceSite
-{
-protected:
-       HWND    _hwnd;
-
-public:
-       OleInPlaceClient(HWND hwnd=0)
-        :      _hwnd(hwnd)
-       {
-       }
-
-       void attach(HWND hwnd)
-       {
-               _hwnd = hwnd;
-       }
-
-       HRESULT attach_control(IOleObject* ole_obj, LONG iVerb=OLEIVERB_INPLACEACTIVATE, HWND hwndParent=0, LPCRECT pRect=NULL)
-       {
-               HRESULT hr = ole_obj->SetClientSite(this);
-               if (FAILED(hr))
-                       return hr;
-
-//             hr = ole_obj->SetHostNames(app, doc));
-
-               hr = ole_obj->DoVerb(iVerb, NULL, this, 0, 0/*hwnd*/, NULL/*&rcPos*/);
-
-               return hr;
-       }
-
-       HRESULT detach(IOleObject* ole_obj, DWORD dwSaveOption=OLECLOSE_SAVEIFDIRTY)
-       {
-               HRESULT hr = ole_obj->Close(dwSaveOption);
-
-               _hwnd = 0;
-
-               return hr;
-       }
-
-       STDMETHODIMP QueryInterface(REFIID riid, LPVOID* ppv)
-       {
-               if (IsEqualIID(riid, IID_IOleClientSite))
-                       {*ppv=static_cast<IOleClientSite*>(this); IncRef(); return S_OK;}
-
-               if (IsEqualIID(riid, IID_IOleInPlaceSite))
-                       {*ppv=static_cast<IOleInPlaceSite*>(this); IncRef(); return S_OK;}
-
-               if (IsEqualIID(riid, IID_IUnknown))
-                       {*ppv=static_cast<IOleClientSite/*oder auch IOleInPlaceSite*/*>(this); IncRef(); return S_OK;}
-
-               return E_NOINTERFACE;
-       }
-
-       STDMETHODIMP_(ULONG) AddRef() {return IncRef();}
-       STDMETHODIMP_(ULONG) Release() {return DecRef();}
-
-
-        // IOleWindow:
-
-       virtual /* [input_sync] */ HRESULT STDMETHODCALLTYPE GetWindow(/* [out] */ HWND __RPC_FAR *phwnd)
-       {
-               *phwnd = _hwnd;
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE ContextSensitiveHelp(/* [in] */ BOOL fEnterMode)
-       {
-               return E_NOTIMPL;
-       }
-
-
-        // IOleClientSite:
-
-       virtual HRESULT STDMETHODCALLTYPE SaveObject()
-       {
-               return E_NOTIMPL;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE GetMoniker(DWORD dwAssign, DWORD dwWhichMoniker, IMoniker __RPC_FAR *__RPC_FAR *ppmk)
-       {
-               return E_NOTIMPL;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE GetContainer(IOleContainer __RPC_FAR *__RPC_FAR *ppContainer)
-       {
-               ppContainer = 0;
-               return E_NOINTERFACE;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE ShowObject()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnShowWindow(BOOL fShow)
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE RequestNewObjectLayout()
-       {
-               return S_OK;
-       }
-
-
-        // IOleInPlaceSite:
-
-       virtual HRESULT STDMETHODCALLTYPE CanInPlaceActivate()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnInPlaceActivate()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnUIActivate()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE GetWindowContext(
-               /* [out] */ IOleInPlaceFrame __RPC_FAR *__RPC_FAR *ppFrame,
-               /* [out] */ IOleInPlaceUIWindow __RPC_FAR *__RPC_FAR *ppDoc,
-               /* [out] */ LPRECT lprcPosRect,
-               /* [out] */ LPRECT lprcClipRect,
-               /* [out][in] */ LPOLEINPLACEFRAMEINFO lpFrameInfo)
-       {
-               ClientRect rect(_hwnd);
-
-               ppFrame = 0;
-               ppDoc = 0;
-               *lprcPosRect = rect;
-               *lprcClipRect = rect;
-
-               assert(lpFrameInfo->cb>=sizeof(OLEINPLACEFRAMEINFO));
-               lpFrameInfo->fMDIApp = FALSE;   //@@
-               lpFrameInfo->hwndFrame = 0;
-               lpFrameInfo->haccel = 0;
-               lpFrameInfo->cAccelEntries = 0;
-
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE Scroll(/* [in] */ SIZE scrollExtant)
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnUIDeactivate(/* [in] */ BOOL fUndoable)
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnInPlaceDeactivate()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE DiscardUndoState()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE DeactivateAndUndo()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnPosRectChange(/* [in] */ LPCRECT lprcPosRect)
-       {
-               return S_OK;
-       }
-};
-
-
- // window with in place activates Active-X Control
-
-template<typename BASE, typename SMARTPTR> struct IPCtrlWindow : public BASE
-{
-       typedef BASE super;
-
-       IPCtrlWindow(HWND hwnd)
-        :      super(hwnd)
-       {
-       }
-
-       template<typename T> IPCtrlWindow(HWND hwnd, T& info)
-        :      super(hwnd, info)
-       {
-       }
-
-       HRESULT create_control(HWND hwnd, REFIID clsid, REFIID riid)
-       {
-                // Erzeugen einer Instanz des Controls
-               HRESULT hr = _control.CreateInstance(clsid, riid);
-               if (FAILED(hr))
-                       return hr;
-
-               _client_side.attach(hwnd);
-
-               hr = _client_side.attach_control(SIfacePtr<IOleObject>(_control, IID_IOleObject)/*, OLEIVERB_INPLACEACTIVATE,
-                                                                                       hwnd, &Rect(10, 10, 500, 500)*/);
-               if (FAILED(hr))
-                       return hr;
-
-                // try to get a IOleInPlaceObject interface for window resizing
-               return _control.QueryInterface(IID_IOleInPlaceObject, &_in_place_object);       // _in_place_object = _control
-       }
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               if (nmsg == WM_SIZE) {
-                       if (_in_place_object) {
-                               RECT rect = {0, 0, LOWORD(lparam), HIWORD(lparam)};
-
-                               _in_place_object->SetObjectRects(&rect, &rect);
-                       }
-               } else if (nmsg == WM_CLOSE) {
-                       _in_place_object = NULL;
-
-                       if (_control) {
-                               _client_side.detach(SIfacePtr<IOleObject>(_control, IID_IOleObject), OLECLOSE_NOSAVE);
-                               _control = NULL;
-                       }
-               }
-
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       ComInit _usingCOM;
-       SMARTPTR _control;
-       OleInPlaceClient _client_side;
-       SIfacePtr<IOleInPlaceObject> _in_place_object;
-};
-
-
-
-#include "exdispid.h"
-
-
-struct DWebBrowserEvents2IF
-{
-       virtual ~DWebBrowserEvents2IF() {}
-
-    virtual void StatusTextChange(const BStr& text)
-               {}
-
-    virtual void ProgressChange(long progress, long progressMax)
-               {}
-
-    virtual void WindowMove()
-               {}
-
-    virtual void WindowResize()
-               {}
-
-    virtual void WindowActivate()
-               {}
-
-    virtual void PropertyChange(const BStr& property)
-               {}
-
-    virtual void DownloadComplete()
-               {}
-
-    virtual void CommandStateChange(long command, bool enable)
-               {}
-
-    virtual void DownloadBegin()
-               {}
-
-    virtual void NewWindow2(IDispatch** ppDisp, VARIANT_BOOL& cancel)
-               {}
-
-    virtual void TitleChange(const BStr& text)
-               {}
-
-    virtual void TitleIconChange(const BStr& text)
-               {}
-
-       virtual void FrameBeforeNavigate(const BStr& url, long flags, const BStr& targetFrameName, VARIANT* postData, const BStr& headers, VARIANT_BOOL& cancel)
-               {}
-
-       virtual void FrameNavigateComplete(const BStr& url)
-               {}
-
-       virtual void FrameNewWindow(const BStr&url, long flags, const BStr& targetFrameName, VARIANT* postData, const BStr& headers, VARIANT_BOOL& processed)
-               {}
-
-    virtual void BeforeNavigate2(IDispatch* pDisp, const Variant& url, const Variant& flags,
-                                                       const Variant& targetFrameName, const Variant& postData,
-                                                       const Variant& headers, VARIANT_BOOL& cancel)
-               {}
-
-    virtual void NavigateComplete2(IDispatch* pDisp, const Variant& url)
-               {}
-
-    virtual void OnQuit()
-               {}
-
-       virtual void OnVisible(bool Visible)
-               {}
-
-       virtual void OnToolbar(bool Visible)
-               {}
-
-       virtual void OnMenubar(bool Visible)
-               {}
-
-       virtual void OnStatusbar(bool Visible)
-               {}
-
-       virtual void OnFullscreen(bool Visible)
-               {}
-
-    virtual void DocumentComplete()
-               {}
-
-       virtual void OnTheatermode(bool Visible)
-               {}
-
-       virtual void OnAddressbar(bool Visible)
-               {}
-
-       virtual void WindowSetResizable(bool Visible)
-               {}
-
-       virtual void WindowClosing(VARIANT_BOOL IsChildWindow, VARIANT_BOOL& cancel)
-               {}
-
-       virtual void WindowSetLeft(long Left)
-               {}
-
-       virtual void WindowSetTop(long Top)
-               {}
-
-       virtual void WindowSetWidth(long Width)
-               {}
-
-       virtual void WindowSetHeight(long Height)
-               {}
-
-       virtual void ClientToHostWindow(long& CX, long& CY)
-               {}
-
-       virtual void SetSecureLockIcon(long SecureLockIcon)
-               {}
-
-    virtual void FileDownload(Variant& cancel)
-               {}
-
-    virtual void NavigateError(IDispatch* pDisp, const Variant& url, const Variant& Frame, const Variant& StatusCode, VARIANT_BOOL& cancel)
-               {}
-
-    virtual void PrivacyImpactedStateChange(bool bImpacted)
-               {}
-};
-
-
- // The web browser control has to be initialized completely before being able,
- // to display a page, that does not access internet.
-struct ANSUNC BrowserNavigator
-{
-       BrowserNavigator();
-
-       void    attach(IWebBrowser* browser);
-       void    goto_url(LPCTSTR url);
-       void    set_html_page(const String& html_txt);
-       void    navigated(LPCTSTR url);
-
-       IWebBrowser* get_browser() {return _browser.get();}
-
-protected:
-       SIfacePtr<IWebBrowser> _browser;
-       String  _new_url;
-       String  _new_html_txt;
-       bool    _browser_initialized;
-};
-
-
- // MinGW defines a wrong FixedDWebBrowserEvents2 interface with virtual functions for DISPID calls, so we use our own, corrected version:
-interface FixedDWebBrowserEvents2 : public IDispatch
-{
-#ifdef __GNUC__
-       virtual ~FixedDWebBrowserEvents2() {}
-#endif
-};
-
-struct ANSUNC DWebBrowserEvents2Impl
- :     public IComSrvBase<FixedDWebBrowserEvents2, DWebBrowserEvents2Impl>, public SimpleComObject,
-       public DWebBrowserEvents2IF
-{
-       typedef IComSrvBase<FixedDWebBrowserEvents2, DWebBrowserEvents2Impl> super;
-
-
-       DWebBrowserEvents2IF* _callback;
-
-
-       DWebBrowserEvents2Impl(BrowserNavigator& navigator)
-        :      super(DIID_DWebBrowserEvents2),
-               _navigator(navigator)
-       {
-               _callback = this;
-       }
-
-
-/*      // IUnknown
-    STDMETHOD(QueryInterface)(REFIID riid, LPVOID* ppv)
-       {
-               *ppv = NULL;
-
-               if (SUCCEEDED(super::QueryInterface(riid, ppv)))
-                       return S_OK;
-
-               return E_NOINTERFACE;
-       } */
-
-
-        // IDispatch
-       STDMETHOD(GetTypeInfoCount)(UINT* pctinfo)
-               {return E_NOTIMPL;}
-
-       STDMETHOD(GetTypeInfo)(UINT iTInfo, LCID lcid, ITypeInfo** ppTInfo)
-               {return E_NOTIMPL;}
-
-       STDMETHOD(GetIDsOfNames)(REFIID riid, LPOLESTR* rgszNames, UINT cNames, LCID lcid, DISPID* rgDispId)
-               {return E_NOTIMPL;}
-
-       STDMETHOD(Invoke)(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags,
-                                               DISPPARAMS __RPC_FAR *pDispParams, VARIANT __RPC_FAR *pVarResult, EXCEPINFO __RPC_FAR *pExcepInfo, UINT __RPC_FAR *puArgErr)
-       {
-               switch(dispIdMember) {
-                 case DISPID_STATUSTEXTCHANGE:
-                       _callback->StatusTextChange((BStr)Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_COMMANDSTATECHANGE:
-                       _callback->CommandStateChange(Variant(pDispParams->rgvarg[1]), Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_DOWNLOADBEGIN:
-                       _callback->DownloadBegin();
-                       break;
-
-                 case DISPID_PROGRESSCHANGE:   // sent when download progress is updated
-                       _callback->ProgressChange(Variant(pDispParams->rgvarg[1]), Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWMOVE:               // sent when main window has been moved
-                       _callback->WindowMove();
-                       break;
-
-                 case DISPID_WINDOWRESIZE:             // sent when main window has been sized
-                       _callback->WindowResize();
-                       break;
-
-                 case DISPID_WINDOWACTIVATE:   // sent when main window has been activated
-                       _callback->WindowActivate();
-                       break;
-
-                 case DISPID_PROPERTYCHANGE:   // sent when the PutProperty method is called
-                       _callback->PropertyChange((BStr)Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_TITLECHANGE:              // sent when the document title changes
-                       _callback->TitleChange((BStr)Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_TITLEICONCHANGE:  // sent when the top level window icon may have changed.
-                       _callback->TitleIconChange((BStr)Variant(pDispParams->rgvarg[0]));
-                       break;
-
-
-                       // anything below here is not present in DWebBrowserEvents, only in DWebBrowserEvents2: ->
-
-                 case DISPID_FRAMEBEFORENAVIGATE:
-                       if (pDispParams->cArgs != 6)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->FrameBeforeNavigate(
-                                                                 (BStr)Variant(&pDispParams->rgvarg[5]), Variant(&pDispParams->rgvarg[4]),
-                                                                 (BStr)Variant(&pDispParams->rgvarg[3]), &pDispParams->rgvarg[2],
-                                                                 (BStr)Variant(&pDispParams->rgvarg[1]), *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_FRAMENAVIGATECOMPLETE:
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->FrameNavigateComplete((BStr)Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_FRAMENEWWINDOW:
-                       if (pDispParams->cArgs != 6)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->FrameNewWindow((BStr)Variant(&pDispParams->rgvarg[5]), Variant(&pDispParams->rgvarg[4]),
-                                                                 (BStr)Variant(&pDispParams->rgvarg[3]), &pDispParams->rgvarg[2],
-                                                                 (BStr)Variant(&pDispParams->rgvarg[1]), *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_BEFORENAVIGATE2:  // hyperlink clicked on
-                       if (pDispParams->cArgs != 7)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->BeforeNavigate2(Variant(pDispParams->rgvarg[6]),
-                                                                 pDispParams->rgvarg[5], &pDispParams->rgvarg[4],
-                                                                 pDispParams->rgvarg[3], &pDispParams->rgvarg[2],
-                                                                 pDispParams->rgvarg[1], *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_NEWWINDOW2:               // sent when a new window should be created
-                       if (pDispParams->cArgs != 2)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[1]) != (VT_DISPATCH|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->NewWindow2(V_DISPATCHREF(&pDispParams->rgvarg[1]), *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_NAVIGATECOMPLETE2:// UIActivate new document
-                       if (pDispParams->cArgs != 2)
-                               return E_INVALIDARG;
-
-                        // notify the navigator
-                       NavigateComplete2(Variant(pDispParams->rgvarg[1]), Variant(pDispParams->rgvarg[0]));
-
-                       _callback->NavigateComplete2(Variant(pDispParams->rgvarg[1]), Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONQUIT:
-                       _callback->OnQuit();
-                       break;
-
-                 case DISPID_ONVISIBLE:                // sent when the window goes visible/hidden
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnVisible(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONTOOLBAR:                // sent when the toolbar should be shown/hidden
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnToolbar(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONMENUBAR:                // sent when the menubar should be shown/hidden
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnMenubar(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONSTATUSBAR:              // sent when the statusbar should be shown/hidden
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnStatusbar(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONFULLSCREEN:             // sent when kiosk mode should be on/off
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnFullscreen(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_DOCUMENTCOMPLETE:// new document goes ReadyState_Complete
-                       _callback->DocumentComplete();
-                       break;
-
-                 case DISPID_DOWNLOADCOMPLETE:
-                       _callback->DownloadComplete();
-                       break;
-
-                 case DISPID_ONTHEATERMODE:    // sent when theater mode should be on/off
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnTheatermode(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONADDRESSBAR:             // sent when the address bar should be shown/hidden
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnAddressbar(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWSETRESIZABLE:// sent to set the style of the host window frame
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->WindowSetResizable(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWCLOSING:    // sent before script window.close closes the window
-                       if (pDispParams->cArgs != 2)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->WindowClosing(Variant(pDispParams->rgvarg[1]), *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWSETLEFT:    // sent when the put_left method is called on the WebOC
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->WindowSetLeft(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWSETTOP:             // sent when the put_top method is called on the WebOC
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->WindowSetTop(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWSETWIDTH:   // sent when the put_width method is called on the WebOC
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->WindowSetWidth(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWSETHEIGHT:  // sent when the put_height method is called on the WebOC
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->WindowSetHeight(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_CLIENTTOHOSTWINDOW:// sent during window.open to request conversion of dimensions
-                       if (pDispParams->cArgs != 2)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_I4|VT_BYREF))
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[1]) != (VT_I4|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->ClientToHostWindow(*V_I4REF(&pDispParams->rgvarg[1]), *V_I4REF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_SETSECURELOCKICON:// sent to suggest the appropriate security icon to show
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->SetSecureLockIcon(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_FILEDOWNLOAD: {   // Fired to indicate the File Download dialog is opening
-                       if (pDispParams->cArgs != 1)    //@@ every time 2 ?!
-                               return E_INVALIDARG;
-                       Variant var(pDispParams->rgvarg[0]);
-                       _callback->FileDownload(var);}
-                       break;
-
-                 case DISPID_NAVIGATEERROR:    // Fired to indicate the a binding error has occured
-                       if (pDispParams->cArgs != 5)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->NavigateError(Variant(pDispParams->rgvarg[4]), Variant(pDispParams->rgvarg[3]),
-                                                               Variant(pDispParams->rgvarg[2]), Variant(pDispParams->rgvarg[1]),
-                                                               *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_PRIVACYIMPACTEDSTATECHANGE:// Fired when the user's browsing experience is impacted
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->PrivacyImpactedStateChange(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 default:
-                       return NOERROR;
-               }
-
-               return S_OK;
-       }
-
-protected:
-       BrowserNavigator& _navigator;
-
-       void NavigateComplete2(IDispatch* pDisp, const Variant& url)
-       {
-               String adr = (BStr)url;
-
-               _navigator.navigated(adr);
-       }
-};
-
-
- /// encapsulation of Web control in MDI child windows
-struct WebChildWindow : public IPCtrlWindow<ChildWindow, SIfacePtr<IWebBrowser2> >,
-                                               public DWebBrowserEvents2Impl
-{
-       typedef IPCtrlWindow<ChildWindow, SIfacePtr<IWebBrowser2> > super;
-       typedef DWebBrowserEvents2Impl web_super;
-
-       WebChildWindow(HWND hwnd, const WebChildWndInfo& info);
-
-       static WebChildWindow* create(const FileChildWndInfo& info)
-       {
-               ChildWindow* child = ChildWindow::create(info, info._pos.rcNormalPosition,
-                       WINDOW_CREATOR_INFO(WebChildWindow,WebChildWndInfo), CLASSNAME_CHILDWND, NULL, info._pos.showCmd==SW_SHOWMAXIMIZED? WS_MAXIMIZE: 0);
-
-               return static_cast<WebChildWindow*>(child);
-       }
-
-
-        // DWebBrowserEvents2Impl overides ->
-
-    void BeforeNavigate2(IDispatch* pDisp, const Variant& url, const Variant& flags,
-                                                       const Variant& targetFrameName, const Variant& postData,
-                                                       const Variant& headers, VARIANT_BOOL& cancel)
-       {
-               //String adr = (BStr)url;
-       }
-
-    void NavigateComplete2(IDispatch* pDisp, const Variant& url)
-       {
-               web_super::NavigateComplete2(pDisp, url);
-
-               set_url(String(BStr(url)));
-       }
-
-    void StatusTextChange(const BStr& text)
-       {
-               _statusText = text;
-               SendMessage(_hwndFrame, PM_SETSTATUSTEXT, 0, (LPARAM)_statusText.c_str());
-       }
-
-    void ProgressChange(long Progress, long ProgressMax)
-       {
-       }
-
-    void WindowMove()
-       {
-       }
-
-    void WindowResize()
-       {
-       }
-
-    void WindowActivate()
-       {
-       }
-
-    void PropertyChange(const BStr& Property)
-       {
-               Variant value;
-               _control->GetProperty(Property, &value);
-       }
-
-    void CommandStateChange(long command/*CSC_NAVIGATEFORWARD, CSC_NAVIGATEBACK*/, bool enable)
-       {
-       }
-
-    void DownloadBegin()
-       {
-       }
-
-    void NewWindow2(IDispatch** ppDisp, VARIANT_BOOL& cancel)
-       {
-               //*ppDisp = ;
-               //cancel = TRUE;
-       }
-
-    void TitleChange(const BStr& text)
-       {
-               SetWindowText(_hwnd, String(text));
-       }
-
-    void TitleIconChange(const BStr& text)
-       {
-       }
-
-    void FrameBeforeNavigate(const BStr& url, long flags, const BStr& targetFrameName, VARIANT* postData, const BStr& headers, VARIANT_BOOL& cancel)
-       {
-       }
-
-    void FrameNavigateComplete(const BStr& url)
-       {
-       }
-
-    void FrameNewWindow(const BStr& url, long flags, const BStr& targetFrameName, VARIANT* postData, const BStr& headers, VARIANT_BOOL& processed)
-       {
-       }
-
-    void OnQuit()
-       {
-       }
-
-       void OnVisible(bool Visible)
-       {
-       }
-
-       void OnToolbar(bool Visible)
-       {
-       }
-
-       void OnMenubar(bool Visible)
-       {
-       }
-
-       void OnStatusbar(bool Visible)
-       {
-       }
-
-       void OnFullscreen(bool Visible)
-       {
-       }
-
-    void DocumentComplete()
-       {
-       }
-
-       void OnTheatermode(bool Visible)
-       {
-       }
-
-       void OnAddressbar(bool Visible)
-       {
-       }
-
-       void WindowSetResizable(bool Visible)
-       {
-       }
-
-       void WindowClosing(VARIANT_BOOL IsChildWindow, VARIANT_BOOL& cancel)
-       {
-       }
-
-       void WindowSetLeft(long Left)
-       {
-       }
-
-       void WindowSetTop(long Top)
-       {
-       }
-
-       void WindowSetWidth(long Width)
-       {
-       }
-
-       void WindowSetHeight(long Height)
-       {
-       }
-
-       void ClientToHostWindow(long& CX, long& CY)
-       {
-       }
-
-       void SetSecureLockIcon(long SecureLockIcon)
-       {
-       }
-
-    void FileDownload(Variant& cancel)
-       {
-       }
-
-    void NavigateError(IDispatch* pDisp, const Variant& url, const Variant& Frame, const Variant& StatusCode, VARIANT_BOOL& cancel)
-       {
-       }
-
-    void PrivacyImpactedStateChange(bool bImpacted)
-       {
-       }
-
-
-protected:
-       BrowserNavigator _navigator;
-       auto_ptr<EventConnector> _connector;
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       virtual String jump_to_int(LPCTSTR url);
-};
diff --git a/reactos/subsys/system/explorer/shell/winfs.cpp b/reactos/subsys/system/explorer/shell/winfs.cpp
deleted file mode 100644 (file)
index a2a1c88..0000000
+++ /dev/null
@@ -1,252 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // winfs.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include <precomp.h>
-
-#ifndef _NO_WIN_FS
-
-//#include "winfs.h"
-
-
-int ScanNTFSStreams(Entry* entry, HANDLE hFile)
-{
-       PVOID ctx = 0;
-       DWORD read, seek_high;
-       Entry** pnext = &entry->_down;
-       int cnt = 0;
-
-       for(;;) {
-               struct NTFS_StreamHdr : public WIN32_STREAM_ID {
-                       WCHAR name_padding[_MAX_FNAME]; // room for reading stream name
-               } hdr;
-
-               if (!BackupRead(hFile, (LPBYTE)&hdr, (LPBYTE)&hdr.cStreamName-(LPBYTE)&hdr, &read, FALSE, FALSE, &ctx) ||
-                       (long)read!=(LPBYTE)&hdr.cStreamName-(LPBYTE)&hdr)
-                       break;
-
-               if (hdr.dwStreamId == BACKUP_ALTERNATE_DATA) {
-                       if (hdr.dwStreamNameSize &&
-                               BackupRead(hFile, (LPBYTE)hdr.cStreamName, hdr.dwStreamNameSize, &read, FALSE, FALSE, &ctx) &&
-                               read==hdr.dwStreamNameSize)
-                       {
-                               ++cnt;
-
-                               int l = hdr.dwStreamNameSize / sizeof(WCHAR);
-                               LPCWSTR p = hdr.cStreamName;
-                               LPCWSTR e = hdr.cStreamName + l;
-
-                               if (l>0 && *p==':') {
-                                       ++p, --l;
-
-                                       e = p;
-
-                                       while(l>0 && *e!=':')
-                                               ++e, --l;
-
-                                       l = e - p;
-                               }
-
-                               Entry* stream_entry = new WinEntry(entry);
-
-                               memcpy(&stream_entry->_data, &entry->_data, sizeof(WIN32_FIND_DATA));
-                               lstrcpy(stream_entry->_data.cFileName, String(p, l));
-
-                               stream_entry->_down = NULL;
-                               stream_entry->_expanded = false;
-                               stream_entry->_scanned = false;
-                               stream_entry->_level = entry->_level + 1;
-
-                               *pnext = stream_entry;
-                               pnext = &stream_entry->_next;
-                       }
-               }
-
-                // jump to the next stream header
-               if (!BackupSeek(hFile, ~0, ~0, &read, &seek_high, &ctx)) {
-                       DWORD error = GetLastError();
-
-                       if (error != ERROR_SEEK) {
-                               BackupRead(hFile, 0, 0, &read, TRUE, FALSE, &ctx);      // terminate BackupRead() loop
-                               THROW_EXCEPTION(error);
-                               //break;
-                       }
-
-                       hdr.Size.QuadPart -= read;
-                       hdr.Size.HighPart -= seek_high;
-
-                       BYTE buffer[4096];
-
-                       while(hdr.Size.QuadPart > 0) {
-                               if (!BackupRead(hFile, buffer, sizeof(buffer), &read, FALSE, FALSE, &ctx) || read!=sizeof(buffer))
-                                       break;
-
-                               hdr.Size.QuadPart -= read;
-                       }
-               }
-       }
-
-       if (ctx)
-               if (!BackupRead(hFile, 0, 0, &read, TRUE, FALSE, &ctx)) // terminate BackupRead() loop
-                       THROW_EXCEPTION(GetLastError());
-
-       return cnt;
-}
-
-
-void WinDirectory::read_directory(int scan_flags)
-{
-       CONTEXT("WinDirectory::read_directory()");
-
-       int level = _level + 1;
-
-       Entry* first_entry = NULL;
-       Entry* last = NULL;
-       Entry* entry;
-
-       LPCTSTR path = (LPCTSTR)_path;
-       TCHAR buffer[MAX_PATH], *pname;
-       for(pname=buffer; *path; )
-               *pname++ = *path++;
-
-       lstrcpy(pname, TEXT("\\*"));
-
-       WIN32_FIND_DATA w32fd;
-       HANDLE hFind = FindFirstFile(buffer, &w32fd);
-
-       if (hFind != INVALID_HANDLE_VALUE) {
-               do {
-                       lstrcpy(pname+1, w32fd.cFileName);
-
-                       if (w32fd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                               entry = new WinDirectory(this, buffer);
-                       else
-                               entry = new WinEntry(this);
-
-                       if (!first_entry)
-                               first_entry = entry;
-
-                       if (last)
-                               last->_next = entry;
-
-                       memcpy(&entry->_data, &w32fd, sizeof(WIN32_FIND_DATA));
-                       entry->_level = level;
-
-                        // display file type names, but don't hide file extensions
-                       g_Globals._ftype_mgr.set_type(entry, true);
-
-                       if (!(scan_flags & SCAN_DONT_ACCESS)) {
-                               HANDLE hFile = CreateFile(buffer, GENERIC_READ, FILE_SHARE_READ|FILE_SHARE_WRITE|FILE_SHARE_DELETE,
-                                                                                       0, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, 0);
-
-                               if (hFile != INVALID_HANDLE_VALUE) {
-                                       if (GetFileInformationByHandle(hFile, &entry->_bhfi))
-                                               entry->_bhfi_valid = true;
-
-                                       if (ScanNTFSStreams(entry, hFile))
-                                               entry->_scanned = true; // There exist named NTFS sub-streams in this file.
-
-                                       CloseHandle(hFile);
-                               }
-                       }
-
-                       last = entry;   // There is always at least one entry, because FindFirstFile() succeeded and we don't filter the file entries.
-               } while(FindNextFile(hFind, &w32fd));
-
-               if (last)
-                       last->_next = NULL;
-
-               FindClose(hFind);
-       }
-
-       _down = first_entry;
-       _scanned = true;
-}
-
-
-const void* WinDirectory::get_next_path_component(const void* p) const
-{
-       LPCTSTR s = (LPCTSTR) p;
-
-       while(*s && *s!=TEXT('\\') && *s!=TEXT('/'))
-               ++s;
-
-       while(*s==TEXT('\\') || *s==TEXT('/'))
-               ++s;
-
-       if (!*s)
-               return NULL;
-
-       return s;
-}
-
-
-Entry* WinDirectory::find_entry(const void* p)
-{
-       LPCTSTR name = (LPCTSTR)p;
-
-       for(Entry*entry=_down; entry; entry=entry->_next) {
-               LPCTSTR p = name;
-               LPCTSTR q = entry->_data.cFileName;
-
-               do {
-                       if (!*p || *p==TEXT('\\') || *p==TEXT('/'))
-                               return entry;
-               } while(tolower(*p++) == tolower(*q++));
-
-               p = name;
-               q = entry->_data.cAlternateFileName;
-
-               do {
-                       if (!*p || *p==TEXT('\\') || *p==TEXT('/'))
-                               return entry;
-               } while(tolower(*p++) == tolower(*q++));
-       }
-
-       return NULL;
-}
-
-
- // get full path of specified directory entry
-bool WinEntry::get_path(PTSTR path, size_t path_count) const
-{
-       return get_path_base(path, path_count, ET_WINDOWS);
-}
-
-ShellPath WinEntry::create_absolute_pidl() const
-{
-       CONTEXT("WinEntry::create_absolute_pidl()");
-
-       TCHAR path[MAX_PATH];
-
-       if (get_path(path, COUNTOF(path)))
-               return ShellPath(path);
-
-       return ShellPath();
-}
-
-#endif // _NO_WIN_FS
diff --git a/reactos/subsys/system/explorer/shell/winfs.h b/reactos/subsys/system/explorer/shell/winfs.h
deleted file mode 100644 (file)
index c2954b4..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // winfs.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
- /// Windows file system file-entry
-struct WinEntry : public Entry
-{
-       WinEntry(Entry* parent) : Entry(parent, ET_WINDOWS) {}
-
-protected:
-       WinEntry() : Entry(ET_WINDOWS) {}
-
-       virtual bool get_path(PTSTR path, size_t path_count) const;
-       virtual ShellPath create_absolute_pidl() const;
-};
-
-
- /// Windows file system directory-entry
-struct WinDirectory : public WinEntry, public Directory
-{
-       WinDirectory(LPCTSTR root_path)
-        :      WinEntry()
-       {
-               _path = _tcsdup(root_path);
-       }
-
-       WinDirectory(Entry* parent, LPCTSTR path)
-        :      WinEntry(parent)
-       {
-               _path = _tcsdup(path);
-       }
-
-       ~WinDirectory()
-       {
-               free(_path);
-               _path = NULL;
-       }
-
-       virtual void read_directory(int scan_flags=0);
-       virtual const void* get_next_path_component(const void*) const;
-       virtual Entry* find_entry(const void*);
-};
-
-extern int ScanNTFSStreams(Entry* entry, HANDLE hFile);
diff --git a/reactos/subsys/system/explorer/taskbar/desktopbar.cpp b/reactos/subsys/system/explorer/taskbar/desktopbar.cpp
deleted file mode 100644 (file)
index 9a47520..0000000
+++ /dev/null
@@ -1,542 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // desktopbar.cpp
- //
- // Martin Fuchs, 22.08.2003
- //
-
-
-#include <precomp.h>
-
-#include "../resource.h"
-
-#include "desktopbar.h"
-#include "taskbar.h"
-#include "startmenu.h"
-#include "traynotify.h"
-#include "quicklaunch.h"
-
-#include "../dialogs/settings.h"
-
-
-DesktopBar::DesktopBar(HWND hwnd)
- :     super(hwnd),
-#ifdef _ROS_
-       _trayIcon(hwnd, ID_TRAY_VOLUME)
-#else
-       WM_TASKBARCREATED(RegisterWindowMessage(WINMSG_TASKBARCREATED))
-#endif
-{
-       SetWindowIcon(hwnd, IDI_REACTOS);
-
-       SystemParametersInfo(SPI_GETWORKAREA, 0, &_work_area_org, 0);
-}
-
-DesktopBar::~DesktopBar()
-{
-        // restore work area to the previous size
-       SystemParametersInfo(SPI_SETWORKAREA, 0, &_work_area_org, 0);
-       PostMessage(HWND_BROADCAST, WM_SETTINGCHANGE, SPI_SETWORKAREA, 0);
-
-        // exit application after destroying desktop window
-       PostQuitMessage(0);
-}
-
-
-HWND DesktopBar::Create()
-{
-       static BtnWindowClass wcDesktopBar(CLASSNAME_EXPLORERBAR);
-
-       RECT rect;
-
-       rect.left = -2; // hide left border
-#ifdef TASKBAR_AT_TOP
-       rect.top = -2;  // hide top border
-#else
-       rect.top = GetSystemMetrics(SM_CYSCREEN) - DESKTOPBARBAR_HEIGHT;
-#endif
-       rect.right = GetSystemMetrics(SM_CXSCREEN) + 2;
-       rect.bottom = rect.top + DESKTOPBARBAR_HEIGHT + 2;
-
-       return Window::Create(WINDOW_CREATOR(DesktopBar), WS_EX_PALETTEWINDOW,
-                                                       wcDesktopBar, TITLE_EXPLORERBAR,
-                                                       WS_POPUP|WS_THICKFRAME|WS_CLIPCHILDREN|WS_VISIBLE,
-                                                       rect.left, rect.top, rect.right-rect.left, rect.bottom-rect.top, 0);
-}
-
-
-LRESULT DesktopBar::Init(LPCREATESTRUCT pcs)
-{
-       if (super::Init(pcs))
-               return 1;
-
-        // create start button
-       ResString start_str(IDS_START);
-       WindowCanvas canvas(_hwnd);
-       RECT rect = {0, 0};
-       DrawText(canvas, start_str, -1, &rect, DT_SINGLELINE|DT_CALCRECT);
-       int start_btn_width = rect.right+16+8;
-
-       _taskbar_pos = start_btn_width + 6;
-
-        // create "Start" button
-       HWND hwndStart = Button(_hwnd, start_str, 1, 1, start_btn_width, REBARBAND_HEIGHT, IDC_START, WS_VISIBLE|WS_CHILD|BS_OWNERDRAW);
-       new StartButton(hwndStart);
-        // disable double clicks
-       SetClassLong(hwndStart, GCL_STYLE, GetClassLong(hwndStart, GCL_STYLE) & ~CS_DBLCLKS);
-
-        // create task bar
-       _hwndTaskBar = TaskBar::Create(_hwnd);
-
-#ifndef __MINGW32__ // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || !SHRestricted(REST_NOTRAYITEMSDISPLAY))
-#endif
-                // create tray notification area
-               _hwndNotify = NotifyArea::Create(_hwnd);
-
-
-        // notify all top level windows about the successfully created desktop bar
-        //@@ Use SendMessage() instead of PostMessage() to avoid problems with delayed created shell service objects?
-       PostMessage(HWND_BROADCAST, WM_TASKBARCREATED, 0, 0);
-
-
-       _hwndQuickLaunch = QuickLaunchBar::Create(_hwnd);
-
-        // create rebar window to manage task and quick launch bar
-#ifndef _NO_REBAR
-       _hwndrebar = CreateWindowEx(WS_EX_TOOLWINDOW, REBARCLASSNAME, NULL,
-                                       WS_CHILD|WS_VISIBLE|WS_CLIPSIBLINGS|WS_CLIPCHILDREN|
-                                       RBS_VARHEIGHT|RBS_AUTOSIZE|RBS_DBLCLKTOGGLE|    //|RBS_REGISTERDROP
-                                       CCS_NODIVIDER|CCS_NOPARENTALIGN|CCS_TOP,
-                                       0, 0, 0, 0, _hwnd, 0, g_Globals._hInstance, 0);
-
-       REBARBANDINFO rbBand;
-
-       rbBand.cbSize = sizeof(REBARBANDINFO);
-       rbBand.fMask  = RBBIM_TEXT|RBBIM_STYLE|RBBIM_CHILD|RBBIM_CHILDSIZE|RBBIM_SIZE|RBBIM_ID|RBBIM_IDEALSIZE;
-#ifndef RBBS_HIDETITLE // missing in MinGW headers as of 25.02.2004
-#define RBBS_HIDETITLE 0x400
-#endif
-       rbBand.cyChild = REBARBAND_HEIGHT;
-       rbBand.cyMaxChild = (ULONG)-1;
-       rbBand.cyMinChild = REBARBAND_HEIGHT;
-       rbBand.cyIntegral = REBARBAND_HEIGHT + 3;       //@@ OK?
-       rbBand.cxMinChild = rbBand.cyIntegral * 3;
-       rbBand.fStyle = RBBS_VARIABLEHEIGHT|RBBS_GRIPPERALWAYS|RBBS_HIDETITLE;
-
-       rbBand.lpText = TEXT("Quicklaunch");
-       rbBand.hwndChild = _hwndQuickLaunch;
-       rbBand.cx = 250;
-       rbBand.wID = IDW_QUICKLAUNCHBAR;
-       SendMessage(_hwndrebar, RB_INSERTBAND, (WPARAM)-1, (LPARAM)&rbBand);
-
-       rbBand.lpText = TEXT("Taskbar");
-       rbBand.hwndChild = _hwndTaskBar;
-       rbBand.cx = 200;        //pcs->cx-_taskbar_pos-quicklaunch_width-(notifyarea_width+1);
-       rbBand.wID = IDW_TASKTOOLBAR;
-       SendMessage(_hwndrebar, RB_INSERTBAND, (WPARAM)-1, (LPARAM)&rbBand);
-#endif
-
-
-       RegisterHotkeys();
-
-        // prepare Startmenu, but hide it for now
-       _startMenuRoot = GET_WINDOW(StartMenuRoot, StartMenuRoot::Create(_hwnd, STARTMENUROOT_ICON_SIZE));
-
-       return 0;
-}
-
-
-StartButton::StartButton(HWND hwnd)
- :     PictureButton(hwnd, SmallIcon(IDI_STARTMENU), GetSysColorBrush(COLOR_BTNFACE))
-{
-}
-
-LRESULT        StartButton::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-          // one click activation: handle button-down message, don't wait for button-up
-         case WM_LBUTTONDOWN:
-               if (!Button_GetState(_hwnd)) {
-                       Button_SetState(_hwnd, TRUE);
-
-                       SetCapture(_hwnd);
-
-                       SendMessage(GetParent(_hwnd), WM_COMMAND, MAKEWPARAM(GetDlgCtrlID(_hwnd),0), 0);
-               }
-
-               Button_SetState(_hwnd, FALSE);
-               break;
-
-          // re-target mouse move messages while moving the mouse cursor through the start menu
-         case WM_MOUSEMOVE:
-               if (GetCapture() == _hwnd) {
-                       POINT pt = {GET_X_LPARAM(lparam), GET_Y_LPARAM(lparam)};
-
-                       ClientToScreen(_hwnd, &pt);
-                       HWND hwnd = WindowFromPoint(pt);
-
-                       if (hwnd && hwnd!=_hwnd) {
-                               ScreenToClient(hwnd, &pt);
-                               SendMessage(hwnd, WM_MOUSEMOVE, 0, MAKELPARAM(pt.x, pt.y));
-                       }
-               }
-               break;
-
-         case WM_LBUTTONUP:
-               if (GetCapture() == _hwnd) {
-                       ReleaseCapture();
-
-                       POINT pt = {GET_X_LPARAM(lparam), GET_Y_LPARAM(lparam)};
-
-                       ClientToScreen(_hwnd, &pt);
-                       HWND hwnd = WindowFromPoint(pt);
-
-                       if (hwnd && hwnd!=_hwnd) {
-                               ScreenToClient(hwnd, &pt);
-                               PostMessage(hwnd, WM_LBUTTONDOWN, 0, MAKELPARAM(pt.x, pt.y));
-                               PostMessage(hwnd, WM_LBUTTONUP, 0, MAKELPARAM(pt.x, pt.y));
-                       }
-               }
-               break;
-
-         case WM_CANCELMODE:
-               ReleaseCapture();
-               break;
-
-         default:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-
-void DesktopBar::RegisterHotkeys()
-{
-        // register hotkey WIN+E opening explorer
-       RegisterHotKey(_hwnd, 0, MOD_WIN, 'E');
-
-               ///@todo register all common hotkeys
-}
-
-void DesktopBar::ProcessHotKey(int id_hotkey)
-{
-       switch(id_hotkey) {
-         case 0:       explorer_show_frame(SW_SHOWNORMAL);
-               break;
-
-               ///@todo implement all common hotkeys
-       }
-}
-
-
-LRESULT DesktopBar::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_NCHITTEST: {
-               LRESULT res = super::WndProc(nmsg, wparam, lparam);
-
-               if (res>=HTSIZEFIRST && res<=HTSIZELAST) {
-#ifdef TASKBAR_AT_TOP
-                       if (res == HTBOTTOM)    // enable vertical resizing at the lower border
-#else
-                       if (res == HTTOP)               // enable vertical resizing at the upper border
-#endif
-                               return res;
-                       else
-                               return HTCLIENT;        // disable any other resizing
-               }
-               return res;}
-
-         case WM_SYSCOMMAND:
-               if ((wparam&0xFFF0) == SC_SIZE) {
-#ifdef TASKBAR_AT_TOP
-                       if (wparam == SC_SIZE+6)// enable vertical resizing at the lower border
-#else
-                       if (wparam == SC_SIZE+3)// enable vertical resizing at the upper border
-#endif
-                               goto def;
-                       else
-                               return 0;                       // disable any other resizing
-               } else if (wparam == SC_TASKLIST)
-                       ShowStartMenu();
-               goto def;
-
-         case WM_SIZE:
-               Resize(LOWORD(lparam), HIWORD(lparam));
-               break;
-
-         case WM_SIZING:
-               ControlResize(wparam, lparam);
-               break;
-
-         case PM_RESIZE_CHILDREN: {
-               ClientRect size(_hwnd);
-               Resize(size.right, size.bottom);
-               break;}
-
-         case WM_CLOSE:
-               ShowExitWindowsDialog(_hwnd);
-               break;
-
-         case WM_HOTKEY:
-               ProcessHotKey(wparam);
-               break;
-
-         case WM_COPYDATA:
-               return ProcessCopyData((COPYDATASTRUCT*)lparam);
-
-         case WM_CONTEXTMENU: {
-               PopupMenu menu(IDM_DESKTOPBAR);
-               SetMenuDefaultItem(menu, 0, MF_BYPOSITION);
-               menu.TrackPopupMenu(_hwnd, MAKEPOINTS(lparam));
-               break;}
-
-         case PM_GET_LAST_ACTIVE:
-               if (_hwndTaskBar)
-                       return SendMessage(_hwndTaskBar, nmsg, wparam, lparam);
-               break;
-
-         case PM_REFRESH_CONFIG:       ///@todo read desktop bar settings
-               SendMessage(_hwndNotify, PM_REFRESH_CONFIG, 0, 0);
-               break;
-
-         case WM_TIMER:
-               if (wparam == ID_TRAY_VOLUME) {
-                       KillTimer(_hwnd, wparam);
-                       launch_file(_hwnd, TEXT("sndvol32.exe"), SW_SHOWNORMAL, TEXT("-t"));    // launch volume control in small mode
-               }
-               break;
-
-         case PM_GET_NOTIFYAREA:
-               return (LRESULT)(HWND)_hwndNotify;
-
-         default: def:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-int DesktopBar::Notify(int id, NMHDR* pnmh)
-{
-       if (pnmh->code == RBN_CHILDSIZE) {
-               /* align the task bands to the top, so it's in row with the Start button */
-               NMREBARCHILDSIZE* childSize = (NMREBARCHILDSIZE*)pnmh;
-
-               if (childSize->wID == IDW_TASKTOOLBAR) {
-                       int cy = childSize->rcChild.top - childSize->rcBand.top;
-
-                       if (cy) {
-                               childSize->rcChild.bottom -= cy;
-                               childSize->rcChild.top -= cy;
-                       }
-               }
-       }
-
-       return 0;
-}
-
-void DesktopBar::Resize(int cx, int cy)
-{
-       ///@todo general children resizing algorithm
-       int quicklaunch_width = SendMessage(_hwndQuickLaunch, PM_GET_WIDTH, 0, 0);
-       int notifyarea_width = SendMessage(_hwndNotify, PM_GET_WIDTH, 0, 0);
-
-       HDWP hdwp = BeginDeferWindowPos(3);
-
-       if (_hwndrebar)
-               DeferWindowPos(hdwp, _hwndrebar, 0, _taskbar_pos, 1, cx-_taskbar_pos-(notifyarea_width+1), cy-2, SWP_NOZORDER|SWP_NOACTIVATE);
-       else {
-               if (_hwndQuickLaunch)
-                       DeferWindowPos(hdwp, _hwndQuickLaunch, 0, _taskbar_pos, 1, quicklaunch_width, cy-2, SWP_NOZORDER|SWP_NOACTIVATE);
-
-               if (_hwndTaskBar)
-                       DeferWindowPos(hdwp, _hwndTaskBar, 0, _taskbar_pos+quicklaunch_width, 0, cx-_taskbar_pos-quicklaunch_width-(notifyarea_width+1), cy, SWP_NOZORDER|SWP_NOACTIVATE);
-       }
-
-       if (_hwndNotify)
-               DeferWindowPos(hdwp, _hwndNotify, 0, cx-(notifyarea_width+1), 1, notifyarea_width, cy-2, SWP_NOZORDER|SWP_NOACTIVATE);
-
-       EndDeferWindowPos(hdwp);
-
-       WindowRect rect(_hwnd);
-       RECT work_area = {0, 0, GetSystemMetrics(SM_CXSCREEN), rect.top};
-       SystemParametersInfo(SPI_SETWORKAREA, 0, &work_area, 0);        // don't use SPIF_SENDCHANGE because then we have to wait for any message being delivered
-       PostMessage(HWND_BROADCAST, WM_SETTINGCHANGE, SPI_SETWORKAREA, 0);
-}
-
-
-int DesktopBar::Command(int id, int code)
-{
-       switch(id) {
-         case IDC_START:
-               ShowStartMenu();
-               break;
-
-         case ID_ABOUT_EXPLORER:
-               explorer_about(_hwnd);
-               break;
-
-         case ID_DESKTOPBAR_SETTINGS:
-               ExplorerPropertySheet(_hwnd);
-               break;
-
-         case ID_MINIMIZE_ALL:
-               g_Globals._desktops.ToggleMinimize();
-               break;
-
-         case ID_EXPLORE:
-               explorer_show_frame(SW_SHOWNORMAL);
-               break;
-
-         case ID_TASKMGR:
-               launch_file(_hwnd, TEXT("taskmgr.exe"), SW_SHOWNORMAL);
-               break;
-
-         case ID_SWITCH_DESKTOP_1:
-         case ID_SWITCH_DESKTOP_1+1:
-         case ID_SWITCH_DESKTOP_1+2:
-         case ID_SWITCH_DESKTOP_1+3: {
-               int desktop_idx = id - ID_SWITCH_DESKTOP_1;
-
-               g_Globals._desktops.SwitchToDesktop(desktop_idx);
-
-               if (_hwndQuickLaunch)
-                       PostMessage(_hwndQuickLaunch, PM_UPDATE_DESKTOP, desktop_idx, 0);
-               break;}
-
-#ifdef _ROS_
-         case ID_TRAY_VOLUME:
-               launch_file(_hwnd, TEXT("sndvol32.exe"), SW_SHOWNORMAL);        // launch volume control application
-               break;
-
-         case ID_VOLUME_PROPERTIES:
-               launch_cpanel(_hwnd, TEXT("mmsys.cpl"));
-               break;
-#endif
-
-         default:
-               if (_hwndQuickLaunch)
-                       return SendMessage(_hwndQuickLaunch, WM_COMMAND, MAKEWPARAM(id,code), 0);
-               else
-                       return 1;
-       }
-
-       return 0;
-}
-
-
-void DesktopBar::ShowStartMenu()
-{
-       if (_startMenuRoot)
-               _startMenuRoot->TrackStartmenu();
-}
-
-
- /// copy data structure for tray notifications
-struct TrayNotifyCDS {
-       DWORD   cookie;
-       DWORD   notify_code;
-       NOTIFYICONDATA nicon_data;
-};
-
-LRESULT DesktopBar::ProcessCopyData(COPYDATASTRUCT* pcd)
-{
-        // Is this a tray notification message?
-       if (pcd->dwData == 1) {
-               TrayNotifyCDS* ptr = (TrayNotifyCDS*) pcd->lpData;
-
-               NotifyArea* notify_area = GET_WINDOW(NotifyArea, _hwndNotify);
-
-               if (notify_area)
-                       return notify_area->ProcessTrayNotification(ptr->notify_code, &ptr->nicon_data);
-       }
-
-       return FALSE;
-}
-
-
-void DesktopBar::ControlResize(WPARAM wparam, LPARAM lparam)
-{
-       PRECT dragRect = (PRECT) lparam;
-       //int screenWidth = GetSystemMetrics(SM_CXSCREEN);
-       int screenHeight = GetSystemMetrics(SM_CYSCREEN);
-
-       ///@todo write code for taskbar being at sides or top.
-
-       switch(wparam) {
-         case WMSZ_BOTTOM: //@todo Taskbar is at the top of the screen
-               break;
-
-         case WMSZ_TOP:        // Taskbar is at the bottom of the screen
-               dragRect->top = screenHeight - (((screenHeight - dragRect->top) + DESKTOPBARBAR_HEIGHT/2) / DESKTOPBARBAR_HEIGHT) * DESKTOPBARBAR_HEIGHT;
-               if (dragRect->top < screenHeight / 2)
-                       dragRect->top = screenHeight - (screenHeight/2 / DESKTOPBARBAR_HEIGHT * DESKTOPBARBAR_HEIGHT);
-               else if (dragRect->top > screenHeight - 5)
-                       dragRect->top = screenHeight - 5;
-               break;
-
-         case WMSZ_RIGHT:      //@todo Taskbar is at the left of the screen
-               break;
-
-         case WMSZ_LEFT:       //@todo Taskbar is at the right of the screen
-               break;
-       }
-}
-
-
-#ifdef _ROS_
-
-void DesktopBar::AddTrayIcons()
-{
-       _trayIcon.Add(SmallIcon(IDI_SPEAKER), ResString(IDS_VOLUME));
-}
-
-void DesktopBar::TrayClick(UINT id, int btn)
-{
-       switch(id) {
-         case ID_TRAY_VOLUME:
-               if (btn == TRAYBUTTON_LEFT)
-                       SetTimer(_hwnd, ID_TRAY_VOLUME, 500, NULL); // wait a bit to correctly handle double clicks
-               else {
-                       PopupMenu menu(IDM_VOLUME);
-                       SetMenuDefaultItem(menu, 0, MF_BYPOSITION);
-                       menu.TrackPopupMenuAtPos(_hwnd, GetMessagePos());
-               }
-               break;
-       }
-}
-
-void DesktopBar::TrayDblClick(UINT id, int btn)
-{
-       switch(id) {
-         case ID_TRAY_VOLUME:
-               KillTimer(_hwnd, ID_TRAY_VOLUME);       // finish one-click timer
-               launch_file(_hwnd, TEXT("sndvol32.exe"), SW_SHOWNORMAL);        // launch volume control application
-               break;
-       }
-}
-
-#endif
diff --git a/reactos/subsys/system/explorer/taskbar/desktopbar.h b/reactos/subsys/system/explorer/taskbar/desktopbar.h
deleted file mode 100644 (file)
index 36b0f18..0000000
+++ /dev/null
@@ -1,131 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer and Desktop clone
- //
- // desktopbar.h
- //
- // Martin Fuchs, 22.08.2003
- //
-
-
-#define        CLASSNAME_EXPLORERBAR   TEXT("Shell_TrayWnd")
-#define        TITLE_EXPLORERBAR               TEXT("")        // use an empty window title, so windows taskmanager does not show the window in its application list
-
-
-#define        DESKTOPBARBAR_HEIGHT    (GetSystemMetrics(SM_CYSIZE) + 5 * GetSystemMetrics(SM_CYEDGE))
-#define        REBARBAND_HEIGHT                (GetSystemMetrics(SM_CYSIZE) + 2 * GetSystemMetrics(SM_CYEDGE))
-
-
-#define        IDC_START                               0x1000
-#define        IDC_LOGOFF                              0x1001
-#define        IDC_SHUTDOWN                    0x1002
-#define        IDC_LAUNCH                              0x1003
-#define        IDC_START_HELP                  0x1004
-#define        IDC_SEARCH_FILES                0x1005
-#define        IDC_SEARCH_COMPUTER             0x1006
-#define        IDC_SETTINGS                    0x1007
-#define        IDC_ADMIN                               0x1008
-#define        IDC_DOCUMENTS                   0x1009
-#define        IDC_RECENT                              0x100A
-#define        IDC_FAVORITES                   0x100B
-#define        IDC_PROGRAMS                    0x100C
-#define        IDC_EXPLORE                             0x100D
-#define        IDC_NETWORK                             0x100E
-#define        IDC_CONNECTIONS                 0x100F
-#define        IDC_DRIVES                              0x1010
-#define        IDC_CONTROL_PANEL               0x1011
-#define        IDC_SETTINGS_MENU               0x1012
-#define        IDC_PRINTERS                    0x1013
-#define        IDC_PRINTERS_MENU               0x1014
-#define        IDC_BROWSE                              0x1015
-#define        IDC_SEARCH_PROGRAM              0x1016
-#define        IDC_SEARCH                              0x1017
-#define        IDC_TERMINATE                   0x1018
-
-#define        IDC_FIRST_MENU                  0x3000
-
-
- /// desktop bar window, also known as "system tray"
-struct DesktopBar : public
-#ifdef _ROS_
-       TrayIconControllerTemplate<
-                               OwnerDrawParent<Window> >
-#else
-       OwnerDrawParent<Window>
-#endif
-{
-#ifdef _ROS_
-       typedef TrayIconControllerTemplate<
-                               OwnerDrawParent<Window> > super;
-#else
-       typedef OwnerDrawParent<Window> super;
-#endif
-
-       DesktopBar(HWND hwnd);
-       ~DesktopBar();
-
-       static HWND Create();
-
-protected:
-       RECT    _work_area_org;
-       int             _taskbar_pos;
-
-       LRESULT Init(LPCREATESTRUCT pcs);
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Notify(int id, NMHDR* pnmh);
-       int             Command(int id, int code);
-
-       void    Resize(int cx, int cy);
-       void    ControlResize(WPARAM wparam, LPARAM lparam);
-       void    RegisterHotkeys();
-       void    ProcessHotKey(int id_hotkey);
-       void    ShowStartMenu();
-       LRESULT ProcessCopyData(COPYDATASTRUCT* pcd);
-
-       WindowHandle _hwndTaskBar;
-       WindowHandle _hwndNotify;
-       WindowHandle _hwndQuickLaunch;
-       WindowHandle _hwndrebar;
-
-       struct StartMenuRoot* _startMenuRoot;
-
-#ifdef _ROS_
-       TrayIcon        _trayIcon;
-
-       void    AddTrayIcons();
-       virtual void TrayClick(UINT id, int btn);
-       virtual void TrayDblClick(UINT id, int btn);
-#else
-       const UINT WM_TASKBARCREATED;
-#endif
-};
-
-
- /// special "Start" button with one click activation
-struct StartButton : public PictureButton
-{
-       typedef PictureButton super;
-
-       StartButton(HWND hwnd);
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-};
diff --git a/reactos/subsys/system/explorer/taskbar/favorites.cpp b/reactos/subsys/system/explorer/taskbar/favorites.cpp
deleted file mode 100644 (file)
index ea35c4a..0000000
+++ /dev/null
@@ -1,489 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer and Desktop clone
- //
- // favorites.cpp
- //
- // Martin Fuchs, 04.04.2004
- //
-
-
-#include <precomp.h>
-
-#include "startmenu.h"
-
-
-String DecodeURLString(const char* s)
-{
-       TCHAR buffer[BUFFER_LEN];
-       LPTSTR o = buffer;
-
-       for(const char* p=s; *p; ++p)
-               if (*p == '%') {
-                       if (!strncmp(p+1, "20", 2)) {
-                               *o++ = ' ';
-                               p += 2;
-                       } else
-                               *o++ = *p;
-               } else
-                       *o++ = *p;
-
-       return String(buffer, o-buffer);
-}
-
-
- /// read .URL file
-bool Bookmark::read_url(LPCTSTR path)
-{
-       char line[BUFFER_LEN];
-
-       tifstream in(path);
-
-       while(in.good()) {
-               in.getline(line, BUFFER_LEN);
-
-               const char* p = line;
-               while(isspace(*p))
-                       ++p;
-
-               const char* keyword = p;
-               const char* eq = strchr(p, '=');
-
-               if (eq) {
-                       const char* cont = eq + 1;
-                       while(isspace(*cont))
-                               ++cont;
-
-                       if (!_strnicmp(keyword, "URL", 3))
-                               _url = DecodeURLString(cont);
-                       else if (!_strnicmp(keyword, "IconFile", 8))
-                               _icon_path = DecodeURLString(cont);
-               }
-       }
-
-       return true;
-}
-
- /// convert XBEL bookmark node
-bool Bookmark::read(const_XMLPos& pos)
-{
-       _url = pos.get("href").c_str();
-
-       if (pos.go_down("title")) {
-               _name = pos->get_content();
-               pos.back();
-       }
-
-       if (pos.go_down("desc")) {
-               _description = pos->get_content();
-               pos.back();
-       }
-
-       if (pos.go_down("info")) {
-               const_XMLChildrenFilter metadata(pos, "metadata");
-
-               for(const_XMLChildrenFilter::const_iterator it=metadata.begin(); it!=metadata.end(); ++it) {
-                       const XMLNode& node = **it;
-                       const_XMLPos sub_pos(&node);
-
-                       if (node.get("owner") == "ros-explorer") {
-                               if (sub_pos.go_down("icon")) {
-                                       _icon_path = sub_pos.get("path").c_str();
-                                       _icon_idx = XS_toi(sub_pos.get("index"));
-
-                                       sub_pos.back(); // </icon>
-                               }
-                       }
-               }
-
-               pos.back();     // </metadata>
-               pos.back();     // </info>
-       }
-
-       return !_url.empty();   // _url is mandatory.
-}
-
- /// write XBEL bookmark node
-void Bookmark::write(XMLPos& pos) const
-{
-       pos.create("bookmark");
-
-       pos["href"] = _url.c_str();
-
-       if (!_name.empty()) {
-               pos.create("title");
-               pos->set_content(_name);
-               pos.back();
-       }
-
-       if (!_description.empty()) {
-               pos.create("desc");
-               pos->set_content(_description);
-               pos.back();
-       }
-
-       if (!_icon_path.empty()) {
-               pos.create("info");
-               pos.create("metadata");
-               pos["owner"] = "ros-explorer";
-               pos.create("icon");
-               pos["path"] = _icon_path.c_str();
-               pos["index"].printf(XS_TEXT("%d"), _icon_idx);
-               pos.back();     // </icon>
-               pos.back();     // </metadata>
-               pos.back();     // </info>
-       }
-
-       pos.back();
-}
-
-
- /// read bookmark folder from XBEL formated XML tree
-void BookmarkFolder::read(const_XMLPos& pos)
-{
-       if (pos.go_down("title")) {
-               _name = pos->get_content();
-               pos.back();
-       }
-
-       if (pos.go_down("desc")) {
-               _description = pos->get_content();
-               pos.back();
-       }
-
-       _bookmarks.read(pos);
-}
-
- /// write bookmark folder content from XBEL formated XML tree
-void BookmarkFolder::write(XMLPos& pos) const
-{
-       pos.create("folder");
-
-       if (!_name.empty()) {
-               pos.create("title");
-               pos->set_content(_name);
-               pos.back();
-       }
-
-       if (!_description.empty()) {
-               pos.create("desc");
-               pos->set_content(_description);
-               pos.back();
-       }
-
-       _bookmarks.write(pos);
-}
-
-
-BookmarkNode::BookmarkNode()
- :     _type(BMNT_NONE)
-{
-       _pbookmark = NULL;
-}
-
-BookmarkNode::BookmarkNode(const Bookmark& bm)
- :     _type(BMNT_BOOKMARK)
-{
-       _pbookmark = new Bookmark(bm);
-}
-
-BookmarkNode::BookmarkNode(const BookmarkFolder& bmf)
- :     _type(BMNT_FOLDER)
-{
-       _pfolder = new BookmarkFolder(bmf);
-}
-
-BookmarkNode::BookmarkNode(const BookmarkNode& other)
- :     _type(other._type)
-{
-       if (other._type == BMNT_BOOKMARK)
-               _pbookmark = new Bookmark(*other._pbookmark);
-       else if (other._type == BMNT_FOLDER)
-               _pfolder = new BookmarkFolder(*other._pfolder);
-       else
-               _pbookmark = NULL;
-}
-
-BookmarkNode::~BookmarkNode()
-{
-       if (_type == BMNT_BOOKMARK)
-               delete _pbookmark;
-       else if (_type == BMNT_FOLDER)
-               delete _pfolder;
-}
-
-BookmarkNode& BookmarkNode::operator=(const Bookmark& bm)
-{
-       clear();
-
-       _pbookmark = new Bookmark(bm);
-
-       return *this;
-}
-
-BookmarkNode& BookmarkNode::operator=(const BookmarkFolder& bmf)
-{
-       clear();
-
-       _pfolder = new BookmarkFolder(bmf);
-
-       return *this;
-}
-
-BookmarkNode& BookmarkNode::operator=(const BookmarkNode& other)
-{
-       clear();
-
-       _type = other._type;
-
-       if (other._type == BMNT_BOOKMARK)
-               _pbookmark = new Bookmark(*other._pbookmark);
-       else if (other._type == BMNT_FOLDER)
-               _pfolder = new BookmarkFolder(*other._pfolder);
-
-       return *this;
-}
-
-void BookmarkNode::clear()
-{
-       if (_type == BMNT_BOOKMARK) {
-               delete _pbookmark;
-               _pbookmark = NULL;
-       }
-       else if (_type == BMNT_FOLDER) {
-               delete _pfolder;
-               _pfolder = NULL;
-       }
-
-       _type = BMNT_NONE;
-}
-
-
- /// read bookmark list from XBEL formated XML tree
-void BookmarkList::read(const_XMLPos& pos)
-{
-       const XMLNode::Children& children = pos->get_children();
-
-       for(XMLNode::Children::const_iterator it=children.begin(); it!=children.end(); ++it) {
-               const XMLNode& node = **it;
-               const_XMLPos sub_pos(&node);
-
-               if (node == "folder") {
-                       BookmarkFolder folder;
-
-                       folder.read(sub_pos);
-
-                       push_back(folder);
-               } else if (node == "bookmark") {
-                       Bookmark bookmark;
-
-                       if (bookmark.read(sub_pos))
-                               push_back(bookmark);
-               }
-       }
-}
-
- /// write bookmark list into XBEL formated XML tree
-void BookmarkList::write(XMLPos& pos) const
-{
-       for(const_iterator it=begin(); it!=end(); ++it) {
-               const BookmarkNode& node = *it;
-
-               if (node._type == BookmarkNode::BMNT_FOLDER) {
-                       const BookmarkFolder& folder = *node._pfolder;
-
-                       folder.write(pos);
-
-                       pos.back();
-               } else if (node._type == BookmarkNode::BMNT_BOOKMARK) {
-                       const Bookmark& bookmark = *node._pbookmark;
-
-                       if (!bookmark._url.empty())
-                               bookmark.write(pos);
-               }
-       }
-}
-
-
- /// fill treeview control with bookmark tree content
-void BookmarkList::fill_tree(HWND hwnd, HTREEITEM parent, HIMAGELIST himagelist, HDC hdc_wnd) const
-{
-       TV_INSERTSTRUCT tvi;
-
-       tvi.hParent = parent;
-       tvi.hInsertAfter = TVI_LAST;
-
-       TV_ITEM& tv = tvi.item;
-       tv.mask = TVIF_TEXT|TVIF_IMAGE|TVIF_SELECTEDIMAGE|TVIF_PARAM;
-
-       for(const_iterator it=begin(); it!=end(); ++it) {
-               const BookmarkNode& node = *it;
-
-               tv.lParam = (LPARAM)&node;
-
-               if (node._type == BookmarkNode::BMNT_FOLDER) {
-                       const BookmarkFolder& folder = *node._pfolder;
-
-                       tv.pszText = (LPTSTR)folder._name.c_str();
-                       tv.iImage = 3;                  // folder
-                       tv.iSelectedImage = 4;  // open folder
-                       HTREEITEM hitem = TreeView_InsertItem(hwnd, &tvi);
-
-                       folder._bookmarks.fill_tree(hwnd, hitem, himagelist, hdc_wnd);
-               } else if (node._type == BookmarkNode::BMNT_BOOKMARK) {
-                       const Bookmark& bookmark = *node._pbookmark;
-
-                       tv.pszText = (LPTSTR)bookmark._name.c_str();
-                       tv.iImage = 1;                  // bookmark
-                       tv.iSelectedImage = 2;  // selected bookmark
-
-                       if (!bookmark._icon_path.empty()) {
-                               const Icon& icon = g_Globals._icon_cache.extract(bookmark._icon_path, bookmark._icon_idx);
-
-                               if ((ICON_ID)icon != ICID_NONE)
-                                       tv.iImage = tv.iSelectedImage = icon.add_to_imagelist(himagelist, hdc_wnd);
-                       }
-
-                       (void)TreeView_InsertItem(hwnd, &tvi);
-               }
-       }
-}
-
-
- /// import Internet Explorer bookmarks from Favorites folder into bookmark list
-void BookmarkList::import_IE_favorites(ShellDirectory& dir, HWND hwnd)
-{
-       TCHAR path[MAX_PATH], ext[_MAX_EXT];
-
-       dir.smart_scan(SORT_NAME, SCAN_DONT_EXTRACT_ICONS);
-
-       for(Entry*entry=dir._down; entry; entry=entry->_next) {
-               if (entry->_shell_attribs & SFGAO_HIDDEN)       // ignore files like "desktop.ini"
-                       continue;
-
-               String name;
-
-               if (entry->_etype == ET_SHELL)
-                       name = dir._folder.get_name(static_cast<ShellEntry*>(entry)->_pidl);
-               else
-                       name = entry->_display_name;
-
-               if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-                       BookmarkFolder new_folder;
-
-                       new_folder._name = DecodeXMLString(name);
-
-                       if (entry->_etype == ET_SHELL) {
-                               ShellDirectory new_dir(dir._folder, static_cast<ShellEntry*>(entry)->_pidl, hwnd);
-                               new_folder._bookmarks.import_IE_favorites(new_dir, hwnd);
-                       } else {
-                               entry->get_path(path, COUNTOF(path));
-                               ShellDirectory new_dir(GetDesktopFolder(), path, hwnd);
-                               new_folder._bookmarks.import_IE_favorites(new_dir, hwnd);
-                       }
-
-                       push_back(new_folder);
-               } else {
-                       Bookmark bookmark;
-
-                       bookmark._name = DecodeXMLString(name);
-
-                       entry->get_path(path, COUNTOF(path));
-                       _tsplitpath_s(path, NULL, 0, NULL, 0, NULL, 0, ext, COUNTOF(ext));
-
-                       if (!_tcsicmp(ext, TEXT(".url"))) {
-                               bookmark.read_url(path);
-                               push_back(bookmark);
-                       } else {
-                               ///@todo read shell links
-                               //assert(0);
-                       }
-               }
-       }
-}
-
-
- /// read XBEL bookmark file
-bool Favorites::read(LPCTSTR path)
-{
-       XMLDoc xbel;
-
-       if (!xbel.read(path))
-               if (xbel._last_error == XML_ERROR_NO_ELEMENTS)
-                       return false;
-               else
-                       MessageBox(g_Globals._hwndDesktop, String(xbel._last_error_msg.c_str()),
-                                               TEXT("ROS Explorer - reading bookmark file"), MB_OK);
-
-       const_XMLPos pos(&xbel);
-
-       if (!pos.go_down("xbel"))
-               return false;
-
-       super::read(pos);
-
-       pos.back();
-
-       return true;
-}
-
- /// write XBEL bookmark file
-void Favorites::write(LPCTSTR path) const
-{
-       XMLDoc xbel;
-
-       XMLPos pos(&xbel);
-       pos.create("xbel");
-       super::write(pos);
-       pos.back();
-
-       xbel._header._doctype = "<!DOCTYPE xbel"
-               " PUBLIC \"+//IDN python.org//DTD XML Bookmark Exchange Language 1.0//EN//XML\"\n"
-               " \"http://www.python.org/topics/xml/dtds/xbel-1.0.dtd\">";
-
-       xbel.write(path);
-}
-
- /// import Internet Explorer bookmarks from Favorites folder
-bool Favorites::import_IE_favorites(HWND hwnd)
-{
-       WaitCursor wait;
-
-       StartMenuShellDirs dirs;
-
-       try {
-               dirs.push_back(ShellDirectory(GetDesktopFolder(), SpecialFolderPath(CSIDL_COMMON_FAVORITES, hwnd), hwnd));
-               dirs.push_back(ShellDirectory(GetDesktopFolder(), SpecialFolderPath(CSIDL_FAVORITES, hwnd), hwnd));
-       } catch(COMException&) {
-       }
-
-       for(StartMenuShellDirs::iterator it=dirs.begin(); it!=dirs.end(); ++it) {
-               StartMenuDirectory& smd = *it;
-               ShellDirectory& dir = smd._dir;
-
-               try {
-                       super::import_IE_favorites(dir, hwnd);
-               } catch(COMException&) {
-               }
-       }
-
-       return true;
-}
diff --git a/reactos/subsys/system/explorer/taskbar/favorites.h b/reactos/subsys/system/explorer/taskbar/favorites.h
deleted file mode 100644 (file)
index 4d139ee..0000000
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer and Desktop clone
- //
- // favorites.h
- //
- // Martin Fuchs, 04.04.2004
- //
-
-
-extern String DecodeURLString(const char* s);
-
-
-struct Bookmark
-{
-       Bookmark() : _icon_idx(0) {}
-
-       String  _name;
-       String  _description;
-       String  _url;
-       String  _icon_path;
-       int             _icon_idx;
-
-       bool    read_url(LPCTSTR path);
-       bool    read(const_XMLPos& pos);
-       void    write(XMLPos& pos) const;
-};
-
-struct BookmarkFolder;
-
-struct BookmarkNode
-{
-       BookmarkNode();
-       BookmarkNode(const Bookmark& bm);
-       BookmarkNode(const BookmarkFolder& bmf);
-       BookmarkNode(const BookmarkNode& other);
-
-       ~BookmarkNode();
-
-       BookmarkNode& operator=(const Bookmark& bm);
-       BookmarkNode& operator=(const BookmarkFolder& bmf);
-       BookmarkNode& operator=(const BookmarkNode& other);
-
-       void    clear();
-
-       enum BOOKMARKNODE_TYPE {
-               BMNT_NONE, BMNT_BOOKMARK, BMNT_FOLDER
-       };
-
-       BOOKMARKNODE_TYPE       _type;
-
-       union {
-               Bookmark*               _pbookmark;
-               BookmarkFolder* _pfolder;
-       };
-};
-
-struct BookmarkList : public list<BookmarkNode>
-{
-       void    import_IE_favorites(struct ShellDirectory& dir, HWND hwnd);
-
-       void    read(const_XMLPos& pos);
-       void    write(XMLPos& pos) const;
-
-       void    fill_tree(HWND hwnd, HTREEITEM parent, HIMAGELIST, HDC hdc_wnd) const;
-};
-
-struct BookmarkFolder
-{
-       String  _name;
-       String  _description;
-       BookmarkList _bookmarks;
-
-       void    read(const_XMLPos& pos);
-       void    write(XMLPos& pos) const;
-};
-
-struct Favorites : public BookmarkList
-{
-       typedef BookmarkList super;
-
-       bool    read(LPCTSTR path);
-       void    write(LPCTSTR path) const;
-
-       bool    import_IE_favorites(HWND hwnd);
-};
diff --git a/reactos/subsys/system/explorer/taskbar/quicklaunch.cpp b/reactos/subsys/system/explorer/taskbar/quicklaunch.cpp
deleted file mode 100644 (file)
index 19acaa3..0000000
+++ /dev/null
@@ -1,303 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // quicklaunch.cpp
- //
- // Martin Fuchs, 22.08.2003
- //
-
-
-#include <precomp.h>
-
-#include "../resource.h"
-
-#include "quicklaunch.h"
-
-
-QuickLaunchEntry::QuickLaunchEntry()
-{
-       _hbmp = 0;
-}
-
-QuickLaunchMap::~QuickLaunchMap()
-{
-       while(!empty()) {
-               iterator it = begin();
-               DeleteBitmap(it->second._hbmp);
-               erase(it);
-       }
-}
-
-
-QuickLaunchBar::QuickLaunchBar(HWND hwnd)
- :     super(hwnd)
-{
-       CONTEXT("QuickLaunchBar::QuickLaunchBar()");
-
-       _dir = NULL;
-       _next_id = IDC_FIRST_QUICK_ID;
-       _btn_dist = 20;
-       _size = 0;
-
-       HWND hwndToolTip = (HWND) SendMessage(hwnd, TB_GETTOOLTIPS, 0, 0);
-
-       SetWindowStyle(hwndToolTip, GetWindowStyle(hwndToolTip)|TTS_ALWAYSTIP);
-
-        // delay refresh to some time later
-       PostMessage(hwnd, PM_REFRESH, 0, 0);
-}
-
-QuickLaunchBar::~QuickLaunchBar()
-{
-       delete _dir;
-}
-
-HWND QuickLaunchBar::Create(HWND hwndParent)
-{
-       CONTEXT("QuickLaunchBar::Create()");
-
-       ClientRect clnt(hwndParent);
-
-       HWND hwnd = CreateToolbarEx(hwndParent,
-                                                               WS_CHILD|WS_VISIBLE|WS_CLIPSIBLINGS|WS_CLIPCHILDREN|
-                                                               CCS_TOP|CCS_NODIVIDER|CCS_NOPARENTALIGN|CCS_NORESIZE|
-                                                               TBSTYLE_TOOLTIPS|TBSTYLE_WRAPABLE|TBSTYLE_FLAT,
-                                                               IDW_QUICKLAUNCHBAR, 0, 0, 0, NULL, 0, 0, 0, 16, 16, sizeof(TBBUTTON));
-
-       if (hwnd)
-               new QuickLaunchBar(hwnd);
-
-       return hwnd;
-}
-
-void QuickLaunchBar::AddShortcuts()
-{
-       CONTEXT("QuickLaunchBar::AddShortcuts()");
-
-       WaitCursor wait;
-
-       try {
-               TCHAR path[MAX_PATH];
-
-               SpecialFolderFSPath app_data(CSIDL_APPDATA, _hwnd);     ///@todo perhaps also look into CSIDL_COMMON_APPDATA ?
-
-               _stprintf(path, TEXT("%s\\")QUICKLAUNCH_FOLDER, (LPCTSTR)app_data);
-
-               RecursiveCreateDirectory(path);
-               _dir = new ShellDirectory(GetDesktopFolder(), path, _hwnd);
-
-               _dir->smart_scan(SORT_NAME);
-
-                // immediatelly extract the shortcut icons
-               for(Entry*entry=_dir->_down; entry; entry=entry->_next)
-                       entry->_icon_id = entry->safe_extract_icon(ICF_NORMAL);
-       } catch(COMException&) {
-               return;
-       }
-
-
-       ShellFolder desktop_folder;
-       WindowCanvas canvas(_hwnd);
-
-       COLORREF bk_color = GetSysColor(COLOR_BTNFACE);
-       HBRUSH bk_brush = GetSysColorBrush(COLOR_BTNFACE);
-
-       AddButton(ID_MINIMIZE_ALL, g_Globals._icon_cache.get_icon(ICID_MINIMIZE).create_bitmap(bk_color, bk_brush, canvas), ResString(IDS_MINIMIZE_ALL), NULL);
-       AddButton(ID_EXPLORE, g_Globals._icon_cache.get_icon(ICID_EXPLORER).create_bitmap(bk_color, bk_brush, canvas), ResString(IDS_TITLE), NULL);
-
-       TBBUTTON sep = {0, -1, TBSTATE_ENABLED, BTNS_SEP, {0, 0}, 0, 0};
-       SendMessage(_hwnd, TB_INSERTBUTTON, INT_MAX, (LPARAM)&sep);
-
-       int cur_desktop = g_Globals._desktops._current_desktop;
-       ResString desktop_fmt(IDS_DESKTOP_NUM);
-
-       HDC hdc = CreateCompatibleDC(canvas);
-       DWORD size = SendMessage(_hwnd, TB_GETBUTTONSIZE, 0, 0);
-       int cx = LOWORD(size);
-       int cy = HIWORD(size);
-       RECT rect = {0, 0, cx, cy};
-       RECT textRect = {0, 0, cx-7, cy-7};
-
-       for(int i=0; i<DESKTOP_COUNT; ++i) {
-               HBITMAP hbmp = CreateCompatibleBitmap(canvas, cx, cy);
-               HBITMAP hbmp_old = SelectBitmap(hdc, hbmp);
-
-               FmtString num_txt(TEXT("%d"), i+1);
-               TextColor color(hdc, RGB(64,64,64));
-               BkMode mode(hdc, TRANSPARENT);
-               FillRect(hdc, &rect, GetSysColorBrush(COLOR_BTNFACE));
-               DrawText(hdc, num_txt, num_txt.length(), &textRect, DT_CENTER|DT_VCENTER|DT_SINGLELINE);
-
-               SelectBitmap(hdc, hbmp_old);
-
-               AddButton(ID_SWITCH_DESKTOP_1+i, hbmp, FmtString(desktop_fmt, i+1), NULL, cur_desktop==i?TBSTATE_ENABLED|TBSTATE_CHECKED:TBSTATE_ENABLED);
-       }
-       DeleteDC(hdc);
-
-       SendMessage(_hwnd, TB_INSERTBUTTON, INT_MAX, (LPARAM)&sep);
-
-       for(Entry*entry=_dir->_down; entry; entry=entry->_next) {
-                // hide files like "desktop.ini"
-               if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_HIDDEN)
-                       continue;
-
-                // hide subfolders
-               if (!(entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)) {
-                       HBITMAP hbmp = g_Globals._icon_cache.get_icon(entry->_icon_id).create_bitmap(bk_color, bk_brush, canvas);
-
-                       AddButton(_next_id++, hbmp, entry->_display_name, entry);       //entry->_etype==ET_SHELL? desktop_folder.get_name(static_cast<ShellEntry*>(entry)->_pidl): entry->_display_name);
-               }
-       }
-
-       _btn_dist = LOWORD(SendMessage(_hwnd, TB_GETBUTTONSIZE, 0, 0));
-       _size = _entries.size() * _btn_dist;
-
-       SendMessage(GetParent(_hwnd), PM_RESIZE_CHILDREN, 0, 0);
-}
-
-void QuickLaunchBar::AddButton(int id, HBITMAP hbmp, LPCTSTR name, Entry* entry, int flags)
-{
-       TBADDBITMAP ab = {0, (UINT_PTR)hbmp};
-       int bmp_idx = SendMessage(_hwnd, TB_ADDBITMAP, 1, (LPARAM)&ab);
-
-       QuickLaunchEntry qle;
-
-       qle._hbmp = hbmp;
-       qle._title = name;
-       qle._entry = entry;
-
-       _entries[id] = qle;
-
-       TBBUTTON btn = {0, 0, flags, BTNS_BUTTON|BTNS_NOPREFIX, {0, 0}, 0, 0};
-
-       btn.idCommand = id;
-       btn.iBitmap = bmp_idx;
-
-       SendMessage(_hwnd, TB_INSERTBUTTON, INT_MAX, (LPARAM)&btn);
-}
-
-void QuickLaunchBar::UpdateDesktopButtons(int desktop_idx)
-{
-       for(int i=0; i<DESKTOP_COUNT; ++i) {
-               TBBUTTONINFO tbi = {sizeof(TBBUTTONINFO), TBIF_STATE, 0, 0, desktop_idx==i? TBSTATE_ENABLED|TBSTATE_CHECKED: TBSTATE_ENABLED};
-
-               SendMessage(_hwnd, TB_SETBUTTONINFO, ID_SWITCH_DESKTOP_1+i, (LPARAM)&tbi);
-       }
-}
-
-LRESULT QuickLaunchBar::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case PM_REFRESH:
-               AddShortcuts();
-               break;
-
-         case PM_GET_WIDTH: {
-                // take line wrapping into account 
-               int btns = SendMessage(_hwnd, TB_BUTTONCOUNT, 0, 0);
-               int rows = SendMessage(_hwnd, TB_GETROWS, 0, 0);
-
-               if (rows<2 || rows==btns)
-                       return _size;
-
-               RECT rect;
-               int max_cx = 0;
-
-               for(QuickLaunchMap::const_iterator it=_entries.begin(); it!=_entries.end(); ++it) {
-                       SendMessage(_hwnd, TB_GETRECT, it->first, (LPARAM)&rect);
-
-                       if (rect.right > max_cx)
-                               max_cx = rect.right;
-               }
-
-               return max_cx;}
-
-         case PM_UPDATE_DESKTOP:
-               UpdateDesktopButtons(wparam);
-               break;
-
-         case WM_CONTEXTMENU: {
-               TBBUTTON btn;
-               QuickLaunchMap::iterator it;
-               Point screen_pt(lparam), clnt_pt=screen_pt;
-               ScreenToClient(_hwnd, &clnt_pt);
-
-               Entry* entry = NULL;
-               int idx = SendMessage(_hwnd, TB_HITTEST, 0, (LPARAM)&clnt_pt);
-
-               if (idx>=0 &&
-                       SendMessage(_hwnd, TB_GETBUTTON, idx, (LPARAM)&btn)!=-1 &&
-                       (it=_entries.find(btn.idCommand))!=_entries.end()) {
-                       entry = it->second._entry;
-               }
-
-               if (entry)      // entry is NULL for desktop switch buttons
-                       CHECKERROR(entry->do_context_menu(_hwnd, screen_pt, _cm_ifs));
-               else
-                       goto def;
-               break;}
-
-         default: def:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-int QuickLaunchBar::Command(int id, int code)
-{
-       CONTEXT("QuickLaunchBar::Command()");
-
-       if ((id&~0xFF) == IDC_FIRST_QUICK_ID) {
-               QuickLaunchEntry& qle = _entries[id];
-
-               if (qle._entry) {
-                       qle._entry->launch_entry(_hwnd);
-                       return 0;
-               }
-       }
-
-       return 0; // Don't return 1 to avoid recursion with DesktopBar::Command()
-}
-
-int QuickLaunchBar::Notify(int id, NMHDR* pnmh)
-{
-       switch(pnmh->code) {
-         case TTN_GETDISPINFO: {
-               NMTTDISPINFO* ttdi = (NMTTDISPINFO*) pnmh;
-
-               int id = ttdi->hdr.idFrom;
-               ttdi->lpszText = _entries[id]._title.str();
-#ifdef TTF_DI_SETITEM
-               ttdi->uFlags |= TTF_DI_SETITEM;
-#endif
-
-                // enable multiline tooltips (break at CR/LF and for very long one-line strings)
-               SendMessage(pnmh->hwndFrom, TTM_SETMAXTIPWIDTH, 0, 400);
-
-               break;}
-
-               return super::Notify(id, pnmh);
-       }
-
-       return 0;
-}
diff --git a/reactos/subsys/system/explorer/taskbar/quicklaunch.h b/reactos/subsys/system/explorer/taskbar/quicklaunch.h
deleted file mode 100644 (file)
index 2593e23..0000000
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer and Desktop clone
- //
- // quicklaunch.h
- //
- // Martin Fuchs, 22.08.2003
- //
-
-
-#define        QUICKLAUNCH_WIDTH_DEF   70
-#define        QUICKLAUNCH_WIDTH_DEF   70
-
-#define        IDW_QUICKLAUNCHBAR      101
-
-#define        PM_UPDATE_DESKTOP       (WM_APP+0x23)
-
-#define        IDC_FIRST_QUICK_ID      0x4000
-
-
-#define        QUICKLAUNCH_FOLDER      TEXT("Microsoft\\Internet Explorer\\Quick Launch")
-
-
- /// quick launch bar shortcut
-struct QuickLaunchEntry
-{
-       QuickLaunchEntry();
-
-       HBITMAP _hbmp;
-       String  _title;
-       Entry*  _entry;
-};
-
- /// map for managing the task bar buttons
-struct QuickLaunchMap : public map<int, QuickLaunchEntry>
-{
-       ~QuickLaunchMap();
-};
-
-
- /// quick launch bar window
-struct QuickLaunchBar : public ExtContextMenuHandlerT<SubclassedWindow>
-{
-       typedef ExtContextMenuHandlerT<SubclassedWindow> super;
-
-       QuickLaunchBar(HWND hwnd);
-       ~QuickLaunchBar();
-
-       static HWND     Create(HWND hwndParent);
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Command(int id, int code);
-       int             Notify(int id, NMHDR* pnmh);
-
-       ShellDirectory* _dir;
-
-       int                             _next_id;
-       QuickLaunchMap  _entries;
-       int                             _btn_dist;
-       int                             _size;
-
-       void    AddShortcuts();
-       void    AddButton(int id, HBITMAP hbmp, LPCTSTR name, Entry* entry, int flags=TBSTATE_ENABLED);
-       void    UpdateDesktopButtons(int desktop_idx);
-};
diff --git a/reactos/subsys/system/explorer/taskbar/startmenu.cpp b/reactos/subsys/system/explorer/taskbar/startmenu.cpp
deleted file mode 100644 (file)
index 81466d0..0000000
+++ /dev/null
@@ -1,2303 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // startmenu.cpp
- //
- // Explorer start menu
- //
- // Martin Fuchs, 19.08.2003
- //
- // Credits: Thanks to Everaldo (http://www.everaldo.com) for his nice looking icons.
- //
-
-
-#include <precomp.h>
-
-#include "../resource.h"
-
-#include "desktopbar.h"
-#include "startmenu.h"
-
-#include "../dialogs/searchprogram.h"
-#include "../dialogs/settings.h"
-
-
-#define        SHELLPATH_CONTROL_PANEL         TEXT("::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\\::{21EC2020-3AEA-1069-A2DD-08002B30309D}")
-#define        SHELLPATH_PRINTERS                      TEXT("::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\\::{2227A280-3AEA-1069-A2DE-08002B30309D}")
-#define        SHELLPATH_NET_CONNECTIONS       TEXT("::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\\::{21EC2020-3AEA-1069-A2DD-08002B30309D}\\::{7007ACC7-3202-11D1-AAD2-00805FC1270E}")
-
-
-StartMenu::StartMenu(HWND hwnd, int icon_size)
- :     super(hwnd),
-       _icon_size(icon_size)
-{
-       _next_id = IDC_FIRST_MENU;
-       _submenu_id = 0;
-
-       _border_left = 0;
-       _border_top = 0;
-       _bottom_max = INT_MAX;
-
-       _floating_btn = false;
-       _arrow_btns = false;
-       _scroll_mode = SCROLL_NOT;
-       _scroll_pos = 0;
-       _invisible_lines = 0;
-
-       _last_pos = WindowRect(hwnd).pos();
-#ifdef _LIGHT_STARTMENU
-       _selected_id = -1;
-       _last_mouse_pos = 0;
-#endif
-}
-
-StartMenu::StartMenu(HWND hwnd, const StartMenuCreateInfo& create_info, int icon_size)
- :     super(hwnd),
-       _create_info(create_info),
-       _icon_size(icon_size)
-{
-       for(StartMenuFolders::const_iterator it=create_info._folders.begin(); it!=create_info._folders.end(); ++it)
-               if (*it)
-                       _dirs.push_back(ShellDirectory(GetDesktopFolder(), *it, _hwnd));
-
-       _next_id = IDC_FIRST_MENU;
-       _submenu_id = 0;
-
-       _border_left = 0;
-       _border_top = create_info._border_top;
-       _bottom_max = INT_MAX;
-
-       _floating_btn = create_info._border_top? true: false;
-       _arrow_btns = false;
-       _scroll_mode = SCROLL_NOT;
-       _scroll_pos = 0;
-       _invisible_lines = 0;
-
-       _last_pos = WindowRect(hwnd).pos();
-#ifdef _LIGHT_STARTMENU
-       _selected_id = -1;
-       _last_mouse_pos = 0;
-#endif
-}
-
-StartMenu::~StartMenu()
-{
-       SendParent(PM_STARTMENU_CLOSED);
-}
-
-
- // We need this wrapper function for s_wcStartMenu, it calls the WIN32 API,
- // though static C++ initializers are not allowed for Winelib applications.
-BtnWindowClass& StartMenu::GetWndClasss()
-{
-       static BtnWindowClass s_wcStartMenu(CLASSNAME_STARTMENU);
-
-       return s_wcStartMenu;
-}
-
-
-Window::CREATORFUNC_INFO StartMenu::s_def_creator = STARTMENU_CREATOR(StartMenu);
-
-HWND StartMenu::Create(int x, int y, const StartMenuFolders& folders, HWND hwndParent, LPCTSTR title,
-                                               CREATORFUNC_INFO creator, void* info, const String& filter)
-{
-       UINT style, ex_style;
-       int top_height;
-
-       if (hwndParent) {
-               style = WS_POPUP|WS_THICKFRAME|WS_CLIPCHILDREN|WS_VISIBLE;
-               ex_style = 0;
-               top_height = STARTMENU_TOP_BTN_SPACE;
-       } else {
-               style = WS_POPUP|WS_CAPTION|WS_SYSMENU|WS_CLIPCHILDREN|WS_VISIBLE;
-               ex_style = WS_EX_TOOLWINDOW;
-               top_height = 0;
-       }
-
-       int icon_size = ICON_SIZE_SMALL;
-       RECT rect = {x, y-STARTMENU_LINE_HEIGHT(icon_size)-top_height, x+STARTMENU_WIDTH_MIN, y};
-
-#ifndef _LIGHT_STARTMENU
-       rect.top += STARTMENU_LINE_HEIGHT(icon_size);
-#endif
-
-       AdjustWindowRectEx(&rect, style, FALSE, ex_style);
-
-       StartMenuCreateInfo create_info;
-
-       create_info._folders = folders;
-       create_info._border_top = top_height;
-       create_info._creator = creator;
-       create_info._info = info;
-       create_info._filter = filter;
-
-       if (title)
-               create_info._title = title;
-
-       HWND hwnd = Window::Create(creator, &create_info, ex_style, GetWndClasss(), title,
-                                                               style, rect.left, rect.top, rect.right-rect.left, rect.bottom-rect.top, hwndParent);
-
-        // make sure the window is not off the screen
-       MoveVisible(hwnd);
-
-       return hwnd;
-}
-
-
-LRESULT StartMenu::Init(LPCREATESTRUCT pcs)
-{
-       try {
-               AddEntries();
-
-               if (super::Init(pcs))
-                       return 1;
-
-                // create buttons for registered entries in _entries
-               for(ShellEntryMap::const_iterator it=_entries.begin(); it!=_entries.end(); ++it) {
-                       const StartMenuEntry& sme = it->second;
-                       bool hasSubmenu = false;
-
-                       for(ShellEntrySet::const_iterator it=sme._entries.begin(); it!=sme._entries.end(); ++it)
-                               if ((*it)->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-                                       hasSubmenu = true;
-
-#ifdef _LIGHT_STARTMENU
-                       _buttons.push_back(SMBtnInfo(sme, it->first, hasSubmenu));
-#else
-                       AddButton(sme._title, sme._hIcon, hasSubmenu, it->first);
-#endif
-               }
-
-#ifdef _LIGHT_STARTMENU
-               if (_buttons.empty())
-#else
-               if (!GetWindow(_hwnd, GW_CHILD))
-#endif
-                       AddButton(ResString(IDS_EMPTY), ICID_NONE, false, 0, false);
-
-#ifdef _LIGHT_STARTMENU
-               ResizeToButtons();
-#endif
-
-#ifdef _LAZY_ICONEXTRACT
-               PostMessage(_hwnd, PM_UPDATE_ICONS, 0, 0);
-#endif
-       } catch(COMException& e) {
-               HandleException(e, pcs->hwndParent);    // destroys the start menu window while switching focus
-       }
-
-       return 0;
-}
-
-void StartMenu::AddEntries()
-{
-       for(StartMenuShellDirs::iterator it=_dirs.begin(); it!=_dirs.end(); ++it) {
-               StartMenuDirectory& smd = *it;
-               ShellDirectory& dir = smd._dir;
-
-               if (!dir._scanned) {
-                       WaitCursor wait;
-
-#ifdef _LAZY_ICONEXTRACT
-                       dir.smart_scan(SORT_NAME, SCAN_DONT_EXTRACT_ICONS);     // lazy icon extraction, try to read directly from filesystem
-#else
-                       dir.smart_scan(SORT_NAME);
-#endif
-               }
-
-               AddShellEntries(dir, -1, smd._ignore);
-       }
-}
-
-
-static LPTSTR trim_path_slash(LPTSTR path)
-{
-       LPTSTR p = path;
-
-       while(*p)
-               ++p;
-
-       if (p>path && (p[-1]=='\\' || p[-1]=='/'))
-               *--p = '\0';
-
-       return path;
-}
-
-void StartMenu::AddShellEntries(const ShellDirectory& dir, int max, const String& ignore)
-{
-       TCHAR ignore_path[MAX_PATH], ignore_dir[MAX_PATH], ignore_name[_MAX_FNAME], ignore_ext[_MAX_EXT];
-       TCHAR dir_path[MAX_PATH];
-
-       if (!ignore.empty()) {
-               _tsplitpath_s(ignore, ignore_path, COUNTOF(ignore_path), ignore_dir, COUNTOF(ignore_dir), ignore_name, COUNTOF(ignore_name), ignore_ext, COUNTOF(ignore_ext));
-
-               _tcscat(ignore_path, ignore_dir);
-               _tcscat(ignore_name, ignore_ext);
-
-               dir.get_path(dir_path, COUNTOF(dir_path));
-
-               if (_tcsicmp(trim_path_slash(dir_path), trim_path_slash(ignore_path)))
-                       *ignore_name = '\0';
-       } else
-               *ignore_name = '\0';
-
-       String lwr_filter = _create_info._filter;
-       lwr_filter.toLower();
-
-       int cnt = 0;
-       for(Entry*entry=dir._down; entry; entry=entry->_next) {
-                // hide files like "desktop.ini"
-               if (entry->_shell_attribs & SFGAO_HIDDEN)
-               //not appropriate for drive roots: if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_HIDDEN)
-                       continue;
-
-                // hide "Programs" subfolders if requested
-               if (*ignore_name && !_tcsicmp(entry->_data.cFileName, ignore_name))
-                       continue;
-
-                // only 'max' entries shall be added.
-               if (++cnt == max)
-                       break;
-
-                // filter only non-directory entries
-               if (!(entry->_data.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY) && !lwr_filter.empty()) {
-                       String lwr_name = entry->_data.cFileName;
-                       String lwr_disp = entry->_display_name;
-
-                       lwr_name.toLower();
-                       lwr_disp.toLower();
-
-                       if (!_tcsstr(lwr_name,lwr_filter) && !_tcsstr(lwr_disp,lwr_filter))
-                               continue;
-               }
-
-               if (entry->_etype == ET_SHELL)
-                       AddEntry(dir._folder, static_cast<ShellEntry*>(entry));
-               else
-                       AddEntry(dir._folder, entry);
-       }
-}
-
-
-LRESULT StartMenu::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_PAINT: {
-               PaintCanvas canvas(_hwnd);
-               Paint(canvas);
-               break;}
-
-         case WM_SIZE:
-               ResizeButtons(LOWORD(lparam)-_border_left);
-               break;
-
-         case WM_MOVE: {
-               const POINTS& pos = MAKEPOINTS(lparam);
-
-                // move open submenus of floating menus
-               if (_submenu) {
-                       int dx = pos.x - _last_pos.x;
-                       int dy = pos.y - _last_pos.y;
-
-                       if (dx || dy) {
-                               WindowRect rt(_submenu);
-                               SetWindowPos(_submenu, 0, rt.left+dx, rt.top+dy, 0, 0, SWP_NOSIZE|SWP_NOACTIVATE);
-                               //MoveVisible(_submenu);
-                       }
-               }
-
-               _last_pos.x = pos.x;
-               _last_pos.y = pos.y;
-               goto def;}
-
-         case WM_NCHITTEST: {
-               LRESULT res = super::WndProc(nmsg, wparam, lparam);
-
-               if (res>=HTSIZEFIRST && res<=HTSIZELAST)
-                       return HTCLIENT;        // disable window resizing
-
-               return res;}
-
-         case WM_LBUTTONDOWN: {
-               RECT rect;
-
-                // check mouse cursor for coordinates of floating button
-               GetFloatingButtonRect(&rect);
-
-               if (PtInRect(&rect, Point(lparam))) {
-                        // create a floating copy of the current start menu
-                       WindowRect pos(_hwnd);
-
-                       ///@todo do something similar to StartMenuRoot::TrackStartmenu() in order to automatically close submenus when clicking on the desktop background
-                       StartMenu::Create(pos.left+3, pos.bottom-3, _create_info._folders, 0, _create_info._title, _create_info._creator, _create_info._info);
-                       CloseStartMenu();
-               }
-
-#ifdef _LIGHT_STARTMENU
-               int id = ButtonHitTest(Point(lparam));
-
-               if (id)
-                       Command(id, BN_CLICKED);
-#endif
-               break;}
-
-         case WM_SYSCOMMAND:
-               if ((wparam&0xFFF0) == SC_SIZE)
-                       return 0;                       // disable window resizing
-               goto def;
-
-         case WM_ACTIVATEAPP:
-                // close start menu when activating another application
-               if (!wparam)
-                       CloseStartMenu();
-               break;  // don't call super::WndProc in case "this" has been deleted
-
-         case WM_CANCELMODE:
-               CloseStartMenu();
-
-#ifdef _LIGHT_STARTMENU
-               if (_scroll_mode != SCROLL_NOT) {
-                       ReleaseCapture();
-                       KillTimer(_hwnd, 0);
-               }
-#endif
-               break;
-
-#ifdef _LIGHT_STARTMENU
-         case WM_MOUSEMOVE: {
-                // automatically set the focus to startmenu entries when moving the mouse over them
-               if (lparam != _last_mouse_pos) { // don't process WM_MOUSEMOVE when opening submenus using keyboard navigation
-                       Point pt(lparam);
-
-                       if (_arrow_btns) {
-                               RECT rect_up, rect_down;
-
-                               GetArrowButtonRects(&rect_up, &rect_down, _icon_size);
-
-                               SCROLL_MODE scroll_mode = SCROLL_NOT;
-
-                               if (PtInRect(&rect_up, pt))
-                                       scroll_mode = SCROLL_UP;
-                               else if (PtInRect(&rect_down, pt))
-                                       scroll_mode = SCROLL_DOWN;
-
-                               if (scroll_mode != _scroll_mode) {
-                                       if (scroll_mode == SCROLL_NOT) {
-                                               ReleaseCapture();
-                                               KillTimer(_hwnd, 0);
-                                       } else {
-                                               CloseSubmenus();
-                                               SetTimer(_hwnd, 0, 150, NULL);  // 150 ms scroll interval
-                                               SetCapture(_hwnd);
-                                       }
-
-                                       _scroll_mode = scroll_mode;
-                               }
-                       }
-
-                       int new_id = ButtonHitTest(pt);
-
-                       if (new_id > 0 && new_id != _selected_id)
-                               SelectButton(new_id);
-
-                       _last_mouse_pos = lparam;
-               }
-               break;}
-
-         case WM_TIMER:
-               if (_scroll_mode == SCROLL_UP) {
-                       if (_scroll_pos > 0) {
-                               --_scroll_pos;
-                               InvalidateRect(_hwnd, NULL, TRUE);
-                       }
-               } else {
-                       if (_scroll_pos <= _invisible_lines) {
-                               ++_scroll_pos;
-                               InvalidateRect(_hwnd, NULL, TRUE);
-                       }
-               }
-               break;
-
-         case WM_KEYDOWN:
-               ProcessKey(wparam);
-               break;
-#else
-         case PM_STARTENTRY_FOCUSED: { ///@todo use TrackMouseEvent() and WM_MOUSEHOVER to wait a bit before opening submenus
-               BOOL hasSubmenu = wparam;
-               HWND hctrl = (HWND)lparam;
-
-                // automatically open submenus
-               if (hasSubmenu) {
-                       UpdateWindow(_hwnd);    // draw focused button before waiting on submenu creation
-                       //SendMessage(_hwnd, WM_COMMAND, MAKEWPARAM(GetDlgCtrlID(hctrl),BN_CLICKED), (LPARAM)hctrl);
-                       Command(GetDlgCtrlID(hctrl), BN_CLICKED);
-               } else {
-                        // close any open submenu
-                       CloseOtherSubmenus();
-               }
-               break;}
-#endif
-
-#ifdef _LAZY_ICONEXTRACT
-         case PM_UPDATE_ICONS:
-               UpdateIcons(/*wparam*/);
-               break;
-#endif
-
-         case PM_STARTENTRY_LAUNCHED:
-               if (GetWindowStyle(_hwnd) & WS_CAPTION) // don't automatically close floating menus
-                       return 0;
-
-                // route message to the parent menu and close menus after launching an entry
-               if (!SendParent(nmsg, wparam, lparam))
-                       CloseStartMenu();
-               return 1;       // signal that we have received and processed the message
-
-         case PM_STARTMENU_CLOSED:
-               _submenu = 0;
-               break;
-
-         case PM_SELECT_ENTRY:
-               SelectButtonIndex(0, wparam!=0);
-               break;
-
-#ifdef _LIGHT_STARTMENU
-         case WM_CONTEXTMENU: {
-               Point screen_pt(lparam), clnt_pt=screen_pt;
-               ScreenToClient(_hwnd, &clnt_pt);
-
-               int id = ButtonHitTest(clnt_pt);
-
-               if (id) {
-                       StartMenuEntry& sme = _entries[id];
-
-                       for(ShellEntrySet::iterator it=sme._entries.begin(); it!=sme._entries.end(); ++it) {
-                               Entry* entry = *it;
-
-                               if (entry) {
-                                       CHECKERROR(entry->do_context_menu(_hwnd, screen_pt, _cm_ifs));  // may close start menu because of focus loss
-                                       break;  ///@todo handle context menu for more than one entry
-                               }
-                       }
-               }
-               break;}
-#endif
-
-         default: def:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-
-#ifdef _LIGHT_STARTMENU
-
-int StartMenu::ButtonHitTest(POINT pt)
-{
-       ClientRect clnt(_hwnd);
-       const int icon_size = _icon_size;
-       RECT rect = {_border_left, _border_top, clnt.right, STARTMENU_LINE_HEIGHT(icon_size)};
-
-       if (pt.x<rect.left || pt.x>rect.right)
-               return 0;
-
-       for(SMBtnVector::const_iterator it=_buttons.begin()+_scroll_pos; it!=_buttons.end(); ++it) {
-               const SMBtnInfo& info = *it;
-
-               if (rect.top > pt.y)
-                       break;
-
-               rect.bottom = rect.top + (info._id==-1? STARTMENU_SEP_HEIGHT(icon_size): STARTMENU_LINE_HEIGHT(icon_size));
-
-               if (rect.bottom > _bottom_max)
-                       break;
-
-               if (pt.y < rect.bottom) // PtInRect(&rect, pt)
-                       return info._id;
-
-               rect.top = rect.bottom;
-       }
-
-       return 0;
-}
-
-void StartMenu::InvalidateSelection()
-{
-       if (_selected_id <= 0)
-               return;
-
-       ClientRect clnt(_hwnd);
-       const int icon_size = _icon_size;
-       RECT rect = {_border_left, _border_top, clnt.right, STARTMENU_LINE_HEIGHT(icon_size)};
-
-       for(SMBtnVector::const_iterator it=_buttons.begin()+_scroll_pos; it!=_buttons.end(); ++it) {
-               const SMBtnInfo& info = *it;
-
-               rect.bottom = rect.top + (info._id==-1? STARTMENU_SEP_HEIGHT(icon_size): STARTMENU_LINE_HEIGHT(icon_size));
-
-               if (info._id == _selected_id) {
-                       InvalidateRect(_hwnd, &rect, TRUE);
-                       break;
-               }
-
-               rect.top = rect.bottom;
-       }
-}
-
-const SMBtnInfo* StartMenu::GetButtonInfo(int id) const
-{
-       for(SMBtnVector::const_iterator it=_buttons.begin(); it!=_buttons.end(); ++it)
-               if (it->_id == id)
-                       return &*it;
-
-       return NULL;
-}
-
-bool StartMenu::SelectButton(int id, bool open_sub)
-{
-       if (id == -1)
-               return false;
-
-       if (id == _selected_id)
-               return true;
-
-       InvalidateSelection();
-
-       const SMBtnInfo* btn = GetButtonInfo(id);
-
-       if (btn && btn->_enabled) {
-               _selected_id = id;
-
-               InvalidateSelection();
-
-                // automatically open submenus
-               if (btn->_hasSubmenu) {
-                       if (open_sub)
-                               OpenSubmenu();
-               } else
-                       CloseOtherSubmenus();   // close any open submenu
-
-               return true;
-       } else {
-               _selected_id = -1;
-               return false;
-       }
-}
-
-bool StartMenu::OpenSubmenu(bool select_first)
-{
-       if (_selected_id == -1)
-               return false;
-
-       InvalidateSelection();
-
-       const SMBtnInfo* btn = GetButtonInfo(_selected_id);
-
-        // automatically open submenus
-       if (btn->_hasSubmenu) {
-               //@@ allows destroying of startmenu when processing PM_UPDATE_ICONS -> GPF
-               UpdateWindow(_hwnd);    // draw focused button before waiting on submenu creation
-               Command(_selected_id, BN_CLICKED);
-
-               if (select_first && _submenu)
-                       SendMessage(_submenu, PM_SELECT_ENTRY, (WPARAM)false, 0);
-
-               return true;
-       } else
-               return false;
-}
-
-
-int StartMenu::GetSelectionIndex()
-{
-       if (_selected_id == -1)
-               return -1;
-
-       for(int i=0; i<(int)_buttons.size(); ++i)
-               if (_buttons[i]._id == _selected_id)
-                       return i;
-
-       return -1;
-}
-
-bool StartMenu::SelectButtonIndex(int idx, bool open_sub)
-{
-       if (idx>=0 && idx<(int)_buttons.size())
-               return SelectButton(_buttons[idx]._id, open_sub);
-       else
-               return false;
-}
-
-void StartMenu::ProcessKey(int vk)
-{
-       switch(vk) {
-         case VK_RETURN:
-               if (_selected_id)
-                       Command(_selected_id, BN_CLICKED);
-               break;
-
-         case VK_UP:
-               Navigate(-1);
-               break;
-
-         case VK_DOWN:
-               Navigate(+1);
-               break;
-
-         case VK_HOME:
-               SelectButtonIndex(0, false);
-               break;
-
-         case VK_END:
-               SelectButtonIndex(_buttons.size()-1, false);
-               break;
-
-         case VK_LEFT:
-               if (_submenu)
-                       CloseOtherSubmenus();
-               else if (!(GetWindowStyle(_hwnd) & WS_CAPTION)) // don't automatically close floating menus
-                       DestroyWindow(_hwnd);
-               break;
-
-         case VK_RIGHT:
-               OpenSubmenu(true);
-               break;
-
-         case VK_ESCAPE:
-               CloseStartMenu();
-               break;
-
-         default:
-               if (vk>='0' && vk<='Z')
-                       JumpToNextShortcut(vk);
-       }
-}
-
-bool StartMenu::Navigate(int step)
-{
-       int idx = GetSelectionIndex();
-
-       if (idx == -1)
-               if (step > 0)
-                       idx = 0 - step;
-               else
-                       idx = _buttons.size() - step;
-
-       for(;;) {
-               idx += step;
-
-               if (idx<0 || idx>(int)_buttons.size())
-                       break;
-
-               if (SelectButtonIndex(idx, false))
-                       return true;
-       }
-
-       return false;
-}
-
-bool StartMenu::JumpToNextShortcut(char c)
-{
-       int cur_idx = GetSelectionIndex();
-
-       if (cur_idx == -1)
-               cur_idx = 0;
-
-       int first_found = 0;
-       int found_more = 0;
-
-       SMBtnVector::const_iterator cur_it = _buttons.begin();
-       cur_it += cur_idx + 1;
-
-        // first search down from current item...
-       SMBtnVector::const_iterator it = cur_it;
-       for(; it!=_buttons.end(); ++it) {
-               const SMBtnInfo& btn = *it;
-
-               if (!btn._title.empty() && toupper((TBYTE)btn._title.at(0)) == c) {
-                       if (!first_found)
-                               first_found = btn._id;
-                       else
-                               ++found_more;
-               }
-       }
-
-        // ...now search from top to the current item
-       it = _buttons.begin();
-       for(; it!=_buttons.end() && it!=cur_it; ++it) {
-               const SMBtnInfo& btn = *it;
-
-               if (!btn._title.empty() && toupper((TBYTE)btn._title.at(0)) == c) {
-                       if (!first_found)
-                               first_found = btn._id;
-                       else
-                               ++found_more;
-               }
-       }
-
-       if (first_found) {
-               SelectButton(first_found);
-
-               if (!found_more)
-                       Command(first_found, BN_CLICKED);
-
-               return true;
-       } else
-               return false;
-}
-
-#endif // _LIGHT_STARTMENU
-
-
-bool StartMenu::GetButtonRect(int id, PRECT prect) const
-{
-#ifdef _LIGHT_STARTMENU
-       ClientRect clnt(_hwnd);
-       const int icon_size = _icon_size;
-       RECT rect = {_border_left, _border_top, clnt.right, STARTMENU_LINE_HEIGHT(icon_size)};
-
-       for(SMBtnVector::const_iterator it=_buttons.begin()+_scroll_pos; it!=_buttons.end(); ++it) {
-               const SMBtnInfo& info = *it;
-
-               rect.bottom = rect.top + (info._id==-1? STARTMENU_SEP_HEIGHT(icon_size): STARTMENU_LINE_HEIGHT(icon_size));
-
-               if (info._id == id) {
-                       *prect = rect;
-                       return true;
-               }
-
-               rect.top = rect.bottom;
-       }
-
-       return false;
-#else
-       HWND btn = GetDlgItem(_hwnd, id);
-
-       if (btn) {
-               GetWindowRect(btn, prect);
-               ScreenToClient(_hwnd, prect);
-
-               return true;
-       } else
-               return false;
-#endif
-}
-
-
-void StartMenu::DrawFloatingButton(HDC hdc)
-{
-       static ResIconEx floatingIcon(IDI_FLOATING, 8, 4);
-
-       ClientRect clnt(_hwnd);
-
-       DrawIconEx(hdc, clnt.right-12, 0, floatingIcon, 8, 4, 0, 0, DI_NORMAL);
-}
-
-void StartMenu::GetFloatingButtonRect(LPRECT prect)
-{
-       GetClientRect(_hwnd, prect);
-
-       prect->right -= 4;
-       prect->left = prect->right - 8;
-       prect->bottom = 4;
-}
-
-
-void StartMenu::DrawArrows(HDC hdc, int icon_size)
-{
-       int cx = icon_size / 2;
-       int cy = icon_size / 4;
-
-       ResIconEx arrowUpIcon(IDI_ARROW_UP, cx, cy);
-       ResIconEx arrowDownIcon(IDI_ARROW_DOWN, cx, cy);
-
-       ClientRect clnt(_hwnd);
-
-       DrawIconEx(hdc, clnt.right/2-cx/2, _floating_btn?3:1, arrowUpIcon, cx, cy, 0, 0, DI_NORMAL);
-       DrawIconEx(hdc, clnt.right/2-cx/2, clnt.bottom-cy-1, arrowDownIcon, cx, cy, 0, 0, DI_NORMAL);
-}
-
-void StartMenu::GetArrowButtonRects(LPRECT prect_up, LPRECT prect_down, int icon_size)
-{
-       int cx = icon_size / 2;
-       int cy = icon_size / 4;
-
-       GetClientRect(_hwnd, prect_up);
-       *prect_down = *prect_up;
-
-//     prect_up->left = prect_up->right/2 - cx/2;
-//     prect_up->right = prect_up->left + cy;
-       prect_up->right -= cx;
-       prect_up->top = _floating_btn? cy-1: 1;
-       prect_up->bottom = prect_up->top + cy;
-
-//     prect_down->left = prect_down->right/2 - cx/2;
-//     prect_down->right = prect_down->left + cy;
-       prect_down->right -= cx;
-       prect_down->top = prect_down->bottom - cy - 1;
-}
-
-
-void StartMenu::Paint(PaintCanvas& canvas)
-{
-       if (_floating_btn)
-               DrawFloatingButton(canvas);
-
-#ifdef _LIGHT_STARTMENU
-       if (_arrow_btns)
-               DrawArrows(canvas, _icon_size);
-
-       ClientRect clnt(_hwnd);
-       const int icon_size = _icon_size;
-       RECT rect = {_border_left, _border_top, clnt.right, STARTMENU_LINE_HEIGHT(icon_size)};
-
-       int sep_width = rect.right-rect.left - 4;
-
-       FontSelection font(canvas, GetStockFont(DEFAULT_GUI_FONT));
-       BkMode bk_mode(canvas, TRANSPARENT);
-
-       for(SMBtnVector::const_iterator it=_buttons.begin()+_scroll_pos; it!=_buttons.end(); ++it) {
-               const SMBtnInfo& btn = *it;
-
-               if (rect.top > canvas.rcPaint.bottom)
-                       break;
-
-               if (btn._id == -1) {    // a separator?
-                       rect.bottom = rect.top + STARTMENU_SEP_HEIGHT(icon_size);
-
-                       if (rect.bottom > _bottom_max)
-                               break;
-
-                       BrushSelection brush_sel(canvas, GetSysColorBrush(COLOR_BTNSHADOW));
-                       PatBlt(canvas, rect.left+2, rect.top+STARTMENU_SEP_HEIGHT(icon_size)/2-1, sep_width, 1, PATCOPY);
-
-                       SelectBrush(canvas, GetSysColorBrush(COLOR_BTNHIGHLIGHT));
-                       PatBlt(canvas, rect.left+2, rect.top+STARTMENU_SEP_HEIGHT(icon_size)/2, sep_width, 1, PATCOPY);
-               } else {
-                       rect.bottom = rect.top + STARTMENU_LINE_HEIGHT(icon_size);
-
-                       if (rect.bottom > _bottom_max)
-                               break;
-
-                       if (rect.top >= canvas.rcPaint.top)
-                               DrawStartMenuButton(canvas, rect, btn._title, btn, btn._id==_selected_id, false, _icon_size);
-               }
-
-               rect.top = rect.bottom;
-       }
-#endif
-}
-
-#ifdef _LAZY_ICONEXTRACT
-void StartMenu::UpdateIcons(/*int idx*/)
-{
-       UpdateWindow(_hwnd);
-
-#ifdef _SINGLE_ICONEXTRACT
-
-       //if (idx >= 0)
-       int idx = _scroll_pos;
-
-       for(; idx<(int)_buttons.size(); ++idx) {
-               SMBtnInfo& btn = _buttons[idx];
-
-               if (btn._icon_id==ICID_UNKNOWN && btn._id>0) {
-                       StartMenuEntry& sme = _entries[btn._id];
-
-                       btn._icon_id = ICID_NONE;
-
-                       for(ShellEntrySet::iterator it=sme._entries.begin(); it!=sme._entries.end(); ++it) {
-                               Entry* entry = *it;
-
-                               if (entry->_icon_id == ICID_UNKNOWN)
-                                       entry->_icon_id = entry->safe_extract_icon(ICF_FROM_ICON_SIZE(_icon_size));
-
-                               if (entry->_icon_id > ICID_NONE) {
-                                       btn._icon_id = (ICON_ID)/*@@*/ entry->_icon_id;
-
-                                       RECT rect;
-
-                                       GetButtonRect(btn._id, &rect);
-
-                                       if (rect.bottom > _bottom_max)
-                                               break;
-
-                                       WindowCanvas canvas(_hwnd);
-                                       DrawStartMenuButton(canvas, rect, NULL, btn, btn._id==_selected_id, false, _icon_size);
-
-                                       //InvalidateRect(_hwnd, &rect, FALSE);
-                                       //UpdateWindow(_hwnd);
-                                       //break;
-
-                                       break;
-                               }
-                       }
-               }
-       }
-
-//     if (++idx < (int)_buttons.size())
-//             PostMessage(_hwnd, PM_UPDATE_ICONS, idx, 0);
-
-#else
-
-       int icons_extracted = 0;
-       int icons_updated = 0;
-
-       for(StartMenuShellDirs::iterator it=_dirs.begin(); it!=_dirs.end(); ++it) {
-               ShellDirectory& dir = it->_dir;
-
-               icons_extracted += dir.extract_icons(icon_size);
-       }
-
-       if (icons_extracted) {
-               for(ShellEntryMap::iterator it1=_entries.begin(); it1!=_entries.end(); ++it1) {
-                       StartMenuEntry& sme = it1->second;
-
-                       if (!sme._hIcon) {
-                               sme._hIcon = (HICON)-1;
-
-                               for(ShellEntrySet::const_iterator it2=sme._entries.begin(); it2!=sme._entries.end(); ++it2) {
-                                       const Entry* sm_entry = *it2;
-
-                                       if (sm_entry->_hIcon) {
-                                               sme._hIcon = sm_entry->_hIcon;
-                                               break;
-                                       }
-                               }
-                       }
-               }
-
-               for(SMBtnVector::iterator it=_buttons.begin(); it!=_buttons.end(); ++it) {
-                       SMBtnInfo& info = *it;
-
-                       if (info._id>0 && !info._hIcon) {
-                               info._hIcon = _entries[info._id]._hIcon;
-                               ++icons_updated;
-                       }
-               }
-       }
-
-       if (icons_updated) {
-               InvalidateRect(_hwnd, NULL, FALSE);
-               UpdateWindow(_hwnd);
-       }
-#endif
-}
-#endif
-
-
- // resize child button controls to accomodate for new window size
-void StartMenu::ResizeButtons(int cx)
-{
-       HDWP hdwp = BeginDeferWindowPos(10);
-
-       for(HWND ctrl=GetWindow(_hwnd,GW_CHILD); ctrl; ctrl=GetNextWindow(ctrl,GW_HWNDNEXT)) {
-               ClientRect rt(ctrl);
-
-               if (rt.right != cx) {
-                       int height = rt.bottom - rt.top;
-
-                        // special handling for separator controls
-                       if (!height && (GetWindowStyle(ctrl)&SS_TYPEMASK)==SS_ETCHEDHORZ)
-                               height = 2;
-
-                       hdwp = DeferWindowPos(hdwp, ctrl, 0, 0, 0, cx, height, SWP_NOMOVE|SWP_NOZORDER|SWP_NOACTIVATE);
-               }
-       }
-
-       EndDeferWindowPos(hdwp);
-}
-
-
-int StartMenu::Command(int id, int code)
-{
-#ifndef _LIGHT_STARTMENU
-       switch(id) {
-         case IDCANCEL:
-               CloseStartMenu(id);
-               break;
-
-         default: {
-#endif
-               ShellEntryMap::iterator found = _entries.find(id);
-
-               if (found != _entries.end()) {
-                       ActivateEntry(id, found->second._entries);
-                       return 0;
-               }
-
-               return super::Command(id, code);
-#ifndef _LIGHT_STARTMENU
-         }
-       }
-
-       return 0;
-#endif
-}
-
-
-ShellEntryMap::iterator StartMenu::AddEntry(const String& title, ICON_ID icon_id, Entry* entry)
-{
-        // search for an already existing subdirectory entry with the same name
-       if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-               for(ShellEntryMap::iterator it=_entries.begin(); it!=_entries.end(); ++it) {
-                       StartMenuEntry& sme = it->second;
-
-                       if (!_tcsicmp(sme._title, title))       ///@todo speed up by using a map indexed by name
-                               for(ShellEntrySet::iterator it2=sme._entries.begin(); it2!=sme._entries.end(); ++it2) {
-                                       if ((*it2)->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-                                                // merge the new shell entry with the existing of the same name
-                                               sme._entries.insert(entry);
-
-                                               return it;
-                                       }
-                               }
-               }
-
-       ShellEntryMap::iterator sme = AddEntry(title, icon_id);
-
-       sme->second._entries.insert(entry);
-
-       return sme;
-}
-
-ShellEntryMap::iterator StartMenu::AddEntry(const String& title, ICON_ID icon_id, int id)
-{
-       if (id == -1)
-               id = ++_next_id;
-
-       StartMenuEntry sme;
-
-       sme._title = title;
-       sme._icon_id = icon_id;
-
-       ShellEntryMap::iterator it = _entries.insert(make_pair(id, sme)).first;
-
-       return it;
-}
-
-ShellEntryMap::iterator StartMenu::AddEntry(const ShellFolder folder, ShellEntry* entry)
-{
-       ICON_ID icon_id;
-
-       if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-               icon_id = ICID_APPS;
-       else
-               icon_id = (ICON_ID)/*@@*/ entry->_icon_id;
-
-       return AddEntry(folder.get_name(entry->_pidl), icon_id, entry);
-}
-
-ShellEntryMap::iterator StartMenu::AddEntry(const ShellFolder folder, Entry* entry)
-{
-       ICON_ID icon_id;
-
-       if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-               icon_id = ICID_APPS;
-       else
-               icon_id = (ICON_ID)/*@@*/ entry->_icon_id;
-
-       return AddEntry(entry->_display_name, icon_id, entry);
-}
-
-
-void StartMenu::AddButton(LPCTSTR title, ICON_ID icon_id, bool hasSubmenu, int id, bool enabled)
-{
-#ifdef _LIGHT_STARTMENU
-       _buttons.push_back(SMBtnInfo(title, icon_id, id, hasSubmenu, enabled));
-#else
-       DWORD style = enabled? WS_VISIBLE|WS_CHILD|BS_OWNERDRAW: WS_VISIBLE|WS_CHILD|BS_OWNERDRAW|WS_DISABLED;
-
-       WindowRect rect(_hwnd);
-       ClientRect clnt(_hwnd);
-
-        // increase window height to make room for the new button
-       rect.top -= STARTMENU_LINE_HEIGHT(icon_size);
-
-        // move down if we are too high now
-       if (rect.top < 0) {
-               rect.top += STARTMENU_LINE_HEIGHT(icon_size);
-               rect.bottom += STARTMENU_LINE_HEIGHT(icon_size);
-       }
-
-       WindowCanvas canvas(_hwnd);
-       FontSelection font(canvas, GetStockFont(DEFAULT_GUI_FONT));
-
-        // widen window, if it is too small
-       int text_width = GetStartMenuBtnTextWidth(canvas, title, _hwnd) + icon_size + 10/*placeholder*/ + 16/*arrow*/;
-
-       int cx = clnt.right - _border_left;
-       if (text_width > cx)
-               rect.right += text_width-cx;
-
-       MoveWindow(_hwnd, rect.left, rect.top, rect.right-rect.left, rect.bottom-rect.top, TRUE);
-
-       StartMenuCtrl(_hwnd, _border_left, clnt.bottom, rect.right-rect.left-_border_left,
-                                       title, id, g_Globals._icon_cache.get_icon(icon_id)._hIcon, hasSubmenu, style);
-#endif
-}
-
-void StartMenu::AddSeparator()
-{
-#ifdef _LIGHT_STARTMENU
-       _buttons.push_back(SMBtnInfo(NULL, ICID_NONE, -1, false));
-#else
-       WindowRect rect(_hwnd);
-       ClientRect clnt(_hwnd);
-
-        // increase window height to make room for the new separator
-       rect.top -= STARTMENU_SEP_HEIGHT(icon_size);
-
-        // move down if we are too high now
-       if (rect.top < 0) {
-               rect.top += STARTMENU_LINE_HEIGHT(icon_size);
-               rect.bottom += STARTMENU_LINE_HEIGHT(icon_size);
-       }
-
-       MoveWindow(_hwnd, rect.left, rect.top, rect.right-rect.left, rect.bottom-rect.top, TRUE);
-
-       StartMenuSeparator(_hwnd, _border_left, clnt.bottom, rect.right-rect.left-_border_left);
-#endif
-}
-
-
-bool StartMenu::CloseOtherSubmenus(int id)
-{
-       if (_submenu) {
-               if (IsWindow(_submenu)) {
-                       if (_submenu_id == id)
-                               return false;
-                       else {
-                               _submenu_id = 0;
-                               DestroyWindow(_submenu);
-                               // _submenu should be reset automatically by PM_STARTMENU_CLOSED, but safety first...
-                       }
-               }
-
-               _submenu = 0;
-       }
-
-       return true;
-}
-
-
-void StartMenu::CreateSubmenu(int id, LPCTSTR title, CREATORFUNC_INFO creator, void* info)
-{
-       CreateSubmenu(id, StartMenuFolders(), title, creator, info);
-}
-
-bool StartMenu::CreateSubmenu(int id, int folder_id, LPCTSTR title, CREATORFUNC_INFO creator, void* info)
-{
-       try {
-               SpecialFolderPath folder(folder_id, _hwnd);
-
-               StartMenuFolders new_folders;
-               new_folders.push_back(folder);
-
-               CreateSubmenu(id, new_folders, title, creator, info);
-
-               return true;
-       } catch(COMException&) {
-               // ignore Exception and don't display anything
-               CloseOtherSubmenus(id);
-               _buttons[GetSelectionIndex()]._enabled = false; // disable entries for non-existing folders
-               return false;
-       }
-}
-
-bool StartMenu::CreateSubmenu(int id, int folder_id1, int folder_id2, LPCTSTR title, CREATORFUNC_INFO creator, void* info)
-{
-       StartMenuFolders new_folders;
-
-       try {
-               new_folders.push_back(SpecialFolderPath(folder_id1, _hwnd));
-       } catch(COMException&) {
-       }
-
-       try {
-               new_folders.push_back(SpecialFolderPath(folder_id2, _hwnd));
-       } catch(COMException&) {
-       }
-
-       if (!new_folders.empty()) {
-               CreateSubmenu(id, new_folders, title, creator, info);
-               return true;
-       } else {
-               CloseOtherSubmenus(id);
-               _buttons[GetSelectionIndex()]._enabled = false; // disable entries for non-existing folders
-               return false;
-       }
-}
-
-void StartMenu::CreateSubmenu(int id, const StartMenuFolders& new_folders, LPCTSTR title, CREATORFUNC_INFO creator, void* info)
-{
-        // Only open one submenu at a time.
-       if (!CloseOtherSubmenus(id))
-               return;
-
-       RECT rect;
-       int x, y;
-
-       if (GetButtonRect(id, &rect)) {
-               ClientToScreen(_hwnd, &rect);
-
-               x = rect.right; // Submenus should overlap their parent a bit.
-               const int icon_size = _icon_size;
-               y = rect.top+STARTMENU_LINE_HEIGHT(icon_size) +_border_top/*own border*/ -STARTMENU_TOP_BTN_SPACE/*border of new submenu*/;
-       } else {
-               WindowRect pos(_hwnd);
-
-               x = pos.right;
-               y = pos.top;
-       }
-
-       _submenu_id = id;
-       _submenu = StartMenu::Create(x, y, new_folders, _hwnd, title, creator, info, _create_info._filter);
-}
-
-
-void StartMenu::ActivateEntry(int id, const ShellEntrySet& entries)
-{
-       StartMenuFolders new_folders;
-       String title;
-
-       for(ShellEntrySet::const_iterator it=entries.begin(); it!=entries.end(); ++it) {
-               Entry* entry = const_cast<Entry*>(*it);
-
-               if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-
-                       ///@todo If the user explicitly clicked on a submenu, display this folder as floating start menu.
-
-                       if (entry->_etype == ET_SHELL)
-                               new_folders.push_back(entry->create_absolute_pidl());
-                       else {
-                               TCHAR path[MAX_PATH];
-
-                               if (entry->get_path(path, COUNTOF(path)))
-                                       new_folders.push_back(path);
-                       }
-
-                       if (title.empty())
-                               title = entry->_display_name;
-               } else {
-                        // The entry is no subdirectory, so there can only be one shell entry.
-                       assert(entries.size()==1);
-
-                       HWND hparent = GetParent(_hwnd);
-                       ShellPath shell_path = entry->create_absolute_pidl();
-
-                        // close start menus when launching the selected entry
-                       CloseStartMenu(id);
-
-                       ///@todo launch in the background; specify correct HWND for error message box titles
-                       SHELLEXECUTEINFO shexinfo;
-
-                       shexinfo.cbSize = sizeof(SHELLEXECUTEINFO);
-                       shexinfo.fMask = SEE_MASK_IDLIST;       // SEE_MASK_INVOKEIDLIST is also possible.
-                       shexinfo.hwnd = hparent;
-                       shexinfo.lpVerb = NULL;
-                       shexinfo.lpFile = NULL;
-                       shexinfo.lpParameters = NULL;
-                       shexinfo.lpDirectory = NULL;
-                       shexinfo.nShow = SW_SHOWNORMAL;
-
-                       shexinfo.lpIDList = &*shell_path;
-
-                        // add PIDL to the recent file list
-                       SHAddToRecentDocs(SHARD_PIDL, shexinfo.lpIDList);
-
-                       if (!ShellExecuteEx(&shexinfo))
-                               display_error(hparent, GetLastError());
-
-                        // we may have deleted 'this' - ensure we leave the loop and function
-                       return;
-               }
-       }
-
-       if (!new_folders.empty()) {
-                // Only open one submenu at a time.
-               if (!CloseOtherSubmenus(id))
-                       return;
-
-               CreateSubmenu(id, new_folders, title);
-       }
-}
-
-
- /// close all windows of the start menu popup
-void StartMenu::CloseStartMenu(int id)
-{
-       if (!(GetWindowStyle(_hwnd) & WS_CAPTION)) {    // don't automatically close floating menus
-               if (!SendParent(PM_STARTENTRY_LAUNCHED, id, (LPARAM)_hwnd))
-                       DestroyWindow(_hwnd);
-       } else if (_submenu)    // instead close submenus of floating parent menus
-               CloseSubmenus();
-}
-
-
-int GetStartMenuBtnTextWidth(HDC hdc, LPCTSTR title, HWND hwnd)
-{
-       RECT rect = {0, 0, 0, 0};
-       DrawText(hdc, title, -1, &rect, DT_SINGLELINE|DT_NOPREFIX|DT_CALCRECT);
-
-       return rect.right-rect.left;
-}
-
-#ifdef _LIGHT_STARTMENU
-void DrawStartMenuButton(HDC hdc, const RECT& rect, LPCTSTR title, const SMBtnInfo& btn, bool has_focus, bool pushed, int icon_size)
-#else
-void DrawStartMenuButton(HDC hdc, const RECT& rect, LPCTSTR title, HICON hIcon,
-                                                               bool hasSubmenu, bool enabled, bool has_focus, bool pushed, int icon_size);
-#endif
-{
-       UINT style = DFCS_BUTTONPUSH;
-
-       if (!btn._enabled)
-               style |= DFCS_INACTIVE;
-
-       POINT iconPos = {rect.left+2, (rect.top+rect.bottom-icon_size)/2};
-       RECT textRect = {rect.left+icon_size+4, rect.top+2, rect.right-4, rect.bottom-4};
-
-       if (pushed) {
-               style |= DFCS_PUSHED;
-               ++iconPos.x;            ++iconPos.y;
-               ++textRect.left;        ++textRect.top;
-               ++textRect.right;       ++textRect.bottom;
-       }
-
-       int bk_color_idx = COLOR_BTNFACE;
-       int text_color_idx = COLOR_BTNTEXT;
-
-       if (has_focus) {
-               bk_color_idx = COLOR_HIGHLIGHT;
-               text_color_idx = COLOR_HIGHLIGHTTEXT;
-       }
-
-       COLORREF bk_color = GetSysColor(bk_color_idx);
-       HBRUSH bk_brush = GetSysColorBrush(bk_color_idx);
-
-       if (title)
-               FillRect(hdc, &rect, bk_brush);
-
-       if (btn._icon_id > ICID_NONE)
-               g_Globals._icon_cache.get_icon(btn._icon_id).draw(hdc, iconPos.x, iconPos.y, icon_size, icon_size, bk_color, bk_brush/*, icon_size*/);
-
-        // draw submenu arrow at the right
-       if (btn._hasSubmenu) {
-               ResIconEx arrowIcon(IDI_ARROW, icon_size, icon_size);
-               ResIconEx selArrowIcon(IDI_ARROW_SELECTED, icon_size, icon_size);
-
-               DrawIconEx(hdc, rect.right-icon_size, iconPos.y,
-                                       has_focus? selArrowIcon: arrowIcon,
-                                       icon_size, icon_size, 0, bk_brush, DI_NORMAL);
-       }
-
-       if (title) {
-               BkMode bk_mode(hdc, TRANSPARENT);
-
-               if (!btn._enabled)      // dis->itemState & (ODS_DISABLED|ODS_GRAYED)
-                       DrawGrayText(hdc, &textRect, title, DT_SINGLELINE|DT_NOPREFIX|DT_VCENTER);
-               else {
-                       TextColor lcColor(hdc, GetSysColor(text_color_idx));
-                       DrawText(hdc, title, -1, &textRect, DT_SINGLELINE|DT_NOPREFIX|DT_VCENTER);
-               }
-       }
-}
-
-
-#ifdef _LIGHT_STARTMENU
-
-void StartMenu::ResizeToButtons()
-{
-       WindowRect rect(_hwnd);
-
-       WindowCanvas canvas(_hwnd);
-       FontSelection font(canvas, GetStockFont(DEFAULT_GUI_FONT));
-
-       const int icon_size = _icon_size;
-
-       int max_width = STARTMENU_WIDTH_MIN;
-       int height = 0;
-
-       for(SMBtnVector::const_iterator it=_buttons.begin(); it!=_buttons.end(); ++it) {
-               int w = GetStartMenuBtnTextWidth(canvas, it->_title, _hwnd);
-
-               if (w > max_width)
-                       max_width = w;
-
-               if (it->_id == -1)
-                       height += STARTMENU_SEP_HEIGHT(icon_size);
-               else
-                       height += STARTMENU_LINE_HEIGHT(icon_size);
-       }
-
-        // calculate new window size
-       int text_width = max_width + icon_size + 10/*placeholder*/ + 16/*arrow*/;
-
-       RECT rt_hgt = {rect.left, rect.bottom-_border_top-height, rect.left+_border_left+text_width, rect.bottom};
-       AdjustWindowRectEx(&rt_hgt, GetWindowStyle(_hwnd), FALSE, GetWindowExStyle(_hwnd));
-
-        // ignore movement, only look at the size change
-       rect.right = rect.left + (rt_hgt.right-rt_hgt.left);
-       rect.top = rect.bottom - (rt_hgt.bottom-rt_hgt.top);
-
-        // move down if we are too high
-       if (rect.top < 0) {
-               int dy = -rect.top;
-               rect.top += dy;
-               rect.bottom += dy;
-       }
-
-        // enable scroll mode for long start menus, which span more than the whole screen height
-       int cyscreen = GetSystemMetrics(SM_CYSCREEN);
-       int bottom_max = 0;
-
-       if (rect.bottom > cyscreen) {
-               _arrow_btns = true;
-
-               _invisible_lines = (rect.bottom-cyscreen+(STARTMENU_LINE_HEIGHT(icon_size)-1))/STARTMENU_SEP_HEIGHT(icon_size) + 1;
-               rect.bottom -= _invisible_lines * STARTMENU_LINE_HEIGHT(icon_size);
-
-               bottom_max = rect.bottom;
-
-               if (_floating_btn)
-                       rect.bottom += 6;       // lower scroll arrow
-               else {
-                       _border_top += 6;       // upper scroll arrow
-                       rect.bottom += 2*6;     // upper+lower scroll arrow
-               }
-       }
-
-       MoveWindow(_hwnd, rect.left, rect.top, rect.right-rect.left, rect.bottom-rect.top, TRUE);
-
-       if (bottom_max) {
-               POINT pt = {0, bottom_max};
-
-               ScreenToClient(_hwnd, &pt);
-
-               _bottom_max = pt.y;
-       }
-}
-
-#else // _LIGHT_STARTMENU
-
-LRESULT StartMenuButton::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_MOUSEMOVE:
-                // automatically set the focus to startmenu entries when moving the mouse over them
-               if (GetFocus()!=_hwnd && !(GetWindowStyle(_hwnd)&WS_DISABLED))
-                       SetFocus(_hwnd);
-               break;
-
-         case WM_SETFOCUS:
-               PostParent(PM_STARTENTRY_FOCUSED, _hasSubmenu, (LPARAM)_hwnd);
-               goto def;
-
-         case WM_CANCELMODE:
-                // route WM_CANCELMODE to the startmenu window
-               return SendParent(nmsg, wparam, lparam);
-
-         default: def:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-void StartMenuButton::DrawItem(LPDRAWITEMSTRUCT dis)
-{
-       TCHAR title[BUFFER_LEN];
-
-       GetWindowText(_hwnd, title, BUFFER_LEN);
-
-       DrawStartMenuButton(dis->hDC, dis->rcItem, title, _hIcon,
-                                               _hasSubmenu,
-                                               !(dis->itemState & ODS_DISABLED),
-                                               dis->itemState&ODS_FOCUS? true: false,
-                                               dis->itemState&ODS_SELECTED? true: false);
-}
-
-#endif
-
-
-StartMenuRoot::StartMenuRoot(HWND hwnd, const StartMenuRootCreateInfo& info)
- :     super(hwnd, info._icon_size)
-{
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || !SHRestricted(REST_NOCOMMONGROUPS))
-#endif
-               try {
-                        // insert directory "All Users\Start Menu"
-                       ShellDirectory cmn_startmenu(GetDesktopFolder(), SpecialFolderPath(CSIDL_COMMON_STARTMENU, _hwnd), _hwnd);
-                       _dirs.push_back(StartMenuDirectory(cmn_startmenu, (LPCTSTR)SpecialFolderFSPath(CSIDL_COMMON_PROGRAMS, _hwnd)));
-               } catch(COMException&) {
-                       // ignore exception and don't show additional shortcuts
-               }
-
-       try {
-                // insert directory "<user name>\Start Menu"
-               ShellDirectory usr_startmenu(GetDesktopFolder(), SpecialFolderPath(CSIDL_STARTMENU, _hwnd), _hwnd);
-               _dirs.push_back(StartMenuDirectory(usr_startmenu, (LPCTSTR)SpecialFolderFSPath(CSIDL_PROGRAMS, _hwnd)));
-       } catch(COMException&) {
-               // ignore exception and don't show additional shortcuts
-       }
-
-       ReadLogoSize();
-}
-
-void StartMenuRoot::ReadLogoSize()
-{
-        // read size of logo bitmap
-       BITMAP bmp_hdr;
-       GetObject(ResBitmap(GetLogoResId()), sizeof(BITMAP), &bmp_hdr);
-       _logo_size.cx = bmp_hdr.bmWidth;
-       _logo_size.cy = bmp_hdr.bmHeight;
-
-        // cache logo width
-       _border_left = _logo_size.cx + 1;
-}
-
-
-static void CalculateStartPos(HWND hwndOwner, RECT& rect, int icon_size)
-{
-       WindowRect pos(hwndOwner);
-
-       rect.left = pos.left;
-       rect.top = pos.top-STARTMENU_LINE_HEIGHT(icon_size)-4;
-       rect.right = pos.left+STARTMENU_WIDTH_MIN;
-       rect.bottom = pos.top;
-
-#ifndef _LIGHT_STARTMENU
-       rect.top += STARTMENU_LINE_HEIGHT(icon_size);
-#endif
-
-       AdjustWindowRectEx(&rect, WS_POPUP|WS_THICKFRAME|WS_CLIPCHILDREN|WS_VISIBLE, FALSE, 0);
-}
-
-HWND StartMenuRoot::Create(HWND hwndOwner, int icon_size)
-{
-       RECT rect;
-
-       CalculateStartPos(hwndOwner, rect, icon_size);
-
-       StartMenuRootCreateInfo create_info;
-
-       create_info._icon_size = icon_size;
-
-       return Window::Create(WINDOW_CREATOR_INFO(StartMenuRoot,StartMenuRootCreateInfo), &create_info, 0, GetWndClasss(), TITLE_STARTMENU,
-                                                       WS_POPUP|WS_THICKFRAME|WS_CLIPCHILDREN,
-                                                       rect.left, rect.top, rect.right-rect.left, rect.bottom-rect.top, hwndOwner);
-}
-
-
-void StartMenuRoot::TrackStartmenu()
-{
-       MSG msg;
-       HWND hwnd = _hwnd;
-
-#ifdef _LIGHT_STARTMENU
-       _selected_id = -1;
-#endif
-
-#ifdef _LIGHT_STARTMENU
-        // recalculate start menu root position
-       RECT rect;
-
-       CalculateStartPos(GetParent(hwnd), rect, _icon_size);
-
-       SetWindowPos(hwnd, 0, rect.left, rect.top, rect.right-rect.left, rect.bottom-rect.top, 0);
-
-       ResizeToButtons();
-#endif
-
-        // show previously hidden start menu
-       ShowWindow(hwnd, SW_SHOW);
-       SetForegroundWindow(hwnd);
-
-       while(IsWindow(hwnd) && IsWindowVisible(hwnd)) {
-               if (!GetMessage(&msg, 0, 0, 0)) {
-                       PostQuitMessage(msg.wParam);
-                       break;
-               }
-
-                // Check for a mouse click on any window, that is not part of the start menu
-               if (msg.message==WM_LBUTTONDOWN || msg.message==WM_MBUTTONDOWN || msg.message==WM_RBUTTONDOWN) {
-                       StartMenu* menu_wnd = NULL;
-
-                       for(HWND hwnd=msg.hwnd; hwnd; hwnd=GetParent(hwnd)) {
-                               menu_wnd = WINDOW_DYNAMIC_CAST(StartMenu, hwnd);
-
-                               if (menu_wnd)
-                                       break;
-                       }
-
-                       if (!menu_wnd) {
-                               CloseStartMenu();
-                               break;
-                       }
-               }
-
-               try {
-                       if (pretranslate_msg(&msg))
-                               continue;
-
-                       if (dispatch_dialog_msg(&msg))
-                               continue;
-
-                       TranslateMessage(&msg);
-
-                       try {
-                               DispatchMessage(&msg);
-                       } catch(COMException& e) {
-                               HandleException(e, _hwnd);
-                       }
-               } catch(COMException& e) {
-                       HandleException(e, _hwnd);
-               }
-       }
-}
-
-
-LRESULT        StartMenuRoot::Init(LPCREATESTRUCT pcs)
-{
-        // add buttons for entries in _entries
-       if (super::Init(pcs))
-               return 1;
-
-       AddSeparator();
-
-
-#ifdef __MINGW32__
-       HKEY hkey, hkeyAdv;
-       DWORD value, len;
-
-       if (RegOpenKey(HKEY_CURRENT_USER, _T("Software\\Microsoft\\Windows\\CurrentVersion\\Policies\\Explorer"), &hkey))
-               hkey = 0;
-
-       if (RegOpenKey(HKEY_CURRENT_USER, _T("Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Advanced"), &hkeyAdv))
-               hkeyAdv = 0;
-
-#define        IS_VALUE_ZERO(hk, name) \
-       (!hk || (len=sizeof(value),RegQueryValueEx(hk, name, NULL, NULL, (LPBYTE)&value, &len) || !value))
-
-#define        IS_VALUE_NOT_ZERO(hk, name) \
-       (!hk || (len=sizeof(value),RegQueryValueEx(hk, name, NULL, NULL, (LPBYTE)&value, &len) || value>0))
-#endif
-
-
-        // insert hard coded start entries
-       AddButton(ResString(IDS_PROGRAMS),              ICID_APPS, true, IDC_PROGRAMS);
-
-       AddButton(ResString(IDS_DOCUMENTS),             ICID_DOCUMENTS, true, IDC_DOCUMENTS);
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || !SHRestricted(REST_NORECENTDOCSMENU))
-#else
-       if (IS_VALUE_ZERO(hkey, _T("NoRecentDocsMenu")))
-#endif
-               AddButton(ResString(IDS_RECENT),        ICID_RECENT, true, IDC_RECENT);
-
-       AddButton(ResString(IDS_FAVORITES),             ICID_FAVORITES, true, IDC_FAVORITES);
-
-       AddButton(ResString(IDS_SETTINGS),              ICID_CONFIG, true, IDC_SETTINGS);
-
-       AddButton(ResString(IDS_BROWSE),                ICID_FOLDER, true, IDC_BROWSE);
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || !SHRestricted(REST_NOFIND))
-#else
-       if (IS_VALUE_ZERO(hkey, _T("NoFind")))
-#endif
-               AddButton(ResString(IDS_SEARCH),        ICID_SEARCH, true, IDC_SEARCH);
-
-       AddButton(ResString(IDS_START_HELP),    ICID_INFO, false, IDC_START_HELP);
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || !SHRestricted(REST_NORUN))
-#else
-       if (IS_VALUE_ZERO(hkey, _T("NoRun")))
-#endif
-               AddButton(ResString(IDS_LAUNCH),        ICID_ACTION, false, IDC_LAUNCH);
-
-
-       AddSeparator();
-
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || !SHRestricted(REST_NOCLOSE))
-#else
-       if (IS_VALUE_NOT_ZERO(hkeyAdv, _T("StartMenuLogoff")))
-#endif
-               AddButton(ResString(IDS_LOGOFF),        ICID_LOGOFF, false, IDC_LOGOFF);
-
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || SHRestricted(REST_STARTMENULOGOFF) != 1)
-#else
-       if (IS_VALUE_ZERO(hkey, _T("NoClose")))
-#endif
-               AddButton(ResString(IDS_SHUTDOWN),      ICID_SHUTDOWN, false, IDC_SHUTDOWN);
-
-
-#ifndef _ROS_
-       AddButton(ResString(IDS_TERMINATE),     ICID_LOGOFF, false, IDC_TERMINATE);
-#endif
-
-
-#ifdef __MINGW32__
-       RegCloseKey(hkeyAdv);
-       RegCloseKey(hkey);
-#endif
-
-
-#ifdef _LIGHT_STARTMENU
-        // set the window size to fit all buttons
-       ResizeToButtons();
-#endif
-
-       return 0;
-}
-
-
-void StartMenuRoot::AddEntries()
-{
-       super::AddEntries();
-
-       AddButton(ResString(IDS_EXPLORE),       ICID_EXPLORER, false, IDC_EXPLORE);
-}
-
-
-LRESULT        StartMenuRoot::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_PAINT: {
-               PaintCanvas canvas(_hwnd);
-               Paint(canvas);
-               break;}
-
-         case WM_DISPLAYCHANGE:
-                // re-evaluate logo size using the correct color depth
-               ReadLogoSize();
-               break;
-
-         default:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-void StartMenuRoot::Paint(PaintCanvas& canvas)
-{
-       MemCanvas mem_dc;
-       ResBitmap bmp(GetLogoResId());
-       BitmapSelection sel(mem_dc, bmp);
-
-       ClientRect clnt(_hwnd);
-       int h = min(_logo_size.cy, clnt.bottom);
-
-       RECT rect = {0, 0, _logo_size.cx, clnt.bottom-h};
-       HBRUSH hbr = CreateSolidBrush(GetPixel(mem_dc, 0, 0));
-       FillRect(canvas, &rect, hbr);
-       DeleteObject(hbr);
-
-       PatBlt(canvas, _logo_size.cx, 0, 1, clnt.bottom, WHITENESS);
-
-    BitBlt(canvas, 0, clnt.bottom-h, _logo_size.cx, h, mem_dc, 0, ( h<_logo_size.cy ? _logo_size.cy-h : 0) , SRCCOPY);
-
-       super::Paint(canvas);
-}
-
-UINT StartMenuRoot::GetLogoResId()
-{
-       WindowCanvas dc(_hwnd);
-
-       int clr_bits = GetDeviceCaps(dc, BITSPIXEL);
-
-       if (clr_bits > 8)
-               return IDB_LOGOV;
-       else if (clr_bits > 4)
-               return IDB_LOGOV256;
-       else
-               return IDB_LOGOV16;
-}
-
-
-void StartMenuRoot::CloseStartMenu(int id)
-{
-       if (_submenu)
-               CloseSubmenus();
-
-       ShowWindow(_hwnd, SW_HIDE);
-}
-
-void StartMenuRoot::ProcessKey(int vk)
-{
-       switch(vk) {
-         case VK_LEFT:
-               if (_submenu)
-                       CloseOtherSubmenus();
-               // don't close start menu root
-               break;
-
-         default:
-               super::ProcessKey(vk);
-       }
-}
-
-
-int StartMenuHandler::Command(int id, int code)
-{
-       switch(id) {
-
-       // start menu root
-
-         case IDC_PROGRAMS:
-               CreateSubmenu(id, CSIDL_COMMON_PROGRAMS, CSIDL_PROGRAMS, ResString(IDS_PROGRAMS));
-               break;
-
-         case IDC_EXPLORE:
-               CloseStartMenu(id);
-               explorer_show_frame(SW_SHOWNORMAL);
-               break;
-
-         case IDC_LAUNCH:
-               CloseStartMenu(id);
-               ShowLaunchDialog(g_Globals._hwndDesktopBar);
-               break;
-
-         case IDC_DOCUMENTS:
-               CreateSubmenu(id, CSIDL_PERSONAL, ResString(IDS_DOCUMENTS));
-               break;
-
-         case IDC_RECENT:
-               CreateSubmenu(id, CSIDL_RECENT, ResString(IDS_RECENT), STARTMENU_CREATOR(RecentStartMenu));
-               break;
-
-         case IDC_FAVORITES:
-#ifndef _SHELL32_FAVORITES
-               CreateSubmenu(id, ResString(IDS_FAVORITES), STARTMENU_CREATOR(FavoritesMenu), &static_cast<BookmarkList&>(g_Globals._favorites));
-#else
-               CreateSubmenu(id, CSIDL_COMMON_FAVORITES, CSIDL_FAVORITES, ResString(IDS_FAVORITES));
-#endif
-               break;
-
-         case IDC_BROWSE:
-               CreateSubmenu(id, ResString(IDS_BROWSE), STARTMENU_CREATOR(BrowseMenu));
-               break;
-
-         case IDC_SETTINGS:
-               CreateSubmenu(id, ResString(IDS_SETTINGS), STARTMENU_CREATOR(SettingsMenu));
-               break;
-
-         case IDC_SEARCH:
-               CreateSubmenu(id, ResString(IDS_SEARCH), STARTMENU_CREATOR(SearchMenu));
-               break;
-
-         case IDC_START_HELP:
-               CloseStartMenu(id);
-               MessageBox(g_Globals._hwndDesktopBar, TEXT("Help not yet implemented"), ResString(IDS_TITLE), MB_OK);
-               break;
-
-         case IDC_LOGOFF:
-               CloseStartMenu(id);
-               ShowLogoffDialog(g_Globals._hwndDesktopBar);
-               break;
-
-#ifndef _ROS_
-         case IDC_TERMINATE:
-               DestroyWindow(GetParent(_hwnd));
-               break;
-#endif
-
-         case IDC_SHUTDOWN:
-               CloseStartMenu(id);
-               ShowExitWindowsDialog(g_Globals._hwndDesktopBar);
-               break;
-
-
-       // settings menu
-
-         case ID_DESKTOPBAR_SETTINGS:
-               CloseStartMenu(id);
-               ExplorerPropertySheet(g_Globals._hwndDesktopBar);
-               break;
-
-         case IDC_CONTROL_PANEL: {
-               CloseStartMenu(id);
-#ifndef ROSSHELL
-#ifndef _NO_MDI
-               XMLPos explorer_options = g_Globals.get_cfg("general/explorer");
-               bool mdi = XMLBool(explorer_options, "mdi", true);
-
-               if (mdi)
-                       MDIMainFrame::Create(TEXT("::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\\::{21EC2020-3AEA-1069-A2DD-08002B30309D}"), 0);
-               else
-#endif
-                       SDIMainFrame::Create(TEXT("::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\\::{21EC2020-3AEA-1069-A2DD-08002B30309D}"), 0);
-#else
-               launch_file(_hwnd, SHELLPATH_CONTROL_PANEL);
-#endif
-               break;}
-
-         case IDC_SETTINGS_MENU:
-               CreateSubmenu(id, CSIDL_CONTROLS, ResString(IDS_SETTINGS_MENU));
-               break;
-
-         case IDC_PRINTERS: {
-               CloseStartMenu(id);
-
-#ifndef ROSSHELL
-#ifdef _ROS_   // to be removed when printer folder will be implemented
-               MessageBox(0, TEXT("printer folder not yet implemented in SHELL32"), ResString(IDS_TITLE), MB_OK);
-#else
-#ifndef _NO_MDI
-               XMLPos explorer_options = g_Globals.get_cfg("general/explorer");
-               bool mdi = XMLBool(explorer_options, "mdi", true);
-
-               if (mdi)
-                       MDIMainFrame::Create(TEXT("::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\\::{21EC2020-3AEA-1069-A2DD-08002B30309D}\\::{2227A280-3AEA-1069-A2DE-08002B30309D}"), 0);
-               else
-#endif
-                       SDIMainFrame::Create(TEXT("::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\\::{21EC2020-3AEA-1069-A2DD-08002B30309D}\\::{2227A280-3AEA-1069-A2DE-08002B30309D}"), 0);
-#endif
-#else
-               launch_file(_hwnd, SHELLPATH_PRINTERS);
-#endif
-               break;}
-
-#if 0  ///@todo use printer start menu folder per default and allow opening "printers" cabinet window using the context menu
-         case IDC_PRINTERS_MENU:
-               CreateSubmenu(id, CSIDL_PRINTERS, CSIDL_PRINTHOOD, ResString(IDS_PRINTERS));
-/*             StartMenuFolders new_folders;
-
-               try {
-                       new_folders.push_back(ShellPath(TEXT("::{20D04FE0-3AEA-1069-A2D8-08002B30309D}\\::{21EC2020-3AEA-1069-A2DD-08002B30309D}\\::{2227A280-3AEA-1069-A2DE-08002B30309D}")));
-               } catch(COMException&) {
-               }
-
-               CreateSubmenu(id, new_folders, ResString(IDS_PRINTERS));*/
-               break;
-#endif
-
-         case IDC_ADMIN:
-#ifndef ROSSHELL
-               CreateSubmenu(id, CSIDL_COMMON_ADMINTOOLS, CSIDL_ADMINTOOLS, ResString(IDS_ADMIN));
-               //CloseStartMenu(id);
-               //MainFrame::Create(SpecialFolderPath(CSIDL_COMMON_ADMINTOOLS, _hwnd), OWM_PIDL);
-#else
-               launch_file(_hwnd, SpecialFolderFSPath(CSIDL_COMMON_ADMINTOOLS, _hwnd));
-#endif
-               break;
-
-         case IDC_CONNECTIONS:
-#ifndef ROSSHELL
-#ifdef _ROS_   // to be removed when RAS will be implemented
-               MessageBox(0, TEXT("RAS folder not yet implemented in SHELL32"), ResString(IDS_TITLE), MB_OK);
-#else
-               CreateSubmenu(id, CSIDL_CONNECTIONS, ResString(IDS_CONNECTIONS));
-               //CloseStartMenu(id);
-               //MainFrame::Create(SpecialFolderPath(CSIDL_CONNECTIONS, _hwnd), OWM_PIDL);
-#endif
-#else
-               launch_file(_hwnd, SHELLPATH_NET_CONNECTIONS);
-#endif
-               break;
-
-
-       // browse menu
-
-         case IDC_NETWORK:
-#ifdef _ROS_   ///@todo to be removed when network browsing will be implemented in shell namespace
-               MessageBox(0, TEXT("network not yet implemented"), ResString(IDS_TITLE), MB_OK);
-#else
-               CreateSubmenu(id, CSIDL_NETWORK, ResString(IDS_NETWORK));
-#endif
-               break;
-
-         case IDC_DRIVES:
-               ///@todo exclude removable drives
-               CreateSubmenu(id, CSIDL_DRIVES, ResString(IDS_DRIVES));
-               break;
-
-
-       // search menu
-
-         case IDC_SEARCH_PROGRAM:
-               CloseStartMenu(id);
-               Dialog::DoModal(IDD_SEARCH_PROGRAM, WINDOW_CREATOR(FindProgramDlg));
-               break;
-
-         case IDC_SEARCH_FILES:
-               CloseStartMenu(id);
-               ShowSearchDialog();
-               break;
-
-         case IDC_SEARCH_COMPUTER:
-               CloseStartMenu(id);
-               ShowSearchComputer();
-               break;
-
-
-         default:
-               return super::Command(id, code);
-       }
-
-       return 0;
-}
-
-
-void StartMenuHandler::ShowSearchDialog()
-{
-#ifndef _ROS_  ///@todo to be removed when SHFindFiles() will be implemented in shell32.dll
-       static DynamicFct<SHFINDFILES> SHFindFiles(TEXT("SHELL32"), 90);
-
-       if (SHFindFiles)
-               (*SHFindFiles)(NULL, NULL);
-       else
-#endif
-               MessageBox(0, TEXT("SHFindFiles() not yet implemented in SHELL32"), ResString(IDS_TITLE), MB_OK);
-}
-
-void StartMenuHandler::ShowSearchComputer()
-{
-#ifndef _ROS_  ///@todo to be removed when SHFindComputer() will be implemented in shell32.dll
-       static DynamicFct<SHFINDCOMPUTER> SHFindComputer(TEXT("SHELL32"), 91);
-
-       if (SHFindComputer)
-               (*SHFindComputer)(NULL, NULL);
-       else
-#endif
-               MessageBox(0, TEXT("SHFindComputer() not yet implemented in SHELL32"), ResString(IDS_TITLE), MB_OK);
-}
-
-void StartMenuHandler::ShowLaunchDialog(HWND hwndOwner)
-{
-        ///@todo All text phrases should be put into the resources.
-       static LPCSTR szTitle = "Run";
-       static LPCSTR szText = "Type the name of a program, folder, document, or Internet resource, and Explorer will open it for you.";
-
-       static DynamicFct<RUNFILEDLG> RunFileDlg(TEXT("SHELL32"), 61);
-
-        // Show "Run..." dialog
-       if (RunFileDlg) {
-#ifndef _ROS_ /* FIXME: our shell32 always expects Ansi strings */
-               if ((HIWORD(GetVersion())>>14) == W_VER_NT) {
-                       WCHAR wTitle[40], wText[256];
-
-                       MultiByteToWideChar(CP_ACP, 0, szTitle, -1, wTitle, 40);
-                       MultiByteToWideChar(CP_ACP, 0, szText, -1, wText, 256);
-
-                       (*RunFileDlg)(hwndOwner, 0, NULL, (LPCSTR)wTitle, (LPCSTR)wText, RFF_CALCDIRECTORY);
-               }
-               else
-#endif
-                       (*RunFileDlg)(hwndOwner, 0, NULL, szTitle, szText, RFF_CALCDIRECTORY);
-       }
-}
-
-void StartMenuHandler::ShowLogoffDialog(HWND hwndOwner)
-{
-       static DynamicFct<LOGOFFWINDOWSDIALOG> LogoffWindowsDialog(TEXT("SHELL32"), 54);
-//     static DynamicFct<RESTARTWINDOWSDLG> RestartDialog(TEXT("SHELL32"), 59);
-
-       if (LogoffWindowsDialog)
-               (*LogoffWindowsDialog)(0);
-/* The RestartDialog function prompts about some system setting change. This is not what we want to display here.
-       else if (RestartDialog)
-               return (*RestartDialog)(hwndOwner, (LPWSTR)L"You selected <Log Off>.\n\n", EWX_LOGOFF) == 1;    ///@todo ANSI string conversion if needed
-*/
-       else
-               MessageBox(hwndOwner, TEXT("LogoffWindowsDialog() not yet implemented in SHELL32"), ResString(IDS_TITLE), MB_OK);
-}
-
-void ShowExitWindowsDialog(HWND hwndOwner)
-{
-       static DynamicFct<EXITWINDOWSDLG> ExitWindowsDialog(TEXT("SHELL32"), 60);
-
-       if (ExitWindowsDialog)
-               (*ExitWindowsDialog)(hwndOwner);
-       else
-               MessageBox(hwndOwner, TEXT("ExitWindowsDialog() not yet implemented in SHELL32"), ResString(IDS_TITLE), MB_OK);
-}
-
-
-void SettingsMenu::AddEntries()
-{
-       super::AddEntries();
-
-#if defined(ROSSHELL) || defined(_ROS_)        // _ROS_ to be removed when printer/network will be implemented
-//TODO AddButton(ResString(IDS_PRINTERS),                      ICID_PRINTER, false, IDC_PRINTERS_MENU);
-       AddButton(ResString(IDS_CONNECTIONS),           ICID_NETWORK, false, IDC_CONNECTIONS);
-#else
-//TODO AddButton(ResString(IDS_PRINTERS),                      ICID_PRINTER, true, IDC_PRINTERS_MENU);
-       AddButton(ResString(IDS_CONNECTIONS),           ICID_NETCONNS, false, IDC_CONNECTIONS);
-#endif
-       AddButton(ResString(IDS_ADMIN),                         ICID_ADMIN, true, IDC_ADMIN);
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || !SHRestricted(REST_NOCONTROLPANEL))
-#endif
-       AddButton(ResString(IDS_SETTINGS_MENU), ICID_CONFIG, true, IDC_SETTINGS_MENU);
-
-       AddButton(ResString(IDS_DESKTOPBAR_SETTINGS), ICID_DESKSETTING, false, ID_DESKTOPBAR_SETTINGS);
-
-       AddButton(ResString(IDS_PRINTERS),                      ICID_PRINTER, false, IDC_PRINTERS);
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || !SHRestricted(REST_NOCONTROLPANEL))
-#endif
-               AddButton(ResString(IDS_CONTROL_PANEL), ICID_CONTROLPAN, false, IDC_CONTROL_PANEL);
-}
-
-void BrowseMenu::AddEntries()
-{
-       super::AddEntries();
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || !SHRestricted(REST_NONETHOOD))  // or REST_NOENTIRENETWORK ?
-#endif
-#if defined(ROSSHELL) || defined(_ROS_)        // _ROS_ to be removed when printer/network will be implemented
-               AddButton(ResString(IDS_NETWORK),               ICID_NETWORK, false, IDC_NETWORK);
-#else
-               AddButton(ResString(IDS_NETWORK),               ICID_NETWORK, true, IDC_NETWORK);
-#endif
-
-       AddButton(ResString(IDS_DRIVES),                        ICID_FOLDER, true, IDC_DRIVES);
-}
-
-void SearchMenu::AddEntries()
-{
-       super::AddEntries();
-
-       AddButton(ResString(IDS_SEARCH_FILES),          ICID_SEARCH_DOC, false, IDC_SEARCH_FILES);
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || !SHRestricted(REST_HASFINDCOMPUTERS))
-#endif
-               AddButton(ResString(IDS_SEARCH_COMPUTER),ICID_COMPUTER, false, IDC_SEARCH_COMPUTER);
-
-       AddButton(ResString(IDS_SEARCH_PRG),            ICID_APPS, false, IDC_SEARCH_PROGRAM);
-}
-
-
-void RecentStartMenu::AddEntries()
-{
-       for(StartMenuShellDirs::iterator it=_dirs.begin(); it!=_dirs.end(); ++it) {
-               StartMenuDirectory& smd = *it;
-               ShellDirectory& dir = smd._dir;
-
-               if (!dir._scanned) {
-                       WaitCursor wait;
-
-#ifdef _LAZY_ICONEXTRACT
-                       dir.smart_scan(SORT_NAME, SCAN_DONT_EXTRACT_ICONS);
-#else
-                       dir.smart_scan(SORT_NAME);
-#endif
-               }
-
-               dir.sort_directory(SORT_DATE);
-               AddShellEntries(dir, RECENT_DOCS_COUNT, smd._ignore);   ///@todo read max. count of entries from registry
-       }
-}
-
-
-#ifndef _SHELL32_FAVORITES
-
-void FavoritesMenu::AddEntries()
-{
-       super::AddEntries();
-
-       String lwr_filter = _create_info._filter;
-       lwr_filter.toLower();
-
-       for(BookmarkList::iterator it=_bookmarks.begin(); it!=_bookmarks.end(); ++it) {
-               BookmarkNode& node = *it;
-
-               int id = ++_next_id;
-
-               _entries[id] = node;
-
-               if (node._type == BookmarkNode::BMNT_FOLDER) {
-                       BookmarkFolder& folder = *node._pfolder;
-
-                       AddButton(folder._name, ICID_FOLDER, true, id);
-               } else if (node._type == BookmarkNode::BMNT_BOOKMARK) {
-                       Bookmark& bookmark = *node._pbookmark;
-
-                       ICON_ID icon = ICID_NONE;
-
-                       if (!bookmark._icon_path.empty())
-                               icon = g_Globals._icon_cache.extract(bookmark._icon_path, bookmark._icon_idx);
-
-                        // filter non-directory entries
-                       if (!lwr_filter.empty()) {
-                               String lwr_name = bookmark._name;
-                               String lwr_desc = bookmark._description;
-                               String lwr_url = bookmark._url;
-
-                               lwr_name.toLower();
-                               lwr_desc.toLower();
-                               lwr_url.toLower();
-
-                               if (!_tcsstr(lwr_name,lwr_filter) && !_tcsstr(lwr_desc,lwr_filter) && !_tcsstr(lwr_url,lwr_filter))
-                                       continue;
-                       }
-
-                       AddButton(bookmark._name, icon!=ICID_NONE?icon:ICID_BOOKMARK, false, id);
-               }
-       }
-}
-
-int FavoritesMenu::Command(int id, int code)
-{
-       BookmarkMap::iterator found = _entries.find(id);
-
-       if (found != _entries.end()) {
-               BookmarkNode& node = found->second;
-
-               if (node._type == BookmarkNode::BMNT_FOLDER) {
-                       BookmarkFolder& folder = *node._pfolder;
-
-                       if (CloseOtherSubmenus(id))
-                               CreateSubmenu(id, folder._name, STARTMENU_CREATOR(FavoritesMenu), &static_cast<BookmarkList&>(folder._bookmarks));
-               } else if (node._type == BookmarkNode::BMNT_BOOKMARK) {
-                       Bookmark& bookmark = *node._pbookmark;
-
-                       String url = bookmark._url;
-                       HWND hparent = GetParent(_hwnd);
-
-                       CloseStartMenu(id);
-
-                       launch_file(hparent, url, SW_SHOWNORMAL);
-               }
-
-               return 0;
-       }
-
-       return super::Command(id, code);
-}
-
-#endif
diff --git a/reactos/subsys/system/explorer/taskbar/startmenu.h b/reactos/subsys/system/explorer/taskbar/startmenu.h
deleted file mode 100644 (file)
index db9cc63..0000000
+++ /dev/null
@@ -1,474 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer and Desktop clone
- //
- // startmenu.h
- //
- // Martin Fuchs, 16.08.2003
- //
-
-
-#define        CLASSNAME_STARTMENU             TEXT("ReactosStartmenuClass")
-#define        TITLE_STARTMENU                 TEXT("Start Menu")
-
-
-#define        STARTMENU_WIDTH_MIN                                     120
-#define        STARTMENU_LINE_HEIGHT(icon_size)        (icon_size+4)
-#define        STARTMENU_SEP_HEIGHT(icon_size)         (STARTMENU_LINE_HEIGHT(icon_size)/2)
-#define        STARTMENU_TOP_BTN_SPACE                         8
-
-
- // private message constants
-#define        PM_STARTMENU_CLOSED             (WM_APP+0x11)
-#define        PM_STARTENTRY_LAUNCHED  (WM_APP+0x12)
-
-#ifndef _LIGHT_STARTMENU
-#define        PM_STARTENTRY_FOCUSED   (WM_APP+0x13)
-#endif
-
-#define        PM_UPDATE_ICONS                 (WM_APP+0x14)
-#define        PM_SELECT_ENTRY                 (WM_APP+0x15)
-
-
- /// StartMenuDirectory is used to store the base directory of start menus.
-struct StartMenuDirectory
-{
-       StartMenuDirectory(const ShellDirectory& dir, const String& ignore="")
-        :      _dir(dir), _ignore(ignore)
-       {
-       }
-
-       ~StartMenuDirectory()
-       {
-               _dir.free_subentries();
-       }
-
-       ShellDirectory _dir;
-       String  _ignore;
-};
-
-typedef list<StartMenuDirectory> StartMenuShellDirs;
-typedef set<Entry*> ShellEntrySet;
-
- /// structure holding information about one start menu entry
-struct StartMenuEntry
-{
-       StartMenuEntry() : _icon_id(ICID_UNKNOWN) {}
-
-       String  _title;
-       ICON_ID _icon_id;
-       ShellEntrySet _entries;
-};
-
-
-extern int GetStartMenuBtnTextWidth(HDC hdc, LPCTSTR title, HWND hwnd);
-
-
-#ifndef _LIGHT_STARTMENU
-
- /**
-       StartMenuButton draws the face of a StartMenuCtrl button control.
- */
-struct StartMenuButton : public OwnerdrawnButton
-{
-       typedef OwnerdrawnButton super;
-
-       StartMenuButton(HWND hwnd, ICON_ID icon_id, bool hasSubmenu)
-        :      super(hwnd), _hIcon(hIcon), _hasSubmenu(hasSubmenu) {}
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       virtual void DrawItem(LPDRAWITEMSTRUCT dis);
-
-       ICON_ID _icon_id;
-       bool    _hasSubmenu;
-};
-
-
- /**
-       To create a Startmenu button control, construct a StartMenuCtrl object.
- */
-struct StartMenuCtrl : public Button
-{
-       StartMenuCtrl(HWND parent, int x, int y, int w, LPCTSTR title,
-                                       UINT id, HICON hIcon=0, bool hasSubmenu=false, DWORD style=WS_VISIBLE|WS_CHILD|BS_OWNERDRAW, DWORD exStyle=0)
-        :      Button(parent, title, x, y, w, STARTMENU_LINE_HEIGHT(icon_size), id, style, exStyle)
-       {
-               *new StartMenuButton(_hwnd, hIcon, hasSubmenu);
-
-               SetWindowFont(_hwnd, GetStockFont(DEFAULT_GUI_FONT), FALSE);
-       }
-};
-
-
- /// separator between start menu entries
-struct StartMenuSeparator : public Static
-{
-       StartMenuSeparator(HWND parent, int x, int y, int w, DWORD style=WS_VISIBLE|WS_CHILD|WS_DISABLED|SS_ETCHEDHORZ, DWORD exStyle=0)
-        :      Static(parent, NULL, x, y+STARTMENU_SEP_HEIGHT(icon_size)/2-1, w, 2, -1, style, exStyle)
-       {
-       }
-};
-
-#endif
-
-
-typedef list<ShellPath> StartMenuFolders;
-
- /// structor containing information for creating of start menus
-struct StartMenuCreateInfo
-{
-       StartMenuCreateInfo() : _border_top(0) {}
-
-       StartMenuFolders _folders;
-       int             _border_top;
-       String  _title;
-       Window::CREATORFUNC_INFO _creator;
-       void*   _info;
-       String  _filter;
-};
-
-#define STARTMENU_CREATOR(WND_CLASS) WINDOW_CREATOR_INFO(WND_CLASS, StartMenuCreateInfo)
-
-typedef map<int, StartMenuEntry> ShellEntryMap;
-
-
-#ifdef _LIGHT_STARTMENU
-
-struct SMBtnInfo
-{
-       SMBtnInfo(const StartMenuEntry& entry, int id, bool hasSubmenu=false, bool enabled=true)
-        :      _title(entry._title),
-               _icon_id(entry._icon_id),
-               _id(id),
-               _hasSubmenu(hasSubmenu),
-               _enabled(enabled)
-       {
-       }
-
-       SMBtnInfo(LPCTSTR title, ICON_ID icon_id, int id, bool hasSubmenu=false, bool enabled=true)
-        :      _title(title),
-               _icon_id(icon_id),
-               _id(id),
-               _hasSubmenu(hasSubmenu),
-               _enabled(enabled)
-       {
-       }
-
-       String  _title;
-       ICON_ID _icon_id;
-       int             _id;
-       bool    _hasSubmenu;
-       bool    _enabled;
-};
-
-typedef vector<SMBtnInfo> SMBtnVector;
-
-extern void DrawStartMenuButton(HDC hdc, const RECT& rect, LPCTSTR title, const SMBtnInfo& btn, bool has_focus, bool pushed, int icon_size);
-
-#else
-
-extern void DrawStartMenuButton(HDC hdc, const RECT& rect, LPCTSTR title, HICON hIcon,
-                                                               bool hasSubmenu, bool enabled, bool has_focus, bool pushed, int icon_size);
-
-#endif
-
-
- /**
-       Startmenu window.
-       To create a start menu call its Create() function.
- */
-struct StartMenu :
-#ifdef _LIGHT_STARTMENU
-       public ExtContextMenuHandlerT<OwnerDrawParent<Window> >
-#else
-       public ExtContextMenuHandlerT<OwnerDrawParent<DialogWindow> >
-#endif
-{
-#ifdef _LIGHT_STARTMENU
-       typedef ExtContextMenuHandlerT<OwnerDrawParent<Window> > super;
-#else
-       typedef ExtContextMenuHandlerT<OwnerDrawParent<DialogWindow> > super;
-#endif
-
-       StartMenu(HWND hwnd, int icon_size=ICON_SIZE_SMALL);
-       StartMenu(HWND hwnd, const StartMenuCreateInfo& create_info, int icon_size=ICON_SIZE_SMALL);
-       ~StartMenu();
-
-       static HWND Create(int x, int y, const StartMenuFolders&, HWND hwndParent, LPCTSTR title,
-                                               CREATORFUNC_INFO creator=s_def_creator, void* info=NULL, const String& filter="");
-       static CREATORFUNC_INFO s_def_creator;
-
-protected:
-        // overridden member functions
-       LRESULT Init(LPCREATESTRUCT pcs);
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Command(int id, int code);
-
-        // window class
-       static BtnWindowClass& GetWndClasss();
-
-        // data members
-       int             _next_id;
-       ShellEntryMap _entries;
-       StartMenuShellDirs _dirs;
-
-       int             _submenu_id;
-       WindowHandle _submenu;
-
-       int             _border_left;   // left border in pixels
-       int             _border_top;    // top border in pixels
-       int             _bottom_max;    // limit display area for long start menus
-
-       bool    _floating_btn;
-       bool    _arrow_btns;
-
-       POINT   _last_pos;
-       enum SCROLL_MODE {SCROLL_NOT, SCROLL_UP, SCROLL_DOWN} _scroll_mode;
-       int             _scroll_pos;
-       int             _invisible_lines;
-
-       StartMenuCreateInfo _create_info;       // copy of the original create info
-
-       int             _icon_size;
-
-#ifdef _LIGHT_STARTMENU
-       SMBtnVector _buttons;
-       int             _selected_id;
-       LPARAM  _last_mouse_pos;
-
-       void    ResizeToButtons();
-       int             ButtonHitTest(POINT pt);
-       void    InvalidateSelection();
-       const SMBtnInfo* GetButtonInfo(int id) const;
-       bool    SelectButton(int id, bool open_sub=true);
-       bool    SelectButtonIndex(int idx, bool open_sub=true);
-       int             GetSelectionIndex();
-       virtual void ProcessKey(int vk);
-       bool    Navigate(int step);
-       bool    OpenSubmenu(bool select_first=false);
-       bool    JumpToNextShortcut(char c);
-#endif
-
-        // member functions
-       void    ResizeButtons(int cx);
-
-       virtual void AddEntries();
-
-       ShellEntryMap::iterator AddEntry(const String& title, ICON_ID icon_id, Entry* entry);
-       ShellEntryMap::iterator AddEntry(const String& title, ICON_ID icon_id=ICID_NONE, int id=-1);
-       ShellEntryMap::iterator AddEntry(const ShellFolder folder, ShellEntry* entry);
-       ShellEntryMap::iterator AddEntry(const ShellFolder folder, Entry* entry);
-
-       void    AddShellEntries(const ShellDirectory& dir, int max=-1, const String& ignore="");
-
-       void    AddButton(LPCTSTR title, ICON_ID icon_id=ICID_NONE, bool hasSubmenu=false, int id=-1, bool enabled=true);
-       void    AddSeparator();
-
-       bool    CloseSubmenus() {return CloseOtherSubmenus();}
-       bool    CloseOtherSubmenus(int id=0);
-       void    CreateSubmenu(int id, LPCTSTR title, CREATORFUNC_INFO creator=s_def_creator, void*info=NULL);
-       bool    CreateSubmenu(int id, int folder, LPCTSTR title, CREATORFUNC_INFO creator=s_def_creator, void*info=NULL);
-       bool    CreateSubmenu(int id, int folder1, int folder2, LPCTSTR title, CREATORFUNC_INFO creator=s_def_creator, void*info=NULL);
-       void    CreateSubmenu(int id, const StartMenuFolders& new_folders, LPCTSTR title, CREATORFUNC_INFO creator=s_def_creator, void*info=NULL);
-       void    ActivateEntry(int id, const ShellEntrySet& entries);
-       virtual void CloseStartMenu(int id=0);
-
-       bool    GetButtonRect(int id, PRECT prect) const;
-
-       void    DrawFloatingButton(HDC hdc);
-       void    GetFloatingButtonRect(LPRECT prect);
-       void    GetArrowButtonRects(LPRECT prect_up, LPRECT prect_down, int icon_size);
-
-       void    DrawArrows(HDC hdc, int icon_size);
-
-       void    Paint(PaintCanvas& canvas);
-       void    UpdateIcons(/*int idx*/);
-};
-
-
- // declare shell32's "Run..." dialog export function
-typedef        void (WINAPI* RUNFILEDLG)(HWND hwndOwner, HICON hIcon, LPCSTR lpstrDirectory, LPCSTR lpstrTitle, LPCSTR lpstrDescription, UINT uFlags);
-
- //
- // Flags for RunFileDlg
- //
-
-#define        RFF_NOBROWSE            0x01    // Removes the browse button.
-#define        RFF_NODEFAULT           0x02    // No default item selected.
-#define        RFF_CALCDIRECTORY       0x04    // Calculates the working directory from the file name.
-#define        RFF_NOLABEL                     0x08    // Removes the edit box label.
-#define        RFF_NOSEPARATEMEM       0x20    // Removes the Separate Memory Space check box (Windows NT only).
-
-
- // declare more previously undocumented shell32 functions
-typedef        void (WINAPI* EXITWINDOWSDLG)(HWND hwndOwner);
-typedef        int (WINAPI* LOGOFFWINDOWSDIALOG)(UINT flags);
-typedef        int (WINAPI* RESTARTWINDOWSDLG)(HWND hwndOwner, LPCWSTR reason, UINT flags);
-typedef        int (WINAPI* RESTARTWINDOWSDLGEX)(HWND hWndOwner, LPCWSTR lpwstrReason, DWORD uFlags, DWORD uReason);
-typedef        BOOL (WINAPI* SHFINDFILES)(LPCITEMIDLIST pidlRoot, LPCITEMIDLIST pidlSavedSearch);
-typedef        BOOL (WINAPI* SHFINDCOMPUTER)(LPCITEMIDLIST pidlRoot, LPCITEMIDLIST pidlSavedSearch);
-
-
- /// Handling of standard start menu commands
-struct StartMenuHandler : public StartMenu
-{
-       typedef StartMenu super;
-
-       StartMenuHandler(HWND hwnd, int icon_size=ICON_SIZE_SMALL)
-        :      super(hwnd, icon_size)
-       {
-       }
-
-       StartMenuHandler(HWND hwnd, const StartMenuCreateInfo& create_info, int icon_size=ICON_SIZE_SMALL)
-        :      super(hwnd, create_info, icon_size)
-       {
-       }
-
-protected:
-       int             Command(int id, int code);
-
-       static void     ShowLaunchDialog(HWND hwndOwner);
-       static void     ShowLogoffDialog(HWND hwndOwner);
-       static void     ShowSearchDialog();
-       static void     ShowSearchComputer();
-};
-
-
-struct StartMenuRootCreateInfo
-{
-       int     _icon_size;
-};
-
-
- /// Startmenu root window
-struct StartMenuRoot : public StartMenuHandler
-{
-       typedef StartMenuHandler super;
-
-       StartMenuRoot(HWND hwnd, const StartMenuRootCreateInfo& info);
-
-       static HWND Create(HWND hwndDesktopBar, int icon_size);
-       void    TrackStartmenu();
-
-protected:
-       LRESULT Init(LPCREATESTRUCT pcs);
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       SIZE    _logo_size;
-
-       virtual void AddEntries();
-       virtual void ProcessKey(int vk);
-
-       void    Paint(PaintCanvas& canvas);
-       void    CloseStartMenu(int id=0);
-
-       void    ReadLogoSize();
-       UINT    GetLogoResId();
-};
-
-
- /// Settings sub-startmenu
-struct SettingsMenu : public StartMenuHandler
-{
-       typedef StartMenuHandler super;
-
-       SettingsMenu(HWND hwnd, const StartMenuCreateInfo& create_info)
-        :      super(hwnd, create_info)
-       {
-       }
-
-protected:
-       virtual void AddEntries();
-};
-
-
- /// "Browse Files..." sub-start menu
-struct BrowseMenu : public StartMenuHandler
-{
-       typedef StartMenuHandler super;
-
-       BrowseMenu(HWND hwnd, const StartMenuCreateInfo& create_info)
-        :      super(hwnd, create_info)
-       {
-       }
-
-protected:
-       virtual void AddEntries();
-};
-
-
- /// Search sub-startmenu
-struct SearchMenu : public StartMenuHandler
-{
-       typedef StartMenuHandler super;
-
-       SearchMenu(HWND hwnd, const StartMenuCreateInfo& create_info)
-        :      super(hwnd, create_info)
-       {
-       }
-
-protected:
-       virtual void AddEntries();
-};
-
-
-#define        RECENT_DOCS_COUNT       20      ///@todo read max. count of entries from registry
-
- /// "Recent Files" sub-start menu
-struct RecentStartMenu : public StartMenu
-{
-       typedef StartMenu super;
-
-       RecentStartMenu(HWND hwnd, const StartMenuCreateInfo& create_info)
-        :      super(hwnd, create_info)
-       {
-       }
-
-protected:
-       virtual void AddEntries();
-};
-
-
-#ifndef _SHELL32_FAVORITES
-
-typedef map<int, BookmarkNode> BookmarkMap;
-
- /// Bookmarks sub-startmenu
-struct FavoritesMenu : public StartMenu
-{
-       typedef StartMenu super;
-
-       FavoritesMenu(HWND hwnd, const StartMenuCreateInfo& create_info)
-        :      super(hwnd, create_info),
-               _bookmarks(*(BookmarkList*)create_info._info)
-       {
-       }
-
-protected:
-       virtual int Command(int id, int code);
-       virtual void AddEntries();
-
-       BookmarkList _bookmarks;
-       BookmarkMap     _entries;
-};
-
-#endif
diff --git a/reactos/subsys/system/explorer/taskbar/taskbar.cpp b/reactos/subsys/system/explorer/taskbar/taskbar.cpp
deleted file mode 100644 (file)
index e7dd94e..0000000
+++ /dev/null
@@ -1,584 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // taskbar.cpp
- //
- // Martin Fuchs, 16.08.2003
- //
-
-
-#include <precomp.h>
-
-#include "taskbar.h"
-#include "traynotify.h" // for NOTIFYAREA_WIDTH_DEF
-
-
-DynamicFct<BOOL (WINAPI*)(HWND hwnd)> g_SetTaskmanWindow(TEXT("user32"), "SetTaskmanWindow");
-DynamicFct<BOOL (WINAPI*)(HWND hwnd)> g_RegisterShellHookWindow(TEXT("user32"), "RegisterShellHookWindow");
-DynamicFct<BOOL (WINAPI*)(HWND hwnd)> g_DeregisterShellHookWindow(TEXT("user32"), "DeregisterShellHookWindow");
-
-/*
-DynamicFct<BOOL (WINAPI*)(HWND hWnd, DWORD dwType)> g_RegisterShellHook(TEXT("shell32"), (LPCSTR)0xb5);
-
- // constants for RegisterShellHook()
-#define RSH_UNREGISTER                 0
-#define RSH_REGISTER                   1
-#define RSH_REGISTER_PROGMAN   2
-#define RSH_REGISTER_TASKMAN   3
-*/
-
-
-TaskBarEntry::TaskBarEntry()
-{
-       _id = 0;
-       _hbmp = 0;
-       _bmp_idx = 0;
-       _used = 0;
-       _btn_idx = 0;
-       _fsState = 0;
-}
-
-TaskBarMap::~TaskBarMap()
-{
-       while(!empty()) {
-               iterator it = begin();
-               DeleteBitmap(it->second._hbmp);
-               erase(it);
-       }
-}
-
-
-TaskBar::TaskBar(HWND hwnd)
- :     super(hwnd),
-       WM_SHELLHOOK(RegisterWindowMessage(WINMSG_SHELLHOOK))
-{
-       _last_btn_width = 0;
-
-       _mmMetrics_org.cbSize = sizeof(MINIMIZEDMETRICS);
-
-       SystemParametersInfo(SPI_GETMINIMIZEDMETRICS, sizeof(_mmMetrics_org), &_mmMetrics_org, 0);
-
-        // configure the window manager to hide windows when they are minimized
-        // This is neccessary to enable shell hook messages.
-       if (!(_mmMetrics_org.iArrange & ARW_HIDE)) {
-               MINIMIZEDMETRICS _mmMetrics_new = _mmMetrics_org;
-
-               _mmMetrics_new.iArrange |= ARW_HIDE;
-
-               SystemParametersInfo(SPI_SETMINIMIZEDMETRICS, sizeof(_mmMetrics_new), &_mmMetrics_new, 0);
-       }
-}
-
-TaskBar::~TaskBar()
-{
-//     if (g_RegisterShellHook)
-//             (*g_RegisterShellHook)(_hwnd, RSH_UNREGISTER);
-
-       if (g_DeregisterShellHookWindow)
-               (*g_DeregisterShellHookWindow)(_hwnd);
-       else
-               KillTimer(_hwnd, 0);
-
-       if (g_SetTaskmanWindow)
-               (*g_SetTaskmanWindow)(0);
-
-       SystemParametersInfo(SPI_GETMINIMIZEDMETRICS, sizeof(_mmMetrics_org), &_mmMetrics_org, 0);
-}
-
-HWND TaskBar::Create(HWND hwndParent)
-{
-       ClientRect clnt(hwndParent);
-
-       int taskbar_pos = 80;   // This start position will be adjusted in DesktopBar::Resize().
-
-       return Window::Create(WINDOW_CREATOR(TaskBar), 0,
-                                                       BtnWindowClass(CLASSNAME_TASKBAR), TITLE_TASKBAR,
-                                                       WS_CHILD|WS_VISIBLE | CCS_TOP|CCS_NODIVIDER|CCS_NORESIZE,
-                                                       taskbar_pos, 0, clnt.right-taskbar_pos-(NOTIFYAREA_WIDTH_DEF+1), clnt.bottom, hwndParent);
-}
-
-LRESULT TaskBar::Init(LPCREATESTRUCT pcs)
-{
-       if (super::Init(pcs))
-               return 1;
-
-       /* FIXME: There's an internal padding for non-flat toolbar. Get rid of it somehow. */
-       _htoolbar = CreateToolbarEx(_hwnd,
-                                                               WS_CHILD|WS_VISIBLE|WS_CLIPSIBLINGS|WS_CLIPCHILDREN|
-                                                               CCS_TOP|CCS_NODIVIDER|TBSTYLE_LIST|TBSTYLE_TOOLTIPS|TBSTYLE_WRAPABLE,//|TBSTYLE_AUTOSIZE
-                                                               IDW_TASKTOOLBAR, 0, 0, 0, NULL, 0, 0, 0, 16, 16, sizeof(TBBUTTON));
-
-       SendMessage(_htoolbar, TB_SETBUTTONWIDTH, 0, MAKELONG(TASKBUTTONWIDTH_MAX,TASKBUTTONWIDTH_MAX));
-       //SendMessage(_htoolbar, TB_SETEXTENDEDSTYLE, 0, TBSTYLE_EX_MIXEDBUTTONS);
-       //SendMessage(_htoolbar, TB_SETDRAWTEXTFLAGS, DT_CENTER|DT_VCENTER, DT_CENTER|DT_VCENTER);
-       //SetWindowFont(_htoolbar, GetStockFont(ANSI_VAR_FONT), FALSE);
-       //SendMessage(_htoolbar, TB_SETPADDING, 0, MAKELPARAM(8,8));
-
-#ifndef __MINGW32__    // TBMETRICS missing in MinGW (as of 20.09.2005)
-        // set metrics for the Taskbar toolbar to enable button spacing
-       TBMETRICS metrics;
-
-       metrics.cbSize = sizeof(TBMETRICS);
-       metrics.dwMask = TBMF_BARPAD | TBMF_BUTTONSPACING;
-       metrics.cxBarPad = 0;
-       metrics.cyBarPad = 0;
-       metrics.cxButtonSpacing = 3;
-       metrics.cyButtonSpacing = 3;
-
-       SendMessage(_htoolbar, TB_SETMETRICS, 0, (LPARAM)&metrics);
-#endif
-
-       _next_id = IDC_FIRST_APP;
-
-        // register the taskbar window as task manager window to make the following call to RegisterShellHookWindow working
-       if (g_SetTaskmanWindow)
-               (*g_SetTaskmanWindow)(_hwnd);
-
-       if (g_RegisterShellHookWindow) {
-               LOG(TEXT("Using shell hooks for notification of shell events."));
-
-               (*g_RegisterShellHookWindow)(_hwnd);
-       } else {
-               LOG(TEXT("Shell hooks not available."));
-
-               SetTimer(_hwnd, 0, 200, NULL);
-       }
-
-/* Alternatively we could use the RegisterShellHook() function in SHELL32, but this is not yet implemented in the WINE code.
-       if (g_RegisterShellHook) {
-               (*g_RegisterShellHook)(0, RSH_REGISTER);
-
-               if ((HIWORD(GetVersion())>>14) == W_VER_NT)
-                       (*g_RegisterShellHook)(_hwnd, RSH_REGISTER_TASKMAN);
-               else
-                       (*g_RegisterShellHook)(_hwnd, RSH_REGISTER);
-       }
-*/
-       Refresh();
-
-       return 0;
-}
-
-LRESULT TaskBar::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_SIZE:
-               SendMessage(_htoolbar, WM_SIZE, 0, 0);
-               ResizeButtons();
-               break;
-
-         case WM_TIMER:
-               Refresh();
-               return 0;
-
-         case WM_CONTEXTMENU: {
-               Point pt(lparam);
-               ScreenToClient(_htoolbar, &pt);
-
-               if ((HWND)wparam==_htoolbar && SendMessage(_htoolbar, TB_HITTEST, 0, (LPARAM)&pt)>=0)
-                       break;  // avoid displaying context menu for application button _and_ desktop bar at the same time
-
-               goto def;}
-
-         case PM_GET_LAST_ACTIVE:
-               return (LRESULT)(HWND)_last_foreground_wnd;
-
-         default: def:
-               if (nmsg == WM_SHELLHOOK) {
-                       switch(wparam) {
-                         case HSHELL_WINDOWCREATED:
-                         case HSHELL_WINDOWDESTROYED:
-                         case HSHELL_WINDOWACTIVATED:
-                         case HSHELL_REDRAW:
-#ifdef HSHELL_FLASH
-                         case HSHELL_FLASH:
-#endif
-#ifdef HSHELL_RUDEAPPACTIVATED
-                         case HSHELL_RUDEAPPACTIVATED:
-#endif
-                               Refresh();
-                               break;
-                       }
-               } else {
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-       }
-
-       return 0;
-}
-
-int TaskBar::Command(int id, int code)
-{
-       TaskBarMap::iterator found = _map.find_id(id);
-
-       if (found != _map.end()) {
-               ActivateApp(found);
-               return 0;
-       }
-
-       return super::Command(id, code);
-}
-
-int TaskBar::Notify(int id, NMHDR* pnmh)
-{
-       if (pnmh->hwndFrom == _htoolbar)
-               switch(pnmh->code) {
-                 case NM_RCLICK: {
-                       TBBUTTONINFO btninfo;
-                       TaskBarMap::iterator it;
-                       Point pt(GetMessagePos());
-                       ScreenToClient(_htoolbar, &pt);
-
-                       btninfo.cbSize = sizeof(TBBUTTONINFO);
-                       btninfo.dwMask = TBIF_BYINDEX|TBIF_COMMAND;
-
-                       int idx = SendMessage(_htoolbar, TB_HITTEST, 0, (LPARAM)&pt);
-
-                       if (idx>=0 &&
-                               SendMessage(_htoolbar, TB_GETBUTTONINFO, idx, (LPARAM)&btninfo)!=-1 &&
-                               (it=_map.find_id(btninfo.idCommand))!=_map.end()) {
-                               //TaskBarEntry& entry = it->second;
-
-                               ActivateApp(it, false, false);  // don't restore minimized windows on right button click
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-                               static DynamicFct<DWORD(STDAPICALLTYPE*)(RESTRICTIONS)> pSHRestricted(TEXT("SHELL32"), "SHRestricted");
-
-                               if (pSHRestricted && !(*pSHRestricted)(REST_NOTRAYCONTEXTMENU))
-#endif
-                                       ShowAppSystemMenu(it);
-                       }
-                       break;}
-
-                 default:
-                       return super::Notify(id, pnmh);
-               }
-
-       return 0;
-}
-
-
-void TaskBar::ActivateApp(TaskBarMap::iterator it, bool can_minimize, bool can_restore)
-{
-       HWND hwnd = it->first;
-
-       bool minimize_it = can_minimize && !IsIconic(hwnd) &&
-                                               (hwnd==GetForegroundWindow() || hwnd==_last_foreground_wnd);
-
-        // switch to selected application window
-       if (can_restore && !minimize_it)
-               if (IsIconic(hwnd))
-                       PostMessage(hwnd, WM_SYSCOMMAND, SC_RESTORE, 0);
-
-        // In case minimize_it is true, we _have_ to switch to the app before
-        // posting SW_MINIMIZE to be compatible with some applications (e.g. "Sleipnir")
-       SetForegroundWindow(hwnd);
-
-       if (minimize_it) {
-               PostMessage(hwnd, WM_SYSCOMMAND, SC_MINIMIZE, 0);
-               _last_foreground_wnd = 0;
-       } else
-               _last_foreground_wnd = hwnd;
-
-       Refresh();
-}
-
-void TaskBar::ShowAppSystemMenu(TaskBarMap::iterator it)
-{
-       HMENU hmenu = GetSystemMenu(it->first, FALSE);
-
-       if (hmenu) {
-               POINT pt;
-
-               GetCursorPos(&pt);
-               int cmd = TrackPopupMenu(hmenu, TPM_LEFTBUTTON|TPM_RIGHTBUTTON|TPM_RETURNCMD, pt.x, pt.y, 0, _hwnd, NULL);
-
-               if (cmd) {
-                       ActivateApp(it, false, false);  // reactivate window after the context menu has closed
-                       PostMessage(it->first, WM_SYSCOMMAND, cmd, 0);
-               }
-       }
-}
-
-
-HICON get_window_icon_small(HWND hwnd)
-{
-       HICON hIcon = 0;
-
-       SendMessageTimeout(hwnd, WM_GETICON, ICON_SMALL2, 0, SMTO_ABORTIFHUNG, 1000, (LPDWORD)&hIcon);
-
-       if (!hIcon)
-               SendMessageTimeout(hwnd, WM_GETICON, ICON_SMALL, 0, SMTO_ABORTIFHUNG, 1000, (LPDWORD)&hIcon);
-
-       if (!hIcon)
-               SendMessageTimeout(hwnd, WM_GETICON, ICON_BIG, 0, SMTO_ABORTIFHUNG, 1000, (LPDWORD)&hIcon);
-
-       if (!hIcon)
-               hIcon = (HICON)GetClassLong(hwnd, GCL_HICONSM);
-
-       if (!hIcon)
-               hIcon = (HICON)GetClassLong(hwnd, GCL_HICON);
-
-       if (!hIcon)
-               SendMessageTimeout(hwnd, WM_QUERYDRAGICON, 0, 0, 0, 1000, (LPDWORD)&hIcon);
-
-       return hIcon;
-}
-
-HICON get_window_icon_big(HWND hwnd, bool allow_from_class)
-{
-       HICON hIcon = 0;
-
-       SendMessageTimeout(hwnd, WM_GETICON, ICON_BIG, 0, SMTO_ABORTIFHUNG, 1000, (LPDWORD)&hIcon);
-
-       if (!hIcon)
-               SendMessageTimeout(hwnd, WM_GETICON, ICON_SMALL2, 0, SMTO_ABORTIFHUNG, 1000, (LPDWORD)&hIcon);
-
-       if (!hIcon)
-               SendMessageTimeout(hwnd, WM_GETICON, ICON_SMALL, 0, SMTO_ABORTIFHUNG, 1000, (LPDWORD)&hIcon);
-
-       if (allow_from_class) {
-               if (!hIcon)
-                       hIcon = (HICON)GetClassLong(hwnd, GCL_HICON);
-
-               if (!hIcon)
-                       hIcon = (HICON)GetClassLong(hwnd, GCL_HICONSM);
-       }
-
-       if (!hIcon)
-               SendMessageTimeout(hwnd, WM_QUERYDRAGICON, 0, 0, 0, 1000, (LPDWORD)&hIcon);
-
-       return hIcon;
-}
-
- // fill task bar with buttons for enumerated top level windows
-BOOL CALLBACK TaskBar::EnumWndProc(HWND hwnd, LPARAM lparam)
-{
-       TaskBar* pThis = (TaskBar*)lparam;
-
-       DWORD style = GetWindowStyle(hwnd);
-       DWORD ex_style = GetWindowExStyle(hwnd);
-
-       if ((style&WS_VISIBLE) && !(ex_style&WS_EX_TOOLWINDOW) &&
-               !GetParent(hwnd) && !GetWindow(hwnd,GW_OWNER)) {
-               TCHAR title[BUFFER_LEN];
-
-               if (!GetWindowText(hwnd, title, BUFFER_LEN))
-                       title[0] = '\0';
-
-               TaskBarMap::iterator found = pThis->_map.find(hwnd);
-               int last_id = 0;
-
-               if (found != pThis->_map.end()) {
-                       last_id = found->second._id;
-
-                       if (!last_id)
-                               found->second._id = pThis->_next_id++;
-               } else {
-                       HBITMAP hbmp;
-                       HICON hIcon = get_window_icon_small(hwnd);
-                       BOOL delete_icon = FALSE;
-
-                       if (!hIcon) {
-                               hIcon = LoadIcon(0, IDI_APPLICATION);
-                               delete_icon = TRUE;
-                       }
-
-                       if (hIcon) {
-                               hbmp = create_bitmap_from_icon(hIcon, GetSysColorBrush(COLOR_BTNFACE), WindowCanvas(pThis->_htoolbar));
-                               if (delete_icon)
-                                       DestroyIcon(hIcon); // some icons can be freed, some not - so ignore any error return of DestroyIcon()
-                       } else
-                               hbmp = 0;
-
-                       TBADDBITMAP ab = {0, (UINT_PTR)hbmp};
-                       int bmp_idx = SendMessage(pThis->_htoolbar, TB_ADDBITMAP, 1, (LPARAM)&ab);
-
-                       TaskBarEntry entry;
-
-                       entry._id = pThis->_next_id++;
-                       entry._hbmp = hbmp;
-                       entry._bmp_idx = bmp_idx;
-                       entry._title = title;
-
-                       pThis->_map[hwnd] = entry;
-                       found = pThis->_map.find(hwnd);
-               }
-
-               TBBUTTON btn = {-2/*I_IMAGENONE*/, 0, TBSTATE_ENABLED/*|TBSTATE_ELLIPSES*/, BTNS_BUTTON, {0, 0}, 0, 0};
-               TaskBarEntry& entry = found->second;
-
-               ++entry._used;
-               btn.idCommand = entry._id;
-
-               HWND foreground = GetForegroundWindow();
-               HWND foreground_owner = GetWindow(foreground, GW_OWNER);
-
-               if (hwnd==foreground || hwnd==foreground_owner) {
-                       btn.fsState |= TBSTATE_PRESSED|TBSTATE_CHECKED;
-                       pThis->_last_foreground_wnd = hwnd;
-               }
-
-               if (!last_id) {
-                        // create new toolbar buttons for new windows
-                       if (title[0])
-                               btn.iString = (INT_PTR)title;
-
-                       btn.iBitmap = entry._bmp_idx;
-                       entry._btn_idx = SendMessage(pThis->_htoolbar, TB_BUTTONCOUNT, 0, 0);
-
-                       SendMessage(pThis->_htoolbar, TB_INSERTBUTTON, entry._btn_idx, (LPARAM)&btn);
-
-                       pThis->ResizeButtons();
-               } else {
-                        // refresh attributes of existing buttons
-                       if (btn.fsState != entry._fsState)
-                               SendMessage(pThis->_htoolbar, TB_SETSTATE, entry._id, MAKELONG(btn.fsState,0));
-
-                       if (entry._title != title) {
-                               TBBUTTONINFO info;
-
-                               info.cbSize = sizeof(TBBUTTONINFO);
-                               info.dwMask = TBIF_TEXT;
-                               info.pszText = title;
-
-                               SendMessage(pThis->_htoolbar, TB_SETBUTTONINFO, entry._id, (LPARAM)&info);
-
-                               entry._title = title;
-                       }
-               }
-
-               entry._fsState = btn.fsState;
-
-#ifdef _ROS_   // now handled by activating the ARW_HIDE flag with SystemParametersInfo(SPI_SETMINIMIZEDMETRICS)
-                // move minimized windows out of sight
-               if (IsIconic(hwnd)) {
-                       RECT rect;
-
-                       GetWindowRect(hwnd, &rect);
-
-                       if (rect.bottom > 0)
-                               SetWindowPos(hwnd, 0, -32000, -32000, 0, 0, SWP_NOSIZE|SWP_NOZORDER|SWP_NOACTIVATE);
-               }
-#endif
-       }
-
-       return TRUE;
-}
-
-void TaskBar::Refresh()
-{
-       for(TaskBarMap::iterator it=_map.begin(); it!=_map.end(); ++it)
-               it->second._used = 0;
-
-       EnumWindows(EnumWndProc, (LPARAM)this);
-       //EnumDesktopWindows(GetThreadDesktop(GetCurrentThreadId()), EnumWndProc, (LPARAM)_htoolbar);
-
-       set<int> btn_idx_to_delete;
-       set<HBITMAP> hbmp_to_delete;
-
-       for(TaskBarMap::iterator it=_map.begin(); it!=_map.end(); ++it) {
-               TaskBarEntry& entry = it->second;
-
-               if (!entry._used && entry._id) {
-                        // store button indexes to remove
-                       btn_idx_to_delete.insert(entry._btn_idx);
-                       hbmp_to_delete.insert(entry._hbmp);
-                       entry._id = 0;
-               }
-       }
-
-       if (!btn_idx_to_delete.empty()) {
-                // remove buttons from right to left
-               for(set<int>::reverse_iterator it=btn_idx_to_delete.rbegin(); it!=btn_idx_to_delete.rend(); ++it) {
-                       int idx = *it;
-
-                       SendMessage(_htoolbar, TB_DELETEBUTTON, idx, 0);
-
-                       for(TaskBarMap::iterator it=_map.begin(); it!=_map.end(); ++it) {
-                               TaskBarEntry& entry = it->second;
-
-                                // adjust button indexes
-                               if (entry._btn_idx > idx) {
-                                       --entry._btn_idx;
-                                       --entry._bmp_idx;
-
-                                       TBBUTTONINFO info;
-
-                                       info.cbSize = sizeof(TBBUTTONINFO);
-                                       info.dwMask = TBIF_IMAGE;
-                                       info.iImage = entry._bmp_idx;
-
-                                       SendMessage(_htoolbar, TB_SETBUTTONINFO, entry._id, (LPARAM)&info);
-                               }
-                       }
-               }
-
-               for(set<HBITMAP>::iterator it=hbmp_to_delete.begin(); it!=hbmp_to_delete.end(); ++it) {
-                       HBITMAP hbmp = *it;
-
-                       TBREPLACEBITMAP tbrepl = {0, (UINT_PTR)hbmp, 0, 0};
-                       SendMessage(_htoolbar, TB_REPLACEBITMAP, 0, (LPARAM)&tbrepl);
-
-                       DeleteObject(hbmp);
-
-                       for(TaskBarMap::iterator it=_map.begin(); it!=_map.end(); ++it)
-                               if (it->second._hbmp == hbmp) {
-                                       _map.erase(it);
-                                       break;
-                               }
-               }
-
-               ResizeButtons();
-       }
-}
-
-TaskBarMap::iterator TaskBarMap::find_id(int id)
-{
-       for(iterator it=begin(); it!=end(); ++it)
-               if (it->second._id == id)
-                       return it;
-
-       return end();
-}
-
-void TaskBar::ResizeButtons()
-{
-       int btns = _map.size();
-
-       if (btns > 0) {
-               int bar_width = ClientRect(_hwnd).right;
-               int btn_width = (bar_width / btns) - 3;
-
-               if (btn_width < TASKBUTTONWIDTH_MIN)
-                       btn_width = TASKBUTTONWIDTH_MIN;
-               else if (btn_width > TASKBUTTONWIDTH_MAX)
-                       btn_width = TASKBUTTONWIDTH_MAX;
-
-               if (btn_width != _last_btn_width) {
-                       _last_btn_width = btn_width;
-
-                       SendMessage(_htoolbar, TB_SETBUTTONWIDTH, 0, MAKELONG(btn_width,btn_width));
-                       SendMessage(_htoolbar, TB_AUTOSIZE, 0, 0);
-               }
-       }
-}
diff --git a/reactos/subsys/system/explorer/taskbar/taskbar.h b/reactos/subsys/system/explorer/taskbar/taskbar.h
deleted file mode 100644 (file)
index e752af8..0000000
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer and Desktop clone
- //
- // taskbar.h
- //
- // Martin Fuchs, 16.08.2003
- //
-
-
-//#include "shellhook.h"
-
-
-#define        CLASSNAME_TASKBAR               TEXT("MSTaskSwWClass")
-#define        TITLE_TASKBAR                   TEXT("Running Applications")
-
-#define        IDC_FIRST_APP   0x2000
-
-//#define TASKBAR_AT_TOP
-
-#define        TASKBUTTONWIDTH_MIN             38
-#define        TASKBUTTONWIDTH_MAX             160
-
-
-#define        IDW_TASKTOOLBAR 100
-
-
-#define        PM_GET_LAST_ACTIVE      (WM_APP+0x1D)
-
-
- /// internal task bar button management entry
-struct TaskBarEntry
-{
-       TaskBarEntry();
-
-       int             _id;    // ID for WM_COMMAND
-       HBITMAP _hbmp;
-       int             _bmp_idx;
-       int             _used;
-       int             _btn_idx;
-       String  _title;
-       BYTE    _fsState;
-};
-
- /// map for managing the task bar buttons, mapped by application window handle
-struct TaskBarMap : public map<HWND, TaskBarEntry>
-{
-       ~TaskBarMap();
-
-       iterator find_id(int id);
-};
-
-
- /// Taskbar window
-struct TaskBar : public Window
-{
-       typedef Window super;
-
-       TaskBar(HWND hwnd);
-       ~TaskBar();
-
-       static HWND Create(HWND hwndParent);
-
-protected:
-       WindowHandle _htoolbar;
-       TaskBarMap      _map;
-       int                     _next_id;
-       WindowHandle _last_foreground_wnd;
-       int                     _last_btn_width;
-       MINIMIZEDMETRICS _mmMetrics_org;
-
-       const UINT WM_SHELLHOOK;
-
-       LRESULT Init(LPCREATESTRUCT pcs);
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Command(int id, int code);
-       int             Notify(int id, NMHDR* pnmh);
-
-       void    ActivateApp(TaskBarMap::iterator it, bool can_minimize=true, bool can_restore=true);
-       void    ShowAppSystemMenu(TaskBarMap::iterator it);
-
-       static BOOL CALLBACK EnumWndProc(HWND hwnd, LPARAM lparam);
-
-       void    Refresh();
-       void    ResizeButtons();
-};
diff --git a/reactos/subsys/system/explorer/taskbar/traynotify.cpp b/reactos/subsys/system/explorer/taskbar/traynotify.cpp
deleted file mode 100644 (file)
index d8878cf..0000000
+++ /dev/null
@@ -1,1364 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // traynotify.cpp
- //
- // Martin Fuchs, 22.08.2003
- //
-
-
-#include <precomp.h>
-
-#include "../resource.h"
-
-#include "traynotify.h"
-
-
-#include "../notifyhook/notifyhook.h"
-
-NotifyHook::NotifyHook()
- :     WM_GETMODULEPATH(InstallNotifyHook())
-{
-}
-
-NotifyHook::~NotifyHook()
-{
-       DeinstallNotifyHook();
-}
-
-void NotifyHook::GetModulePath(HWND hwnd, HWND hwndCallback)
-{
-       PostMessage(hwnd, WM_GETMODULEPATH, (WPARAM)hwndCallback, 0);
-}
-
-bool NotifyHook::ModulePathCopyData(LPARAM lparam, HWND* phwnd, String& path)
-{
-       char buffer[MAX_PATH];
-
-       int l = GetWindowModulePathCopyData(lparam, phwnd, buffer, COUNTOF(buffer));
-
-       if (l) {
-               path.assign(buffer, l);
-               return true;
-       } else
-               return false;
-}
-
-
-NotifyIconIndex::NotifyIconIndex(NOTIFYICONDATA* pnid)
-{
-       _hWnd = pnid->hWnd;
-       _uID = pnid->uID;
-
-        // special handling for windows task manager
-       if ((int)_uID < 0)
-               _uID = 0;
-}
-
-NotifyIconIndex::NotifyIconIndex()
-{
-       _hWnd = 0;
-       _uID = 0;
-}
-
-
-NotifyInfo::NotifyInfo()
-{
-       _idx = -1;
-       _hIcon = 0;
-       _dwState = 0;
-       _uCallbackMessage = 0;
-       _version = 0;
-
-       _mode = NIM_AUTO;
-       _lastChange = GetTickCount();
-}
-
-
- // WCHAR versions von NOTIFYICONDATA
-#define        NID_SIZE_W6      sizeof(NOTIFYICONDATAW)                                                                                // _WIN32_IE = 0x600
-#define        NID_SIZE_W5     (sizeof(NOTIFYICONDATAW)-sizeof(GUID))                                                  // _WIN32_IE = 0x500
-#define        NID_SIZE_W3     (sizeof(NOTIFYICONDATAW)-sizeof(GUID)-(128-64)*sizeof(WCHAR))   // _WIN32_IE < 0x500
-
- // CHAR versions von NOTIFYICONDATA
-#define        NID_SIZE_A6      sizeof(NOTIFYICONDATAA)
-#define        NID_SIZE_A5     (sizeof(NOTIFYICONDATAA)-sizeof(GUID))
-#define        NID_SIZE_A3     (sizeof(NOTIFYICONDATAA)-sizeof(GUID)-(128-64)*sizeof(CHAR))
-
-bool NotifyInfo::modify(NOTIFYICONDATA* pnid)
-{
-       bool changes = false;
-
-       if (_hWnd!=pnid->hWnd || _uID!=pnid->uID) {
-               _hWnd = pnid->hWnd;
-               _uID = pnid->uID;
-
-               changes = true;
-       }
-
-       if (pnid->uFlags & NIF_MESSAGE) {
-               if (_uCallbackMessage != pnid->uCallbackMessage) {
-                       _uCallbackMessage = pnid->uCallbackMessage;
-                       changes = true;
-               }
-       }
-
-       if (pnid->uFlags & NIF_ICON) {
-                // Some applications destroy the icon immediatelly after completing the
-                // NIM_ADD/MODIFY message, so we have to make a copy of it.
-               if (_hIcon)
-                       DestroyIcon(_hIcon);
-
-               _hIcon = (HICON) CopyImage(pnid->hIcon, IMAGE_ICON, NOTIFYICON_SIZE, NOTIFYICON_SIZE, 0);
-
-               changes = true; ///@todo compare icon
-       }
-
-#ifdef NIF_STATE       // as of 21.08.2003 missing in MinGW headers
-       if (pnid->uFlags & NIF_STATE) {
-               DWORD new_state = (_dwState&~pnid->dwStateMask) | (pnid->dwState&pnid->dwStateMask);
-
-               if (_dwState != new_state) {
-                       _dwState = new_state;
-                       changes = true;
-               }
-       }
-#endif
-
-        // store tool tip text
-       if (pnid->uFlags & NIF_TIP) {
-               String new_text;
-
-               if (pnid->cbSize==NID_SIZE_W6 || pnid->cbSize==NID_SIZE_W5 || pnid->cbSize==NID_SIZE_W3) {
-                        // UNICODE version of NOTIFYICONDATA structure
-                       LPCWSTR txt = (LPCWSTR)pnid->szTip;
-                       int max_len = pnid->cbSize==NID_SIZE_W3? 64: 128;
-
-                        // get tooltip string length
-                       int l = 0;
-                       for(; l<max_len; ++l)
-                               if (!txt[l])
-                                       break;
-
-                       new_text.assign(txt, l);
-
-                       if (new_text != _tipText) {
-                               _tipText = new_text;
-                               changes = true;
-                       }
-               } else if (pnid->cbSize==NID_SIZE_A6 || pnid->cbSize==NID_SIZE_A5 || pnid->cbSize==NID_SIZE_A3) {
-                       LPCSTR txt = (LPCSTR)pnid->szTip;
-                       int max_len = pnid->cbSize==NID_SIZE_A3? 64: 128;
-
-                       int l = 0;
-                       for(int l=0; l<max_len; ++l)
-                               if (!txt[l])
-                                       break;
-
-                       new_text.assign(txt, l);
-
-                       if (new_text != _tipText) {
-                               _tipText = new_text;
-                               changes = true;
-                       }
-               }
-       }
-
-       TCHAR title[MAX_PATH];
-
-       DWORD pid;
-       GetWindowThreadProcessId(_hWnd, &pid);
-
-        // avoid to send WM_GETTEXT messages to the own process
-       if (pid != GetCurrentProcessId())
-               if (GetWindowText(_hWnd, title, COUNTOF(title))) {
-                       if (_windowTitle != title) {
-                               _windowTitle = title;
-                               changes = true;
-                       }
-               }
-
-       if (changes) {
-               create_name();
-               _lastChange = GetTickCount();
-       }
-
-       return changes;
-}
-
-
-NotifyArea::NotifyArea(HWND hwnd)
- :     super(hwnd),
-       _tooltip(hwnd)
-{
-       _next_idx = 0;
-       _clock_width = 0;
-       _last_icon_count = 0;
-       _show_hidden = false;
-       _hide_inactive = true;
-       _show_button = true;
-}
-
-NotifyArea::~NotifyArea()
-{
-       KillTimer(_hwnd, 0);
-
-       write_config();
-}
-
-static bool get_hide_clock_from_registry()
-{
-       HKEY hkeyStuckRects = 0;
-       DWORD buffer[10];
-       DWORD len = sizeof(buffer);
-
-       bool hide_clock = false;
-
-        // check if the clock should be hidden
-       if (!RegOpenKey(HKEY_CURRENT_USER, TEXT("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Explorer\\StuckRects2"), &hkeyStuckRects) &&
-               !RegQueryValueEx(hkeyStuckRects, TEXT("Settings"), 0, NULL, (LPBYTE)buffer, &len) &&
-               len==sizeof(buffer) && buffer[0]==sizeof(buffer))
-               hide_clock = buffer[2] & 0x08? true: false;
-
-       if (hkeyStuckRects)
-               RegCloseKey(hkeyStuckRects);
-
-       return hide_clock;
-}
-
-void NotifyArea::read_config()
-{
-       bool clock_visible = true;
-
-        // read notification icon settings from XML configuration
-       XMLPos cfg_pos = g_Globals.get_cfg();
-
-#ifndef __MINGW32__    // SHRestricted() missing in MinGW (as of 29.10.2003)
-       if (!g_Globals._SHRestricted || !SHRestricted(REST_HIDECLOCK))
-#endif
-       {
-               if (cfg_pos.go_down("desktopbar")) {
-                       clock_visible = XMLBoolRef(XMLPos(cfg_pos,"options"), "show-clock", !get_hide_clock_from_registry());
-                       cfg_pos.back();
-               }
-       }
-
-       if (cfg_pos.go_down("notify-icons")) {
-               XMLPos options(cfg_pos, "options");
-
-               _hide_inactive = XMLBool(options, "hide-inactive", true);       ///@todo read default setting from registry
-               _show_hidden = XMLBool(options, "show-hidden", false);  ///@todo read default setting from registry
-               _show_button = XMLBool(options, "show-button", true);
-
-               XMLChildrenFilter icons(cfg_pos, "icon");
-
-               for(XMLChildrenFilter::iterator it=icons.begin(); it!=icons.end(); ++it) {
-                       const XMLNode& node = **it;
-
-                       NotifyIconConfig cfg;
-
-                       cfg._name = node.get("name").c_str();
-                       cfg._tipText = node.get("text").c_str();
-                       cfg._windowTitle = node.get("window").c_str();
-                       cfg._modulePath = node.get("module").c_str();
-                       const string& mode = node.get("show");
-
-                       if (mode == "show")
-                               cfg._mode = NIM_SHOW;
-                       else if (mode == "hide")
-                               cfg._mode = NIM_HIDE;
-                       else //if (mode == "auto")
-                               cfg._mode = NIM_HIDE;
-
-                       _cfg.push_back(cfg);
-               }
-
-               cfg_pos.back();
-       }
-
-       show_clock(clock_visible);
-}
-
-void NotifyArea::write_config()
-{
-        // write notification icon settings to XML configuration file
-       XMLPos cfg_pos = g_Globals.get_cfg();
-
-       cfg_pos.smart_create("desktopbar");
-       XMLBoolRef boolRef(XMLPos(cfg_pos,"options"), "show-clock");
-    boolRef = _hwndClock!=0;
-       cfg_pos.back();
-
-       cfg_pos.smart_create("notify-icons");
-
-       XMLPos options(cfg_pos, "options");
-       XMLBoolRef(options, "hide-inactive") = _hide_inactive;
-       XMLBoolRef(options, "show-hidden") = _show_hidden;
-       XMLBoolRef(options, "show-button") = _show_button;
-
-       for(NotifyIconCfgList::iterator it=_cfg.begin(); it!=_cfg.end(); ++it) {
-               NotifyIconConfig& cfg = *it;
-
-                // search for the corresponding node using the original name
-               cfg_pos.smart_create("icon", "name", cfg._name);
-
-                // refresh unique name
-               cfg.create_name();
-
-               cfg_pos["name"] = cfg._name.c_str();
-               cfg_pos["text"] = cfg._tipText.c_str();
-               cfg_pos["window"] = cfg._windowTitle.c_str();
-               cfg_pos["module"] = cfg._modulePath.c_str();
-               cfg_pos["show"] = string_from_mode(cfg._mode).c_str();
-
-               cfg_pos.back();
-       }
-
-       cfg_pos.back(); // smart_create
-}
-
-void NotifyArea::show_clock(bool flag)
-{
-       bool vis = _hwndClock!=0;
-
-       if (vis != flag) {
-               if (flag) {
-                        // create clock window
-                       _hwndClock = ClockWindow::Create(_hwnd);
-
-                       if (_hwndClock) {
-                               ClientRect clock_size(_hwndClock);
-                               _clock_width = clock_size.right;
-                       }
-               } else {
-                       DestroyWindow(_hwndClock);
-                       _hwndClock = 0;
-                       _clock_width = 0;
-               }
-
-               SendMessage(GetParent(_hwnd), PM_RESIZE_CHILDREN, 0, 0);
-       }
-}
-
-LRESULT NotifyArea::Init(LPCREATESTRUCT pcs)
-{
-       if (super::Init(pcs))
-               return 1;
-
-       read_config();
-
-       SetTimer(_hwnd, 0, 1000, NULL);
-
-       return 0;
-}
-
-HWND NotifyArea::Create(HWND hwndParent)
-{
-       static BtnWindowClass wcTrayNotify(CLASSNAME_TRAYNOTIFY, CS_DBLCLKS);
-
-       ClientRect clnt(hwndParent);
-
-       return Window::Create(WINDOW_CREATOR(NotifyArea), WS_EX_STATICEDGE,
-                                                       wcTrayNotify, TITLE_TRAYNOTIFY, WS_CHILD|WS_VISIBLE|WS_CLIPCHILDREN,
-                                                       clnt.right-(NOTIFYAREA_WIDTH_DEF+1), 1, NOTIFYAREA_WIDTH_DEF, clnt.bottom-2, hwndParent);
-}
-
-LRESULT NotifyArea::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_PAINT:
-               Paint();
-               break;
-
-         case WM_TIMER: {
-               Refresh();
-
-               ClockWindow* clock_window = GET_WINDOW(ClockWindow, _hwndClock);
-
-               if (clock_window)
-                       clock_window->TimerTick();
-               break;}
-
-         case PM_REFRESH:
-               Refresh(true);
-               break;
-
-         case WM_SIZE: {
-               int cx = LOWORD(lparam);
-               SetWindowPos(_hwndClock, 0, cx-_clock_width, 0, 0, 0, SWP_NOSIZE|SWP_NOZORDER|SWP_NOACTIVATE);
-               break;}
-
-         case PM_GET_WIDTH: {
-               int w = _sorted_icons.size()*NOTIFYICON_DIST + NOTIFYAREA_SPACE + _clock_width;
-               if (_show_button)
-                       w += NOTIFYICON_DIST;
-               return w;}
-
-         case PM_REFRESH_CONFIG:
-               read_config();
-               break;
-
-         case WM_CONTEXTMENU: {
-               Point pt(lparam);
-               ScreenToClient(_hwnd, &pt);
-
-               if (IconHitTest(pt) == _sorted_icons.end()) { // display menu only when no icon clicked
-                       PopupMenu menu(IDM_NOTIFYAREA);
-                       SetMenuDefaultItem(menu, 0, MF_BYPOSITION);
-                       CheckMenuItem(menu, ID_SHOW_HIDDEN_ICONS, MF_BYCOMMAND|(_show_hidden?MF_CHECKED:MF_UNCHECKED));
-                       CheckMenuItem(menu, ID_SHOW_ICON_BUTTON, MF_BYCOMMAND|(_show_button?MF_CHECKED:MF_UNCHECKED));
-                       menu.TrackPopupMenu(_hwnd, MAKEPOINTS(lparam));
-               }
-               break;}
-
-         case WM_COPYDATA: {   // receive NotifyHook answers
-               String path;
-               HWND hwnd;
-
-               if (_hook.ModulePathCopyData(lparam, &hwnd, path))
-                       _window_modules[hwnd] = path;
-               break;}
-
-         default:
-               if (nmsg>=WM_MOUSEFIRST && nmsg<=WM_MOUSELAST) {
-                        // close startup menu and other popup menus
-                        // This functionality is missing in MS Windows.
-                       if (nmsg==WM_LBUTTONDOWN || nmsg==WM_MBUTTONDOWN || nmsg==WM_RBUTTONDOWN
-#ifdef WM_XBUTTONDOWN
-                               || nmsg==WM_XBUTTONDOWN
-#endif
-                               )
-
-                               CancelModes();
-
-                       Point pt(lparam);
-                       NotifyIconSet::const_iterator found = IconHitTest(pt);
-
-                       if (found != _sorted_icons.end()) {
-                               const NotifyInfo& entry = const_cast<NotifyInfo&>(*found);      // Why does GCC 3.3 need this additional const_cast ?!
-
-                                // set activation time stamp
-                               if (nmsg == WM_LBUTTONDOWN ||   // Some programs need PostMessage() instead of SendMessage().
-                                       nmsg == WM_MBUTTONDOWN ||       // So call SendMessage() only for BUTTONUP and BLCLK messages
-#ifdef WM_XBUTTONDOWN
-                                       nmsg == WM_XBUTTONDOWN ||
-#endif
-                                       nmsg == WM_RBUTTONDOWN) {
-                                       _icon_map[entry]._lastChange = GetTickCount();
-                               }
-
-                                // Notify the message if the owner is still alive
-                               if (IsWindow(entry._hWnd)) {
-                                       if (nmsg == WM_MOUSEMOVE ||             // avoid to call blocking SendMessage() for merely moving the mouse over icons
-                                               nmsg == WM_LBUTTONDOWN ||       // Some programs need PostMessage() instead of SendMessage().
-                                               nmsg == WM_MBUTTONDOWN ||       // So call SendMessage() only for BUTTONUP and BLCLK messages
-#ifdef WM_XBUTTONDOWN
-                                               nmsg == WM_XBUTTONDOWN ||
-#endif
-                                               nmsg == WM_RBUTTONDOWN)
-                                               PostMessage(entry._hWnd, entry._uCallbackMessage, entry._uID, nmsg);
-                                       else {
-                                                // allow SetForegroundWindow() in client process
-                                               DWORD pid;
-
-                                               if (GetWindowThreadProcessId(entry._hWnd, &pid)) {
-                                                        // bind dynamically to AllowSetForegroundWindow() to be compatible to WIN98
-                                                       static DynamicFct<BOOL(WINAPI*)(DWORD)> AllowSetForegroundWindow(TEXT("USER32"), "AllowSetForegroundWindow");
-
-                                                       if (AllowSetForegroundWindow)
-                                                               (*AllowSetForegroundWindow)(pid);
-                                               }
-
-                                                // use PostMessage() for notifcation icons of Shell Service Objects in the own process
-                                               if (pid == GetCurrentProcessId())
-                                                       PostMessage(entry._hWnd, entry._uCallbackMessage, entry._uID, nmsg);
-                                               else
-                                                       SendMessage(entry._hWnd, entry._uCallbackMessage, entry._uID, nmsg);
-                                       }
-                               }
-                               else if (_icon_map.erase(entry))        // delete icons without valid owner window
-                                       UpdateIcons();
-                       } else
-                                // handle clicks on notification area button "show hidden icons"
-                               if (_show_button)
-                                       if (nmsg == WM_LBUTTONDOWN)
-                                               if (pt.x>=NOTIFYICON_X && pt.x<NOTIFYICON_X+NOTIFYICON_SIZE &&
-                                                       pt.y>=NOTIFYICON_Y && pt.y<NOTIFYICON_Y+NOTIFYICON_SIZE)
-                                                       PostMessage(_hwnd, WM_COMMAND, MAKEWPARAM(ID_SHOW_HIDDEN_ICONS,0), 0);
-               }
-
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-int NotifyArea::Command(int id, int code)
-{
-       switch(id) {
-         case ID_SHOW_HIDDEN_ICONS:
-               _show_hidden = !_show_hidden;
-               UpdateIcons();
-               break;
-
-         case ID_SHOW_ICON_BUTTON:
-               _show_button = !_show_button;
-               UpdateIcons();
-               break;
-
-         case ID_CONFIG_NOTIFYAREA:
-               Dialog::DoModal(IDD_NOTIFYAREA, WINDOW_CREATOR(TrayNotifyDlg), GetParent(_hwnd));
-               break;
-
-         case ID_CONFIG_TIME:
-               launch_cpanel(_hwnd, TEXT("timedate.cpl"));
-               break;
-
-         default:
-               SendParent(WM_COMMAND, MAKELONG(id,code), 0);
-       }
-
-       return 0;
-}
-
-int NotifyArea::Notify(int id, NMHDR* pnmh)
-{
-       if (pnmh->code == TTN_GETDISPINFO) {
-               LPNMTTDISPINFO pdi = (LPNMTTDISPINFO)pnmh;
-
-               Point pt(GetMessagePos());
-               ScreenToClient(_hwnd, &pt);
-
-               if (_show_button &&
-                       pt.x>=NOTIFYICON_X && pt.x<NOTIFYICON_X+NOTIFYICON_SIZE &&
-                       pt.y>=NOTIFYICON_Y && pt.y<NOTIFYICON_Y+NOTIFYICON_SIZE)
-               {
-                       static ResString sShowIcons(IDS_SHOW_HIDDEN_ICONS);
-                       static ResString sHideIcons(IDS_HIDE_ICONS);
-
-                       pdi->lpszText = (_show_hidden? sHideIcons: sShowIcons).str();
-               } else {
-                       NotifyIconSet::iterator found = IconHitTest(pt);
-
-                       if (found != _sorted_icons.end()) {
-                               NotifyInfo& entry = const_cast<NotifyInfo&>(*found);    // Why does GCC 3.3 need this additional const_cast ?!
-
-                                // enable multiline tooltips (break at CR/LF and for very long one-line strings)
-                               SendMessage(pnmh->hwndFrom, TTM_SETMAXTIPWIDTH, 0, 400);
-
-                               pdi->lpszText = entry._tipText.str();
-                       }
-               }
-       }
-
-       return 0;
-}
-
-void NotifyArea::CancelModes()
-{
-       PostMessage(HWND_BROADCAST, WM_CANCELMODE, 0, 0);
-
-       for(NotifyIconSet::const_iterator it=_sorted_icons.begin(); it!=_sorted_icons.end(); ++it)
-               PostMessage(it->_hWnd, WM_CANCELMODE, 0, 0);
-}
-
-LRESULT NotifyArea::ProcessTrayNotification(int notify_code, NOTIFYICONDATA* pnid)
-{
-       switch(notify_code) {
-         case NIM_ADD:
-         case NIM_MODIFY:
-               if ((int)pnid->uID >= 0) {      ///@todo This is a fix for Windows Task Manager.
-                       NotifyInfo& entry = _icon_map[pnid];
-
-                        // a new entry?
-                       if (entry._idx == -1)
-                               entry._idx = ++_next_idx;
-               /* equivalent code using iterator::find();
-                       NotifyIconMap::iterator found = _icon_map.find(pnid);
-                       NotifyInfo* pentry;
-                        // a new entry?
-                       if (found == _icon_map.end()) {
-                               pentry = &_icon_map[pnid];
-                               pentry->_idx = ++_next_idx;
-                       } else {
-                               pentry = &found->second;
-                       }
-                       NotifyInfo& entry = *pentry;
-               */
-                       bool changes = entry.modify(pnid);
-
-#if NOTIFYICON_VERSION>=3      // as of 21.08.2003 missing in MinGW headers
-                       if (DetermineHideState(entry) && entry._mode==NIM_HIDE) {
-                               entry._dwState |= NIS_HIDDEN;
-                               changes = true;
-                       }
-#endif
-
-                       if (changes)
-                               UpdateIcons();  ///@todo call only if really changes occurred
-
-                       return TRUE;
-               }
-               break;
-
-         case NIM_DELETE: {
-               NotifyIconMap::iterator found = _icon_map.find(pnid);
-
-               if (found != _icon_map.end()) {
-                       if (found->second._hIcon)
-                               DestroyIcon(found->second._hIcon);
-                       _icon_map.erase(found);
-                       UpdateIcons();
-                       return TRUE;
-               }
-               break;}
-
-#if NOTIFYICON_VERSION>=3      // as of 21.08.2003 missing in MinGW headers
-         case NIM_SETFOCUS:
-               SetForegroundWindow(_hwnd);
-               return TRUE;
-
-         case NIM_SETVERSION:
-               NotifyIconMap::iterator found = _icon_map.find(pnid);
-
-               if (found != _icon_map.end()) {
-                       found->second._version = pnid->UNION_MEMBER(uVersion);
-                       return TRUE;
-               } else
-                       return FALSE;
-#endif
-       }
-
-       return FALSE;
-}
-
-void NotifyArea::UpdateIcons()
-{
-       _sorted_icons.clear();
-
-        // sort icon infos by display index
-       for(NotifyIconMap::const_iterator it=_icon_map.begin(); it!=_icon_map.end(); ++it) {
-               const NotifyInfo& entry = it->second;
-
-#ifdef NIF_STATE       // as of 21.08.2003 missing in MinGW headers
-               if (_show_hidden || !(entry._dwState & NIS_HIDDEN))
-#endif
-                       _sorted_icons.insert(entry);
-       }
-
-        // sync tooltip areas to current icon number
-       if (_sorted_icons.size() != _last_icon_count) {
-               RECT rect = {NOTIFYICON_X, NOTIFYICON_Y, NOTIFYICON_X+NOTIFYICON_SIZE, NOTIFYICON_Y+NOTIFYICON_SIZE};
-
-               size_t tt_idx = 0;
-
-               if (_show_button) {
-                       _tooltip.add(_hwnd, tt_idx++, rect);
-
-                       rect.left += NOTIFYICON_DIST;
-                       rect.right += NOTIFYICON_DIST;
-               }
-
-               size_t icon_cnt = _sorted_icons.size();
-               while(tt_idx < icon_cnt) {
-                       _tooltip.add(_hwnd, tt_idx++, rect);
-
-                       rect.left += NOTIFYICON_DIST;
-                       rect.right += NOTIFYICON_DIST;
-               }
-
-               while(tt_idx < _last_icon_count)
-                       _tooltip.remove(_hwnd, tt_idx++);
-
-               _last_icon_count = _sorted_icons.size();
-       }
-
-       SendMessage(GetParent(_hwnd), PM_RESIZE_CHILDREN, 0, 0);
-
-       InvalidateRect(_hwnd, NULL, FALSE);     // refresh icon display
-       UpdateWindow(_hwnd);
-}
-
-#ifndef _NO_ALPHABLEND
-#ifdef _MSC_VER
-#pragma comment(lib, "msimg32")        // for AlphaBlend()
-#endif
-#endif
-
-void NotifyArea::Paint()
-{
-       BufferedPaintCanvas canvas(_hwnd);
-
-        // first fill with the background color
-       FillRect(canvas, &canvas.rcPaint, GetSysColorBrush(COLOR_BTNFACE));
-
-        // draw icons
-       int x = NOTIFYICON_X;
-       int y = NOTIFYICON_Y;
-
-       if (_show_button) {
-               static SmallIcon leftArrowIcon(IDI_NOTIFY_L);
-               static SmallIcon rightArrowIcon(IDI_NOTIFY_R);
-
-               DrawIconEx(canvas, x, y, _show_hidden?rightArrowIcon:leftArrowIcon, NOTIFYICON_SIZE, NOTIFYICON_SIZE, 0, 0, DI_NORMAL);
-               x += NOTIFYICON_DIST;
-       }
-
-#ifndef _NO_ALPHABLEND
-       MemCanvas mem_dc;
-       SelectedBitmap bmp(mem_dc, CreateCompatibleBitmap(canvas, NOTIFYICON_SIZE, NOTIFYICON_SIZE));
-       RECT rect = {0, 0, NOTIFYICON_SIZE, NOTIFYICON_SIZE};
-       BLENDFUNCTION blend = {AC_SRC_OVER, 0, 128, 0}; // 50 % visible
-#endif
-
-       for(NotifyIconSet::const_iterator it=_sorted_icons.begin(); it!=_sorted_icons.end(); ++it) {
-#ifndef _NO_ALPHABLEND
-               if (it->_dwState & NIS_HIDDEN) {
-                       FillRect(mem_dc, &rect, GetSysColorBrush(COLOR_BTNFACE));
-                       DrawIconEx(mem_dc, 0, 0, it->_hIcon, NOTIFYICON_SIZE, NOTIFYICON_SIZE, 0, 0, DI_NORMAL);
-                       AlphaBlend(canvas, x, y, NOTIFYICON_SIZE, NOTIFYICON_SIZE, mem_dc, 0, 0, NOTIFYICON_SIZE, NOTIFYICON_SIZE, blend);
-               } else
-#endif
-                       DrawIconEx(canvas, x, y, it->_hIcon, NOTIFYICON_SIZE, NOTIFYICON_SIZE, 0, 0, DI_NORMAL);
-
-               x += NOTIFYICON_DIST;
-       }
-}
-
-void NotifyArea::Refresh(bool update)
-{
-        // Look for task icons without valid owner window.
-        // This is an extended feature missing in MS Windows.
-       for(NotifyIconSet::const_iterator it=_sorted_icons.begin(); it!=_sorted_icons.end(); ++it) {
-               const NotifyInfo& entry = *it;
-
-               if (!IsWindow(entry._hWnd))
-                       if (_icon_map.erase(entry))     // delete icons without valid owner window
-                               ++update;
-       }
-
-       DWORD now = GetTickCount();
-
-        // handle icon hiding
-       for(NotifyIconMap::iterator it=_icon_map.begin(); it!=_icon_map.end(); ++it) {
-               NotifyInfo& entry = it->second;
-
-               DetermineHideState(entry);
-
-               switch(entry._mode) {
-                 case NIM_HIDE:
-                       if (!(entry._dwState & NIS_HIDDEN)) {
-                               entry._dwState |= NIS_HIDDEN;
-                               ++update;
-                       }
-                       break;
-
-                 case NIM_SHOW:
-                       if (entry._dwState&NIS_HIDDEN) {
-                               entry._dwState &= ~NIS_HIDDEN;
-                               ++update;
-                       }
-                       break;
-
-                 case NIM_AUTO:
-                        // automatically hide icons after long periods of inactivity
-                       if (_hide_inactive)
-                               if (!(entry._dwState & NIS_HIDDEN))
-                                       if (now-entry._lastChange > ICON_AUTOHIDE_SECONDS*1000) {
-                                               entry._dwState |= NIS_HIDDEN;
-                                               ++update;
-                                       }
-                       break;
-               }
-       }
-
-       if (update)
-               UpdateIcons();
-}
-
- /// search for a icon at a given client coordinate position
-NotifyIconSet::iterator NotifyArea::IconHitTest(const POINT& pos)
-{
-       if (pos.y<NOTIFYICON_Y || pos.y>=NOTIFYICON_Y+NOTIFYICON_SIZE)
-               return _sorted_icons.end();
-
-       NotifyIconSet::iterator it = _sorted_icons.begin();
-
-       int x = NOTIFYICON_X;
-
-       if (_show_button)
-               x += NOTIFYICON_DIST;
-
-       for(; it!=_sorted_icons.end(); ++it) {
-               //NotifyInfo& entry = const_cast<NotifyInfo&>(*it);     // Why does GCC 3.3 need this additional const_cast ?!
-
-               if (pos.x>=x && pos.x<x+NOTIFYICON_SIZE)
-                       break;
-
-               x += NOTIFYICON_DIST;
-       }
-
-       return it;
-}
-
-
-void NotifyIconConfig::create_name()
-{
-       _name = FmtString(TEXT("'%s' - '%s' - '%s'"), _tipText.c_str(), _windowTitle.c_str(), _modulePath.c_str());
-}
-
-
-#if NOTIFYICON_VERSION>=3      // as of 21.08.2003 missing in MinGW headers
-
-bool NotifyIconConfig::match(const NotifyIconConfig& props) const
-{
-       if (!_tipText.empty() && !props._tipText.empty())
-               if (props._tipText == _tipText)
-                       return true;
-
-       if (!_windowTitle.empty() && !props._windowTitle.empty())
-               if (_tcsstr(props._windowTitle, _windowTitle))
-                       return true;
-
-       if (!_modulePath.empty() && !props._modulePath.empty())
-               if (!_tcsicmp(props._modulePath, _modulePath))
-                       return true;
-
-       return false;
-}
-
-bool NotifyArea::DetermineHideState(NotifyInfo& entry)
-{
-       if (entry._modulePath.empty()) {
-               const String& modulePath = _window_modules[entry._hWnd];
-
-                // request module path for new windows (We will get an asynchronous answer by a WM_COPYDATA message.)
-               if (!modulePath.empty())
-                       entry._modulePath = modulePath;
-               else
-                       _hook.GetModulePath(entry._hWnd, _hwnd);
-       }
-
-       for(NotifyIconCfgList::const_iterator it=_cfg.begin(); it!=_cfg.end(); ++it) {
-               const NotifyIconConfig& cfg = *it;
-
-               if (cfg.match(entry)) {
-                       entry._mode = cfg._mode;
-                       return true;
-               }
-       }
-
-       return false;
-}
-
-#endif
-
-
-String string_from_mode(NOTIFYICONMODE mode)
-{
-       switch(mode) {
-         case NIM_SHOW:
-               return ResString(IDS_NOTIFY_SHOW);
-
-         case NIM_HIDE:
-               return ResString(IDS_NOTIFY_HIDE);
-
-         default:      //case NIM_AUTO
-               return ResString(IDS_NOTIFY_AUTOHIDE);
-       }
-}
-
-
-TrayNotifyDlg::TrayNotifyDlg(HWND hwnd)
- :     super(hwnd),
-       _tree_ctrl(GetDlgItem(hwnd, IDC_NOTIFY_ICONS)),
-       _himl(ImageList_Create(GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), ILC_COLOR24, 3, 0)),
-       _pNotifyArea(static_cast<NotifyArea*>(Window::get_window((HWND)SendMessage(g_Globals._hwndDesktopBar, PM_GET_NOTIFYAREA, 0, 0))))
-{
-       _selectedItem = 0;
-
-       if (_pNotifyArea) {
-                // save original icon states and configuration data
-               for(NotifyIconMap::const_iterator it=_pNotifyArea->_icon_map.begin(); it!=_pNotifyArea->_icon_map.end(); ++it)
-                       _icon_states_org[it->first] = IconStatePair(it->second._mode, it->second._dwState);
-
-               _cfg_org = _pNotifyArea->_cfg;
-               _show_hidden_org = _pNotifyArea->_show_hidden;
-       }
-
-       SetWindowIcon(hwnd, IDI_REACTOS);
-
-       _haccel = LoadAccelerators(g_Globals._hInstance, MAKEINTRESOURCE(IDA_TRAYNOTIFY));
-
-       {
-       WindowCanvas canvas(_hwnd);
-       HBRUSH hbkgnd = GetStockBrush(WHITE_BRUSH);
-
-       ImageList_AddAlphaIcon(_himl, SmallIcon(IDI_DOT), hbkgnd, canvas);
-       ImageList_AddAlphaIcon(_himl, SmallIcon(IDI_DOT_TRANS), hbkgnd, canvas);
-       ImageList_AddAlphaIcon(_himl, SmallIcon(IDI_DOT_RED), hbkgnd, canvas);
-       }
-
-       (void)TreeView_SetImageList(_tree_ctrl, _himl, TVSIL_NORMAL);
-
-       _resize_mgr.Add(IDC_NOTIFY_ICONS,       RESIZE);
-       _resize_mgr.Add(IDC_LABEL1,                     MOVE_Y);
-       _resize_mgr.Add(IDC_NOTIFY_TOOLTIP,     RESIZE_X|MOVE_Y);
-       _resize_mgr.Add(IDC_LABEL2,                     MOVE_Y);
-       _resize_mgr.Add(IDC_NOTIFY_TITLE,       RESIZE_X|MOVE_Y);
-       _resize_mgr.Add(IDC_LABEL3,                     MOVE_Y);
-       _resize_mgr.Add(IDC_NOTIFY_MODULE,      RESIZE_X|MOVE_Y);
-
-       _resize_mgr.Add(IDC_LABEL4,                     MOVE_Y);
-       _resize_mgr.Add(IDC_NOTIFY_SHOW,        MOVE_Y);
-       _resize_mgr.Add(IDC_NOTIFY_HIDE,        MOVE_Y);
-       _resize_mgr.Add(IDC_NOTIFY_AUTOHIDE,MOVE_Y);
-
-       _resize_mgr.Add(IDC_PICTURE,            MOVE);
-       _resize_mgr.Add(ID_SHOW_HIDDEN_ICONS,MOVE_Y);
-
-       _resize_mgr.Add(IDC_LABEL6,                     MOVE_Y);
-       _resize_mgr.Add(IDC_LAST_CHANGE,        MOVE_Y);
-
-       _resize_mgr.Add(IDOK,                           MOVE);
-       _resize_mgr.Add(IDCANCEL,                       MOVE);
-
-       _resize_mgr.Resize(+150, +200);
-
-       Refresh();
-
-       SetTimer(_hwnd, 0, 3000, NULL);
-       register_pretranslate(hwnd);
-}
-
-TrayNotifyDlg::~TrayNotifyDlg()
-{
-       KillTimer(_hwnd, 0);
-       unregister_pretranslate(_hwnd);
-       ImageList_Destroy(_himl);
-}
-
-void TrayNotifyDlg::Refresh()
-{
-       ///@todo refresh incrementally
-
-       HiddenWindow hide(_tree_ctrl);
-
-       TreeView_DeleteAllItems(_tree_ctrl);
-
-       TV_INSERTSTRUCT tvi;
-
-       tvi.hParent = 0;
-       tvi.hInsertAfter = TVI_LAST;
-
-       TV_ITEM& tv = tvi.item;
-       tv.mask = TVIF_TEXT|TVIF_IMAGE|TVIF_SELECTEDIMAGE;
-
-       ResString str_cur(IDS_ITEMS_CUR);
-       tv.pszText = str_cur.str();
-       tv.iSelectedImage = tv.iImage = 0;      // IDI_DOT
-       _hitemCurrent = TreeView_InsertItem(_tree_ctrl, &tvi);
-
-       ResString str_conf(IDS_ITEMS_CONFIGURED);
-       tv.pszText = str_conf.str();
-       tv.iSelectedImage = tv.iImage = 2;      // IDI_DOT_RED
-       _hitemConfig = TreeView_InsertItem(_tree_ctrl, &tvi);
-
-       tvi.hParent = _hitemCurrent;
-
-       ResString str_visible(IDS_ITEMS_VISIBLE);
-       tv.pszText = str_visible.str();
-       tv.iSelectedImage = tv.iImage = 0;      // IDI_DOT
-       _hitemCurrent_visible = TreeView_InsertItem(_tree_ctrl, &tvi);
-
-       ResString str_hidden(IDS_ITEMS_HIDDEN);
-       tv.pszText = str_hidden.str();
-       tv.iSelectedImage = tv.iImage = 1;      // IDI_DOT_TRANS
-       _hitemCurrent_hidden = TreeView_InsertItem(_tree_ctrl, &tvi);
-
-       if (_pNotifyArea) {
-               _info.clear();
-
-               tv.mask |= TVIF_PARAM;
-
-               WindowCanvas canvas(_hwnd);
-
-                // insert current (visible and hidden) items
-               for(NotifyIconMap::const_iterator it=_pNotifyArea->_icon_map.begin(); it!=_pNotifyArea->_icon_map.end(); ++it) {
-                       const NotifyInfo& entry = it->second;
-
-                       InsertItem(entry._dwState&NIS_HIDDEN? _hitemCurrent_hidden: _hitemCurrent_visible, TVI_LAST, entry, canvas);
-               }
-
-                // insert configured items in tree view
-               const NotifyIconCfgList& cfg = _pNotifyArea->_cfg;
-               for(NotifyIconCfgList::const_iterator it=cfg.begin(); it!=cfg.end(); ++it) {
-                       const NotifyIconConfig& cfg_entry = *it;
-
-                       HICON hicon = 0;
-
-                       if (!cfg_entry._modulePath.empty()) {
-                               if ((int)ExtractIconEx(cfg_entry._modulePath, 0, NULL, &hicon, 1) <= 0)
-                                       hicon = 0;
-
-                               if (!hicon) {
-                                       SHFILEINFO sfi;
-
-                                       if (SHGetFileInfo(cfg_entry._modulePath, 0, &sfi, sizeof(sfi), SHGFI_ICON|SHGFI_SMALLICON))
-                                               hicon = sfi.hIcon;
-                               }
-                       }
-
-                       InsertItem(_hitemConfig, TVI_SORT, cfg_entry, canvas, hicon, cfg_entry._mode);
-
-                       if (hicon)
-                               DestroyIcon(hicon);
-               }
-
-               CheckDlgButton(_hwnd, ID_SHOW_HIDDEN_ICONS, _pNotifyArea->_show_hidden? BST_CHECKED: BST_UNCHECKED);
-       }
-
-       TreeView_Expand(_tree_ctrl, _hitemCurrent_visible, TVE_EXPAND);
-       TreeView_Expand(_tree_ctrl, _hitemCurrent_hidden, TVE_EXPAND);
-       TreeView_Expand(_tree_ctrl, _hitemCurrent, TVE_EXPAND);
-       TreeView_Expand(_tree_ctrl, _hitemConfig, TVE_EXPAND);
-
-       TreeView_EnsureVisible(_tree_ctrl, _hitemCurrent_visible);
-}
-
-void TrayNotifyDlg::InsertItem(HTREEITEM hparent, HTREEITEM after, const NotifyInfo& entry, HDC hdc)
-{
-       InsertItem(hparent, after, entry, hdc, entry._hIcon, entry._mode);
-}
-
-void TrayNotifyDlg::InsertItem(HTREEITEM hparent, HTREEITEM after, const NotifyIconDlgInfo& entry,
-                                                               HDC hdc, HICON hicon, NOTIFYICONMODE mode)
-{
-       int idx = _info.size() + 1;
-       _info[idx] = entry;
-
-       String mode_str = string_from_mode(mode);
-
-       switch(mode) {
-         case NIM_SHOW:        mode_str = ResString(IDS_NOTIFY_SHOW);          break;
-         case NIM_HIDE:        mode_str = ResString(IDS_NOTIFY_HIDE);          break;
-         case NIM_AUTO:        mode_str = ResString(IDS_NOTIFY_AUTOHIDE);
-       }
-
-       FmtString txt(TEXT("%s  -  %s  [%s]"), entry._tipText.c_str(), entry._windowTitle.c_str(), mode_str.c_str());
-
-       TV_INSERTSTRUCT tvi;
-
-       tvi.hParent = hparent;
-       tvi.hInsertAfter = after;
-
-       TV_ITEM& tv = tvi.item;
-       tv.mask = TVIF_TEXT|TVIF_IMAGE|TVIF_SELECTEDIMAGE|TVIF_PARAM;
-
-       tv.lParam = (LPARAM)idx;
-       tv.pszText = txt.str();
-       tv.iSelectedImage = tv.iImage = ImageList_AddAlphaIcon(_himl, hicon, GetStockBrush(WHITE_BRUSH), hdc);
-       (void)TreeView_InsertItem(_tree_ctrl, &tvi);
-}
-
-LRESULT TrayNotifyDlg::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case PM_TRANSLATE_MSG: {
-               MSG* pmsg = (MSG*) lparam;
-
-               if (TranslateAccelerator(_hwnd, _haccel, pmsg))
-                       return TRUE;
-
-               return FALSE;}
-
-         case WM_TIMER:
-               Refresh();
-               break;
-
-         default:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-int TrayNotifyDlg::Command(int id, int code)
-{
-       if (code == BN_CLICKED) {
-               switch(id) {
-                 case ID_REFRESH:
-                       Refresh();
-                       break;
-
-                 case IDC_NOTIFY_SHOW:
-                       SetIconMode(NIM_SHOW);
-                       break;
-
-                 case IDC_NOTIFY_HIDE:
-                       SetIconMode(NIM_HIDE);
-                       break;
-
-                 case IDC_NOTIFY_AUTOHIDE:
-                       SetIconMode(NIM_AUTO);
-                       break;
-
-                 case ID_SHOW_HIDDEN_ICONS:
-                       if (_pNotifyArea)
-                               SendMessage(*_pNotifyArea, WM_COMMAND, MAKEWPARAM(id,code), 0);
-                       break;
-
-                 case IDOK:
-                       EndDialog(_hwnd, id);
-                       break;
-
-                 case IDCANCEL:
-                        // rollback changes
-                       if (_pNotifyArea) {
-                                // restore original icon states and configuration data
-                               _pNotifyArea->_cfg = _cfg_org;
-                               _pNotifyArea->_show_hidden = _show_hidden_org;
-
-                               for(IconStateMap::const_iterator it=_icon_states_org.begin(); it!=_icon_states_org.end(); ++it) {
-                                       NotifyInfo& info = _pNotifyArea->_icon_map[it->first];
-
-                                       info._mode = it->second.first;
-                                       info._dwState = it->second.second;
-                               }
-
-                               SendMessage(*_pNotifyArea, PM_REFRESH, 0, 0);
-                       }
-
-                       EndDialog(_hwnd, id);
-                       break;
-               }
-
-               return 0;
-       }
-
-       return 1;
-}
-
-int TrayNotifyDlg::Notify(int id, NMHDR* pnmh)
-{
-       switch(pnmh->code) {
-         case TVN_SELCHANGED: {
-               NMTREEVIEW* pnmtv = (NMTREEVIEW*)pnmh;
-               int idx = pnmtv->itemNew.lParam;
-
-               if (idx) {
-                       RefreshProperties(_info[idx]);
-                       _selectedItem = pnmtv->itemNew.hItem;
-               } else {
-                       /*
-                       SetDlgItemText(_hwnd, IDC_NOTIFY_TOOLTIP, NULL);
-                       SetDlgItemText(_hwnd, IDC_NOTIFY_TITLE, NULL);
-                       SetDlgItemText(_hwnd, IDC_NOTIFY_MODULE, NULL);
-                       */
-                       CheckRadioButton(_hwnd, IDC_NOTIFY_SHOW, IDC_NOTIFY_AUTOHIDE, 0);
-               }
-               break;}
-       }
-
-       return 0;
-}
-
-void TrayNotifyDlg::RefreshProperties(const NotifyIconDlgInfo& entry)
-{
-       SetDlgItemText(_hwnd, IDC_NOTIFY_TOOLTIP, entry._tipText);
-       SetDlgItemText(_hwnd, IDC_NOTIFY_TITLE, entry._windowTitle);
-       SetDlgItemText(_hwnd, IDC_NOTIFY_MODULE, entry._modulePath);
-
-       CheckRadioButton(_hwnd, IDC_NOTIFY_SHOW, IDC_NOTIFY_AUTOHIDE, IDC_NOTIFY_SHOW+entry._mode);
-
-       String change_str;
-       if (entry._lastChange)
-               change_str.printf(TEXT("before %d s"), (GetTickCount()-entry._lastChange+500)/1000);
-       SetDlgItemText(_hwnd, IDC_LAST_CHANGE, change_str);
-
-       HICON hicon = 0; //get_window_icon_big(entry._hWnd, false);
-
-        // If we could not find an icon associated with the owner window, try to load one from the owning module.
-       if (!hicon && !entry._modulePath.empty()) {
-               hicon = ExtractIcon(g_Globals._hInstance, entry._modulePath, 0);
-
-               if (!hicon) {
-                       SHFILEINFO sfi;
-
-                       if (SHGetFileInfo(entry._modulePath, 0, &sfi, sizeof(sfi), SHGFI_ICON|SHGFI_LARGEICON))
-                               hicon = sfi.hIcon;
-               }
-       }
-
-       if (hicon) {
-               SendMessage(GetDlgItem(_hwnd, IDC_PICTURE), STM_SETICON, (LPARAM)hicon, 0);
-               DestroyIcon(hicon);
-       } else
-               SendMessage(GetDlgItem(_hwnd, IDC_PICTURE), STM_SETICON, 0, 0);
-}
-
-void TrayNotifyDlg::SetIconMode(NOTIFYICONMODE mode)
-{
-       int idx = TreeView_GetItemData(_tree_ctrl, _selectedItem);
-
-       if (!idx)
-               return;
-
-       NotifyIconConfig& entry = _info[idx];
-
-       if (entry._mode != mode) {
-               entry._mode = mode;
-
-                // trigger refresh in notify area and this dialog
-               if (_pNotifyArea)
-                       SendMessage(*_pNotifyArea, PM_REFRESH, 0, 0);
-       }
-
-       if (_pNotifyArea) {
-               bool found = false;
-
-               NotifyIconCfgList& cfg = _pNotifyArea->_cfg;
-               for(NotifyIconCfgList::iterator it=cfg.begin(); it!=cfg.end(); ++it) {
-                       NotifyIconConfig& cfg_entry = *it;
-
-                       if (cfg_entry.match(entry)) {
-                               cfg_entry._mode = mode;
-                               ++found;
-                               break;
-                       }
-               }
-
-               if (!found) {
-                        // insert new configuration entry
-                       NotifyIconConfig cfg_entry = entry;
-
-                       cfg_entry._mode = mode;
-
-                       _pNotifyArea->_cfg.push_back(cfg_entry);
-               }
-       }
-
-       Refresh();
-       ///@todo select treeview item at new position in tree view -> refresh HTREEITEM in _selectedItem
-}
-
-
-ClockWindow::ClockWindow(HWND hwnd)
- :     super(hwnd),
-       _tooltip(hwnd)
-{
-       *_time = TEXT('\0');
-       FormatTime();
-
-       _tooltip.add(_hwnd, _hwnd);
-}
-
-HWND ClockWindow::Create(HWND hwndParent)
-{
-       static BtnWindowClass wcClock(CLASSNAME_CLOCKWINDOW, CS_DBLCLKS);
-
-       ClientRect clnt(hwndParent);
-
-       WindowCanvas canvas(hwndParent);
-       FontSelection font(canvas, GetStockFont(DEFAULT_GUI_FONT));
-
-       RECT rect = {0, 0, 0, 0};
-       TCHAR buffer[8];
-
-       if (!GetTimeFormat(LOCALE_USER_DEFAULT, TIME_NOSECONDS, NULL, NULL, buffer, sizeof(buffer)/sizeof(TCHAR)))
-               _tcscpy(buffer, TEXT("00:00"));
-
-       DrawText(canvas, buffer, -1, &rect, DT_SINGLELINE|DT_NOPREFIX|DT_CALCRECT);
-       int clockwindowWidth = rect.right-rect.left + 4;
-
-       return Window::Create(WINDOW_CREATOR(ClockWindow), 0,
-                                                       wcClock, NULL, WS_CHILD|WS_VISIBLE,
-                                                       clnt.right-(clockwindowWidth), 1, clockwindowWidth, clnt.bottom-2, hwndParent);
-}
-
-LRESULT ClockWindow::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_PAINT:
-               Paint();
-               break;
-
-         case WM_LBUTTONDBLCLK:
-               launch_cpanel(_hwnd, TEXT("timedate.cpl"));
-               break;
-
-         default:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-int ClockWindow::Notify(int id, NMHDR* pnmh)
-{
-       if (pnmh->code == TTN_GETDISPINFO) {
-               LPNMTTDISPINFO pdi = (LPNMTTDISPINFO)pnmh;
-
-               SYSTEMTIME systime;
-               TCHAR buffer[64];
-
-               GetLocalTime(&systime);
-
-               if (GetDateFormat(LOCALE_USER_DEFAULT, DATE_LONGDATE, &systime, NULL, buffer, 64))
-                       _tcscpy(pdi->szText, buffer);
-               else
-                       pdi->szText[0] = '\0';
-       }
-
-       return 0;
-}
-
-void ClockWindow::TimerTick()
-{
-       if (FormatTime())
-               InvalidateRect(_hwnd, NULL, TRUE);      // refresh displayed time
-}
-
-bool ClockWindow::FormatTime()
-{
-       TCHAR buffer[16];
-
-       if (GetTimeFormat(LOCALE_USER_DEFAULT, TIME_NOSECONDS, NULL, NULL, buffer, sizeof(buffer)/sizeof(TCHAR)))
-               if (_tcscmp(buffer, _time)) {
-                       _tcscpy(_time, buffer);
-                       return true;    // The text to display has changed.
-               }
-
-       return false;   // no change
-}
-
-void ClockWindow::Paint()
-{
-       PaintCanvas canvas(_hwnd);
-
-       FillRect(canvas, &canvas.rcPaint, GetSysColorBrush(COLOR_BTNFACE));
-
-       BkMode bkmode(canvas, TRANSPARENT);
-       FontSelection font(canvas, GetStockFont(ANSI_VAR_FONT));
-
-       DrawText(canvas, _time, -1, ClientRect(_hwnd), DT_SINGLELINE|DT_VCENTER|DT_NOPREFIX);
-}
diff --git a/reactos/subsys/system/explorer/taskbar/traynotify.h b/reactos/subsys/system/explorer/taskbar/traynotify.h
deleted file mode 100644 (file)
index 7d90406..0000000
+++ /dev/null
@@ -1,257 +0,0 @@
-/*
- * Copyright 2003, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer and Desktop clone
- //
- // traynotify.h
- //
- // Martin Fuchs, 22.08.2003
- //
-
-
-#define        CLASSNAME_TRAYNOTIFY    TEXT("TrayNotifyWnd")
-#define        TITLE_TRAYNOTIFY                TEXT("")
-
-#define        CLASSNAME_CLOCKWINDOW   TEXT("TrayClockWClass")
-
-#define        NOTIFYAREA_WIDTH_DEF    100
-#define        NOTIFYICON_DIST                 20
-#define        NOTIFYAREA_SPACE                10
-#define        NOTIFYICON_SIZE                 16
-#define        NOTIFYICON_X                    2
-#define        NOTIFYICON_Y                    3
-
-#define        ICON_AUTOHIDE_SECONDS   300
-
-#define        PM_GETMODULEPATH_CB             (WM_APP+0x21)
-#define        PM_GET_NOTIFYAREA               (WM_APP+0x22)
-
-
- /// NotifyIconIndex is used for maintaining the order of notification icons.
-struct NotifyIconIndex
-{
-       NotifyIconIndex(NOTIFYICONDATA* pnid);
-
-        // sort operator
-       friend bool operator<(const NotifyIconIndex& a, const NotifyIconIndex& b)
-               {return a._hWnd<b._hWnd || (a._hWnd==b._hWnd && a._uID<b._uID);}
-
-       HWND    _hWnd;
-       UINT    _uID;
-
-protected:
-       NotifyIconIndex();
-};
-
-
-enum NOTIFYICONMODE {
-       NIM_SHOW, NIM_HIDE, NIM_AUTO
-};
-
-extern String string_from_mode(NOTIFYICONMODE mode);
-
- /// configuration for the display mode of a notification icon
-struct NotifyIconConfig
-{
-       NotifyIconConfig() : _mode(NIM_AUTO) {}
-
-       void    create_name();
-       bool    match(const NotifyIconConfig& props) const;
-
-        // properties used to identify a notification icon
-       String  _tipText;
-       String  _windowTitle;   // To look at the window title and at the window module path of the notify icon owner window
-       String  _modulePath;    // to identify notification icons is an extension above XP's behaviour.
-                                                       // (XP seems to store icon image data in the registry instead.)
-       NOTIFYICONMODE _mode;
-
-       String  _name;                  /// unique name used to identify the entry in the configuration file
-};
-
- /// list of NotifyIconConfig structures
-typedef list<NotifyIconConfig> NotifyIconCfgList;
-
-
- /// structure for maintaining informations about one notification icon
-struct NotifyInfo : public NotifyIconIndex, public NotifyIconConfig
-{
-       NotifyInfo();
-
-        // sort operator
-       friend bool operator<(const NotifyInfo& a, const NotifyInfo& b)
-               {return a._idx < b._idx;}
-
-       bool    modify(NOTIFYICONDATA* pnid);
-
-       int             _idx;   // display index
-       HICON   _hIcon;
-       DWORD   _dwState;
-       UINT    _uCallbackMessage;
-       UINT    _version;
-
-       DWORD   _lastChange;    // timer tick value of the last change
-};
-
-typedef map<NotifyIconIndex, NotifyInfo> NotifyIconMap;
-typedef set<NotifyInfo> NotifyIconSet;
-
-
-struct NotifyHook
-{
-       NotifyHook();
-       ~NotifyHook();
-
-       void    GetModulePath(HWND hwnd, HWND hwndCallback);
-       bool    ModulePathCopyData(LPARAM lparam, HWND* phwnd, String& path);
-
-protected:
-       const UINT WM_GETMODULEPATH;
-};
-
-
- /// tray notification area aka "tray"
-struct NotifyArea : public Window
-{
-       typedef Window super;
-
-       NotifyArea(HWND hwnd);
-       ~NotifyArea();
-
-       static HWND Create(HWND hwndParent);
-
-       LRESULT ProcessTrayNotification(int notify_code, NOTIFYICONDATA* pnid);
-
-protected:
-       WindowHandle _hwndClock;
-       int             _clock_width;
-
-       ToolTip _tooltip;
-       NotifyHook _hook;
-
-       bool    _show_hidden;
-       bool    _hide_inactive;
-       bool    _show_button;
-
-       LRESULT Init(LPCREATESTRUCT pcs);
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Command(int id, int code);
-       int             Notify(int id, NMHDR* pnmh);
-
-       void    UpdateIcons();
-       void    Paint();
-       void    Refresh(bool do_refresh=false);
-       void    CancelModes();
-
-       NotifyIconSet::iterator IconHitTest(const POINT& pos);
-       bool    DetermineHideState(NotifyInfo& entry);
-
-       void    read_config();
-       void    write_config();
-
-       friend struct TrayNotifyDlg;
-
-       NotifyIconCfgList _cfg;
-
-       map<HWND, String> _window_modules;
-
-       NotifyIconMap _icon_map;
-       NotifyIconSet _sorted_icons;
-       int             _next_idx;
-       size_t  _last_icon_count;
-
-       void    show_clock(bool flag);
-};
-
-
-struct NotifyIconDlgInfo : public NotifyIconConfig
-{
-       typedef NotifyIconConfig super;
-
-       NotifyIconDlgInfo(const NotifyInfo& info) : super(info), _lastChange(info._lastChange) {}
-       NotifyIconDlgInfo(const NotifyIconConfig& cfg) : super(cfg), _lastChange(0) {}
-       NotifyIconDlgInfo() : _lastChange(0) {}
-
-       DWORD   _lastChange;
-};
-
-typedef map<int, NotifyIconDlgInfo> NotifyIconDlgInfoMap;
-
-
- /// configuration dialog for notification icons
-struct TrayNotifyDlg : public ResizeController<Dialog>
-{
-       typedef ResizeController<Dialog> super;
-
-       TrayNotifyDlg(HWND hwnd);
-       ~TrayNotifyDlg();
-
-protected:
-       HWND    _tree_ctrl;
-       HACCEL  _haccel;
-       HIMAGELIST      _himl;
-       NotifyArea* _pNotifyArea;
-       NotifyIconDlgInfoMap _info;
-
-       typedef pair<NOTIFYICONMODE, DWORD> IconStatePair;
-       typedef map<NotifyIconIndex, IconStatePair> IconStateMap;
-
-       NotifyIconCfgList _cfg_org;
-       IconStateMap _icon_states_org;
-       bool    _show_hidden_org;
-
-       HTREEITEM _hitemCurrent;
-       HTREEITEM _hitemCurrent_visible;
-       HTREEITEM _hitemCurrent_hidden;
-       HTREEITEM _hitemConfig;
-       HTREEITEM _selectedItem;
-
-       virtual LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       virtual int     Command(int id, int code);
-       virtual int     Notify(int id, NMHDR* pnmh);
-
-       void    Refresh();
-       void    InsertItem(HTREEITEM hparent, HTREEITEM after, const NotifyInfo&, HDC);
-       void    InsertItem(HTREEITEM hparent, HTREEITEM after, const NotifyIconDlgInfo&, HDC, HICON, NOTIFYICONMODE);
-       void    SetIconMode(NOTIFYICONMODE mode);
-       void    RefreshProperties(const NotifyIconDlgInfo& entry);
-};
-
-
- /// window for displaying the time in the tray notification area
-struct ClockWindow : public Window
-{
-       typedef Window super;
-
-       ClockWindow(HWND hwnd);
-
-       static HWND Create(HWND hwndParent);
-
-       void    TimerTick();
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Notify(int id, NMHDR* pnmh);
-
-       bool    FormatTime();
-       void    Paint();
-
-       TCHAR   _time[16];
-       ToolTip _tooltip;
-};
diff --git a/reactos/subsys/system/explorer/utility/dragdropimpl.cpp b/reactos/subsys/system/explorer/utility/dragdropimpl.cpp
deleted file mode 100644 (file)
index 92f7ed5..0000000
+++ /dev/null
@@ -1,514 +0,0 @@
-#include <precomp.h>
-
-/**************************************************************************
-   THIS CODE AND INFORMATION IS PROVIDED 'AS IS' WITHOUT WARRANTY OF
-   ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO
-   THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
-   PARTICULAR PURPOSE.
-   Author: Leon Finker 11/2000
-   Modifications: replaced ATL by STL, Martin Fuchs 7/2003
-**************************************************************************/
-
-// dragdropimp.cpp: implementation of the IDataObjectImpl class.
-//////////////////////////////////////////////////////////////////////
-
-//#include <shlobj.h>
-//#include <assert.h>
-
-//#include "dragdropimpl.h"
-
-//////////////////////////////////////////////////////////////////////
-// IDataObjectImpl Class
-//////////////////////////////////////////////////////////////////////
-
-IDataObjectImpl::IDataObjectImpl(IDropSourceImpl* pDropSource)
- :     super(IID_IDataObject),
-       m_pDropSource(pDropSource),
-       m_cRefCount(0)
-{
-}
-
-IDataObjectImpl::~IDataObjectImpl()
-{
-       for(StorageArray::iterator it=_storage.begin(); it!=_storage.end(); ++it)
-               ReleaseStgMedium(it->_medium);
-}
-
-STDMETHODIMP IDataObjectImpl::GetData(
-       /* [unique][in] */ FORMATETC __RPC_FAR *pformatetcIn,
-       /* [out] */ STGMEDIUM __RPC_FAR *pmedium)
-{
-       if (pformatetcIn == NULL || pmedium == NULL)
-               return E_INVALIDARG;
-
-       pmedium->hGlobal = NULL;
-
-       for(StorageArray::iterator it=_storage.begin(); it!=_storage.end(); ++it)
-       {
-               if (pformatetcIn->tymed & it->_format->tymed &&
-                  pformatetcIn->dwAspect == it->_format->dwAspect &&
-                  pformatetcIn->cfFormat == it->_format->cfFormat)
-               {
-                       CopyMedium(pmedium, it->_medium, it->_format);
-                       return S_OK;
-               }
-       }
-
-       return DV_E_FORMATETC;
-}
-
-STDMETHODIMP IDataObjectImpl::GetDataHere(
-       /* [unique][in] */ FORMATETC __RPC_FAR *pformatetc,
-       /* [out][in] */ STGMEDIUM __RPC_FAR *pmedium)
-{
-       return E_NOTIMPL;
-}
-
-STDMETHODIMP IDataObjectImpl::QueryGetData(
-   /* [unique][in] */ FORMATETC __RPC_FAR *pformatetc)
-{
-       if (pformatetc == NULL)
-               return E_INVALIDARG;
-
-       //support others if needed DVASPECT_THUMBNAIL  //DVASPECT_ICON   //DVASPECT_DOCPRINT
-       if (!(DVASPECT_CONTENT & pformatetc->dwAspect))
-               return (DV_E_DVASPECT);
-
-       HRESULT  hr = DV_E_TYMED;
-
-       for(StorageArray::iterator it=_storage.begin(); it!=_storage.end(); ++it)
-       {
-          if (pformatetc->tymed & it->_format->tymed)
-          {
-                 if (pformatetc->cfFormat == it->_format->cfFormat)
-                        return S_OK;
-                 else
-                        hr = DV_E_CLIPFORMAT;
-          }
-          else
-                 hr = DV_E_TYMED;
-       }
-
-       return hr;
-}
-
-STDMETHODIMP IDataObjectImpl::GetCanonicalFormatEtc(
-       /* [unique][in] */ FORMATETC __RPC_FAR *pformatectIn,
-       /* [out] */ FORMATETC __RPC_FAR *pformatetcOut)
-{
-       if (pformatetcOut == NULL)
-               return E_INVALIDARG;
-
-       return DATA_S_SAMEFORMATETC;
-}
-
-STDMETHODIMP IDataObjectImpl::SetData(
-       /* [unique][in] */ FORMATETC __RPC_FAR *pformatetc,
-       /* [unique][in] */ STGMEDIUM __RPC_FAR *pmedium,
-       /* [in] */ BOOL fRelease)
-{
-       if (pformatetc == NULL || pmedium == NULL)
-         return E_INVALIDARG;
-
-       assert(pformatetc->tymed == pmedium->tymed);
-       FORMATETC* fetc=new FORMATETC;
-       STGMEDIUM* pStgMed = new STGMEDIUM;
-
-       if (fetc == NULL || pStgMed == NULL)
-               return E_OUTOFMEMORY;
-
-       ZeroMemory(fetc, sizeof(FORMATETC));
-       ZeroMemory(pStgMed, sizeof(STGMEDIUM));
-
-       *fetc = *pformatetc;
-
-       if (fRelease)
-         *pStgMed = *pmedium;
-       else
-               CopyMedium(pStgMed, pmedium, pformatetc);
-
-       DataStorage storage;
-
-       storage._format = fetc;
-       storage._medium = pStgMed;
-
-       _storage.push_back(storage);
-
-       return S_OK;
-}
-
-void IDataObjectImpl::CopyMedium(STGMEDIUM* pMedDest, STGMEDIUM* pMedSrc, FORMATETC* pFmtSrc)
-{
-       switch(pMedSrc->tymed)
-       {
-       case TYMED_HGLOBAL:
-               pMedDest->hGlobal = (HGLOBAL)OleDuplicateData(pMedSrc->hGlobal, pFmtSrc->cfFormat, 0);
-               break;
-       case TYMED_GDI:
-               pMedDest->hBitmap = (HBITMAP)OleDuplicateData(pMedSrc->hBitmap, pFmtSrc->cfFormat, 0);
-               break;
-       case TYMED_MFPICT:
-               pMedDest->hMetaFilePict = (HMETAFILEPICT)OleDuplicateData(pMedSrc->hMetaFilePict, pFmtSrc->cfFormat, 0);
-               break;
-       case TYMED_ENHMF:
-               pMedDest->hEnhMetaFile = (HENHMETAFILE)OleDuplicateData(pMedSrc->hEnhMetaFile, pFmtSrc->cfFormat, 0);
-               break;
-       case TYMED_FILE:
-               pMedDest->lpszFileName = (LPOLESTR)OleDuplicateData(pMedSrc->lpszFileName, pFmtSrc->cfFormat, 0);
-               break;
-       case TYMED_ISTREAM:
-               pMedDest->pstm = pMedSrc->pstm;
-               pMedSrc->pstm->AddRef();
-               break;
-       case TYMED_ISTORAGE:
-               pMedDest->pstg = pMedSrc->pstg;
-               pMedSrc->pstg->AddRef();
-               break;
-       case TYMED_NULL:
-       default:
-               break;
-       }
-       pMedDest->tymed = pMedSrc->tymed;
-       pMedDest->pUnkForRelease = pMedSrc->pUnkForRelease;
-}
-
-STDMETHODIMP IDataObjectImpl::EnumFormatEtc(
-   /* [in] */ DWORD dwDirection,
-   /* [out] */ IEnumFORMATETC __RPC_FAR *__RPC_FAR *ppenumFormatEtc)
-{
-       if (ppenumFormatEtc == NULL)
-         return E_POINTER;
-
-       *ppenumFormatEtc=NULL;
-       switch (dwDirection)
-       {
-         case DATADIR_GET:
-                *ppenumFormatEtc = new EnumFormatEtcImpl(_storage);
-
-                if (!*ppenumFormatEtc)
-                        return E_OUTOFMEMORY;
-
-                (*ppenumFormatEtc)->AddRef();
-                break;
-       
-         case DATADIR_SET:
-         default:
-                return E_NOTIMPL;
-                break;
-       }
-
-   return S_OK;
-}
-
-STDMETHODIMP IDataObjectImpl::DAdvise(
-   /* [in] */ FORMATETC __RPC_FAR *pformatetc,
-   /* [in] */ DWORD advf,
-   /* [unique][in] */ IAdviseSink __RPC_FAR *pAdvSink,
-   /* [out] */ DWORD __RPC_FAR *pdwConnection)
-{
-       return OLE_E_ADVISENOTSUPPORTED;
-}
-
-STDMETHODIMP IDataObjectImpl::DUnadvise(
-   /* [in] */ DWORD dwConnection)
-{
-       return E_NOTIMPL;
-}
-
-HRESULT STDMETHODCALLTYPE IDataObjectImpl::EnumDAdvise(
-   /* [out] */ IEnumSTATDATA __RPC_FAR *__RPC_FAR *ppenumAdvise)
-{
-       return OLE_E_ADVISENOTSUPPORTED;
-}
-
-//////////////////////////////////////////////////////////////////////
-// IDropSourceImpl Class
-//////////////////////////////////////////////////////////////////////
-
-STDMETHODIMP IDropSourceImpl::QueryContinueDrag(
-       /* [in] */ BOOL fEscapePressed,
-       /* [in] */ DWORD grfKeyState)
-{
-   if (fEscapePressed)
-         return DRAGDROP_S_CANCEL;
-   if (!(grfKeyState & (MK_LBUTTON|MK_RBUTTON)))
-   {
-         m_bDropped = true;
-         return DRAGDROP_S_DROP;
-   }
-
-   return S_OK;
-
-}
-
-STDMETHODIMP IDropSourceImpl::GiveFeedback(
-       /* [in] */ DWORD dwEffect)
-{
-       return DRAGDROP_S_USEDEFAULTCURSORS;
-}
-
-//////////////////////////////////////////////////////////////////////
-// EnumFormatEtcImpl Class
-//////////////////////////////////////////////////////////////////////
-
-EnumFormatEtcImpl::EnumFormatEtcImpl(const FormatArray& ArrFE)
- :     super(IID_IEnumFORMATETC),
-       m_cRefCount(0),
-       m_iCur(0)
-{
-   for(FormatArray::const_iterator it=ArrFE.begin(); it!=ArrFE.end(); ++it)
-               m_pFmtEtc.push_back(*it);
-}
-
-EnumFormatEtcImpl::EnumFormatEtcImpl(const StorageArray& ArrFE)
- :     super(IID_IEnumFORMATETC),
-       m_cRefCount(0),
-       m_iCur(0)
-{
-   for(StorageArray::const_iterator it=ArrFE.begin(); it!=ArrFE.end(); ++it)
-               m_pFmtEtc.push_back(*it->_format);
-}
-
-STDMETHODIMP EnumFormatEtcImpl::Next(ULONG celt,LPFORMATETC lpFormatEtc, ULONG* pceltFetched)
-{
-   if (pceltFetched != NULL)
-          *pceltFetched=0;
-       
-   ULONG cReturn = celt;
-
-   if (celt <= 0 || lpFormatEtc == NULL || m_iCur >= m_pFmtEtc.size())
-         return S_FALSE;
-
-   if (pceltFetched == NULL && celt != 1) // pceltFetched can be NULL only for 1 item request
-         return S_FALSE;
-
-       while (m_iCur < m_pFmtEtc.size() && cReturn > 0)
-       {
-               *lpFormatEtc++ = m_pFmtEtc[m_iCur++];
-               --cReturn;
-       }
-       if (pceltFetched != NULL)
-               *pceltFetched = celt - cReturn;
-
-       return (cReturn == 0) ? S_OK : S_FALSE;
-}
-
-STDMETHODIMP EnumFormatEtcImpl::Skip(ULONG celt)
-{
-       if ((m_iCur + int(celt)) >= m_pFmtEtc.size())
-               return S_FALSE;
-
-       m_iCur += celt;
-       return S_OK;
-}
-
-STDMETHODIMP EnumFormatEtcImpl::Reset(void)
-{
-   m_iCur = 0;
-   return S_OK;
-}
-                       
-STDMETHODIMP EnumFormatEtcImpl::Clone(IEnumFORMATETC** ppCloneEnumFormatEtc)
-{
-  if (ppCloneEnumFormatEtc == NULL)
-       return E_POINTER;
-       
-  EnumFormatEtcImpl* newEnum = new EnumFormatEtcImpl(m_pFmtEtc);
-
-  if (!newEnum)
-       return E_OUTOFMEMORY;
-
-  newEnum->AddRef();
-  newEnum->m_iCur = m_iCur;
-  *ppCloneEnumFormatEtc = newEnum;
-
-  return S_OK;
-}
-
-//////////////////////////////////////////////////////////////////////
-// IDropTargetImpl Class
-//////////////////////////////////////////////////////////////////////
-IDropTargetImpl::IDropTargetImpl(HWND hTargetWnd)
- :     m_cRefCount(0),
-       m_bAllowDrop(false),
-       m_pDropTargetHelper(NULL),
-       m_pSupportedFrmt(NULL),
-       m_hTargetWnd(hTargetWnd)
-{
-       assert(m_hTargetWnd != NULL);
-
-       if (FAILED(CoCreateInstance(CLSID_DragDropHelper, NULL, CLSCTX_INPROC_SERVER,
-                                        IID_IDropTargetHelper,(LPVOID*)&m_pDropTargetHelper)))
-               m_pDropTargetHelper = NULL;
-}
-
-IDropTargetImpl::~IDropTargetImpl()
-{
-       if (m_pDropTargetHelper != NULL)
-       {
-               m_pDropTargetHelper->Release();
-               m_pDropTargetHelper = NULL;
-       }
-}
-
-HRESULT STDMETHODCALLTYPE IDropTargetImpl::QueryInterface( /* [in] */ REFIID riid,
-                                               /* [iid_is][out] */ void __RPC_FAR *__RPC_FAR *ppvObject)
-{
-       *ppvObject = NULL;
-       if (IID_IUnknown==riid || IID_IDropTarget==riid)
-               *ppvObject=this;
-
-       if (*ppvObject != NULL)
-       {
-               ((LPUNKNOWN)*ppvObject)->AddRef();
-               return S_OK;
-       }
-
-       return E_NOINTERFACE;
-}
-
-ULONG STDMETHODCALLTYPE IDropTargetImpl::Release()
-{
-   long nTemp = --m_cRefCount;
-
-   assert(nTemp >= 0);
-
-   if (nTemp == 0)
-         delete this;
-
-   return nTemp;
-}
-
-bool IDropTargetImpl::QueryDrop(DWORD grfKeyState, LPDWORD pdwEffect)
-{
-       DWORD dwOKEffects = *pdwEffect;
-
-       if (!m_bAllowDrop)
-       {
-          *pdwEffect = DROPEFFECT_NONE;
-          return false;
-       }
-
-       //CTRL+SHIFT  -- DROPEFFECT_LINK
-       //CTRL            -- DROPEFFECT_COPY
-       //SHIFT           -- DROPEFFECT_MOVE
-       //no modifier -- DROPEFFECT_MOVE or whatever is allowed by src
-       *pdwEffect = (grfKeyState & MK_CONTROL) ?
-                                ( (grfKeyState & MK_SHIFT) ? DROPEFFECT_LINK : DROPEFFECT_COPY ):
-                                ( (grfKeyState & MK_SHIFT) ? DROPEFFECT_MOVE : DROPEFFECT_NONE );
-       if (*pdwEffect == 0)
-       {
-          // No modifier keys used by user while dragging.
-          if (DROPEFFECT_COPY & dwOKEffects)
-                 *pdwEffect = DROPEFFECT_COPY;
-          else if (DROPEFFECT_MOVE & dwOKEffects)
-                 *pdwEffect = DROPEFFECT_MOVE;
-          else if (DROPEFFECT_LINK & dwOKEffects)
-                 *pdwEffect = DROPEFFECT_LINK;
-          else
-          {
-                 *pdwEffect = DROPEFFECT_NONE;
-          }
-       }
-       else
-       {
-          // Check if the drag source application allows the drop effect desired by user.
-          // The drag source specifies this in DoDragDrop
-          if (!(*pdwEffect & dwOKEffects))
-                 *pdwEffect = DROPEFFECT_NONE;
-       }
-
-       return (DROPEFFECT_NONE == *pdwEffect)?false:true;
-}      
-
-HRESULT STDMETHODCALLTYPE IDropTargetImpl::DragEnter(
-       /* [unique][in] */ IDataObject __RPC_FAR *pDataObj,
-       /* [in] */ DWORD grfKeyState,
-       /* [in] */ POINTL pt,
-       /* [out][in] */ DWORD __RPC_FAR *pdwEffect)
-{
-       if (pDataObj == NULL)
-               return E_INVALIDARG;
-
-       if (m_pDropTargetHelper)
-               m_pDropTargetHelper->DragEnter(m_hTargetWnd, pDataObj, (LPPOINT)&pt, *pdwEffect);
-
-       //IEnumFORMATETC* pEnum;
-       //pDataObj->EnumFormatEtc(DATADIR_GET,&pEnum);
-       //FORMATETC ftm;
-       //for()
-       //pEnum->Next(1,&ftm,0);
-       //pEnum->Release();
-       m_pSupportedFrmt = NULL;
-
-       for(FormatArray::iterator it=m_formatetc.begin(); it!=m_formatetc.end(); ++it)
-       {
-               m_bAllowDrop = (pDataObj->QueryGetData(&*it) == S_OK)? true: false;
-
-               if (m_bAllowDrop)
-               {
-                       m_pSupportedFrmt = &*it;
-                       break;
-               }
-       }
-
-       QueryDrop(grfKeyState, pdwEffect);
-
-       return S_OK;
-}
-
-HRESULT STDMETHODCALLTYPE IDropTargetImpl::DragOver(
-               /* [in] */ DWORD grfKeyState,
-               /* [in] */ POINTL pt,
-               /* [out][in] */ DWORD __RPC_FAR *pdwEffect)
-{
-       if (m_pDropTargetHelper)
-               m_pDropTargetHelper->DragOver((LPPOINT)&pt, *pdwEffect);
-
-       QueryDrop(grfKeyState, pdwEffect);
-
-       return S_OK;
-}
-
-HRESULT STDMETHODCALLTYPE IDropTargetImpl::DragLeave()
-{
-       if (m_pDropTargetHelper)
-               m_pDropTargetHelper->DragLeave();
-       
-       m_bAllowDrop = false;
-       m_pSupportedFrmt = NULL;
-
-       return S_OK;
-}
-
-HRESULT STDMETHODCALLTYPE IDropTargetImpl::Drop(
-       /* [unique][in] */ IDataObject __RPC_FAR *pDataObj,
-       /* [in] */ DWORD grfKeyState, /* [in] */ POINTL pt,
-       /* [out][in] */ DWORD __RPC_FAR *pdwEffect)
-{
-       if (pDataObj == NULL)
-               return E_INVALIDARG;    
-
-       if (m_pDropTargetHelper)
-               m_pDropTargetHelper->Drop(pDataObj, (LPPOINT)&pt, *pdwEffect);
-
-       if (QueryDrop(grfKeyState, pdwEffect))
-       {
-               if (m_bAllowDrop && m_pSupportedFrmt != NULL)
-               {
-                       STGMEDIUM medium;
-
-                       if (pDataObj->GetData(m_pSupportedFrmt, &medium) == S_OK)
-                       {
-                               if (OnDrop(m_pSupportedFrmt, medium, pdwEffect)) //does derive class wants us to free medium?
-                                       ReleaseStgMedium(&medium);
-                       }
-               }
-       }
-
-       m_bAllowDrop = false;
-       *pdwEffect = DROPEFFECT_NONE;
-       m_pSupportedFrmt = NULL;
-
-       return S_OK;
-}
diff --git a/reactos/subsys/system/explorer/utility/dragdropimpl.h b/reactos/subsys/system/explorer/utility/dragdropimpl.h
deleted file mode 100644 (file)
index 6a59c67..0000000
+++ /dev/null
@@ -1,267 +0,0 @@
-// IDataObjectImpl.h: interface for the CIDataObjectImpl class.
-/**************************************************************************
-   THIS CODE AND INFORMATION IS PROVIDED 'AS IS' WITHOUT WARRANTY OF
-   ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO
-   THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
-   PARTICULAR PURPOSE.
-   Author: Leon Finker 11/2000
-   Modifications: replaced ATL by STL, Martin Fuchs 7/2003
-**************************************************************************/
-
-#include <vector>
-using std::vector;
-
-
-typedef vector<FORMATETC> FormatArray;
-
- /// structure containing information for one format of EnumFormatEtcImpl
-struct DataStorage {
-       FORMATETC*      _format;
-       STGMEDIUM*      _medium;
-};
-
-typedef vector<DataStorage> StorageArray;
-
-
- /// implementation of IEnumFORMATETC interface
-class EnumFormatEtcImpl
- :     public IComSrvBase<IEnumFORMATETC, EnumFormatEtcImpl>, public SimpleComObject
-{
-       typedef IComSrvBase<IEnumFORMATETC, EnumFormatEtcImpl> super;
-
-private:
-        ULONG                  m_cRefCount;
-        FormatArray    m_pFmtEtc;
-        size_t                 m_iCur;
-
-public:
-        EnumFormatEtcImpl(const FormatArray& ArrFE);
-        EnumFormatEtcImpl(const StorageArray& ArrFE);
-        virtual ~EnumFormatEtcImpl() {}
-
-        //IEnumFORMATETC members
-        virtual HRESULT STDMETHODCALLTYPE Next(ULONG, LPFORMATETC, ULONG*);
-        virtual HRESULT STDMETHODCALLTYPE Skip(ULONG);
-        virtual HRESULT STDMETHODCALLTYPE Reset(void);
-        virtual HRESULT STDMETHODCALLTYPE Clone(IEnumFORMATETC**);
-};
-
- /// implementation of IDropSource interface
-class IDropSourceImpl
- :     public IComSrvBase<IDropSource, IDropSourceImpl>, public SimpleComObject
-{
-       typedef IComSrvBase<IDropSource, IDropSourceImpl> super;
-
-       long m_cRefCount;
-
-public:
-       bool m_bDropped;
-
-       IDropSourceImpl()
-        :      super(IID_IDropSource),
-               m_cRefCount(0),
-               m_bDropped(false)
-       {
-       }
-
-       virtual ~IDropSourceImpl() {}
-
-       //IDropSource
-       virtual HRESULT STDMETHODCALLTYPE QueryContinueDrag(
-               /* [in] */ BOOL fEscapePressed,
-               /* [in] */ DWORD grfKeyState);
-
-       virtual HRESULT STDMETHODCALLTYPE GiveFeedback(
-               /* [in] */ DWORD dwEffect);
-};
-
- /// implementation of IDataObject interface
-class IDataObjectImpl
- :     public IComSrvBase<IDataObject, IDataObjectImpl>, public SimpleComObject
-       //public IAsyncOperation
-{
-       typedef IComSrvBase<IDataObject, IDataObjectImpl> super;
-
-       IDropSourceImpl* m_pDropSource;
-       long m_cRefCount;
-
-       StorageArray    _storage;
-
-public:
-       IDataObjectImpl(IDropSourceImpl* pDropSource);
-       virtual ~IDataObjectImpl();
-
-       void CopyMedium(STGMEDIUM* pMedDest, STGMEDIUM* pMedSrc, FORMATETC* pFmtSrc);
-
-       //IDataObject
-       virtual /* [local] */ HRESULT STDMETHODCALLTYPE GetData(
-               /* [unique][in] */ FORMATETC __RPC_FAR *pformatetcIn,
-               /* [out] */ STGMEDIUM __RPC_FAR *pmedium);
-
-       virtual /* [local] */ HRESULT STDMETHODCALLTYPE GetDataHere(
-               /* [unique][in] */ FORMATETC __RPC_FAR *pformatetc,
-               /* [out][in] */ STGMEDIUM __RPC_FAR *pmedium);
-
-       virtual HRESULT STDMETHODCALLTYPE QueryGetData(
-               /* [unique][in] */ FORMATETC __RPC_FAR *pformatetc);
-
-       virtual HRESULT STDMETHODCALLTYPE GetCanonicalFormatEtc(
-               /* [unique][in] */ FORMATETC __RPC_FAR *pformatectIn,
-               /* [out] */ FORMATETC __RPC_FAR *pformatetcOut);
-
-       virtual /* [local] */ HRESULT STDMETHODCALLTYPE SetData(
-               /* [unique][in] */ FORMATETC __RPC_FAR *pformatetc,
-               /* [unique][in] */ STGMEDIUM __RPC_FAR *pmedium,
-               /* [in] */ BOOL fRelease);
-
-       virtual HRESULT STDMETHODCALLTYPE EnumFormatEtc(
-               /* [in] */ DWORD dwDirection,
-               /* [out] */ IEnumFORMATETC __RPC_FAR *__RPC_FAR *ppenumFormatEtc);
-
-       virtual HRESULT STDMETHODCALLTYPE DAdvise(
-               /* [in] */ FORMATETC __RPC_FAR *pformatetc,
-               /* [in] */ DWORD advf,
-               /* [unique][in] */ IAdviseSink __RPC_FAR *pAdvSink,
-               /* [out] */ DWORD __RPC_FAR *pdwConnection);
-
-       virtual HRESULT STDMETHODCALLTYPE DUnadvise(
-               /* [in] */ DWORD dwConnection);
-
-       virtual HRESULT STDMETHODCALLTYPE EnumDAdvise(
-               /* [out] */ IEnumSTATDATA __RPC_FAR *__RPC_FAR *ppenumAdvise);
-
-       //IAsyncOperation
-       //virtual HRESULT STDMETHODCALLTYPE SetAsyncMode(
-       //        /* [in] */ BOOL fDoOpAsync)
-       //{
-       //      return E_NOTIMPL;
-       //}
-       //
-       //virtual HRESULT STDMETHODCALLTYPE GetAsyncMode(
-       //        /* [out] */ BOOL __RPC_FAR *pfIsOpAsync)
-       //{
-       //      return E_NOTIMPL;
-       //}
-       //
-       //virtual HRESULT STDMETHODCALLTYPE StartOperation(
-       //        /* [optional][unique][in] */ IBindCtx __RPC_FAR *pbcReserved)
-       //{
-       //      return E_NOTIMPL;
-       //}
-       //
-       //virtual HRESULT STDMETHODCALLTYPE InOperation(
-       //        /* [out] */ BOOL __RPC_FAR *pfInAsyncOp)
-       //{
-       //      return E_NOTIMPL;
-       //}
-       //
-       //virtual HRESULT STDMETHODCALLTYPE EndOperation(
-       //        /* [in] */ HRESULT hResult,
-       //        /* [unique][in] */ IBindCtx __RPC_FAR *pbcReserved,
-       //        /* [in] */ DWORD dwEffects)
-       //{
-       //      return E_NOTIMPL;
-       //}*/
-};
-
- /// implementation of IDropTarget interface
-class IDropTargetImpl : public IDropTarget
-{
-       DWORD m_cRefCount;
-       bool m_bAllowDrop;
-       IDropTargetHelper* m_pDropTargetHelper;
-
-       FormatArray m_formatetc;
-       FORMATETC* m_pSupportedFrmt;
-
-protected:
-       HWND m_hTargetWnd;
-
-public:
-       IDropTargetImpl(HWND m_hTargetWnd);
-       virtual ~IDropTargetImpl();
-
-       void AddSuportedFormat(FORMATETC& ftetc) {m_formatetc.push_back(ftetc);}
-
-       //return values: true - release the medium. false - don't release the medium
-       virtual bool OnDrop(FORMATETC* pFmtEtc, STGMEDIUM& medium, DWORD *pdwEffect) = 0;
-
-       virtual HRESULT STDMETHODCALLTYPE QueryInterface(
-               /* [in] */ REFIID riid,
-               /* [iid_is][out] */ void __RPC_FAR *__RPC_FAR *ppvObject);
-       virtual ULONG STDMETHODCALLTYPE AddRef() {return ++m_cRefCount;}
-       virtual ULONG STDMETHODCALLTYPE Release();
-
-       bool QueryDrop(DWORD grfKeyState, LPDWORD pdwEffect);
-       virtual HRESULT STDMETHODCALLTYPE DragEnter(
-               /* [unique][in] */ IDataObject __RPC_FAR *pDataObj,
-               /* [in] */ DWORD grfKeyState,
-               /* [in] */ POINTL pt,
-               /* [out][in] */ DWORD __RPC_FAR *pdwEffect);
-       virtual HRESULT STDMETHODCALLTYPE DragOver(
-               /* [in] */ DWORD grfKeyState,
-               /* [in] */ POINTL pt,
-               /* [out][in] */ DWORD __RPC_FAR *pdwEffect);
-       virtual HRESULT STDMETHODCALLTYPE DragLeave();
-       virtual HRESULT STDMETHODCALLTYPE Drop(
-               /* [unique][in] */ IDataObject __RPC_FAR *pDataObj,
-               /* [in] */ DWORD grfKeyState,
-               /* [in] */ POINTL pt,
-               /* [out][in] */ DWORD __RPC_FAR *pdwEffect);
-};
-
- /// implementation of IDragSourceHelper interface
-class DragSourceHelper
-{
-       IDragSourceHelper* pDragSourceHelper;
-
-public:
-       DragSourceHelper()
-       {
-               if (FAILED(CoCreateInstance(CLSID_DragDropHelper,
-                                               NULL,
-                                               CLSCTX_INPROC_SERVER,
-                                               IID_IDragSourceHelper,
-                                               (void**)&pDragSourceHelper)))
-                       pDragSourceHelper = NULL;
-       }
-
-       virtual ~DragSourceHelper()
-       {
-               if (pDragSourceHelper != NULL)
-               {
-                       pDragSourceHelper->Release();
-                       pDragSourceHelper=NULL;
-               }
-       }
-
-       // IDragSourceHelper
-       HRESULT InitializeFromBitmap(HBITMAP hBitmap,
-               POINT& pt,      // cursor position in client coords of the window
-               RECT& rc,       // selected item's bounding rect
-               IDataObject* pDataObject,
-               COLORREF crColorKey=GetSysColor(COLOR_WINDOW)// color of the window used for transparent effect.
-               )
-       {
-               if (pDragSourceHelper == NULL)
-                       return E_FAIL;
-
-                       SHDRAGIMAGE di;
-                       BITMAP          bm;
-                       GetObject(hBitmap, sizeof(bm), &bm);
-                       di.sizeDragImage.cx = bm.bmWidth;
-                       di.sizeDragImage.cy = bm.bmHeight;
-                       di.hbmpDragImage = hBitmap;
-                       di.crColorKey = crColorKey;
-                       di.ptOffset.x = pt.x - rc.left;
-                       di.ptOffset.y = pt.y - rc.top;
-               return pDragSourceHelper->InitializeFromBitmap(&di, pDataObject);
-       }
-
-       HRESULT InitializeFromWindow(HWND hwnd, POINT& pt,IDataObject* pDataObject)
-       {
-               if (pDragSourceHelper == NULL)
-                       return E_FAIL;
-               return pDragSourceHelper->InitializeFromWindow(hwnd, &pt, pDataObject);
-       }
-};
diff --git a/reactos/subsys/system/explorer/utility/shellbrowserimpl.cpp b/reactos/subsys/system/explorer/utility/shellbrowserimpl.cpp
deleted file mode 100644 (file)
index 61b11c5..0000000
+++ /dev/null
@@ -1,117 +0,0 @@
-/*
- * Copyright 2003 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- // 
- // shellbrowserimpl.cpp
- //
- // Martin Fuchs, 28.09.2003
- //
- // Credits: Thanks to Leon Finker for his explorer cabinet window example
- //
-
-
-#include <precomp.h>
-
-
-HRESULT IShellBrowserImpl::QueryInterface(REFIID iid, void** ppvObject)
-{
-       if (!ppvObject)
-               return E_POINTER;
-
-       if (iid == IID_IUnknown)
-               *ppvObject = (IUnknown*)static_cast<IShellBrowser*>(this);
-       else if (iid == IID_IOleWindow)
-               *ppvObject = static_cast<IOleWindow*>(this);
-       else if (iid == IID_IShellBrowser)
-               *ppvObject = static_cast<IShellBrowser*>(this);
-       else if (iid == IID_ICommDlgBrowser)
-               *ppvObject = static_cast<ICommDlgBrowser*>(this);
-       else if (iid == IID_IServiceProvider)
-               *ppvObject = static_cast<IServiceProvider*>(this);
-       else {
-               *ppvObject = NULL;
-               return E_NOINTERFACE;
-       }
-
-       return S_OK;
-}
-
-HRESULT IShellBrowserImpl::QueryService(REFGUID guidService, REFIID riid, void** ppvObject)
-{
-       if (!ppvObject)
-               return E_POINTER;
-
-       ///@todo use guidService
-
-       if (riid == IID_IUnknown)
-               *ppvObject = (IUnknown*)static_cast<IShellBrowser*>(this);
-       else if (riid == IID_IOleWindow)
-               *ppvObject = static_cast<IOleWindow*>(this);
-       else if (riid == IID_IShellBrowser)
-               *ppvObject = static_cast<IShellBrowser*>(this);
-       else if (riid == IID_ICommDlgBrowser)
-               *ppvObject = static_cast<ICommDlgBrowser*>(this);
-       else if (riid == IID_IServiceProvider)
-               *ppvObject = static_cast<IServiceProvider*>(this);
-       else if (riid == IID_IOleCommandTarget)
-               *ppvObject = static_cast<IOleCommandTarget*>(this);
-       else {
-               *ppvObject = NULL;
-               return E_NOINTERFACE;
-       }
-
-       return S_OK;
-}
-
-HRESULT IShellBrowserImpl::QueryStatus(const GUID* pguidCmdGroup, ULONG cCmds, OLECMD prgCmds[], OLECMDTEXT* pCmdText)
-{
-       return E_FAIL;  ///@todo implement IOleCommandTarget
-}
-
-HRESULT IShellBrowserImpl::Exec(const GUID* pguidCmdGroup, DWORD nCmdID, DWORD nCmdexecopt, VARIANT* pvaIn, VARIANT* pvaOut)
-{
-       return E_FAIL;  ///@todo implement IOleCommandTarget
-}
-
-
- // process default command: look for folders and traverse into them
-HRESULT IShellBrowserImpl::OnDefaultCommand(IShellView* ppshv)
-{
-       IDataObject* selection;
-
-       HRESULT hr = ppshv->GetItemObject(SVGIO_SELECTION, IID_IDataObject, (void**)&selection);
-       if (FAILED(hr))
-               return hr;
-
-       PIDList pidList;
-
-       hr = pidList.GetData(selection);
-       if (FAILED(hr)) {
-               selection->Release();
-               return hr;
-       }
-
-       hr = OnDefaultCommand(pidList);
-
-       selection->Release();
-
-       return hr;
-}
diff --git a/reactos/subsys/system/explorer/utility/shellbrowserimpl.h b/reactos/subsys/system/explorer/utility/shellbrowserimpl.h
deleted file mode 100644 (file)
index e1bfe0b..0000000
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Copyright 2003 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // shellbrowserimpl.h
- //
- // Martin Fuchs, 23.07.2003
- //
- // Credits: Thanks to Leon Finker for his explorer cabinet window example
- //
-
-#ifdef __MINGW32__
-#include "servprov.h"  // for IServiceProvider
-#include "docobj.h"    // for IOleCommandTarget
-#endif
-
-
- /// Implementation of IShellBrowser and ICommDlgBrowser interfaces for explorer child windows (see ShellBrowserChild)
-struct IShellBrowserImpl
- :     public IShellBrowser,
-       public ICommDlgBrowser,
-       public IServiceProvider,
-       public IOleCommandTarget
-{
-       IShellBrowserImpl()
-        :      _dwRef(0)
-       {
-       }
-
-       virtual ~IShellBrowserImpl()
-       {
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID iid, void** ppvObject);
-
-       virtual ULONG STDMETHODCALLTYPE AddRef() {return ++_dwRef;}
-       virtual ULONG STDMETHODCALLTYPE Release() {return --_dwRef;}  //not heap based
-
-       // *** IOleWindow methods ***
-       virtual HRESULT STDMETHODCALLTYPE ContextSensitiveHelp(BOOL fEnterMode) {return E_NOTIMPL;}
-
-       // *** ICommDlgBrowser methods ***
-       virtual HRESULT STDMETHODCALLTYPE OnDefaultCommand(IShellView* ppshv);
-
-       virtual HRESULT STDMETHODCALLTYPE OnStateChange(IShellView* ppshv, ULONG uChange)
-       {       //handle selection, rename, focus if needed
-               return E_NOTIMPL;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE IncludeObject(IShellView* ppshv, LPCITEMIDLIST pidl)
-       {       //filter files if needed
-               return S_OK;
-       }
-
-       // *** IShellBrowser methods *** (same as IOleInPlaceFrame)
-       virtual HRESULT STDMETHODCALLTYPE InsertMenusSB(HMENU hmenuShared, LPOLEMENUGROUPWIDTHS lpMenuWidths) {return E_NOTIMPL;}
-       virtual HRESULT STDMETHODCALLTYPE SetMenuSB(HMENU hmenuShared, HOLEMENU holemenuReserved, HWND hwndActiveObject) {return E_NOTIMPL;}
-       virtual HRESULT STDMETHODCALLTYPE RemoveMenusSB(HMENU hmenuShared) {return E_NOTIMPL;}
-       virtual HRESULT STDMETHODCALLTYPE SetStatusTextSB(LPCOLESTR lpszStatusText) {return E_NOTIMPL;}
-       virtual HRESULT STDMETHODCALLTYPE EnableModelessSB(BOOL fEnable) {return E_NOTIMPL;}
-       virtual HRESULT STDMETHODCALLTYPE BrowseObject(LPCITEMIDLIST pidl, UINT wFlags) {return E_NOTIMPL;}
-       virtual HRESULT STDMETHODCALLTYPE GetViewStateStream(DWORD grfMode, LPSTREAM* ppStrm) {return E_NOTIMPL;}
-       virtual HRESULT STDMETHODCALLTYPE OnViewWindowActive(IShellView* ppshv) {return E_NOTIMPL;}
-       virtual HRESULT STDMETHODCALLTYPE SetToolbarItems(LPTBBUTTON lpButtons, UINT nButtons, UINT uFlags) {return E_NOTIMPL;}
-       virtual HRESULT STDMETHODCALLTYPE TranslateAcceleratorSB(LPMSG lpmsg, WORD wID) {return S_OK;}
-
-       // IServiceProvider
-       virtual HRESULT STDMETHODCALLTYPE QueryService(REFGUID guidService, REFIID riid, void** ppvObject);
-
-       // IOleCommandTarget
-       virtual HRESULT STDMETHODCALLTYPE QueryStatus(const GUID *pguidCmdGroup, ULONG cCmds, OLECMD prgCmds[], OLECMDTEXT* pCmdText);
-       virtual HRESULT STDMETHODCALLTYPE Exec(const GUID *pguidCmdGroup, DWORD nCmdID, DWORD nCmdexecopt, VARIANT *pvaIn, VARIANT *pvaOut);
-
-protected:
-       DWORD   _dwRef;
-
-       virtual HRESULT OnDefaultCommand(LPIDA pida) {return E_NOTIMPL;}
-};
-
-#ifndef WM_GETISHELLBROWSER
-#define WM_GETISHELLBROWSER (WM_USER+7)
-#endif
diff --git a/reactos/subsys/system/explorer/utility/shellclasses.cpp b/reactos/subsys/system/explorer/utility/shellclasses.cpp
deleted file mode 100644 (file)
index f7cd3fe..0000000
+++ /dev/null
@@ -1,571 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- // 
- // shellclasses.cpp
- //
- // C++ wrapper classes for COM interfaces and shell objects
- //
- // Martin Fuchs, 20.07.2003
- //
-
-
-#include <precomp.h>
-
-
-#ifdef _MS_VER
-#pragma comment(lib, "shell32")        // link to shell32.dll
-#endif
-
-
- // work around GCC's wide string constant bug
-#ifdef __GNUC__
-const LPCTSTR sCFSTR_SHELLIDLIST = TEXT("Shell IDList Array");
-#endif
-
-
- // helper functions for string copying
-
-/*LPSTR strcpyn(LPSTR dest, LPCSTR source, size_t count)
-{
-       LPCSTR s;
-       LPSTR d = dest;
-
-       for(s=source; count&&(*d++=*s++); )
-               count--;
-
-       return dest;
-}
-
-LPWSTR wcscpyn(LPWSTR dest, LPCWSTR source, size_t count)
-{
-       LPCWSTR s;
-       LPWSTR d = dest;
-
-       for(s=source; count&&(*d++=*s++); )
-               count--;
-
-       return dest;
-}*/
-
-
-String COMException::toString() const
-{
-       TCHAR msg[4*BUFFER_LEN];
-       int l = 4*BUFFER_LEN;
-       LPTSTR p = msg;
-
-       int n = _stprintf_s2(p, l, TEXT("%s\nContext: %s"), super::ErrorMessage(), (LPCTSTR)_context.toString());
-       p += n;
-       l -= n;
-
-       if (_file)
-               p += _stprintf_s2(p, l, TEXT("\nLocation: %hs:%d"), _file, _line);
-
-       return msg;
-}
-
-
- /// Exception Handler for COM exceptions
-
-void HandleException(COMException& e, HWND hwnd)
-{
-       String msg = e.toString();
-
-       SetLastError(0);
-
-       if (hwnd && !IsWindowVisible(hwnd))
-               hwnd = 0;
-
-       MessageBox(hwnd, msg, TEXT("ShellClasses Exception"), MB_ICONHAND|MB_OK);
-
-        // If displaying the error message box _with_ parent was not successfull, display it now without a parent window.
-       if (GetLastError() == ERROR_INVALID_WINDOW_HANDLE)
-               MessageBox(0, msg, TEXT("ShellClasses Exception"), MB_ICONHAND|MB_OK);
-}
-
-
- // common IMalloc object
-
-CommonShellMalloc ShellMalloc::s_cmn_shell_malloc;
-
-
- // common desktop object
-
-ShellFolder& GetDesktopFolder()
-{
-       static CommonDesktop s_desktop;
-
-        // initialize s_desktop
-       s_desktop.init();
-
-       return s_desktop;
-}
-
-
-void CommonDesktop::init()
-{
-       CONTEXT("CommonDesktop::init()");
-
-       if (!_desktop)
-               _desktop = new ShellFolder;
-}
-
-CommonDesktop::~CommonDesktop()
-{
-       if (_desktop)
-               delete _desktop;
-}
-
-
-HRESULT path_from_pidlA(IShellFolder* folder, LPCITEMIDLIST pidl, LPSTR buffer, int len)
-{
-       CONTEXT("path_from_pidlA()");
-
-       StrRetA str;
-
-       HRESULT hr = folder->GetDisplayNameOf(pidl, SHGDN_FORPARSING, &str);
-
-       if (SUCCEEDED(hr))
-               str.GetString(pidl->mkid, buffer, len);
-       else
-               buffer[0] = '\0';
-
-       return hr;
-}
-
-HRESULT path_from_pidlW(IShellFolder* folder, LPCITEMIDLIST pidl, LPWSTR buffer, int len)
-{
-       CONTEXT("path_from_pidlW()");
-
-       StrRetW str;
-
-       HRESULT hr = folder->GetDisplayNameOf(pidl, SHGDN_FORPARSING, &str);
-
-       if (SUCCEEDED(hr))
-               str.GetString(pidl->mkid, buffer, len);
-       else
-               buffer[0] = '\0';
-
-       return hr;
-}
-
-HRESULT name_from_pidl(IShellFolder* folder, LPCITEMIDLIST pidl, LPTSTR buffer, int len, SHGDNF flags)
-{
-       CONTEXT("name_from_pidl()");
-
-       StrRet str;
-
-       HRESULT hr = folder->GetDisplayNameOf(pidl, flags, &str);
-
-       if (SUCCEEDED(hr))
-               str.GetString(pidl->mkid, buffer, len);
-       else
-               buffer[0] = '\0';
-
-       return hr;
-}
-
-
-#ifndef _NO_COMUTIL
-
-ShellFolder::ShellFolder()
-{
-       CONTEXT("ShellFolder::ShellFolder()");
-
-       IShellFolder* desktop;
-
-       CHECKERROR(SHGetDesktopFolder(&desktop));
-
-       super::Attach(desktop);
-       desktop->AddRef();
-}
-
-ShellFolder::ShellFolder(IShellFolder* p)
- :     super(p)
-{
-       CONTEXT("ShellFolder::ShellFolder(IShellFolder*)");
-
-       p->AddRef();
-}
-
-ShellFolder::ShellFolder(IShellFolder* parent, LPCITEMIDLIST pidl)
-{
-       CONTEXT("ShellFolder::ShellFolder(IShellFolder*, LPCITEMIDLIST)");
-
-       IShellFolder* ptr;
-
-       if (!pidl)
-               CHECKERROR(E_INVALIDARG);
-
-       if (pidl && pidl->mkid.cb)
-               CHECKERROR(parent->BindToObject(pidl, 0, IID_IShellFolder, (LPVOID*)&ptr));
-       else
-               ptr = parent;
-
-       super::Attach(ptr);
-       ptr->AddRef();
-}
-
-ShellFolder::ShellFolder(LPCITEMIDLIST pidl)
-{
-       CONTEXT("ShellFolder::ShellFolder(LPCITEMIDLIST)");
-
-       IShellFolder* ptr;
-       IShellFolder* parent = GetDesktopFolder();
-
-       if (pidl && pidl->mkid.cb)
-               CHECKERROR(parent->BindToObject(pidl, 0, IID_IShellFolder, (LPVOID*)&ptr));
-       else
-               ptr = parent;
-
-       super::Attach(ptr);
-       ptr->AddRef();
-}
-
-void ShellFolder::attach(IShellFolder* parent, LPCITEMIDLIST pidl)
-{
-       CONTEXT("ShellFolder::attach(IShellFolder*, LPCITEMIDLIST)");
-
-       IShellFolder* ptr;
-
-       if (pidl && pidl->mkid.cb)
-               CHECKERROR(parent->BindToObject(pidl, 0, IID_IShellFolder, (LPVOID*)&ptr));
-       else
-               ptr = parent;
-
-       super::Attach(ptr);
-       ptr->AddRef();
-}
-
-#else // _com_ptr not available -> use SIfacePtr
-
-ShellFolder::ShellFolder()
-{
-       CONTEXT("ShellFolder::ShellFolder()");
-
-       CHECKERROR(SHGetDesktopFolder(&_p));
-
-       _p->AddRef();
-}
-
-ShellFolder::ShellFolder(IShellFolder* p)
- :     super(p)
-{
-       CONTEXT("ShellFolder::ShellFolder(IShellFolder*)");
-
-       _p->AddRef();
-}
-
-ShellFolder::ShellFolder(IShellFolder* parent, LPCITEMIDLIST pidl)
-{
-       CONTEXT("ShellFolder::ShellFolder(IShellFolder*, LPCITEMIDLIST)");
-
-       if (pidl && pidl->mkid.cb)
-               CHECKERROR(parent->BindToObject(pidl, 0, IID_IShellFolder, (LPVOID*)&_p));
-       else
-               _p = GetDesktopFolder();
-
-       _p->AddRef();
-}
-
-ShellFolder::ShellFolder(LPCITEMIDLIST pidl)
-{
-       CONTEXT("ShellFolder::ShellFolder(LPCITEMIDLIST)");
-
-       if (pidl && pidl->mkid.cb)
-               CHECKERROR(GetDesktopFolder()->BindToObject(pidl, 0, IID_IShellFolder, (LPVOID*)&_p));
-       else
-               _p = GetDesktopFolder();
-
-       _p->AddRef();
-}
-
-void ShellFolder::attach(IShellFolder* parent, LPCITEMIDLIST pidl)
-{
-       CONTEXT("ShellFolder::ShellFolder(IShellFolder*, LPCITEMIDLIST)");
-
-       IShellFolder* h = _p;
-
-       CHECKERROR(parent->BindToObject(pidl, 0, IID_IShellFolder, (LPVOID*)&_p));
-
-       _p->AddRef();
-       h->Release();
-}
-
-#endif
-
-String ShellFolder::get_name(LPCITEMIDLIST pidl, SHGDNF flags) const
-{
-       CONTEXT("ShellFolder::get_name()");
-
-       TCHAR buffer[MAX_PATH];
-       StrRet strret;
-
-       HRESULT hr = ((IShellFolder*)*const_cast<ShellFolder*>(this))->GetDisplayNameOf(pidl, flags, &strret);
-
-       if (hr == S_OK)
-               strret.GetString(pidl->mkid, buffer, COUNTOF(buffer));
-       else {
-               CHECKERROR(hr);
-               *buffer = TEXT('\0');
-       }
-
-       return buffer;
-}
-
-
-void ShellPath::split(ShellPath& parent, ShellPath& obj) const
-{
-       SHITEMID *piid, *piidLast;
-       int size = 0;
-
-        // find last item-id and calculate total size of pidl
-       for(piid=piidLast=&_p->mkid; piid->cb; ) {
-               piidLast = piid;
-               size += (piid->cb);
-               piid = (SHITEMID*)((LPBYTE)piid + (piid->cb));
-       }
-
-        // copy parent folder portion
-       size -= piidLast->cb;  // don't count "object" item-id
-
-       if (size > 0)
-               parent.assign(_p, size);
-
-        // copy "object" portion
-       obj.assign((ITEMIDLIST*)piidLast, piidLast->cb);
-}
-
-void ShellPath::GetUIObjectOf(REFIID riid, LPVOID* ppvOut, HWND hWnd, ShellFolder& sf)
-{
-       CONTEXT("ShellPath::GetUIObjectOf()");
-
-       ShellPath parent, obj;
-
-       split(parent, obj);
-
-       LPCITEMIDLIST idl = obj;
-
-       if (parent && parent->mkid.cb)
-                // use the IShellFolder of the parent
-               CHECKERROR(ShellFolder((IShellFolder*)sf,parent)->GetUIObjectOf(hWnd, 1, &idl, riid, 0, ppvOut));
-       else // else use desktop folder
-               CHECKERROR(sf->GetUIObjectOf(hWnd, 1, &idl, riid, 0, ppvOut));
-}
-
-#if 0  // ILCombine() was missing in previous versions of MinGW and is not exported from shell32.dll on Windows 2000.
-
- // convert an item id list from relative to absolute (=relative to the desktop) format
-ShellPath ShellPath::create_absolute_pidl(LPCITEMIDLIST parent_pidl) const
-{
-       CONTEXT("ShellPath::create_absolute_pidl()");
-
-       return ILCombine(parent_pidl, _p);
-
-/* seems to work only for NT upwards
-        // create a new item id list with _p append behind parent_pidl
-       int l1 = ILGetSize(parent_pidl) - sizeof(USHORT/ SHITEMID::cb /);
-       int l2 = ILGetSize(_p);
-
-       LPITEMIDLIST p = (LPITEMIDLIST) _malloc->Alloc(l1+l2);
-
-       memcpy(p, parent_pidl, l1);
-       memcpy((LPBYTE)p+l1, _p, l2);
-
-       return p;
-*/
-}
-
-#else
-
-ShellPath ShellPath::create_absolute_pidl(LPCITEMIDLIST parent_pidl) const
-{
-       CONTEXT("ShellPath::create_absolute_pidl()");
-
-       static DynamicFct<LPITEMIDLIST(WINAPI*)(LPCITEMIDLIST, LPCITEMIDLIST)> ILCombine(TEXT("SHELL32"), 25);
-
-       if (ILCombine)
-               return (*ILCombine)(parent_pidl, _p);
-
-        // create a new item id list with _p append behind parent_pidl
-       int l1 = ILGetSize(parent_pidl) - sizeof(USHORT/*SHITEMID::cb*/);
-       int l2 = ILGetSize(_p);
-
-       LPITEMIDLIST p = (LPITEMIDLIST) _malloc->Alloc(l1+l2);
-
-       memcpy(p, parent_pidl, l1);
-       memcpy((LPBYTE)p+l1, _p, l2);
-
-       return p;
-}
-
-#endif
-
- // local implementation of ILGetSize() to replace missing export on Windows 2000
-UINT ILGetSize_local(LPCITEMIDLIST pidl)
-{
-       if (!pidl)
-               return 0;
-
-       int l = sizeof(USHORT/*SHITEMID::cb*/);
-
-       while(pidl->mkid.cb) {
-               l += pidl->mkid.cb;
-               pidl = LPCITEMIDLIST((LPBYTE)pidl+pidl->mkid.cb);
-       }
-
-       return l;
-}
-
-
-#ifndef        _SHFOLDER_H_
-#define        CSIDL_FLAG_CREATE       0x8000
-#endif
-
- /// file system path of special folder
-SpecialFolderFSPath::SpecialFolderFSPath(int folder, HWND hwnd)
-{
-       _fullpath[0] = '\0';
-
-#ifdef UNICODE
-       static DynamicFct<BOOL (__stdcall*)(HWND hwnd, LPTSTR pszPath, int csidl, BOOL fCreate)> s_pSHGetSpecialFolderPath(TEXT("shell32"), "SHGetSpecialFolderPathW");
-#else
-       static DynamicFct<BOOL (__stdcall*)(HWND hwnd, LPTSTR pszPath, int csidl, BOOL fCreate)> s_pSHGetSpecialFolderPath(TEXT("shell32"), "SHGetSpecialFolderPathA");
-#endif
-       if (*s_pSHGetSpecialFolderPath)
-               (*s_pSHGetSpecialFolderPath)(hwnd, _fullpath, folder, TRUE);
-       else {
-                // SHGetSpecialFolderPath() is not compatible to WIN95/NT4
-#ifdef UNICODE
-               static DynamicFct<HRESULT (__stdcall*)(HWND hwnd, int csidl, HANDLE hToken, DWORD dwFlags, LPTSTR pszPath)> s_pSHGetFolderPath_shell32(TEXT("shell32"), "SHGetFolderPathW");
-#else
-               static DynamicFct<HRESULT (__stdcall*)(HWND hwnd, int csidl, HANDLE hToken, DWORD dwFlags, LPTSTR pszPath)> s_pSHGetFolderPath_shell32(TEXT("shell32"), "SHGetFolderPathA");
-#endif
-               if (*s_pSHGetFolderPath_shell32)
-                       (*s_pSHGetFolderPath_shell32)(hwnd, folder|CSIDL_FLAG_CREATE, 0, 0, _fullpath);
-               else {
-                        // SHGetFolderPath() is only present in shfolder.dll on some platforms.
-#ifdef UNICODE
-                       static DynamicLoadLibFct<HRESULT (__stdcall*)(HWND hwnd, int csidl, HANDLE hToken, DWORD dwFlags, LPTSTR pszPath)> s_pSHGetFolderPath_shfolder(TEXT("shfolder"), "SHGetFolderPathW");
-#else
-                       static DynamicLoadLibFct<HRESULT (__stdcall*)(HWND hwnd, int csidl, HANDLE hToken, DWORD dwFlags, LPTSTR pszPath)> s_pSHGetFolderPath_shfolder(TEXT("shfolder"), "SHGetFolderPathA");
-#endif
-                       if (*s_pSHGetFolderPath_shfolder)
-                               (*s_pSHGetFolderPath_shfolder)(hwnd, folder|CSIDL_FLAG_CREATE, 0, 0, _fullpath);
-               }
-       }
-}
-
-
-void CtxMenuInterfaces::reset()
-{
-       _pctxmenu2 = NULL;
-
-#ifndef __MINGW32__    // IContextMenu3 missing in MinGW (as of 6.2.2005)
-       _pctxmenu3 = NULL;
-#endif
-}
-
-bool CtxMenuInterfaces::HandleMenuMsg(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-#ifndef __MINGW32__    // IContextMenu3 missing in MinGW (as of 6.2.2005)
-       if (_pctxmenu3) {
-               if (SUCCEEDED(_pctxmenu3->HandleMenuMsg(nmsg, wparam, lparam)))
-                       return true;
-       }
-#endif
-
-       if (_pctxmenu2)
-               if (SUCCEEDED(_pctxmenu2->HandleMenuMsg(nmsg, wparam, lparam)))
-                       return true;
-
-       return false;
-}
-
-IContextMenu* CtxMenuInterfaces::query_interfaces(IContextMenu* pcm1)
-{
-       IContextMenu* pcm = NULL;
-
-       reset();
-
-        // Get the higher version context menu interfaces.
-#ifndef __MINGW32__    // IContextMenu3 missing in MinGW (as of 6.2.2005)
-       if (pcm1->QueryInterface(IID_IContextMenu3, (void**)&pcm) == NOERROR)
-               _pctxmenu3 = (LPCONTEXTMENU3)pcm;
-       else
-#endif
-       if (pcm1->QueryInterface(IID_IContextMenu2, (void**)&pcm) == NOERROR)
-               _pctxmenu2 = (LPCONTEXTMENU2)pcm;
-
-       if (pcm) {
-               pcm1->Release();
-               return pcm;
-       } else
-               return pcm1;
-}
-
-
-HRESULT ShellFolderContextMenu(IShellFolder* shell_folder, HWND hwndParent, int cidl,
-                                                               LPCITEMIDLIST* apidl, int x, int y, CtxMenuInterfaces& cm_ifs)
-{
-       IContextMenu* pcm;
-
-       HRESULT hr = shell_folder->GetUIObjectOf(hwndParent, cidl, apidl, IID_IContextMenu, NULL, (LPVOID*)&pcm);
-//     HRESULT hr = CDefFolderMenu_Create2(dir?dir->_pidl:DesktopFolder(), hwndParent, 1, &pidl, shell_folder, NULL, 0, NULL, &pcm);
-
-       if (SUCCEEDED(hr)) {
-               pcm = cm_ifs.query_interfaces(pcm);
-
-               HMENU hmenu = CreatePopupMenu();
-
-               if (hmenu) {
-                       hr = pcm->QueryContextMenu(hmenu, 0, FCIDM_SHVIEWFIRST, FCIDM_SHVIEWLAST, CMF_NORMAL|CMF_EXPLORE);
-
-                       if (SUCCEEDED(hr)) {
-                               UINT idCmd = TrackPopupMenu(hmenu, TPM_LEFTALIGN|TPM_RETURNCMD|TPM_RIGHTBUTTON, x, y, 0, hwndParent, NULL);
-
-                               cm_ifs.reset();
-
-                               if (idCmd) {
-                                 CMINVOKECOMMANDINFO cmi;
-
-                                 cmi.cbSize = sizeof(CMINVOKECOMMANDINFO);
-                                 cmi.fMask = 0;
-                                 cmi.hwnd = hwndParent;
-                                 cmi.lpVerb = (LPCSTR)(INT_PTR)(idCmd - FCIDM_SHVIEWFIRST);
-                                 cmi.lpParameters = NULL;
-                                 cmi.lpDirectory = NULL;
-                                 cmi.nShow = SW_SHOWNORMAL;
-                                 cmi.dwHotKey = 0;
-                                 cmi.hIcon = 0;
-
-                                 hr = pcm->InvokeCommand(&cmi);
-                               }
-                       } else
-                               cm_ifs.reset();
-               }
-
-               pcm->Release();
-       }
-
-       return hr;
-}
diff --git a/reactos/subsys/system/explorer/utility/shellclasses.dsp b/reactos/subsys/system/explorer/utility/shellclasses.dsp
deleted file mode 100644 (file)
index 7c1b30d..0000000
+++ /dev/null
@@ -1,146 +0,0 @@
-# Microsoft Developer Studio Project File - Name="shellclasses" - Package Owner=<4>\r
-# Microsoft Developer Studio Generated Build File, Format Version 6.00\r
-# ** DO NOT EDIT **\r
-\r
-# TARGTYPE "Win32 (x86) Console Application" 0x0103\r
-\r
-CFG=shellclasses - Win32 Unicode Debug\r
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,\r
-!MESSAGE use the Export Makefile command and run\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "shellclasses.mak".\r
-!MESSAGE \r
-!MESSAGE You can specify a configuration when running NMAKE\r
-!MESSAGE by defining the macro CFG on the command line. For example:\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "shellclasses.mak" CFG="shellclasses - Win32 Unicode Debug"\r
-!MESSAGE \r
-!MESSAGE Possible choices for configuration are:\r
-!MESSAGE \r
-!MESSAGE "shellclasses - Win32 Release" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "shellclasses - Win32 Debug" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "shellclasses - Win32 Unicode Debug" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "shellclasses - Win32 Unicode Release" (based on "Win32 (x86) Console Application")\r
-!MESSAGE \r
-\r
-# Begin Project\r
-# PROP AllowPerConfigDependencies 0\r
-# PROP Scc_ProjName ""\r
-# PROP Scc_LocalPath ""\r
-CPP=cl.cmd\r
-RSC=rc.exe\r
-\r
-!IF  "$(CFG)" == "shellclasses - Win32 Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "Release"\r
-# PROP BASE Intermediate_Dir "Release"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "Release"\r
-# PROP Intermediate_Dir "Release"\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c\r
-# ADD CPP /nologo /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /YX /FD /c\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.cmd\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386\r
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386\r
-\r
-!ELSEIF  "$(CFG)" == "shellclasses - Win32 Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c\r
-# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /FR /YX /FD /GZ /c\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.cmd\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
-\r
-!ELSEIF  "$(CFG)" == "shellclasses - Win32 Unicode Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "shellclasses___Win32_Unicode_Debug"\r
-# PROP BASE Intermediate_Dir "shellclasses___Win32_Unicode_Debug"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "UDebug"\r
-# PROP Intermediate_Dir "UDebug"\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /FR /YX /FD /GZ /c\r
-# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "UNICODE" /FR /YX /FD /GZ /c\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.cmd\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
-\r
-!ELSEIF  "$(CFG)" == "shellclasses - Win32 Unicode Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "shellclasses___Win32_Unicode_Release"\r
-# PROP BASE Intermediate_Dir "shellclasses___Win32_Unicode_Release"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "URelease"\r
-# PROP Intermediate_Dir "URelease"\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /YX /FD /c\r
-# ADD CPP /nologo /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "UNICODE" /YX /FD /c\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.cmd\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386\r
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386\r
-\r
-!ENDIF \r
-\r
-# Begin Target\r
-\r
-# Name "shellclasses - Win32 Release"\r
-# Name "shellclasses - Win32 Debug"\r
-# Name "shellclasses - Win32 Unicode Debug"\r
-# Name "shellclasses - Win32 Unicode Release"\r
-# Begin Source File\r
-\r
-SOURCE=.\shellclasses.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shellclasses.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\shelltests.cpp\r
-# End Source File\r
-# End Target\r
-# End Project\r
diff --git a/reactos/subsys/system/explorer/utility/shellclasses.dsw b/reactos/subsys/system/explorer/utility/shellclasses.dsw
deleted file mode 100644 (file)
index 7630200..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-Microsoft Developer Studio Workspace File, Format Version 6.00\r
-# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!\r
-\r
-###############################################################################\r
-\r
-Project: "shellclasses"=.\shellclasses.dsp - Package Owner=<4>\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<4>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
-Global:\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<3>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
diff --git a/reactos/subsys/system/explorer/utility/shellclasses.h b/reactos/subsys/system/explorer/utility/shellclasses.h
deleted file mode 100644 (file)
index 3b23981..0000000
+++ /dev/null
@@ -1,1165 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // shellclasses.h
- //
- // C++ wrapper classes for COM interfaces and shell objects
- //
- // Martin Fuchs, 20.07.2003
- //
-
-
- // windows shell headers
-#include <shellapi.h>
-#include <shlobj.h>
-
-/*@@
-#if _MSC_VER>=1300     // VS.Net
-#include <comdefsp.h>
-using namespace _com_util;
-#endif
-*/
-
-#ifndef _INC_COMUTIL   // is comutil.h of MS headers not available?
-#ifndef _NO_COMUTIL
-#define        _NO_COMUTIL
-#endif
-#endif
-
- // work around GCC's wide string constant bug when compiling inline functions
-#ifdef __GNUC__
-extern const LPCTSTR sCFSTR_SHELLIDLIST;
-#undef CFSTR_SHELLIDLIST
-#define        CFSTR_SHELLIDLIST sCFSTR_SHELLIDLIST
-#endif
-
-#ifdef _MSC_VER
-#define        NOVTABLE __declspec(novtable)
-#else
-#define        NOVTABLE
-#endif
-#define        ANSUNC
-
-
- // Exception Handling
-
-#ifndef _NO_COMUTIL
-
-#define        COMExceptionBase _com_error
-
-#else
-
- /// COM ExceptionBase class as replacement for _com_error
-struct COMExceptionBase
-{
-       COMExceptionBase(HRESULT hr)
-        :      _hr(hr)
-       {
-       }
-
-       HRESULT Error() const
-       {
-               return _hr;
-       }
-
-       LPCTSTR ErrorMessage() const
-       {
-               if (_msg.empty()) {
-                       LPTSTR pBuf;
-
-                       if (FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER|FORMAT_MESSAGE_FROM_SYSTEM,
-                               0, _hr, MAKELANGID(LANG_NEUTRAL,SUBLANG_DEFAULT), (LPTSTR)&pBuf, 0, NULL)) {
-                               _msg = pBuf;
-                               LocalFree(pBuf);
-                        } else {
-                               TCHAR buffer[128];
-                               _sntprintf(buffer, COUNTOF(buffer), TEXT("unknown Exception: 0x%08lX"), _hr);
-                               _msg = buffer;
-                        }
-               }
-
-               return _msg;
-       }
-
-protected:
-       HRESULT _hr;
-       mutable String _msg;
-};
-
-#endif
-
-
- /// Exception with context information
-
-struct COMException : public COMExceptionBase
-{
-       typedef COMExceptionBase super;
-
-       COMException(HRESULT hr)
-        :      super(hr),
-               _context(CURRENT_CONTEXT),
-               _file(NULL), _line(0)
-       {
-               LOG(toString());
-               LOG(CURRENT_CONTEXT.getStackTrace());
-       }
-
-       COMException(HRESULT hr, const char* file, int line)
-        :      super(hr),
-               _context(CURRENT_CONTEXT),
-               _file(file), _line(line)
-       {
-               LOG(toString());
-               LOG(CURRENT_CONTEXT.getStackTrace());
-       }
-
-       COMException(HRESULT hr, const String& obj)
-        :      super(hr),
-               _context(CURRENT_CONTEXT),
-               _file(NULL), _line(0)
-       {
-               LOG(toString());
-               LOG(CURRENT_CONTEXT.getStackTrace());
-       }
-
-       COMException(HRESULT hr, const String& obj, const char* file, int line)
-        :      super(hr),
-               _context(CURRENT_CONTEXT),
-               _file(file), _line(line)
-       {
-               LOG(toString());
-               LOG(CURRENT_CONTEXT.getStackTrace());
-       }
-
-       String toString() const;
-
-       Context _context;
-
-       const char* _file;
-       int _line;
-};
-
-#define        THROW_EXCEPTION(hr) throw COMException(hr, __FILE__, __LINE__)
-#define        CHECKERROR(hr) ((void)(FAILED(hr)? THROW_EXCEPTION(hr): 0))
-
-
-#ifdef _NO_COMUTIL
-
-inline void CheckError(HRESULT hr)
-{
-       if (FAILED(hr))
-               throw COMException(hr);
-}
-
-#endif
-
-
- /// COM Initialisation
-
-struct ComInit
-{
-       ComInit()
-       {
-               CHECKERROR(CoInitialize(0));
-       }
-
-#if (_WIN32_WINNT>=0x0400) || defined(_WIN32_DCOM)
-       ComInit(DWORD flag)
-       {
-               CHECKERROR(CoInitializeEx(0, flag));
-       }
-#endif
-
-       ~ComInit()
-       {
-               CoUninitialize();
-       }
-};
-
-
- /// OLE initialisation for drag drop support
-
-struct OleInit
-{
-       OleInit()
-       {
-               CHECKERROR(OleInitialize(0));
-       }
-
-       ~OleInit()
-       {
-               OleUninitialize();
-       }
-};
-
-
- /// Exception Handler for COM exceptions
-
-extern void HandleException(COMException& e, HWND hwnd);
-
-
- /// We use a common IMalloc object for all shell memory allocations.
-
-struct CommonShellMalloc
-{
-       CommonShellMalloc()
-       {
-               _p = NULL;
-       }
-
-       void init()
-       {
-               if (!_p)
-                       CHECKERROR(SHGetMalloc(&_p));
-       }
-
-       ~CommonShellMalloc()
-       {
-               if (_p)
-                       _p->Release();
-       }
-
-       operator IMalloc*()
-       {
-               return _p;
-       }
-
-       IMalloc* _p;
-};
-
-
- /// wrapper class for IMalloc with usage of common allocator
-
-struct ShellMalloc
-{
-       ShellMalloc()
-       {
-                // initialize s_cmn_shell_malloc
-               s_cmn_shell_malloc.init();
-       }
-
-       IMalloc* operator->()
-       {
-               return s_cmn_shell_malloc;
-       }
-
-       static CommonShellMalloc s_cmn_shell_malloc;
-};
-
-
- /// wrapper template class for pointers to shell objects managed by IMalloc
-
-template<typename T> struct SShellPtr
-{
-       ~SShellPtr()
-       {
-               _malloc->Free(_p);
-       }
-
-       T* operator->()
-       {
-               return _p;
-       }
-
-       T const* operator->() const
-       {
-               return _p;
-       }
-
-       operator T const *() const
-       {
-               return _p;
-       }
-
-       const T& operator*() const
-       {
-               return *_p;
-       }
-
-       T& operator*()
-       {
-               return *_p;
-       }
-
-protected:
-       SShellPtr()
-        :      _p(0)
-       {
-       }
-
-       SShellPtr(T* p)
-        :      _p(p)
-       {
-       }
-
-       void Free()
-       {
-               _malloc->Free(_p);
-               _p = NULL;
-       }
-
-       T* _p;
-       mutable ShellMalloc _malloc;    // IMalloc memory management object
-
-private:
-        // disallow copying of SShellPtr objects
-       SShellPtr(const SShellPtr&) {}
-       void operator=(SShellPtr const&) {}
-};
-
-
- /// wrapper class for COM interface pointers
-
-template<typename T> struct SIfacePtr
-{
-       SIfacePtr()
-        :      _p(0)
-       {
-       }
-
-       SIfacePtr(T* p)
-        :      _p(p)
-       {
-               if (p)
-                       p->AddRef();
-       }
-
-       SIfacePtr(IUnknown* unknown, REFIID riid)
-       {
-               CHECKERROR(unknown->QueryInterface(riid, (LPVOID*)&_p));
-       }
-
-       ~SIfacePtr()
-       {
-               Free();
-       }
-
-       T* operator->()
-       {
-               return _p;
-       }
-
-       const T* operator->() const
-       {
-               return _p;
-       }
-
-/* not GCC compatible
-       operator const T*() const
-       {
-               return _p;
-       } */
-
-       operator T*()
-       {
-               return _p;
-       }
-
-       T** operator&()
-       {
-               return &_p;
-       }
-
-       bool empty() const      //NOTE: GCC seems not to work correctly when defining operator bool() AND operator T*() at one time
-       {
-               return !_p;
-       }
-
-       SIfacePtr& operator=(T* p)
-       {
-               Free();
-
-               if (p) {
-                       p->AddRef();
-                       _p = p;
-               }
-
-               return *this;
-       }
-
-       void operator=(SIfacePtr const& o)
-       {
-               T* h = _p;
-
-               if (o._p)
-                       o._p->AddRef();
-
-               _p = o._p;
-
-               if (h)
-                       h->Release();
-       }
-
-       HRESULT CreateInstance(REFIID clsid, REFIID riid)
-       {
-               return CoCreateInstance(clsid, NULL, CLSCTX_INPROC_SERVER, riid, (LPVOID*)&_p);
-       }
-
-       template<typename I> HRESULT QueryInterface(REFIID riid, I* p)
-       {
-               return _p->QueryInterface(riid, (LPVOID*)p);
-       }
-
-       T* get()
-       {
-               return _p;
-       }
-
-       void Free()
-       {
-               T* h = _p;
-               _p = NULL;
-
-               if (h)
-                       h->Release();
-       }
-
-protected:
-       SIfacePtr(const SIfacePtr& o)
-        :      _p(o._p)
-       {
-               if (_p)
-                       _p->AddRef();
-       }
-
-       T* _p;
-};
-
-
-struct NOVTABLE ComSrvObject   // NOVTABLE erlaubt, da protected Destruktor
-{
-protected:
-       ComSrvObject() : _ref(1) {}
-       virtual ~ComSrvObject() {}
-
-       ULONG   _ref;
-};
-
-struct SimpleComObject : public ComSrvObject
-{
-       ULONG IncRef() {return ++_ref;}
-       ULONG DecRef() {ULONG ref=--_ref; if (!ref) {_ref++; delete this;} return ref;}
-};
-
-
- // server object interfaces
-
-template<typename BASE> struct IComSrvQI : public BASE
-{
-       IComSrvQI(REFIID uuid_base)
-        :      _uuid_base(uuid_base)
-       {
-       }
-
-       STDMETHODIMP QueryInterface(REFIID riid, LPVOID* ppv)
-       {
-               *ppv = NULL;
-
-               if (IsEqualIID(riid, _uuid_base) || IsEqualIID(riid, IID_IUnknown))
-                       {*ppv=static_cast<BASE*>(this); this->AddRef(); return S_OK;}
-
-               return E_NOINTERFACE;
-       }
-
-protected:
-       IComSrvQI() {}
-       virtual ~IComSrvQI() {}
-
-       REFIID  _uuid_base;
-};
-
-template<> struct IComSrvQI<IUnknown> : public IUnknown
-{
-       STDMETHODIMP QueryInterface(REFIID riid, LPVOID* ppv)
-       {
-               *ppv = NULL;
-
-               if (IsEqualIID(riid, IID_IUnknown))
-                       {*ppv=this; AddRef(); return S_OK;}
-
-               return E_NOINTERFACE;
-       }
-
-protected:
-       IComSrvQI<IUnknown>() {}
-       virtual ~IComSrvQI<IUnknown>() {}
-};
-
-
-template<typename BASE, typename OBJ>
-       class IComSrvBase : public IComSrvQI<BASE>
-{
-       typedef IComSrvQI<BASE> super;
-
-protected:
-       IComSrvBase(REFIID uuid_base)
-        :      super(uuid_base)
-       {
-       }
-
-public:
-       STDMETHODIMP_(ULONG) AddRef() {return static_cast<OBJ*>(this)->IncRef();}
-       STDMETHODIMP_(ULONG) Release() {return static_cast<OBJ*>(this)->DecRef();}
-};
-
-
-
-struct ShellFolder;
-
-
- /// caching of desktop ShellFolder object
-
-struct CommonDesktop
-{
-       CommonDesktop()
-       {
-               _desktop = 0;
-       }
-
-       ~CommonDesktop();
-
-       void init();
-
-       operator ShellFolder&()
-       {
-               return *_desktop;
-       }
-
-protected:
-       ShellFolder* _desktop;
-};
-
-
-#ifndef _NO_COMUTIL    // _com_ptr available?
-
- /// IShellFolder smart pointer
-struct ShellFolder : public IShellFolderPtr    // IShellFolderPtr uses intrinsic extensions of the VC++ compiler.
-{
-       typedef IShellFolderPtr super;
-
-       ShellFolder();  // desktop folder
-       ShellFolder(IShellFolder* p);
-       ShellFolder(IShellFolder* parent, LPCITEMIDLIST pidl);
-       ShellFolder(LPCITEMIDLIST pidl);
-
-       void    attach(IShellFolder* parent, LPCITEMIDLIST pidl);
-       String  get_name(LPCITEMIDLIST pidl=NULL, SHGDNF flags=SHGDN_NORMAL) const;
-
-       bool    empty() const {return !operator bool();}        //NOTE: see SIfacePtr::empty()
-};
-
-#ifdef UNICODE
-#define        IShellLinkPtr IShellLinkWPtr
-#else
-#define        IShellLinkPtr IShellLinkAPtr
-#endif
-
- /// IShellLink smart pointer
-struct ShellLinkPtr : public IShellLinkPtr
-{
-       typedef IShellLinkPtr super;
-
-       ShellLinkPtr(IShellLink* p)
-        :      super(p)
-       {
-               p->AddRef();
-       }
-
-       bool    empty() const {return !operator bool();}        //NOTE: see SIfacePtr::empty()
-};
-
-#else // _com_ptr not available -> use SIfacePtr
-
- /// IShellFolder smart pointer
-struct ShellFolder : public SIfacePtr<IShellFolder>
-{
-       typedef SIfacePtr<IShellFolder> super;
-
-       ShellFolder();
-       ShellFolder(IShellFolder* p);
-       ShellFolder(IShellFolder* parent, LPCITEMIDLIST pidl);
-       ShellFolder(LPCITEMIDLIST pidl);
-
-       void    attach(IShellFolder* parent, LPCITEMIDLIST pidl);
-       String  get_name(LPCITEMIDLIST pidl, SHGDNF flags=SHGDN_NORMAL) const;
-};
-
- /// IShellLink smart pointer
-struct ShellLinkPtr : public SIfacePtr<IShellLink>
-{
-       typedef SIfacePtr<IShellLink> super;
-
-       ShellLinkPtr(IShellLink* p)
-        :      super(p)
-       {
-               _p->AddRef();
-       }
-
-};
-
-#endif
-
-
-extern ShellFolder& GetDesktopFolder();
-
-
-#ifdef UNICODE
-#define        path_from_pidl path_from_pidlW
-#else
-#define        path_from_pidl path_from_pidlA
-#endif
-
-extern HRESULT path_from_pidlA(IShellFolder* folder, LPCITEMIDLIST pidl, LPSTR buffer, int len);
-extern HRESULT path_from_pidlW(IShellFolder* folder, LPCITEMIDLIST pidl, LPWSTR buffer, int len);
-extern HRESULT name_from_pidl(IShellFolder* folder, LPCITEMIDLIST pidl, LPTSTR buffer, int len, SHGDNF flags);
-
-
- // ILGetSize() was missing in previous versions of MinGW and is not exported from shell32.dll on Windows 2000.
-extern "C" UINT ILGetSize_local(LPCITEMIDLIST pidl);
-#define ILGetSize ILGetSize_local
-
-#if 0
-#ifdef UNICODE         // CFSTR_FILENAME was defined wrong in previous versions of MinGW.
-#define CFSTR_FILENAMEW TEXT("FileNameW")
-#undef CFSTR_FILENAME
-#define CFSTR_FILENAME CFSTR_FILENAMEW
-#endif
-#endif
-
-
- /// wrapper class for item ID lists
-
-struct ShellPath : public SShellPtr<ITEMIDLIST>
-{
-       typedef SShellPtr<ITEMIDLIST> super;
-
-       ShellPath()
-       {
-       }
-
-       ShellPath(IShellFolder* folder, LPCWSTR path)
-       {
-               CONTEXT("ShellPath::ShellPath(IShellFolder*, LPCWSTR)");
-
-               if (path)
-                       CHECKERROR(folder->ParseDisplayName(0, NULL, (LPOLESTR)path, NULL, &_p, NULL));
-               else
-                       _p = NULL;
-       }
-
-       ShellPath(LPCWSTR path)
-       {
-               OBJ_CONTEXT("ShellPath::ShellPath(LPCWSTR)", path);
-
-               if (path)
-                       CHECKERROR(GetDesktopFolder()->ParseDisplayName(0, NULL, (LPOLESTR)path, NULL, &_p, NULL));
-               else
-                       _p = NULL;
-       }
-
-       ShellPath(IShellFolder* folder, LPCSTR path)
-       {
-               CONTEXT("ShellPath::ShellPath(IShellFolder*, LPCSTR)");
-
-               WCHAR b[MAX_PATH];
-
-               if (path) {
-                       MultiByteToWideChar(CP_ACP, 0, path, -1, b, COUNTOF(b));
-                       CHECKERROR(folder->ParseDisplayName(0, NULL, b, NULL, &_p, NULL));
-               } else
-                       _p = NULL;
-       }
-
-       ShellPath(LPCSTR path)
-       {
-               CONTEXT("ShellPath::ShellPath(LPCSTR)");
-
-               WCHAR b[MAX_PATH];
-
-               if (path) {
-                       MultiByteToWideChar(CP_ACP, 0, path, -1, b, COUNTOF(b));
-                       CHECKERROR(GetDesktopFolder()->ParseDisplayName(0, NULL, b, NULL, &_p, NULL));
-               } else
-                       _p = NULL;
-       }
-
-       ShellPath(const ShellPath& o)
-        :      super(NULL)
-       {
-               //CONTEXT("ShellPath::ShellPath(const ShellPath&)");
-
-               if (o._p) {
-                       int l = ILGetSize(o._p);
-                       _p = (ITEMIDLIST*) _malloc->Alloc(l);
-                       if (_p) memcpy(_p, o._p, l);
-               }
-       }
-
-       explicit ShellPath(LPITEMIDLIST p)
-        :      super(p)
-       {
-       }
-
-       ShellPath(LPCITEMIDLIST p)
-       {
-               //CONTEXT("ShellPath::ShellPath(LPCITEMIDLIST)");
-
-               if (p) {
-                       int l = ILGetSize(p);
-                       _p = (ITEMIDLIST*) _malloc->Alloc(l);
-                       if (_p) memcpy(_p, p, l);
-               }
-       }
-
-       void operator=(const ShellPath& o)
-       {
-               //CONTEXT("ShellPath::operator=(const ShellPath&)");
-
-               ITEMIDLIST* h = _p;
-
-               if (o._p) {
-                       int l = ILGetSize(o._p);
-
-                       _p = (ITEMIDLIST*) _malloc->Alloc(l);
-                       if (_p) memcpy(_p, o._p, l);
-               }
-               else
-                       _p = NULL;
-
-               _malloc->Free(h);
-       }
-
-       void operator=(ITEMIDLIST* p)
-       {
-               //CONTEXT("ShellPath::operator=(ITEMIDLIST*)");
-
-               ITEMIDLIST* h = _p;
-
-               if (p) {
-                       int l = ILGetSize(p);
-                       _p = (ITEMIDLIST*) _malloc->Alloc(l);
-                       if (_p) memcpy(_p, p, l);
-               }
-               else
-                       _p = NULL;
-
-               _malloc->Free(h);
-       }
-
-       void operator=(const SHITEMID& o)
-       {
-               ITEMIDLIST* h = _p;
-
-               LPBYTE p = (LPBYTE)_malloc->Alloc(o.cb+2);
-               if (p) *(PWORD)((LPBYTE)memcpy(p, &o, o.cb)+o.cb) = 0;
-               _p = (ITEMIDLIST*)p;
-
-               _malloc->Free(h);
-       }
-
-       void operator+=(const SHITEMID& o)
-       {
-               int l0 = ILGetSize(_p);
-               LPBYTE p = (LPBYTE)_malloc->Alloc(l0+o.cb);
-               int l = l0 - 2;
-
-               if (p) {
-                       memcpy(p, _p, l);
-                       *(PWORD)((LPBYTE)memcpy(p+l, &o, o.cb)+o.cb) = 0;
-               }
-
-               _malloc->Free(_p);
-               _p = (ITEMIDLIST*)p;
-       }
-
-       void assign(LPCITEMIDLIST pidl, size_t size)
-       {
-               //CONTEXT("ShellPath::assign(LPCITEMIDLIST, size_t)");
-
-               ITEMIDLIST* h = _p;
-
-               _p = (ITEMIDLIST*) _malloc->Alloc(size+sizeof(USHORT/*SHITEMID::cb*/));
-
-               if (_p) {
-                       memcpy(_p, pidl, size);
-                       ((ITEMIDLIST*)((LPBYTE)_p+size))->mkid.cb = 0; // terminator
-               }
-
-               _malloc->Free(h);
-       }
-
-       void assign(LPCITEMIDLIST pidl)
-       {
-               //CONTEXT("ShellPath::assign(LPCITEMIDLIST)");
-
-               ITEMIDLIST* h = _p;
-
-               if (pidl) {
-                       int l = ILGetSize(pidl);
-                       _p = (ITEMIDLIST*) _malloc->Alloc(l);
-                       if (_p) memcpy(_p, pidl, l);
-               } else
-                       _p = NULL;
-
-               _malloc->Free(h);
-       }
-
-       void split(ShellPath& parent, ShellPath& obj) const;
-
-       void GetUIObjectOf(REFIID riid, LPVOID* ppvOut, HWND hWnd=0, ShellFolder& sf=GetDesktopFolder());
-
-       ShellFolder get_folder()
-       {
-               return ShellFolder(_p);
-       }
-
-       ShellFolder get_folder(IShellFolder* parent)
-       {
-               CONTEXT("ShellPath::get_folder()");
-               return ShellFolder(parent, _p);
-       }
-
-        // convert an item id list from relative to absolute (=relative to the desktop) format
-       ShellPath create_absolute_pidl(LPCITEMIDLIST parent_pidl) const;
-};
-
-
-#if defined(__WINE__) && defined(NONAMELESSUNION)      // Wine doesn't know of unnamed union members and uses some macros instead.
-#define        UNION_MEMBER(x) DUMMYUNIONNAME.##x
-#else
-#define        UNION_MEMBER(x) x
-#endif
-
-
- // encapsulation of STRRET structure for easy string retrieval with conversion
-
-#ifdef UNICODE
-#define        StrRet StrRetW
-//#define      tcscpyn wcscpyn
-#else
-#define        StrRet StrRetA
-//#define      tcscpyn strcpyn
-#endif
-
-//extern LPSTR strcpyn(LPSTR dest, LPCSTR source, size_t count);
-//extern LPWSTR wcscpyn(LPWSTR dest, LPCWSTR source, size_t count);
-
- /// easy retrieval of multi byte strings out of STRRET structures
-struct StrRetA : public STRRET
-{
-       ~StrRetA()
-       {
-               if (uType == STRRET_WSTR)
-                       ShellMalloc()->Free(pOleStr);
-       }
-
-       void GetString(const SHITEMID& shiid, LPSTR b, int l)
-       {
-               switch(uType) {
-                 case STRRET_WSTR:
-                       WideCharToMultiByte(CP_ACP, 0, UNION_MEMBER(pOleStr), -1, b, l, NULL, NULL);
-                       break;
-
-                 case STRRET_OFFSET:
-                       lstrcpynA(b, (LPCSTR)&shiid+UNION_MEMBER(uOffset), l);
-                       break;
-
-                 case STRRET_CSTR:
-                       lstrcpynA(b, UNION_MEMBER(cStr), l);
-               }
-       }
-};
-
- /// easy retrieval of wide char strings out of STRRET structures
-struct StrRetW : public STRRET
-{
-       ~StrRetW()
-       {
-               if (uType == STRRET_WSTR)
-                       ShellMalloc()->Free(pOleStr);
-       }
-
-       void GetString(const SHITEMID& shiid, LPWSTR b, int l)
-       {
-               switch(uType) {
-                 case STRRET_WSTR:
-                       lstrcpynW(b, UNION_MEMBER(pOleStr), l);
-                       break;
-
-                 case STRRET_OFFSET:
-                       MultiByteToWideChar(CP_ACP, 0, (LPCSTR)&shiid+UNION_MEMBER(uOffset), -1, b, l);
-                       break;
-
-                 case STRRET_CSTR:
-                       MultiByteToWideChar(CP_ACP, 0, UNION_MEMBER(cStr), -1, b, l);
-               }
-       }
-};
-
-
- /// Retrieval of file system paths of ShellPath objects
-class FileSysShellPath : public ShellPath
-{
-       TCHAR   _fullpath[MAX_PATH];
-
-protected:
-       FileSysShellPath() {_fullpath[0] = '\0';}
-
-public:
-       FileSysShellPath(const ShellPath& o) : ShellPath(o) {_fullpath[0] = '\0';}
-
-       operator LPCTSTR() {if (!SHGetPathFromIDList(_p, _fullpath)) return NULL; return _fullpath;}
-};
-
-
- /// Browse dialog operating on shell namespace
-struct FolderBrowser : public FileSysShellPath
-{
-       FolderBrowser(HWND owner, UINT flags, LPCTSTR title, LPCITEMIDLIST root=0)
-       {
-               _displayname[0] = '\0';
-               _browseinfo.hwndOwner = owner;
-               _browseinfo.pidlRoot = root;
-               _browseinfo.pszDisplayName = _displayname;
-               _browseinfo.lpszTitle = title;
-               _browseinfo.ulFlags = flags;
-               _browseinfo.lpfn = 0;
-               _browseinfo.lParam = 0;
-               _browseinfo.iImage = 0;
-
-               _p = SHBrowseForFolder(&_browseinfo);
-       }
-
-       LPCTSTR GetDisplayName()
-       {
-               return _displayname;
-       }
-
-       bool IsOK()
-       {
-               return _p != 0;
-       }
-
-private:
-       BROWSEINFO _browseinfo;
-       TCHAR   _displayname[MAX_PATH];
-};
-
-
- /// Retrieval of special shell folder paths
-struct SpecialFolderPath : public ShellPath
-{
-       SpecialFolderPath(int folder, HWND hwnd)
-       {
-               HRESULT hr = SHGetSpecialFolderLocation(hwnd, folder, &_p);
-               CHECKERROR(hr);
-       }
-};
-
- /// Shell folder path of the desktop
-struct DesktopFolderPath : public SpecialFolderPath
-{
-       DesktopFolderPath()
-        :      SpecialFolderPath(CSIDL_DESKTOP, 0)
-       {
-       }
-};
-
- /// Retrieval of special shell folder
-struct SpecialFolder : public ShellFolder
-{
-       SpecialFolder(int folder, HWND hwnd)
-        :      ShellFolder(GetDesktopFolder(), SpecialFolderPath(folder, hwnd))
-       {
-       }
-};
-
- /// Shell folder of the desktop
-struct DesktopFolder : public ShellFolder
-{
-};
-
-
- /// file system path of special folder
-struct SpecialFolderFSPath
-{
-       SpecialFolderFSPath(int folder/*e.g. CSIDL_DESKTOP*/, HWND hwnd);
-
-       operator LPCTSTR()
-       {
-               return _fullpath;
-       }
-
-protected:
-       TCHAR   _fullpath[MAX_PATH];
-};
-
-/*
- /// file system path of special folder
-struct SpecialFolderFSPath : public FileSysShellPath
-{
-       SpecialFolderFSPath(int folder, HWND hwnd)
-       {
-               CONTEXT("SpecialFolderFSPath::SpecialFolderFSPath()");
-
-               HRESULT hr = SHGetSpecialFolderLocation(hwnd, folder, &_p);
-               CHECKERROR(hr);
-       }
-};
-*/
-
-
- /// wrapper class for enumerating shell namespace objects
-
-struct ShellItemEnumerator : public SIfacePtr<IEnumIDList>
-{
-       ShellItemEnumerator(IShellFolder* folder, DWORD flags=SHCONTF_FOLDERS|SHCONTF_NONFOLDERS|SHCONTF_INCLUDEHIDDEN)
-       {
-               CONTEXT("ShellItemEnumerator::ShellItemEnumerator()");
-
-               CHECKERROR(folder->EnumObjects(0, flags, &_p));
-       }
-};
-
-
- /// list of PIDLs
-struct PIDList
-{
-       PIDList()
-       {
-               memset(&_stgm, 0, sizeof(STGMEDIUM));
-       }
-
-       ~PIDList()
-       {
-               if (_stgm.hGlobal) {
-                       GlobalUnlock(_stgm.hGlobal);
-                       ReleaseStgMedium(&_stgm);
-               }
-       }
-
-       HRESULT GetData(IDataObject* selection)
-       {
-               static UINT CF_IDLIST = RegisterClipboardFormat(CFSTR_SHELLIDLIST);
-
-               FORMATETC fetc;
-               fetc.cfFormat = CF_IDLIST;
-               fetc.ptd = NULL;
-               fetc.dwAspect = DVASPECT_CONTENT;
-               fetc.lindex = -1;
-               fetc.tymed = TYMED_HGLOBAL;
-
-               HRESULT hr = selection->QueryGetData(&fetc);
-               if (FAILED(hr))
-                       return hr;
-
-               hr = selection->GetData(&fetc, &_stgm);
-               if (FAILED(hr))
-                       return hr;
-
-               _pIDList = (LPIDA)GlobalLock(_stgm.hGlobal);
-
-               return hr;
-       }
-
-       operator LPIDA() {return _pIDList;}
-
-protected:
-       STGMEDIUM _stgm;
-       LPIDA _pIDList;
-};
-
-
-struct CtxMenuInterfaces
-{
-       CtxMenuInterfaces()
-       {
-               reset();
-       }
-
-       void    reset();
-       bool    HandleMenuMsg(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       IContextMenu* query_interfaces(IContextMenu* pcm1);
-
-       IContextMenu2*  _pctxmenu2;
-
-#ifndef __MINGW32__    // IContextMenu3 missing in MinGW (as of 6.2.2005)
-       IContextMenu3*  _pctxmenu3;
-#endif
-};
-
-template<typename BASE> struct ExtContextMenuHandlerT
- : public BASE
-{
-       typedef BASE super;
-
-       ExtContextMenuHandlerT(HWND hwnd)
-        :      super(hwnd)
-       {
-       }
-
-       template<typename PARA> ExtContextMenuHandlerT(HWND hwnd, const PARA& info)
-        :      super(hwnd, info)
-       {
-       }
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               switch(nmsg) {
-                 case WM_DRAWITEM:
-                 case WM_MEASUREITEM:
-                       if (!wparam)    // Is the message menu-related?
-                               if (_cm_ifs.HandleMenuMsg(nmsg, wparam, lparam))
-                                       return TRUE;
-
-                       break;
-
-                 case WM_INITMENUPOPUP:
-                       if (_cm_ifs.HandleMenuMsg(nmsg, wparam, lparam))
-                               return 0;
-
-                       break;
-
-#ifndef __MINGW32__    // IContextMenu3 missing in MinGW (as of 6.2.2005)
-                 case WM_MENUCHAR:     // only supported by IContextMenu3
-                  if (_cm_ifs._pctxmenu3) {
-                          LRESULT lResult = 0;
-
-                          _cm_ifs._pctxmenu3->HandleMenuMsg2(nmsg, wparam, lparam, &lResult);
-
-                          return lResult;
-                  }
-
-                  return 0;
-#endif
-               }
-
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-protected:
-       CtxMenuInterfaces _cm_ifs;
-};
-
-
-extern HRESULT ShellFolderContextMenu(IShellFolder* shell_folder, HWND hwndParent, int cidl,
-                                                                               LPCITEMIDLIST* ppidl, int x, int y, CtxMenuInterfaces& cm_ifs);
diff --git a/reactos/subsys/system/explorer/utility/shelltests.cpp b/reactos/subsys/system/explorer/utility/shelltests.cpp
deleted file mode 100644 (file)
index 4984b6c..0000000
+++ /dev/null
@@ -1,140 +0,0 @@
-/*
- * Copyright 2003 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- // 
- // shelltests.cpp
- //
- // Examples for usage of shellclasses.cpp, shellclasses.h
- //
- // Martin Fuchs, 20.07.2003
- //
-
-
-//#define WIN32_LEAN_AND_MEAN
-//#define WIN32_EXTRA_LEAN
-//#include <windows.h>
-
-#include "utility.h" // for String
-#include "shellclasses.h"
-
-
-static void dump_shell_namespace(ShellFolder& folder)
-{
-       ShellItemEnumerator enumerator(folder, SHCONTF_FOLDERS|SHCONTF_NONFOLDERS|SHCONTF_INCLUDEHIDDEN|SHCONTF_SHAREABLE|SHCONTF_STORAGE);
-
-       LPITEMIDLIST pidl;
-       HRESULT hr = S_OK;
-
-       do {
-               ULONG cnt = 0;
-
-               HRESULT hr = enumerator->Next(1, &pidl, &cnt);
-
-               if (!SUCCEEDED(hr))
-                       break;
-
-               if (hr == S_FALSE)      // no more entries?
-                       break;
-
-                if (pidl) {
-                       ULONG attribs = -1;
-
-                       HRESULT hr = folder->GetAttributesOf(1, (LPCITEMIDLIST*)&pidl, &attribs);
-
-                       if (SUCCEEDED(hr)) {
-                               if (attribs == -1)
-                                       attribs = 0;
-
-                               const String& name = folder.get_name(pidl);
-
-                               if (attribs & (SFGAO_FOLDER|SFGAO_HASSUBFOLDER))
-                                       cout << "folder: ";
-                                else
-                                       cout << "file: ";
-
-                               cout << "\"" << name << "\"\n attribs=" << hex << attribs << endl;
-                       }
-               }
-       } while(SUCCEEDED(hr));
-}
-
-
-int main()
-{
-        // initialize COM
-       ComInit usingCOM;
-
-
-       HWND hwnd = 0;
-
-
-       try {
-
-                // example for retrieval of special folder paths
-
-               SpecialFolderFSPath programs(CSIDL_PROGRAM_FILES, hwnd);
-               SpecialFolderFSPath autostart(CSIDL_STARTUP, hwnd);
-
-               cout << "program files path = " << (LPCTSTR)programs << endl;
-               cout << "autostart folder path = " << (LPCTSTR)autostart << endl;
-
-               cout << endl;
-
-
-                // example for enumerating shell namespace objects
-
-               cout << "Desktop:\n";
-               dump_shell_namespace(GetDesktopFolder());
-               cout << endl;
-
-               cout << "C:\\\n";
-               dump_shell_namespace(ShellPath("C:\\").get_folder());
-               cout << endl;
-
-
-                // example for calling a browser dialog for the whole desktop
-
-               FolderBrowser desktop_browser(hwnd,
-                                                                         BIF_RETURNONLYFSDIRS|BIF_EDITBOX|BIF_NEWDIALOGSTYLE,
-                                                                         TEXT("Please select the path:"));
-
-               if (desktop_browser.IsOK())
-                       MessageBox(hwnd, desktop_browser, TEXT("Your selected path"), MB_OK);
-
-
-                // example for calling a rooted browser dialog
-
-               ShellPath browseRoot("C:\\");
-               FolderBrowser rooted_browser(hwnd,
-                                                                        BIF_RETURNONLYFSDIRS|BIF_EDITBOX|BIF_VALIDATE,
-                                                                        TEXT("Please select the path:"),
-                                                                        browseRoot);
-
-               if (rooted_browser.IsOK())
-                       MessageBox(hwnd, rooted_browser, TEXT("Your selected path"), MB_OK);
-
-       } catch(COMException& e) {
-
-               //HandleException(e, hwnd);
-               cerr << e.ErrorMessage() << endl;
-
-       }
-
-       return 0;
-}
diff --git a/reactos/subsys/system/explorer/utility/splitpath.c b/reactos/subsys/system/explorer/utility/splitpath.c
deleted file mode 100644 (file)
index 157bed4..0000000
+++ /dev/null
@@ -1,151 +0,0 @@
-/*
- * Copyright 2000 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-#include "utility.h"
-
-#ifdef UNICODE
-
-void _wsplitpath(const WCHAR* path, WCHAR* drv, WCHAR* dir, WCHAR* name, WCHAR* ext)
-{
-        const WCHAR* end; /* end of processed string */
-       const WCHAR* p;   /* search pointer */
-       const WCHAR* s;   /* copy pointer */
-
-       /* extract drive name */
-       if (path[0] && path[1]==':') {
-               if (drv) {
-                       *drv++ = *path++;
-                       *drv++ = *path++;
-                       *drv = L'\0';
-               }
-       } else if (drv)
-               *drv = L'\0';
-
-       /* search for end of string or stream separator */
-       for(end=path; *end && *end!=L':'; )
-               end++;
-
-       /* search for begin of file extension */
-       for(p=end; p>path && *--p!=L'\\' && *p!=L'/'; )
-               if (*p == L'.') {
-                       end = p;
-                       break;
-               }
-
-       if (ext)
-               for(s=end; *ext=*s++; )
-                       ext++;
-
-       /* search for end of directory name */
-       for(p=end; p>path; )
-               if (*--p=='\\' || *p=='/') {
-                       p++;
-                       break;
-               }
-
-       if (name) {
-               for(s=p; s<end; )
-                       *name++ = *s++;
-
-               *name = L'\0';
-       }
-
-       if (dir) {
-               for(s=path; s<p; )
-                       *dir++ = *s++;
-
-               *dir = L'\0';
-       }
-}
-
-#else
-
-void _splitpath(const CHAR* path, CHAR* drv, CHAR* dir, CHAR* name, CHAR* ext)
-{
-        const CHAR* end; /* end of processed string */
-       const CHAR* p;   /* search pointer */
-       const CHAR* s;   /* copy pointer */
-
-       /* extract drive name */
-       if (path[0] && path[1]==':') {
-               if (drv) {
-                       *drv++ = *path++;
-                       *drv++ = *path++;
-                       *drv = '\0';
-               }
-       } else if (drv)
-               *drv = '\0';
-
-       /* search for end of string or stream separator */
-       for(end=path; *end && *end!=':'; )
-               end++;
-
-       /* search for begin of file extension */
-       for(p=end; p>path && *--p!='\\' && *p!='/'; )
-               if (*p == '.') {
-                       end = p;
-                       break;
-               }
-
-       if (ext)
-               for(s=end; (*ext=*s++); )
-                       ext++;
-
-       /* search for end of directory name */
-       for(p=end; p>path; )
-               if (*--p=='\\' || *p=='/') {
-                       p++;
-                       break;
-               }
-
-       if (name) {
-               for(s=p; s<end; )
-                       *name++ = *s++;
-
-               *name = '\0';
-       }
-
-       if (dir) {
-               for(s=path; s<p; )
-                       *dir++ = *s++;
-
-               *dir = '\0';
-       }
-}
-
-#endif
-
-/*
-void main()    // test splipath()
-{
-       TCHAR drv[_MAX_DRIVE+1], dir[_MAX_DIR], name[_MAX_FNAME], ext[_MAX_EXT];
-
-       _tsplitpath(L"x\\y", drv, dir, name, ext);
-       _tsplitpath(L"x\\", drv, dir, name, ext);
-       _tsplitpath(L"\\x", drv, dir, name, ext);
-       _tsplitpath(L"x", drv, dir, name, ext);
-       _tsplitpath(L"", drv, dir, name, ext);
-       _tsplitpath(L".x", drv, dir, name, ext);
-       _tsplitpath(L":x", drv, dir, name, ext);
-       _tsplitpath(L"a:x", drv, dir, name, ext);
-       _tsplitpath(L"a.b:x", drv, dir, name, ext);
-       _tsplitpath(L"W:\\/\\abc/Z:~", drv, dir, name, ext);
-       _tsplitpath(L"abc.EFGH:12345", drv, dir, name, ext);
-       _tsplitpath(L"C:/dos/command.com", drv, dir, name, ext);
-}
-*/
diff --git a/reactos/subsys/system/explorer/utility/treedroptarget.h b/reactos/subsys/system/explorer/utility/treedroptarget.h
deleted file mode 100644 (file)
index 2e263ee..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-/**************************************************************************
-   THIS CODE AND INFORMATION IS PROVIDED 'AS IS' WITHOUT WARRANTY OF
-   ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO
-   THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
-   PARTICULAR PURPOSE.
-   Author: Leon Finker  01/2001
-   Modifications: removed ATL dependencies, Martin Fuchs 7/2003
-**************************************************************************/
-
-#include "dragdropimpl.h"
-
- /// OLE drop target for tree controls
-class TreeDropTarget : public IDropTargetImpl
-{
-public:
-       TreeDropTarget(HWND hTargetWnd) : IDropTargetImpl(hTargetWnd) {}
-
-       virtual bool OnDrop(FORMATETC* pFmtEtc, STGMEDIUM& medium, DWORD *pdwEffect)
-       {
-               if (pFmtEtc->cfFormat == CF_HDROP && medium.tymed == TYMED_HGLOBAL)
-               {
-                       HDROP hDrop = (HDROP)GlobalLock(medium.hGlobal);
-                       if (hDrop != NULL)
-                       {
-                               TCHAR szFileName[MAX_PATH];
-
-                               UINT cFiles = DragQueryFile(hDrop, 0xFFFFFFFF, NULL, 0);
-
-                               for(UINT i = 0; i < cFiles; ++i)
-                               {
-                                       DragQueryFile(hDrop, i, szFileName, sizeof(szFileName));
-
-                                       if (DROPEFFECT_COPY & *pdwEffect)
-                                       {
-                                                // copy the file or dir
-
-                                               ///@todo Add the code to handle Copy
-
-                                       }
-                                       else if (DROPEFFECT_MOVE & *pdwEffect)
-                                       {
-                                                // move the file or dir
-
-                                               ///@todo Add the code to handle Move
-
-                                       }
-                               }
-                               //DragFinish(hDrop); // base class calls ReleaseStgMedium
-                       }
-                       GlobalUnlock(medium.hGlobal);
-               }
-
-               TreeView_SelectDropTarget(m_hTargetWnd, NULL);
-
-               return true; //let base free the medium
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE DragOver(
-        /* [in] */ DWORD grfKeyState,
-        /* [in] */ POINTL pt,
-        /* [out][in] */ DWORD __RPC_FAR *pdwEffect)
-       {
-               TVHITTESTINFO hit;
-               hit.pt = (POINT&)pt;
-               ScreenToClient(m_hTargetWnd, &hit.pt);
-               hit.flags = TVHT_ONITEM;
-               HTREEITEM hItem = TreeView_HitTest(m_hTargetWnd,&hit);
-
-               if (hItem != NULL)
-                       TreeView_SelectDropTarget(m_hTargetWnd, hItem);
-
-               return IDropTargetImpl::DragOver(grfKeyState, pt, pdwEffect);
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE DragLeave(void)
-       {
-               TreeView_SelectDropTarget(m_hTargetWnd, NULL);
-
-               return IDropTargetImpl::DragLeave();
-       }
-};
diff --git a/reactos/subsys/system/explorer/utility/utility.cpp b/reactos/subsys/system/explorer/utility/utility.cpp
deleted file mode 100644 (file)
index 825e537..0000000
+++ /dev/null
@@ -1,534 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- // 
- // utility.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include <precomp.h>
-
-//#include <shellapi.h>
-
-#include <time.h>
-#include <sstream>
-
-
-DWORD WINAPI Thread::ThreadProc(void* para)
-{
-       Thread* pThis = (Thread*) para;
-
-       int ret = pThis->Run();
-
-       pThis->_alive = false;
-
-       return ret;
-}
-
-
-void CenterWindow(HWND hwnd)
-{
-       RECT rt, prt;
-       GetWindowRect(hwnd, &rt);
-
-       DWORD style;
-       HWND owner = 0;
-
-       for(HWND wh=hwnd; (wh=GetWindow(wh,GW_OWNER))!=0; )
-               if (((style=GetWindowStyle(wh))&WS_VISIBLE) && !(style&WS_MINIMIZE))
-                       {owner=wh; break;}
-
-       if (owner)
-               GetWindowRect(owner, &prt);
-       else
-               SystemParametersInfo(SPI_GETWORKAREA, 0, &prt, 0);      //@@ GetDesktopWindow() wäre auch hilfreich.
-
-       SetWindowPos(hwnd, 0, (prt.left+prt.right+rt.left-rt.right)/2,
-                                          (prt.top+prt.bottom+rt.top-rt.bottom)/2, 0,0, SWP_NOACTIVATE|SWP_NOSIZE|SWP_NOZORDER);
-
-       MoveVisible(hwnd);
-}
-
-void MoveVisible(HWND hwnd)
-{
-       RECT rc;
-       GetWindowRect(hwnd, &rc);
-       int left=rc.left, top=rc.top;
-
-       int xmax = GetSystemMetrics(SM_CXSCREEN);
-       int ymax = GetSystemMetrics(SM_CYSCREEN);
-
-       if (rc.left < 0)
-               rc.left = 0;
-       else if (rc.right > xmax)
-               if ((rc.left-=rc.right-xmax) < 0)
-                       rc.left = 0;
-
-       if (rc.top < 0)
-               rc.top = 0;
-       else if (rc.bottom > ymax)
-               if ((rc.top-=rc.bottom-ymax) < 0)
-                       rc.top = 0;
-
-       if (rc.left!=left || rc.top!=top)
-               SetWindowPos(hwnd, 0, rc.left,rc.top, 0,0, SWP_NOZORDER|SWP_NOSIZE|SWP_NOACTIVATE);
-}
-
-
-void display_error(HWND hwnd, DWORD error)     //@@ CONTEXT mit ausgeben -> display_error(HWND hwnd, const Exception& e)
-{
-       PTSTR msg;
-
-       if (FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER|FORMAT_MESSAGE_FROM_SYSTEM,
-               0, error, MAKELANGID(LANG_NEUTRAL,SUBLANG_DEFAULT), (PTSTR)&msg, 0, NULL)) {
-               LOG(FmtString(TEXT("display_error(%#x): %s"), error, msg));
-
-               SetLastError(0);
-               MessageBox(hwnd, msg, TEXT("ROS Explorer"), MB_OK);
-
-               if (GetLastError() == ERROR_INVALID_WINDOW_HANDLE)
-                       MessageBox(0, msg, TEXT("ROS Explorer"), MB_OK);
-       } else {
-               LOG(FmtString(TEXT("Unknown Error %#x"), error));
-
-               FmtString msg(TEXT("Unknown Error %#x"), error);
-
-               SetLastError(0);
-               MessageBox(hwnd, msg, TEXT("ROS Explorer"), MB_OK);
-
-               if (GetLastError() == ERROR_INVALID_WINDOW_HANDLE)
-                       MessageBox(0, msg, TEXT("ROS Explorer"), MB_OK);
-       }
-
-       LocalFree(msg);
-}
-
-
-Context Context::s_main("-NO-CONTEXT-");
-Context* Context::s_current = &Context::s_main;
-
-String Context::toString() const
-{
-       String str = _ctx;
-
-       if (!_obj.empty())
-               str.appendf(TEXT("\nObject: %s"), (LPCTSTR)_obj);
-
-       return str;
-}
-
-String Context::getStackTrace() const
-{
-       ostringstream str;
-
-       str << "Context Trace:\n";
-
-       for(const Context*p=this; p && p!=&s_main; p=p->_last) {
-               str << "- " << p->_ctx;
-
-               if (!p->_obj.empty())
-                       str << " obj=" << ANS(p->_obj);
-
-               str << '\n';
-       }
-
-       return str.str();
-}
-
-
-BOOL time_to_filetime(const time_t* t, FILETIME* ftime)
-{
-#ifdef __STDC_WANT_SECURE_LIB__
-       SYSTEMTIME stime;
-       struct tm tm_;
-       struct tm* tm = &tm_;
-
-       if (gmtime_s(tm, t) != 0)
-               return FALSE;
-#else
-       struct tm* tm = gmtime(t);
-       SYSTEMTIME stime;
-
-       if (!tm)
-               return FALSE;
-#endif
-
-       stime.wYear = tm->tm_year+1900;
-       stime.wMonth = tm->tm_mon+1;
-       stime.wDayOfWeek = (WORD)-1;
-       stime.wDay = tm->tm_mday;
-       stime.wHour = tm->tm_hour;
-       stime.wMinute = tm->tm_min;
-       stime.wSecond = tm->tm_sec;
-       stime.wMilliseconds = 0;
-
-       return SystemTimeToFileTime(&stime, ftime);
-}
-
-
-BOOL launch_file(HWND hwnd, LPCTSTR cmd, UINT nCmdShow, LPCTSTR parameters)
-{
-       CONTEXT("launch_file()");
-
-       HINSTANCE hinst = ShellExecute(hwnd, NULL/*operation*/, cmd, parameters, NULL/*dir*/, nCmdShow);
-
-       if ((int)hinst <= 32) {
-               display_error(hwnd, GetLastError());
-               return FALSE;
-       }
-
-       return TRUE;
-}
-
-#ifdef UNICODE
-BOOL launch_fileA(HWND hwnd, LPSTR cmd, UINT nCmdShow, LPCSTR parameters)
-{
-       HINSTANCE hinst = ShellExecuteA(hwnd, NULL/*operation*/, cmd, parameters, NULL/*dir*/, nCmdShow);
-
-       if ((int)hinst <= 32) {
-               display_error(hwnd, GetLastError());
-               return FALSE;
-       }
-
-       return TRUE;
-}
-#endif
-
-
-/* search for already running instance */
-
-static int g_foundPrevInstance = 0;
-
-static BOOL CALLBACK EnumWndProc(HWND hwnd, LPARAM lparam)
-{
-       TCHAR cls[128];
-
-       GetClassName(hwnd, cls, 128);
-
-       if (!lstrcmp(cls, (LPCTSTR)lparam)) {
-               g_foundPrevInstance++;
-               return FALSE;
-       }
-
-       return TRUE;
-}
-
-/* search for window of given class name to allow only one running instance */
-int find_window_class(LPCTSTR classname)
-{
-       EnumWindows(EnumWndProc, (LPARAM)classname);
-
-       if (g_foundPrevInstance)
-               return 1;
-
-       return 0;
-}
-
-
-String get_windows_version_str()
-{
-       OSVERSIONINFOEX osvi = {sizeof(OSVERSIONINFOEX)};
-       BOOL osvie_val;
-       String str;
-
-       if (!(osvie_val = GetVersionEx((OSVERSIONINFO*)&osvi))) {
-               osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
-
-               if (!GetVersionEx((OSVERSIONINFO*)&osvi))
-                       return TEXT("???");
-       }
-
-       switch(osvi.dwPlatformId) {
-         case VER_PLATFORM_WIN32_NT:
-#ifdef _ROS_   // This work around can be removed if ReactOS gets a unique version number.
-               str = TEXT("ReactOS");
-#else
-               if (osvi.dwMajorVersion <= 4)
-                       str = TEXT("Microsoft Windows NT");
-               else if (osvi.dwMajorVersion==5 && osvi.dwMinorVersion==0)
-                       str = TEXT("Microsoft Windows 2000");
-               else if (osvi.dwMajorVersion==5 && osvi.dwMinorVersion==1)
-                       str = TEXT("Microsoft Windows XP");
-#endif
-
-               if (osvie_val) {
-                       if (osvi.wProductType == VER_NT_WORKSTATION) {
-                          if (osvi.wSuiteMask & VER_SUITE_PERSONAL)
-                                 str += TEXT(" Personal");
-                          else
-                                 str += TEXT(" Professional");
-                       } else if (osvi.wProductType == VER_NT_SERVER) {
-                          if (osvi.wSuiteMask & VER_SUITE_DATACENTER)
-                                 str += TEXT(" DataCenter Server");
-                          else if (osvi.wSuiteMask & VER_SUITE_ENTERPRISE)
-                                 str += TEXT(" Advanced Server");
-                          else
-                                 str += TEXT(" Server");
-                       } else if (osvi.wProductType == VER_NT_DOMAIN_CONTROLLER) {
-                               str += TEXT(" Domain Controller");
-                       }
-               } else {
-                       TCHAR type[80];
-                       DWORD dwBufLen;
-                       HKEY hkey;
-
-                       if (!RegOpenKeyEx(HKEY_LOCAL_MACHINE, TEXT("SYSTEM\\CurrentControlSet\\Control\\ProductOptions"), 0, KEY_QUERY_VALUE, &hkey)) {
-                               RegQueryValueEx(hkey, TEXT("ProductType"), NULL, NULL, (LPBYTE)type, &dwBufLen);
-                               RegCloseKey(hkey);
-
-                               if (!_tcsicmp(TEXT("WINNT"), type))
-                                  str += TEXT(" Workstation");
-                               else if (!_tcsicmp(TEXT("LANMANNT"), type))
-                                  str += TEXT(" Server");
-                               else if (!_tcsicmp(TEXT("SERVERNT"), type))
-                                       str += TEXT(" Advanced Server");
-                       }
-               }
-               break;
-
-         case VER_PLATFORM_WIN32_WINDOWS:
-               if (osvi.dwMajorVersion>4 ||
-                       (osvi.dwMajorVersion==4 && osvi.dwMinorVersion>0)) {
-                       if (osvi.dwMinorVersion == 90)
-                               str = TEXT("Microsoft Windows ME");
-                       else
-                               str = TEXT("Microsoft Windows 98");
-
-            if (osvi.szCSDVersion[1] == 'A')
-                               str += TEXT(" SE");
-               } else {
-                       str = TEXT("Microsoft Windows 95");
-
-            if (osvi.szCSDVersion[1]=='B' || osvi.szCSDVersion[1]=='C')
-                               str += TEXT(" OSR2");
-               }
-               break;
-
-         case VER_PLATFORM_WIN32s:
-               str = TEXT("Microsoft Win32s");
-
-         default:
-               return TEXT("???");
-       }
-
-       String vstr;
-
-       if (osvi.dwMajorVersion <= 4)
-               vstr.printf(TEXT(" Version %d.%d %s Build %d"),
-                                               osvi.dwMajorVersion, osvi.dwMinorVersion,
-                                               osvi.szCSDVersion, osvi.dwBuildNumber&0xFFFF);
-       else
-               vstr.printf(TEXT(" %s (Build %d)"), osvi.szCSDVersion, osvi.dwBuildNumber&0xFFFF);
-
-       return str + vstr;
-}
-
-
-typedef void (WINAPI*RUNDLLPROC)(HWND hwnd, HINSTANCE hinst, LPCTSTR cmdline, DWORD nCmdShow);
-
-BOOL RunDLL(HWND hwnd, LPCTSTR dllname, LPCSTR procname, LPCTSTR cmdline, UINT nCmdShow)
-{
-       HMODULE hmod = LoadLibrary(dllname);
-       if (!hmod)
-               return FALSE;
-
-/*TODO
-       <Windows NT/2000>
-       It is possible to create a Unicode version of the function.
-       Rundll32 first tries to find a function named EntryPointW.
-       If it cannot find this function, it tries EntryPointA, then EntryPoint.
-       To create a DLL that supports ANSI on Windows 95/98/Me and Unicode otherwise,
-       export two functions: EntryPointW and EntryPoint.
-*/
-       RUNDLLPROC proc = (RUNDLLPROC)GetProcAddress(hmod, procname);
-       if (!proc) {
-               FreeLibrary(hmod);
-               return FALSE;
-       }
-
-       proc(hwnd, hmod, cmdline, nCmdShow);
-
-       FreeLibrary(hmod);
-
-       return TRUE;
-}
-
-
-#ifdef UNICODE
-#define CONTROL_RUNDLL "Control_RunDLLW"
-#else
-#define CONTROL_RUNDLL "Control_RunDLLA"
-#endif
-
-BOOL launch_cpanel(HWND hwnd, LPCTSTR applet)
-{
-       //launch_file(_hwnd, applet, SW_SHOWNORMAL);    // This would be enough, but we want the to use the most direct and fastest call.
-       //launch_file(_hwnd, String(TEXT("rundll32.exe /d shell32.dll,Control_RunDLL "))+applet, SW_SHOWNORMAL);
-
-       return RunDLL(hwnd, TEXT("shell32"), CONTROL_RUNDLL, applet, SW_SHOWNORMAL);
-}
-
-
-BOOL RecursiveCreateDirectory(LPCTSTR path_in)
-{
-       TCHAR path[MAX_PATH], hole_path[MAX_PATH];
-
-       _tcscpy(hole_path, path_in);
-
-       int drv_len = 0;
-       LPCTSTR d;
-
-       for(d=hole_path; *d && *d!='/' && *d!='\\'; ++d) {
-               ++drv_len;
-
-               if (*d == ':')
-                       break;
-       }
-
-       LPTSTR dir = hole_path + drv_len;
-
-       int l;
-       LPTSTR p = hole_path + (l=_tcslen(hole_path));
-
-       while(--p>=hole_path && (*p=='/' || *p=='\\'))
-               *p = '\0';
-
-       WIN32_FIND_DATA w32fd;
-
-       HANDLE hFind = FindFirstFile(hole_path, &w32fd);
-
-       if (hFind == INVALID_HANDLE_VALUE) {
-               _tcsncpy(path, hole_path, drv_len);
-               int i = drv_len;
-
-               for(p=dir; *p=='/'||*p=='\\'; p++)
-                       path[i++] = *p++;
-
-               for(; i<l; i++) {
-                       memcpy(path, hole_path, i*sizeof(TCHAR));
-
-                       for(; hole_path[i] && hole_path[i]!='/' && hole_path[i]!='\\'; i++)
-                               path[i] = hole_path[i];
-
-                       path[i] = '\0';
-
-                       hFind = FindFirstFile(path, &w32fd);
-
-                       if (hFind != INVALID_HANDLE_VALUE)
-                               FindClose(hFind);
-                       else {
-                               LOG(FmtString(TEXT("CreateDirectory(\"%s\")"), path));
-
-                               if (!CreateDirectory(path, 0))
-                                       return FALSE;
-                       }
-               }
-       } else
-               FindClose(hFind);
-
-       return TRUE;
-}
-
-
-DWORD RegGetDWORDValue(HKEY root, LPCTSTR path, LPCTSTR valueName, DWORD def)
-{
-       HKEY hkey;
-       DWORD ret;
-
-       if (!RegOpenKey(root, path, &hkey)) {
-               DWORD len = sizeof(ret);
-
-               if (RegQueryValueEx(hkey, valueName, 0, NULL, (LPBYTE)&ret, &len))
-                       ret = def;
-
-               RegCloseKey(hkey);
-
-               return ret;
-       } else
-               return def;
-}
-
-
-BOOL RegSetDWORDValue(HKEY root, LPCTSTR path, LPCTSTR valueName, DWORD value)
-{
-       HKEY hkey;
-       BOOL ret = FALSE;
-
-       if (!RegOpenKey(root, path, &hkey)) {
-               ret = RegSetValueEx(hkey, valueName, 0, REG_DWORD, (LPBYTE)&value, sizeof(value));
-
-               RegCloseKey(hkey);
-       }
-
-       return ret;
-}
-
-
-BOOL exists_path(LPCTSTR path)
-{
-       WIN32_FIND_DATA fd;
-
-       HANDLE hfind = FindFirstFile(path, &fd);
-
-       if (hfind != INVALID_HANDLE_VALUE) {
-               FindClose(hfind);
-
-               return TRUE;
-       } else
-               return FALSE;
-}
-
-
-bool SplitFileSysURL(LPCTSTR url, String& dir_out, String& fname_out)
-{
-       if (!_tcsnicmp(url, TEXT("file://"), 7)) {
-               url += 7;
-
-                // remove third slash in front of drive characters
-               if (*url == '/')
-                       ++url;
-       }
-
-       if (exists_path(url)) {
-               TCHAR path[_MAX_PATH];
-
-                // convert slashes to back slashes
-               GetFullPathName(url, COUNTOF(path), path, NULL);
-
-               if (GetFileAttributes(path) & FILE_ATTRIBUTE_DIRECTORY)
-                       fname_out.erase();
-               else {
-                       TCHAR drv[_MAX_DRIVE], dir[_MAX_DIR], fname[_MAX_FNAME], ext[_MAX_EXT];
-
-                       _tsplitpath_s(path, drv, COUNTOF(drv), dir, COUNTOF(dir), fname, COUNTOF(fname), ext, COUNTOF(ext));
-                       _stprintf(path, TEXT("%s%s"), drv, dir);
-
-                       fname_out.printf(TEXT("%s%s"), fname, ext);
-               }
-
-               dir_out = path;
-
-               return true;
-       } else
-               return false;
-}
diff --git a/reactos/subsys/system/explorer/utility/utility.h b/reactos/subsys/system/explorer/utility/utility.h
deleted file mode 100644 (file)
index db37ee5..0000000
+++ /dev/null
@@ -1,1071 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // utility.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
- // standard windows headers
-#define WIN32_LEAN_AND_MEAN
-#define WIN32_EXTRA_LEAN
-#include <windows.h>
-
- // Unicode support
-#ifdef UNICODE
-#define        _UNICODE
-#endif
-#include <tchar.h>
-
-#include <windowsx.h>  // for SelectBrush(), ListBox_SetSel(), SubclassWindow(), ...
-#include <commctrl.h>
-
-#ifndef _MSC_VER
-#include <objbase.h>
-#endif
-#include <oleauto.h>   // for VARIANT
-
-#include <malloc.h>            // for alloca()
-#include <assert.h>
-#include <stdlib.h>            // for _MAX_DIR, ...
-#include <stdio.h>             // for sprintf()
-#include <time.h>
-
-#ifndef _MAX_PATH
-#define _MAX_DRIVE     3
-#define _MAX_FNAME     256
-#define _MAX_DIR       _MAX_FNAME
-#define _MAX_EXT       _MAX_FNAME
-#define _MAX_PATH      260
-#endif
-
-#define        W_VER_NT 0      // constant for HIWORD(GetVersion())>>14
-
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-#define        for if (0) {} else for
-
-#ifdef _countof
-#define COUNTOF _countof
-#else
-#define        COUNTOF(x)      (sizeof(x)/sizeof(x[0]))
-#endif
-
-
-#define        BUFFER_LEN                              2048
-
-
-extern void _log_(LPCTSTR txt);
-
-#define        LOG(txt) _log_(txt)
-
-
-#ifdef _MSC_VER
-#define        LONGLONGARG TEXT("I64")
-#else
-#define        LONGLONGARG TEXT("L")
-#endif
-
-
-#ifndef _tcsrchr
-#ifdef UNICODE
-#define        _tcsrchr wcsrchr
-#else
-#define        _tcsrchr strrchr
-#endif
-#endif
-
-#ifndef _stprintf
-#ifdef UNICODE
-#define        _stprintf wcsprintf
-#else
-#define        _stprintf sprintf
-#endif
-#endif
-
-#define        U2A(s, d, l) WideCharToMultiByte(CP_ACP, 0, s, -1, d, l, NULL, NULL)
-#define        U2nA(s, d, l) WideCharToMultiByte(CP_ACP, 0, s, l, d, l, NULL, NULL)
-#define        A2U(s, d, l) MultiByteToWideChar(CP_ACP, 0, s, -1, d, l)
-#define        A2nU(s, d, l) MultiByteToWideChar(CP_ACP, 0, s, l, d, l)
-
-
-#ifdef __WINE__
-#ifdef UNICODE
-extern void _wsplitpath(const WCHAR* path, WCHAR* drv, WCHAR* dir, WCHAR* name, WCHAR* ext);
-#else
-extern void _splitpath(const CHAR* path, CHAR* drv, CHAR* dir, CHAR* name, CHAR* ext);
-#endif
-#define        _tcsnicmp strncasecmp
-#define        _tcsicoll strcasecmp
-#endif
-
-#ifndef FILE_ATTRIBUTE_NOT_CONTENT_INDEXED
-#define FILE_ATTRIBUTE_ENCRYPTED            0x00000040
-#define FILE_ATTRIBUTE_SPARSE_FILE          0x00000200
-#define FILE_ATTRIBUTE_REPARSE_POINT        0x00000400
-#define FILE_ATTRIBUTE_NOT_CONTENT_INDEXED  0x00002000
-#endif
-
-
-#define        SetDlgCtrlID(hwnd, id) SetWindowLong(hwnd, GWL_ID, id)
-#define        SetWindowStyle(hwnd, val) (DWORD)SetWindowLong(hwnd, GWL_STYLE, val)
-#define        SetWindowExStyle(h, val) (DWORD)SetWindowLong(hwnd, GWL_EXSTYLE, val)
-#define        Window_SetIcon(hwnd, type, hicon) (HICON)SendMessage(hwnd, WM_SETICON, type, (LPARAM)(hicon))
-
-
- // center window in respect to its parent window
-extern void CenterWindow(HWND hwnd);
-
- // move window into visibility
-extern void MoveVisible(HWND hwnd);
-
- // display error message
-extern void display_error(HWND hwnd, DWORD error);
-
- // convert time_t to WIN32 FILETIME
-extern BOOL time_to_filetime(const time_t* t, FILETIME* ftime);
-
- // search for windows of a specific classname
-extern int find_window_class(LPCTSTR classname);
-
- // create a directory with all missing parent directories
-BOOL RecursiveCreateDirectory(LPCTSTR path_in);
-
- // read DWORD value from registry
-DWORD RegGetDWORDValue(HKEY root, LPCTSTR path, LPCTSTR valueName, DWORD def);
-
- // write DWORD value to registry
-BOOL RegSetDWORDValue(HKEY root, LPCTSTR path, LPCTSTR valueName, DWORD value);
-
- // test for existing directory
-BOOL exists_path(LPCTSTR path);
-
-
-#ifdef __cplusplus
-} // extern "C"
-#endif
-
-
- // secure CRT functions
-#ifdef __STDC_WANT_SECURE_LIB__        // for VS 2005: _MSC_VER>=1400
-
-#define _stprintf_s1 _stprintf_s
-#define _stprintf_s2 _stprintf_s
-
-#else  // __STDC_WANT_SECURE_LIB__
-
-#define strcpy_s(d, l, s) strcpy(d, s)
-#define _tcscpy_s(d, l, s) _tcscpy(d, s)
-#define wcsncpy_s(d, l, s, n) wcsncpy(d, s, n)
-#define _stprintf_s1(b, l, f, p1) _stprintf(b, f, p1)
-#define _stprintf_s2(b, l, f, p1,p2) _stprintf(b, f, p1,p2)
-#define _tsplitpath_s(f, d,dl, p,pl, n,nl, e,el) _tsplitpath(f, d, p, n, e)
-
-#endif // __STDC_WANT_SECURE_LIB__
-
-
-#ifdef __cplusplus
-
-#ifdef _MSC_VER
-#pragma warning(disable: 4786) // disable warnings about too long debug information symbols
-#endif
-
- // STL headers for strings and streams
-#include <string>
-#include <iostream>
-using namespace std;
-
- // containers
-#include <map>
-#include <set>
-#include <list>
-#include <stack>
-#include <vector>
-
-
-/* not necessary with correct include file order for comdef.h ("<MS PSDK>\include" path first)
-#if _MSC_VER>=1300     // VS.Net
-#define _NO_COMUTIL
-#endif
-*/
-
-#if defined(_MSC_VER) && !defined(_NO_COMUTIL)
-
- // COM utility headers
-#include <comdef.h>
-using namespace _com_util;
-
-#endif // _MSC_VER && !_NO_COMUTIL
-
-
- // launch a program or document file
-extern BOOL launch_file(HWND hwnd, LPCTSTR cmd, UINT nCmdShow=SW_SHOWNORMAL, LPCTSTR parameters=NULL);
-#ifdef UNICODE
-extern BOOL launch_fileA(HWND hwnd, LPSTR cmd, UINT nCmdShow=SW_SHOWNORMAL, LPCSTR parameters=NULL);
-#else
-#define        launch_fileA launch_file
-#endif
-
- // call an DLL export like rundll32
-extern BOOL RunDLL(HWND hwnd, LPCTSTR dllname, LPCSTR procname, LPCTSTR cmdline, UINT nCmdShow);
-
- // launch control panel applet
-extern BOOL launch_cpanel(HWND hwnd, LPCTSTR applet);
-
-
- /// initialization of windows common controls
-struct CommonControlInit
-{
-       CommonControlInit(DWORD flags=ICC_LISTVIEW_CLASSES|ICC_TREEVIEW_CLASSES|ICC_BAR_CLASSES|ICC_PROGRESS_CLASS|ICC_COOL_CLASSES)
-       {
-               INITCOMMONCONTROLSEX icc = {sizeof(INITCOMMONCONTROLSEX), flags};
-
-               InitCommonControlsEx(&icc);
-       }
-};
-
-
- /// wait cursor
-
-struct WaitCursor      ///@todo integrate with WM_SETCURSOR to enable multithreaded background tasks as program launching
-{
-       WaitCursor()
-       {
-               _old_cursor = SetCursor(LoadCursor(0, IDC_WAIT));
-       }
-
-       ~WaitCursor()
-       {
-               SetCursor(_old_cursor);
-       }
-
-protected:
-       HCURSOR _old_cursor;
-};
-
-
- /// base of all structures storing a window handle
-struct WindowHandle
-{
-       WindowHandle(HWND hwnd=0)
-        :      _hwnd(hwnd) {}
-
-       operator HWND() const {return _hwnd;}
-       HWND* operator&() {return &_hwnd;}
-
-protected:
-       HWND    _hwnd;
-};
-
-
- /// locally hide a window
-struct HiddenWindow : public WindowHandle
-{
-       HiddenWindow(HWND hwnd)
-        :      WindowHandle(IsWindowVisible(hwnd)? hwnd: 0)
-       {
-               if (_hwnd)
-                       SetWindowPos(_hwnd, 0, 0, 0, 0, 0, SWP_HIDEWINDOW|SWP_NOREDRAW|SWP_NOMOVE|SWP_NOSIZE|SWP_NOZORDER);
-       }
-
-       ~HiddenWindow()
-       {
-               if (_hwnd)
-                       SetWindowPos(_hwnd, 0, 0, 0, 0, 0, SWP_SHOWWINDOW|SWP_NOMOVE|SWP_NOSIZE|SWP_NOZORDER);
-       }
-};
-
-
- /// critical section wrapper
-
-struct CritSect : public CRITICAL_SECTION
-{
-       CritSect()
-       {
-               InitializeCriticalSection(this);
-       }
-
-       ~CritSect()
-       {
-               DeleteCriticalSection(this);
-       }
-};
-
-
- /// Lock protects a code section utilizing a critical section
-
-struct Lock
-{
-       Lock(CritSect& crit_sect)
-        :      _crit_sect(crit_sect)
-       {
-               EnterCriticalSection(&crit_sect);
-       }
-
-       ~Lock()
-       {
-               LeaveCriticalSection(&_crit_sect);
-       }
-
-protected:
-       CritSect&       _crit_sect;
-};
-
-
- /// Thread base class
-
-struct Thread
-{
-       Thread()
-        :      _alive(false),
-               _destroy(false)
-       {
-               _hThread = INVALID_HANDLE_VALUE;
-               _evtFinish = CreateEvent(NULL, TRUE, FALSE, NULL);
-       }
-
-       virtual ~Thread()
-       {
-               Stop();
-
-               CloseHandle(_evtFinish);
-               CloseHandle(_hThread);
-
-               if (_destroy)
-                       delete this;
-       }
-
-       void Start()
-       {
-               if (!_alive) {
-                       _alive = true;
-                       _hThread = CreateThread(NULL, 0, ThreadProc, this, 0, NULL);
-               }
-       }
-
-       void Stop()
-       {
-               SetEvent(_evtFinish);
-
-               if (_alive) {
-                       {
-                       Lock lock(_crit_sect);
-                       _alive = false;
-                       }
-
-                        // wait for finishing
-                       WaitForSingleObject(_hThread, INFINITE);
-               }
-       }
-
-       virtual int Run() = 0;
-
-       bool    is_alive() const {return _alive;}
-
-       CritSect _crit_sect;
-
-protected:
-       static DWORD WINAPI ThreadProc(void* para);
-
-       HANDLE  _hThread;
-       HANDLE  _evtFinish;
-       bool    _alive;
-       bool    _destroy;
-};
-
-
- // window utilities
-
- /// ClientRect retreives the client area rectangle of a window.
-struct ClientRect : public RECT
-{
-       ClientRect(HWND hwnd)
-       {
-               GetClientRect(hwnd, this);
-       }
-
-       operator LPRECT() {return this;}
-
-       POINT& pos() {return *(LPPOINT)this;}
-};
-
- /// ClientRect retreives the window rectangle of a window.
-struct WindowRect : public RECT
-{
-       WindowRect(HWND hwnd)
-       {
-               GetWindowRect(hwnd, this);
-       }
-
-       operator LPRECT() {return this;}
-
-       POINT& pos() {return *(LPPOINT)this;}
-};
-
- /// PointL encapsulates the POINT structure into a C++ object.
-struct Point : public POINT
-{
-       Point(LONG x_, LONG y_)
-       {
-               x = x_;
-               y = y_;
-       }
-
-        // constructor for being used in processing WM_MOUSEMOVE, WM_LBUTTONDOWN, ... messages
-       Point(LPARAM lparam)
-       {
-               x = GET_X_LPARAM(lparam);
-               y = GET_Y_LPARAM(lparam);
-       }
-
-       operator LPPOINT() {return this;}
-};
-
-
- /// transform coordinates in a RECT from client to screen coordiantes
-inline void ClientToScreen(HWND hwnd, RECT* prect)
- {::ClientToScreen(hwnd,(LPPOINT)&prect->left); ::ClientToScreen(hwnd,(LPPOINT)&prect->right);}
-
- /// transform coordinates in a RECT from screen to client coordiantes
-inline void ScreenToClient(HWND hwnd, RECT* prect)
- {::ScreenToClient(hwnd,(LPPOINT)&prect->left); ::ScreenToClient(hwnd,(LPPOINT)&prect->right);}
-
-
- /// structure containing information about full screen display of the frame window
-struct FullScreenParameters
-{
-       FullScreenParameters()
-        :      _mode(FALSE)
-       {
-       }
-
-       BOOL    _mode;
-       RECT    _orgPos;
-       BOOL    _wasZoomed;
-};
-
-
- // drawing utilities
-
- /// PaintCanvas is a encapsulation of device contexts managed by BeginPaint()/EndPaint().
-struct PaintCanvas : public PAINTSTRUCT
-{
-       PaintCanvas(HWND hwnd)
-        :      _hwnd(hwnd)
-       {
-               BeginPaint(hwnd, this);
-       }
-
-       ~PaintCanvas()
-       {
-               EndPaint(_hwnd, this);
-       }
-
-       operator HDC() const {return hdc;}
-
-protected:
-       HWND    _hwnd;
-};
-
- /// Canvas is a encapsulation of device contexts.
-struct Canvas
-{
-       Canvas(HDC hdc) : _hdc(hdc) {}
-
-       operator HDC() {return _hdc;}
-
-protected:
-       HDC _hdc;
-};
-
- /// WindowCanvas is a encapsulation of client area device contexts.
-struct WindowCanvas : public Canvas
-{
-       WindowCanvas(HWND hwnd)
-        :      Canvas(GetDC(hwnd)), _hwnd(hwnd) {}
-
-       ~WindowCanvas() {ReleaseDC(_hwnd, _hdc);}
-
-protected:
-       HWND    _hwnd;
-};
-
-
- // double buffering classes
-
- /// Memory Canvas creates and destroys memory devoce contexts.
-struct MemCanvas : public Canvas
-{
-       MemCanvas(HDC hdc=0)
-        :      Canvas(CreateCompatibleDC(hdc)) {assert(_hdc);}
-
-       ~MemCanvas() {DeleteDC(_hdc);}
-};
-
- /// SelectedBitmap is used to localy select bitmaps into device contexts.
-struct SelectedBitmap
-{
-       SelectedBitmap(HDC hdc, HBITMAP hbmp)
-        :      _hdc(hdc), _old_hbmp(SelectBitmap(hdc, hbmp)) {}
-
-       ~SelectedBitmap() {DeleteObject(SelectBitmap(_hdc, _old_hbmp));}
-
-protected:
-       HDC             _hdc;
-       HBITMAP _old_hbmp;
-};
-
- /// BufferCanvas manages offscreen bitmaps selected into memory device contexts.
-struct BufferCanvas : public MemCanvas
-{
-       BufferCanvas(HDC hdc, int x, int y, int w, int h)
-        :      MemCanvas(hdc), _hdctarg(hdc),
-               _x(x), _y(y), _w(w), _h(h),
-               _bmp(_hdc, CreateCompatibleBitmap(hdc, w, h)) {}
-
-       BufferCanvas(HDC hdc, const RECT& rect)
-        :      MemCanvas(hdc), _hdctarg(hdc),
-               _x(rect.left), _y(rect.top), _w(rect.right-rect.left), _h(rect.bottom-rect.top),
-               _bmp(_hdc, CreateCompatibleBitmap(hdc, _w, _h)) {}
-
-protected:
-       HDC     _hdctarg;
-       int     _x, _y, _w, _h;
-       SelectedBitmap _bmp;
-};
-
- /// BufferedCanvas enables double buffering for a device context.
-struct BufferedCanvas : public BufferCanvas
-{
-       BufferedCanvas(HDC hdc, int x, int y, int w, int h, DWORD mode=SRCCOPY)
-        :      BufferCanvas(hdc, x, y, w, h), _mode(mode) {}
-
-       BufferedCanvas(HDC hdc, const RECT& rect, DWORD mode=SRCCOPY)
-        :      BufferCanvas(hdc, rect), _mode(mode) {}
-
-       ~BufferedCanvas() {BitBlt(_hdctarg, _x, _y, _w, _h, _hdc, 0, 0, _mode);}
-
-       DWORD   _mode;
-};
-
- /// BufferedPaintCanvas extends PaintCanvas for double buffering.
-struct BufferedPaintCanvas : public PaintCanvas, public BufferedCanvas
-{
-       BufferedPaintCanvas(HWND hwnd)
-        :      PaintCanvas(hwnd),
-               BufferedCanvas(PAINTSTRUCT::hdc, 0, 0, rcPaint.right, rcPaint.bottom)
-       {
-       }
-
-       operator HDC() {return BufferedCanvas::_hdc;}
-};
-
-
- /// TextColor locally selects a text color for drawing.
-struct TextColor
-{
-       TextColor(HDC hdc, COLORREF color)
-        : _hdc(hdc), _old_color(SetTextColor(hdc, color)) {}
-
-       ~TextColor() {SetTextColor(_hdc, _old_color);}
-
-protected:
-       HDC              _hdc;
-       COLORREF _old_color;
-};
-
- /// BkMode locally sets the background mode for drawing.
-struct BkMode
-{
-       BkMode(HDC hdc, int bkmode)
-        : _hdc(hdc), _old_bkmode(SetBkMode(hdc, bkmode)) {}
-
-       ~BkMode() {SetBkMode(_hdc, _old_bkmode);}
-
-protected:
-       HDC              _hdc;
-       COLORREF _old_bkmode;
-};
-
- /// FontSelection locally selects a font for drawing.
-struct FontSelection
-{
-       FontSelection(HDC hdc, HFONT hFont)
-        : _hdc(hdc), _old_hFont(SelectFont(hdc, hFont)) {}
-
-       ~FontSelection() {SelectFont(_hdc, _old_hFont);}
-
-protected:
-       HDC             _hdc;
-       HFONT   _old_hFont;
-};
-
- /// BitmapSelection locally selects a bitmap into a device context.
-struct BitmapSelection
-{
-       BitmapSelection(HDC hdc, HBITMAP hBmp)
-        : _hdc(hdc), _old_hBmp(SelectBitmap(hdc, hBmp)) {}
-
-       ~BitmapSelection() {SelectBitmap(_hdc, _old_hBmp);}
-
-protected:
-       HDC             _hdc;
-       HBITMAP _old_hBmp;
-};
-
- /// BrushSelection locally selects a brush into a device context.
-struct BrushSelection
-{
-       BrushSelection(HDC hdc, HBRUSH hBrush)
-        : _hdc(hdc), _old_hBrush(SelectBrush(hdc, hBrush)) {}
-
-       ~BrushSelection() {SelectBrush(_hdc, _old_hBrush);}
-
-protected:
-       HDC             _hdc;
-       HBRUSH  _old_hBrush;
-};
-
-
- /// Popup Menus
-struct PopupMenu
-{
-       PopupMenu()
-        :      _hmenu(CreatePopupMenu())
-       {
-       }
-
-       PopupMenu(UINT nid);
-
-       operator HMENU() {return _hmenu;}
-
-       void Append(UINT id, LPCTSTR str, UINT flags=MF_STRING)
-       {
-               AppendMenu(_hmenu, flags, id, str);
-       }
-
-       int TrackPopupMenu(HWND hwnd, const POINT& pt, UINT flags=TPM_LEFTBUTTON|TPM_RIGHTBUTTON, LPTPMPARAMS tpm=NULL) {
-        return TrackPopupMenuEx(_hmenu, flags, pt.x, pt.y, hwnd, tpm);
-       }
-
-       int PopupContextMenu(HWND hwnd, POINTS pos, UINT flags=TPM_LEFTBUTTON|TPM_RIGHTBUTTON) {
-        POINT pt; POINTSTOPOINT(pt, pos);
-        return TrackPopupMenuEx(_hmenu, flags, pt.x, pt.y, hwnd, NULL);
-       }
-
-       int TrackPopupMenu(HWND hwnd, POINTS pos, UINT flags=TPM_LEFTBUTTON|TPM_RIGHTBUTTON) {
-        POINT pt; POINTSTOPOINT(pt, pos);
-        ClientToScreen(hwnd, &pt);
-        return TrackPopupMenuEx(_hmenu, flags, pt.x, pt.y, hwnd, NULL);
-       }
-
-       int TrackPopupMenuAtCursor(HWND hwnd, UINT flags=TPM_LEFTBUTTON) {
-        POINT pt; GetCursorPos(&pt);
-        return TrackPopupMenuEx(_hmenu, flags, pt.x, pt.y, hwnd, NULL);
-       }
-
-       int TrackPopupMenuAtPos(HWND hwnd, DWORD pos, UINT flags=TPM_LEFTBUTTON) {
-        return TrackPopupMenuEx(_hmenu, flags, GET_X_LPARAM(pos), GET_Y_LPARAM(pos), hwnd, NULL);
-       }
-
-protected:
-       HMENU _hmenu;
-};
-
-
-struct Variant : public VARIANT
-{
-       Variant() {VariantInit(this);}
-       Variant(const VARIANT& var);
-       Variant(const VARIANT* var);
-       ~Variant();
-
-       operator long() const;
-       operator bool() const;
-       operator VARIANT_BOOL() const;
-       operator IDispatch*() const;
-};
-
-
-struct BStr
-{
-       BStr()
-       {
-               _p = NULL;
-       }
-
-       BStr(const BSTR s)
-       {
-               _p = SysAllocString(s);
-       }
-
-       BStr(LPCSTR s)
-       {
-               WCHAR b[BUFFER_LEN];
-
-               if (s)
-                       _p = SysAllocStringLen(b, MultiByteToWideChar(CP_ACP, 0, s, -1, b, BUFFER_LEN)-1);
-               else
-                       _p = NULL;
-       }
-
-       BStr(LPCWSTR s)
-       {
-               _p = SysAllocString(s);
-       }
-
-       BStr(const VARIANT& var)
-        :      _p(NULL)
-       {
-               assign(var);
-       }
-
-       ~BStr()
-       {
-               SysFreeString(_p);
-       }
-
-       void assign(BSTR s);
-       void assign(const VARIANT& var);
-
-       operator BSTR() const
-       {
-               return _p? _p: (BSTR)L"";
-       }
-
-       int length() const
-       {
-               return _p? wcslen(_p): 0;
-       }
-
-protected:
-       BSTR    _p;
-};
-
-
- /// string class for TCHAR strings
-struct String
-#ifdef UNICODE
- : public wstring
-#else
- : public string
-#endif
-{
-#ifdef UNICODE
-       typedef wstring super;
-#else
-       typedef string super;
-#endif
-
-       String() {}
-
-       String(LPCTSTR s) {if (s) super::assign(s);}
-       String(LPCTSTR s, int l) : super(s, l) {}
-
-       String(const super& other) : super(other) {}
-       String(const String& other) : super(other) {}
-
-#ifdef UNICODE
-       String(LPCSTR s) {assign(s);}
-       String(LPCSTR s, int l) {assign(s, l);}
-       String(const string& other) {assign(other.c_str());}
-       String& operator=(LPCSTR s) {assign(s); return *this;}
-       void assign(LPCSTR s) {if (s) {TCHAR b[BUFFER_LEN]; super::assign(b, MultiByteToWideChar(CP_ACP, 0, s, -1, b, BUFFER_LEN)-1);} else erase();}
-       void assign(LPCSTR s, int l) {if (s) {TCHAR b[BUFFER_LEN]; super::assign(b, MultiByteToWideChar(CP_ACP, 0, s, l, b, BUFFER_LEN));} else erase();}
-       void assign(const BStr& s) {int l = s.length(); super::assign(s, l);}
-#else
-       String(LPCWSTR s) {assign(s);}
-       String(LPCWSTR s, int l) {assign(s, l);}
-       String(const wstring& other) {assign(other.c_str());}
-       String& operator=(LPCWSTR s) {assign(s); return *this;}
-       void assign(LPCWSTR s) {if (s) {char b[BUFFER_LEN]; super::assign(b, WideCharToMultiByte(CP_ACP, 0, s, -1, b, BUFFER_LEN, 0, 0)-1);} else erase();}
-       void assign(LPCWSTR s, int l) {if (s) {char b[BUFFER_LEN]; super::assign(b, WideCharToMultiByte(CP_ACP, 0, s, l, b, BUFFER_LEN, 0, 0));} else erase();}
-       void assign(const BStr& s) {int l = s.length(); if (l) {char b[BUFFER_LEN]; super::assign(b, WideCharToMultiByte(CP_ACP, 0, s, l, b, BUFFER_LEN, 0, 0));} else erase();}
-#endif
-       String(const BStr& s) {assign(s);}
-       String& operator=(const BStr& s) {assign(s); return *this;}
-
-       String& operator=(LPCTSTR s) {if (s) super::assign(s); else erase(); return *this;}
-       String& operator=(const super& s) {super::assign(s); return *this;}
-       void assign(LPCTSTR s) {super::assign(s);}
-       void assign(LPCTSTR s, int l) {super::assign(s, l);}
-
-       operator LPCTSTR() const {return c_str();}
-
-#ifdef UNICODE
-       operator string() const {char b[BUFFER_LEN]; return string(b, WideCharToMultiByte(CP_ACP, 0, c_str(), -1, b, BUFFER_LEN, 0, 0)-1);}
-#else
-       operator wstring() const {WCHAR b[BUFFER_LEN]; return wstring(b, MultiByteToWideChar(CP_ACP, 0, c_str(), -1, b, BUFFER_LEN)-1);}
-#endif
-
-       LPTSTR str() {return (LPTSTR)data();}   /// return modifyable character string pointer
-
-       String& printf(LPCTSTR fmt, ...)
-       {
-               va_list l;
-               TCHAR b[BUFFER_LEN];
-
-               va_start(l, fmt);
-               super::assign(b, _vsntprintf(b, COUNTOF(b), fmt, l));
-               va_end(l);
-
-               return *this;
-       }
-
-       String& vprintf(LPCTSTR fmt, va_list l)
-       {
-               TCHAR b[BUFFER_LEN];
-
-               super::assign(b, _vsntprintf(b, COUNTOF(b), fmt, l));
-
-               return *this;
-       }
-
-       String& appendf(LPCTSTR fmt, ...)
-       {
-               va_list l;
-               TCHAR b[BUFFER_LEN];
-
-               va_start(l, fmt);
-               super::append(b, _vsntprintf(b, COUNTOF(b), fmt, l));
-               va_end(l);
-
-               return *this;
-       }
-
-       String& vappendf(LPCTSTR fmt, va_list l)
-       {
-               TCHAR b[BUFFER_LEN];
-
-               super::append(b, _vsntprintf(b, COUNTOF(b), fmt, l));
-
-               return *this;
-       }
-
-       void toLower()
-       {
-               if (!empty())
-                       CharLower(str());
-       }
-};
-
-#define        _STRING_DEFINED
-
-
-struct FmtString : public String
-{
-       FmtString(LPCTSTR fmt, ...)
-       {
-               va_list l;
-
-               va_start(l, fmt);
-               vprintf(fmt, l);
-               va_end(l);
-       }
-};
-
-
-#ifdef UNICODE
-
-struct ANS
-{
-       ANS(LPCWSTR s)
-       {
-               int l = wcslen(s) + 1;
-               _str = (LPSTR) malloc(2*l);
-
-               if (WideCharToMultiByte(CP_ACP, 0, s, -1, _str, 2*l, 0, 0) <= 0)
-                       *_str = '\0';
-       }
-
-       ~ANS()
-       {
-               free(_str);
-       }
-
-       operator LPCSTR() {return _str;}
-
-protected:
-       LPSTR   _str;
-};
-
-#define        UNC(x) ((LPCWSTR)(x))
-
-#else
-
-#define        ANS(x) ((LPCSTR)(x))
-
-struct UNC
-{
-       UNC(LPCSTR s)
-       {
-               int l = strlen(s) + 1;
-               _str = (LPWSTR) malloc(2*l);
-
-               if (_str && MultiByteToWideChar(CP_ACP, 0, s, -1, _str, l) <= 0)
-                       *_str = '\0';
-       }
-
-       ~UNC()
-       {
-               free(_str);
-       }
-
-       operator LPCWSTR() {return _str;}
-
-protected:
-       LPWSTR  _str;
-};
-
-#endif
-
-
- // determine windows version string
-String get_windows_version_str();
-
-
- /// link dynamicly to functions by using GetModuleHandle() and GetProcAddress()
-template<typename FCT> struct DynamicFct
-{
-       DynamicFct(LPCTSTR moduleName, UINT ordinal)
-       {
-               HMODULE hModule = GetModuleHandle(moduleName);
-
-               _fct = (FCT) GetProcAddress(hModule, (LPCSTR)ordinal);
-       }
-
-       DynamicFct(LPCTSTR moduleName, LPCSTR name)
-       {
-               HMODULE hModule = GetModuleHandle(moduleName);
-
-               _fct = (FCT) GetProcAddress(hModule, name);
-       }
-
-       FCT operator*() const {return _fct;}
-       operator bool() const {return _fct? true: false;}
-
-protected:
-       FCT     _fct;
-};
-
-
- /// link dynamicly to functions by using LoadLibrary() and GetProcAddress()
-template<typename FCT> struct DynamicLoadLibFct
-{
-       DynamicLoadLibFct(LPCTSTR moduleName, UINT ordinal)
-       {
-               _hModule = LoadLibrary(moduleName);
-
-               _fct = (FCT) GetProcAddress(_hModule, (LPCSTR)ordinal);
-       }
-
-       DynamicLoadLibFct(LPCTSTR moduleName, LPCSTR name)
-       {
-               _hModule = LoadLibrary(moduleName);
-
-               _fct = (FCT) GetProcAddress(_hModule, name);
-       }
-
-       ~DynamicLoadLibFct()
-       {
-               FreeLibrary(_hModule);
-       }
-
-       FCT operator*() const {return _fct;}
-       operator bool() const {return _fct? true: false;}
-
-protected:
-       HMODULE _hModule;
-       FCT     _fct;
-};
-
-
-struct Context
-{
-       Context(const char* ctx)
-        :      _ctx(ctx)
-       {
-               _last = s_current;
-               s_current = this;
-       }
-
-       Context(const char* ctx, LPCSTR obj)
-        :      _ctx(ctx),
-               _obj(obj)
-       {
-               _last = s_current;
-               s_current = this;
-       }
-
-       Context(const char* ctx, LPCWSTR obj)
-        :      _ctx(ctx),
-               _obj(obj)
-       {
-               _last = s_current;
-               s_current = this;
-       }
-
-       Context(const Context& other)
-        :      _ctx(other._ctx),
-               _obj(other._obj)
-       {
-               _last = NULL;
-       }
-
-       ~Context()
-       {
-               if (_last) {
-                       s_current = _last;
-                       _last = NULL;
-               }
-       }
-
-       String toString() const;
-       String getStackTrace() const;
-
-       const char* _ctx;
-       String  _obj;
-
-       static Context& current() {return *s_current;}
-
-protected:
-       Context* _last;
-
-       static Context* s_current;      ///@todo use TLS
-       static Context  s_main;
-};
-
-#define        CONTEXT_OBJ __ctx__._obj
-#define        CONTEXT(c) Context __ctx__(c)
-#define        CURRENT_CONTEXT Context::current()
-#define        OBJ_CONTEXT(c, o) Context __ctx__(c, o)
-
-
-extern bool SplitFileSysURL(LPCTSTR url, String& dir_out, String& fname_out);
-
-
-#endif // __cplusplus
diff --git a/reactos/subsys/system/explorer/utility/window.cpp b/reactos/subsys/system/explorer/utility/window.cpp
deleted file mode 100644 (file)
index 1eb43bf..0000000
+++ /dev/null
@@ -1,1446 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // window.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include <precomp.h>
-
-#include "../resource.h"       // for ID_GO_BACK, ...
-
-
-WindowClass::WindowClass(LPCTSTR classname, UINT style_, WNDPROC wndproc)
-{
-       memset(this, 0, sizeof(WNDCLASSEX));
-
-       cbSize = sizeof(WNDCLASSEX);
-       style = style_;
-       hInstance = g_Globals._hInstance;
-       hCursor = LoadCursor(0, IDC_ARROW);
-
-       lpszClassName = classname;
-       lpfnWndProc = wndproc;
-
-       _atomClass = 0;
-}
-
-
-IconWindowClass::IconWindowClass(LPCTSTR classname, UINT nid, UINT style, WNDPROC wndproc)
- :     WindowClass(classname, style, wndproc)
-{
-       hIcon = ResIcon(nid);
-       hIconSm = SmallIcon(nid);
-}
-
-
-Window::WindowMap      Window::s_wnd_map;
-
-Window::CREATORFUNC    Window::s_window_creator = NULL;
-const void*                    Window::s_new_info = NULL;
-
-HHOOK                          Window::s_hcbtHook = 0;
-
-
-Window::StaticWindowData& Window::GetStaticWindowData()
-{
-       static StaticWindowData s_initialized_data;
-
-       return s_initialized_data;
-}
-
-
-Window::Window(HWND hwnd)
- :     WindowHandle(hwnd)
-{
-       Lock lock(GetStaticWindowData()._map_crit_sect);        // protect access to s_wnd_map
-
-       s_wnd_map[_hwnd] = this;
-}
-
-Window::~Window()
-{
-       Lock lock(GetStaticWindowData()._map_crit_sect);        // protect access to s_wnd_map
-
-       s_wnd_map.erase(_hwnd);
-}
-
-
-HWND Window::Create(CREATORFUNC creator, DWORD dwExStyle,
-                                       LPCTSTR lpClassName, LPCTSTR lpWindowName,
-                                       DWORD dwStyle, int x, int y, int w, int h,
-                                       HWND hwndParent, HMENU hMenu/*, LPVOID lpParam*/)
-{
-       Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-       s_window_creator = creator;
-       s_new_info = NULL;
-
-       return CreateWindowEx(dwExStyle, lpClassName, lpWindowName, dwStyle,
-                                                       x, y, w, h,
-                                                       hwndParent, hMenu, g_Globals._hInstance, 0/*lpParam*/);
-}
-
-HWND Window::Create(CREATORFUNC_INFO creator, const void* info, DWORD dwExStyle,
-                                       LPCTSTR lpClassName, LPCTSTR lpWindowName,
-                                       DWORD dwStyle, int x, int y, int w, int h,
-                                       HWND hwndParent, HMENU hMenu/*, LPVOID lpParam*/)
-{
-       Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-       s_window_creator = (CREATORFUNC) creator;
-       s_new_info = info;
-
-       return CreateWindowEx(dwExStyle, lpClassName, lpWindowName, dwStyle,
-                                                       x, y, w, h,
-                                                       hwndParent, hMenu, g_Globals._hInstance, 0/*lpParam*/);
-}
-
-
-Window* Window::create_mdi_child(const ChildWndInfo& info, const MDICREATESTRUCT& mcs, CREATORFUNC_INFO creator)
-{
-       Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-       s_window_creator = (CREATORFUNC) creator;
-       s_new_info = &info;
-
-       s_hcbtHook = SetWindowsHookEx(WH_CBT, MDICBTHookProc, 0, GetCurrentThreadId());
-
-       HWND hwnd = (HWND) SendMessage(info._hmdiclient, WM_MDICREATE, 0, (LPARAM)&mcs);
-
-       UnhookWindowsHookEx(s_hcbtHook);
-
-       Window* child = get_window(hwnd);
-       s_new_info = NULL;
-
-       if (child && (!hwnd || !child->_hwnd))
-               child = NULL;
-
-       return child;
-}
-
-LRESULT CALLBACK Window::MDICBTHookProc(int code, WPARAM wparam, LPARAM lparam)
-{
-       if (code == HCBT_CREATEWND) {
-               HWND hwnd = (HWND)wparam;
-
-                // create Window controller and associate it with the window handle
-               Window* child = get_window(hwnd);
-
-               if (!child)
-                       child = create_controller(hwnd);
-       }
-
-       return CallNextHookEx(s_hcbtHook, code, wparam, lparam);
-}
-
-
-/*
-Window* Window::create_property_sheet(PropertySheetDialog* ppsd, CREATORFUNC creator, const void* info)
-{
-       Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-       s_window_creator = creator;
-       s_new_info = info;
-
-       s_hcbtHook = SetWindowsHookEx(WH_CBT, PropSheetCBTHookProc, 0, GetCurrentThreadId());
-
-       HWND hwnd = (HWND) PropertySheet(ppsd);
-
-       UnhookWindowsHookEx(s_hcbtHook);
-
-       Window* child = get_window(hwnd);
-       s_new_info = NULL;
-
-       if (child && (!hwnd || !child->_hwnd))
-               child = NULL;
-
-       return child;
-}
-*/
-
-LRESULT CALLBACK Window::PropSheetCBTHookProc(int code, WPARAM wparam, LPARAM lparam)
-{
-       if (code == HCBT_CREATEWND) {
-               HWND hwnd = (HWND)wparam;
-
-                // create Window controller and associate it with the window handle
-               Window* child = get_window(hwnd);
-
-               if (!child)
-                       child = create_controller(hwnd);
-       }
-
-       return CallNextHookEx(s_hcbtHook, code, wparam, lparam);
-}
-
-
- /// get window controller from window handle
-
-Window* Window::get_window(HWND hwnd)
-{
-       {
-               Lock lock(GetStaticWindowData()._map_crit_sect);        // protect access to s_wnd_map
-
-               WindowMap::const_iterator found = s_wnd_map.find(hwnd);
-
-               if (found!=s_wnd_map.end())
-                       return found->second;
-       }
-
-       return NULL;
-}
-
-
- /// create controller for a new window
-
-Window* Window::create_controller(HWND hwnd)
-{
-       if (s_window_creator) { // protect for recursion and create the window object only for the first window
-               Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-               const void* info = s_new_info;
-               s_new_info = NULL;
-
-               CREATORFUNC window_creator = s_window_creator;
-               s_window_creator = NULL;
-
-               if (info)
-                       return CREATORFUNC_INFO(window_creator)(hwnd, info);
-               else
-                       return CREATORFUNC(window_creator)(hwnd);
-       }
-
-       return NULL;
-}
-
-
-LRESULT Window::Init(LPCREATESTRUCT pcs)
-{
-       return 0;
-}
-
-
-LRESULT CALLBACK Window::WindowWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       Window* pThis = get_window(hwnd);
-
-       if (!pThis)
-               pThis = create_controller(hwnd);
-
-       if (pThis) {
-               switch(nmsg) {
-                 case WM_COMMAND:
-                       return pThis->Command(LOWORD(wparam), HIWORD(wparam));
-
-                 case WM_NOTIFY:
-                       return pThis->Notify(wparam, (NMHDR*)lparam);
-
-                 case WM_NOTIFYFORMAT:
-                       return NFR_CURRENT;
-
-                 case WM_CREATE:
-                       return pThis->Init((LPCREATESTRUCT)lparam);
-
-                 case WM_NCDESTROY:
-                       delete pThis;
-                       return 0;
-
-                 default:
-                       return pThis->WndProc(nmsg, wparam, lparam);
-               }
-       }
-       else
-               return DefWindowProc(hwnd, nmsg, wparam, lparam);
-}
-
-LRESULT Window::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       return DefWindowProc(_hwnd, nmsg, wparam, lparam);
-}
-
-int Window::Command(int id, int code)
-{
-       return 1;       // no command handler found
-}
-
-int Window::Notify(int id, NMHDR* pnmh)
-{
-       return 0;
-}
-
-void Window::CancelModes()
-{
-       PostMessage(HWND_BROADCAST, WM_CANCELMODE, 0, 0);
-}
-
-
-SubclassedWindow::SubclassedWindow(HWND hwnd)
- :     super(hwnd)
-{
-       _orgWndProc = SubclassWindow(_hwnd, SubclassedWndProc);
-
-       if (!_orgWndProc)
-               delete this;
-}
-
-LRESULT CALLBACK SubclassedWindow::SubclassedWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       SubclassedWindow* pThis = GET_WINDOW(SubclassedWindow, hwnd);
-       assert(pThis);
-
-       if (pThis) {
-               switch(nmsg) {
-                 case WM_COMMAND:
-                       if (!pThis->Command(LOWORD(wparam), HIWORD(wparam)))
-                               return 0;
-                       break;
-
-                 case WM_NOTIFY:
-                       return pThis->Notify(wparam, (NMHDR*)lparam);
-
-                 case WM_NOTIFYFORMAT:
-                       return NFR_CURRENT;
-
-                 case WM_CREATE:
-                       return pThis->Init((LPCREATESTRUCT)lparam);
-
-                 case WM_NCDESTROY:
-                       delete pThis;
-                       return 0;
-
-                 default:
-                       return pThis->WndProc(nmsg, wparam, lparam);
-               }
-       }
-
-       return CallWindowProc(pThis->_orgWndProc, hwnd, nmsg, wparam, lparam);
-}
-
-LRESULT SubclassedWindow::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       return CallWindowProc(_orgWndProc, _hwnd, nmsg, wparam, lparam);
-}
-
-int SubclassedWindow::Command(int id, int code)
-{
-       return 1;       // no command handler found
-}
-
-int SubclassedWindow::Notify(int id, NMHDR* pnmh)
-{
-       return CallWindowProc(_orgWndProc, _hwnd, WM_NOTIFY, id, (LPARAM)pnmh);
-}
-
-
-ChildWindow::ChildWindow(HWND hwnd, const ChildWndInfo& info)
- :     super(hwnd),
-       _hwndFrame(GetParent(info._hmdiclient))
-{
-       _focus_pane = 0;
-       _split_pos = DEFAULT_SPLIT_POS;
-       _last_split = DEFAULT_SPLIT_POS;
-}
-
-
-ChildWindow* ChildWindow::create(const ChildWndInfo& info, const RECT& rect, CREATORFUNC_INFO creator,
-                                                                       LPCTSTR classname, LPCTSTR title, DWORD style)
-{
-       MDICREATESTRUCT mcs;
-
-       mcs.szClass = classname;
-       mcs.szTitle = title;
-       mcs.hOwner      = g_Globals._hInstance;
-       mcs.x           = rect.left,
-       mcs.y           = rect.top;
-       mcs.cx          = rect.right - rect.left;
-       mcs.cy          = rect.bottom - rect.top;
-       mcs.style       = style;
-       mcs.lParam      = 0;
-
-       return static_cast<ChildWindow*>(create_mdi_child(info, mcs, creator));
-}
-
-
-LRESULT ChildWindow::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_PAINT: {
-        RECT rc;
-               PaintCanvas canvas(_hwnd);
-               ClientRect rt(_hwnd);
-               rt.left = _split_pos-SPLIT_WIDTH/2;
-               rt.right = _split_pos+SPLIT_WIDTH/2+1;
-               HBRUSH lastBrush = SelectBrush(canvas, GetStockBrush(LTGRAY_BRUSH));
-               Rectangle(canvas, rt.left, rt.top-1, rt.right, rt.bottom+1);
-        SetRect(&rc, rt.left, rt.top-1, rt.right, rt.bottom+1);
-        DrawEdge(canvas, &rc, EDGE_RAISED, BF_RECT);
-               SelectObject(canvas, lastBrush);
-               break;}
-
-         case WM_SETCURSOR:
-               if (LOWORD(lparam) == HTCLIENT) {
-                       POINT pt;
-                       GetCursorPos(&pt);
-                       ScreenToClient(_hwnd, &pt);
-
-                       if (pt.x>=_split_pos-SPLIT_WIDTH/2 && pt.x<_split_pos+SPLIT_WIDTH/2+1) {
-                               SetCursor(LoadCursor(0, IDC_SIZEWE));
-                               return TRUE;
-                       }
-               }
-               goto def;
-
-         case WM_SIZE:
-               if (wparam != SIZE_MINIMIZED)
-                       resize_children(LOWORD(lparam), HIWORD(lparam));
-               goto def;
-
-         case WM_GETMINMAXINFO:
-               DefMDIChildProc(_hwnd, nmsg, wparam, lparam);
-
-               {LPMINMAXINFO lpmmi = (LPMINMAXINFO)lparam;
-
-               lpmmi->ptMaxTrackSize.x <<= 1;  // 2*GetSystemMetrics(SM_CXSCREEN) / SM_CXVIRTUALSCREEN
-               lpmmi->ptMaxTrackSize.y <<= 1;  // 2*GetSystemMetrics(SM_CYSCREEN) / SM_CYVIRTUALSCREEN
-               break;}
-
-         case WM_LBUTTONDOWN: {
-               int x = GET_X_LPARAM(lparam);
-
-               ClientRect rt(_hwnd);
-
-               if (x>=_split_pos-SPLIT_WIDTH/2 && x<_split_pos+SPLIT_WIDTH/2+1) {
-                       _last_split = _split_pos;
-                       SetCapture(_hwnd);
-               }
-
-               break;}
-
-         case WM_LBUTTONUP:
-               if (GetCapture() == _hwnd)
-                       ReleaseCapture();
-               break;
-
-         case WM_KEYDOWN:
-               if (wparam == VK_ESCAPE)
-                       if (GetCapture() == _hwnd) {
-                               _split_pos = _last_split;
-                               ClientRect rt(_hwnd);
-                               resize_children(rt.right, rt.bottom);
-                               _last_split = -1;
-                               ReleaseCapture();
-                               SetCursor(LoadCursor(0, IDC_ARROW));
-                       }
-               break;
-
-         case WM_MOUSEMOVE:
-               if (GetCapture() == _hwnd) {
-                       int x = GET_X_LPARAM(lparam);
-
-                       ClientRect rt(_hwnd);
-
-                       if (x>=0 && x<rt.right) {
-                               _split_pos = x;
-                               resize_children(rt.right, rt.bottom);
-                               rt.left = x-SPLIT_WIDTH/2;
-                               rt.right = x+SPLIT_WIDTH/2+1;
-                               InvalidateRect(_hwnd, &rt, FALSE);
-                               UpdateWindow(_left_hwnd);
-                               UpdateWindow(_hwnd);
-                               UpdateWindow(_right_hwnd);
-                       }
-               }
-               break;
-
-         case PM_DISPATCH_COMMAND:
-               switch(LOWORD(wparam)) {
-                 case ID_GO_BACK:
-                       if (!_url_history.empty()) {
-                               const String& url = jump_to_int(_url_history.top());
-
-                               if (jump_to_int(url))
-                                       set_url(url);
-
-                               _url_history.pop();
-                       }
-                       break;
-
-                 case ID_GO_FORWARD:
-                       //@@
-                       break;
-
-                 case ID_GO_UP:
-                       ///@todo
-                       break;
-
-                 case ID_GO_HOME:
-                       //@@
-                       break;
-
-                 default:
-                       return FALSE;
-               }
-               return TRUE;
-
-         case WM_MDIACTIVATE:
-               if ((HWND)lparam == _hwnd) {
-                       SendMessage(_hwndFrame, PM_SETSTATUSTEXT, 0, (LPARAM)_statusText.c_str());
-                       SendMessage(_hwndFrame, PM_URL_CHANGED, 0, (LPARAM)_url.c_str());
-               }
-               break;
-
-         case PM_JUMP_TO_URL:
-               return go_to((LPCTSTR)lparam)? TRUE: FALSE;
-
-         default: def:
-               return DefMDIChildProc(_hwnd, nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-
-void ChildWindow::resize_children(int cx, int cy)
-{
-       HDWP hdwp = BeginDeferWindowPos(2);
-       RECT rt;
-
-       rt.left   = 0;
-       rt.top    = 0;
-       rt.right  = cx;
-       rt.bottom = cy;
-
-       if (_left_hwnd) {
-               cx = _split_pos + SPLIT_WIDTH/2;
-
-               hdwp = DeferWindowPos(hdwp, _left_hwnd, 0, rt.left, rt.top, _split_pos-SPLIT_WIDTH/2-rt.left, rt.bottom-rt.top, SWP_NOZORDER|SWP_NOACTIVATE);
-       } else {
-               _split_pos = 0;
-               cx = 0;
-       }
-
-       if (_right_hwnd)
-               hdwp = DeferWindowPos(hdwp, _right_hwnd, 0, rt.left+cx+1, rt.top, rt.right-cx, rt.bottom-rt.top, SWP_NOZORDER|SWP_NOACTIVATE);
-
-       EndDeferWindowPos(hdwp);
-}
-
-
-bool ChildWindow::go_to(LPCTSTR url)
-{
-       const String& url_str = jump_to_int(url);
-
-       if (!url_str.empty()) {
-               set_url(url_str);
-
-               _url_history.push(url_str);
-
-               return true;
-       } else
-               return false;
-}
-
-void ChildWindow::set_url(LPCTSTR url)
-{
-       if (_url != url) {
-               _url = url;
-
-               SendMessage(_hwndFrame, PM_URL_CHANGED, 0, (LPARAM)url);
-       }
-}
-
-
-WindowSet Window::s_pretranslate_windows;
-
-void Window::register_pretranslate(HWND hwnd)
-{
-       s_pretranslate_windows.insert(hwnd);
-}
-
-void Window::unregister_pretranslate(HWND hwnd)
-{
-       s_pretranslate_windows.erase(hwnd);
-}
-
-BOOL Window::pretranslate_msg(LPMSG pmsg)
-{
-       for(WindowSet::const_iterator it=Window::s_pretranslate_windows.begin(); it!=s_pretranslate_windows.end(); ++it)
-               if (SendMessage(*it, PM_TRANSLATE_MSG, 0, (LPARAM)pmsg))
-                       return TRUE;
-
-       return FALSE;
-}
-
-
-WindowSet Window::s_dialogs;
-
-void Window::register_dialog(HWND hwnd)
-{
-       s_dialogs.insert(hwnd);
-}
-
-void Window::unregister_dialog(HWND hwnd)
-{
-       s_dialogs.erase(hwnd);
-}
-
-BOOL Window::dispatch_dialog_msg(MSG* pmsg)
-{
-       for(WindowSet::const_iterator it=Window::s_dialogs.begin(); it!=s_dialogs.end(); ++it)
-               if (IsDialogMessage(*it, pmsg))
-                       return TRUE;
-
-       return FALSE;
-}
-
-
-int Window::MessageLoop()
-{
-       MSG msg;
-
-       while(GetMessage(&msg, 0, 0, 0)) {
-               try {
-                       if (pretranslate_msg(&msg))
-                               continue;
-
-                       if (dispatch_dialog_msg(&msg))
-                               continue;
-
-                       TranslateMessage(&msg);
-
-                       try {
-                               DispatchMessage(&msg);
-                       } catch(COMException& e) {
-                               HandleException(e, 0);
-                       }
-               } catch(COMException& e) {
-                       HandleException(e, 0);
-               }
-       }
-
-       return msg.wParam;
-}
-
-
-LRESULT        Window::SendParent(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       HWND parent = GetParent(_hwnd);
-
-       if (!parent)
-               return 0;
-
-       return SendMessage(parent, nmsg, wparam, lparam);
-}
-
-LRESULT        Window::PostParent(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       HWND parent = GetParent(_hwnd);
-
-       if (!parent)
-               return 0;
-
-       return PostMessage(parent, nmsg, wparam, lparam);
-}
-
-
-PreTranslateWindow::PreTranslateWindow(HWND hwnd)
- :     super(hwnd)
-{
-       register_pretranslate(hwnd);
-}
-
-PreTranslateWindow::~PreTranslateWindow()
-{
-       unregister_pretranslate(_hwnd);
-}
-
-
-Dialog::Dialog(HWND hwnd)
- :     super(hwnd)
-{
-       register_dialog(hwnd);
-}
-
-Dialog::~Dialog()
-{
-       unregister_dialog(_hwnd);
-}
-
-int Dialog::DoModal(UINT nid, CREATORFUNC creator, HWND hwndParent)
-{
-       Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-       s_window_creator = creator;
-       s_new_info = NULL;
-
-       ///@todo call Window::pretranslate_msg()
-
-       return DialogBoxParam(g_Globals._hInstance, MAKEINTRESOURCE(nid), hwndParent, DialogProc, 0/*lpParam*/);
-}
-
-int Dialog::DoModal(UINT nid, CREATORFUNC_INFO creator, const void* info, HWND hwndParent)
-{
-       Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-       s_window_creator = (CREATORFUNC) creator;
-       s_new_info = NULL;
-
-       ///@todo call Window::pretranslate_msg()
-
-       return DialogBoxParam(g_Globals._hInstance, MAKEINTRESOURCE(nid), hwndParent, DialogProc, 0/*lpParam*/);
-}
-
-INT_PTR CALLBACK Window::DialogProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       Window* pThis = get_window(hwnd);
-
-       if (pThis) {
-               switch(nmsg) {
-                 case WM_COMMAND:
-                       pThis->Command(LOWORD(wparam), HIWORD(wparam));
-                       return TRUE;    // message has been processed
-
-                 case WM_NOTIFY:
-                       pThis->Notify(wparam, (NMHDR*)lparam);
-                       return TRUE;    // message has been processed
-
-                 case WM_NOTIFYFORMAT:
-                       SetWindowLong(hwnd, DWLP_MSGRESULT, NFR_CURRENT);       // set return value NFR_CURRENT
-                       return TRUE;    // message has been processed
-
-                 case WM_NCDESTROY:
-                       delete pThis;
-                       return TRUE;    // message has been processed
-
-                 default:
-                       return pThis->WndProc(nmsg, wparam, lparam);
-               }
-       } else if (nmsg == WM_INITDIALOG) {
-               pThis = create_controller(hwnd);
-
-               if (pThis)
-                       return pThis->Init(NULL);
-       }
-
-       return FALSE;   // message has not been processed
-}
-
-LRESULT Dialog::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       return FALSE;   // message has not been processed
-}
-
-int Dialog::Command(int id, int code)
-{
-       if (code == BN_CLICKED) {
-               EndDialog(_hwnd, id);
-               return 0;       // message has been processed
-       }
-
-       return 1;
-}
-
-
-ResizeManager::ResizeManager(HWND hwnd)
- :     _hwnd(hwnd)
-{
-       ClientRect clnt(hwnd);
-       _last_size.cx = clnt.right;
-       _last_size.cy = clnt.bottom;
-
-       WindowRect rect(hwnd);
-       _min_wnd_size.cx = rect.right - rect.left;
-       _min_wnd_size.cy = rect.bottom - rect.top;
-}
-
-void ResizeManager::HandleSize(int cx, int cy)
-{
-       ClientRect clnt_rect(_hwnd);
-       SIZE new_size = {cx, cy};
-
-       int dx = new_size.cx - _last_size.cx;
-       int dy = new_size.cy - _last_size.cy;
-
-       if (!dx && !dy)
-               return;
-
-       _last_size = new_size;
-
-       HDWP hDWP = BeginDeferWindowPos(size());
-
-       for(ResizeManager::const_iterator it=begin(); it!=end(); ++it) {
-               const ResizeEntry& e = *it;
-               RECT move = {0};
-
-               if (e._flags & MOVE_LEFT)
-                       move.left += dx;
-
-               if (e._flags & MOVE_RIGHT)
-                       move.right += dx;
-
-               if (e._flags & MOVE_TOP)
-                       move.top += dy;
-
-               if (e._flags & MOVE_BOTTOM)
-                       move.bottom += dy;
-
-               UINT flags = 0;
-
-               if (!move.left && !move.top)
-                       flags = SWP_NOMOVE;
-
-               if (move.right==move.left && move.bottom==move.top)
-                       flags |= SWP_NOSIZE;
-
-               if (flags != (SWP_NOMOVE|SWP_NOSIZE)) {
-                       HWND hwnd = GetDlgItem(_hwnd, e._id);
-
-                       if (hwnd) {
-                               WindowRect rect(hwnd);
-                               ScreenToClient(_hwnd, rect);
-
-                               rect.left       += move.left;
-                               rect.right      += move.right;
-                               rect.top        += move.top;
-                               rect.bottom     += move.bottom;
-
-                               hDWP = DeferWindowPos(hDWP, hwnd, 0, rect.left, rect.top, rect.right-rect.left, rect.bottom-rect.top, flags|SWP_NOACTIVATE|SWP_NOZORDER);
-                       }
-               }
-       }
-
-       EndDeferWindowPos(hDWP);
-}
-
-void ResizeManager::Resize(int dx, int dy)
-{
-       ::SetWindowPos(_hwnd, 0, 0, 0, _min_wnd_size.cx+dx, _min_wnd_size.cy+dy, SWP_NOMOVE|SWP_NOACTIVATE);
-       MoveVisible(_hwnd);
-
-       ClientRect clnt_rect(_hwnd);
-       HandleSize(clnt_rect.right, clnt_rect.bottom);
-}
-
-
-Button::Button(HWND parent, LPCTSTR title, int left, int top, int width, int height,
-                               int id, DWORD flags, DWORD exStyle)
- :     WindowHandle(CreateWindowEx(exStyle, TEXT("BUTTON"), title, flags, left, top, width, height,
-                                                       parent, (HMENU)id, g_Globals._hInstance, 0))
-{
-}
-
-
-LRESULT OwnerdrawnButton::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       if (nmsg == PM_DISPATCH_DRAWITEM) {
-               DrawItem((LPDRAWITEMSTRUCT)lparam);
-               return TRUE;
-       } else
-               return super::WndProc(nmsg, wparam, lparam);
-}
-
-
-Static::Static(HWND parent, LPCTSTR title, int left, int top, int width, int height,
-                               int id, DWORD flags, DWORD exStyle)
- :     WindowHandle(CreateWindowEx(exStyle, TEXT("STATIC"), title, flags, left, top, width, height,
-                                                       parent, (HMENU)id, g_Globals._hInstance, 0))
-{
-}
-
-
-static RECT s_MyDrawText_Rect = {0, 0, 0, 0};
-
-static BOOL CALLBACK MyDrawText(HDC hdc, LPARAM data, int cnt)
-{
-       ::DrawText(hdc, (LPCTSTR)data, cnt, &s_MyDrawText_Rect, DT_SINGLELINE);
-       return TRUE;
-}
-
-void DrawGrayText(HDC hdc, LPRECT pRect, LPCTSTR title, int dt_flags)
-{
-       COLORREF gray = GetSysColor(COLOR_GRAYTEXT);
-
-       if (gray) {
-               TextColor lcColor(hdc, GetSysColor(COLOR_BTNHIGHLIGHT));
-               RECT shadowRect = {pRect->left+1, pRect->top+1, pRect->right+1, pRect->bottom+1};
-               DrawText(hdc, title, -1, &shadowRect, dt_flags);
-
-               SetTextColor(hdc, gray);
-               DrawText(hdc, title, -1, pRect, dt_flags);
-       } else {
-               int old_r = pRect->right;
-               int old_b = pRect->bottom;
-
-               DrawText(hdc, title, -1, pRect, dt_flags|DT_CALCRECT);
-
-               int x = pRect->left + (old_r-pRect->right)/2;
-               int y = pRect->top + (old_b-pRect->bottom)/2;
-               int w = pRect->right-pRect->left;
-               int h = pRect->bottom-pRect->top;
-               s_MyDrawText_Rect.right = w;
-               s_MyDrawText_Rect.bottom = h;
-
-               GrayString(hdc, GetSysColorBrush(COLOR_GRAYTEXT), MyDrawText, (LPARAM)title, -1, x, y, w, h);
-       }
-}
-
-
-/* not yet used
-void ColorButton::DrawItem(LPDRAWITEMSTRUCT dis)
-{
-       UINT state = DFCS_BUTTONPUSH;
-
-       if (dis->itemState & ODS_DISABLED)
-               state |= DFCS_INACTIVE;
-
-       RECT textRect = {dis->rcItem.left+2, dis->rcItem.top+2, dis->rcItem.right-4, dis->rcItem.bottom-4};
-
-       if (dis->itemState & ODS_SELECTED) {
-               state |= DFCS_PUSHED;
-               ++textRect.left;        ++textRect.top;
-               ++textRect.right;       ++textRect.bottom;
-       }
-
-       DrawFrameControl(dis->hDC, &dis->rcItem, DFC_BUTTON, state);
-
-       TCHAR title[BUFFER_LEN];
-       GetWindowText(_hwnd, title, BUFFER_LEN);
-
-       BkMode bk_mode(dis->hDC, TRANSPARENT);
-
-       if (dis->itemState & (ODS_DISABLED|ODS_GRAYED))
-               DrawGrayText(dis, &textRect, title, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
-       else {
-               TextColor lcColor(dis->hDC, _textColor);
-               DrawText(dis->hDC, title, -1, &textRect, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
-       }
-
-       if (dis->itemState & ODS_FOCUS) {
-               RECT rect = {
-                       dis->rcItem.left+3, dis->rcItem.top+3,
-                       dis->rcItem.right-dis->rcItem.left-4, dis->rcItem.bottom-dis->rcItem.top-4
-               };
-               if (dis->itemState & ODS_SELECTED) {
-                       ++rect.left;    ++rect.top;
-                       ++rect.right;   ++rect.bottom;
-               }
-               DrawFocusRect(dis->hDC, &rect);
-       }
-}
-*/
-
-
-void PictureButton::DrawItem(LPDRAWITEMSTRUCT dis)
-{
-       UINT state = DFCS_BUTTONPUSH;
-       int style = GetWindowStyle(_hwnd);
-
-       if (dis->itemState & ODS_DISABLED)
-               state |= DFCS_INACTIVE;
-
-       POINT imagePos;
-       RECT textRect;
-       int dt_flags;
-
-       if (style & BS_BOTTOM) {
-                // align horizontal centered, vertical floating
-               imagePos.x = (dis->rcItem.left + dis->rcItem.right - _cx) / 2;
-               imagePos.y = dis->rcItem.top + 3;
-
-               textRect.left = dis->rcItem.left + 2;
-               textRect.top = dis->rcItem.top + _cy + 4;
-               textRect.right = dis->rcItem.right - 4;
-               textRect.bottom = dis->rcItem.bottom - 4;
-
-               dt_flags = DT_SINGLELINE|DT_CENTER|DT_VCENTER;
-       } else {
-                // horizontal floating, vertical centered
-               imagePos.x = dis->rcItem.left + 3;
-               imagePos.y = (dis->rcItem.top + dis->rcItem.bottom - _cy)/2;
-
-               textRect.left = dis->rcItem.left + _cx + 4;
-               textRect.top = dis->rcItem.top + 2;
-               textRect.right = dis->rcItem.right - 4;
-               textRect.bottom = dis->rcItem.bottom - 4;
-
-               dt_flags = DT_SINGLELINE|DT_VCENTER/*|DT_CENTER*/;
-       }
-
-       if (dis->itemState & ODS_SELECTED) {
-               state |= DFCS_PUSHED;
-               ++imagePos.x;           ++imagePos.y;
-               ++textRect.left;        ++textRect.top;
-               ++textRect.right;       ++textRect.bottom;
-       }
-
-       if (_flat) {
-               FillRect(dis->hDC, &dis->rcItem, _hBrush);
-
-               if (style & BS_FLAT)    // Only with BS_FLAT set, there will be drawn a frame without highlight.
-                       DrawEdge(dis->hDC, &dis->rcItem, EDGE_RAISED, BF_RECT|BF_FLAT);
-       } else
-               DrawFrameControl(dis->hDC, &dis->rcItem, DFC_BUTTON, state);
-
-       if (_hIcon)
-               DrawIconEx(dis->hDC, imagePos.x, imagePos.y, _hIcon, _cx, _cy, 0, _hBrush, DI_NORMAL);
-       else {
-               MemCanvas mem_dc;
-               BitmapSelection sel(mem_dc, _hBmp);
-               BitBlt(dis->hDC, imagePos.x, imagePos.y, _cx, _cy, mem_dc, 0, 0, SRCCOPY);
-       }
-
-       TCHAR title[BUFFER_LEN];
-       GetWindowText(_hwnd, title, BUFFER_LEN);
-
-       BkMode bk_mode(dis->hDC, TRANSPARENT);
-
-       if (dis->itemState & (ODS_DISABLED|ODS_GRAYED))
-               DrawGrayText(dis->hDC, &textRect, title, dt_flags);
-       else {
-               TextColor lcColor(dis->hDC, GetSysColor(COLOR_BTNTEXT));
-               DrawText(dis->hDC, title, -1, &textRect, dt_flags);
-       }
-
-       if (dis->itemState & ODS_FOCUS) {
-               RECT rect = {
-                       dis->rcItem.left+3, dis->rcItem.top+3,
-                       dis->rcItem.right-dis->rcItem.left-4, dis->rcItem.bottom-dis->rcItem.top-4
-               };
-               if (dis->itemState & ODS_SELECTED) {
-                       ++rect.left;    ++rect.top;
-                       ++rect.right;   ++rect.bottom;
-               }
-               DrawFocusRect(dis->hDC, &rect);
-       }
-}
-
-
-void FlatButton::DrawItem(LPDRAWITEMSTRUCT dis)
-{
-       UINT style = DFCS_BUTTONPUSH;
-
-       if (dis->itemState & ODS_DISABLED)
-               style |= DFCS_INACTIVE;
-
-       RECT textRect = {dis->rcItem.left+2, dis->rcItem.top+2, dis->rcItem.right-4, dis->rcItem.bottom-4};
-
-       if (dis->itemState & ODS_SELECTED) {
-               style |= DFCS_PUSHED;
-               ++textRect.left;        ++textRect.top;
-               ++textRect.right;       ++textRect.bottom;
-       }
-
-       FillRect(dis->hDC, &dis->rcItem, GetSysColorBrush(COLOR_BTNFACE));
-
-        // highlight the button?
-       if (_active)
-               DrawEdge(dis->hDC, &dis->rcItem, EDGE_ETCHED, BF_RECT);
-       else if (GetWindowStyle(_hwnd) & BS_FLAT)       // Only with BS_FLAT there will be drawn a frame to show highlighting.
-               DrawEdge(dis->hDC, &dis->rcItem, EDGE_RAISED, BF_RECT|BF_FLAT);
-
-       TCHAR txt[BUFFER_LEN];
-       int txt_len = GetWindowText(_hwnd, txt, BUFFER_LEN);
-
-       if (dis->itemState & (ODS_DISABLED|ODS_GRAYED)) {
-               COLORREF gray = GetSysColor(COLOR_GRAYTEXT);
-
-               if (gray) {
-                       {
-                       TextColor lcColor(dis->hDC, GetSysColor(COLOR_BTNHIGHLIGHT));
-                       RECT shadowRect = {textRect.left+1, textRect.top+1, textRect.right+1, textRect.bottom+1};
-                       DrawText(dis->hDC, txt, txt_len, &shadowRect, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
-                       }
-
-                       BkMode mode(dis->hDC, TRANSPARENT);
-                       TextColor lcColor(dis->hDC, gray);
-                       DrawText(dis->hDC, txt, txt_len, &textRect, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
-               } else {
-                       int old_r = textRect.right;
-                       int old_b = textRect.bottom;
-                       DrawText(dis->hDC, txt, txt_len, &textRect, DT_SINGLELINE|DT_VCENTER|DT_CENTER|DT_CALCRECT);
-                       int x = textRect.left + (old_r-textRect.right)/2;
-                       int y = textRect.top + (old_b-textRect.bottom)/2;
-                       int w = textRect.right-textRect.left;
-                       int h = textRect.bottom-textRect.top;
-                       s_MyDrawText_Rect.right = w;
-                       s_MyDrawText_Rect.bottom = h;
-                       GrayString(dis->hDC, GetSysColorBrush(COLOR_GRAYTEXT), MyDrawText, (LPARAM)txt, txt_len, x, y, w, h);
-               }
-       } else {
-               TextColor lcColor(dis->hDC, _active? _activeColor: _textColor);
-               DrawText(dis->hDC, txt, txt_len, &textRect, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
-       }
-
-       if (dis->itemState & ODS_FOCUS) {
-               RECT rect = {
-                       dis->rcItem.left+3, dis->rcItem.top+3,
-                       dis->rcItem.right-dis->rcItem.left-4, dis->rcItem.bottom-dis->rcItem.top-4
-               };
-               if (dis->itemState & ODS_SELECTED) {
-                       ++rect.left;    ++rect.top;
-                       ++rect.right;   ++rect.bottom;
-               }
-               DrawFocusRect(dis->hDC, &rect);
-       }
-}
-
-LRESULT        FlatButton::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_MOUSEMOVE: {
-               bool active = false;
-
-               if (IsWindowEnabled(_hwnd)) {
-                       DWORD pid_foreground;
-                       HWND hwnd_foreground = GetForegroundWindow();   //@@ may be better look for WM_ACTIVATEAPP ?
-                       GetWindowThreadProcessId(hwnd_foreground, &pid_foreground);
-
-                       if (GetCurrentProcessId() == pid_foreground) {
-                               POINT pt = {GET_X_LPARAM(lparam), GET_Y_LPARAM(lparam)};
-                               ClientRect clntRect(_hwnd);
-
-                                // highlight the button?
-                               if (pt.x>=clntRect.left && pt.x<clntRect.right && pt.y>=clntRect.top && pt.y<clntRect.bottom)
-                                       active = true;
-                       }
-               }
-
-               if (active != _active) {
-                       _active = active;
-
-                       if (active) {
-                               TRACKMOUSEEVENT tme = {sizeof(tme), /*TME_HOVER|*/TME_LEAVE, _hwnd/*, HOVER_DEFAULT*/};
-                               _TrackMouseEvent(&tme);
-                       }
-
-                       InvalidateRect(_hwnd, NULL, TRUE);
-               }
-
-               return 0;}
-
-         case WM_LBUTTONUP: {
-               POINT pt = {GET_X_LPARAM(lparam), GET_Y_LPARAM(lparam)};
-               ClientRect clntRect(_hwnd);
-
-                // no more in the active rectangle?
-               if (pt.x<clntRect.left || pt.x>=clntRect.right || pt.y<clntRect.top || pt.y>=clntRect.bottom)
-                       goto cancel_press;
-
-               goto def;}
-
-         case WM_CANCELMODE:
-         cancel_press: {
-               TRACKMOUSEEVENT tme = {sizeof(tme), /*TME_HOVER|*/TME_LEAVE|TME_CANCEL, _hwnd/*, HOVER_DEFAULT*/};
-               _TrackMouseEvent(&tme);
-               _active = false;
-               ReleaseCapture();}
-               // fall through
-
-         case WM_MOUSELEAVE:
-               if (_active) {
-                       _active = false;
-
-                       InvalidateRect(_hwnd, NULL, TRUE);
-               }
-
-               return 0;
-
-         default: def:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-}
-
-
-HyperlinkCtrl::HyperlinkCtrl(HWND hwnd, COLORREF colorLink, COLORREF colorVisited)
- :     super(hwnd),
-       _cmd(ResString(GetDlgCtrlID(hwnd))),
-       _textColor(colorLink),
-       _colorVisited(colorVisited),
-       _hfont(0),
-       _crsr_link(0)
-{
-       init();
-}
-
-HyperlinkCtrl::HyperlinkCtrl(HWND owner, int id, COLORREF colorLink, COLORREF colorVisited)
- :     super(GetDlgItem(owner, id)),
-       _cmd(ResString(id)),
-       _textColor(colorLink),
-       _colorVisited(colorVisited),
-       _hfont(0),
-       _crsr_link(0)
-{
-       init();
-}
-
-void HyperlinkCtrl::init()
-{
-       if (_cmd.empty()) {
-               TCHAR txt[BUFFER_LEN];
-               _cmd.assign(txt, GetWindowText(_hwnd, txt, BUFFER_LEN));
-       }
-}
-
-HyperlinkCtrl::~HyperlinkCtrl()
-{
-       if (_hfont)
-               DeleteObject(_hfont);
-}
-
-LRESULT HyperlinkCtrl::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case PM_DISPATCH_CTLCOLOR: {
-               if (!_hfont) {
-                       HFONT hfont = (HFONT) SendMessage(_hwnd, WM_GETFONT, 0, 0);
-                       LOGFONT lf; GetObject(hfont, sizeof(lf), &lf);
-                       lf.lfUnderline = TRUE;
-                       _hfont = CreateFontIndirect(&lf);
-               }
-
-               HDC hdc = (HDC) wparam;
-               SetTextColor(hdc, _textColor);  //@@
-               SelectFont(hdc, _hfont);
-               SetBkMode(hdc, TRANSPARENT);
-               return (LRESULT)GetStockObject(HOLLOW_BRUSH);
-         }
-
-         case WM_SETCURSOR:
-               if (!_crsr_link)
-                       _crsr_link = LoadCursor(0, IDC_HAND);
-
-               if (_crsr_link)
-                       SetCursor(_crsr_link);
-               return 0;
-
-         case WM_NCHITTEST:
-               return HTCLIENT;        // Aktivierung von Maus-Botschaften
-
-         case WM_LBUTTONDOWN:
-               if (LaunchLink()) {
-                       _textColor = _colorVisited;
-                       InvalidateRect(_hwnd, NULL, FALSE);
-               } else
-                       MessageBeep(0);
-               return 0;
-
-         default:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-}
-
-
-ToolTip::ToolTip(HWND owner)
- :     super(CreateWindowEx(WS_EX_TOPMOST|WS_EX_NOPARENTNOTIFY, TOOLTIPS_CLASS, 0,
-                                WS_POPUP|TTS_NOPREFIX|TTS_ALWAYSTIP, CW_USEDEFAULT,CW_USEDEFAULT,CW_USEDEFAULT,CW_USEDEFAULT,
-                                owner, 0, g_Globals._hInstance, 0))
-{
-       activate();
-}
-
-
-ListSort::ListSort(HWND hwndListview, PFNLVCOMPARE compare_fct)
- :     WindowHandle(hwndListview),
-       _compare_fct(compare_fct)
-{
-       _sort_crit = 0;
-       _direction = false;
-}
-
-void ListSort::toggle_sort(int idx)
-{
-       if (_sort_crit == idx)
-               _direction = !_direction;
-       else {
-               _sort_crit = idx;
-               _direction = false;
-       }
-}
-
-void ListSort::sort()
-{
-       int idx = ListView_GetSelectionMark(_hwnd);
-       LPARAM param = ListView_GetItemData(_hwnd, idx);
-
-       ListView_SortItems(_hwnd, _compare_fct, (LPARAM)this);
-
-       if (idx >= 0) {
-               idx = ListView_FindItemPara(_hwnd, param);
-               ListView_EnsureVisible(_hwnd, idx, FALSE);
-       }
-}
-
-
-PropSheetPage::PropSheetPage(UINT nid, Window::CREATORFUNC dlg_creator)
- :     _dlg_creator(dlg_creator)
-{
-       PROPSHEETPAGE::dwSize           = sizeof(PROPSHEETPAGE);
-       PROPSHEETPAGE::dwFlags          = 0;
-       PROPSHEETPAGE::hInstance        = g_Globals._hInstance;
-       PROPSHEETPAGE::pszTemplate      = MAKEINTRESOURCE(nid);
-       PROPSHEETPAGE::pfnDlgProc       = PropSheetPageDlg::DialogProc;
-       PROPSHEETPAGE::lParam           = (LPARAM) this;
-}
-
-
-#ifndef PSM_GETRESULT  // currently (as of 18.01.2004) missing in MinGW headers
-#define PSM_GETRESULT                          (WM_USER + 135)
-#define PropSheet_GetResult(hDlg)      SNDMSG(hDlg, PSM_GETRESULT, 0, 0)
-#endif
-
-
-PropertySheetDialog::PropertySheetDialog(HWND owner)
- :     _hwnd(0)
-{
-       PROPSHEETHEADER::dwSize = sizeof(PROPSHEETHEADER);
-       PROPSHEETHEADER::dwFlags = PSH_PROPSHEETPAGE | PSH_MODELESS;
-       PROPSHEETHEADER::hwndParent = owner;
-       PROPSHEETHEADER::hInstance = g_Globals._hInstance;
-}
-
-void PropertySheetDialog::add(PropSheetPage& psp)
-{
-       _pages.push_back(psp);
-}
-
-int    PropertySheetDialog::DoModal(int start_page)
-{
-       PROPSHEETHEADER::ppsp = (LPCPROPSHEETPAGE) &_pages[0];
-       PROPSHEETHEADER::nPages = _pages.size();
-       PROPSHEETHEADER::nStartPage = start_page;
-/*
-       Window* pwnd = Window::create_property_sheet(this, WINDOW_CREATOR(PropertySheetDlg), NULL);
-       if (!pwnd)
-               return -1;
-
-       HWND hwndPropSheet = *pwnd;
-*/
-       int ret = PropertySheet(this);
-       if (ret == -1)
-               return -1;
-
-       HWND hwndPropSheet = (HWND) ret;
-       HWND hwndparent = GetParent(hwndPropSheet);
-
-       if (hwndparent)
-               EnableWindow(hwndparent, FALSE);
-
-       ret = 0;
-       MSG msg;
-
-       while(GetMessage(&msg, 0, 0, 0)) {
-               try {
-                       if (Window::pretranslate_msg(&msg))
-                               continue;
-
-                       if (PropSheet_IsDialogMessage(hwndPropSheet, &msg))
-                               continue;
-
-                       if (Window::dispatch_dialog_msg(&msg))
-                               continue;
-
-                       TranslateMessage(&msg);
-
-                       try {
-                               DispatchMessage(&msg);
-                       } catch(COMException& e) {
-                               HandleException(e, 0);
-                       }
-
-                       if (!PropSheet_GetCurrentPageHwnd(hwndPropSheet)) {
-                               ret = PropSheet_GetResult(hwndPropSheet);
-                               break;
-                       }
-               } catch(COMException& e) {
-                       HandleException(e, 0);
-               }
-       }
-
-       if (hwndparent)
-               EnableWindow(hwndparent, TRUE);
-
-       DestroyWindow(hwndPropSheet);
-
-       return ret;
-}
-
-HWND PropertySheetDialog::GetCurrentPage()
-{
-       HWND hdlg = PropSheet_GetCurrentPageHwnd(_hwnd);
-       return hdlg;
-}
-
-
-PropSheetPageDlg::PropSheetPageDlg(HWND hwnd)
- :     super(hwnd)
-{
-}
-
-INT_PTR CALLBACK PropSheetPageDlg::DialogProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       PropSheetPageDlg* pThis = GET_WINDOW(PropSheetPageDlg, hwnd);
-
-       if (pThis) {
-               switch(nmsg) {
-                 case WM_COMMAND:
-                       pThis->Command(LOWORD(wparam), HIWORD(wparam));
-                       return TRUE;    // message has been processed
-
-                 case WM_NOTIFY:
-                       pThis->Notify(wparam, (NMHDR*)lparam);
-                       return TRUE;    // message has been processed
-
-                 case WM_NOTIFYFORMAT:
-                       SetWindowLong(hwnd, DWLP_MSGRESULT, NFR_CURRENT);       // set return value NFR_CURRENT
-                       return TRUE;    // message has been processed
-
-                 case WM_NCDESTROY:
-                       delete pThis;
-                       return TRUE;    // message has been processed
-
-                 default:
-                       return pThis->WndProc(nmsg, wparam, lparam);
-               }
-       } else if (nmsg == WM_INITDIALOG) {
-               PROPSHEETPAGE* psp = (PROPSHEETPAGE*) lparam;
-               PropSheetPage* ppsp = (PropSheetPage*) psp->lParam;
-
-               if (ppsp->_dlg_creator) {
-                       pThis = static_cast<PropSheetPageDlg*>(ppsp->_dlg_creator(hwnd));
-
-                       if (pThis)
-                               return pThis->Init(NULL);
-               }
-       }
-
-       return FALSE;   // message has not been processed
-}
-
-int PropSheetPageDlg::Command(int id, int code)
-{
-       // override call to EndDialog in Dialog::Command();
-
-       return FALSE;
-}
diff --git a/reactos/subsys/system/explorer/utility/window.h b/reactos/subsys/system/explorer/utility/window.h
deleted file mode 100644 (file)
index 4d2a8b4..0000000
+++ /dev/null
@@ -1,1119 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // window.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-typedef set<HWND> WindowSet;
-
-
- /*
-       Classes are declared using "struct", not "class" because the default
-       access mode is "public". This way we can list the member functions in a
-       natural order without explicitly specifying any access mode at the begin
-       of the definition.
-       First are public constructors and destructor, then public member functions.
-       After that we list protected member varibables and functions. If needed,
-       private implemenation varibales and functions are positioned at the end.
- */
-
-
- /// information structure for creation of a MDI child window
-struct ChildWndInfo
-{
-       ChildWndInfo(HWND hmdiclient)
-        :      _hmdiclient(hmdiclient) {}
-
-       HWND    _hmdiclient;
-};
-
-
- /**
-       Class Window is the base class for several C++ window wrapper classes.
-       Window objects are allocated from the heap. They are automatically freed
-       when the window gets destroyed.
- */
-struct Window : public WindowHandle
-{
-       Window(HWND hwnd);
-       virtual ~Window();
-
-
-       typedef map<HWND,Window*> WindowMap;
-
-       typedef Window* (*CREATORFUNC)(HWND);
-       typedef Window* (*CREATORFUNC_INFO)(HWND, const void*);
-
-       static HWND Create(CREATORFUNC creator,
-                               DWORD dwExStyle, LPCTSTR lpClassName, LPCTSTR lpWindowName,
-                               DWORD dwStyle, int x, int y, int w, int h,
-                               HWND hwndParent=0, HMENU hMenu=0/*, LPVOID lpParam=0*/);
-
-       static HWND Create(CREATORFUNC_INFO creator, const void* info,
-                               DWORD dwExStyle, LPCTSTR lpClassName, LPCTSTR lpWindowName,
-                               DWORD dwStyle, int x, int y, int w, int h,
-                               HWND hwndParent=0, HMENU hMenu=0/*, LPVOID lpParam=0*/);
-
-       static Window* create_mdi_child(const ChildWndInfo& info, const MDICREATESTRUCT& mcs, CREATORFUNC_INFO creator);
-//     static Window* create_property_sheet(struct PropertySheetDialog* ppsd, CREATORFUNC creator, const void* info);
-
-       static LRESULT CALLBACK WindowWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-       static INT_PTR CALLBACK DialogProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       static Window* get_window(HWND hwnd);
-#ifndef _MSC_VER
-       template<typename CLASS> static CLASS* get_window(HWND hwnd) {return static_cast<CLASS*>(get_window(hwnd));}
-#define        GET_WINDOW(CLASS, hwnd) Window::get_window<CLASS>(hwnd)
-#endif
-
-       static void register_pretranslate(HWND hwnd);
-       static void unregister_pretranslate(HWND hwnd);
-       static BOOL     pretranslate_msg(LPMSG pmsg);
-
-       static void     register_dialog(HWND hwnd);
-       static void     unregister_dialog(HWND hwnd);
-       static BOOL     dispatch_dialog_msg(LPMSG pmsg);
-
-       static int      MessageLoop();
-
-
-       LRESULT SendParent(UINT nmsg, WPARAM wparam=0, LPARAM lparam=0);
-       LRESULT PostParent(UINT nmsg, WPARAM wparam=0, LPARAM lparam=0);
-
-       static void CancelModes();
-
-
-protected:
-       virtual LRESULT Init(LPCREATESTRUCT pcs);                                                       // WM_CREATE processing
-       virtual LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       virtual int             Command(int id, int code);                                                      // WM_COMMAND processing
-       virtual int             Notify(int id, NMHDR* pnmh);                                            // WM_NOTIFY processing
-
-       static Window* create_controller(HWND hwnd);
-
-
-       static WindowMap        s_wnd_map;
-
-       static const void*      s_new_info;
-       static CREATORFUNC      s_window_creator;
-
-
-        /// structure for managing critical sections as static class information in struct Window
-       struct StaticWindowData {
-               CritSect        _map_crit_sect;
-               CritSect        _create_crit_sect;
-       };
-
-       static StaticWindowData& GetStaticWindowData();
-
-
-        // MDI child creation
-       static HHOOK s_hcbtHook;
-       static LRESULT CALLBACK MDICBTHookProc(int code, WPARAM wparam, LPARAM lparam);
-       static LRESULT CALLBACK PropSheetCBTHookProc(int code, WPARAM wparam, LPARAM lparam);
-
-       static WindowSet s_pretranslate_windows;
-       static WindowSet s_dialogs;
-};
-
-#ifdef UNICODE
-#define        NFR_CURRENT     NFR_UNICODE
-#else
-#define        NFR_CURRENT     NFR_ANSI
-#endif
-
-
-#ifdef _MSC_VER
-template<typename CLASS> struct GetWindowHelper
-{
-       static CLASS* get_window(HWND hwnd) {
-               return static_cast<CLASS*>(Window::get_window(hwnd));
-       }
-};
-#define        GET_WINDOW(CLASS, hwnd) GetWindowHelper<CLASS>::get_window(hwnd)
-#endif
-
-
- /// dynamic casting of Window pointers
-template<typename CLASS> struct TypeCheck
-{
-       static CLASS* dyn_cast(Window* wnd)
-               {return dynamic_cast<CLASS*>(wnd);}
-};
-
-#define        WINDOW_DYNAMIC_CAST(CLASS, hwnd) \
-       TypeCheck<CLASS>::dyn_cast(Window::get_window(hwnd))
-
-
- /**
-       SubclassedWindow is used to wrap already existing window handles
-       into C++ Window objects. To construct a object, use the "new" operator
-       to put it in the heap. It is automatically freed, when the window
-       gets destroyed.
- */
-struct SubclassedWindow : public Window
-{
-       typedef Window super;
-
-       SubclassedWindow(HWND);
-
-protected:
-       WNDPROC _orgWndProc;
-
-       static LRESULT CALLBACK SubclassedWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       virtual LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       virtual int             Command(int id, int code);
-       virtual int             Notify(int id, NMHDR* pnmh);
-};
-
-
- /// template class used in macro WINDOW_CREATOR to define the creater functions for Window objects
-template<typename WND_CLASS> struct WindowCreator
-{
-       static WND_CLASS* window_creator(HWND hwnd)
-       {
-               return new WND_CLASS(hwnd);
-       }
-};
-
-#define WINDOW_CREATOR(WND_CLASS) \
-       ((Window::CREATORFUNC) WindowCreator<WND_CLASS>::window_creator)
-
-
- /// template class used in macro WINDOW_CREATOR_INFO to the define creater functions for Window objects with additional creation information
-template<typename WND_CLASS, typename INFO_CLASS> struct WindowCreatorInfo
-{
-       static WND_CLASS* window_creator(HWND hwnd, const void* info)
-       {
-               return new WND_CLASS(hwnd, *static_cast<const INFO_CLASS*>(info));
-       }
-};
-
-#define WINDOW_CREATOR_INFO(WND_CLASS, INFO_CLASS) \
-       ((Window::CREATORFUNC_INFO) WindowCreatorInfo<WND_CLASS, INFO_CLASS>::window_creator)
-
-
- /**
-       WindowClass is a neat wrapper for RegisterClassEx().
-       Just construct a WindowClass object, override the attributes you want
-       to change, then call Register() or simply request the ATOM value to
-       register the window class. You don't have to worry calling Register()
-       more than once. It checks if, the class has already been registered.
- */
-struct WindowClass : public WNDCLASSEX
-{
-       WindowClass(LPCTSTR classname, UINT style=0, WNDPROC wndproc=Window::WindowWndProc);
-
-       ATOM Register()
-       {
-               if (!_atomClass)
-                       _atomClass = RegisterClassEx(this);
-
-               return _atomClass;
-       }
-
-       operator ATOM() {return Register();}
-
-        // return LPCTSTR for the CreateWindowEx() parameter
-       operator LPCTSTR() {return (LPCTSTR)(int)Register();}
-
-protected:
-       ATOM    _atomClass;
-};
-
- /// window class with gray background color
-struct BtnWindowClass : public WindowClass
-{
-       BtnWindowClass(LPCTSTR classname, UINT style=0, WNDPROC wndproc=Window::WindowWndProc)
-        :      WindowClass(classname, style, wndproc)
-       {
-               hbrBackground = (HBRUSH)(COLOR_BTNFACE+1);
-       }
-};
-
- /// window class with specified icon from resources
-struct IconWindowClass : public WindowClass
-{
-       IconWindowClass(LPCTSTR classname, UINT nid, UINT style=0, WNDPROC wndproc=Window::WindowWndProc);
-};
-
-
- // private message constants
-#define        PM_DISPATCH_COMMAND             (WM_APP+0x00)
-#define        PM_TRANSLATE_MSG                (WM_APP+0x01)
-
-
-#define SPLIT_WIDTH            5
-#define DEFAULT_SPLIT_POS      300
-#define        COLOR_SPLITBAR          LTGRAY_BRUSH
-
-
- /// menu info structure
-struct MenuInfo
-{
-       HMENU   _hMenuView;
-};
-
-#define        PM_FRM_GET_MENUINFO             (WM_APP+0x02)
-
-#define        Frame_GetMenuInfo(hwnd) ((MenuInfo*)SNDMSG(hwnd, PM_FRM_GET_MENUINFO, 0, 0))
-
-
- /**
-       Class ChildWindow represents MDI child windows.
-       It is used with class MainFrame.
- */
-struct ChildWindow : public Window
-{
-       typedef Window super;
-
-       ChildWindow(HWND hwnd, const ChildWndInfo& info);
-
-       static ChildWindow* create(const ChildWndInfo& info, const RECT& rect, CREATORFUNC_INFO creator,
-                                                               LPCTSTR classname, LPCTSTR title=NULL, DWORD style=0);
-
-       bool    go_to(LPCTSTR url);
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       virtual void resize_children(int cx, int cy);
-       virtual String jump_to_int(LPCTSTR url) = 0;
-
-protected:
-       MenuInfo*_menu_info;
-
-       WindowHandle _left_hwnd;
-       WindowHandle _right_hwnd;
-       int     _focus_pane;            // 0: left      1: right
-
-       int     _split_pos;
-       int             _last_split;
-
-       HWND    _hwndFrame;
-       String  _statusText;
-       String  _url;
-
-       stack<String> _url_history;
-
-       void    set_url(LPCTSTR url);
-};
-
-#define        PM_SETSTATUSTEXT                (WM_APP+0x1E)
-
-
- /**
-       PreTranslateWindow is used to register windows to be called by Window::pretranslate_msg().
-       This way you get PM_TRANSLATE_MSG messages before the message loop dispatches messages.
-       You can then for example use TranslateAccelerator() to implement key shortcuts.
- */
-struct PreTranslateWindow : public Window
-{
-       typedef Window super;
-
-       PreTranslateWindow(HWND);
-       ~PreTranslateWindow();
-};
-
-
- /**
-       The class DialogWindow implements modeless dialogs, which are managed by
-       Window::dispatch_dialog_msg() in Window::MessageLoop().
-       A DialogWindow object should be constructed by calling Window::Create()
-       and specifying the class using the WINDOW_CREATOR() macro.
- */
-struct DialogWindow : public Window
-{
-       typedef Window super;
-
-       DialogWindow(HWND hwnd)
-        :      super(hwnd)
-       {
-               register_dialog(hwnd);
-       }
-
-       ~DialogWindow()
-       {
-               unregister_dialog(_hwnd);
-       }
-};
-
-
- /**
-       The class Dialog implements modal dialogs.
-       A Dialog object should be constructed by calling Dialog::DoModal()
-       and specifying the class using the WINDOW_CREATOR() macro.
- */
-struct Dialog : public Window
-{
-       typedef Window super;
-
-       Dialog(HWND);
-       ~Dialog();
-
-       static int DoModal(UINT nid, CREATORFUNC creator, HWND hwndParent=0);
-       static int DoModal(UINT nid, CREATORFUNC_INFO creator, const void* info, HWND hwndParent=0);
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Command(int id, int code);
-};
-
-
-#define        PM_FRM_CALC_CLIENT              (WM_APP+0x03)
-#define        Frame_CalcFrameClient(hwnd, prt) ((BOOL)SNDMSG(hwnd, PM_FRM_CALC_CLIENT, 0, (LPARAM)(PRECT)prt))
-
-#define        PM_JUMP_TO_URL                  (WM_APP+0x25)
-#define        PM_URL_CHANGED                  (WM_APP+0x26)
-
-
-struct PropSheetPage : public PROPSHEETPAGE
-{
-       PropSheetPage(UINT nid, Window::CREATORFUNC dlg_creator);
-
-       void    init(struct PropertySheetDialog*);
-
-protected:
-       friend struct PropSheetPageDlg;
-
-       Window::CREATORFUNC     _dlg_creator;
-};
-
-
- /// Property Sheet dialog
-struct PropertySheetDialog : public PROPSHEETHEADER
-{
-       PropertySheetDialog(HWND owner);
-
-       void    add(PropSheetPage& psp);
-       int             DoModal(int start_page=0);
-
-       HWND    GetCurrentPage();
-
-protected:
-       typedef vector<PROPSHEETPAGE> Vector;
-       Vector  _pages;
-       HWND    _hwnd;
-};
-
-
- /// Property Sheet Page (inner dialog)
-struct PropSheetPageDlg : public Dialog
-{
-       typedef Dialog super;
-
-       PropSheetPageDlg(HWND);
-
-protected:
-       friend struct PropertySheetDialog;
-       friend struct PropSheetPage;
-
-       static INT_PTR CALLBACK DialogProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       int     Command(int id, int code);
-};
-
-
-/*
- /// Property Sheet Dialog (outer dialog)
-struct PropertySheetDlg : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       PropertySheetDlg(HWND hwnd) : super(hwnd) {}
-};
-*/
-
-
- // Layouting of resizable windows
-
- /// Flags to specify how to move and resize controls when resizing their parent window
-enum RESIZE_FLAGS {
-       MOVE_LEFT       = 0x1,
-       MOVE_RIGHT      = 0x2,
-       MOVE_TOP        = 0x4,
-       MOVE_BOTTOM     = 0x8,
-
-       MOVE_X  =  MOVE_LEFT | MOVE_RIGHT,
-       MOVE_Y  =  MOVE_TOP | MOVE_BOTTOM,
-       RESIZE_X=  MOVE_RIGHT,
-       RESIZE_Y=  MOVE_BOTTOM,
-
-       MOVE    = MOVE_X   | MOVE_Y,
-       RESIZE  = RESIZE_X | RESIZE_Y
-};
-
- /// structure to assign RESIZE_FLAGS to dialogs control
-struct ResizeEntry
-{
-       ResizeEntry(UINT id, int flags)
-        : _id(id), _flags(flags) {}
-
-       ResizeEntry(HWND hwnd, int flags)
-        : _id(GetDlgCtrlID(hwnd)), _flags(flags) {}
-
-       UINT    _id;
-       int             _flags;
-};
-
-
- /// Management of controls in resizable dialogs
-struct ResizeManager : public std::list<ResizeEntry>
-{
-       typedef std::list<ResizeEntry> super;
-
-       ResizeManager(HWND hwnd);
-
-       void Add(UINT id, int flags)
-               {push_back(ResizeEntry(id, flags));}
-
-       void Add(HWND hwnd, int flags)
-               {push_back(ResizeEntry(hwnd, flags));}
-
-       void HandleSize(int cx, int cy);
-       void Resize(int dx, int dy);
-
-       void SetMinMaxInfo(LPMINMAXINFO lpmmi)
-       {
-               lpmmi->ptMinTrackSize.x = _min_wnd_size.cx;
-               lpmmi->ptMinTrackSize.y = _min_wnd_size.cy;
-       }
-
-       SIZE    _min_wnd_size;
-
-protected:
-       HWND    _hwnd;
-       SIZE    _last_size;
-};
-
-
- /// Controller base template class for resizable dialogs
-template<typename BASE> struct ResizeController : public BASE
-{
-       typedef BASE super;
-
-       ResizeController(HWND hwnd)
-        :      super(hwnd),
-               _resize_mgr(hwnd)
-       {
-       }
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               switch(nmsg) {
-                 case PM_FRM_CALC_CLIENT:
-                       GetClientSpace((PRECT)lparam);
-                       return TRUE;
-
-                 case WM_SIZE:
-                       if (wparam != SIZE_MINIMIZED)
-                               _resize_mgr.HandleSize(LOWORD(lparam), HIWORD(lparam));
-                       goto def;
-
-                 case WM_GETMINMAXINFO:
-                       _resize_mgr.SetMinMaxInfo((LPMINMAXINFO)lparam);
-                       goto def;
-
-                 default: def:
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-       }
-
-       virtual void GetClientSpace(PRECT prect)
-       {
-                if (!IsIconic(this->_hwnd)) {
-                       GetClientRect(this->_hwnd, prect);
-                } else {
-                       WINDOWPLACEMENT wp;
-                       GetWindowPlacement(this->_hwnd, &wp);
-                       prect->left = prect->top = 0;
-                       prect->right = wp.rcNormalPosition.right-wp.rcNormalPosition.left-
-                               2*(GetSystemMetrics(SM_CXSIZEFRAME)+GetSystemMetrics(SM_CXEDGE));
-                       prect->bottom = wp.rcNormalPosition.bottom-wp.rcNormalPosition.top-
-                               2*(GetSystemMetrics(SM_CYSIZEFRAME)+GetSystemMetrics(SM_CYEDGE))-
-                               GetSystemMetrics(SM_CYCAPTION)-GetSystemMetrics(SM_CYMENUSIZE);
-               }
-       }
-
-protected:
-       ResizeManager _resize_mgr;
-};
-
-
- /**
-       This class constructs button controls.
-       The button will remain existent when the C++ Button object is destroyed.
-       There is no conjunction between C++ object and windows control life time.
- */
-struct Button : public WindowHandle
-{
-       Button(HWND parent, LPCTSTR text, int left, int top, int width, int height,
-                       int id, DWORD flags=WS_VISIBLE|WS_CHILD|BS_PUSHBUTTON, DWORD exStyle=0);
-};
-
-
- /**
-       This class constructs static controls.
-       The control will remain existent when the C++ object is destroyed.
-       There is no conjunction between C++ object and windows control life time.
- */
-struct Static : public WindowHandle
-{
-       Static(HWND parent, LPCTSTR text, int left, int top, int width, int height,
-                       int id, DWORD flags=WS_VISIBLE|WS_CHILD|SS_SIMPLE, DWORD ex_flags=0);
-};
-
-
- // control color message routing for ColorStatic and HyperlinkCtrl
-
-#define        PM_DISPATCH_CTLCOLOR    (WM_APP+0x08)
-
-template<typename BASE> struct CtlColorParent : public BASE
-{
-       typedef BASE super;
-
-       CtlColorParent(HWND hwnd)
-        : super(hwnd) {}
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               switch(nmsg) {
-                 case WM_CTLCOLOR:
-                 case WM_CTLCOLORBTN:
-                 case WM_CTLCOLORDLG:
-                 case WM_CTLCOLORSCROLLBAR:
-                 case WM_CTLCOLORSTATIC: {
-                       HWND hctl = (HWND) lparam;
-                       return SendMessage(hctl, PM_DISPATCH_CTLCOLOR, wparam, nmsg);
-                 }
-
-                 default:
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-       }
-};
-
-
-#define        PM_DISPATCH_DRAWITEM    (WM_APP+0x09)
-
- /// draw message routing for ColorButton and PictureButton
-template<typename BASE> struct OwnerDrawParent : public BASE
-{
-       typedef BASE super;
-
-       OwnerDrawParent(HWND hwnd)
-        : super(hwnd) {}
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               switch(nmsg) {
-                 case WM_DRAWITEM:
-                       if (wparam) {   // should there be drawn a control?
-                               HWND hctl = GetDlgItem(this->_hwnd, wparam);
-
-                               if (hctl)
-                                       return SendMessage(hctl, PM_DISPATCH_DRAWITEM, wparam, lparam);
-                       } /*else                // or is it a menu entry?
-                               ; */
-
-                       return 0;
-
-                 default:
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-       }
-};
-
-
- /**
-       Subclass button controls to draw them by using PM_DISPATCH_DRAWITEM
-       The owning window should use the OwnerDrawParent template to route owner draw messages to the buttons.
- */
-struct OwnerdrawnButton : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       OwnerdrawnButton(HWND hwnd)
-        :      super(hwnd) {}
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       virtual void DrawItem(LPDRAWITEMSTRUCT dis) = 0;
-};
-
-extern void DrawGrayText(HDC hdc, LPRECT pRect, LPCTSTR text, int dt_flags);
-
-
- /**
-       Subclass button controls to paint colored text labels.
-       The owning window should use the OwnerDrawParent template to route owner draw messages to the buttons.
- */
-/* not yet used
-struct ColorButton : public OwnerdrawnButton
-{
-       typedef OwnerdrawnButton super;
-
-       ColorButton(HWND hwnd, COLORREF textColor)
-        :      super(hwnd), _textColor(textColor) {}
-
-protected:
-       virtual void DrawItem(LPDRAWITEMSTRUCT dis);
-
-       COLORREF _textColor;
-};
-*/
-
-
-struct FlatButton : public OwnerdrawnButton
-{
-       typedef OwnerdrawnButton super;
-
-       FlatButton(HWND hwnd)
-        : super(hwnd), _active(false) {}
-
-       FlatButton(HWND owner, int id)
-        : super(GetDlgItem(owner, IDOK)), _active(false) {}
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       virtual void DrawItem(LPDRAWITEMSTRUCT dis);
-
-       COLORREF _textColor;
-       COLORREF _activeColor;
-       bool    _active;
-};
-
-
- /**
-       Subclass button controls to paint pictures left to the labels.
-       The buttons should have set the style bit BS_OWNERDRAW.
-       The owning window should use the OwnerDrawParent template to route owner draw messages to the buttons.
- */
-struct PictureButton : public OwnerdrawnButton
-{
-       typedef OwnerdrawnButton super;
-
-       PictureButton(HWND hwnd, HICON hIcon, HBRUSH hbrush=GetSysColorBrush(COLOR_BTNFACE), bool flat=false)
-        :      super(hwnd), _hIcon(hIcon), _hBmp(0), _hBrush(hbrush), _flat(flat)
-       {
-               _cx = 16;
-               _cy = 16;
-       }
-
-       PictureButton(HWND hparent, int id, HICON hIcon, HBRUSH hbrush=GetSysColorBrush(COLOR_BTNFACE), bool flat=false)
-        :      super(GetDlgItem(hparent, id)), _hIcon(hIcon), _hBmp(0), _hBrush(hbrush), _flat(flat)
-       {
-               _cx = 16;
-               _cy = 16;
-       }
-
-       PictureButton(HWND hwnd, HBITMAP hBmp, HBRUSH hbrush=GetSysColorBrush(COLOR_BTNFACE), bool flat=false)
-        :      super(hwnd), _hIcon(0), _hBmp(hBmp), _hBrush(hbrush), _flat(flat)
-       {
-               BITMAP bmp;
-               GetObject(hBmp, sizeof(bmp), &bmp);
-               _cx = bmp.bmWidth;
-               _cy = bmp.bmHeight;
-       }
-
-       PictureButton(HWND hparent, int id, HBITMAP hBmp, HBRUSH hbrush=GetSysColorBrush(COLOR_BTNFACE), bool flat=false)
-        :      super(GetDlgItem(hparent, id)), _hIcon(0), _hBmp(hBmp), _hBrush(hbrush), _flat(flat)
-       {
-               BITMAP bmp;
-               GetObject(hBmp, sizeof(bmp), &bmp);
-               _cx = bmp.bmWidth;
-               _cy = bmp.bmHeight;
-       }
-
-protected:
-       virtual void DrawItem(LPDRAWITEMSTRUCT dis);
-
-       HICON   _hIcon;
-       HBITMAP _hBmp;
-       HBRUSH  _hBrush;
-
-       int             _cx;
-       int             _cy;
-
-       bool    _flat;
-};
-
-
-struct ColorStatic : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       ColorStatic(HWND hwnd, COLORREF textColor=RGB(255,0,0), HBRUSH hbrush_bkgnd=0, HFONT hfont=0)
-        :      super(hwnd),
-               _textColor(textColor),
-               _hbrush_bkgnd(hbrush_bkgnd),
-               _hfont(hfont)
-       {
-       }
-
-       ColorStatic(HWND owner, int id, COLORREF textColor=RGB(255,0,0), HBRUSH hbrush_bkgnd=0, HFONT hfont=0)
-        :      super(GetDlgItem(owner, id)),
-               _textColor(textColor),
-               _hbrush_bkgnd(hbrush_bkgnd),
-               _hfont(hfont)
-       {
-       }
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               if (nmsg == PM_DISPATCH_CTLCOLOR) {
-                       HDC hdc = (HDC) wparam;
-
-                       SetTextColor(hdc, _textColor);
-
-                       if (_hfont)
-                               SelectFont(hdc, _hfont);
-
-                       if (_hbrush_bkgnd)
-                               return (LRESULT)_hbrush_bkgnd;
-                       else {
-                               SetBkMode(hdc, TRANSPARENT);
-                               return (LRESULT)GetStockBrush(HOLLOW_BRUSH);
-                       }
-               } else
-                       return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       COLORREF        _textColor;
-       HBRUSH          _hbrush_bkgnd;
-       HFONT           _hfont;
-};
-
-
-  /// Hyperlink Controls
-
-struct HyperlinkCtrl : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       HyperlinkCtrl(HWND hwnd, COLORREF colorLink=RGB(0,0,255), COLORREF colorVisited=RGB(128,0,128));
-       HyperlinkCtrl(HWND owner, int id, COLORREF colorLink=RGB(0,0,255), COLORREF colorVisited=RGB(128,0,128));
-
-       ~HyperlinkCtrl();
-
-       String  _cmd;
-
-protected:
-       COLORREF _textColor;
-       COLORREF _colorVisited;
-       HFONT    _hfont;
-       HCURSOR _crsr_link;
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       void init();
-
-       bool LaunchLink()
-       {
-               if (!_cmd.empty()) {
-                       HINSTANCE hinst = ShellExecute(GetParent(_hwnd), _T("open"), _cmd, 0, 0, SW_SHOWNORMAL);
-                       return (int)hinst > HINSTANCE_ERROR;
-               }
-
-               return true;
-       }
-};
-
-
- /// encapsulation of tool tip controls
-struct ToolTip : public WindowHandle
-{
-       typedef WindowHandle super;
-
-       ToolTip(HWND owner);
-
-       void activate(BOOL active=TRUE)
-       {
-               SendMessage(_hwnd, TTM_ACTIVATE, active, 0);
-       }
-
-       void add(HWND hparent, HWND htool, LPCTSTR txt=LPSTR_TEXTCALLBACK, LPARAM lparam=0)
-       {
-               TOOLINFO ti = {
-                       sizeof(TOOLINFO), TTF_SUBCLASS|TTF_IDISHWND|TTF_TRANSPARENT, hparent, (UINT)htool,
-                       {0,0,0,0}, 0, (LPTSTR)txt, lparam
-               };
-
-#ifdef UNICODE ///@todo Why is it neccesary to try both TTM_ADDTOOLW and TTM_ADDTOOLW ?!
-               if (!SendMessage(_hwnd, TTM_ADDTOOLW, 0, (LPARAM)&ti))
-                       SendMessage(_hwnd, TTM_ADDTOOLA, 0, (LPARAM)&ti);
-#else
-               if (!SendMessage(_hwnd, TTM_ADDTOOLA, 0, (LPARAM)&ti))
-                       SendMessage(_hwnd, TTM_ADDTOOLW, 0, (LPARAM)&ti);
-#endif
-       }
-
-       void add(HWND hparent, UINT id, const RECT& rect, LPCTSTR txt=LPSTR_TEXTCALLBACK, LPARAM lparam=0)
-       {
-               TOOLINFO ti = {
-                       sizeof(TOOLINFO), TTF_SUBCLASS|TTF_TRANSPARENT, hparent, id,
-                       {rect.left,rect.top,rect.right,rect.bottom}, 0, (LPTSTR)txt, lparam
-               };
-
-#ifdef UNICODE
-               if (!SendMessage(_hwnd, TTM_ADDTOOLW, 0, (LPARAM)&ti))
-                       SendMessage(_hwnd, TTM_ADDTOOLA, 0, (LPARAM)&ti);
-#else
-               if (!SendMessage(_hwnd, TTM_ADDTOOLA, 0, (LPARAM)&ti))
-                       SendMessage(_hwnd, TTM_ADDTOOLW, 0, (LPARAM)&ti);
-#endif
-       }
-
-       void remove(HWND hparent, HWND htool)
-       {
-               TOOLINFO ti = {
-                       sizeof(TOOLINFO), TTF_IDISHWND, hparent, (UINT)htool,
-                       {0,0,0,0}, 0, 0, 0
-               };
-
-               SendMessage(_hwnd, TTM_DELTOOL, 0, (LPARAM)&ti);
-       }
-
-       void remove(HWND hparent, UINT id)
-       {
-               TOOLINFO ti = {
-                       sizeof(TOOLINFO), 0, hparent, id,
-                       {0,0,0,0}, 0, 0, 0
-               };
-
-               SendMessage(_hwnd, TTM_DELTOOL, 0, (LPARAM)&ti);
-       }
-};
-
-
-inline int ListView_GetItemData(HWND list_ctrl, int idx)
-{
-       LV_ITEM item;
-
-       item.mask = LVIF_PARAM;
-       item.iItem = idx;
-
-       if (!ListView_GetItem(list_ctrl, &item))
-               return 0;
-
-       return item.lParam;
-}
-
-inline int ListView_FindItemPara(HWND list_ctrl, LPARAM param)
-{
-       LVFINDINFO fi;
-
-       fi.flags = LVFI_PARAM;
-       fi.lParam = param;
-
-       return ListView_FindItem(list_ctrl, (unsigned)-1, &fi);
-}
-
-inline int ListView_GetFocusedItem(HWND list_ctrl)
-{
-       int idx = ListView_GetItemCount(list_ctrl);
-
-       while(--idx >= 0)
-               if (ListView_GetItemState(list_ctrl, idx, LVIS_FOCUSED))
-                       break;
-
-       return idx;
-}
-
-
- /// sorting of list controls
-struct ListSort : public WindowHandle
-{
-       ListSort(HWND hwndListview, PFNLVCOMPARE compare_fct);
-
-       void    toggle_sort(int idx);
-       void    sort();
-
-       int             _sort_crit;
-       bool    _direction;
-
-protected:
-       PFNLVCOMPARE _compare_fct;
-
-       static int CALLBACK CompareFunc(LPARAM lparam1, LPARAM lparam2, LPARAM lparamSort);
-};
-
-
-inline LPARAM TreeView_GetItemData(HWND hwndTreeView, HTREEITEM hItem)
-{
-       TVITEM tvItem;
-
-       tvItem.mask = TVIF_PARAM;
-       tvItem.hItem = hItem;
-
-       if (!TreeView_GetItem(hwndTreeView, &tvItem))
-               return 0;
-
-       return tvItem.lParam;
-}
-
-
-enum {TRAYBUTTON_LEFT=0, TRAYBUTTON_RIGHT, TRAYBUTTON_MIDDLE};
-
-#define        PM_TRAYICON             (WM_APP+0x20)
-
-#define        WINMSG_TASKBARCREATED   TEXT("TaskbarCreated")
-
-#define        WINMSG_SHELLHOOK                TEXT("SHELLHOOK")
-
-
-struct TrayIcon
-{
-       TrayIcon(HWND hparent, UINT id)
-        :      _hparent(hparent), _id(id) {}
-
-       ~TrayIcon()
-               {Remove();}
-
-       void    Add(HICON hIcon, LPCTSTR tooltip=NULL)
-               {Set(NIM_ADD, _id, hIcon, tooltip);}
-
-       void    Modify(HICON hIcon, LPCTSTR tooltip=NULL)
-               {Set(NIM_MODIFY, _id, hIcon, tooltip);}
-
-       void    Remove()
-       {
-               NOTIFYICONDATA nid = {
-                       sizeof(NOTIFYICONDATA), // cbSize
-                       _hparent,                               // hWnd
-                       _id,                                    // uID
-               };
-
-               Shell_NotifyIcon(NIM_DELETE, &nid);
-       }
-
-protected:
-       HWND    _hparent;
-       UINT    _id;
-
-       void    Set(DWORD dwMessage, UINT id, HICON hIcon, LPCTSTR tooltip=NULL)
-       {
-               NOTIFYICONDATA nid = {
-                       sizeof(NOTIFYICONDATA), // cbSize
-                       _hparent,                               // hWnd
-                       id,                                             // uID
-                       NIF_MESSAGE|NIF_ICON,   // uFlags
-                       PM_TRAYICON,                    // uCallbackMessage
-                       hIcon                                   // hIcon
-               };
-
-               if (tooltip)
-                       lstrcpyn(nid.szTip, tooltip, COUNTOF(nid.szTip));
-
-               if (nid.szTip[0])
-                       nid.uFlags |= NIF_TIP;
-
-               Shell_NotifyIcon(dwMessage, &nid);
-       }
-};
-
-
-template<typename BASE> struct TrayIconControllerTemplate : public BASE
-{
-       typedef BASE super;
-
-       TrayIconControllerTemplate(HWND hwnd) : BASE(hwnd),
-               WM_TASKBARCREATED(RegisterWindowMessage(WINMSG_TASKBARCREATED))
-       {
-       }
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               if (nmsg == PM_TRAYICON) {
-                       switch(lparam) {
-                         case WM_MOUSEMOVE:
-                               TrayMouseOver(wparam);
-                               break;
-
-                         case WM_LBUTTONDOWN:
-                               TrayClick(wparam, TRAYBUTTON_LEFT);
-                               break;
-
-                         case WM_LBUTTONDBLCLK:
-                               TrayDblClick(wparam, TRAYBUTTON_LEFT);
-                               break;
-
-                         case WM_RBUTTONDOWN:
-                               TrayClick(wparam, TRAYBUTTON_RIGHT);
-                               break;
-
-                         case WM_RBUTTONDBLCLK:
-                               TrayDblClick(wparam, TRAYBUTTON_RIGHT);
-                               break;
-
-                         case WM_MBUTTONDOWN:
-                               TrayClick(wparam, TRAYBUTTON_MIDDLE);
-                               break;
-
-                         case WM_MBUTTONDBLCLK:
-                               TrayDblClick(wparam, TRAYBUTTON_MIDDLE);
-                               break;
-                       }
-
-                       return 0;
-               } else if (nmsg == WM_TASKBARCREATED) {
-                       AddTrayIcons();
-                       return 0;
-               } else
-                       return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       virtual void AddTrayIcons() = 0;
-       virtual void TrayMouseOver(UINT id) {}
-       virtual void TrayClick(UINT id, int btn) {}
-       virtual void TrayDblClick(UINT id, int btn) {}
-
-protected:
-       const UINT WM_TASKBARCREATED;
-};
-
-
-struct EditController : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       EditController(HWND hwnd)
-        :      super(hwnd)
-       {
-       }
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               if (nmsg==WM_KEYDOWN && wparam==VK_RETURN) {
-                       SendParent(WM_COMMAND, MAKEWPARAM(GetDlgCtrlID(_hwnd),1), (LPARAM)_hwnd);
-                       return 0;
-               } else
-                       return super::WndProc(nmsg, wparam, lparam);
-       }
-};
diff --git a/reactos/subsys/system/explorer/utility/xmlstorage.cpp b/reactos/subsys/system/explorer/utility/xmlstorage.cpp
deleted file mode 100644 (file)
index 91978f3..0000000
+++ /dev/null
@@ -1,638 +0,0 @@
-
- //
- // XML storage classes
- //
- // xmlstorage.cpp
- //
- // Copyright (c) 2004, 2005 Martin Fuchs <martin-fuchs@gmx.net>
- //
-
-
-/*
-
-  All rights reserved.
-
-  Redistribution and use in source and binary forms, with or without
-  modification, are permitted provided that the following conditions are met:
-
-  * Redistributions of source code must retain the above copyright
-       notice, this list of conditions and the following disclaimer.
-  * Redistributions in binary form must reproduce the above copyright
-       notice, this list of conditions and the following disclaimer in
-       the documentation and/or other materials provided with the
-       distribution.
-
-  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-  ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-  LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-  CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-  SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-  INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-  CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-  POSSIBILITY OF SUCH DAMAGE.
-
-*/
-
-#ifndef _NO_COMMENT
-#define _NO_COMMENT    // no #pragma comment(lib, ...) statements in .lib files
-#endif
-
-//#include "xmlstorage.h"
-#include <precomp.h>
-
-
- // work around GCC's wide string constant bug
-#ifdef __GNUC__
-const LPCXSSTR XMLStorage::XS_TRUE = XS_TRUE_STR;
-const LPCXSSTR XMLStorage::XS_FALSE = XS_FALSE_STR;
-const LPCXSSTR XMLStorage::XS_NUMBERFMT = XS_NUMBERFMT_STR;
-#endif
-
-
-namespace XMLStorage {
-
-
- /// remove escape characters from zero terminated string
-static std::string unescape(const char* s, char b='"', char e='"')
-{
-       const char* end = s + strlen(s);
-
-//     if (*s == b)
-//             ++s;
-//
-//     if (end>s && end[-1]==e)
-//             --end;
-
-       if (*s == b)
-               if (end>s && end[-1]==e)
-                       ++s, --end;
-
-       return std::string(s, end-s);
-}
-
- /// remove escape characters from string with specified length
-static std::string unescape(const char* s, int l, char b='"', char e='"')
-{
-       const char* end = s + l;
-
-//     if (*s == b)
-//             ++s;
-//
-//     if (end>s && end[-1]==e)
-//             --end;
-
-       if (*s == b)
-               if (end>s && end[-1]==e)
-                       ++s, --end;
-
-       return std::string(s, end-s);
-}
-
-
- /// move XPath like to position in XML tree
-bool XMLPos::go(const char* path)
-{
-       XMLNode* node = _cur;
-
-        // Is this an absolute path?
-       if (*path == '/') {
-               node = _root;
-               ++path;
-       }
-
-       node = node->find_relative(path);
-
-       if (node) {
-               go_to(node);
-               return true;
-       } else
-               return false;
-}
-
- /// move XPath like to position in XML tree
-bool const_XMLPos::go(const char* path)
-{
-       const XMLNode* node = _cur;
-
-        // Is this an absolute path?
-       if (*path == '/') {
-               node = _root;
-               ++path;
-       }
-
-       node = node->find_relative(path);
-
-       if (node) {
-               go_to(node);
-               return true;
-       } else
-               return false;
-}
-
-
-const XMLNode* XMLNode::find_relative(const char* path) const
-{
-       const XMLNode* node = this;
-
-        // parse relative path
-       while(*path) {
-               const char* slash = strchr(path, '/');
-               if (slash == path)
-                       return NULL;
-
-               int l = slash? slash-path: strlen(path);
-               std::string comp(path, l);
-               path += l;
-
-                // look for [n] and [@attr_name="attr_value"] expressions in path components
-               const char* bracket = strchr(comp.c_str(), '[');
-               l = bracket? bracket-comp.c_str(): comp.length();
-               std::string child_name(comp.c_str(), l);
-               std::string attr_name, attr_value;
-
-               int n = 0;
-               if (bracket) {
-                       std::string expr = unescape(bracket, '[', ']');
-                       const char* p = expr.c_str();
-
-                       n = atoi(p);    // read index number
-
-                       if (n)
-                               n = n - 1;      // convert into zero based index
-
-                       const char* at = strchr(p, '@');
-
-                       if (at) {
-                               p = at + 1;
-                               const char* equal = strchr(p, '=');
-
-                                // read attribute name and value
-                               if (equal) {
-                                       attr_name = unescape(p, equal-p);
-                                       attr_value = unescape(equal+1);
-                               }
-                       }
-               }
-
-               if (attr_name.empty())
-                        // search n.th child node with specified name
-                       node = node->find(child_name, n);
-               else
-                        // search n.th child node with specified name and matching attribute value
-                       node = node->find(child_name, attr_name, attr_value, n);
-
-               if (!node)
-                       return NULL;
-
-               if (*path == '/')
-                       ++path;
-       }
-
-       return node;
-}
-
-XMLNode* XMLNode::create_relative(const char* path)
-{
-       XMLNode* node = this;
-
-        // parse relative path
-       while(*path) {
-               const char* slash = strchr(path, '/');
-               if (slash == path)
-                       return NULL;
-
-               int l = slash? slash-path: strlen(path);
-               std::string comp(path, l);
-               path += l;
-
-                // look for [n] and [@attr_name="attr_value"] expressions in path components
-               const char* bracket = strchr(comp.c_str(), '[');
-               l = bracket? bracket-comp.c_str(): comp.length();
-               std::string child_name(comp.c_str(), l);
-               std::string attr_name, attr_value;
-
-               int n = 0;
-               if (bracket) {
-                       std::string expr = unescape(bracket, '[', ']');
-                       const char* p = expr.c_str();
-
-                       n = atoi(p);    // read index number
-
-                       if (n)
-                               n = n - 1;      // convert into zero based index
-
-                       const char* at = strchr(p, '@');
-
-                       if (at) {
-                               p = at + 1;
-                               const char* equal = strchr(p, '=');
-
-                                // read attribute name and value
-                               if (equal) {
-                                       attr_name = unescape(p, equal-p);
-                                       attr_value = unescape(equal+1);
-                               }
-                       }
-               }
-
-               XMLNode* child;
-
-               if (attr_name.empty())
-                        // search n.th child node with specified name
-                       child = node->find(child_name, n);
-               else
-                        // search n.th child node with specified name and matching attribute value
-                       child = node->find(child_name, attr_name, attr_value, n);
-
-               if (!child) {
-                       child = new XMLNode(child_name);
-                       node->add_child(child);
-
-                       if (!attr_name.empty())
-                               (*node)[attr_name] = attr_value;
-               }
-
-               node = child;
-
-               if (*path == '/')
-                       ++path;
-       }
-
-       return node;
-}
-
-
- /// read XML stream into XML tree below _pos
-XML_Status XMLReaderBase::read()
-{
-       XML_Status status = XML_STATUS_OK;
-
-       while(status == XML_STATUS_OK) {
-               char* buffer = (char*) XML_GetBuffer(_parser, BUFFER_LEN);
-
-               int l = read_buffer(buffer, BUFFER_LEN);
-               if (l < 0)
-                       break;
-
-               status = XML_ParseBuffer(_parser, l, false);
-       }
-
-       if (status != XML_STATUS_ERROR)
-               status = XML_ParseBuffer(_parser, 0, true);
-
-       if (_pos->_children.empty())
-               _pos->_trailing.append(_content);
-       else
-               _pos->_children.back()->_trailing.append(_content);
-
-       _content.erase();
-
-       return status;
-}
-
-
- /// store XML version and encoding into XML reader
-void XMLCALL XMLReaderBase::XML_XmlDeclHandler(void* userData, const XML_Char* version, const XML_Char* encoding, int standalone)
-{
-       XMLReaderBase* pReader = (XMLReaderBase*) userData;
-
-       if (version)
-               pReader->_xml_version = version;
-
-       if (encoding)
-               pReader->_encoding = encoding;
-}
-
- /// notifications about XML start tag
-void XMLCALL XMLReaderBase::XML_StartElementHandler(void* userData, const XML_Char* name, const XML_Char** atts)
-{
-       XMLReaderBase* pReader = (XMLReaderBase*) userData;
-       XMLPos& pos = pReader->_pos;
-
-        // search for end of first line
-       const char* s = pReader->_content.c_str();
-       const char* p = s;
-       const char* e = p + pReader->_content.length();
-
-       for(; p<e; ++p)
-               if (*p == '\n') {
-                       ++p;
-                       break;
-               }
-
-       if (p != s)
-               if (pos->_children.empty()) {   // no children in last node?
-                       if (pReader->_last_tag == TAG_START)
-                               pos->_content.append(s, p-s);
-                       else if (pReader->_last_tag == TAG_END)
-                               pos->_trailing.append(s, p-s);
-                       // else TAG_NONE -> don't store white space in root node
-               } else
-                       pos->_children.back()->_trailing.append(s, p-s);
-
-       std::string leading;
-
-       if (p != e)
-               leading.assign(p, e-p);
-
-       XMLNode* node = new XMLNode(String_from_XML_Char(name), leading);
-
-       pos.add_down(node);
-
-       while(*atts) {
-               const XML_Char* attr_name = *atts++;
-               const XML_Char* attr_value = *atts++;
-
-               (*node)[String_from_XML_Char(attr_name)] = String_from_XML_Char(attr_value);
-       }
-
-       pReader->_last_tag = TAG_START;
-       pReader->_content.erase();
-}
-
- /// notifications about XML end tag
-void XMLCALL XMLReaderBase::XML_EndElementHandler(void* userData, const XML_Char* name)
-{
-       XMLReaderBase* pReader = (XMLReaderBase*) userData;
-       XMLPos& pos = pReader->_pos;
-
-        // search for end of first line
-       const char* s = pReader->_content.c_str();
-       const char* p = s;
-       const char* e = p + pReader->_content.length();
-
-       for(; p<e; ++p)
-               if (*p == '\n') {
-                       ++p;
-                       break;
-               }
-
-       if (p != s)
-               if (pos->_children.empty())     // no children in current node?
-                       pos->_content.append(s, p-s);
-               else
-                       if (pReader->_last_tag == TAG_START)
-                               pos->_content.append(s, p-s);
-                       else
-                               pos->_children.back()->_trailing.append(s, p-s);
-
-       if (p != e)
-               pos->_end_leading.assign(p, e-p);
-
-       pos.back();
-
-       pReader->_last_tag = TAG_END;
-       pReader->_content.erase();
-}
-
- /// store content, white space and comments
-void XMLCALL XMLReaderBase::XML_DefaultHandler(void* userData, const XML_Char* s, int len)
-{
-       XMLReaderBase* pReader = (XMLReaderBase*) userData;
-
-       pReader->_content.append(s, len);
-}
-
-
- /// return error strings for Expat errors
-std::string XMLReaderBase::get_error_string() const
-{
-       XML_Error error = XML_GetErrorCode(_parser);
-
-       switch(error) {
-         case XML_ERROR_NONE:                                                          return "XML_ERROR_NONE";
-         case XML_ERROR_NO_MEMORY:                                                     return "XML_ERROR_NO_MEMORY";
-         case XML_ERROR_SYNTAX:                                                        return "XML_ERROR_SYNTAX";
-         case XML_ERROR_NO_ELEMENTS:                                           return "XML_ERROR_NO_ELEMENTS";
-         case XML_ERROR_INVALID_TOKEN:                                         return "XML_ERROR_INVALID_TOKEN";
-         case XML_ERROR_UNCLOSED_TOKEN:                                        return "XML_ERROR_UNCLOSED_TOKEN";
-         case XML_ERROR_PARTIAL_CHAR:                                          return "XML_ERROR_PARTIAL_CHAR";
-         case XML_ERROR_TAG_MISMATCH:                                          return "XML_ERROR_TAG_MISMATCH";
-         case XML_ERROR_DUPLICATE_ATTRIBUTE:                           return "XML_ERROR_DUPLICATE_ATTRIBUTE";
-         case XML_ERROR_JUNK_AFTER_DOC_ELEMENT:                        return "XML_ERROR_JUNK_AFTER_DOC_ELEMENT";
-         case XML_ERROR_PARAM_ENTITY_REF:                                      return "XML_ERROR_PARAM_ENTITY_REF";
-         case XML_ERROR_UNDEFINED_ENTITY:                                      return "XML_ERROR_UNDEFINED_ENTITY";
-         case XML_ERROR_RECURSIVE_ENTITY_REF:                          return "XML_ERROR_RECURSIVE_ENTITY_REF";
-         case XML_ERROR_ASYNC_ENTITY:                                          return "XML_ERROR_ASYNC_ENTITY";
-         case XML_ERROR_BAD_CHAR_REF:                                          return "XML_ERROR_BAD_CHAR_REF";
-         case XML_ERROR_BINARY_ENTITY_REF:                                     return "XML_ERROR_BINARY_ENTITY_REF";
-         case XML_ERROR_ATTRIBUTE_EXTERNAL_ENTITY_REF:         return "XML_ERROR_ATTRIBUTE_EXTERNAL_ENTITY_REF";
-         case XML_ERROR_MISPLACED_XML_PI:                                      return "XML_ERROR_MISPLACED_XML_PI";
-         case XML_ERROR_UNKNOWN_ENCODING:                                      return "XML_ERROR_UNKNOWN_ENCODING";
-         case XML_ERROR_INCORRECT_ENCODING:                            return "XML_ERROR_INCORRECT_ENCODING";
-         case XML_ERROR_UNCLOSED_CDATA_SECTION:                        return "XML_ERROR_UNCLOSED_CDATA_SECTION";
-         case XML_ERROR_EXTERNAL_ENTITY_HANDLING:                      return "XML_ERROR_EXTERNAL_ENTITY_HANDLING";
-         case XML_ERROR_NOT_STANDALONE:                                        return "XML_ERROR_NOT_STANDALONE";
-         case XML_ERROR_UNEXPECTED_STATE:                                      return "XML_ERROR_UNEXPECTED_STATE";
-         case XML_ERROR_ENTITY_DECLARED_IN_PE:                         return "XML_ERROR_ENTITY_DECLARED_IN_PE";
-         case XML_ERROR_FEATURE_REQUIRES_XML_DTD:                      return "XML_ERROR_FEATURE_REQUIRES_XML_DTD";
-         case XML_ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING:      return "XML_ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING";
-         case XML_ERROR_UNBOUND_PREFIX:                                        return "XML_ERROR_UNBOUND_PREFIX";
- // EXPAT version >= 1.95.8
-#if XML_MAJOR_VERSION>1 || (XML_MAJOR_VERSION==1 && XML_MINOR_VERSION>95) || (XML_MAJOR_VERSION==1 && XML_MINOR_VERSION==95 && XML_MICRO_VERSION>7)
-         case XML_ERROR_UNDECLARING_PREFIX:                            return "XML_ERROR_UNDECLARING_PREFIX";
-         case XML_ERROR_INCOMPLETE_PE:                                         return "XML_ERROR_INCOMPLETE_PE";
-         case XML_ERROR_XML_DECL:                                                      return "XML_ERROR_XML_DECL";
-         case XML_ERROR_TEXT_DECL:                                                     return "XML_ERROR_TEXT_DECL";
-         case XML_ERROR_PUBLICID:                                                      return "XML_ERROR_PUBLICID";
-         case XML_ERROR_SUSPENDED:                                                     return "XML_ERROR_SUSPENDED";
-         case XML_ERROR_NOT_SUSPENDED:                                         return "XML_ERROR_NOT_SUSPENDED";
-         case XML_ERROR_ABORTED:                                                       return "XML_ERROR_ABORTED";
-         case XML_ERROR_FINISHED:                                                      return "XML_ERROR_FINISHED";
-         case XML_ERROR_SUSPEND_PE:                                            return "XML_ERROR_SUSPEND_PE";
-#endif
-#if XML_MAJOR_VERSION>=2
-               /* Added in 2.0. */
-         case XML_ERROR_RESERVED_PREFIX_XML:                           return "XML_ERROR_RESERVED_PREFIX_XML";
-         case XML_ERROR_RESERVED_PREFIX_XMLNS:                         return "XML_ERROR_RESERVED_PREFIX_XMLNS";
-         case XML_ERROR_RESERVED_NAMESPACE_URI:                        return "XML_ERROR_RESERVED_NAMESPACE_URI";
-#endif
-       }
-
-       std::ostringstream out;
-
-       out << "XML parser error #" << error;
-
-       return out.str();
-}
-
-
- /// encode XML string literals
-std::string EncodeXMLString(const XS_String& str)
-{
-       LPCXSSTR s = str.c_str();
-       LPXSSTR buffer = (LPXSSTR)alloca(6*sizeof(XS_CHAR)*XS_len(s));  // worst case "&quot;" / "&apos;"
-       LPXSSTR o = buffer;
-
-       for(LPCXSSTR p=s; *p; ++p)
-               switch(*p) {
-                 case '&':
-                       *o++ = '&';     *o++ = 'a';     *o++ = 'm';     *o++ = 'p';     *o++ = ';';
-                       break;
-
-                 case '<':
-                       *o++ = '&';     *o++ = 'l'; *o++ = 't'; *o++ = ';';
-                       break;
-
-                 case '>':
-                       *o++ = '&';     *o++ = 'g'; *o++ = 't'; *o++ = ';';
-                       break;
-
-                 case '"':
-                       *o++ = '&';     *o++ = 'q'; *o++ = 'u'; *o++ = 'o'; *o++ = 't'; *o++ = ';';
-                       break;
-
-                 case '\'':
-                       *o++ = '&';     *o++ = 'a'; *o++ = 'p'; *o++ = 'o'; *o++ = 's'; *o++ = ';';
-                       break;
-
-                 default:
-                       if ((unsigned)*p<20 && *p!='\t' && *p!='\r' && *p!='\n') {
-                               char b[16];
-                               sprintf(b, "&%d;", (unsigned)*p);
-                               for(const char*q=b; *q; )
-                                       *o++ = *q++;
-                       } else
-                               *o++ = *p;
-               }
-
-#ifdef XS_STRING_UTF8
-       return XS_String(buffer, o-buffer);
-#else
-       return get_utf8(buffer, o-buffer);
-#endif
-}
-
- /// decode XML string literals
-XS_String DecodeXMLString(const XS_String& str)
-{
-       LPCXSSTR s = str.c_str();
-       LPXSSTR buffer = (LPXSSTR)alloca(sizeof(XS_CHAR)*XS_len(s));
-       LPXSSTR o = buffer;
-
-       for(LPCXSSTR p=s; *p; ++p)
-               if (*p == '&') {
-                       if (!XS_nicmp(p+1, XS_TEXT("lt;"), 3)) {
-                               *o++ = '<';
-                               p += 3;
-                       } else if (!XS_nicmp(p+1, XS_TEXT("gt;"), 3)) {
-                               *o++ = '>';
-                               p += 3;
-                       } else if (!XS_nicmp(p+1, XS_TEXT("amp;"), 4)) {
-                               *o++ = '&';
-                               p += 4;
-                       } else if (!XS_nicmp(p+1, XS_TEXT("quot;"), 5)) {
-                               *o++ = '"';
-                               p += 5;
-                       } else if (!XS_nicmp(p+1, XS_TEXT("apos;"), 5)) {
-                               *o++ = '\'';
-                               p += 5;
-                       } else
-                               *o++ = *p;
-               } else
-                       *o++ = *p;
-
-       return XS_String(buffer, o-buffer);
-}
-
-
- /// write node with children tree to output stream using original white space
-void XMLNode::write_worker(std::ostream& out, int indent) const
-{
-       out << _leading << '<' << EncodeXMLString(*this);
-
-       for(AttributeMap::const_iterator it=_attributes.begin(); it!=_attributes.end(); ++it)
-               out << ' ' << EncodeXMLString(it->first) << "=\"" << EncodeXMLString(it->second) << "\"";
-
-       if (!_children.empty() || !_content.empty()) {
-               out << '>' << _content;
-
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it)
-                       (*it)->write_worker(out, indent+1);
-
-               out << _end_leading << "</" << EncodeXMLString(*this) << '>';
-       } else
-               out << "/>";
-
-       out << _trailing;
-}
-
-
- /// pretty print node with children tree to output stream
-void XMLNode::pretty_write_worker(std::ostream& out, int indent) const
-{
-       for(int i=indent; i--; )
-               out << XML_INDENT_SPACE;
-
-       out << '<' << EncodeXMLString(*this);
-
-       for(AttributeMap::const_iterator it=_attributes.begin(); it!=_attributes.end(); ++it)
-               out << ' ' << EncodeXMLString(it->first) << "=\"" << EncodeXMLString(it->second) << "\"";
-
-       if (!_children.empty() || !_content.empty()) {
-               out << ">\n";
-
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it)
-                       (*it)->pretty_write_worker(out, indent+1);
-
-               for(int i=indent; i--; )
-                       out << XML_INDENT_SPACE;
-
-               out << "</" << EncodeXMLString(*this) << ">\n";
-       } else
-               out << "/>\n";
-}
-
-
- /// write node with children tree to output stream using smart formating
-void XMLNode::smart_write_worker(std::ostream& out, int indent) const
-{
-       if (_leading.empty())
-               for(int i=indent; i--; )
-                       out << XML_INDENT_SPACE;
-       else
-               out << _leading;
-
-       out << '<' << EncodeXMLString(*this);
-
-       for(AttributeMap::const_iterator it=_attributes.begin(); it!=_attributes.end(); ++it)
-               out << ' ' << EncodeXMLString(it->first) << "=\"" << EncodeXMLString(it->second) << "\"";
-
-       if (_children.empty() && _content.empty())
-               out << "/>";
-       else {
-               out << '>';
-
-               if (_content.empty())
-                       out << '\n';
-               else
-                       out << _content;
-
-               Children::const_iterator it = _children.begin();
-
-               if (it != _children.end()) {
-                       for(; it!=_children.end(); ++it)
-                               (*it)->smart_write_worker(out, indent+1);
-
-                       if (_end_leading.empty())
-                               for(int i=indent; i--; )
-                                       out << XML_INDENT_SPACE;
-                       else
-                               out << _end_leading;
-               } else
-                       out << _end_leading;
-
-               out << "</" << EncodeXMLString(*this) << '>';
-       }
-
-       if (_trailing.empty())
-               out << '\n';
-       else
-               out << _trailing;
-}
-
-
-}      // namespace XMLStorage
diff --git a/reactos/subsys/system/explorer/utility/xmlstorage.h b/reactos/subsys/system/explorer/utility/xmlstorage.h
deleted file mode 100644 (file)
index 125a693..0000000
+++ /dev/null
@@ -1,1940 +0,0 @@
-
- //
- // XML storage classes
- //
- // xmlstorage.h
- //
- // Copyright (c) 2004, 2005 Martin Fuchs <martin-fuchs@gmx.net>
- //
-
-
-/*
-
-  All rights reserved.
-
-  Redistribution and use in source and binary forms, with or without
-  modification, are permitted provided that the following conditions are met:
-
-  * Redistributions of source code must retain the above copyright
-       notice, this list of conditions and the following disclaimer.
-  * Redistributions in binary form must reproduce the above copyright
-       notice, this list of conditions and the following disclaimer in
-       the documentation and/or other materials provided with the
-       distribution.
-
-  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-  ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-  LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-  CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-  SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-  INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-  CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-  POSSIBILITY OF SUCH DAMAGE.
-
-*/
-
-#ifndef _XMLSTORAGE_H
-
-#include <expat/expat.h>
-
-#ifdef _MSC_VER
-#pragma comment(lib, "libexpat.lib")
-#pragma warning(disable: 4786)
-#endif
-
-
-#include <windows.h>   // for LPCTSTR
-
-#ifdef UNICODE
-#define _UNICODE
-#endif
-
-#include <tchar.h>
-#include <malloc.h>
-
-#include <fstream>
-#include <sstream>
-#include <string>
-#include <stack>
-#include <list>
-#include <map>
-
-
-#ifndef BUFFER_LEN
-#define BUFFER_LEN 2048
-#endif
-
-
-namespace XMLStorage {
-
-
-#ifndef XS_String
-
-#ifdef XS_STRING_UTF8
-#define        XS_CHAR char
-#define        XS_TEXT(x) x
-#define LPXSSTR LPSTR
-#define LPCXSSTR LPCSTR
-#define        XS_icmp stricmp
-#define        XS_nicmp strnicmp
-#define        XS_toi atoi
-#define        XS_len strlen
-#define        XS_snprintf snprintf
-#define        XS_vsnprintf vsnprintf
-#else
-#define        XS_CHAR TCHAR
-#define        XS_TEXT(x) TEXT(x)
-#define LPXSSTR LPTSTR
-#define LPCXSSTR LPCTSTR
-#define        XS_icmp _tcsicmp
-#define        XS_nicmp _tcsnicmp
-#define        XS_toi _ttoi
-#define        XS_len _tcslen
-#define        XS_snprintf _sntprintf
-#define        XS_vsnprintf _vsntprintf
-#endif
-
-#ifndef COUNTOF
-#define COUNTOF(b) (sizeof(b)/sizeof(b[0]))
-#endif
-
-#if defined(_STRING_DEFINED) && !defined(XS_STRING_UTF8)
-
-#define        XS_String String
-
-#else // _STRING_DEFINED, !XS_STRING_UTF8
-
- /// string class for TCHAR strings
-
-struct XS_String
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
- : public std::wstring
-#else
- : public std::string
-#endif
-{
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-       typedef std::wstring super;
-#else
-       typedef std::string super;
-#endif
-
-       XS_String() {}
-
-       XS_String(LPCXSSTR s) {if (s) super::assign(s);}
-       XS_String(LPCXSSTR s, size_t l) : super(s, l) {}
-
-       XS_String(const super& other) : super(other) {}
-       XS_String(const XS_String& other) : super(other) {}
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-       XS_String(LPCSTR s) {assign(s);}
-       XS_String(LPCSTR s, size_t l) {assign(s, l);}
-       XS_String(const std::string& other) {assign(other.c_str());}
-       XS_String& operator=(LPCSTR s) {assign(s); return *this;}
-       void assign(LPCSTR s) {if (s) {size_t bl=strlen(s); LPWSTR b=(LPWSTR)alloca(sizeof(WCHAR)*bl); super::assign(b, MultiByteToWideChar(CP_ACP, 0, s, bl, b, bl));} else erase();}
-       void assign(LPCSTR s, size_t l) {if (s) {size_t bl=l; LPWSTR b=(LPWSTR)alloca(sizeof(WCHAR)*bl); super::assign(b, MultiByteToWideChar(CP_ACP, 0, s, l, b, bl));} else erase();}
-#else
-       XS_String(LPCWSTR s) {assign(s);}
-       XS_String(LPCWSTR s, size_t l) {assign(s, l);}
-       XS_String(const std::wstring& other) {assign(other.c_str());}
-       XS_String& operator=(LPCWSTR s) {assign(s); return *this;}
-#ifdef XS_STRING_UTF8
-       void assign(const XS_String& s) {assign(s.c_str());}
-       void assign(LPCWSTR s) {if (s) {size_t bl=wcslen(s); LPSTR b=(LPSTR)alloca(bl); super::assign(b, WideCharToMultiByte(CP_UTF8, 0, s, (int)bl, b, (int)bl, 0, 0));} else erase();}
-       void assign(LPCWSTR s, size_t l) {size_t bl=l; if (s) {LPSTR b=(LPSTR)alloca(bl); super::assign(b, WideCharToMultiByte(CP_UTF8, 0, s, (int)l, b, (int)bl, 0, 0));} else erase();}
-#else // if !UNICODE && !XS_STRING_UTF8
-       void assign(LPCWSTR s) {if (s) {size_t bl=wcslen(s); LPSTR b=(LPSTR)alloca(bl); super::assign(b, WideCharToMultiByte(CP_ACP, 0, s, (int)bl, b, (int)bl, 0, 0));} else erase();}
-       void assign(LPCWSTR s, size_t l) {size_t bl=l; if (s) {LPSTR b=(LPSTR)alloca(bl); super::assign(b, WideCharToMultiByte(CP_ACP, 0, s, (int)l, b, (int)bl, 0, 0));} else erase();}
-#endif
-#endif
-
-       XS_String& operator=(LPCXSSTR s) {if (s) super::assign(s); else erase(); return *this;}
-       XS_String& operator=(const super& s) {super::assign(s); return *this;}
-       void assign(LPCXSSTR s) {super::assign(s);}
-       void assign(LPCXSSTR s, size_t l) {super::assign(s, l);}
-
-       operator LPCXSSTR() const {return c_str();}
-
-#ifdef XS_STRING_UTF8
-       operator std::wstring() const {size_t bl=length(); LPWSTR b=(LPWSTR)alloca(sizeof(WCHAR)*bl); return std::wstring(b, MultiByteToWideChar(CP_UTF8, 0, c_str(), bl, b, bl));}
-#elif defined(UNICODE)
-       operator std::string() const {size_t bl=length(); LPSTR b=(LPSTR)alloca(bl); return std::string(b, WideCharToMultiByte(CP_ACP, 0, c_str(), bl, b, bl, 0, 0));}
-#else
-       operator std::wstring() const {size_t bl=length(); LPWSTR b=(LPWSTR)alloca(sizeof(WCHAR)*bl); return std::wstring(b, MultiByteToWideChar(CP_ACP, 0, c_str(), (int)bl, b, (int)bl));}
-#endif
-
-       XS_String& printf(LPCXSSTR fmt, ...)
-       {
-               va_list l;
-               XS_CHAR b[BUFFER_LEN];
-
-               va_start(l, fmt);
-               super::assign(b, XS_vsnprintf(b, COUNTOF(b), fmt, l));
-               va_end(l);
-
-               return *this;
-       }
-
-       XS_String& vprintf(LPCXSSTR fmt, va_list l)
-       {
-               XS_CHAR b[BUFFER_LEN];
-
-               super::assign(b, XS_vsnprintf(b, COUNTOF(b), fmt, l));
-
-               return *this;
-       }
-
-       XS_String& appendf(LPCXSSTR fmt, ...)
-       {
-               va_list l;
-               XS_CHAR b[BUFFER_LEN];
-
-               va_start(l, fmt);
-               super::append(b, XS_vsnprintf(b, COUNTOF(b), fmt, l));
-               va_end(l);
-
-               return *this;
-       }
-
-       XS_String& vappendf(LPCXSSTR fmt, va_list l)
-       {
-               XS_CHAR b[BUFFER_LEN];
-
-               super::append(b, XS_vsnprintf(b, COUNTOF(b), fmt, l));
-
-               return *this;
-       }
-};
-
-#endif // _STRING_DEFINED, !XS_STRING_UTF8
-
-#endif // XS_String
-
-
-#ifndef XS_STRING_UTF8
-
-inline void assign_utf8(XS_String& s, const char* str)
-{
-       int lutf8 = (int)strlen(str);
-
-#ifdef UNICODE
-       LPTSTR buffer = (LPTSTR)alloca(sizeof(TCHAR)*lutf8);
-       int l = MultiByteToWideChar(CP_UTF8, 0, str, lutf8, buffer, lutf8);
-#else
-       LPWSTR wbuffer = (LPWSTR)alloca(sizeof(WCHAR)*lutf8);
-       int l = MultiByteToWideChar(CP_UTF8, 0, str, lutf8, wbuffer, lutf8);
-
-       int bl=2*l; LPSTR buffer = (LPSTR)alloca(bl);
-       l = WideCharToMultiByte(CP_ACP, 0, wbuffer, l, buffer, bl, 0, 0);
-#endif
-
-       s.assign(buffer, l);
-}
-
-inline std::string get_utf8(LPCTSTR s, size_t l)
-{
-#ifdef UNICODE
-       size_t bl=2*l; LPSTR buffer = (LPSTR)alloca(bl);
-       l = WideCharToMultiByte(CP_UTF8, 0, s, (int)l, buffer, (int)bl, 0, 0);
-#else
-       LPWSTR wbuffer = (LPWSTR)alloca(sizeof(WCHAR)*l);
-       l = MultiByteToWideChar(CP_ACP, 0, s, (int)l, wbuffer, (int)l);
-
-       size_t bl=2*l; LPSTR buffer = (LPSTR)alloca(bl);
-       l = WideCharToMultiByte(CP_UTF8, 0, wbuffer, (int)l, buffer, (int)bl, 0, 0);
-#endif
-
-       return std::string(buffer, l);
-}
-
-inline std::string get_utf8(const XS_String& s)
-{
-       return get_utf8(s.c_str(), s.length());
-}
-
-#endif // XS_STRING_UTF8
-
-extern std::string EncodeXMLString(const XS_String& str);
-extern XS_String DecodeXMLString(const XS_String& str);
-
-
-#ifdef __GNUC__
-#include <ext/stdio_filebuf.h>
-typedef __gnu_cxx::stdio_filebuf<char> STDIO_FILEBUF;
-#else
-typedef std::filebuf STDIO_FILEBUF;
-#endif
-
-
-struct FileHolder
-{
-       FileHolder(LPCTSTR path, LPCTSTR mode)
-       {
-#ifdef __STDC_WANT_SECURE_LIB__        // secure CRT functions using VS 2005
-               if (_tfopen_s(&_pfile, path, mode) != 0)
-                       _pfile = NULL;
-#else
-               _pfile = _tfopen(path, mode);
-#endif
-       }
-
-       ~FileHolder()
-       {
-               if (_pfile)
-                       fclose(_pfile);
-       }
-
-protected:
-       FILE*   _pfile;
-};
-
- /// input file stream with ANSI/UNICODE file names
-struct tifstream : public std::istream, FileHolder
-{
-       typedef std::istream super;
-
-       tifstream(LPCTSTR path)
-        :      super(&_buf),
-               FileHolder(path, TEXT("r")),
-#ifdef __GNUC__
-               _buf(_pfile, ios::in)
-#else
-               _buf(_pfile)
-#endif
-       {
-       }
-
-protected:
-       STDIO_FILEBUF _buf;
-};
-
- /// output file stream with ANSI/UNICODE file names
-struct tofstream : public std::ostream, FileHolder
-{
-       typedef std::ostream super;
-
-       tofstream(LPCTSTR path)
-        :      super(&_buf),
-               FileHolder(path, TEXT("w")),
-#ifdef __GNUC__
-               _buf(_pfile, ios::out)
-#else
-               _buf(_pfile)
-#endif
-       {
-       }
-
-       ~tofstream()
-       {
-               flush();
-       }
-
-protected:
-       STDIO_FILEBUF _buf;
-};
-
-
- // write XML files with 2 spaces indenting
-#define XML_INDENT_SPACE "  "
-
-
-#ifdef XML_UNICODE     // Are XML_Char strings UTF-16 encoded?
-
-typedef XS_String String_from_XML_Char;
-
-#elif defined(XS_STRING_UTF8)
-
-typedef XS_String String_from_XML_Char;
-
-#else
-
- /// converter from Expat strings to XMLStorage internal strings
-struct String_from_XML_Char : public XS_String
-{
-       String_from_XML_Char(const XML_Char* str)
-       {
-               assign_utf8(*this, str);
-       }
-};
-
-#endif
-
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-
- // optimization for faster UNICODE/ASCII string comparison without temporary A/U conversion
-inline bool operator==(const XS_String& s1, const char* s2)
-{
-       LPCWSTR p = s1;
-       const unsigned char* q = (const unsigned char*)s2;
-
-       while(*p && *q)
-               if (*p++ != *q++)
-                       return false;
-
-       return *p == *q;
-};
-
-#endif
-
-
- /// in memory representation of an XML node
-struct XMLNode : public XS_String
-{
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-        // optimized read access without temporary A/U conversion when using ASCII attribute names
-       struct AttributeMap : public std::map<XS_String, XS_String>
-       {
-               typedef std::map<XS_String, XS_String> super;
-
-               const_iterator find(const char* x) const
-               {
-                       for(const_iterator it=begin(); it!=end(); ++it)
-                               if (it->first == x)
-                                       return it;
-
-                       return end();
-               }
-
-               const_iterator find(const key_type& x) const
-               {
-                       return super::find(x);
-               }
-
-               iterator find(const key_type& x)
-               {
-                       return super::find(x);
-               }
-       };
-#else
-       typedef std::map<XS_String, XS_String> AttributeMap;
-#endif
-
-        /// internal children node list
-       struct Children : public std::list<XMLNode*>
-       {
-               void assign(const Children& other)
-               {
-                       clear();
-
-                       for(Children::const_iterator it=other.begin(); it!=other.end(); ++it)
-                               push_back(new XMLNode(**it));
-               }
-
-               void clear()
-               {
-                       while(!empty()) {
-                               XMLNode* node = back();
-                               pop_back();
-
-                               node->clear();
-                               delete node;
-                       }
-               }
-       };
-
-        // access to protected class members for XMLPos and XMLReader
-       friend struct XMLPos;
-       friend struct const_XMLPos;
-       friend struct XMLReaderBase;
-
-       XMLNode(const XS_String& name)
-        :      XS_String(name)
-       {
-       }
-
-       XMLNode(const XS_String& name, const std::string& leading)
-        :      XS_String(name),
-               _leading(leading)
-       {
-       }
-
-       XMLNode(const XMLNode& other)
-        :      _attributes(other._attributes),
-               _leading(other._leading),
-               _content(other._content),
-               _end_leading(other._end_leading),
-               _trailing(other._trailing)
-       {
-               for(Children::const_iterator it=other._children.begin(); it!=other._children.end(); ++it)
-                       _children.push_back(new XMLNode(**it));
-       }
-
-       ~XMLNode()
-       {
-               while(!_children.empty()) {
-                       delete _children.back();
-                       _children.pop_back();
-               }
-       }
-
-       void clear()
-       {
-               _leading.erase();
-               _content.erase();
-               _end_leading.erase();
-               _trailing.erase();
-
-               _attributes.clear();
-               _children.clear();
-
-               XS_String::erase();
-       }
-
-       XMLNode& operator=(const XMLNode& other)
-       {
-               _children.assign(other._children);
-
-               _attributes = other._attributes;
-
-               _leading = other._leading;
-               _content = other._content;
-               _end_leading = other._end_leading;
-               _trailing = other._trailing;
-
-               return *this;
-       }
-
-        /// add a new child node
-       void add_child(XMLNode* child)
-       {
-               _children.push_back(child);
-       }
-
-        /// write access to an attribute
-       void put(const XS_String& attr_name, const XS_String& value)
-       {
-               _attributes[attr_name] = value;
-       }
-
-        /// C++ write access to an attribute
-       XS_String& operator[](const XS_String& attr_name)
-       {
-               return _attributes[attr_name];
-       }
-
-        /// read only access to an attribute
-       template<typename T> XS_String get(const T& attr_name) const
-       {
-               AttributeMap::const_iterator found = _attributes.find(attr_name);
-
-               if (found != _attributes.end())
-                       return found->second;
-               else
-                       return XS_String();
-       }
-
-        /// convenient value access in children node
-       XS_String subvalue(const XS_String& name, const XS_String& attr_name, int n=0) const
-       {
-               const XMLNode* node = find(name, n);
-
-               if (node)
-                       return node->get(attr_name);
-               else
-                       return XS_String();
-       }
-
-        /// convenient storage of distinct values in children node
-       XS_String& subvalue(const XS_String& name, const XS_String& attr_name, int n=0)
-       {
-               XMLNode* node = find(name, n);
-
-               if (!node) {
-                       node = new XMLNode(name);
-                       add_child(node);
-               }
-
-               return (*node)[attr_name];
-       }
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-        /// convenient value access in children node
-       XS_String subvalue(const char* name, const char* attr_name, int n=0) const
-       {
-               const XMLNode* node = find(name, n);
-
-               if (node)
-                       return node->get(attr_name);
-               else
-                       return XS_String();
-       }
-
-        /// convenient storage of distinct values in children node
-       XS_String& subvalue(const char* name, const XS_String& attr_name, int n=0)
-       {
-               XMLNode* node = find(name, n);
-
-               if (!node) {
-                       node = new XMLNode(name);
-                       add_child(node);
-               }
-
-               return (*node)[attr_name];
-       }
-#endif
-
-       const Children& get_children() const
-       {
-               return _children;
-       }
-
-       Children& get_children()
-       {
-               return _children;
-       }
-
-       XS_String get_content() const
-       {
-#ifdef XS_STRING_UTF8
-               const XS_String& ret = _content;
-#else
-               XS_String ret;
-               assign_utf8(ret, _content.c_str());
-#endif
-
-               return DecodeXMLString(ret.c_str());
-       }
-
-       void set_content(const XS_String& s)
-       {
-               _content.assign(EncodeXMLString(s.c_str()));
-       }
-
-       enum WRITE_MODE {
-               FORMAT_SMART    = 0,    /// preserve original white space and comments if present; pretty print otherwise
-               FORMAT_ORIGINAL = 1,    /// write XML stream preserving original white space and comments
-               FORMAT_PRETTY   = 2     /// pretty print node to stream without preserving original white space
-       };
-
-        /// write node with children tree to output stream
-       std::ostream& write(std::ostream& out, WRITE_MODE mode=FORMAT_SMART, int indent=0) const
-       {
-               switch(mode) {
-                 case FORMAT_PRETTY:
-                       pretty_write_worker(out, indent);
-                       break;
-
-                 case FORMAT_ORIGINAL:
-                       write_worker(out, indent);
-                       break;
-
-               default:         // FORMAT_SMART
-                       smart_write_worker(out, indent);
-               }
-
-               return out;
-       }
-
-protected:
-       Children _children;
-       AttributeMap _attributes;
-
-       std::string _leading;
-       std::string _content;
-       std::string _end_leading;
-       std::string _trailing;
-
-       XMLNode* get_first_child() const
-       {
-               if (!_children.empty())
-                       return _children.front();
-               else
-                       return NULL;
-       }
-
-       XMLNode* find(const XS_String& name, int n=0) const
-       {
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it)
-                       if (**it == name)
-                               if (!n--)
-                                       return *it;
-
-               return NULL;
-       }
-
-       XMLNode* find(const XS_String& name, const XS_String& attr_name, const XS_String& attr_value, int n=0) const
-       {
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it) {
-                       const XMLNode& node = **it;
-
-                       if (node==name && node.get(attr_name)==attr_value)
-                               if (!n--)
-                                       return *it;
-               }
-
-               return NULL;
-       }
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-       XMLNode* find(const char* name, int n=0) const
-       {
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it)
-                       if (**it == name)
-                               if (!n--)
-                                       return *it;
-
-               return NULL;
-       }
-
-       template<typename T, typename U>
-       XMLNode* find(const char* name, const T& attr_name, const U& attr_value, int n=0) const
-       {
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it) {
-                       const XMLNode& node = **it;
-
-                       if (node==name && node.get(attr_name)==attr_value)
-                               if (!n--)
-                                       return *it;
-               }
-
-               return NULL;
-       }
-#endif
-
-        /// XPath find function (const)
-       const XMLNode* find_relative(const char* path) const;
-
-        /// XPath find function
-       XMLNode* find_relative(const char* path)
-               {return const_cast<XMLNode*>(const_cast<const XMLNode*>(this)->find_relative(path));}
-
-        /// relative XPath create function
-       XMLNode* create_relative(const char* path);
-
-       void write_worker(std::ostream& out, int indent) const;
-       void pretty_write_worker(std::ostream& out, int indent) const;
-       void smart_write_worker(std::ostream& out, int indent) const;
-};
-
-
- /// iterator access to children nodes with name filtering
-struct XMLChildrenFilter
-{
-       XMLChildrenFilter(XMLNode::Children& children, const XS_String& name)
-        :      _begin(children.begin(), children.end(), name),
-               _end(children.end(), children.end(), name)
-       {
-       }
-
-       XMLChildrenFilter(XMLNode* node, const XS_String& name)
-        :      _begin(node->get_children().begin(), node->get_children().end(), name),
-               _end(node->get_children().end(), node->get_children().end(), name)
-       {
-       }
-
-        /// internal iterator class
-       struct iterator
-       {
-               typedef XMLNode::Children::iterator BaseIterator;
-
-               iterator(BaseIterator begin, BaseIterator end, const XS_String& filter_name)
-                :      _cur(begin),
-                       _end(end),
-                       _filter_name(filter_name)
-               {
-                       search_next();
-               }
-
-               operator BaseIterator()
-               {
-                       return _cur;
-               }
-
-               const XMLNode* operator*() const
-               {
-                       return *_cur;
-               }
-
-               XMLNode* operator*()
-               {
-                       return *_cur;
-               }
-
-               iterator& operator++()
-               {
-                       ++_cur;
-                       search_next();
-
-                       return *this;
-               }
-
-               iterator operator++(int)
-               {
-                       iterator ret = *this;
-
-                       ++_cur;
-                       search_next();
-
-                       return ret;
-               }
-
-               bool operator==(const BaseIterator& other) const
-               {
-                       return _cur == other;
-               }
-
-               bool operator!=(const BaseIterator& other) const
-               {
-                       return _cur != other;
-               }
-
-       protected:
-               BaseIterator    _cur;
-               BaseIterator    _end;
-               XS_String       _filter_name;
-
-               void search_next()
-               {
-                       while(_cur!=_end && **_cur!=_filter_name)
-                               ++_cur;
-               }
-       };
-
-       iterator begin()
-       {
-               return _begin;
-       }
-
-       iterator end()
-       {
-               return _end;
-       }
-
-protected:
-       iterator        _begin;
-       iterator        _end;
-};
-
-
- /// read only iterator access to children nodes with name filtering
-struct const_XMLChildrenFilter
-{
-       const_XMLChildrenFilter(const XMLNode::Children& children, const XS_String& name)
-        :      _begin(children.begin(), children.end(), name),
-               _end(children.end(), children.end(), name)
-       {
-       }
-
-       const_XMLChildrenFilter(const XMLNode* node, const XS_String& name)
-        :      _begin(node->get_children().begin(), node->get_children().end(), name),
-               _end(node->get_children().end(), node->get_children().end(), name)
-       {
-       }
-
-        /// internal iterator class
-       struct const_iterator
-       {
-               typedef XMLNode::Children::const_iterator BaseIterator;
-
-               const_iterator(BaseIterator begin, BaseIterator end, const XS_String& filter_name)
-                :      _cur(begin),
-                       _end(end),
-                       _filter_name(filter_name)
-               {
-                       search_next();
-               }
-
-               operator BaseIterator()
-               {
-                       return _cur;
-               }
-
-               const XMLNode* operator*() const
-               {
-                       return *_cur;
-               }
-
-               const_iterator& operator++()
-               {
-                       ++_cur;
-                       search_next();
-
-                       return *this;
-               }
-
-               const_iterator operator++(int)
-               {
-                       const_iterator ret = *this;
-
-                       ++_cur;
-                       search_next();
-
-                       return ret;
-               }
-
-               bool operator==(const BaseIterator& other) const
-               {
-                       return _cur == other;
-               }
-
-               bool operator!=(const BaseIterator& other) const
-               {
-                       return _cur != other;
-               }
-
-       protected:
-               BaseIterator    _cur;
-               BaseIterator    _end;
-               XS_String       _filter_name;
-
-               void search_next()
-               {
-                       while(_cur!=_end && **_cur!=_filter_name)
-                               ++_cur;
-               }
-       };
-
-       const_iterator begin()
-       {
-               return _begin;
-       }
-
-       const_iterator end()
-       {
-               return _end;
-       }
-
-protected:
-       const_iterator  _begin;
-       const_iterator  _end;
-};
-
-
- /// iterator for XML trees
-struct XMLPos
-{
-       XMLPos(XMLNode* root)
-        :      _root(root),
-               _cur(root)
-       {
-       }
-
-       XMLPos(const XMLPos& other)
-        :      _root(other._root),
-               _cur(other._cur)
-       {       // don't copy _stack
-       }
-
-       XMLPos(XMLNode* node, const XS_String& name)
-        :      _root(node),
-               _cur(node)
-       {
-               smart_create(name);
-       }
-
-       XMLPos(XMLNode* node, const XS_String& name, const XS_String& attr_name, const XS_String& attr_value)
-        :      _root(node),
-               _cur(node)
-       {
-               smart_create(name, attr_name, attr_value);
-       }
-
-       XMLPos(const XMLPos& other, const XS_String& name)
-        :      _root(other._root),
-               _cur(other._cur)
-       {
-               smart_create(name);
-       }
-
-       XMLPos(const XMLPos& other, const XS_String& name, const XS_String& attr_name, const XS_String& attr_value)
-        :      _root(other._root),
-               _cur(other._cur)
-       {
-               smart_create(name, attr_name, attr_value);
-       }
-
-        /// access to current node
-       XMLNode& cur()
-       {
-               return *_cur;
-       }
-
-       const XMLNode& cur() const
-       {
-               return *_cur;
-       }
-
-        /// C++ access to current node
-       operator const XMLNode*() const {return _cur;}
-       operator XMLNode*() {return _cur;}
-
-       const XMLNode* operator->() const {return _cur;}
-       XMLNode* operator->() {return _cur;}
-
-       const XMLNode& operator*() const {return *_cur;}
-       XMLNode& operator*() {return *_cur;}
-
-        /// attribute access
-       XS_String get(const XS_String& attr_name) const
-       {
-               return _cur->get(attr_name);
-       }
-
-        /// attribute setting
-       void put(const XS_String& attr_name, const XS_String& value)
-       {
-               _cur->put(attr_name, value);
-       }
-
-        /// C++ attribute access
-       template<typename T> XS_String get(const T& attr_name) const {return (*_cur)[attr_name];}
-       XS_String& operator[](const XS_String& attr_name) {return (*_cur)[attr_name];}
-
-        /// insert children when building tree
-       void add_down(XMLNode* child)
-       {
-               _cur->add_child(child);
-               go_to(child);
-       }
-
-        /// go back to previous position
-       bool back()
-       {
-               if (!_stack.empty()) {
-                       _cur = _stack.top();
-                       _stack.pop();
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// go down to first child
-       bool go_down()
-       {
-               XMLNode* node = _cur->get_first_child();
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// search for child and go down
-       bool go_down(const XS_String& name, int n=0)
-       {
-               XMLNode* node = _cur->find(name, n);
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// move XPath like to position in XML tree
-       bool go(const char* path);
-
-        /// create child nodes using XPath notation and move to the deepest child
-       bool create_relative(const char* path)
-       {
-               XMLNode* node = _cur->create_relative(path);
-               if (!node)
-                       return false;   // invalid path specified
-
-               go_to(node);
-               return true;
-       }
-
-        /// create node and move to it
-       void create(const XS_String& name)
-       {
-               add_down(new XMLNode(name));
-       }
-
-        /// create node if not already existing and move to it
-       void smart_create(const XS_String& name)
-       {
-               XMLNode* node = _cur->find(name);
-
-               if (node)
-                       go_to(node);
-               else
-                       add_down(new XMLNode(name));
-       }
-
-        /// search matching child node identified by key name and an attribute value
-       void smart_create(const XS_String& name, const XS_String& attr_name, const XS_String& attr_value)
-       {
-               XMLNode* node = _cur->find(name, attr_name, attr_value);
-
-               if (node)
-                       go_to(node);
-               else {
-                       node = new XMLNode(name);
-                       add_down(node);
-                       (*node)[attr_name] = attr_value;
-               }
-       }
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-        /// search for child and go down
-       bool go_down(const char* name, int n=0)
-       {
-               XMLNode* node = _cur->find(name, n);
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// create node and move to it
-       void create(const char* name)
-       {
-               add_down(new XMLNode(name));
-       }
-
-        /// create node if not already existing and move to it
-       void smart_create(const char* name)
-       {
-               XMLNode* node = _cur->find(name);
-
-               if (node)
-                       go_to(node);
-               else
-                       add_down(new XMLNode(name));
-       }
-
-        /// search matching child node identified by key name and an attribute value
-       template<typename T, typename U>
-       void smart_create(const char* name, const T& attr_name, const U& attr_value)
-       {
-               XMLNode* node = _cur->find(name, attr_name, attr_value);
-
-               if (node)
-                       go_to(node);
-               else {
-                       XMLNode* node = new XMLNode(name);
-                       add_down(node);
-                       (*node)[attr_name] = attr_value;
-               }
-       }
-#endif
-
-       XS_String& str() {return *_cur;}
-       const XS_String& str() const {return *_cur;}
-
-protected:
-       XMLNode* _root;
-       XMLNode* _cur;
-       std::stack<XMLNode*> _stack;
-
-        /// go to specified node
-       void go_to(XMLNode* child)
-       {
-               _stack.push(_cur);
-               _cur = child;
-       }
-};
-
-
- /// iterator for XML trees
-struct const_XMLPos
-{
-       const_XMLPos(const XMLNode* root)
-        :      _root(root),
-               _cur(root)
-       {
-       }
-
-       const_XMLPos(const const_XMLPos& other)
-        :      _root(other._root),
-               _cur(other._cur)
-       {       // don't copy _stack
-       }
-
-        /// access to current node
-       const XMLNode& cur() const
-       {
-               return *_cur;
-       }
-
-        /// C++ access to current node
-       operator const XMLNode*() const {return _cur;}
-
-       const XMLNode* operator->() const {return _cur;}
-
-       const XMLNode& operator*() const {return *_cur;}
-
-        /// attribute access
-       XS_String get(const XS_String& attr_name) const
-       {
-               return _cur->get(attr_name);
-       }
-
-        /// C++ attribute access
-       template<typename T> XS_String get(const T& attr_name) const {return _cur->get(attr_name);}
-
-        /// go back to previous position
-       bool back()
-       {
-               if (!_stack.empty()) {
-                       _cur = _stack.top();
-                       _stack.pop();
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// go down to first child
-       bool go_down()
-       {
-               const XMLNode* node = _cur->get_first_child();
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// search for child and go down
-       bool go_down(const XS_String& name, int n=0)
-       {
-               XMLNode* node = _cur->find(name, n);
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// move XPath like to position in XML tree
-       bool go(const char* path);
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-        /// search for child and go down
-       bool go_down(const char* name, int n=0)
-       {
-               XMLNode* node = _cur->find(name, n);
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-#endif
-
-       const XS_String& str() const {return *_cur;}
-
-protected:
-       const XMLNode* _root;
-       const XMLNode* _cur;
-       std::stack<const XMLNode*> _stack;
-
-        /// go to specified node
-       void go_to(const XMLNode* child)
-       {
-               _stack.push(_cur);
-               _cur = child;
-       }
-};
-
-
-#define        XS_TRUE_STR XS_TEXT("true")
-#define        XS_FALSE_STR XS_TEXT("false")
-#define        XS_NUMBERFMT_STR XS_TEXT("%d")
-
- // work around GCC's wide string constant bug
-#ifdef __GNUC__
-extern const LPCXSSTR XS_TRUE;
-extern const LPCXSSTR XS_FALSE;
-extern const LPCXSSTR XS_NUMBERFMT;
-#else
-#define        XS_TRUE XS_TRUE_STR
-#define        XS_FALSE XS_FALSE_STR
-#define        XS_NUMBERFMT XS_NUMBERFMT_STR
-#endif
-
-
- /// type converter for boolean data
-struct XMLBool
-{
-       XMLBool(bool value=false)
-        :      _value(value)
-       {
-       }
-
-       XMLBool(LPCXSSTR value, bool def=false)
-       {
-               if (value && *value)
-                       _value = !XS_icmp(value, XS_TRUE);
-               else
-                       _value = def;
-       }
-
-       XMLBool(const XMLNode* node, const XS_String& attr_name, bool def=false)
-       {
-               const XS_String& value = node->get(attr_name);
-
-               if (!value.empty())
-                       _value = !XS_icmp(value.c_str(), XS_TRUE);
-               else
-                       _value = def;
-       }
-
-       operator bool() const
-       {
-               return _value;
-       }
-
-       bool operator!() const
-       {
-               return !_value;
-       }
-
-       operator LPCXSSTR() const
-       {
-               return _value? XS_TRUE: XS_FALSE;
-       }
-
-protected:
-       bool    _value;
-
-private:
-       void operator=(const XMLBool&); // disallow assignment operations
-};
-
- /// type converter for boolean data with write access
-struct XMLBoolRef
-{
-       XMLBoolRef(XMLNode* node, const XS_String& attr_name, bool def=false)
-        :      _ref((*node)[attr_name])
-       {
-               if (_ref.empty())
-                       assign(def);
-       }
-
-       operator bool() const
-       {
-               return !XS_icmp(_ref.c_str(), XS_TRUE);
-       }
-
-       bool operator!() const
-       {
-               return XS_icmp(_ref.c_str(), XS_TRUE)? true: false;
-       }
-
-       XMLBoolRef& operator=(bool value)
-       {
-               assign(value);
-
-               return *this;
-       }
-
-       void assign(bool value)
-       {
-               _ref.assign(value? XS_TRUE: XS_FALSE);
-       }
-
-       void toggle()
-       {
-               assign(!operator bool());
-       }
-
-protected:
-       XS_String& _ref;
-};
-
-
- /// type converter for integer data
-struct XMLInt
-{
-       XMLInt(int value)
-        :      _value(value)
-       {
-       }
-
-       XMLInt(LPCXSSTR value, int def=0)
-       {
-               if (value && *value)
-                       _value = XS_toi(value);
-               else
-                       _value = def;
-       }
-
-       XMLInt(const XMLNode* node, const XS_String& attr_name, int def=0)
-       {
-               const XS_String& value = node->get(attr_name);
-
-               if (!value.empty())
-                       _value = XS_toi(value.c_str());
-               else
-                       _value = def;
-       }
-
-       operator int() const
-       {
-               return _value;
-       }
-
-       operator XS_String() const
-       {
-               XS_CHAR buffer[32];
-               XS_snprintf(buffer, COUNTOF(buffer), XS_NUMBERFMT, _value);
-               return buffer;
-       }
-
-protected:
-       int _value;
-
-private:
-       void operator=(const XMLInt&); // disallow assignment operations
-};
-
- /// type converter for integer data with write access
-struct XMLIntRef
-{
-       XMLIntRef(XMLNode* node, const XS_String& attr_name, int def=0)
-        :      _ref((*node)[attr_name])
-       {
-               if (_ref.empty())
-                       assign(def);
-       }
-
-       XMLIntRef& operator=(int value)
-       {
-               assign(value);
-
-               return *this;
-       }
-
-       operator int() const
-       {
-               return XS_toi(_ref.c_str());
-       }
-
-       void assign(int value)
-       {
-               XS_CHAR buffer[32];
-               XS_snprintf(buffer, COUNTOF(buffer), XS_NUMBERFMT, value);
-               _ref.assign(buffer);
-       }
-
-protected:
-       XS_String& _ref;
-};
-
-
- /// type converter for string data
-struct XMLString
-{
-       XMLString(const XS_String& value)
-        :      _value(value)
-       {
-       }
-
-       XMLString(LPCXSSTR value, LPCXSSTR def=XS_TEXT(""))
-       {
-               if (value && *value)
-                       _value = value;
-               else
-                       _value = def;
-       }
-
-       XMLString(const XMLNode* node, const XS_String& attr_name, LPCXSSTR def=XS_TEXT(""))
-       {
-               const XS_String& value = node->get(attr_name);
-
-               if (!value.empty())
-                       _value = value;
-               else
-                       _value = def;
-       }
-
-       operator const XS_String&() const
-       {
-               return _value;
-       }
-
-       const XS_String& c_str() const
-       {
-               return _value;
-       }
-
-protected:
-       XS_String       _value;
-
-private:
-       void operator=(const XMLString&); // disallow assignment operations
-};
-
- /// type converter for string data with write access
-struct XMStringRef
-{
-       XMStringRef(XMLNode* node, const XS_String& attr_name, LPCXSSTR def=XS_TEXT(""))
-        :      _ref((*node)[attr_name])
-       {
-               if (_ref.empty())
-                       assign(def);
-       }
-
-       XMStringRef(XMLNode* node, const XS_String& node_name, const XS_String& attr_name, LPCXSSTR def=XS_TEXT(""))
-        :      _ref(node->subvalue(node_name, attr_name))
-       {
-               if (_ref.empty())
-                       assign(def);
-       }
-
-       XMStringRef& operator=(const XS_String& value)
-       {
-               assign(value);
-
-               return *this;
-       }
-
-       operator const XS_String&() const
-       {
-               return _ref;
-       }
-
-       void assign(const XS_String& value)
-       {
-               _ref.assign(value);
-       }
-
-protected:
-       XS_String& _ref;
-};
-
-
-template<typename T>
-       inline void read_option(T& var, const_XMLPos& cfg, LPCXSSTR key)
-       {
-               const XS_String& val = cfg.get(key);
-
-               if (!val.empty())
-                       var = val;
-       }
-
-template<>
-       inline void read_option(int& var, const_XMLPos& cfg, LPCXSSTR key)
-       {
-               const XS_String& val = cfg.get(key);
-
-               if (!val.empty())
-                       var = XS_toi(val.c_str());
-       }
-
-
-#ifdef _MSC_VER
-#pragma warning(disable: 4355)
-#endif
-
- /// XML reader base class
-struct XMLReaderBase
-{
-       XMLReaderBase(XMLNode* node)
-        :      _pos(node),
-               _parser(XML_ParserCreate(NULL))
-       {
-               XML_SetUserData(_parser, this);
-               XML_SetXmlDeclHandler(_parser, XML_XmlDeclHandler);
-               XML_SetElementHandler(_parser, XML_StartElementHandler, XML_EndElementHandler);
-               XML_SetDefaultHandler(_parser, XML_DefaultHandler);
-
-               _last_tag = TAG_NONE;
-       }
-
-       virtual ~XMLReaderBase()
-       {
-               XML_ParserFree(_parser);
-       }
-
-       XML_Status read();
-
-       virtual int read_buffer(char* buffer, int len) = 0;
-
-       std::string get_position() const
-       {
-               int line = XML_GetCurrentLineNumber(_parser);
-               int column = XML_GetCurrentColumnNumber(_parser);
-
-               std::ostringstream out;
-               out << "(" << line << ") : [column " << column << "]";
-
-               return out.str();
-       }
-
-       std::string get_instructions() const {return _instructions;}
-
-       XML_Error       get_error_code() {return XML_GetErrorCode(_parser);}
-       std::string get_error_string() const;
-
-protected:
-       XMLPos          _pos;
-       XML_Parser      _parser;
-       std::string _xml_version;
-       std::string _encoding;
-       std::string     _instructions;
-
-       std::string _content;
-       enum {TAG_NONE, TAG_START, TAG_END} _last_tag;
-
-       static void XMLCALL XML_XmlDeclHandler(void* userData, const XML_Char* version, const XML_Char* encoding, int standalone);
-       static void XMLCALL XML_StartElementHandler(void* userData, const XML_Char* name, const XML_Char** atts);
-       static void XMLCALL XML_EndElementHandler(void* userData, const XML_Char* name);
-       static void XMLCALL XML_DefaultHandler(void* userData, const XML_Char* s, int len);
-};
-
-
- /// XML file reader
-struct XMLReader : public XMLReaderBase
-{
-       XMLReader(XMLNode* node, std::istream& in)
-        :      XMLReaderBase(node),
-               _in(in)
-       {
-       }
-
-        /// read XML stream into XML tree below _pos
-       int read_buffer(char* buffer, int len)
-       {
-               if (!_in.good())
-                       return -1;
-
-               _in.read(buffer, len);
-
-               return _in.gcount();
-       }
-
-protected:
-       std::istream&   _in;
-};
-
-
- /// management of XML file headers
-struct XMLHeader
-{
-       XMLHeader(const std::string& xml_version="1.0", const std::string& encoding="UTF-8", const std::string& doctype="")
-        :      _version(xml_version),
-               _encoding(encoding),
-               _doctype(doctype)
-       {
-       }
-
-       void print(std::ostream& out, bool pretty=true) const
-       {
-               out << "<?xml version=\"" << _version << "\" encoding=\"" << _encoding << "\"?>";
-
-               if (pretty)
-                       out << std::endl;
-
-               if (!_doctype.empty())
-                       out << _doctype << '\n';
-
-               if (!_additional.empty())
-                       out << _additional << '\n';
-       }
-
-       std::string _version;
-       std::string _encoding;
-       std::string _doctype;
-       std::string _additional;
-};
-
-
- /// XML document holder
-struct XMLDoc : public XMLNode
-{
-       XMLDoc()
-        :      XMLNode(""),
-               _last_error(XML_ERROR_NONE)
-       {
-       }
-
-       XMLDoc(LPCTSTR path)
-        :      XMLNode(""),
-               _last_error(XML_ERROR_NONE)
-       {
-               read(path);
-       }
-
-       std::istream& read(std::istream& in)
-       {
-               XMLReader reader(this, in);
-
-               read(reader);
-
-               return in;
-       }
-
-       bool read(LPCTSTR path)
-       {
-               tifstream in(path);
-               XMLReader reader(this, in);
-
-//#if defined(_STRING_DEFINED) && !defined(XS_STRING_UTF8)
-//             return read(reader, std::string(ANS(path)));
-//#else
-               return read(reader, XS_String(path));
-//#endif
-       }
-
-       bool read(XMLReaderBase& reader)
-       {
-               XML_Status status = reader.read();
-
-               _header._additional = reader.get_instructions();
-
-               if (status == XML_STATUS_ERROR) {
-                       std::ostringstream out;
-
-                       out << "input stream" << reader.get_position() << " " << reader.get_error_string();
-
-                       _last_error = reader.get_error_code();
-                       _last_error_msg = out.str();
-               }
-
-               return status != XML_STATUS_ERROR;
-       }
-
-       bool read(XMLReaderBase& reader, const std::string& display_path)
-       {
-               XML_Status status = reader.read();
-
-               _header._additional = reader.get_instructions();
-
-               if (status == XML_STATUS_ERROR) {
-                       std::ostringstream out;
-
-                       out << display_path << reader.get_position() << " " << reader.get_error_string();
-
-                       _last_error = reader.get_error_code();
-                       _last_error_msg = out.str();
-               }
-
-               return status != XML_STATUS_ERROR;
-       }
-
-        /// write XML stream preserving previous white space and comments
-       std::ostream& write(std::ostream& out, WRITE_MODE mode=FORMAT_SMART) const
-       {
-               _header.print(out);
-
-               if (!_children.empty())
-                       _children.front()->write(out);
-
-               return out;
-       }
-
-        /// write XML stream with formating
-       std::ostream& write_formating(std::ostream& out) const
-       {
-               return write(out, FORMAT_PRETTY);
-       }
-
-       void write(LPCTSTR path, WRITE_MODE mode=FORMAT_SMART) const
-       {
-               tofstream out(path);
-
-               write(out, mode);
-       }
-
-       void write_formating(LPCTSTR path) const
-       {
-               tofstream out(path);
-
-               write_formating(out);
-       }
-
-       XMLHeader       _header;
-       XML_Error       _last_error;
-       std::string _last_error_msg;
-};
-
-
- /// XML message wrapper
-struct XMLMessage : public XMLDoc
-{
-       XMLMessage(const char* name)
-        :      _pos(this)
-       {
-               _pos.create(name);
-       }
-
-       XMLPos  _pos;
-};
-
-
-enum PRETTY_FLAGS {
-       PRETTY_PLAIN    = 0,
-       PRETTY_LINEFEED = 1,
-       PRETTY_INDENT   = 2
-};
-
-struct XMLWriter
-{
-       XMLWriter(std::ostream& out, PRETTY_FLAGS pretty=PRETTY_INDENT, const XMLHeader& header=XMLHeader())
-        :      _pofstream(NULL),
-               _out(out),
-               _pretty(pretty)
-       {
-               header.print(_out, false);
-       }
-
-       XMLWriter(LPCTSTR path, PRETTY_FLAGS pretty=PRETTY_INDENT, const XMLHeader& header=XMLHeader())
-        :      _pofstream(new tofstream(path)),
-               _out(*_pofstream),
-               _pretty(pretty)
-       {
-               header.print(_out, false);
-       }
-
-       ~XMLWriter()
-       {
-               _out << std::endl;
-               delete _pofstream;
-       }
-
-        /// create node and move to it
-       void create(const XS_String& name)
-       {
-               if (!_stack.empty()) {
-                       StackEntry& last = _stack.top();
-
-                       if (last._state < PRE_CLOSED) {
-                               write_attributes(last);
-                               close_pre(last);
-                       }
-
-                       ++last._children;
-               }
-
-               StackEntry entry;
-               entry._node_name = name;
-               _stack.push(entry);
-
-               write_pre(entry);
-       }
-
-        /// go back to previous position
-       bool back()
-       {
-               if (!_stack.empty()) {
-                       write_post(_stack.top());
-
-                       _stack.pop();
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// attribute setting
-       void put(const XS_String& attr_name, const XS_String& value)
-       {
-               if (!_stack.empty())
-                       _stack.top()._attributes[attr_name] = value;
-       }
-
-        /// C++ write access to an attribute
-       XS_String& operator[](const XS_String& attr_name)
-       {
-               if (_stack.empty())
-                       return s_empty_attr;
-
-               return _stack.top()._attributes[attr_name];
-       }
-
-       void set_content(const XS_String& s)
-       {
-               if (!_stack.empty())
-                       _stack.top()._content = s;
-       }
-
-        // public for access in StackEntry
-       enum WRITESTATE {
-               NOTHING, /*PRE,*/ ATTRIBUTES, PRE_CLOSED, /*CONTENT,*/ POST
-       };
-
-protected:
-       tofstream*              _pofstream;
-       std::ostream&   _out;
-       PRETTY_FLAGS    _pretty;
-
-       typedef XMLNode::AttributeMap AttrMap;
-
-       struct StackEntry {
-               XS_String       _node_name;
-               AttrMap         _attributes;
-               std::string     _content;
-               WRITESTATE      _state;
-               bool            _children;
-
-               StackEntry() : _state(NOTHING), _children(false) {}
-       };
-
-       std::stack<StackEntry> _stack;
-
-       static XS_String s_empty_attr;
-
-       void close_pre(StackEntry& entry)
-       {
-               _out << '>';
-
-               entry._state = PRE_CLOSED;
-       }
-
-       void write_pre(StackEntry& entry)
-       {
-               if (_pretty >= PRETTY_LINEFEED)
-                       _out << std::endl;
-
-               if (_pretty == PRETTY_INDENT)
-                       for(int i=_stack.size(); --i>0; )
-                               _out << XML_INDENT_SPACE;
-
-               _out << '<' << EncodeXMLString(entry._node_name);
-               //entry._state = PRE;
-       }
-
-       void write_attributes(StackEntry& entry)
-       {
-               for(AttrMap::const_iterator it=entry._attributes.begin(); it!=entry._attributes.end(); ++it)
-                       _out << ' ' << EncodeXMLString(it->first) << "=\"" << EncodeXMLString(it->second) << "\"";
-
-               entry._state = ATTRIBUTES;
-       }
-
-       void write_post(StackEntry& entry)
-       {
-               if (entry._state < ATTRIBUTES)
-                       write_attributes(entry);
-
-               if (entry._children || !entry._content.empty()) {
-                       if (entry._state < PRE_CLOSED)
-                               close_pre(entry);
-
-                       _out << entry._content;
-                       //entry._state = CONTENT;
-
-                       if (_pretty>=PRETTY_LINEFEED && entry._content.empty())
-                               _out << std::endl;
-
-                       if (_pretty==PRETTY_INDENT && entry._content.empty())
-                               for(int i=_stack.size(); --i>0; )
-                                       _out << XML_INDENT_SPACE;
-
-                       _out << "</" << EncodeXMLString(entry._node_name) << ">";
-               } else {
-                       _out << "/>";
-               }
-
-               entry._state = POST;
-       }
-};
-
-
-}      // namespace XMLStorage
-
-#define _XMLSTORAGE_H
-#endif // _XMLSTORAGE_H
diff --git a/reactos/subsys/system/hostname/hostname.c b/reactos/subsys/system/hostname/hostname.c
deleted file mode 100644 (file)
index 42f0c04..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- *  ReactOS Win32 Applications
- *  Copyright (C) 2005 ReactOS Team
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- */
-/* $Id$
- *
- * COPYRIGHT : See COPYING in the top level directory
- * PROJECT   : ReactOS/Win32 get host name 
- * FILE      : subsys/system/hostname/hostname.c
- * PROGRAMMER: Emanuele Aliberti (ea@reactos.com)
- */
-#include <windows.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-int main (int argc, char ** argv)
-{
-       if (1 == argc)
-       {
-               TCHAR ComputerName [MAX_COMPUTERNAME_LENGTH + 1];
-               DWORD ComputerNameSize = sizeof ComputerName / sizeof ComputerName[0];
-
-               ZeroMemory (ComputerName, sizeof ComputerName );
-               if (GetComputerName(ComputerName, & ComputerNameSize))
-               {
-                       printf ("%s\n", ComputerName);
-                       return EXIT_SUCCESS;
-               }
-               fprintf (stderr, "%s: Win32 error %ld.\n",
-                       argv[0], GetLastError());
-               return EXIT_FAILURE;
-       }else{
-               if (0 == strcmp(argv[1],"-s"))
-               {
-                       fprintf(stderr,"%s: -s not supported.\n",argv[0]);
-                       return EXIT_FAILURE;
-               }else{
-                       printf("Print the current host's name.\n\nhostname\n");
-               }
-       }
-       return EXIT_SUCCESS;
-}
-/* EOF */
diff --git a/reactos/subsys/system/hostname/hostname.rc b/reactos/subsys/system/hostname/hostname.rc
deleted file mode 100644 (file)
index 227ff6a..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-#define REACTOS_STR_FILE_DESCRIPTION   "Win32 Get local host name\0"
-#define REACTOS_STR_INTERNAL_NAME      "hostname\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "hostname.exe\0"
-#include <reactos/version.rc>
diff --git a/reactos/subsys/system/hostname/hostname.xml b/reactos/subsys/system/hostname/hostname.xml
deleted file mode 100644 (file)
index 03c29d5..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<module name="hostname" type="win32cui" installbase="system32" installname="hostname.exe" allowwarnings="true">
-       <define name="__USE_W32API" />
-       <library>kernel32</library>
-       <file>hostname.c</file>
-       <file>hostname.rc</file>
-</module>
-
diff --git a/reactos/subsys/system/ibrowser/De.rc b/reactos/subsys/system/ibrowser/De.rc
deleted file mode 100644 (file)
index f88edbd..0000000
+++ /dev/null
@@ -1,148 +0,0 @@
-//Microsoft Developer Studio generated resource script.\r
-//\r
-#include "ibrowser_intres.h"\r
-\r
-#define APSTUDIO_READONLY_SYMBOLS\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 2 resource.\r
-//\r
-#include <windows.h>\r
-/////////////////////////////////////////////////////////////////////////////\r
-#undef APSTUDIO_READONLY_SYMBOLS\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-// German (Germany) resources\r
-\r
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)\r
-#ifdef _WIN32\r
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN\r
-#pragma code_page(1252)\r
-#endif //_WIN32\r
-\r
-#ifdef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// TEXTINCLUDE\r
-//\r
-\r
-1 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "ibrowser_intres.h\0"\r
-END\r
-\r
-2 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#include <windows.h>\0"\r
-END\r
-\r
-3 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#ifndef _ROS_\r\n"\r
-    "LANGUAGE LANG_GERMAN, SUBLANG_GERMAN\r\n"\r
-    "STRINGTABLE DISCARDABLE \r\n"\r
-    "BEGIN\r\n"\r
-    "#ifdef UNICODE\r\n"\r
-    "IDS_IBROWSER_VERSION_STR ""ROS IBrowser%0s""\r\n"\r
-    "#else\r\n"\r
-    "IDS_IBROWSER_VERSION_STR ""ROS IBrowser Ansi%0s""\r\n"\r
-    "#endif\r\n"\r
-    "END\r\n"\r
-    "#endif\r\n"\r
-    "\0"\r
-END\r
-\r
-#endif    // APSTUDIO_INVOKED\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Menu\r
-//\r
-\r
-IDM_SDIFRAME MENU PRELOAD DISCARDABLE \r
-BEGIN\r
-    POPUP "&Datei"\r
-    BEGIN\r
-        MENUITEM "&Beenden",                    ID_FILE_EXIT\r
-    END\r
-    POPUP "&Ansicht"\r
-    BEGIN\r
-        MENUITEM "&Toolbar",                    ID_VIEW_TOOL_BAR\r
-        MENUITEM "S&ide Bar",                   ID_VIEW_SIDE_BAR, GRAYED\r
-        MENUITEM "&Status Bar",                 ID_VIEW_STATUSBAR\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Aktualisieren\tF5",          ID_REFRESH\r
-        MENUITEM "&Vollbild\tCtrl+Shift+S",     ID_VIEW_FULLSCREEN\r
-    END\r
-    POPUP "&Hilfe"\r
-    BEGIN\r
-        MENUITEM "IBrowser &FAQ...",            ID_IBROWSER_FAQ\r
-        MENUITEM "&About IBrowser...",          ID_ABOUT_IBROWSER\r
-        MENUITEM "About &OS...",                ID_ABOUT_WINDOWS\r
-    END\r
-END\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Dialog\r
-//\r
-\r
-IDD_ABOUT_IBROWSER DIALOG DISCARDABLE  0, 0, 199, 106\r
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "About ReactOS Web Browser"\r
-FONT 10, "MS Sans Serif"\r
-BEGIN\r
-    LTEXT           "ReactOS Web Browser",IDC_ROS_IBROWSER,91,13,104,11\r
-    LTEXT           "V 0.9",IDC_VERSION_TXT,91,27,104,8\r
-    LTEXT           "(c) 2005 Martin Fuchs",IDC_STATIC,91,42,104,8\r
-    LTEXT           "",IDC_WIN_VERSION,91,58,98,22\r
-    LTEXT           "http://www.sky.franken.de/explorer/",IDC_WWW,17,84,129,\r
-                    8\r
-    CONTROL         "&OK",IDOK,"Button",BS_OWNERDRAW | BS_FLAT | WS_GROUP,\r
-                    154,90,38,12\r
-END\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// String Table\r
-//\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_TITLE               "Reactos Internet Web Browser"\r
-    IDS_EMPTY               "(Empty)"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_ABOUT_IBROWSER      "&Über..."\r
-END\r
-\r
-#endif    // German (Germany) resources\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-\r
-\r
-#ifndef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 3 resource.\r
-//\r
-#ifndef _ROS_\r
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-#ifdef UNICODE\r
-IDS_IBROWSER_VERSION_STR "ROS IBrowser%0s"\r
-#else\r
-IDS_IBROWSER_VERSION_STR "ROS IBrowser Ansi%0s"\r
-#endif\r
-END\r
-#endif\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-#endif    // not APSTUDIO_INVOKED\r
-\r
diff --git a/reactos/subsys/system/ibrowser/En.rc b/reactos/subsys/system/ibrowser/En.rc
deleted file mode 100644 (file)
index 92212e2..0000000
+++ /dev/null
@@ -1,161 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "ibrowser_intres.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include <windows.h>
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// German (Germany) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)
-#ifdef _WIN32
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-#pragma code_page(1252)
-#endif //_WIN32
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "ibrowser_intres.h\0"
-END
-
-2 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#include <windows.h>\0"
-END
-
-3 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#ifndef _ROS_\r\n"
-    "LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US\r\n"
-    "STRINGTABLE DISCARDABLE \r\n"
-    "BEGIN\r\n"
-    "#ifdef UNICODE\r\n"
-    "IDS_IBROWSER_VERSION_STR ""ROS IBrowser%0s""\r\n"
-    "#else\r\n"
-    "IDS_IBROWSER_VERSION_STR ""ROS IBrowser Ansi%0s""\r\n"
-    "#endif\r\n"
-    "END\r\n"
-    "#endif\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-#endif    // German (Germany) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-/////////////////////////////////////////////////////////////////////////////
-// English (U.S.) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
-#ifdef _WIN32
-LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
-#pragma code_page(1252)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_SDIFRAME MENU PRELOAD DISCARDABLE 
-BEGIN
-    POPUP "&File"
-    BEGIN
-        MENUITEM "&Open",                       ID_FILE_OPEN
-        MENUITEM "E&xit",                       ID_FILE_EXIT
-    END
-    POPUP "&View"
-    BEGIN
-        MENUITEM "&Toolbar",                    ID_VIEW_TOOL_BAR
-        MENUITEM "S&ide Bar",                   ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "&Status Bar",                 ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Refresh\tF5",                ID_REFRESH
-        MENUITEM "F&ull Screen\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-    END
-    POPUP "&Help"
-    BEGIN
-        MENUITEM "IBrowser &FAQ...",            ID_IBROWSER_FAQ
-        MENUITEM "&About IBrowser...",          ID_ABOUT_IBROWSER
-        MENUITEM "About &OS...",                ID_ABOUT_WINDOWS
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Dialog
-//
-
-IDD_ABOUT_IBROWSER DIALOG DISCARDABLE  0, 0, 199, 106
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "About ReactOS Web Browser"
-FONT 10, "MS Sans Serif"
-BEGIN
-    LTEXT           "ReactOS Web Browser",IDC_ROS_IBROWSER,91,13,104,11
-    LTEXT           "V 0.9",IDC_VERSION_TXT,91,27,104,8
-    LTEXT           "(c) 2005 Martin Fuchs",IDC_STATIC,91,42,104,8
-    LTEXT           "",IDC_WIN_VERSION,91,58,98,22
-    LTEXT           "http://www.sky.franken.de/explorer/",IDC_WWW,17,84,129,
-                    8
-    CONTROL         "&OK",IDOK,"Button",BS_OWNERDRAW | BS_FLAT | WS_GROUP,
-                    154,90,38,12
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "Reactos Internet Web Browser"
-    IDS_EMPTY               "(Empty)"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_ABOUT_IBROWSER      "&About..."
-END
-
-#endif    // English (U.S.) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-#ifndef _ROS_
-LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
-STRINGTABLE DISCARDABLE 
-BEGIN
-#ifdef UNICODE
-IDS_IBROWSER_VERSION_STR "ROS IBrowser%0s"
-#else
-IDS_IBROWSER_VERSION_STR "ROS IBrowser Ansi%0s"
-#endif
-END
-#endif
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/ibrowser/Es.rc b/reactos/subsys/system/ibrowser/Es.rc
deleted file mode 100644 (file)
index 244da05..0000000
+++ /dev/null
@@ -1,122 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "ibrowser_intres.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include <windows.h>
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// German (Germany) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)
-#ifdef _WIN32
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-#pragma code_page(1252)
-#endif //_WIN32
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "ibrowser_intres.h\0"
-END
-
-2 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#include <windows.h>\0"
-END
-
-3 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#ifndef _ROS_\r\n"
-    "LANGUAGE LANG_SPANISH, SUBLANG_SPANISH\r\n"
-    "STRINGTABLE DISCARDABLE \r\n"
-    "BEGIN\r\n"
-    "#ifdef UNICODE\r\n"
-    "IDS_IBROWSER_VERSION_STR ""Nevegador de Web ReactOS%0s""\r\n"
-    "#else\r\n"
-    "IDS_IBROWSER_VERSION_STR ""Nevegador de Web ReactOS Ansi%0s""\r\n"
-    "#endif\r\n"
-    "END\r\n"
-    "#endif\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-#endif    // German (Germany) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-/////////////////////////////////////////////////////////////////////////////
-// Spanish (Castilian) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ESP)
-#ifdef _WIN32
-LANGUAGE LANG_SPANISH, SUBLANG_SPANISH
-#pragma code_page(1252)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_SDIFRAME MENU PRELOAD DISCARDABLE 
-BEGIN
-    POPUP "&Archivo"
-    BEGIN
-        MENUITEM "S&alir",                      ID_FILE_EXIT
-    END
-    POPUP "&Ver"
-    BEGIN
-        MENUITEM "&Barra de Herramientas",      ID_VIEW_TOOL_BAR
-        MENUITEM "Barra &Lateral",              ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "Barra de &Estado",            ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "&Actualizar\tF5",             ID_REFRESH
-        MENUITEM "P&antalla Completa\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-    END
-    POPUP "&Ayuda"
-    BEGIN
-        MENUITEM "IBrowser &FAQ...",            ID_IBROWSER_FAQ
-        MENUITEM "&Acerca de IBrowser...",      ID_ABOUT_IBROWSER
-        MENUITEM "Acerca de &OS...",            ID_ABOUT_WINDOWS
-    END
-END
-
-#endif    // Spanish (Castilian) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-#ifndef _ROS_
-LANGUAGE LANG_SPANISH, SUBLANG_SPANISH
-STRINGTABLE DISCARDABLE 
-BEGIN
-#ifdef UNICODE
-IDS_IBROWSER_VERSION_STR "Nevegador de Web ReactOS%0s"
-#else
-IDS_IBROWSER_VERSION_STR "Nevegador de Web ReactOS Ansi%0s"
-#endif
-END
-#endif
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/ibrowser/Fr.rc b/reactos/subsys/system/ibrowser/Fr.rc
deleted file mode 100644 (file)
index d720513..0000000
+++ /dev/null
@@ -1,151 +0,0 @@
-//Microsoft Developer Studio generated resource script.\r
-//\r
-#include "ibrowser_intres.h"\r
-\r
-#define APSTUDIO_READONLY_SYMBOLS\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 2 resource.\r
-//\r
-#include <windows.h>\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-#undef APSTUDIO_READONLY_SYMBOLS\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-// German (Germany) resources\r
-\r
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)\r
-#ifdef _WIN32\r
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN\r
-#pragma code_page(1252)\r
-#endif //_WIN32\r
-\r
-#ifdef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// TEXTINCLUDE\r
-//\r
-\r
-1 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "ibrowser_intres.h\0"\r
-END\r
-\r
-2 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#include <windows.h>\r\n"\r
-    "\0"\r
-END\r
-\r
-#endif    // APSTUDIO_INVOKED\r
-\r
-#endif    // German (Germany) resources\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-// French (France) resources\r
-\r
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_FRA)\r
-#ifdef _WIN32\r
-LANGUAGE LANG_FRENCH, SUBLANG_FRENCH\r
-#pragma code_page(1252)\r
-#endif //_WIN32\r
-\r
-#ifdef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// TEXTINCLUDE\r
-//\r
-\r
-3 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#ifndef _ROS_\r\n"\r
-    "LANGUAGE LANG_FRENCH, SUBLANG_FRENCH\r\n"\r
-    "STRINGTABLE DISCARDABLE \r\n"\r
-    "BEGIN\r\n"\r
-    "#ifdef UNICODE\r\n"\r
-    "IDS_IBROWSER_VERSION_STR ""Navigateur Internet de ReactOS%0s""\r\n"\r
-    "#else\r\n"\r
-    "IDS_IBROWSER_VERSION_STR ""Navigateur Internet de ReactOS Ansi%0s""\r\n"\r
-    "#endif\r\n"\r
-    "END\r\n"\r
-    "#endif\r\n"\r
-    "\0"\r
-END\r
-\r
-#endif    // APSTUDIO_INVOKED\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Menu\r
-//\r
-\r
-IDM_SDIFRAME MENU PRELOAD DISCARDABLE \r
-BEGIN\r
-    POPUP "&Fichier"\r
-    BEGIN\r
-        MENUITEM "&Ouvrir",                     ID_FILE_OPEN\r
-        MENUITEM "&Quitter",                    ID_FILE_EXIT\r
-    END\r
-    POPUP "&Affichage"\r
-    BEGIN\r
-        MENUITEM "Barre d'ou&tils",             ID_VIEW_TOOL_BAR\r
-        MENUITEM "Pann&eau lat?al",             ID_VIEW_SIDE_BAR, GRAYED\r
-        MENUITEM "&Barre d'?at",                ID_VIEW_STATUSBAR\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Actualise&r",                 ID_REFRESH\r
-        MENUITEM "&Plein ?ran",                 ID_VIEW_FULLSCREEN\r
-    END\r
-    POPUP "&Aide"\r
-    BEGIN\r
-        MENUITEM "&Rubriques d'aide de iBrowser", ID_IBROWSER_FAQ\r
-        MENUITEM "? propos de iBrowser...",     ID_ABOUT_IBROWSER\r
-        MENUITEM "? propos de ReactOS...",      ID_ABOUT_WINDOWS\r
-    END\r
-END\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// String Table\r
-//\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_TITLE               "Navigateur internet de Reactos"\r
-    IDS_EMPTY               "(Vide)"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_ABOUT_IBROWSER      "? propos de iBrowser..."\r
-END\r
-\r
-#endif    // French (France) resources\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-\r
-\r
-#ifndef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 3 resource.\r
-//\r
-#ifndef _ROS_\r
-LANGUAGE LANG_FRENCH, SUBLANG_FRENCH\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-#ifdef UNICODE\r
-IDS_IBROWSER_VERSION_STR "Navigateur Internet de ReactOS%0s"\r
-#else\r
-IDS_IBROWSER_VERSION_STR "Navigateur Internet de ReactOS Ansi%0s"\r
-#endif\r
-END\r
-#endif\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-#endif    // not APSTUDIO_INVOKED\r
-\r
diff --git a/reactos/subsys/system/ibrowser/Hu.rc b/reactos/subsys/system/ibrowser/Hu.rc
deleted file mode 100644 (file)
index ee9b38e..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-//Microsoft Developer Studio generated resource script.\r
-//\r
-#include "ibrowser_intres.h"\r
-\r
-#define APSTUDIO_READONLY_SYMBOLS\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 2 resource.\r
-//\r
-#include <windows.h>\r
-/////////////////////////////////////////////////////////////////////////////\r
-#undef APSTUDIO_READONLY_SYMBOLS\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-// German (Germany) resources\r
-\r
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)\r
-#ifdef _WIN32\r
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN\r
-#pragma code_page(1252)\r
-#endif //_WIN32\r
-\r
-#ifdef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// TEXTINCLUDE\r
-//\r
-\r
-1 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "ibrowser_intres.h\0"\r
-END\r
-\r
-2 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#include <windows.h>\0"\r
-END\r
-\r
-3 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#ifndef _ROS_\r\n"\r
-    "LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT\r\n"\r
-    "STRINGTABLE DISCARDABLE \r\n"\r
-    "BEGIN\r\n"\r
-    "#ifdef UNICODE\r\n"\r
-    "IDS_IBROWSER_VERSION_STR ""A ReactOS %s webböngészõ%0s""\r\n"\r
-    "#else\r\n"\r
-    "IDS_IBROWSER_VERSION_STR ""A ReactOS %s webböngészõ Ansi%0s""\r\n"\r
-    "#endif\r\n"\r
-    "END\r\n"\r
-    "#endif\r\n"\r
-    "\0"\r
-END\r
-\r
-#endif    // APSTUDIO_INVOKED\r
-\r
-#endif    // German (Germany) resources\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-\r
-\r
-#ifndef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 3 resource.\r
-//\r
-#ifndef _ROS_\r
-LANGUAGE LANG_HUNGARIAN, SUBLANG_DEFAULT\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-#ifdef UNICODE\r
-IDS_IBROWSER_VERSION_STR "A ReactOS %s webböngészõ%0s"\r
-#else\r
-IDS_IBROWSER_VERSION_STR "A ReactOS %s webböngészõ Ansi%0s"\r
-#endif\r
-END\r
-#endif\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-#endif    // not APSTUDIO_INVOKED\r
-\r
diff --git a/reactos/subsys/system/ibrowser/Ja.rc b/reactos/subsys/system/ibrowser/Ja.rc
deleted file mode 100644 (file)
index f541cc2..0000000
+++ /dev/null
@@ -1,140 +0,0 @@
-//Microsoft Developer Studio generated resource script.
-//
-#include "ibrowser_intres.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include <windows.h>
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// Japanese resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_JPN)
-#ifdef _WIN32
-LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT
-#pragma code_page(932)
-#endif //_WIN32
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Menu
-//
-
-IDM_SDIFRAME MENU PRELOAD DISCARDABLE 
-BEGIN
-    POPUP "\83t\83@\83C\83\8b(&F)"
-    BEGIN
-        MENUITEM "\8aJ\82­(&O)",                    ID_FILE_OPEN
-        MENUITEM "\8fI\97¹(&X)",                    ID_FILE_EXIT
-    END
-    POPUP "\95\\\8e¦(&V)"
-    BEGIN
-        MENUITEM "\83c\81[\83\8b \83o\81[(&T)",             ID_VIEW_TOOL_BAR
-        MENUITEM "\83T\83C\83\83o\81[(&I)",             ID_VIEW_SIDE_BAR, GRAYED
-        MENUITEM "\83X\83e\81[\83^\83\83o\81[(&S)",         ID_VIEW_STATUSBAR
-        MENUITEM SEPARATOR
-        MENUITEM "\8dÅ\90V\82Ì\8fî\95ñ\82É\8dX\90V(&R)\tF5",    ID_REFRESH
-        MENUITEM "\91S\89æ\96Ê\95\\\8e¦(&I)\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-    END
-    POPUP "\83w\83\8b\83v(&H)"
-    BEGIN
-        MENUITEM "IBrowser FAQ (&F)...",        ID_IBROWSER_FAQ
-        MENUITEM "IBrowser \82É\82Â\82¢\82Ä(&A)...",    ID_ABOUT_IBROWSER
-        MENUITEM "OS \82É\82Â\82¢\82Ä(&O)...",          ID_ABOUT_WINDOWS
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_TITLE               "Reactos Internet Web Browser"
-    IDS_EMPTY               "(Empty)"
-END
-
-STRINGTABLE DISCARDABLE 
-BEGIN
-    IDS_ABOUT_IBROWSER      "\83o\81[\83W\83\87\83\93\8fî\95ñ(&A)..."
-END
-
-#endif    // Japanese resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-/////////////////////////////////////////////////////////////////////////////
-// German (Germany) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)
-#ifdef _WIN32
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-#pragma code_page(1252)
-#endif //_WIN32
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "ibrowser_intres.h\0"
-END
-
-2 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#include <windows.h>\0"
-END
-
-3 TEXTINCLUDE DISCARDABLE 
-BEGIN
-    "#ifndef _ROS_\r\n"
-    "LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT\r\n"
-    "STRINGTABLE DISCARDABLE \r\n"
-    "BEGIN\r\n"
-    "#ifdef UNICODE\r\n"
-    "IDS_IBROWSER_VERSION_STR ""ROS IBrowser%0s""\r\n"
-    "#else\r\n"
-    "IDS_IBROWSER_VERSION_STR ""ROS IBrowser Ansi%0s""\r\n"
-    "#endif\r\n"
-    "END\r\n"
-    "#endif\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-#endif    // German (Germany) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-#ifndef _ROS_
-LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT
-STRINGTABLE DISCARDABLE 
-BEGIN
-#ifdef UNICODE
-IDS_IBROWSER_VERSION_STR "ROS IBrowser%0s"
-#else
-IDS_IBROWSER_VERSION_STR "ROS IBrowser Ansi%0s"
-#endif
-END
-#endif
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/reactos/subsys/system/ibrowser/Makefile.MinGW b/reactos/subsys/system/ibrowser/Makefile.MinGW
deleted file mode 100644 (file)
index cd1d90f..0000000
+++ /dev/null
@@ -1,67 +0,0 @@
-#\r
-#  ROS Internet Web Browser\r
-#\r
-#  Makefile.MinGW\r
-#\r
-\r
-CC = gcc\r
-CXX = g++\r
-LINK = g++\r
-\r
-CFLAGS = -DWIN32 -D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 -fexceptions -Wall -Wno-unused-value -I. -I$(EXPAT_INC)\r
-RCFLAGS        = -DWIN32 -D__WINDRES__\r
-LFLAGS = -Wl,--subsystem,windows\r
-\r
-ifdef DEBUG\r
-CFLAGS += -D_DEBUG -g\r
-RCFLAGS        += -D_DEBUG\r
-LFLAGS += -g\r
-else\r
-CFLAGS += -DNDEBUG -Os\r
-RCFLAGS        += -DNDEBUG\r
-LFLAGS += -s\r
-endif\r
-\r
-ifndef UNICODE\r
-UNICODE = 1\r
-endif\r
-\r
-ifeq ($(UNICODE),1)\r
-CFLAGS += -DUNICODE\r
-# LFLAGS+= -Wl,--entry,_wWinMain@16\r
-RCFLAGS += -DUNICODE\r
-endif\r
-\r
-CXXFLAGS = $(CFLAGS)\r
-\r
-EXEC_SUFFIX = .exe\r
-RES_SUFFIX = .coff\r
-\r
-VPATH = utility\r
-\r
-PROGRAM = ibrowser\r
-\r
-TARGET = $(PROGRAM)$(EXEC_SUFFIX)\r
-\r
-OBJECTS = \\r
-       utility.o \\r
-       window.o \\r
-       ibrowser.o \\r
-       webchild.o \\r
-       mainframe.o \\r
-       favorites.o \\r
-       xmlstorage.o\r
-\r
-LIBS = gdi32 comctl32 shell32 ole32 uuid oleaut32\r
-\r
-all: $(TARGET)\r
-\r
-$(TARGET): $(OBJECTS) $(PROGRAM)$(RES_SUFFIX) libexpat.dll\r
-       $(LINK) $(LFLAGS) -o $@ $^ $(addprefix -l,$(LIBS)) $(addprefix -l,$(DELAYIMPORTS))\r
-\r
-ibrowser$(RES_SUFFIX): $(PROGRAM)_intres.rc res/*.bmp res/*.ico\r
-       windres $(RCFLAGS) -o $@ $(PROGRAM)_intres.rc\r
-\r
-clean:\r
-       rm -f $(TARGET) $(OBJECTS) $(PROGRAM)$(RES_SUFFIX) \\r
-       desktop/*.o dialogs/*.o shell/*.o taskbar/*.o utility/*.o\r
diff --git a/reactos/subsys/system/ibrowser/Makefile.PCH b/reactos/subsys/system/ibrowser/Makefile.PCH
deleted file mode 100644 (file)
index 769da64..0000000
+++ /dev/null
@@ -1,72 +0,0 @@
-#\r
-#  ROS Internet Web Browser\r
-#\r
-#  Makefile.PCH\r
-#\r
-#  MinGW Makefile with precompiled header support\r
-#\r
-\r
-CC = gcc\r
-CXX = g++\r
-LINK = g++\r
-\r
-CFLAGS = -DWIN32 -D_WIN32_IE=0x0600 -D_WIN32_WINNT=0x0501 -DWINVER=0x0500 -fexceptions -Wall -Wno-unused-value -I. -I$(EXPAT_INC)\r
-RCFLAGS        = -DWIN32 -D__WINDRES__\r
-LFLAGS = -Wl,--subsystem,windows\r
-\r
-ifdef DEBUG\r
-CFLAGS += -D_DEBUG -g\r
-RCFLAGS        += -D_DEBUG\r
-LFLAGS += -g\r
-else\r
-CFLAGS += -DNDEBUG -Os -march=pentium4\r
-RCFLAGS        += -DNDEBUG\r
-LFLAGS += -s\r
-endif\r
-\r
-ifndef UNICODE\r
-UNICODE = 1\r
-endif\r
-\r
-ifeq ($(UNICODE),1)\r
-CFLAGS += -DUNICODE\r
-# LFLAGS+= -Wl,--entry,_wWinMain@16\r
-RCFLAGS += -DUNICODE\r
-endif\r
-\r
-CXXFLAGS = $(CFLAGS)\r
-\r
-EXEC_SUFFIX = .exe\r
-RES_SUFFIX = .coff\r
-\r
-VPATH = utility\r
-\r
-PROGRAM = ibrowser\r
-\r
-TARGET = $(PROGRAM)$(EXEC_SUFFIX)\r
-\r
-OBJECTS = \\r
-       utility.o \\r
-       window.o \\r
-       ibrowser.o \\r
-       webchild.o \\r
-       mainframe.o \\r
-       favorites.o \\r
-       xmlstorage.o\r
-\r
-LIBS = gdi32 comctl32 shell32 ole32 oleaut32 uuid\r
-\r
-all: precomp.h.gch $(TARGET)\r
-\r
-precomp.h.gch: *.h utility/*.h\r
-       $(CXX) $(CFLAGS) precomp.h\r
-\r
-$(TARGET): $(OBJECTS) $(PROGRAM)$(RES_SUFFIX) libexpat.dll\r
-       $(LINK) $(LFLAGS) -o $@ $^ $(addprefix -l,$(LIBS)) $(addprefix -l,$(DELAYIMPORTS))\r
-\r
-ibrowser$(RES_SUFFIX): $(PROGRAM)_intres.rc res/*.bmp res/*.ico\r
-       windres $(RCFLAGS) -o $@ $(PROGRAM)_intres.rc\r
-\r
-clean:\r
-       rm -f $(TARGET) $(OBJECTS) $(PROGRAM)$(RES_SUFFIX) precomp.h.gch \\r
-       utility/*.o\r
diff --git a/reactos/subsys/system/ibrowser/Ro.rc b/reactos/subsys/system/ibrowser/Ro.rc
deleted file mode 100644 (file)
index 884a319..0000000
+++ /dev/null
@@ -1,122 +0,0 @@
-//Microsoft Developer Studio generated resource script.\r
-//\r
-#include "ibrowser_intres.h"\r
-\r
-#define APSTUDIO_READONLY_SYMBOLS\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 2 resource.\r
-//\r
-#include <windows.h>\r
-/////////////////////////////////////////////////////////////////////////////\r
-#undef APSTUDIO_READONLY_SYMBOLS\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-// Neutral (Default) resources\r
-\r
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_NEUD)\r
-#ifdef _WIN32\r
-LANGUAGE LANG_NEUTRAL, SUBLANG_DEFAULT\r
-#pragma code_page(1252)\r
-#endif //_WIN32\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Menu\r
-//\r
-\r
-IDM_SDIFRAME MENU PRELOAD DISCARDABLE \r
-BEGIN\r
-    POPUP "&Fisier"\r
-    BEGIN\r
-        MENUITEM "&Iesire",                     ID_FILE_EXIT\r
-    END\r
-    POPUP "&Prezentare"\r
-    BEGIN\r
-        MENUITEM "&Bara cu instrumente",        ID_VIEW_TOOL_BAR\r
-        MENUITEM "&Side Bar",                   ID_VIEW_SIDE_BAR, GRAYED\r
-        MENUITEM "&Bara de stare",              ID_VIEW_STATUSBAR\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Resetare\tF5",               ID_REFRESH\r
-        MENUITEM "F&ull Screen\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN\r
-    END\r
-    POPUP "&Ajutor"\r
-    BEGIN\r
-        MENUITEM "IBrowser &FAQ...",            ID_IBROWSER_FAQ\r
-        MENUITEM "&Despre IBrowser...",         ID_ABOUT_IBROWSER\r
-        MENUITEM "Despre &OS...",               ID_ABOUT_WINDOWS\r
-    END\r
-END\r
-\r
-#endif    // Neutral (Default) resources\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-// German (Germany) resources\r
-\r
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)\r
-#ifdef _WIN32\r
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN\r
-#pragma code_page(1252)\r
-#endif //_WIN32\r
-\r
-#ifdef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// TEXTINCLUDE\r
-//\r
-\r
-1 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "ibrowser_intres.h\0"\r
-END\r
-\r
-2 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#include <windows.h>\0"\r
-END\r
-\r
-3 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#ifndef _ROS_\r\n"\r
-    "LANGUAGE LANG_ROMANIAN, SUBLANG_DEFAULT\r\n"\r
-    "STRINGTABLE DISCARDABLE \r\n"\r
-    "BEGIN\r\n"\r
-    "#ifdef UNICODE\r\n"\r
-    "IDS_IBROWSER_VERSION_STR ""ROS IBrowser%0s""\r\n"\r
-    "#else\r\n"\r
-    "IDS_IBROWSER_VERSION_STR ""ROS IBrowser Ansi%0s""\r\n"\r
-    "#endif\r\n"\r
-    "END\r\n"\r
-    "#endif\r\n"\r
-    "\0"\r
-END\r
-\r
-#endif    // APSTUDIO_INVOKED\r
-\r
-#endif    // German (Germany) resources\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-\r
-\r
-#ifndef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 3 resource.\r
-//\r
-#ifndef _ROS_\r
-LANGUAGE LANG_ROMANIAN, SUBLANG_DEFAULT\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-#ifdef UNICODE\r
-IDS_IBROWSER_VERSION_STR "ROS IBrowser%0s"\r
-#else\r
-IDS_IBROWSER_VERSION_STR "ROS IBrowser Ansi%0s"\r
-#endif\r
-END\r
-#endif\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-#endif    // not APSTUDIO_INVOKED\r
-\r
diff --git a/reactos/subsys/system/ibrowser/Sv.rc b/reactos/subsys/system/ibrowser/Sv.rc
deleted file mode 100644 (file)
index d52763d..0000000
+++ /dev/null
@@ -1,140 +0,0 @@
-//Microsoft Developer Studio generated resource script.\r
-//\r
-#include "ibrowser_intres.h"\r
-\r
-#define APSTUDIO_READONLY_SYMBOLS\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 2 resource.\r
-//\r
-#include <windows.h>\r
-/////////////////////////////////////////////////////////////////////////////\r
-#undef APSTUDIO_READONLY_SYMBOLS\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-// German (Germany) resources\r
-\r
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU)\r
-#ifdef _WIN32\r
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN\r
-#pragma code_page(1252)\r
-#endif //_WIN32\r
-\r
-#ifdef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// TEXTINCLUDE\r
-//\r
-\r
-1 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "ibrowser_intres.h\0"\r
-END\r
-\r
-2 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#include <windows.h>\0"\r
-END\r
-\r
-3 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#ifndef _ROS_\r\n"\r
-    "LANGUAGE LANG_SWEDISH, SUBLANG_DEFAULT\r\n"\r
-    "STRINGTABLE DISCARDABLE \r\n"\r
-    "BEGIN\r\n"\r
-    "#ifdef UNICODE\r\n"\r
-    "IDS_IBROWSER_VERSION_STR ""ROS IBrowser%0s""\r\n"\r
-    "#else\r\n"\r
-    "IDS_IBROWSER_VERSION_STR ""ROS IBrowser Ansi%0s""\r\n"\r
-    "#endif\r\n"\r
-    "END\r\n"\r
-    "#endif\r\n"\r
-    "\0"\r
-END\r
-\r
-#endif    // APSTUDIO_INVOKED\r
-\r
-#endif    // German (Germany) resources\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-// Swedish resources\r
-\r
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_SVE)\r
-#ifdef _WIN32\r
-LANGUAGE LANG_SWEDISH, SUBLANG_DEFAULT\r
-#pragma code_page(1252)\r
-#endif //_WIN32\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Menu\r
-//\r
-\r
-IDM_SDIFRAME MENU PRELOAD DISCARDABLE \r
-BEGIN\r
-    POPUP "&Arkiv"\r
-    BEGIN\r
-        MENUITEM "&Öppna",                      ID_FILE_OPEN\r
-        MENUITEM "&Avsluta",                    ID_FILE_EXIT\r
-    END\r
-    POPUP "&Visa"\r
-    BEGIN\r
-        MENUITEM "&Verktygsfält",               ID_VIEW_TOOL_BAR\r
-        MENUITEM "S&idfält",                    ID_VIEW_SIDE_BAR, GRAYED\r
-        MENUITEM "&Statusfält",                 ID_VIEW_STATUSBAR\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Uppdatera\tF5",              ID_REFRESH\r
-        MENUITEM "&Fullskärm\tCtrl+Shift+S",    ID_VIEW_FULLSCREEN\r
-    END\r
-    POPUP "&Hjälp"\r
-    BEGIN\r
-        MENUITEM "IBrowser &FAQ...",            ID_IBROWSER_FAQ\r
-        MENUITEM "Om &IBrowser...",             ID_ABOUT_IBROWSER\r
-        MENUITEM "Om &operativsystemet...",     ID_ABOUT_WINDOWS\r
-    END\r
-END\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// String Table\r
-//\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_TITLE               "ReactOS webbläsare"\r
-    IDS_EMPTY               "(Tom)"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-    IDS_ABOUT_IBROWSER      "&Om..."\r
-END\r
-\r
-#endif    // Swedish resources\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-\r
-\r
-#ifndef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 3 resource.\r
-//\r
-#ifndef _ROS_\r
-LANGUAGE LANG_SWEDISH, SUBLANG_DEFAULT\r
-STRINGTABLE DISCARDABLE \r
-BEGIN\r
-#ifdef UNICODE\r
-IDS_IBROWSER_VERSION_STR "ROS IBrowser%0s"\r
-#else\r
-IDS_IBROWSER_VERSION_STR "ROS IBrowser Ansi%0s"\r
-#endif\r
-END\r
-#endif\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-#endif    // not APSTUDIO_INVOKED\r
-\r
diff --git a/reactos/subsys/system/ibrowser/expat.license b/reactos/subsys/system/ibrowser/expat.license
deleted file mode 100644 (file)
index 5c5d524..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-Copyright (c) 1998, 1999, 2000 Thai Open Source Software Center Ltd
-                               and Clark Cooper
-Copyright (c) 2001, 2002, 2003 Expat maintainers.
-
-Permission is hereby granted, free of charge, to any person obtaining
-a copy of this software and associated documentation files (the
-"Software"), to deal in the Software without restriction, including
-without limitation the rights to use, copy, modify, merge, publish,
-distribute, sublicense, and/or sell copies of the Software, and to
-permit persons to whom the Software is furnished to do so, subject to
-the following conditions:
-
-The above copyright notice and this permission notice shall be included
-in all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/reactos/subsys/system/ibrowser/favorites.cpp b/reactos/subsys/system/ibrowser/favorites.cpp
deleted file mode 100644 (file)
index 47f7948..0000000
+++ /dev/null
@@ -1,496 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer and Desktop clone
- //
- // favorites.cpp
- //
- // Martin Fuchs, 04.04.2004
- //
-
-
-#include <precomp.h>
-
-
-String DecodeURLString(const char* s)
-{
-       TCHAR buffer[BUFFER_LEN];
-       LPTSTR o = buffer;
-
-       for(const char* p=s; *p; ++p)
-               if (*p == '%') {
-                       if (!strncmp(p+1, "20", 2)) {
-                               *o++ = ' ';
-                               p += 2;
-                       } else
-                               *o++ = *p;
-               } else
-                       *o++ = *p;
-
-       return String(buffer, o-buffer);
-}
-
-
- /// read .URL file
-bool Bookmark::read_url(LPCTSTR path)
-{
-       char line[BUFFER_LEN];
-
-       tifstream in(path);
-
-       while(in.good()) {
-               in.getline(line, BUFFER_LEN);
-
-               const char* p = line;
-               while(isspace(*p))
-                       ++p;
-
-               const char* keyword = p;
-               const char* eq = strchr(p, '=');
-
-               if (eq) {
-                       const char* cont = eq + 1;
-                       while(isspace(*cont))
-                               ++cont;
-
-                       if (!strnicmp(keyword, "URL", 3))
-                               _url = DecodeURLString(cont);
-                       else if (!strnicmp(keyword, "IconFile", 8))
-                               _icon_path = DecodeURLString(cont);
-               }
-       }
-
-       return true;
-}
-
- /// convert XBEL bookmark node
-bool Bookmark::read(const_XMLPos& pos)
-{
-       _url = pos.get("href").c_str();
-
-       if (pos.go_down("title")) {
-               _name = pos->get_content();
-               pos.back();
-       }
-
-       if (pos.go_down("desc")) {
-               _description = pos->get_content();
-               pos.back();
-       }
-
-       if (pos.go_down("info")) {
-               const_XMLChildrenFilter metadata(pos, "metadata");
-
-               for(const_XMLChildrenFilter::const_iterator it=metadata.begin(); it!=metadata.end(); ++it) {
-                       const XMLNode& node = **it;
-                       const_XMLPos sub_pos(&node);
-
-                       if (node.get("owner") == "ros-explorer") {
-                               if (sub_pos.go_down("icon")) {
-                                       _icon_path = sub_pos.get("path").c_str();
-                                       _icon_idx = XS_toi(sub_pos.get("index"));
-
-                                       sub_pos.back(); // </icon>
-                               }
-                       }
-               }
-
-               pos.back();     // </metadata>
-               pos.back();     // </info>
-       }
-
-       return !_url.empty();   // _url is mandatory.
-}
-
- /// write XBEL bookmark node
-void Bookmark::write(XMLPos& pos) const
-{
-       pos.create("bookmark");
-
-       pos["href"] = _url.c_str();
-
-       if (!_name.empty()) {
-               pos.create("title");
-               pos->set_content(_name);
-               pos.back();
-       }
-
-       if (!_description.empty()) {
-               pos.create("desc");
-               pos->set_content(_description);
-               pos.back();
-       }
-
-       if (!_icon_path.empty()) {
-               pos.create("info");
-               pos.create("metadata");
-               pos["owner"] = "ros-explorer";
-               pos.create("icon");
-               pos["path"] = _icon_path.c_str();
-               pos["index"].printf(XS_TEXT("%d"), _icon_idx);
-               pos.back();     // </icon>
-               pos.back();     // </metadata>
-               pos.back();     // </info>
-       }
-
-       pos.back();
-}
-
-
- /// read bookmark folder from XBEL formated XML tree
-void BookmarkFolder::read(const_XMLPos& pos)
-{
-       if (pos.go_down("title")) {
-               _name = pos->get_content();
-               pos.back();
-       }
-
-       if (pos.go_down("desc")) {
-               _description = pos->get_content();
-               pos.back();
-       }
-
-       _bookmarks.read(pos);
-}
-
- /// write bookmark folder content from XBEL formated XML tree
-void BookmarkFolder::write(XMLPos& pos) const
-{
-       pos.create("folder");
-
-       if (!_name.empty()) {
-               pos.create("title");
-               pos->set_content(_name);
-               pos.back();
-       }
-
-       if (!_description.empty()) {
-               pos.create("desc");
-               pos->set_content(_description);
-               pos.back();
-       }
-
-       _bookmarks.write(pos);
-}
-
-
-BookmarkNode::BookmarkNode()
- :     _type(BMNT_NONE)
-{
-       _pbookmark = NULL;
-}
-
-BookmarkNode::BookmarkNode(const Bookmark& bm)
- :     _type(BMNT_BOOKMARK)
-{
-       _pbookmark = new Bookmark(bm);
-}
-
-BookmarkNode::BookmarkNode(const BookmarkFolder& bmf)
- :     _type(BMNT_FOLDER)
-{
-       _pfolder = new BookmarkFolder(bmf);
-}
-
-BookmarkNode::BookmarkNode(const BookmarkNode& other)
- :     _type(other._type)
-{
-       if (other._type == BMNT_BOOKMARK)
-               _pbookmark = new Bookmark(*other._pbookmark);
-       else if (other._type == BMNT_FOLDER)
-               _pfolder = new BookmarkFolder(*other._pfolder);
-       else
-               _pbookmark = NULL;
-}
-
-BookmarkNode::~BookmarkNode()
-{
-       if (_type == BMNT_BOOKMARK)
-               delete _pbookmark;
-       else if (_type == BMNT_FOLDER)
-               delete _pfolder;
-}
-
-BookmarkNode& BookmarkNode::operator=(const Bookmark& bm)
-{
-       clear();
-
-       _pbookmark = new Bookmark(bm);
-
-       return *this;
-}
-
-BookmarkNode& BookmarkNode::operator=(const BookmarkFolder& bmf)
-{
-       clear();
-
-       _pfolder = new BookmarkFolder(bmf);
-
-       return *this;
-}
-
-BookmarkNode& BookmarkNode::operator=(const BookmarkNode& other)
-{
-       clear();
-
-       _type = other._type;
-
-       if (other._type == BMNT_BOOKMARK)
-               _pbookmark = new Bookmark(*other._pbookmark);
-       else if (other._type == BMNT_FOLDER)
-               _pfolder = new BookmarkFolder(*other._pfolder);
-
-       return *this;
-}
-
-void BookmarkNode::clear()
-{
-       if (_type == BMNT_BOOKMARK) {
-               delete _pbookmark;
-               _pbookmark = NULL;
-       }
-       else if (_type == BMNT_FOLDER) {
-               delete _pfolder;
-               _pfolder = NULL;
-       }
-
-       _type = BMNT_NONE;
-}
-
-
- /// read bookmark list from XBEL formated XML tree
-void BookmarkList::read(const_XMLPos& pos)
-{
-       const XMLNode::Children& children = pos->get_children();
-
-       for(XMLNode::Children::const_iterator it=children.begin(); it!=children.end(); ++it) {
-               const XMLNode& node = **it;
-               const_XMLPos sub_pos(&node);
-
-               if (node == "folder") {
-                       BookmarkFolder folder;
-
-                       folder.read(sub_pos);
-
-                       push_back(folder);
-               } else if (node == "bookmark") {
-                       Bookmark bookmark;
-
-                       if (bookmark.read(sub_pos))
-                               push_back(bookmark);
-               }
-       }
-}
-
- /// write bookmark list into XBEL formated XML tree
-void BookmarkList::write(XMLPos& pos) const
-{
-       for(const_iterator it=begin(); it!=end(); ++it) {
-               const BookmarkNode& node = *it;
-
-               if (node._type == BookmarkNode::BMNT_FOLDER) {
-                       const BookmarkFolder& folder = *node._pfolder;
-
-                       folder.write(pos);
-
-                       pos.back();
-               } else if (node._type == BookmarkNode::BMNT_BOOKMARK) {
-                       const Bookmark& bookmark = *node._pbookmark;
-
-                       if (!bookmark._url.empty())
-                               bookmark.write(pos);
-               }
-       }
-}
-
-
- /// fill treeview control with bookmark tree content
-void BookmarkList::fill_tree(HWND hwnd, HTREEITEM parent, HIMAGELIST himagelist, HDC hdc_wnd) const
-{
-       TV_INSERTSTRUCT tvi;
-
-       tvi.hParent = parent;
-       tvi.hInsertAfter = TVI_LAST;
-
-       TV_ITEM& tv = tvi.item;
-       tv.mask = TVIF_TEXT|TVIF_IMAGE|TVIF_SELECTEDIMAGE|TVIF_PARAM;
-
-       for(const_iterator it=begin(); it!=end(); ++it) {
-               const BookmarkNode& node = *it;
-
-               tv.lParam = (LPARAM)&node;
-
-               if (node._type == BookmarkNode::BMNT_FOLDER) {
-                       const BookmarkFolder& folder = *node._pfolder;
-
-                       tv.pszText = (LPTSTR)folder._name.c_str();
-                       tv.iImage = 3;                  // folder
-                       tv.iSelectedImage = 4;  // open folder
-                       HTREEITEM hitem = TreeView_InsertItem(hwnd, &tvi);
-
-                       folder._bookmarks.fill_tree(hwnd, hitem, himagelist, hdc_wnd);
-               } else if (node._type == BookmarkNode::BMNT_BOOKMARK) {
-                       const Bookmark& bookmark = *node._pbookmark;
-
-                       tv.pszText = (LPTSTR)bookmark._name.c_str();
-                       tv.iImage = 1;                  // bookmark
-                       tv.iSelectedImage = 2;  // selected bookmark
-
-                       if (!bookmark._icon_path.empty()) {
-                               const Icon& icon = g_icon_cache.extract(bookmark._icon_path, bookmark._icon_idx);
-
-                               if ((ICON_ID)icon != ICID_NONE)
-                                       tv.iImage = tv.iSelectedImage = icon.add_to_imagelist(himagelist, hdc_wnd);
-                       }
-
-                       (void)TreeView_InsertItem(hwnd, &tvi);
-               }
-       }
-}
-
-
-/*@@
-
- /// import Internet Explorer bookmarks from Favorites folder into bookmark list
-void BookmarkList::import_IE_favorites(ShellDirectory& dir, HWND hwnd)
-{
-       TCHAR path[MAX_PATH], ext[_MAX_EXT];
-
-       dir.smart_scan(SORT_NAME, SCAN_FILESYSTEM);
-
-       for(Entry*entry=dir._down; entry; entry=entry->_next) {
-               if (entry->_shell_attribs & SFGAO_HIDDEN)       // ignore files like "desktop.ini"
-                       continue;
-
-               String name;
-
-               if (entry->_etype == ET_SHELL)
-                       name = dir._folder.get_name(static_cast<ShellEntry*>(entry)->_pidl);
-               else
-                       name = entry->_display_name;
-
-               if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-                       BookmarkFolder new_folder;
-
-                       new_folder._name = DecodeXMLString(name);
-
-                       if (entry->_etype == ET_SHELL) {
-                               ShellDirectory new_dir(dir._folder, static_cast<ShellEntry*>(entry)->_pidl, hwnd);
-                               new_folder._bookmarks.import_IE_favorites(new_dir, hwnd);
-                       } else {
-                               entry->get_path(path);
-                               ShellDirectory new_dir(GetDesktopFolder(), path, hwnd);
-                               new_folder._bookmarks.import_IE_favorites(new_dir, hwnd);
-                       }
-
-                       push_back(new_folder);
-               } else {
-                       Bookmark bookmark;
-
-                       bookmark._name = DecodeXMLString(name);
-
-                       entry->get_path(path);
-                       _tsplitpath(path, NULL, NULL, NULL, ext);
-
-                       if (!_tcsicmp(ext, TEXT(".url"))) {
-                               bookmark.read_url(path);
-                               push_back(bookmark);
-                       } else {
-                               ///@todo read shell links
-                               //assert(0);
-                       }
-               }
-       }
-}
-
-*/
-
-
- /// read XBEL bookmark file
-bool Favorites::read(LPCTSTR path)
-{
-       XMLDoc xbel;
-
-       if (!xbel.read(path))
-               if (xbel._last_error == XML_ERROR_NO_ELEMENTS)
-                       return false;
-               else
-                       MessageBox(0/*@@g_Globals._hwndDesktop*/, String(xbel._last_error_msg.c_str()),
-                                               TEXT("ROS Explorer - reading bookmark file"), MB_OK);
-
-       const_XMLPos pos(&xbel);
-
-       if (!pos.go_down("xbel"))
-               return false;
-
-       super::read(pos);
-
-       pos.back();
-
-       return true;
-}
-
- /// write XBEL bookmark file
-void Favorites::write(LPCTSTR path) const
-{
-       XMLDoc xbel;
-
-       XMLPos pos(&xbel);
-       pos.create("xbel");
-       super::write(pos);
-       pos.back();
-
-       xbel._header._doctype = "<!DOCTYPE xbel"
-               " PUBLIC \"+//IDN python.org//DTD XML Bookmark Exchange Language 1.0//EN//XML\"\n"
-               " \"http://www.python.org/topics/xml/dtds/xbel-1.0.dtd\">";
-
-       xbel.write(path);
-}
-
-
-/*@@
-
- /// import Internet Explorer bookmarks from Favorites folder
-bool Favorites::import_IE_favorites(HWND hwnd)
-{
-       WaitCursor wait;
-
-       StartMenuShellDirs dirs;
-
-       try {
-               dirs.push_back(ShellDirectory(GetDesktopFolder(), SpecialFolderPath(CSIDL_COMMON_FAVORITES, hwnd), hwnd));
-               dirs.push_back(ShellDirectory(GetDesktopFolder(), SpecialFolderPath(CSIDL_FAVORITES, hwnd), hwnd));
-       } catch(COMException&) {
-       }
-
-       for(StartMenuShellDirs::iterator it=dirs.begin(); it!=dirs.end(); ++it) {
-               StartMenuDirectory& smd = *it;
-               ShellDirectory& dir = smd._dir;
-
-               try {
-                       super::import_IE_favorites(dir, hwnd);
-               } catch(COMException&) {
-               }
-       }
-
-       return true;
-}
-
-*/
diff --git a/reactos/subsys/system/ibrowser/favorites.h b/reactos/subsys/system/ibrowser/favorites.h
deleted file mode 100644 (file)
index 4d139ee..0000000
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * Copyright 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer and Desktop clone
- //
- // favorites.h
- //
- // Martin Fuchs, 04.04.2004
- //
-
-
-extern String DecodeURLString(const char* s);
-
-
-struct Bookmark
-{
-       Bookmark() : _icon_idx(0) {}
-
-       String  _name;
-       String  _description;
-       String  _url;
-       String  _icon_path;
-       int             _icon_idx;
-
-       bool    read_url(LPCTSTR path);
-       bool    read(const_XMLPos& pos);
-       void    write(XMLPos& pos) const;
-};
-
-struct BookmarkFolder;
-
-struct BookmarkNode
-{
-       BookmarkNode();
-       BookmarkNode(const Bookmark& bm);
-       BookmarkNode(const BookmarkFolder& bmf);
-       BookmarkNode(const BookmarkNode& other);
-
-       ~BookmarkNode();
-
-       BookmarkNode& operator=(const Bookmark& bm);
-       BookmarkNode& operator=(const BookmarkFolder& bmf);
-       BookmarkNode& operator=(const BookmarkNode& other);
-
-       void    clear();
-
-       enum BOOKMARKNODE_TYPE {
-               BMNT_NONE, BMNT_BOOKMARK, BMNT_FOLDER
-       };
-
-       BOOKMARKNODE_TYPE       _type;
-
-       union {
-               Bookmark*               _pbookmark;
-               BookmarkFolder* _pfolder;
-       };
-};
-
-struct BookmarkList : public list<BookmarkNode>
-{
-       void    import_IE_favorites(struct ShellDirectory& dir, HWND hwnd);
-
-       void    read(const_XMLPos& pos);
-       void    write(XMLPos& pos) const;
-
-       void    fill_tree(HWND hwnd, HTREEITEM parent, HIMAGELIST, HDC hdc_wnd) const;
-};
-
-struct BookmarkFolder
-{
-       String  _name;
-       String  _description;
-       BookmarkList _bookmarks;
-
-       void    read(const_XMLPos& pos);
-       void    write(XMLPos& pos) const;
-};
-
-struct Favorites : public BookmarkList
-{
-       typedef BookmarkList super;
-
-       bool    read(LPCTSTR path);
-       void    write(LPCTSTR path) const;
-
-       bool    import_IE_favorites(HWND hwnd);
-};
diff --git a/reactos/subsys/system/ibrowser/ibrowser.cpp b/reactos/subsys/system/ibrowser/ibrowser.cpp
deleted file mode 100644 (file)
index 04b44e8..0000000
+++ /dev/null
@@ -1,550 +0,0 @@
-/*
- * Copyright 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // ROS Internet Web Browser
- //
- // ibrowser.cpp
- //
- // Martin Fuchs, 24.01.2005
- //
-
-
-#include <precomp.h>
-
-#include "ibrowser_intres.h"
-
-#include <locale.h>    // for setlocale()
-
-#ifndef __WINE__
-#include <io.h>                // for dup2()
-#include <fcntl.h>     // for _O_RDONLY
-#endif
-
-
- // globals
-
-HINSTANCE g_hInstance;
-IconCache g_icon_cache;
-ATOM g_hframeClass;
-
-
-/*@@
-void ExplorerGlobals::read_persistent()
-{
-        // read configuration file
-       _cfg_dir.printf(TEXT("%s\\ReactOS"), (LPCTSTR)SpecialFolderFSPath(CSIDL_APPDATA,0));
-       _cfg_path.printf(TEXT("%s\\ros-ibrowser-cfg.xml"), _cfg_dir.c_str());
-
-       if (!_cfg.read(_cfg_path)) {
-               if (_cfg._last_error != XML_ERROR_NO_ELEMENTS)
-                       MessageBox(g_Globals._hwndDesktop, String(_cfg._last_error_msg.c_str()),
-                                               TEXT("ROS Explorer - reading user settings"), MB_OK);
-
-               _cfg.read(TEXT("ibrowser-cfg-template.xml"));
-       }
-
-        // read bookmarks
-       _favorites_path.printf(TEXT("%s\\ros-ibrowser-bookmarks.xml"), _cfg_dir.c_str());
-
-       if (!_favorites.read(_favorites_path)) {
-               _favorites.import_IE_favorites(0);
-               _favorites.write(_favorites_path);
-       }
-}
-
-void ExplorerGlobals::write_persistent()
-{
-        // write configuration file
-       RecursiveCreateDirectory(_cfg_dir);
-
-       _cfg.write(_cfg_path);
-       _favorites.write(_favorites_path);
-}
-
-
-XMLPos ExplorerGlobals::get_cfg()
-{
-       XMLPos cfg_pos(&_cfg);
-
-       cfg_pos.smart_create("ibrowser-cfg");
-
-       return cfg_pos;
-}
-
-XMLPos ExplorerGlobals::get_cfg(const char* path)
-{
-       XMLPos cfg_pos(&_cfg);
-
-       cfg_pos.smart_create("ibrowser-cfg");
-       cfg_pos.create_relative(path);
-
-       return cfg_pos;
-}
-*/
-
-
-Icon::Icon()
- :     _id(ICID_UNKNOWN),
-       _itype(IT_STATIC),
-       _hicon(0)
-{
-}
-
-Icon::Icon(ICON_ID id, UINT nid)
- :     _id(id),
-       _itype(IT_STATIC),
-       _hicon(SmallIcon(nid))
-{
-}
-
-Icon::Icon(ICON_TYPE itype, int id, HICON hIcon)
- :     _id((ICON_ID)id),
-       _itype(itype),
-       _hicon(hIcon)
-{
-}
-
-Icon::Icon(ICON_TYPE itype, int id, int sys_idx)
- :     _id((ICON_ID)id),
-       _itype(itype),
-       _sys_idx(sys_idx)
-{
-}
-
-void Icon::draw(HDC hdc, int x, int y, int cx, int cy, COLORREF bk_color, HBRUSH bk_brush) const
-{
-       if (_itype == IT_SYSCACHE)
-               ImageList_DrawEx(g_icon_cache.get_sys_imagelist(), _sys_idx, hdc, x, y, cx, cy, bk_color, CLR_DEFAULT, ILD_NORMAL);
-       else
-               DrawIconEx(hdc, x, y, _hicon, cx, cy, 0, bk_brush, DI_NORMAL);
-}
-
-HBITMAP        Icon::create_bitmap(COLORREF bk_color, HBRUSH hbrBkgnd, HDC hdc_wnd) const
-{
-       if (_itype == IT_SYSCACHE) {
-               HIMAGELIST himl = g_icon_cache.get_sys_imagelist();
-
-               int cx, cy;
-               ImageList_GetIconSize(himl, &cx, &cy);
-
-               HBITMAP hbmp = CreateCompatibleBitmap(hdc_wnd, cx, cy);
-               HDC hdc = CreateCompatibleDC(hdc_wnd);
-               HBITMAP hbmp_old = SelectBitmap(hdc, hbmp);
-               ImageList_DrawEx(himl, _sys_idx, hdc, 0, 0, cx, cy, bk_color, CLR_DEFAULT, ILD_NORMAL);
-               SelectBitmap(hdc, hbmp_old);
-               DeleteDC(hdc);
-
-               return hbmp;
-       } else
-               return create_bitmap_from_icon(_hicon, hbrBkgnd, hdc_wnd);
-}
-
-
-int Icon::add_to_imagelist(HIMAGELIST himl, HDC hdc_wnd, COLORREF bk_color, HBRUSH bk_brush) const
-{
-       int ret;
-
-       if (_itype == IT_SYSCACHE) {
-               HIMAGELIST himl = g_icon_cache.get_sys_imagelist();
-
-               int cx, cy;
-               ImageList_GetIconSize(himl, &cx, &cy);
-
-               HBITMAP hbmp = CreateCompatibleBitmap(hdc_wnd, cx, cy);
-               HDC hdc = CreateCompatibleDC(hdc_wnd);
-               HBITMAP hbmp_old = SelectBitmap(hdc, hbmp);
-               ImageList_DrawEx(himl, _sys_idx, hdc, 0, 0, cx, cy, bk_color, CLR_DEFAULT, ILD_NORMAL);
-               SelectBitmap(hdc, hbmp_old);
-               DeleteDC(hdc);
-
-               ret = ImageList_Add(himl, hbmp, 0);
-
-               DeleteObject(hbmp);
-       } else
-               ret = ImageList_AddAlphaIcon(himl, _hicon, bk_brush, hdc_wnd);
-
-       return ret;
-}
-
-HBITMAP create_bitmap_from_icon(HICON hIcon, HBRUSH hbrush_bkgnd, HDC hdc_wnd)
-{
-       int cx = GetSystemMetrics(SM_CXSMICON);
-       int cy = GetSystemMetrics(SM_CYSMICON);
-       HBITMAP hbmp = CreateCompatibleBitmap(hdc_wnd, cx, cy);
-
-       MemCanvas canvas;
-       BitmapSelection sel(canvas, hbmp);
-
-       RECT rect = {0, 0, cx, cy};
-       FillRect(canvas, &rect, hbrush_bkgnd);
-
-       DrawIconEx(canvas, 0, 0, hIcon, cx, cy, 0, hbrush_bkgnd, DI_NORMAL);
-
-       return hbmp;
-}
-
-int ImageList_AddAlphaIcon(HIMAGELIST himl, HICON hIcon, HBRUSH hbrush_bkgnd, HDC hdc_wnd)
-{
-       HBITMAP hbmp = create_bitmap_from_icon(hIcon, hbrush_bkgnd, hdc_wnd);
-
-       int ret = ImageList_Add(himl, hbmp, 0);
-
-       DeleteObject(hbmp);
-
-       return ret;
-}
-
-
-int IconCache::s_next_id = ICID_DYNAMIC;
-
-
-void IconCache::init()
-{
-       _icons[ICID_NONE]               = Icon(IT_STATIC, ICID_NONE, (HICON)0);
-
-       _icons[ICID_IBROWSER]   = Icon(ICID_IBROWSER,   IDI_IBROWSER);
-       _icons[ICID_BOOKMARK]   = Icon(ICID_BOOKMARK,   IDI_DOT_TRANS);
-}
-
-
-const Icon& IconCache::extract(const String& path)
-{
-       PathMap::iterator found = _pathMap.find(path);
-
-       if (found != _pathMap.end())
-               return _icons[found->second];
-
-       SHFILEINFO sfi;
-
-#if 1  // use system image list
-       HIMAGELIST himlSys = (HIMAGELIST) SHGetFileInfo(path, 0, &sfi, sizeof(sfi), SHGFI_SYSICONINDEX|SHGFI_SMALLICON);
-
-       if (himlSys) {
-               _himlSys = himlSys;
-
-               const Icon& icon = add(sfi.iIcon/*, IT_SYSCACHE*/);
-#else
-       if (SHGetFileInfo(path, 0, &sfi, sizeof(sfi), SHGFI_ICON|SHGFI_SMALLICON)) {
-               const Icon& icon = add(sfi.hIcon, IT_CACHED);
-#endif
-
-               ///@todo limit cache size
-               _pathMap[path] = icon;
-
-               return icon;
-       } else
-               return _icons[ICID_NONE];
-}
-
-const Icon& IconCache::extract(LPCTSTR path, int idx)
-{
-       CachePair key(path, idx);
-
-#ifndef __WINE__ ///@todo _tcslwr() for Wine
-       _tcslwr((LPTSTR)key.first.c_str());
-#endif
-
-       PathIdxMap::iterator found = _pathIdxMap.find(key);
-
-       if (found != _pathIdxMap.end())
-               return _icons[found->second];
-
-       HICON hIcon;
-
-       if ((int)ExtractIconEx(path, idx, NULL, &hIcon, 1) > 0) {
-               const Icon& icon = add(hIcon, IT_CACHED);
-
-               _pathIdxMap[key] = icon;
-
-               return icon;
-       } else {
-
-               ///@todo retreive "http://.../favicon.ico" format icons
-
-               return _icons[ICID_NONE];
-       }
-}
-
-
-const Icon& IconCache::add(HICON hIcon, ICON_TYPE type)
-{
-       int id = ++s_next_id;
-
-       return _icons[id] = Icon(type, id, hIcon);
-}
-
-const Icon&    IconCache::add(int sys_idx/*, ICON_TYPE type=IT_SYSCACHE*/)
-{
-       int id = ++s_next_id;
-
-       return _icons[id] = SysCacheIcon(id, sys_idx);
-}
-
-const Icon& IconCache::get_icon(int id)
-{
-       return _icons[id];
-}
-
-void IconCache::free_icon(int icon_id)
-{
-       IconMap::iterator found = _icons.find(icon_id);
-
-       if (found != _icons.end()) {
-               Icon& icon = found->second;
-
-               if (icon.destroy())
-                       _icons.erase(found);
-       }
-}
-
-
-ResString::ResString(UINT nid)
-{
-       TCHAR buffer[BUFFER_LEN];
-
-       int len = LoadString(g_hInstance, nid, buffer, sizeof(buffer)/sizeof(TCHAR));
-
-       super::assign(buffer, len);
-}
-
-
-ResIcon::ResIcon(UINT nid)
-{
-       _hicon = LoadIcon(g_hInstance, MAKEINTRESOURCE(nid));
-}
-
-SmallIcon::SmallIcon(UINT nid)
-{
-       _hicon = (HICON)LoadImage(g_hInstance, MAKEINTRESOURCE(nid), IMAGE_ICON, GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), LR_SHARED);
-}
-
-ResIconEx::ResIconEx(UINT nid, int w, int h)
-{
-       _hicon = (HICON)LoadImage(g_hInstance, MAKEINTRESOURCE(nid), IMAGE_ICON, w, h, LR_SHARED);
-}
-
-
-void SetWindowIcon(HWND hwnd, UINT nid)
-{
-       HICON hIcon = ResIcon(nid);
-       (void)Window_SetIcon(hwnd, ICON_BIG, hIcon);
-
-       HICON hIconSmall = SmallIcon(nid);
-       (void)Window_SetIcon(hwnd, ICON_SMALL, hIconSmall);
-}
-
-
-ResBitmap::ResBitmap(UINT nid)
-{
-       _hBmp = LoadBitmap(g_hInstance, MAKEINTRESOURCE(nid));
-}
-
-
-void ibrowser_show_frame(int cmdshow, LPTSTR lpCmdLine)
-{
-       MainFrameBase::Create(lpCmdLine, cmdshow);
-}
-
-
-PopupMenu::PopupMenu(UINT nid)
-{
-       HMENU hMenu = LoadMenu(g_hInstance, MAKEINTRESOURCE(nid));
-       _hmenu = GetSubMenu(hMenu, 0);
-}
-
-
- /// "About" Dialog
-struct ExplorerAboutDlg : public
-                       CtlColorParent<
-                               OwnerDrawParent<Dialog>
-                       >
-{
-       typedef CtlColorParent<
-                               OwnerDrawParent<Dialog>
-                       > super;
-
-       ExplorerAboutDlg(HWND hwnd)
-        :      super(hwnd)
-       {
-               SetWindowIcon(hwnd, IDI_REACTOS);
-
-               new FlatButton(hwnd, IDOK);
-
-               _hfont = CreateFont(20, 0, 0, 0, FW_BOLD, TRUE, 0, 0, 0, 0, 0, 0, 0, TEXT("Sans Serif"));
-               new ColorStatic(hwnd, IDC_ROS_IBROWSER, RGB(32,32,128), 0, _hfont);
-
-               new HyperlinkCtrl(hwnd, IDC_WWW);
-
-               FmtString ver_txt(ResString(IDS_IBROWSER_VERSION_STR), (LPCTSTR)ResString(IDS_VERSION_STR));
-               SetWindowText(GetDlgItem(hwnd, IDC_VERSION_TXT), ver_txt);
-
-               /*@@
-               HWND hwnd_winver = GetDlgItem(hwnd, IDC_WIN_VERSION);
-               SetWindowText(hwnd_winver, get_windows_version_str());
-               SetWindowFont(hwnd_winver, GetStockFont(DEFAULT_GUI_FONT), FALSE);
-               */
-
-               CenterWindow(hwnd);
-       }
-
-       ~ExplorerAboutDlg()
-       {
-               DeleteObject(_hfont);
-       }
-
-protected:
-       HFONT   _hfont;
-};
-
-void ibrowser_about(HWND hwndParent)
-{
-       Dialog::DoModal(IDD_ABOUT_IBROWSER, WINDOW_CREATOR(ExplorerAboutDlg), hwndParent);
-}
-void ibrowser_open(HWND hwndParent)
-{
-    HMODULE            hShell32;
-    RUNFILEDLG        RunFileDlg;
-    OSVERSIONINFO    versionInfo;
-    WCHAR            wTitle[40];
-    WCHAR            wText[256];
-    char            szTitle[40] = "Open";
-    char            szText[256] = "Type the Internet Address of a document or folder and IBrowser will open it for you.";
-
-    hShell32 = LoadLibrary(_T("SHELL32.DLL"));
-    RunFileDlg = (RUNFILEDLG)(FARPROC)GetProcAddress(hShell32, (char*)((long)0x3D));
-
-    /* Show "Run..." dialog */
-    if (RunFileDlg)
-    {
-        versionInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
-        GetVersionEx(&versionInfo);
-
-        if (versionInfo.dwPlatformId == VER_PLATFORM_WIN32_NT)
-        {
-            MultiByteToWideChar(CP_ACP, MB_PRECOMPOSED, szTitle, -1, wTitle, 40);
-            MultiByteToWideChar(CP_ACP, MB_PRECOMPOSED, szText, -1, wText, 256);
-            RunFileDlg(hwndParent, 0, NULL, (LPCSTR)wTitle, (LPCSTR)wText, RFF_CALCDIRECTORY);
-        }
-        else
-            RunFileDlg(hwndParent, 0, NULL, szTitle, szText, RFF_CALCDIRECTORY);
-    }
-
-    FreeLibrary(hShell32);
-}
-
-static void InitInstance(HINSTANCE hInstance)
-{
-       CONTEXT("InitInstance");
-
-        // register frame window class
-       g_hframeClass = IconWindowClass(CLASSNAME_FRAME,IDI_IBROWSER);
-
-        // register child window class
-       WindowClass(CLASSNAME_CHILDWND, CS_CLASSDC|CS_VREDRAW).Register();
-}
-
-
-int ibrowser_main(HINSTANCE hInstance, LPTSTR lpCmdLine, int cmdshow)
-{
-       CONTEXT("ibrowser_main");
-
-        // initialize Common Controls library
-       CommonControlInit usingCmnCtrl;
-
-       try {
-               InitInstance(hInstance);
-       } catch(COMException& e) {
-               HandleException(e, GetDesktopWindow());
-               return -1;
-       }
-
-       if (cmdshow != SW_HIDE) {
-/*     // don't maximize if being called from the ROS desktop
-               if (cmdshow == SW_SHOWNORMAL)
-                               ///@todo read window placement from registry
-                       cmdshow = SW_MAXIMIZE;
-*/
-
-               ibrowser_show_frame(cmdshow, lpCmdLine);
-       }
-
-       return Window::MessageLoop();
-}
-
-
- // MinGW does not provide a Unicode startup routine, so we have to implement an own.
-#if defined(__MINGW32__) && defined(UNICODE)
-
-#define _tWinMain wWinMain
-int WINAPI wWinMain(HINSTANCE, HINSTANCE, LPWSTR, int);
-
-int main(int argc, char* argv[])
-{
-       CONTEXT("main");
-
-       STARTUPINFO startupinfo;
-       int nShowCmd = SW_SHOWNORMAL;
-
-       GetStartupInfo(&startupinfo);
-
-       if (startupinfo.dwFlags & STARTF_USESHOWWINDOW)
-               nShowCmd = startupinfo.wShowWindow;
-
-       LPWSTR cmdline = GetCommandLineW();
-
-       while(*cmdline && !_istspace(*cmdline))
-               ++cmdline;
-
-       while(_istspace(*cmdline))
-               ++cmdline;
-
-       return wWinMain(GetModuleHandle(NULL), 0, cmdline, nShowCmd);
-}
-
-#endif // __MINGW && UNICODE
-
-
-int WINAPI _tWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPTSTR lpCmdLine, int nShowCmd)
-{
-       CONTEXT("WinMain()");
-
-       g_hInstance = hInstance;
-
-        // initialize COM and OLE before creating the desktop window
-       OleInit usingCOM;
-
-        // init common controls library
-       CommonControlInit usingCmnCtrl;
-
-//@@   g_Globals.read_persistent();
-
-       /**TODO fix command line handling */
-       if (*lpCmdLine=='"' && lpCmdLine[_tcslen(lpCmdLine)-1]=='"') {
-               ++lpCmdLine;
-               lpCmdLine[_tcslen(lpCmdLine)-1] = '\0';
-       }
-
-       int ret = ibrowser_main(hInstance, lpCmdLine, nShowCmd);
-
-        // write configuration file
-//@@   g_Globals.write_persistent();
-
-       return ret;
-}
diff --git a/reactos/subsys/system/ibrowser/ibrowser.dsp b/reactos/subsys/system/ibrowser/ibrowser.dsp
deleted file mode 100644 (file)
index 902a990..0000000
+++ /dev/null
@@ -1,346 +0,0 @@
-# Microsoft Developer Studio Project File - Name="ibrowser" - Package Owner=<4>\r
-# Microsoft Developer Studio Generated Build File, Format Version 6.00\r
-# ** DO NOT EDIT **\r
-\r
-# TARGTYPE "Win32 (x86) Console Application" 0x0103\r
-\r
-CFG=IBROWSER - WIN32 DEBUG\r
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,\r
-!MESSAGE use the Export Makefile command and run\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "ibrowser.mak".\r
-!MESSAGE \r
-!MESSAGE You can specify a configuration when running NMAKE\r
-!MESSAGE by defining the macro CFG on the command line. For example:\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "ibrowser.mak" CFG="IBROWSER - WIN32 DEBUG"\r
-!MESSAGE \r
-!MESSAGE Possible choices for configuration are:\r
-!MESSAGE \r
-!MESSAGE "ibrowser - Win32 Release" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "ibrowser - Win32 Debug" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "ibrowser - Win32 Debug Release" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "ibrowser - Win32 Unicode Release" (based on "Win32 (x86) Console Application")\r
-!MESSAGE "ibrowser - Win32 Unicode Debug" (based on "Win32 (x86) Console Application")\r
-!MESSAGE \r
-\r
-# Begin Project\r
-# PROP AllowPerConfigDependencies 0\r
-# PROP Scc_ProjName ""\r
-# PROP Scc_LocalPath ""\r
-CPP=cl.exe\r
-RSC=rc.exe\r
-\r
-!IF  "$(CFG)" == "ibrowser - Win32 Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "Release"\r
-# PROP BASE Intermediate_Dir "Release"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "Release"\r
-# PROP Intermediate_Dir "Release"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c\r
-# ADD CPP /nologo /MD /W3 /GR /GX /O1 /D "NDEBUG" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /Yu"precomp.h" /FD /c\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386\r
-# ADD LINK32 gdi32.lib comctl32.lib shell32.lib ole32.lib /nologo /subsystem:windows /machine:I386 /libpath:"Release"\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "ibrowser - Win32 Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c\r
-# ADD CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /FR /Yu"precomp.h" /FD /GZ /c\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 kernel32.lib gdi32.lib comctl32.lib shell32.lib ole32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept /libpath:"Debug"\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "ibrowser - Win32 Debug Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "DRelease"\r
-# PROP BASE Intermediate_Dir "DRelease"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "DRelease"\r
-# PROP Intermediate_Dir "DRelease"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "_ROS_" /YX /FD /c\r
-# ADD CPP /nologo /MD /W3 /GR /GX /Zi /O2 /D "NDEBUG" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /FR /Yu"precomp.h" /FD /c\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib shell32.lib /nologo /subsystem:console /machine:I386\r
-# ADD LINK32 gdi32.lib comctl32.lib shell32.lib ole32.lib /nologo /subsystem:windows /debug /machine:I386\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "ibrowser - Win32 Unicode Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "URelease"\r
-# PROP BASE Intermediate_Dir "URelease"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "URelease"\r
-# PROP Intermediate_Dir "URelease"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "NDEBUG" /D "WIN32" /D "UNICODE" /D "_ROS_" /YX /FD /c\r
-# ADD CPP /nologo /MD /W3 /GR /GX /O2 /D "NDEBUG" /D "UNICODE" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /Yu"precomp.h" /FD /c\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib shell32.lib /nologo /subsystem:console /machine:I386\r
-# ADD LINK32 gdi32.lib comctl32.lib shell32.lib ole32.lib /nologo /subsystem:windows /machine:I386 /libpath:"Release"\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ELSEIF  "$(CFG)" == "ibrowser - Win32 Unicode Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "UDebug"\r
-# PROP BASE Intermediate_Dir "UDebug"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "UDebug"\r
-# PROP Intermediate_Dir "UDebug"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "WIN32" /D "UNICODE" /D "_ROS_" /FR /YX /FD /GZ /c\r
-# ADD CPP /nologo /MDd /W3 /Gm /GR /GX /ZI /Od /D "_DEBUG" /D "UNICODE" /D "WIN32" /D _WIN32_IE=0x0600 /D _WIN32_WINNT=0x0501 /FR /Yu"precomp.h" /FD /GZ /c\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib shell32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 gdi32.lib comctl32.lib shell32.lib ole32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept /libpath:"Debug"\r
-# SUBTRACT LINK32 /pdb:none\r
-\r
-!ENDIF \r
-\r
-# Begin Target\r
-\r
-# Name "ibrowser - Win32 Release"\r
-# Name "ibrowser - Win32 Debug"\r
-# Name "ibrowser - Win32 Debug Release"\r
-# Name "ibrowser - Win32 Unicode Release"\r
-# Name "ibrowser - Win32 Unicode Debug"\r
-# Begin Group "utility"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\comutil.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\utility.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\utility.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\window.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\window.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\xmlstorage.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\utility\xmlstorage.h\r
-# End Source File\r
-# End Group\r
-# Begin Group "resources"\r
-\r
-# PROP Default_Filter "bmp,ico"\r
-# Begin Source File\r
-\r
-SOURCE=.\De.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\dot.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\dot_red.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\dot_trans.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\En.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Es.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\favorites.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Fr.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Hu.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\ibrowser.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\ibrowser.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\ibrowser_intres.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\ibrowser_intres.rc\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\iexplore.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Ja.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\network.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\reactos.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Ro.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Sv.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\res\toolbar.bmp\r
-# End Source File\r
-# End Group\r
-# Begin Group "main"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\favorites.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\favorites.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\ibrowser.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\ibrowser.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\mainframe.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\mainframe.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\precomp.cpp\r
-# ADD CPP /Yc"precomp.h"\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\precomp.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\webchild.cpp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\webchild.h\r
-# End Source File\r
-# End Group\r
-# Begin Source File\r
-\r
-SOURCE=.\readme.txt\r
-# End Source File\r
-# End Target\r
-# End Project\r
diff --git a/reactos/subsys/system/ibrowser/ibrowser.dsw b/reactos/subsys/system/ibrowser/ibrowser.dsw
deleted file mode 100644 (file)
index eb8d259..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-Microsoft Developer Studio Workspace File, Format Version 6.00\r
-# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!\r
-\r
-###############################################################################\r
-\r
-Project: "ibrowser"=.\ibrowser.dsp - Package Owner=<4>\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<4>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
-Project: "make_ibrowser"=.\make_ibrowser.dsp - Package Owner=<4>\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<4>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
-Global:\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<3>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
diff --git a/reactos/subsys/system/ibrowser/ibrowser.h b/reactos/subsys/system/ibrowser/ibrowser.h
deleted file mode 100644 (file)
index f1e3b26..0000000
+++ /dev/null
@@ -1,231 +0,0 @@
-/*
- * Copyright 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // ROS Internet Web Browser
- //
- // ibrowser.h
- //
- // Martin Fuchs, 25.01.2005
- //
-
-
-#include "utility/window.h"
-
-
-#define        IDW_STATUSBAR                   0x100
-#define        IDW_TOOLBAR                             0x101
-#define        IDW_EXTRABAR                    0x102
-#define        IDW_ADDRESSBAR                  0x104
-#define        IDW_SIDEBAR                             0x106
-#define        IDW_FIRST_CHILD                 0xC000  /*0x200*/
-
-
-#define        PM_GET_FILEWND_PTR              (WM_APP+0x05)
-#define        PM_GET_SHELLBROWSER_PTR (WM_APP+0x06)
-
-#define        PM_GET_CONTROLWINDOW    (WM_APP+0x16)
-
-#define        PM_RESIZE_CHILDREN              (WM_APP+0x17)
-#define        PM_GET_WIDTH                    (WM_APP+0x18)
-
-#define        PM_REFRESH                              (WM_APP+0x1B)
-#define        PM_REFRESH_CONFIG               (WM_APP+0x1C)
-
-
-#define        CLASSNAME_FRAME                 TEXT("IBrowserFrameWClass")
-
-#define        CLASSNAME_CHILDWND              TEXT("IBrowserChildWClass")
-
-
-#include "mainframe.h"
-
-
- /// convenient loading of string resources
-struct ResString : public String
-{
-       ResString(UINT nid);
-};
-
- /// convenient loading of standard (32x32) icon resources
-struct ResIcon
-{
-       ResIcon(UINT nid);
-
-       operator HICON() const {return _hicon;}
-
-protected:
-       HICON   _hicon;
-};
-
- /// convenient loading of small (16x16) icon resources
-struct SmallIcon
-{
-       SmallIcon(UINT nid);
-
-       operator HICON() const {return _hicon;}
-
-protected:
-       HICON   _hicon;
-};
-
- /// convenient loading of icon resources with specified sizes
-struct ResIconEx
-{
-       ResIconEx(UINT nid, int w, int h);
-
-       operator HICON() const {return _hicon;}
-
-protected:
-       HICON   _hicon;
-};
-
- /// set big and small icons out of the resources for a window
-extern void SetWindowIcon(HWND hwnd, UINT nid);
-
- /// convenient loading of bitmap resources
-struct ResBitmap
-{
-       ResBitmap(UINT nid);
-       ~ResBitmap() {DeleteObject(_hBmp);}
-
-       operator HBITMAP() const {return _hBmp;}
-
-protected:
-       HBITMAP _hBmp;
-};
-
-
-enum ICON_TYPE {
-       IT_STATIC,
-       IT_CACHED,
-       IT_DYNAMIC,
-       IT_SYSCACHE
-};
-
-enum ICON_ID {
-       ICID_UNKNOWN,
-       ICID_NONE,
-
-       ICID_IBROWSER,
-       ICID_BOOKMARK,
-
-       ICID_DYNAMIC
-};
-
-struct Icon {
-       Icon();
-       Icon(ICON_ID id, UINT nid);
-       Icon(ICON_TYPE itype, int id, HICON hIcon);
-       Icon(ICON_TYPE itype, int id, int sys_idx);
-
-       operator ICON_ID() const {return _id;}
-
-       void    draw(HDC hdc, int x, int y, int cx, int cy, COLORREF bk_color, HBRUSH bk_brush) const;
-       HBITMAP create_bitmap(COLORREF bk_color, HBRUSH hbrBkgnd, HDC hdc_wnd) const;
-       int             add_to_imagelist(HIMAGELIST himl, HDC hdc_wnd, COLORREF bk_color=GetSysColor(COLOR_WINDOW), HBRUSH bk_brush=GetSysColorBrush(COLOR_WINDOW)) const;
-
-       int             get_sysiml_idx() const {return _itype==IT_SYSCACHE? _sys_idx: -1;}
-
-       bool    destroy() {if (_itype == IT_DYNAMIC) {DestroyIcon(_hicon); return true;} else return false;}
-
-protected:
-       ICON_ID _id;
-       ICON_TYPE _itype;
-       HICON   _hicon;
-       int             _sys_idx;
-};
-
-struct SysCacheIcon : public Icon {
-       SysCacheIcon(int id, int sys_idx)
-        :      Icon(IT_SYSCACHE, id, sys_idx) {}
-};
-
-struct IconCache {
-       IconCache() : _himlSys(0) {}
-
-       void    init();
-
-       const Icon&     extract(const String& path);
-       const Icon&     extract(LPCTSTR path, int idx);
-       const Icon&     extract(IExtractIcon* pExtract, LPCTSTR path, int idx);
-
-       const Icon&     add(HICON hIcon, ICON_TYPE type=IT_DYNAMIC);
-       const Icon&     add(int sys_idx/*, ICON_TYPE type=IT_SYSCACHE*/);
-
-       const Icon&     get_icon(int icon_id);
-       HIMAGELIST get_sys_imagelist() const {return _himlSys;}
-
-       void    free_icon(int icon_id);
-
-protected:
-       static int s_next_id;
-
-       typedef map<int, Icon> IconMap;
-       IconMap _icons;
-
-       typedef map<String, ICON_ID> PathMap;
-       PathMap _pathMap;
-
-       typedef pair<String, int> CachePair;
-       typedef map<CachePair, ICON_ID> PathIdxMap;
-       PathIdxMap _pathIdxMap;
-
-       HIMAGELIST _himlSys;
-};
-
-
- /// create a bitmap from an icon
-extern HBITMAP create_bitmap_from_icon(HICON hIcon, HBRUSH hbrush_bkgnd, HDC hdc_wnd);
-
- /// add icon with alpha channel to imagelist using the specified background color
-extern int ImageList_AddAlphaIcon(HIMAGELIST himl, HICON hIcon, HBRUSH hbrush_bkgnd, HDC hdc_wnd);
-
-
-#include "utility/xmlstorage.h"
-
-using namespace XMLStorage;
-
-#include "favorites.h"
-
-
- // globals
-extern HINSTANCE g_hInstance;
-extern IconCache g_icon_cache;
-extern ATOM g_hframeClass;
-
-
- // display explorer "About" dialog
-extern void ibrowser_about(HWND hwndParent);
-
- // display explorer "open" dialog
-extern void ibrowser_open(HWND hwndParent);
-
- // declare shell32's "Run..." dialog export function
-typedef        void (WINAPI* RUNFILEDLG)(HWND hwndOwner, HICON hIcon, LPCSTR lpstrDirectory, LPCSTR lpstrTitle, LPCSTR lpstrDescription, UINT uFlags);
-
- //
- // Flags for RunFileDlg
- //
-
-#define        RFF_NOBROWSE            0x01    // Removes the browse button.
-#define        RFF_NODEFAULT           0x02    // No default item selected.
-#define        RFF_CALCDIRECTORY       0x04    // Calculates the working directory from the file name.
-#define        RFF_NOLABEL                     0x08    // Removes the edit box label.
-#define        RFF_NOSEPARATEMEM       0x20    // Removes the Separate Memory Space check box (Windows NT only).
diff --git a/reactos/subsys/system/ibrowser/ibrowser.rc b/reactos/subsys/system/ibrowser/ibrowser.rc
deleted file mode 100644 (file)
index 2dbd1d6..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-#include <windows.h>\r
-\r
-#include "ibrowser_intres.rc"\r
-\r
-#define REACTOS_STR_FILE_DESCRIPTION   "ROS Internet Web Browser\0"\r
-#define REACTOS_STR_INTERNAL_NAME              "ibrowser\0"\r
-#define REACTOS_STR_ORIGINAL_FILENAME  "ibrowser.exe\0"\r
-#include <reactos/version.rc>\r
-\r
-LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US\r
-\r
-#define IDS_VERSION_STR             5000\r
-#define IDS_IBROWSER_VERSION_STR    5001\r
diff --git a/reactos/subsys/system/ibrowser/ibrowser.xml b/reactos/subsys/system/ibrowser/ibrowser.xml
deleted file mode 100644 (file)
index e4fd3fd..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<module name="ibrowser" type="win32gui" installbase="system32" installname="ibrowser.exe"  allowwarnings ="true">
-       <linkerflag>-fexceptions</linkerflag>
-       <include base="ibrowser">.</include>
-       <include base="ReactOS">include/expat</include>
-       <define name="__USE_W32API" />
-       <define name="UNICODE" />
-       <define name="WIN32" />
-       <define name="_ROS_" />
-       <define name="_WIN32_IE">0x0600</define>
-       <define name="_WIN32_WINNT">0x0501</define>
-       <define name="WINVER">0x0500</define>
-       <library>uuid</library>
-       <library>kernel32</library>
-       <library>gdi32</library>
-       <library>comctl32</library>
-       <library>ole32</library>
-       <library>oleaut32</library>
-       <library>shell32</library>
-       <library>expat</library>
-       <pch>precomp.h</pch>
-       <directory name="utility">
-               <file>utility.cpp</file>
-               <file>window.cpp</file>
-               <file>xmlstorage.cpp</file>
-       </directory>
-       <file>ibrowser.cpp</file>
-       <file>favorites.cpp</file>
-       <file>mainframe.cpp</file>
-       <file>webchild.cpp</file>
-       <file>ibrowser.rc</file>
-</module>
diff --git a/reactos/subsys/system/ibrowser/ibrowser_intres.h b/reactos/subsys/system/ibrowser/ibrowser_intres.h
deleted file mode 100644 (file)
index c80ddc7..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-//{{NO_DEPENDENCIES}}
-// Microsoft Developer Studio generated include file.
-// Used by ibrowser_intres.rc
-//
-#define IDS_TITLE                       1
-#define IDS_EMPTY                       13
-#define IDS_ABOUT_IBROWSER              27
-#define IDI_REACTOS                     100
-#define IDB_TOOLBAR                     103
-#define IDA_IBROWSER                    104
-#define IDM_SDIFRAME                    113
-#define IDD_ABOUT_IBROWSER              135
-#define IDI_FAVORITES                   140
-#define IDI_DOT                         163
-#define IDI_DOT_TRANS                   164
-#define IDI_DOT_RED                     165
-#define IDI_IBROWSER                    169
-#define ID_VIEW_STATUSBAR               503
-#define ID_VIEW_TOOL_BAR                508
-#define ID_VIEW_SIDE_BAR                510
-#define IDC_ROS_IBROWSER                1000
-#define IDC_WWW                         1012
-#define IDC_VERSION_TXT                 1029
-#define IDC_WIN_VERSION                 1030
-#define ID_REFRESH                      1704
-#define IDS_VERSION_STR                 5000
-#define IDS_IBROWSER_VERSION_STR        5001
-#define ID_IBROWSER_FAQ                 10002
-#define ID_VIEW_FULLSCREEN              0x8004
-#define ID_ABOUT_WINDOWS                40002
-#define ID_ABOUT_IBROWSER               40003
-#define ID_GO_BACK                      40005
-#define ID_GO_FORWARD                   40006
-#define ID_GO_HOME                      40007
-#define ID_GO_SEARCH                    40008
-#define ID_GO_UP                        40009
-#define ID_STOP                         40010
-#define ID_FILE_OPEN                    0xE140
-#define ID_FILE_EXIT                    0xE141
-#define ID_HELP                         0xE146
-#define IDC_STATIC                      -1
-
-// Next default values for new objects
-// 
-#ifdef APSTUDIO_INVOKED
-#ifndef APSTUDIO_READONLY_SYMBOLS
-#define _APS_NEXT_RESOURCE_VALUE        170
-#define _APS_NEXT_COMMAND_VALUE         40024
-#define _APS_NEXT_CONTROL_VALUE         1033
-#define _APS_NEXT_SYMED_VALUE           101
-#endif
-#endif
diff --git a/reactos/subsys/system/ibrowser/ibrowser_intres.rc b/reactos/subsys/system/ibrowser/ibrowser_intres.rc
deleted file mode 100644 (file)
index 0afbb76..0000000
+++ /dev/null
@@ -1,107 +0,0 @@
-//Microsoft Developer Studio generated resource script.\r
-//\r
-#include "ibrowser_intres.h"\r
-\r
-#define APSTUDIO_READONLY_SYMBOLS\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 2 resource.\r
-//\r
-#include <windows.h>\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-#undef APSTUDIO_READONLY_SYMBOLS\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-// Neutral resources\r
-\r
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_NEU)\r
-#ifdef _WIN32\r
-LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL\r
-#pragma code_page(1252)\r
-#endif //_WIN32\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Bitmap\r
-//\r
-\r
-IDB_TOOLBAR             BITMAP  DISCARDABLE     "res/toolbar.bmp"\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Accelerator\r
-//\r
-\r
-IDA_IBROWSER ACCELERATORS DISCARDABLE \r
-BEGIN\r
-    "X",            ID_FILE_EXIT,           VIRTKEY, ALT, NOINVERT\r
-    "S",            ID_VIEW_FULLSCREEN,     VIRTKEY, SHIFT, CONTROL, \r
-                                                    NOINVERT\r
-END\r
-\r
-\r
-#ifdef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// TEXTINCLUDE\r
-//\r
-\r
-1 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "ibrowser_intres.h\0"\r
-END\r
-\r
-2 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#include <windows.h>\r\n"\r
-    "\0"\r
-END\r
-\r
-3 TEXTINCLUDE DISCARDABLE \r
-BEGIN\r
-    "#include ""En.rc""\r\n"\r
-    "#include ""Es.rc""\r\n"\r
-    "#include ""Fr.rc""\r\n"\r
-    "#include ""Sv.rc""\r\n"\r
-    "#include ""Hu.rc""\r\n"\r
-    "#include ""Ro.rc""\r\n"\r
-    "#include ""Ja.rc""\0"\r
-END\r
-\r
-#endif    // APSTUDIO_INVOKED\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Icon\r
-//\r
-\r
-// Icon with lowest ID value placed first to ensure application icon\r
-// remains consistent on all systems.\r
-IDI_REACTOS             ICON    DISCARDABLE     "res/reactos.ico"\r
-IDI_FAVORITES           ICON    DISCARDABLE     "res/favorites.ico"\r
-IDI_DOT                 ICON    DISCARDABLE     "res/dot.ico"\r
-IDI_DOT_TRANS           ICON    DISCARDABLE     "res/dot_trans.ico"\r
-IDI_DOT_RED             ICON    DISCARDABLE     "res/dot_red.ico"\r
-IDI_IBROWSER            ICON    DISCARDABLE     "res/ibrowser.ico"\r
-#endif    // Neutral resources\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-\r
-\r
-#ifndef APSTUDIO_INVOKED\r
-/////////////////////////////////////////////////////////////////////////////\r
-//\r
-// Generated from the TEXTINCLUDE 3 resource.\r
-//\r
-#include "En.rc"\r
-#include "Es.rc"\r
-#include "Fr.rc"\r
-#include "Sv.rc"\r
-#include "Hu.rc"\r
-#include "Ro.rc"\r
-#include "Ja.rc"\r
-/////////////////////////////////////////////////////////////////////////////\r
-#endif    // not APSTUDIO_INVOKED\r
-\r
diff --git a/reactos/subsys/system/ibrowser/mainframe.cpp b/reactos/subsys/system/ibrowser/mainframe.cpp
deleted file mode 100644 (file)
index b92ea80..0000000
+++ /dev/null
@@ -1,791 +0,0 @@
-/*
- * Copyright 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // ROS Internet Web Browser
- //
- // mainframe.cpp
- //
- // Martin Fuchs, 25.01.2005
- //
-
-
-#include <precomp.h>
-
-/* We can't include webchild.h here - otherwise MinGW produces errors like: "multiple definition of `QACONTAINERFLAGS'"
-#include "webchild.h"
-*/
-extern HWND create_webchildwindow(const WebChildWndInfo& info);
-
-#include "ibrowser_intres.h"
-
-
-HWND MainFrameBase::Create(LPCTSTR url, UINT cmdshow)
-{
-       HWND hMainFrame;
-
-       hMainFrame = MainFrame::Create();
-       //@@hMainFrame = MainFrame::Create(url);
-
-       if (hMainFrame) {
-               if (url) {
-                       static String sPath = url;      // copy url to avoid accessing freed memory
-                       url = sPath;
-               }
-
-               ShowWindow(hMainFrame, cmdshow);
-               UpdateWindow(hMainFrame);
-
-                // Open the first child window after initializing the application
-               PostMessage(hMainFrame, PM_OPEN_WINDOW, 0, (LPARAM)url);
-       }
-
-       return hMainFrame;
-}
-
-
-MainFrameBase::MainFrameBase(HWND hwnd)
- :     super(hwnd),
-       _himl(ImageList_Create(GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), ILC_MASK|ILC_COLOR24, 2, 0))
-{
-       _hMenuFrame = GetMenu(hwnd);
-       _hMenuWindow = GetSubMenu(_hMenuFrame, GetMenuItemCount(_hMenuFrame)-3);
-
-       _menu_info._hMenuView = GetSubMenu(_hMenuFrame, 1);
-
-       _hAccel = LoadAccelerators(g_hInstance, MAKEINTRESOURCE(IDA_IBROWSER));
-
-
-       TBBUTTON toolbarBtns[] = {
-#ifdef _NO_REBAR
-               {0, 0, 0, BTNS_SEP, {0, 0}, 0, 0},
-#endif
-               {7, ID_GO_BACK, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {8, ID_GO_FORWARD, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {9, ID_GO_UP, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {10, ID_GO_HOME, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {11, ID_GO_SEARCH, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {12, ID_REFRESH, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-               {13, ID_STOP, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0}
-       };
-
-       _htoolbar = CreateToolbarEx(hwnd, 
-#ifndef _NO_REBAR
-               CCS_NOPARENTALIGN|CCS_NORESIZE|
-#endif
-               WS_CHILD|WS_VISIBLE, IDW_TOOLBAR, 2, g_hInstance, IDB_TOOLBAR,
-               toolbarBtns, sizeof(toolbarBtns)/sizeof(TBBUTTON),
-               16, 15, 16, 15, sizeof(TBBUTTON));
-
-       CheckMenuItem(_menu_info._hMenuView, ID_VIEW_TOOL_BAR, MF_BYCOMMAND|MF_CHECKED);
-
-
-        // address bar
-       WindowCanvas canvas(hwnd);
-       RECT rect = {0, 0, 0, 0};
-       DrawText(canvas, TEXT("My"), -1, &rect, DT_SINGLELINE|DT_NOPREFIX|DT_CALCRECT);
-       HFONT hfont = GetStockFont(DEFAULT_GUI_FONT);
-
-       _haddressedit = CreateWindow(TEXT("EDIT"), NULL, WS_CHILD|WS_VISIBLE|WS_BORDER, 0, 0, 0, rect.bottom,
-                                                       hwnd, (HMENU)IDW_ADDRESSBAR, g_hInstance, 0);
-       SetWindowFont(_haddressedit, hfont, FALSE);
-       new EditController(_haddressedit);
-
-       /* CreateStatusWindow does not accept WS_BORDER
-               _hstatusbar = CreateWindowEx(WS_EX_NOPARENTNOTIFY, STATUSCLASSNAME, 0,
-                                               WS_CHILD|WS_VISIBLE|WS_CLIPSIBLINGS|WS_BORDER|CCS_NODIVIDER, 0,0,0,0,
-                                               hwnd, (HMENU)IDW_STATUSBAR, g_hInstance, 0);*/
-
-       _hstatusbar = CreateStatusWindow(WS_CHILD|WS_VISIBLE, 0, hwnd, IDW_STATUSBAR);
-       CheckMenuItem(_menu_info._hMenuView, ID_VIEW_STATUSBAR, MF_BYCOMMAND|MF_CHECKED);
-
-       _hsidebar = CreateWindowEx(WS_EX_STATICEDGE, WC_TREEVIEW, TEXT("Sidebar"),
-                                       WS_CHILD|WS_TABSTOP|WS_BORDER|/*WS_VISIBLE|*/WS_CHILD|TVS_HASLINES|TVS_HASBUTTONS|TVS_SHOWSELALWAYS|TVS_INFOTIP,
-                                       -1, -1, 200, 0, _hwnd, (HMENU)IDW_SIDEBAR, g_hInstance, 0);
-
-       (void)TreeView_SetImageList(_hsidebar, _himl, TVSIL_NORMAL);
-
-       CheckMenuItem(_menu_info._hMenuView, ID_VIEW_SIDE_BAR, MF_BYCOMMAND|MF_UNCHECKED/*MF_CHECKED*/);
-
-
-        // create rebar window to manage toolbar and address bar
-#ifndef _NO_REBAR
-       _hwndrebar = CreateWindowEx(WS_EX_TOOLWINDOW, REBARCLASSNAME, NULL,
-                                       WS_CHILD|WS_VISIBLE|WS_CLIPSIBLINGS|WS_CLIPCHILDREN|
-                                       RBS_VARHEIGHT|RBS_AUTOSIZE|RBS_DBLCLKTOGGLE|
-                                       CCS_NODIVIDER|CCS_NOPARENTALIGN,
-                                       0, 0, 0, 0, _hwnd, 0, g_hInstance, 0);
-
-       int btn_hgt = HIWORD(SendMessage(_htoolbar, TB_GETBUTTONSIZE, 0, 0));
-
-       REBARBANDINFO rbBand;
-
-       rbBand.cbSize = sizeof(REBARBANDINFO);
-       rbBand.fMask  = RBBIM_TEXT|RBBIM_STYLE|RBBIM_CHILD|RBBIM_CHILDSIZE|RBBIM_SIZE;
-#ifndef RBBS_HIDETITLE // missing in MinGW headers as of 25.02.2004
-#define RBBS_HIDETITLE 0x400
-#endif
-       rbBand.fStyle = RBBS_CHILDEDGE|RBBS_GRIPPERALWAYS|RBBS_HIDETITLE;
-
-       rbBand.cxMinChild = 0;
-       rbBand.cyMinChild = 0;
-       rbBand.cyChild = 0;
-       rbBand.cyMaxChild = 0;
-       rbBand.cyIntegral = btn_hgt;
-
-       rbBand.lpText = TEXT("Toolbar");
-       rbBand.hwndChild = _htoolbar;
-       rbBand.cxMinChild = 0;
-       rbBand.cyMinChild = btn_hgt + 4;
-       rbBand.cx = 182;
-       SendMessage(_hwndrebar, RB_INSERTBAND, (WPARAM)-1, (LPARAM)&rbBand);
-
-       rbBand.lpText = TEXT("Address");
-       rbBand.hwndChild = _haddressedit;
-       rbBand.cxMinChild = 0;
-       rbBand.cyMinChild = btn_hgt - 2;
-       rbBand.cx = 284;
-       SendMessage(_hwndrebar, RB_INSERTBAND, (WPARAM)-1, (LPARAM)&rbBand);
-#endif
-}
-
-
-MainFrameBase::~MainFrameBase()
-{
-       ImageList_Destroy(_himl);
-
-//@@if (g_Globals._hMainWnd == _hwnd)
-               PostQuitMessage(0);
-}
-
-
-LRESULT MainFrameBase::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       LRESULT res;
-
-       if (ProcessMessage(nmsg, wparam, lparam, &res))
-               return res;
-       else
-               return super::WndProc(nmsg, wparam, lparam);
-}
-
-bool MainFrameBase::ProcessMessage(UINT nmsg, WPARAM wparam, LPARAM lparam, LRESULT* pres)
-{
-       switch(nmsg) {
-         case PM_TRANSLATE_MSG:
-               *pres = TranslateMsg((MSG*)lparam);
-               return true;
-
-         case WM_SHOWWINDOW:
-               if (wparam)     // trigger child resizing after window creation - now we can succesfully call IsWindowVisible()
-                       resize_frame_client();
-               return false; // goto def;
-
-         case WM_CLOSE:
-               DestroyWindow(_hwnd);
-//@@           g_Globals._hMainWnd = 0;
-               break;
-
-         case WM_DESTROY:
-               break;
-
-         case WM_SIZE:
-               resize_frame(LOWORD(lparam), HIWORD(lparam));
-               break;  // do not pass message to DefFrameProc
-
-         case WM_GETMINMAXINFO: {
-               LPMINMAXINFO lpmmi = (LPMINMAXINFO)lparam;
-
-               lpmmi->ptMaxTrackSize.x <<= 1;/*2*GetSystemMetrics(SM_CXSCREEN) / SM_CXVIRTUALSCREEN */
-               lpmmi->ptMaxTrackSize.y <<= 1;/*2*GetSystemMetrics(SM_CYSCREEN) / SM_CYVIRTUALSCREEN */
-               break;}
-
-         case PM_FRM_CALC_CLIENT:
-               frame_get_clientspace((PRECT)lparam);
-               *pres = TRUE;
-               return true;
-
-         case PM_FRM_GET_MENUINFO:
-               *pres = (LPARAM)&_menu_info;
-               return true;
-
-         case PM_GET_CONTROLWINDOW:
-               if (wparam == FCW_STATUS) {
-                       *pres = (LRESULT)(HWND)_hstatusbar;
-                       return true;
-               }
-               break;
-
-         case PM_SETSTATUSTEXT:
-               SendMessage(_hstatusbar, SB_SETTEXT, wparam, lparam);
-               break;
-
-         case PM_URL_CHANGED:
-               SetWindowText(_haddressedit, (LPCTSTR)lparam);
-               break;
-
-         default:
-               return false;
-       }
-
-       *pres = 0;
-       return true;
-}
-
-BOOL MainFrameBase::TranslateMsg(MSG* pmsg)
-{
-       if (TranslateAccelerator(_hwnd, _hAccel, pmsg))
-               return TRUE;
-
-       return FALSE;
-}
-
-
-int MainFrameBase::Command(int id, int code)
-{
-       CONTEXT("MainFrameBase::Command()");
-
-       switch(id) {
-         case ID_FILE_OPEN:
-               ibrowser_open(_hwnd);
-               break;
-
-         case ID_FILE_EXIT:
-               SendMessage(_hwnd, WM_CLOSE, 0, 0);
-               break;
-
-         case ID_VIEW_TOOL_BAR:
-               toggle_child(_hwnd, id, _htoolbar, 0);
-               break;
-
-         case ID_VIEW_STATUSBAR:
-               toggle_child(_hwnd, id, _hstatusbar);
-               break;
-
-         case ID_VIEW_SIDE_BAR:
-                // lazy initialization
-               if (!TreeView_GetCount(_hsidebar))
-                       FillBookmarks();
-
-               toggle_child(_hwnd, id, _hsidebar);
-               break;
-
-         case ID_HELP:
-               WinHelp(_hwnd, TEXT("ibrowser")/*file ibrowser.hlp*/, HELP_INDEX, 0);
-               break;
-
-         case ID_VIEW_FULLSCREEN:
-               CheckMenuItem(_menu_info._hMenuView, id, toggle_fullscreen()?MF_CHECKED:0);
-               break;
-
-         case ID_ABOUT_WINDOWS:
-               ShellAbout(_hwnd, ResString(IDS_TITLE), NULL, 0);
-               break;
-
-         case ID_ABOUT_IBROWSER:
-               ibrowser_about(_hwnd);
-               break;
-
-         case ID_IBROWSER_FAQ:
-               launch_file(_hwnd, TEXT("http://www.sky.franken.de/explorer/"), SW_SHOW);
-               break;
-
-         case IDW_ADDRESSBAR:
-               if (code == 1) {
-                       TCHAR url[BUFFER_LEN];
-
-                       if (GetWindowText(_haddressedit, url, BUFFER_LEN))
-                               go_to(url, false);
-               }
-               break;
-
-         default:
-               return 1;       // no command handlers in Window::Command()
-       }
-
-       return 0;
-}
-
-
-int MainFrameBase::Notify(int id, NMHDR* pnmh)
-{
-       switch(pnmh->code) {
-                // resize children windows when the rebar size changes
-         case RBN_AUTOSIZE:
-               resize_frame_client();
-               break;
-
-         case TVN_GETINFOTIP: {
-               NMTVGETINFOTIP* pnmgit = (NMTVGETINFOTIP*)pnmh;
-
-               if (pnmgit->lParam) {
-                       const BookmarkNode& node = *(BookmarkNode*)pnmgit->lParam;
-
-                       if (node._type == BookmarkNode::BMNT_FOLDER) {
-                                // display tooltips for bookmark folders
-                               if (!node._pfolder->_description.empty())
-                                       lstrcpyn(pnmgit->pszText, node._pfolder->_description.c_str(), pnmgit->cchTextMax);
-                       } else if (node._type == BookmarkNode::BMNT_BOOKMARK) {
-                                // display tooltips for bookmark folders
-                               String txt = node._pbookmark->_description;
-
-                               if (!node._pbookmark->_url.empty()) {
-                                       if (!txt.empty())
-                                               txt += TEXT("  -  ");
-
-                                       txt += node._pbookmark->_url;
-                               }
-
-                               lstrcpyn(pnmgit->pszText, txt.c_str(), pnmgit->cchTextMax);
-                       }
-               }
-               break;}
-
-         case NM_DBLCLK: {
-               HTREEITEM hitem = TreeView_GetSelection(_hsidebar);
-               LPARAM lparam = TreeView_GetItemData(_hsidebar, hitem);
-
-               if (lparam) {
-                       const BookmarkNode& node = *(BookmarkNode*)lparam;
-
-                       if (node._type == BookmarkNode::BMNT_BOOKMARK) {
-                               bool new_window = GetAsyncKeyState(VK_SHIFT)<0;
-
-                               go_to(node._pbookmark->_url, new_window);
-                       }
-               }
-               break;}
-       }
-
-       return 0;
-}
-
-
-void MainFrameBase::resize_frame(int cx, int cy)
-{
-       if (cy <= 0)
-               return; // avoid resizing children when receiving RBN_AUTOSIZE while getting minimized
-
-       RECT rect = {0, 0, cx, cy};
-
-       if (_hwndrebar) {
-               int height = ClientRect(_hwndrebar).bottom;
-               MoveWindow(_hwndrebar, rect.left, rect.top, rect.right-rect.left, height, TRUE);
-               rect.top += height;
-       } else {
-               if (IsWindowVisible(_htoolbar)) {
-                       SendMessage(_htoolbar, WM_SIZE, 0, 0);
-                       WindowRect rt(_htoolbar);
-                       rect.top = rt.bottom;
-               //      rect.bottom -= rt.bottom;
-               }
-       }
-
-       if (IsWindowVisible(_hstatusbar)) {
-               int parts[] = {300, 500};
-
-               SendMessage(_hstatusbar, WM_SIZE, 0, 0);
-               SendMessage(_hstatusbar, SB_SETPARTS, 2, (LPARAM)&parts);
-               ClientRect rt(_hstatusbar);
-               rect.bottom -= rt.bottom;
-       }
-
-       if (IsWindowVisible(_hsidebar)) {
-               WindowRect rt(_hsidebar);
-               rect.left += rt.right-rt.left;
-
-               SetWindowPos(_hsidebar, 0, -1, rect.top-1, rt.right-rt.left, rect.bottom-rect.top+1, SWP_NOACTIVATE|SWP_NOZORDER);
-       }
-}
-
-void MainFrameBase::resize_frame_client()
-{
-       ClientRect rect(_hwnd);
-
-       resize_frame(rect.right, rect.bottom);
-}
-
-void MainFrameBase::frame_get_clientspace(PRECT prect)
-{
-       if (!IsIconic(_hwnd))
-               GetClientRect(_hwnd, prect);
-       else {
-               WINDOWPLACEMENT wp;
-
-               GetWindowPlacement(_hwnd, &wp);
-
-               prect->left = prect->top = 0;
-               prect->right = wp.rcNormalPosition.right-wp.rcNormalPosition.left-
-                                               2*(GetSystemMetrics(SM_CXSIZEFRAME)+GetSystemMetrics(SM_CXEDGE));
-               prect->bottom = wp.rcNormalPosition.bottom-wp.rcNormalPosition.top-
-                                               2*(GetSystemMetrics(SM_CYSIZEFRAME)+GetSystemMetrics(SM_CYEDGE))-
-                                               GetSystemMetrics(SM_CYCAPTION)-GetSystemMetrics(SM_CYMENUSIZE);
-       }
-
-       if (IsWindowVisible(_htoolbar)) {
-               ClientRect rt(_htoolbar);
-               prect->top += rt.bottom+2;
-       }
-
-       if (IsWindowVisible(_hstatusbar)) {
-               ClientRect rt(_hstatusbar);
-               prect->bottom -= rt.bottom;
-       }
-}
-
-BOOL MainFrameBase::toggle_fullscreen()
-{
-       RECT rt;
-
-       if ((_fullscreen._mode=!_fullscreen._mode)) {
-               GetWindowRect(_hwnd, &_fullscreen._orgPos);
-               _fullscreen._wasZoomed = IsZoomed(_hwnd);
-
-               Frame_CalcFrameClient(_hwnd, &rt);
-               ClientToScreen(_hwnd, (LPPOINT)&rt.left);
-               ClientToScreen(_hwnd, (LPPOINT)&rt.right);
-
-               rt.left = _fullscreen._orgPos.left-rt.left;
-               rt.top = _fullscreen._orgPos.top-rt.top;
-               rt.right = GetSystemMetrics(SM_CXSCREEN)+_fullscreen._orgPos.right-rt.right;
-               rt.bottom = GetSystemMetrics(SM_CYSCREEN)+_fullscreen._orgPos.bottom-rt.bottom;
-
-               MoveWindow(_hwnd, rt.left, rt.top, rt.right-rt.left, rt.bottom-rt.top, TRUE);
-       } else {
-               MoveWindow(_hwnd, _fullscreen._orgPos.left, _fullscreen._orgPos.top,
-                                                       _fullscreen._orgPos.right-_fullscreen._orgPos.left,
-                                                       _fullscreen._orgPos.bottom-_fullscreen._orgPos.top, TRUE);
-
-               if (_fullscreen._wasZoomed)
-                       ShowWindow(_hwnd, WS_MAXIMIZE);
-       }
-
-       return _fullscreen._mode;
-}
-
-void MainFrameBase::fullscreen_move()
-{
-       RECT rt, pos;
-       GetWindowRect(_hwnd, &pos);
-
-       Frame_CalcFrameClient(_hwnd, &rt);
-       ClientToScreen(_hwnd, (LPPOINT)&rt.left);
-       ClientToScreen(_hwnd, (LPPOINT)&rt.right);
-
-       rt.left = pos.left-rt.left;
-       rt.top = pos.top-rt.top;
-       rt.right = GetSystemMetrics(SM_CXSCREEN)+pos.right-rt.right;
-       rt.bottom = GetSystemMetrics(SM_CYSCREEN)+pos.bottom-rt.bottom;
-
-       MoveWindow(_hwnd, rt.left, rt.top, rt.right-rt.left, rt.bottom-rt.top, TRUE);
-}
-
-
-void MainFrameBase::toggle_child(HWND hwnd, UINT cmd, HWND hchild, int band_idx)
-{
-       BOOL vis = IsWindowVisible(hchild);
-
-       CheckMenuItem(_menu_info._hMenuView, cmd, vis?MF_BYCOMMAND:MF_BYCOMMAND|MF_CHECKED);
-
-       if (band_idx != -1)
-               SendMessage(_hwndrebar, RB_SHOWBAND, band_idx, !vis);
-       else
-               ShowWindow(hchild, vis? SW_HIDE: SW_SHOW);
-
-       if (_fullscreen._mode)
-               fullscreen_move();
-
-       resize_frame_client();
-}
-
-void MainFrameBase::FillBookmarks()
-{
-/*@@
-       HiddenWindow hide(_hsidebar);
-       WindowCanvas canvas(_hwnd);
-
-       TreeView_DeleteAllItems(_hsidebar);
-
-       g_icon_cache.get_icon(ICID_FAVORITES).add_to_imagelist(_himl, canvas);
-       g_icon_cache.get_icon(ICID_BOOKMARK).add_to_imagelist(_himl, canvas);
-       ImageList_AddAlphaIcon(_himl, SmallIcon(IDI_DOT), GetStockBrush(WHITE_BRUSH), canvas);
-       g_icon_cache.get_icon(ICID_FOLDER).add_to_imagelist(_himl, canvas);
-       g_icon_cache.get_icon(ICID_FOLDER).add_to_imagelist(_himl, canvas);
-
-       TV_INSERTSTRUCT tvi;
-
-       tvi.hParent = TVI_ROOT;
-       tvi.hInsertAfter = TVI_LAST;
-       tvi.item.mask = TVIF_TEXT|TVIF_IMAGE|TVIF_SELECTEDIMAGE;
-       ResString sFavorites(IDS_FAVORITES);
-       tvi.item.pszText = (LPTSTR)sFavorites.c_str();
-       tvi.item.iSelectedImage = tvi.item.iImage = 0;
-
-       HTREEITEM hitem_bookmarks = TreeView_InsertItem(_hsidebar, &tvi);
-
-       g_Globals._favorites.fill_tree(_hsidebar, hitem_bookmarks, _himl, canvas);
-
-       TreeView_Expand(_hsidebar, hitem_bookmarks, TVE_EXPAND);
-*/
-}
-
-
-MainFrame::MainFrame(HWND hwnd)
- :     super(hwnd)
-{
-       _split_pos = DEFAULT_SPLIT_POS;
-       _last_split = DEFAULT_SPLIT_POS;
-}
-
-HWND MainFrame::Create()
-{
-       HMENU hMenuFrame = LoadMenu(g_hInstance, MAKEINTRESOURCE(IDM_SDIFRAME));
-
-       return Window::Create(WINDOW_CREATOR(MainFrame), 0,
-                               (LPCTSTR)(int)g_hframeClass, ResString(IDS_TITLE), WS_OVERLAPPEDWINDOW,
-                               CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT,
-                               0/*hwndDesktop*/, hMenuFrame);
-}
-
-/*@@
-HWND MainFrame::Create(LPCTSTR url)
-{
-       HWND hFrame = Create();
-       if (!hFrame)
-               return 0;
-
-       ShowWindow(hFrame, SW_SHOW);
-
-       MainFrame* pFrame = GET_WINDOW(MainFrame, hFrame);
-
-       if (pFrame)
-               pFrame->set_url(url);
-
-       return hFrame;
-}
-*/
-
-LRESULT MainFrame::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_SIZE:
-               resize_frame(LOWORD(lparam), HIWORD(lparam));
-               break;
-
-         case WM_PAINT: {
-               PaintCanvas canvas(_hwnd);
-
-               if (_left_hwnd && _right_hwnd) {
-                       ClientRect rt(_hwnd);
-                       rt.left = _split_pos-SPLIT_WIDTH/2;
-                       rt.right = _split_pos+SPLIT_WIDTH/2+1;
-
-                       if (_right_hwnd) {
-                               WindowRect right_rect(_right_hwnd);
-                               ScreenToClient(_hwnd, &right_rect);
-                               rt.top = right_rect.top;
-                               rt.bottom = right_rect.bottom;
-                       }
-
-                       HBRUSH lastBrush = SelectBrush(canvas, GetStockBrush(COLOR_SPLITBAR));
-                       Rectangle(canvas, rt.left, rt.top-1, rt.right, rt.bottom+1);
-                       SelectObject(canvas, lastBrush);
-               }
-               break;}
-
-         case WM_SETCURSOR:
-               if (LOWORD(lparam) == HTCLIENT) {
-                       POINT pt;
-                       GetCursorPos(&pt);
-                       ScreenToClient(_hwnd, &pt);
-
-                       if (pt.x>=_split_pos-SPLIT_WIDTH/2 && pt.x<_split_pos+SPLIT_WIDTH/2+1) {
-                               SetCursor(LoadCursor(0, IDC_SIZEWE));
-                               return TRUE;
-                       }
-               }
-               goto def;
-
-         case WM_LBUTTONDOWN: {
-               int x = GET_X_LPARAM(lparam);
-
-               ClientRect rt(_hwnd);
-
-               if (x>=_split_pos-SPLIT_WIDTH/2 && x<_split_pos+SPLIT_WIDTH/2+1) {
-                       _last_split = _split_pos;
-                       SetCapture(_hwnd);
-               }
-
-               break;}
-
-         case WM_LBUTTONUP:
-               if (GetCapture() == _hwnd)
-                       ReleaseCapture();
-               break;
-
-         case WM_KEYDOWN:
-               if (wparam == VK_ESCAPE)
-                       if (GetCapture() == _hwnd) {
-                               _split_pos = _last_split;
-                               resize_children();
-                               _last_split = -1;
-                               ReleaseCapture();
-                               SetCursor(LoadCursor(0, IDC_ARROW));
-                       }
-               break;
-
-         case WM_MOUSEMOVE:
-               if (GetCapture() == _hwnd) {
-                       int x = LOWORD(lparam);
-
-                       ClientRect rt(_hwnd);
-
-                       if (x>=0 && x<rt.right) {
-                               _split_pos = x;
-                               resize_children();
-                               rt.left = x-SPLIT_WIDTH/2;
-                               rt.right = x+SPLIT_WIDTH/2+1;
-                               InvalidateRect(_hwnd, &rt, FALSE);
-                               UpdateWindow(_left_hwnd);
-                               UpdateWindow(_hwnd);
-                               UpdateWindow(_right_hwnd);
-                       }
-               }
-               break;
-
-         case PM_OPEN_WINDOW: {CONTEXT("MainFrame PM_OPEN_WINDOW");
-               LPCTSTR url = (LPCTSTR)lparam;
-
-               if (!url || !*url)
-#ifdef _DEBUG
-                       url = TEXT("http://localhost");
-#else
-                       url = TEXT("about:blank");
-#endif
-
-               if (!_right_hwnd) {
-                       _right_hwnd = create_webchildwindow(WebChildWndInfo(_hwnd, url));
-                       resize_children();
-               } else
-                       set_url(url);
-               return TRUE;}   // success
-
-         default: def:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-int MainFrame::Command(int id, int code)
-{
-       if (_right_hwnd)
-               if (SendMessage(_right_hwnd, PM_DISPATCH_COMMAND, MAKELONG(id,code), 0))
-                       return 0;
-
-       return super::Command(id, code);
-}
-
-void MainFrame::resize_frame(int cx, int cy)
-{
-       if (cy <= 0)
-               return; // avoid resizing children when receiving RBN_AUTOSIZE while getting minimized
-
-       RECT rect = {0, 0, cx, cy};
-
-       if (_hwndrebar) {
-               int height = ClientRect(_hwndrebar).bottom;
-               MoveWindow(_hwndrebar, rect.left, rect.top, rect.right-rect.left, height, TRUE);
-               rect.top += height;
-       } else {
-               if (IsWindowVisible(_htoolbar)) {
-                       SendMessage(_htoolbar, WM_SIZE, 0, 0);
-                       WindowRect rt(_htoolbar);
-                       rect.top = rt.bottom;
-               //      rect.bottom -= rt.bottom;
-               }
-       }
-
-       if (IsWindowVisible(_hstatusbar)) {
-               int parts[] = {300, 500};
-
-               SendMessage(_hstatusbar, WM_SIZE, 0, 0);
-               SendMessage(_hstatusbar, SB_SETPARTS, 2, (LPARAM)&parts);
-               ClientRect rt(_hstatusbar);
-               rect.bottom -= rt.bottom;
-       }
-
-       if (IsWindowVisible(_hsidebar)) {
-               WindowRect rt(_hsidebar);
-               rect.left += rt.right-rt.left;
-
-               SetWindowPos(_hsidebar, 0, -1, rect.top-1, rt.right-rt.left, rect.bottom-rect.top+1, SWP_NOACTIVATE|SWP_NOZORDER);
-       }
-
-       _clnt_rect = rect;
-
-       resize_children();
-}
-
-void MainFrame::resize_children()
-{
-       HDWP hdwp = BeginDeferWindowPos(2);
-
-       int cx = _clnt_rect.left;
-
-       if (_left_hwnd) {
-               cx = _split_pos + SPLIT_WIDTH/2;
-
-               hdwp = DeferWindowPos(hdwp, _left_hwnd, 0, _clnt_rect.left, _clnt_rect.top, _split_pos-SPLIT_WIDTH/2-_clnt_rect.left, _clnt_rect.bottom-_clnt_rect.top, SWP_NOZORDER|SWP_NOACTIVATE);
-       } else {
-               //_split_pos = 0;
-               cx = 0;
-       }
-
-       if (_right_hwnd)
-               hdwp = DeferWindowPos(hdwp, _right_hwnd, 0, _clnt_rect.left+cx, _clnt_rect.top, _clnt_rect.right-cx, _clnt_rect.bottom-_clnt_rect.top, SWP_NOZORDER|SWP_NOACTIVATE);
-
-       EndDeferWindowPos(hdwp);
-}
-
-void MainFrame::update_clnt_rect()
-{
-       ClientRect rect(_hwnd);
-
-       resize_frame(rect.right, rect.bottom);
-}
-
-void MainFrame::set_url(LPCTSTR url)
-{
-       if (_url != url) {
-               _url = url;
-
-               SetWindowText(_haddressedit, url); //SendMessage(_hwndFrame, PM_URL_CHANGED, 0, (LPARAM)url);
-       }
-}
-
-bool MainFrame::go_to(LPCTSTR url, bool new_window)
-{
-       if (_right_hwnd) {
-               SendMessage(_right_hwnd, PM_JUMP_TO_URL, 0, (LPARAM)url);
-               return true;
-       }
-
-       return false;
-}
diff --git a/reactos/subsys/system/ibrowser/mainframe.h b/reactos/subsys/system/ibrowser/mainframe.h
deleted file mode 100644 (file)
index eb8e869..0000000
+++ /dev/null
@@ -1,125 +0,0 @@
-/*
- * Copyright 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // ROS Internet Web Browser
- //
- // mainframe.h
- //
- // Martin Fuchs, 25.01.2005
- //
-
-
-#define        PM_OPEN_WINDOW                  (WM_APP+0x07)
-
-
- /// Explorer frame window base class
-struct MainFrameBase : public PreTranslateWindow
-{
-       typedef PreTranslateWindow super;
-
-       MainFrameBase(HWND hwnd);
-       ~MainFrameBase();
-
-       static HWND Create(LPCTSTR url, UINT cmdshow=SW_SHOWNORMAL);
-
-       WindowHandle _hwndrebar;
-
-       WindowHandle _htoolbar;
-       WindowHandle _hstatusbar;
-
-       WindowHandle _haddressedit;
-
-       WindowHandle _hsidebar;
-       HIMAGELIST      _himl;
-
-       HMENU   _hMenuFrame;
-       HMENU   _hMenuWindow;
-
-       MenuInfo _menu_info;
-
-protected:
-       FullScreenParameters _fullscreen;
-
-       HACCEL  _hAccel;
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       bool    ProcessMessage(UINT nmsg, WPARAM wparam, LPARAM lparam, LRESULT* pres);
-       int             Command(int id, int code);
-       int             Notify(int id, NMHDR* pnmh);
-
-       virtual BOOL TranslateMsg(MSG* pmsg);
-
-       void    toggle_child(HWND hwnd, UINT cmd, HWND hchild, int band_idx=-1);
-
-       void    resize_frame_client();
-       virtual void resize_frame(int cx, int cy);
-       virtual void frame_get_clientspace(PRECT prect);
-
-       BOOL    toggle_fullscreen();
-       void    fullscreen_move();
-
-       void    FillBookmarks();
-       virtual bool go_to(LPCTSTR url, bool new_window) {return false;}
-};
-
-
-struct MainFrame : public MainFrameBase
-{
-       typedef MainFrameBase super;
-
-       MainFrame(HWND hwnd);
-
-       static HWND Create();
-       //@@static HWND Create(LPCTSTR url);
-
-protected:
-       WindowHandle _left_hwnd;
-       WindowHandle _right_hwnd;
-
-       int     _split_pos;
-       int             _last_split;
-       RECT    _clnt_rect;
-
-       String  _url;
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Command(int id, int code);
-
-       void    resize_frame(int cx, int cy);
-       void    resize_children();
-       void    update_clnt_rect();
-
-       void    set_url(LPCTSTR url);
-
-       virtual bool go_to(LPCTSTR url, bool new_window);
-};
-
-
-struct WebChildWndInfo : public ChildWndInfo
-{
-       WebChildWndInfo(HWND hwndFrame, LPCTSTR url)
-        :      ChildWndInfo(hwndFrame),
-               _url(url)
-       {
-       }
-
-       String  _url;
-};
-
diff --git a/reactos/subsys/system/ibrowser/make_ibrowser.dsp b/reactos/subsys/system/ibrowser/make_ibrowser.dsp
deleted file mode 100644 (file)
index e83ba69..0000000
+++ /dev/null
@@ -1,172 +0,0 @@
-# Microsoft Developer Studio Project File - Name="make_ibrowser" - Package Owner=<4>\r
-# Microsoft Developer Studio Generated Build File, Format Version 6.00\r
-# ** DO NOT EDIT **\r
-\r
-# TARGTYPE "Win32 (x86) External Target" 0x0106\r
-\r
-CFG=make_ibrowser - Win32 bjam\r
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,\r
-!MESSAGE use the Export Makefile command and run\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "make_ibrowser.mak".\r
-!MESSAGE \r
-!MESSAGE You can specify a configuration when running NMAKE\r
-!MESSAGE by defining the macro CFG on the command line. For example:\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "make_ibrowser.mak" CFG="make_ibrowser - Win32 bjam"\r
-!MESSAGE \r
-!MESSAGE Possible choices for configuration are:\r
-!MESSAGE \r
-!MESSAGE "make_ibrowser - Win32 Release" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_ibrowser - Win32 Debug" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_ibrowser - Win32 Unicode Debug" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_ibrowser - Win32 Unicode Release" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_ibrowser - Win32 bjam" (based on "Win32 (x86) External Target")\r
-!MESSAGE \r
-\r
-# Begin Project\r
-# PROP AllowPerConfigDependencies 0\r
-# PROP Scc_ProjName ""\r
-# PROP Scc_LocalPath ""\r
-\r
-!IF  "$(CFG)" == "make_ibrowser - Win32 Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "Release"\r
-# PROP BASE Intermediate_Dir "Release"\r
-# PROP BASE Cmd_Line "NMAKE /f make_ibrowser.mak"\r
-# PROP BASE Rebuild_Opt "/a"\r
-# PROP BASE Target_File "make_ibrowser.exe"\r
-# PROP BASE Bsc_Name "make_ibrowser.bsc"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "Release"\r
-# PROP Intermediate_Dir "Release"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.PCH UNICODE=0"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "ibrowser.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_ibrowser - Win32 Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Cmd_Line "NMAKE /f make_ibrowser.mak"\r
-# PROP BASE Rebuild_Opt "/a"\r
-# PROP BASE Target_File "make_ibrowser.exe"\r
-# PROP BASE Bsc_Name "make_ibrowser.bsc"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.PCH UNICODE=0 DEBUG=1"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "ibrowser.exe"\r
-# PROP Bsc_Name "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=0 DEBUG=1"\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_ibrowser - Win32 Unicode Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "UDebug"\r
-# PROP BASE Intermediate_Dir "UDebug"\r
-# PROP BASE Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=1 DEBUG=1"\r
-# PROP BASE Rebuild_Opt "clean all"\r
-# PROP BASE Target_File "ibrowser.exe"\r
-# PROP BASE Bsc_Name ""\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "UDebug"\r
-# PROP Intermediate_Dir "UDebug"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=1 DEBUG=1"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "ibrowser.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_ibrowser - Win32 Unicode Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "URelease"\r
-# PROP BASE Intermediate_Dir "URelease"\r
-# PROP BASE Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW UNICODE=1"\r
-# PROP BASE Rebuild_Opt "clean all"\r
-# PROP BASE Target_File "ibrowser.exe"\r
-# PROP BASE Bsc_Name ""\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "URelease"\r
-# PROP Intermediate_Dir "URelease"\r
-# PROP Cmd_Line "msdevfilt -gcc make -f Makefile.PCH UNICODE=1"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "ibrowser.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_ibrowser - Win32 bjam"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW DEBUG=1"\r
-# PROP BASE Rebuild_Opt "clean all"\r
-# PROP BASE Target_File "ibrowser.exe"\r
-# PROP BASE Bsc_Name ""\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" bjam"\r
-# PROP Rebuild_Opt "clean&bjam release"\r
-# PROP Target_File "ibrowser.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ENDIF \r
-\r
-# Begin Target\r
-\r
-# Name "make_ibrowser - Win32 Release"\r
-# Name "make_ibrowser - Win32 Debug"\r
-# Name "make_ibrowser - Win32 Unicode Debug"\r
-# Name "make_ibrowser - Win32 Unicode Release"\r
-# Name "make_ibrowser - Win32 bjam"\r
-\r
-!IF  "$(CFG)" == "make_ibrowser - Win32 Release"\r
-\r
-!ELSEIF  "$(CFG)" == "make_ibrowser - Win32 Debug"\r
-\r
-!ELSEIF  "$(CFG)" == "make_ibrowser - Win32 Unicode Debug"\r
-\r
-!ELSEIF  "$(CFG)" == "make_ibrowser - Win32 Unicode Release"\r
-\r
-!ELSEIF  "$(CFG)" == "make_ibrowser - Win32 bjam"\r
-\r
-!ENDIF \r
-\r
-# Begin Source File\r
-\r
-SOURCE=.\Makefile\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Makefile.MinGW\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Makefile.PCH\r
-# End Source File\r
-# End Target\r
-# End Project\r
diff --git a/reactos/subsys/system/ibrowser/precomp.cpp b/reactos/subsys/system/ibrowser/precomp.cpp
deleted file mode 100644 (file)
index c786813..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Copyright 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // ROS Internet Web Browser - precompiled header support
- //
- // precomp.h
- //
- // Martin Fuchs, 25.01.2005
- //
-
-#include "precomp.h"
diff --git a/reactos/subsys/system/ibrowser/precomp.h b/reactos/subsys/system/ibrowser/precomp.h
deleted file mode 100644 (file)
index c0d382d..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // ROS Internet Web Browser - precompiled header support
- //
- // precomp.h
- //
- // Martin Fuchs, 25.01.2005
- //
-
-#include "utility/utility.h"
-#include "utility/comutil.h"
-
-#include "ibrowser.h"
-
diff --git a/reactos/subsys/system/ibrowser/readme.txt b/reactos/subsys/system/ibrowser/readme.txt
deleted file mode 100644 (file)
index 234c112..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-\r
-IBrowser is a Web Browser User Interface similar derived from ROS Explorer.\r
-It encapsulates the Mozilla or MS Web Browser Control.\r
-\r
-\r
-For more information about ReactOS Explorer please look at the FAQ web page:\r
-\r
-http://www.sky.franken.de/explorer/\r
-\r
diff --git a/reactos/subsys/system/ibrowser/res/dot.ico b/reactos/subsys/system/ibrowser/res/dot.ico
deleted file mode 100644 (file)
index 9ddbb8a..0000000
Binary files a/reactos/subsys/system/ibrowser/res/dot.ico and /dev/null differ
diff --git a/reactos/subsys/system/ibrowser/res/dot_red.ico b/reactos/subsys/system/ibrowser/res/dot_red.ico
deleted file mode 100644 (file)
index 4d176ee..0000000
Binary files a/reactos/subsys/system/ibrowser/res/dot_red.ico and /dev/null differ
diff --git a/reactos/subsys/system/ibrowser/res/dot_trans.ico b/reactos/subsys/system/ibrowser/res/dot_trans.ico
deleted file mode 100644 (file)
index d5ede5a..0000000
Binary files a/reactos/subsys/system/ibrowser/res/dot_trans.ico and /dev/null differ
diff --git a/reactos/subsys/system/ibrowser/res/favorites.ico b/reactos/subsys/system/ibrowser/res/favorites.ico
deleted file mode 100644 (file)
index 558748e..0000000
Binary files a/reactos/subsys/system/ibrowser/res/favorites.ico and /dev/null differ
diff --git a/reactos/subsys/system/ibrowser/res/ibrowser.ico b/reactos/subsys/system/ibrowser/res/ibrowser.ico
deleted file mode 100644 (file)
index cb99641..0000000
Binary files a/reactos/subsys/system/ibrowser/res/ibrowser.ico and /dev/null differ
diff --git a/reactos/subsys/system/ibrowser/res/network.ico b/reactos/subsys/system/ibrowser/res/network.ico
deleted file mode 100644 (file)
index 5bcf5ec..0000000
Binary files a/reactos/subsys/system/ibrowser/res/network.ico and /dev/null differ
diff --git a/reactos/subsys/system/ibrowser/res/reactos.ico b/reactos/subsys/system/ibrowser/res/reactos.ico
deleted file mode 100644 (file)
index 492e388..0000000
Binary files a/reactos/subsys/system/ibrowser/res/reactos.ico and /dev/null differ
diff --git a/reactos/subsys/system/ibrowser/res/toolbar.bmp b/reactos/subsys/system/ibrowser/res/toolbar.bmp
deleted file mode 100644 (file)
index c3001a7..0000000
Binary files a/reactos/subsys/system/ibrowser/res/toolbar.bmp and /dev/null differ
diff --git a/reactos/subsys/system/ibrowser/utility/comutil.h b/reactos/subsys/system/ibrowser/utility/comutil.h
deleted file mode 100644 (file)
index fc2655e..0000000
+++ /dev/null
@@ -1,321 +0,0 @@
-/*
- * Copyright 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // ROS Internet Web Browser
- // 
- // comutil.h
- //
- // C++ wrapper classes for COM interfaces
- //
- // Martin Fuchs, 25.01.2005
- //
-
-
- // windows shell headers
-#include <shellapi.h>
-#include <shlobj.h>
-
-/*@@
-#if _MSC_VER>=1300     // VS.Net
-#include <comdefsp.h>
-using namespace _com_util;
-#endif
-*/
-
-#ifndef _INC_COMUTIL   // is comutil.h of MS headers not available?
-#ifndef _NO_COMUTIL
-#define        _NO_COMUTIL
-#endif
-#endif
-
-
- // Exception Handling
-
-#ifndef _NO_COMUTIL
-
-#define        COMExceptionBase _com_error
-
-#else
-
- /// COM ExceptionBase class as replacement for _com_error
-struct COMExceptionBase
-{
-       COMExceptionBase(HRESULT hr)
-        :      _hr(hr)
-       {
-       }
-
-       HRESULT Error() const
-       {
-               return _hr;
-       }
-
-       LPCTSTR ErrorMessage() const
-       {
-               if (_msg.empty()) {
-                       LPTSTR pBuf;
-
-                       if (FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER|FORMAT_MESSAGE_FROM_SYSTEM,
-                               0, _hr, MAKELANGID(LANG_NEUTRAL,SUBLANG_DEFAULT), (LPTSTR)&pBuf, 0, NULL)) {
-                               _msg = pBuf;
-                               LocalFree(pBuf);
-                        } else {
-                               TCHAR buffer[128];
-                               _stprintf(buffer, TEXT("unknown Exception: 0x%08lX"), _hr);
-                               _msg = buffer;
-                        }
-               }
-
-               return _msg;
-       }
-
-protected:
-       HRESULT _hr;
-       mutable String _msg;
-};
-
-#endif
-
-
- /// Exception with context information
-
-struct COMException : public COMExceptionBase
-{
-       typedef COMExceptionBase super;
-
-       COMException(HRESULT hr)
-        :      super(hr),
-               _context(CURRENT_CONTEXT),
-               _file(NULL), _line(0)
-       {
-               LOG(toString());
-               LOG(CURRENT_CONTEXT.getStackTrace());
-       }
-
-       COMException(HRESULT hr, const char* file, int line)
-        :      super(hr),
-               _context(CURRENT_CONTEXT),
-               _file(file), _line(line)
-       {
-               LOG(toString());
-               LOG(CURRENT_CONTEXT.getStackTrace());
-       }
-
-       COMException(HRESULT hr, const String& obj)
-        :      super(hr),
-               _context(CURRENT_CONTEXT),
-               _file(NULL), _line(0)
-       {
-               LOG(toString());
-               LOG(CURRENT_CONTEXT.getStackTrace());
-       }
-
-       COMException(HRESULT hr, const String& obj, const char* file, int line)
-        :      super(hr),
-               _context(CURRENT_CONTEXT),
-               _file(file), _line(line)
-       {
-               LOG(toString());
-               LOG(CURRENT_CONTEXT.getStackTrace());
-       }
-
-       String toString() const;
-
-       Context _context;
-
-       const char* _file;
-       int _line;
-};
-
-#define        THROW_EXCEPTION(hr) throw COMException(hr, __FILE__, __LINE__)
-#define        CHECKERROR(hr) ((void)(FAILED(hr)? THROW_EXCEPTION(hr): 0))
-
-
-#ifdef _NO_COMUTIL
-
-inline void CheckError(HRESULT hr)
-{
-       if (FAILED(hr))
-               throw COMException(hr);
-}
-
-#endif
-
-
- /// COM Initialisation
-
-struct ComInit
-{
-       ComInit()
-       {
-               CHECKERROR(CoInitialize(0));
-       }
-
-#if (_WIN32_WINNT>=0x0400) || defined(_WIN32_DCOM)
-       ComInit(DWORD flag)
-       {
-               CHECKERROR(CoInitializeEx(0, flag));
-       }
-#endif
-
-       ~ComInit()
-       {
-               CoUninitialize();
-       }
-};
-
-
- /// OLE initialisation for drag drop support
-
-struct OleInit
-{
-       OleInit()
-       {
-               CHECKERROR(OleInitialize(0));
-       }
-
-       ~OleInit()
-       {
-               OleUninitialize();
-       }
-};
-
-
- /// Exception Handler for COM exceptions
-
-extern void HandleException(COMException& e, HWND hwnd);
-
-
- /// wrapper class for COM interface pointers
-
-template<typename T> struct SIfacePtr
-{
-       SIfacePtr()
-        :      _p(0)
-       {
-       }
-
-       SIfacePtr(T* p)
-        :      _p(p)
-       {
-               if (p)
-                       p->AddRef();
-       }
-
-       SIfacePtr(IUnknown* unknown, REFIID riid)
-       {
-               CHECKERROR(unknown->QueryInterface(riid, (LPVOID*)&_p));
-       }
-
-       ~SIfacePtr()
-       {
-               Free();
-       }
-
-       T* operator->()
-       {
-               return _p;
-       }
-
-       const T* operator->() const
-       {
-               return _p;
-       }
-
-/* not GCC compatible
-       operator const T*() const
-       {
-               return _p;
-       } */
-
-       operator T*()
-       {
-               return _p;
-       }
-
-       T** operator&()
-       {
-               return &_p;
-       }
-
-       bool empty() const      //NOTE: GCC seems not to work correctly when defining operator bool() AND operator T*() at one time
-       {
-               return !_p;
-       }
-
-       SIfacePtr& operator=(T* p)
-       {
-               Free();
-
-               if (p) {
-                       p->AddRef();
-                       _p = p;
-               }
-
-               return *this;
-       }
-
-       void operator=(SIfacePtr const& o)
-       {
-               T* h = _p;
-
-               if (o._p)
-                       o._p->AddRef();
-
-               _p = o._p;
-
-               if (h)
-                       h->Release();
-       }
-
-       HRESULT CreateInstance(REFIID clsid, REFIID riid)
-       {
-               return CoCreateInstance(clsid, NULL, CLSCTX_INPROC_SERVER, riid, (LPVOID*)&_p);
-       }
-
-       template<typename I> HRESULT QueryInterface(REFIID riid, I* p)
-       {
-               return _p->QueryInterface(riid, (LPVOID*)p);
-       }
-
-       T* get()
-       {
-               return _p;
-       }
-
-       void Free()
-       {
-               T* h = _p;
-               _p = NULL;
-
-               if (h)
-                       h->Release();
-       }
-
-protected:
-       SIfacePtr(const SIfacePtr& o)
-        :      _p(o._p)
-       {
-               if (_p)
-                       _p->AddRef();
-       }
-
-       T* _p;
-};
diff --git a/reactos/subsys/system/ibrowser/utility/utility.cpp b/reactos/subsys/system/ibrowser/utility/utility.cpp
deleted file mode 100644 (file)
index 5ab4981..0000000
+++ /dev/null
@@ -1,419 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- // 
- // utility.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include <precomp.h>
-
-//#include <shellapi.h>
-
-#include <time.h>
-#include <sstream>
-
-
-DWORD WINAPI Thread::ThreadProc(void* para)
-{
-       Thread* pThis = (Thread*) para;
-
-       int ret = pThis->Run();
-
-       pThis->_alive = false;
-
-       return ret;
-}
-
-
-void CenterWindow(HWND hwnd)
-{
-       RECT rt, prt;
-       GetWindowRect(hwnd, &rt);
-
-       DWORD style;
-       HWND owner = 0;
-
-       for(HWND wh=hwnd; (wh=GetWindow(wh,GW_OWNER))!=0; )
-               if (((style=GetWindowStyle(wh))&WS_VISIBLE) && !(style&WS_MINIMIZE))
-                       {owner=wh; break;}
-
-       if (owner)
-               GetWindowRect(owner, &prt);
-       else
-               SystemParametersInfo(SPI_GETWORKAREA, 0, &prt, 0);      //@@ GetDesktopWindow() wäre auch hilfreich.
-
-       SetWindowPos(hwnd, 0, (prt.left+prt.right+rt.left-rt.right)/2,
-                                          (prt.top+prt.bottom+rt.top-rt.bottom)/2, 0,0, SWP_NOACTIVATE|SWP_NOSIZE|SWP_NOZORDER);
-
-       MoveVisible(hwnd);
-}
-
-void MoveVisible(HWND hwnd)
-{
-       RECT rc;
-       GetWindowRect(hwnd, &rc);
-       int left=rc.left, top=rc.top;
-
-       int xmax = GetSystemMetrics(SM_CXSCREEN);
-       int ymax = GetSystemMetrics(SM_CYSCREEN);
-
-       if (rc.left < 0)
-               rc.left = 0;
-       else if (rc.right > xmax)
-               if ((rc.left-=rc.right-xmax) < 0)
-                       rc.left = 0;
-
-       if (rc.top < 0)
-               rc.top = 0;
-       else if (rc.bottom > ymax)
-               if ((rc.top-=rc.bottom-ymax) < 0)
-                       rc.top = 0;
-
-       if (rc.left!=left || rc.top!=top)
-               SetWindowPos(hwnd, 0, rc.left,rc.top, 0,0, SWP_NOZORDER|SWP_NOSIZE|SWP_NOACTIVATE);
-}
-
-
-void display_error(HWND hwnd, DWORD error)     //@@ CONTEXT mit ausgeben -> display_error(HWND hwnd, const Exception& e)
-{
-       PTSTR msg;
-
-       if (FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER|FORMAT_MESSAGE_FROM_SYSTEM,
-               0, error, MAKELANGID(LANG_NEUTRAL,SUBLANG_DEFAULT), (PTSTR)&msg, 0, NULL)) {
-               LOG(FmtString(TEXT("display_error(%#x): %s"), error, msg));
-
-               SetLastError(0);
-               MessageBox(hwnd, msg, TEXT("ROS Explorer"), MB_OK);
-
-               if (GetLastError() == ERROR_INVALID_WINDOW_HANDLE)
-                       MessageBox(0, msg, TEXT("ROS Explorer"), MB_OK);
-       } else {
-               LOG(FmtString(TEXT("Unknown Error %#x"), error));
-
-               FmtString msg(TEXT("Unknown Error %#x"), error);
-
-               SetLastError(0);
-               MessageBox(hwnd, msg, TEXT("ROS Explorer"), MB_OK);
-
-               if (GetLastError() == ERROR_INVALID_WINDOW_HANDLE)
-                       MessageBox(0, msg, TEXT("ROS Explorer"), MB_OK);
-       }
-
-       LocalFree(msg);
-}
-
-
-Context Context::s_main("-NO-CONTEXT-");
-Context* Context::s_current = &Context::s_main;
-
-String Context::toString() const
-{
-       String str = _ctx;
-
-       if (!_obj.empty())
-               str.appendf(TEXT("\nObject: %s"), (LPCTSTR)_obj);
-
-       return str;
-}
-
-String Context::getStackTrace() const
-{
-       ostringstream str;
-
-       str << "Context Trace:\n";
-
-       for(const Context*p=this; p && p!=&s_main; p=p->_last) {
-               str << "- " << p->_ctx;
-
-               if (!p->_obj.empty())
-                       str << " obj=" << ANS(p->_obj);
-
-               str << '\n';
-       }
-
-       return str.str();
-}
-
-
-BOOL time_to_filetime(const time_t* t, FILETIME* ftime)
-{
-       struct tm* tm = gmtime(t);
-       SYSTEMTIME stime;
-
-       if (!tm)
-               return FALSE;
-
-       stime.wYear = tm->tm_year+1900;
-       stime.wMonth = tm->tm_mon+1;
-       stime.wDayOfWeek = (WORD)-1;
-       stime.wDay = tm->tm_mday;
-       stime.wHour = tm->tm_hour;
-       stime.wMinute = tm->tm_min;
-       stime.wSecond = tm->tm_sec;
-       stime.wMilliseconds = 0;
-
-       return SystemTimeToFileTime(&stime, ftime);
-}
-
-
-BOOL launch_file(HWND hwnd, LPCTSTR cmd, UINT nCmdShow, LPCTSTR parameters)
-{
-       CONTEXT("launch_file()");
-
-       HINSTANCE hinst = ShellExecute(hwnd, NULL/*operation*/, cmd, parameters, NULL/*dir*/, nCmdShow);
-
-       if ((int)hinst <= 32) {
-               display_error(hwnd, GetLastError());
-               return FALSE;
-       }
-
-       return TRUE;
-}
-
-#ifdef UNICODE
-BOOL launch_fileA(HWND hwnd, LPSTR cmd, UINT nCmdShow, LPCSTR parameters)
-{
-       HINSTANCE hinst = ShellExecuteA(hwnd, NULL/*operation*/, cmd, parameters, NULL/*dir*/, nCmdShow);
-
-       if ((int)hinst <= 32) {
-               display_error(hwnd, GetLastError());
-               return FALSE;
-       }
-
-       return TRUE;
-}
-#endif
-
-
-/* search for already running instance */
-
-static int g_foundPrevInstance = 0;
-
-static BOOL CALLBACK EnumWndProc(HWND hwnd, LPARAM lparam)
-{
-       TCHAR cls[128];
-
-       GetClassName(hwnd, cls, 128);
-
-       if (!lstrcmp(cls, (LPCTSTR)lparam)) {
-               g_foundPrevInstance++;
-               return FALSE;
-       }
-
-       return TRUE;
-}
-
-/* search for window of given class name to allow only one running instance */
-int find_window_class(LPCTSTR classname)
-{
-       EnumWindows(EnumWndProc, (LPARAM)classname);
-
-       if (g_foundPrevInstance)
-               return 1;
-
-       return 0;
-}
-
-
-typedef void (WINAPI*RUNDLLPROC)(HWND hwnd, HINSTANCE hinst, LPCTSTR cmdline, DWORD nCmdShow);
-
-BOOL RunDLL(HWND hwnd, LPCTSTR dllname, LPCSTR procname, LPCTSTR cmdline, UINT nCmdShow)
-{
-       HMODULE hmod = LoadLibrary(dllname);
-       if (!hmod)
-               return FALSE;
-
-/*TODO
-       <Windows NT/2000>
-       It is possible to create a Unicode version of the function.
-       Rundll32 first tries to find a function named EntryPointW.
-       If it cannot find this function, it tries EntryPointA, then EntryPoint.
-       To create a DLL that supports ANSI on Windows 95/98/Me and Unicode otherwise,
-       export two functions: EntryPointW and EntryPoint.
-*/
-       RUNDLLPROC proc = (RUNDLLPROC)GetProcAddress(hmod, procname);
-       if (!proc) {
-               FreeLibrary(hmod);
-               return FALSE;
-       }
-
-       proc(hwnd, hmod, cmdline, nCmdShow);
-
-       FreeLibrary(hmod);
-
-       return TRUE;
-}
-
-
-BOOL launch_cpanel(HWND hwnd, LPCTSTR applet)
-{
-       //launch_file(_hwnd, applet, SW_SHOWNORMAL);    // This would be enough, but we want the fastest solution.
-       //launch_file(_hwnd, TEXT("rundll32.exe /d shell32.dll,Control_RunDLL ")+applet, SW_SHOWNORMAL);
-
-       return RunDLL(hwnd, TEXT("shell32"), "Control_RunDLL", applet, SW_SHOWNORMAL);
-}
-
-
-BOOL RecursiveCreateDirectory(LPCTSTR path_in)
-{
-       TCHAR path[MAX_PATH], hole_path[MAX_PATH];
-
-       _tcscpy(hole_path, path_in);
-
-       int drv_len = 0;
-       LPCTSTR d;
-
-       for(d=hole_path; *d && *d!='/' && *d!='\\'; ++d) {
-               ++drv_len;
-
-               if (*d == ':')
-                       break;
-       }
-
-       LPTSTR dir = hole_path + drv_len;
-
-       int l;
-       LPTSTR p = hole_path + (l=_tcslen(hole_path));
-
-       while(--p>=hole_path && (*p=='/' || *p=='\\'))
-               *p = '\0';
-
-       WIN32_FIND_DATA w32fd;
-
-       HANDLE hFind = FindFirstFile(hole_path, &w32fd);
-
-       if (hFind == INVALID_HANDLE_VALUE) {
-               _tcsncpy(path, hole_path, drv_len);
-               int i = drv_len;
-
-               for(p=dir; *p=='/'||*p=='\\'; p++)
-                       path[i++] = *p++;
-
-               for(; i<l; i++) {
-                       memcpy(path, hole_path, i*sizeof(TCHAR));
-
-                       for(; hole_path[i] && hole_path[i]!='/' && hole_path[i]!='\\'; i++)
-                               path[i] = hole_path[i];
-
-                       path[i] = '\0';
-
-                       hFind = FindFirstFile(path, &w32fd);
-
-                       if (hFind != INVALID_HANDLE_VALUE)
-                               FindClose(hFind);
-                       else {
-                               LOG(FmtString(TEXT("CreateDirectory(\"%s\")"), path));
-
-                               if (!CreateDirectory(path, 0))
-                                       return FALSE;
-                       }
-               }
-       } else
-               FindClose(hFind);
-
-       return TRUE;
-}
-
-
-BOOL exists_path(LPCTSTR path)
-{
-       WIN32_FIND_DATA fd;
-
-       HANDLE hfind = FindFirstFile(path, &fd);
-
-       if (hfind != INVALID_HANDLE_VALUE) {
-               FindClose(hfind);
-
-               return TRUE;
-       } else
-               return FALSE;
-}
-
-
-bool SplitFileSysURL(LPCTSTR url, String& dir_out, String& fname_out)
-{
-       if (!_tcsnicmp(url, TEXT("file://"), 7)) {
-               url += 7;
-
-                // remove third slash in front of drive characters
-               if (*url == '/')
-                       ++url;
-       }
-
-       if (exists_path(url)) {
-               TCHAR path[_MAX_PATH];
-
-                // convert slashes to back slashes
-               GetFullPathName(url, _MAX_PATH, path, NULL);
-
-               if (GetFileAttributes(path) & FILE_ATTRIBUTE_DIRECTORY)
-                       fname_out.erase();
-               else {
-                       TCHAR drv[_MAX_DRIVE], dir[_MAX_DIR], fname[_MAX_FNAME], ext[_MAX_EXT];
-
-                       _tsplitpath(path, drv, dir, fname, ext);
-                       _stprintf(path, TEXT("%s%s"), drv, dir);
-
-                       fname_out.printf(TEXT("%s%s"), fname, ext);
-               }
-
-               dir_out = path;
-
-               return true;
-       } else
-               return false;
-}
-
-
- /// Exception Handler for COM exceptions
-
-void HandleException(COMException& e, HWND hwnd)
-{
-       String msg = e.toString();
-
-       SetLastError(0);
-
-       if (hwnd && !IsWindowVisible(hwnd))
-               hwnd = 0;
-
-       MessageBox(hwnd, msg, TEXT("ShellClasses Exception"), MB_ICONHAND|MB_OK);
-
-        // If displaying the error message box _with_ parent was not successfull, display it now without a parent window.
-       if (GetLastError() == ERROR_INVALID_WINDOW_HANDLE)
-               MessageBox(0, msg, TEXT("ShellClasses Exception"), MB_ICONHAND|MB_OK);
-}
-
-
-String COMException::toString() const
-{
-       TCHAR msg[4*BUFFER_LEN];
-       LPTSTR p = msg;
-
-       p += _stprintf(p, TEXT("%s\nContext: %s"), super::ErrorMessage(), (LPCTSTR)_context.toString());
-
-       if (_file)
-               p += _stprintf(p, TEXT("\nLocation: %hs:%d"), _file, _line);
-
-       return msg;
-}
diff --git a/reactos/subsys/system/ibrowser/utility/utility.h b/reactos/subsys/system/ibrowser/utility/utility.h
deleted file mode 100644 (file)
index 56f7fae..0000000
+++ /dev/null
@@ -1,1022 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // Explorer clone
- //
- // utility.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
- // standard windows headers
-#define WIN32_LEAN_AND_MEAN
-#define WIN32_EXTRA_LEAN
-#include <windows.h>
-
- // Unicode support
-#ifdef UNICODE
-#define        _UNICODE
-#endif
-#include <tchar.h>
-
-#include <windowsx.h>  // for SelectBrush(), ListBox_SetSel(), SubclassWindow(), ...
-#include <commctrl.h>
-
-#ifndef _MSC_VER
-#include <objbase.h>
-#endif
-#include <oleauto.h>   // for VARIANT
-
-#include <malloc.h>            // for alloca()
-#include <assert.h>
-#include <stdlib.h>            // for _MAX_DIR, ...
-#include <stdio.h>             // for sprintf()
-#include <time.h>
-
-#ifndef _MAX_PATH
-#define _MAX_DRIVE     3
-#define _MAX_FNAME     256
-#define _MAX_DIR       _MAX_FNAME
-#define _MAX_EXT       _MAX_FNAME
-#define _MAX_PATH      260
-#endif
-
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-#define        for if (0) {} else for
-
-#define        COUNTOF(x)      (sizeof(x)/sizeof(x[0]))
-
-
-#define        BUFFER_LEN                              2048
-
-
-#define        LOG(txt)
-
-
-#ifndef _tcsrchr
-#ifdef UNICODE
-#define        _tcsrchr wcsrchr
-#else
-#define        _tcsrchr strrchr
-#endif
-#endif
-
-#ifndef _stprintf
-#ifdef UNICODE
-#define        _stprintf wcsprintf
-#else
-#define        _stprintf sprintf
-#endif
-#endif
-
-#define        U2A(s, d, l) WideCharToMultiByte(CP_ACP, 0, s, -1, d, l, NULL, NULL)
-#define        U2nA(s, d, l) WideCharToMultiByte(CP_ACP, 0, s, l, d, l, NULL, NULL)
-#define        A2U(s, d, l) MultiByteToWideChar(CP_ACP, 0, s, -1, d, l)
-#define        A2nU(s, d, l) MultiByteToWideChar(CP_ACP, 0, s, l, d, l)
-
-
-#ifdef __WINE__
-#ifdef UNICODE
-extern void _wsplitpath(const WCHAR* path, WCHAR* drv, WCHAR* dir, WCHAR* name, WCHAR* ext);
-#else
-extern void _splitpath(const CHAR* path, CHAR* drv, CHAR* dir, CHAR* name, CHAR* ext);
-#endif
-#define        _tcsnicmp strncasecmp
-#define        _tcsicoll strcasecmp
-#endif
-
-#ifndef FILE_ATTRIBUTE_NOT_CONTENT_INDEXED
-#define FILE_ATTRIBUTE_ENCRYPTED            0x00000040
-#define FILE_ATTRIBUTE_SPARSE_FILE          0x00000200
-#define FILE_ATTRIBUTE_REPARSE_POINT        0x00000400
-#define FILE_ATTRIBUTE_NOT_CONTENT_INDEXED  0x00002000
-#endif
-
-
-#define        SetDlgCtrlID(hwnd, id) SetWindowLong(hwnd, GWL_ID, id)
-#define        SetWindowStyle(hwnd, val) (DWORD)SetWindowLong(hwnd, GWL_STYLE, val)
-#define        SetWindowExStyle(h, val) (DWORD)SetWindowLong(hwnd, GWL_EXSTYLE, val)
-#define        Window_SetIcon(hwnd, type, hicon) (HICON)SendMessage(hwnd, WM_SETICON, type, (LPARAM)(hicon))
-
-
- // center window in respect to its parent window
-extern void CenterWindow(HWND hwnd);
-
- // move window into visibility
-extern void MoveVisible(HWND hwnd);
-
- // display error message
-extern void display_error(HWND hwnd, DWORD error);
-
- // convert time_t to WIN32 FILETIME
-extern BOOL time_to_filetime(const time_t* t, FILETIME* ftime);
-
- // search for windows of a specific classname
-extern int find_window_class(LPCTSTR classname);
-
- // create a directory with all missing parent directories
-BOOL RecursiveCreateDirectory(LPCTSTR path_in);
-
- // test for existing directory
-BOOL exists_path(LPCTSTR path);
-
-
-#ifdef __cplusplus
-} // extern "C"
-#endif
-
-
-#ifdef __cplusplus
-
-#ifdef _MSC_VER
-#pragma warning(disable: 4786) // disable warnings about too long debug information symbols
-#endif
-
- // STL headers for strings and streams
-#include <string>
-#include <iostream>
-using namespace std;
-
- // containers
-#include <map>
-#include <set>
-#include <list>
-#include <stack>
-#include <vector>
-
-
-#if _MSC_VER>=1300     // VS.Net
-#define _NO_COMUTIL    //@@
-#endif
-
-#if defined(_MSC_VER) && !defined(_NO_COMUTIL)
-
- // COM utility headers
-#include <comdef.h>
-using namespace _com_util;
-
-#endif // _MSC_VER && !_NO_COMUTIL
-
-
- // launch a program or document file
-extern BOOL launch_file(HWND hwnd, LPCTSTR cmd, UINT nCmdShow=SW_SHOWNORMAL, LPCTSTR parameters=NULL);
-#ifdef UNICODE
-extern BOOL launch_fileA(HWND hwnd, LPSTR cmd, UINT nCmdShow=SW_SHOWNORMAL, LPCSTR parameters=NULL);
-#else
-#define        launch_fileA launch_file
-#endif
-
- // call an DLL export like rundll32
-extern BOOL RunDLL(HWND hwnd, LPCTSTR dllname, LPCSTR procname, LPCTSTR cmdline, UINT nCmdShow);
-
- // launch control panel applet
-extern BOOL launch_cpanel(HWND hwnd, LPCTSTR applet);
-
-
- /// initialization of windows common controls
-struct CommonControlInit
-{
-       CommonControlInit(DWORD flags=ICC_LISTVIEW_CLASSES|ICC_TREEVIEW_CLASSES|ICC_BAR_CLASSES|ICC_PROGRESS_CLASS|ICC_COOL_CLASSES)
-       {
-               INITCOMMONCONTROLSEX icc = {sizeof(INITCOMMONCONTROLSEX), flags};
-
-               InitCommonControlsEx(&icc);
-       }
-};
-
-
- /// wait cursor
-
-struct WaitCursor      ///@todo integrate with WM_SETCURSOR to enable multithreaded background tasks as program launching
-{
-       WaitCursor()
-       {
-               _old_cursor = SetCursor(LoadCursor(0, IDC_WAIT));
-       }
-
-       ~WaitCursor()
-       {
-               SetCursor(_old_cursor);
-       }
-
-protected:
-       HCURSOR _old_cursor;
-};
-
-
- /// base of all structures storing a window handle
-struct WindowHandle
-{
-       WindowHandle(HWND hwnd=0)
-        :      _hwnd(hwnd) {}
-
-       operator HWND() const {return _hwnd;}
-       HWND* operator&() {return &_hwnd;}
-
-protected:
-       HWND    _hwnd;
-};
-
-
- /// locally hide a window
-struct HiddenWindow : public WindowHandle
-{
-       HiddenWindow(HWND hwnd)
-        :      WindowHandle(IsWindowVisible(hwnd)? hwnd: 0)
-       {
-               if (_hwnd)
-                       SetWindowPos(_hwnd, 0, 0, 0, 0, 0, SWP_HIDEWINDOW|SWP_NOREDRAW|SWP_NOMOVE|SWP_NOSIZE|SWP_NOZORDER);
-       }
-
-       ~HiddenWindow()
-       {
-               if (_hwnd)
-                       SetWindowPos(_hwnd, 0, 0, 0, 0, 0, SWP_SHOWWINDOW|SWP_NOMOVE|SWP_NOSIZE|SWP_NOZORDER);
-       }
-};
-
-
- /// critical section wrapper
-
-struct CritSect : public CRITICAL_SECTION
-{
-       CritSect()
-       {
-               InitializeCriticalSection(this);
-       }
-
-       ~CritSect()
-       {
-               DeleteCriticalSection(this);
-       }
-};
-
-
- /// Lock protects a code section utilizing a critical section
-
-struct Lock
-{
-       Lock(CritSect& crit_sect)
-        :      _crit_sect(crit_sect)
-       {
-               EnterCriticalSection(&crit_sect);
-       }
-
-       ~Lock()
-       {
-               LeaveCriticalSection(&_crit_sect);
-       }
-
-protected:
-       CritSect&       _crit_sect;
-};
-
-
- /// Thread base class
-
-struct Thread
-{
-       Thread()
-        :      _alive(false),
-               _destroy(false)
-       {
-               _hThread = INVALID_HANDLE_VALUE;
-               _evtFinish = CreateEvent(NULL, TRUE, FALSE, NULL);
-       }
-
-       virtual ~Thread()
-       {
-               Stop();
-
-               CloseHandle(_evtFinish);
-               CloseHandle(_hThread);
-
-               if (_destroy)
-                       delete this;
-       }
-
-       void Start()
-       {
-               if (!_alive) {
-                       _alive = true;
-                       _hThread = CreateThread(NULL, 0, ThreadProc, this, 0, NULL);
-               }
-       }
-
-       void Stop()
-       {
-               SetEvent(_evtFinish);
-
-               if (_alive) {
-                       {
-                       Lock lock(_crit_sect);
-                       _alive = false;
-                       }
-
-                        // wait for finishing
-                       WaitForSingleObject(_hThread, INFINITE);
-               }
-       }
-
-       virtual int Run() = 0;
-
-       bool    is_alive() const {return _alive;}
-
-       CritSect _crit_sect;
-
-protected:
-       static DWORD WINAPI ThreadProc(void* para);
-
-       HANDLE  _hThread;
-       HANDLE  _evtFinish;
-       bool    _alive;
-       bool    _destroy;
-};
-
-
- // window utilities
-
- /// ClientRect retreives the client area rectangle of a window.
-struct ClientRect : public RECT
-{
-       ClientRect(HWND hwnd)
-       {
-               GetClientRect(hwnd, this);
-       }
-
-       operator LPRECT() {return this;}
-
-       POINT& pos() {return *(LPPOINT)this;}
-};
-
- /// ClientRect retreives the window rectangle of a window.
-struct WindowRect : public RECT
-{
-       WindowRect(HWND hwnd)
-       {
-               GetWindowRect(hwnd, this);
-       }
-
-       operator LPRECT() {return this;}
-
-       POINT& pos() {return *(LPPOINT)this;}
-};
-
- /// PointL encapsulates the POINT structure into a C++ object.
-struct Point : public POINT
-{
-       Point(LONG x_, LONG y_)
-       {
-               x = x_;
-               y = y_;
-       }
-
-        // constructor for being used in processing WM_MOUSEMOVE, WM_LBUTTONDOWN, ... messages
-       Point(LPARAM lparam)
-       {
-               x = GET_X_LPARAM(lparam);
-               y = GET_Y_LPARAM(lparam);
-       }
-
-       operator LPPOINT() {return this;}
-};
-
-
- /// transform coordinates in a RECT from client to screen coordiantes
-inline void ClientToScreen(HWND hwnd, RECT* prect)
- {::ClientToScreen(hwnd,(LPPOINT)&prect->left); ::ClientToScreen(hwnd,(LPPOINT)&prect->right);}
-
- /// transform coordinates in a RECT from screen to client coordiantes
-inline void ScreenToClient(HWND hwnd, RECT* prect)
- {::ScreenToClient(hwnd,(LPPOINT)&prect->left); ::ScreenToClient(hwnd,(LPPOINT)&prect->right);}
-
-
- /// structure containing information about full screen display of the frame window
-struct FullScreenParameters
-{
-       FullScreenParameters()
-        :      _mode(FALSE)
-       {
-       }
-
-       BOOL    _mode;
-       RECT    _orgPos;
-       BOOL    _wasZoomed;
-};
-
-
- // drawing utilities
-
- /// PaintCanvas is a encapsulation of device contexts managed by BeginPaint()/EndPaint().
-struct PaintCanvas : public PAINTSTRUCT
-{
-       PaintCanvas(HWND hwnd)
-        :      _hwnd(hwnd)
-       {
-               BeginPaint(hwnd, this);
-       }
-
-       ~PaintCanvas()
-       {
-               EndPaint(_hwnd, this);
-       }
-
-       operator HDC() const {return hdc;}
-
-protected:
-       HWND    _hwnd;
-};
-
- /// Canvas is a encapsulation of device contexts.
-struct Canvas
-{
-       Canvas(HDC hdc) : _hdc(hdc) {}
-
-       operator HDC() {return _hdc;}
-
-protected:
-       HDC _hdc;
-};
-
- /// WindowCanvas is a encapsulation of client area device contexts.
-struct WindowCanvas : public Canvas
-{
-       WindowCanvas(HWND hwnd)
-        :      Canvas(GetDC(hwnd)), _hwnd(hwnd) {}
-
-       ~WindowCanvas() {ReleaseDC(_hwnd, _hdc);}
-
-protected:
-       HWND    _hwnd;
-};
-
-
- // double buffering classes
-
- /// Memory Canvas creates and destroys memory devoce contexts.
-struct MemCanvas : public Canvas
-{
-       MemCanvas(HDC hdc=0)
-        :      Canvas(CreateCompatibleDC(hdc)) {assert(_hdc);}
-
-       ~MemCanvas() {DeleteDC(_hdc);}
-};
-
- /// SelectedBitmap is used to localy select bitmaps into device contexts.
-struct SelectedBitmap
-{
-       SelectedBitmap(HDC hdc, HBITMAP hbmp)
-        :      _hdc(hdc), _old_hbmp(SelectBitmap(hdc, hbmp)) {}
-
-       ~SelectedBitmap() {DeleteObject(SelectBitmap(_hdc, _old_hbmp));}
-
-protected:
-       HDC             _hdc;
-       HBITMAP _old_hbmp;
-};
-
- /// BufferCanvas manages offscreen bitmaps selected into memory device contexts.
-struct BufferCanvas : public MemCanvas
-{
-       BufferCanvas(HDC hdc, int x, int y, int w, int h)
-        :      MemCanvas(hdc), _hdctarg(hdc),
-               _x(x), _y(y), _w(w), _h(h),
-               _bmp(_hdc, CreateCompatibleBitmap(hdc, w, h)) {}
-
-       BufferCanvas(HDC hdc, const RECT& rect)
-        :      MemCanvas(hdc), _hdctarg(hdc),
-               _x(rect.left), _y(rect.top), _w(rect.right-rect.left), _h(rect.bottom-rect.top),
-               _bmp(_hdc, CreateCompatibleBitmap(hdc, _w, _h)) {}
-
-protected:
-       HDC     _hdctarg;
-       int     _x, _y, _w, _h;
-       SelectedBitmap _bmp;
-};
-
- /// BufferedCanvas enables double buffering for a device context.
-struct BufferedCanvas : public BufferCanvas
-{
-       BufferedCanvas(HDC hdc, int x, int y, int w, int h, DWORD mode=SRCCOPY)
-        :      BufferCanvas(hdc, x, y, w, h), _mode(mode) {}
-
-       BufferedCanvas(HDC hdc, const RECT& rect, DWORD mode=SRCCOPY)
-        :      BufferCanvas(hdc, rect), _mode(mode) {}
-
-       ~BufferedCanvas() {BitBlt(_hdctarg, _x, _y, _w, _h, _hdc, 0, 0, _mode);}
-
-       DWORD   _mode;
-};
-
- /// BufferedPaintCanvas extends PaintCanvas for double buffering.
-struct BufferedPaintCanvas : public PaintCanvas, public BufferedCanvas
-{
-       BufferedPaintCanvas(HWND hwnd)
-        :      PaintCanvas(hwnd),
-               BufferedCanvas(PAINTSTRUCT::hdc, 0, 0, rcPaint.right, rcPaint.bottom)
-       {
-       }
-
-       operator HDC() {return BufferedCanvas::_hdc;}
-};
-
-
- /// TextColor locally selects a text color for drawing.
-struct TextColor
-{
-       TextColor(HDC hdc, COLORREF color)
-        : _hdc(hdc), _old_color(SetTextColor(hdc, color)) {}
-
-       ~TextColor() {SetTextColor(_hdc, _old_color);}
-
-protected:
-       HDC              _hdc;
-       COLORREF _old_color;
-};
-
- /// BkMode locally sets the background mode for drawing.
-struct BkMode
-{
-       BkMode(HDC hdc, int bkmode)
-        : _hdc(hdc), _old_bkmode(SetBkMode(hdc, bkmode)) {}
-
-       ~BkMode() {SetBkMode(_hdc, _old_bkmode);}
-
-protected:
-       HDC              _hdc;
-       COLORREF _old_bkmode;
-};
-
- /// FontSelection locally selects a font for drawing.
-struct FontSelection
-{
-       FontSelection(HDC hdc, HFONT hFont)
-        : _hdc(hdc), _old_hFont(SelectFont(hdc, hFont)) {}
-
-       ~FontSelection() {SelectFont(_hdc, _old_hFont);}
-
-protected:
-       HDC             _hdc;
-       HFONT   _old_hFont;
-};
-
- /// BitmapSelection locally selects a bitmap into a device context.
-struct BitmapSelection
-{
-       BitmapSelection(HDC hdc, HBITMAP hBmp)
-        : _hdc(hdc), _old_hBmp(SelectBitmap(hdc, hBmp)) {}
-
-       ~BitmapSelection() {SelectBitmap(_hdc, _old_hBmp);}
-
-protected:
-       HDC             _hdc;
-       HBITMAP _old_hBmp;
-};
-
- /// BrushSelection locally selects a brush into a device context.
-struct BrushSelection
-{
-       BrushSelection(HDC hdc, HBRUSH hBrush)
-        : _hdc(hdc), _old_hBrush(SelectBrush(hdc, hBrush)) {}
-
-       ~BrushSelection() {SelectBrush(_hdc, _old_hBrush);}
-
-protected:
-       HDC             _hdc;
-       HBRUSH  _old_hBrush;
-};
-
-
- /// Popup Menus
-struct PopupMenu
-{
-       PopupMenu()
-        :      _hmenu(CreatePopupMenu())
-       {
-       }
-
-       PopupMenu(UINT nid);
-
-       operator HMENU() {return _hmenu;}
-
-       void Append(UINT id, LPCTSTR str, UINT flags=MF_STRING)
-       {
-               AppendMenu(_hmenu, flags, id, str);
-       }
-
-       int TrackPopupMenu(HWND hwnd, const POINT& pt, UINT flags=TPM_LEFTBUTTON|TPM_RIGHTBUTTON, LPTPMPARAMS tpm=NULL) {
-        return TrackPopupMenuEx(_hmenu, flags, pt.x, pt.y, hwnd, tpm);
-       }
-
-       int PopupContextMenu(HWND hwnd, POINTS pos, UINT flags=TPM_LEFTBUTTON|TPM_RIGHTBUTTON) {
-        POINT pt; POINTSTOPOINT(pt, pos);
-        return TrackPopupMenuEx(_hmenu, flags, pt.x, pt.y, hwnd, NULL);
-       }
-
-       int TrackPopupMenu(HWND hwnd, POINTS pos, UINT flags=TPM_LEFTBUTTON|TPM_RIGHTBUTTON) {
-        POINT pt; POINTSTOPOINT(pt, pos);
-        ClientToScreen(hwnd, &pt);
-        return TrackPopupMenuEx(_hmenu, flags, pt.x, pt.y, hwnd, NULL);
-       }
-
-       int TrackPopupMenuAtCursor(HWND hwnd, UINT flags=TPM_LEFTBUTTON) {
-        POINT pt; GetCursorPos(&pt);
-        return TrackPopupMenuEx(_hmenu, flags, pt.x, pt.y, hwnd, NULL);
-       }
-
-       int TrackPopupMenuAtPos(HWND hwnd, DWORD pos, UINT flags=TPM_LEFTBUTTON) {
-        return TrackPopupMenuEx(_hmenu, flags, GET_X_LPARAM(pos), GET_Y_LPARAM(pos), hwnd, NULL);
-       }
-
-protected:
-       HMENU _hmenu;
-};
-
-
-struct Variant : public VARIANT
-{
-       Variant() {VariantInit(this);}
-       Variant(const VARIANT& var);
-       Variant(const VARIANT* var);
-       ~Variant();
-
-       operator long() const;
-       operator bool() const;
-       operator VARIANT_BOOL() const;
-       operator IDispatch*() const;
-};
-
-
-struct BStr
-{
-       BStr()
-       {
-               _p = NULL;
-       }
-
-       BStr(const BSTR s)
-       {
-               _p = SysAllocString(s);
-       }
-
-       BStr(LPCSTR s)
-       {
-               WCHAR b[BUFFER_LEN];
-
-               if (s)
-                       _p = SysAllocStringLen(b, MultiByteToWideChar(CP_ACP, 0, s, -1, b, BUFFER_LEN)-1);
-               else
-                       _p = NULL;
-       }
-
-       BStr(LPCWSTR s)
-       {
-               _p = SysAllocString(s);
-       }
-
-       BStr(const VARIANT& var)
-        :      _p(NULL)
-       {
-               assign(var);
-       }
-
-       ~BStr()
-       {
-               SysFreeString(_p);
-       }
-
-       void assign(BSTR s);
-       void assign(const VARIANT& var);
-
-       operator BSTR() const
-       {
-               return _p? _p: (BSTR)L"";
-       }
-
-       int length() const
-       {
-               return _p? wcslen(_p): 0;
-       }
-
-protected:
-       BSTR    _p;
-};
-
-
- /// string class for TCHAR strings
-struct String
-#ifdef UNICODE
- : public wstring
-#else
- : public string
-#endif
-{
-#ifdef UNICODE
-       typedef wstring super;
-#else
-       typedef string super;
-#endif
-
-       String() {}
-
-       String(LPCTSTR s) {if (s) super::assign(s);}
-       String(LPCTSTR s, int l) : super(s, l) {}
-
-       String(const super& other) : super(other) {}
-       String(const String& other) : super(other) {}
-
-#ifdef UNICODE
-       String(LPCSTR s) {assign(s);}
-       String(LPCSTR s, int l) {assign(s, l);}
-       String(const string& other) {assign(other.c_str());}
-       String& operator=(LPCSTR s) {assign(s); return *this;}
-       void assign(LPCSTR s) {if (s) {TCHAR b[BUFFER_LEN]; super::assign(b, MultiByteToWideChar(CP_ACP, 0, s, -1, b, BUFFER_LEN)-1);} else erase();}
-       void assign(LPCSTR s, int l) {if (s) {TCHAR b[BUFFER_LEN]; super::assign(b, MultiByteToWideChar(CP_ACP, 0, s, l, b, BUFFER_LEN));} else erase();}
-       void assign(const BStr& s) {int l = s.length(); super::assign(s, l);}
-#else
-       String(LPCWSTR s) {assign(s);}
-       String(LPCWSTR s, int l) {assign(s, l);}
-       String(const wstring& other) {assign(other.c_str());}
-       String& operator=(LPCWSTR s) {assign(s); return *this;}
-       void assign(LPCWSTR s) {if (s) {char b[BUFFER_LEN]; super::assign(b, WideCharToMultiByte(CP_ACP, 0, s, -1, b, BUFFER_LEN, 0, 0)-1);} else erase();}
-       void assign(LPCWSTR s, int l) {if (s) {char b[BUFFER_LEN]; super::assign(b, WideCharToMultiByte(CP_ACP, 0, s, l, b, BUFFER_LEN, 0, 0));} else erase();}
-       void assign(const BStr& s) {int l = s.length(); if (l) {char b[BUFFER_LEN]; super::assign(b, WideCharToMultiByte(CP_ACP, 0, s, l, b, BUFFER_LEN, 0, 0));} else erase();}
-#endif
-       String(const BStr& s) {assign(s);}
-       String& operator=(const BStr& s) {assign(s); return *this;}
-
-       String& operator=(LPCTSTR s) {if (s) super::assign(s); else erase(); return *this;}
-       String& operator=(const super& s) {super::assign(s); return *this;}
-       void assign(LPCTSTR s) {super::assign(s);}
-       void assign(LPCTSTR s, int l) {super::assign(s, l);}
-
-       operator LPCTSTR() const {return c_str();}
-
-#ifdef UNICODE
-       operator string() const {char b[BUFFER_LEN]; return string(b, WideCharToMultiByte(CP_ACP, 0, c_str(), -1, b, BUFFER_LEN, 0, 0)-1);}
-#else
-       operator wstring() const {WCHAR b[BUFFER_LEN]; return wstring(b, MultiByteToWideChar(CP_ACP, 0, c_str(), -1, b, BUFFER_LEN)-1);}
-#endif
-
-       String& printf(LPCTSTR fmt, ...)
-       {
-               va_list l;
-               TCHAR b[BUFFER_LEN];
-
-               va_start(l, fmt);
-               super::assign(b, _vstprintf(b, fmt, l));
-               va_end(l);
-
-               return *this;
-       }
-
-       String& vprintf(LPCTSTR fmt, va_list l)
-       {
-               TCHAR b[BUFFER_LEN];
-
-               super::assign(b, _vstprintf(b, fmt, l));
-
-               return *this;
-       }
-
-       String& appendf(LPCTSTR fmt, ...)
-       {
-               va_list l;
-               TCHAR b[BUFFER_LEN];
-
-               va_start(l, fmt);
-               super::append(b, _vstprintf(b, fmt, l));
-               va_end(l);
-
-               return *this;
-       }
-
-       String& vappendf(LPCTSTR fmt, va_list l)
-       {
-               TCHAR b[BUFFER_LEN];
-
-               super::append(b, _vstprintf(b, fmt, l));
-
-               return *this;
-       }
-};
-
-#define        _STRING_DEFINED
-
-
-struct FmtString : public String
-{
-       FmtString(LPCTSTR fmt, ...)
-       {
-               va_list l;
-
-               va_start(l, fmt);
-               vprintf(fmt, l);
-               va_end(l);
-       }
-};
-
-
-#ifdef UNICODE
-
-struct ANS
-{
-       ANS(LPCWSTR s)
-       {
-               int l = wcslen(s) + 1;
-               _str = (LPSTR) malloc(2*l);
-
-               if (WideCharToMultiByte(CP_ACP, 0, s, -1, _str, 2*l, 0, 0) <= 0)
-                       *_str = '\0';
-       }
-
-       ~ANS()
-       {
-               free(_str);
-       }
-
-       operator LPCSTR() {return _str;}
-
-protected:
-       LPSTR   _str;
-};
-
-#define        UNC(x) ((LPCWSTR)(x))
-
-#else
-
-#define        ANS(x) ((LPCSTR)(x))
-
-struct UNC
-{
-       UNC(LPCSTR s)
-       {
-               int l = strlen(s) + 1;
-               _str = (LPWSTR) malloc(2*l);
-
-               if (MultiByteToWideChar(CP_ACP, 0, s, -1, _str, l) <= 0)
-                       *_str = '\0';
-       }
-
-       ~UNC()
-       {
-               free(_str);
-       }
-
-       operator LPCWSTR() {return _str;}
-
-protected:
-       LPWSTR  _str;
-};
-
-#endif
-
-
- // determine windows version string
-//@@String get_windows_version_str();
-
-
- /// link dynamicly to functions by using GetModuleHandle() and GetProcAddress()
-template<typename FCT> struct DynamicFct
-{
-       DynamicFct(LPCTSTR moduleName, UINT ordinal)
-       {
-               HMODULE hModule = GetModuleHandle(moduleName);
-
-               _fct = (FCT) GetProcAddress(hModule, (LPCSTR)ordinal);
-       }
-
-       DynamicFct(LPCTSTR moduleName, LPCSTR name)
-       {
-               HMODULE hModule = GetModuleHandle(moduleName);
-
-               _fct = (FCT) GetProcAddress(hModule, name);
-       }
-
-       FCT operator*() const {return _fct;}
-       operator bool() const {return _fct? true: false;}
-
-protected:
-       FCT     _fct;
-};
-
-
- /// link dynamicly to functions by using LoadLibrary() and GetProcAddress()
-template<typename FCT> struct DynamicLoadLibFct
-{
-       DynamicLoadLibFct(LPCTSTR moduleName, UINT ordinal)
-       {
-               _hModule = LoadLibrary(moduleName);
-
-               _fct = (FCT) GetProcAddress(_hModule, (LPCSTR)ordinal);
-       }
-
-       DynamicLoadLibFct(LPCTSTR moduleName, LPCSTR name)
-       {
-               _hModule = LoadLibrary(moduleName);
-
-               _fct = (FCT) GetProcAddress(_hModule, name);
-       }
-
-       ~DynamicLoadLibFct()
-       {
-               FreeLibrary(_hModule);
-       }
-
-       FCT operator*() const {return _fct;}
-       operator bool() const {return _fct? true: false;}
-
-protected:
-       HMODULE _hModule;
-       FCT     _fct;
-};
-
-
-struct Context
-{
-       Context(const char* ctx)
-        :      _ctx(ctx)
-       {
-               _last = s_current;
-               s_current = this;
-       }
-
-       Context(const char* ctx, LPCSTR obj)
-        :      _ctx(ctx),
-               _obj(obj)
-       {
-               _last = s_current;
-               s_current = this;
-       }
-
-       Context(const char* ctx, LPCWSTR obj)
-        :      _ctx(ctx),
-               _obj(obj)
-       {
-               _last = s_current;
-               s_current = this;
-       }
-
-       Context(const Context& other)
-        :      _ctx(other._ctx),
-               _obj(other._obj)
-       {
-               _last = NULL;
-       }
-
-       ~Context()
-       {
-               if (_last) {
-                       s_current = _last;
-                       _last = NULL;
-               }
-       }
-
-       String toString() const;
-       String getStackTrace() const;
-
-       const char* _ctx;
-       String  _obj;
-
-       static Context& current() {return *s_current;}
-
-protected:
-       Context* _last;
-
-       static Context* s_current;      ///@todo use TLS
-       static Context  s_main;
-};
-
-#define        CONTEXT_OBJ __ctx__._obj
-#define        CONTEXT(c) Context __ctx__(c)
-#define        CURRENT_CONTEXT Context::current()
-#define        OBJ_CONTEXT(c, o) Context __ctx__(c, o)
-
-
-extern bool SplitFileSysURL(LPCTSTR url, String& dir_out, String& fname_out);
-
-
-#endif // __cplusplus
diff --git a/reactos/subsys/system/ibrowser/utility/window.cpp b/reactos/subsys/system/ibrowser/utility/window.cpp
deleted file mode 100644 (file)
index 3d23a32..0000000
+++ /dev/null
@@ -1,1206 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // ROS Internet Web Browser
- //
- // window.cpp
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-#include <precomp.h>
-
-#include "../ibrowser_intres.h"        // for ID_GO_BACK, ...
-
-
-WindowClass::WindowClass(LPCTSTR classname, UINT style_, WNDPROC wndproc)
-{
-       memset(this, 0, sizeof(WNDCLASSEX));
-
-       cbSize = sizeof(WNDCLASSEX);
-       style = style_;
-       hInstance = g_hInstance;
-       hCursor = LoadCursor(0, IDC_ARROW);
-
-       lpszClassName = classname;
-       lpfnWndProc = wndproc;
-
-       _atomClass = 0;
-}
-
-
-IconWindowClass::IconWindowClass(LPCTSTR classname, UINT nid, UINT style, WNDPROC wndproc)
- :     WindowClass(classname, style, wndproc)
-{
-       hIcon = ResIcon(nid);
-       hIconSm = SmallIcon(nid);
-}
-
-
-Window::WindowMap      Window::s_wnd_map;
-
-Window::CREATORFUNC    Window::s_window_creator = NULL;
-const void*                    Window::s_new_info = NULL;
-
-
-Window::StaticWindowData& Window::GetStaticWindowData()
-{
-       static StaticWindowData s_initialized_data;
-
-       return s_initialized_data;
-}
-
-
-Window::Window(HWND hwnd)
- :     WindowHandle(hwnd)
-{
-       Lock lock(GetStaticWindowData()._map_crit_sect);        // protect access to s_wnd_map
-
-       s_wnd_map[_hwnd] = this;
-}
-
-Window::~Window()
-{
-       Lock lock(GetStaticWindowData()._map_crit_sect);        // protect access to s_wnd_map
-
-       s_wnd_map.erase(_hwnd);
-}
-
-
-HWND Window::Create(CREATORFUNC creator, DWORD dwExStyle,
-                                       LPCTSTR lpClassName, LPCTSTR lpWindowName,
-                                       DWORD dwStyle, int x, int y, int w, int h,
-                                       HWND hwndParent, HMENU hMenu/*, LPVOID lpParam*/)
-{
-       Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-       s_window_creator = creator;
-       s_new_info = NULL;
-
-       return CreateWindowEx(dwExStyle, lpClassName, lpWindowName, dwStyle,
-                                                       x, y, w, h,
-                                                       hwndParent, hMenu, g_hInstance, 0/*lpParam*/);
-}
-
-HWND Window::Create(CREATORFUNC_INFO creator, const void* info, DWORD dwExStyle,
-                                       LPCTSTR lpClassName, LPCTSTR lpWindowName,
-                                       DWORD dwStyle, int x, int y, int w, int h,
-                                       HWND hwndParent, HMENU hMenu/*, LPVOID lpParam*/)
-{
-       Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-       s_window_creator = (CREATORFUNC) creator;
-       s_new_info = info;
-
-       return CreateWindowEx(dwExStyle, lpClassName, lpWindowName, dwStyle,
-                                                       x, y, w, h,
-                                                       hwndParent, hMenu, g_hInstance, 0/*lpParam*/);
-}
-
-
- /// get window controller from window handle
-
-Window* Window::get_window(HWND hwnd)
-{
-       {
-               Lock lock(GetStaticWindowData()._map_crit_sect);        // protect access to s_wnd_map
-
-               WindowMap::const_iterator found = s_wnd_map.find(hwnd);
-
-               if (found!=s_wnd_map.end())
-                       return found->second;
-       }
-
-       return NULL;
-}
-
-
- /// create controller for a new window
-
-Window* Window::create_controller(HWND hwnd)
-{
-       if (s_window_creator) { // protect for recursion and create the window object only for the first window
-               Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-               const void* info = s_new_info;
-               s_new_info = NULL;
-
-               CREATORFUNC window_creator = s_window_creator;
-               s_window_creator = NULL;
-
-               if (info)
-                       return CREATORFUNC_INFO(window_creator)(hwnd, info);
-               else
-                       return CREATORFUNC(window_creator)(hwnd);
-       }
-
-       return NULL;
-}
-
-
-LRESULT Window::Init(LPCREATESTRUCT pcs)
-{
-       return 0;
-}
-
-
-LRESULT CALLBACK Window::WindowWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       Window* pThis = get_window(hwnd);
-
-       if (!pThis)
-               pThis = create_controller(hwnd);
-
-       if (pThis) {
-               switch(nmsg) {
-                 case WM_COMMAND:
-                       return pThis->Command(LOWORD(wparam), HIWORD(wparam));
-
-                 case WM_NOTIFY:
-                       return pThis->Notify(wparam, (NMHDR*)lparam);
-
-                 case WM_NOTIFYFORMAT:
-                       return NFR_CURRENT;
-
-                 case WM_CREATE:
-                       return pThis->Init((LPCREATESTRUCT)lparam);
-
-                 case WM_NCDESTROY:
-                       delete pThis;
-                       return 0;
-
-                 default:
-                       return pThis->WndProc(nmsg, wparam, lparam);
-               }
-       }
-       else
-               return DefWindowProc(hwnd, nmsg, wparam, lparam);
-}
-
-LRESULT Window::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       return DefWindowProc(_hwnd, nmsg, wparam, lparam);
-}
-
-int Window::Command(int id, int code)
-{
-       return 1;       // no command handler found
-}
-
-int Window::Notify(int id, NMHDR* pnmh)
-{
-       return 0;
-}
-
-void Window::CancelModes(HWND hwnd)
-{
-       if (hwnd)
-               PostMessage(hwnd, WM_CANCELMODE, 0, 0);
-       else
-               PostMessage(HWND_BROADCAST, WM_CANCELMODE, 0, 0);
-}
-
-
-SubclassedWindow::SubclassedWindow(HWND hwnd)
- :     super(hwnd)
-{
-       _orgWndProc = SubclassWindow(_hwnd, SubclassedWndProc);
-
-       if (!_orgWndProc)
-               delete this;
-}
-
-LRESULT CALLBACK SubclassedWindow::SubclassedWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       SubclassedWindow* pThis = GET_WINDOW(SubclassedWindow, hwnd);
-       assert(pThis);
-
-       if (pThis) {
-               switch(nmsg) {
-                 case WM_COMMAND:
-                       if (!pThis->Command(LOWORD(wparam), HIWORD(wparam)))
-                               return 0;
-                       break;
-
-                 case WM_NOTIFY:
-                       return pThis->Notify(wparam, (NMHDR*)lparam);
-
-                 case WM_NOTIFYFORMAT:
-                       return NFR_CURRENT;
-
-                 case WM_CREATE:
-                       return pThis->Init((LPCREATESTRUCT)lparam);
-
-                 case WM_NCDESTROY:
-                       delete pThis;
-                       return 0;
-
-                 default:
-                       return pThis->WndProc(nmsg, wparam, lparam);
-               }
-       }
-
-       return CallWindowProc(pThis->_orgWndProc, hwnd, nmsg, wparam, lparam);
-}
-
-LRESULT SubclassedWindow::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       return CallWindowProc(_orgWndProc, _hwnd, nmsg, wparam, lparam);
-}
-
-int SubclassedWindow::Command(int id, int code)
-{
-       return 1;       // no command handler found
-}
-
-int SubclassedWindow::Notify(int id, NMHDR* pnmh)
-{
-       return CallWindowProc(_orgWndProc, _hwnd, WM_NOTIFY, id, (LPARAM)pnmh);
-}
-
-
-ChildWindow::ChildWindow(HWND hwnd, HWND hwndFrame)
- :     super(hwnd),
-       _hwndFrame(hwndFrame)
-{
-}
-
-
-ChildWindow* ChildWindow::create(const ChildWndInfo& info, CREATORFUNC_INFO creator,
-                                                                       LPCTSTR classname, LPCTSTR title, DWORD style)
-{
-       HWND hwnd = Window::Create(creator, &info, 0, classname, title, style,
-                                       CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, info._hwndFrame);
-
-       return GET_WINDOW(ChildWindow, hwnd);
-}
-
-
-LRESULT ChildWindow::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case PM_JUMP_TO_URL:
-               return go_to((LPCTSTR)lparam)? TRUE: FALSE;
-
-         default:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-
-bool ChildWindow::go_to(LPCTSTR url)
-{
-       const String& url_str = jump_to_int(url);
-
-       if (!url_str.empty()) {
-               set_url(url_str);
-
-               _url_history.push(url_str);
-
-               return true;
-       } else
-               return false;
-}
-
-void ChildWindow::set_url(LPCTSTR url)
-{
-       if (_url != url) {
-               _url = url;
-
-               SendMessage(_hwndFrame, PM_URL_CHANGED, 0, (LPARAM)url);
-       }
-}
-
-
-WindowSet Window::s_pretranslate_windows;
-
-void Window::register_pretranslate(HWND hwnd)
-{
-       s_pretranslate_windows.insert(hwnd);
-}
-
-void Window::unregister_pretranslate(HWND hwnd)
-{
-       s_pretranslate_windows.erase(hwnd);
-}
-
-BOOL Window::pretranslate_msg(LPMSG pmsg)
-{
-       for(WindowSet::const_iterator it=Window::s_pretranslate_windows.begin(); it!=s_pretranslate_windows.end(); ++it)
-               if (SendMessage(*it, PM_TRANSLATE_MSG, 0, (LPARAM)pmsg))
-                       return TRUE;
-
-       return FALSE;
-}
-
-
-WindowSet Window::s_dialogs;
-
-void Window::register_dialog(HWND hwnd)
-{
-       s_dialogs.insert(hwnd);
-}
-
-void Window::unregister_dialog(HWND hwnd)
-{
-       s_dialogs.erase(hwnd);
-}
-
-BOOL Window::dispatch_dialog_msg(MSG* pmsg)
-{
-       for(WindowSet::const_iterator it=Window::s_dialogs.begin(); it!=s_dialogs.end(); ++it)
-               if (IsDialogMessage(*it, pmsg))
-                       return TRUE;
-
-       return FALSE;
-}
-
-
-int Window::MessageLoop()
-{
-       MSG msg;
-
-       while(GetMessage(&msg, 0, 0, 0)) {
-               try {
-                       if (pretranslate_msg(&msg))
-                               continue;
-
-                       if (dispatch_dialog_msg(&msg))
-                               continue;
-
-                       TranslateMessage(&msg);
-
-                       try {
-                               DispatchMessage(&msg);
-                       } catch(COMException& e) {
-                               HandleException(e, 0);
-                       }
-               } catch(COMException& e) {
-                       HandleException(e, 0);
-               }
-       }
-
-       return msg.wParam;
-}
-
-
-LRESULT        Window::SendParent(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       HWND parent = GetParent(_hwnd);
-
-       if (!parent)
-               return 0;
-
-       return SendMessage(parent, nmsg, wparam, lparam);
-}
-
-LRESULT        Window::PostParent(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       HWND parent = GetParent(_hwnd);
-
-       if (!parent)
-               return 0;
-
-       return PostMessage(parent, nmsg, wparam, lparam);
-}
-
-
-PreTranslateWindow::PreTranslateWindow(HWND hwnd)
- :     super(hwnd)
-{
-       register_pretranslate(hwnd);
-}
-
-PreTranslateWindow::~PreTranslateWindow()
-{
-       unregister_pretranslate(_hwnd);
-}
-
-
-Dialog::Dialog(HWND hwnd)
- :     super(hwnd)
-{
-       register_dialog(hwnd);
-}
-
-Dialog::~Dialog()
-{
-       unregister_dialog(_hwnd);
-}
-
-int Dialog::DoModal(UINT nid, CREATORFUNC creator, HWND hwndParent)
-{
-       Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-       s_window_creator = creator;
-       s_new_info = NULL;
-
-       ///@todo call Window::pretranslate_msg()
-
-       return DialogBoxParam(g_hInstance, MAKEINTRESOURCE(nid), hwndParent, DialogProc, 0/*lpParam*/);
-}
-
-int Dialog::DoModal(UINT nid, CREATORFUNC_INFO creator, const void* info, HWND hwndParent)
-{
-       Lock lock(GetStaticWindowData()._create_crit_sect);     // protect access to s_window_creator and s_new_info
-
-       s_window_creator = (CREATORFUNC) creator;
-       s_new_info = NULL;
-
-       ///@todo call Window::pretranslate_msg()
-
-       return DialogBoxParam(g_hInstance, MAKEINTRESOURCE(nid), hwndParent, DialogProc, 0/*lpParam*/);
-}
-
-INT_PTR CALLBACK Window::DialogProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       Window* pThis = get_window(hwnd);
-
-       if (pThis) {
-               switch(nmsg) {
-                 case WM_COMMAND:
-                       pThis->Command(LOWORD(wparam), HIWORD(wparam));
-                       return TRUE;    // message has been processed
-
-                 case WM_NOTIFY:
-                       pThis->Notify(wparam, (NMHDR*)lparam);
-                       return TRUE;    // message has been processed
-
-                 case WM_NOTIFYFORMAT:
-                       SetWindowLong(hwnd, DWLP_MSGRESULT, NFR_CURRENT);       // set return value NFR_CURRENT
-                       return TRUE;    // message has been processed
-
-                 case WM_NCDESTROY:
-                       delete pThis;
-                       return TRUE;    // message has been processed
-
-                 default:
-                       return pThis->WndProc(nmsg, wparam, lparam);
-               }
-       } else if (nmsg == WM_INITDIALOG) {
-               pThis = create_controller(hwnd);
-
-               if (pThis)
-                       return pThis->Init(NULL);
-       }
-
-       return FALSE;   // message has not been processed
-}
-
-LRESULT Dialog::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       return FALSE;   // message has not been processed
-}
-
-int Dialog::Command(int id, int code)
-{
-       if (code == BN_CLICKED) {
-               EndDialog(_hwnd, id);
-               return 0;       // message has been processed
-       }
-
-       return 1;
-}
-
-
-ResizeManager::ResizeManager(HWND hwnd)
- :     _hwnd(hwnd)
-{
-       ClientRect clnt(hwnd);
-       _last_size.cx = clnt.right;
-       _last_size.cy = clnt.bottom;
-
-       WindowRect rect(hwnd);
-       _min_wnd_size.cx = rect.right - rect.left;
-       _min_wnd_size.cy = rect.bottom - rect.top;
-}
-
-void ResizeManager::HandleSize(int cx, int cy)
-{
-       ClientRect clnt_rect(_hwnd);
-       SIZE new_size = {cx, cy};
-
-       int dx = new_size.cx - _last_size.cx;
-       int dy = new_size.cy - _last_size.cy;
-
-       if (!dx && !dy)
-               return;
-
-       _last_size = new_size;
-
-       HDWP hDWP = BeginDeferWindowPos(size());
-
-       for(ResizeManager::const_iterator it=begin(); it!=end(); ++it) {
-               const ResizeEntry& e = *it;
-               RECT move = {0};
-
-               if (e._flags & MOVE_LEFT)
-                       move.left += dx;
-
-               if (e._flags & MOVE_RIGHT)
-                       move.right += dx;
-
-               if (e._flags & MOVE_TOP)
-                       move.top += dy;
-
-               if (e._flags & MOVE_BOTTOM)
-                       move.bottom += dy;
-
-               UINT flags = 0;
-
-               if (!move.left && !move.top)
-                       flags = SWP_NOMOVE;
-
-               if (move.right==move.left && move.bottom==move.top)
-                       flags |= SWP_NOSIZE;
-
-               if (flags != (SWP_NOMOVE|SWP_NOSIZE)) {
-                       HWND hwnd = GetDlgItem(_hwnd, e._id);
-
-                       if (hwnd) {
-                               WindowRect rect(hwnd);
-                               ScreenToClient(_hwnd, rect);
-
-                               rect.left       += move.left;
-                               rect.right      += move.right;
-                               rect.top        += move.top;
-                               rect.bottom     += move.bottom;
-
-                               hDWP = DeferWindowPos(hDWP, hwnd, 0, rect.left, rect.top, rect.right-rect.left, rect.bottom-rect.top, flags|SWP_NOACTIVATE|SWP_NOZORDER);
-                       }
-               }
-       }
-
-       EndDeferWindowPos(hDWP);
-}
-
-void ResizeManager::Resize(int dx, int dy)
-{
-       ::SetWindowPos(_hwnd, 0, 0, 0, _min_wnd_size.cx+dx, _min_wnd_size.cy+dy, SWP_NOMOVE|SWP_NOACTIVATE);
-       MoveVisible(_hwnd);
-
-       ClientRect clnt_rect(_hwnd);
-       HandleSize(clnt_rect.right, clnt_rect.bottom);
-}
-
-
-Button::Button(HWND parent, LPCTSTR title, int left, int top, int width, int height,
-                               int id, DWORD flags, DWORD exStyle)
- :     WindowHandle(CreateWindowEx(exStyle, TEXT("BUTTON"), title, flags, left, top, width, height,
-                                                       parent, (HMENU)id, g_hInstance, 0))
-{
-}
-
-
-LRESULT OwnerdrawnButton::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       if (nmsg == PM_DISPATCH_DRAWITEM) {
-               DrawItem((LPDRAWITEMSTRUCT)lparam);
-               return TRUE;
-       } else
-               return super::WndProc(nmsg, wparam, lparam);
-}
-
-
-Static::Static(HWND parent, LPCTSTR title, int left, int top, int width, int height,
-                               int id, DWORD flags, DWORD exStyle)
- :     WindowHandle(CreateWindowEx(exStyle, TEXT("STATIC"), title, flags, left, top, width, height,
-                                                       parent, (HMENU)id, g_hInstance, 0))
-{
-}
-
-
-static RECT s_MyDrawText_Rect = {0, 0, 0, 0};
-
-static BOOL CALLBACK MyDrawText(HDC hdc, LPARAM data, int cnt)
-{
-       ::DrawText(hdc, (LPCTSTR)data, cnt, &s_MyDrawText_Rect, DT_SINGLELINE);
-       return TRUE;
-}
-
-void DrawGrayText(HDC hdc, LPRECT pRect, LPCTSTR title, int dt_flags)
-{
-       COLORREF gray = GetSysColor(COLOR_GRAYTEXT);
-
-       if (gray) {
-               TextColor lcColor(hdc, GetSysColor(COLOR_BTNHIGHLIGHT));
-               RECT shadowRect = {pRect->left+1, pRect->top+1, pRect->right+1, pRect->bottom+1};
-               DrawText(hdc, title, -1, &shadowRect, dt_flags);
-
-               SetTextColor(hdc, gray);
-               DrawText(hdc, title, -1, pRect, dt_flags);
-       } else {
-               int old_r = pRect->right;
-               int old_b = pRect->bottom;
-
-               DrawText(hdc, title, -1, pRect, dt_flags|DT_CALCRECT);
-
-               int x = pRect->left + (old_r-pRect->right)/2;
-               int y = pRect->top + (old_b-pRect->bottom)/2;
-               int w = pRect->right-pRect->left;
-               int h = pRect->bottom-pRect->top;
-               s_MyDrawText_Rect.right = w;
-               s_MyDrawText_Rect.bottom = h;
-
-               GrayString(hdc, GetSysColorBrush(COLOR_GRAYTEXT), MyDrawText, (LPARAM)title, -1, x, y, w, h);
-       }
-}
-
-
-/* not yet used
-void ColorButton::DrawItem(LPDRAWITEMSTRUCT dis)
-{
-       UINT state = DFCS_BUTTONPUSH;
-
-       if (dis->itemState & ODS_DISABLED)
-               state |= DFCS_INACTIVE;
-
-       RECT textRect = {dis->rcItem.left+2, dis->rcItem.top+2, dis->rcItem.right-4, dis->rcItem.bottom-4};
-
-       if (dis->itemState & ODS_SELECTED) {
-               state |= DFCS_PUSHED;
-               ++textRect.left;        ++textRect.top;
-               ++textRect.right;       ++textRect.bottom;
-       }
-
-       DrawFrameControl(dis->hDC, &dis->rcItem, DFC_BUTTON, state);
-
-       TCHAR title[BUFFER_LEN];
-       GetWindowText(_hwnd, title, BUFFER_LEN);
-
-       BkMode bk_mode(dis->hDC, TRANSPARENT);
-
-       if (dis->itemState & (ODS_DISABLED|ODS_GRAYED))
-               DrawGrayText(dis, &textRect, title, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
-       else {
-               TextColor lcColor(dis->hDC, _textColor);
-               DrawText(dis->hDC, title, -1, &textRect, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
-       }
-
-       if (dis->itemState & ODS_FOCUS) {
-               RECT rect = {
-                       dis->rcItem.left+3, dis->rcItem.top+3,
-                       dis->rcItem.right-dis->rcItem.left-4, dis->rcItem.bottom-dis->rcItem.top-4
-               };
-               if (dis->itemState & ODS_SELECTED) {
-                       ++rect.left;    ++rect.top;
-                       ++rect.right;   ++rect.bottom;
-               }
-               DrawFocusRect(dis->hDC, &rect);
-       }
-}
-*/
-
-
-void PictureButton::DrawItem(LPDRAWITEMSTRUCT dis)
-{
-       UINT state = DFCS_BUTTONPUSH;
-       int style = GetWindowStyle(_hwnd);
-
-       if (dis->itemState & ODS_DISABLED)
-               state |= DFCS_INACTIVE;
-
-       POINT imagePos;
-       RECT textRect;
-       int dt_flags;
-
-       if (style & BS_BOTTOM) {
-                // align horizontal centered, vertical floating
-               imagePos.x = (dis->rcItem.left + dis->rcItem.right - _cx) / 2;
-               imagePos.y = dis->rcItem.top + 3;
-
-               textRect.left = dis->rcItem.left + 2;
-               textRect.top = dis->rcItem.top + _cy + 4;
-               textRect.right = dis->rcItem.right - 4;
-               textRect.bottom = dis->rcItem.bottom - 4;
-
-               dt_flags = DT_SINGLELINE|DT_CENTER|DT_VCENTER;
-       } else {
-                // horizontal floating, vertical centered
-               imagePos.x = dis->rcItem.left + 3;
-               imagePos.y = (dis->rcItem.top + dis->rcItem.bottom - _cy)/2;
-
-               textRect.left = dis->rcItem.left + _cx + 4;
-               textRect.top = dis->rcItem.top + 2;
-               textRect.right = dis->rcItem.right - 4;
-               textRect.bottom = dis->rcItem.bottom - 4;
-
-               dt_flags = DT_SINGLELINE|DT_VCENTER/*|DT_CENTER*/;
-       }
-
-       if (dis->itemState & ODS_SELECTED) {
-               state |= DFCS_PUSHED;
-               ++imagePos.x;           ++imagePos.y;
-               ++textRect.left;        ++textRect.top;
-               ++textRect.right;       ++textRect.bottom;
-       }
-
-       if (_flat) {
-               FillRect(dis->hDC, &dis->rcItem, _hBrush);
-
-               if (style & BS_FLAT)    // Only with BS_FLAT set, there will be drawn a frame without highlight.
-                       DrawEdge(dis->hDC, &dis->rcItem, EDGE_RAISED, BF_RECT|BF_FLAT);
-       } else
-               DrawFrameControl(dis->hDC, &dis->rcItem, DFC_BUTTON, state);
-
-       if (_hIcon)
-               DrawIconEx(dis->hDC, imagePos.x, imagePos.y, _hIcon, _cx, _cy, 0, _hBrush, DI_NORMAL);
-       else {
-               MemCanvas mem_dc;
-               BitmapSelection sel(mem_dc, _hBmp);
-               BitBlt(dis->hDC, imagePos.x, imagePos.y, _cx, _cy, mem_dc, 0, 0, SRCCOPY);
-       }
-
-       TCHAR title[BUFFER_LEN];
-       GetWindowText(_hwnd, title, BUFFER_LEN);
-
-       BkMode bk_mode(dis->hDC, TRANSPARENT);
-
-       if (dis->itemState & (ODS_DISABLED|ODS_GRAYED))
-               DrawGrayText(dis->hDC, &textRect, title, dt_flags);
-       else {
-               TextColor lcColor(dis->hDC, GetSysColor(COLOR_BTNTEXT));
-               DrawText(dis->hDC, title, -1, &textRect, dt_flags);
-       }
-
-       if (dis->itemState & ODS_FOCUS) {
-               RECT rect = {
-                       dis->rcItem.left+3, dis->rcItem.top+3,
-                       dis->rcItem.right-dis->rcItem.left-4, dis->rcItem.bottom-dis->rcItem.top-4
-               };
-               if (dis->itemState & ODS_SELECTED) {
-                       ++rect.left;    ++rect.top;
-                       ++rect.right;   ++rect.bottom;
-               }
-               DrawFocusRect(dis->hDC, &rect);
-       }
-}
-
-
-void FlatButton::DrawItem(LPDRAWITEMSTRUCT dis)
-{
-       UINT style = DFCS_BUTTONPUSH;
-
-       if (dis->itemState & ODS_DISABLED)
-               style |= DFCS_INACTIVE;
-
-       RECT textRect = {dis->rcItem.left+2, dis->rcItem.top+2, dis->rcItem.right-4, dis->rcItem.bottom-4};
-
-       if (dis->itemState & ODS_SELECTED) {
-               style |= DFCS_PUSHED;
-               ++textRect.left;        ++textRect.top;
-               ++textRect.right;       ++textRect.bottom;
-       }
-
-       FillRect(dis->hDC, &dis->rcItem, GetSysColorBrush(COLOR_BTNFACE));
-
-        // highlight the button?
-       if (_active)
-               DrawEdge(dis->hDC, &dis->rcItem, EDGE_ETCHED, BF_RECT);
-       else if (GetWindowStyle(_hwnd) & BS_FLAT)       // Only with BS_FLAT there will be drawn a frame to show highlighting.
-               DrawEdge(dis->hDC, &dis->rcItem, EDGE_RAISED, BF_RECT|BF_FLAT);
-
-       TCHAR txt[BUFFER_LEN];
-       int txt_len = GetWindowText(_hwnd, txt, BUFFER_LEN);
-
-       if (dis->itemState & (ODS_DISABLED|ODS_GRAYED)) {
-               COLORREF gray = GetSysColor(COLOR_GRAYTEXT);
-
-               if (gray) {
-                       {
-                       TextColor lcColor(dis->hDC, GetSysColor(COLOR_BTNHIGHLIGHT));
-                       RECT shadowRect = {textRect.left+1, textRect.top+1, textRect.right+1, textRect.bottom+1};
-                       DrawText(dis->hDC, txt, txt_len, &shadowRect, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
-                       }
-
-                       BkMode mode(dis->hDC, TRANSPARENT);
-                       TextColor lcColor(dis->hDC, gray);
-                       DrawText(dis->hDC, txt, txt_len, &textRect, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
-               } else {
-                       int old_r = textRect.right;
-                       int old_b = textRect.bottom;
-                       DrawText(dis->hDC, txt, txt_len, &textRect, DT_SINGLELINE|DT_VCENTER|DT_CENTER|DT_CALCRECT);
-                       int x = textRect.left + (old_r-textRect.right)/2;
-                       int y = textRect.top + (old_b-textRect.bottom)/2;
-                       int w = textRect.right-textRect.left;
-                       int h = textRect.bottom-textRect.top;
-                       s_MyDrawText_Rect.right = w;
-                       s_MyDrawText_Rect.bottom = h;
-                       GrayString(dis->hDC, GetSysColorBrush(COLOR_GRAYTEXT), MyDrawText, (LPARAM)txt, txt_len, x, y, w, h);
-               }
-       } else {
-               TextColor lcColor(dis->hDC, _active? _activeColor: _textColor);
-               DrawText(dis->hDC, txt, txt_len, &textRect, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
-       }
-
-       if (dis->itemState & ODS_FOCUS) {
-               RECT rect = {
-                       dis->rcItem.left+3, dis->rcItem.top+3,
-                       dis->rcItem.right-dis->rcItem.left-4, dis->rcItem.bottom-dis->rcItem.top-4
-               };
-               if (dis->itemState & ODS_SELECTED) {
-                       ++rect.left;    ++rect.top;
-                       ++rect.right;   ++rect.bottom;
-               }
-               DrawFocusRect(dis->hDC, &rect);
-       }
-}
-
-LRESULT        FlatButton::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case WM_MOUSEMOVE: {
-               bool active = false;
-
-               if (IsWindowEnabled(_hwnd)) {
-                       DWORD pid_foreground;
-                       HWND hwnd_foreground = GetForegroundWindow();   //@@ may be better look for WM_ACTIVATEAPP ?
-                       GetWindowThreadProcessId(hwnd_foreground, &pid_foreground);
-
-                       if (GetCurrentProcessId() == pid_foreground) {
-                               POINT pt = {GET_X_LPARAM(lparam), GET_Y_LPARAM(lparam)};
-                               ClientRect clntRect(_hwnd);
-
-                                // highlight the button?
-                               if (pt.x>=clntRect.left && pt.x<clntRect.right && pt.y>=clntRect.top && pt.y<clntRect.bottom)
-                                       active = true;
-                       }
-               }
-
-               if (active != _active) {
-                       _active = active;
-
-                       if (active) {
-                               TRACKMOUSEEVENT tme = {sizeof(tme), /*TME_HOVER|*/TME_LEAVE, _hwnd/*, HOVER_DEFAULT*/};
-                               _TrackMouseEvent(&tme);
-                       }
-
-                       InvalidateRect(_hwnd, NULL, TRUE);
-               }
-
-               return 0;}
-
-         case WM_LBUTTONUP: {
-               POINT pt = {GET_X_LPARAM(lparam), GET_Y_LPARAM(lparam)};
-               ClientRect clntRect(_hwnd);
-
-                // no more in the active rectangle?
-               if (pt.x<clntRect.left || pt.x>=clntRect.right || pt.y<clntRect.top || pt.y>=clntRect.bottom)
-                       goto cancel_press;
-
-               goto def;}
-
-         case WM_CANCELMODE:
-         cancel_press: {
-               TRACKMOUSEEVENT tme = {sizeof(tme), /*TME_HOVER|*/TME_LEAVE|TME_CANCEL, _hwnd/*, HOVER_DEFAULT*/};
-               _TrackMouseEvent(&tme);
-               _active = false;
-               ReleaseCapture();}
-               // fall through
-
-         case WM_MOUSELEAVE:
-               if (_active) {
-                       _active = false;
-
-                       InvalidateRect(_hwnd, NULL, TRUE);
-               }
-
-               return 0;
-
-         default: def:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-}
-
-
-HyperlinkCtrl::HyperlinkCtrl(HWND hwnd, COLORREF colorLink, COLORREF colorVisited)
- :     super(hwnd),
-       _cmd(ResString(GetDlgCtrlID(hwnd))),
-       _textColor(colorLink),
-       _colorVisited(colorVisited),
-       _hfont(0),
-       _crsr_link(0)
-{
-       init();
-}
-
-HyperlinkCtrl::HyperlinkCtrl(HWND owner, int id, COLORREF colorLink, COLORREF colorVisited)
- :     super(GetDlgItem(owner, id)),
-       _cmd(ResString(id)),
-       _textColor(colorLink),
-       _colorVisited(colorVisited),
-       _hfont(0),
-       _crsr_link(0)
-{
-       init();
-}
-
-void HyperlinkCtrl::init()
-{
-       if (_cmd.empty()) {
-               TCHAR txt[BUFFER_LEN];
-               _cmd.assign(txt, GetWindowText(_hwnd, txt, BUFFER_LEN));
-       }
-}
-
-HyperlinkCtrl::~HyperlinkCtrl()
-{
-       if (_hfont)
-               DeleteObject(_hfont);
-}
-
-LRESULT HyperlinkCtrl::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       switch(nmsg) {
-         case PM_DISPATCH_CTLCOLOR: {
-               if (!_hfont) {
-                       HFONT hfont = (HFONT) SendMessage(_hwnd, WM_GETFONT, 0, 0);
-                       LOGFONT lf; GetObject(hfont, sizeof(lf), &lf);
-                       lf.lfUnderline = TRUE;
-                       _hfont = CreateFontIndirect(&lf);
-               }
-
-               HDC hdc = (HDC) wparam;
-               SetTextColor(hdc, _textColor);  //@@
-               SelectFont(hdc, _hfont);
-               SetBkMode(hdc, TRANSPARENT);
-               return (LRESULT)GetStockObject(HOLLOW_BRUSH);
-         }
-
-         case WM_SETCURSOR:
-               if (!_crsr_link)
-                       _crsr_link = LoadCursor(0, IDC_HAND);
-
-               if (_crsr_link)
-                       SetCursor(_crsr_link);
-               return 0;
-
-         case WM_NCHITTEST:
-               return HTCLIENT;        // Aktivierung von Maus-Botschaften
-
-         case WM_LBUTTONDOWN:
-               if (LaunchLink()) {
-                       _textColor = _colorVisited;
-                       InvalidateRect(_hwnd, NULL, FALSE);
-               } else
-                       MessageBeep(0);
-               return 0;
-
-         default:
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-}
-
-
-ToolTip::ToolTip(HWND owner)
- :     super(CreateWindowEx(WS_EX_TOPMOST|WS_EX_NOPARENTNOTIFY, TOOLTIPS_CLASS, 0,
-                                WS_POPUP|TTS_NOPREFIX|TTS_ALWAYSTIP, CW_USEDEFAULT,CW_USEDEFAULT,CW_USEDEFAULT,CW_USEDEFAULT,
-                                owner, 0, g_hInstance, 0))
-{
-       activate();
-}
-
-
-ListSort::ListSort(HWND hwndListview, PFNLVCOMPARE compare_fct)
- :     WindowHandle(hwndListview),
-       _compare_fct(compare_fct)
-{
-       _sort_crit = 0;
-       _direction = false;
-}
-
-void ListSort::toggle_sort(int idx)
-{
-       if (_sort_crit == idx)
-               _direction = !_direction;
-       else {
-               _sort_crit = idx;
-               _direction = false;
-       }
-}
-
-void ListSort::sort()
-{
-       int idx = ListView_GetSelectionMark(_hwnd);
-       LPARAM param = ListView_GetItemData(_hwnd, idx);
-
-       ListView_SortItems(_hwnd, _compare_fct, (LPARAM)this);
-
-       if (idx >= 0) {
-               idx = ListView_FindItemPara(_hwnd, param);
-               ListView_EnsureVisible(_hwnd, idx, FALSE);
-       }
-}
-
-
-PropSheetPage::PropSheetPage(UINT nid, Window::CREATORFUNC dlg_creator)
- :     _dlg_creator(dlg_creator)
-{
-       PROPSHEETPAGE::dwSize           = sizeof(PROPSHEETPAGE);
-       PROPSHEETPAGE::dwFlags          = 0;
-       PROPSHEETPAGE::hInstance        = g_hInstance;
-       PROPSHEETPAGE::pszTemplate      = MAKEINTRESOURCE(nid);
-       PROPSHEETPAGE::pfnDlgProc       = PropSheetPageDlg::DialogProc;
-       PROPSHEETPAGE::lParam           = (LPARAM) this;
-}
-
-
-#ifndef PSM_GETRESULT  // currently (as of 18.01.2004) missing in MinGW headers
-#define PSM_GETRESULT                          (WM_USER + 135)
-#define PropSheet_GetResult(hDlg)      SNDMSG(hDlg, PSM_GETRESULT, 0, 0)
-#endif
-
-
-PropertySheetDialog::PropertySheetDialog(HWND owner)
- :     _hwnd(0)
-{
-       PROPSHEETHEADER::dwSize = sizeof(PROPSHEETHEADER);
-       PROPSHEETHEADER::dwFlags = PSH_PROPSHEETPAGE | PSH_MODELESS;
-       PROPSHEETHEADER::hwndParent = owner;
-       PROPSHEETHEADER::hInstance = g_hInstance;
-}
-
-void PropertySheetDialog::add(PropSheetPage& psp)
-{
-       _pages.push_back(psp);
-}
-
-int    PropertySheetDialog::DoModal(int start_page)
-{
-       PROPSHEETHEADER::ppsp = (LPCPROPSHEETPAGE) &_pages[0];
-       PROPSHEETHEADER::nPages = _pages.size();
-       PROPSHEETHEADER::nStartPage = start_page;
-/*
-       Window* pwnd = Window::create_property_sheet(this, WINDOW_CREATOR(PropertySheetDlg), NULL);
-       if (!pwnd)
-               return -1;
-
-       HWND hwndPropSheet = *pwnd;
-*/
-       int ret = PropertySheet(this);
-       if (ret == -1)
-               return -1;
-
-       HWND hwndPropSheet = (HWND) ret;
-       HWND hwndparent = GetParent(hwndPropSheet);
-
-       if (hwndparent)
-               EnableWindow(hwndparent, FALSE);
-
-       ret = 0;
-       MSG msg;
-
-       while(GetMessage(&msg, 0, 0, 0)) {
-               try {
-                       if (Window::pretranslate_msg(&msg))
-                               continue;
-
-                       if (PropSheet_IsDialogMessage(hwndPropSheet, &msg))
-                               continue;
-
-                       if (Window::dispatch_dialog_msg(&msg))
-                               continue;
-
-                       TranslateMessage(&msg);
-
-                       try {
-                               DispatchMessage(&msg);
-                       } catch(COMException& e) {
-                               HandleException(e, 0);
-                       }
-
-                       if (!PropSheet_GetCurrentPageHwnd(hwndPropSheet)) {
-                               ret = PropSheet_GetResult(hwndPropSheet);
-                               break;
-                       }
-               } catch(COMException& e) {
-                       HandleException(e, 0);
-               }
-       }
-
-       if (hwndparent)
-               EnableWindow(hwndparent, TRUE);
-
-       DestroyWindow(hwndPropSheet);
-
-       return ret;
-}
-
-HWND PropertySheetDialog::GetCurrentPage()
-{
-       HWND hdlg = PropSheet_GetCurrentPageHwnd(_hwnd);
-       return hdlg;
-}
-
-
-PropSheetPageDlg::PropSheetPageDlg(HWND hwnd)
- :     super(hwnd)
-{
-}
-
-INT_PTR CALLBACK PropSheetPageDlg::DialogProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       PropSheetPageDlg* pThis = GET_WINDOW(PropSheetPageDlg, hwnd);
-
-       if (pThis) {
-               switch(nmsg) {
-                 case WM_COMMAND:
-                       pThis->Command(LOWORD(wparam), HIWORD(wparam));
-                       return TRUE;    // message has been processed
-
-                 case WM_NOTIFY:
-                       pThis->Notify(wparam, (NMHDR*)lparam);
-                       return TRUE;    // message has been processed
-
-                 case WM_NOTIFYFORMAT:
-                       SetWindowLong(hwnd, DWLP_MSGRESULT, NFR_CURRENT);       // set return value NFR_CURRENT
-                       return TRUE;    // message has been processed
-
-                 case WM_NCDESTROY:
-                       delete pThis;
-                       return TRUE;    // message has been processed
-
-                 default:
-                       return pThis->WndProc(nmsg, wparam, lparam);
-               }
-       } else if (nmsg == WM_INITDIALOG) {
-               PROPSHEETPAGE* psp = (PROPSHEETPAGE*) lparam;
-               PropSheetPage* ppsp = (PropSheetPage*) psp->lParam;
-
-               if (ppsp->_dlg_creator) {
-                       pThis = static_cast<PropSheetPageDlg*>(ppsp->_dlg_creator(hwnd));
-
-                       if (pThis)
-                               return pThis->Init(NULL);
-               }
-       }
-
-       return FALSE;   // message has not been processed
-}
-
-int PropSheetPageDlg::Command(int id, int code)
-{
-       // override call to EndDialog in Dialog::Command();
-
-       return FALSE;
-}
diff --git a/reactos/subsys/system/ibrowser/utility/window.h b/reactos/subsys/system/ibrowser/utility/window.h
deleted file mode 100644 (file)
index 73b9ea6..0000000
+++ /dev/null
@@ -1,1100 +0,0 @@
-/*
- * Copyright 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // ROS Internet Web Browser
- //
- // window.h
- //
- // Martin Fuchs, 23.07.2003
- //
-
-
-typedef set<HWND> WindowSet;
-
-
- /*
-       Classes are declared using "struct", not "class" because the default
-       access mode is "public". This way we can list the member functions in a
-       natural order without explicitly specifying any access mode at the begin
-       of the definition.
-       First are public constructors and destructor, then public member functions.
-       After that we list protected member varibables and functions. If needed,
-       private implemenation varibales and functions are positioned at the end.
- */
-
-
- /// information structure for creation of a child window
-struct ChildWndInfo
-{
-       ChildWndInfo(HWND hwndFrame)
-        :      _hwndFrame(hwndFrame) {}
-
-       HWND    _hwndFrame;
-};
-
-
- /**
-       Class Window is the base class for several C++ window wrapper classes.
-       Window objects are allocated from the heap. They are automatically freed
-       when the window gets destroyed.
- */
-struct Window : public WindowHandle
-{
-       Window(HWND hwnd);
-       virtual ~Window();
-
-
-       typedef map<HWND,Window*> WindowMap;
-
-       typedef Window* (*CREATORFUNC)(HWND);
-       typedef Window* (*CREATORFUNC_INFO)(HWND, const void*);
-
-       static HWND Create(CREATORFUNC creator, DWORD dwExStyle,
-                               LPCTSTR lpClassName, LPCTSTR lpWindowName,
-                               DWORD dwStyle, int x, int y, int w, int h,
-                               HWND hwndParent=0, HMENU hMenu=0/*, LPVOID lpParam=0*/);
-
-       static HWND Create(CREATORFUNC_INFO creator, const void* info,
-                               DWORD dwExStyle, LPCTSTR lpClassName, LPCTSTR lpWindowName,
-                               DWORD dwStyle, int x, int y, int w, int h,
-                               HWND hwndParent=0, HMENU hMenu=0/*, LPVOID lpParam=0*/);
-
-       static LRESULT CALLBACK WindowWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-       static INT_PTR CALLBACK DialogProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       static Window* get_window(HWND hwnd);
-#ifndef _MSC_VER
-       template<typename CLASS> static CLASS* get_window(HWND hwnd) {return static_cast<CLASS*>(get_window(hwnd));}
-#define        GET_WINDOW(CLASS, hwnd) Window::get_window<CLASS>(hwnd)
-#endif
-
-       static void register_pretranslate(HWND hwnd);
-       static void unregister_pretranslate(HWND hwnd);
-       static BOOL     pretranslate_msg(LPMSG pmsg);
-
-       static void     register_dialog(HWND hwnd);
-       static void     unregister_dialog(HWND hwnd);
-       static BOOL     dispatch_dialog_msg(LPMSG pmsg);
-
-       static int      MessageLoop();
-
-
-       LRESULT SendParent(UINT nmsg, WPARAM wparam=0, LPARAM lparam=0);
-       LRESULT PostParent(UINT nmsg, WPARAM wparam=0, LPARAM lparam=0);
-
-       static void CancelModes(HWND hwnd=0);
-
-
-protected:
-       virtual LRESULT Init(LPCREATESTRUCT pcs);                                                       // WM_CREATE processing
-       virtual LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       virtual int             Command(int id, int code);                                                      // WM_COMMAND processing
-       virtual int             Notify(int id, NMHDR* pnmh);                                            // WM_NOTIFY processing
-
-       static Window* create_controller(HWND hwnd);
-
-
-       static WindowMap        s_wnd_map;
-
-       static const void*      s_new_info;
-       static CREATORFUNC      s_window_creator;
-
-
-        /// structure for managing critical sections as static class information in struct Window
-       struct StaticWindowData {
-               CritSect        _map_crit_sect;
-               CritSect        _create_crit_sect;
-       };
-
-       static StaticWindowData& GetStaticWindowData();
-
-
-       static WindowSet s_pretranslate_windows;
-       static WindowSet s_dialogs;
-};
-
-#ifdef UNICODE
-#define        NFR_CURRENT     NFR_UNICODE
-#else
-#define        NFR_CURRENT     NFR_ANSI
-#endif
-
-
-#ifdef _MSC_VER
-template<typename CLASS> struct GetWindowHelper
-{
-       static CLASS* get_window(HWND hwnd) {
-               return static_cast<CLASS*>(Window::get_window(hwnd));
-       }
-};
-#define        GET_WINDOW(CLASS, hwnd) GetWindowHelper<CLASS>::get_window(hwnd)
-#endif
-
-
- /// dynamic casting of Window pointers
-template<typename CLASS> struct TypeCheck
-{
-       static CLASS* dyn_cast(Window* wnd)
-               {return dynamic_cast<CLASS*>(wnd);}
-};
-
-#define        WINDOW_DYNAMIC_CAST(CLASS, hwnd) \
-       TypeCheck<CLASS>::dyn_cast(Window::get_window(hwnd))
-
-
- /**
-       SubclassedWindow is used to wrap already existing window handles
-       into C++ Window objects. To construct a object, use the "new" operator
-       to put it in the heap. It is automatically freed, when the window
-       gets destroyed.
- */
-struct SubclassedWindow : public Window
-{
-       typedef Window super;
-
-       SubclassedWindow(HWND);
-
-protected:
-       WNDPROC _orgWndProc;
-
-       static LRESULT CALLBACK SubclassedWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       virtual LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       virtual int             Command(int id, int code);
-       virtual int             Notify(int id, NMHDR* pnmh);
-};
-
-
- /// template class used in macro WINDOW_CREATOR to define the creater functions for Window objects
-template<typename WND_CLASS> struct WindowCreator
-{
-       static WND_CLASS* window_creator(HWND hwnd)
-       {
-               return new WND_CLASS(hwnd);
-       }
-};
-
-#define WINDOW_CREATOR(WND_CLASS) \
-       ((Window::CREATORFUNC) WindowCreator<WND_CLASS>::window_creator)
-
-
- /// template class used in macro WINDOW_CREATOR_INFO to the define creater functions for Window objects with additional creation information
-template<typename WND_CLASS, typename INFO_CLASS> struct WindowCreatorInfo
-{
-       static WND_CLASS* window_creator(HWND hwnd, const void* info)
-       {
-               return new WND_CLASS(hwnd, *static_cast<const INFO_CLASS*>(info));
-       }
-};
-
-#define WINDOW_CREATOR_INFO(WND_CLASS, INFO_CLASS) \
-       ((Window::CREATORFUNC_INFO) WindowCreatorInfo<WND_CLASS, INFO_CLASS>::window_creator)
-
-
- /**
-       WindowClass is a neat wrapper for RegisterClassEx().
-       Just construct a WindowClass object, override the attributes you want
-       to change, then call Register() or simply request the ATOM value to
-       register the window class. You don't have to worry calling Register()
-       more than once. It checks if, the class has already been registered.
- */
-struct WindowClass : public WNDCLASSEX
-{
-       WindowClass(LPCTSTR classname, UINT style=0, WNDPROC wndproc=Window::WindowWndProc);
-
-       ATOM Register()
-       {
-               if (!_atomClass)
-                       _atomClass = RegisterClassEx(this);
-
-               return _atomClass;
-       }
-
-       operator ATOM() {return Register();}
-
-        // return LPCTSTR for the CreateWindowEx() parameter
-       operator LPCTSTR() {return (LPCTSTR)(int)Register();}
-
-protected:
-       ATOM    _atomClass;
-};
-
- /// window class with gray background color
-struct BtnWindowClass : public WindowClass
-{
-       BtnWindowClass(LPCTSTR classname, UINT style=0, WNDPROC wndproc=Window::WindowWndProc)
-        :      WindowClass(classname, style, wndproc)
-       {
-               hbrBackground = (HBRUSH)(COLOR_BTNFACE+1);
-       }
-};
-
- /// window class with specified icon from resources
-struct IconWindowClass : public WindowClass
-{
-       IconWindowClass(LPCTSTR classname, UINT nid, UINT style=0, WNDPROC wndproc=Window::WindowWndProc);
-};
-
-
- // private message constants
-#define        PM_DISPATCH_COMMAND             (WM_APP+0x00)
-#define        PM_TRANSLATE_MSG                (WM_APP+0x01)
-
-
-#define SPLIT_WIDTH            5
-#define DEFAULT_SPLIT_POS      300
-#define        COLOR_SPLITBAR          LTGRAY_BRUSH
-
-
- /// menu info structure
-struct MenuInfo
-{
-       HMENU   _hMenuView;
-};
-
-#define        PM_FRM_GET_MENUINFO             (WM_APP+0x02)
-
-#define        Frame_GetMenuInfo(hwnd) ((MenuInfo*)SNDMSG(hwnd, PM_FRM_GET_MENUINFO, 0, 0))
-
-
- /**
-       Class ChildWindow is used with class MainFrame.
- */
-struct ChildWindow : public Window
-{
-       typedef Window super;
-
-       ChildWindow(HWND hwnd, HWND hwndFrame);
-
-       static ChildWindow* create(const ChildWndInfo& info, CREATORFUNC_INFO creator,
-                                                               LPCTSTR classname, LPCTSTR title=NULL, DWORD style=0);
-
-       bool    go_to(LPCTSTR url);
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       virtual String jump_to_int(LPCTSTR url) = 0;
-
-protected:
-       MenuInfo*_menu_info;
-
-       HWND    _hwndFrame;
-       String  _statusText;
-       String  _url;
-
-       stack<String> _url_history;
-
-       void    set_url(LPCTSTR url);
-};
-
-#define        PM_SETSTATUSTEXT                (WM_APP+0x1E)
-
-
- /**
-       PreTranslateWindow is used to register windows to be called by Window::pretranslate_msg().
-       This way you get PM_TRANSLATE_MSG messages before the message loop dispatches messages.
-       You can then for example use TranslateAccelerator() to implement key shortcuts.
- */
-struct PreTranslateWindow : public Window
-{
-       typedef Window super;
-
-       PreTranslateWindow(HWND);
-       ~PreTranslateWindow();
-};
-
-
- /**
-       The class DialogWindow implements modeless dialogs, which are managed by
-       Window::dispatch_dialog_msg() in Window::MessageLoop().
-       A DialogWindow object should be constructed by calling Window::Create()
-       and specifying the class using the WINDOW_CREATOR() macro.
- */
-struct DialogWindow : public Window
-{
-       typedef Window super;
-
-       DialogWindow(HWND hwnd)
-        :      super(hwnd)
-       {
-               register_dialog(hwnd);
-       }
-
-       ~DialogWindow()
-       {
-               unregister_dialog(_hwnd);
-       }
-};
-
-
- /**
-       The class Dialog implements modal dialogs.
-       A Dialog object should be constructed by calling Dialog::DoModal()
-       and specifying the class using the WINDOW_CREATOR() macro.
- */
-struct Dialog : public Window
-{
-       typedef Window super;
-
-       Dialog(HWND);
-       ~Dialog();
-
-       static int DoModal(UINT nid, CREATORFUNC creator, HWND hwndParent=0);
-       static int DoModal(UINT nid, CREATORFUNC_INFO creator, const void* info, HWND hwndParent=0);
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       int             Command(int id, int code);
-};
-
-
-#define        PM_FRM_CALC_CLIENT              (WM_APP+0x03)
-#define        Frame_CalcFrameClient(hwnd, prt) ((BOOL)SNDMSG(hwnd, PM_FRM_CALC_CLIENT, 0, (LPARAM)(PRECT)prt))
-
-#define        PM_JUMP_TO_URL                  (WM_APP+0x25)
-#define        PM_URL_CHANGED                  (WM_APP+0x26)
-
-
-struct PropSheetPage : public PROPSHEETPAGE
-{
-       PropSheetPage(UINT nid, Window::CREATORFUNC dlg_creator);
-
-       void    init(struct PropertySheetDialog*);
-
-protected:
-       friend struct PropSheetPageDlg;
-
-       Window::CREATORFUNC     _dlg_creator;
-};
-
-
- /// Property Sheet dialog
-struct PropertySheetDialog : public PROPSHEETHEADER
-{
-       PropertySheetDialog(HWND owner);
-
-       void    add(PropSheetPage& psp);
-       int             DoModal(int start_page=0);
-
-       HWND    GetCurrentPage();
-
-protected:
-       typedef vector<PROPSHEETPAGE> Vector;
-       Vector  _pages;
-       HWND    _hwnd;
-};
-
-
- /// Property Sheet Page (inner dialog)
-struct PropSheetPageDlg : public Dialog
-{
-       typedef Dialog super;
-
-       PropSheetPageDlg(HWND);
-
-protected:
-       friend struct PropertySheetDialog;
-       friend struct PropSheetPage;
-
-       static INT_PTR CALLBACK DialogProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       int     Command(int id, int code);
-};
-
-
-/*
- /// Property Sheet Dialog (outer dialog)
-struct PropertySheetDlg : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       PropertySheetDlg(HWND hwnd) : super(hwnd) {}
-};
-*/
-
-
- // Layouting of resizable windows
-
- /// Flags to specify how to move and resize controls when resizing their parent window
-enum RESIZE_FLAGS {
-       MOVE_LEFT       = 0x1,
-       MOVE_RIGHT      = 0x2,
-       MOVE_TOP        = 0x4,
-       MOVE_BOTTOM     = 0x8,
-
-       MOVE_X  =  MOVE_LEFT | MOVE_RIGHT,
-       MOVE_Y  =  MOVE_TOP | MOVE_BOTTOM,
-       RESIZE_X=  MOVE_RIGHT,
-       RESIZE_Y=  MOVE_BOTTOM,
-
-       MOVE    = MOVE_X   | MOVE_Y,
-       RESIZE  = RESIZE_X | RESIZE_Y
-};
-
- /// structure to assign RESIZE_FLAGS to dialogs control
-struct ResizeEntry
-{
-       ResizeEntry(UINT id, int flags)
-        : _id(id), _flags(flags) {}
-
-       ResizeEntry(HWND hwnd, int flags)
-        : _id(GetDlgCtrlID(hwnd)), _flags(flags) {}
-
-       UINT    _id;
-       int             _flags;
-};
-
-
- /// Management of controls in resizable dialogs
-struct ResizeManager : public std::list<ResizeEntry>
-{
-       typedef std::list<ResizeEntry> super;
-
-       ResizeManager(HWND hwnd);
-
-       void Add(UINT id, int flags)
-               {push_back(ResizeEntry(id, flags));}
-
-       void Add(HWND hwnd, int flags)
-               {push_back(ResizeEntry(hwnd, flags));}
-
-       void HandleSize(int cx, int cy);
-       void Resize(int dx, int dy);
-
-       void SetMinMaxInfo(LPMINMAXINFO lpmmi)
-       {
-               lpmmi->ptMinTrackSize.x = _min_wnd_size.cx;
-               lpmmi->ptMinTrackSize.y = _min_wnd_size.cy;
-       }
-
-       SIZE    _min_wnd_size;
-
-protected:
-       HWND    _hwnd;
-       SIZE    _last_size;
-};
-
-
- /// Controller base template class for resizable dialogs
-template<typename BASE> struct ResizeController : public BASE
-{
-       typedef BASE super;
-
-       ResizeController(HWND hwnd)
-        :      super(hwnd),
-               _resize_mgr(hwnd)
-       {
-       }
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               switch(nmsg) {
-                 case PM_FRM_CALC_CLIENT:
-                       GetClientSpace((PRECT)lparam);
-                       return TRUE;
-
-                 case WM_SIZE:
-                       if (wparam != SIZE_MINIMIZED)
-                               _resize_mgr.HandleSize(LOWORD(lparam), HIWORD(lparam));
-                       goto def;
-
-                 case WM_GETMINMAXINFO:
-                       _resize_mgr.SetMinMaxInfo((LPMINMAXINFO)lparam);
-                       goto def;
-
-                 default: def:
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-       }
-
-       virtual void GetClientSpace(PRECT prect)
-       {
-                if (!IsIconic(this->_hwnd)) {
-                       GetClientRect(this->_hwnd, prect);
-                } else {
-                       WINDOWPLACEMENT wp;
-                       GetWindowPlacement(this->_hwnd, &wp);
-                       prect->left = prect->top = 0;
-                       prect->right = wp.rcNormalPosition.right-wp.rcNormalPosition.left-
-                               2*(GetSystemMetrics(SM_CXSIZEFRAME)+GetSystemMetrics(SM_CXEDGE));
-                       prect->bottom = wp.rcNormalPosition.bottom-wp.rcNormalPosition.top-
-                               2*(GetSystemMetrics(SM_CYSIZEFRAME)+GetSystemMetrics(SM_CYEDGE))-
-                               GetSystemMetrics(SM_CYCAPTION)-GetSystemMetrics(SM_CYMENUSIZE);
-               }
-       }
-
-protected:
-       ResizeManager _resize_mgr;
-};
-
-
- /**
-       This class constructs button controls.
-       The button will remain existent when the C++ Button object is destroyed.
-       There is no conjunction between C++ object and windows control life time.
- */
-struct Button : public WindowHandle
-{
-       Button(HWND parent, LPCTSTR text, int left, int top, int width, int height,
-                       int id, DWORD flags=WS_VISIBLE|WS_CHILD|BS_PUSHBUTTON, DWORD exStyle=0);
-};
-
-
- /**
-       This class constructs static controls.
-       The control will remain existent when the C++ object is destroyed.
-       There is no conjunction between C++ object and windows control life time.
- */
-struct Static : public WindowHandle
-{
-       Static(HWND parent, LPCTSTR text, int left, int top, int width, int height,
-                       int id, DWORD flags=WS_VISIBLE|WS_CHILD|SS_SIMPLE, DWORD ex_flags=0);
-};
-
-
- // control color message routing for ColorStatic and HyperlinkCtrl
-
-#define        PM_DISPATCH_CTLCOLOR    (WM_APP+0x08)
-
-template<typename BASE> struct CtlColorParent : public BASE
-{
-       typedef BASE super;
-
-       CtlColorParent(HWND hwnd)
-        : super(hwnd) {}
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               switch(nmsg) {
-                 case WM_CTLCOLOR:
-                 case WM_CTLCOLORBTN:
-                 case WM_CTLCOLORDLG:
-                 case WM_CTLCOLORSCROLLBAR:
-                 case WM_CTLCOLORSTATIC: {
-                       HWND hctl = (HWND) lparam;
-                       return SendMessage(hctl, PM_DISPATCH_CTLCOLOR, wparam, nmsg);
-                 }
-
-                 default:
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-       }
-};
-
-
-#define        PM_DISPATCH_DRAWITEM    (WM_APP+0x09)
-
- /// draw message routing for ColorButton and PictureButton
-template<typename BASE> struct OwnerDrawParent : public BASE
-{
-       typedef BASE super;
-
-       OwnerDrawParent(HWND hwnd)
-        : super(hwnd) {}
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               switch(nmsg) {
-                 case WM_DRAWITEM:
-                       if (wparam) {   // should there be drawn a control?
-                               HWND hctl = GetDlgItem(this->_hwnd, wparam);
-
-                               if (hctl)
-                                       return SendMessage(hctl, PM_DISPATCH_DRAWITEM, wparam, lparam);
-                       } /*else                // or is it a menu entry?
-                               ; */
-
-                       return 0;
-
-                 default:
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-       }
-};
-
-
- /**
-       Subclass button controls to draw them by using PM_DISPATCH_DRAWITEM
-       The owning window should use the OwnerDrawParent template to route owner draw messages to the buttons.
- */
-struct OwnerdrawnButton : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       OwnerdrawnButton(HWND hwnd)
-        :      super(hwnd) {}
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       virtual void DrawItem(LPDRAWITEMSTRUCT dis) = 0;
-};
-
-extern void DrawGrayText(HDC hdc, LPRECT pRect, LPCTSTR text, int dt_flags);
-
-
- /**
-       Subclass button controls to paint colored text labels.
-       The owning window should use the OwnerDrawParent template to route owner draw messages to the buttons.
- */
-/* not yet used
-struct ColorButton : public OwnerdrawnButton
-{
-       typedef OwnerdrawnButton super;
-
-       ColorButton(HWND hwnd, COLORREF textColor)
-        :      super(hwnd), _textColor(textColor) {}
-
-protected:
-       virtual void DrawItem(LPDRAWITEMSTRUCT dis);
-
-       COLORREF _textColor;
-};
-*/
-
-
-struct FlatButton : public OwnerdrawnButton
-{
-       typedef OwnerdrawnButton super;
-
-       FlatButton(HWND hwnd)
-        : super(hwnd), _active(false) {}
-
-       FlatButton(HWND owner, int id)
-        : super(GetDlgItem(owner, IDOK)), _active(false) {}
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-       virtual void DrawItem(LPDRAWITEMSTRUCT dis);
-
-       COLORREF _textColor;
-       COLORREF _activeColor;
-       bool    _active;
-};
-
-
- /**
-       Subclass button controls to paint pictures left to the labels.
-       The buttons should have set the style bit BS_OWNERDRAW.
-       The owning window should use the OwnerDrawParent template to route owner draw messages to the buttons.
- */
-struct PictureButton : public OwnerdrawnButton
-{
-       typedef OwnerdrawnButton super;
-
-       PictureButton(HWND hwnd, HICON hIcon, HBRUSH hbrush=GetSysColorBrush(COLOR_BTNFACE), bool flat=false)
-        :      super(hwnd), _hIcon(hIcon), _hBmp(0), _hBrush(hbrush), _flat(flat)
-       {
-               _cx = 16;
-               _cy = 16;
-       }
-
-       PictureButton(HWND hparent, int id, HICON hIcon, HBRUSH hbrush=GetSysColorBrush(COLOR_BTNFACE), bool flat=false)
-        :      super(GetDlgItem(hparent, id)), _hIcon(hIcon), _hBmp(0), _hBrush(hbrush), _flat(flat)
-       {
-               _cx = 16;
-               _cy = 16;
-       }
-
-       PictureButton(HWND hwnd, HBITMAP hBmp, HBRUSH hbrush=GetSysColorBrush(COLOR_BTNFACE), bool flat=false)
-        :      super(hwnd), _hIcon(0), _hBmp(hBmp), _hBrush(hbrush), _flat(flat)
-       {
-               BITMAP bmp;
-               GetObject(hBmp, sizeof(bmp), &bmp);
-               _cx = bmp.bmWidth;
-               _cy = bmp.bmHeight;
-       }
-
-       PictureButton(HWND hparent, int id, HBITMAP hBmp, HBRUSH hbrush=GetSysColorBrush(COLOR_BTNFACE), bool flat=false)
-        :      super(GetDlgItem(hparent, id)), _hIcon(0), _hBmp(hBmp), _hBrush(hbrush), _flat(flat)
-       {
-               BITMAP bmp;
-               GetObject(hBmp, sizeof(bmp), &bmp);
-               _cx = bmp.bmWidth;
-               _cy = bmp.bmHeight;
-       }
-
-protected:
-       virtual void DrawItem(LPDRAWITEMSTRUCT dis);
-
-       HICON   _hIcon;
-       HBITMAP _hBmp;
-       HBRUSH  _hBrush;
-
-       int             _cx;
-       int             _cy;
-
-       bool    _flat;
-};
-
-
-struct ColorStatic : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       ColorStatic(HWND hwnd, COLORREF textColor=RGB(255,0,0), HBRUSH hbrush_bkgnd=0, HFONT hfont=0)
-        :      super(hwnd),
-               _textColor(textColor),
-               _hbrush_bkgnd(hbrush_bkgnd),
-               _hfont(hfont)
-       {
-       }
-
-       ColorStatic(HWND owner, int id, COLORREF textColor=RGB(255,0,0), HBRUSH hbrush_bkgnd=0, HFONT hfont=0)
-        :      super(GetDlgItem(owner, id)),
-               _textColor(textColor),
-               _hbrush_bkgnd(hbrush_bkgnd),
-               _hfont(hfont)
-       {
-       }
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               if (nmsg == PM_DISPATCH_CTLCOLOR) {
-                       HDC hdc = (HDC) wparam;
-
-                       SetTextColor(hdc, _textColor);
-
-                       if (_hfont)
-                               SelectFont(hdc, _hfont);
-
-                       if (_hbrush_bkgnd)
-                               return (LRESULT)_hbrush_bkgnd;
-                       else {
-                               SetBkMode(hdc, TRANSPARENT);
-                               return (LRESULT)GetStockBrush(HOLLOW_BRUSH);
-                       }
-               } else
-                       return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       COLORREF        _textColor;
-       HBRUSH          _hbrush_bkgnd;
-       HFONT           _hfont;
-};
-
-
-  /// Hyperlink Controls
-
-struct HyperlinkCtrl : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       HyperlinkCtrl(HWND hwnd, COLORREF colorLink=RGB(0,0,255), COLORREF colorVisited=RGB(128,0,128));
-       HyperlinkCtrl(HWND owner, int id, COLORREF colorLink=RGB(0,0,255), COLORREF colorVisited=RGB(128,0,128));
-
-       ~HyperlinkCtrl();
-
-       String  _cmd;
-
-protected:
-       COLORREF _textColor;
-       COLORREF _colorVisited;
-       HFONT    _hfont;
-       HCURSOR _crsr_link;
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       void init();
-
-       bool LaunchLink()
-       {
-               if (!_cmd.empty()) {
-                       HINSTANCE hinst = ShellExecute(GetParent(_hwnd), _T("open"), _cmd, 0, 0, SW_SHOWNORMAL);
-                       return (int)hinst > HINSTANCE_ERROR;
-               }
-
-               return true;
-       }
-};
-
-
- /// encapsulation of tool tip controls
-struct ToolTip : public WindowHandle
-{
-       typedef WindowHandle super;
-
-       ToolTip(HWND owner);
-
-       void activate(BOOL active=TRUE)
-       {
-               SendMessage(_hwnd, TTM_ACTIVATE, active, 0);
-       }
-
-       void add(HWND hparent, HWND htool, LPCTSTR txt=LPSTR_TEXTCALLBACK, LPARAM lparam=0)
-       {
-               TOOLINFO ti = {
-                       sizeof(TOOLINFO), TTF_SUBCLASS|TTF_IDISHWND|TTF_TRANSPARENT, hparent, (UINT)htool,
-                       {0,0,0,0}, 0, (LPTSTR)txt, lparam
-               };
-
-#ifdef UNICODE ///@todo Why is it neccesary to try both TTM_ADDTOOLW and TTM_ADDTOOLW ?!
-               if (!SendMessage(_hwnd, TTM_ADDTOOLW, 0, (LPARAM)&ti))
-                       SendMessage(_hwnd, TTM_ADDTOOLA, 0, (LPARAM)&ti);
-#else
-               if (!SendMessage(_hwnd, TTM_ADDTOOLA, 0, (LPARAM)&ti))
-                       SendMessage(_hwnd, TTM_ADDTOOLW, 0, (LPARAM)&ti);
-#endif
-       }
-
-       void add(HWND hparent, UINT id, const RECT& rect, LPCTSTR txt=LPSTR_TEXTCALLBACK, LPARAM lparam=0)
-       {
-               TOOLINFO ti = {
-                       sizeof(TOOLINFO), TTF_SUBCLASS|TTF_TRANSPARENT, hparent, id,
-                       {rect.left,rect.top,rect.right,rect.bottom}, 0, (LPTSTR)txt, lparam
-               };
-
-#ifdef UNICODE
-               if (!SendMessage(_hwnd, TTM_ADDTOOLW, 0, (LPARAM)&ti))
-                       SendMessage(_hwnd, TTM_ADDTOOLA, 0, (LPARAM)&ti);
-#else
-               if (!SendMessage(_hwnd, TTM_ADDTOOLA, 0, (LPARAM)&ti))
-                       SendMessage(_hwnd, TTM_ADDTOOLW, 0, (LPARAM)&ti);
-#endif
-       }
-
-       void remove(HWND hparent, HWND htool)
-       {
-               TOOLINFO ti = {
-                       sizeof(TOOLINFO), TTF_IDISHWND, hparent, (UINT)htool,
-                       {0,0,0,0}, 0, 0, 0
-               };
-
-               SendMessage(_hwnd, TTM_DELTOOL, 0, (LPARAM)&ti);
-       }
-
-       void remove(HWND hparent, UINT id)
-       {
-               TOOLINFO ti = {
-                       sizeof(TOOLINFO), 0, hparent, id,
-                       {0,0,0,0}, 0, 0, 0
-               };
-
-               SendMessage(_hwnd, TTM_DELTOOL, 0, (LPARAM)&ti);
-       }
-};
-
-
-inline int ListView_GetItemData(HWND list_ctrl, int idx)
-{
-       LV_ITEM item;
-
-       item.mask = LVIF_PARAM;
-       item.iItem = idx;
-
-       if (!ListView_GetItem(list_ctrl, &item))
-               return 0;
-
-       return item.lParam;
-}
-
-inline int ListView_FindItemPara(HWND list_ctrl, LPARAM param)
-{
-       LVFINDINFO fi;
-
-       fi.flags = LVFI_PARAM;
-       fi.lParam = param;
-
-       return ListView_FindItem(list_ctrl, (unsigned)-1, &fi);
-}
-
-inline int ListView_GetFocusedItem(HWND list_ctrl)
-{
-       int idx = ListView_GetItemCount(list_ctrl);
-
-       while(--idx >= 0)
-               if (ListView_GetItemState(list_ctrl, idx, LVIS_FOCUSED))
-                       break;
-
-       return idx;
-}
-
-
- /// sorting of list controls
-struct ListSort : public WindowHandle
-{
-       ListSort(HWND hwndListview, PFNLVCOMPARE compare_fct);
-
-       void    toggle_sort(int idx);
-       void    sort();
-
-       int             _sort_crit;
-       bool    _direction;
-
-protected:
-       PFNLVCOMPARE _compare_fct;
-
-       static int CALLBACK CompareFunc(LPARAM lparam1, LPARAM lparam2, LPARAM lparamSort);
-};
-
-
-inline LPARAM TreeView_GetItemData(HWND hwndTreeView, HTREEITEM hItem)
-{
-       TVITEM tvItem;
-
-       tvItem.mask = TVIF_PARAM;
-       tvItem.hItem = hItem;
-
-       if (!TreeView_GetItem(hwndTreeView, &tvItem))
-               return 0;
-
-       return tvItem.lParam;
-}
-
-
-enum {TRAYBUTTON_LEFT=0, TRAYBUTTON_RIGHT, TRAYBUTTON_MIDDLE};
-
-#define        PM_TRAYICON             (WM_APP+0x20)
-
-#define        WINMSG_TASKBARCREATED   TEXT("TaskbarCreated")
-
-
-struct TrayIcon
-{
-       TrayIcon(HWND hparent, UINT id)
-        :      _hparent(hparent), _id(id) {}
-
-       ~TrayIcon()
-               {Remove();}
-
-       void    Add(HICON hIcon, LPCTSTR tooltip=NULL)
-               {Set(NIM_ADD, _id, hIcon, tooltip);}
-
-       void    Modify(HICON hIcon, LPCTSTR tooltip=NULL)
-               {Set(NIM_MODIFY, _id, hIcon, tooltip);}
-
-       void    Remove()
-       {
-               NOTIFYICONDATA nid = {
-                       sizeof(NOTIFYICONDATA), // cbSize
-                       _hparent,                               // hWnd
-                       _id,                                    // uID
-               };
-
-               Shell_NotifyIcon(NIM_DELETE, &nid);
-       }
-
-protected:
-       HWND    _hparent;
-       UINT    _id;
-
-       void    Set(DWORD dwMessage, UINT id, HICON hIcon, LPCTSTR tooltip=NULL)
-       {
-               NOTIFYICONDATA nid = {
-                       sizeof(NOTIFYICONDATA), // cbSize
-                       _hparent,                               // hWnd
-                       id,                                             // uID
-                       NIF_MESSAGE|NIF_ICON,   // uFlags
-                       PM_TRAYICON,                    // uCallbackMessage
-                       hIcon                                   // hIcon
-               };
-
-               if (tooltip)
-                       lstrcpyn(nid.szTip, tooltip, COUNTOF(nid.szTip));
-
-               if (nid.szTip[0])
-                       nid.uFlags |= NIF_TIP;
-
-               Shell_NotifyIcon(dwMessage, &nid);
-       }
-};
-
-
-template<typename BASE> struct TrayIconControllerTemplate : public BASE
-{
-       typedef BASE super;
-
-       TrayIconControllerTemplate(HWND hwnd) : BASE(hwnd),
-               WM_TASKBARCREATED(RegisterWindowMessage(WINMSG_TASKBARCREATED))
-       {
-       }
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               if (nmsg == PM_TRAYICON) {
-                       switch(lparam) {
-                         case WM_MOUSEMOVE:
-                               TrayMouseOver(wparam);
-                               break;
-
-                         case WM_LBUTTONDOWN:
-                               TrayClick(wparam, TRAYBUTTON_LEFT);
-                               break;
-
-                         case WM_LBUTTONDBLCLK:
-                               TrayDblClick(wparam, TRAYBUTTON_LEFT);
-                               break;
-
-                         case WM_RBUTTONDOWN:
-                               TrayClick(wparam, TRAYBUTTON_RIGHT);
-                               break;
-
-                         case WM_RBUTTONDBLCLK:
-                               TrayDblClick(wparam, TRAYBUTTON_RIGHT);
-                               break;
-
-                         case WM_MBUTTONDOWN:
-                               TrayClick(wparam, TRAYBUTTON_MIDDLE);
-                               break;
-
-                         case WM_MBUTTONDBLCLK:
-                               TrayDblClick(wparam, TRAYBUTTON_MIDDLE);
-                               break;
-                       }
-
-                       return 0;
-               } else if (nmsg == WM_TASKBARCREATED) {
-                       AddTrayIcons();
-                       return 0;
-               } else
-                       return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       virtual void AddTrayIcons() = 0;
-       virtual void TrayMouseOver(UINT id) {}
-       virtual void TrayClick(UINT id, int btn) {}
-       virtual void TrayDblClick(UINT id, int btn) {}
-
-protected:
-       const UINT WM_TASKBARCREATED;
-};
-
-
-struct EditController : public SubclassedWindow
-{
-       typedef SubclassedWindow super;
-
-       EditController(HWND hwnd)
-        :      super(hwnd)
-       {
-       }
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               if (nmsg==WM_KEYDOWN && wparam==VK_RETURN) {
-                       SendParent(WM_COMMAND, MAKEWPARAM(GetDlgCtrlID(_hwnd),1), (LPARAM)_hwnd);
-                       return 0;
-               } else
-                       return super::WndProc(nmsg, wparam, lparam);
-       }
-};
diff --git a/reactos/subsys/system/ibrowser/utility/xmlstorage.cpp b/reactos/subsys/system/ibrowser/utility/xmlstorage.cpp
deleted file mode 100644 (file)
index 0a2dc79..0000000
+++ /dev/null
@@ -1,623 +0,0 @@
-
- //
- // XML storage classes
- //
- // xmlstorage.cpp
- //
- // Copyright (c) 2004, 2005 Martin Fuchs <martin-fuchs@gmx.net>
- //
-
-
-/*
-
-  All rights reserved.
-
-  Redistribution and use in source and binary forms, with or without
-  modification, are permitted provided that the following conditions are met:
-
-  * Redistributions of source code must retain the above copyright
-       notice, this list of conditions and the following disclaimer.
-  * Redistributions in binary form must reproduce the above copyright
-       notice, this list of conditions and the following disclaimer in
-       the documentation and/or other materials provided with the
-       distribution.
-
-  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-  ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-  LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-  CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-  SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-  INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-  CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-  POSSIBILITY OF SUCH DAMAGE.
-
-*/
-
-//#include "xmlstorage.h"
-#include <precomp.h>
-
-
- // work around GCC's wide string constant bug
-#ifdef __GNUC__
-const LPCXSSTR XMLStorage::XS_TRUE = XS_TEXT("true");
-const LPCXSSTR XMLStorage::XS_FALSE = XS_TEXT("false");
-const LPCXSSTR XMLStorage::XS_NUMBERFMT = XS_TEXT("%d");
-#endif
-
-
-namespace XMLStorage {
-
-
-static std::string unescape(const char* s, char b='"', char e='"')
-{
-       const char* end = s + strlen(s);
-
-//     if (*s == b)
-//             ++s;
-//
-//     if (end>s && end[-1]==e)
-//             --end;
-
-       if (*s == b)
-               if (end>s && end[-1]==e)
-                       ++s, --end;
-
-       return std::string(s, end-s);
-}
-
-static std::string unescape(const char* s, int l, char b='"', char e='"')
-{
-       const char* end = s + l;
-
-//     if (*s == b)
-//             ++s;
-//
-//     if (end>s && end[-1]==e)
-//             --end;
-
-       if (*s == b)
-               if (end>s && end[-1]==e)
-                       ++s, --end;
-
-       return std::string(s, end-s);
-}
-
-
- /// move XPath like to position in XML tree
-bool XMLPos::go(const char* path)
-{
-       XMLNode* node = _cur;
-
-        // Is this an absolute path?
-       if (*path == '/') {
-               node = _root;
-               ++path;
-       }
-
-       node = node->find_relative(path);
-
-       if (node) {
-               go_to(node);
-               return true;
-       } else
-               return false;
-}
-
- /// move XPath like to position in XML tree
-bool const_XMLPos::go(const char* path)
-{
-       const XMLNode* node = _cur;
-
-        // Is this an absolute path?
-       if (*path == '/') {
-               node = _root;
-               ++path;
-       }
-
-       node = node->find_relative(path);
-
-       if (node) {
-               go_to(node);
-               return true;
-       } else
-               return false;
-}
-
-
-const XMLNode* XMLNode::find_relative(const char* path) const
-{
-       const XMLNode* node = this;
-
-        // parse relative path
-       while(*path) {
-               const char* slash = strchr(path, '/');
-               if (slash == path)
-                       return NULL;
-
-               int l = slash? slash-path: strlen(path);
-               std::string comp(path, l);
-               path += l;
-
-                // look for [n] and [@attr_name="attr_value"] expressions in path components
-               const char* bracket = strchr(comp.c_str(), '[');
-               l = bracket? bracket-comp.c_str(): comp.length();
-               std::string child_name(comp.c_str(), l);
-               std::string attr_name, attr_value;
-
-               int n = 0;
-               if (bracket) {
-                       std::string expr = unescape(bracket, '[', ']');
-                       const char* p = expr.c_str();
-
-                       n = atoi(p);    // read index number
-
-                       if (n)
-                               n = n - 1;      // convert into zero based index
-
-                       const char* at = strchr(p, '@');
-
-                       if (at) {
-                               p = at + 1;
-                               const char* equal = strchr(p, '=');
-
-                                // read attribute name and value
-                               if (equal) {
-                                       attr_name = unescape(p, equal-p);
-                                       attr_value = unescape(equal+1);
-                               }
-                       }
-               }
-
-               if (attr_name.empty())
-                        // search n.th child node with specified name
-                       node = node->find(child_name, n);
-               else
-                        // search n.th child node with specified name and matching attribute value
-                       node = node->find(child_name, attr_name, attr_value, n);
-
-               if (!node)
-                       return NULL;
-
-               if (*path == '/')
-                       ++path;
-       }
-
-       return node;
-}
-
-XMLNode* XMLNode::create_relative(const char* path)
-{
-       XMLNode* node = this;
-
-        // parse relative path
-       while(*path) {
-               const char* slash = strchr(path, '/');
-               if (slash == path)
-                       return NULL;
-
-               int l = slash? slash-path: strlen(path);
-               std::string comp(path, l);
-               path += l;
-
-                // look for [n] and [@attr_name="attr_value"] expressions in path components
-               const char* bracket = strchr(comp.c_str(), '[');
-               l = bracket? bracket-comp.c_str(): comp.length();
-               std::string child_name(comp.c_str(), l);
-               std::string attr_name, attr_value;
-
-               int n = 0;
-               if (bracket) {
-                       std::string expr = unescape(bracket, '[', ']');
-                       const char* p = expr.c_str();
-
-                       n = atoi(p);    // read index number
-
-                       if (n)
-                               n = n - 1;      // convert into zero based index
-
-                       const char* at = strchr(p, '@');
-
-                       if (at) {
-                               p = at + 1;
-                               const char* equal = strchr(p, '=');
-
-                                // read attribute name and value
-                               if (equal) {
-                                       attr_name = unescape(p, equal-p);
-                                       attr_value = unescape(equal+1);
-                               }
-                       }
-               }
-
-               XMLNode* child;
-
-               if (attr_name.empty())
-                        // search n.th child node with specified name
-                       child = node->find(child_name, n);
-               else
-                        // search n.th child node with specified name and matching attribute value
-                       child = node->find(child_name, attr_name, attr_value, n);
-
-               if (!child) {
-                       child = new XMLNode(child_name);
-                       node->add_child(child);
-
-                       if (!attr_name.empty())
-                               (*node)[attr_name] = attr_value;
-               }
-
-               node = child;
-
-               if (*path == '/')
-                       ++path;
-       }
-
-       return node;
-}
-
-
- /// read XML stream into XML tree below _pos
-XML_Status XMLReaderBase::read()
-{
-       XML_Status status = XML_STATUS_OK;
-
-       while(status == XML_STATUS_OK) {
-               char* buffer = (char*) XML_GetBuffer(_parser, BUFFER_LEN);
-
-               int l = read_buffer(buffer, BUFFER_LEN);
-               if (l < 0)
-                       break;
-
-               status = XML_ParseBuffer(_parser, l, false);
-       }
-
-       if (status != XML_STATUS_ERROR)
-               status = XML_ParseBuffer(_parser, 0, true);
-
-       if (_pos->_children.empty())
-               _pos->_trailing.append(_content);
-       else
-               _pos->_children.back()->_trailing.append(_content);
-
-       _content.erase();
-
-       return status;
-}
-
-
- /// store XML version and encoding into XML reader
-void XMLCALL XMLReaderBase::XML_XmlDeclHandler(void* userData, const XML_Char* version, const XML_Char* encoding, int standalone)
-{
-       XMLReaderBase* pReader = (XMLReaderBase*) userData;
-
-       if (version)
-               pReader->_xml_version = version;
-
-       if (encoding)
-               pReader->_encoding = encoding;
-}
-
- /// notifications about XML start tag
-void XMLCALL XMLReaderBase::XML_StartElementHandler(void* userData, const XML_Char* name, const XML_Char** atts)
-{
-       XMLReaderBase* pReader = (XMLReaderBase*) userData;
-       XMLPos& pos = pReader->_pos;
-
-        // search for end of first line
-       const char* s = pReader->_content.c_str();
-       const char* p = s;
-       const char* e = p + pReader->_content.length();
-
-       for(; p<e; ++p)
-               if (*p == '\n') {
-                       ++p;
-                       break;
-               }
-
-       if (p != s)
-               if (pos->_children.empty()) {   // no children in last node?
-                       if (pReader->_last_tag == TAG_START)
-                               pos->_content.append(s, p-s);
-                       else if (pReader->_last_tag == TAG_END)
-                               pos->_trailing.append(s, p-s);
-                       // else TAG_NONE -> don't store white space in root node
-               } else
-                       pos->_children.back()->_trailing.append(s, p-s);
-
-       std::string leading;
-
-       if (p != e)
-               leading.assign(p, e-p);
-
-       XMLNode* node = new XMLNode(String_from_XML_Char(name), leading);
-
-       pos.add_down(node);
-
-       while(*atts) {
-               const XML_Char* attr_name = *atts++;
-               const XML_Char* attr_value = *atts++;
-
-               (*node)[String_from_XML_Char(attr_name)] = String_from_XML_Char(attr_value);
-       }
-
-       pReader->_last_tag = TAG_START;
-       pReader->_content.erase();
-}
-
- /// notifications about XML end tag
-void XMLCALL XMLReaderBase::XML_EndElementHandler(void* userData, const XML_Char* name)
-{
-       XMLReaderBase* pReader = (XMLReaderBase*) userData;
-       XMLPos& pos = pReader->_pos;
-
-        // search for end of first line
-       const char* s = pReader->_content.c_str();
-       const char* p = s;
-       const char* e = p + pReader->_content.length();
-
-       for(; p<e; ++p)
-               if (*p == '\n') {
-                       ++p;
-                       break;
-               }
-
-       if (p != s)
-               if (pos->_children.empty())     // no children in current node?
-                       pos->_content.append(s, p-s);
-               else
-                       if (pReader->_last_tag == TAG_START)
-                               pos->_content.append(s, p-s);
-                       else
-                               pos->_children.back()->_trailing.append(s, p-s);
-
-       if (p != e)
-               pos->_end_leading.assign(p, e-p);
-
-       pos.back();
-
-       pReader->_last_tag = TAG_END;
-       pReader->_content.erase();
-}
-
- /// store content, white space and comments
-void XMLCALL XMLReaderBase::XML_DefaultHandler(void* userData, const XML_Char* s, int len)
-{
-       XMLReaderBase* pReader = (XMLReaderBase*) userData;
-
-       pReader->_content.append(s, len);
-}
-
-
-std::string XMLReaderBase::get_error_string() const
-{
-       XML_Error error = XML_GetErrorCode(_parser);
-
-       switch(error) {
-         case XML_ERROR_NONE:                                                          return "XML_ERROR_NONE";
-         case XML_ERROR_NO_MEMORY:                                                     return "XML_ERROR_NO_MEMORY";
-         case XML_ERROR_SYNTAX:                                                        return "XML_ERROR_SYNTAX";
-         case XML_ERROR_NO_ELEMENTS:                                           return "XML_ERROR_NO_ELEMENTS";
-         case XML_ERROR_INVALID_TOKEN:                                         return "XML_ERROR_INVALID_TOKEN";
-         case XML_ERROR_UNCLOSED_TOKEN:                                        return "XML_ERROR_UNCLOSED_TOKEN";
-         case XML_ERROR_PARTIAL_CHAR:                                          return "XML_ERROR_PARTIAL_CHAR";
-         case XML_ERROR_TAG_MISMATCH:                                          return "XML_ERROR_TAG_MISMATCH";
-         case XML_ERROR_DUPLICATE_ATTRIBUTE:                           return "XML_ERROR_DUPLICATE_ATTRIBUTE";
-         case XML_ERROR_JUNK_AFTER_DOC_ELEMENT:                        return "XML_ERROR_JUNK_AFTER_DOC_ELEMENT";
-         case XML_ERROR_PARAM_ENTITY_REF:                                      return "XML_ERROR_PARAM_ENTITY_REF";
-         case XML_ERROR_UNDEFINED_ENTITY:                                      return "XML_ERROR_UNDEFINED_ENTITY";
-         case XML_ERROR_RECURSIVE_ENTITY_REF:                          return "XML_ERROR_RECURSIVE_ENTITY_REF";
-         case XML_ERROR_ASYNC_ENTITY:                                          return "XML_ERROR_ASYNC_ENTITY";
-         case XML_ERROR_BAD_CHAR_REF:                                          return "XML_ERROR_BAD_CHAR_REF";
-         case XML_ERROR_BINARY_ENTITY_REF:                                     return "XML_ERROR_BINARY_ENTITY_REF";
-         case XML_ERROR_ATTRIBUTE_EXTERNAL_ENTITY_REF:         return "XML_ERROR_ATTRIBUTE_EXTERNAL_ENTITY_REF";
-         case XML_ERROR_MISPLACED_XML_PI:                                      return "XML_ERROR_MISPLACED_XML_PI";
-         case XML_ERROR_UNKNOWN_ENCODING:                                      return "XML_ERROR_UNKNOWN_ENCODING";
-         case XML_ERROR_INCORRECT_ENCODING:                            return "XML_ERROR_INCORRECT_ENCODING";
-         case XML_ERROR_UNCLOSED_CDATA_SECTION:                        return "XML_ERROR_UNCLOSED_CDATA_SECTION";
-         case XML_ERROR_EXTERNAL_ENTITY_HANDLING:                      return "XML_ERROR_EXTERNAL_ENTITY_HANDLING";
-         case XML_ERROR_NOT_STANDALONE:                                        return "XML_ERROR_NOT_STANDALONE";
-         case XML_ERROR_UNEXPECTED_STATE:                                      return "XML_ERROR_UNEXPECTED_STATE";
-         case XML_ERROR_ENTITY_DECLARED_IN_PE:                         return "XML_ERROR_ENTITY_DECLARED_IN_PE";
-         case XML_ERROR_FEATURE_REQUIRES_XML_DTD:                      return "XML_ERROR_FEATURE_REQUIRES_XML_DTD";
-         case XML_ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING:      return "XML_ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING";
-         case XML_ERROR_UNBOUND_PREFIX:                                        return "XML_ERROR_UNBOUND_PREFIX";
- // EXPAT version >= 1.95.8
-#if XML_MAJOR_VERSION>1 || (XML_MAJOR_VERSION==1 && XML_MINOR_VERSION>95) || (XML_MAJOR_VERSION==1 && XML_MINOR_VERSION==95 && XML_MICRO_VERSION>7)
-         case XML_ERROR_UNDECLARING_PREFIX:                            return "XML_ERROR_UNDECLARING_PREFIX";
-         case XML_ERROR_INCOMPLETE_PE:                                         return "XML_ERROR_INCOMPLETE_PE";
-         case XML_ERROR_XML_DECL:                                                      return "XML_ERROR_XML_DECL";
-         case XML_ERROR_TEXT_DECL:                                                     return "XML_ERROR_TEXT_DECL";
-         case XML_ERROR_PUBLICID:                                                      return "XML_ERROR_PUBLICID";
-         case XML_ERROR_SUSPENDED:                                                     return "XML_ERROR_SUSPENDED";
-         case XML_ERROR_NOT_SUSPENDED:                                         return "XML_ERROR_NOT_SUSPENDED";
-         case XML_ERROR_ABORTED:                                                       return "XML_ERROR_ABORTED";
-         case XML_ERROR_FINISHED:                                                      return "XML_ERROR_FINISHED";
-         case XML_ERROR_SUSPEND_PE:                                            return "XML_ERROR_SUSPEND_PE";
-//#endif
-//#if XML_MAJOR_VERSION>=2
-               /* Added in 2.0. */
-         case XML_ERROR_RESERVED_PREFIX_XML:                           return "XML_ERROR_RESERVED_PREFIX_XML";
-         case XML_ERROR_RESERVED_PREFIX_XMLNS:                         return "XML_ERROR_RESERVED_PREFIX_XMLNS";
-         case XML_ERROR_RESERVED_NAMESPACE_URI:                        return "XML_ERROR_RESERVED_NAMESPACE_URI";
-#endif
-       }
-
-       std::ostringstream out;
-
-       out << "XML parser error #" << error;
-
-       return out.str();
-}
-
-
-std::string EncodeXMLString(const XS_String& str)
-{
-       LPCXSSTR s = str.c_str();
-       LPXSSTR buffer = (LPXSSTR)alloca(5*sizeof(XS_CHAR)*XS_len(s));  // worst case. "&amp;"
-       LPXSSTR o = buffer;
-
-       for(LPCXSSTR p=s; *p; ++p)
-               switch(*p) {
-                 case '&':
-                       *o++ = '&';     *o++ = 'a';     *o++ = 'm';     *o++ = 'p';     *o++ = ';';
-                       break;
-
-                 case '<':
-                       *o++ = '&';     *o++ = 'l'; *o++ = 't'; *o++ = ';';
-                       break;
-
-                 case '>':
-                       *o++ = '&';     *o++ = 'g'; *o++ = 't'; *o++ = ';';
-                       break;
-
-                 case '"':
-                       *o++ = '&';     *o++ = 'q'; *o++ = 'u'; *o++ = 'o'; *o++ = 't'; *o++ = ';';
-                       break;
-
-                 case '\'':
-                       *o++ = '&';     *o++ = 'a'; *o++ = 'p'; *o++ = 'o'; *o++ = 's'; *o++ = ';';
-                       break;
-
-                 default:
-                       *o++ = *p;
-               }
-
-#ifdef XS_STRING_UTF8
-       return XS_String(buffer, o-buffer);
-#else
-       return get_utf8(buffer, o-buffer);
-#endif
-}
-
-XS_String DecodeXMLString(const XS_String& str)
-{
-       LPCXSSTR s = str.c_str();
-       LPXSSTR buffer = (LPXSSTR)alloca(sizeof(XS_CHAR)*XS_len(s));
-       LPXSSTR o = buffer;
-
-       for(LPCXSSTR p=s; *p; ++p)
-               if (*p == '&') {
-                       if (!XS_nicmp(p+1, XS_TEXT("lt;"), 3)) {
-                               *o++ = '<';
-                               p += 3;
-                       } else if (!XS_nicmp(p+1, XS_TEXT("gt;"), 3)) {
-                               *o++ = '>';
-                               p += 3;
-                       } else if (!XS_nicmp(p+1, XS_TEXT("amp;"), 4)) {
-                               *o++ = '&';
-                               p += 4;
-                       } else if (!XS_nicmp(p+1, XS_TEXT("quot;"), 5)) {
-                               *o++ = '"';
-                               p += 5;
-                       } else if (!XS_nicmp(p+1, XS_TEXT("apos;"), 5)) {
-                               *o++ = '\'';
-                               p += 5;
-                       } else
-                               *o++ = *p;
-               } else
-                       *o++ = *p;
-
-       return XS_String(buffer, o-buffer);
-}
-
-
- /// write node with children tree to output stream using original white space
-void XMLNode::write_worker(std::ostream& out, int indent) const
-{
-       out << _leading << '<' << EncodeXMLString(*this);
-
-       for(AttributeMap::const_iterator it=_attributes.begin(); it!=_attributes.end(); ++it)
-               out << ' ' << EncodeXMLString(it->first) << "=\"" << EncodeXMLString(it->second) << "\"";
-
-       if (!_children.empty() || !_content.empty()) {
-               out << '>' << _content;
-
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it)
-                       (*it)->write_worker(out, indent+1);
-
-               out << _end_leading << "</" << EncodeXMLString(*this) << '>';
-       } else
-               out << "/>";
-
-       out << _trailing;
-}
-
-
- /// pretty print node with children tree to output stream
-void XMLNode::pretty_write_worker(std::ostream& out, int indent) const
-{
-       for(int i=indent; i--; )
-               out << XML_INDENT_SPACE;
-
-       out << '<' << EncodeXMLString(*this);
-
-       for(AttributeMap::const_iterator it=_attributes.begin(); it!=_attributes.end(); ++it)
-               out << ' ' << EncodeXMLString(it->first) << "=\"" << EncodeXMLString(it->second) << "\"";
-
-       if (!_children.empty() || !_content.empty()) {
-               out << ">\n";
-
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it)
-                       (*it)->pretty_write_worker(out, indent+1);
-
-               for(int i=indent; i--; )
-                       out << XML_INDENT_SPACE;
-
-               out << "</" << EncodeXMLString(*this) << ">\n";
-       } else
-               out << "/>\n";
-}
-
-
- /// write node with children tree to output stream using smart formating
-void XMLNode::smart_write_worker(std::ostream& out, int indent) const
-{
-       if (_leading.empty())
-               for(int i=indent; i--; )
-                       out << XML_INDENT_SPACE;
-       else
-               out << _leading;
-
-       out << '<' << EncodeXMLString(*this);
-
-       for(AttributeMap::const_iterator it=_attributes.begin(); it!=_attributes.end(); ++it)
-               out << ' ' << EncodeXMLString(it->first) << "=\"" << EncodeXMLString(it->second) << "\"";
-
-       if (_children.empty() && _content.empty())
-               out << "/>";
-       else {
-               out << '>';
-
-               if (_content.empty())
-                       out << '\n';
-               else
-                       out << _content;
-
-               Children::const_iterator it = _children.begin();
-
-               if (it != _children.end()) {
-                       for(; it!=_children.end(); ++it)
-                               (*it)->smart_write_worker(out, indent+1);
-
-                       if (_end_leading.empty())
-                               for(int i=indent; i--; )
-                                       out << XML_INDENT_SPACE;
-                       else
-                               out << _end_leading;
-               } else
-                       out << _end_leading;
-
-               out << "</" << EncodeXMLString(*this) << '>';
-       }
-
-       if (_trailing.empty())
-               out << '\n';
-       else
-               out << _trailing;
-}
-
-
-}      // namespace XMLStorage
diff --git a/reactos/subsys/system/ibrowser/utility/xmlstorage.h b/reactos/subsys/system/ibrowser/utility/xmlstorage.h
deleted file mode 100644 (file)
index f3ef5cf..0000000
+++ /dev/null
@@ -1,1733 +0,0 @@
-
- //
- // XML storage classes
- //
- // xmlstorage.h
- //
- // Copyright (c) 2004, 2005 Martin Fuchs <martin-fuchs@gmx.net>
- //
-
-
-/*
-
-  All rights reserved.
-
-  Redistribution and use in source and binary forms, with or without
-  modification, are permitted provided that the following conditions are met:
-
-  * Redistributions of source code must retain the above copyright
-       notice, this list of conditions and the following disclaimer.
-  * Redistributions in binary form must reproduce the above copyright
-       notice, this list of conditions and the following disclaimer in
-       the documentation and/or other materials provided with the
-       distribution.
-
-  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-  ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-  LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-  CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-  SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-  INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-  CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-  POSSIBILITY OF SUCH DAMAGE.
-
-*/
-
-#ifndef _XMLSTORAGE_H
-
-#include <expat/expat.h>
-
-#ifdef _MSC_VER
-#pragma comment(lib, "libexpat.lib")
-#pragma warning(disable: 4786)
-#endif
-
-
-#include <windows.h>   // for LPCTSTR
-
-#ifdef UNICODE
-#define _UNICODE
-#endif
-
-#include <tchar.h>
-#include <malloc.h>
-
-#include <fstream>
-#include <sstream>
-#include <string>
-#include <stack>
-#include <list>
-#include <map>
-
-
-#ifndef BUFFER_LEN
-#define BUFFER_LEN 2048
-#endif
-
-
-namespace XMLStorage {
-
-
-#ifndef XS_String
-
-#ifdef XS_STRING_UTF8
-#define        XS_CHAR char
-#define        XS_TEXT(x) x
-#define LPXSSTR LPSTR
-#define LPCXSSTR LPCSTR
-#define        XS_icmp stricmp
-#define        XS_nicmp strnicmp
-#define        XS_toi atoi
-#define        XS_len strlen
-#define        XS_sprintf sprintf
-#define        XS_vsprintf vsprintf
-#else
-#define        XS_CHAR TCHAR
-#define        XS_TEXT(x) TEXT(x)
-#define LPXSSTR LPTSTR
-#define LPCXSSTR LPCTSTR
-#define        XS_icmp _tcsicmp
-#define        XS_nicmp _tcsnicmp
-#define        XS_toi _ttoi
-#define        XS_len _tcslen
-#define        XS_sprintf _stprintf
-#define        XS_vsprintf _vstprintf
-#endif
-
-#if defined(_STRING_DEFINED) && !defined(XS_STRING_UTF8)
-
-#define        XS_String String
-
-#else // _STRING_DEFINED, !XS_STRING_UTF8
-
- /// string class for TCHAR strings
-
-struct XS_String
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
- : public std::wstring
-#else
- : public std::string
-#endif
-{
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-       typedef std::wstring super;
-#else
-       typedef std::string super;
-#endif
-
-       XS_String() {}
-
-       XS_String(LPCXSSTR s) {if (s) super::assign(s);}
-       XS_String(LPCXSSTR s, int l) : super(s, l) {}
-
-       XS_String(const super& other) : super(other) {}
-       XS_String(const XS_String& other) : super(other) {}
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-       XS_String(LPCSTR s) {assign(s);}
-       XS_String(LPCSTR s, int l) {assign(s, l);}
-       XS_String(const std::string& other) {assign(other.c_str());}
-       XS_String& operator=(LPCSTR s) {assign(s); return *this;}
-       void assign(LPCSTR s) {if (s) {int bl=strlen(s); LPWSTR b=(LPWSTR)alloca(sizeof(WCHAR)*bl); super::assign(b, MultiByteToWideChar(CP_ACP, 0, s, bl, b, bl));} else erase();}
-       void assign(LPCSTR s, int l) {if (s) {int bl=l; LPWSTR b=(LPWSTR)alloca(sizeof(WCHAR)*bl); super::assign(b, MultiByteToWideChar(CP_ACP, 0, s, l, b, bl));} else erase();}
-#else
-       XS_String(LPCWSTR s) {assign(s);}
-       XS_String(LPCWSTR s, int l) {assign(s, l);}
-       XS_String(const std::wstring& other) {assign(other.c_str());}
-       XS_String& operator=(LPCWSTR s) {assign(s); return *this;}
-#ifdef XS_STRING_UTF8
-       void assign(const XS_String& s) {assign(s.c_str());}
-       void assign(LPCWSTR s) {if (s) {int bl=wcslen(s); LPSTR b=(LPSTR)alloca(bl); super::assign(b, WideCharToMultiByte(CP_UTF8, 0, s, bl, b, bl, 0, 0));} else erase();}
-       void assign(LPCWSTR s, int l) {int bl=l; if (s) {LPSTR b=(LPSTR)alloca(bl); super::assign(b, WideCharToMultiByte(CP_UTF8, 0, s, l, b, bl, 0, 0));} else erase();}
-#else // if !UNICODE && !XS_STRING_UTF8
-       void assign(LPCWSTR s) {if (s) {int bl=wcslen(s); LPSTR b=(LPSTR)alloca(bl); super::assign(b, WideCharToMultiByte(CP_ACP, 0, s, bl, b, bl, 0, 0));} else erase();}
-       void assign(LPCWSTR s, int l) {int bl=l; if (s) {LPSTR b=(LPSTR)alloca(bl); super::assign(b, WideCharToMultiByte(CP_ACP, 0, s, l, b, bl, 0, 0));} else erase();}
-#endif
-#endif
-
-       XS_String& operator=(LPCXSSTR s) {if (s) super::assign(s); else erase(); return *this;}
-       XS_String& operator=(const super& s) {super::assign(s); return *this;}
-       void assign(LPCXSSTR s) {super::assign(s);}
-       void assign(LPCXSSTR s, int l) {super::assign(s, l);}
-
-       operator LPCXSSTR() const {return c_str();}
-
-#ifdef XS_STRING_UTF8
-       operator std::wstring() const {int bl=length(); LPWSTR b=(LPWSTR)alloca(sizeof(WCHAR)*bl); return std::wstring(b, MultiByteToWideChar(CP_UTF8, 0, c_str(), bl, b, bl));}
-#elif defined(UNICODE)
-       operator std::string() const {int bl=length(); LPSTR b=(LPSTR)alloca(bl); return std::string(b, WideCharToMultiByte(CP_ACP, 0, c_str(), bl, b, bl, 0, 0));}
-#else
-       operator std::wstring() const {int bl=length(); LPWSTR b=(LPWSTR)alloca(sizeof(WCHAR)*bl); return std::wstring(b, MultiByteToWideChar(CP_ACP, 0, c_str(), bl, b, bl));}
-#endif
-
-       XS_String& printf(LPCXSSTR fmt, ...)
-       {
-               va_list l;
-               XS_CHAR b[BUFFER_LEN];
-
-               va_start(l, fmt);
-               super::assign(b, XS_vsprintf(b, fmt, l));
-               va_end(l);
-
-               return *this;
-       }
-
-       XS_String& vprintf(LPCXSSTR fmt, va_list l)
-       {
-               XS_CHAR b[BUFFER_LEN];
-
-               super::assign(b, XS_vsprintf(b, fmt, l));
-
-               return *this;
-       }
-
-       XS_String& appendf(LPCXSSTR fmt, ...)
-       {
-               va_list l;
-               XS_CHAR b[BUFFER_LEN];
-
-               va_start(l, fmt);
-               super::append(b, XS_vsprintf(b, fmt, l));
-               va_end(l);
-
-               return *this;
-       }
-
-       XS_String& vappendf(LPCXSSTR fmt, va_list l)
-       {
-               XS_CHAR b[BUFFER_LEN];
-
-               super::append(b, XS_vsprintf(b, fmt, l));
-
-               return *this;
-       }
-};
-
-#endif // _STRING_DEFINED, !XS_STRING_UTF8
-
-#endif // XS_String
-
-
-#ifndef XS_STRING_UTF8
-
-inline void assign_utf8(XS_String& s, const char* str)
-{
-       int lutf8 = strlen(str);
-
-#ifdef UNICODE
-       LPTSTR buffer = (LPTSTR)alloca(sizeof(TCHAR)*lutf8);
-       int l = MultiByteToWideChar(CP_UTF8, 0, str, lutf8, buffer, lutf8);
-#else
-       LPWSTR wbuffer = (LPWSTR)alloca(sizeof(WCHAR)*lutf8);
-       int l = MultiByteToWideChar(CP_UTF8, 0, str, lutf8, wbuffer, lutf8);
-
-       int bl=2*l; LPSTR buffer = (LPSTR)alloca(bl);
-       l = WideCharToMultiByte(CP_ACP, 0, wbuffer, l, buffer, bl, 0, 0);
-#endif
-
-       s.assign(buffer, l);
-}
-
-inline std::string get_utf8(LPCTSTR s, int l)
-{
-#ifdef UNICODE
-       int bl=2*l; LPSTR buffer = (LPSTR)alloca(bl);
-       l = WideCharToMultiByte(CP_UTF8, 0, s, l, buffer, bl, 0, 0);
-#else
-       LPWSTR wbuffer = (LPWSTR)alloca(sizeof(WCHAR)*l);
-       l = MultiByteToWideChar(CP_ACP, 0, s, l, wbuffer, l);
-
-       int bl=2*l; LPSTR buffer = (LPSTR)alloca(bl);
-       l = WideCharToMultiByte(CP_UTF8, 0, wbuffer, l, buffer, bl, 0, 0);
-#endif
-
-       return std::string(buffer, l);
-}
-
-inline std::string get_utf8(const XS_String& s)
-{
-       return get_utf8(s.c_str(), s.length());
-}
-
-#endif // XS_STRING_UTF8
-
-extern std::string EncodeXMLString(const XS_String& str);
-extern XS_String DecodeXMLString(const XS_String& str);
-
-
-#ifdef __GNUC__
-#include <ext/stdio_filebuf.h>
-typedef __gnu_cxx::stdio_filebuf<char> STDIO_FILEBUF;
-#else
-typedef std::filebuf STDIO_FILEBUF;
-#endif
-
- /// input file stream with ANSI/UNICODE file names
-struct tifstream : public std::istream
-{
-       typedef std::istream super;
-
-       tifstream(LPCTSTR path)
-        :      super(&_buf),
-               _pfile(_tfopen(path, TEXT("r"))),
-#ifdef __GNUC__
-               _buf(_pfile, ios::in)
-#else
-               _buf(_pfile)
-#endif
-       {
-       }
-
-       ~tifstream()
-       {
-               if (_pfile)
-                       fclose(_pfile);
-       }
-
-protected:
-       FILE*   _pfile;
-       STDIO_FILEBUF _buf;
-};
-
- /// output file stream with ANSI/UNICODE file names
-struct tofstream : public std::ostream
-{
-       typedef std::ostream super;
-
-       tofstream(LPCTSTR path)
-        :      super(&_buf),
-               _pfile(_tfopen(path, TEXT("w"))),
-#ifdef __GNUC__
-               _buf(_pfile, ios::out)
-#else
-               _buf(_pfile)
-#endif
-       {
-       }
-
-       ~tofstream()
-       {
-               flush();
-
-               if (_pfile)
-                       fclose(_pfile);
-       }
-
-protected:
-       FILE*   _pfile;
-       STDIO_FILEBUF _buf;
-};
-
-
- // write XML files with 2 spaces indenting
-#define XML_INDENT_SPACE "  "
-
-
-#ifdef XML_UNICODE     // Are XML_Char strings UTF-16 encoded?
-
-typedef XS_String String_from_XML_Char;
-
-#elif defined(XS_STRING_UTF8)
-
-typedef XS_String String_from_XML_Char;
-
-#else
-
-struct String_from_XML_Char : public XS_String
-{
-       String_from_XML_Char(const XML_Char* str)
-       {
-               assign_utf8(*this, str);
-       }
-};
-
-#endif
-
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-
- // optimization for faster UNICODE/ASCII string comparison without temporary A/U conversion
-inline bool operator==(const XS_String& s1, const char* s2)
-{
-       LPCWSTR p = s1;
-       const unsigned char* q = (const unsigned char*)s2;
-
-       while(*p && *q)
-               if (*p++ != *q++)
-                       return false;
-
-       return *p == *q;
-};
-
-#endif
-
-
- /// in memory representation of an XML node
-struct XMLNode : public XS_String
-{
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-        // optimized read access without temporary A/U conversion when using ASCII attribute names
-       struct AttributeMap : public std::map<XS_String, XS_String>
-       {
-               typedef std::map<XS_String, XS_String> super;
-
-               const_iterator find(const char* x) const
-               {
-                       for(const_iterator it=begin(); it!=end(); ++it)
-                               if (it->first == x)
-                                       return it;
-
-                       return end();
-               }
-
-               const_iterator find(const key_type& x) const
-               {
-                       return super::find(x);
-               }
-
-               iterator find(const key_type& x)
-               {
-                       return super::find(x);
-               }
-       };
-#else
-       typedef std::map<XS_String, XS_String> AttributeMap;
-#endif
-
-       struct Children : public std::list<XMLNode*>
-       {
-               void assign(const Children& other)
-               {
-                       clear();
-
-                       for(Children::const_iterator it=other.begin(); it!=other.end(); ++it)
-                               push_back(new XMLNode(**it));
-               }
-
-               void clear()
-               {
-                       while(!empty()) {
-                               XMLNode* node = back();
-                               pop_back();
-
-                               node->clear();
-                               delete node;
-                       }
-               }
-       };
-
-        // access to protected class members for XMLPos and XMLReader
-       friend struct XMLPos;
-       friend struct const_XMLPos;
-       friend struct XMLReaderBase;
-
-       XMLNode(const XS_String& name)
-        :      XS_String(name)
-       {
-       }
-
-       XMLNode(const XS_String& name, const std::string& leading)
-        :      XS_String(name),
-               _leading(leading)
-       {
-       }
-
-       XMLNode(const XMLNode& other)
-        :      _attributes(other._attributes),
-               _leading(other._leading),
-               _content(other._content),
-               _end_leading(other._end_leading),
-               _trailing(other._trailing)
-       {
-               for(Children::const_iterator it=other._children.begin(); it!=other._children.end(); ++it)
-                       _children.push_back(new XMLNode(**it));
-       }
-
-       ~XMLNode()
-       {
-               while(!_children.empty()) {
-                       delete _children.back();
-                       _children.pop_back();
-               }
-       }
-
-       void clear()
-       {
-               _leading.erase();
-               _content.erase();
-               _end_leading.erase();
-               _trailing.erase();
-
-               _attributes.clear();
-               _children.clear();
-
-               XS_String::erase();
-       }
-
-       XMLNode& operator=(const XMLNode& other)
-       {
-               _children.assign(other._children);
-
-               _attributes = other._attributes;
-
-               _leading = other._leading;
-               _content = other._content;
-               _end_leading = other._end_leading;
-               _trailing = other._trailing;
-
-               return *this;
-       }
-
-        /// add a new child node
-       void add_child(XMLNode* child)
-       {
-               _children.push_back(child);
-       }
-
-        /// write access to an attribute
-       void put(const XS_String& attr_name, const XS_String& value)
-       {
-               _attributes[attr_name] = value;
-       }
-
-        /// C++ write access to an attribute
-       XS_String& operator[](const XS_String& attr_name)
-       {
-               return _attributes[attr_name];
-       }
-
-        /// read only access to an attribute
-       template<typename T> XS_String get(const T& attr_name) const
-       {
-               AttributeMap::const_iterator found = _attributes.find(attr_name);
-
-               if (found != _attributes.end())
-                       return found->second;
-               else
-                       return XS_String();
-       }
-
-        /// convenient value access in children node
-       XS_String subvalue(const XS_String& name, const XS_String& attr_name, int n=0) const
-       {
-               const XMLNode* node = find(name, n);
-
-               if (node)
-                       return node->get(attr_name);
-               else
-                       return XS_String();
-       }
-
-        /// convenient storage of distinct values in children node
-       XS_String& subvalue(const XS_String& name, const XS_String& attr_name, int n=0)
-       {
-               XMLNode* node = find(name, n);
-
-               if (!node) {
-                       node = new XMLNode(name);
-                       add_child(node);
-               }
-
-               return (*node)[attr_name];
-       }
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-        /// convenient value access in children node
-       XS_String subvalue(const char* name, const char* attr_name, int n=0) const
-       {
-               const XMLNode* node = find(name, n);
-
-               if (node)
-                       return node->get(attr_name);
-               else
-                       return XS_String();
-       }
-
-        /// convenient storage of distinct values in children node
-       XS_String& subvalue(const char* name, const XS_String& attr_name, int n=0)
-       {
-               XMLNode* node = find(name, n);
-
-               if (!node) {
-                       node = new XMLNode(name);
-                       add_child(node);
-               }
-
-               return (*node)[attr_name];
-       }
-#endif
-
-       const Children& get_children() const
-       {
-               return _children;
-       }
-
-       Children& get_children()
-       {
-               return _children;
-       }
-
-       XS_String get_content() const
-       {
-#ifdef XS_STRING_UTF8
-               const XS_String& ret = _content;
-#else
-               XS_String ret;
-               assign_utf8(ret, _content.c_str());
-#endif
-
-               return DecodeXMLString(ret.c_str());
-       }
-
-       void set_content(const XS_String& s)
-       {
-               _content.assign(EncodeXMLString(s.c_str()));
-       }
-
-       enum WRITE_MODE {
-               FORMAT_SMART    = 0,    /// preserve original white space and comments if present; pretty print otherwise
-               FORMAT_ORIGINAL = 1,    /// write XML stream preserving original white space and comments
-               FORMAT_PRETTY   = 2     /// pretty print node to stream without preserving original white space
-       };
-
-        /// write node with children tree to output stream
-       std::ostream& write(std::ostream& out, WRITE_MODE mode=FORMAT_SMART, int indent=0) const
-       {
-               switch(mode) {
-                 case FORMAT_PRETTY:
-                       pretty_write_worker(out, indent);
-                       break;
-
-                 case FORMAT_ORIGINAL:
-                       write_worker(out, indent);
-                       break;
-
-               default:         // FORMAT_SMART
-                       smart_write_worker(out, indent);
-               }
-
-               return out;
-       }
-
-protected:
-       Children _children;
-       AttributeMap _attributes;
-
-       std::string _leading;
-       std::string _content;
-       std::string _end_leading;
-       std::string _trailing;
-
-       XMLNode* get_first_child() const
-       {
-               if (!_children.empty())
-                       return _children.front();
-               else
-                       return NULL;
-       }
-
-       XMLNode* find(const XS_String& name, int n=0) const
-       {
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it)
-                       if (**it == name)
-                               if (!n--)
-                                       return *it;
-
-               return NULL;
-       }
-
-       XMLNode* find(const XS_String& name, const XS_String& attr_name, const XS_String& attr_value, int n=0) const
-       {
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it) {
-                       const XMLNode& node = **it;
-
-                       if (node==name && node.get(attr_name)==attr_value)
-                               if (!n--)
-                                       return *it;
-               }
-
-               return NULL;
-       }
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-       XMLNode* find(const char* name, int n=0) const
-       {
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it)
-                       if (**it == name)
-                               if (!n--)
-                                       return *it;
-
-               return NULL;
-       }
-
-       template<typename T, typename U>
-       XMLNode* find(const char* name, const T& attr_name, const U& attr_value, int n=0) const
-       {
-               for(Children::const_iterator it=_children.begin(); it!=_children.end(); ++it) {
-                       const XMLNode& node = **it;
-
-                       if (node==name && node.get(attr_name)==attr_value)
-                               if (!n--)
-                                       return *it;
-               }
-
-               return NULL;
-       }
-#endif
-
-        /// XPath find functions
-       const XMLNode* find_relative(const char* path) const;
-
-       XMLNode* find_relative(const char* path)
-               {return const_cast<XMLNode*>(const_cast<const XMLNode*>(this)->find_relative(path));}
-
-        /// relative XPath create function
-       XMLNode* create_relative(const char* path);
-
-       void write_worker(std::ostream& out, int indent) const;
-       void pretty_write_worker(std::ostream& out, int indent) const;
-       void smart_write_worker(std::ostream& out, int indent) const;
-};
-
-
- /// iterator access to children nodes with name filtering
-struct XMLChildrenFilter
-{
-       XMLChildrenFilter(XMLNode::Children& children, const XS_String& name)
-        :      _begin(children.begin(), children.end(), name),
-               _end(children.end(), children.end(), name)
-       {
-       }
-
-       XMLChildrenFilter(XMLNode* node, const XS_String& name)
-        :      _begin(node->get_children().begin(), node->get_children().end(), name),
-               _end(node->get_children().end(), node->get_children().end(), name)
-       {
-       }
-
-       struct iterator
-       {
-               typedef XMLNode::Children::iterator BaseIterator;
-
-               iterator(BaseIterator begin, BaseIterator end, const XS_String& filter_name)
-                :      _cur(begin),
-                       _end(end),
-                       _filter_name(filter_name)
-               {
-                       search_next();
-               }
-
-               operator BaseIterator()
-               {
-                       return _cur;
-               }
-
-               const XMLNode* operator*() const
-               {
-                       return *_cur;
-               }
-
-               XMLNode* operator*()
-               {
-                       return *_cur;
-               }
-
-               iterator& operator++()
-               {
-                       ++_cur;
-                       search_next();
-
-                       return *this;
-               }
-
-               iterator operator++(int)
-               {
-                       iterator ret = *this;
-
-                       ++_cur;
-                       search_next();
-
-                       return ret;
-               }
-
-               bool operator==(const BaseIterator& other) const
-               {
-                       return _cur == other;
-               }
-
-               bool operator!=(const BaseIterator& other) const
-               {
-                       return _cur != other;
-               }
-
-       protected:
-               BaseIterator    _cur;
-               BaseIterator    _end;
-               XS_String       _filter_name;
-
-               void search_next()
-               {
-                       while(_cur!=_end && **_cur!=_filter_name)
-                               ++_cur;
-               }
-       };
-
-       iterator begin()
-       {
-               return _begin;
-       }
-
-       iterator end()
-       {
-               return _end;
-       }
-
-protected:
-       iterator        _begin;
-       iterator        _end;
-};
-
-
- /// read only iterator access to children nodes with name filtering
-struct const_XMLChildrenFilter
-{
-       const_XMLChildrenFilter(const XMLNode::Children& children, const XS_String& name)
-        :      _begin(children.begin(), children.end(), name),
-               _end(children.end(), children.end(), name)
-       {
-       }
-
-       const_XMLChildrenFilter(const XMLNode* node, const XS_String& name)
-        :      _begin(node->get_children().begin(), node->get_children().end(), name),
-               _end(node->get_children().end(), node->get_children().end(), name)
-       {
-       }
-
-       struct const_iterator
-       {
-               typedef XMLNode::Children::const_iterator BaseIterator;
-
-               const_iterator(BaseIterator begin, BaseIterator end, const XS_String& filter_name)
-                :      _cur(begin),
-                       _end(end),
-                       _filter_name(filter_name)
-               {
-                       search_next();
-               }
-
-               operator BaseIterator()
-               {
-                       return _cur;
-               }
-
-               const XMLNode* operator*() const
-               {
-                       return *_cur;
-               }
-
-               const_iterator& operator++()
-               {
-                       ++_cur;
-                       search_next();
-
-                       return *this;
-               }
-
-               const_iterator operator++(int)
-               {
-                       const_iterator ret = *this;
-
-                       ++_cur;
-                       search_next();
-
-                       return ret;
-               }
-
-               bool operator==(const BaseIterator& other) const
-               {
-                       return _cur == other;
-               }
-
-               bool operator!=(const BaseIterator& other) const
-               {
-                       return _cur != other;
-               }
-
-       protected:
-               BaseIterator    _cur;
-               BaseIterator    _end;
-               XS_String       _filter_name;
-
-               void search_next()
-               {
-                       while(_cur!=_end && **_cur!=_filter_name)
-                               ++_cur;
-               }
-       };
-
-       const_iterator begin()
-       {
-               return _begin;
-       }
-
-       const_iterator end()
-       {
-               return _end;
-       }
-
-protected:
-       const_iterator  _begin;
-       const_iterator  _end;
-};
-
-
- /// iterator for XML trees
-struct XMLPos
-{
-       XMLPos(XMLNode* root)
-        :      _root(root),
-               _cur(root)
-       {
-       }
-
-       XMLPos(const XMLPos& other)
-        :      _root(other._root),
-               _cur(other._cur)
-       {       // don't copy _stack
-       }
-
-       XMLPos(XMLNode* node, const XS_String& name)
-        :      _root(node),
-               _cur(node)
-       {
-               smart_create(name);
-       }
-
-       XMLPos(XMLNode* node, const XS_String& name, const XS_String& attr_name, const XS_String& attr_value)
-        :      _root(node),
-               _cur(node)
-       {
-               smart_create(name, attr_name, attr_value);
-       }
-
-       XMLPos(const XMLPos& other, const XS_String& name)
-        :      _root(other._root),
-               _cur(other._cur)
-       {
-               smart_create(name);
-       }
-
-       XMLPos(const XMLPos& other, const XS_String& name, const XS_String& attr_name, const XS_String& attr_value)
-        :      _root(other._root),
-               _cur(other._cur)
-       {
-               smart_create(name, attr_name, attr_value);
-       }
-
-        /// access to current node
-       XMLNode& cur()
-       {
-               return *_cur;
-       }
-
-       const XMLNode& cur() const
-       {
-               return *_cur;
-       }
-
-        /// C++ access to current node
-       operator const XMLNode*() const {return _cur;}
-       operator XMLNode*() {return _cur;}
-
-       const XMLNode* operator->() const {return _cur;}
-       XMLNode* operator->() {return _cur;}
-
-       const XMLNode& operator*() const {return *_cur;}
-       XMLNode& operator*() {return *_cur;}
-
-        /// attribute access
-       XS_String get(const XS_String& attr_name) const
-       {
-               return _cur->get(attr_name);
-       }
-
-       void put(const XS_String& attr_name, const XS_String& value)
-       {
-               _cur->put(attr_name, value);
-       }
-
-        /// C++ attribute access
-       template<typename T> XS_String get(const T& attr_name) const {return (*_cur)[attr_name];}
-       XS_String& operator[](const XS_String& attr_name) {return (*_cur)[attr_name];}
-
-        /// insert children when building tree
-       void add_down(XMLNode* child)
-       {
-               _cur->add_child(child);
-               go_to(child);
-       }
-
-        /// go back to previous position
-       bool back()
-       {
-               if (!_stack.empty()) {
-                       _cur = _stack.top();
-                       _stack.pop();
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// go down to first child
-       bool go_down()
-       {
-               XMLNode* node = _cur->get_first_child();
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// search for child and go down
-       bool go_down(const XS_String& name, int n=0)
-       {
-               XMLNode* node = _cur->find(name, n);
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// move XPath like to position in XML tree
-       bool go(const char* path);
-
-        /// create child nodes using XPath notation and move to the deepest child
-       bool create_relative(const char* path)
-       {
-               XMLNode* node = _cur->create_relative(path);
-               if (!node)
-                       return false;   // invalid path specified
-
-               go_to(node);
-               return true;
-       }
-
-        /// create node and move to it
-       void create(const XS_String& name)
-       {
-               add_down(new XMLNode(name));
-       }
-
-        /// create node if not already existing and move to it
-       void smart_create(const XS_String& name)
-       {
-               XMLNode* node = _cur->find(name);
-
-               if (node)
-                       go_to(node);
-               else
-                       add_down(new XMLNode(name));
-       }
-
-        /// search matching child node identified by key name and an attribute value
-       void smart_create(const XS_String& name, const XS_String& attr_name, const XS_String& attr_value)
-       {
-               XMLNode* node = _cur->find(name, attr_name, attr_value);
-
-               if (node)
-                       go_to(node);
-               else {
-                       node = new XMLNode(name);
-                       add_down(node);
-                       (*node)[attr_name] = attr_value;
-               }
-       }
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-        /// search for child and go down
-       bool go_down(const char* name, int n=0)
-       {
-               XMLNode* node = _cur->find(name, n);
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// create node and move to it
-       void create(const char* name)
-       {
-               add_down(new XMLNode(name));
-       }
-
-        /// create node if not already existing and move to it
-       void smart_create(const char* name)
-       {
-               XMLNode* node = _cur->find(name);
-
-               if (node)
-                       go_to(node);
-               else
-                       add_down(new XMLNode(name));
-       }
-
-        /// search matching child node identified by key name and an attribute value
-       template<typename T, typename U>
-       void smart_create(const char* name, const T& attr_name, const U& attr_value)
-       {
-               XMLNode* node = _cur->find(name, attr_name, attr_value);
-
-               if (node)
-                       go_to(node);
-               else {
-                       XMLNode* node = new XMLNode(name);
-                       add_down(node);
-                       (*node)[attr_name] = attr_value;
-               }
-       }
-#endif
-
-       XS_String& str() {return *_cur;}
-       const XS_String& str() const {return *_cur;}
-
-protected:
-       XMLNode* _root;
-       XMLNode* _cur;
-       std::stack<XMLNode*> _stack;
-
-        /// go to specified node
-       void go_to(XMLNode* child)
-       {
-               _stack.push(_cur);
-               _cur = child;
-       }
-};
-
-
- /// iterator for XML trees
-struct const_XMLPos
-{
-       const_XMLPos(const XMLNode* root)
-        :      _root(root),
-               _cur(root)
-       {
-       }
-
-       const_XMLPos(const const_XMLPos& other)
-        :      _root(other._root),
-               _cur(other._cur)
-       {       // don't copy _stack
-       }
-
-        /// access to current node
-       const XMLNode& cur() const
-       {
-               return *_cur;
-       }
-
-        /// C++ access to current node
-       operator const XMLNode*() const {return _cur;}
-
-       const XMLNode* operator->() const {return _cur;}
-
-       const XMLNode& operator*() const {return *_cur;}
-
-        /// attribute access
-       XS_String get(const XS_String& attr_name) const
-       {
-               return _cur->get(attr_name);
-       }
-
-        /// C++ attribute access
-       template<typename T> XS_String get(const T& attr_name) const {return _cur->get(attr_name);}
-
-        /// go back to previous position
-       bool back()
-       {
-               if (!_stack.empty()) {
-                       _cur = _stack.top();
-                       _stack.pop();
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// go down to first child
-       bool go_down()
-       {
-               const XMLNode* node = _cur->get_first_child();
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// search for child and go down
-       bool go_down(const XS_String& name, int n=0)
-       {
-               XMLNode* node = _cur->find(name, n);
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-
-        /// move XPath like to position in XML tree
-       bool go(const char* path);
-
-#if defined(UNICODE) && !defined(XS_STRING_UTF8)
-        /// search for child and go down
-       bool go_down(const char* name, int n=0)
-       {
-               XMLNode* node = _cur->find(name, n);
-
-               if (node) {
-                       go_to(node);
-                       return true;
-               } else
-                       return false;
-       }
-#endif
-
-       const XS_String& str() const {return *_cur;}
-
-protected:
-       const XMLNode* _root;
-       const XMLNode* _cur;
-       std::stack<const XMLNode*> _stack;
-
-        /// go to specified node
-       void go_to(const XMLNode* child)
-       {
-               _stack.push(_cur);
-               _cur = child;
-       }
-};
-
-
- // work around GCC's wide string constant bug
-#ifdef __GNUC__
-extern const LPCXSSTR XS_TRUE;
-extern const LPCXSSTR XS_FALSE;
-extern const LPCXSSTR XS_NUMBERFMT;
-#else
-#define        XS_TRUE XS_TEXT("true")
-#define        XS_FALSE XS_TEXT("false")
-#define        XS_NUMBERFMT XS_TEXT("%d")
-#endif
-
-
-struct XMLBool
-{
-       XMLBool(bool value=false)
-        :      _value(value)
-       {
-       }
-
-       XMLBool(LPCXSSTR value, bool def=false)
-       {
-               if (value && *value)
-                       _value = !XS_icmp(value, XS_TRUE);
-               else
-                       _value = def;
-       }
-
-       XMLBool(const XMLNode* node, const XS_String& attr_name, bool def=false)
-       {
-               const XS_String& value = node->get(attr_name);
-
-               if (!value.empty())
-                       _value = !XS_icmp(value.c_str(), XS_TRUE);
-               else
-                       _value = def;
-       }
-
-       operator bool() const
-       {
-               return _value;
-       }
-
-       bool operator!() const
-       {
-               return !_value;
-       }
-
-       operator LPCXSSTR() const
-       {
-               return _value? XS_TRUE: XS_FALSE;
-       }
-
-protected:
-       bool    _value;
-
-private:
-       void operator=(const XMLBool&); // disallow assignment operations
-};
-
-struct XMLBoolRef
-{
-       XMLBoolRef(XMLNode* node, const XS_String& attr_name, bool def=false)
-        :      _ref((*node)[attr_name])
-       {
-               if (_ref.empty())
-                       assign(def);
-       }
-
-       operator bool() const
-       {
-               return !XS_icmp(_ref.c_str(), XS_TRUE);
-       }
-
-       bool operator!() const
-       {
-               return XS_icmp(_ref.c_str(), XS_TRUE)? true: false;
-       }
-
-       XMLBoolRef& operator=(bool value)
-       {
-               assign(value);
-
-               return *this;
-       }
-
-       void assign(bool value)
-       {
-               _ref.assign(value? XS_TRUE: XS_FALSE);
-       }
-
-       void toggle()
-       {
-               assign(!operator bool());
-       }
-
-protected:
-       XS_String& _ref;
-};
-
-
-struct XMLInt
-{
-       XMLInt(int value)
-        :      _value(value)
-       {
-       }
-
-       XMLInt(LPCXSSTR value, int def=0)
-       {
-               if (value && *value)
-                       _value = XS_toi(value);
-               else
-                       _value = def;
-       }
-
-       XMLInt(const XMLNode* node, const XS_String& attr_name, int def=0)
-       {
-               const XS_String& value = node->get(attr_name);
-
-               if (!value.empty())
-                       _value = XS_toi(value.c_str());
-               else
-                       _value = def;
-       }
-
-       operator int() const
-       {
-               return _value;
-       }
-
-       operator XS_String() const
-       {
-               XS_CHAR buffer[32];
-               XS_sprintf(buffer, XS_NUMBERFMT, _value);
-               return buffer;
-       }
-
-protected:
-       int _value;
-
-private:
-       void operator=(const XMLInt&); // disallow assignment operations
-};
-
-struct XMLIntRef
-{
-       XMLIntRef(XMLNode* node, const XS_String& attr_name, int def=0)
-        :      _ref((*node)[attr_name])
-       {
-               if (_ref.empty())
-                       assign(def);
-       }
-
-       XMLIntRef& operator=(int value)
-       {
-               assign(value);
-
-               return *this;
-       }
-
-       operator int() const
-       {
-               return XS_toi(_ref.c_str());
-       }
-
-       void assign(int value)
-       {
-               XS_CHAR buffer[32];
-               XS_sprintf(buffer, XS_NUMBERFMT, value);
-               _ref.assign(buffer);
-       }
-
-protected:
-       XS_String& _ref;
-};
-
-
-struct XMLString
-{
-       XMLString(const XS_String& value)
-        :      _value(value)
-       {
-       }
-
-       XMLString(LPCXSSTR value, LPCXSSTR def=XS_TEXT(""))
-       {
-               if (value && *value)
-                       _value = value;
-               else
-                       _value = def;
-       }
-
-       XMLString(const XMLNode* node, const XS_String& attr_name, LPCXSSTR def=XS_TEXT(""))
-       {
-               const XS_String& value = node->get(attr_name);
-
-               if (!value.empty())
-                       _value = value;
-               else
-                       _value = def;
-       }
-
-       operator const XS_String&() const
-       {
-               return _value;
-       }
-
-       const XS_String& c_str() const
-       {
-               return _value;
-       }
-
-protected:
-       XS_String       _value;
-
-private:
-       void operator=(const XMLString&); // disallow assignment operations
-};
-
-struct XMStringRef
-{
-       XMStringRef(XMLNode* node, const XS_String& attr_name, LPCXSSTR def=XS_TEXT(""))
-        :      _ref((*node)[attr_name])
-       {
-               if (_ref.empty())
-                       assign(def);
-       }
-
-       XMStringRef(XMLNode* node, const XS_String& node_name, const XS_String& attr_name, LPCXSSTR def=XS_TEXT(""))
-        :      _ref(node->subvalue(node_name, attr_name))
-       {
-               if (_ref.empty())
-                       assign(def);
-       }
-
-       XMStringRef& operator=(const XS_String& value)
-       {
-               assign(value);
-
-               return *this;
-       }
-
-       operator const XS_String&() const
-       {
-               return _ref;
-       }
-
-       void assign(const XS_String& value)
-       {
-               _ref.assign(value);
-       }
-
-protected:
-       XS_String& _ref;
-};
-
-
-template<typename T>
-       inline void read_option(T& var, const_XMLPos& cfg, LPCXSSTR key)
-       {
-               const XS_String& val = cfg.get(key);
-
-               if (!val.empty())
-                       var = val;
-       }
-
-template<>
-       inline void read_option(int& var, const_XMLPos& cfg, LPCXSSTR key)
-       {
-               const XS_String& val = cfg.get(key);
-
-               if (!val.empty())
-                       var = XS_toi(val.c_str());
-       }
-
-
-#ifdef _MSC_VER
-#pragma warning(disable: 4355)
-#endif
-
- /// XML reader base class
-struct XMLReaderBase
-{
-       XMLReaderBase(XMLNode* node)
-        :      _pos(node),
-               _parser(XML_ParserCreate(NULL))
-       {
-               XML_SetUserData(_parser, this);
-               XML_SetXmlDeclHandler(_parser, XML_XmlDeclHandler);
-               XML_SetElementHandler(_parser, XML_StartElementHandler, XML_EndElementHandler);
-               XML_SetDefaultHandler(_parser, XML_DefaultHandler);
-
-               _last_tag = TAG_NONE;
-       }
-
-       virtual ~XMLReaderBase()
-       {
-               XML_ParserFree(_parser);
-       }
-
-       XML_Status read();
-
-       virtual int read_buffer(char* buffer, int len) = 0;
-
-       std::string get_position() const
-       {
-               int line = XML_GetCurrentLineNumber(_parser);
-               int column = XML_GetCurrentColumnNumber(_parser);
-
-               std::ostringstream out;
-               out << "(" << line << ") : [column " << column << "]";
-
-               return out.str();
-       }
-
-       std::string get_instructions() const {return _instructions;}
-
-       XML_Error       get_error_code() {return XML_GetErrorCode(_parser);}
-       std::string get_error_string() const;
-
-protected:
-       XMLPos          _pos;
-       XML_Parser      _parser;
-       std::string _xml_version;
-       std::string _encoding;
-       std::string     _instructions;
-
-       std::string _content;
-       enum {TAG_NONE, TAG_START, TAG_END} _last_tag;
-
-       static void XMLCALL XML_XmlDeclHandler(void* userData, const XML_Char* version, const XML_Char* encoding, int standalone);
-       static void XMLCALL XML_StartElementHandler(void* userData, const XML_Char* name, const XML_Char** atts);
-       static void XMLCALL XML_EndElementHandler(void* userData, const XML_Char* name);
-       static void XMLCALL XML_DefaultHandler(void* userData, const XML_Char* s, int len);
-};
-
-
- /// XML file reader
-struct XMLReader : public XMLReaderBase
-{
-       XMLReader(XMLNode* node, std::istream& in)
-        :      XMLReaderBase(node),
-               _in(in)
-       {
-       }
-
-        /// read XML stream into XML tree below _pos
-       int read_buffer(char* buffer, int len)
-       {
-               if (!_in.good())
-                       return -1;
-
-               _in.read(buffer, len);
-
-               return _in.gcount();
-       }
-
-protected:
-       std::istream&   _in;
-};
-
-
-struct XMLHeader
-{
-       XMLHeader(const std::string& xml_version="1.0", const std::string& encoding="UTF-8", const std::string& doctype="")
-        :      _version(xml_version),
-               _encoding(encoding),
-               _doctype(doctype)
-       {
-       }
-
-       void print(std::ostream& out) const
-       {
-               out << "<?xml version=\"" << _version << "\" encoding=\"" << _encoding << "\"?>\n";
-
-               if (!_doctype.empty())
-                       out << _doctype << '\n';
-               if (!_additional.empty())
-                       out << _additional << '\n';
-       }
-
-       std::string _version;
-       std::string _encoding;
-       std::string _doctype;
-       std::string _additional;
-};
-
-
-struct XMLDoc : public XMLNode
-{
-       XMLDoc()
-        :      XMLNode(""),
-               _last_error(XML_ERROR_NONE)
-       {
-       }
-
-       XMLDoc(LPCTSTR path)
-        :      XMLNode(""),
-               _last_error(XML_ERROR_NONE)
-       {
-               read(path);
-       }
-
-       std::istream& read(std::istream& in)
-       {
-               XMLReader reader(this, in);
-
-               read(reader);
-
-               return in;
-       }
-
-       bool read(LPCTSTR path)
-       {
-               tifstream in(path);
-               XMLReader reader(this, in);
-
-//#if defined(_STRING_DEFINED) && !defined(XS_STRING_UTF8)
-//             return read(reader, std::string(ANS(path)));
-//#else
-               return read(reader, XS_String(path));
-//#endif
-       }
-
-       bool read(XMLReaderBase& reader)
-       {
-               XML_Status status = reader.read();
-
-               _header._additional = reader.get_instructions();
-
-               if (status == XML_STATUS_ERROR) {
-                       std::ostringstream out;
-
-                       out << "input stream" << reader.get_position() << " " << reader.get_error_string();
-
-                       _last_error = reader.get_error_code();
-                       _last_error_msg = out.str();
-               }
-
-               return status != XML_STATUS_ERROR;
-       }
-
-       bool read(XMLReaderBase& reader, const std::string& display_path)
-       {
-               XML_Status status = reader.read();
-
-               _header._additional = reader.get_instructions();
-
-               if (status == XML_STATUS_ERROR) {
-                       std::ostringstream out;
-
-                       out << display_path << reader.get_position() << " " << reader.get_error_string();
-
-                       _last_error = reader.get_error_code();
-                       _last_error_msg = out.str();
-               }
-
-               return status != XML_STATUS_ERROR;
-       }
-
-        /// write XML stream preserving previous white space and comments
-       std::ostream& write(std::ostream& out, WRITE_MODE mode=FORMAT_SMART) const
-       {
-               _header.print(out);
-
-               if (!_children.empty())
-                       _children.front()->write(out);
-
-               return out;
-       }
-
-        /// write XML stream with formating
-       std::ostream& write_formating(std::ostream& out) const
-       {
-               return write(out, FORMAT_PRETTY);
-       }
-
-       void write(LPCTSTR path, WRITE_MODE mode=FORMAT_SMART) const
-       {
-               tofstream out(path);
-
-               write(out, mode);
-       }
-
-       void write_formating(LPCTSTR path) const
-       {
-               tofstream out(path);
-
-               write_formating(out);
-       }
-
-       XMLHeader       _header;
-       XML_Error       _last_error;
-       std::string _last_error_msg;
-};
-
-
-struct XMLMessage : public XMLDoc
-{
-       XMLMessage(const char* name)
-        :      _pos(this)
-       {
-               _pos.create(name);
-       }
-
-       XMLPos  _pos;
-};
-
-
-}      // namespace XMLStorage
-
-#define _XMLSTORAGE_H
-#endif // _XMLSTORAGE_H
diff --git a/reactos/subsys/system/ibrowser/webchild.cpp b/reactos/subsys/system/ibrowser/webchild.cpp
deleted file mode 100644 (file)
index 76bb895..0000000
+++ /dev/null
@@ -1,309 +0,0 @@
-/*
- * Copyright 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // ROS Internet Web Browser
- //
- // webchild.cpp
- //
- // Martin Fuchs, 25.01.2005
- //
-
-
-#include <precomp.h>
-
-#include "ibrowser_intres.h"
-
-#include "webchild.h"
-
-
-#ifdef _MSC_VER
-
-#if _MSC_VER>=1300     // vtMissing for VS.Net
-#include <comutil.h>
-#pragma comment(lib, "comsupp")
-#endif
-
-#else
-
-#ifdef __MINGW32__     // MinGW is lacking vtMissing (as of 07.02.2004)
-static Variant vtMissing;
-#endif
-
-#endif
-
-//#include <mshtml.h>
-
-
-Variant::Variant(const VARIANT& var)
-{
-       VariantInit(this);
-       CheckError(VariantCopy(this, const_cast<VARIANT*>(&var)));
-}
-
-Variant::Variant(const VARIANT* var)
-{
-       VariantInit(this);
-       CheckError(VariantCopy(this, const_cast<VARIANT*>(var)));
-}
-
-Variant::~Variant()
-{
-       VariantClear(this);
-}
-
-
-Variant::operator long() const
-{
-       Variant v;
-       CheckError(VariantChangeType(&v, (VARIANT*)this, 0, VT_I4));
-       return V_I4(&v);
-}
-
-Variant::operator bool() const
-{
-       Variant v;
-       CheckError(VariantChangeType(&v, (VARIANT*)this, 0, VT_BOOL));
-       return V_BOOL(&v)? true: false;
-}
-
-Variant::operator IDispatch*() const
-{
-       Variant v;
-       CheckError(VariantChangeType(&v, (VARIANT*)this, 0, VT_DISPATCH));
-       return V_DISPATCH(&v);
-}
-
-Variant::operator VARIANT_BOOL() const
-{
-       Variant v;
-       CheckError(VariantChangeType(&v, (VARIANT*)this, 0, VT_BOOL));
-       return V_BOOL(&v);
-}
-
-
-void BStr::assign(BSTR s)
-{
-       if (!SysReAllocString(&_p, s))
-               THROW_EXCEPTION(E_OUTOFMEMORY);
-}
-
-void BStr::assign(const VARIANT& var)
-{
-       if (V_VT(&var) == VT_BSTR)
-               assign(V_BSTR(&var));
-       else {
-               Variant v;
-               CheckError(VariantChangeType(&v, const_cast<VARIANT*>(&var), 0, VT_BSTR));
-               assign(V_BSTR(&v));
-       }
-}
-
-
-BrowserNavigator::BrowserNavigator()
- :     _browser_initialized(false)
-{
-}
-
-void BrowserNavigator::attach(IWebBrowser* browser)
-{
-       _browser = browser;
-}
-
-void BrowserNavigator::goto_url(LPCTSTR url)
-{
-       if (_browser_initialized)
-               _browser->Navigate(BStr(url), NULL, NULL, NULL, NULL);
-       else {
-               _new_url = url;
-
-               _browser->Navigate(L"about:blank", NULL, NULL, NULL, NULL);
-       }
-}
-
-void BrowserNavigator::set_html_page(const String& html_txt)
-{
-       _new_html_txt = html_txt;
-
-       goto_url(TEXT("about:blank"));
-}
-
-void T2nA_binary(LPCTSTR s, LPSTR d, int len)
-{
-       while(len-- > 0)
-               *d++ = (unsigned char)*s++;
-}
-
-void BrowserNavigator::navigated(LPCTSTR url)
-{
-       _browser_initialized = true;
-
-       bool nav = false;
-
-       if (!_new_url.empty()) {
-               if (!_tcscmp(url,TEXT("about:blank")) && _new_url!=TEXT("about:blank")) {
-                       _browser->Navigate(BStr(_new_url), NULL, NULL, NULL, NULL);
-                       ++nav;
-               }
-
-               _new_url.erase();
-       }
-
-       if (!nav && !_new_html_txt.empty()) {   ///@todo move this into DocumentComplete() ?
-               int len = _new_html_txt.length();
-               HGLOBAL hHtmlText = GlobalAlloc(GPTR, len);
-
-               if (!hHtmlText) {
-                       T2nA_binary(_new_html_txt, (char*)hHtmlText, len);
-                       _new_html_txt.erase();
-
-                       SIfacePtr<IStream> pStream;
-                       HRESULT hr = CreateStreamOnHGlobal(hHtmlText, TRUE, &pStream);
-
-                       if (SUCCEEDED(hr)) {
-                               SIfacePtr<IDispatch> pHtmlDoc;
-                               CheckError(_browser->get_Document(&pHtmlDoc));
-
-                               SIfacePtr<IPersistStreamInit> pPersistStreamInit;
-                               pHtmlDoc.QueryInterface(IID_IPersistStreamInit, &pPersistStreamInit);
-
-                               CheckError(pPersistStreamInit->InitNew());
-                               CheckError(pPersistStreamInit->Load(pStream));
-                       } else
-                               GlobalFree(hHtmlText);
-               }
-       }
-}
-
-
-HWND create_webchildwindow(const WebChildWndInfo& info)
-{
-       WebChildWindow* pWnd = WebChildWindow::create(info);
-
-       if (!pWnd)
-               return 0;
-
-       return *pWnd;
-}
-
-static const CLSID CLSID_MozillaBrowser =
-       {0x1339B54C, 0x3453, 0x11D2, {0x93, 0xB9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}};
-
-
-WebChildWindow::WebChildWindow(HWND hwnd, const WebChildWndInfo& info)
- :     super(hwnd, info._hwndFrame),
-       web_super(_navigator)
-{
-        // first try to create a web control with MS IE's CLASSID
-       HRESULT hr = create_control(hwnd, CLSID_WebBrowser, IID_IWebBrowser2);
-
-        // If this failed, try to use Mozilla's web control
-       if (FAILED(hr))
-               hr = create_control(hwnd, CLSID_MozillaBrowser, IID_IWebBrowser2);
-
-       if (SUCCEEDED(hr)) {
-               _navigator.attach(_control);
-
-               _connector = auto_ptr<EventConnector>(new EventConnector(_control, DIID_DWebBrowserEvents2, this));
-
-                // We need to call Navigate() here to initialize the browser control (see _browser_initialized)
-               _control->Navigate(BStr(info._url), &vtMissing, &vtMissing, &vtMissing, &vtMissing);
-       }
-}
-
-LRESULT WebChildWindow::WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       try {
-               switch(nmsg) {
-                 case WM_ERASEBKGND:
-                       if (!_control) {
-                               HDC hdc = (HDC)wparam;
-                               ClientRect rect(_hwnd);
-
-                               HBRUSH hbrush = CreateSolidBrush(RGB(200,200,235));
-                               BkMode mode(hdc, TRANSPARENT);
-                               TextColor color(hdc, RGB(200,40,40));
-                               FillRect(hdc, &rect, hbrush);
-                               DrawText(hdc, TEXT("Sorry - no web browser control could be loaded."), -1, &rect, DT_CENTER|DT_VCENTER|DT_SINGLELINE);
-                               DeleteObject(hbrush);
-                       }
-
-                       return TRUE;
-
-
-                 case PM_DISPATCH_COMMAND: {
-                       if (_control) {
-                               HRESULT hr = E_FAIL;
-
-                               switch(LOWORD(wparam)) {
-                                 case ID_GO_BACK:
-                                       hr = _control->GoBack();
-                                       break;
-
-                                 case ID_GO_FORWARD:
-                                       hr = _control->GoForward();
-                                       break;
-
-                                 case ID_GO_UP:
-                                       ///@todo
-                                       break;
-
-                                 case ID_GO_HOME:
-                                       hr = _control->GoHome();
-                                       break;
-
-                                 case ID_GO_SEARCH:
-                                       hr = _control->GoSearch();
-                                       break;
-
-                                 case ID_REFRESH:
-                                       hr = _control->Refresh();
-                                       break;
-
-                                 case ID_STOP:
-                                       hr = _control->Stop();
-                                       break;
-
-                                 default:
-                                       return super::WndProc(nmsg, wparam, lparam);
-                               }
-
-                               if (FAILED(hr) && hr!=E_FAIL)
-                                       THROW_EXCEPTION(hr);
-                       }
-
-                       return TRUE;}
-
-                 default:
-                       return super::WndProc(nmsg, wparam, lparam);
-               }
-       } catch(COMException& e) {
-               HandleException(e, _hwnd);
-       }
-
-       return 0;
-}
-
-
-String WebChildWindow::jump_to_int(LPCTSTR url)
-{
-       _navigator.goto_url(url);
-
-       return url;
-}
diff --git a/reactos/subsys/system/ibrowser/webchild.h b/reactos/subsys/system/ibrowser/webchild.h
deleted file mode 100644 (file)
index 5258db5..0000000
+++ /dev/null
@@ -1,1103 +0,0 @@
-/*
- * Copyright 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
- //
- // ROS Internet Web Browser
- //
- // webchild.h
- //
- // Martin Fuchs, 25.01.2005
- //
-
-
-#ifndef _MSC_VER
-#include <exdisp.h>            // for IConnectionPointContainer
-#include <exdispid.h>  // for DWebBrowserEvents2 IDs
-#endif
-
-#ifndef DISPID_BEFORENAVIGATE  // missing in MinGW (as of 07.02.2004)
-#define DISPID_BEFORENAVIGATE                  100
-#define DISPID_NAVIGATECOMPLETE                        101
-#define DISPID_STATUSTEXTCHANGE                        102
-#define DISPID_QUIT                                            103
-#define DISPID_DOWNLOADCOMPLETE                        104
-#define DISPID_COMMANDSTATECHANGE              105
-#define DISPID_DOWNLOADBEGIN                   106
-#define DISPID_NEWWINDOW                               107
-#define DISPID_PROGRESSCHANGE                  108
-#define DISPID_WINDOWMOVE                              109
-#define DISPID_WINDOWRESIZE                            110
-#define DISPID_WINDOWACTIVATE                  111
-#define DISPID_PROPERTYCHANGE                  112
-#define DISPID_TITLECHANGE                             113
-#define DISPID_TITLEICONCHANGE                 114
-#define DISPID_FRAMEBEFORENAVIGATE             200
-#define DISPID_FRAMENAVIGATECOMPLETE   201
-#define DISPID_FRAMENEWWINDOW                  204
-
-#define DISPID_NAVIGATECOMPLETE2               252
-#define DISPID_ONQUIT                                  253
-#define DISPID_ONVISIBLE                               254
-#define DISPID_ONTOOLBAR                               255
-#define DISPID_ONMENUBAR                               256
-#define DISPID_ONSTATUSBAR                             257
-#define DISPID_ONFULLSCREEN                            258
-#define DISPID_DOCUMENTCOMPLETE                        259
-#define DISPID_ONTHEATERMODE                   260
-#define DISPID_ONADDRESSBAR                            261
-#define DISPID_WINDOWSETRESIZABLE              262
-#define DISPID_WINDOWCLOSING                   263
-#define DISPID_WINDOWSETLEFT                   264
-#define DISPID_WINDOWSETTOP                            265
-#define DISPID_WINDOWSETWIDTH                  266
-#define DISPID_WINDOWSETHEIGHT                 267
-#define DISPID_CLIENTTOHOSTWINDOW              268
-#define DISPID_SETSECURELOCKICON               269
-#define DISPID_FILEDOWNLOAD                            270
-#define DISPID_NAVIGATEERROR                   271
-#define DISPID_PRIVACYIMPACTEDSTATECHANGE 272
-#endif
-
-#ifndef V_INT  // missing in MinGW (as of 07.02.2004)
-#define        V_INT(x) V_UNION(x, intVal)
-#endif
-
-#ifdef _MSC_VER
-#define        NOVTABLE __declspec(novtable)
-#else
-#define        NOVTABLE
-#endif
-#define        ANSUNC
-
-#ifdef _MSC_VER
-#pragma warning(disable: 4355) // use of 'this' for initialization of _connector
-#endif
-
-
-struct NOVTABLE ComSrvObject   // NOVTABLE erlaubt, da protected Destruktor
-{
-protected:
-       ComSrvObject() : _ref(1) {}
-       virtual ~ComSrvObject() {}
-
-       ULONG   _ref;
-};
-
-struct SimpleComObject : public ComSrvObject
-{
-       ULONG IncRef() {return ++_ref;}
-       ULONG DecRef() {ULONG ref=--_ref; if (!ref) {_ref++; delete this;} return ref;}
-};
-
-
- // server object interfaces
-
-template<typename BASE> struct IComSrvQI : public BASE
-{
-       IComSrvQI(REFIID uuid_base)
-        :      _uuid_base(uuid_base)
-       {
-       }
-
-       STDMETHODIMP QueryInterface(REFIID riid, LPVOID* ppv)
-       {
-               *ppv = NULL;
-
-               if (IsEqualIID(riid, _uuid_base) || IsEqualIID(riid, IID_IUnknown))
-                       {*ppv=static_cast<BASE*>(this); this->AddRef(); return S_OK;}
-
-               return E_NOINTERFACE;
-       }
-
-protected:
-       IComSrvQI() {}
-       virtual ~IComSrvQI() {}
-
-       REFIID  _uuid_base;
-};
-
-template<> struct IComSrvQI<IUnknown> : public IUnknown
-{
-       STDMETHODIMP QueryInterface(REFIID riid, LPVOID* ppv)
-       {
-               *ppv = NULL;
-
-               if (IsEqualIID(riid, IID_IUnknown))
-                       {*ppv=this; AddRef(); return S_OK;}
-
-               return E_NOINTERFACE;
-       }
-
-protected:
-       IComSrvQI<IUnknown>() {}
-       virtual ~IComSrvQI<IUnknown>() {}
-};
-
-
-template<typename BASE, typename OBJ>
-       class IComSrvBase : public IComSrvQI<BASE>
-{
-       typedef IComSrvQI<BASE> super;
-
-protected:
-       IComSrvBase(REFIID uuid_base)
-        :      super(uuid_base)
-       {
-       }
-
-public:
-       STDMETHODIMP_(ULONG) AddRef() {return static_cast<OBJ*>(this)->IncRef();}
-       STDMETHODIMP_(ULONG) Release() {return static_cast<OBJ*>(this)->DecRef();}
-};
-
-
-template<typename T> struct ConnectionPoint : public SIfacePtr<T>
-{
-       ConnectionPoint(IConnectionPointContainer* pCPC, REFIID riid)
-       {
-               CheckError(pCPC->FindConnectionPoint(riid, &this->_p));
-       }
-};
-
-struct EventConnection
-{
-       EventConnection(IConnectionPoint* connectionpoint, IUnknown* sink)
-       {
-               CheckError(connectionpoint->Advise(sink, &_cookie));
-               _connectionpoint = connectionpoint;
-       }
-
-       template<typename T> EventConnection(T& connectionpoint, IUnknown* sink)
-       {
-               CheckError(connectionpoint->Advise(sink, &_cookie));
-               _connectionpoint = connectionpoint;
-       }
-
-/*     template<typename T> EventConnection(SIfacePtr<T>& connectionpoint, IUnknown* sink)
-       {
-               CheckError(connectionpoint->Advise(sink, &_cookie));
-               _connectionpoint = connectionpoint.GetPtr();
-       } */
-
-/*     template<typename T> EventConnection(T& connectionpoint, IUnknown* sink)
-       {
-               CheckError(connectionpoint->Advise(sink, &_cookie));
-               _connectionpoint = connectionpoint;
-       } */
-
-       ~EventConnection()
-       {
-               if (_connectionpoint)
-                       _connectionpoint->Unadvise(_cookie);
-       }
-
-protected:
-       SIfacePtr<IConnectionPoint> _connectionpoint;
-       DWORD   _cookie;
-};
-
-struct EventConnector : public EventConnection
-{
-       EventConnector(IUnknown* unknown, REFIID riid, IUnknown* sink)
-        :      EventConnection(ConnectionPoint<IConnectionPoint>(
-                               SIfacePtr<IConnectionPointContainer>(unknown, IID_IConnectionPointContainer), riid), sink)
-       {
-       }
-};
-
-
-struct OleInPlaceClient : public SimpleComObject,
-                                                       public IOleClientSite,
-                                                       public IOleInPlaceSite
-{
-protected:
-       HWND    _hwnd;
-
-public:
-       OleInPlaceClient(HWND hwnd=0)
-        :      _hwnd(hwnd)
-       {
-       }
-
-       void attach(HWND hwnd)
-       {
-               _hwnd = hwnd;
-       }
-
-       HRESULT attach_control(IOleObject* ole_obj, LONG iVerb=OLEIVERB_INPLACEACTIVATE, HWND hwndParent=0, LPCRECT pRect=NULL)
-       {
-               HRESULT hr = ole_obj->SetClientSite(this);
-               if (FAILED(hr))
-                       return hr;
-
-//             hr = ole_obj->SetHostNames(app, doc));
-
-               hr = ole_obj->DoVerb(iVerb, NULL, this, 0, 0/*hwnd*/, NULL/*&rcPos*/);
-
-               return hr;
-       }
-
-       HRESULT detach(IOleObject* ole_obj, DWORD dwSaveOption=OLECLOSE_SAVEIFDIRTY)
-       {
-               HRESULT hr = ole_obj->Close(dwSaveOption);
-
-               _hwnd = 0;
-
-               return hr;
-       }
-
-       STDMETHODIMP QueryInterface(REFIID riid, LPVOID* ppv)
-       {
-               if (IsEqualIID(riid, IID_IOleClientSite))
-                       {*ppv=static_cast<IOleClientSite*>(this); IncRef(); return S_OK;}
-
-               if (IsEqualIID(riid, IID_IOleInPlaceSite))
-                       {*ppv=static_cast<IOleInPlaceSite*>(this); IncRef(); return S_OK;}
-
-               if (IsEqualIID(riid, IID_IUnknown))
-                       {*ppv=static_cast<IOleClientSite/*oder auch IOleInPlaceSite*/*>(this); IncRef(); return S_OK;}
-
-               return E_NOINTERFACE;
-       }
-
-       STDMETHODIMP_(ULONG) AddRef() {return IncRef();}
-       STDMETHODIMP_(ULONG) Release() {return DecRef();}
-
-
-        // IOleWindow:
-
-       virtual /* [input_sync] */ HRESULT STDMETHODCALLTYPE GetWindow(/* [out] */ HWND __RPC_FAR *phwnd)
-       {
-               *phwnd = _hwnd;
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE ContextSensitiveHelp(/* [in] */ BOOL fEnterMode)
-       {
-               return E_NOTIMPL;
-       }
-
-
-        // IOleClientSite:
-
-       virtual HRESULT STDMETHODCALLTYPE SaveObject()
-       {
-               return E_NOTIMPL;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE GetMoniker(DWORD dwAssign, DWORD dwWhichMoniker, IMoniker __RPC_FAR *__RPC_FAR *ppmk)
-       {
-               return E_NOTIMPL;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE GetContainer(IOleContainer __RPC_FAR *__RPC_FAR *ppContainer)
-       {
-               ppContainer = 0;
-               return E_NOINTERFACE;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE ShowObject()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnShowWindow(BOOL fShow)
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE RequestNewObjectLayout()
-       {
-               return S_OK;
-       }
-
-
-        // IOleInPlaceSite:
-
-       virtual HRESULT STDMETHODCALLTYPE CanInPlaceActivate()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnInPlaceActivate()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnUIActivate()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE GetWindowContext(
-               /* [out] */ IOleInPlaceFrame __RPC_FAR *__RPC_FAR *ppFrame,
-               /* [out] */ IOleInPlaceUIWindow __RPC_FAR *__RPC_FAR *ppDoc,
-               /* [out] */ LPRECT lprcPosRect,
-               /* [out] */ LPRECT lprcClipRect,
-               /* [out][in] */ LPOLEINPLACEFRAMEINFO lpFrameInfo)
-       {
-               ClientRect rect(_hwnd);
-
-               ppFrame = 0;
-               ppDoc = 0;
-               *lprcPosRect = rect;
-               *lprcClipRect = rect;
-
-               assert(lpFrameInfo->cb>=sizeof(OLEINPLACEFRAMEINFO));
-               lpFrameInfo->fMDIApp = FALSE;
-               lpFrameInfo->hwndFrame = 0;
-               lpFrameInfo->haccel = 0;
-               lpFrameInfo->cAccelEntries = 0;
-
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE Scroll(/* [in] */ SIZE scrollExtant)
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnUIDeactivate(/* [in] */ BOOL fUndoable)
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnInPlaceDeactivate()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE DiscardUndoState()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE DeactivateAndUndo()
-       {
-               return S_OK;
-       }
-
-       virtual HRESULT STDMETHODCALLTYPE OnPosRectChange(/* [in] */ LPCRECT lprcPosRect)
-       {
-               return S_OK;
-       }
-};
-
-
- // window with in place activates Active-X Control
-
-template<typename BASE, typename SMARTPTR> struct IPCtrlWindow : public BASE
-{
-       typedef BASE super;
-
-       IPCtrlWindow(HWND hwnd)
-        :      super(hwnd)
-       {
-       }
-
-       template<typename T> IPCtrlWindow(HWND hwnd, T& info)
-        :      super(hwnd, info)
-       {
-       }
-
-       HRESULT create_control(HWND hwnd, REFIID clsid, REFIID riid)
-       {
-                // Erzeugen einer Instanz des Controls
-               HRESULT hr = _control.CreateInstance(clsid, riid);
-               if (FAILED(hr))
-                       return hr;
-
-               _client_side.attach(hwnd);
-
-               hr = _client_side.attach_control(SIfacePtr<IOleObject>(_control, IID_IOleObject)/*, OLEIVERB_INPLACEACTIVATE,
-                                                                                       hwnd, &Rect(10, 10, 500, 500)*/);
-               if (FAILED(hr))
-                       return hr;
-
-                // try to get a IOleInPlaceObject interface for window resizing
-               return _control.QueryInterface(IID_IOleInPlaceObject, &_in_place_object);       // _in_place_object = _control
-       }
-
-protected:
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam)
-       {
-               if (nmsg == WM_SIZE) {
-                       if (_in_place_object) {
-                               RECT rect = {0, 0, LOWORD(lparam), HIWORD(lparam)};
-
-                               _in_place_object->SetObjectRects(&rect, &rect);
-                       }
-               } else if (nmsg == WM_CLOSE) {
-                       _in_place_object = NULL;
-
-                       if (_control) {
-                               _client_side.detach(SIfacePtr<IOleObject>(_control, IID_IOleObject), OLECLOSE_NOSAVE);
-                               _control = NULL;
-                       }
-               }
-
-               return super::WndProc(nmsg, wparam, lparam);
-       }
-
-       ComInit _usingCOM;
-       SMARTPTR _control;
-       OleInPlaceClient _client_side;
-       SIfacePtr<IOleInPlaceObject> _in_place_object;
-};
-
-
-
-#include "exdispid.h"
-
-
-struct DWebBrowserEvents2IF
-{
-       virtual ~DWebBrowserEvents2IF() {}
-
-    virtual void StatusTextChange(const BStr& text)
-               {}
-
-    virtual void ProgressChange(long progress, long progressMax)
-               {}
-
-    virtual void WindowMove()
-               {}
-
-    virtual void WindowResize()
-               {}
-
-    virtual void WindowActivate()
-               {}
-
-    virtual void PropertyChange(const BStr& property)
-               {}
-
-    virtual void DownloadComplete()
-               {}
-
-    virtual void CommandStateChange(long command, bool enable)
-               {}
-
-    virtual void DownloadBegin()
-               {}
-
-    virtual void NewWindow2(IDispatch** ppDisp, VARIANT_BOOL& cancel)
-               {}
-
-    virtual void TitleChange(const BStr& text)
-               {}
-
-    virtual void TitleIconChange(const BStr& text)
-               {}
-
-       virtual void FrameBeforeNavigate(const BStr& url, long flags, const BStr& targetFrameName, VARIANT* postData, const BStr& headers, VARIANT_BOOL& cancel)
-               {}
-
-       virtual void FrameNavigateComplete(const BStr& url)
-               {}
-
-       virtual void FrameNewWindow(const BStr&url, long flags, const BStr& targetFrameName, VARIANT* postData, const BStr& headers, VARIANT_BOOL& processed)
-               {}
-
-    virtual void BeforeNavigate2(IDispatch* pDisp, const Variant& url, const Variant& flags,
-                                                       const Variant& targetFrameName, const Variant& postData,
-                                                       const Variant& headers, VARIANT_BOOL& cancel)
-               {}
-
-    virtual void NavigateComplete2(IDispatch* pDisp, const Variant& url)
-               {}
-
-    virtual void OnQuit()
-               {}
-
-       virtual void OnVisible(bool Visible)
-               {}
-
-       virtual void OnToolbar(bool Visible)
-               {}
-
-       virtual void OnMenubar(bool Visible)
-               {}
-
-       virtual void OnStatusbar(bool Visible)
-               {}
-
-       virtual void OnFullscreen(bool Visible)
-               {}
-
-    virtual void DocumentComplete()
-               {}
-
-       virtual void OnTheatermode(bool Visible)
-               {}
-
-       virtual void OnAddressbar(bool Visible)
-               {}
-
-       virtual void WindowSetResizable(bool Visible)
-               {}
-
-       virtual void WindowClosing(VARIANT_BOOL IsChildWindow, VARIANT_BOOL& cancel)
-               {}
-
-       virtual void WindowSetLeft(long Left)
-               {}
-
-       virtual void WindowSetTop(long Top)
-               {}
-
-       virtual void WindowSetWidth(long Width)
-               {}
-
-       virtual void WindowSetHeight(long Height)
-               {}
-
-       virtual void ClientToHostWindow(long& CX, long& CY)
-               {}
-
-       virtual void SetSecureLockIcon(long SecureLockIcon)
-               {}
-
-    virtual void FileDownload(Variant& cancel)
-               {}
-
-    virtual void NavigateError(IDispatch* pDisp, const Variant& url, const Variant& Frame, const Variant& StatusCode, VARIANT_BOOL& cancel)
-               {}
-
-    virtual void PrivacyImpactedStateChange(bool bImpacted)
-               {}
-};
-
-
- // The web browser control has to be initialized completely before being able,
- // to display a page, that does not access internet.
-struct ANSUNC BrowserNavigator
-{
-       BrowserNavigator();
-
-       void    attach(IWebBrowser* browser);
-       void    goto_url(LPCTSTR url);
-       void    set_html_page(const String& html_txt);
-       void    navigated(LPCTSTR url);
-
-       IWebBrowser* get_browser() {return _browser.get();}
-
-protected:
-       SIfacePtr<IWebBrowser> _browser;
-       String  _new_url;
-       String  _new_html_txt;
-       bool    _browser_initialized;
-};
-
-
- // MinGW defines a wrong FixedDWebBrowserEvents2 interface with virtual functions for DISPID calls, so we use our own, corrected version:
-interface FixedDWebBrowserEvents2 : public IDispatch
-{
-#ifdef __GNUC__
-       virtual ~FixedDWebBrowserEvents2() {}
-#endif
-};
-
-struct ANSUNC DWebBrowserEvents2Impl : public SimpleComObject,
-                                       public IComSrvBase<FixedDWebBrowserEvents2, DWebBrowserEvents2Impl>,
-                                       public DWebBrowserEvents2IF
-{
-       typedef IComSrvBase<FixedDWebBrowserEvents2, DWebBrowserEvents2Impl> super;
-
-
-       DWebBrowserEvents2IF* _callback;
-
-
-       DWebBrowserEvents2Impl(BrowserNavigator& navigator)
-        :      super(DIID_DWebBrowserEvents2),
-               _navigator(navigator)
-       {
-               _callback = this;
-       }
-
-
-/*      // IUnknown
-    STDMETHOD(QueryInterface)(REFIID riid, LPVOID* ppv)
-       {
-               *ppv = NULL;
-
-               if (SUCCEEDED(super::QueryInterface(riid, ppv)))
-                       return S_OK;
-
-               return E_NOINTERFACE;
-       } */
-
-
-        // IDispatch
-       STDMETHOD(GetTypeInfoCount)(UINT* pctinfo)
-               {return E_NOTIMPL;}
-
-       STDMETHOD(GetTypeInfo)(UINT iTInfo, LCID lcid, ITypeInfo** ppTInfo)
-               {return E_NOTIMPL;}
-
-       STDMETHOD(GetIDsOfNames)(REFIID riid, LPOLESTR* rgszNames, UINT cNames, LCID lcid, DISPID* rgDispId)
-               {return E_NOTIMPL;}
-
-       STDMETHOD(Invoke)(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags,
-                                               DISPPARAMS __RPC_FAR *pDispParams, VARIANT __RPC_FAR *pVarResult, EXCEPINFO __RPC_FAR *pExcepInfo, UINT __RPC_FAR *puArgErr)
-       {
-               switch(dispIdMember) {
-                 case DISPID_STATUSTEXTCHANGE:
-                       _callback->StatusTextChange((BStr)Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_COMMANDSTATECHANGE:
-                       _callback->CommandStateChange(Variant(pDispParams->rgvarg[1]), Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_DOWNLOADBEGIN:
-                       _callback->DownloadBegin();
-                       break;
-
-                 case DISPID_PROGRESSCHANGE:   // sent when download progress is updated
-                       _callback->ProgressChange(Variant(pDispParams->rgvarg[1]), Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWMOVE:               // sent when main window has been moved
-                       _callback->WindowMove();
-                       break;
-
-                 case DISPID_WINDOWRESIZE:             // sent when main window has been sized
-                       _callback->WindowResize();
-                       break;
-
-                 case DISPID_WINDOWACTIVATE:   // sent when main window has been activated
-                       _callback->WindowActivate();
-                       break;
-
-                 case DISPID_PROPERTYCHANGE:   // sent when the PutProperty method is called
-                       _callback->PropertyChange((BStr)Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_TITLECHANGE:              // sent when the document title changes
-                       _callback->TitleChange((BStr)Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_TITLEICONCHANGE:  // sent when the top level window icon may have changed.
-                       _callback->TitleIconChange((BStr)Variant(pDispParams->rgvarg[0]));
-                       break;
-
-
-                       // anything below here is not present in DWebBrowserEvents, only in DWebBrowserEvents2: ->
-
-                 case DISPID_FRAMEBEFORENAVIGATE:
-                       if (pDispParams->cArgs != 6)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->FrameBeforeNavigate(
-                                                                 (BStr)Variant(&pDispParams->rgvarg[5]), Variant(&pDispParams->rgvarg[4]),
-                                                                 (BStr)Variant(&pDispParams->rgvarg[3]), &pDispParams->rgvarg[2],
-                                                                 (BStr)Variant(&pDispParams->rgvarg[1]), *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_FRAMENAVIGATECOMPLETE:
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->FrameNavigateComplete((BStr)Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_FRAMENEWWINDOW:
-                       if (pDispParams->cArgs != 6)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->FrameNewWindow((BStr)Variant(&pDispParams->rgvarg[5]), Variant(&pDispParams->rgvarg[4]),
-                                                                 (BStr)Variant(&pDispParams->rgvarg[3]), &pDispParams->rgvarg[2],
-                                                                 (BStr)Variant(&pDispParams->rgvarg[1]), *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_BEFORENAVIGATE2:  // hyperlink clicked on
-                       if (pDispParams->cArgs != 7)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->BeforeNavigate2(Variant(pDispParams->rgvarg[6]),
-                                                                 pDispParams->rgvarg[5], &pDispParams->rgvarg[4],
-                                                                 pDispParams->rgvarg[3], &pDispParams->rgvarg[2],
-                                                                 pDispParams->rgvarg[1], *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_NEWWINDOW2:               // sent when a new window should be created
-                       if (pDispParams->cArgs != 2)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[1]) != (VT_DISPATCH|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->NewWindow2(V_DISPATCHREF(&pDispParams->rgvarg[1]), *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_NAVIGATECOMPLETE2:// UIActivate new document
-                       if (pDispParams->cArgs != 2)
-                               return E_INVALIDARG;
-
-                        // notify the navigator
-                       NavigateComplete2(Variant(pDispParams->rgvarg[1]), Variant(pDispParams->rgvarg[0]));
-
-                       _callback->NavigateComplete2(Variant(pDispParams->rgvarg[1]), Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONQUIT:
-                       _callback->OnQuit();
-                       break;
-
-                 case DISPID_ONVISIBLE:                // sent when the window goes visible/hidden
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnVisible(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONTOOLBAR:                // sent when the toolbar should be shown/hidden
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnToolbar(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONMENUBAR:                // sent when the menubar should be shown/hidden
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnMenubar(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONSTATUSBAR:              // sent when the statusbar should be shown/hidden
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnStatusbar(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONFULLSCREEN:             // sent when kiosk mode should be on/off
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnFullscreen(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_DOCUMENTCOMPLETE:// new document goes ReadyState_Complete
-                       _callback->DocumentComplete();
-                       break;
-
-                 case DISPID_DOWNLOADCOMPLETE:
-                       _callback->DownloadComplete();
-                       break;
-
-                 case DISPID_ONTHEATERMODE:    // sent when theater mode should be on/off
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnTheatermode(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_ONADDRESSBAR:             // sent when the address bar should be shown/hidden
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->OnAddressbar(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWSETRESIZABLE:// sent to set the style of the host window frame
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->WindowSetResizable(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWCLOSING:    // sent before script window.close closes the window
-                       if (pDispParams->cArgs != 2)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->WindowClosing(Variant(pDispParams->rgvarg[1]), *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWSETLEFT:    // sent when the put_left method is called on the WebOC
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->WindowSetLeft(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWSETTOP:             // sent when the put_top method is called on the WebOC
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->WindowSetTop(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWSETWIDTH:   // sent when the put_width method is called on the WebOC
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->WindowSetWidth(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_WINDOWSETHEIGHT:  // sent when the put_height method is called on the WebOC
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->WindowSetHeight(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_CLIENTTOHOSTWINDOW:// sent during window.open to request conversion of dimensions
-                       if (pDispParams->cArgs != 2)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_I4|VT_BYREF))
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[1]) != (VT_I4|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->ClientToHostWindow(*V_I4REF(&pDispParams->rgvarg[1]), *V_I4REF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_SETSECURELOCKICON:// sent to suggest the appropriate security icon to show
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->SetSecureLockIcon(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_FILEDOWNLOAD: {   // Fired to indicate the File Download dialog is opening
-                       if (pDispParams->cArgs != 1)    //@@ every time 2 ?!
-                               return E_INVALIDARG;
-                       Variant var(pDispParams->rgvarg[0]);
-                       _callback->FileDownload(var);}
-                       break;
-
-                 case DISPID_NAVIGATEERROR:    // Fired to indicate the a binding error has occured
-                       if (pDispParams->cArgs != 5)
-                               return E_INVALIDARG;
-                       if (V_VT(&pDispParams->rgvarg[0]) != (VT_BOOL|VT_BYREF))
-                               return E_INVALIDARG;
-                       _callback->NavigateError(Variant(pDispParams->rgvarg[4]), Variant(pDispParams->rgvarg[3]),
-                                                               Variant(pDispParams->rgvarg[2]), Variant(pDispParams->rgvarg[1]),
-                                                               *V_BOOLREF(&pDispParams->rgvarg[0]));
-                       break;
-
-                 case DISPID_PRIVACYIMPACTEDSTATECHANGE:// Fired when the user's browsing experience is impacted
-                       if (pDispParams->cArgs != 1)
-                               return E_INVALIDARG;
-                       _callback->PrivacyImpactedStateChange(Variant(pDispParams->rgvarg[0]));
-                       break;
-
-                 default:
-                       return NOERROR;
-               }
-
-               return S_OK;
-       }
-
-protected:
-       BrowserNavigator& _navigator;
-
-       void NavigateComplete2(IDispatch* pDisp, const Variant& url)
-       {
-               String adr = (BStr)url;
-
-               _navigator.navigated(adr);
-       }
-};
-
-
- /// encapsulation of the Web control
-struct WebChildWindow : public IPCtrlWindow<ChildWindow, SIfacePtr<IWebBrowser2> >,
-                                               public DWebBrowserEvents2Impl
-{
-       typedef IPCtrlWindow<ChildWindow, SIfacePtr<IWebBrowser2> > super;
-       typedef DWebBrowserEvents2Impl web_super;
-
-       WebChildWindow(HWND hwnd, const WebChildWndInfo& info);
-
-       static WebChildWindow* create(const WebChildWndInfo& info)
-       {
-               ChildWindow* child = ChildWindow::create(info,
-                       WINDOW_CREATOR_INFO(WebChildWindow,WebChildWndInfo), CLASSNAME_CHILDWND, NULL, WS_CHILD|WS_VISIBLE);
-
-               return static_cast<WebChildWindow*>(child);
-       }
-
-
-        // DWebBrowserEvents2Impl overides ->
-
-    void BeforeNavigate2(IDispatch* pDisp, const Variant& url, const Variant& flags,
-                                                       const Variant& targetFrameName, const Variant& postData,
-                                                       const Variant& headers, VARIANT_BOOL& cancel)
-       {
-               //String adr = (BStr)url;
-       }
-
-    void NavigateComplete2(IDispatch* pDisp, const Variant& url)
-       {
-               web_super::NavigateComplete2(pDisp, url);
-
-               set_url(String(BStr(url)));
-       }
-
-    void StatusTextChange(const BStr& text)
-       {
-               _statusText = text;
-               SendMessage(_hwndFrame, PM_SETSTATUSTEXT, 0, (LPARAM)_statusText.c_str());
-       }
-
-    void ProgressChange(long Progress, long ProgressMax)
-       {
-               String txt;
-
-               if (Progress>=0 && Progress<ProgressMax)
-                       txt.printf(TEXT("%3d %%"), (int)(100.*Progress/ProgressMax+.5));
-
-               SendMessage(_hwndFrame, PM_SETSTATUSTEXT, 1, (LPARAM)txt.c_str());
-       }
-
-    void WindowMove()
-       {
-       }
-
-    void WindowResize()
-       {
-       }
-
-    void WindowActivate()
-       {
-       }
-
-    void PropertyChange(const BStr& Property)
-       {
-               Variant value;
-               _control->GetProperty(Property, &value);
-       }
-
-    void CommandStateChange(long command/*CSC_NAVIGATEFORWARD, CSC_NAVIGATEBACK*/, bool enable)
-       {
-       }
-
-    void DownloadBegin()
-       {
-       }
-
-    void NewWindow2(IDispatch** ppDisp, VARIANT_BOOL& cancel)
-       {
-               //*ppDisp = ;
-               //cancel = TRUE;
-       }
-
-    void TitleChange(const BStr& text)
-       {
-               SetWindowText(_hwnd, String(text));
-       }
-
-    void TitleIconChange(const BStr& text)
-       {
-       }
-
-    void FrameBeforeNavigate(const BStr& url, long flags, const BStr& targetFrameName, VARIANT* postData, const BStr& headers, VARIANT_BOOL& cancel)
-       {
-       }
-
-    void FrameNavigateComplete(const BStr& url)
-       {
-       }
-
-    void FrameNewWindow(const BStr& url, long flags, const BStr& targetFrameName, VARIANT* postData, const BStr& headers, VARIANT_BOOL& processed)
-       {
-       }
-
-    void OnQuit()
-       {
-       }
-
-       void OnVisible(bool Visible)
-       {
-       }
-
-       void OnToolbar(bool Visible)
-       {
-       }
-
-       void OnMenubar(bool Visible)
-       {
-       }
-
-       void OnStatusbar(bool Visible)
-       {
-       }
-
-       void OnFullscreen(bool Visible)
-       {
-       }
-
-    void DocumentComplete()
-       {
-       }
-
-       void OnTheatermode(bool Visible)
-       {
-       }
-
-       void OnAddressbar(bool Visible)
-       {
-       }
-
-       void WindowSetResizable(bool Visible)
-       {
-       }
-
-       void WindowClosing(VARIANT_BOOL IsChildWindow, VARIANT_BOOL& cancel)
-       {
-       }
-
-       void WindowSetLeft(long Left)
-       {
-       }
-
-       void WindowSetTop(long Top)
-       {
-       }
-
-       void WindowSetWidth(long Width)
-       {
-       }
-
-       void WindowSetHeight(long Height)
-       {
-       }
-
-       void ClientToHostWindow(long& CX, long& CY)
-       {
-       }
-
-       void SetSecureLockIcon(long SecureLockIcon)
-       {
-       }
-
-    void FileDownload(Variant& cancel)
-       {
-       }
-
-    void NavigateError(IDispatch* pDisp, const Variant& url, const Variant& Frame, const Variant& StatusCode, VARIANT_BOOL& cancel)
-       {
-       }
-
-    void PrivacyImpactedStateChange(bool bImpacted)
-       {
-       }
-
-
-protected:
-       BrowserNavigator _navigator;
-       auto_ptr<EventConnector> _connector;
-
-       LRESULT WndProc(UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-       virtual String jump_to_int(LPCTSTR url);
-};
diff --git a/reactos/subsys/system/msconfig/De.rc b/reactos/subsys/system/msconfig/De.rc
deleted file mode 100644 (file)
index f057363..0000000
+++ /dev/null
@@ -1,155 +0,0 @@
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-
-IDD_MSCONFIG_DIALOG DIALOG DISCARDABLE  0, 0, 378, 220
-STYLE DS_CENTER | WS_MINIMIZEBOX | WS_POPUP |
-    WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU |
-    WS_THICKFRAME
-CAPTION "Systemkonfigurationsprogramm"
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL "Tab1",IDC_TAB,"SysTabControl32",WS_TABSTOP,2,2,374,195
-    DEFPUSHBUTTON "OK", IDOK, 211, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-    PUSHBUTTON "&Hilfe", IDC_BTN_HELP, 2, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-    PUSHBUTTON "Abbrechen", IDCANCEL, 267, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-    PUSHBUTTON "Ü&bernehmen", IDC_BTN_APPLY, 323, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-END
-
-IDD_STARTUP_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL         "List3",IDC_STARTUP_LIST, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP, 2, 1, 360, 148
-    PUSHBUTTON      "Alle &aktivieren",IDC_BTN_STARTUP_ACTIVATE,223,155,66,14
-    PUSHBUTTON      "Alle &deaktivieren",IDC_BTN_STARTUP_DEACTIVATE,295,155,66,14
-END
-
-IDD_TOOLS_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL "List2",IDC_TOOLS_LIST, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP, 2, 1, 360, 134
-    EDITTEXT IDC_TOOLS_CMDLINE, 1, 139, 360, 12, ES_READONLY
-    PUSHBUTTON "&Ausführen", IDC_BTN_RUN, 311, 155, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-END
-
-IDD_SERVICES_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL         "List1",IDC_SERVICES_LIST,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | WS_TABSTOP,2,1,360,148
-    PUSHBUTTON      "Alle &aktivieren",IDC_BTN_SERVICES_ACTIVATE,223,155,66,14
-    PUSHBUTTON      "Alle &deaktivieren",IDC_BTN_SERVICES_DEACTIVATE,295,155,66,14
-END
-
-IDD_GENERAL_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
- GROUPBOX "Systemstartauswahl", -1, 10, 10, 340, 150
- CONTROL "&Normaler Systemstart - Alle Gerätetreiber und Dienste laden", IDC_CBX_NORMAL_START, "Button", 0x50010009, 20, 30, 210, 10
- CONTROL "&Diagnosesystemstart - Nur grundlegende Geräte und Dienste laden", IDC_CBX_DIAGNOSTIC_START, "Button", 0x50010009, 20, 45, 230, 10
- CONTROL "B&enutzerdefinierter Systemstart", IDC_CBX_SELECTIVE_STARTUP, "Button", 0x50010009, 20, 60, 120, 10
- CHECKBOX "D&atei SYSTEM.INI verarbeiten", IDC_CBX_SYSTEM_INI, 30, 80, 110, 10
- CHECKBOX "&Systemdienste laden", IDC_CBX_SYSTEM_SERVICE, 30, 95, 90, 10
- CHECKBOX "S&ystemstartelemente laden", IDC_CBX_STARTUP_ITEM, 30, 110, 110, 10
-END
-
-IDD_FREELDR_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-   CONTROL "", IDC_LIST_BOX, "ListBox", 0x50010141, 10, 10, 340, 50, 0x00000200
-   PUSHBUTTON    "&Alle Bootpfade überprüfen", IDC_BTN_CHECK_BOOT_PATH, 10, 65, 90, 12
-   PUSHBUTTON    "A&ls Standard", IDC_BTN_SET_DEFAULT_BOOT, 120, 65, 63, 12
-   PUSHBUTTON    "Nach &oben", IDC_BTN_MOVE_UP_BOOT_OPTION, 203, 65, 63, 12
-   PUSHBUTTON    "Nach &unten", IDC_BTN_MOVE_DOWN_BOOT_OPTION, 286, 65, 63, 12
-   GROUPBOX "Boot Optionen", -1, 10, 80, 250, 90
-   CHECKBOX "/SA&FEBOOT", IDC_CBX_SAFE_BOOT, 15, 90, 50, 10
-   CHECKBOX "/&NOGUIBOOT", IDC_CBX_NO_GUI_BOOT, 15, 105, 55, 10
-   CHECKBOX "/&BOOTLOG", IDC_CBX_BOOT_LOG, 15, 120, 50, 10
-   CHECKBOX "/BAS&EVIDEO", IDC_CBX_BASE_VIDEO, 15, 135, 55, 10
-   CHECKBOX "/S&OS", IDC_CBX_SOS, 15, 150, 50, 10
-   PUSHBUTTON "E&rweiterte Optionen...", IDC_BTN_ADVANCED_OPTIONS, 100, 150, 90, 12 
-   LTEXT "&Zeitlimit:", -1, 280, 91, 30, 10
-   EDITTEXT IDC_TXT_BOOT_TIMEOUT, 310, 90, 25, 12, ES_LEFT
-   LTEXT "Sek.", -1, 340, 91, 15, 10
-END
-
-IDD_FREELDR_ADVANCED_PAGE DIALOG DISCARDABLE  0, 0, 175, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-   CHECKBOX "/&MAXMEM=", IDC_CBX_MAX_MEM, 10, 10, 50, 10
-   EDITTEXT IDC_TXT_MAX_MEM, 80, 10, 60, 12
-   CONTROL "",IDC_SCR_MAX_MEM, "msctls_updown32", 0x50000000, 140, 10, 11, 11
-   CHECKBOX "/&NUMPROC=", IDC_CBX_NUM_PROC, 10, 25, 50, 10
-   COMBOBOX IDC_DRP_NUM_PROC, 80, 25, 60, 10, CBS_DROPDOWNLIST | CBS_SORT | WS_CHILD | WS_VISIBLE | WS_TABSTOP
-   CHECKBOX "/&PCILOCK", IDC_CBX_PCI_LOCK, 10, 40, 50, 10
-   CHECKBOX "/P&ROFILE", IDC_CBX_PROFILE, 10, 55, 50, 10
-   CHECKBOX "/&IRQ", IDC_CBX_IRQ, 10, 70, 40, 12
-   EDITTEXT IDC_TXT_IRQ, 80, 70, 60, 12, ES_LEFT
-   CHECKBOX "/&DEBUG", IDC_CBX_DEBUG, 10, 85, 40, 10
-   CHECKBOX "/D&EBUGPORT", IDC_CBX_DEBUG_PORT, 20, 100, 60, 10
-   COMBOBOX IDC_DRP_DEBUG_PORT, 80, 100, 60, 10, CBS_DROPDOWNLIST | CBS_SORT | WS_CHILD | WS_VISIBLE | WS_TABSTOP
-   CHECKBOX "/&BAUDRATE", IDC_CBX_BAUD_RATE, 20, 115, 50, 10
-   COMBOBOX IDC_DRP_DRP_BAUD_RATE, 80, 115, 60, 10, CBS_DROPDOWNLIST | CBS_SORT | WS_CHILD | WS_VISIBLE | WS_TABSTOP
-   CHECKBOX "/&CHANNEL", IDC_CBX_CHANNEL, 20, 130, 50, 10
-   EDITTEXT IDC_TXT_CHANNEL, 80, 130, 60, 12, ES_LEFT
-   CONTROL "",IDC_SCR_CHANNEL, "msctls_updown32", 0x50000000, 140, 130, 11, 11
-   PUSHBUTTON "OK", IDC_OK, 20, 160, 50, 12
-   PUSHBUTTON "Abbrechen", IDC_CANCEL, 100, 160, 50, 12
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_MSCONFIG             "Systemkonfigurationsprogramm"
-    IDS_TAB_GENERAL          "Allgemein"
-    IDS_TAB_SYSTEM           "SYSTEM.INI"
-    IDS_TAB_FREELDR          "FREELDR.INI"   
-    IDS_TAB_SERVICES         "Dienste" 
-    IDS_TAB_STARTUP          "Systemstart" 
-    IDS_TAB_TOOLS            "Tools"
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_SERVICES_COLUMN_SERVICE "Dienst"
-    IDS_SERVICES_COLUMN_REQ     "Erforderlich"
-    IDS_SERVICES_COLUMN_VENDOR  "Hersteller"
-    IDS_SERVICES_COLUMN_STATUS  "Status"
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_TOOLS_COLUMN_NAME    "Name"
-    IDS_TOOLS_COLUMN_DESCR   "Beschreibung"
-
-    IDS_TOOLS_CMD_NAME       "Konsole"
-    IDS_TOOLS_CMD_DESCR      ""           
-    IDS_TOOLS_CMD_CMD        "cmd.exe"
-
-    IDS_TOOLS_INFO_NAME      "Version"
-    IDS_TOOLS_INFO_DESCR     "Zeigt die installierte ReactOS Version an."
-    IDS_TOOLS_INFO_CMD       "winver.exe"
-
-    IDS_TOOLS_REGEDIT_NAME   "Registrierungs-Editor"
-    IDS_TOOLS_REGEDIT_DESCR  "Öffnet den Registrierungs-Editor."
-    IDS_TOOLS_REGEDIT_CMD    "regedit.exe"
-
-    IDS_TOOLS_SYSDM_NAME     "Systemeigenschaften"
-    IDS_TOOLS_SYSDM_DESCR    "Zeigt Informationen über diesen Rechner an."
-    IDS_TOOLS_SYSDM_CMD      "control"
-    IDS_TOOLS_SYSDM_PARAM    "sysdm.cpl"
-
-    IDS_STARTUP_COLUMN_ELEMENT "Element"
-    IDS_STARTUP_COLUMN_CMD     "Befehl"
-    IDS_STARTUP_COLUMN_PATH    "Pfad"
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_SERVICES_STATUS_RUNNING "Gestartet"
-    IDS_SERVICES_STATUS_STOPPED "Beendet"
-    IDS_SERVICES_YES "Ja"
-    IDS_SERVICES_UNKNOWN "Unbekannt" 
-END
diff --git a/reactos/subsys/system/msconfig/En.rc b/reactos/subsys/system/msconfig/En.rc
deleted file mode 100644 (file)
index 01c170e..0000000
+++ /dev/null
@@ -1,155 +0,0 @@
-LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
-
-IDD_MSCONFIG_DIALOG DIALOG DISCARDABLE  0, 0, 378, 220
-STYLE DS_CENTER | WS_MINIMIZEBOX | WS_POPUP |
-    WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU |
-    WS_THICKFRAME
-CAPTION "System configuration program"
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL "Tab1",IDC_TAB,"SysTabControl32",WS_TABSTOP,2,2,374,195
-    DEFPUSHBUTTON "OK", IDOK, 211, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-    PUSHBUTTON "&Help", IDC_BTN_HELP, 2, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-    PUSHBUTTON "Cancel", IDCANCEL, 267, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-    PUSHBUTTON "Apply", IDC_BTN_APPLY, 323, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-END
-
-IDD_STARTUP_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL         "List3",IDC_STARTUP_LIST, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP, 2, 1, 360, 148
-    PUSHBUTTON      "&Activate all",IDC_BTN_STARTUP_ACTIVATE,223,155,66,14
-    PUSHBUTTON      "&Deactivate all",IDC_BTN_STARTUP_DEACTIVATE,295,155,66,14
-END
-
-IDD_TOOLS_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL "List2",IDC_TOOLS_LIST, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP, 2, 1, 360, 134
-    EDITTEXT IDC_TOOLS_CMDLINE, 1, 139, 360, 12, ES_READONLY
-    PUSHBUTTON "&Run", IDC_BTN_RUN, 311, 155, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-END
-
-IDD_SERVICES_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL         "List1",IDC_SERVICES_LIST,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | WS_TABSTOP,2,1,360,148
-    PUSHBUTTON      "&Activate all",IDC_BTN_SERVICES_ACTIVATE,223,155,66,14
-    PUSHBUTTON      "&Deactivate all",IDC_BTN_SERVICES_DEACTIVATE,295,155,66,14
-END
-
-IDD_GENERAL_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
- GROUPBOX "Startup Selection", -1, 10, 10, 340, 150
- CONTROL "&Normal Startup - load all device drivers and services", IDC_CBX_NORMAL_START, "Button", 0x50010009, 20, 30, 180, 10
- CONTROL "&Diagnostic Startup - load basic devices and services only", IDC_CBX_DIAGNOSTIC_START, "Button", 0x50010009, 20, 45, 195, 10
- CONTROL "S&elective Startup", IDC_CBX_SELECTIVE_STARTUP, "Button", 0x50010009, 20, 60, 70, 10
- CHECKBOX "P&rocess SYSTEM.INI File", IDC_CBX_SYSTEM_INI, 30, 80, 95, 10
- CHECKBOX "&Load System Services", IDC_CBX_SYSTEM_SERVICE, 30, 95, 90, 10
- CHECKBOX "&L&oad Startup Items", IDC_CBX_STARTUP_ITEM, 30, 110, 75, 10
-END
-
-IDD_FREELDR_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-   CONTROL "", IDC_LIST_BOX, "ListBox", 0x50010141, 10, 10, 340, 50, 0x00000200
-   PUSHBUTTON    "&Check All Boot Paths", IDC_BTN_CHECK_BOOT_PATH, 10, 65, 70, 12
-   PUSHBUTTON    "&Set as Default", IDC_BTN_SET_DEFAULT_BOOT, 100, 65, 70, 12
-   PUSHBUTTON    "Move &Up", IDC_BTN_MOVE_UP_BOOT_OPTION, 190, 65, 70, 12
-   PUSHBUTTON    "Move &Down", IDC_BTN_MOVE_DOWN_BOOT_OPTION, 280, 65, 70, 12
-   GROUPBOX "Boot Options", -1, 10, 80, 250, 90
-   CHECKBOX "/SA&FEBOOT", IDC_CBX_SAFE_BOOT, 15, 90, 50, 10
-   CHECKBOX "/&NOGUIBOOT", IDC_CBX_NO_GUI_BOOT, 15, 105, 55, 10
-   CHECKBOX "/&BOOTLOG", IDC_CBX_BOOT_LOG, 15, 120, 50, 10
-   CHECKBOX "/BAS&EVIDEO", IDC_CBX_BASE_VIDEO, 15, 135, 55, 10
-   CHECKBOX "/S&OS", IDC_CBX_SOS, 15, 150, 50, 10
-   PUSHBUTTON "Ad&vanced Options...", IDC_BTN_ADVANCED_OPTIONS, 100, 150, 70, 12 
-   LTEXT "&Timeout:", -1, 280, 91, 30, 10
-   EDITTEXT IDC_TXT_BOOT_TIMEOUT, 310, 90, 25, 12, ES_LEFT
-   LTEXT "sec.", -1, 340, 91, 15, 10
-END
-
-IDD_FREELDR_ADVANCED_PAGE DIALOG DISCARDABLE  0, 0, 175, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-   CHECKBOX "/&MAXMEM=", IDC_CBX_MAX_MEM, 10, 10, 50, 10
-   EDITTEXT IDC_TXT_MAX_MEM, 80, 10, 60, 12
-   CONTROL "",IDC_SCR_MAX_MEM, "msctls_updown32", 0x50000000, 140, 10, 11, 11
-   CHECKBOX "/&NUMPROC=", IDC_CBX_NUM_PROC, 10, 25, 50, 10
-   COMBOBOX IDC_DRP_NUM_PROC, 80, 25, 60, 10, CBS_DROPDOWNLIST | CBS_SORT | WS_CHILD | WS_VISIBLE | WS_TABSTOP
-   CHECKBOX "/&PCILOCK", IDC_CBX_PCI_LOCK, 10, 40, 50, 10
-   CHECKBOX "/P&ROFILE", IDC_CBX_PROFILE, 10, 55, 50, 10
-   CHECKBOX "/&IRQ", IDC_CBX_IRQ, 10, 70, 40, 12
-   EDITTEXT IDC_TXT_IRQ, 80, 70, 60, 12, ES_LEFT
-   CHECKBOX "/&DEBUG", IDC_CBX_DEBUG, 10, 85, 40, 10
-   CHECKBOX "/D&EBUGPORT", IDC_CBX_DEBUG_PORT, 20, 100, 60, 10
-   COMBOBOX IDC_DRP_DEBUG_PORT, 80, 100, 60, 10, CBS_DROPDOWNLIST | CBS_SORT | WS_CHILD | WS_VISIBLE | WS_TABSTOP
-   CHECKBOX "/&BAUDRATE", IDC_CBX_BAUD_RATE, 20, 115, 50, 10
-   COMBOBOX IDC_DRP_DRP_BAUD_RATE, 80, 115, 60, 10, CBS_DROPDOWNLIST | CBS_SORT | WS_CHILD | WS_VISIBLE | WS_TABSTOP
-   CHECKBOX "/&CHANNEL", IDC_CBX_CHANNEL, 20, 130, 50, 10
-   EDITTEXT IDC_TXT_CHANNEL, 80, 130, 60, 12, ES_LEFT
-   CONTROL "",IDC_SCR_CHANNEL, "msctls_updown32", 0x50000000, 140, 130, 11, 11
-   PUSHBUTTON "Ok", IDC_OK, 20, 160, 50, 12
-   PUSHBUTTON "Cancel", IDC_CANCEL, 100, 160, 50, 12
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_MSCONFIG             "System configuration program"
-    IDS_TAB_GENERAL          "General"
-    IDS_TAB_SYSTEM           "SYSTEM.INI"
-    IDS_TAB_FREELDR          "FREELDR.INI"   
-    IDS_TAB_SERVICES         "Services" 
-    IDS_TAB_STARTUP          "Startup" 
-    IDS_TAB_TOOLS            "Tools"
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_SERVICES_COLUMN_SERVICE "Service"
-    IDS_SERVICES_COLUMN_REQ     "Required"
-    IDS_SERVICES_COLUMN_VENDOR  "Vendor"
-    IDS_SERVICES_COLUMN_STATUS  "Status"
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_TOOLS_COLUMN_NAME    "Name"
-    IDS_TOOLS_COLUMN_DESCR   "Description"
-
-    IDS_TOOLS_CMD_NAME       "Console"
-    IDS_TOOLS_CMD_DESCR      ""
-    IDS_TOOLS_CMD_CMD        "cmd.exe"
-
-    IDS_TOOLS_INFO_NAME      "Version"
-    IDS_TOOLS_INFO_DESCR     "Displays version information."
-    IDS_TOOLS_INFO_CMD       "winver.exe"
-
-    IDS_TOOLS_REGEDIT_NAME   "Registry-Editor"
-    IDS_TOOLS_REGEDIT_DESCR  "Opens the Registry-Editor."
-    IDS_TOOLS_REGEDIT_CMD    "regedit.exe"
-
-    IDS_TOOLS_SYSDM_NAME     "System properties"
-    IDS_TOOLS_SYSDM_DESCR    "Shows information about this computer."
-    IDS_TOOLS_SYSDM_CMD      "control"
-    IDS_TOOLS_SYSDM_PARAM    "sysdm.cpl"
-
-    IDS_STARTUP_COLUMN_ELEMENT "Element"
-    IDS_STARTUP_COLUMN_CMD     "Command"
-    IDS_STARTUP_COLUMN_PATH    "Path"
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_SERVICES_STATUS_RUNNING "Running"
-    IDS_SERVICES_STATUS_STOPPED "Stopped"
-    IDS_SERVICES_YES "Yes"
-    IDS_SERVICES_UNKNOWN "Unknown" 
-END
diff --git a/reactos/subsys/system/msconfig/Fr.rc b/reactos/subsys/system/msconfig/Fr.rc
deleted file mode 100644 (file)
index 8c7407f..0000000
+++ /dev/null
@@ -1,96 +0,0 @@
-LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL
-
-IDD_MSCONFIG_DIALOG DIALOG DISCARDABLE  0, 0, 378, 220
-STYLE DS_CENTER | WS_MINIMIZEBOX | WS_POPUP |
-    WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU |
-    WS_THICKFRAME
-CAPTION "Utilitaire de configuration système"
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL "Tab1",IDC_TAB,"SysTabControl32",WS_TABSTOP,2,2,374,195
-    DEFPUSHBUTTON "OK", IDOK, 211, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-    PUSHBUTTON "&Aide", IDC_BTN_HELP, 2, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-    PUSHBUTTON "Annuler", IDCANCEL, 267, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-    PUSHBUTTON "A&ppliquer", IDC_BTN_APPLY, 323, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-END
-
-IDD_STARTUP_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL         "List3",IDC_STARTUP_LIST, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP, 2, 1, 360, 148
-    PUSHBUTTON      "&Activer tout",IDC_BTN_STARTUP_ACTIVATE,223,155,66,14
-    PUSHBUTTON      "&Désactiver tout",IDC_BTN_STARTUP_DEACTIVATE,295,155,66,14
-END
-
-IDD_TOOLS_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL "List2",IDC_TOOLS_LIST, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP, 2, 1, 360, 134
-    EDITTEXT IDC_TOOLS_CMDLINE, 1, 139, 360, 12, ES_READONLY
-    PUSHBUTTON "&Lancer", IDC_BTN_RUN, 311, 155, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
-END
-
-IDD_SERVICES_PAGE DIALOG DISCARDABLE  0, 0, 362, 175
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
-FONT 8, "Tahoma"
-BEGIN
-    CONTROL         "List1",IDC_SERVICES_LIST,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | WS_TABSTOP,2,1,360,148
-    PUSHBUTTON      "&Activer tout",IDC_BTN_SERVICES_ACTIVATE,223,155,66,14
-    PUSHBUTTON      "&Désactiver tout",IDC_BTN_SERVICES_DEACTIVATE,295,155,66,14
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_MSCONFIG             "Utilitaire de configuration système"
-    IDS_TAB_GENERAL          "Général"
-    IDS_TAB_SYSTEM           "SYSTEM.INI"
-    IDS_TAB_FREELDR          "FREELDR.INI"   
-    IDS_TAB_SERVICES         "Services" 
-    IDS_TAB_STARTUP          "Démarrage" 
-    IDS_TAB_TOOLS            "Outils"
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_SERVICES_COLUMN_SERVICE "Service"
-    IDS_SERVICES_COLUMN_REQ     "Requis"
-    IDS_SERVICES_COLUMN_VENDOR  "Fabricant"
-    IDS_SERVICES_COLUMN_STATUS  "Etat"
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_TOOLS_COLUMN_NAME    "Nom"
-    IDS_TOOLS_COLUMN_DESCR   "Description"
-
-    IDS_TOOLS_CMD_NAME       "Console"
-    IDS_TOOLS_CMD_DESCR      ""
-    IDS_TOOLS_CMD_CMD        "cmd.exe"
-
-    IDS_TOOLS_INFO_NAME      "Version"
-    IDS_TOOLS_INFO_DESCR     "Affiche les informations de version."
-    IDS_TOOLS_INFO_CMD       "winver.exe"
-
-    IDS_TOOLS_REGEDIT_NAME   "Editeur de Registre"
-    IDS_TOOLS_REGEDIT_DESCR  "Ouvre l'éditeur de Registre"
-    IDS_TOOLS_REGEDIT_CMD    "regedit.exe"
-
-    IDS_TOOLS_SYSDM_NAME     "Propriétés système"
-    IDS_TOOLS_SYSDM_DESCR    "Affiche/modifie des information a propos de l'ordinateur."
-    IDS_TOOLS_SYSDM_CMD      "control"
-    IDS_TOOLS_SYSDM_PARAM    "sysdm.cpl"
-
-    IDS_STARTUP_COLUMN_ELEMENT "Elément"
-    IDS_STARTUP_COLUMN_CMD     "Commande"
-    IDS_STARTUP_COLUMN_PATH    "Chemin"
-END
-
-STRINGTABLE DISCARDABLE
-BEGIN
-    IDS_SERVICES_STATUS_RUNNING "En cours"
-    IDS_SERVICES_STATUS_STOPPED "Arrêté"
-    IDS_SERVICES_YES "Oui"
-    IDS_SERVICES_UNKNOWN "Inconnu" 
-END
diff --git a/reactos/subsys/system/msconfig/Hu.rc b/reactos/subsys/system/msconfig/Hu.rc
deleted file mode 100644 (file)
index bdbf73f..0000000
+++ /dev/null
@@ -1,98 +0,0 @@
-// Hungarian resources, by Robert Horvath (Talley at cubeclub.hu)\r
-\r
-LANGUAGE LANG_HUNGARIAN, SUBLANG_NEUTRAL\r
-\r
-IDD_MSCONFIG_DIALOG DIALOG DISCARDABLE  0, 0, 378, 220\r
-STYLE DS_CENTER | WS_MINIMIZEBOX | WS_POPUP |\r
-    WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU |\r
-    WS_THICKFRAME\r
-CAPTION "Rendszerbeállítások"\r
-FONT 8, "Tahoma"\r
-BEGIN\r
-    CONTROL "Tab1",IDC_TAB,"SysTabControl32",WS_TABSTOP,2,2,374,195\r
-    DEFPUSHBUTTON "OK", IDOK, 211, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP\r
-    PUSHBUTTON "&Súgó", IDC_BTN_HELP, 2, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP\r
-    PUSHBUTTON "Mégse", IDCANCEL, 267, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP\r
-    PUSHBUTTON "Alkalmaz", IDC_BTN_APPLY, 323, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP\r
-END\r
-\r
-IDD_STARTUP_PAGE DIALOG DISCARDABLE  0, 0, 362, 175\r
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN\r
-FONT 8, "Tahoma"\r
-BEGIN\r
-    CONTROL         "List3",IDC_STARTUP_LIST, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP, 2, 1, 360, 148\r
-    PUSHBUTTON      "Mindet &bekapcsol",IDC_BTN_STARTUP_ACTIVATE,223,155,66,14\r
-    PUSHBUTTON      "Mindet &kikapcsol",IDC_BTN_STARTUP_DEACTIVATE,295,155,66,14\r
-END\r
-\r
-IDD_TOOLS_PAGE DIALOG DISCARDABLE  0, 0, 362, 175\r
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN\r
-FONT 8, "Tahoma"\r
-BEGIN\r
-    CONTROL "List2",IDC_TOOLS_LIST, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP, 2, 1, 360, 134\r
-    EDITTEXT IDC_TOOLS_CMDLINE, 1, 139, 360, 12, ES_READONLY\r
-    PUSHBUTTON "&Futtat", IDC_BTN_RUN, 311, 155, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP\r
-END\r
-\r
-IDD_SERVICES_PAGE DIALOG DISCARDABLE  0, 0, 362, 175\r
-STYLE DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN\r
-FONT 8, "Tahoma"\r
-BEGIN\r
-    CONTROL         "List1",IDC_SERVICES_LIST,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | WS_TABSTOP,2,1,360,148\r
-    PUSHBUTTON      "Mindet &bekapcsol",IDC_BTN_SERVICES_ACTIVATE,223,155,66,14\r
-    PUSHBUTTON      "Mindet &kikapcsol",IDC_BTN_SERVICES_DEACTIVATE,295,155,66,14\r
-END\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-    IDS_MSCONFIG             "Rendszerkonfiguráciüs segédprogram"\r
-    IDS_TAB_GENERAL          "Általános"\r
-    IDS_TAB_SYSTEM           "SYSTEM.INI"\r
-    IDS_TAB_FREELDR          "FREELDR.INI"   \r
-    IDS_TAB_SERVICES         "Szolgáltatások" \r
-    IDS_TAB_STARTUP          "Automatikus indítás" \r
-    IDS_TAB_TOOLS            "Segédprogramok"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-    IDS_SERVICES_COLUMN_SERVICE "Szolgálgatás"\r
-    IDS_SERVICES_COLUMN_REQ     "Lényeges"\r
-    IDS_SERVICES_COLUMN_VENDOR  "Gyártó"\r
-    IDS_SERVICES_COLUMN_STATUS  "Állapot"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-    IDS_TOOLS_COLUMN_NAME    "Név"\r
-    IDS_TOOLS_COLUMN_DESCR   "Description"\r
-\r
-    IDS_TOOLS_CMD_NAME       "Konzol"\r
-    IDS_TOOLS_CMD_DESCR      ""\r
-    IDS_TOOLS_CMD_CMD        "cmd.exe"\r
-\r
-    IDS_TOOLS_INFO_NAME      "Verzió"\r
-    IDS_TOOLS_INFO_DESCR     "Megjeleníti a verzió-információkat."\r
-    IDS_TOOLS_INFO_CMD       "winver.exe"\r
-\r
-    IDS_TOOLS_REGEDIT_NAME   "Rendszerleíróadatbázis-szerkesztõ"\r
-    IDS_TOOLS_REGEDIT_DESCR  "Megnyitja a szerkesztõ programot."\r
-    IDS_TOOLS_REGEDIT_CMD    "regedit.exe"\r
-\r
-    IDS_TOOLS_SYSDM_NAME     "Rendszertulajdonságok"\r
-    IDS_TOOLS_SYSDM_DESCR    "Megjeleníti a számítógép információkat."\r
-    IDS_TOOLS_SYSDM_CMD      "control"\r
-    IDS_TOOLS_SYSDM_PARAM    "sysdm.cpl"\r
-\r
-    IDS_STARTUP_COLUMN_ELEMENT "Element"\r
-    IDS_STARTUP_COLUMN_CMD     "Parancs"\r
-    IDS_STARTUP_COLUMN_PATH    "Elérési út"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-    IDS_SERVICES_STATUS_RUNNING "Fut"\r
-    IDS_SERVICES_STATUS_STOPPED "Leállítva"\r
-    IDS_SERVICES_YES "Igen"\r
-    IDS_SERVICES_UNKNOWN "Ismeretlen"\r
-END\r
diff --git a/reactos/subsys/system/msconfig/freeldrpage.c b/reactos/subsys/system/msconfig/freeldrpage.c
deleted file mode 100644 (file)
index a6d84d5..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-#include <precomp.h>
-
-HWND hFreeLdrPage;
-HWND hFreeLdrDialog;
-
-INT_PTR CALLBACK
-FreeLdrPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
-{
-    switch (message) {
-    case WM_INITDIALOG:
-        hFreeLdrDialog = hDlg;
-           SetWindowPos(hDlg, NULL, 10, 32, 0, 0, SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSIZE | SWP_NOZORDER);
-               return TRUE;
-       }
-
-  return 0;
-}
diff --git a/reactos/subsys/system/msconfig/freeldrpage.h b/reactos/subsys/system/msconfig/freeldrpage.h
deleted file mode 100644 (file)
index 6e0331b..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-extern HWND hFreeLdrPage;
-
-INT_PTR CALLBACK FreeLdrPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
diff --git a/reactos/subsys/system/msconfig/generalpage.c b/reactos/subsys/system/msconfig/generalpage.c
deleted file mode 100644 (file)
index ed5454c..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-#include <precomp.h>
-
-HWND hGeneralPage;
-HWND hGeneralDialog;
-
-INT_PTR CALLBACK
-GeneralPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
-{
-    switch (message) {
-    case WM_INITDIALOG:
-        hGeneralDialog = hDlg;
-           SetWindowPos(hDlg, NULL, 10, 32, 0, 0, SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSIZE | SWP_NOZORDER);
-               return TRUE;
-       }
-
-  return 0;
-}
diff --git a/reactos/subsys/system/msconfig/generalpage.h b/reactos/subsys/system/msconfig/generalpage.h
deleted file mode 100644 (file)
index 408c404..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-extern HWND hGeneralPage;
-
-INT_PTR CALLBACK GeneralPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
diff --git a/reactos/subsys/system/msconfig/msconfig.c b/reactos/subsys/system/msconfig/msconfig.c
deleted file mode 100644 (file)
index 839c6fa..0000000
+++ /dev/null
@@ -1,198 +0,0 @@
-#include <precomp.h>
-
-HINSTANCE hInst = 0;
-
-HWND hMainWnd;                   /* Main Window */
-HWND hTabWnd;                    /* Tab Control Window */
-
-void MsConfig_OnTabWndSelChange(void);
-
-BOOL OnCreate(HWND hWnd)
-{
-       TCHAR   szTemp[256];
-       TCITEM  item;
-
-       hTabWnd = GetDlgItem(hWnd, IDC_TAB);
-    hGeneralPage = CreateDialog(hInst, MAKEINTRESOURCE(IDD_GENERAL_PAGE), hWnd, GeneralPageWndProc);
-    hSystemPage = CreateDialog(hInst, MAKEINTRESOURCE(IDD_SYSTEM_PAGE), hWnd, SystemPageWndProc);
-    hFreeLdrPage = CreateDialog(hInst, MAKEINTRESOURCE(IDD_FREELDR_PAGE), hWnd, FreeLdrPageWndProc);
-    hServicesPage = CreateDialog(hInst, MAKEINTRESOURCE(IDD_SERVICES_PAGE), hWnd, ServicesPageWndProc);
-    hStartupPage = CreateDialog(hInst, MAKEINTRESOURCE(IDD_STARTUP_PAGE), hWnd, StartupPageWndProc);
-    hToolsPage = CreateDialog(hInst, MAKEINTRESOURCE(IDD_TOOLS_PAGE), hWnd, ToolsPageWndProc);
-
-    LoadString(hInst, IDS_MSCONFIG, szTemp, 256);
-    SetWindowText(hWnd, szTemp);
-
-       // Insert Tab Pages
-       LoadString(hInst, IDS_TAB_GENERAL, szTemp, 256);
-    memset(&item, 0, sizeof(TCITEM));
-    item.mask = TCIF_TEXT;
-    item.pszText = szTemp;
-    TabCtrl_InsertItem(hTabWnd, 0, &item);
-
-       LoadString(hInst, IDS_TAB_SYSTEM, szTemp, 256);
-    memset(&item, 0, sizeof(TCITEM));
-    item.mask = TCIF_TEXT;
-    item.pszText = szTemp;
-    TabCtrl_InsertItem(hTabWnd, 1, &item);
-
-       LoadString(hInst, IDS_TAB_FREELDR, szTemp, 256);
-    memset(&item, 0, sizeof(TCITEM));
-    item.mask = TCIF_TEXT;
-    item.pszText = szTemp;
-    TabCtrl_InsertItem(hTabWnd, 2, &item);
-
-       LoadString(hInst, IDS_TAB_SERVICES, szTemp, 256);
-    memset(&item, 0, sizeof(TCITEM));
-    item.mask = TCIF_TEXT;
-    item.pszText = szTemp;
-    TabCtrl_InsertItem(hTabWnd, 3, &item);
-
-       LoadString(hInst, IDS_TAB_STARTUP, szTemp, 256);
-    memset(&item, 0, sizeof(TCITEM));
-    item.mask = TCIF_TEXT;
-    item.pszText = szTemp;
-    TabCtrl_InsertItem(hTabWnd, 4, &item);
-
-       LoadString(hInst, IDS_TAB_TOOLS, szTemp, 256);
-    memset(&item, 0, sizeof(TCITEM));
-    item.mask = TCIF_TEXT;
-    item.pszText = szTemp;
-    TabCtrl_InsertItem(hTabWnd, 5, &item);
-
-    MsConfig_OnTabWndSelChange();
-
-       return TRUE;
-}
-
-
-void MsConfig_OnTabWndSelChange(void)
-{
-    switch (TabCtrl_GetCurSel(hTabWnd)) {
-    case 0: //General
-        ShowWindow(hGeneralPage, SW_SHOW);
-        ShowWindow(hSystemPage, SW_HIDE);
-               ShowWindow(hFreeLdrPage, SW_HIDE);
-               ShowWindow(hServicesPage, SW_HIDE);
-               ShowWindow(hStartupPage, SW_HIDE);
-        ShowWindow(hToolsPage, SW_HIDE);
-        BringWindowToTop(hGeneralPage);
-               break;
-    case 1: //SYSTEM.INI
-        ShowWindow(hGeneralPage, SW_HIDE);
-        ShowWindow(hSystemPage, SW_SHOW);
-        ShowWindow(hToolsPage, SW_HIDE);
-               ShowWindow(hStartupPage, SW_HIDE);
-               ShowWindow(hFreeLdrPage, SW_HIDE);
-               ShowWindow(hServicesPage, SW_HIDE);
-        BringWindowToTop(hSystemPage);
-               break;
-    case 2: //Freeldr
-        ShowWindow(hGeneralPage, SW_HIDE);
-        ShowWindow(hSystemPage, SW_HIDE);
-               ShowWindow(hFreeLdrPage, SW_SHOW);
-               ShowWindow(hServicesPage, SW_HIDE);
-               ShowWindow(hStartupPage, SW_HIDE);
-        ShowWindow(hToolsPage, SW_HIDE);
-        BringWindowToTop(hFreeLdrPage);
-               break;
-    case 3: //Services
-        ShowWindow(hGeneralPage, SW_HIDE);
-        ShowWindow(hSystemPage, SW_HIDE);
-               ShowWindow(hFreeLdrPage, SW_HIDE);
-               ShowWindow(hServicesPage, SW_SHOW);
-               ShowWindow(hStartupPage, SW_HIDE);
-        ShowWindow(hToolsPage, SW_HIDE);
-        BringWindowToTop(hServicesPage);
-               break;
-    case 4: //startup
-        ShowWindow(hGeneralPage, SW_HIDE);
-        ShowWindow(hSystemPage, SW_HIDE);
-               ShowWindow(hFreeLdrPage, SW_HIDE);
-               ShowWindow(hServicesPage, SW_HIDE);
-               ShowWindow(hStartupPage, SW_SHOW);
-        ShowWindow(hToolsPage, SW_HIDE);
-        BringWindowToTop(hStartupPage);
-               break;
-       case 5: //Tools
-        ShowWindow(hGeneralPage, SW_HIDE);
-        ShowWindow(hSystemPage, SW_HIDE);
-               ShowWindow(hFreeLdrPage, SW_HIDE);
-               ShowWindow(hServicesPage, SW_HIDE);
-               ShowWindow(hStartupPage, SW_HIDE);
-        ShowWindow(hToolsPage, SW_SHOW);
-        BringWindowToTop(hToolsPage);
-               break;
-       }
-}
-
-
-/* Message handler for dialog box. */
-INT_PTR CALLBACK
-MsConfigWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
-{
-    int             idctrl;
-    LPNMHDR         pnmh;
-
-    switch (message) {
-    case WM_INITDIALOG:
-        hMainWnd = hDlg;
-        return OnCreate(hDlg);
-
-       case WM_COMMAND:
-
-               if (LOWORD(wParam) == IDOK) {
-                       //MsConfig_OnSaveChanges();
-               }
-
-        if (LOWORD(wParam) == IDOK || LOWORD(wParam) == IDCANCEL) {
-            EndDialog(hDlg, LOWORD(wParam));
-            return TRUE;
-               }
-               break;
-
-    case WM_NOTIFY:
-        idctrl = (int)wParam;
-        pnmh = (LPNMHDR)lParam;
-        if ((pnmh->hwndFrom == hTabWnd) &&
-            (pnmh->idFrom == IDC_TAB) &&
-            (pnmh->code == TCN_SELCHANGE))
-        {
-            MsConfig_OnTabWndSelChange();
-        }
-        break;
-
-    case WM_DESTROY:
-               DestroyWindow(hToolsPage);
-        DestroyWindow(hGeneralPage);
-               DestroyWindow(hServicesPage);
-               DestroyWindow(hStartupPage);
-        DestroyWindow(hFreeLdrPage);
-        DestroyWindow(hSystemPage);
-        return DefWindowProc(hDlg, message, wParam, lParam);
-
-    }
-
-    return 0;
-}
-
-int APIENTRY WinMain(HINSTANCE hInstance,
-                     HINSTANCE hPrevInstance,
-                     LPSTR     lpCmdLine,
-                     int       nCmdShow)
-{
-
-    INITCOMMONCONTROLSEX InitControls;
-
-    InitControls.dwSize = sizeof(INITCOMMONCONTROLSEX);
-    InitControls.dwICC = ICC_TAB_CLASSES | ICC_LISTVIEW_CLASSES;
-    InitCommonControlsEx(&InitControls);
-
-    hInst = hInstance;
-    DialogBox(hInst, (LPCTSTR)IDD_MSCONFIG_DIALOG, NULL, MsConfigWndProc);
-  
-    return 0;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/msconfig/msconfig.h b/reactos/subsys/system/msconfig/msconfig.h
deleted file mode 100644 (file)
index 4a45546..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-extern HINSTANCE hInst;
-
diff --git a/reactos/subsys/system/msconfig/msconfig.rc b/reactos/subsys/system/msconfig/msconfig.rc
deleted file mode 100644 (file)
index 54b22a9..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-#include <windows.h>
-#include <commctrl.h>
-
-#include "resource.h"
-
-
-LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
-
-#define REACTOS_VERSION_DLL
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS Systemconfiguration Tool\0"
-#define REACTOS_STR_INTERNAL_NAME      "msconfig\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "msconfig.exe\0"
-#include <reactos/version.rc>
-
-
-#include "De.rc"
-#include "En.rc"
-#include "Fr.rc"
-#include "Hu.rc"
diff --git a/reactos/subsys/system/msconfig/msconfig.xml b/reactos/subsys/system/msconfig/msconfig.xml
deleted file mode 100644 (file)
index 76d3f79..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<module name="msconfig" type="win32gui" installbase="system32" installname="msconfig.exe">
-       <include base="msconfig">.</include>
-       <define name="UNICODE" />
-       <define name="_UNICODE" />
-       <define name="__REACTOS__" />
-       <define name="__USE_W32API" />
-       <define name="_WIN32_IE">0x600</define>
-       <define name="_WIN32_WINNT">0x501</define>
-       <library>kernel32</library>
-       <library>user32</library>
-       <library>advapi32</library>
-       <library>version</library>
-       <library>comctl32</library>
-       <library>shell32</library>
-       <compilationunit name="unit.c">
-               <file>toolspage.c</file>
-               <file>srvpage.c</file>
-               <file>systempage.c</file>
-               <file>startuppage.c</file>
-               <file>freeldrpage.c</file>
-               <file>generalpage.c</file>
-               <file>msconfig.c</file>
-       </compilationunit>
-       <file>msconfig.rc</file>
-       <pch>precomp.h</pch>
-</module>
diff --git a/reactos/subsys/system/msconfig/precomp.h b/reactos/subsys/system/msconfig/precomp.h
deleted file mode 100644 (file)
index 056a48e..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-#include <windows.h>
-#define NTOS_MODE_USER
-#include <commctrl.h>
-#include <winuser.h>
-#include <tchar.h>
-
-#include "resource.h"
-#include "msconfig.h"
-#include "toolspage.h"
-#include "srvpage.h"
-#include "startuppage.h"
-#include "freeldrpage.h"
-#include "systempage.h"
-#include "generalpage.h"
-
-#define MAX_KEY_LENGTH 255
-#define MAX_VALUE_NAME 16383
-
-
diff --git a/reactos/subsys/system/msconfig/resource.h b/reactos/subsys/system/msconfig/resource.h
deleted file mode 100644 (file)
index 9ad2663..0000000
+++ /dev/null
@@ -1,104 +0,0 @@
-#define IDD_MSCONFIG_DIALOG              101
-#define IDD_TOOLS_PAGE                   102
-#define IDD_SERVICES_PAGE                103
-#define IDD_GENERAL_PAGE                 104
-#define IDD_STARTUP_PAGE                 105
-#define IDD_FREELDR_PAGE                 106
-#define IDD_SYSTEM_PAGE                  107
-#define IDD_FREELDR_ADVANCED_PAGE        108
-
-#define IDC_TAB                         1001
-#define IDC_BTN_APPLY                   1002
-#define IDC_BTN_HELP                    1003
-#define IDC_TOOLS_CMDLINE               1004
-#define IDC_BTN_RUN                     1005
-#define IDC_SERVICES_LIST               1006
-#define IDC_TOOLS_LIST                  1007
-#define IDC_STARTUP_LIST                1008
-#define IDC_BTN_SERVICES_ACTIVATE       1009
-#define IDC_BTN_SERVICES_DEACTIVATE     1010
-#define IDC_BTN_STARTUP_ACTIVATE        1011
-#define IDC_BTN_STARTUP_DEACTIVATE      1012
-#define IDC_CBX_NORMAL_START            1013
-#define IDC_CBX_DIAGNOSTIC_START        1014
-#define IDC_CBX_SELECTIVE_STARTUP       1015
-#define IDC_CBX_SYSTEM_INI              1016
-#define IDC_CBX_SYSTEM_SERVICE          1017
-#define IDC_CBX_STARTUP_ITEM            1018
-#define IDC_LIST_BOX                    1019
-#define IDC_BTN_CHECK_BOOT_PATH         1020
-#define IDC_BTN_SET_DEFAULT_BOOT        1021
-#define IDC_BTN_MOVE_UP_BOOT_OPTION     1022
-#define IDC_BTN_MOVE_DOWN_BOOT_OPTION   1023
-#define IDC_CBX_SAFE_BOOT               1024
-#define IDC_CBX_NO_GUI_BOOT             1025
-#define IDC_CBX_BOOT_LOG                1026
-#define IDC_CBX_BASE_VIDEO              1027
-#define IDC_CBX_SOS                     1028
-#define IDC_BTN_ADVANCED_OPTIONS        1029
-#define IDC_TXT_BOOT_TIMEOUT            1030
-#define IDC_CBX_MAX_MEM                 1031
-#define IDC_TXT_MAX_MEM                 1032
-#define IDC_SCR_MAX_MEM                 1033
-#define IDC_CBX_NUM_PROC                1034
-#define IDC_DRP_NUM_PROC                1035
-#define IDC_CBX_PCI_LOCK                1036
-#define IDC_CBX_PROFILE                 1037
-#define IDC_CBX_IRQ                     1038
-#define IDC_TXT_IRQ                     1039
-#define IDC_CBX_DEBUG                   1040
-#define IDC_CBX_DEBUG_PORT              1041
-#define IDC_DRP_DEBUG_PORT              1042
-#define IDC_CBX_BAUD_RATE               1043
-#define IDC_DRP_DRP_BAUD_RATE           1044
-#define IDC_CBX_CHANNEL                 1045
-#define IDC_TXT_CHANNEL                 1046
-#define IDC_SCR_CHANNEL                 1047
-#define IDC_OK                          1048
-#define IDC_CANCEL                      1049
-
-#define IDS_TAB_TOOLS                   2001
-#define IDS_TAB_SYSTEM                  2002
-#define IDS_TAB_FREELDR                 2003
-#define IDS_TAB_STARTUP                 2004
-#define IDS_TAB_SERVICES                2005
-#define IDS_TAB_GENERAL                 2006
-
-#define IDS_TOOLS_COLUMN_NAME           2010
-#define IDS_TOOLS_COLUMN_DESCR          2011
-#define IDS_SERVICES_COLUMN_SERVICE     2012
-#define IDS_SERVICES_COLUMN_REQ         2013
-#define IDS_SERVICES_COLUMN_VENDOR      2014
-#define IDS_SERVICES_COLUMN_STATUS      2015
-#define IDS_STARTUP_COLUMN_ELEMENT      2016
-#define IDS_STARTUP_COLUMN_CMD          2017
-#define IDS_STARTUP_COLUMN_PATH         2018
-
-#define IDS_TOOLS_CMD_NAME              2100
-#define IDS_TOOLS_CMD_DESCR             2101
-#define IDS_TOOLS_CMD_CMD               2102
-#define IDS_TOOLS_CMD_PARAM             2103
-
-#define IDS_TOOLS_INFO_NAME             2104
-#define IDS_TOOLS_INFO_DESCR            2105
-#define IDS_TOOLS_INFO_CMD              2106
-#define IDS_TOOLS_INFO_PARAM            2107
-
-#define IDS_TOOLS_REGEDIT_NAME          2108
-#define IDS_TOOLS_REGEDIT_DESCR         2109
-#define IDS_TOOLS_REGEDIT_CMD           2110
-#define IDS_TOOLS_REGEDIT_PARAM         2111
-
-#define IDS_TOOLS_SYSDM_NAME            2112
-#define IDS_TOOLS_SYSDM_DESCR           2113
-#define IDS_TOOLS_SYSDM_CMD             2114
-#define IDS_TOOLS_SYSDM_PARAM           2115
-
-#define IDS_SERVICES_STATUS_STOPPED     2200
-#define IDS_SERVICES_STATUS_RUNNING     2201
-#define IDS_SERVICES_YES                2202
-#define IDS_SERVICES_UNKNOWN            2203
-
-#define IDS_MSCONFIG                    3000
-
-/* EOF */
diff --git a/reactos/subsys/system/msconfig/srvpage.c b/reactos/subsys/system/msconfig/srvpage.c
deleted file mode 100644 (file)
index aed2e01..0000000
+++ /dev/null
@@ -1,251 +0,0 @@
-#include <precomp.h>
-
-HWND hServicesPage;
-HWND hServicesListCtrl;
-HWND hServicesDialog;
-
-void GetServices ( void );
-
-INT_PTR CALLBACK
-ServicesPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
-{
-       LV_COLUMN   column;
-       TCHAR       szTemp[256];
-       DWORD dwStyle;
-
-    switch (message) {
-    case WM_INITDIALOG:
-
-        hServicesListCtrl = GetDlgItem(hDlg, IDC_SERVICES_LIST);
-        hServicesDialog = hDlg;
-
-        dwStyle = (DWORD) SendMessage(hServicesListCtrl, LVM_GETEXTENDEDLISTVIEWSTYLE, 0, 0);
-        dwStyle = dwStyle | LVS_EX_FULLROWSELECT | LVS_EX_CHECKBOXES;
-        SendMessage(hServicesListCtrl, LVM_SETEXTENDEDLISTVIEWSTYLE, 0, dwStyle);
-
-           SetWindowPos(hDlg, NULL, 10, 32, 0, 0, SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSIZE | SWP_NOZORDER);
-
-        // Initialize the application page's controls
-        column.mask = LVCF_TEXT | LVCF_WIDTH;
-
-        LoadString(hInst, IDS_SERVICES_COLUMN_SERVICE, szTemp, 256);
-        column.pszText = szTemp;
-        column.cx = 200;
-        ListView_InsertColumn(hServicesListCtrl, 0, &column);
-
-        column.mask = LVCF_TEXT | LVCF_WIDTH;
-        LoadString(hInst, IDS_SERVICES_COLUMN_REQ, szTemp, 256);
-        column.pszText = szTemp;
-        column.cx = 70;
-        ListView_InsertColumn(hServicesListCtrl, 1, &column);
-
-        column.mask = LVCF_TEXT | LVCF_WIDTH;
-        LoadString(hInst, IDS_SERVICES_COLUMN_VENDOR, szTemp, 256);
-        column.pszText = szTemp;
-        column.cx = 200;
-        ListView_InsertColumn(hServicesListCtrl, 2, &column);
-
-        column.mask = LVCF_TEXT | LVCF_WIDTH;
-        LoadString(hInst, IDS_SERVICES_COLUMN_STATUS, szTemp, 256);
-        column.pszText = szTemp;
-        column.cx = 70;
-        ListView_InsertColumn(hServicesListCtrl, 3, &column);
-
-        GetServices();
-               return TRUE;
-       }
-
-  return 0;
-}
-
-void
-GetServices ( void )
-{
-    LV_ITEM item;
-    WORD wCodePage;
-    WORD wLangID;
-    SC_HANDLE ScHandle;
-    SC_HANDLE hService;
-    DWORD BytesNeeded = 0;
-    DWORD ResumeHandle = 0;
-    DWORD NumServices = 0; 
-    DWORD dwHandle, dwLen;
-    size_t Index;
-    UINT BufLen;
-    TCHAR szStatus[128];
-    TCHAR* lpData;
-    TCHAR* lpBuffer;
-    TCHAR szStrFileInfo[80];
-    TCHAR FileName[MAX_PATH];
-    LPVOID pvData;
-
-    LPSERVICE_FAILURE_ACTIONS pServiceFailureActions = NULL;
-    LPQUERY_SERVICE_CONFIG pServiceConfig = NULL;
-    ENUM_SERVICE_STATUS_PROCESS *pServiceStatus = NULL;
-
-    ScHandle = OpenSCManager(NULL, NULL, SC_MANAGER_ENUMERATE_SERVICE);
-    if (ScHandle != INVALID_HANDLE_VALUE)
-    {
-        if (EnumServicesStatusEx(ScHandle, SC_ENUM_PROCESS_INFO, SERVICE_WIN32, SERVICE_STATE_ALL, (LPBYTE)pServiceStatus, 0, &BytesNeeded, &NumServices, &ResumeHandle, 0) == 0)
-        {
-            /* Call function again if required size was returned */
-            if (GetLastError() == ERROR_MORE_DATA)
-            {
-                /* reserve memory for service info array */
-                pServiceStatus = (ENUM_SERVICE_STATUS_PROCESS *) HeapAlloc(GetProcessHeap(), 0, BytesNeeded);
-                if (!pServiceStatus) 
-                               return;
-
-                /* fill array with service info */
-                if (EnumServicesStatusEx(ScHandle, SC_ENUM_PROCESS_INFO, SERVICE_WIN32, SERVICE_STATE_ALL, (LPBYTE)pServiceStatus, BytesNeeded, &BytesNeeded, &NumServices, &ResumeHandle, 0) == 0)
-                {
-                    HeapFree(GetProcessHeap(), 0, pServiceStatus);
-                    return;
-                }
-            }
-            else /* exit on failure */
-            {
-                return;
-            }
-        }
-
-        if (NumServices)
-        {
-            if (!pServiceStatus)
-                return;
-            for (Index = 0; Index < NumServices; Index++)
-            {
-                memset(&item, 0, sizeof(LV_ITEM));
-                item.mask = LVIF_TEXT;
-                item.iImage = 0;
-                item.pszText = pServiceStatus[Index].lpDisplayName;
-                item.iItem = ListView_GetItemCount(hServicesListCtrl);
-                item.lParam = 0;
-                item.iItem = ListView_InsertItem(hServicesListCtrl, &item);
-
-                BytesNeeded = 0;
-                hService = OpenService(ScHandle, pServiceStatus[Index].lpServiceName, SC_MANAGER_CONNECT);
-                if (hService != INVALID_HANDLE_VALUE) 
-                {
-                    /* check if service is required by the system*/
-                    if (!QueryServiceConfig2(hService, SERVICE_CONFIG_FAILURE_ACTIONS, (LPBYTE)pServiceFailureActions, 0, &BytesNeeded))
-                    {
-                        if (GetLastError() == ERROR_INSUFFICIENT_BUFFER)
-                        {
-                            pServiceFailureActions = (LPSERVICE_FAILURE_ACTIONS) HeapAlloc(GetProcessHeap(), 0, BytesNeeded);
-                            if (pServiceFailureActions == NULL) 
-                                           return;
-
-                            if (!QueryServiceConfig2(hService, SERVICE_CONFIG_FAILURE_ACTIONS, (LPBYTE)pServiceFailureActions, BytesNeeded, &BytesNeeded))
-                            {
-                                HeapFree(GetProcessHeap(), 0, pServiceFailureActions);
-                                return;
-                            }
-                        }
-                        else /* exit on failure */
-                        {
-                            return;
-                        }
-                    }
-                    if (pServiceFailureActions->cActions)
-                    {
-                        if (pServiceFailureActions->lpsaActions[0].Type == SC_ACTION_REBOOT)
-                        {
-                            LoadString(hInst, IDS_SERVICES_YES, szStatus, 128);
-                            item.pszText = szStatus;
-                            item.iSubItem = 1;
-                            SendMessage(hServicesListCtrl, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);
-                        }
-                    }
-
-                                       if (pServiceFailureActions != NULL)
-                                       {
-                                               HeapFree(GetProcessHeap(), 0, pServiceFailureActions);
-                                               pServiceFailureActions = NULL;
-                                       }
-
-                    /* get vendor of service binary */
-                    BytesNeeded = 0;
-                    if (!QueryServiceConfig(hService, pServiceConfig, 0, &BytesNeeded))
-                    {
-                        if (GetLastError() == ERROR_INSUFFICIENT_BUFFER)
-                        {
-                            pServiceConfig = (LPQUERY_SERVICE_CONFIG) HeapAlloc(GetProcessHeap(), 0, BytesNeeded);
-                            if (pServiceConfig == NULL) 
-                                           return;
-
-                            if (!QueryServiceConfig(hService, pServiceConfig, BytesNeeded, &BytesNeeded))
-                            {
-                                HeapFree(GetProcessHeap(), 0, pServiceConfig);
-                                return;
-                            }
-                        }
-                        else /* exit on failure */
-                        {
-                            return;
-                        }
-                    }
-
-                    memset(&FileName, 0, MAX_PATH);
-                    if (_tcscspn(pServiceConfig->lpBinaryPathName, _T("\"")))
-                    {
-                        _tcsncpy(FileName, pServiceConfig->lpBinaryPathName, _tcscspn(pServiceConfig->lpBinaryPathName, _T(" ")) );
-                    }
-                    else
-                    {
-                        _tcscpy(FileName, pServiceConfig->lpBinaryPathName);
-                    }
-
-                                       HeapFree(GetProcessHeap(), 0, pServiceConfig);
-                                       pServiceConfig = NULL;
-
-                                       dwLen = GetFileVersionInfoSize(FileName, &dwHandle);
-                    if (dwLen)
-                    {
-                        lpData = (TCHAR*) HeapAlloc(GetProcessHeap(), 0, dwLen);
-                        if (lpData == NULL) 
-                                       return;
-
-                        if (!GetFileVersionInfo (FileName, dwHandle, dwLen, lpData)) {
-                                   HeapFree(GetProcessHeap(), 0, lpData);
-                                   return;
-                           }
-
-                        if (VerQueryValue(lpData, _T("\\VarFileInfo\\Translation"), &pvData, (PUINT) &BufLen))
-                        {
-                            wCodePage = LOWORD(*(DWORD*) pvData);
-                            wLangID = HIWORD(*(DWORD*) pvData);
-                            wsprintf(szStrFileInfo, _T("StringFileInfo\\%04X%04X\\CompanyName"), wCodePage, wLangID);
-                        }
-
-                        if (VerQueryValue (lpData, szStrFileInfo, (LPVOID) &lpBuffer, (PUINT) &BufLen)) {
-                            item.pszText = lpBuffer;
-                            item.iSubItem = 2;
-                            SendMessage(hServicesListCtrl, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);
-                        }  
-                                               HeapFree(GetProcessHeap(), 0, lpData);
-                    }
-                    else
-                    {
-                        LoadString(hInst, IDS_SERVICES_UNKNOWN, szStatus, 128);
-                        item.pszText = szStatus;
-                        item.iSubItem = 2;
-                        SendMessage(hServicesListCtrl, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);
-                    }
-                    CloseServiceHandle(hService);
-                }
-
-                LoadString(hInst, ((pServiceStatus[Index].ServiceStatusProcess.dwCurrentState == SERVICE_STOPPED) ? IDS_SERVICES_STATUS_STOPPED : IDS_SERVICES_STATUS_RUNNING), szStatus, 128);
-                item.pszText = szStatus;
-                item.iSubItem = 3;
-                SendMessage(hServicesListCtrl, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);
-
-            }
-        }
-
-        HeapFree(GetProcessHeap(), 0, pServiceStatus);
-        CloseServiceHandle(ScHandle);
-    }        
-
-
-}
diff --git a/reactos/subsys/system/msconfig/srvpage.h b/reactos/subsys/system/msconfig/srvpage.h
deleted file mode 100644 (file)
index 89c8f3e..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-extern HWND hServicesPage;
-extern HWND hServicesListCtrl;
-
-INT_PTR CALLBACK ServicesPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
diff --git a/reactos/subsys/system/msconfig/startuppage.c b/reactos/subsys/system/msconfig/startuppage.c
deleted file mode 100644 (file)
index 2ebe2ac..0000000
+++ /dev/null
@@ -1,123 +0,0 @@
-#include <precomp.h>
-
-HWND hStartupPage;
-HWND hStartupListCtrl;
-HWND hStartupDialog;
-
-void GetAutostartEntriesFromRegistry ( HKEY hRootKey, TCHAR* KeyName );
-
-INT_PTR CALLBACK
-StartupPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
-{
-    LV_COLUMN   column;
-    TCHAR       szTemp[256];
-    DWORD dwStyle;
-
-    switch (message) {
-    case WM_INITDIALOG:
-
-        hStartupListCtrl = GetDlgItem(hDlg, IDC_STARTUP_LIST);
-        hStartupDialog = hDlg;
-
-        dwStyle = (DWORD) SendMessage(hStartupListCtrl, LVM_GETEXTENDEDLISTVIEWSTYLE, 0, 0);
-        dwStyle = dwStyle | LVS_EX_FULLROWSELECT | LVS_EX_CHECKBOXES;
-        SendMessage(hStartupListCtrl, LVM_SETEXTENDEDLISTVIEWSTYLE, 0, dwStyle);
-
-        SetWindowPos(hDlg, NULL, 10, 32, 0, 0, SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSIZE | SWP_NOZORDER);
-
-        // Initialize the application page's controls
-        column.mask = LVCF_TEXT | LVCF_WIDTH;
-
-        LoadString(hInst, IDS_STARTUP_COLUMN_ELEMENT, szTemp, 256);
-        column.pszText = szTemp;
-        column.cx = 150;
-        ListView_InsertColumn(hStartupListCtrl, 0, &column);
-
-        column.mask = LVCF_TEXT | LVCF_WIDTH;
-        LoadString(hInst, IDS_STARTUP_COLUMN_CMD, szTemp, 256);
-        column.pszText = szTemp;
-        column.cx = 150;
-        ListView_InsertColumn(hStartupListCtrl, 1, &column);
-
-        column.mask = LVCF_TEXT | LVCF_WIDTH;
-        LoadString(hInst, IDS_STARTUP_COLUMN_PATH, szTemp, 256);
-        column.pszText = szTemp;
-        column.cx = 250;
-        ListView_InsertColumn(hStartupListCtrl, 2, &column);
-
-        GetAutostartEntriesFromRegistry(HKEY_LOCAL_MACHINE, _T("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run"));
-        GetAutostartEntriesFromRegistry(HKEY_CURRENT_USER, _T("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run"));
-        //FIXME: What about HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\Userinit
-        //FIXME: Common Startup (startmenu)
-
-        return TRUE;
-    }
-
-    return 0;
-}
-
-void
-GetAutostartEntriesFromRegistry ( HKEY hRootKey, TCHAR* KeyName )
-{
-    HKEY hKey;
-    DWORD Index, dwValues, retVal, dwType;
-    DWORD dwValueLength, dwDataLength = MAX_VALUE_NAME; 
-    TCHAR* Data;
-    TCHAR lpValueName[MAX_KEY_LENGTH];
-    TCHAR Path[MAX_KEY_LENGTH + 5];
-    LV_ITEM item;
-
-    if (RegOpenKeyEx(hRootKey, KeyName, 0, KEY_READ, &hKey) == ERROR_SUCCESS)
-    {
-        if (RegQueryInfoKey(hKey, NULL, NULL, NULL, NULL, NULL, NULL, &dwValues, NULL, NULL, NULL, NULL) == ERROR_SUCCESS)
-        {
-            for (Index = 0, retVal = ERROR_SUCCESS; Index < dwValues; Index++) 
-            {
-                dwValueLength = MAX_KEY_LENGTH;
-                dwDataLength = MAX_VALUE_NAME;
-                Data = (TCHAR*) HeapAlloc(GetProcessHeap(), 0, MAX_VALUE_NAME * sizeof(TCHAR));
-                if (Data == NULL)
-                    break;
-                retVal = RegEnumValue(hKey, Index, lpValueName, &dwValueLength, NULL, &dwType, (LPBYTE)Data, &dwDataLength);
-                if (retVal == ERROR_SUCCESS) 
-                {
-                    memset(&item, 0, sizeof(LV_ITEM));
-                    item.mask = LVIF_TEXT;
-                    item.iImage = 0;
-                    item.pszText = lpValueName;
-                    item.iItem = ListView_GetItemCount(hStartupListCtrl);
-                    item.lParam = 0;
-                    ListView_InsertItem(hStartupListCtrl, &item);
-
-                    if (dwType == REG_SZ)
-                    {
-                        GetLongPathName(Data, Data, (DWORD) _tcsclen(Data));
-                        item.pszText = Data;
-                        item.iSubItem = 1;
-                        SendMessage(hStartupListCtrl, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);
-                    }
-                    
-                    switch (PtrToLong(hRootKey))
-                    {
-                    case PtrToLong(HKEY_LOCAL_MACHINE):
-                        _tcscpy(Path, _T("HKLM\\\0"));
-                        break;
-                    case PtrToLong(HKEY_CURRENT_USER):
-                        _tcscpy(Path, _T("HKCU\\\0"));
-                        break;
-                    default:
-                        _tcscpy(Path, _T("\0"));
-                    }
-
-                    _tcscat(Path, KeyName);
-                    item.pszText = Path;
-                    item.iSubItem = 2;
-                    SendMessage(hStartupListCtrl, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);
-                    HeapFree(GetProcessHeap(), 0, Data);
-                }
-            }
-        }
-        RegCloseKey(hKey);
-    }
-
-}
diff --git a/reactos/subsys/system/msconfig/startuppage.h b/reactos/subsys/system/msconfig/startuppage.h
deleted file mode 100644 (file)
index 9ac6440..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-extern HWND hStartupPage;
-extern HWND hStartupPageListCtrl;
-
-INT_PTR CALLBACK StartupPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
diff --git a/reactos/subsys/system/msconfig/systempage.c b/reactos/subsys/system/msconfig/systempage.c
deleted file mode 100644 (file)
index 316f196..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-#include <precomp.h>
-
-HWND hSystemPage;
-HWND hSystemDialog;
-
-INT_PTR CALLBACK
-SystemPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
-{
-    switch (message) {
-    case WM_INITDIALOG:
-        hSystemDialog = hDlg;
-           SetWindowPos(hDlg, NULL, 10, 32, 0, 0, SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSIZE | SWP_NOZORDER);
-               return TRUE;
-       }
-
-  return 0;
-}
diff --git a/reactos/subsys/system/msconfig/systempage.h b/reactos/subsys/system/msconfig/systempage.h
deleted file mode 100644 (file)
index d928c77..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-extern HWND hSystemPage;
-
-INT_PTR CALLBACK SystemPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
diff --git a/reactos/subsys/system/msconfig/toolspage.c b/reactos/subsys/system/msconfig/toolspage.c
deleted file mode 100644 (file)
index d020a45..0000000
+++ /dev/null
@@ -1,124 +0,0 @@
-#include <precomp.h>
-
-HWND hToolsPage;
-HWND hToolsListCtrl;
-HWND hToolsDialog;
-
-void AddItem ( DWORD, DWORD, DWORD, DWORD );
-void FillListView ( void );
-
-DWORD ListItems_Cmds[20];
-DWORD ListItems_Params[20];
-        
-void AddItem ( DWORD name_id, DWORD descr_id, DWORD cmd_id , DWORD param_id ) {
-       TCHAR szTemp[256];
-    LV_ITEM item;
-
-       LoadString(hInst, name_id, szTemp, 256);
-       memset(&item, 0, sizeof(LV_ITEM));
-    item.mask = LVIF_TEXT;
-    item.iImage = 0;
-    item.pszText = szTemp;
-    item.iItem = ListView_GetItemCount(hToolsListCtrl);
-    item.lParam = 0;
-    ListView_InsertItem(hToolsListCtrl, &item);
-
-       ListItems_Cmds[item.iItem] = cmd_id;
-       ListItems_Params[item.iItem] = param_id;
-
-       LoadString(hInst, descr_id, szTemp, 256);
-       item.pszText = szTemp;
-       item.iSubItem = 1;
-       SendMessage(hToolsListCtrl, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);
-}
-
-void FillListView ( void ) {
-       AddItem(IDS_TOOLS_CMD_NAME, IDS_TOOLS_CMD_DESCR, IDS_TOOLS_CMD_CMD, IDS_TOOLS_CMD_PARAM);
-       AddItem(IDS_TOOLS_REGEDIT_NAME, IDS_TOOLS_REGEDIT_DESCR, IDS_TOOLS_REGEDIT_CMD,IDS_TOOLS_REGEDIT_PARAM);
-       AddItem(IDS_TOOLS_SYSDM_NAME, IDS_TOOLS_SYSDM_DESCR, IDS_TOOLS_SYSDM_CMD, IDS_TOOLS_SYSDM_PARAM);
-       AddItem(IDS_TOOLS_INFO_NAME, IDS_TOOLS_INFO_DESCR, IDS_TOOLS_INFO_CMD, IDS_TOOLS_INFO_PARAM);
-}
-
-INT_PTR CALLBACK
-ToolsPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
-{
-       LV_COLUMN   column;
-       TCHAR       szTemp[256];
-       TCHAR       szTemp2[256];
-       LPNMITEMACTIVATE lpnmitem;
-       LPNMHDR nmh;
-       DWORD dwStyle;
-
-    switch (message) {
-    case WM_INITDIALOG:
-
-        hToolsListCtrl = GetDlgItem(hDlg, IDC_TOOLS_LIST);
-        hToolsDialog = hDlg;
-
-        dwStyle = (DWORD) SendMessage(hToolsListCtrl, LVM_GETEXTENDEDLISTVIEWSTYLE, 0, 0);
-        dwStyle = dwStyle | LVS_EX_FULLROWSELECT;
-        SendMessage(hToolsListCtrl, LVM_SETEXTENDEDLISTVIEWSTYLE, 0, dwStyle);
-
-           SetWindowPos(hDlg, NULL, 10, 32, 0, 0, SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSIZE | SWP_NOZORDER);
-
-        // Initialize the application page's controls
-        column.mask = LVCF_TEXT | LVCF_WIDTH;
-
-        LoadString(hInst, IDS_TOOLS_COLUMN_NAME, szTemp, 256);
-        column.pszText = szTemp;
-        column.cx = 150;
-        ListView_InsertColumn(hToolsListCtrl, 0, &column);
-
-        column.mask = LVCF_TEXT | LVCF_WIDTH;
-        LoadString(hInst, IDS_TOOLS_COLUMN_DESCR, szTemp, 256);
-        column.pszText = szTemp;
-        column.cx = 500;
-        ListView_InsertColumn(hToolsListCtrl, 1, &column);
-
-               FillListView();
-               return TRUE;
-
-       case WM_COMMAND:
-               switch (LOWORD(wParam))
-        {
-        case IDC_BTN_RUN:
-                       if (ListView_GetSelectionMark(hToolsListCtrl) != -1) {
-                               LoadString(hInst, ListItems_Cmds[ListView_GetSelectionMark(hToolsListCtrl)], szTemp, 256);
-                               LoadString(hInst, ListItems_Params[ListView_GetSelectionMark(hToolsListCtrl)], szTemp2, 256);
-                               ShellExecute(0, _T("open"), szTemp, szTemp2, _T(""), SW_NORMAL);
-                       }
-               }
-               break;
-
-       case WM_NOTIFY:
-               nmh = (LPNMHDR) lParam;
-               if (nmh->hwndFrom == hToolsListCtrl)
-               {
-                       switch (nmh->code)
-               {
-                   case NM_CLICK:
-                               lpnmitem = (LPNMITEMACTIVATE) lParam;
-                               if (lpnmitem->iItem > -1) {
-                                       LoadString(hInst, ListItems_Cmds[lpnmitem->iItem], szTemp, 256);
-                                       LoadString(hInst, ListItems_Params[lpnmitem->iItem], szTemp2, 256);
-                                       _tcscat(szTemp, _T(" "));
-                                       _tcscat(szTemp, szTemp2);
-                                       SendDlgItemMessage(hToolsDialog, IDC_TOOLS_CMDLINE, WM_SETTEXT, 0, (LPARAM) szTemp);
-                               }
-                               break;
-                   case NM_DBLCLK:
-                               lpnmitem = (LPNMITEMACTIVATE) lParam;
-                               if (lpnmitem->iItem > -1) {
-                                       LoadString(hInst, ListItems_Cmds[lpnmitem->iItem], szTemp, 256);
-                                       LoadString(hInst, ListItems_Params[lpnmitem->iItem], szTemp2, 256);
-                                       ShellExecute(0, _T("open"), szTemp, szTemp2, _T(""), SW_NORMAL);
-                               }
-                               break;
-                       }
-               }
-               break;
-       }
-
-  return 0;
-}
-
diff --git a/reactos/subsys/system/msconfig/toolspage.h b/reactos/subsys/system/msconfig/toolspage.h
deleted file mode 100644 (file)
index daa938f..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-extern HWND hToolsPage;
-extern HWND hToolsListCtrl;
-
-INT_PTR CALLBACK ToolsPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
-
diff --git a/reactos/subsys/system/sc/control.c b/reactos/subsys/system/sc/control.c
deleted file mode 100644 (file)
index 2fac5fe..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS SC utility
- * FILE:        subsys/system/sc/control.c
- * PURPOSE:     control ReactOS services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *           Ged Murphy 20/10/05 Created
- *
- */
-
-#include "sc.h"
-
-/*
- * handles the following commands:
- * control, continue, interrogate, pause, stop
- */
-
-BOOL Control(DWORD Control, LPCTSTR ServiceName, LPCTSTR *Args)
-{
-    SC_HANDLE hSc;
-    SERVICE_STATUS Status;
-
-#ifdef SCDBG    
-    /* testing */
-    _tprintf(_T("service to control - %s\n\n"), ServiceName);
-    _tprintf(_T("command - %lu\n\n"), Control);
-    _tprintf(_T("Arguments :\n"));
-    while (*Args)
-    {
-        printf("%s\n", *Args);
-        Args++;
-    }
-#endif /* SCDBG */
-
-    hSc = OpenService(hSCManager, ServiceName,
-                      SERVICE_INTERROGATE | SERVICE_PAUSE_CONTINUE |
-                      SERVICE_STOP | SERVICE_USER_DEFINED_CONTROL |
-                      SERVICE_QUERY_STATUS);
-
-    if (hSc == NULL)
-    {
-        _tprintf(_T("openService failed\n"));
-        ReportLastError();
-        return FALSE;
-    }
-
-    if (! ControlService(hSc, Control, &Status))
-    {
-               _tprintf(_T("[SC] controlService FAILED %lu:\n\n"), GetLastError());
-        ReportLastError();
-        return FALSE;
-    }
-
-    CloseServiceHandle(hSc);
-    
-    /* print the status information */
-    
-    return TRUE;
-
-}
diff --git a/reactos/subsys/system/sc/create.c b/reactos/subsys/system/sc/create.c
deleted file mode 100644 (file)
index 89e1ea5..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS SC utility
- * FILE:        subsys/system/sc/create.c
- * PURPOSE:     control ReactOS services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *           Ged Murphy 20/10/05 Created
- *
- */
-
-#include "sc.h"
-
-BOOL Create(LPCTSTR ServiceName, LPCTSTR *ServiceArgs)
-{
-    SC_HANDLE hSc;
-    LPCTSTR BinaryPathName = *++ServiceArgs;
-//    LPCTSTR *Options = ++ServiceArgs;
-    
-    if ((! ServiceName) || (! BinaryPathName))
-        return CreateUsage();
-
-#ifdef SCDBG  
-    /* testing */
-    printf("service to create - %s\n", ServiceName);
-    printf("Binary path - %s\n", BinaryPathName);
-    printf("Arguments :\n");
-    while (*Options)
-    {
-        printf("%s\n", *Options);
-        Options++;
-    }
-#endif 
-    hSc = CreateService(hSCManager,
-                        ServiceName,
-                        ServiceName,
-                        SERVICE_ALL_ACCESS,
-                        SERVICE_WIN32_OWN_PROCESS,
-                        SERVICE_DEMAND_START,
-                        SERVICE_ERROR_NORMAL,
-                        BinaryPathName,
-                        NULL,
-                        NULL,
-                        NULL,
-                        NULL,
-                        NULL);
-
-    if (hSc == NULL)
-    {
-        _tprintf(_T("CreateService failed\n"));
-        ReportLastError();
-        return FALSE;
-    }
-
-       _tprintf(_T("[SC] CreateService SUCCESS\n"));
-    CloseServiceHandle(hSc);
-    return TRUE;
-}
diff --git a/reactos/subsys/system/sc/delete.c b/reactos/subsys/system/sc/delete.c
deleted file mode 100644 (file)
index 2873108..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS SC utility
- * FILE:        subsys/system/sc/delete.c
- * PURPOSE:     control ReactOS services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *           Ged Murphy 20/10/05 Created
- *
- */
-
-#include "sc.h"
-
-BOOL Delete(LPCTSTR ServiceName)
-{
-    SC_HANDLE hSc;
-
-#ifdef SCDBG  
-    /* testing */
-    printf("service to delete - %s\n\n", ServiceName);
-#endif
-
-    hSc = OpenService(hSCManager, ServiceName, DELETE);
-
-    if (hSc == NULL)
-    {
-        _tprintf(_T("openService failed\n"));
-        ReportLastError();
-        return FALSE;
-    }
-
-    if (! DeleteService(hSc))
-    {
-        _tprintf(_T("DeleteService failed\n"));
-        ReportLastError();
-        return FALSE;
-    }
-
-       _tprintf(_T("[SC] DeleteService SUCCESS\n"));
-    CloseServiceHandle(hSc);
-    return TRUE;
-}
diff --git a/reactos/subsys/system/sc/query.c b/reactos/subsys/system/sc/query.c
deleted file mode 100644 (file)
index c951584..0000000
+++ /dev/null
@@ -1,327 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS SC utility
- * FILE:        subsys/system/sc/query.c
- * PURPOSE:     control ReactOS services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *           Ged Murphy 20/10/05 Created
- *
- */
-/*
- * TODO:
- * Allow calling of 2 options e.g.:
- *    type= driver state= inactive
- */
-
-#include "sc.h"
-
-/* local function decs */
-VOID PrintService(BOOL bExtended);
-BOOL EnumServices(DWORD ServiceType, DWORD ServiceState);
-BOOL QueryService(LPCTSTR ServiceName, BOOL bExtended);
-
-/* global variables */
-static ENUM_SERVICE_STATUS_PROCESS *pServiceStatus = NULL;
-DWORD NumServices = 0;
-
-
-BOOL
-Query(LPCTSTR ServiceName, LPCTSTR *ServiceArgs, BOOL bExtended)
-{
-    if (! ServiceName) /* display all running services and drivers */
-    {
-        /* get default values */
-        EnumServices(SERVICE_WIN32, SERVICE_ACTIVE);
-        
-        /* print default values */
-        PrintService(bExtended);
-    }
-    else if (_tcsicmp(ServiceName, _T("type=")) == 0)
-    {
-        LPCTSTR Type = *ServiceArgs;
-        
-        if (_tcsicmp(Type, _T("driver")) == 0)
-            EnumServices(SERVICE_DRIVER, SERVICE_ACTIVE);
-        else if (_tcsicmp(Type, _T("service")) == 0)
-            EnumServices(SERVICE_WIN32, SERVICE_ACTIVE);
-        else if (_tcsicmp(Type, _T("all")) == 0)
-            EnumServices(SERVICE_DRIVER|SERVICE_WIN32, SERVICE_ACTIVE);
-        else
-        {
-            _tprintf(_T("\nERROR following \"type=\"!\n"));
-            _tprintf(_T("Must be \"driver\" or \"service\" or \"all\"\n"));
-        }
-        
-        PrintService(bExtended);
-    }
-    else if(_tcsicmp(ServiceName, _T("state=")) == 0)
-    {
-        LPCTSTR State = *ServiceArgs;
-
-        if (_tcsicmp(State, _T("inactive")) == 0)
-            EnumServices(SERVICE_WIN32, SERVICE_INACTIVE);
-        else if (_tcsicmp(State, _T("all")) == 0)
-            EnumServices(SERVICE_WIN32, SERVICE_STATE_ALL);
-        else
-        {
-            _tprintf(_T("\nERROR following \"state=\"!\n"));
-            _tprintf(_T("Must be \"active\" or \"inactive\" or \"all\"\n"));
-        }
-            
-        PrintService(bExtended);
-    }
-/*
-    else if(_tcsicmp(ServiceName, _T("bufsize=")))
-
-    else if(_tcsicmp(ServiceName, _T("ri=")))
-
-    else if(_tcsicmp(ServiceName, _T("group=")))
-*/
-    else /* print only the service requested */
-    {
-        QueryService(ServiceName, bExtended);
-    }
-    
-    return TRUE;
-}
-
-
-BOOL
-QueryService(LPCTSTR ServiceName, BOOL bExtended)
-{
-    SERVICE_STATUS_PROCESS *pServiceInfo = NULL;
-    SC_HANDLE hSc;
-    DWORD BufSiz = 0;
-    DWORD BytesNeeded = 0;
-    DWORD Ret;
-
-    hSc = OpenService(hSCManager, ServiceName, SERVICE_QUERY_STATUS);
-
-    if (hSc == NULL)
-    {
-        _tprintf(_T("QueryService: openService failed\n"));
-        ReportLastError();
-        return FALSE;
-    }
-
-    Ret = QueryServiceStatusEx(hSc,
-                SC_STATUS_PROCESS_INFO,
-                NULL,
-                BufSiz,
-                &BytesNeeded);
-
-    if ((Ret != 0) || (GetLastError() != ERROR_INSUFFICIENT_BUFFER))
-    {
-        _tprintf(_T("QueryService: First call to QueryServiceStatusEx failed : "));
-        ReportLastError();
-        return FALSE;
-    }
-    else /* Call function again if required size was returned */
-    {
-        /* reserve memory for service info array */
-        pServiceInfo = (SERVICE_STATUS_PROCESS *)
-            HeapAlloc(GetProcessHeap(), 0, BytesNeeded);
-        if (pServiceInfo == NULL)
-        {
-            _tprintf(_T("QueryService: Failed to allocate memory : "));
-            ReportLastError();
-            return FALSE;
-        }
-
-        /* fill array with service info */
-        if (! QueryServiceStatusEx(hSc,
-                    SC_STATUS_PROCESS_INFO,
-                    (LPBYTE)pServiceInfo,
-                    BytesNeeded,
-                    &BytesNeeded))
-        {
-            _tprintf(_T("QueryService: Second call to QueryServiceStatusEx failed : "));
-            ReportLastError();
-            HeapFree(GetProcessHeap(), 0, pServiceInfo);
-            return FALSE;
-        }
-    }
-
-    
-    _tprintf(_T("SERVICE_NAME: %s\n"), ServiceName);
-
-    _tprintf(_T("\tTYPE               : %x  "),
-         (unsigned int)pServiceInfo->dwServiceType);
-    switch (pServiceInfo->dwServiceType)
-    {
-        case 1 : _tprintf(_T("KERNEL_DRIVER\n")); break;
-        case 2 : _tprintf(_T("FILE_SYSTEM_DRIVER\n")); break;
-        case 16 : _tprintf(_T("WIN32_OWN_PROCESS\n")); break;
-        case 32 : _tprintf(_T("WIN32_SHARE_PROCESS\n")); break;
-        default : _tprintf(_T("\n")); break;
-    }
-
-    _tprintf(_T("\tSTATE              : %x  "),
-        (unsigned int)pServiceInfo->dwCurrentState);
-
-    switch (pServiceInfo->dwCurrentState)
-    {
-        case 1 : _tprintf(_T("STOPPED\n")); break;
-        case 2 : _tprintf(_T("START_PENDING\n")); break;
-        case 3 : _tprintf(_T("STOP_PENDING\n")); break;
-        case 4 : _tprintf(_T("RUNNING\n")); break;
-        case 5 : _tprintf(_T("CONTINUE_PENDING\n")); break;
-        case 6 : _tprintf(_T("PAUSE_PENDING\n")); break;
-        case 7 : _tprintf(_T("PAUSED\n")); break;
-        default : _tprintf(_T("\n")); break;
-    }
-
-//        _tprintf(_T("\n\taccepted         : 0x%x\n\n"),
-//            pServiceStatus[i].ServiceStatusProcess.dwControlsAccepted);
-//            (STOPPABLE,NOT_PAUSABLE,ACCEPTS_SHUTDOWN)
-
-    _tprintf(_T("\tWIN32_EXIT_CODE    : %d  (0x%x)\n"),
-        (unsigned int)pServiceInfo->dwWin32ExitCode,
-        (unsigned int)pServiceInfo->dwWin32ExitCode);
-    _tprintf(_T("\tSERVICE_EXIT_CODE  : %d  (0x%x)\n"),
-        (unsigned int)pServiceInfo->dwServiceSpecificExitCode,
-        (unsigned int)pServiceInfo->dwServiceSpecificExitCode);
-    _tprintf(_T("\tCHECKPOINT         : 0x%x\n"),
-        (unsigned int)pServiceInfo->dwCheckPoint);
-    _tprintf(_T("\tWAIT_HINT          : 0x%x\n"),
-        (unsigned int)pServiceInfo->dwWaitHint);
-    if (bExtended)
-    {
-        _tprintf(_T("\tPID                : %lu\n"),
-            pServiceInfo->dwProcessId);
-        _tprintf(_T("\tFLAGS              : %lu\n"),
-            pServiceInfo->dwServiceFlags);
-    }
-    
-    HeapFree(GetProcessHeap(), 0, pServiceInfo);
-
-    return TRUE;
-}
-
-
-BOOL
-EnumServices(DWORD ServiceType, DWORD ServiceState)
-{
-    DWORD BufSize = 0;
-    DWORD BytesNeeded = 0;
-    DWORD ResumeHandle = 0;
-    DWORD Ret;
-
-    /* determine required buffer size */
-    Ret = EnumServicesStatusEx(hSCManager,
-                SC_ENUM_PROCESS_INFO,
-                ServiceType,
-                ServiceState,
-                (LPBYTE)pServiceStatus,
-                BufSize,
-                &BytesNeeded,
-                &NumServices,
-                &ResumeHandle,
-                0);
-
-    if ((Ret != 0) && (GetLastError() != ERROR_MORE_DATA))
-    {
-        _tprintf(_T("EnumServices: First call to EnumServicesStatusEx failed : "));
-        ReportLastError();
-        return FALSE;
-    }
-    else /* Call function again if required size was returned */
-    {
-        /* reserve memory for service info array */
-        pServiceStatus = (ENUM_SERVICE_STATUS_PROCESS *)
-                HeapAlloc(GetProcessHeap(), 0, BytesNeeded);
-        if (pServiceStatus == NULL)
-        {
-            _tprintf(_T("EnumServices: Failed to allocate memory : "));
-            ReportLastError();
-            return FALSE;
-        }
-
-        /* fill array with service info */
-        if (! EnumServicesStatusEx(hSCManager,
-                    SC_ENUM_PROCESS_INFO,
-                    ServiceType,
-                    ServiceState,
-                    (LPBYTE)pServiceStatus,
-                    BytesNeeded,
-                    &BytesNeeded,
-                    &NumServices,
-                    &ResumeHandle,
-                    0))
-        {
-            _tprintf(_T("EnumServices: Second call to EnumServicesStatusEx failed : "));
-            ReportLastError();
-            HeapFree(GetProcessHeap(), 0, pServiceStatus);
-            return FALSE;
-        }
-    }
-
-    return TRUE;
-}
-
-
-VOID
-PrintService(BOOL bExtended)
-{
-    DWORD i;
-    
-    for (i=0; i < NumServices; i++)
-    {
-
-        _tprintf(_T("SERVICE_NAME: %s\n"), pServiceStatus[i].lpServiceName);
-        _tprintf(_T("DISPLAY_NAME: %s\n"), pServiceStatus[i].lpDisplayName);
-
-        _tprintf(_T("\tTYPE               : %x  "),
-            (unsigned int)pServiceStatus[i].ServiceStatusProcess.dwServiceType);
-        switch (pServiceStatus[i].ServiceStatusProcess.dwServiceType)
-        {
-            case 1 : _tprintf(_T("KERNEL_DRIVER\n")); break;
-            case 2 : _tprintf(_T("FILE_SYSTEM_DRIVER\n")); break;
-            case 16 : _tprintf(_T("WIN32_OWN_PROCESS\n")); break;
-            case 32 : _tprintf(_T("WIN32_SHARE_PROCESS\n")); break;
-            default : _tprintf(_T("\n")); break;
-        }
-
-        _tprintf(_T("\tSTATE              : %x  "),
-            (unsigned int)pServiceStatus[i].ServiceStatusProcess.dwCurrentState);
-
-        switch (pServiceStatus[i].ServiceStatusProcess.dwCurrentState)
-        {
-            case 1 : _tprintf(_T("STOPPED\n")); break;
-            case 2 : _tprintf(_T("START_PENDING\n")); break;
-            case 3 : _tprintf(_T("STOP_PENDING\n")); break;
-            case 4 : _tprintf(_T("RUNNING\n")); break;
-            case 5 : _tprintf(_T("CONTINUE_PENDING\n")); break;
-            case 6 : _tprintf(_T("PAUSE_PENDING\n")); break;
-            case 7 : _tprintf(_T("PAUSED\n")); break;
-            default : _tprintf(_T("\n")); break;
-        }
-
-    //        _tprintf(_T("\n\taccepted         : 0x%x\n\n"),
-    //            pServiceStatus[i].ServiceStatusProcess.dwControlsAccepted);
-    //            (STOPPABLE,NOT_PAUSABLE,ACCEPTS_SHUTDOWN)
-
-        _tprintf(_T("\tWIN32_EXIT_CODE    : %d  (0x%x)\n"),
-            (unsigned int)pServiceStatus[i].ServiceStatusProcess.dwWin32ExitCode,
-            (unsigned int)pServiceStatus[i].ServiceStatusProcess.dwWin32ExitCode);
-        _tprintf(_T("\tSERVICE_EXIT_CODE  : %d  (0x%x)\n"),
-            (unsigned int)pServiceStatus[i].ServiceStatusProcess.dwServiceSpecificExitCode,
-            (unsigned int)pServiceStatus[i].ServiceStatusProcess.dwServiceSpecificExitCode);
-        _tprintf(_T("\tCHECKPOINT         : 0x%x\n"),
-            (unsigned int)pServiceStatus[i].ServiceStatusProcess.dwCheckPoint);
-        _tprintf(_T("\tWAIT_HINT          : 0x%x\n"),
-            (unsigned int)pServiceStatus[i].ServiceStatusProcess.dwWaitHint);
-        if (bExtended)
-        {
-            _tprintf(_T("\tPID                : %lu\n"),
-                pServiceStatus[i].ServiceStatusProcess.dwProcessId);
-            _tprintf(_T("\tFLAGS              : %lu\n"),
-                pServiceStatus[i].ServiceStatusProcess.dwServiceFlags);
-        }
-
-            _tprintf(_T("\n"));
-    }
-    
-    _tprintf(_T("number : %lu\n"), NumServices);
-}
diff --git a/reactos/subsys/system/sc/sc.c b/reactos/subsys/system/sc/sc.c
deleted file mode 100644 (file)
index de8333d..0000000
+++ /dev/null
@@ -1,212 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS SC utility
- * FILE:        subsys/system/sc/sc.c
- * PURPOSE:     control ReactOS services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *           Ged Murphy 20/10/05 Created
- *
- */
-
-#include "sc.h"
-
-SC_HANDLE hSCManager;
-
-DWORD ReportLastError(VOID)
-{
-    LPVOID lpMsgBuf;
-    DWORD RetVal;
-
-    DWORD ErrorCode = GetLastError();
-    if (ErrorCode != ERROR_SUCCESS) 
-    {
-        RetVal = FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER |
-                               FORMAT_MESSAGE_FROM_SYSTEM |
-                               FORMAT_MESSAGE_IGNORE_INSERTS,
-                               NULL,
-                               ErrorCode,
-                               MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), /* Default language */
-                               (LPTSTR) &lpMsgBuf,
-                               0,
-                               NULL );
-
-        if (RetVal != 0)
-        {
-            _tprintf(_T("%s"), (LPTSTR)lpMsgBuf);
-
-            LocalFree(lpMsgBuf);
-            /* return number of TCHAR's stored in output buffer
-             * excluding '\0' - as FormatMessage does*/
-            return RetVal;
-        }
-    }
-    return 0;
-}
-
-
-INT ScControl(LPTSTR MachineName,   // remote machine name
-              LPCTSTR Command,      // sc command
-              LPCTSTR ServiceName,  // name of service
-              LPCTSTR *ServiceArgs, // any options
-              DWORD ArgCount)       // argument counter
-{
-    /* count trailing arguments */
-    ArgCount -= 3;
-
-    if (MachineName)
-    {
-        _tprintf(_T("Remote service control is not yet implemented\n"));
-        return 2;
-    }
-    
-    /* if we are emurating the services, we don't need administrator access */
-    if ( (_tcsicmp(Command, _T("query")) == 0) || (_tcsicmp(Command, _T("queryex")) == 0) )
-        hSCManager = OpenSCManager(MachineName, NULL, SC_MANAGER_ENUMERATE_SERVICE);
-    else
-        hSCManager = OpenSCManager(MachineName, NULL, SC_MANAGER_ALL_ACCESS);
-    if (hSCManager == NULL)
-    {
-        _tprintf(_T("[SC] OpenSCManager FAILED %lu:\n\n"), GetLastError());
-        ReportLastError();
-        return -1;
-    }
-
-    /* emurate command */
-    if (_tcsicmp(Command, _T("query")) == 0)
-        Query(ServiceName, ServiceArgs, FALSE);
-        
-    else if (_tcsicmp(Command, _T("queryex")) == 0)
-        Query(ServiceName, ServiceArgs, TRUE);
-        
-    else if (_tcsicmp(Command, _T("start")) == 0)
-    {
-        if (ServiceName)
-            Start(ServiceName, ServiceArgs, ArgCount);
-        else
-            StartUsage();
-    }
-    else if (_tcsicmp(Command, _T("pause")) == 0)
-    {
-        if (ServiceName)
-            Control(SERVICE_CONTROL_PAUSE, ServiceName, ServiceArgs);
-        else
-            PauseUsage();
-    }
-    else if (_tcsicmp(Command, _T("interrogate")) == 0)
-    {
-        if (ServiceName)
-            Control(SERVICE_CONTROL_INTERROGATE, ServiceName, ServiceArgs);
-        else
-            InterrogateUsage();
-    }
-    else if (_tcsicmp(Command, _T("stop")) == 0)
-    {
-        if (ServiceName)
-            Control(SERVICE_CONTROL_STOP, ServiceName, ServiceArgs);
-        else
-            StopUsage();
-    }
-    else if (_tcsicmp(Command, _T("continue")) == 0)
-    {
-        if (ServiceName)
-            Control(SERVICE_CONTROL_CONTINUE, ServiceName, ServiceArgs);
-        else
-            ContinueUsage();
-    }
-    else if (_tcsicmp(Command, _T("delete")) == 0)
-    {
-        if (ServiceName)
-            Delete(ServiceName);
-        else
-            DeleteUsage();
-    }
-    else if (_tcsicmp(Command, _T("create")) == 0)
-    {
-        if (*ServiceArgs)
-            Create(ServiceName, ServiceArgs);
-        else
-            CreateUsage();
-    }
-    else if (_tcsicmp(Command, _T("control")) == 0)
-    {
-        if (ServiceName)
-            Control(0, ServiceName, ServiceArgs);
-        else
-            ContinueUsage();
-    }
-    return 0;
-}
-
-#if defined(_UNICODE) && defined(__GNUC__)
-static
-#endif
-
-int _tmain(int argc, LPCTSTR argv[])
-{
-       LPTSTR MachineName = NULL;   // remote machine
-    LPCTSTR Command = NULL;      // sc command
-    LPCTSTR ServiceName = NULL;  // Name of service
-
-    if (argc < 2)
-        return MainUsage();
-
-    /* get server name */
-    if ((argv[1][0] == '\\') && (argv[1][1] == '\\'))
-    {
-        if (argc < 3)
-            return MainUsage();
-
-        _tcscpy(MachineName, argv[1]);
-        Command = argv[2];
-        if (argc > 3)
-            ServiceName = argv[3];
-        return ScControl(MachineName, Command, ServiceName,  &argv[4], argc);
-    }
-    else
-    {
-        Command = argv[1];
-        if (argc > 2)
-            ServiceName = argv[2];
-        return ScControl(MachineName, Command, ServiceName, &argv[3], argc);
-    }
-}
-
-
-#if defined(_UNICODE) && defined(__GNUC__)
-/* HACK - MINGW HAS NO OFFICIAL SUPPORT FOR wmain()!!! */
-int main( int argc, char **argv )
-{
-    WCHAR **argvW;
-    int i, j, Ret = 1;
-
-    if ((argvW = malloc(argc * sizeof(WCHAR*))))
-    {
-        /* convert the arguments */
-        for (i = 0, j = 0; i < argc; i++)
-        {
-            if (!(argvW[i] = malloc((strlen(argv[i]) + 1) * sizeof(WCHAR))))
-            {
-                j++;
-            }
-            swprintf(argvW[i], L"%hs", argv[i]);
-        }
-        
-        if (j == 0)
-        {
-            /* no error converting the parameters, call wmain() */
-            Ret = wmain(argc, (LPCTSTR *)argvW);
-        }
-        
-        /* free the arguments */
-        for (i = 0; i < argc; i++)
-        {
-            if (argvW[i])
-                free(argvW[i]);
-        }
-        free(argvW);
-    }
-    
-    return Ret;
-}
-#endif
diff --git a/reactos/subsys/system/sc/sc.h b/reactos/subsys/system/sc/sc.h
deleted file mode 100644 (file)
index f6c977c..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-#include <windows.h>
-#include <conio.h>
-#include <stdio.h>
-#include <tchar.h>
-
-extern SC_HANDLE hSCManager; // declared in sc.c
-
-//#define SCDBG
-
-/* control functions */
-BOOL Query(LPCTSTR ServiceName, LPCTSTR *ServiceArgs, BOOL bExtended);
-BOOL Start(LPCTSTR ServiceName, LPCTSTR *ServiceArgs, INT ArgCount);
-BOOL Create(LPCTSTR ServiceName, LPCTSTR *ServiceArgs);
-BOOL Delete(LPCTSTR ServiceName);
-BOOL Control(DWORD Control, LPCTSTR ServiceName, LPCTSTR *Args);
-
-/* print and error functions */
-DWORD ReportLastError(VOID);
-
-/* usage functions */
-INT MainUsage(VOID);
-INT StartUsage(VOID);
-INT PauseUsage(VOID);
-INT InterrogateUsage(VOID);
-INT ContinueUsage(VOID);
-INT StopUsage(VOID);
-INT ConfigUsage(VOID);
-INT DescriptionUsage(VOID);
-INT DeleteUsage(VOID);
-INT CreateUsage(VOID);
diff --git a/reactos/subsys/system/sc/sc.rc b/reactos/subsys/system/sc/sc.rc
deleted file mode 100644 (file)
index 8677743..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-#define REACTOS_STR_FILE_DESCRIPTION   "Services control application\0"\r
-#define REACTOS_STR_INTERNAL_NAME      "sc\0"\r
-#define REACTOS_STR_ORIGINAL_FILENAME  "sc.exe\0"\r
-#include <reactos/version.rc>\r
diff --git a/reactos/subsys/system/sc/sc.xml b/reactos/subsys/system/sc/sc.xml
deleted file mode 100644 (file)
index 076fb90..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-<module name="sc" type="win32cui" installbase="system32" installname="sc.exe">\r
-       <define name="__USE_W32API" />\r
-       <define name="DEFINE_GUID" />\r
-       <define name="UNICODE" />\r
-       <define name="_UNICODE" />\r
-       <library>kernel32</library>\r
-       <library>advapi32</library>\r
-       <file>sc.c</file>\r
-       <file>start.c</file>\r
-       <file>query.c</file>\r
-       <file>control.c</file>\r
-       <file>create.c</file>\r
-       <file>delete.c</file>\r
-       <file>usage.c</file>\r
-       <file>sc.rc</file>\r
-       <pch>sc.h</pch>\r
-</module>\r
diff --git a/reactos/subsys/system/sc/start.c b/reactos/subsys/system/sc/start.c
deleted file mode 100644 (file)
index bb4277d..0000000
+++ /dev/null
@@ -1,111 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS SC utility
- * FILE:        subsys/system/sc/start.c
- * PURPOSE:     control ReactOS services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *           Ged Murphy 20/10/05 Created
- *
- */
-
-#include "sc.h"
-
-BOOL Start(LPCTSTR ServiceName, LPCTSTR *ServiceArgs, INT ArgCount)
-{
-    SC_HANDLE hSc;
-    SERVICE_STATUS_PROCESS ServiceStatus, ServiceStatus2;
-    DWORD BytesNeeded;
-
-#ifdef SCDBG  
-    /* testing */
-    _tprintf(_T("service to start - %s\n\n"), ServiceName);
-    _tprintf(_T("Arguments :\n"));
-    while (*ServiceArgs)
-    {
-        printf("%s\n", *ServiceArgs);
-        ServiceArgs++;
-    }
-#endif    
-
-    /* get a handle to the service requested for starting */
-    hSc = OpenService(hSCManager, ServiceName, SERVICE_ALL_ACCESS);
-
-    if (hSc == NULL)
-    {
-        _tprintf(_T("openService failed\n"));
-        ReportLastError();
-        return FALSE;
-    }
-
-    /* start the service opened */
-    if (! StartService(hSc, ArgCount, ServiceArgs))
-    {
-               _tprintf(_T("[SC] StartService FAILED %lu:\n\n"), GetLastError());
-        ReportLastError();
-        return FALSE;
-    }
-    
-    if (! QueryServiceStatusEx(
-            hSc,
-            SC_STATUS_PROCESS_INFO,
-            (LPBYTE)&ServiceStatus,
-            sizeof(SERVICE_STATUS_PROCESS),
-            &BytesNeeded))
-    {
-        _tprintf(_T("QueryServiceStatusEx 1 failed\n"));
-        ReportLastError();
-        return FALSE;
-    }
-
-    
-    while (ServiceStatus.dwCurrentState == SERVICE_START_PENDING)
-    {
-        /* wait before checking status */
-        Sleep(ServiceStatus.dwWaitHint);
-        
-        /* check status again */
-        if (! QueryServiceStatusEx(
-                hSc,
-                SC_STATUS_PROCESS_INFO,
-                (LPBYTE)&ServiceStatus,
-                sizeof(SERVICE_STATUS_PROCESS),
-                &BytesNeeded))
-        {
-            _tprintf(_T("QueryServiceStatusEx 2 failed\n"));
-            ReportLastError();
-            return FALSE;
-        }
-    }
-
-       QueryServiceStatusEx(hSc, SC_STATUS_PROCESS_INFO, (LPBYTE)&ServiceStatus2, 
-               sizeof(SERVICE_STATUS_PROCESS), &BytesNeeded);
-
-    CloseServiceHandle(hSc);
-    
-    if (ServiceStatus.dwCurrentState == SERVICE_RUNNING)
-    {
-        _tprintf(_T("\nSERVICE_NAME: %s\n"), ServiceName);
-        _tprintf(_T("\tTYPE               : %lu\n"), ServiceStatus2.dwServiceType);
-        _tprintf(_T("\tSTATE              : %lu\n"), ServiceStatus2.dwCurrentState);
-               _tprintf(_T("\tWIN32_EXIT_CODE    : %lu\n"), ServiceStatus2.dwWin32ExitCode);
-               _tprintf(_T("\tCHECKPOINT         : %lu\n"), ServiceStatus2.dwCheckPoint);
-               _tprintf(_T("\tWAIT_HINT          : %lu\n"), ServiceStatus2.dwWaitHint);
-               _tprintf(_T("\tPID                : %lu\n"), ServiceStatus2.dwProcessId);
-               _tprintf(_T("\tFLAGS              : %lu\n"), ServiceStatus2.dwServiceFlags);
-
-        return TRUE;
-    }
-    else
-    {
-        _tprintf(_T("Failed to start %s\n"), ServiceName);
-        _tprintf(_T("Curent state: %lu\n"), ServiceStatus.dwCurrentState);
-        _tprintf(_T("Exit code: %lu\n"), ServiceStatus.dwWin32ExitCode);
-        _tprintf(_T("Service Specific exit code: %lu\n"),
-                ServiceStatus.dwServiceSpecificExitCode);
-        _tprintf(_T("Check point: %lu\n"), ServiceStatus.dwCheckPoint);
-        _tprintf(_T("Wait hint: %lu\n"), ServiceStatus.dwWaitHint);
-        
-        return FALSE;
-    }
-}
diff --git a/reactos/subsys/system/sc/usage.c b/reactos/subsys/system/sc/usage.c
deleted file mode 100644 (file)
index eb02542..0000000
+++ /dev/null
@@ -1,204 +0,0 @@
-/*
- * COPYRIGHT:   See COPYING in the top level directory
- * PROJECT:     ReactOS SC utility
- * FILE:        subsys/system/sc/usage.c
- * PURPOSE:     control ReactOS services
- * PROGRAMMERS: Ged Murphy (gedmurphy@gmail.com)
- * REVISIONS:
- *           Ged Murphy 20/10/05 Created
- *
- */
-#include "sc.h"
-
-INT MainUsage(VOID)
-{
-    INT c;
-
-    _tprintf(_T("DESCRIPTION:\n")
-    _T("\tSC is a command line program used for communicating with\n")
-    _T("\tthe Service Control Manager and its services.\n")
-    _T("USAGE:\n")
-    _T("\tsc <server> [command] [service name] <option1> <option2>...\n")
-
-    _T("\tThe optional parameter <server> has the form \"\\ServerName\"\n")
-    _T("\tFurther help on commands can be obtained by typing: \"sc [command]\"\n")
-    _T("\tService Commands:\n")
-    _T("\t  query          : Queries the status for a service, or\n")
-    _T("\t                   enumerates the status for types of services.\n")
-    _T("\t  queryex        : Queries the extended status for a service, or\n")
-//    _T("\t                   enumerates the status for types of services.\n"
-    _T("\t  start          : Starts a service.\n")
-    _T("\t  pause          : Sends a PAUSE control request to a service.\n")
-    _T("\t  interrogate    : Sends a INTERROGATE control request to a service.\n")
-    _T("\t  continue       : Sends a CONTINUE control request to a service.\n")
-    _T("\t  stop           : Sends a STOP request to a service.\n")
-//    "\t  config         : Changes the configuration of a service (persistant).\n"
-//    "\t  description    : Changes the description of a service.\n"
-//    "\t  failure        : Changes the actions taken by a service upon failure.\n"
-//    "\t  qc             : Queries the configuration information for a service.\n"
-//    "\t  qdescription   : Queries the description for a service.\n"
-//    "\t  qfailure       : Queries the actions taken by a service upon failure.\n"
-    _T("\t  delete         : Deletes a service (from the registry).\n")
-    _T("\t  create         : Creates a service. (adds it to the registry).\n")
-    _T("\t  control        : Sends a control to a service.\n"));
-//    "\t  sdshow         : Displays a service's security descriptor.\n")
-//    "\t  sdset          : Sets a service's security descriptor.\n")
-//    "\t  GetDisplayName : Gets the DisplayName for a service.\n")
-//    "\t  GetKeyName     : Gets the ServiceKeyName for a service.\n")
-//    "\t  EnumDepend     : Enumerates Service Dependencies.\n")
-//    "\n")
-//    "\tService Name Independant Commands:\n")
-//    "\t  boot           : (ok | bad) Indicates whether the last boot should\n")
-//    "\t                   be saved as the last-known-good boot configuration\n")
-//    "\t  Lock           : Locks the SCM Database\n")
-//    "\t  QueryLock      : Queries the LockStatus for the SCM Database\n")
-
-    _tprintf(_T("\nWould you like to see help for the QUERY and QUERYEX commands? [ y | n ]: "));
-    c = _getch(); // _gettch isn't defined in our tchar.h
-    _tprintf(_T("%c\n"), c);
-    if (tolower(c) == 'y')
-    {
-        _tprintf(_T("QUERY and QUERYEX OPTIONS :\n")
-        _T("        If the query command is followed by a service name, the status\n")
-        _T("        for that service is returned.  Further options do not apply in\n")
-        _T("        this case.  If the query command is followed by nothing or one of\n")
-        _T("        the options listed below, the services are enumerated.\n")
-        _T("    type=    Type of services to enumerate (driver, service, all)\n")
-        _T("             (default = service)\n")
-        _T("    state=   State of services to enumerate (inactive, all)\n")
-        _T("             (default = active)\n")
-/*
-        _T("    bufsize= The size (in bytes) of the enumeration buffer\n")
-        _T("             (default = 4096)\n")
-        _T("    ri=      The resume index number at which to begin the enumeration\n")
-        _T("             (default = 0)\n")
-        _T("    group=   Service group to enumerate\n")
-        _T("             (default = all groups)\n")
-*/
-        _T("SYNTAX EXAMPLES\n")
-        _T("sc query                - Enumerates status for active services & drivers\n")
-        _T("sc query messenger      - Displays status for the messenger service\n")
-        _T("sc queryex messenger    - Displays extended status for the messenger service\n")
-        _T("sc query type= driver   - Enumerates only active drivers\n")
-        _T("sc query type= service  - Enumerates only Win32 services\n")
-        _T("sc query state= all     - Enumerates all services & drivers\n")
-//        _T("sc query bufsize= 50    - Enumerates with a 50 byte buffer.\n")
-//        _T("sc query ri= 14         - Enumerates with resume index = 14\n")
-//        _T("sc queryex group= ""    - Enumerates active services not in a group\n")
-        _T("sc query type= service type= interact - Enumerates all interactive services\n"));
-//        _T("sc query type= driver group= NDIS     - Enumerates all NDIS drivers\n"));
-    }
-
-
-    return 0;
-}
-
-
-INT StartUsage(VOID)
-{
-    _tprintf(_T("DESCRIPTION:\n")
-                _T("        Starts a service running.\n")
-                _T("USAGE:\n")
-                _T("        sc <server> start [service name] <arg1> <arg2> ...\n"));
-
-    return 0;
-}
-
-
-INT PauseUsage(VOID)
-{
-    _tprintf(_T("DESCRIPTION:\n")
-                _T("        Sends a PAUSE control request to a service.\n")
-                _T("USAGE:\n")
-                _T("        sc <server> pause [service name]\n"));
-
-    return 0;
-}
-
-INT InterrogateUsage(VOID)
-{
-    _tprintf(_T("DESCRIPTION:\n")
-                _T("        Sends an INTERROGATE control request to a service.\n")
-                _T("USAGE:\n")
-                _T("        sc <server> interrogate [service name]\n"));
-
-    return 0;
-}
-
-
-INT StopUsage(VOID)
-{
-    _tprintf(_T("DESCRIPTION:\n")
-                _T("        Sends an STOP control request to a service.\n")
-                _T("USAGE:\n")
-                _T("        sc <server> stop [service name]\n"));
-
-    return 0;
-}
-
-INT ContinueUsage(VOID)
-{
-    _tprintf(_T("DESCRIPTION:\n")
-                _T("        Sends an CONTINUE control request to a service.\n")
-                _T("USAGE:\n")
-                _T("        sc <server> continue [service name]\n"));
-
-    return 0;
-}
-
-
-INT ConfigUsage(VOID)
-{
-    _tprintf(_T("not yet implemented\n"));
-
-    return 0;
-}
-
-
-INT DescriptionUsage(VOID)
-{
-    _tprintf(_T("DESCRIPTION:\n")
-                _T("        Sets the description string for a service.\n")
-                _T("USAGE:\n")
-                _T("        sc <server> description [service name]\n"));
-
-    return 0;
-}
-
-INT DeleteUsage(VOID)
-{
-    _tprintf(_T("DESCRIPTION:\n")
-                _T("        Deletes a service entry from the registry.\n")
-                _T("        If the service is running, or another process has an\n")
-                _T("        open handle to the service, the service is simply marked\n")
-                _T("        for deletion.\n")
-                _T("USAGE:\n")
-                _T("        sc <server> delete [service name]\n"));
-
-    return 0;
-}
-
-INT CreateUsage(VOID)
-{
-    _tprintf(_T("Creates a service entry in the registry and Service Database.\n")
-                _T("SYNTAX:\n")
-                _T("sc create [service name] [binPath= ] <option1> <option2>...\n")
-                _T("CREATE OPTIONS:\n")
-                _T("NOTE: The option name includes the equal sign.\n")
-                _T(" type= <own|share|interact|kernel|filesys|rec>\n")
-                _T("       (default = own)\n")
-                _T(" start= <boot|system|auto|demand|disabled>\n")
-                _T("       (default = demand)\n")
-                _T(" error= <normal|severe|critical|ignore>\n")
-                _T("       (default = normal)\n")
-                _T(" binPath= <BinaryPathName>\n")
-                _T(" group= <LoadOrderGroup>\n")
-                _T(" tag= <yes|no>\n")
-                _T(" depend= <Dependencies(separated by / (forward slash))>\n")
-                _T(" obj= <AccountName|ObjectName>\n")
-                _T("       (default = LocalSystem)\n")
-                _T(" DisplayName= <display name>\n")
-                _T(" password= <password>\n"));
-
-    return 0;
-}
diff --git a/reactos/subsys/system/servman/De.rc b/reactos/subsys/system/servman/De.rc
deleted file mode 100644 (file)
index a19ef86..0000000
+++ /dev/null
@@ -1,121 +0,0 @@
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN\r
-\r
-IDR_MAINMENU MENU\r
-BEGIN\r
-  POPUP "&Datei"\r
-  BEGIN\r
-    MENUITEM "B&eenden",ID_FILE_EXIT\r
-  END\r
-  POPUP "Action"\r
-  BEGIN\r
-    MENUITEM "Start",ID_START\r
-    MENUITEM "Stopp",ID_STOP\r
-    MENUITEM "Pause",ID_PAUSE\r
-    MENUITEM "Fortsetzen",ID_RESUME\r
-    MENUITEM "Neustart",ID_RESTART\r
-    MENUITEM SEPARATOR\r
-    MENUITEM "Aktualisieren",ID_REFRESH\r
-    MENUITEM SEPARATOR\r
-    MENUITEM "Eigenschaften",ID_PROP\r
-  END\r
-  POPUP "Ansicht"\r
-  BEGIN\r
-    MENUITEM "Anpassen",ID_VIEW_CUSTOMIZE\r
-  END\r
-  POPUP "Hilfe"\r
-  BEGIN\r
-    MENUITEM "Info",ID_HELP_ABOUT\r
-  END\r
-END\r
-\r
-IDD_ABOUTBOX DIALOG DISCARDABLE  22,16,190,182\r
-STYLE DS_MODALFRAME | WS_CAPTION | WS_SYSMENU\r
-CAPTION "Über den Service Manager"\r
-FONT 8, "Tahoma"\r
-BEGIN\r
-    CONTROL         "Service Manager v0.1\nCopyright (C) 2006\nby Ged Murphy (gedmurphy@gmail.com)",\r
-                    IDC_STATIC,"Static",SS_LEFTNOWORDWRAP | WS_GROUP,48,7,130,26\r
-    DEFPUSHBUTTON   "Schließen",IDOK,140,162,44,15,WS_GROUP\r
-    ICON            IDI_SM_ICON,IDC_STATIC,12,7,30,20\r
-    EDITTEXT        IDC_LICENSE_EDIT,8,44,174,107,ES_MULTILINE |\r
-                    ES_READONLY | WS_VSCROLL\r
-END\r
-\r
-\r
-IDD_DLG_GENERAL DIALOGEX 6,6,253,225\r
-CAPTION "Allgemein"\r
-FONT 8,"MS Sans Serif",0,0\r
-STYLE 0x10CF0000\r
-BEGIN\r
-  CONTROL "Dienstname:",IDC_STATIC,"Static",0x50000000,4,11,53,11\r
-  CONTROL "Anzeigename:",IDC_STATIC,"Static",0x50000000,4,29,53,11\r
-  CONTROL "Beschreibung",IDC_STATIC,"Static",0x50000000,4,51,53,11\r
-  CONTROL "",IDC_SERV_NAME,"Static",0x50000000,70,11,176,11\r
-  CONTROL "",IDC_DISP_NAME,"Static",0x50001000,70,29,176,12\r
-  CONTROL "",IDC_DESCRIPTION,"Static",0x50201000,70,46,176,22\r
-  CONTROL "Pfad zum ausführbarem Programm:",IDC_STATIC,"Static",0x50000000,6,73,150,9\r
-  CONTROL "",IDC_STATIC,"Static",0x50001000,6,86,238,12\r
-  CONTROL "Starttyp:",IDC_STATIC,"Static",0x50000000,6,108,53,11\r
-  CONTROL "",IDC_START_TYPE,"ComboBox",0x50010003,70,107,176,11\r
-  CONTROL "Status des Dienstes:",IDC_STATIC,"Static",0x50000000,4,138,100,11\r
-  CONTROL "",IDC_SERV_STATUS,"Static",0x50000000,70,138,176,11\r
-  CONTROL "Start",IDC_START,"Button",0x50010000,6,155,54,15\r
-  CONTROL "Stopp",IDC_STOP,"Button",0x50010000,68,155,54,15\r
-  CONTROL "Pause",IDC_PAUSE,"Button",0x50010000,130,155,54,15\r
-  CONTROL "Fortsetzen",IDC_RESUME,"Button",0x50010000,192,155,54,15\r
-  CONTROL "Sie können die Startparameter festlegen, die verwendet werden, wenn Sie den Dienst von hier aus starten.",IDC_STATIC,"Static",0x50000000,6,177,240,15\r
-  CONTROL "Startparameter",IDC_STATIC,"Static",0x50000000,6,199,53,11\r
-  CONTROL "",IDC_START_PARAM,"Static",0x50001000,70,199,176,11\r
-END\r
-\r
-IDB_BUTTONS BITMAP "buttons.bmp"\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-  IDS_FIRSTCOLUMN "Name"\r
-  IDS_SECONDCOLUMN "Beschreibung"\r
-  IDS_THIRDCOLUMN "Status"\r
-  IDS_FOURTHCOLUMN "Starttyp"\r
-  IDS_FITHCOLUMN "Anmelden als"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-  IDS_SERVICES_STATUS_RUNNING "Gestartet"\r
-  IDS_SERVICES_STATUS_STOPPED "Gestoppt"\r
-  IDS_SERVICES_YES "Ja"\r
-  IDS_SERVICES_UNKNOWN "Unbekannt"\r
-  IDS_SERVICES_AUTO "Automatisch"\r
-  IDS_SERVICES_MAN "Manuel"\r
-  IDS_SERVICES_DIS "Deaktiviert"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-  IDS_SERVICES_NUM_SERVICES "Dienste: %d"\r
-  IDS_LICENSE "This program is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.\r\n\r\nThis program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more details.\r\n\r\nYou should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA."\r
-  /*"This program is free software; you can redistribute it "\r
-              "and/or modify it under the terms of the GNU Lesser General "\r
-              "Public License as published by the Free Software Foundation; "\r
-              "either version 2.1 of the License, or (at your option) any "\r
-              "later version.\r\n\r\nThis program is distributed in the hope "\r
-              "that it will be useful, but WITHOUT ANY WARRANTY; without even "\r
-              "the implied warranty of MERCHANTABILITY or FITNESS FOR A "\r
-              "PARTICULAR PURPOSE.  See the GNU General Public License for more "\r
-              "details.\r\n\r\nYou should have received a copy of the GNU "\r
-              "General Public License along with this program; if not, write "\r
-              "to the Free Software Foundation, Inc., 59 Temple Place - Suite "\r
-              "330, Boston, MA  02111-1307, USA." */\r
-  \r
-END\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-    IDS_TOOLTIP_PROP    "Eigenschaften"\r
-    IDS_TOOLTIP_REFRESH "Aktualisieren"\r
-    IDS_TOOLTIP_EXPORT  "Liste exportieren"\r
-    IDS_TOOLTIP_START   "Dienst starten"\r
-    IDS_TOOLTIP_STOP    "Dienst beenden"\r
-    IDS_TOOLTIP_PAUSE   "Diest pausieren"\r
-    IDS_TOOLTIP_RESTART "Diest neustarten"\r
-END\r
diff --git a/reactos/subsys/system/servman/En.rc b/reactos/subsys/system/servman/En.rc
deleted file mode 100644 (file)
index 32de931..0000000
+++ /dev/null
@@ -1,182 +0,0 @@
-IDR_MAINMENU MENU\r
-BEGIN\r
-  POPUP "&File"\r
-  BEGIN\r
-    MENUITEM "E&xit",ID_EXIT\r
-  END\r
-  POPUP "Action"\r
-  BEGIN\r
-    MENUITEM "Start",ID_START\r
-    MENUITEM "Stop",ID_STOP\r
-    MENUITEM "Pause",ID_PAUSE\r
-    MENUITEM "Resume",ID_RESUME\r
-    MENUITEM "Restart",ID_RESTART\r
-    MENUITEM SEPARATOR\r
-    MENUITEM "Refresh",ID_REFRESH\r
-    MENUITEM SEPARATOR\r
-    MENUITEM "Properties",ID_PROP\r
-  END\r
-  POPUP "View"\r
-  BEGIN\r
-    MENUITEM "Customize",ID_VIEW_CUSTOMIZE\r
-  END\r
-  POPUP "Help"\r
-  BEGIN\r
-    MENUITEM "About",ID_ABOUT\r
-  END\r
-END\r
-IDR_POPUP MENU\r
-BEGIN\r
-  POPUP "popup"\r
-  BEGIN\r
-    MENUITEM "Start",ID_START\r
-    MENUITEM "Stop",ID_STOP\r
-    MENUITEM "Pause",ID_PAUSE\r
-    MENUITEM "Resume",ID_RESUME\r
-    MENUITEM "Restart",ID_RESTART\r
-    MENUITEM SEPARATOR\r
-    POPUP "All tasks"\r
-    BEGIN\r
-      MENUITEM "Start",ID_START\r
-      MENUITEM "Stop",ID_STOP\r
-      MENUITEM "Pause",ID_PAUSE\r
-      MENUITEM "Resume",ID_RESUME\r
-      MENUITEM "Restart",ID_RESTART\r
-      MENUITEM "Refresh",ID_REFRESH\r
-    END\r
-    MENUITEM SEPARATOR\r
-    MENUITEM "Refresh",ID_REFRESH\r
-    MENUITEM SEPARATOR\r
-    MENUITEM "Properties",ID_PROP\r
-    MENUITEM SEPARATOR\r
-    MENUITEM "Help",ID_HELP\r
-  END\r
-END\r
-\r
-IDD_ABOUTBOX DIALOGEX 22,16,190,182\r
-CAPTION "About Service Manager"\r
-FONT 8,"Tahoma",0,0\r
-STYLE WS_BORDER | WS_DLGFRAME | WS_SYSMENU | DS_MODALFRAME\r
-BEGIN\r
-  LTEXT "Service Manager v0.1\nCopyright (C) 2006\nby Ged Murphy (gedmurphy@gmail.com)", IDC_STATIC, 48, 7, 130, 26\r
-  PUSHBUTTON "Close", IDOK, 75, 162, 44, 15\r
-  ICON IDI_SM_ICON, IDC_STATIC, 10, 10, 7, 30\r
-  EDITTEXT IDC_LICENSE_EDIT, 8, 44, 174, 107, WS_VISIBLE | WS_VSCROLL | WS_TABSTOP | ES_READONLY | ES_MULTILINE\r
-END\r
-\r
-IDD_DLG_GENERAL DIALOGEX 6,6,253,225\r
-CAPTION "General"\r
-FONT 8,"Tahoma",0,0\r
-STYLE WS_BORDER | WS_VISIBLE | WS_DLGFRAME | WS_SYSMENU | WS_THICKFRAME | WS_GROUP | WS_TABSTOP\r
-BEGIN\r
-  LTEXT "", IDC_SERV_NAME, 70,11,176,11, WS_CHILD | WS_VISIBLE\r
-  EDITTEXT IDC_DISP_NAME, 70, 29, 176, 13, WS_CHILD | WS_VISIBLE | WS_TABSTOP | ES_READONLY\r
-  EDITTEXT IDC_DESCRIPTION, 70, 46, 176, 24, WS_CHILD | WS_VISIBLE | WS_VSCROLL | WS_TABSTOP | ES_MULTILINE | ES_READONLY\r
-  EDITTEXT IDC_EXEPATH, 6, 86, 240, 13, WS_CHILD | WS_VISIBLE | WS_TABSTOP | ES_READONLY\r
-  CONTROL "",IDC_START_TYPE,"ComboBox",0x50010003,70,107,176,11\r
-  PUSHBUTTON "Start", IDC_START, 6, 155, 54, 15\r
-  PUSHBUTTON "Stop", IDC_STOP, 68, 155, 54, 15\r
-  PUSHBUTTON "Pause", IDC_PAUSE , 130, 155, 54, 15\r
-  PUSHBUTTON "Resume", IDC_RESUME, 192, 155, 54, 15\r
-  LTEXT "Service name:", IDC_STATIC, 4, 11, 53, 11\r
-  LTEXT "Display name:", IDC_STATIC, 4, 29, 53, 11\r
-  LTEXT "Description", IDC_STATIC, 4, 51, 53, 11\r
-  LTEXT "Path to executable:", IDC_STATIC, 6, 73, 82, 9\r
-  LTEXT "Startup type:", IDC_STATIC, 6, 108, 53, 11\r
-  LTEXT "Service status:", IDC_STATIC, 4, 138, 53, 11\r
-  CONTROL "",IDC_SERV_STATUS,"Static",0x50000000,70,138,176,11\r
-  LTEXT "You can specify the start parameters that apply when you start the service from here.",IDC_STATIC, 6,177,240,15\r
-  LTEXT "Start parameters", IDC_STATIC, 6, 199, 53, 11\r
-  EDITTEXT IDC_START_PARAM, 68, 199, 178, 13, WS_CHILD | WS_VISIBLE | WS_TABSTOP\r
-END\r
-\r
-IDD_DLG_DEPEND DIALOGEX 6,6,253,225\r
-CAPTION "Dependencies"\r
-FONT 8,"Tahoma",0,0\r
-STYLE WS_BORDER | WS_VISIBLE | WS_DLGFRAME | WS_SYSMENU | WS_THICKFRAME | WS_GROUP | WS_TABSTOP\r
-BEGIN\r
-  CONTROL "",IDC_DEPEND_TREE1,"SysTreeView32",0x50010007,8,70,236,68,0x00000200\r
-  CONTROL "",IDC_DEPEND_TREE2,"SysTreeView32",0x50010007,8,151,234,67,0x00000200\r
-  CONTROL "Some services depend on other services, system drivers and load order groups. If a system component is stopped or it is not running properly, dependant services can be affected.",IDC_STATIC,"Static",0x50000000,8,7,238,26\r
-  CONTROL "This service depends on the following components",IDC_STATIC,"Static",0x50000000,8,57,236,9\r
-  CONTROL "",IDC_DEPEND_SERVICE,"Static",0x50000000,8,38,236,13\r
-END\r
-\r
-IDD_DLG_CREATE DIALOGEX 6,6,225,209\r
-CAPTION "Create a service"\r
-FONT 8,"Tahoma",0,0\r
-STYLE WS_BORDER | WS_VISIBLE | WS_DLGFRAME | WS_SYSMENU | WS_THICKFRAME | WS_GROUP | WS_TABSTOP\r
-BEGIN\r
-  CONTROL "",IDC_CREATE_SERVNAME,"Edit",0x50010000,72,12,150,11,0x00000200\r
-  CONTROL "",IDC_CREATE_DISPNAME,"Edit",0x50010000,72,31,150,11,0x00000200\r
-  CONTROL "",IDC_CREATE_PATH,"Edit",0x50010000,8,62,214,13,0x00000200\r
-  CONTROL "",IDC_CREATE_DESC,"Edit",0x50010000,10,97,210,48,0x00000200\r
-  CONTROL "",IDC_CREATE_OPTIONS,"Edit",0x50010000,10,162,210,13,0x00000200\r
-  CONTROL "Service Name :",IDC_STATIC,"Static",0x50000202,12,12,54,9\r
-  CONTROL "Display Name :",IDC_STATIC,"Static",0x50000202,12,33,54,9\r
-  CONTROL "Path to executable :",IDC_STATIC,"Static",0x50000000,10,51,68,9\r
-  CONTROL "Description :",IDC_STATIC,"Static",0x50000000,12,86,44,9\r
-  CONTROL "OK",IDOK,"Button",0x50010000,126,192,44,13\r
-  CONTROL "Cancel",IDCANCEL,"Button",0x50010000,176,192,46,13\r
-  CONTROL "Additional options (click help for details)",IDC_STATIC,"Static",0x50000000,10,151,134,9\r
-  CONTROL "Help",ID_CREATE_HELP,"Button",0x50010000,6,192,44,13\r
-END\r
-\r
-IDD_DLG_PROGRESS DIALOGEX 6,6,255,89\r
-CAPTION "Service Control"\r
-FONT 8,"MS Sans Serif",0,0\r
-STYLE WS_BORDER | WS_DLGFRAME | WS_SYSMENU | DS_MODALFRAME\r
-EXSTYLE WS_EX_TOOLWINDOW\r
-BEGIN\r
-  CONTROL "",IDC_SERVCON_PROGRESS,"msctls_progress32",0x50000000,8,46,238,13\r
-  CONTROL "",IDC_SERVCON_INFO,"Static",0x50000000,8,5,236,11\r
-  CONTROL "",IDC_SERVCON_NAME,"Static",0x50000000,8,25,66,11\r
-  CONTROL "&Close",IDOK,"Button",0x50010000,100,70,54,13\r
-END\r
-\r
-\r
-IDB_BUTTONS BITMAP DISCARDABLE "res/toolbar.bmp"\r
-\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-  IDS_FIRSTCOLUMN "Name"\r
-  IDS_SECONDCOLUMN "Description"\r
-  IDS_THIRDCOLUMN "Status"\r
-  IDS_FOURTHCOLUMN "Startup Type"\r
-  IDS_FITHCOLUMN "Log On As"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-  IDS_SERVICES_STARTED "Started"\r
-  IDS_SERVICES_STOPPED "Stopped"\r
-  IDS_SERVICES_AUTO "Automatic"\r
-  IDS_SERVICES_MAN "Manual"\r
-  IDS_SERVICES_DIS "Disabled"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-  IDS_NUM_SERVICES "Num Services: %d"\r
-  IDS_LICENSE "This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.\r\n\r\nThis program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more details.\r\n\r\nYou should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-  IDS_TOOLTIP_PROP "Properties"\r
-  IDS_TOOLTIP_REFRESH "Refresh"\r
-  IDS_TOOLTIP_EXPORT "Export list"\r
-  IDS_TOOLTIP_START "Start service"\r
-  IDS_TOOLTIP_STOP "Stop service"\r
-  IDS_TOOLTIP_PAUSE "Pause service"\r
-  IDS_TOOLTIP_RESTART "Restart service"\r
-  IDS_TOOLTIP_NEW "Create a new service"\r
-  IDS_TOOLTIP_HELP "Help"\r
-  IDS_TOOLTIP_EXIT "Exit"\r
-END\r
-\r
-STRINGTABLE DISCARDABLE\r
-BEGIN\r
-  IDS_PROGRESS_INFO "ReactOS is attempting to %s the following service"\r
-END\r
diff --git a/reactos/subsys/system/servman/about.c b/reactos/subsys/system/servman/about.c
deleted file mode 100644 (file)
index 64da2c9..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-/*\r
- * PROJECT:     ReactOS Services\r
- * LICENSE:     GPL - See COPYING in the top level directory\r
- * FILE:        subsys/system/servman/about.c\r
- * PURPOSE:     About dialog box message handler\r
- * COPYRIGHT:   Copyright 2005 Ged Murphy <gedmurphy@gmail.com>\r
- *\r
- */\r
-\r
-//ShellAbout(hwnd, _T("test"), _T("test2"), MAKEINTRESOURCE(IDI_SM_ICON));\r
-\r
-#include "servman.h"\r
-\r
-extern HINSTANCE hInstance;\r
-\r
-#ifdef _MSC_VER\r
-#pragma warning(disable : 4100)\r
-#endif\r
-BOOL CALLBACK\r
-AboutDialogProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)\r
-{\r
-    HWND  hLicenseEditWnd;\r
-    HICON hIcon = NULL;\r
-    TCHAR strLicense[0x1000];\r
-\r
-    switch (message)\r
-    {\r
-    case WM_INITDIALOG:\r
-\r
-        hIcon = LoadImage(hInstance, MAKEINTRESOURCE(IDI_SM_ICON), IMAGE_ICON, 16, 16, 0);\r
-        SendMessage(hDlg, WM_SETICON, ICON_SMALL, (LPARAM)hIcon);\r
-\r
-        hLicenseEditWnd = GetDlgItem(hDlg, IDC_LICENSE_EDIT);\r
-\r
-        LoadString(hInstance, IDS_LICENSE, strLicense, 0x1000);\r
-\r
-        SetWindowText(hLicenseEditWnd, strLicense);\r
-\r
-        return TRUE;\r
-\r
-    case WM_COMMAND:\r
-\r
-        if ((LOWORD(wParam) == IDOK) || (LOWORD(wParam) == IDCANCEL))\r
-        {\r
-            DestroyIcon(hIcon);\r
-            EndDialog(hDlg, LOWORD(wParam));\r
-            return TRUE;\r
-        }\r
-\r
-        break;\r
-    }\r
-\r
-    return FALSE;\r
-}\r
diff --git a/reactos/subsys/system/servman/control.c b/reactos/subsys/system/servman/control.c
deleted file mode 100644 (file)
index b1a1785..0000000
+++ /dev/null
@@ -1,138 +0,0 @@
-/*\r
- * PROJECT:     ReactOS Services\r
- * LICENSE:     GPL - See COPYING in the top level directory\r
- * FILE:        subsys/system/servman/control\r
- * PURPOSE:     Stops, pauses and resumes a service\r
- * COPYRIGHT:   Copyright 2005 - 2006 Ged Murphy <gedmurphy@gmail.com>\r
- *\r
- */\r
-\r
-#include "servman.h"\r
-\r
-extern HWND hListView;\r
-\r
-\r
-BOOL Control(HWND hProgDlg, DWORD Control)\r
-{\r
-    HWND hProgBar;\r
-    SC_HANDLE hSCManager;\r
-    SC_HANDLE hSc;\r
-    ENUM_SERVICE_STATUS_PROCESS *Service = NULL;\r
-    SERVICE_STATUS_PROCESS ServiceStatus;\r
-    SERVICE_STATUS Status;\r
-    LVITEM item;\r
-    DWORD BytesNeeded = 0;\r
-    DWORD dwStartTickCount, dwOldCheckPoint;\r
-\r
-    item.mask = LVIF_PARAM;\r
-    item.iItem = GetSelectedItem();\r
-    SendMessage(hListView, LVM_GETITEM, 0, (LPARAM)&item);\r
-\r
-    /* copy pointer to selected service */\r
-    Service = (ENUM_SERVICE_STATUS_PROCESS *)item.lParam;\r
-\r
-    /* set the progress bar range and step */\r
-    hProgBar = GetDlgItem(hProgDlg, IDC_SERVCON_PROGRESS);\r
-    SendMessage(hProgBar, PBM_SETRANGE, 0, MAKELPARAM(0, PROGRESSRANGE));\r
-    SendMessage(hProgBar, PBM_SETSTEP, (WPARAM)1, 0);\r
-\r
-    /* open handle to the SCM */\r
-    hSCManager = OpenSCManager(NULL, NULL, SC_MANAGER_ALL_ACCESS);\r
-    if (hSCManager == NULL)\r
-    {\r
-        GetError(0);\r
-        return FALSE;\r
-    }\r
-\r
-    /* open handle to the service */\r
-    hSc = OpenService(hSCManager, Service->lpServiceName,\r
-                      SC_MANAGER_ALL_ACCESS);\r
-    if (hSc == NULL)\r
-    {\r
-        GetError(0);\r
-        return FALSE;\r
-    }\r
-\r
-    /* process requested action */\r
-    if (! ControlService(hSc, Control, &Status))\r
-    {\r
-        GetError(0);\r
-        CloseServiceHandle(hSc);\r
-        return FALSE;\r
-    }\r
-\r
-    /* query the state of the service */\r
-    if (! QueryServiceStatusEx(hSc,\r
-                               SC_STATUS_PROCESS_INFO,\r
-                               (LPBYTE)&ServiceStatus,\r
-                               sizeof(SERVICE_STATUS_PROCESS),\r
-                               &BytesNeeded))\r
-    {\r
-        GetError(0);\r
-        return FALSE;\r
-    }\r
-\r
-    /* Save the tick count and initial checkpoint. */\r
-    dwStartTickCount = GetTickCount();\r
-    dwOldCheckPoint = ServiceStatus.dwCheckPoint;\r
-\r
-    /* loop whilst service is not running */\r
-    /* FIXME: needs more control adding. 'Loop' is temparary */\r
-    while (ServiceStatus.dwCurrentState != Control)\r
-    {\r
-        DWORD dwWaitTime;\r
-\r
-        dwWaitTime = ServiceStatus.dwWaitHint / 10;\r
-\r
-        if( dwWaitTime < 500 )\r
-            dwWaitTime = 500;\r
-        else if ( dwWaitTime > 5000 )\r
-            dwWaitTime = 5000;\r
-\r
-        /* increment the progress bar */\r
-        SendMessage(hProgBar, PBM_STEPIT, 0, 0);\r
-\r
-        /* wait before checking status */\r
-        Sleep(dwWaitTime);\r
-\r
-        /* check status again */\r
-        if (! QueryServiceStatusEx(\r
-                hSc,\r
-                SC_STATUS_PROCESS_INFO,\r
-                (LPBYTE)&ServiceStatus,\r
-                sizeof(SERVICE_STATUS_PROCESS),\r
-                &BytesNeeded))\r
-        {\r
-            GetError(0);\r
-            return FALSE;\r
-        }\r
-        \r
-        if (ServiceStatus.dwCheckPoint > dwOldCheckPoint)\r
-        {\r
-            /* The service is making progress. increment the progress bar */\r
-            SendMessage(hProgBar, PBM_STEPIT, 0, 0);\r
-            dwStartTickCount = GetTickCount();\r
-            dwOldCheckPoint = ServiceStatus.dwCheckPoint;\r
-        }\r
-        else\r
-        {\r
-            if(GetTickCount() - dwStartTickCount > ServiceStatus.dwWaitHint)\r
-            {\r
-                /* No progress made within the wait hint */\r
-                break;\r
-            }\r
-        }\r
-    }\r
-\r
-    CloseServiceHandle(hSc);\r
-\r
-    if (ServiceStatus.dwCurrentState == Control)\r
-    {\r
-        SendMessage(hProgBar, PBM_DELTAPOS, PROGRESSRANGE, 0);\r
-        Sleep(1000);\r
-        return TRUE;\r
-    }\r
-    else\r
-        return FALSE;\r
-\r
-}\r
diff --git a/reactos/subsys/system/servman/geterror.c b/reactos/subsys/system/servman/geterror.c
deleted file mode 100644 (file)
index 29c28f4..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
-//#include <stdarg>\r
-#include "servman.h"\r
-/* temp file for debugging */\r
-\r
-VOID GetError(DWORD err)\r
-{\r
-    LPVOID lpMsgBuf;\r
-\r
-    if (err == 0)\r
-        err = GetLastError();\r
-\r
-    FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER |\r
-                  FORMAT_MESSAGE_FROM_SYSTEM |\r
-                  FORMAT_MESSAGE_IGNORE_INSERTS,\r
-                  NULL,\r
-                  err,\r
-                  MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), /* Default language */\r
-                  (LPTSTR) &lpMsgBuf,\r
-                   0,\r
-                   NULL );\r
-\r
-        MessageBox(NULL, lpMsgBuf, _T("Error!"), MB_OK | MB_ICONERROR);\r
-\r
-        LocalFree(lpMsgBuf);\r
-}\r
-\r
-\r
-VOID DisplayString(PTCHAR Msg)\r
-{\r
-\r
-    MessageBox(NULL, Msg, _T("Error!"), MB_OK | MB_ICONERROR);\r
-\r
-}\r
diff --git a/reactos/subsys/system/servman/progress.c b/reactos/subsys/system/servman/progress.c
deleted file mode 100644 (file)
index afe1575..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-/*\r
- * PROJECT:     ReactOS Services\r
- * LICENSE:     GPL - See COPYING in the top level directory\r
- * FILE:        subsys/system/servman/progress.c\r
- * PURPOSE:     Progress dialog box message handler\r
- * COPYRIGHT:   Copyright 2006 Ged Murphy <gedmurphy@gmail.com>\r
- *\r
- */\r
-\r
-#include "servman.h"\r
-\r
-extern HINSTANCE hInstance;\r
-//extern HWND hMainWnd;\r
-\r
-\r
-BOOL CALLBACK ProgressDialogProc(HWND hDlg, UINT Message, WPARAM wParam, LPARAM lParam)\r
-{\r
-    switch(Message)\r
-    {\r
-        case WM_INITDIALOG:\r
-\r
-        break;\r
-\r
-        case WM_COMMAND:\r
-            switch(LOWORD(wParam))\r
-            {\r
-                case IDOK:\r
-                    DestroyWindow(hDlg);\r
-                break;\r
-\r
-            }\r
-        break;\r
-\r
-        case WM_DESTROY:\r
-            DestroyWindow(hDlg);\r
-        break;\r
-\r
-        default:\r
-            return FALSE;\r
-    }\r
-\r
-    return TRUE;\r
-\r
-}\r
-\r
diff --git a/reactos/subsys/system/servman/propsheet.c b/reactos/subsys/system/servman/propsheet.c
deleted file mode 100644 (file)
index 50e514b..0000000
+++ /dev/null
@@ -1,295 +0,0 @@
-/*\r
- * PROJECT:     ReactOS Services\r
- * LICENSE:     GPL - See COPYING in the top level directory\r
- * FILE:        subsys/system/servman/propsheet.c\r
- * PURPOSE:     Property dialog box message handler\r
- * COPYRIGHT:   Copyright 2005 - 2006 Ged Murphy <gedmurphy@gmail.com>\r
- *\r
- */\r
-\r
-#include "servman.h"\r
-\r
-extern ENUM_SERVICE_STATUS_PROCESS *pServiceStatus;\r
-extern HINSTANCE hInstance;\r
-extern HWND hListView;\r
-extern HWND hMainWnd;\r
-\r
-\r
-typedef struct _PROP_DLG_INFO\r
-{\r
-    LPTSTR lpServiceName;\r
-    LPTSTR lpDisplayName;\r
-    LPTSTR lpDescription;\r
-    LPTSTR lpPathToExe;\r
-    TCHAR  szStartupType;\r
-    TCHAR  szServiceStatus[25];\r
-    LPTSTR lpStartParams;\r
-} PROP_DLG_INFO, *PPROP_DLG_INFO;\r
-\r
-\r
-/*\r
- * Fills the 'startup type' combo box with possible\r
- * values and sets it to value of the selected item\r
- */\r
-VOID SetStartupType(HKEY hKey, HWND hwndDlg)\r
-{\r
-    HWND hList;\r
-    TCHAR buf[25];\r
-    DWORD dwValueSize = 0;\r
-    DWORD StartUp = 0;\r
-\r
-    hList = GetDlgItem(hwndDlg, IDC_START_TYPE);\r
-\r
-    LoadString(hInstance, IDS_SERVICES_AUTO, buf, sizeof(buf) / sizeof(TCHAR));\r
-    SendMessage(hList, CB_ADDSTRING, 0, (LPARAM)buf);\r
-    LoadString(hInstance, IDS_SERVICES_MAN, buf, sizeof(buf) / sizeof(TCHAR));\r
-    SendMessage(hList, CB_ADDSTRING, 0, (LPARAM)buf);\r
-    LoadString(hInstance, IDS_SERVICES_DIS, buf, sizeof(buf) / sizeof(TCHAR));\r
-    SendMessage(hList, CB_ADDSTRING, 0, (LPARAM)buf);\r
-\r
-    dwValueSize = sizeof(DWORD);\r
-    if (RegQueryValueEx(hKey,\r
-                        _T("Start"),\r
-                        NULL,\r
-                        NULL,\r
-                        (LPBYTE)&StartUp,\r
-                        &dwValueSize))\r
-    {\r
-        RegCloseKey(hKey);\r
-        return;\r
-    }\r
-\r
-    if (StartUp == 0x02)\r
-        SendMessage(hList, CB_SETCURSEL, 0, 0);\r
-    else if (StartUp == 0x03)\r
-        SendMessage(hList, CB_SETCURSEL, 1, 0);\r
-    else if (StartUp == 0x04)\r
-        SendMessage(hList, CB_SETCURSEL, 2, 0);\r
-\r
-}\r
-\r
-\r
-/*\r
- * Populates the General Properties dialog with\r
- * the relevant service information\r
- */\r
-VOID GetDlgInfo(HWND hwndDlg)\r
-{\r
-    HKEY hKey;\r
-    ENUM_SERVICE_STATUS_PROCESS *Service = NULL;\r
-    PROP_DLG_INFO DlgInfo;\r
-    LPCTSTR Path = _T("System\\CurrentControlSet\\Services\\%s");\r
-    TCHAR buf[300];\r
-\r
-    /* get pointer to selected service */\r
-    Service = GetSelectedService();\r
-\r
-    /* open the registry key for the service */\r
-    _sntprintf(buf, sizeof(buf) / sizeof(TCHAR), Path, Service->lpServiceName);\r
-    RegOpenKeyEx(HKEY_LOCAL_MACHINE,\r
-                 buf,\r
-                 0,\r
-                 KEY_READ,\r
-                 &hKey);\r
-\r
-    /* set the service name */\r
-    DlgInfo.lpServiceName = Service->lpServiceName;\r
-    SendDlgItemMessage(hwndDlg, IDC_SERV_NAME, WM_SETTEXT, 0, (\r
-        LPARAM)DlgInfo.lpServiceName);\r
-\r
-\r
-    /* set the display name */\r
-    DlgInfo.lpDisplayName = Service->lpDisplayName;\r
-    SendDlgItemMessage(hwndDlg, IDC_DISP_NAME, WM_SETTEXT, 0,\r
-        (LPARAM)DlgInfo.lpDisplayName);\r
-\r
-\r
-    /* set the description */\r
-    if (GetDescription(hKey, &DlgInfo.lpDescription))\r
-        SendDlgItemMessage(hwndDlg, IDC_DESCRIPTION, WM_SETTEXT, 0,\r
-            (LPARAM)DlgInfo.lpDescription);\r
-\r
-\r
-    /* set the executable path */\r
-    if (GetExecutablePath(&DlgInfo.lpPathToExe))\r
-        SendDlgItemMessage(hwndDlg, IDC_EXEPATH, WM_SETTEXT, 0, (LPARAM)DlgInfo.lpPathToExe);\r
-\r
-\r
-    /* set startup type */\r
-    SetStartupType(hKey, hwndDlg);\r
-\r
-\r
-\r
-    /* set service status */\r
-    if (Service->ServiceStatusProcess.dwCurrentState == SERVICE_RUNNING)\r
-    {\r
-        LoadString(hInstance, IDS_SERVICES_STARTED, DlgInfo.szServiceStatus,\r
-            sizeof(DlgInfo.szServiceStatus) / sizeof(TCHAR));\r
-        SendDlgItemMessageW(hwndDlg, IDC_SERV_STATUS, WM_SETTEXT, 0, (LPARAM)DlgInfo.szServiceStatus);\r
-    }\r
-    else\r
-    {\r
-        LoadString(hInstance, IDS_SERVICES_STOPPED, DlgInfo.szServiceStatus,\r
-            sizeof(DlgInfo.szServiceStatus) / sizeof(TCHAR));\r
-        SendDlgItemMessageW(hwndDlg, IDC_SERV_STATUS, WM_SETTEXT, 0, (LPARAM)DlgInfo.szServiceStatus);\r
-    }\r
-\r
-\r
-\r
-\r
-}\r
-\r
-\r
-#ifdef _MSC_VER\r
-#pragma warning(disable : 4100)\r
-#endif\r
-\r
-/*\r
- * General Property dialog callback.\r
- * Controls messages to the General dialog\r
- */\r
-/* FIXME: this may be better as a modeless dialog */\r
-INT_PTR CALLBACK\r
-GeneralPageProc(HWND hwndDlg,\r
-                UINT uMsg,\r
-                       WPARAM wParam,\r
-                       LPARAM lParam)\r
-{\r
-\r
-    switch (uMsg)\r
-    {\r
-        case WM_INITDIALOG:\r
-            GetDlgInfo(hwndDlg);\r
-            break;\r
-\r
-        case WM_COMMAND:\r
-            switch(LOWORD(wParam))\r
-            {\r
-                case IDC_START:\r
-                    SendMessage(hMainWnd, WM_COMMAND, ID_START, 0);\r
-                    break;\r
-\r
-                case IDC_STOP:\r
-                    SendMessage(hMainWnd, WM_COMMAND, ID_STOP, 0);\r
-                    break;\r
-\r
-                case IDC_PAUSE:\r
-                    SendMessage(hMainWnd, WM_COMMAND, ID_PAUSE, 0);\r
-                    break;\r
-\r
-                case IDC_RESUME:\r
-                    SendMessage(hMainWnd, WM_COMMAND, ID_RESUME, 0);\r
-                    break;\r
-            }\r
-            break;\r
-\r
-        case WM_DESTROY:\r
-            break;\r
-\r
-        case WM_NOTIFY:\r
-            {\r
-                LPNMHDR lpnm = (LPNMHDR)lParam;\r
-\r
-                switch (lpnm->code)\r
-\r
-                default:\r
-                    break;\r
-            }\r
-            break;\r
-    }\r
-\r
-    return FALSE;\r
-}\r
-\r
-\r
-\r
-/*\r
- * Dependancies Property dialog callback.\r
- * Controls messages to the Dependancies dialog\r
- */\r
-/* FIXME: this may be better as a modeless dialog */\r
-INT_PTR CALLBACK\r
-DependanciesPageProc(HWND hwndDlg,\r
-                UINT uMsg,\r
-                       WPARAM wParam,\r
-                       LPARAM lParam)\r
-{\r
-\r
-    switch (uMsg)\r
-    {\r
-        case WM_INITDIALOG:\r
-\r
-            break;\r
-\r
-        case WM_COMMAND:\r
-            switch(LOWORD(wParam))\r
-            {\r
-                case IDC_START:\r
-                    break;\r
-\r
-                case IDC_STOP:\r
-\r
-                    break;\r
-            }\r
-            break;\r
-\r
-        case WM_DESTROY:\r
-            break;\r
-\r
-        case WM_NOTIFY:\r
-            {\r
-                LPNMHDR lpnm = (LPNMHDR)lParam;\r
-\r
-                switch (lpnm->code)\r
-\r
-                default:\r
-                    break;\r
-            }\r
-            break;\r
-    }\r
-\r
-    return FALSE;\r
-}\r
-\r
-\r
-static VOID\r
-InitPropSheetPage(PROPSHEETPAGE *psp, WORD idDlg, DLGPROC DlgProc)\r
-{\r
-  ZeroMemory(psp, sizeof(PROPSHEETPAGE));\r
-  psp->dwSize = sizeof(PROPSHEETPAGE);\r
-  psp->dwFlags = PSP_DEFAULT;\r
-  psp->hInstance = hInstance;\r
-  psp->pszTemplate = MAKEINTRESOURCE(idDlg);\r
-  psp->pfnDlgProc = DlgProc;\r
-}\r
-\r
-\r
-LONG APIENTRY\r
-OpenPropSheet(HWND hwnd)\r
-{\r
-  PROPSHEETHEADER psh;\r
-  PROPSHEETPAGE psp[2];\r
-  TCHAR Caption[256];\r
-\r
-  LoadString(hInstance, IDS_PROP_SHEET, Caption, sizeof(Caption) / sizeof(TCHAR));\r
-\r
-  ZeroMemory(&psh, sizeof(PROPSHEETHEADER));\r
-  psh.dwSize = sizeof(PROPSHEETHEADER);\r
-  psh.dwFlags =  PSH_PROPSHEETPAGE | PSH_PROPTITLE;\r
-  psh.hwndParent = NULL;\r
-  psh.hInstance = hInstance;\r
-  psh.hIcon = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_SM_ICON));\r
-  psh.pszCaption = Caption;\r
-  psh.nPages = sizeof(psp) / sizeof(PROPSHEETPAGE);\r
-  psh.nStartPage = 0;\r
-  psh.ppsp = psp;\r
-\r
-  InitPropSheetPage(&psp[0], IDD_DLG_GENERAL, GeneralPageProc);\r
-  //InitPropSheetPage(&psp[1], IDD_DLG_GENERAL, LogonPageProc);\r
-  //InitPropSheetPage(&psp[2], IDD_DLG_GENERAL, RecoveryPageProc);\r
-  InitPropSheetPage(&psp[1], IDD_DLG_DEPEND, DependanciesPageProc);\r
-\r
-\r
-  return (LONG)(PropertySheet(&psh) != -1);\r
-}\r
-\r
diff --git a/reactos/subsys/system/servman/query.c b/reactos/subsys/system/servman/query.c
deleted file mode 100644 (file)
index 4922e20..0000000
+++ /dev/null
@@ -1,619 +0,0 @@
-/*\r
- * PROJECT:     ReactOS Services\r
- * LICENSE:     GPL - See COPYING in the top level directory\r
- * FILE:        subsys/system/servman/query.c\r
- * PURPOSE:     Query service information\r
- * COPYRIGHT:   Copyright 2005 - 2006 Ged Murphy <gedmurphy@gmail.com>\r
- *\r
- */\r
-\r
-#include "servman.h"\r
-\r
-extern HINSTANCE hInstance;\r
-extern HWND hListView;\r
-extern HWND hStatus;\r
-\r
-/* Stores the complete services array */\r
-ENUM_SERVICE_STATUS_PROCESS *pServiceStatus = NULL;\r
-\r
-\r
-/* Free service array */\r
-VOID FreeMemory(VOID)\r
-{\r
-    HeapFree(GetProcessHeap(), 0, pServiceStatus);\r
-}\r
-\r
-\r
-\r
-ENUM_SERVICE_STATUS_PROCESS* \r
-GetSelectedService(VOID)\r
-{\r
-    ENUM_SERVICE_STATUS_PROCESS *pSelectedService = NULL;\r
-    LVITEM item;\r
-\r
-    item.mask = LVIF_PARAM;\r
-    item.iItem = GetSelectedItem();\r
-    SendMessage(hListView, LVM_GETITEM, 0, (LPARAM)&item);\r
-\r
-    /* copy pointer to selected service */\r
-    pSelectedService = (ENUM_SERVICE_STATUS_PROCESS *)item.lParam;\r
-\r
-    return pSelectedService;\r
-}\r
-\r
-\r
-/* Retrives the service description from the registry */\r
-BOOL GetDescription(HKEY hKey, LPTSTR *retDescription)\r
-{\r
-\r
-    LPTSTR Description = NULL;\r
-    DWORD dwValueSize = 0;\r
-    LONG ret = RegQueryValueEx(hKey,\r
-                               _T("Description"),\r
-                               NULL,\r
-                               NULL,\r
-                               NULL,\r
-                               &dwValueSize);\r
-    if (ret != ERROR_SUCCESS && ret != ERROR_FILE_NOT_FOUND && ret != ERROR_INVALID_HANDLE)\r
-    {\r
-        RegCloseKey(hKey);\r
-        return FALSE;\r
-    }\r
-\r
-    if (ret != ERROR_FILE_NOT_FOUND)\r
-    {\r
-        Description = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, dwValueSize);\r
-        if (Description == NULL)\r
-        {\r
-            RegCloseKey(hKey);\r
-            return FALSE;\r
-        }\r
-\r
-        if(RegQueryValueEx(hKey,\r
-                           _T("Description"),\r
-                           NULL,\r
-                           NULL,\r
-                           (LPBYTE)Description,\r
-                           &dwValueSize))\r
-        {\r
-            HeapFree(GetProcessHeap(), 0, Description);\r
-            RegCloseKey(hKey);\r
-            return FALSE;\r
-        }\r
-    }\r
-\r
-    /* copy pointer over */\r
-    *retDescription = Description;\r
-\r
-    return TRUE;\r
-}\r
-\r
-\r
-/* get vendor of service binary */\r
-BOOL GetExecutablePath(LPTSTR *ExePath)\r
-{\r
-    SC_HANDLE hSCManager = NULL;\r
-    SC_HANDLE hSc = NULL;\r
-    LPQUERY_SERVICE_CONFIG pServiceConfig = NULL;\r
-    ENUM_SERVICE_STATUS_PROCESS *Service = NULL;\r
-    DWORD BytesNeeded = 0;\r
-\r
-    /* copy pointer to selected service */\r
-    Service = GetSelectedService();\r
-\r
-    /* open handle to the SCM */\r
-    hSCManager = OpenSCManager(NULL, NULL, SC_MANAGER_ENUMERATE_SERVICE);\r
-    if (hSCManager == NULL)\r
-    {\r
-        GetError(0);\r
-        return FALSE;\r
-    }\r
-\r
-    /* get a handle to the service requested for starting */\r
-    hSc = OpenService(hSCManager, Service->lpServiceName, SERVICE_QUERY_CONFIG);\r
-    if (hSc == NULL)\r
-    {\r
-        GetError(0);\r
-        goto cleanup;\r
-    }\r
-\r
-\r
-    if (!QueryServiceConfig(hSc, pServiceConfig, 0, &BytesNeeded))\r
-    {\r
-        if (GetLastError() == ERROR_INSUFFICIENT_BUFFER)\r
-        {\r
-            pServiceConfig = (LPQUERY_SERVICE_CONFIG)\r
-                HeapAlloc(GetProcessHeap(), 0, BytesNeeded);\r
-            if (pServiceConfig == NULL)\r
-                goto cleanup;\r
-\r
-            if (!QueryServiceConfig(hSc,\r
-                                    pServiceConfig,\r
-                                    BytesNeeded,\r
-                                    &BytesNeeded))\r
-            {\r
-                HeapFree(GetProcessHeap(), 0, pServiceConfig);\r
-                goto cleanup;\r
-            }\r
-        }\r
-        else /* exit on failure */\r
-        {\r
-            goto cleanup;\r
-        }\r
-    }\r
-\r
-    *ExePath = pServiceConfig->lpBinaryPathName;\r
-\r
-    CloseServiceHandle(hSCManager);\r
-    CloseServiceHandle(hSc);\r
-\r
-    return TRUE;\r
-\r
-cleanup:\r
-    if (hSCManager != NULL)\r
-        CloseServiceHandle(hSCManager);\r
-    if (hSc != NULL)\r
-        CloseServiceHandle(hSc);\r
-    return FALSE;\r
-}\r
-\r
-\r
-\r
-\r
-BOOL\r
-RefreshServiceList(VOID)\r
-{\r
-    LVITEM item;\r
-    TCHAR szNumServices[32];\r
-    TCHAR szStatus[64];\r
-    DWORD NumServices = 0;\r
-    DWORD Index;\r
-    LPCTSTR Path = _T("System\\CurrentControlSet\\Services\\%s");\r
-\r
-    ListView_DeleteAllItems(hListView);\r
-\r
-    NumServices = GetServiceList();\r
-\r
-    if (NumServices)\r
-    {\r
-        HICON hiconItem;    /* icon for list-view items */\r
-        HIMAGELIST hSmall;  /* image list for other views */\r
-        TCHAR buf[300];     /* buffer to hold key path */\r
-        INT NumListedServ = 0; /* how many services were listed */\r
-\r
-        /* Create the icon image lists */\r
-        hSmall = ImageList_Create(GetSystemMetrics(SM_CXSMICON),\r
-        GetSystemMetrics(SM_CYSMICON), ILC_MASK | ILC_COLOR16, 1, 1);\r
-\r
-        /* Add an icon to each image list */\r
-        hiconItem = LoadImage(hInstance, MAKEINTRESOURCE(IDI_SM_ICON),\r
-                              IMAGE_ICON, 16, 16, 0);\r
-        ImageList_AddIcon(hSmall, hiconItem);\r
-\r
-        /* assign the image to the list view */\r
-        ListView_SetImageList(hListView, hSmall, LVSIL_SMALL);\r
-\r
-        for (Index = 0; Index < NumServices; Index++)\r
-        {\r
-            HKEY hKey = NULL;\r
-            LPTSTR Description = NULL;\r
-            LPTSTR LogOnAs = NULL;\r
-            DWORD StartUp = 0;\r
-            DWORD dwValueSize;\r
-\r
-             /* open the registry key for the service */\r
-            _sntprintf(buf, 300, Path,\r
-                      pServiceStatus[Index].lpServiceName);\r
-\r
-            RegOpenKeyEx(HKEY_LOCAL_MACHINE,\r
-                         buf,\r
-                         0,\r
-                         KEY_READ,\r
-                         &hKey);\r
-\r
-\r
-            /* set the display name */\r
-\r
-            ZeroMemory(&item, sizeof(LVITEM));\r
-            item.mask = LVIF_TEXT | LVIF_PARAM;\r
-            item.pszText = pServiceStatus[Index].lpDisplayName;\r
-\r
-            /* Set a pointer for each service so we can query it later.\r
-             * Not all services are added to the list, so we can't query\r
-             * the item number as they become out of sync with the array */\r
-            item.lParam = (LPARAM)&pServiceStatus[Index];\r
-\r
-            item.iItem = ListView_GetItemCount(hListView);\r
-            item.iItem = ListView_InsertItem(hListView, &item);\r
-\r
-\r
-\r
-\r
-            /* set the description */\r
-\r
-            if (GetDescription(hKey, &Description))\r
-            {\r
-                item.pszText = Description;\r
-                item.iSubItem = 1;\r
-                SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-\r
-                HeapFree(GetProcessHeap(), 0, Description);\r
-            }\r
-\r
-\r
-            /* set the status */\r
-\r
-            if (pServiceStatus[Index].ServiceStatusProcess.dwCurrentState\r
-                    == SERVICE_RUNNING)\r
-            {\r
-                LoadString(hInstance, IDS_SERVICES_STARTED, szStatus,\r
-                    sizeof(szStatus) / sizeof(TCHAR));\r
-                item.pszText = szStatus;\r
-                item.iSubItem = 2;\r
-                SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-            }\r
-\r
-\r
-\r
-            /* set the startup type */\r
-\r
-            dwValueSize = sizeof(DWORD);\r
-            if (RegQueryValueEx(hKey,\r
-                                _T("Start"),\r
-                                NULL,\r
-                                NULL,\r
-                                (LPBYTE)&StartUp,\r
-                                &dwValueSize))\r
-            {\r
-                RegCloseKey(hKey);\r
-                continue;\r
-            }\r
-\r
-            if (StartUp == 0x02)\r
-            {\r
-                LoadString(hInstance, IDS_SERVICES_AUTO, szStatus,\r
-                    sizeof(szStatus) / sizeof(TCHAR));\r
-                item.pszText = szStatus;\r
-                item.iSubItem = 3;\r
-                SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-            }\r
-            else if (StartUp == 0x03)\r
-            {\r
-                LoadString(hInstance, IDS_SERVICES_MAN, szStatus,\r
-                    sizeof(szStatus) / sizeof(TCHAR));\r
-                item.pszText = szStatus;\r
-                item.iSubItem = 3;\r
-                SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-            }\r
-            else if (StartUp == 0x04)\r
-            {\r
-                LoadString(hInstance, IDS_SERVICES_DIS, szStatus,\r
-                    sizeof(szStatus) / sizeof(TCHAR));\r
-                item.pszText = szStatus;\r
-                item.iSubItem = 3;\r
-                SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-            }\r
-\r
-\r
-\r
-            /* set Log On As */\r
-\r
-            dwValueSize = 0;\r
-            if (RegQueryValueEx(hKey,\r
-                                _T("ObjectName"),\r
-                                NULL,\r
-                                NULL,\r
-                                NULL,\r
-                                &dwValueSize))\r
-            {\r
-                RegCloseKey(hKey);\r
-                continue;\r
-            }\r
-\r
-            LogOnAs = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, dwValueSize);\r
-            if (LogOnAs == NULL)\r
-            {\r
-                RegCloseKey(hKey);\r
-                return FALSE;\r
-            }\r
-            if(RegQueryValueEx(hKey,\r
-                               _T("ObjectName"),\r
-                               NULL,\r
-                               NULL,\r
-                               (LPBYTE)LogOnAs,\r
-                               &dwValueSize))\r
-            {\r
-                HeapFree(GetProcessHeap(), 0, LogOnAs);\r
-                RegCloseKey(hKey);\r
-                continue;\r
-            }\r
-\r
-            item.pszText = LogOnAs;\r
-            item.iSubItem = 4;\r
-            SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-\r
-            HeapFree(GetProcessHeap(), 0, LogOnAs);\r
-\r
-            RegCloseKey(hKey);\r
-\r
-        }\r
-\r
-        NumListedServ = ListView_GetItemCount(hListView);\r
-\r
-        /* set the number of listed services in the status bar */\r
-        LoadString(hInstance, IDS_NUM_SERVICES, szNumServices,\r
-            sizeof(szNumServices) / sizeof(TCHAR));\r
-        _sntprintf(buf, 300, szNumServices, NumListedServ);\r
-        SendMessage(hStatus, SB_SETTEXT, 0, (LPARAM)buf);\r
-    }\r
-\r
-    /* turn redraw flag on. It's turned off initially via the LBS_NOREDRAW flag */\r
-    SendMessage (hListView, WM_SETREDRAW, TRUE, 0) ;\r
-\r
-    return TRUE;\r
-}\r
-\r
-\r
-\r
-\r
-DWORD\r
-GetServiceList(VOID)\r
-{\r
-    SC_HANDLE ScHandle;\r
-\r
-    DWORD BytesNeeded = 0;\r
-    DWORD ResumeHandle = 0;\r
-    DWORD NumServices = 0;\r
-\r
-    ScHandle = OpenSCManager(NULL, NULL, SC_MANAGER_ENUMERATE_SERVICE);\r
-    if (ScHandle != INVALID_HANDLE_VALUE)\r
-    {\r
-        if (EnumServicesStatusEx(ScHandle,\r
-                                 SC_ENUM_PROCESS_INFO,\r
-                                 SERVICE_WIN32,\r
-                                 SERVICE_STATE_ALL,\r
-                                 (LPBYTE)pServiceStatus,\r
-                                 0, &BytesNeeded,\r
-                                 &NumServices,\r
-                                 &ResumeHandle,\r
-                                 0) == 0)\r
-        {\r
-            /* Call function again if required size was returned */\r
-            if (GetLastError() == ERROR_MORE_DATA)\r
-            {\r
-                /* reserve memory for service info array */\r
-                pServiceStatus = (ENUM_SERVICE_STATUS_PROCESS *)\r
-                        HeapAlloc(GetProcessHeap(), 0, BytesNeeded);\r
-                if (pServiceStatus == NULL)\r
-                               return FALSE;\r
-\r
-                /* fill array with service info */\r
-                if (EnumServicesStatusEx(ScHandle,\r
-                                         SC_ENUM_PROCESS_INFO,\r
-                                         SERVICE_WIN32,\r
-                                         SERVICE_STATE_ALL,\r
-                                         (LPBYTE)pServiceStatus,\r
-                                         BytesNeeded,\r
-                                         &BytesNeeded,\r
-                                         &NumServices,\r
-                                         &ResumeHandle,\r
-                                         0) == 0)\r
-                {\r
-                    HeapFree(GetProcessHeap(), 0, pServiceStatus);\r
-                    return FALSE;\r
-                }\r
-            }\r
-            else /* exit on failure */\r
-            {\r
-                return FALSE;\r
-            }\r
-        }\r
-    }\r
-\r
-    CloseServiceHandle(ScHandle);\r
-\r
-    return NumServices;\r
-}\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-/*\r
-    //WORD wCodePage;\r
-    //WORD wLangID;\r
-    //SC_HANDLE hService;\r
-    //DWORD dwHandle, dwLen;\r
-    //UINT BufLen;\r
-    //TCHAR* lpData;\r
-    //TCHAR* lpBuffer;\r
-    //TCHAR szStrFileInfo[80];\r
-    //TCHAR FileName[MAX_PATH];\r
-    //LPVOID pvData;\r
-\r
-    //LPSERVICE_FAILURE_ACTIONS pServiceFailureActions = NULL;\r
-    //LPQUERY_SERVICE_CONFIG pServiceConfig = NULL;\r
-\r
-               BytesNeeded = 0;\r
-                hService = OpenService(ScHandle,\r
-                                       pServiceStatus[Index].lpServiceName,\r
-                                       SC_MANAGER_CONNECT);\r
-                if (hService != INVALID_HANDLE_VALUE)\r
-                {\r
-                    / * check if service is required by the system* /\r
-                    if (!QueryServiceConfig2(hService,\r
-                                             SERVICE_CONFIG_FAILURE_ACTIONS,\r
-                                             (LPBYTE)pServiceFailureActions,\r
-                                             0,\r
-                                             &BytesNeeded))\r
-                    {\r
-                        if (GetLastError() == ERROR_INSUFFICIENT_BUFFER)\r
-                        {\r
-                            pServiceFailureActions = (LPSERVICE_FAILURE_ACTIONS)\r
-                                HeapAlloc(GetProcessHeap(), 0, BytesNeeded);\r
-                            if (pServiceFailureActions == NULL)\r
-                                           return FALSE;\r
-\r
-                            if (!QueryServiceConfig2(hService,\r
-                                                     SERVICE_CONFIG_FAILURE_ACTIONS,\r
-                                                     (LPBYTE)pServiceFailureActions,\r
-                                                     BytesNeeded,\r
-                                                     &BytesNeeded))\r
-                            {\r
-                                HeapFree(GetProcessHeap(), 0, pServiceFailureActions);\r
-                                return FALSE;\r
-                            }\r
-                        }\r
-                        else / * exit on failure * /\r
-                        {\r
-                            return FALSE;\r
-                        }\r
-                    }\r
-                    if (pServiceFailureActions->cActions)\r
-                    {\r
-                        if (pServiceFailureActions->lpsaActions[0].Type == SC_ACTION_REBOOT)\r
-                        {\r
-                            LoadString(hInstance, IDS_SERVICES_YES, szStatus, 128);\r
-                            item.pszText = szStatus;\r
-                            item.iSubItem = 1;\r
-                            SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-                        }\r
-                    }\r
-\r
-                                       if (pServiceFailureActions != NULL)\r
-                                       {\r
-                                               HeapFree(GetProcessHeap(), 0, pServiceFailureActions);\r
-                                               pServiceFailureActions = NULL;\r
-                                       }\r
-\r
-                    / * get vendor of service binary * /\r
-                    BytesNeeded = 0;\r
-                    if (!QueryServiceConfig(hService, pServiceConfig, 0, &BytesNeeded))\r
-                    {\r
-                        if (GetLastError() == ERROR_INSUFFICIENT_BUFFER)\r
-                        {\r
-                            pServiceConfig = (LPQUERY_SERVICE_CONFIG)\r
-                                HeapAlloc(GetProcessHeap(), 0, BytesNeeded);\r
-                            if (pServiceConfig == NULL)\r
-                                           return FALSE;\r
-\r
-                            if (!QueryServiceConfig(hService,\r
-                                                    pServiceConfig,\r
-                                                    BytesNeeded,\r
-                                                    &BytesNeeded))\r
-                            {\r
-                                HeapFree(GetProcessHeap(), 0, pServiceConfig);\r
-                                return FALSE;\r
-                            }\r
-                        }\r
-                        else / * exit on failure * /\r
-                        {\r
-                            return FALSE;\r
-                        }\r
-                    }\r
-\r
-                    memset(&FileName, 0, MAX_PATH);\r
-                    if (_tcscspn(pServiceConfig->lpBinaryPathName, _T("\"")))\r
-                    {\r
-                        _tcsncpy(FileName, pServiceConfig->lpBinaryPathName,\r
-                            _tcscspn(pServiceConfig->lpBinaryPathName, _T(" ")) );\r
-                    }\r
-                    else\r
-                    {\r
-                        _tcscpy(FileName, pServiceConfig->lpBinaryPathName);\r
-                    }\r
-\r
-                                       HeapFree(GetProcessHeap(), 0, pServiceConfig);\r
-                                       pServiceConfig = NULL;\r
-\r
-                                       dwLen = GetFileVersionInfoSize(FileName, &dwHandle);\r
-                    if (dwLen)\r
-                    {\r
-                        lpData = (TCHAR*) HeapAlloc(GetProcessHeap(), 0, dwLen);\r
-                        if (lpData == NULL)\r
-                                       return FALSE;\r
-\r
-                        if (!GetFileVersionInfo (FileName, dwHandle, dwLen, lpData)) {\r
-                                   HeapFree(GetProcessHeap(), 0, lpData);\r
-                                   return FALSE;\r
-                           }\r
-\r
-                        if (VerQueryValue(lpData, _T("\\VarFileInfo\\Translation"), &pvData, (PUINT) &BufLen))\r
-                        {\r
-                            wCodePage = LOWORD(*(DWORD*) pvData);\r
-                            wLangID = HIWORD(*(DWORD*) pvData);\r
-                            wsprintf(szStrFileInfo, _T("StringFileInfo\\%04X%04X\\CompanyName"), wCodePage, wLangID);\r
-                        }\r
-\r
-                        if (VerQueryValue (lpData, szStrFileInfo, (LPVOID) &lpBuffer, (PUINT) &BufLen)) {\r
-                            item.pszText = lpBuffer;\r
-                            item.iSubItem = 2;\r
-                            SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-                        }\r
-                                               HeapFree(GetProcessHeap(), 0, lpData);\r
-                    }\r
-                    else\r
-                    {\r
-                        LoadString(hInstance, IDS_SERVICES_UNKNOWN, szStatus, 128);\r
-                        item.pszText = szStatus;\r
-                        item.iSubItem = 2;\r
-                        SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-                    }\r
-                    CloseServiceHandle(hService);\r
-                }\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-    HeapFree(GetProcessHeap(), 0, pServiceConfig);\r
-    pServiceConfig = NULL;\r
-\r
-    dwLen = GetFileVersionInfoSize(FileName, &dwHandle);\r
-    if (dwLen)\r
-    {\r
-        lpData = (TCHAR*) HeapAlloc(GetProcessHeap(), 0, dwLen);\r
-        if (lpData == NULL)\r
-            return FALSE;\r
-\r
-        if (!GetFileVersionInfo (FileName, dwHandle, dwLen, lpData)) {\r
-            HeapFree(GetProcessHeap(), 0, lpData);\r
-            return FALSE;\r
-        }\r
-\r
-        if (VerQueryValue(lpData, _T("\\VarFileInfo\\Translation"),\r
-                          &pvData, (PUINT) &BufLen))\r
-        {\r
-            wCodePage = LOWORD(*(DWORD*) pvData);\r
-            wLangID = HIWORD(*(DWORD*) pvData);\r
-            wsprintf(szStrFileInfo, _T("StringFileInfo\\%04X%04X\\CompanyName"),\r
-                     wCodePage, wLangID);\r
-        }\r
-\r
-        if (VerQueryValue (lpData, szStrFileInfo, (LPVOID) &lpBuffer, (PUINT) &BufLen))\r
-        {\r
-            item.pszText = lpBuffer;\r
-            item.iSubItem = 2;\r
-            SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-        }\r
-        HeapFree(GetProcessHeap(), 0, lpData);\r
-    }\r
-    else\r
-    {\r
-        LoadString(hInstance, IDS_SERVICES_UNKNOWN, szStatus, 128);\r
-        item.pszText = szStatus;\r
-        item.iSubItem = 2;\r
-        SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-    }\r
-\r
-\r
-*/\r
-\r
diff --git a/reactos/subsys/system/servman/res/system.ico b/reactos/subsys/system/servman/res/system.ico
deleted file mode 100644 (file)
index 2d8f322..0000000
Binary files a/reactos/subsys/system/servman/res/system.ico and /dev/null differ
diff --git a/reactos/subsys/system/servman/res/toolbar.bmp b/reactos/subsys/system/servman/res/toolbar.bmp
deleted file mode 100644 (file)
index 5f26621..0000000
Binary files a/reactos/subsys/system/servman/res/toolbar.bmp and /dev/null differ
diff --git a/reactos/subsys/system/servman/resource.h b/reactos/subsys/system/servman/resource.h
deleted file mode 100644 (file)
index 927e91e..0000000
+++ /dev/null
@@ -1,105 +0,0 @@
-#define IDC_STATIC -1\r
-\r
-/* about box info */\r
-#define IDD_ABOUTBOX        200\r
-#define IDC_LICENSE_EDIT    201\r
-#define IDS_LICENSE         202\r
-\r
-#define IDC_SERVLIST        1000\r
-#define IDC_TOOLBAR         1001\r
-#define IDC_STATUSBAR      1002\r
-\r
-#define ID_PROP             2000\r
-#define ID_REFRESH          2001\r
-#define ID_EXPORT           2002\r
-#define ID_START            2003\r
-#define ID_STOP             2004\r
-#define ID_PAUSE            2005\r
-#define ID_RESUME           2006\r
-#define ID_RESTART          2007\r
-#define ID_NEW              2008\r
-#define ID_HELP             2009\r
-#define ID_EXIT             2010\r
-\r
-#define IDR_MAINMENU        102\r
-#define IDR_POPUP           103\r
-#define ID_VIEW_CUSTOMIZE   4021\r
-#define ID_ABOUT            4031\r
-\r
-/* List view columns */\r
-#define IDS_FIRSTCOLUMN     1\r
-#define IDS_SECONDCOLUMN    2\r
-#define IDS_THIRDCOLUMN     3\r
-#define IDS_FOURTHCOLUMN    4\r
-#define IDS_FITHCOLUMN      5\r
-\r
-/* tooltips */\r
-#define IDS_TOOLTIP_PROP    6000\r
-#define IDS_TOOLTIP_REFRESH 6001\r
-#define IDS_TOOLTIP_EXPORT  6002\r
-#define IDS_TOOLTIP_START   6003\r
-#define IDS_TOOLTIP_STOP    6004\r
-#define IDS_TOOLTIP_PAUSE   6005\r
-#define IDS_TOOLTIP_RESTART 6006\r
-#define IDS_TOOLTIP_NEW     6007\r
-#define IDS_TOOLTIP_HELP    6008\r
-#define IDS_TOOLTIP_EXIT    6009\r
-\r
-#define IDS_SERVICES_STARTED 5000\r
-#define IDS_SERVICES_STOPPED 5001\r
-#define IDS_SERVICES_AUTO    5004\r
-#define IDS_SERVICES_MAN     5005\r
-#define IDS_SERVICES_DIS     5006\r
-#define IDS_NUM_SERVICES     5010\r
-\r
-#define IDI_SM_ICON         50\r
-#define IDB_BUTTONS         51\r
-\r
-/* toolbar buttons */\r
-#define TBICON_PROP         0\r
-#define TBICON_REFRESH      1\r
-#define TBICON_EXPORT       2\r
-#define TBICON_NEW          3\r
-#define TBICON_START        4\r
-#define TBICON_STOP         5\r
-#define TBICON_PAUSE        6\r
-#define TBICON_RESTART      7\r
-#define TBICON_HELP         8\r
-#define TBICON_EXIT         9\r
-\r
-/* properties dialog */\r
-#define IDS_PROP_SHEET      10000\r
-#define IDD_DLG_GENERAL     10001\r
-#define IDC_SERV_NAME       10041\r
-#define IDC_DISP_NAME       10051\r
-#define IDC_DESCRIPTION     10061\r
-#define IDC_EXEPATH         10062\r
-#define IDC_START_TYPE      10101\r
-#define IDC_SERV_STATUS     10121\r
-#define IDC_START           10131\r
-#define IDC_STOP            10141\r
-#define IDC_PAUSE           10151\r
-#define IDC_RESUME          10161\r
-#define IDC_START_PARAM     10191\r
-\r
-#define IDD_DLG_DEPEND      20001\r
-#define IDC_DEPEND_TREE1    20002\r
-#define IDC_DEPEND_TREE2    20003\r
-#define IDC_DEPEND_SERVICE  20004\r
-\r
-\r
-/* create service dialog */\r
-#define IDD_DLG_CREATE      8000\r
-#define IDC_CREATE_SERVNAME 8001\r
-#define IDC_CREATE_DISPNAME 8002\r
-#define IDC_CREATE_PATH     8003\r
-#define IDC_CREATE_DESC     8004\r
-#define IDC_CREATE_OPTIONS  8005\r
-#define ID_CREATE_HELP      8006\r
-\r
-/* progress bar */\r
-#define IDD_DLG_PROGRESS    7000\r
-#define IDC_SERVCON_PROGRESS 7001\r
-#define IDC_SERVCON_INFO    7002\r
-#define IDC_SERVCON_NAME    7003\r
-#define IDS_PROGRESS_INFO   7004\r
diff --git a/reactos/subsys/system/servman/servman.c b/reactos/subsys/system/servman/servman.c
deleted file mode 100644 (file)
index f186361..0000000
+++ /dev/null
@@ -1,552 +0,0 @@
-/*\r
- * PROJECT:     ReactOS Services\r
- * LICENSE:     GPL - See COPYING in the top level directory\r
- * FILE:        subsys/system/servman/servman.c\r
- * PURPOSE:     Main window message handler\r
- * COPYRIGHT:   Copyright 2005 - 2006 Ged Murphy <gedmurphy@gmail.com>\r
- *\r
- */\r
-\r
-#include "servman.h"\r
-\r
-const TCHAR ClassName[] = _T("ServiceManager");\r
-\r
-HINSTANCE hInstance;\r
-HWND hMainWnd;\r
-HWND hListView;\r
-HWND hStatus;\r
-HWND hTool;\r
-HWND hProgDlg;\r
-HMENU hShortcutMenu;\r
-INT SelectedItem;\r
-\r
-\r
-INT GetSelectedItem(VOID)\r
-{\r
-    return SelectedItem;\r
-}\r
-\r
-\r
-LRESULT CALLBACK WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)\r
-{\r
-    switch(msg)\r
-    {\r
-        case WM_CREATE:\r
-        {\r
-            TBADDBITMAP tbab;\r
-            INT iImageOffset;\r
-            INT statwidths[] = {110, -1}; /* widths of status bar */\r
-            TCHAR szTemp[256];\r
-            LVCOLUMN lvc = { 0 };\r
-\r
-            /* Toolbar buttons */\r
-            TBBUTTON tbb [NUM_BUTTONS] =\r
-            {   /* iBitmap, idCommand, fsState, fsStyle, bReserved[2], dwData, iString */\r
-                {TBICON_PROP,    ID_PROP,    TBSTATE_ENABLED, BTNS_BUTTON, {0}, 0, 0},    /* properties */\r
-                {TBICON_REFRESH, ID_REFRESH, TBSTATE_ENABLED, BTNS_BUTTON, {0}, 0, 0},    /* refresh */\r
-                {TBICON_EXPORT,  ID_EXPORT,  TBSTATE_ENABLED, BTNS_BUTTON, {0}, 0, 0},    /* export */\r
-\r
-                /* Note: First item for a seperator is its width in pixels */\r
-                {15, 0, TBSTATE_ENABLED, BTNS_SEP, {0}, 0, 0},                            /* separator */\r
-\r
-                {TBICON_NEW,     ID_NEW,   TBSTATE_ENABLED, BTNS_BUTTON, {0}, 0, 0 },     /* create */\r
-\r
-                {15, 0, TBSTATE_ENABLED, BTNS_SEP, {0}, 0, 0},                            /* separator */\r
-\r
-                {TBICON_START,   ID_START,   TBSTATE_ENABLED, BTNS_BUTTON, {0}, 0, 0 },   /* start */\r
-                {TBICON_STOP,    ID_STOP,    TBSTATE_ENABLED, BTNS_BUTTON, {0}, 0, 0 },   /* stop */\r
-                {TBICON_PAUSE,   ID_PAUSE,   TBSTATE_ENABLED, BTNS_BUTTON, {0}, 0, 0 },   /* pause */\r
-                {TBICON_RESTART, ID_RESTART, TBSTATE_ENABLED, BTNS_BUTTON, {0}, 0, 0 },   /* restart */\r
-\r
-                {15, 0, TBSTATE_ENABLED, BTNS_SEP, {0}, 0, 0},                            /* separator */\r
-\r
-                {TBICON_HELP,    ID_HELP,    TBSTATE_ENABLED, BTNS_BUTTON, {0}, 0, 0 },   /* help */\r
-                {TBICON_EXIT,    ID_EXIT,   TBSTATE_ENABLED, BTNS_BUTTON, {0}, 0, 0 },    /* exit */\r
-\r
-            };\r
-\r
-/* ======================== Create Toolbar ============================== */\r
-\r
-            /* Create Toolbar */\r
-            hTool = CreateWindowEx(0,\r
-                                   TOOLBARCLASSNAME,\r
-                                   NULL,\r
-                                   WS_CHILD | WS_VISIBLE | TBSTYLE_FLAT | TBSTYLE_TOOLTIPS,\r
-                                   0, 0, 0, 0,\r
-                                   hwnd,\r
-                                   (HMENU)IDC_TOOLBAR,\r
-                                   hInstance,\r
-                                   NULL);\r
-            if(hTool == NULL)\r
-                MessageBox(hwnd, _T("Could not create tool bar."), _T("Error"), MB_OK | MB_ICONERROR);\r
-\r
-            /* Send the TB_BUTTONSTRUCTSIZE message, which is required for backward compatibility */\r
-            SendMessage(hTool, TB_BUTTONSTRUCTSIZE, sizeof(TBBUTTON), 0);\r
-\r
-            /* Add custom images */\r
-            tbab.hInst = hInstance;\r
-            tbab.nID = IDB_BUTTONS;\r
-            iImageOffset = (INT)SendMessage(hTool, TB_ADDBITMAP, NUM_BUTTONS, (LPARAM)&tbab);\r
-            tbb[0].iBitmap += iImageOffset; /* properties */\r
-            tbb[1].iBitmap += iImageOffset; /* refresh */\r
-            tbb[2].iBitmap += iImageOffset; /* export */\r
-            tbb[4].iBitmap += iImageOffset; /* new */\r
-            tbb[6].iBitmap += iImageOffset; /* start */\r
-            tbb[7].iBitmap += iImageOffset; /* stop */\r
-            tbb[8].iBitmap += iImageOffset; /* pause */\r
-            tbb[9].iBitmap += iImageOffset; /* restart */\r
-            tbb[11].iBitmap += iImageOffset; /* help */\r
-            tbb[12].iBitmap += iImageOffset; /* exit */\r
-\r
-            /* Add buttons to toolbar */\r
-            SendMessage(hTool, TB_ADDBUTTONS, NUM_BUTTONS, (LPARAM) &tbb);\r
-\r
-            /* Show toolbar */\r
-            ShowWindow(hTool, SW_SHOWNORMAL);\r
-\r
-\r
-\r
-/* ======================== Create List View ============================== */\r
-\r
-            hListView = CreateWindowEx(0,\r
-                                       WC_LISTVIEW,\r
-                                       NULL,\r
-                                       WS_CHILD | WS_VISIBLE | LVS_REPORT | WS_BORDER |\r
-                                       LBS_NOTIFY | LVS_SORTASCENDING | LBS_NOREDRAW,\r
-                                       0, 0, 0, 0, /* sized via WM_SIZE */\r
-                                       hwnd,\r
-                                       (HMENU) IDC_SERVLIST,\r
-                                       hInstance,\r
-                                       NULL);\r
-            if (hListView == NULL)\r
-                MessageBox(hwnd, _T("Could not create List View."), _T("Error"), MB_OK | MB_ICONERROR);\r
-\r
-            ListView_SetExtendedListViewStyle(hListView, LVS_EX_FULLROWSELECT |\r
-                    LVS_EX_GRIDLINES | LVS_EX_HEADERDRAGDROP);\r
-\r
-            lvc.mask = LVCF_TEXT | LVCF_SUBITEM | LVCF_WIDTH  | LVCF_FMT;\r
-            lvc.fmt  = LVCFMT_LEFT;\r
-\r
-            /* Add columns to the list-view */\r
-\r
-            /* name */\r
-            lvc.iSubItem = 0;\r
-            lvc.cx       = 150;\r
-            LoadString(hInstance, IDS_FIRSTCOLUMN, szTemp, 256);\r
-            lvc.pszText  = szTemp;\r
-            ListView_InsertColumn(hListView, 0, &lvc);\r
-\r
-            /* description */\r
-            lvc.iSubItem = 1;\r
-            lvc.cx       = 240;\r
-            LoadString(hInstance, IDS_SECONDCOLUMN, szTemp, 256);\r
-            lvc.pszText  = szTemp;\r
-            ListView_InsertColumn(hListView, 1, &lvc);\r
-\r
-            /* status */\r
-            lvc.iSubItem = 2;\r
-            lvc.cx       = 55;\r
-            LoadString(hInstance, IDS_THIRDCOLUMN, szTemp, 256);\r
-            lvc.pszText  = szTemp;\r
-            ListView_InsertColumn(hListView, 2, &lvc);\r
-\r
-            /* startup type */\r
-            lvc.iSubItem = 3;\r
-            lvc.cx       = 80;\r
-            LoadString(hInstance, IDS_FOURTHCOLUMN, szTemp, 256);\r
-            lvc.pszText  = szTemp;\r
-            ListView_InsertColumn(hListView, 3, &lvc);\r
-\r
-            /* logon as */\r
-            lvc.iSubItem = 4;\r
-            lvc.cx       = 100;\r
-            LoadString(hInstance, IDS_FITHCOLUMN, szTemp, 256);\r
-            lvc.pszText  = szTemp;\r
-            ListView_InsertColumn(hListView, 4, &lvc);\r
-\r
-\r
-\r
-/* ======================== Create Status Bar ============================== */\r
-\r
-                   hStatus = CreateWindowEx(0,\r
-                                     STATUSCLASSNAME,\r
-                                     NULL,\r
-                                     WS_CHILD | WS_VISIBLE | SBARS_SIZEGRIP,\r
-                                     0, 0, 0, 0,\r
-                                     hwnd,\r
-                                     (HMENU)IDC_STATUSBAR,\r
-                                     hInstance,\r
-                                     NULL);\r
-            if(hStatus == NULL)\r
-                           MessageBox(hwnd, _T("Could not create status bar."),\r
-                           _T("Error!"), MB_OK | MB_ICONERROR);\r
-\r
-                   SendMessage(hStatus, SB_SETPARTS, sizeof(statwidths)/sizeof(int), (LPARAM)statwidths);\r
-\r
-\r
-/* ======================== Create Popup Menu ============================== */\r
-\r
-            hShortcutMenu = LoadMenu(hInstance, MAKEINTRESOURCE (IDR_POPUP));\r
-            hShortcutMenu = GetSubMenu(hShortcutMenu, 0);\r
-\r
-\r
-\r
-\r
-/* ================= populate the list view with all services =================== */\r
-\r
-                   RefreshServiceList();\r
-\r
-           }\r
-           break;\r
-\r
-           case WM_SIZE:\r
-           {\r
-                   RECT rcTool;\r
-                   int iToolHeight;\r
-\r
-                   RECT rcStatus;\r
-                   int iStatusHeight;\r
-\r
-                   int lvHeight;\r
-                   RECT rcClient;\r
-\r
-                   /* Size toolbar and get height */\r
-            hTool = GetDlgItem(hwnd, IDC_TOOLBAR);\r
-                   SendMessage(hTool, TB_AUTOSIZE, 0, 0);\r
-\r
-                   GetWindowRect(hTool, &rcTool);\r
-                   iToolHeight = rcTool.bottom - rcTool.top;\r
-\r
-                   /* Size status bar and get height */\r
-                   hStatus = GetDlgItem(hwnd, IDC_STATUSBAR);\r
-                   SendMessage(hStatus, WM_SIZE, 0, 0);\r
-\r
-                   GetWindowRect(hStatus, &rcStatus);\r
-                   iStatusHeight = rcStatus.bottom - rcStatus.top;\r
-\r
-                   /* Calculate remaining height and size list view */\r
-                   GetClientRect(hwnd, &rcClient);\r
-\r
-                   lvHeight = rcClient.bottom - iToolHeight - iStatusHeight;\r
-\r
-                   hListView = GetDlgItem(hwnd, IDC_SERVLIST);\r
-                   SetWindowPos(hListView, NULL, 0, iToolHeight, rcClient.right, lvHeight, SWP_NOZORDER);\r
-           }\r
-           break;\r
-\r
-           case WM_NOTIFY:\r
-        {\r
-            NMHDR* nm = (NMHDR*) lParam;\r
-\r
-            switch (nm->code)\r
-            {\r
-                   case NM_DBLCLK:\r
-                    OpenPropSheet(hwnd);\r
-                           break;\r
-\r
-                           case LVN_ITEMCHANGED:\r
-                           {\r
-                               LPNMLISTVIEW pnmv = (LPNMLISTVIEW) lParam;\r
-\r
-                               SelectedItem = pnmv->iItem;\r
-\r
-                           }\r
-                           break;\r
-\r
-                case TTN_GETDISPINFO:\r
-                {\r
-                    LPTOOLTIPTEXT lpttt;\r
-                    UINT idButton;\r
-\r
-                    lpttt = (LPTOOLTIPTEXT) lParam;\r
-\r
-                    /* Specify the resource identifier of the descriptive\r
-                     * text for the given button. */\r
-                    idButton = (UINT)lpttt->hdr.idFrom;\r
-                    switch (idButton)\r
-                    {\r
-                        case ID_PROP:\r
-                            lpttt->lpszText = MAKEINTRESOURCE(IDS_TOOLTIP_PROP);\r
-                        break;\r
-\r
-                        case ID_REFRESH:\r
-                            lpttt->lpszText = MAKEINTRESOURCE(IDS_TOOLTIP_REFRESH);\r
-                        break;\r
-\r
-                        case ID_EXPORT:\r
-                            lpttt->lpszText = MAKEINTRESOURCE(IDS_TOOLTIP_EXPORT);\r
-                        break;\r
-\r
-                        case ID_START:\r
-                            lpttt->lpszText = MAKEINTRESOURCE(IDS_TOOLTIP_START);\r
-                        break;\r
-\r
-                        case ID_STOP:\r
-                            lpttt->lpszText = MAKEINTRESOURCE(IDS_TOOLTIP_STOP);\r
-                        break;\r
-\r
-                        case ID_PAUSE:\r
-                            lpttt->lpszText = MAKEINTRESOURCE(IDS_TOOLTIP_PAUSE);\r
-                        break;\r
-\r
-                        case ID_RESTART:\r
-                            lpttt->lpszText = MAKEINTRESOURCE(IDS_TOOLTIP_RESTART);\r
-                        break;\r
-\r
-                        case ID_NEW:\r
-                            lpttt->lpszText = MAKEINTRESOURCE(IDS_TOOLTIP_NEW);\r
-                        break;\r
-\r
-                        case ID_HELP:\r
-                            lpttt->lpszText = MAKEINTRESOURCE(IDS_TOOLTIP_HELP);\r
-                        break;\r
-\r
-                        case ID_EXIT:\r
-                            lpttt->lpszText = MAKEINTRESOURCE(IDS_TOOLTIP_EXIT);\r
-                        break;\r
-\r
-                    }\r
-                }\r
-                break;\r
-\r
-                default:\r
-                break;\r
-            }\r
-        }\r
-        break;\r
-\r
-        case WM_CONTEXTMENU:\r
-            {\r
-                int xPos, yPos;\r
-\r
-                xPos = GET_X_LPARAM(lParam);\r
-                yPos = GET_Y_LPARAM(lParam);\r
-\r
-                TrackPopupMenuEx(hShortcutMenu, TPM_RIGHTBUTTON,\r
-                                 xPos, yPos, hwnd, NULL);\r
-            }\r
-        break;\r
-\r
-           case WM_COMMAND:\r
-\r
-                   switch(LOWORD(wParam))\r
-                   {\r
-                case ID_PROP:\r
-                    OpenPropSheet(hwnd);\r
-\r
-                break;\r
-\r
-                case ID_REFRESH:\r
-                    RefreshServiceList();\r
-                break;\r
-\r
-                case ID_EXPORT:\r
-                break;\r
-\r
-                case ID_START:\r
-                {\r
-                    ENUM_SERVICE_STATUS_PROCESS *Service = NULL;\r
-                    TCHAR buf1[100];\r
-                    TCHAR buf2[100];\r
-                    /* open the progress dialog */\r
-                    hProgDlg = CreateDialog(GetModuleHandle(NULL), \r
-                                            MAKEINTRESOURCE(IDD_DLG_PROGRESS),\r
-                                            hMainWnd, \r
-                                            (DLGPROC)ProgressDialogProc);\r
-                    if (hProgDlg != NULL)\r
-                    {\r
-                        ShowWindow(hProgDlg, SW_SHOW);\r
-\r
-                        /* write the  info to the progress dialog */\r
-                        LoadString(hInstance, IDS_PROGRESS_INFO, buf1,\r
-                            sizeof(buf1) / sizeof(TCHAR));\r
-                        _sntprintf(buf2, 100, buf1, _T("start"));\r
-                        SendDlgItemMessage(hProgDlg, IDC_SERVCON_INFO, WM_SETTEXT, 0, (LPARAM)buf2);\r
-\r
-                        /* get pointer to selected service */\r
-                        Service = GetSelectedService();\r
-\r
-                        /* write the service name to the progress dialog */\r
-                        SendDlgItemMessage(hProgDlg, IDC_SERVCON_NAME, WM_SETTEXT, 0, \r
-                            (LPARAM)Service->lpServiceName);\r
-                    }\r
-\r
-                    if ( DoStartService(hProgDlg) )\r
-                    {\r
-                        LVITEM item;\r
-                        TCHAR szStatus[64];\r
-\r
-                        LoadString(hInstance, IDS_SERVICES_STARTED, szStatus,\r
-                            sizeof(szStatus) / sizeof(TCHAR));\r
-                        item.pszText = szStatus;\r
-                        item.iItem = GetSelectedItem();\r
-                        item.iSubItem = 2;\r
-                        SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-                    }\r
-\r
-                    SendMessage(hProgDlg, WM_DESTROY, 0, 0);\r
-                }\r
-                           break;\r
-\r
-                case ID_STOP:\r
-                {\r
-                    ENUM_SERVICE_STATUS_PROCESS *Service = NULL;\r
-                    TCHAR buf1[100];\r
-                    TCHAR buf2[100];\r
-                    /* open the progress dialog */\r
-                    hProgDlg = CreateDialog(GetModuleHandle(NULL), \r
-                                            MAKEINTRESOURCE(IDD_DLG_PROGRESS),\r
-                                            hMainWnd, \r
-                                            (DLGPROC)ProgressDialogProc);\r
-                    if (hProgDlg != NULL)\r
-                    {\r
-                        ShowWindow(hProgDlg, SW_SHOW);\r
-\r
-                        /* write the  info to the progress dialog */\r
-                        LoadString(hInstance, IDS_PROGRESS_INFO, buf1,\r
-                            sizeof(buf1) / sizeof(TCHAR));\r
-                        _sntprintf(buf2, 100, buf1, _T("stop"));\r
-                        SendDlgItemMessage(hProgDlg, IDC_SERVCON_INFO, WM_SETTEXT, 0, (LPARAM)buf2);\r
-\r
-                        /* get pointer to selected service */\r
-                        Service = GetSelectedService();\r
-\r
-                        /* write the service name to the progress dialog */\r
-                        SendDlgItemMessage(hProgDlg, IDC_SERVCON_NAME, WM_SETTEXT, 0, \r
-                            (LPARAM)Service->lpServiceName);\r
-                    }\r
-\r
-                    if( Control(hProgDlg, SERVICE_CONTROL_STOP) )\r
-                    {\r
-                        LVITEM item;\r
-\r
-                        item.pszText = '\0';\r
-                        item.iItem = GetSelectedItem();\r
-                        item.iSubItem = 2;\r
-                        SendMessage(hListView, LVM_SETITEMTEXT, item.iItem, (LPARAM) &item);\r
-                    }\r
-\r
-                    SendMessage(hProgDlg, WM_DESTROY, 0, 0);\r
-                }\r
-                break;\r
-\r
-                case ID_PAUSE:\r
-                    Control(hProgDlg, SERVICE_CONTROL_PAUSE);\r
-                break;\r
-\r
-                case ID_RESUME:\r
-                    Control(hProgDlg, SERVICE_CONTROL_CONTINUE );\r
-                break;\r
-\r
-                case ID_RESTART:\r
-                    SendMessage(hMainWnd, WM_COMMAND, 0, ID_STOP);\r
-                    SendMessage(hMainWnd, WM_COMMAND, 0, ID_START);\r
-                break;\r
-\r
-                case ID_NEW:\r
-                break;\r
-\r
-                case ID_HELP:\r
-                    MessageBox(NULL, _T("Help is not yet implemented\n"),\r
-                        _T("Note!"), MB_OK | MB_ICONINFORMATION);\r
-                break;\r
-\r
-                case ID_EXIT:\r
-                    PostMessage(hwnd, WM_CLOSE, 0, 0);\r
-                break;\r
-\r
-                case ID_VIEW_CUSTOMIZE:\r
-                break;\r
-\r
-                case ID_ABOUT:\r
-                    DialogBox(hInstance,\r
-                              MAKEINTRESOURCE(IDD_ABOUTBOX),\r
-                              hMainWnd,\r
-                              (DLGPROC)AboutDialogProc);\r
-                 break;\r
-\r
-                   }\r
-           break;\r
-\r
-           case WM_CLOSE:\r
-            FreeMemory(); /* free the service array */\r
-            DestroyMenu(hShortcutMenu);\r
-                   DestroyWindow(hwnd);\r
-           break;\r
-\r
-           case WM_DESTROY:\r
-                   PostQuitMessage(0);\r
-           break;\r
-\r
-           default:\r
-                   return DefWindowProc(hwnd, msg, wParam, lParam);\r
-    }\r
-    return 0;\r
-}\r
-\r
-#ifdef _MSC_VER\r
-#pragma warning(disable : 4100)\r
-#endif\r
-int WINAPI WinMain(HINSTANCE hThisInstance, HINSTANCE hPrevInstance,\r
-    LPSTR lpCmdLine, int nCmdShow)\r
-{\r
-    WNDCLASSEX wc;\r
-    MSG Msg;\r
-\r
-    hInstance = hThisInstance;\r
-\r
-    InitCommonControls();\r
-\r
-    wc.cbSize           = sizeof(WNDCLASSEX);\r
-    wc.style            = 0;\r
-    wc.lpfnWndProc      = WndProc;\r
-    wc.cbClsExtra       = 0;\r
-    wc.cbWndExtra       = 0;\r
-    wc.hInstance        = hInstance;\r
-    wc.hIcon            = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_SM_ICON));\r
-    wc.hCursor          = LoadCursor(NULL, IDC_ARROW);\r
-    wc.hbrBackground = (HBRUSH)(COLOR_BTNFACE + 1);\r
-    wc.lpszMenuName  = MAKEINTRESOURCE(IDR_MAINMENU);\r
-    wc.lpszClassName = ClassName;\r
-    wc.hIconSm          = (HICON)LoadImage(hInstance,\r
-                        MAKEINTRESOURCE(IDI_SM_ICON), IMAGE_ICON, 16, 16, 0);\r
-\r
-    if(!RegisterClassEx(&wc))\r
-    {\r
-           MessageBox(NULL, _T("Window Registration Failed!"), _T("Error!"),\r
-                   MB_ICONEXCLAMATION | MB_OK);\r
-           return 0;\r
-    }\r
-\r
-    hMainWnd = CreateWindowEx(\r
-           0,\r
-           ClassName,\r
-           _T("ReactOS Service Manager"),\r
-           WS_OVERLAPPEDWINDOW | WS_CLIPCHILDREN,\r
-           CW_USEDEFAULT, CW_USEDEFAULT, 650, 450,\r
-           NULL, NULL, hInstance, NULL);\r
-\r
-    if(hMainWnd == NULL)\r
-    {\r
-           MessageBox(NULL, _T("Window Creation Failed!"), _T("Error!"),\r
-                   MB_ICONEXCLAMATION | MB_OK);\r
-           return 0;\r
-    }\r
-\r
-    ShowWindow(hMainWnd, nCmdShow);\r
-    UpdateWindow(hMainWnd);\r
-\r
-    while( GetMessage( &Msg, NULL, 0, 0 ) )\r
-    {\r
-        if(! IsDialogMessage(hProgDlg, &Msg) )\r
-        {\r
-            TranslateMessage(&Msg);\r
-            DispatchMessage(&Msg);\r
-        }\r
-\r
-    }\r
-    return (int)Msg.wParam;\r
-}\r
-\r
-\r
-\r
diff --git a/reactos/subsys/system/servman/servman.h b/reactos/subsys/system/servman/servman.h
deleted file mode 100644 (file)
index be22a04..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-#ifndef __SERVMAN_H\r
-#define __SERVMAN_H\r
-\r
-#define WIN32_LEAN_AND_MEAN\r
-#include <windows.h>\r
-#include <windowsx.h> /* GET_X/Y_LPARAM */\r
-#include <stdio.h>\r
-#include <tchar.h>\r
-#include <commctrl.h>\r
-#include "resource.h"\r
-\r
-#define MAX_KEY_LENGTH 256\r
-#define NUM_BUTTONS 13\r
-#define PROGRESSRANGE 8\r
-\r
-BOOL RefreshServiceList(VOID);\r
-\r
-BOOL CALLBACK AboutDialogProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);\r
-BOOL CALLBACK ProgressDialogProc(HWND hDlg, UINT Message, WPARAM wParam, LPARAM lParam);\r
-\r
-BOOL DoStartService(HWND hProgDlg);\r
-BOOL Control(HWND hProgBar, DWORD Control);\r
-\r
-INT GetSelectedItem(VOID);\r
-\r
-ENUM_SERVICE_STATUS_PROCESS* GetSelectedService(VOID);\r
-\r
-VOID GetError(DWORD);\r
-VOID FreeMemory(VOID);\r
-VOID DisplayString(PTCHAR);\r
-\r
-BOOL GetDescription(HKEY, LPTSTR *);\r
-BOOL GetExecutablePath(LPTSTR *);\r
-\r
-LONG APIENTRY OpenPropSheet(HWND);\r
-\r
-DWORD GetServiceList(VOID);\r
-\r
-\r
-#endif /* __SERVMAN_H */\r
diff --git a/reactos/subsys/system/servman/servman.rc b/reactos/subsys/system/servman/servman.rc
deleted file mode 100644 (file)
index b771ab9..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-#include <windows.h>\r
-#include <commctrl.h>\r
-#include "resource.h"\r
-\r
-\r
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS Service Manager\0"\r
-#define REACTOS_STR_INTERNAL_NAME      "services\0"\r
-#define REACTOS_STR_ORIGINAL_FILENAME  "services.exe\0"\r
-//#include <reactos/version.rc>\r
-\r
-LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US\r
-\r
-IDI_SM_ICON ICON "res/system.ico"\r
-\r
-#include "En.rc"\r
-//#include "De.rc" /* I don't want to have to keep altering 2 files whilst developing */\r
-\r
diff --git a/reactos/subsys/system/servman/servman.xml b/reactos/subsys/system/servman/servman.xml
deleted file mode 100644 (file)
index 37e8bce..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-<module name="servman" type="win32gui" installbase="system32" installname="servman.exe">\r
-       <include base="servman">.</include>\r
-       <define name="UNICODE" />\r
-       <define name="_UNICODE" />\r
-       <define name="__REACTOS__" />\r
-       <define name="__USE_W32API" />\r
-       <define name="_WIN32_IE">0x600</define>\r
-       <define name="_WIN32_WINNT">0x501</define>\r
-       <library>kernel32</library>\r
-       <library>user32</library>\r
-       <library>advapi32</library>\r
-       <library>version</library>\r
-       <library>comctl32</library>\r
-       <library>shell32</library>\r
-       <compilationunit name="unit.c">\r
-               <file>about.c</file>\r
-               <file>control.c</file>\r
-               <file>geterror.c</file>\r
-               <file>progress.c</file>\r
-               <file>propsheet.c</file>\r
-               <file>query.c</file>\r
-               <file>servman.c</file>\r
-               <file>start.c</file>\r
-       </compilationunit>\r
-       <file>servman.rc</file>\r
-       <pch>servman.h</pch>\r
-</module>\r
diff --git a/reactos/subsys/system/servman/start.c b/reactos/subsys/system/servman/start.c
deleted file mode 100644 (file)
index 25908fb..0000000
+++ /dev/null
@@ -1,132 +0,0 @@
-/*\r
- * PROJECT:     ReactOS Services\r
- * LICENSE:     GPL - See COPYING in the top level directory\r
- * FILE:        subsys/system/servman/start.c\r
- * PURPOSE:     Start a service\r
- * COPYRIGHT:   Copyright 2005 - 2006 Ged Murphy <gedmurphy@gmail.com>\r
- *\r
- */\r
-\r
-#include "servman.h"\r
-\r
-extern HWND hListView;\r
-extern HWND hMainWnd;\r
-\r
-BOOL DoStartService(HWND hProgDlg)\r
-{\r
-    HWND hProgBar;\r
-    SC_HANDLE hSCManager;\r
-    SC_HANDLE hSc;\r
-    SERVICE_STATUS_PROCESS ServiceStatus;\r
-    ENUM_SERVICE_STATUS_PROCESS *Service = NULL;\r
-    DWORD BytesNeeded = 0;\r
-    INT ArgCount = 0;\r
-    DWORD dwStartTickCount, dwOldCheckPoint;\r
-\r
-    /* copy pointer to selected service */\r
-    Service = GetSelectedService();\r
-\r
-    /* set the progress bar range and step */\r
-    hProgBar = GetDlgItem(hProgDlg, IDC_SERVCON_PROGRESS);\r
-    SendMessage(hProgBar, PBM_SETRANGE, 0, MAKELPARAM(0, PROGRESSRANGE));\r
-    SendMessage(hProgBar, PBM_SETSTEP, (WPARAM)1, 0);\r
-\r
-    /* open handle to the SCM */\r
-    hSCManager = OpenSCManager(NULL, NULL, SC_MANAGER_ALL_ACCESS);\r
-    if (hSCManager == NULL)\r
-    {\r
-        GetError(0);\r
-        return FALSE;\r
-    }\r
-\r
-    /* get a handle to the service requested for starting */\r
-    hSc = OpenService(hSCManager, Service->lpServiceName, SERVICE_ALL_ACCESS);\r
-    if (hSc == NULL)\r
-    {\r
-        GetError(0);\r
-        return FALSE;\r
-    }\r
-\r
-    /* start the service opened */\r
-    if (! StartService(hSc, ArgCount, NULL))\r
-    {\r
-        GetError(0);\r
-        return FALSE;\r
-    }\r
-\r
-    /* query the state of the service */\r
-    if (! QueryServiceStatusEx(hSc,\r
-                               SC_STATUS_PROCESS_INFO,\r
-                               (LPBYTE)&ServiceStatus,\r
-                               sizeof(SERVICE_STATUS_PROCESS),\r
-                               &BytesNeeded))\r
-    {\r
-        GetError(0);\r
-        return FALSE;\r
-    }\r
-\r
-    /* Save the tick count and initial checkpoint. */\r
-    dwStartTickCount = GetTickCount();\r
-    dwOldCheckPoint = ServiceStatus.dwCheckPoint;\r
-\r
-    /* loop whilst service is not running */\r
-    /* FIXME: needs more control adding. 'Loop' is temparary */\r
-    while (ServiceStatus.dwCurrentState != SERVICE_RUNNING)\r
-    {\r
-        DWORD dwWaitTime;\r
-\r
-        dwWaitTime = ServiceStatus.dwWaitHint / 10;\r
-\r
-        if( dwWaitTime < 500 )\r
-            dwWaitTime = 500;\r
-        else if ( dwWaitTime > 5000 )\r
-            dwWaitTime = 5000;\r
-\r
-        /* increment the progress bar */\r
-        SendMessage(hProgBar, PBM_STEPIT, 0, 0);\r
-\r
-        /* wait before checking status */\r
-        Sleep(ServiceStatus.dwWaitHint / 8);\r
-\r
-        /* check status again */\r
-        if (! QueryServiceStatusEx(\r
-                hSc,\r
-                SC_STATUS_PROCESS_INFO,\r
-                (LPBYTE)&ServiceStatus,\r
-                sizeof(SERVICE_STATUS_PROCESS),\r
-                &BytesNeeded))\r
-        {\r
-            GetError(0);\r
-            return FALSE;\r
-        }\r
-        \r
-        if (ServiceStatus.dwCheckPoint > dwOldCheckPoint)\r
-        {\r
-            /* The service is making progress. increment the progress bar */\r
-            SendMessage(hProgBar, PBM_STEPIT, 0, 0);\r
-            dwStartTickCount = GetTickCount();\r
-            dwOldCheckPoint = ServiceStatus.dwCheckPoint;\r
-        }\r
-        else\r
-        {\r
-            if(GetTickCount() - dwStartTickCount > ServiceStatus.dwWaitHint)\r
-            {\r
-                /* No progress made within the wait hint */\r
-                break;\r
-            }\r
-        }\r
-    }\r
-\r
-    CloseServiceHandle(hSc);\r
-\r
-    if (ServiceStatus.dwCurrentState == SERVICE_RUNNING)\r
-    {\r
-        SendMessage(hProgBar, PBM_DELTAPOS, PROGRESSRANGE, 0);\r
-        Sleep(1000);\r
-        return TRUE;\r
-    }\r
-    else\r
-        return FALSE;\r
-\r
-}\r
-\r
diff --git a/reactos/subsys/system/setup/setup.c b/reactos/subsys/system/setup/setup.c
deleted file mode 100644 (file)
index cf78891..0000000
+++ /dev/null
@@ -1,122 +0,0 @@
-/*
- *  ReactOS kernel
- *  Copyright (C) 2003 ReactOS Team
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- */
-/*
- * COPYRIGHT:       See COPYING in the top level directory
- * PROJECT:         ReactOS GUI/console setup
- * FILE:            subsys/system/setup/setup.c
- * PURPOSE:         Second stage setup
- * PROGRAMMER:      Eric Kohl
- */
-#define WIN32_NO_STATUS
-#include <windows.h>
-#include <tchar.h>
-#include <syssetup/syssetup.h>
-#include <userenv.h>
-#include <tchar.h>
-
-#define NDEBUG
-#include <debug.h>
-
-
-typedef DWORD (STDCALL *PINSTALL_REACTOS)(HINSTANCE hInstance);
-
-
-/* FUNCTIONS ****************************************************************/
-
-LPTSTR lstrchr(LPCTSTR s, TCHAR c)
-{
-  while (*s)
-    {
-      if (*s == c)
-        return (LPTSTR)s;
-      s++;
-    }
-
-  if (c == (TCHAR)0)
-    return (LPTSTR)s;
-
-  return (LPTSTR)NULL;
-}
-
-static VOID
-RunNewSetup (HINSTANCE hInstance)
-{
-  HMODULE hDll;
-  PINSTALL_REACTOS InstallReactOS;
-
-  /* some dlls (loaded by syssetup) need a valid user profile */
-  InitializeProfiles();
-
-  hDll = LoadLibrary (TEXT("syssetup"));
-  if (hDll == NULL)
-    {
-      DPRINT("Failed to load 'syssetup'!\n");
-      return;
-    }
-
-  DPRINT("Loaded 'syssetup'!\n");
-  InstallReactOS = (PINSTALL_REACTOS)GetProcAddress (hDll, "InstallReactOS");
-
-  if (InstallReactOS == NULL)
-    {
-      DPRINT("Failed to get address for 'InstallReactOS()'!\n");
-      FreeLibrary (hDll);
-      return;
-    }
-
-  InstallReactOS (hInstance);
-
-  FreeLibrary (hDll);
-}
-
-
-int STDCALL
-WinMain (HINSTANCE hInstance,
-        HINSTANCE hPrevInstance,
-        LPSTR lpCmdLine,
-        int nShowCmd)
-{
-  LPTSTR CmdLine;
-  LPTSTR p;
-
-  CmdLine = GetCommandLine ();
-
-  DPRINT("CmdLine: <%s>\n",CmdLine);
-
-  p = lstrchr (CmdLine, TEXT('-'));
-  if (p == NULL)
-    return 0;
-
-  if (!lstrcmpi (p, TEXT("-newsetup")))
-    {
-      RunNewSetup (hInstance);
-    }
-
-#if 0
-  /* Add new setup types here */
-  else if (...)
-    {
-
-    }
-#endif
-
-  return 0;
-}
-
-/* EOF */
diff --git a/reactos/subsys/system/setup/setup.rc b/reactos/subsys/system/setup/setup.rc
deleted file mode 100644 (file)
index 23995f1..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-/* $Id$ */
-
-#define REACTOS_STR_FILE_DESCRIPTION   "ReactOS Setup\0"
-#define REACTOS_STR_INTERNAL_NAME      "setup\0"
-#define REACTOS_STR_ORIGINAL_FILENAME  "setup.exe\0"
-#include <reactos/version.rc>
diff --git a/reactos/subsys/system/setup/setup.xml b/reactos/subsys/system/setup/setup.xml
deleted file mode 100644 (file)
index fc77f84..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-<module name="setup" type="win32gui" installbase="system32" installname="setup.exe">
-       <include base="setup">.</include>
-       <define name="__USE_W32API" />
-       <define name="UNICODE" />
-       <define name="_UNICODE" />
-       <define name="_WIN32_IE">0x0400</define>
-       <library>kernel32</library>
-       <library>userenv</library>
-       <file>setup.c</file>
-       <file>setup.rc</file>
-</module>
diff --git a/reactos/subsys/system/winefile/Doxyfile b/reactos/subsys/system/winefile/Doxyfile
deleted file mode 100644 (file)
index 41ba87a..0000000
+++ /dev/null
@@ -1,1213 +0,0 @@
-# Doxyfile 1.4.1
-
-# This file describes the settings to be used by the documentation system
-# doxygen (www.doxygen.org) for a project
-#
-# All text after a hash (#) is considered a comment and will be ignored
-# The format is:
-#       TAG = value [value, ...]
-# For lists items can also be appended using:
-#       TAG += value [value, ...]
-# Values that contain spaces should be placed between quotes (" ")
-
-#---------------------------------------------------------------------------
-# Project related configuration options
-#---------------------------------------------------------------------------
-
-# The PROJECT_NAME tag is a single word (or a sequence of words surrounded 
-# by quotes) that should identify the project.
-
-PROJECT_NAME           = Winefile
-
-# The PROJECT_NUMBER tag can be used to enter a project or revision number. 
-# This could be handy for archiving the generated documentation or 
-# if some version control system is used.
-
-PROJECT_NUMBER         = 
-
-# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) 
-# base path where the generated documentation will be put. 
-# If a relative path is entered, it will be relative to the location 
-# where doxygen was started. If left blank the current directory will be used.
-
-OUTPUT_DIRECTORY       = doxy-doc
-
-# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create 
-# 4096 sub-directories (in 2 levels) under the output directory of each output 
-# format and will distribute the generated files over these directories. 
-# Enabling this option can be useful when feeding doxygen a huge amount of 
-# source files, where putting all generated files in the same directory would 
-# otherwise cause performance problems for the file system.
-
-CREATE_SUBDIRS         = NO
-
-# The OUTPUT_LANGUAGE tag is used to specify the language in which all 
-# documentation generated by doxygen is written. Doxygen will use this 
-# information to generate all constant output in the proper language. 
-# The default language is English, other supported languages are: 
-# Brazilian, Catalan, Chinese, Chinese-Traditional, Croatian, Czech, Danish, 
-# Dutch, Finnish, French, German, Greek, Hungarian, Italian, Japanese, 
-# Japanese-en (Japanese with English messages), Korean, Korean-en, Norwegian, 
-# Polish, Portuguese, Romanian, Russian, Serbian, Slovak, Slovene, Spanish, 
-# Swedish, and Ukrainian.
-
-OUTPUT_LANGUAGE        = English
-
-# This tag can be used to specify the encoding used in the generated output. 
-# The encoding is not always determined by the language that is chosen, 
-# but also whether or not the output is meant for Windows or non-Windows users. 
-# In case there is a difference, setting the USE_WINDOWS_ENCODING tag to YES 
-# forces the Windows encoding (this is the default for the Windows binary), 
-# whereas setting the tag to NO uses a Unix-style encoding (the default for 
-# all platforms other than Windows).
-
-USE_WINDOWS_ENCODING   = YES
-
-# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will 
-# include brief member descriptions after the members that are listed in 
-# the file and class documentation (similar to JavaDoc). 
-# Set to NO to disable this.
-
-BRIEF_MEMBER_DESC      = YES
-
-# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend 
-# the brief description of a member or function before the detailed description. 
-# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the 
-# brief descriptions will be completely suppressed.
-
-REPEAT_BRIEF           = YES
-
-# This tag implements a quasi-intelligent brief description abbreviator 
-# that is used to form the text in various listings. Each string 
-# in this list, if found as the leading text of the brief description, will be 
-# stripped from the text and the result after processing the whole list, is 
-# used as the annotated text. Otherwise, the brief description is used as-is. 
-# If left blank, the following values are used ("$name" is automatically 
-# replaced with the name of the entity): "The $name class" "The $name widget" 
-# "The $name file" "is" "provides" "specifies" "contains" 
-# "represents" "a" "an" "the"
-
-ABBREVIATE_BRIEF       = 
-
-# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then 
-# Doxygen will generate a detailed section even if there is only a brief 
-# description.
-
-ALWAYS_DETAILED_SEC    = NO
-
-# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all 
-# inherited members of a class in the documentation of that class as if those 
-# members were ordinary class members. Constructors, destructors and assignment 
-# operators of the base classes will not be shown.
-
-INLINE_INHERITED_MEMB  = NO
-
-# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full 
-# path before files name in the file list and in the header files. If set 
-# to NO the shortest path that makes the file name unique will be used.
-
-FULL_PATH_NAMES        = NO
-
-# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag 
-# can be used to strip a user-defined part of the path. Stripping is 
-# only done if one of the specified strings matches the left-hand part of 
-# the path. The tag can be used to show relative paths in the file list. 
-# If left blank the directory from which doxygen is run is used as the 
-# path to strip.
-
-STRIP_FROM_PATH        = 
-
-# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of 
-# the path mentioned in the documentation of a class, which tells 
-# the reader which header file to include in order to use a class. 
-# If left blank only the name of the header file containing the class 
-# definition is used. Otherwise one should specify the include paths that 
-# are normally passed to the compiler using the -I flag.
-
-STRIP_FROM_INC_PATH    = 
-
-# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter 
-# (but less readable) file names. This can be useful is your file systems 
-# doesn't support long names like on DOS, Mac, or CD-ROM.
-
-SHORT_NAMES            = NO
-
-# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen 
-# will interpret the first line (until the first dot) of a JavaDoc-style 
-# comment as the brief description. If set to NO, the JavaDoc 
-# comments will behave just like the Qt-style comments (thus requiring an 
-# explicit @brief command for a brief description.
-
-JAVADOC_AUTOBRIEF      = YES
-
-# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen 
-# treat a multi-line C++ special comment block (i.e. a block of //! or /// 
-# comments) as a brief description. This used to be the default behaviour. 
-# The new default is to treat a multi-line C++ comment block as a detailed 
-# description. Set this tag to YES if you prefer the old behaviour instead.
-
-MULTILINE_CPP_IS_BRIEF = NO
-
-# If the DETAILS_AT_TOP tag is set to YES then Doxygen 
-# will output the detailed description near the top, like JavaDoc.
-# If set to NO, the detailed description appears after the member 
-# documentation.
-
-DETAILS_AT_TOP         = NO
-
-# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented 
-# member inherits the documentation from any documented member that it 
-# re-implements.
-
-INHERIT_DOCS           = YES
-
-# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC 
-# tag is set to YES, then doxygen will reuse the documentation of the first 
-# member in the group (if any) for the other members of the group. By default 
-# all members of a group must be documented explicitly.
-
-DISTRIBUTE_GROUP_DOC   = NO
-
-# The TAB_SIZE tag can be used to set the number of spaces in a tab. 
-# Doxygen uses this value to replace tabs by spaces in code fragments.
-
-TAB_SIZE               = 8
-
-# This tag can be used to specify a number of aliases that acts 
-# as commands in the documentation. An alias has the form "name=value". 
-# For example adding "sideeffect=\par Side Effects:\n" will allow you to 
-# put the command \sideeffect (or @sideeffect) in the documentation, which 
-# will result in a user-defined paragraph with heading "Side Effects:". 
-# You can put \n's in the value part of an alias to insert newlines.
-
-ALIASES                = 
-
-# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C 
-# sources only. Doxygen will then generate output that is more tailored for C. 
-# For instance, some of the names that are used will be different. The list 
-# of all members will be omitted, etc.
-
-OPTIMIZE_OUTPUT_FOR_C  = YES
-
-# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java sources 
-# only. Doxygen will then generate output that is more tailored for Java. 
-# For instance, namespaces will be presented as packages, qualified scopes 
-# will look different, etc.
-
-OPTIMIZE_OUTPUT_JAVA   = NO
-
-# Set the SUBGROUPING tag to YES (the default) to allow class member groups of 
-# the same type (for instance a group of public functions) to be put as a 
-# subgroup of that type (e.g. under the Public Functions section). Set it to 
-# NO to prevent subgrouping. Alternatively, this can be done per class using 
-# the \nosubgrouping command.
-
-SUBGROUPING            = YES
-
-#---------------------------------------------------------------------------
-# Build related configuration options
-#---------------------------------------------------------------------------
-
-# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in 
-# documentation are documented, even if no documentation was available. 
-# Private class members and static file members will be hidden unless 
-# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES
-
-EXTRACT_ALL            = YES
-
-# If the EXTRACT_PRIVATE tag is set to YES all private members of a class 
-# will be included in the documentation.
-
-EXTRACT_PRIVATE        = YES
-
-# If the EXTRACT_STATIC tag is set to YES all static members of a file 
-# will be included in the documentation.
-
-EXTRACT_STATIC         = YES
-
-# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) 
-# defined locally in source files will be included in the documentation. 
-# If set to NO only classes defined in header files are included.
-
-EXTRACT_LOCAL_CLASSES  = YES
-
-# This flag is only useful for Objective-C code. When set to YES local 
-# methods, which are defined in the implementation section but not in 
-# the interface are included in the documentation. 
-# If set to NO (the default) only methods in the interface are included.
-
-EXTRACT_LOCAL_METHODS  = NO
-
-# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all 
-# undocumented members of documented classes, files or namespaces. 
-# If set to NO (the default) these members will be included in the 
-# various overviews, but no documentation section is generated. 
-# This option has no effect if EXTRACT_ALL is enabled.
-
-HIDE_UNDOC_MEMBERS     = NO
-
-# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all 
-# undocumented classes that are normally visible in the class hierarchy. 
-# If set to NO (the default) these classes will be included in the various 
-# overviews. This option has no effect if EXTRACT_ALL is enabled.
-
-HIDE_UNDOC_CLASSES     = NO
-
-# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all 
-# friend (class|struct|union) declarations. 
-# If set to NO (the default) these declarations will be included in the 
-# documentation.
-
-HIDE_FRIEND_COMPOUNDS  = NO
-
-# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any 
-# documentation blocks found inside the body of a function. 
-# If set to NO (the default) these blocks will be appended to the 
-# function's detailed documentation block.
-
-HIDE_IN_BODY_DOCS      = NO
-
-# The INTERNAL_DOCS tag determines if documentation 
-# that is typed after a \internal command is included. If the tag is set 
-# to NO (the default) then the documentation will be excluded. 
-# Set it to YES to include the internal documentation.
-
-INTERNAL_DOCS          = NO
-
-# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate 
-# file names in lower-case letters. If set to YES upper-case letters are also 
-# allowed. This is useful if you have classes or files whose names only differ 
-# in case and if your file system supports case sensitive file names. Windows 
-# and Mac users are advised to set this option to NO.
-
-CASE_SENSE_NAMES       = YES
-
-# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen 
-# will show members with their full class and namespace scopes in the 
-# documentation. If set to YES the scope will be hidden.
-
-HIDE_SCOPE_NAMES       = NO
-
-# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen 
-# will put a list of the files that are included by a file in the documentation 
-# of that file.
-
-SHOW_INCLUDE_FILES     = YES
-
-# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] 
-# is inserted in the documentation for inline members.
-
-INLINE_INFO            = YES
-
-# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen 
-# will sort the (detailed) documentation of file and class members 
-# alphabetically by member name. If set to NO the members will appear in 
-# declaration order.
-
-SORT_MEMBER_DOCS       = YES
-
-# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the 
-# brief documentation of file, namespace and class members alphabetically 
-# by member name. If set to NO (the default) the members will appear in 
-# declaration order.
-
-SORT_BRIEF_DOCS        = NO
-
-# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be 
-# sorted by fully-qualified names, including namespaces. If set to 
-# NO (the default), the class list will be sorted only by class name, 
-# not including the namespace part. 
-# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES.
-# Note: This option applies only to the class list, not to the 
-# alphabetical list.
-
-SORT_BY_SCOPE_NAME     = NO
-
-# The GENERATE_TODOLIST tag can be used to enable (YES) or 
-# disable (NO) the todo list. This list is created by putting \todo 
-# commands in the documentation.
-
-GENERATE_TODOLIST      = YES
-
-# The GENERATE_TESTLIST tag can be used to enable (YES) or 
-# disable (NO) the test list. This list is created by putting \test 
-# commands in the documentation.
-
-GENERATE_TESTLIST      = YES
-
-# The GENERATE_BUGLIST tag can be used to enable (YES) or 
-# disable (NO) the bug list. This list is created by putting \bug 
-# commands in the documentation.
-
-GENERATE_BUGLIST       = YES
-
-# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or 
-# disable (NO) the deprecated list. This list is created by putting 
-# \deprecated commands in the documentation.
-
-GENERATE_DEPRECATEDLIST= YES
-
-# The ENABLED_SECTIONS tag can be used to enable conditional 
-# documentation sections, marked by \if sectionname ... \endif.
-
-ENABLED_SECTIONS       = 
-
-# The MAX_INITIALIZER_LINES tag determines the maximum number of lines 
-# the initial value of a variable or define consists of for it to appear in 
-# the documentation. If the initializer consists of more lines than specified 
-# here it will be hidden. Use a value of 0 to hide initializers completely. 
-# The appearance of the initializer of individual variables and defines in the 
-# documentation can be controlled using \showinitializer or \hideinitializer 
-# command in the documentation regardless of this setting.
-
-MAX_INITIALIZER_LINES  = 30
-
-# Set the SHOW_USED_FILES tag to NO to disable the list of files generated 
-# at the bottom of the documentation of classes and structs. If set to YES the 
-# list will mention the files that were used to generate the documentation.
-
-SHOW_USED_FILES        = YES
-
-# If the sources in your project are distributed over multiple directories 
-# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy 
-# in the documentation.
-
-SHOW_DIRECTORIES       = YES
-
-# The FILE_VERSION_FILTER tag can be used to specify a program or script that 
-# doxygen should invoke to get the current version for each file (typically from the 
-# version control system). Doxygen will invoke the program by executing (via 
-# popen()) the command <command> <input-file>, where <command> is the value of 
-# the FILE_VERSION_FILTER tag, and <input-file> is the name of an input file 
-# provided by doxygen. Whatever the progam writes to standard output 
-# is used as the file version. See the manual for examples.
-
-FILE_VERSION_FILTER    = 
-
-#---------------------------------------------------------------------------
-# configuration options related to warning and progress messages
-#---------------------------------------------------------------------------
-
-# The QUIET tag can be used to turn on/off the messages that are generated 
-# by doxygen. Possible values are YES and NO. If left blank NO is used.
-
-QUIET                  = NO
-
-# The WARNINGS tag can be used to turn on/off the warning messages that are 
-# generated by doxygen. Possible values are YES and NO. If left blank 
-# NO is used.
-
-WARNINGS               = NO
-
-# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings 
-# for undocumented members. If EXTRACT_ALL is set to YES then this flag will 
-# automatically be disabled.
-
-WARN_IF_UNDOCUMENTED   = NO
-
-# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for 
-# potential errors in the documentation, such as not documenting some 
-# parameters in a documented function, or documenting parameters that 
-# don't exist or using markup commands wrongly.
-
-WARN_IF_DOC_ERROR      = YES
-
-# This WARN_NO_PARAMDOC option can be abled to get warnings for 
-# functions that are documented, but have no documentation for their parameters 
-# or return value. If set to NO (the default) doxygen will only warn about 
-# wrong or incomplete parameter documentation, but not about the absence of 
-# documentation.
-
-WARN_NO_PARAMDOC       = NO
-
-# The WARN_FORMAT tag determines the format of the warning messages that 
-# doxygen can produce. The string should contain the $file, $line, and $text 
-# tags, which will be replaced by the file and line number from which the 
-# warning originated and the warning text. Optionally the format may contain 
-# $version, which will be replaced by the version of the file (if it could 
-# be obtained via FILE_VERSION_FILTER)
-
-WARN_FORMAT            = "$file:$line: $text"
-
-# The WARN_LOGFILE tag can be used to specify a file to which warning 
-# and error messages should be written. If left blank the output is written 
-# to stderr.
-
-WARN_LOGFILE           = 
-
-#---------------------------------------------------------------------------
-# configuration options related to the input files
-#---------------------------------------------------------------------------
-
-# The INPUT tag can be used to specify the files and/or directories that contain 
-# documented source files. You may enter file names like "myfile.cpp" or 
-# directories like "/usr/src/myproject". Separate the files or directories 
-# with spaces.
-
-INPUT                  = .
-
-# If the value of the INPUT tag contains directories, you can use the 
-# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp 
-# and *.h) to filter out the source-files in the directories. If left 
-# blank the following patterns are tested: 
-# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx 
-# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm
-
-FILE_PATTERNS          = *.c \
-                         *.h
-
-# The RECURSIVE tag can be used to turn specify whether or not subdirectories 
-# should be searched for input files as well. Possible values are YES and NO. 
-# If left blank NO is used.
-
-RECURSIVE              = YES
-
-# The EXCLUDE tag can be used to specify files and/or directories that should 
-# excluded from the INPUT source files. This way you can easily exclude a 
-# subdirectory from a directory tree whose root is specified with the INPUT tag.
-
-EXCLUDE                = 
-
-# The EXCLUDE_SYMLINKS tag can be used select whether or not files or 
-# directories that are symbolic links (a Unix filesystem feature) are excluded 
-# from the input.
-
-EXCLUDE_SYMLINKS       = NO
-
-# If the value of the INPUT tag contains directories, you can use the 
-# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude 
-# certain files from those directories.
-
-EXCLUDE_PATTERNS       = 
-
-# The EXAMPLE_PATH tag can be used to specify one or more files or 
-# directories that contain example code fragments that are included (see 
-# the \include command).
-
-EXAMPLE_PATH           = 
-
-# If the value of the EXAMPLE_PATH tag contains directories, you can use the 
-# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp 
-# and *.h) to filter out the source-files in the directories. If left 
-# blank all files are included.
-
-EXAMPLE_PATTERNS       = 
-
-# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be 
-# searched for input files to be used with the \include or \dontinclude 
-# commands irrespective of the value of the RECURSIVE tag. 
-# Possible values are YES and NO. If left blank NO is used.
-
-EXAMPLE_RECURSIVE      = NO
-
-# The IMAGE_PATH tag can be used to specify one or more files or 
-# directories that contain image that are included in the documentation (see 
-# the \image command).
-
-IMAGE_PATH             = 
-
-# The INPUT_FILTER tag can be used to specify a program that doxygen should 
-# invoke to filter for each input file. Doxygen will invoke the filter program 
-# by executing (via popen()) the command <filter> <input-file>, where <filter> 
-# is the value of the INPUT_FILTER tag, and <input-file> is the name of an 
-# input file. Doxygen will then use the output that the filter program writes 
-# to standard output.  If FILTER_PATTERNS is specified, this tag will be 
-# ignored.
-
-INPUT_FILTER           = 
-
-# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern 
-# basis.  Doxygen will compare the file name with each pattern and apply the 
-# filter if there is a match.  The filters are a list of the form: 
-# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further 
-# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER 
-# is applied to all files.
-
-FILTER_PATTERNS        = 
-
-# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using 
-# INPUT_FILTER) will be used to filter the input files when producing source 
-# files to browse (i.e. when SOURCE_BROWSER is set to YES).
-
-FILTER_SOURCE_FILES    = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to source browsing
-#---------------------------------------------------------------------------
-
-# If the SOURCE_BROWSER tag is set to YES then a list of source files will 
-# be generated. Documented entities will be cross-referenced with these sources. 
-# Note: To get rid of all source code in the generated output, make sure also 
-# VERBATIM_HEADERS is set to NO.
-
-SOURCE_BROWSER         = YES
-
-# Setting the INLINE_SOURCES tag to YES will include the body 
-# of functions and classes directly in the documentation.
-
-INLINE_SOURCES         = YES
-
-# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct 
-# doxygen to hide any special comment blocks from generated source code 
-# fragments. Normal C and C++ comments will always remain visible.
-
-STRIP_CODE_COMMENTS    = YES
-
-# If the REFERENCED_BY_RELATION tag is set to YES (the default) 
-# then for each documented function all documented 
-# functions referencing it will be listed.
-
-REFERENCED_BY_RELATION = YES
-
-# If the REFERENCES_RELATION tag is set to YES (the default) 
-# then for each documented function all documented entities 
-# called/used by that function will be listed.
-
-REFERENCES_RELATION    = YES
-
-# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen 
-# will generate a verbatim copy of the header file for each class for 
-# which an include is specified. Set to NO to disable this.
-
-VERBATIM_HEADERS       = YES
-
-#---------------------------------------------------------------------------
-# configuration options related to the alphabetical class index
-#---------------------------------------------------------------------------
-
-# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index 
-# of all compounds will be generated. Enable this if the project 
-# contains a lot of classes, structs, unions or interfaces.
-
-ALPHABETICAL_INDEX     = YES
-
-# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then 
-# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns 
-# in which this list will be split (can be a number in the range [1..20])
-
-COLS_IN_ALPHA_INDEX    = 5
-
-# In case all classes in a project start with a common prefix, all 
-# classes will be put under the same header in the alphabetical index. 
-# The IGNORE_PREFIX tag can be used to specify one or more prefixes that 
-# should be ignored while generating the index headers.
-
-IGNORE_PREFIX          = 
-
-#---------------------------------------------------------------------------
-# configuration options related to the HTML output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_HTML tag is set to YES (the default) Doxygen will 
-# generate HTML output.
-
-GENERATE_HTML          = YES
-
-# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `html' will be used as the default path.
-
-HTML_OUTPUT            = html
-
-# The HTML_FILE_EXTENSION tag can be used to specify the file extension for 
-# each generated HTML page (for example: .htm,.php,.asp). If it is left blank 
-# doxygen will generate files with .html extension.
-
-HTML_FILE_EXTENSION    = .html
-
-# The HTML_HEADER tag can be used to specify a personal HTML header for 
-# each generated HTML page. If it is left blank doxygen will generate a 
-# standard header.
-
-HTML_HEADER            = 
-
-# The HTML_FOOTER tag can be used to specify a personal HTML footer for 
-# each generated HTML page. If it is left blank doxygen will generate a 
-# standard footer.
-
-HTML_FOOTER            = doxy-footer.html
-
-# The HTML_STYLESHEET tag can be used to specify a user-defined cascading 
-# style sheet that is used by each HTML page. It can be used to 
-# fine-tune the look of the HTML output. If the tag is left blank doxygen 
-# will generate a default style sheet. Note that doxygen will try to copy 
-# the style sheet file to the HTML output directory, so don't put your own 
-# stylesheet in the HTML output directory as well, or it will be erased!
-
-HTML_STYLESHEET        = 
-
-# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, 
-# files or namespaces will be aligned in HTML using tables. If set to 
-# NO a bullet list will be used.
-
-HTML_ALIGN_MEMBERS     = YES
-
-# If the GENERATE_HTMLHELP tag is set to YES, additional index files 
-# will be generated that can be used as input for tools like the 
-# Microsoft HTML help workshop to generate a compressed HTML help file (.chm) 
-# of the generated HTML documentation.
-
-GENERATE_HTMLHELP      = YES
-
-# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can 
-# be used to specify the file name of the resulting .chm file. You 
-# can add a path in front of the file if the result should not be 
-# written to the html output directory.
-
-CHM_FILE               = 
-
-# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can 
-# be used to specify the location (absolute path including file name) of 
-# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run 
-# the HTML help compiler on the generated index.hhp.
-
-HHC_LOCATION           = 
-
-# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag 
-# controls if a separate .chi index file is generated (YES) or that 
-# it should be included in the master .chm file (NO).
-
-GENERATE_CHI           = NO
-
-# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag 
-# controls whether a binary table of contents is generated (YES) or a 
-# normal table of contents (NO) in the .chm file.
-
-BINARY_TOC             = NO
-
-# The TOC_EXPAND flag can be set to YES to add extra items for group members 
-# to the contents of the HTML help documentation and to the tree view.
-
-TOC_EXPAND             = NO
-
-# The DISABLE_INDEX tag can be used to turn on/off the condensed index at 
-# top of each HTML page. The value NO (the default) enables the index and 
-# the value YES disables it.
-
-DISABLE_INDEX          = NO
-
-# This tag can be used to set the number of enum values (range [1..20]) 
-# that doxygen will group on one line in the generated HTML documentation.
-
-ENUM_VALUES_PER_LINE   = 4
-
-# If the GENERATE_TREEVIEW tag is set to YES, a side panel will be
-# generated containing a tree-like index structure (just like the one that 
-# is generated for HTML Help). For this to work a browser that supports 
-# JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+, 
-# Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are 
-# probably better off using the HTML help feature.
-
-GENERATE_TREEVIEW      = YES
-
-# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be 
-# used to set the initial width (in pixels) of the frame in which the tree 
-# is shown.
-
-TREEVIEW_WIDTH         = 240
-
-#---------------------------------------------------------------------------
-# configuration options related to the LaTeX output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will 
-# generate Latex output.
-
-GENERATE_LATEX         = NO
-
-# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `latex' will be used as the default path.
-
-LATEX_OUTPUT           = latex
-
-# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be 
-# invoked. If left blank `latex' will be used as the default command name.
-
-LATEX_CMD_NAME         = latex
-
-# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to 
-# generate index for LaTeX. If left blank `makeindex' will be used as the 
-# default command name.
-
-MAKEINDEX_CMD_NAME     = makeindex
-
-# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact 
-# LaTeX documents. This may be useful for small projects and may help to 
-# save some trees in general.
-
-COMPACT_LATEX          = NO
-
-# The PAPER_TYPE tag can be used to set the paper type that is used 
-# by the printer. Possible values are: a4, a4wide, letter, legal and 
-# executive. If left blank a4wide will be used.
-
-PAPER_TYPE             = a4wide
-
-# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX 
-# packages that should be included in the LaTeX output.
-
-EXTRA_PACKAGES         = 
-
-# The LATEX_HEADER tag can be used to specify a personal LaTeX header for 
-# the generated latex document. The header should contain everything until 
-# the first chapter. If it is left blank doxygen will generate a 
-# standard header. Notice: only use this tag if you know what you are doing!
-
-LATEX_HEADER           = 
-
-# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated 
-# is prepared for conversion to pdf (using ps2pdf). The pdf file will 
-# contain links (just like the HTML output) instead of page references 
-# This makes the output suitable for online browsing using a pdf viewer.
-
-PDF_HYPERLINKS         = NO
-
-# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of 
-# plain latex in the generated Makefile. Set this option to YES to get a 
-# higher quality PDF documentation.
-
-USE_PDFLATEX           = NO
-
-# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. 
-# command to the generated LaTeX files. This will instruct LaTeX to keep 
-# running if errors occur, instead of asking the user for help. 
-# This option is also used when generating formulas in HTML.
-
-LATEX_BATCHMODE        = NO
-
-# If LATEX_HIDE_INDICES is set to YES then doxygen will not 
-# include the index chapters (such as File Index, Compound Index, etc.) 
-# in the output.
-
-LATEX_HIDE_INDICES     = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the RTF output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output 
-# The RTF output is optimized for Word 97 and may not look very pretty with 
-# other RTF readers or editors.
-
-GENERATE_RTF           = NO
-
-# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `rtf' will be used as the default path.
-
-RTF_OUTPUT             = rtf
-
-# If the COMPACT_RTF tag is set to YES Doxygen generates more compact 
-# RTF documents. This may be useful for small projects and may help to 
-# save some trees in general.
-
-COMPACT_RTF            = YES
-
-# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated 
-# will contain hyperlink fields. The RTF file will 
-# contain links (just like the HTML output) instead of page references. 
-# This makes the output suitable for online browsing using WORD or other 
-# programs which support those fields. 
-# Note: wordpad (write) and others do not support links.
-
-RTF_HYPERLINKS         = YES
-
-# Load stylesheet definitions from file. Syntax is similar to doxygen's 
-# config file, i.e. a series of assignments. You only have to provide 
-# replacements, missing definitions are set to their default value.
-
-RTF_STYLESHEET_FILE    = 
-
-# Set optional variables used in the generation of an rtf document. 
-# Syntax is similar to doxygen's config file.
-
-RTF_EXTENSIONS_FILE    = 
-
-#---------------------------------------------------------------------------
-# configuration options related to the man page output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_MAN tag is set to YES (the default) Doxygen will 
-# generate man pages
-
-GENERATE_MAN           = NO
-
-# The MAN_OUTPUT tag is used to specify where the man pages will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `man' will be used as the default path.
-
-MAN_OUTPUT             = man
-
-# The MAN_EXTENSION tag determines the extension that is added to 
-# the generated man pages (default is the subroutine's section .3)
-
-MAN_EXTENSION          = .3
-
-# If the MAN_LINKS tag is set to YES and Doxygen generates man output, 
-# then it will generate one additional man file for each entity 
-# documented in the real man page(s). These additional files 
-# only source the real man page, but without them the man command 
-# would be unable to find the correct page. The default is NO.
-
-MAN_LINKS              = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the XML output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_XML tag is set to YES Doxygen will 
-# generate an XML file that captures the structure of 
-# the code including all documentation.
-
-GENERATE_XML           = NO
-
-# The XML_OUTPUT tag is used to specify where the XML pages will be put. 
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be 
-# put in front of it. If left blank `xml' will be used as the default path.
-
-XML_OUTPUT             = xml
-
-# The XML_SCHEMA tag can be used to specify an XML schema, 
-# which can be used by a validating XML parser to check the 
-# syntax of the XML files.
-
-XML_SCHEMA             = 
-
-# The XML_DTD tag can be used to specify an XML DTD, 
-# which can be used by a validating XML parser to check the 
-# syntax of the XML files.
-
-XML_DTD                = 
-
-# If the XML_PROGRAMLISTING tag is set to YES Doxygen will 
-# dump the program listings (including syntax highlighting 
-# and cross-referencing information) to the XML output. Note that 
-# enabling this will significantly increase the size of the XML output.
-
-XML_PROGRAMLISTING     = YES
-
-#---------------------------------------------------------------------------
-# configuration options for the AutoGen Definitions output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will 
-# generate an AutoGen Definitions (see autogen.sf.net) file 
-# that captures the structure of the code including all 
-# documentation. Note that this feature is still experimental 
-# and incomplete at the moment.
-
-GENERATE_AUTOGEN_DEF   = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the Perl module output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_PERLMOD tag is set to YES Doxygen will 
-# generate a Perl module file that captures the structure of 
-# the code including all documentation. Note that this 
-# feature is still experimental and incomplete at the 
-# moment.
-
-GENERATE_PERLMOD       = NO
-
-# If the PERLMOD_LATEX tag is set to YES Doxygen will generate 
-# the necessary Makefile rules, Perl scripts and LaTeX code to be able 
-# to generate PDF and DVI output from the Perl module output.
-
-PERLMOD_LATEX          = NO
-
-# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be 
-# nicely formatted so it can be parsed by a human reader.  This is useful 
-# if you want to understand what is going on.  On the other hand, if this 
-# tag is set to NO the size of the Perl module output will be much smaller 
-# and Perl will parse it just the same.
-
-PERLMOD_PRETTY         = YES
-
-# The names of the make variables in the generated doxyrules.make file 
-# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. 
-# This is useful so different doxyrules.make files included by the same 
-# Makefile don't overwrite each other's variables.
-
-PERLMOD_MAKEVAR_PREFIX = 
-
-#---------------------------------------------------------------------------
-# Configuration options related to the preprocessor   
-#---------------------------------------------------------------------------
-
-# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will 
-# evaluate all C-preprocessor directives found in the sources and include 
-# files.
-
-ENABLE_PREPROCESSING   = YES
-
-# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro 
-# names in the source code. If set to NO (the default) only conditional 
-# compilation will be performed. Macro expansion can be done in a controlled 
-# way by setting EXPAND_ONLY_PREDEF to YES.
-
-MACRO_EXPANSION        = NO
-
-# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES 
-# then the macro expansion is limited to the macros specified with the 
-# PREDEFINED and EXPAND_AS_PREDEFINED tags.
-
-EXPAND_ONLY_PREDEF     = NO
-
-# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files 
-# in the INCLUDE_PATH (see below) will be search if a #include is found.
-
-SEARCH_INCLUDES        = YES
-
-# The INCLUDE_PATH tag can be used to specify one or more directories that 
-# contain include files that are not input files but should be processed by 
-# the preprocessor.
-
-INCLUDE_PATH           = 
-
-# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard 
-# patterns (like *.h and *.hpp) to filter out the header-files in the 
-# directories. If left blank, the patterns specified with FILE_PATTERNS will 
-# be used.
-
-INCLUDE_FILE_PATTERNS  = 
-
-# The PREDEFINED tag can be used to specify one or more macro names that 
-# are defined before the preprocessor is started (similar to the -D option of 
-# gcc). The argument of the tag is a list of macros of the form: name 
-# or name=definition (no spaces). If the definition and the = are 
-# omitted =1 is assumed. To prevent a macro definition from being 
-# undefined via #undef or recursively expanded use the := operator 
-# instead of the = operator.
-
-PREDEFINED             = 
-
-# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then 
-# this tag can be used to specify a list of macro names that should be expanded. 
-# The macro definition that is found in the sources will be used. 
-# Use the PREDEFINED tag if you want to use a different macro definition.
-
-EXPAND_AS_DEFINED      = 
-
-# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then 
-# doxygen's preprocessor will remove all function-like macros that are alone 
-# on a line, have an all uppercase name, and do not end with a semicolon. Such 
-# function macros are typically used for boiler-plate code, and will confuse 
-# the parser if not removed.
-
-SKIP_FUNCTION_MACROS   = YES
-
-#---------------------------------------------------------------------------
-# Configuration::additions related to external references   
-#---------------------------------------------------------------------------
-
-# The TAGFILES option can be used to specify one or more tagfiles. 
-# Optionally an initial location of the external documentation 
-# can be added for each tagfile. The format of a tag file without 
-# this location is as follows: 
-#   TAGFILES = file1 file2 ... 
-# Adding location for the tag files is done as follows: 
-#   TAGFILES = file1=loc1 "file2 = loc2" ... 
-# where "loc1" and "loc2" can be relative or absolute paths or 
-# URLs. If a location is present for each tag, the installdox tool 
-# does not have to be run to correct the links.
-# Note that each tag file must have a unique name
-# (where the name does NOT include the path)
-# If a tag file is not located in the directory in which doxygen 
-# is run, you must also specify the path to the tagfile here.
-
-TAGFILES               = 
-
-# When a file name is specified after GENERATE_TAGFILE, doxygen will create 
-# a tag file that is based on the input files it reads.
-
-GENERATE_TAGFILE       = 
-
-# If the ALLEXTERNALS tag is set to YES all external classes will be listed 
-# in the class index. If set to NO only the inherited external classes 
-# will be listed.
-
-ALLEXTERNALS           = NO
-
-# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed 
-# in the modules index. If set to NO, only the current project's groups will 
-# be listed.
-
-EXTERNAL_GROUPS        = YES
-
-# The PERL_PATH should be the absolute path and name of the perl script 
-# interpreter (i.e. the result of `which perl').
-
-PERL_PATH              = /usr/bin/perl
-
-#---------------------------------------------------------------------------
-# Configuration options related to the dot tool   
-#---------------------------------------------------------------------------
-
-# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will 
-# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base 
-# or super classes. Setting the tag to NO turns the diagrams off. Note that 
-# this option is superseded by the HAVE_DOT option below. This is only a 
-# fallback. It is recommended to install and use dot, since it yields more 
-# powerful graphs.
-
-CLASS_DIAGRAMS         = YES
-
-# If set to YES, the inheritance and collaboration graphs will hide 
-# inheritance and usage relations if the target is undocumented 
-# or is not a class.
-
-HIDE_UNDOC_RELATIONS   = NO
-
-# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is 
-# available from the path. This tool is part of Graphviz, a graph visualization 
-# toolkit from AT&T and Lucent Bell Labs. The other options in this section 
-# have no effect if this option is set to NO (the default)
-
-HAVE_DOT               = YES
-
-# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen 
-# will generate a graph for each documented class showing the direct and 
-# indirect inheritance relations. Setting this tag to YES will force the 
-# the CLASS_DIAGRAMS tag to NO.
-
-CLASS_GRAPH            = YES
-
-# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen 
-# will generate a graph for each documented class showing the direct and 
-# indirect implementation dependencies (inheritance, containment, and 
-# class references variables) of the class with other documented classes.
-
-COLLABORATION_GRAPH    = YES
-
-# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen 
-# will generate a graph for groups, showing the direct groups dependencies
-
-GROUP_GRAPHS           = YES
-
-# If the UML_LOOK tag is set to YES doxygen will generate inheritance and 
-# collaboration diagrams in a style similar to the OMG's Unified Modeling 
-# Language.
-
-UML_LOOK               = NO
-
-# If set to YES, the inheritance and collaboration graphs will show the 
-# relations between templates and their instances.
-
-TEMPLATE_RELATIONS     = NO
-
-# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT 
-# tags are set to YES then doxygen will generate a graph for each documented 
-# file showing the direct and indirect include dependencies of the file with 
-# other documented files.
-
-INCLUDE_GRAPH          = YES
-
-# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and 
-# HAVE_DOT tags are set to YES then doxygen will generate a graph for each 
-# documented header file showing the documented files that directly or 
-# indirectly include this file.
-
-INCLUDED_BY_GRAPH      = YES
-
-# If the CALL_GRAPH and HAVE_DOT tags are set to YES then doxygen will 
-# generate a call dependency graph for every global function or class method. 
-# Note that enabling this option will significantly increase the time of a run. 
-# So in most cases it will be better to enable call graphs for selected 
-# functions only using the \callgraph command.
-
-CALL_GRAPH             = YES
-
-# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen 
-# will graphical hierarchy of all classes instead of a textual one.
-
-GRAPHICAL_HIERARCHY    = YES
-
-# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES 
-# then doxygen will show the dependencies a directory has on other directories 
-# in a graphical way. The dependency relations are determined by the #include
-# relations between the files in the directories.
-
-DIRECTORY_GRAPH        = YES
-
-# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images 
-# generated by dot. Possible values are png, jpg, or gif
-# If left blank png will be used.
-
-DOT_IMAGE_FORMAT       = png
-
-# The tag DOT_PATH can be used to specify the path where the dot tool can be 
-# found. If left blank, it is assumed the dot tool can be found in the path.
-
-DOT_PATH               = 
-
-# The DOTFILE_DIRS tag can be used to specify one or more directories that 
-# contain dot files that are included in the documentation (see the 
-# \dotfile command).
-
-DOTFILE_DIRS           = 
-
-# The MAX_DOT_GRAPH_WIDTH tag can be used to set the maximum allowed width 
-# (in pixels) of the graphs generated by dot. If a graph becomes larger than 
-# this value, doxygen will try to truncate the graph, so that it fits within 
-# the specified constraint. Beware that most browsers cannot cope with very 
-# large images.
-
-MAX_DOT_GRAPH_WIDTH    = 1024
-
-# The MAX_DOT_GRAPH_HEIGHT tag can be used to set the maximum allows height 
-# (in pixels) of the graphs generated by dot. If a graph becomes larger than 
-# this value, doxygen will try to truncate the graph, so that it fits within 
-# the specified constraint. Beware that most browsers cannot cope with very 
-# large images.
-
-MAX_DOT_GRAPH_HEIGHT   = 1024
-
-# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the 
-# graphs generated by dot. A depth value of 3 means that only nodes reachable 
-# from the root by following a path via at most 3 edges will be shown. Nodes 
-# that lay further from the root node will be omitted. Note that setting this 
-# option to 1 or 2 may greatly reduce the computation time needed for large 
-# code bases. Also note that a graph may be further truncated if the graph's 
-# image dimensions are not sufficient to fit the graph (see MAX_DOT_GRAPH_WIDTH 
-# and MAX_DOT_GRAPH_HEIGHT). If 0 is used for the depth value (the default), 
-# the graph is not depth-constrained.
-
-MAX_DOT_GRAPH_DEPTH    = 0
-
-# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent 
-# background. This is disabled by default, which results in a white background. 
-# Warning: Depending on the platform used, enabling this option may lead to 
-# badly anti-aliased labels on the edges of a graph (i.e. they become hard to 
-# read).
-
-DOT_TRANSPARENT        = NO
-
-# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output 
-# files in one run (i.e. multiple -o and -T options on the command line). This 
-# makes dot run faster, but since only newer versions of dot (>1.8.10) 
-# support this, this feature is disabled by default.
-
-DOT_MULTI_TARGETS      = NO
-
-# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will 
-# generate a legend page explaining the meaning of the various boxes and 
-# arrows in the dot generated graphs.
-
-GENERATE_LEGEND        = YES
-
-# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will 
-# remove the intermediate dot files that are used to generate 
-# the various graphs.
-
-DOT_CLEANUP            = YES
-
-#---------------------------------------------------------------------------
-# Configuration::additions related to the search engine   
-#---------------------------------------------------------------------------
-
-# The SEARCHENGINE tag specifies whether or not a search engine should be 
-# used. If set to NO the values of all tags below this one will be ignored.
-
-SEARCHENGINE           = YES
diff --git a/reactos/subsys/system/winefile/Makefile.MinGW b/reactos/subsys/system/winefile/Makefile.MinGW
deleted file mode 100644 (file)
index b0ac8fd..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-#
-#  Winefile Makefile for MinGW
-#
-
-CC = gcc
-LD = gcc
-
-CFLAGS = -D_WIN32_IE=0x0501 -D_WIN32_WINNT=0x0501
-RCFLAGS        = -D__WINDRES__
-LFLAGS = -Wl,--subsystem,windows
-
-ifdef DEBUG
-CFLAGS += -D_DEBUG -g
-RCFLAGS        += -D_DEBUG
-LFLAGS += -g
-else
-CFLAGS += -DNDEBUG -Os
-RCFLAGS        += -DNDEBUG
-LFLAGS += -s
-endif
-
-ifndef UNICODE
-UNICODE = 1
-endif
-
-ifeq ($(UNICODE),1)
-CFLAGS += -DUNICODE
-#LFLAGS        += -Wl,--entry,_wWinMain@16
-RCFLAGS += -DUNICODE
-endif
-
-CXXFLAGS = $(CFLAGS)
-
-EXEC_SUFFIX = .exe
-RES_SUFFIX = .coff
-
-PROGRAM = winefile
-
-OBJECTS = winefile.o
-
-LIBS = uuid user32 gdi32 advapi32 comctl32 shell32 comdlg32 ole32 version mpr
-
-DELAYIMPORTS = 
-
-TARGET = $(PROGRAM)$(EXEC_SUFFIX)
-
-all: $(TARGET)
-
-$(TARGET): $(OBJECTS) $(PROGRAM)$(RES_SUFFIX)
-       $(LD) $(LFLAGS) -o $@ $^ $(addprefix -l,$(LIBS)) $(addprefix -l,$(DELAYIMPORTS))
-
-$(PROGRAM)$(RES_SUFFIX): $(PROGRAM).rc *.bmp *.ico
-       windres $(RCFLAGS) -o $@ $(PROGRAM).rc
-
-clean:
-       rm -f $(TARGET) $(OBJECTS) $(PROGRAM)$(RES_SUFFIX)
diff --git a/reactos/subsys/system/winefile/Sv.rc b/reactos/subsys/system/winefile/Sv.rc
deleted file mode 100644 (file)
index 99984cf..0000000
+++ /dev/null
@@ -1,209 +0,0 @@
-/*\r
- * WineFile\r
- * Swedish Language Support\r
- *\r
- * Copyright 2005 David Nordenberg\r
- *\r
- * This library is free software; you can redistribute it and/or\r
- * modify it under the terms of the GNU Lesser General Public\r
- * License as published by the Free Software Foundation; either\r
- * version 2.1 of the License, or (at your option) any later version.\r
- *\r
- * This library is distributed in the hope that it will be useful,\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU\r
- * Lesser General Public License for more details.\r
- *\r
- * You should have received a copy of the GNU Lesser General Public\r
- * License along with this library; if not, write to the Free Software\r
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA\r
- */\r
-\r
-LANGUAGE LANG_SWEDISH, SUBLANG_NEUTRAL\r
-#pragma code_page(1252)\r
-\r
-\r
-/* Menu */\r
-\r
-\r
-IDM_WINEFILE MENU FIXED IMPURE\r
-{\r
-    POPUP "&Arkiv" {\r
-        MENUITEM "&Öppna\tEnter",               ID_ACTIVATE\r
-        MENUITEM "&Flytta...\tF7",              ID_FILE_MOVE\r
-        MENUITEM "&Kopiera...\tF8",             ID_FILE_COPY\r
-        MENUITEM "&I urklipp...\tF9",           118\r
-        MENUITEM "&Ta bort\tDel",               ID_FILE_DELETE\r
-        MENUITEM "&Byt namn...",                109\r
-        MENUITEM "&Egenskaper...\tAlt+Enter",   ID_EDIT_PROPERTIES\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Komprimera...",              119\r
-        MENUITEM "Packa &upp...",               120\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Kör...",                     ID_EXECUTE\r
-        MENUITEM "&Skriv ut...",                102\r
-        MENUITEM "Associera...",                103\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Skapa mapp...",               111\r
-        MENUITEM "&Sök...",                     104\r
-        MENUITEM "&Välj filer...",              116\r
-        MENUITEM SEPARATOR\r
-#ifndef _NO_EXTENSIONS\r
-        MENUITEM "&Avsluta\tAlt+X",             ID_FILE_EXIT\r
-#else\r
-        MENUITEM "&Avsluta",                    ID_FILE_EXIT\r
-#endif\r
-    }\r
-\r
-    POPUP "&Disk" {\r
-        MENUITEM "&Kopiera disk...",            201\r
-        MENUITEM "&Namnge disk...",             202\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Formatera disk...",          ID_FORMAT_DISK\r
-#ifdef _WIN95\r
-        MENUITEM "&Skapa systemdisk...", -1 /*TODO*/\r
-#endif\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Anslut &Nätverksenhet",       ID_CONNECT_NETWORK_DRIVE\r
-        MENUITEM "&Koppla ifrån Nätverksenhet", ID_DISCONNECT_NETWORK_DRIVE\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Dela ut...",                  254\r
-        MENUITEM "&Ta bort utdelning...",       255\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Välj enhet...",              251\r
-    }\r
-\r
-    POPUP "&Träd" {\r
-        MENUITEM "&Nästa nivå\t+",              301\r
-        MENUITEM "Utöka &träd\t*",              302\r
-        MENUITEM "Utöka &alla\tCtrl+*",         303\r
-        MENUITEM "Kollapsa &träd\t-",           304\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Markera undermappar",        505\r
-    }\r
-\r
-    POPUP "&Visa" {\r
-        MENUITEM "&Träd och mapp",              413\r
-        MENUITEM "Bara tr&äd",                  411\r
-        MENUITEM "Bara &mapp",                  412\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "De&la",                       ID_VIEW_SPLIT\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Namn",                       ID_VIEW_NAME\r
-        MENUITEM "&Alla Fildetaljer",           ID_VIEW_ALL_ATTRIBUTES, CHECKED\r
-        MENUITEM "&Vissa detaljer...",          ID_VIEW_SELECTED_ATTRIBUTES\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Sortera efter namn",         ID_VIEW_SORT_NAME\r
-        MENUITEM "Sortera efter t&yp",          ID_VIEW_SORT_TYPE\r
-        MENUITEM "Sortera efter st&orlek",      ID_VIEW_SORT_SIZE\r
-        MENUITEM "Sortera efter &datum",        ID_VIEW_SORT_DATE\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Sortera efter &...",          ID_VIEW_FILTER\r
-    }\r
-\r
-    POPUP "&Inställningar" {\r
-        MENUITEM "&Bekräftelse...",             501\r
-        MENUITEM "&Teckensnitt...",             ID_SELECT_FONT\r
-        MENUITEM "&Konfigurera verktygsfält...", 512\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Verktygsfält",               ID_VIEW_TOOL_BAR, CHECKED\r
-        MENUITEM "&Enhetsfält",                 ID_VIEW_DRIVE_BAR, CHECKED\r
-        MENUITEM "St&atusfält",                 ID_VIEW_STATUSBAR, CHECKED\r
-#ifndef _NO_EXTENSIONS\r
-        MENUITEM "F&ullskärm\tCtrl+Shift+S",    ID_VIEW_FULLSCREEN\r
-#endif\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Minimera vid körning",       504\r
-        MENUITEM "&Spara ändringar vid stängning", 511\r
-    }\r
-\r
-    POPUP "&Säkerhet" {\r
-        MENUITEM "&Åtkomst...",                 605\r
-        MENUITEM "&Loggning...",                606\r
-        MENUITEM "&Ägare...",                   607\r
-    }\r
-\r
-    POPUP "&Fönster" {\r
-        MENUITEM "Nytt &fönster",               ID_WINDOW_NEW\r
-        MENUITEM "Överlappande\tCtrl+F5",       ID_WINDOW_CASCADE\r
-        MENUITEM "Ordna &horizontellt",         ID_WINDOW_TILE_HORZ\r
-        MENUITEM "Ordna &vertikalt\tCtrl+F4",   ID_WINDOW_TILE_VERT\r
-#ifndef _NO_EXTENSIONS\r
-        MENUITEM "Ordna automatiskt",           ID_WINDOW_AUTOSORT\r
-#endif\r
-        MENUITEM "Ordna &symboler",             ID_WINDOW_ARRANGE\r
-        MENUITEM "&Uppdatera\tF5",              ID_REFRESH\r
-    }\r
-\r
-    POPUP "&?" {\r
-        MENUITEM "&Hjälpavsnitt\tF1",           ID_HELP\r
-        MENUITEM "Hjälp &sök...\tF1",           ID_HELP\r
-        MENUITEM "&Använda hjälpen\tF1",        ID_HELP_USING\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Information om &Winefile...", ID_ABOUT\r
-#ifdef __WINE__\r
-        MENUITEM "Info about &Wine...",         ID_ABOUT_WINE\r
-#endif\r
-    }\r
-}\r
-\r
-\r
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63\r
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "Kör"\r
-FONT 8, "MS Shell Dlg"\r
-{\r
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10\r
-    CONTROL         "&Kommando:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10\r
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL\r
-    CONTROL         "Som &symbol", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12\r
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14\r
-    PUSHBUTTON      "Avbryt", 2, 158, 23, 47, 14\r
-    PUSHBUTTON      "&Hjälp", 254, 158, 43, 47, 14\r
-}\r
-\r
-IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63\r
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "Välj mål"\r
-FONT 8, "MS Shell Dlg"\r
-{\r
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10\r
-    CONTROL         "&Sökväg:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10\r
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL\r
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14\r
-    PUSHBUTTON      "Avbryt", 2, 158, 23, 47, 14\r
-    PUSHBUTTON      "&Bläddra", 254, 158, 43, 47, 14\r
-}\r
-\r
-STRINGTABLE\r
-{\r
-    IDS_FONT_SEL_DLG_NAME   "Verkställ teckensnittsinställningar"\r
-    IDS_FONT_SEL_ERROR      "Ett fel uppstog när ett nytt teckensnitt valdes."\r
-}\r
-\r
-STRINGTABLE\r
-{\r
-    IDS_WINEFILE            "Winefile"\r
-    IDS_ERROR               "Fel"\r
-    IDS_ROOT_FS             "root fs"\r
-    IDS_UNIXFS              "unixfs"\r
-    IDS_DESKTOP             "Skrivbord"\r
-    IDS_SHELL               "Skal"\r
-    IDS_TITLEFMT            "%s - %s"\r
-    IDS_NO_IMPL             "Ej implementerat ännu"\r
-    IDS_WINE                "WINE"\r
-    IDS_WINE_FILE           "Wine File"\r
-}\r
-\r
-STRINGTABLE\r
-{\r
-    IDS_COL_NAME            "Namn"\r
-    IDS_COL_SIZE            "Storlek"\r
-    IDS_COL_CDATE           "CDatum"\r
-    IDS_COL_ADATE           "ADatum"\r
-    IDS_COL_MDATE           "MDatum"\r
-    IDS_COL_IDX             "Index/Inode"\r
-    IDS_COL_LINKS           "Länkar"\r
-    IDS_COL_ATTR            "Attribut"\r
-    IDS_COL_SEC             "Säkerhet"\r
-}\r
diff --git a/reactos/subsys/system/winefile/cs.rc b/reactos/subsys/system/winefile/cs.rc
deleted file mode 100644 (file)
index 26b10d8..0000000
+++ /dev/null
@@ -1,212 +0,0 @@
-/*\r
- * WineFile\r
- * Czech Language Support\r
- *\r
- * Copyright 2000 Martin Fuchs\r
- * Copyright 2002 Steven Edwards\r
- * Copyright 2002 Alexandre Julliard\r
- * Copyright 2004 David Kredba\r
- *\r
- * This library is free software; you can redistribute it and/or\r
- * modify it under the terms of the GNU Lesser General Public\r
- * License as published by the Free Software Foundation; either\r
- * version 2.1 of the License, or (at your option) any later version.\r
- *\r
- * This library is distributed in the hope that it will be useful,\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU\r
- * Lesser General Public License for more details.\r
- *\r
- * You should have received a copy of the GNU Lesser General Public\r
- * License along with this library; if not, write to the Free Software\r
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA\r
- */\r
-\r
-LANGUAGE LANG_CZECH, SUBLANG_NEUTRAL\r
-#pragma code_page(1250)\r
-\r
-\r
-/* Menu */\r
-\r
-IDM_WINEFILE MENU FIXED IMPURE\r
-{\r
-    POPUP "&Soubor"  {\r
-        MENUITEM "&Otevøít\tEnter",             ID_ACTIVATE\r
-        MENUITEM "&Pøesunout...\tF7",           ID_FILE_MOVE\r
-        MENUITEM "&Kopírovat...\tF8",           ID_FILE_COPY\r
-        MENUITEM "&Ve schránce...\tF9",         118\r
-        MENUITEM "&Smazat\tDel",                ID_FILE_DELETE\r
-        MENUITEM "Pø&ejmenovat...",             109\r
-        MENUITEM "V&lastnosti...\tAlt+Enter",   ID_EDIT_PROPERTIES\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Komprese...",                119\r
-        MENUITEM "&Dekomprese...",              120\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Spustit...",                 ID_EXECUTE\r
-        MENUITEM "&Tisknout...",                102\r
-        MENUITEM "Asociovat...",                103\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "V&ytvoøit adresáø...",        111\r
-        MENUITEM "&Hledat...",                  104\r
-        MENUITEM "&Zvolit voubory...",          116\r
-        MENUITEM SEPARATOR\r
-#ifndef _NO_EXTENSIONS\r
-        MENUITEM "K&onec\tAlt+X",               ID_FILE_EXIT\r
-#else\r
-        MENUITEM "K&onec",                      ID_FILE_EXIT\r
-#endif\r
-    }\r
-\r
-    POPUP "&Disk"  {\r
-        MENUITEM "&Kopírovat disk...",          201\r
-        MENUITEM "&Jmenovka disk...",           202\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Formátovat disk...",         ID_FORMAT_DISK\r
-#ifdef _WIN95\r
-        MENUITEM "&Vytvoøit systemový disk...", -1  /*TODO*/\r
-#endif\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Pøipojit &sí\9dové zaøízení",   ID_CONNECT_NETWORK_DRIVE\r
-        MENUITEM "&Odpojit &sí\9dové zaøízení",   ID_DISCONNECT_NETWORK_DRIVE\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Sdílet jako...",              254\r
-        MENUITEM "&Odstranit sdílení...",       255\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Zvolit zaøízení...",         251\r
-    }\r
-\r
-    POPUP "&Adresáøe"  {\r
-        MENUITEM "&Dal\9aí úroveò\t+",            301\r
-        MENUITEM "Rozbalit &strom\t*",          302\r
-        MENUITEM "Rozbalit &v\9ae\tStrg+*",       303\r
-        MENUITEM "Sbalit &strom\t-",            304\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Oznaèit potomky",            505\r
-    }\r
-\r
-    POPUP "&Zobrazení"  {\r
-        MENUITEM "&Strom a adresáøe",           413\r
-        MENUITEM "&Jen strom",                  411\r
-        MENUITEM "Jen &adresáøe",               412\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Rozdìlit",                   ID_VIEW_SPLIT\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Jméno",                      ID_VIEW_NAME\r
-        MENUITEM "&Detaily v\9aech souborù",      ID_VIEW_ALL_ATTRIBUTES, CHECKED\r
-        MENUITEM "Èá&steèné detaily...",        ID_VIEW_SELECTED_ATTRIBUTES\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Tøídit podle jména",         ID_VIEW_SORT_NAME\r
-        MENUITEM "Tøídit &podle typu",          ID_VIEW_SORT_TYPE\r
-        MENUITEM "Tøídit podle &velikosti",     ID_VIEW_SORT_SIZE\r
-        MENUITEM "Tøídit podle &data",          ID_VIEW_SORT_DATE\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Tøídit podle &...",           ID_VIEW_FILTER\r
-    }\r
-\r
-    POPUP "&Nastavení"  {\r
-        MENUITEM "&Potvrzování...",             501\r
-        MENUITEM "&Písmo...",                   ID_SELECT_FONT\r
-        MENUITEM "Upravit panel &nástrojù...",  512\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Panel nástrojù",             ID_VIEW_TOOL_BAR, CHECKED\r
-        MENUITEM "&Panel zaøíení",              ID_VIEW_DRIVE_BAR, CHECKED\r
-        MENUITEM "&Stavový øádek",              ID_VIEW_STATUSBAR, CHECKED\r
-#ifndef _NO_EXTENSIONS\r
-        MENUITEM "&Celaá obrazovka\tCtrl+Shift+S", ID_VIEW_FULLSCREEN\r
-#endif\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Minimalizovat pøi spu\9atìní", 504\r
-        MENUITEM "&Ulo\9eit nastavení pøi vypnutí",511\r
-    }\r
-\r
-\r
-    POPUP "&Zabezpeèení"  {\r
-        MENUITEM "&Pøístup...",                 605\r
-        MENUITEM "&Logování...",                606\r
-        MENUITEM "&Vlastník...",                607\r
-    }\r
-\r
-    POPUP "&Okno"  {\r
-        MENUITEM "Nové &okno",                  ID_WINDOW_NEW\r
-        MENUITEM "Kaskádování\tCtrl+F5",        ID_WINDOW_CASCADE\r
-        MENUITEM "Uspoøádat &horizontálnì",     ID_WINDOW_TILE_HORZ\r
-        MENUITEM "Uspoøádat &vertikálnì\tCtrl+F4",ID_WINDOW_TILE_VERT\r
-#ifndef _NO_EXTENSIONS\r
-        MENUITEM "Zarovnat automaticky",        ID_WINDOW_AUTOSORT\r
-#endif\r
-        MENUITEM "Zarovnat &symboly",           ID_WINDOW_ARRANGE\r
-        MENUITEM "&Aktualizovat\tF5",           ID_REFRESH\r
-    }\r
-\r
-    POPUP "&?"  {\r
-        MENUITEM "&Témata nápovìdy\tF1",        ID_HELP\r
-        MENUITEM "Hledání v &nápovìdì...\tF1",  ID_HELP\r
-        MENUITEM "&Jak pou\9eívat nápovìdu\tF1",  ID_HELP_USING\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Informace o Winefile...",    ID_ABOUT\r
-#ifdef __WINE__\r
-        MENUITEM "Informace o &Wine...",        ID_ABOUT_WINE\r
-#endif\r
-    }\r
-}\r
-\r
-\r
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63\r
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "Spustit"\r
-FONT 8, "MS Shell Dlg"\r
-{\r
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10\r
-    CONTROL         "&Pøíkaz:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10\r
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL\r
-    CONTROL         "Jako &Symbol", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12\r
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14\r
-    PUSHBUTTON      "Zru\9ait", 2, 158, 23, 47, 14\r
-    PUSHBUTTON      "&Pomoc", 254, 158, 43, 47, 14\r
-}\r
-\r
-IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63\r
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "Zvolte cíl"\r
-FONT 8, "MS Shell Dlg"\r
-{\r
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10\r
-    CONTROL         "&Cesta:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10\r
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL\r
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14\r
-    PUSHBUTTON      "Zru\9ait", 2, 158, 23, 47, 14\r
-    PUSHBUTTON      "&Procházet", 254, 158, 43, 47, 14\r
-}\r
-\r
-STRINGTABLE\r
-{\r
-    IDS_FONT_SEL_DLG_NAME   "Aplikování nastavení písma"\r
-    IDS_FONT_SEL_ERROR      "Chyba pøi volbì nového písma."\r
-}\r
-\r
-STRINGTABLE\r
-{\r
-    IDS_WINEFILE            "Winefile"\r
-    IDS_ERROR               "Chyba"\r
-    IDS_ROOT_FS             "root fs"\r
-    IDS_UNIXFS              "unixfs"\r
-    IDS_DESKTOP             "Plocha"\r
-    IDS_SHELL               "Pøíkazový øádek"\r
-    IDS_TITLEFMT            "%s - %s"\r
-    IDS_NO_IMPL             "Zatím neimplementováno"\r
-    IDS_WINE                "WINE"\r
-    IDS_WINE_FILE           "Wine File"\r
-}\r
-\r
-STRINGTABLE\r
-{\r
-    IDS_COL_NAME            "Jméno"\r
-    IDS_COL_SIZE            "Velikost"\r
-    IDS_COL_CDATE           "Datum vytvoøení"\r
-    IDS_COL_ADATE           "Datum posledního pøístupu"\r
-    IDS_COL_MDATE           "Datum poslední modifikace"\r
-    IDS_COL_IDX             "Index/Inode"\r
-    IDS_COL_LINKS           "Linky"\r
-    IDS_COL_ATTR            "Atributy"\r
-    IDS_COL_SEC             "Zabezpeèení"\r
-}\r
diff --git a/reactos/subsys/system/winefile/de.rc b/reactos/subsys/system/winefile/de.rc
deleted file mode 100644 (file)
index a922f83..0000000
+++ /dev/null
@@ -1,262 +0,0 @@
-/*
- * Winefile
- * German Language Support
- *
- * Copyright 2000, 2005 Martin Fuchs
- * Copyright 2002 Steven Edwards
- * Copyright 2002 Alexandre Julliard
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_GERMAN, SUBLANG_GERMAN
-#pragma code_page(1252)
-
-
-/* Menu */
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "&Datei"  {
-        MENUITEM "Ö&ffnen\tEingabetaste",       ID_ACTIVATE
-        MENUITEM "&Verschieben...\tF7",         ID_FILE_MOVE
-        MENUITEM "&Kopieren...\tF8",            ID_FILE_COPY
-        MENUITEM "&In Zwischenablage...\tF9",   118
-        MENUITEM "&Löschen\tEntf",              ID_FILE_DELETE
-        MENUITEM "&Umbenennen...",              109
-        MENUITEM "&Eigenschaften...\tAlt+Eingabetaste", ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "K&omprimieren...",            119
-        MENUITEM "Deko&mprimieren...",          120
-        MENUITEM SEPARATOR
-        MENUITEM "&Ausführen...",               ID_EXECUTE
-        MENUITEM "&Drucken...",                 102
-        MENUITEM "Zuord&nen...",                103
-        MENUITEM SEPARATOR
-        MENUITEM "Ver&zeichnis erstellen...",   111
-        MENUITEM "&Suchen...",                  104
-        MENUITEM "Dateien aus&wählen...",       116
-        MENUITEM SEPARATOR
-        MENUITEM "&Beenden\tAlt+X",             ID_FILE_EXIT
-    }
-
-    POPUP "Da&tenträger"  {
-        MENUITEM "Datenträger &kopieren...",    201
-        MENUITEM "Datenträger &benennen...",    202
-        MENUITEM SEPARATOR
-        MENUITEM "Datenträger &formatieren...", ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "...",         -1  /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Netzwerklaufwerk &verbinden...",ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "Netzwerklaufwerk &trennen...",ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "F&reigeben als...",           254
-        MENUITEM "Freigabe been&den...",        255
-        MENUITEM SEPARATOR
-        MENUITEM "Laufwerk aus&wählen...",      251
-    }
-
-
-    POPUP "&Verzeichnisse"  {
-        MENUITEM "&Nächste Ebene einblenden\t+",301
-        MENUITEM "&Zweig einblenden\t*",        302
-        MENUITEM "Alle &Ebenen einblenden\tStrg+*",303
-        MENUITEM "Zweig &ausblenden\t-",        304
-        MENUITEM SEPARATOR
-        MENUITEM "&Verzweigungen kennzeichnen", 505
-    }
-
-    POPUP "&Ansicht"  {
-        MENUITEM "Struktur &und Verzeichnis",   413
-        MENUITEM "Nur St&ruktur",               411
-        MENUITEM "Nur &Verzeichnis",            412
-        MENUITEM SEPARATOR
-        MENUITEM "&Teilen",                     ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "&Name",                       ID_VIEW_NAME
-        MENUITEM "A&lle Dateiangaben",          ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "&Bestimmte Dateiangaben...",  ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "Nach N&ame",                  ID_VIEW_SORT_NAME
-        MENUITEM "Nach T&yp",                   ID_VIEW_SORT_TYPE
-        MENUITEM "Nach &Größe",                 ID_VIEW_SORT_SIZE
-        MENUITEM "Nach &Datum",                 ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "Angaben ausw&ählen...",       ID_VIEW_FILTER
-    }
-
-    POPUP "&Optionen"  {
-        MENUITEM "&Bestätigen...",              501
-        MENUITEM "Schrift&art...",              ID_SELECT_FONT
-        MENUITEM "Symbolleiste &definieren...", 512
-        MENUITEM SEPARATOR
-        MENUITEM "Sy&mbolleiste",               ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "Lauf&werkleiste",             ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "&Statusleiste",               ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Vollb&ild\tStrg+Umschalt+S",  ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "&Symbol nach Programmstart",  504
-        MENUITEM "&Einstellungen beim Beenden speichern", 511
-    }
-
-    POPUP "&Sicherheit"  {
-        MENUITEM "&Berechtigungen...",          605
-        MENUITEM "Über&wachen...",              606
-        MENUITEM "Besi&tzer...",                607
-    }
-
-    POPUP "&Fenster"  {
-        MENUITEM "Neues &Fenster",              ID_WINDOW_NEW
-        MENUITEM "Über&lappend\tUmschalt+F5",   ID_WINDOW_CASCADE
-        MENUITEM "&Untereinander",              ID_WINDOW_TILE_HORZ
-        MENUITEM "&Nebeneinander\tUmschalt+F4", ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "au&tomatisch anordnen",       ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "&Symbole anordnen",           ID_WINDOW_ARRANGE
-        MENUITEM "&Aktualisieren\tF5",          ID_REFRESH
-    }
-
-    POPUP "&?"  {
-        MENUITEM "&Hilfethemen\tF1",            ID_HELP
-        MENUITEM "&Suchen...\tF1",              ID_HELP
-        MENUITEM "Hilfe &verwenden\tF1",        ID_HELP_USING
-        MENUITEM SEPARATOR
-        MENUITEM "&Info über Winefile...",      ID_ABOUT
-#ifdef __WINE__
-        MENUITEM "Info über &Wine...",          ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Ausführen"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "Befehls&zeile:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    CONTROL         "Als &Symbol", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Abbrechen", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Hilfe", 254, 158, 43, 47, 14
-}
-
-IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Ziel auswählen"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Verzeichnis:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Abbrechen", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Durchsuchen", 254, 158, 43, 47, 14
-}
-
-IDD_DIALOG_VIEW_TYPE DIALOG DISCARDABLE 15, 13, 161, 97
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Angaben auswählen"
-FONT 8, "MS Sans Serif"
-BEGIN
-    LTEXT           "&Name:",-1,7,8,22,10
-    EDITTEXT        IDC_VIEW_PATTERN,31,7,63,12,ES_AUTOHSCROLL
-    GROUPBOX        "Dateityp",-1,7,23,87,56
-    CONTROL         "&Verzeichnisse",IDC_VIEW_TYPE_DIRECTORIES,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,32,70,10
-    CONTROL         "&Programme",IDC_VIEW_TYPE_PROGRAMS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,43,70,10
-    CONTROL         "&Dokumente",IDC_VIEW_TYPE_DOCUMENTS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,54,70,10
-    CONTROL         "&Andere Dateien",IDC_VIEW_TYPE_OTHERS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,65,70,10
-    CONTROL         "Vers&teckte/Systemdateien anzeigen",IDC_VIEW_TYPE_HIDDEN,
-                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,81,106,9
-    DEFPUSHBUTTON   "OK",IDOK,104,7,50,14
-    PUSHBUTTON      "Abbrechen",IDCANCEL,104,24,50,14
-END
-
-IDD_DIALOG_PROPERTIES DIALOG DISCARDABLE  0, 0, 248, 215
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Eigenschaften für %s"
-FONT 8, "MS Sans Serif"
-BEGIN
-    DEFPUSHBUTTON   "OK",IDOK,191,7,50,14
-    PUSHBUTTON      "Abbrechen",IDCANCEL,191,29,50,14
-    LTEXT           "&Dateiname:",-1,7,7,59,9
-    EDITTEXT        IDC_STATIC_PROP_FILENAME,71,7,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "&Pfad:",-1,7,18,59,9
-    EDITTEXT        IDC_STATIC_PROP_PATH,71,18,120,9, ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Letzte &Änderung:",-1,7,29,59,9
-    EDITTEXT        IDC_STATIC_PROP_LASTCHANGE,71,29,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "&Version:",-1,7,40,59,9
-    EDITTEXT        IDC_STATIC_PROP_VERSION,71,40,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "&Copyright:",-1,7,51,59,9
-    EDITTEXT        IDC_STATIC_PROP_COPYRIGHT,71,51,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "&Größe:",-1,7,62,59,9
-    EDITTEXT        IDC_STATIC_PROP_SIZE,71,62,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    GROUPBOX        "Attribute",-1,7,79,158,46
-    CONTROL         "&Schreibgeschützt",IDC_CHECK_READONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,91,68,9
-    CONTROL         "&Versteckt",IDC_CHECK_HIDDEN,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,91,68,9
-    CONTROL         "&Archiv",IDC_CHECK_ARCHIVE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,101,68,9
-    CONTROL         "Sys&tem",IDC_CHECK_SYSTEM,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,101,68,9
-    CONTROL         "&Komprimiert",IDC_CHECK_COMPRESSED,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,17,111,68,9
-    GROUPBOX        "&Versionsinformationen",-1,7,129,234,79
-    LISTBOX         IDC_LIST_PROP_VERSION_TYPES,13,139,107,63,LBS_SORT | LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP
-    EDITTEXT        IDC_LIST_PROP_VERSION_VALUES,123,139,111,63,ES_MULTILINE | ES_READONLY | WS_VSCROLL
-END
-
-
-STRINGTABLE
-{
-    IDS_FONT_SEL_DLG_NAME   "Anwenden der Schriftarteinstellung"
-    IDS_FONT_SEL_ERROR      "Fehler während der Schriftart-Auswahl."
-}
-
-STRINGTABLE
-{
-    IDS_WINEFILE            "Winefile"
-    IDS_ERROR               "Fehler"
-    IDS_ROOT_FS             "root fs"
-    IDS_UNIXFS              "unixfs"
-    IDS_DESKTOP             "Desktop"
-    IDS_SHELL               "Shell"
-    IDS_TITLEFMT            "%s - %s"
-    IDS_NO_IMPL             "Noch nicht implementiert"
-    IDS_WINE                "WINE"
-    IDS_WINE_FILE           "Wine File"
-}
-
-STRINGTABLE
-{
-    IDS_COL_NAME            "Name"
-    IDS_COL_SIZE            "Größe"
-    IDS_COL_CDATE           "CDatum"
-    IDS_COL_ADATE           "ZDatum"
-    IDS_COL_MDATE           "ÄDatum"
-    IDS_COL_IDX             "Index/Inode"
-    IDS_COL_LINKS           "Links"
-    IDS_COL_ATTR            "Attribute"
-    IDS_COL_SEC             "Sicherheit"
-
-    IDS_FREE_SPACE_FMT      "%s von %s frei"
-}
diff --git a/reactos/subsys/system/winefile/doxy-footer.html b/reactos/subsys/system/winefile/doxy-footer.html
deleted file mode 100644 (file)
index e0ea3bb..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-<hr size="1">
-<table border="0" width="100%" cellspacing="0">
-  <tr>
-    <td><address style="align: right;"><small>
-Winefile Source Code Documentation
-<br>generated on 02.10.2005 by <a href="http://www.doxygen.org/index.html">
-<img src="doxygen.png" alt="doxygen" align="middle" border=0>
-       </small></address>
-       </td>
-    <td>
-      <p align="right"><a href="http://www.sky.franken.de/winefile/" target="_parent">Winefile Homepage</a>
-      </td>
-  </tr>
-</table>
-</body>
-</html>
diff --git a/reactos/subsys/system/winefile/doxy-footer.htmt b/reactos/subsys/system/winefile/doxy-footer.htmt
deleted file mode 100644 (file)
index 0cb3737..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-<hr size="1">
-<table border="0" width="100%" cellspacing="0">
-  <tr>
-    <td><address style="align: right;"><small>
-Winefile Source Code Documentation
-<br>@GEN@ by <a href="http://www.doxygen.org/index.html">
-<img src="doxygen.png" alt="doxygen" align="middle" border=0>
-       </small></address>
-       </td>
-    <td>
-      <p align="right"><a href="http://www.sky.franken.de/winefile/" target="_parent">Winefile Homepage</a>
-      </td>
-  </tr>
-</table>
-</body>
-</html>
diff --git a/reactos/subsys/system/winefile/drivebar.bmp b/reactos/subsys/system/winefile/drivebar.bmp
deleted file mode 100644 (file)
index 6feabbd..0000000
Binary files a/reactos/subsys/system/winefile/drivebar.bmp and /dev/null differ
diff --git a/reactos/subsys/system/winefile/en.rc b/reactos/subsys/system/winefile/en.rc
deleted file mode 100644 (file)
index 5e613c6..0000000
+++ /dev/null
@@ -1,266 +0,0 @@
-/*
- * WineFile
- * English Language Support
- *
- * Copyright 2000 Martin Fuchs
- * Copyright 2002 Steven Edwards
- * Copyright 2002 Alexandre Julliard
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
-#pragma code_page(850)
-
-
-/* Menu */
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "&File"  {
-        MENUITEM "&Open\tEnter",                ID_ACTIVATE
-        MENUITEM "&Move...\tF7",                ID_FILE_MOVE
-        MENUITEM "&Copy...\tF8",                ID_FILE_COPY
-        MENUITEM "&In Clipboard...\tF9",        118
-        MENUITEM "&Delete\tDel",                ID_FILE_DELETE
-        MENUITEM "Re&name...",                  109
-        MENUITEM "Propert&ies...\tAlt+Enter",   ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "C&ompress...",                119
-        MENUITEM "Dec&ompress...",              120
-        MENUITEM SEPARATOR
-        MENUITEM "&Run...",                     ID_EXECUTE
-        MENUITEM "&Print...",                   102
-        MENUITEM "Associate...",                103
-        MENUITEM SEPARATOR
-        MENUITEM "Cr&eate Directory...",        111
-        MENUITEM "Searc&h...",                  104
-        MENUITEM "&Select Files...",            116
-        MENUITEM SEPARATOR
-#ifndef _NO_EXTENSIONS
-        MENUITEM "E&xit\tAlt+X",                ID_FILE_EXIT
-#else
-        MENUITEM "E&xit",                       ID_FILE_EXIT
-#endif
-    }
-
-    POPUP "&Disk"  {
-        MENUITEM "&Copy Disk...",               201
-        MENUITEM "&Label Disk...",              202
-        MENUITEM SEPARATOR
-        MENUITEM "&Format Disk...",             ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "&Make System Disk...", -1 /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Connect &Network Drive",      ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "&Disconnect Network Drive",   ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "Share as...",                 254
-        MENUITEM "&Remove Share...",            255
-        MENUITEM SEPARATOR
-        MENUITEM "&Select Drive...",            251
-    }
-
-    POPUP "Di&rectories"  {
-        MENUITEM "&Next Level\t+",              301
-        MENUITEM "Expand &Tree\t*",             302
-        MENUITEM "Expand &all\tStrg+*",         303
-        MENUITEM "Collapse &Tree\t-",           304
-        MENUITEM SEPARATOR
-        MENUITEM "&Mark Children",              505
-    }
-
-    POPUP "&View"  {
-        MENUITEM "T&ree and Directory",         413
-        MENUITEM "Tr&ee Only",                  411
-        MENUITEM "Directory &Only",             412
-        MENUITEM SEPARATOR
-        MENUITEM "Sp&lit",                      ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "&Name",                       ID_VIEW_NAME
-        MENUITEM "&All File Details",           ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "&Partial Details...",         ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "&Sort by Name",               ID_VIEW_SORT_NAME
-        MENUITEM "Sort &by Type",               ID_VIEW_SORT_TYPE
-        MENUITEM "Sort by Si&ze",               ID_VIEW_SORT_SIZE
-        MENUITEM "Sort by &Date",               ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "Filter by &...",              ID_VIEW_FILTER
-    }
-
-    POPUP "&Options"  {
-        MENUITEM "&Confirmation...",            501
-        MENUITEM "&Font...",                    ID_SELECT_FONT
-        MENUITEM "Customize Tool&bar...",       512
-        MENUITEM SEPARATOR
-        MENUITEM "&Toolbar",                    ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "&Drivebar",                   ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "&Status Bar",                 ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "F&ull Screen\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "&Minimize on run",            504
-        MENUITEM "&Save settings on exit",      511
-    }
-
-
-    POPUP "&Security"  {
-        MENUITEM "&Access...",                  605
-        MENUITEM "&Logging...",                 606
-        MENUITEM "&Owner...",                   607
-    }
-
-    POPUP "&Window"  {
-        MENUITEM "New &Window",                 ID_WINDOW_NEW
-        MENUITEM "Cascading\tCtrl+F5",          ID_WINDOW_CASCADE
-        MENUITEM "Tile &Horizontally",          ID_WINDOW_TILE_HORZ
-        MENUITEM "Tile &Vertically\tCtrl+F4",   ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Arrange Automatically",       ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "Arrange &Symbols",            ID_WINDOW_ARRANGE
-        MENUITEM "&Refresh\tF5",                ID_REFRESH
-    }
-
-    POPUP "&?"  {
-        MENUITEM "&Help Topics\tF1",            ID_HELP
-        MENUITEM "Help &Search...\tF1",         ID_HELP
-        MENUITEM "&Using Help\tF1",             ID_HELP_USING
-        MENUITEM SEPARATOR
-        MENUITEM "&Info about Winefile...",     ID_ABOUT
-#ifdef __WINE__
-        MENUITEM "Info about &Wine...",         ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Execute"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Command:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    CONTROL         "As &Symbol", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Cancel", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Help", 254, 158, 43, 47, 14
-}
-
-IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Select destination"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Path:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Cancel", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Browse", 254, 158, 43, 47, 14
-}
-
-IDD_DIALOG_VIEW_TYPE DIALOG DISCARDABLE 15, 13, 161, 97
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "By File Type"
-FONT 8, "MS Sans Serif"
-BEGIN
-    LTEXT           "&Name:",-1,7,8,22,10
-    EDITTEXT        IDC_VIEW_PATTERN,31,7,63,12,ES_AUTOHSCROLL
-    GROUPBOX        "File Type",-1,7,23,87,56
-    CONTROL         "&Directories",IDC_VIEW_TYPE_DIRECTORIES,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,32,70,10
-    CONTROL         "&Programs",IDC_VIEW_TYPE_PROGRAMS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,43,70,10
-    CONTROL         "Docu&ments",IDC_VIEW_TYPE_DOCUMENTS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,54,70,10
-    CONTROL         "&Other files",IDC_VIEW_TYPE_OTHERS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,65,70,10
-    CONTROL         "Show Hidden/&System Files",IDC_VIEW_TYPE_HIDDEN,
-                    "Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,81,106,9
-    DEFPUSHBUTTON   "OK",IDOK,104,7,50,14
-    PUSHBUTTON      "Cancel",IDCANCEL,104,24,50,14
-END
-
-IDD_DIALOG_PROPERTIES DIALOG DISCARDABLE  0, 0, 248, 215
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Properties for %s"
-FONT 8, "MS Sans Serif"
-BEGIN
-    DEFPUSHBUTTON   "OK",IDOK,191,7,50,14
-    PUSHBUTTON      "Cancel",IDCANCEL,191,29,50,14
-    LTEXT           "&File Name:",-1,7,7,59,9
-    EDITTEXT        IDC_STATIC_PROP_FILENAME,71,7,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Full &Path:",-1,7,18,59,9
-    EDITTEXT        IDC_STATIC_PROP_PATH,71,18,120,9, ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Last Change:",-1,7,29,59,9
-    EDITTEXT        IDC_STATIC_PROP_LASTCHANGE,71,29,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Version:",-1,7,40,59,9
-    EDITTEXT        IDC_STATIC_PROP_VERSION,71,40,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Cop&yright:",-1,7,51,59,9
-    EDITTEXT        IDC_STATIC_PROP_COPYRIGHT,71,51,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Size:",-1,7,62,59,9
-    EDITTEXT        IDC_STATIC_PROP_SIZE,71,62,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    GROUPBOX        "Attributes",-1,7,79,158,46
-    CONTROL         "&Read Only",IDC_CHECK_READONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,91,68,9
-    CONTROL         "H&idden",IDC_CHECK_HIDDEN,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,91,68,9
-    CONTROL         "&Archive",IDC_CHECK_ARCHIVE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,101,68,9
-    CONTROL         "&System",IDC_CHECK_SYSTEM,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,101,68,9
-    CONTROL         "&Compressed",IDC_CHECK_COMPRESSED,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,17,111,68,9
-    GROUPBOX        "&Version Information",-1,7,129,234,79
-    LISTBOX         IDC_LIST_PROP_VERSION_TYPES,13,139,107,63,LBS_SORT | LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP
-    EDITTEXT        IDC_LIST_PROP_VERSION_VALUES,123,139,111,63,ES_MULTILINE | ES_READONLY | WS_VSCROLL
-END
-
-
-STRINGTABLE
-{
-    IDS_FONT_SEL_DLG_NAME   "Applying font settings"
-    IDS_FONT_SEL_ERROR      "Error while selecting new font."
-}
-
-STRINGTABLE
-{
-    IDS_WINEFILE            "Winefile"
-    IDS_ERROR               "Error"
-    IDS_ROOT_FS             "root fs"
-    IDS_UNIXFS              "unixfs"
-    IDS_DESKTOP             "Desktop"
-    IDS_SHELL               "Shell"
-    IDS_TITLEFMT            "%s - %s"
-    IDS_NO_IMPL             "Not yet implemented"
-    IDS_WINE                "WINE"
-    IDS_WINE_FILE           "Wine File"
-}
-
-STRINGTABLE
-{
-    IDS_COL_NAME            "Name"
-    IDS_COL_SIZE            "Size"
-    IDS_COL_CDATE           "CDate"
-    IDS_COL_ADATE           "ADate"
-    IDS_COL_MDATE           "MDate"
-    IDS_COL_IDX             "Index/Inode"
-    IDS_COL_LINKS           "Links"
-    IDS_COL_ATTR            "Attributes"
-    IDS_COL_SEC             "Security"
-
-    IDS_FREE_SPACE_FMT      "%s of %s free"
-}
diff --git a/reactos/subsys/system/winefile/es.rc b/reactos/subsys/system/winefile/es.rc
deleted file mode 100644 (file)
index 4d1e18a..0000000
+++ /dev/null
@@ -1,258 +0,0 @@
-/*
- * WineFile
- * Spanish Language Support
- *
- * Copyright 2004 José Manuel Ferrer Ortiz
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_SPANISH, SUBLANG_NEUTRAL
-
-/* Menu */
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "&Archivo"  {
-        MENUITEM "&Abrir\tEnter",               ID_ACTIVATE
-        MENUITEM "Mo&ver...\tF7",               ID_FILE_MOVE
-        MENUITEM "&Copiar...\tF8",              ID_FILE_COPY
-        MENUITEM "E&n portapapeles...\tF9",     118
-        MENUITEM "&Eliminar\tDel",              ID_FILE_DELETE
-        MENUITEM "&Renombrar...",               109
-        MENUITEM "&Propiedades...\tAlt+Enter",  ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "C&omprimir...",               119
-        MENUITEM "&Descomprimir...",            120
-        MENUITEM SEPARATOR
-        MENUITEM "E&jecutar...",                ID_EXECUTE
-        MENUITEM "I&mprimir...",                102
-        MENUITEM "Asoc&iar...",                 103
-        MENUITEM SEPARATOR
-        MENUITEM "Crear direc&torio...",        111
-        MENUITEM "&Buscar...",                  104
-        MENUITEM "Se&leccionar archivos...",    116
-        MENUITEM SEPARATOR
-#ifndef _NO_EXTENSIONS
-        MENUITEM "&Salir\tAlt+X",               ID_FILE_EXIT
-#else
-        MENUITEM "&Salir",                      ID_FILE_EXIT
-#endif
-    }
-
-    POPUP "&Disco"  {
-        MENUITEM "&Copiar disco...",            201
-        MENUITEM "E&tiquetar disco...",         202
-        MENUITEM SEPARATOR
-        MENUITEM "&Formatear disco...",         ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "&Hacer disco de sistema...", -1   /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "C&onectar unidad de red",     ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "&Desconectar unidad de red",  ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "Co&mpartir como...",          254
-        MENUITEM "&Eliminar compartido...",     255
-        MENUITEM SEPARATOR
-        MENUITEM "&Seleccionar unidad...",      251
-    }
-
-    POPUP "Di&rectorios"  {
-        MENUITEM "&Siguiente nivel\t+",         301
-        MENUITEM "&Expandir árbol\t*",          302
-        MENUITEM "Expandir &todo\tStrg+*",      303
-        MENUITEM "&Colapsar árbol\t-",          304
-        MENUITEM SEPARATOR
-        MENUITEM "&Marcar hijos",               505
-    }
-
-    POPUP "&Ver"  {
-        MENUITEM "Á&rbol y directorio",         413
-        MENUITEM "Árbol &sólo",                 411
-        MENUITEM "&Directorio sólo",            412
-        MENUITEM SEPARATOR
-        MENUITEM "Di&vidir",                    ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "No&mbre",                     ID_VIEW_NAME
-        MENUITEM "T&odos los detalles",         ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "Detalles &parciales...",      ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "Ordenar por &nombre",         ID_VIEW_SORT_NAME
-        MENUITEM "Ordenar por &tipo",           ID_VIEW_SORT_TYPE
-        MENUITEM "Ordenar por t&amaño",         ID_VIEW_SORT_SIZE
-        MENUITEM "Ordenar por &fecha",          ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "Ordenar por &...",            ID_VIEW_FILTER
-    }
-
-    POPUP "&Opciones"  {
-        MENUITEM "&Confirmación...",            501
-        MENUITEM "&Fuente...",                  ID_SELECT_FONT
-        MENUITEM "Personalizar barra &herramientas...", 512
-        MENUITEM SEPARATOR
-        MENUITEM "&Barra de herramientas",      ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "Barra de &unidades",          ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "Barra de &estado",            ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "&Pantalla completa\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "&Minimizar al ejecutarse",    504
-        MENUITEM "&Guardar opciones al salir",  511
-    }
-
-
-    POPUP "&Seguridad"  {
-        MENUITEM "&Acceso...",                  605
-        MENUITEM "&Logging...",                 606
-        MENUITEM "&Propietario...",             607
-    }
-
-    POPUP "&Ventana"  {
-        MENUITEM "&Nueva ventana",              ID_WINDOW_NEW
-        MENUITEM "&Cascada\tCtrl+F5",           ID_WINDOW_CASCADE
-        MENUITEM "Mosaico &horizontal",         ID_WINDOW_TILE_HORZ
-        MENUITEM "Mosaico &vertical\tCtrl+F4",  ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "A&linear automáticamente",    ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "Alinear &símbolos",           ID_WINDOW_ARRANGE
-        MENUITEM "&Actualizar\tF5",             ID_REFRESH
-    }
-
-    POPUP "&?"  {
-        MENUITEM "&Temas de ayuda\tF1",         ID_HELP
-        MENUITEM "&Buscar en la ayuda...\tF1",  ID_HELP
-        MENUITEM "&Usando la ayuda\tF1",        ID_HELP_USING
-        MENUITEM SEPARATOR
-        MENUITEM "&Acerca de Winefile...",      ID_ABOUT
-#ifdef __WINE__
-        MENUITEM "Acerca de &Wine...",          ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Ejecutar"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Comando:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    CONTROL         "Como &símbolo", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12
-    DEFPUSHBUTTON   "Aceptar", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Cancelar", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Ayuda", 254, 158, 43, 47, 14
-}
-
-IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Seleccione destino"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Ruta:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    DEFPUSHBUTTON   "Aceptar", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Cancelar", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Examinar", 254, 158, 43, 47, 14
-}
-IDD_DIALOG_VIEW_TYPE DIALOG DISCARDABLE 15, 13, 161, 97
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "By File Type"
-FONT 8, "MS Sans Serif"
-BEGIN
-    LTEXT           "&Nombre:",-1,7,8,22,10
-    EDITTEXT        IDC_VIEW_PATTERN,31,7,63,12,ES_AUTOHSCROLL
-    GROUPBOX        "Typo de Fichero",-1,7,23,87,56
-    CONTROL         "&Directorios",IDC_VIEW_TYPE_DIRECTORIES,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,32,70,10
-    CONTROL         "&Programas",IDC_VIEW_TYPE_PROGRAMS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,43,70,10
-    CONTROL         "Docu&mentos",IDC_VIEW_TYPE_DOCUMENTS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,54,70,10
-    CONTROL         "&Otros Ficheros",IDC_VIEW_TYPE_OTHERS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,65,70,10
-    CONTROL         "Mostrar ficheros Escondidos/Systema (Hidden/&System)  ",IDC_VIEW_TYPE_HIDDEN,
-                    "Buton",BS_AUTOCHECKBOX | WS_TABSTOP,7,81,106,9
-    DEFPUSHBUTTON   "Aceptar",IDOK,104,7,50,14
-    PUSHBUTTON      "Cancelar",IDCANCEL,104,24,50,14
-END
-
-IDD_DIALOG_PROPERTIES DIALOG DISCARDABLE  0, 0, 248, 215
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Properties for %s"
-FONT 8, "MS Sans Serif"
-BEGIN
-    DEFPUSHBUTTON   "Aceptar",IDOK,191,7,50,14
-    PUSHBUTTON      "Cancelar",IDCANCEL,191,29,50,14
-    LTEXT           "&File Name:",-1,7,7,59,9
-    EDITTEXT        IDC_STATIC_PROP_FILENAME,71,7,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Full &Path:",-1,7,18,59,9
-    EDITTEXT        IDC_STATIC_PROP_PATH,71,18,120,9, ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "último Cambio:",-1,7,29,59,9
-    EDITTEXT        IDC_STATIC_PROP_LASTCHANGE,71,29,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Verción:",-1,7,40,59,9
-    EDITTEXT        IDC_STATIC_PROP_VERSION,71,40,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Cop&yright:",-1,7,51,59,9
-    EDITTEXT        IDC_STATIC_PROP_COPYRIGHT,71,51,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "tamaño:",-1,7,62,59,9
-    EDITTEXT        IDC_STATIC_PROP_SIZE,71,62,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    GROUPBOX        "Atributos",-1,7,79,158,46
-    CONTROL         "&Lectura Solamente",IDC_CHECK_READONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,91,68,9
-    CONTROL         "&Escondido",IDC_CHECK_HIDDEN,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,91,68,9
-    CONTROL         "&Archivado",IDC_CHECK_ARCHIVE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,101,68,9
-    CONTROL         "&Sistema",IDC_CHECK_SYSTEM,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,101,68,9
-    CONTROL         "&Comprimido",IDC_CHECK_COMPRESSED,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,17,111,68,9
-    GROUPBOX        "Información de &Verción",-1,7,129,234,79
-    LISTBOX         IDC_LIST_PROP_VERSION_TYPES,13,139,107,63,LBS_SORT | LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP
-    EDITTEXT        IDC_LIST_PROP_VERSION_VALUES,123,139,111,63,ES_MULTILINE | ES_READONLY | WS_VSCROLL
-END
-
-STRINGTABLE
-{
-    IDS_FONT_SEL_DLG_NAME   "Aplicando configuración de fuente"
-    IDS_FONT_SEL_ERROR      "Error al seleccionar la nueva fuente."
-}
-
-STRINGTABLE
-{
-    IDS_WINEFILE            "Winefile"
-    IDS_ERROR               "Error"
-    IDS_ROOT_FS             "sf raíz"
-    IDS_UNIXFS              "unixfs"
-    IDS_DESKTOP             "Escritorio"
-    IDS_SHELL               "Shell"
-    IDS_TITLEFMT            "%s - %s"
-    IDS_NO_IMPL             "Aún no implementado"
-    IDS_WINE                "WINE"
-    IDS_WINE_FILE           "Wine File"
-}
-
-STRINGTABLE
-{
-    IDS_COL_NAME            "Nombre"
-    IDS_COL_SIZE            "Tamaño"
-    IDS_COL_CDATE           "FechaC"
-    IDS_COL_ADATE           "FechaA"
-    IDS_COL_MDATE           "FechaM"
-    IDS_COL_IDX             "Índice/Nodo-i"
-    IDS_COL_LINKS           "Enlaces"
-    IDS_COL_ATTR            "Atributos"
-    IDS_COL_SEC             "Seguridad"
-}
diff --git a/reactos/subsys/system/winefile/fr.rc b/reactos/subsys/system/winefile/fr.rc
deleted file mode 100644 (file)
index b0cee73..0000000
+++ /dev/null
@@ -1,266 +0,0 @@
-/*
- * WineFile
- * French Language Support
- *
- * Copyright 2000 Martin Fuchs
- * Copyright 2002 Steven Edwards
- * Copyright 2002 Alexandre Julliard
- * Copyright 2003 Sylvain Petreolle
- * Copyright 2005 Jonathan Ernst
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL
-
-/* Menu */
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "&Fichier"  {
-        MENUITEM "&Ouvrir\tEntrée",             ID_ACTIVATE
-        MENUITEM "&Déplacer...\tF7",            ID_FILE_MOVE
-        MENUITEM "&Copier...\tF8",              ID_FILE_COPY
-        MENUITEM "P&resse-Papiers...\tF9",      118
-        MENUITEM "&Effacer\tDel",               ID_FILE_DELETE
-        MENUITEM "Re&nommer...",                109
-        MENUITEM "&Propriétés...\tAlt+Entree", ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "Co&mpresser...",              119
-        MENUITEM "Décompre&sser...",            120
-        MENUITEM SEPARATOR
-        MENUITEM "E&xécuter...",                ID_EXECUTE
-        MENUITEM "&Imprimer...",                102
-        MENUITEM "&Associer...",                103
-        MENUITEM SEPARATOR
-        MENUITEM "Créer Réper&toire...",        111
-        MENUITEM "Rec&hercher...",              104
-        MENUITEM "Sélectionner &Fichiers...",   116
-        MENUITEM SEPARATOR
-#ifndef _NO_EXTENSIONS
-        MENUITEM "&Quitter\tAlt+X",             ID_FILE_EXIT
-#else
-        MENUITEM "&Quitter",                    ID_FILE_EXIT
-#endif
-    }
-
-    POPUP "&Disque"  {
-        MENUITEM "&Copier Disque...",           201
-        MENUITEM "&Nommer Disque...",           202
-        MENUITEM SEPARATOR
-        MENUITEM "&Formater Disque...",         ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "Créer un disque *système...", -1  /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Connecter un lecteur &réseau",ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "&Déconnecter un lecteur réseau",ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "&Partager...",                254
-        MENUITEM "Cesser de parta&ger",         255
-        MENUITEM SEPARATOR
-        MENUITEM "Choisir le &lecteur",         251
-    }
-
-    POPUP "&Répertoires"  {
-        MENUITEM "&Développer un niveau\t+",    301
-        MENUITEM "Développer une &branche\t*",  302
-        MENUITEM "&Tout développer\tCtrl+*",    303
-        MENUITEM "&Réduire une branche\t-",     304
-        MENUITEM SEPARATOR
-        MENUITEM "&Indiquer l'arborescence",    505
-    }
-
-    POPUP "&Vue"  {
-        MENUITEM "Arbre et ré&pertoire",        413
-        MENUITEM "&Arbre seulement",            411
-        MENUITEM "&Répertoire seulement",       412
-        MENUITEM SEPARATOR
-        MENUITEM "&Séparer",                    ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "&Nom",                        ID_VIEW_NAME
-        MENUITEM "Tous &les Détails",           ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "&Détails...",                 ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "Trier par N&om",              ID_VIEW_SORT_NAME
-        MENUITEM "Trier par &Type",             ID_VIEW_SORT_TYPE
-        MENUITEM "Trier par Ta&ille",           ID_VIEW_SORT_SIZE
-        MENUITEM "Trier par Dat&e",             ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "Trier par &...",              ID_VIEW_FILTER
-    }
-
-    POPUP "&Options"  {
-        MENUITEM "&Confirmation...",            501
-        MENUITEM "&Police...",                  ID_SELECT_FONT
-        MENUITEM "Personnaliser la &barre d'Outils...", 512
-        MENUITEM SEPARATOR
-        MENUITEM "Barre d'&Outils",             ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "Barre de &Lecteur",           ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "Barre d'&État",               ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "P&lein Écran\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "&Réduire a l'utilisation",    504
-        MENUITEM "&Enregistrer la configuration en quittant",511
-    }
-
-
-    POPUP "&Sécurité"  {
-        MENUITEM "&Accès...",                   605
-        MENUITEM "&Surveillance...",            606
-        MENUITEM "&Propriétaire...",            607
-    }
-
-    POPUP "&Fenêtre"  {
-        MENUITEM "Nouvelle &fenêtre",           ID_WINDOW_NEW
-        MENUITEM "&En cascade\tCtrl+F5",        ID_WINDOW_CASCADE
-        MENUITEM "Mosaïque &horizontale",       ID_WINDOW_TILE_HORZ
-        MENUITEM "Mosaïque &verticale\tCtrl+F4",ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Réorganisation &Automatique", ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "Réorganiser les &icônes",     ID_WINDOW_ARRANGE
-        MENUITEM "&Actualiser\tF5",             ID_REFRESH
-    }
-
-    POPUP "&Aide"  {
-        MENUITEM "&Sommaire de l'aide\tF1",     ID_HELP
-        MENUITEM "&Rechercher dans l'aide\tF1", ID_HELP
-        MENUITEM "&Utiliser l'aide\tF1",        ID_HELP_USING
-        MENUITEM SEPARATOR
-        MENUITEM "&A propos de Winefile...",    ID_ABOUT
-#ifdef __WINE__
-        MENUITEM "A propos de &Wine...",        ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Exécuter"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Commande :", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    CONTROL         "Sous forme d'icône", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Annuler", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Aide", 254, 158, 43, 47, 14
-}
-
-IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Sélectionner la destination"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Dossier:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Annuler", 2, 158, 23, 47, 14
-    PUSHBUTTON      "Pa&rcourir...", 254, 158, 43, 47, 14
-}
-
-IDD_DIALOG_VIEW_TYPE DIALOG DISCARDABLE 15, 13, 161, 97
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Par type de fichier"
-FONT 8, "MS Sans Serif"
-BEGIN
-    LTEXT           "&Name:",-1,7,8,22,10
-    EDITTEXT        IDC_VIEW_PATTERN,31,7,63,12,ES_AUTOHSCROLL
-    GROUPBOX        "Type de fichier",-1,7,23,87,56
-    CONTROL         "&Répertoires",IDC_VIEW_TYPE_DIRECTORIES,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,32,70,10
-    CONTROL         "&Programmes",IDC_VIEW_TYPE_PROGRAMS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,43,70,10
-    CONTROL         "Docu&ments",IDC_VIEW_TYPE_DOCUMENTS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,54,70,10
-    CONTROL         "&Autres fichiers",IDC_VIEW_TYPE_OTHERS,"Button",
-                    BS_AUTOCHECKBOX | WS_TABSTOP,13,65,70,10
-    CONTROL         "Montrer les fichiers cachés/&système",IDC_VIEW_TYPE_HIDDEN,
-                    "Bouton",BS_AUTOCHECKBOX | WS_TABSTOP,7,81,106,9
-    DEFPUSHBUTTON   "OK",IDOK,104,7,50,14
-    PUSHBUTTON      "Annuler",IDCANCEL,104,24,50,14
-END
-
-IDD_DIALOG_PROPERTIES DIALOG DISCARDABLE  0, 0, 248, 215
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Propriétés de %s"
-FONT 8, "MS Sans Serif"
-BEGIN
-    DEFPUSHBUTTON   "OK",IDOK,191,7,50,14
-    PUSHBUTTON      "Annuler",IDCANCEL,191,29,50,14
-    LTEXT           "Nom du &fichier:",-1,7,7,59,9
-    EDITTEXT        IDC_STATIC_PROP_FILENAME,71,7,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Chemin com&plet:",-1,7,18,59,9
-    EDITTEXT        IDC_STATIC_PROP_PATH,71,18,120,9, ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Modification:",-1,7,29,59,9
-    EDITTEXT        IDC_STATIC_PROP_LASTCHANGE,71,29,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Version:",-1,7,40,59,9
-    EDITTEXT        IDC_STATIC_PROP_VERSION,71,40,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Cop&yright:",-1,7,51,59,9
-    EDITTEXT        IDC_STATIC_PROP_COPYRIGHT,71,51,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    LTEXT           "Taille:",-1,7,62,59,9
-    EDITTEXT        IDC_STATIC_PROP_SIZE,71,62,120,9,ES_READONLY | NOT WS_BORDER | WS_TABSTOP
-    GROUPBOX        "Attributs",-1,7,79,158,46
-    CONTROL         "Lectu&re seule",IDC_CHECK_READONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,91,68,9
-    CONTROL         "Cac&hé",IDC_CHECK_HIDDEN,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,91,68,9
-    CONTROL         "&Archive",IDC_CHECK_ARCHIVE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,17,101,68,9
-    CONTROL         "&Système",IDC_CHECK_SYSTEM,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,92,101,68,9
-    CONTROL         "&Compressé",IDC_CHECK_COMPRESSED,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,17,111,68,9
-    GROUPBOX        "&Version Information",-1,7,129,234,79
-    LISTBOX         IDC_LIST_PROP_VERSION_TYPES,13,139,107,63,LBS_SORT | LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP
-    EDITTEXT        IDC_LIST_PROP_VERSION_VALUES,123,139,111,63,ES_MULTILINE | ES_READONLY | WS_VSCROLL
-END
-
-
-STRINGTABLE
-{
-    IDS_FONT_SEL_DLG_NAME   "Appliquer les réglages des fontes"
-    IDS_FONT_SEL_ERROR      "Erreur dans la sélection de la nouvelle fonte."
-}
-
-STRINGTABLE
-{
-    IDS_WINEFILE            "Winefile"
-    IDS_ERROR               "Erreur"
-    IDS_ROOT_FS             "root fs"
-    IDS_UNIXFS              "unixfs"
-    IDS_DESKTOP             "Desktop"
-    IDS_SHELL               "Shell"
-    IDS_TITLEFMT            "%s - %s"
-    IDS_NO_IMPL             "Pas encore implémenté"
-    IDS_WINE                "WINE"
-    IDS_WINE_FILE           "Wine File"
-}
-
-STRINGTABLE
-{
-    IDS_COL_NAME            "Nom"
-    IDS_COL_SIZE            "Taille"
-    IDS_COL_CDATE           "CDate"
-    IDS_COL_ADATE           "ADate"
-    IDS_COL_MDATE           "MDate"
-    IDS_COL_IDX             "Index/Inode"
-    IDS_COL_LINKS           "Liens"
-    IDS_COL_ATTR            "Attributs"
-    IDS_COL_SEC             "Sécurité"
-
-    IDS_FREE_SPACE_FMT      "%s sur %s libre"
-}
diff --git a/reactos/subsys/system/winefile/hu.rc b/reactos/subsys/system/winefile/hu.rc
deleted file mode 100644 (file)
index 07193db..0000000
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- * WineFile
- * Hungarian Language Support
- *
- * Copyright 2000 Martin Fuchs
- * Copyright 2002 Steven Edwards
- * Copyright 2002 Alexandre Julliard
- * Copyright 2002 Zoly Nagy
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_HUNGARIAN, SUBLANG_NEUTRAL
-
-/* Menu */
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "&Fájl"  {
-        MENUITEM "&Megynitás\tEnter",           ID_ACTIVATE
-        MENUITEM "Át&helyezés...\tF7",          ID_FILE_MOVE
-        MENUITEM "&Másolás...\tF8",             ID_FILE_COPY
-        MENUITEM "&Vágólapon...\tF9",           118
-        MENUITEM "&Törlés\tDel",                ID_FILE_DELETE
-        MENUITEM "Át&nevezés...",               109
-        MENUITEM "T&ulajdonságok...\tAlt+Enter", ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "&Becsomagolás...",            119
-        MENUITEM "K&icsomagolás...",            120
-        MENUITEM SEPARATOR
-        MENUITEM "&Futtatás...",                ID_EXECUTE
-        MENUITEM "&Nyomtatás...",               102
-        MENUITEM "Társítás...",                 103
-        MENUITEM SEPARATOR
-        MENUITEM "Új &mappa...",                111
-        MENUITEM "Kere&sés...",                 104
-        MENUITEM "Fájlok ki&választása...",     116
-        MENUITEM SEPARATOR
-#ifndef _NO_EXTENSIONS
-        MENUITEM "&Kilépés\tAlt+X",             ID_FILE_EXIT
-#else
-        MENUITEM "&Kilépés",                    ID_FILE_EXIT
-#endif
-    }
-
-    POPUP "&Lemez"  {
-        MENUITEM "Lemez &másolása...",          201
-        MENUITEM "&Lemezcimke...",              202
-        MENUITEM SEPARATOR
-        MENUITEM "&Formatálás...",              ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "&Rendszerlemez készítése...", -1  /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "&Hálózati meghajtó csatlakoztatása",ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "Hálózati meghajtó leválasztása",ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "Megosztás...",                254
-        MENUITEM "Megosztás &megszüntetése...", 255
-        MENUITEM SEPARATOR
-        MENUITEM "Meghajtó ki&választása...",   251
-    }
-
-    POPUP "&Mappák"  {
-        MENUITEM "&Következõ szint\t+",         301
-        MENUITEM "&Fa kinyitása\t*",            302
-        MENUITEM "&Minden kinyitása\tStrg+*",   303
-        MENUITEM "Fa &becsukása\t-",            304
-        MENUITEM SEPARATOR
-        MENUITEM "&Gyermekek kijelölése",       505
-    }
-
-    POPUP "&Nézet"  {
-        MENUITEM "&Teljes",                     413
-        MENUITEM "&Könyvtárfa",                 411
-        MENUITEM "&Csak mappák",                412
-        MENUITEM SEPARATOR
-        MENUITEM "&Felosztás",                  ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "&Név",                        ID_VIEW_NAME
-        MENUITEM "&Minden részlet",             ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "&Egyedi...",                  ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "&Rendezés név szerint",       ID_VIEW_SORT_NAME
-        MENUITEM "Rendezés k&iterjesztés szerint",ID_VIEW_SORT_TYPE
-        MENUITEM "Rendezés &méret szerint",     ID_VIEW_SORT_SIZE
-        MENUITEM "Rendezés &dátum szerint",     ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "Egyedi rendezés &...",        ID_VIEW_FILTER
-    }
-
-    POPUP "&Beállítások"  {
-        MENUITEM "&Megerõsítés...",             501
-        MENUITEM "&Betûkészlet...",             ID_SELECT_FONT
-        MENUITEM "E&gyedi eszköztár...",        512
-        MENUITEM SEPARATOR
-        MENUITEM "&Eszköztár",                  ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "&Lemeztár",                   ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "&Állapotsor",                 ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "&Teljes képernyõs\tCtrl+Shift+S",ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Programfuttatás utáni &szimbólum",504
-        MENUITEM "Megszüntetés a tárolás végén",511
-    }
-
-
-    POPUP "&Biztonság"  {
-        MENUITEM "&Hozzáférés...",              605
-        MENUITEM "&Naplózás...",                606
-        MENUITEM "&Tulajdonos...",              607
-    }
-
-    POPUP "&Ablakok"  {
-        MENUITEM "Új a&blak",                   ID_WINDOW_NEW
-        MENUITEM "Lépcsõzetes elrendezés\tCtrl+F5",ID_WINDOW_CASCADE
-        MENUITEM "Mozaikszerû elrendezés &vízszintesen",ID_WINDOW_TILE_HORZ
-        MENUITEM "Mozaikszerû elrendezés fü&ggõlegesen\tCtrl+F4",ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Automatikus elrendezés",      ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "&Szimbólum elrendezés",       ID_WINDOW_ARRANGE
-        MENUITEM "&Frissítés\tF5",              ID_REFRESH
-    }
-
-    POPUP "&?"  {
-        MENUITEM "&Súgó témakörök\tF1",         ID_HELP
-        MENUITEM "Súgó &keresés...\tF1",        ID_HELP
-        MENUITEM "&Használat\tF1",              ID_HELP_USING
-        MENUITEM SEPARATOR
-        MENUITEM "&Winefile-ról...",            ID_ABOUT
-#ifdef __WINE__
-        MENUITEM "W&ine-ról...",                ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Futtatás"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Parancs:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    CONTROL         "&Szimbólumként", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Mégse", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Súgó", 254, 158, 43, 47, 14
-}
diff --git a/reactos/subsys/system/winefile/images.bmp b/reactos/subsys/system/winefile/images.bmp
deleted file mode 100644 (file)
index aaf3413..0000000
Binary files a/reactos/subsys/system/winefile/images.bmp and /dev/null differ
diff --git a/reactos/subsys/system/winefile/it.rc b/reactos/subsys/system/winefile/it.rc
deleted file mode 100644 (file)
index c7ecc19..0000000
+++ /dev/null
@@ -1,183 +0,0 @@
-/*
- * WineFile
- * Italian Language Support
- *
- * Copyright 2000 Martin Fuchs
- * Copyright 2002 Steven Edwards
- * Copyright 2002 Alexandre Julliard
- * Copyright 2004 Ivan Leo Puoti
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL
-
-/* Menu */
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "&File"  {
-        MENUITEM "&Apri\tInvio",                ID_ACTIVATE
-        MENUITEM "&Sposta...\tF7",              ID_FILE_MOVE
-        MENUITEM "&Copia...\tF8",               ID_FILE_COPY
-        MENUITEM "&Negli Appunti...\tF9",       118
-        MENUITEM "&Cancella\tDel",              ID_FILE_DELETE
-        MENUITEM "Ri&nomina...",                109
-        MENUITEM "Propri&età...\tAlt+Invio",    ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "C&omprimi...",                119
-        MENUITEM "Dec&omprimi...",              120
-        MENUITEM SEPARATOR
-        MENUITEM "&Esegui...",                  ID_EXECUTE
-        MENUITEM "&Stampa...",                  102
-        MENUITEM "Associa...",                  103
-        MENUITEM SEPARATOR
-        MENUITEM "Cr&ea Directory...",          111
-        MENUITEM "Cerc&a...",                   104
-        MENUITEM "&Seleziona i file...",        116
-        MENUITEM SEPARATOR
-#ifndef _NO_EXTENSIONS
-        MENUITEM "E&sci\tAlt+X",                ID_FILE_EXIT
-#else
-        MENUITEM "E&sci",                       ID_FILE_EXIT
-#endif
-    }
-
-    POPUP "&Disco"  {
-        MENUITEM "&Copia Disco...",             201
-        MENUITEM "&Etichetta Disco...",         202
-        MENUITEM SEPARATOR
-        MENUITEM "&Formatta Disco...",          ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "&Crea Disco di Sistema...", -1    /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Connetti & Drive di Rete",    ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "&Disconnetti Drive di Rete",  ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "Condividi come...",           254
-        MENUITEM "&Rimuovi condivisione...",    255
-        MENUITEM SEPARATOR
-        MENUITEM "&Seleziona Drive...",         251
-    }
-
-    POPUP "&Directory"  {
-        MENUITEM "&Livello Sucessivo\t+",       301
-        MENUITEM "Espandi &Albero\t*",          302
-        MENUITEM "Espandi &tutto\tStrg+*",      303
-        MENUITEM "Riduci &Albero\t-",           304
-        MENUITEM SEPARATOR
-        MENUITEM "&Seleziona unità",            505
-    }
-
-    POPUP "&Visualizza"  {
-        MENUITEM "A&lbero e Directory",         413
-        MENUITEM "So&lo Albero",                411
-        MENUITEM "&Solo Directory",             412
-        MENUITEM SEPARATOR
-        MENUITEM "Di&vidi",                     ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "&Nome",                       ID_VIEW_NAME
-        MENUITEM "&Mostra tutti i dettagli sui file",ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "&Mostra dettagli parziali...",ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "&Ordina per Nome",            ID_VIEW_SORT_NAME
-        MENUITEM "&Ordina per Tipo",            ID_VIEW_SORT_TYPE
-        MENUITEM "&Ordina per Dimensione",      ID_VIEW_SORT_SIZE
-        MENUITEM "&Ordina per Data",            ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "Ordina per &...",             ID_VIEW_FILTER
-    }
-
-    POPUP "&Opzioni"  {
-        MENUITEM "&Confermazione...",           501
-        MENUITEM "&Font...",                    ID_SELECT_FONT
-        MENUITEM "&Personalizza barra degli strumenti...", 512
-        MENUITEM SEPARATOR
-        MENUITEM "&Barra degli strumenti",      ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "&Barra dei Drive",            ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "&Barra di stato",             ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "A& tutto schermo\tCtrl+Shift+S",ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "&Esegui minimizzato",         504
-        MENUITEM "&Salva impostazioni all'uscita",511
-    }
-
-
-    POPUP "&Sicurezza"  {
-        MENUITEM "&Accessi...",                 605
-        MENUITEM "&Logging...",                 606
-        MENUITEM "&Proprietario...",            607
-    }
-
-    POPUP "&Finestra"  {
-        MENUITEM "Nuova &Finestra",             ID_WINDOW_NEW
-        MENUITEM "Finestre a cascata\tCtrl+F5", ID_WINDOW_CASCADE
-        MENUITEM "Ordina &Orizontalmente",      ID_WINDOW_TILE_HORZ
-        MENUITEM "Ordina &Verticlmente\tCtrl+F4",ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Disponi automaticamente",     ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "Disponi &Simboli",            ID_WINDOW_ARRANGE
-        MENUITEM "&Aggiorna\tF5",               ID_REFRESH
-    }
-
-    POPUP "&Guida"  {
-        MENUITEM "&Sommario della Guida\tF1",   ID_HELP
-        MENUITEM "&Cerca nella Guida...\tF1",   ID_HELP
-        MENUITEM "&Uso dell Guida\tF1",         ID_HELP_USING
-        MENUITEM SEPARATOR
-        MENUITEM "&Informazioni su Winefile...",ID_ABOUT
-#ifdef __WINE__
-        MENUITEM "Informazioni su &Wine...",    ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Esegui"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Comando:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    CONTROL         "Come &Simbolo", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Annulla", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Aiuto", 254, 158, 43, 47, 14
-}
-
-IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Select destination"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Statico", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Percorso:", -1, "Statico", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Annulla", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Naviga", 254, 158, 43, 47, 14
-}
-
-STRINGTABLE
-{
-    IDS_FONT_SEL_DLG_NAME   "Applica le impostazioni dei font"
-    IDS_FONT_SEL_ERROR      "Si è verificato un errore durante la selezione del nuovo font."
-}
diff --git a/reactos/subsys/system/winefile/license.c b/reactos/subsys/system/winefile/license.c
deleted file mode 100644 (file)
index 12193f8..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Copyright 2000 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
-*/
-
-#include "winefile.h"
-
-#ifdef __WINE__
-
-static const CHAR LicenseCaption[] = "LICENSE";
-static const CHAR License[] =
-"This library is free software; you can redistribute it and/or "
-"modify it under the terms of the GNU Lesser General Public "
-"License as published by the Free Software Foundation; either "
-"version 2.1 of the License, or (at your option) any later version.\n"
-
-"This library is distributed in the hope that it will be useful, "
-"but WITHOUT ANY WARRANTY; without even the implied warranty of "
-"MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU "
-"Lesser General Public License for more details.\n"
-
-"You should have received a copy of the GNU Lesser General Public "
-"License along with this library; if not, write to the Free Software "
-"Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA";
-
-static const CHAR NoWarrantyCaption[] = "NO WARRANTY";
-static const CHAR NoWarranty[] =
-"This library is distributed in the hope that it will be useful, "
-"but WITHOUT ANY WARRANTY; without even the implied warranty of "
-"MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU "
-"Lesser General Public License for more details.";
-
-VOID WineLicense(HWND hwnd)
-{
-  MessageBoxA(hwnd, License, LicenseCaption, MB_ICONINFORMATION|MB_OK);
-}
-
-VOID WineWarranty(HWND hwnd)
-{
-  MessageBoxA(hwnd, NoWarranty, NoWarrantyCaption, MB_ICONEXCLAMATION|MB_OK);
-}
-
-#endif
diff --git a/reactos/subsys/system/winefile/make-docu.sh b/reactos/subsys/system/winefile/make-docu.sh
deleted file mode 100755 (executable)
index 7894b44..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-sed 's/@GEN@/generated on '`date +%d.%m.%Y`/ <doxy-footer.htmt >doxy-footer.html
-doxygen Doxyfile
diff --git a/reactos/subsys/system/winefile/make_winefile.dsp b/reactos/subsys/system/winefile/make_winefile.dsp
deleted file mode 100644 (file)
index bf57867..0000000
+++ /dev/null
@@ -1,93 +0,0 @@
-# Microsoft Developer Studio Project File - Name="make_winefile" - Package Owner=<4>\r
-# Microsoft Developer Studio Generated Build File, Format Version 6.00\r
-# ** DO NOT EDIT **\r
-\r
-# TARGTYPE "Win32 (x86) External Target" 0x0106\r
-\r
-CFG=make_winefile - Win32 Debug\r
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,\r
-!MESSAGE use the Export Makefile command and run\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "make_winefile.mak".\r
-!MESSAGE \r
-!MESSAGE You can specify a configuration when running NMAKE\r
-!MESSAGE by defining the macro CFG on the command line. For example:\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "make_winefile.mak" CFG="make_winefile - Win32 Debug"\r
-!MESSAGE \r
-!MESSAGE Possible choices for configuration are:\r
-!MESSAGE \r
-!MESSAGE "make_winefile - Win32 Release" (based on "Win32 (x86) External Target")\r
-!MESSAGE "make_winefile - Win32 Debug" (based on "Win32 (x86) External Target")\r
-!MESSAGE \r
-\r
-# Begin Project\r
-# PROP AllowPerConfigDependencies 0\r
-# PROP Scc_ProjName ""\r
-# PROP Scc_LocalPath ""\r
-\r
-!IF  "$(CFG)" == "make_winefile - Win32 Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "Release"\r
-# PROP BASE Intermediate_Dir "Release"\r
-# PROP BASE Cmd_Line "NMAKE /f make_winefile.mak"\r
-# PROP BASE Rebuild_Opt "/a"\r
-# PROP BASE Target_File "make_winefile.exe"\r
-# PROP BASE Bsc_Name "make_winefile.bsc"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "Release"\r
-# PROP Intermediate_Dir "Release"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "winefile.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ELSEIF  "$(CFG)" == "make_winefile - Win32 Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Cmd_Line "NMAKE /f make_winefile.mak"\r
-# PROP BASE Rebuild_Opt "/a"\r
-# PROP BASE Target_File "make_winefile.exe"\r
-# PROP BASE Bsc_Name "make_winefile.bsc"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "Debug"\r
-# PROP Intermediate_Dir "Debug"\r
-# PROP Cmd_Line "msdevfilt -gcc -pipe "perl d:\tools\gSTLFilt.pl" make -f Makefile.MinGW DEBUG=1"\r
-# PROP Rebuild_Opt "clean all"\r
-# PROP Target_File "winefile.exe"\r
-# PROP Bsc_Name ""\r
-# PROP Target_Dir ""\r
-\r
-!ENDIF \r
-\r
-# Begin Target\r
-\r
-# Name "make_winefile - Win32 Release"\r
-# Name "make_winefile - Win32 Debug"\r
-\r
-!IF  "$(CFG)" == "make_winefile - Win32 Release"\r
-\r
-!ELSEIF  "$(CFG)" == "make_winefile - Win32 Debug"\r
-\r
-!ENDIF \r
-\r
-# Begin Source File\r
-\r
-SOURCE=.\Makefile.MinGW\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\winefile.xml\r
-# End Source File\r
-# End Target\r
-# End Project\r
diff --git a/reactos/subsys/system/winefile/makel-docu.bat b/reactos/subsys/system/winefile/makel-docu.bat
deleted file mode 100755 (executable)
index c10c03f..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-doxygen Doxyfile
-cmd /c start /b /low /wait hhc doxy-doc\html\index.hhp
-move /y doxy-doc\html\index.chm winefile.chm
diff --git a/reactos/subsys/system/winefile/nl.rc b/reactos/subsys/system/winefile/nl.rc
deleted file mode 100644 (file)
index d593328..0000000
+++ /dev/null
@@ -1,160 +0,0 @@
-/*
- * WineFile (Dutch resources)
- *
- * Copyright 2003 Hans Leidekker
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_DUTCH, SUBLANG_NEUTRAL
-
-/* Menu */
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "&Bestand"  {
-        MENUITEM "&Openen\tEnter",              ID_ACTIVATE
-        MENUITEM "&Verplaatsen...\tF7",         ID_FILE_MOVE
-        MENUITEM "&Kopiëren...\tF8",            ID_FILE_COPY
-        MENUITEM "Naar &klembord...\tF9",       118
-        MENUITEM "Ver&wijderen\tDel",           ID_FILE_DELETE
-        MENUITEM "&Naam wijzigen...",           109
-        MENUITEM "&Eigenschappen...\tAlt+Enter",ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "&Comprimeren...",             119
-        MENUITEM "&Dec&omprimeren...",          120
-        MENUITEM SEPARATOR
-        MENUITEM "&Starten...",                 ID_EXECUTE
-        MENUITEM "Af&drukken...",               102
-        MENUITEM "Koppelen...",                 103
-        MENUITEM SEPARATOR
-        MENUITEM "Nieuwe &map...",              111
-        MENUITEM "&Zoeken...",                  104
-        MENUITEM "Bestanden &selecteren...",    116
-        MENUITEM SEPARATOR
-#ifndef _NO_EXTENSIONS
-        MENUITEM "A&fsluiten\tAlt+X",           ID_FILE_EXIT
-#else
-        MENUITEM "A&fsluiten",                  ID_FILE_EXIT
-#endif
-    }
-
-    POPUP "&Disk"  {
-        MENUITEM "Disk &kopiëren...",           201
-        MENUITEM "Disklabel maken...",          202
-        MENUITEM SEPARATOR
-        MENUITEM "Disk &formatteren...",        ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "Systeemdisk maken...", -1 /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Verbinding &maken met netwerkchijf",ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "Verbinding &verbreken met netwerkschijf",ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "Schijf &delen...",            254
-        MENUITEM "Delen &ongedaan maken...",    255
-        MENUITEM SEPARATOR
-        MENUITEM "Schijf &selecteren...",       251
-    }
-
-    POPUP "&Mappen"  {
-        MENUITEM "&Volgende niveau\t+",         301
-        MENUITEM "&Uitklappen\t*",              302
-        MENUITEM "&Alles uitklappen\tCtrl+*",   303
-        MENUITEM "&Inklappen\t-",               304
-        MENUITEM SEPARATOR
-        MENUITEM "&Markeer mappen",             505
-    }
-
-    POPUP "&Beeld"  {
-        MENUITEM "&Hierarchie en mapinhoud",    413
-        MENUITEM "&Alleen hierarchie",          411
-        MENUITEM "Alleen &mapinhoud",           412
-        MENUITEM SEPARATOR
-        MENUITEM "Sp&litsen",                   ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "&Naam",                       ID_VIEW_NAME
-        MENUITEM "&Alle details",               ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "&Gedeeltelijke details...",   ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "Sorteer op &naam",            ID_VIEW_SORT_NAME
-        MENUITEM "Sorteer op &type",            ID_VIEW_SORT_TYPE
-        MENUITEM "Sorteer op &grootte",         ID_VIEW_SORT_SIZE
-        MENUITEM "Sorteer op &datum",           ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "Sorteer op &...",             ID_VIEW_FILTER
-    }
-
-    POPUP "&Opties"  {
-        MENUITEM "&Bevestiging...",             501
-        MENUITEM "&Lettertype...",              ID_SELECT_FONT
-        MENUITEM "Gereedschappenbalk &aanpassen...", 512
-        MENUITEM SEPARATOR
-        MENUITEM "&Gereedschappenbalk",         ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "&Schijvenbalk",               ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "S&tatusbalk",                 ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "&Volledig scherm\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Ge&minimaliseerd starten",    504
-        MENUITEM "&Instellingen opslaan bij afsluiten", 511
-    }
-
-
-    POPUP "&Beveiliging"  {
-        MENUITEM "&Toegang...",                 605
-        MENUITEM "&Loggen...",                  606
-        MENUITEM "&Eigenaar...",                607
-    }
-
-    POPUP "&Venster"  {
-        MENUITEM "Nieuw &venster",              ID_WINDOW_NEW
-        MENUITEM "Trapsgewijs\tCtrl+F5",        ID_WINDOW_CASCADE
-        MENUITEM "&Boven elkaar",               ID_WINDOW_TILE_HORZ
-        MENUITEM "&Naast elkaar\tCtrl+F4",      ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Automatisch schikken",        ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "&Pictogrammen schikken",      ID_WINDOW_ARRANGE
-        MENUITEM "&Vernieuwen\tF5",             ID_REFRESH
-    }
-
-    POPUP "&?"  {
-        MENUITEM "&Help-onderwerpen\tF1",       ID_HELP
-        MENUITEM "&Zoeken...\tF1",              ID_HELP
-        MENUITEM "&Instructie\tF1",             ID_HELP_USING
-        MENUITEM SEPARATOR
-        MENUITEM "&Over Winefile...",           ID_ABOUT
-#ifdef __WINE__
-        MENUITEM "Over &Wine...",               ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Uitvoeren"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Opdracht:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    CONTROL         "Als &pictogram", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Annuleren", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Help", 254, 158, 43, 47, 14
-}
diff --git a/reactos/subsys/system/winefile/pl.rc b/reactos/subsys/system/winefile/pl.rc
deleted file mode 100644 (file)
index afeaea1..0000000
+++ /dev/null
@@ -1,183 +0,0 @@
-/*\r
- * WineFile\r
- * Polish Language Support\r
- *\r
- * Copyright 2000 Martin Fuchs\r
- * Copyright 2002 Steven Edwards\r
- * Copyright 2002 Alexandre Julliard\r
- * Copyright 2004 Piotr Caban\r
- *\r
- * This library is free software; you can redistribute it and/or\r
- * modify it under the terms of the GNU Lesser General Public\r
- * License as published by the Free Software Foundation; either\r
- * version 2.1 of the License, or (at your option) any later version.\r
- *\r
- * This library is distributed in the hope that it will be useful,\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU\r
- * Lesser General Public License for more details.\r
- *\r
- * You should have received a copy of the GNU Lesser General Public\r
- * License along with this library; if not, write to the Free Software\r
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA\r
- */\r
-\r
-LANGUAGE LANG_POLISH, SUBLANG_NEUTRAL\r
-\r
-/* Menu */\r
-\r
-IDM_WINEFILE MENU FIXED IMPURE\r
-{\r
-    POPUP "&Plik"  {\r
-        MENUITEM "&Otwórz\tEnter",              ID_ACTIVATE\r
-        MENUITEM "&Przenie\9c...\tF7",            ID_FILE_MOVE\r
-        MENUITEM "&Kopiuj...\tF8",              ID_FILE_COPY\r
-        MENUITEM "W s&chowku...\tF9",           118\r
-        MENUITEM "&Usuñ\tDel",                  ID_FILE_DELETE\r
-        MENUITEM "&Zmieñ nazwê...",             109\r
-        MENUITEM "Ustawie&nia...\tAlt+Enter",   ID_EDIT_PROPERTIES\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Kompresja...",               119\r
-        MENUITEM "&Dekompresja...",             120\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Uruchom...",                 ID_EXECUTE\r
-        MENUITEM "&Drukuj...",                  102\r
-        MENUITEM "Skojarz...",                  103\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "U&twórz folder...",           111\r
-        MENUITEM "&Szukaj...",                  104\r
-        MENUITEM "&Zaznacz pliki...",           116\r
-        MENUITEM SEPARATOR\r
-#ifndef _NO_EXTENSIONS\r
-        MENUITEM "&Wyj\9ccie\tAlt+X",             ID_FILE_EXIT\r
-#else\r
-        MENUITEM "&Wyj\9ccie",                    ID_FILE_EXIT\r
-#endif\r
-    }\r
-\r
-    POPUP "&Dysk"  {\r
-        MENUITEM "&Kopiuj dusk...",             201\r
-        MENUITEM "&Etykieta dysku...",          202\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Formatuj dysk...",           ID_FORMAT_DISK\r
-#ifdef _WIN95\r
-        MENUITEM "&Stwórz dysk systemowy...", -1    /*TODO*/\r
-#endif\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Pod³¹cz Dysk Sieciowy",      ID_CONNECT_NETWORK_DRIVE\r
-        MENUITEM "&Od³¹cz Dysk Sieciowy",       ID_DISCONNECT_NETWORK_DRIVE\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Udostêpnij jako...",          254\r
-        MENUITEM "&Nie udostêpniaj...",         255\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Wybór &dysku...",             251\r
-    }\r
-\r
-    POPUP "&Katalogi"  {\r
-        MENUITEM "&Nastêpny poziom\t+",         301\r
-        MENUITEM "&Rozwiñ drzewo\t*",           302\r
-        MENUITEM "Rozwiñ &wszystko\tStrg+*",    303\r
-        MENUITEM "&Zwiñ drzewo\t-",             304\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Zaznacz &podkatalogi",        505\r
-    }\r
-\r
-    POPUP "&Widok"  {\r
-        MENUITEM "&Drzewo i katalogi",          413\r
-        MENUITEM "D&rzewo",                     411\r
-        MENUITEM "&Katalogi",                   412\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Po³¹cz",                     ID_VIEW_SPLIT\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Nazwa",                      ID_VIEW_NAME\r
-        MENUITEM "&Wszystkie atrybuty pliku",   ID_VIEW_ALL_ATTRIBUTES, CHECKED\r
-        MENUITEM "Wybrane &atrybuty pliku...",  ID_VIEW_SELECTED_ATTRIBUTES\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "P&osortuj alfabetycznie",     404\r
-        MENUITEM "Posortuj po &typie",          405\r
-        MENUITEM "Rozmie\9cæ &po wielko\9cci",      406\r
-        MENUITEM "&Sortuj po dacie",            407\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Sortuj po &...",              ID_VIEW_FILTER\r
-    }\r
-\r
-    POPUP "&Opcje"  {\r
-        MENUITEM "&Potwierdzenie...",           501\r
-        MENUITEM "&Czcionka...",                ID_SELECT_FONT\r
-        MENUITEM "&Ustawienia paska narzêdzi...", 512\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "Pasek &narzêdzi",             ID_VIEW_TOOL_BAR, CHECKED\r
-        MENUITEM "Pasek &dysków",               ID_VIEW_DRIVE_BAR, CHECKED\r
-        MENUITEM "Pasek &statusu",              ID_VIEW_STATUSBAR, CHECKED\r
-#ifndef _NO_EXTENSIONS\r
-        MENUITEM "Pe³ny &ekran\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN\r
-#endif\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Zminimalizuj przy starcie",  504\r
-        MENUITEM "Z&apisz ustawienia przed zakoñczeniem",511\r
-    }\r
-\r
-\r
-    POPUP "&Bezpieczeñstwo"  {\r
-        MENUITEM "&Dostêp...",                  605\r
-        MENUITEM "&Logowanie...",               606\r
-        MENUITEM "&W³a\9cciciel...",              607\r
-    }\r
-\r
-    POPUP "&Okno"  {\r
-        MENUITEM "&Nowe okno",                  ID_WINDOW_NEW\r
-        MENUITEM "&Kaskaduj¹co\tCtrl+F5",       ID_WINDOW_CASCADE\r
-        MENUITEM "&Tytu³ pionowo",              ID_WINDOW_TILE_HORZ\r
-        MENUITEM "Tytu³ &poziomo\tCtrl+F4",     ID_WINDOW_TILE_VERT\r
-#ifndef _NO_EXTENSIONS\r
-        MENUITEM "Rozmie\9cæ automatycznie",      ID_WINDOW_AUTOSORT\r
-#endif\r
-        MENUITEM "Rozmie\9cæ &symbole",           ID_WINDOW_ARRANGE\r
-        MENUITEM "&Od\9cwierz\tF5",               ID_REFRESH\r
-    }\r
-\r
-    POPUP "&?"  {\r
-        MENUITEM "&Tematu pomocy\tF1",          ID_HELP\r
-        MENUITEM "&Szukaj...",                  ID_HELP\r
-        MENUITEM "&U¿ywanie pomocy",            ID_HELP_USING\r
-        MENUITEM SEPARATOR\r
-        MENUITEM "&Winefile...",                ID_ABOUT\r
-#ifdef __WINE__\r
-        MENUITEM "W&ine...",                    ID_ABOUT_WINE\r
-#endif\r
-    }\r
-}\r
-\r
-\r
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63\r
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "Uruchom"\r
-FONT 8, "MS Shell Dlg"\r
-{\r
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10\r
-    CONTROL         "&Polecenie:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10\r
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL\r
-    CONTROL         "Jako &symbol", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12\r
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14\r
-    PUSHBUTTON      "Anuluj", 2, 158, 23, 47, 14\r
-    PUSHBUTTON      "&Pomoc", 254, 158, 43, 47, 14\r
-}\r
-\r
-IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63\r
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU\r
-CAPTION "Wybór celu"\r
-FONT 8, "MS Shell Dlg"\r
-{\r
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10\r
-    CONTROL         "&\8ccie¿ka:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10\r
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL\r
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14\r
-    PUSHBUTTON      "Anuluj", 2, 158, 23, 47, 14\r
-    PUSHBUTTON      "&Przegl¹daj", 254, 158, 43, 47, 14\r
-}\r
-\r
-STRINGTABLE\r
-{\r
-    IDS_FONT_SEL_DLG_NAME   "Wprowadzanie ustawieñ czcionki"\r
-    IDS_FONT_SEL_ERROR      "B³¹d przy wybieraniu czcionki"\r
-}\r
diff --git a/reactos/subsys/system/winefile/pt.rc b/reactos/subsys/system/winefile/pt.rc
deleted file mode 100644 (file)
index f97c3da..0000000
+++ /dev/null
@@ -1,335 +0,0 @@
-/*
- * WineFile
- * Portuguese Language Support
- *
- * Copyright 2003 Marcelo Duarte
- * Copyright 2004 Américo José Melo
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
-/* Menu */
-
-LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "&Arquivo"  {
-        MENUITEM "A&brir\tEnter",               ID_ACTIVATE
-        MENUITEM "&Mover...\tF7",               ID_FILE_MOVE
-        MENUITEM "&Copiar...\tF8",              ID_FILE_COPY
-        MENUITEM "&In Clipboard...\tF9",        118
-        MENUITEM "E&xcluir\tDel",               ID_FILE_DELETE
-        MENUITEM "Re&nomear...",                109
-        MENUITEM "&Propriedades...\tAlt+Enter", ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "C&omprimir...",               119
-        MENUITEM "Descomprimir...",             120
-        MENUITEM SEPARATOR
-        MENUITEM "Execu&tar...",                ID_EXECUTE
-        MENUITEM "&Imprimir...",                102
-        MENUITEM "A&ssociar...",                103
-        MENUITEM SEPARATOR
-        MENUITEM "Cri&ar pasta...",             111
-        MENUITEM "P&esquisar...",               104
-        MENUITEM "Selecionar arqui&vos...",     116
-        MENUITEM SEPARATOR
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Sai&r\tAlt+X",                ID_FILE_EXIT
-#else
-        MENUITEM "Sai&r",                       ID_FILE_EXIT
-#endif
-    }
-
-    POPUP "&Disco"  {
-        MENUITEM "&Copiar disco...",            201
-        MENUITEM "&Nomear disco...",            202
-        MENUITEM SEPARATOR
-        MENUITEM "&Formatar disco...",          ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "&Gerar disco de sistema...", -1   /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Conecta&r unidade de rede",   ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "&Desconectar unidade de rede",ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "C&ompartilhar como...",       254
-        MENUITEM "&Remover compartilhamento...",255
-        MENUITEM SEPARATOR
-        MENUITEM "Selecionar &unidade...",      251
-    }
-
-    POPUP "Á&rvore"  {
-        MENUITEM "&Próximo nível\t+",           301
-        MENUITEM "Expandi&r pasta\t*",          302
-        MENUITEM "Expandir &tudo\tStrg+*",      303
-        MENUITEM "Recolher p&asta\t-",          304
-        MENUITEM SEPARATOR
-        MENUITEM "&Indicar subníveis",          505
-    }
-
-    POPUP "&Exibir"  {
-        MENUITEM "Á&rvore e pasta",             413
-        MENUITEM "S&omente árvore",             411
-        MENUITEM "So&mente pasta",              412
-        MENUITEM SEPARATOR
-        MENUITEM "&Dividir",                    ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "&Nome",                       ID_VIEW_NAME
-        MENUITEM "&Todos os delalhes",          ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "D&etalhes parciais...",       ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "&Classificar por nome",       ID_VIEW_SORT_NAME
-        MENUITEM "C&lassificar por tipo",       ID_VIEW_SORT_TYPE
-        MENUITEM "Cl&assificar por tamanho",    ID_VIEW_SORT_SIZE
-        MENUITEM "Cla&ssificar por &data",      ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "Classificar &por...",         ID_VIEW_FILTER
-    }
-
-    POPUP "&Opções"  {
-        MENUITEM "&Confirmação...",             501
-        MENUITEM "&Fonte...",                   ID_SELECT_FONT
-        MENUITEM "&Personalizar barra de ferramentas...", 512
-        MENUITEM SEPARATOR
-        MENUITEM "Barra d&e ferramentas",       ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "&Barra de unidades",          ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "B&arra de &status",           ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Tela Cheia\tCtrl+Shift+S",    ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "&Minimizar durante o uso",    504
-        MENUITEM "&Salvar configurações ao sair",511
-    }
-
-
-    POPUP "&Segurança"  {
-        MENUITEM "&Acesso...",                  605
-        MENUITEM "&Logging...",                 606
-        MENUITEM "&Owner...",                   607
-    }
-
-    POPUP "&Janela"  {
-        MENUITEM "&Nova janela",                ID_WINDOW_NEW
-        MENUITEM "&Em cascata\tCtrl+F5",        ID_WINDOW_CASCADE
-        MENUITEM "Lado a lado &horizontalmente",ID_WINDOW_TILE_HORZ
-        MENUITEM "Lado a lado &verticalmente\tCtrl+F4",ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Organizar automaticamente",   ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "&Organizar ícones",           ID_WINDOW_ARRANGE
-        MENUITEM "&Atualizar\tF5",              ID_REFRESH
-    }
-
-    POPUP "Aj&uda"  {
-        MENUITEM "&Tópicos da ajuda\tF1",       ID_HELP
-        MENUITEM "Pesquisar...",                ID_HELP
-        MENUITEM "&Usando a ajuda",             ID_HELP_USING
-        MENUITEM SEPARATOR
-        MENUITEM "&Sobre o Winefile...",        ID_ABOUT
-#ifdef __WINE__
-        MENUITEM "Sobre o &Wine...",            ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "&Ficheiro"  {
-        MENUITEM "A&brir\tEnter",               ID_ACTIVATE
-        MENUITEM "&Mover...\tF7",               ID_FILE_MOVE
-        MENUITEM "&Copiar...\tF8",              ID_FILE_COPY
-        MENUITEM "&Na Area de Transferencia...\tF9",        118
-        MENUITEM "E&xcluir\tDel",               ID_FILE_DELETE
-        MENUITEM "Re&nomear...",                109
-        MENUITEM "&Propriedades...\tAlt+Enter", ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "C&omprimir...",               119
-        MENUITEM "&Descomprimir...",            120
-        MENUITEM SEPARATOR
-        MENUITEM "Execu&tar...",                ID_EXECUTE
-        MENUITEM "&Imprimir...",                102
-        MENUITEM "A&ssociar...",                103
-        MENUITEM SEPARATOR
-        MENUITEM "Cri&ar pasta...",             111
-        MENUITEM "P&esquisar...",               104
-        MENUITEM "Selecionar fichei&ros...",    116
-        MENUITEM SEPARATOR
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Sai&r\tAlt+X",                ID_FILE_EXIT
-#else
-        MENUITEM "Sai&r",                       ID_FILE_EXIT
-#endif
-    }
-
-    POPUP "&Disco"  {
-        MENUITEM "&Copiar disco...",            201
-        MENUITEM "&Nomear disco...",            202
-        MENUITEM SEPARATOR
-        MENUITEM "&Formatar disco...",          ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "&Gerar disco de sistema...", -1   /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Conecta&r unidade de rede",   ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "&Desconectar unidade de rede",ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "&Partilhar como...",          254
-        MENUITEM "&Remover partilha...",        255
-        MENUITEM SEPARATOR
-        MENUITEM "Seleccionar &unidade...",     251
-    }
-
-    POPUP "Á&rvore"  {
-        MENUITEM "&Próximo nível\t+",           301
-        MENUITEM "Expandi&r pasta\t*",          302
-        MENUITEM "Expandir &tudo\tStrg+*",      303
-        MENUITEM "Recolher p&asta\t-",          304
-        MENUITEM SEPARATOR
-        MENUITEM "&Indicar subníveis",          505
-    }
-
-    POPUP "&Exibir"  {
-        MENUITEM "Á&rvore e pasta",             413
-        MENUITEM "S&omente árvore",             411
-        MENUITEM "So&mente pasta",              412
-        MENUITEM SEPARATOR
-        MENUITEM "&Dividir",                    ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "&Nome",                       ID_VIEW_NAME
-        MENUITEM "&Todos os delalhes",          ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "D&etalhes parciais...",       ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "&Classificar por nome",       ID_VIEW_SORT_NAME
-        MENUITEM "C&lassificar por tipo",       ID_VIEW_SORT_TYPE
-        MENUITEM "Cl&assificar por tamanho",    ID_VIEW_SORT_SIZE
-        MENUITEM "Cla&ssificar por &data",      ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "Classificar &por...",         ID_VIEW_FILTER
-    }
-
-    POPUP "&Opções"  {
-        MENUITEM "&Confirmação...",             501
-        MENUITEM "&Fonte...",                   ID_SELECT_FONT
-        MENUITEM "&Personalizar barra de ferramentas...", 512
-        MENUITEM SEPARATOR
-        MENUITEM "Barra d&e ferramentas",       ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "&Barra de unidades",          ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "B&arra de e&stado",           ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Ecrã Complecto\tCtrl+Shift+S",    ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "&Minimizar durante o uso",    504
-        MENUITEM "&Gravar configurações ao sair",511
-    }
-
-
-    POPUP "&Segurança"  {
-        MENUITEM "&Acesso...",                  605
-        MENUITEM "&Logging...",                 606
-        MENUITEM "&Dono...",                    607
-    }
-
-    POPUP "&Janela"  {
-        MENUITEM "&Nova janela",                ID_WINDOW_NEW
-        MENUITEM "&Em cascata\tCtrl+F5",        ID_WINDOW_CASCADE
-        MENUITEM "Lado a lado &horizontalmente",ID_WINDOW_TILE_HORZ
-        MENUITEM "Lado a lado &verticalmente\tCtrl+F4",ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Organizar automaticamente",   ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "&Organizar ícones",           ID_WINDOW_ARRANGE
-        MENUITEM "&Actualizar\tF5",             ID_REFRESH
-    }
-
-    POPUP "Aj&uda"  {
-        MENUITEM "&Tópicos da ajuda\tF1",       ID_HELP
-        MENUITEM "Pesquisar...",                ID_HELP
-        MENUITEM "&Usando a ajuda",             ID_HELP_USING
-        MENUITEM SEPARATOR
-#ifdef __WINE__
-        MENUITEM "Acerca do &Wine...",          ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-LANGUAGE LANG_PORTUGUESE, SUBLANG_NEUTRAL
-
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Executar"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Comando:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    CONTROL         "&Minimizado", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Cancelar", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Ajuda", 254, 158, 43, 47, 14
-}
-
-IDD_SELECT_DESTINATION DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Selecionar destino"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Caminho:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Cancelar", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Procurar", 254, 158, 43, 47, 14
-}
-
-STRINGTABLE
-{
-    IDS_FONT_SEL_DLG_NAME   "Aplicando configurações de fonte"
-    IDS_FONT_SEL_ERROR      "Erro enquanto seleciona nova fonte."
-}
-
-STRINGTABLE
-{
- IDS_WINEFILE               "Winefile"
- IDS_ERROR                  "Erro"
- IDS_ROOT_FS                "root fs"
- IDS_UNIXFS                 "unixfs"
- IDS_DESKTOP                "Área de trabalho"
- IDS_SHELL                  "Shell"
- IDS_TITLEFMT               "%s - %s"
- IDS_NO_IMPL                "Ainda não implementado"
- IDS_WINE                   "WINE"
- IDS_WINE_FILE              "Wine File"
-}
-
-STRINGTABLE
-{
- IDS_COL_NAME               "Nome"
- IDS_COL_SIZE               "Tamanho"
- IDS_COL_CDATE              "CData"
- IDS_COL_ADATE              "AData"
- IDS_COL_MDATE              "MData"
- IDS_COL_IDX                "Index/Inode"
- IDS_COL_LINKS              "Ligações"
- IDS_COL_ATTR               "Atributos"
- IDS_COL_SEC                "Segurança"
-}
diff --git a/reactos/subsys/system/winefile/resource.h b/reactos/subsys/system/winefile/resource.h
deleted file mode 100644 (file)
index cce4de3..0000000
+++ /dev/null
@@ -1,146 +0,0 @@
-/*
- * Copyright 2000, 2003, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-
-/* images */
-
-#define IDB_TOOLBAR                     100
-#define IDB_DRIVEBAR                    101
-#define IDB_IMAGES                      102
-#define IDI_WINEFILE                    100
-
-
-/* accellerators and menus */
-
-#define IDA_WINEFILE                    101
-#define IDM_WINEFILE                    102
-
-
-/* dialogs */
-
-#define IDD_EXECUTE                     103
-#define IDD_SELECT_DESTINATION          104
-#define IDD_DIALOG_VIEW_TYPE            105
-#define IDD_DIALOG_PROPERTIES           106
-
-
-/* control ids */
-
-#define ID_ACTIVATE                     101
-#define ID_EXECUTE                      105
-#define ID_FILE_MOVE                    106
-#define ID_FILE_COPY                    107
-#define ID_FILE_DELETE                  108
-#define ID_FILE_EXIT                    115
-#define ID_FORMAT_DISK                  203
-#define ID_CONNECT_NETWORK_DRIVE        252
-#define ID_DISCONNECT_NETWORK_DRIVE     253
-#define ID_VIEW_NAME                    401
-#define ID_VIEW_ALL_ATTRIBUTES          402
-#define ID_VIEW_SELECTED_ATTRIBUTES     403
-#define ID_VIEW_SORT_NAME               404
-#define ID_VIEW_SORT_TYPE               405
-#define ID_VIEW_SORT_SIZE               406
-#define ID_VIEW_SORT_DATE               407
-#define ID_VIEW_FILTER                  409
-#define ID_VIEW_SPLIT                   414
-#define ID_SELECT_FONT                  510
-#define ID_VIEW_TOOL_BAR                508
-#define ID_VIEW_DRIVE_BAR               507
-#define ID_VIEW_STATUSBAR               503
-
-#define ID_ABOUT                        1803
-#define ID_REFRESH                      1704
-#define ID_EDIT_PROPERTIES              57656
-#define ID_WINDOW_NEW                   0xE130
-#define ID_WINDOW_ARRANGE               0xE131
-#define ID_WINDOW_CASCADE               0xE132
-#define ID_WINDOW_TILE_HORZ             0xE133
-#define ID_WINDOW_TILE_VERT             0xE134
-#define ID_WINDOW_SPLIT                 0xE135
-#define ID_HELP_USING                   0xE144
-#define ID_HELP                         0xE146
-
-#define IDC_VIEW_PATTERN                1000
-#define IDC_VIEW_TYPE_DIRECTORIES       1001
-#define IDC_VIEW_TYPE_PROGRAMS          1002
-#define IDC_VIEW_TYPE_DOCUMENTS         1003
-#define IDC_VIEW_TYPE_OTHERS            1004
-#define IDC_VIEW_TYPE_HIDDEN            1005
-
-#define IDC_STATIC_PROP_FILENAME        1006
-#define IDC_STATIC_PROP_PATH            1007
-#define IDC_STATIC_PROP_LASTCHANGE      1008
-#define IDC_STATIC_PROP_VERSION         1009
-#define IDC_STATIC_PROP_COPYRIGHT       1010
-#define IDC_STATIC_PROP_SIZE            1011
-#define IDC_CHECK_READONLY              1012
-#define IDC_CHECK_ARCHIVE               1013
-#define IDC_CHECK_COMPRESSED            1014
-#define IDC_CHECK_HIDDEN                1015
-#define IDC_CHECK_SYSTEM                1016
-#define IDC_LIST_PROP_VERSION_TYPES     1017
-#define IDC_LIST_PROP_VERSION_VALUES    1018
-
-
-/* winefile extensions */
-
-#define ID_ABOUT_WINE                   0x8000
-#define ID_LICENSE                      0x8001
-#define ID_NO_WARRANTY                  0x8002
-#define ID_WINDOW_AUTOSORT              0x8003
-#define ID_VIEW_FULLSCREEN              0x8004
-#define ID_PREFERRED_SIZES              0x8005
-
-
-/* string table */
-
-#define IDS_FONT_SEL_DLG_NAME           1101
-#define IDS_FONT_SEL_ERROR              1103
-
-#define IDS_WINEFILE                    1200
-#define IDS_ERROR                       1201
-#define IDS_ROOT_FS                     1202
-#define IDS_UNIXFS                      1203
-#define IDS_DESKTOP                     1204
-#define IDS_SHELL                       1205
-#define IDS_TITLEFMT                    1206
-#define IDS_NO_IMPL                     1207
-#define IDS_WINE                        1208
-#define IDS_WINE_FILE                   1209
-
-#define IDS_COL_NAME                    1210
-#define IDS_COL_SIZE                    1211
-#define IDS_COL_CDATE                   1212
-#define IDS_COL_ADATE                   1213
-#define IDS_COL_MDATE                   1214
-#define IDS_COL_IDX                     1215
-#define IDS_COL_LINKS                   1216
-#define IDS_COL_ATTR                    1217
-#define IDS_COL_SEC                     1218
-#define IDS_FREE_SPACE_FMT              1219
-
-
-/* range for drive bar command ids: 0x9000..0x90FF */
-
-#ifdef __WINE__
-#define ID_DRIVE_UNIX_FS                0x9000
-#endif
-#define ID_DRIVE_SHELL_NS               0x9001
-
-#define ID_DRIVE_FIRST                  0x9002
diff --git a/reactos/subsys/system/winefile/resource.rc b/reactos/subsys/system/winefile/resource.rc
deleted file mode 100644 (file)
index ee73563..0000000
+++ /dev/null
@@ -1,293 +0,0 @@
-/*
- * Copyright 2000 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-IDA_WINEFILE ACCELERATORS DISCARDABLE
-{
-    VK_F1, ID_HELP, VIRTKEY, NOINVERT
-    VK_F5, ID_REFRESH, VIRTKEY, NOINVERT
-    VK_F7, ID_FILE_MOVE, VIRTKEY, NOINVERT
-    VK_F8, ID_FILE_COPY, VIRTKEY, NOINVERT
-    VK_DELETE, ID_FILE_DELETE, VIRTKEY, NOINVERT
-    VK_RETURN, ID_ACTIVATE, VIRTKEY, NOINVERT
-    VK_RETURN, ID_EDIT_PROPERTIES, VIRTKEY, ALT, NOINVERT
-#ifndef _NO_EXTENSIONS
-    "X", ID_FILE_EXIT, VIRTKEY, ALT, NOINVERT
-    "S", ID_VIEW_FULLSCREEN, VIRTKEY, SHIFT, CONTROL, NOINVERT
-    VK_ADD, ID_PREFERRED_SIZES, VIRTKEY, CONTROL, NOINVERT
-#endif
-}
-
-IDI_WINEFILE ICON DISCARDABLE
-#ifdef _WIN32
- "winefile.ico"
-#else
-{
- '00 00 01 00 01 00 20 20 10 00 00 00 00 00 E8 02'
- '00 00 16 00 00 00 28 00 00 00 20 00 00 00 40 00'
- '00 00 01 00 04 00 00 00 00 00 80 02 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 80 00 00 80 00 00 00 80 80 00 80 00'
- '00 00 80 00 80 00 80 80 00 00 C0 C0 C0 00 80 80'
- '80 00 00 00 FF 00 00 FF 00 00 00 FF FF 00 FF 00'
- '00 00 FF 00 FF 00 FF FF 00 00 FF FF FF 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 B7'
- 'B7 B7 B7 B7 B7 B7 B7 70 00 00 00 00 00 00 00 70'
- '00 00 00 00 00 00 0B 73 00 00 00 00 00 00 00 B3'
- 'F7 B7 B7 B7 B7 B7 07 73 30 00 00 00 00 00 00 73'
- 'FB 7B 7B 7B 7B 7B 0B 73 33 00 00 00 00 00 00 B3'
- 'F7 BF FF FF F7 B7 07 73 33 00 00 00 00 00 00 73'
- 'FB 70 33 33 0B 7B 0B 73 33 00 0F FF FF 00 00 B3'
- 'F7 B0 33 33 07 B7 07 73 33 00 F0 00 00 F0 00 73'
- 'FB 70 00 00 0B 7B 0B 73 33 00 00 00 00 00 00 B3'
- 'F7 B7 B7 B7 B7 B7 07 73 33 00 00 00 00 00 00 73'
- 'FF FF FF FF FF FF 0B 73 33 00 00 02 00 00 00 B3'
- '33 33 33 33 33 33 07 73 33 00 00 09 00 00 00 7B'
- '7B 7B 7B 7B 7B 7B 7B 73 33 00 00 99 90 00 00 B0'
- '00 00 00 00 00 00 07 73 33 00 0B BB BB 00 00 73'
- 'FB 7B 7B 7B 7B 7B 0B 73 33 00 BB BB BB B0 00 B3'
- 'F7 B7 B7 B7 B7 B7 07 73 33 00 00 00 E0 00 00 73'
- 'FB 7F FF FF FB 7B 0B 73 33 00 00 00 0E 00 00 B3'
- 'F7 B0 33 33 07 B7 07 73 33 00 00 00 00 00 00 73'
- 'FB 70 33 33 0B 7B 0B 73 33 00 00 00 00 00 00 B3'
- 'F7 B0 00 00 07 B7 07 73 33 00 00 00 00 00 00 73'
- 'FB 7B 7B 7B 7B 7B 0B 73 33 00 00 00 00 00 00 B3'
- 'FF FF FF FF FF FF 07 73 33 00 00 00 00 00 00 73'
- '33 33 33 33 33 33 0B 73 33 00 00 00 00 00 00 B7'
- 'B7 B7 B7 B7 B7 B7 B7 73 33 00 00 00 00 00 00 FF'
- 'FF FF FF FF FF FF FF F3 33 00 00 00 00 00 00 07'
- 'B7 B7 B7 B7 B7 B7 B7 BF 33 00 00 00 00 00 00 00'
- '7B 7B 7B 7B 7B 7B 7B 7B F3 00 00 00 00 00 00 00'
- '07 B7 B7 B7 B7 B7 B7 B7 BF 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 00 00 FF FF'
- 'FF FF 80 00 1F FF 80 00 0F FF 80 00 07 FF 80 00'
- '03 FF 80 00 01 FF 80 00 01 FF 80 00 01 83 80 00'
- '01 39 80 00 01 C7 80 00 01 EF 80 00 01 EF 80 00'
- '01 EF 80 00 01 C7 80 00 01 83 80 00 01 01 80 00'
- '01 F7 80 00 01 FB 80 00 01 FF 80 00 01 FF 80 00'
- '01 FF 80 00 01 FF 80 00 01 FF 80 00 01 FF 80 00'
- '01 FF 80 00 01 FF C0 00 01 FF E0 00 01 FF F0 00'
- '01 FF F8 00 01 FF FF FF FF FF FF FF FF FF'
-}
-#endif
-
-IDB_TOOLBAR BITMAP DISCARDABLE
-#ifdef _WIN32
- "toolbar.bmp"
-#else
-{
- '42 4D BE 03 00 00 00 00 00 00 76 00 00 00 28 00'
- '00 00 70 00 00 00 0F 00 00 00 01 00 04 00 00 00'
- '00 00 48 03 00 00 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 80 00 00 80'
- '00 00 00 80 80 00 80 00 00 00 80 00 80 00 80 80'
- '00 00 C0 C0 C0 00 80 80 80 00 00 00 FF 00 00 FF'
- '00 00 00 FF FF 00 FF 00 00 00 FF 00 FF 00 FF FF'
- '00 00 FF FF FF 00 77 77 77 88 88 88 88 88 77 77'
- '77 77 77 77 77 77 77 88 88 88 88 88 88 87 77 88'
- '88 88 88 88 88 87 77 88 88 88 88 88 88 88 78 88'
- '88 88 88 88 88 87 77 77 77 07 07 07 07 07 77 77'
- '74 44 44 44 44 48 77 77 77 88 88 88 88 88 74 44'
- '44 44 44 44 44 87 74 44 44 44 44 44 44 87 74 44'
- '44 44 44 44 44 48 44 44 44 44 44 44 44 87 77 77'
- '77 77 77 77 77 70 77 77 74 FF FF FF FF 48 77 77'
- '74 44 44 44 44 48 74 FF FF FF FF FF F4 87 74 FF'
- 'FF F4 FF FF F4 87 74 FF FF F4 FF FF FF 48 4F FF'
- 'FF 4F FF FF F4 87 07 07 07 07 77 77 77 77 77 77'
- '74 FF FF FF FF 48 77 77 74 FF FF FF FF 48 74 FF'
- 'FF FF FF FF F4 87 74 FF FF F4 FF FF F4 87 74 FF'
- 'FF F4 FF FF FF 48 4F FF FF 44 44 44 44 87 77 77'
- '77 77 77 77 77 70 77 88 88 88 88 88 FF 48 77 77'
- '84 FF FF FF FF 48 74 FF FF FF FF FF F4 87 74 FF'
- 'FF F4 FF FF F4 87 74 FF FF F4 44 44 44 48 4F FF'
- 'FF 44 44 44 44 87 07 77 77 07 77 77 77 77 74 44'
- '8B 44 44 48 44 48 77 74 44 FF FF FF FF 48 74 44'
- '44 44 44 44 44 87 74 FF FF F4 FF FF F4 87 74 FF'
- 'FF F4 44 44 44 48 4F FF FF 4F FF 4F F4 87 77 77'
- '77 70 70 70 70 70 7B FF 8B FF FF 48 44 47 77 74'
- 'F4 44 44 44 44 48 74 44 44 44 44 44 44 87 74 FF'
- 'FF F4 FF FF F4 87 74 FF FF F4 FF F4 FF 48 44 44'
- '44 44 44 44 44 87 07 77 77 07 07 07 07 07 78 B8'
- '8B F8 BF 48 77 77 77 84 F4 44 44 44 44 47 74 44'
- '44 44 44 44 44 87 74 FF FF F4 FF FF F4 87 74 44'
- '44 44 FF F4 FF 48 44 44 44 44 44 44 44 77 70 70'
- '70 70 70 77 77 77 74 8B 8B 8B FF 48 88 87 74 44'
- 'FF FF FF FF 48 77 74 FF FF FF FF FF F4 87 74 FF'
- 'FF F4 FF FF F4 87 74 44 44 44 FF F4 FF 48 77 77'
- '77 77 77 77 77 77 00 F7 07 07 07 70 70 77 7B B8'
- 'BB B4 44 48 44 87 74 F4 44 44 44 44 48 77 74 FF'
- 'FF FF FF FF F4 87 74 FF FF F4 FF FF F4 87 74 FF'
- 'FF F4 FF F4 FF 48 7C CC 77 CC 77 C7 7C 77 00 F7'
- '78 87 77 77 77 07 74 88 BB B4 44 44 F4 87 74 F4'
- '44 44 44 44 47 77 74 FF FF FF FF FF F4 87 74 FF'
- 'FF F4 FF FF F4 87 74 FF FF F4 FF F4 FF 48 C7 7C'
- '7C 7C 7C 77 C7 C7 70 0F 00 F7 77 77 77 77 77 8B'
- '8B 8B FF FF F4 87 74 FF FF FF FF 48 77 77 74 44'
- '44 44 44 44 44 87 74 44 44 44 44 44 44 87 74 FF'
- 'FF F4 FF F4 FF 48 7C CC 7C 7C 7C 77 C7 C7 77 08'
- '07 77 77 77 77 07 78 B7 8B FF FF FF F4 87 74 44'
- '44 44 44 48 77 77 74 44 44 44 44 44 44 87 74 44'
- '44 44 44 44 44 87 74 44 44 44 44 44 44 48 77 7C'
- '7C 7C 7C 77 C7 C7 77 80 0F 77 77 77 77 77 7B 77'
- '8B 44 8B 44 44 87 74 44 44 44 44 47 77 77 74 44'
- '44 44 44 44 44 77 74 44 44 44 44 44 44 77 74 44'
- '44 44 44 44 44 47 7C C7 7C 7C 7C C7 7C 77 80 07'
- '70 F7 07 07 07 07 77 77 8B 44 54 44 44 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 7C 77 77 77 08 77 70 00 70 70 70 77'
-}
-#endif
-
-IDB_DRIVEBAR BITMAP DISCARDABLE
-#ifdef _WIN32
- "drivebar.bmp"
-#else
-{
- '42 4D E6 02 00 00 00 00 00 00 76 00 00 00 28 00'
- '00 00 60 00 00 00 0D 00 00 00 01 00 04 00 00 00'
- '00 00 70 02 00 00 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 80 00 00 80'
- '00 00 00 80 80 00 80 00 00 00 80 00 80 00 80 80'
- '00 00 C0 C0 C0 00 80 80 80 00 00 00 FF 00 00 FF'
- '00 00 00 FF FF 00 FF 00 00 00 FF 00 FF 00 FF FF'
- '00 00 FF FF FF 00 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 08 88 88 88 88 88 88 80 08 88'
- '88 88 88 88 88 80 08 88 88 88 88 88 88 80 08 88'
- '88 88 88 88 88 80 08 88 88 88 88 88 88 80 08 88'
- '88 88 88 88 88 80 07 70 07 77 77 70 00 80 0F 77'
- '77 77 77 77 77 80 0F 00 77 77 77 77 77 80 0F 77'
- '77 77 77 79 97 80 0F 77 70 00 77 77 77 80 0F 77'
- '07 07 07 07 77 80 07 77 70 07 00 00 77 80 0F 77'
- '70 00 00 07 77 80 0F 00 00 00 00 00 00 80 0F 77'
- '70 00 07 77 77 80 0F 77 77 07 77 77 77 80 0F 70'
- '00 00 00 00 77 80 07 77 77 00 00 77 77 80 0F 00'
- '00 00 00 00 00 80 0F 77 77 77 77 77 77 80 0F 77'
- '07 7F 70 77 77 80 0F 77 70 00 77 77 77 80 0F 70'
- '70 70 70 70 77 80 07 70 00 77 70 00 77 80 0F 77'
- '70 00 00 07 77 80 0F 00 00 00 00 00 00 80 0F 00'
- '87 F8 78 00 77 80 0F 00 00 70 00 00 07 80 0F 70'
- '00 00 00 00 77 80 07 07 77 77 77 70 00 80 0F 77'
- '77 77 77 77 70 80 0F 77 77 77 77 77 77 80 0F 00'
- '00 00 00 00 77 80 0F 77 77 77 77 77 77 80 0F 77'
- '07 07 07 07 77 80 07 77 77 77 77 77 77 80 0F FF'
- 'FF FF FF FF FF 80 0F FF FF FF FF FF FF 80 0F FF'
- 'FF FF FF FF FF 80 0F FF FF FF FF FF FF 80 0F FF'
- 'FF FF FF FF FF 80 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77 77 77 77 77 77 77 77 77 77 77'
- '77 77 77 77 77 77'
-}
-#endif
-
-IDB_IMAGES BITMAP DISCARDABLE
-#ifdef _WIN32
- "images.bmp"
-#else
-{
- '42 4D 86 04 00 00 00 00 00 00 76 00 00 00 28 00'
- '00 00 A0 00 00 00 0D 00 00 00 01 00 04 00 00 00'
- '00 00 10 04 00 00 00 00 00 00 00 00 00 00 00 00'
- '00 00 00 00 00 00 00 00 00 00 00 00 80 00 00 80'
- '00 00 00 80 80 00 80 00 00 00 80 00 80 00 80 80'
- '00 00 C0 C0 C0 00 80 80 80 00 00 00 FF 00 00 FF'
- '00 00 00 FF FF 00 FF 00 00 00 FF 00 FF 00 FF FF'
- '00 00 FF FF FF 00 AA AA 00 00 00 00 00 AA AA AA'
- '00 00 00 00 00 AA AA 00 00 00 00 00 00 00 AA 00'
- '00 00 00 00 00 00 AA A0 00 00 00 00 00 0A AA 00'
- '00 00 00 00 00 00 AA A0 00 00 00 00 00 0A AA A0'
- '00 00 00 00 00 0A AA AA AA AA AA AA AA AA AA AA'
- 'AA AA AA AA AA AA AA A7 77 77 77 77 70 AA AA A7'
- '77 77 77 77 70 AA A7 77 77 77 77 77 77 70 A7 77'
- '77 77 77 77 77 80 AA 77 77 77 77 77 77 0A A7 77'
- '77 77 77 77 77 80 AA 77 77 77 77 77 77 0A AA 77'
- '77 77 77 77 77 0A AA AA AA AA AA AA AA AA AA AA'
- 'AA AA AA AA AA AA AA A7 FF FF FF FF 70 AA AA A7'
- 'FF FF FF FF 70 AA A7 7F 7F 7F 7F 7F 7F 70 A7 FB'
- 'FB FB FB FB FB 80 AA 7F BF BF BF BF B7 0A A7 FB'
- 'FB FB FB FB FB 80 AA 7F BF BF BF BF B7 0A AA 7F'
- 'BF BF BF BF B7 0A AA AA AA 00 00 00 0A AA AA AA'
- 'AA 00 AA AA AA AA AA A7 FF FF FF FF 70 AA AA A7'
- 'FF 44 44 FF 70 AA A7 F7 F7 F7 F7 F7 F7 70 A7 FF'
- 'BF BF BF BF BF 80 A7 FB FB FB FB FB F0 8A A7 FF'
- 'BF B0 BF BF BF 80 A7 FB FB F0 FB FB F0 8A A7 FB'
- 'FB FB FB FB F0 8A AA AA A0 E6 68 86 0A AA AA AA'
- 'A0 E8 0A AA AA AA AA A7 FF FF FF FF 70 AA AA A7'
- 'FF FF FF FF 70 AA A7 7F 7F 7F 7F 7F 7F 70 A7 FB'
- 'FB FB FB FB FB 80 A7 BF BF BF BF BF 70 8A A7 FB'
- 'FB F0 FB FB FB 80 A7 BF B0 00 0F BF 70 8A A7 BF'
- 'B0 00 0F BF 70 8A AA AA A0 E0 00 00 AA AA AA AA'
- 'A0 E8 0A AA AA AA AA A7 FF FF FF FF 70 AA AA A7'
- 'FF 44 44 FF 70 AA A7 F7 F7 F7 F7 F7 F7 70 A7 FF'
- 'BF BF BF BF BF 80 7B FB FB FB FB FB 88 8A A7 FF'
- 'B0 00 00 BF BF 80 7B FB FB 0B FB FB 88 8A 7B FB'
- 'FB FB FB FB 88 8A AA AA A0 E0 AA AA AA AA AA AA'
- 'AA 00 AA AA AA AA AA A7 FF FF FF FF 70 AA AA A7'
- 'FF FF FF FF 70 AA A7 7F 7F 7F 7F 7F 7F 70 A7 FB'
- 'FB FB FB FB FB 80 7F FF FF FF FF F7 0F 8A A7 FB'
- 'FB F0 FB FB FB 80 7F FF FF FF FF F7 0F 8A 7F FF'
- 'FF FF FF F7 0F 8A AA AA A0 E0 AA AA AA AA AA AA'
- 'AA AA AA AA AA AA AA A7 FF FF FF FF 70 AA AA A7'
- 'FF 44 44 FF 70 AA A7 F7 F7 F7 F7 F7 F7 70 A7 FF'
- 'BF BF BF BF BF 80 77 77 77 77 77 78 FB 8A A7 FF'
- 'BF B0 BF BF BF 80 77 77 77 77 77 78 FB 8A 77 77'
- '77 77 77 78 FB 8A AA A0 00 E0 00 AA AA AA AA AA'
- 'AA AA AA AA AA AA AA A7 FF FF FF FF 70 AA AA A7'
- 'FF FF FF FF 70 AA A7 7F 7F 7F 7F 7F 7F 70 A7 FB'
- 'FB FB FB FB FB 80 A7 BF BF BF BF BF BF 8A A7 FB'
- 'FB FB FB FB FB 80 A7 BF BF BF BF BF BF 8A A7 BF'
- 'BF BF BF BF BF 8A AA A0 E6 66 60 AA AA AA AA AA'
- 'AA AA AA AA AA AA AA A7 FF FF F7 77 7A AA AA A7'
- 'FF 44 F7 77 7A AA A7 F7 F7 F7 F7 F7 F7 70 A7 FF'
- 'FF FF FF FF FF 80 A7 FB FB FB FF FF FF 8A A7 FF'
- 'FF FF FF FF FF 80 A7 FB FB FB FF FF FF 8A A7 FB'
- 'FB FB FF FF FF 8A AA AA 0E 66 0A AA AA AA AA AA'
- 'AA AA AA AA AA AA AA A7 FF FF F7 F7 AA AA AA A7'
- 'FF FF F7 F7 AA AA A7 77 77 77 77 77 77 70 A7 FB'
- 'FB FB F7 77 77 8A A7 BF BF BF F7 77 77 8A A7 FB'
- 'FB FB F7 77 77 8A A7 BF BF BF F7 77 77 8A A7 BF'
- 'BF BF F7 77 77 8A AA AA A0 E0 AA AA AA AA AA AA'
- 'AA AA AA AA AA AA AA A7 FF FF F7 7A AA AA AA A7'
- 'FF FF F7 7A AA AA A7 EE EE EE EE EE EE 70 AA 7F'
- 'BF BF 7A AA AA AA AA 7F FF FF 7A AA AA AA AA 7F'
- 'BF BF 7A AA AA AA AA 7F FF FF 7A AA AA AA AA 7F'
- 'FF FF 7A AA AA AA AA AA AA 0A AA AA AA AA AA AA'
- 'AA AA AA AA AA AA AA A7 77 77 77 AA AA AA AA A7'
- '77 77 77 AA AA AA A7 77 77 77 77 77 77 7A AA A7'
- '77 77 AA AA AA AA AA A7 77 77 AA AA AA AA AA A7'
- '77 77 AA AA AA AA AA A7 77 77 AA AA AA AA AA A7'
- '77 77 AA AA AA AA AA AA AA AA AA AA AA AA AA AA'
- 'AA AA AA AA AA AA'
-}
-#endif
diff --git a/reactos/subsys/system/winefile/ru.rc b/reactos/subsys/system/winefile/ru.rc
deleted file mode 100644 (file)
index 26a8fe8..0000000
+++ /dev/null
@@ -1,160 +0,0 @@
-/*
- * WineFile (Russian resources)
- *
- * Copyright 2003 Igor Stepin
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_RUSSIAN, SUBLANG_NEUTRAL
-
-/* Menu */
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "&Ôàéë"  {
-        MENUITEM "&Îòêðûòü\tEnter",             ID_ACTIVATE
-        MENUITEM "&Ïåðåìåñòèòü...\tF7",         ID_FILE_MOVE
-        MENUITEM "&Êîïèðîâàòü...\tF8",          ID_FILE_COPY
-        MENUITEM "& áóôåð îáìåíà...\tF9",      118
-        MENUITEM "&Óäàëèòü\tDel",               ID_FILE_DELETE
-        MENUITEM "Ïåðåèìåíîâàòü...",            109
-        MENUITEM "Ñâîéñòâà...\tAlt+Enter",      ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "Àðõèâèðîâàòü...",             119
-        MENUITEM "Ðàñïàêîâàòü...",              120
-        MENUITEM SEPARATOR
-        MENUITEM "&Çàïóñòèòü...",               ID_EXECUTE
-        MENUITEM "&Ïå÷àòàòü...",                102
-        MENUITEM "Àññîöèèðîâàòü...",            103
-        MENUITEM SEPARATOR
-        MENUITEM "Ñîçäàòü äèðåêòîðèþ...",       111
-        MENUITEM "Ïîèñê...",                    104
-        MENUITEM "&Âûäåëèòü ôàéëû...",          116
-        MENUITEM SEPARATOR
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Âûõîä\tAlt+X",                ID_FILE_EXIT
-#else
-        MENUITEM "Âûõîä",                       ID_FILE_EXIT
-#endif
-    }
-
-    POPUP "&Äèñê"  {
-        MENUITEM "&Êîïèðîâàòü äèñê...",         201
-        MENUITEM "&Ìåòêà òîìà...",              202
-        MENUITEM SEPARATOR
-        MENUITEM "&Ôîðìàòèðîâàòü...",           ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "&Ñîçäàòü ñèñòåìíûé äèñê...", -1   /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Ïîäêëþ&÷èòü ñåòåâîé äèñê",    ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "Îòê&ëþ÷èòü ñåòåâîé äèñê",     ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "Ñäåëàòü î&áùèì êàê...",       254
-        MENUITEM "&Çàêðûòü îáùèé äîñòóï...",    255
-        MENUITEM SEPARATOR
-        MENUITEM "&Âûáðàòü äèñê...",            251
-    }
-
-    POPUP "&Ïàïêè"  {
-        MENUITEM "Ñ&ëåäóþùèé óðîâåíü\t+",       301
-        MENUITEM "&Ðàçâåðíóòü äåðåâî\t*",       302
-        MENUITEM "Ðàçâåðíóòü â&ñå\tStrg+*",     303
-        MENUITEM "&Ñâåðíóòü äåðåâî\t-",         304
-        MENUITEM SEPARATOR
-        MENUITEM "&Îòìåòèòü âåòâè",             505
-    }
-
-    POPUP "&Âèä"  {
-        MENUITEM "Äåðåâî &è ïàïêà",             413
-        MENUITEM "Òîëüêî &äåðåâî",              411
-        MENUITEM "Òîëüêî &ïàïêà",               412
-        MENUITEM SEPARATOR
-        MENUITEM "Ðàç&áèòü",                    ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "È&ìÿ",                        ID_VIEW_NAME
-        MENUITEM "Â&ñå ïîäðîáíîñòè î ôàéëå",    ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "&Âûáîðî÷íî î ôàéëå...",       ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "&Ñîðòèðîâàòü ïî èìåíè",       ID_VIEW_SORT_NAME
-        MENUITEM "Ñîðòèðîâàòü ïî &òèïó",        ID_VIEW_SORT_TYPE
-        MENUITEM "Ñîðòèðîâàòü ïî &ðàçìåðó",     ID_VIEW_SORT_SIZE
-        MENUITEM "Ñîðòèðîâàòü ïî ä&àòå",        ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "Ñîðòèðîâàòü ïî &...",         ID_VIEW_FILTER
-    }
-
-    POPUP "&Íàñòðîéêè"  {
-        MENUITEM "Ïîä&òâåðæäåíèÿ...",           501
-        MENUITEM "&Øðèôò...",                   ID_SELECT_FONT
-        MENUITEM "&Íàñòðîèòü ïàíåëü èíñòðóìåíòîâ...", 512
-        MENUITEM SEPARATOR
-        MENUITEM "&Ïàíåëü èíñòðóìåíòîâ",        ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "Ïàíåëü &äèñêîâ",              ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "&Ñòðîêà ñîñòîÿíèÿ",           ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Ï&îëíûé ýêðàí\tCtrl+Shift+S", ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "&Çíà÷îê â ñïèñîê ïðîãðàìì",   504
-        MENUITEM "Ñî&õðàíÿòü íàñòðîéêè ïðè âûõîäå",511
-    }
-
-
-    POPUP "&Áåçîïàñíîñòü"  {
-        MENUITEM "&Äîñòóï...",                  605
-        MENUITEM "&Ïðîòîêîëû...",               606
-        MENUITEM "&Âëàäåëåö...",                607
-    }
-
-    POPUP "&Îêíî"  {
-        MENUITEM "Íîâîå &îêíî",                 ID_WINDOW_NEW
-        MENUITEM "Îêíà &êàñêàäîì\tCtrl+F5",     ID_WINDOW_CASCADE
-        MENUITEM "Îêíà ñ&âåðõó âíèç",           ID_WINDOW_TILE_HORZ
-        MENUITEM "Îêíà ñ&ëåâà íàïðàâî\tCtrl+F4",ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Ðàñïîëîæèòü &àâòîìàòè÷åñêè",  ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "&Ðàñïîëîæèòü",                ID_WINDOW_ARRANGE
-        MENUITEM "Î&áíîâèòü\tF5",               ID_REFRESH
-    }
-
-    POPUP "&Ñïðàâêà"  {
-        MENUITEM "&Ñîäåðæàíèå\tF1",             ID_HELP
-        MENUITEM "&Ïîèñê...\tF1",               ID_HELP
-        MENUITEM "&Èñïîëüçîâàíèå ñïðàâêè\tF1",  ID_HELP_USING
-        MENUITEM SEPARATOR
-        MENUITEM "&ΠWinefile...",              ID_ABOUT
-#ifdef __WINE__
-        MENUITEM "Π&Wine...",                  ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Âûïîëíèòü"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Êîìàíäà:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    CONTROL         "Êàê &ñèìâîë", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Îòìåíà", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Ñïðàâêà", 254, 158, 43, 47, 14
-}
diff --git a/reactos/subsys/system/winefile/si.rc b/reactos/subsys/system/winefile/si.rc
deleted file mode 100644 (file)
index bcafccb..0000000
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- * WineFile
- * Slovenian Language Support
- *
- * Copyright 2003 Rok Mandeljc <rok.mandeljc@gimb.org>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_SLOVENIAN, SUBLANG_NEUTRAL
-
-/* Menu */
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "&File"  {
-        MENUITEM "&Open\tEnter",                ID_ACTIVATE
-        MENUITEM "&Move...\tF7",                ID_FILE_MOVE
-        MENUITEM "&Copy...\tF8",                ID_FILE_COPY
-        MENUITEM "&In Clipboard...\tF9",        118
-        MENUITEM "&Delete\tDel",                ID_FILE_DELETE
-        MENUITEM "Re&name...",                  109
-        MENUITEM "Propert&ies...\tAlt+Enter",   ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "C&ompress...",                119
-        MENUITEM "Dec&ompress...",              120
-        MENUITEM SEPARATOR
-        MENUITEM "&Run...",                     ID_EXECUTE
-        MENUITEM "&Print...",                   102
-        MENUITEM "Associate...",                103
-        MENUITEM SEPARATOR
-        MENUITEM "Cr&eate Directory...",        111
-        MENUITEM "Searc&h...",                  104
-        MENUITEM "&Select Files...",            116
-        MENUITEM SEPARATOR
-#ifndef _NO_EXTENSIONS
-        MENUITEM "E&xit\tAlt+X",                ID_FILE_EXIT
-#else
-        MENUITEM "E&xit",                       ID_FILE_EXIT
-#endif
-    }
-
-    POPUP "&Disk"  {
-        MENUITEM "&Copy Disk...",               201
-        MENUITEM "&Label Disk...",              202
-        MENUITEM SEPARATOR
-        MENUITEM "&Format Disk...",             ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "&Make System Disk...", -1 /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Connect &Network Drive",      ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "&Disconnect Network Drive",   ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "Share as...",                 254
-        MENUITEM "&Remove Share...",            255
-        MENUITEM SEPARATOR
-        MENUITEM "&Select Drive...",            251
-    }
-
-    POPUP "&Directories"  {
-        MENUITEM "&Next Level\t+",              301
-        MENUITEM "Expand &Tree\t*",             302
-        MENUITEM "Expand &all\tStrg+*",         303
-        MENUITEM "Collapse &Tree\t-",           304
-        MENUITEM SEPARATOR
-        MENUITEM "&Mark Childs",                505
-    }
-
-    POPUP "&View"  {
-        MENUITEM "T&ree and Directory",         413
-        MENUITEM "Tr&ee Only",                  411
-        MENUITEM "Directory &Only",             412
-        MENUITEM SEPARATOR
-        MENUITEM "Sp&lit",                      ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "&Name",                       ID_VIEW_NAME
-        MENUITEM "&All File Details",           ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "&Partial Details...",         ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "&Sort by Name",               ID_VIEW_SORT_NAME
-        MENUITEM "Sort &by Type",               ID_VIEW_SORT_TYPE
-        MENUITEM "Sort by Si&ze",               ID_VIEW_SORT_SIZE
-        MENUITEM "Sort by &Date",               ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "Filter by &...",              ID_VIEW_FILTER
-    }
-
-    POPUP "&Options"  {
-        MENUITEM "&Confirmation...",            501
-        MENUITEM "&Font...",                    ID_SELECT_FONT
-        MENUITEM "Customize Tool&bar...",       512
-        MENUITEM SEPARATOR
-        MENUITEM "&Toolbar",                    ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "&Drivebar",                   ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "&Status Bar",                 ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "F&ull Screen\tCtrl+Shift+S",  ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "&Minize on run",              504
-        MENUITEM "&Save settings on exit",      511
-    }
-
-
-    POPUP "&Security"  {
-        MENUITEM "&Access...",                  605
-        MENUITEM "&Logging...",                 606
-        MENUITEM "&Owner...",                   607
-    }
-
-    POPUP "&Window"  {
-        MENUITEM "New &Window",                 ID_WINDOW_NEW
-        MENUITEM "Cascading\tCtrl+F5",          ID_WINDOW_CASCADE
-        MENUITEM "Tile &Horizontally",          ID_WINDOW_TILE_HORZ
-        MENUITEM "Tile &Vertically\tCtrl+F4",   ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Arrange Automatically",       ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "Arrange &Symbols",            ID_WINDOW_ARRANGE
-        MENUITEM "&Refresh\tF5",                ID_REFRESH
-    }
-
-    POPUP "&?"  {
-        MENUITEM "&Help Topics\tF1",            ID_HELP
-        MENUITEM "Help &Search...\tF1",         ID_HELP
-        MENUITEM "&Using Help\tF1",             ID_HELP_USING
-        MENUITEM SEPARATOR
-        MENUITEM "&Info about Winefile...",     ID_ABOUT
-#ifdef __WINE__
-        MENUITEM "Info about &Wine...",         ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "Execute"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "&Command:", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    CONTROL         "As &Symbol", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12
-    DEFPUSHBUTTON   "OK", 1, 158, 6, 47, 14
-    PUSHBUTTON      "Cancel", 2, 158, 23, 47, 14
-    PUSHBUTTON      "&Help", 254, 158, 43, 47, 14
-}
diff --git a/reactos/subsys/system/winefile/splitpath.c b/reactos/subsys/system/winefile/splitpath.c
deleted file mode 100644 (file)
index 7081f75..0000000
+++ /dev/null
@@ -1,155 +0,0 @@
-/*
- * Copyright 2000, 2004 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-#include "winefile.h"
-
-
-#ifdef __WINE__
-#ifdef UNICODE
-
-void _wsplitpath(const WCHAR* path, WCHAR* drv, WCHAR* dir, WCHAR* name, WCHAR* ext)
-{
-        const WCHAR* end; /* end of processed string */
-       const WCHAR* p;   /* search pointer */
-       const WCHAR* s;   /* copy pointer */
-
-       /* extract drive name */
-       if (path[0] && path[1]==':') {
-               if (drv) {
-                       *drv++ = *path++;
-                       *drv++ = *path++;
-                       *drv = L'\0';
-               }
-       } else if (drv)
-               *drv = L'\0';
-
-       /* search for end of string or stream separator */
-       for(end=path; *end && *end!=L':'; )
-               end++;
-
-       /* search for begin of file extension */
-       for(p=end; p>path && *--p!=L'\\' && *p!=L'/'; )
-               if (*p == L'.') {
-                       end = p;
-                       break;
-               }
-
-       if (ext)
-               for(s=end; (*ext=*s++); )
-                       ext++;
-
-       /* search for end of directory name */
-       for(p=end; p>path; )
-               if (*--p=='\\' || *p=='/') {
-                       p++;
-                       break;
-               }
-
-       if (name) {
-               for(s=p; s<end; )
-                       *name++ = *s++;
-
-               *name = L'\0';
-       }
-
-       if (dir) {
-               for(s=path; s<p; )
-                       *dir++ = *s++;
-
-               *dir = L'\0';
-       }
-}
-
-#else /* UNICODE */
-
-void _splitpath(const CHAR* path, CHAR* drv, CHAR* dir, CHAR* name, CHAR* ext)
-{
-        const CHAR* end; /* end of processed string */
-       const CHAR* p;   /* search pointer */
-       const CHAR* s;   /* copy pointer */
-
-       /* extract drive name */
-       if (path[0] && path[1]==':') {
-               if (drv) {
-                       *drv++ = *path++;
-                       *drv++ = *path++;
-                       *drv = '\0';
-               }
-       } else if (drv)
-               *drv = '\0';
-
-       /* search for end of string or stream separator */
-       for(end=path; *end && *end!=':'; )
-               end++;
-
-       /* search for begin of file extension */
-       for(p=end; p>path && *--p!='\\' && *p!='/'; )
-               if (*p == '.') {
-                       end = p;
-                       break;
-               }
-
-       if (ext)
-               for(s=end; (*ext=*s++); )
-                       ext++;
-
-       /* search for end of directory name */
-       for(p=end; p>path; )
-               if (*--p=='\\' || *p=='/') {
-                       p++;
-                       break;
-               }
-
-       if (name) {
-               for(s=p; s<end; )
-                       *name++ = *s++;
-
-               *name = '\0';
-       }
-
-       if (dir) {
-               for(s=path; s<p; )
-                       *dir++ = *s++;
-
-               *dir = '\0';
-       }
-}
-
-#endif /* UNICODE */
-#endif /* __WINE__ */
-
-
-/*
-void main()    // test splipath()
-{
-       TCHAR drv[_MAX_DRIVE+1], dir[_MAX_DIR], name[_MAX_FNAME], ext[_MAX_EXT];
-
-       _tsplitpath(L"x\\y", drv, dir, name, ext);
-       _tsplitpath(L"x\\", drv, dir, name, ext);
-       _tsplitpath(L"\\x", drv, dir, name, ext);
-       _tsplitpath(L"x", drv, dir, name, ext);
-       _tsplitpath(L"", drv, dir, name, ext);
-       _tsplitpath(L".x", drv, dir, name, ext);
-       _tsplitpath(L":x", drv, dir, name, ext);
-       _tsplitpath(L"a:x", drv, dir, name, ext);
-       _tsplitpath(L"a.b:x", drv, dir, name, ext);
-       _tsplitpath(L"W:\\/\\abc/Z:~", drv, dir, name, ext);
-       _tsplitpath(L"abc.EFGH:12345", drv, dir, name, ext);
-       _tsplitpath(L"C:/dos/command.com", drv, dir, name, ext);
-}
-*/
diff --git a/reactos/subsys/system/winefile/toolbar.bmp b/reactos/subsys/system/winefile/toolbar.bmp
deleted file mode 100644 (file)
index c0c0032..0000000
Binary files a/reactos/subsys/system/winefile/toolbar.bmp and /dev/null differ
diff --git a/reactos/subsys/system/winefile/winefile.c b/reactos/subsys/system/winefile/winefile.c
deleted file mode 100644 (file)
index 395876b..0000000
+++ /dev/null
@@ -1,4880 +0,0 @@
-/*
- * Winefile
- *
- * Copyright 2000, 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-#ifdef __WINE__
-#include "config.h"
-#include "wine/port.h"
-
-/* for unix filesystem function calls */
-#include <sys/stat.h>
-#include <sys/types.h>
-#include <dirent.h>
-#endif
-
-#define COBJMACROS
-
-#include "winefile.h"
-
-#include "resource.h"
-
-
-#ifdef _NO_EXTENSIONS
-#undef _LEFT_FILES
-#endif
-
-#ifndef _MAX_PATH
-#define _MAX_DRIVE          3
-#define _MAX_FNAME          256
-#define _MAX_DIR            _MAX_FNAME
-#define _MAX_EXT            _MAX_FNAME
-#define _MAX_PATH           260
-#endif
-
-#ifdef NONAMELESSUNION
-#define        UNION_MEMBER(x) DUMMYUNIONNAME.x
-#else
-#define        UNION_MEMBER(x) x
-#endif
-
-
-#ifdef _SHELL_FOLDERS
-#define        DEFAULT_SPLIT_POS       300
-#else
-#define        DEFAULT_SPLIT_POS       200
-#endif
-
-
-enum ENTRY_TYPE {
-       ET_WINDOWS,
-       ET_UNIX,
-#ifdef _SHELL_FOLDERS
-       ET_SHELL
-#endif
-};
-
-typedef struct _Entry {
-       struct _Entry*  next;
-       struct _Entry*  down;
-       struct _Entry*  up;
-
-       BOOL                    expanded;
-       BOOL                    scanned;
-       int                             level;
-
-       WIN32_FIND_DATA data;
-
-#ifndef _NO_EXTENSIONS
-       BY_HANDLE_FILE_INFORMATION bhfi;
-       BOOL                    bhfi_valid;
-       enum ENTRY_TYPE etype;
-#endif
-#ifdef _SHELL_FOLDERS
-       LPITEMIDLIST    pidl;
-       IShellFolder*   folder;
-       HICON                   hicon;
-#endif
-} Entry;
-
-typedef struct {
-       Entry   entry;
-       TCHAR   path[MAX_PATH];
-       TCHAR   volname[_MAX_FNAME];
-       TCHAR   fs[_MAX_DIR];
-       DWORD   drive_type;
-       DWORD   fs_flags;
-} Root;
-
-enum COLUMN_FLAGS {
-       COL_SIZE                = 0x01,
-       COL_DATE                = 0x02,
-       COL_TIME                = 0x04,
-       COL_ATTRIBUTES  = 0x08,
-       COL_DOSNAMES    = 0x10,
-#ifdef _NO_EXTENSIONS
-       COL_ALL = COL_SIZE|COL_DATE|COL_TIME|COL_ATTRIBUTES|COL_DOSNAMES
-#else
-       COL_INDEX               = 0x20,
-       COL_LINKS               = 0x40,
-       COL_ALL = COL_SIZE|COL_DATE|COL_TIME|COL_ATTRIBUTES|COL_DOSNAMES|COL_INDEX|COL_LINKS
-#endif
-};
-
-typedef enum {
-       SORT_NAME,
-       SORT_EXT,
-       SORT_SIZE,
-       SORT_DATE
-} SORT_ORDER;
-
-typedef struct {
-       HWND    hwnd;
-#ifndef _NO_EXTENSIONS
-       HWND    hwndHeader;
-#endif
-
-#ifndef _NO_EXTENSIONS
-#define        COLUMNS 10
-#else
-#define        COLUMNS 5
-#endif
-       int             widths[COLUMNS];
-       int             positions[COLUMNS+1];
-
-       BOOL    treePane;
-       int             visible_cols;
-       Entry*  root;
-       Entry*  cur;
-} Pane;
-
-typedef struct {
-       HWND    hwnd;
-       Pane    left;
-       Pane    right;
-       int             focus_pane;             /* 0: left  1: right */
-       WINDOWPLACEMENT pos;
-       int             split_pos;
-       BOOL    header_wdths_ok;
-
-       TCHAR   path[MAX_PATH];
-       TCHAR   filter_pattern[MAX_PATH];
-       int             filter_flags;
-       Root    root;
-
-       SORT_ORDER sortOrder;
-} ChildWnd;
-
-
-
-static void read_directory(Entry* dir, LPCTSTR path, SORT_ORDER sortOrder, HWND hwnd);
-static void set_curdir(ChildWnd* child, Entry* entry, int idx, HWND hwnd);
-static void refresh_child(ChildWnd* child);
-static void refresh_drives(void);
-static void get_path(Entry* dir, PTSTR path);
-static void format_date(const FILETIME* ft, TCHAR* buffer, int visible_cols);
-
-static LRESULT CALLBACK FrameWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-static LRESULT CALLBACK ChildWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-static LRESULT CALLBACK TreeWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-
-
-/* globals */
-WINEFILE_GLOBALS Globals;
-
-static int last_split;
-
-
-/* some common string constants */
-const static TCHAR sEmpty[] = {'\0'};
-const static TCHAR sSpace[] = {' ', '\0'};
-const static TCHAR sNumFmt[] = {'%','d','\0'};
-const static TCHAR sQMarks[] = {'?','?','?','\0'};
-
-/* window class names */
-const static TCHAR sWINEFILEFRAME[] = {'W','F','S','_','F','r','a','m','e','\0'};
-const static TCHAR sWINEFILETREE[] = {'W','F','S','_','T','r','e','e','\0'};
-
-#ifdef _MSC_VER
-/* #define LONGLONGARG _T("I64") */
-const static TCHAR sLongHexFmt[] = {'%','I','6','4','X','\0'};
-const static TCHAR sLongNumFmt[] = {'%','I','6','4','d','\0'};
-#else
-/* #define LONGLONGARG _T("L") */
-const static TCHAR sLongHexFmt[] = {'%','L','X','\0'};
-const static TCHAR sLongNumFmt[] = {'%','L','d','\0'};
-#endif
-
-
-/* load resource string */
-static LPTSTR load_string(LPTSTR buffer, UINT id)
-{
-       LoadString(Globals.hInstance, id, buffer, BUFFER_LEN);
-
-       return buffer;
-}
-
-#define        RS(b, i) load_string(b, i)
-
-
-/* display error message for the specified WIN32 error code */
-static void display_error(HWND hwnd, DWORD error)
-{
-       TCHAR b1[BUFFER_LEN], b2[BUFFER_LEN];
-       PTSTR msg;
-
-       if (FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER|FORMAT_MESSAGE_FROM_SYSTEM,
-               0, error, MAKELANGID(LANG_NEUTRAL,SUBLANG_DEFAULT), (PTSTR)&msg, 0, NULL))
-               MessageBox(hwnd, msg, RS(b2,IDS_WINEFILE), MB_OK);
-       else
-               MessageBox(hwnd, RS(b1,IDS_ERROR), RS(b2,IDS_WINEFILE), MB_OK);
-
-       LocalFree(msg);
-}
-
-
-/* display network error message using WNetGetLastError() */
-static void display_network_error(HWND hwnd)
-{
-       TCHAR msg[BUFFER_LEN], provider[BUFFER_LEN], b2[BUFFER_LEN];
-       DWORD error;
-
-       if (WNetGetLastError(&error, msg, BUFFER_LEN, provider, BUFFER_LEN) == NO_ERROR)
-               MessageBox(hwnd, msg, RS(b2,IDS_WINEFILE), MB_OK);
-}
-
-
-#ifdef __WINE__
-
-#ifdef UNICODE
-
-/* call vswprintf() in msvcrt.dll */
-/*TODO: fix swprintf() in non-msvcrt mode, so that this dynamic linking function can be removed */
-static int msvcrt_swprintf(WCHAR* buffer, const WCHAR* fmt, ...)
-{
-       static int (__cdecl *pvswprintf)(WCHAR*, const WCHAR*, va_list) = NULL;
-       va_list ap;
-       int ret;
-
-       if (!pvswprintf) {
-               HMODULE hModMsvcrt = LoadLibraryA("msvcrt");
-               pvswprintf = (int(__cdecl*)(WCHAR*,const WCHAR*,va_list)) GetProcAddress(hModMsvcrt, "vswprintf");
-       }
-
-       va_start(ap, fmt);
-       ret = (*pvswprintf)(buffer, fmt, ap);
-       va_end(ap);
-
-       return ret;
-}
-
-static LPCWSTR my_wcsrchr(LPCWSTR str, WCHAR c)
-{
-       LPCWSTR p = str;
-
-       while(*p)
-               ++p;
-
-       do {
-               if (--p < str)
-                       return NULL;
-       } while(*p != c);
-
-       return p;
-}
-
-#define _tcsrchr my_wcsrchr
-#else  /* UNICODE */
-#define _tcsrchr strrchr
-#endif /* UNICODE */
-
-#endif /* __WINE__ */
-
-
-/* allocate and initialise a directory entry */
-static Entry* alloc_entry(void)
-{
-       Entry* entry = (Entry*) malloc(sizeof(Entry));
-
-#ifdef _SHELL_FOLDERS
-       entry->pidl = NULL;
-       entry->folder = NULL;
-       entry->hicon = 0;
-#endif
-
-       return entry;
-}
-
-/* free a directory entry */
-static void free_entry(Entry* entry)
-{
-#ifdef _SHELL_FOLDERS
-       if (entry->hicon && entry->hicon!=(HICON)-1)
-               DestroyIcon(entry->hicon);
-
-       if (entry->folder && entry->folder!=Globals.iDesktop)
-               IShellFolder_Release(entry->folder);
-
-       if (entry->pidl)
-               IMalloc_Free(Globals.iMalloc, entry->pidl);
-#endif
-
-       free(entry);
-}
-
-/* recursively free all child entries */
-static void free_entries(Entry* dir)
-{
-       Entry *entry, *next=dir->down;
-
-       if (next) {
-               dir->down = 0;
-
-               do {
-                       entry = next;
-                       next = entry->next;
-
-                       free_entries(entry);
-                       free_entry(entry);
-               } while(next);
-       }
-}
-
-
-static void read_directory_win(Entry* dir, LPCTSTR path)
-{
-       Entry* first_entry = NULL;
-       Entry* last = NULL;
-       Entry* entry;
-
-       int level = dir->level + 1;
-       WIN32_FIND_DATA w32fd;
-       HANDLE hFind;
-#ifndef _NO_EXTENSIONS
-       HANDLE hFile;
-#endif
-
-       TCHAR buffer[MAX_PATH], *p;
-       for(p=buffer; *path; )
-               *p++ = *path++;
-
-       *p++ = '\\';
-       p[0] = '*';
-       p[1] = '\0';
-
-       hFind = FindFirstFile(buffer, &w32fd);
-
-       if (hFind != INVALID_HANDLE_VALUE) {
-               do {
-#ifdef _NO_EXTENSIONS
-                       /* hide directory entry "." */
-                       if (w32fd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-                               LPCTSTR name = w32fd.cFileName;
-
-                               if (name[0]=='.' && name[1]=='\0')
-                                       continue;
-                       }
-#endif
-                       entry = alloc_entry();
-
-                       if (!first_entry)
-                               first_entry = entry;
-
-                       if (last)
-                               last->next = entry;
-
-                       memcpy(&entry->data, &w32fd, sizeof(WIN32_FIND_DATA));
-                       entry->down = NULL;
-                       entry->up = dir;
-                       entry->expanded = FALSE;
-                       entry->scanned = FALSE;
-                       entry->level = level;
-
-#ifndef _NO_EXTENSIONS
-                       entry->etype = ET_WINDOWS;
-                       entry->bhfi_valid = FALSE;
-
-                       lstrcpy(p, entry->data.cFileName);
-
-                       hFile = CreateFile(buffer, GENERIC_READ, FILE_SHARE_READ|FILE_SHARE_WRITE|FILE_SHARE_DELETE,
-                                                               0, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, 0);
-
-                       if (hFile != INVALID_HANDLE_VALUE) {
-                               if (GetFileInformationByHandle(hFile, &entry->bhfi))
-                                       entry->bhfi_valid = TRUE;
-
-                               CloseHandle(hFile);
-                       }
-#endif
-
-                       last = entry;
-               } while(FindNextFile(hFind, &w32fd));
-
-               if (last)
-                       last->next = NULL;
-
-               FindClose(hFind);
-       }
-
-       dir->down = first_entry;
-       dir->scanned = TRUE;
-}
-
-
-static Entry* find_entry_win(Entry* dir, LPCTSTR name)
-{
-       Entry* entry;
-
-       for(entry=dir->down; entry; entry=entry->next) {
-               LPCTSTR p = name;
-               LPCTSTR q = entry->data.cFileName;
-
-               do {
-                       if (!*p || *p==TEXT('\\') || *p==TEXT('/'))
-                               return entry;
-               } while(tolower(*p++) == tolower(*q++));
-
-               p = name;
-               q = entry->data.cAlternateFileName;
-
-               do {
-                       if (!*p || *p==TEXT('\\') || *p==TEXT('/'))
-                               return entry;
-               } while(tolower(*p++) == tolower(*q++));
-       }
-
-       return 0;
-}
-
-
-static Entry* read_tree_win(Root* root, LPCTSTR path, SORT_ORDER sortOrder, HWND hwnd)
-{
-       TCHAR buffer[MAX_PATH];
-       Entry* entry = &root->entry;
-       LPCTSTR s = path;
-       PTSTR d = buffer;
-
-       HCURSOR old_cursor = SetCursor(LoadCursor(0, IDC_WAIT));
-
-#ifndef _NO_EXTENSIONS
-       entry->etype = ET_WINDOWS;
-#endif
-
-       while(entry) {
-               while(*s && *s!=TEXT('\\') && *s!=TEXT('/'))
-                       *d++ = *s++;
-
-               while(*s==TEXT('\\') || *s==TEXT('/'))
-                       s++;
-
-               *d++ = TEXT('\\');
-               *d = TEXT('\0');
-
-               read_directory(entry, buffer, sortOrder, hwnd);
-
-               if (entry->down)
-                       entry->expanded = TRUE;
-
-               if (!*s)
-                       break;
-
-               entry = find_entry_win(entry, s);
-       }
-
-       SetCursor(old_cursor);
-
-       return entry;
-}
-
-
-#if !defined(_NO_EXTENSIONS) && defined(__WINE__)
-
-static BOOL time_to_filetime(const time_t* t, FILETIME* ftime)
-{
-       struct tm* tm = gmtime(t);
-       SYSTEMTIME stime;
-
-       if (!tm)
-               return FALSE;
-
-       stime.wYear = tm->tm_year+1900;
-       stime.wMonth = tm->tm_mon+1;
-       /* stime.wDayOfWeek */
-       stime.wDay = tm->tm_mday;
-       stime.wHour = tm->tm_hour;
-       stime.wMinute = tm->tm_min;
-       stime.wSecond = tm->tm_sec;
-
-       return SystemTimeToFileTime(&stime, ftime);
-}
-
-static void read_directory_unix(Entry* dir, LPCTSTR path)
-{
-       Entry* first_entry = NULL;
-       Entry* last = NULL;
-       Entry* entry;
-       DIR* pdir;
-
-       int level = dir->level + 1;
-#ifdef UNICODE
-       char cpath[MAX_PATH];
-
-       WideCharToMultiByte(CP_UNIXCP, 0, path, -1, cpath, MAX_PATH, NULL, NULL);
-#else
-       const char* cpath = path;
-#endif
-
-       pdir = opendir(cpath);
-
-       if (pdir) {
-               struct stat st;
-               struct dirent* ent;
-               char buffer[MAX_PATH], *p;
-               const char* s;
-
-               for(p=buffer,s=cpath; *s; )
-                       *p++ = *s++;
-
-               if (p==buffer || p[-1]!='/')
-                       *p++ = '/';
-
-               while((ent=readdir(pdir))) {
-                       entry = alloc_entry();
-
-                       if (!first_entry)
-                               first_entry = entry;
-
-                       if (last)
-                               last->next = entry;
-
-                       entry->etype = ET_UNIX;
-
-                       strcpy(p, ent->d_name);
-#ifdef UNICODE
-                       MultiByteToWideChar(CP_UNIXCP, 0, p, -1, entry->data.cFileName, MAX_PATH);
-#else
-                       lstrcpy(entry->data.cFileName, p);
-#endif
-
-                       if (!stat(buffer, &st)) {
-                               entry->data.dwFileAttributes = p[0]=='.'? FILE_ATTRIBUTE_HIDDEN: 0;
-
-                               if (S_ISDIR(st.st_mode))
-                                       entry->data.dwFileAttributes |= FILE_ATTRIBUTE_DIRECTORY;
-
-                               entry->data.nFileSizeLow = st.st_size & 0xFFFFFFFF;
-                               entry->data.nFileSizeHigh = st.st_size >> 32;
-
-                               memset(&entry->data.ftCreationTime, 0, sizeof(FILETIME));
-                               time_to_filetime(&st.st_atime, &entry->data.ftLastAccessTime);
-                               time_to_filetime(&st.st_mtime, &entry->data.ftLastWriteTime);
-
-                               entry->bhfi.nFileIndexLow = ent->d_ino;
-                               entry->bhfi.nFileIndexHigh = 0;
-
-                               entry->bhfi.nNumberOfLinks = st.st_nlink;
-
-                               entry->bhfi_valid = TRUE;
-                       } else {
-                               entry->data.nFileSizeLow = 0;
-                               entry->data.nFileSizeHigh = 0;
-                               entry->bhfi_valid = FALSE;
-                       }
-
-                       entry->down = NULL;
-                       entry->up = dir;
-                       entry->expanded = FALSE;
-                       entry->scanned = FALSE;
-                       entry->level = level;
-
-                       last = entry;
-               }
-
-               if (last)
-                       last->next = NULL;
-
-               closedir(pdir);
-       }
-
-       dir->down = first_entry;
-       dir->scanned = TRUE;
-}
-
-static Entry* find_entry_unix(Entry* dir, LPCTSTR name)
-{
-       Entry* entry;
-
-       for(entry=dir->down; entry; entry=entry->next) {
-               LPCTSTR p = name;
-               LPCTSTR q = entry->data.cFileName;
-
-               do {
-                       if (!*p || *p==TEXT('/'))
-                               return entry;
-               } while(*p++ == *q++);
-       }
-
-       return 0;
-}
-
-static Entry* read_tree_unix(Root* root, LPCTSTR path, SORT_ORDER sortOrder, HWND hwnd)
-{
-       TCHAR buffer[MAX_PATH];
-       Entry* entry = &root->entry;
-       LPCTSTR s = path;
-       PTSTR d = buffer;
-
-       HCURSOR old_cursor = SetCursor(LoadCursor(0, IDC_WAIT));
-
-       entry->etype = ET_UNIX;
-
-       while(entry) {
-               while(*s && *s!=TEXT('/'))
-                       *d++ = *s++;
-
-               while(*s == TEXT('/'))
-                       s++;
-
-               *d++ = TEXT('/');
-               *d = TEXT('\0');
-
-               read_directory(entry, buffer, sortOrder, hwnd);
-
-               if (entry->down)
-                       entry->expanded = TRUE;
-
-               if (!*s)
-                       break;
-
-               entry = find_entry_unix(entry, s);
-       }
-
-       SetCursor(old_cursor);
-
-       return entry;
-}
-
-#endif /* !defined(_NO_EXTENSIONS) && defined(__WINE__) */
-
-
-#ifdef _SHELL_FOLDERS
-
-#ifdef UNICODE
-#define        get_strret get_strretW
-#define        path_from_pidl path_from_pidlW
-#else
-#define        get_strret get_strretA
-#define        path_from_pidl path_from_pidlA
-#endif
-
-
-static void free_strret(STRRET* str)
-{
-       if (str->uType == STRRET_WSTR)
-               IMalloc_Free(Globals.iMalloc, str->UNION_MEMBER(pOleStr));
-}
-
-
-#ifndef UNICODE
-
-static LPSTR strcpyn(LPSTR dest, LPCSTR source, size_t count)
-{
- LPCSTR s;
- LPSTR d = dest;
-
- for(s=source; count&&(*d++=*s++); )
-  count--;
-
- return dest;
-}
-
-static void get_strretA(STRRET* str, const SHITEMID* shiid, LPSTR buffer, int len)
-{
- switch(str->uType) {
-  case STRRET_WSTR:
-       WideCharToMultiByte(CP_ACP, 0, str->UNION_MEMBER(pOleStr), -1, buffer, len, NULL, NULL);
-       break;
-
-  case STRRET_OFFSET:
-       strcpyn(buffer, (LPCSTR)shiid+str->UNION_MEMBER(uOffset), len);
-       break;
-
-  case STRRET_CSTR:
-       strcpyn(buffer, str->UNION_MEMBER(cStr), len);
- }
-}
-
-static HRESULT path_from_pidlA(IShellFolder* folder, LPITEMIDLIST pidl, LPSTR buffer, int len)
-{
-       STRRET str;
-
-        /* SHGDN_FORPARSING: get full path of id list */
-       HRESULT hr = IShellFolder_GetDisplayNameOf(folder, pidl, SHGDN_FORPARSING, &str);
-
-       if (SUCCEEDED(hr)) {
-               get_strretA(&str, &pidl->mkid, buffer, len);
-               free_strret(&str);
-       } else
-               buffer[0] = '\0';
-
-       return hr;
-}
-
-#endif
-
-static LPWSTR wcscpyn(LPWSTR dest, LPCWSTR source, size_t count)
-{
- LPCWSTR s;
- LPWSTR d = dest;
-
- for(s=source; count&&(*d++=*s++); )
-  count--;
-
- return dest;
-}
-
-static void get_strretW(STRRET* str, const SHITEMID* shiid, LPWSTR buffer, int len)
-{
- switch(str->uType) {
-  case STRRET_WSTR:
-       wcscpyn(buffer, str->UNION_MEMBER(pOleStr), len);
-       break;
-
-  case STRRET_OFFSET:
-       MultiByteToWideChar(CP_ACP, 0, (LPCSTR)shiid+str->UNION_MEMBER(uOffset), -1, buffer, len);
-       break;
-
-  case STRRET_CSTR:
-       MultiByteToWideChar(CP_ACP, 0, str->UNION_MEMBER(cStr), -1, buffer, len);
- }
-}
-
-
-static HRESULT name_from_pidl(IShellFolder* folder, LPITEMIDLIST pidl, LPTSTR buffer, int len, SHGDNF flags)
-{
-       STRRET str;
-
-       HRESULT hr = IShellFolder_GetDisplayNameOf(folder, pidl, flags, &str);
-
-       if (SUCCEEDED(hr)) {
-               get_strret(&str, &pidl->mkid, buffer, len);
-               free_strret(&str);
-       } else
-               buffer[0] = '\0';
-
-       return hr;
-}
-
-
-static HRESULT path_from_pidlW(IShellFolder* folder, LPITEMIDLIST pidl, LPWSTR buffer, int len)
-{
-       STRRET str;
-
-        /* SHGDN_FORPARSING: get full path of id list */
-       HRESULT hr = IShellFolder_GetDisplayNameOf(folder, pidl, SHGDN_FORPARSING, &str);
-
-       if (SUCCEEDED(hr)) {
-               get_strretW(&str, &pidl->mkid, buffer, len);
-               free_strret(&str);
-       } else
-               buffer[0] = '\0';
-
-       return hr;
-}
-
-
- /* create an item id list from a file system path */
-
-static LPITEMIDLIST get_path_pidl(LPTSTR path, HWND hwnd)
-{
-       LPITEMIDLIST pidl;
-       HRESULT hr;
-       ULONG len;
-
-#ifdef UNICODE
-       LPWSTR buffer = path;
-#else
-       WCHAR buffer[MAX_PATH];
-       MultiByteToWideChar(CP_ACP, 0, path, -1, buffer, MAX_PATH);
-#endif
-
-       hr = IShellFolder_ParseDisplayName(Globals.iDesktop, hwnd, NULL, buffer, &len, &pidl, NULL);
-       if (FAILED(hr))
-               return NULL;
-
-       return pidl;
-}
-
-
- /* convert an item id list from relative to absolute (=relative to the desktop) format */
-
-static LPITEMIDLIST get_to_absolute_pidl(Entry* entry, HWND hwnd)
-{
-       if (entry->up && entry->up->etype==ET_SHELL) {
-               IShellFolder* folder = entry->up->folder;
-               WCHAR buffer[MAX_PATH];
-
-               HRESULT hr = path_from_pidlW(folder, entry->pidl, buffer, MAX_PATH);
-
-               if (SUCCEEDED(hr)) {
-                       LPITEMIDLIST pidl;
-                       ULONG len;
-
-                       hr = IShellFolder_ParseDisplayName(Globals.iDesktop, hwnd, NULL, buffer, &len, &pidl, NULL);
-
-                       if (SUCCEEDED(hr))
-                               return pidl;
-               }
-       } else if (entry->etype == ET_WINDOWS) {
-               TCHAR path[MAX_PATH];
-
-               get_path(entry, path);
-
-               return get_path_pidl(path, hwnd);
-       } else if (entry->pidl)
-               return ILClone(entry->pidl);
-
-       return NULL;
-}
-
-
-static HICON extract_icon(IShellFolder* folder, LPCITEMIDLIST pidl)
-{
-       IExtractIcon* pExtract;
-
-       if (SUCCEEDED(IShellFolder_GetUIObjectOf(folder, 0, 1, (LPCITEMIDLIST*)&pidl, &IID_IExtractIcon, 0, (LPVOID*)&pExtract))) {
-               TCHAR path[_MAX_PATH];
-               unsigned flags;
-               HICON hicon;
-               int idx;
-
-               if (SUCCEEDED((*pExtract->lpVtbl->GetIconLocation)(pExtract, GIL_FORSHELL, path, _MAX_PATH, &idx, &flags))) {
-                       if (!(flags & GIL_NOTFILENAME)) {
-                               if (idx == -1)
-                                       idx = 0;        /* special case for some control panel applications */
-
-                               if ((int)ExtractIconEx(path, idx, 0, &hicon, 1) > 0)
-                                       flags &= ~GIL_DONTCACHE;
-                       } else {
-                               HICON hIconLarge = 0;
-
-                               HRESULT hr = (*pExtract->lpVtbl->Extract)(pExtract, path, idx, &hIconLarge, &hicon, MAKELONG(0/*GetSystemMetrics(SM_CXICON)*/,GetSystemMetrics(SM_CXSMICON)));
-
-                               if (SUCCEEDED(hr))
-                                       DestroyIcon(hIconLarge);
-                       }
-
-                       return hicon;
-               }
-       }
-
-       return 0;
-}
-
-
-static Entry* find_entry_shell(Entry* dir, LPCITEMIDLIST pidl)
-{
-       Entry* entry;
-
-       for(entry=dir->down; entry; entry=entry->next) {
-               if (entry->pidl->mkid.cb == pidl->mkid.cb &&
-                       !memcmp(entry->pidl, pidl, entry->pidl->mkid.cb))
-                       return entry;
-       }
-
-       return 0;
-}
-
-static Entry* read_tree_shell(Root* root, LPITEMIDLIST pidl, SORT_ORDER sortOrder, HWND hwnd)
-{
-       Entry* entry = &root->entry;
-       Entry* next;
-       LPITEMIDLIST next_pidl = pidl;
-       IShellFolder* folder;
-       IShellFolder* child = NULL;
-       HRESULT hr;
-
-       HCURSOR old_cursor = SetCursor(LoadCursor(0, IDC_WAIT));
-
-#ifndef _NO_EXTENSIONS
-       entry->etype = ET_SHELL;
-#endif
-
-       folder = Globals.iDesktop;
-
-       while(entry) {
-               entry->pidl = next_pidl;
-               entry->folder = folder;
-
-               if (!pidl->mkid.cb)
-                       break;
-
-                /* copy first element of item idlist */
-               next_pidl = IMalloc_Alloc(Globals.iMalloc, pidl->mkid.cb+sizeof(USHORT));
-               memcpy(next_pidl, pidl, pidl->mkid.cb);
-               ((LPITEMIDLIST)((LPBYTE)next_pidl+pidl->mkid.cb))->mkid.cb = 0;
-
-               hr = IShellFolder_BindToObject(folder, next_pidl, 0, &IID_IShellFolder, (void**)&child);
-               if (!SUCCEEDED(hr))
-                       break;
-
-               read_directory(entry, NULL, sortOrder, hwnd);
-
-               if (entry->down)
-                       entry->expanded = TRUE;
-
-               next = find_entry_shell(entry, next_pidl);
-               if (!next)
-                       break;
-
-               folder = child;
-               entry = next;
-
-                /* go to next element */
-               pidl = (LPITEMIDLIST) ((LPBYTE)pidl+pidl->mkid.cb);
-       }
-
-       SetCursor(old_cursor);
-
-       return entry;
-}
-
-
-static void fill_w32fdata_shell(IShellFolder* folder, LPCITEMIDLIST pidl, SFGAOF attribs, WIN32_FIND_DATA* w32fdata)
-{
-       if (!(attribs & SFGAO_FILESYSTEM) ||
-                 FAILED(SHGetDataFromIDList(folder, pidl, SHGDFIL_FINDDATA, w32fdata, sizeof(WIN32_FIND_DATA)))) {
-               WIN32_FILE_ATTRIBUTE_DATA fad;
-               IDataObject* pDataObj;
-
-               STGMEDIUM medium = {0, {0}, 0};
-               FORMATETC fmt = {Globals.cfStrFName, 0, DVASPECT_CONTENT, -1, TYMED_HGLOBAL};
-
-               HRESULT hr = IShellFolder_GetUIObjectOf(folder, 0, 1, &pidl, &IID_IDataObject, 0, (LPVOID*)&pDataObj);
-
-               if (SUCCEEDED(hr)) {
-                       hr = IDataObject_GetData(pDataObj, &fmt, &medium);
-
-                       IDataObject_Release(pDataObj);
-
-                       if (SUCCEEDED(hr)) {
-                               LPCTSTR path = (LPCTSTR)GlobalLock(medium.UNION_MEMBER(hGlobal));
-                               UINT sem_org = SetErrorMode(SEM_FAILCRITICALERRORS);
-
-                               if (GetFileAttributesEx(path, GetFileExInfoStandard, &fad)) {
-                                       w32fdata->dwFileAttributes = fad.dwFileAttributes;
-                                       w32fdata->ftCreationTime = fad.ftCreationTime;
-                                       w32fdata->ftLastAccessTime = fad.ftLastAccessTime;
-                                       w32fdata->ftLastWriteTime = fad.ftLastWriteTime;
-
-                                       if (!(fad.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)) {
-                                               w32fdata->nFileSizeLow = fad.nFileSizeLow;
-                                               w32fdata->nFileSizeHigh = fad.nFileSizeHigh;
-                                       }
-                               }
-
-                               SetErrorMode(sem_org);
-
-                               GlobalUnlock(medium.UNION_MEMBER(hGlobal));
-                               GlobalFree(medium.UNION_MEMBER(hGlobal));
-                       }
-               }
-       }
-
-       if (attribs & (SFGAO_FOLDER|SFGAO_HASSUBFOLDER))
-               w32fdata->dwFileAttributes |= FILE_ATTRIBUTE_DIRECTORY;
-
-       if (attribs & SFGAO_READONLY)
-               w32fdata->dwFileAttributes |= FILE_ATTRIBUTE_READONLY;
-
-       if (attribs & SFGAO_COMPRESSED)
-               w32fdata->dwFileAttributes |= FILE_ATTRIBUTE_COMPRESSED;
-}
-
-
-static void read_directory_shell(Entry* dir, HWND hwnd)
-{
-       IShellFolder* folder = dir->folder;
-       int level = dir->level + 1;
-       HRESULT hr;
-
-       IShellFolder* child;
-       IEnumIDList* idlist;
-
-       Entry* first_entry = NULL;
-       Entry* last = NULL;
-       Entry* entry;
-
-       if (!folder)
-               return;
-
-       hr = IShellFolder_EnumObjects(folder, hwnd, SHCONTF_FOLDERS|SHCONTF_NONFOLDERS|SHCONTF_INCLUDEHIDDEN|SHCONTF_SHAREABLE|SHCONTF_STORAGE, &idlist);
-
-       if (SUCCEEDED(hr)) {
-               for(;;) {
-#define        FETCH_ITEM_COUNT        32
-                       LPITEMIDLIST pidls[FETCH_ITEM_COUNT];
-                       SFGAOF attribs;
-                       ULONG cnt = 0;
-                       ULONG n;
-
-                       memset(pidls, 0, sizeof(pidls));
-
-                       hr = IEnumIDList_Next(idlist, FETCH_ITEM_COUNT, pidls, &cnt);
-                       if (!SUCCEEDED(hr))
-                               break;
-
-                       if (hr == S_FALSE)
-                               break;
-
-                       for(n=0; n<cnt; ++n) {
-                               entry = alloc_entry();
-
-                               if (!first_entry)
-                                       first_entry = entry;
-
-                               if (last)
-                                       last->next = entry;
-
-                               memset(&entry->data, 0, sizeof(WIN32_FIND_DATA));
-                               entry->bhfi_valid = FALSE;
-
-                               attribs = ~SFGAO_FILESYSTEM;    /*SFGAO_HASSUBFOLDER|SFGAO_FOLDER; SFGAO_FILESYSTEM sorgt dafür, daß "My Documents" anstatt von "Martin's Documents" angezeigt wird */
-
-                               hr = IShellFolder_GetAttributesOf(folder, 1, (LPCITEMIDLIST*)&pidls[n], &attribs);
-
-                               if (SUCCEEDED(hr)) {
-                                       if (attribs != (SFGAOF)~SFGAO_FILESYSTEM) {
-                                               fill_w32fdata_shell(folder, pidls[n], attribs, &entry->data);
-
-                                               entry->bhfi_valid = TRUE;
-                                       } else
-                                               attribs = 0;
-                               } else
-                                       attribs = 0;
-
-                               entry->pidl = pidls[n];
-
-                               if (entry->data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-                                       hr = IShellFolder_BindToObject(folder, pidls[n], 0, &IID_IShellFolder, (void**)&child);
-
-                                       if (SUCCEEDED(hr))
-                                               entry->folder = child;
-                                       else
-                                               entry->folder = NULL;
-                               }
-                               else
-                                       entry->folder = NULL;
-
-                               if (!entry->data.cFileName[0])
-                                       /*hr = */name_from_pidl(folder, pidls[n], entry->data.cFileName, MAX_PATH, /*SHGDN_INFOLDER*/0x2000/*0x2000=SHGDN_INCLUDE_NONFILESYS*/);
-
-                                /* get display icons for files and virtual objects */
-                               if (!(entry->data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) ||
-                                       !(attribs & SFGAO_FILESYSTEM)) {
-                                       entry->hicon = extract_icon(folder, pidls[n]);
-
-                                       if (!entry->hicon)
-                                               entry->hicon = (HICON)-1;       /* don't try again later */
-                               }
-
-                               entry->down = NULL;
-                               entry->up = dir;
-                               entry->expanded = FALSE;
-                               entry->scanned = FALSE;
-                               entry->level = level;
-
-#ifndef _NO_EXTENSIONS
-                               entry->etype = ET_SHELL;
-                               entry->bhfi_valid = FALSE;
-#endif
-
-                               last = entry;
-                       }
-               }
-
-               IEnumIDList_Release(idlist);
-       }
-
-       if (last)
-               last->next = NULL;
-
-       dir->down = first_entry;
-       dir->scanned = TRUE;
-}
-
-#endif /* _SHELL_FOLDERS */
-
-
-/* sort order for different directory/file types */
-enum TYPE_ORDER {
-       TO_DIR = 0,
-       TO_DOT = 1,
-       TO_DOTDOT = 2,
-       TO_OTHER_DIR = 3,
-       TO_FILE = 4
-};
-
-/* distinguish between ".", ".." and any other directory names */
-static int TypeOrderFromDirname(LPCTSTR name)
-{
-       if (name[0] == '.') {
-               if (name[1] == '\0')
-                       return TO_DOT;  /* "." */
-
-               if (name[1]=='.' && name[2]=='\0')
-                       return TO_DOTDOT;       /* ".." */
-       }
-
-       return TO_OTHER_DIR;    /* anything else */
-}
-
-/* directories first... */
-static int __cdecl compareType(const WIN32_FIND_DATA* fd1, const WIN32_FIND_DATA* fd2)
-{
-       int order1 = fd1->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY? TO_DIR: TO_FILE;
-       int order2 = fd2->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY? TO_DIR: TO_FILE;
-
-       /* Handle "." and ".." as special case and move them at the very first beginning. */
-       if (order1==TO_DIR && order2==TO_DIR) {
-               order1 = TypeOrderFromDirname(fd1->cFileName);
-               order2 = TypeOrderFromDirname(fd2->cFileName);
-       }
-
-       return order2==order1? 0: order1<order2? -1: 1;
-}
-
-
-static int __cdecl compareName(const void* arg1, const void* arg2)
-{
-       const WIN32_FIND_DATA* fd1 = &(*(const Entry* const*)arg1)->data;
-       const WIN32_FIND_DATA* fd2 = &(*(const Entry* const*)arg2)->data;
-
-       int cmp = compareType(fd1, fd2);
-       if (cmp)
-               return cmp;
-
-       return lstrcmpi(fd1->cFileName, fd2->cFileName);
-}
-
-static int __cdecl compareExt(const void* arg1, const void* arg2)
-{
-       const WIN32_FIND_DATA* fd1 = &(*(const Entry* const*)arg1)->data;
-       const WIN32_FIND_DATA* fd2 = &(*(const Entry* const*)arg2)->data;
-       const TCHAR *name1, *name2, *ext1, *ext2;
-
-       int cmp = compareType(fd1, fd2);
-       if (cmp)
-               return cmp;
-
-       name1 = fd1->cFileName;
-       name2 = fd2->cFileName;
-
-       ext1 = _tcsrchr(name1, TEXT('.'));
-       ext2 = _tcsrchr(name2, TEXT('.'));
-
-       if (ext1)
-               ext1++;
-       else
-               ext1 = sEmpty;
-
-       if (ext2)
-               ext2++;
-       else
-               ext2 = sEmpty;
-
-       cmp = lstrcmpi(ext1, ext2);
-       if (cmp)
-               return cmp;
-
-       return lstrcmpi(name1, name2);
-}
-
-static int __cdecl compareSize(const void* arg1, const void* arg2)
-{
-       const WIN32_FIND_DATA* fd1 = &(*(const Entry* const*)arg1)->data;
-       const WIN32_FIND_DATA* fd2 = &(*(const Entry* const*)arg2)->data;
-
-       int cmp = compareType(fd1, fd2);
-       if (cmp)
-               return cmp;
-
-       cmp = fd2->nFileSizeHigh - fd1->nFileSizeHigh;
-
-       if (cmp < 0)
-               return -1;
-       else if (cmp > 0)
-               return 1;
-
-       cmp = fd2->nFileSizeLow - fd1->nFileSizeLow;
-
-       return cmp<0? -1: cmp>0? 1: 0;
-}
-
-static int __cdecl compareDate(const void* arg1, const void* arg2)
-{
-       const WIN32_FIND_DATA* fd1 = &(*(const Entry* const*)arg1)->data;
-       const WIN32_FIND_DATA* fd2 = &(*(const Entry* const*)arg2)->data;
-
-       int cmp = compareType(fd1, fd2);
-       if (cmp)
-               return cmp;
-
-       return CompareFileTime(&fd2->ftLastWriteTime, &fd1->ftLastWriteTime);
-}
-
-
-static int (__cdecl *sortFunctions[])(const void* arg1, const void* arg2) = {
-       compareName,    /* SORT_NAME */
-       compareExt,             /* SORT_EXT */
-       compareSize,    /* SORT_SIZE */
-       compareDate             /* SORT_DATE */
-};
-
-
-static void SortDirectory(Entry* dir, SORT_ORDER sortOrder)
-{
-       Entry* entry = dir->down;
-       Entry** array, **p;
-       int len;
-
-       len = 0;
-       for(entry=dir->down; entry; entry=entry->next)
-               len++;
-
-       if (len) {
-               array = HeapAlloc(GetProcessHeap(), 0, len*sizeof(Entry*));
-
-               p = array;
-               for(entry=dir->down; entry; entry=entry->next)
-                       *p++ = entry;
-
-               /* call qsort with the appropriate compare function */
-               qsort(array, len, sizeof(array[0]), sortFunctions[sortOrder]);
-
-               dir->down = array[0];
-
-               for(p=array; --len; p++)
-                       p[0]->next = p[1];
-
-               (*p)->next = 0;
-
-               HeapFree(GetProcessHeap(), 0, array);
-       }
-}
-
-
-static void read_directory(Entry* dir, LPCTSTR path, SORT_ORDER sortOrder, HWND hwnd)
-{
-       TCHAR buffer[MAX_PATH];
-       Entry* entry;
-       LPCTSTR s;
-       PTSTR d;
-
-#ifdef _SHELL_FOLDERS
-       if (dir->etype == ET_SHELL)
-       {
-               read_directory_shell(dir, hwnd);
-
-               if (Globals.prescan_node) {
-                       s = path;
-                       d = buffer;
-
-                       while(*s)
-                               *d++ = *s++;
-
-                       *d++ = TEXT('\\');
-
-                       for(entry=dir->down; entry; entry=entry->next)
-                               if (entry->data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-                                       read_directory_shell(entry, hwnd);
-                                       SortDirectory(entry, sortOrder);
-                               }
-               }
-       }
-       else
-#endif
-#if !defined(_NO_EXTENSIONS) && defined(__WINE__)
-       if (dir->etype == ET_UNIX)
-       {
-               read_directory_unix(dir, path);
-
-               if (Globals.prescan_node) {
-                       s = path;
-                       d = buffer;
-
-                       while(*s)
-                               *d++ = *s++;
-
-                       *d++ = TEXT('/');
-
-                       for(entry=dir->down; entry; entry=entry->next)
-                               if (entry->data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-                                       lstrcpy(d, entry->data.cFileName);
-                                       read_directory_unix(entry, buffer);
-                                       SortDirectory(entry, sortOrder);
-                               }
-               }
-       }
-       else
-#endif
-       {
-               read_directory_win(dir, path);
-
-               if (Globals.prescan_node) {
-                       s = path;
-                       d = buffer;
-
-                       while(*s)
-                               *d++ = *s++;
-
-                       *d++ = TEXT('\\');
-
-                       for(entry=dir->down; entry; entry=entry->next)
-                               if (entry->data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-                                       lstrcpy(d, entry->data.cFileName);
-                                       read_directory_win(entry, buffer);
-                                       SortDirectory(entry, sortOrder);
-                               }
-               }
-       }
-
-       SortDirectory(dir, sortOrder);
-}
-
-
-static Entry* read_tree(Root* root, LPCTSTR path, LPITEMIDLIST pidl, LPTSTR drv, SORT_ORDER sortOrder, HWND hwnd)
-{
-#if !defined(_NO_EXTENSIONS) && defined(__WINE__)
-       const static TCHAR sSlash[] = {'/', '\0'};
-#endif
-       const static TCHAR sBackslash[] = {'\\', '\0'};
-
-#ifdef _SHELL_FOLDERS
-       if (pidl)
-       {
-                /* read shell namespace tree */
-               root->drive_type = DRIVE_UNKNOWN;
-               drv[0] = '\\';
-               drv[1] = '\0';
-               load_string(root->volname, IDS_DESKTOP);
-               root->fs_flags = 0;
-               load_string(root->fs, IDS_SHELL);
-
-               return read_tree_shell(root, pidl, sortOrder, hwnd);
-       }
-       else
-#endif
-#if !defined(_NO_EXTENSIONS) && defined(__WINE__)
-       if (*path == '/')
-       {
-                /* read unix file system tree */
-               root->drive_type = GetDriveType(path);
-
-               lstrcat(drv, sSlash);
-               load_string(root->volname, IDS_ROOT_FS);
-               root->fs_flags = 0;
-               load_string(root->fs, IDS_UNIXFS);
-
-               lstrcpy(root->path, sSlash);
-
-               return read_tree_unix(root, path, sortOrder, hwnd);
-       }
-#endif
-
-        /* read WIN32 file system tree */
-       root->drive_type = GetDriveType(path);
-
-       lstrcat(drv, sBackslash);
-       GetVolumeInformation(drv, root->volname, _MAX_FNAME, 0, 0, &root->fs_flags, root->fs, _MAX_DIR);
-
-       lstrcpy(root->path, drv);
-
-       return read_tree_win(root, path, sortOrder, hwnd);
-}
-
-
-/* flags to filter different file types */
-enum TYPE_FILTER {
-       TF_DIRECTORIES  = 0x01,
-       TF_PROGRAMS             = 0x02,
-       TF_DOCUMENTS    = 0x04,
-       TF_OTHERS               = 0x08,
-       TF_HIDDEN               = 0x10,
-       TF_ALL                  = 0x1F
-};
-
-
-static ChildWnd* alloc_child_window(LPCTSTR path, LPITEMIDLIST pidl, HWND hwnd)
-{
-       TCHAR drv[_MAX_DRIVE+1], dir[_MAX_DIR], name[_MAX_FNAME], ext[_MAX_EXT];
-       TCHAR b1[BUFFER_LEN];
-       const static TCHAR sAsterics[] = {'*', '\0'};
-
-       ChildWnd* child = (ChildWnd*) malloc(sizeof(ChildWnd));
-       Root* root = &child->root;
-       Entry* entry;
-
-       memset(child, 0, sizeof(ChildWnd));
-
-       child->left.treePane = TRUE;
-       child->left.visible_cols = 0;
-
-       child->right.treePane = FALSE;
-#ifndef _NO_EXTENSIONS
-       child->right.visible_cols = COL_SIZE|COL_DATE|COL_TIME|COL_ATTRIBUTES|COL_INDEX|COL_LINKS;
-#else
-       child->right.visible_cols = COL_SIZE|COL_DATE|COL_TIME|COL_ATTRIBUTES;
-#endif
-
-       child->pos.length = sizeof(WINDOWPLACEMENT);
-       child->pos.flags = 0;
-       child->pos.showCmd = SW_SHOWNORMAL;
-       child->pos.rcNormalPosition.left = CW_USEDEFAULT;
-       child->pos.rcNormalPosition.top = CW_USEDEFAULT;
-       child->pos.rcNormalPosition.right = CW_USEDEFAULT;
-       child->pos.rcNormalPosition.bottom = CW_USEDEFAULT;
-
-       child->focus_pane = 0;
-       child->split_pos = DEFAULT_SPLIT_POS;
-       child->sortOrder = SORT_NAME;
-       child->header_wdths_ok = FALSE;
-
-       if (path)
-       {
-               lstrcpy(child->path, path);
-
-               _tsplitpath(path, drv, dir, name, ext);
-       }
-
-       lstrcpy(child->filter_pattern, sAsterics);
-       child->filter_flags = TF_ALL;
-
-       root->entry.level = 0;
-
-       entry = read_tree(root, path, pidl, drv, child->sortOrder, hwnd);
-
-#ifdef _SHELL_FOLDERS
-       if (root->entry.etype == ET_SHELL)
-               load_string(root->entry.data.cFileName, IDS_DESKTOP);
-       else
-#endif
-               wsprintf(root->entry.data.cFileName, RS(b1,IDS_TITLEFMT), drv, root->fs);
-
-       root->entry.data.dwFileAttributes = FILE_ATTRIBUTE_DIRECTORY;
-
-       child->left.root = &root->entry;
-       child->right.root = NULL;
-
-       set_curdir(child, entry, 0, hwnd);
-
-       return child;
-}
-
-
-/* free all memory associated with a child window */
-static void free_child_window(ChildWnd* child)
-{
-       free_entries(&child->root.entry);
-       free(child);
-}
-
-
-/* get full path of specified directory entry */
-static void get_path(Entry* dir, PTSTR path)
-{
-       Entry* entry;
-       int len = 0;
-       int level = 0;
-
-#ifdef _SHELL_FOLDERS
-       if (dir->etype == ET_SHELL)
-       {
-               SFGAOF attribs;
-               HRESULT hr = S_OK;
-
-               path[0] = TEXT('\0');
-
-               attribs = 0;
-
-               if (dir->folder)
-                       hr = IShellFolder_GetAttributesOf(dir->folder, 1, (LPCITEMIDLIST*)&dir->pidl, &attribs);
-
-               if (SUCCEEDED(hr) && (attribs&SFGAO_FILESYSTEM)) {
-                       IShellFolder* parent = dir->up? dir->up->folder: Globals.iDesktop;
-
-                       hr = path_from_pidl(parent, dir->pidl, path, MAX_PATH);
-               }
-       }
-       else
-#endif
-       {
-               for(entry=dir; entry; level++) {
-                       LPCTSTR name;
-                       int l;
-
-                       {
-                               LPCTSTR s;
-                               name = entry->data.cFileName;
-                               s = name;
-
-                               for(l=0; *s && *s!=TEXT('/') && *s!=TEXT('\\'); s++)
-                                       l++;
-                       }
-
-                       if (entry->up) {
-                               if (l > 0) {
-                                       memmove(path+l+1, path, len*sizeof(TCHAR));
-                                       memcpy(path+1, name, l*sizeof(TCHAR));
-                                       len += l+1;
-
-#ifndef _NO_EXTENSIONS
-                                       if (entry->etype == ET_UNIX)
-                                               path[0] = TEXT('/');
-                                       else
-#endif
-                                       path[0] = TEXT('\\');
-                               }
-
-                               entry = entry->up;
-                       } else {
-                               memmove(path+l, path, len*sizeof(TCHAR));
-                               memcpy(path, name, l*sizeof(TCHAR));
-                               len += l;
-                               break;
-                       }
-               }
-
-               if (!level) {
-#ifndef _NO_EXTENSIONS
-                       if (entry->etype == ET_UNIX)
-                               path[len++] = TEXT('/');
-                       else
-#endif
-                               path[len++] = TEXT('\\');
-               }
-
-               path[len] = TEXT('\0');
-       }
-}
-
-
-static void resize_frame_rect(HWND hwnd, PRECT prect)
-{
-       int new_top;
-       RECT rt;
-
-       if (IsWindowVisible(Globals.htoolbar)) {
-               SendMessage(Globals.htoolbar, WM_SIZE, 0, 0);
-               GetClientRect(Globals.htoolbar, &rt);
-               prect->top = rt.bottom+3;
-               prect->bottom -= rt.bottom+3;
-       }
-
-       if (IsWindowVisible(Globals.hdrivebar)) {
-               SendMessage(Globals.hdrivebar, WM_SIZE, 0, 0);
-               GetClientRect(Globals.hdrivebar, &rt);
-               new_top = --prect->top + rt.bottom+3;
-               MoveWindow(Globals.hdrivebar, 0, prect->top, rt.right, new_top, TRUE);
-               prect->top = new_top;
-               prect->bottom -= rt.bottom+2;
-       }
-
-       if (IsWindowVisible(Globals.hstatusbar)) {
-               int parts[] = {300, 500};
-
-               SendMessage(Globals.hstatusbar, WM_SIZE, 0, 0);
-               SendMessage(Globals.hstatusbar, SB_SETPARTS, 2, (LPARAM)&parts);
-               GetClientRect(Globals.hstatusbar, &rt);
-               prect->bottom -= rt.bottom;
-       }
-
-       MoveWindow(Globals.hmdiclient, prect->left-1,prect->top-1,prect->right+2,prect->bottom+1, TRUE);
-}
-
-static void resize_frame(HWND hwnd, int cx, int cy)
-{
-       RECT rect;
-
-       rect.left   = 0;
-       rect.top    = 0;
-       rect.right  = cx;
-       rect.bottom = cy;
-
-       resize_frame_rect(hwnd, &rect);
-}
-
-static void resize_frame_client(HWND hwnd)
-{
-       RECT rect;
-
-       GetClientRect(hwnd, &rect);
-
-       resize_frame_rect(hwnd, &rect);
-}
-
-
-static HHOOK hcbthook;
-static ChildWnd* newchild = NULL;
-
-static LRESULT CALLBACK CBTProc(int code, WPARAM wparam, LPARAM lparam)
-{
-       if (code==HCBT_CREATEWND && newchild) {
-               ChildWnd* child = newchild;
-               newchild = NULL;
-
-               child->hwnd = (HWND) wparam;
-               SetWindowLongPtr(child->hwnd, GWLP_USERDATA, (LPARAM)child);
-       }
-
-       return CallNextHookEx(hcbthook, code, wparam, lparam);
-}
-
-static HWND create_child_window(ChildWnd* child)
-{
-       MDICREATESTRUCT mcs;
-       int idx;
-
-       mcs.szClass = sWINEFILETREE;
-       mcs.szTitle = (LPTSTR)child->path;
-       mcs.hOwner  = Globals.hInstance;
-       mcs.x       = child->pos.rcNormalPosition.left;
-       mcs.y       = child->pos.rcNormalPosition.top;
-       mcs.cx      = child->pos.rcNormalPosition.right-child->pos.rcNormalPosition.left;
-       mcs.cy      = child->pos.rcNormalPosition.bottom-child->pos.rcNormalPosition.top;
-       mcs.style   = 0;
-       mcs.lParam  = 0;
-
-       hcbthook = SetWindowsHookEx(WH_CBT, CBTProc, 0, GetCurrentThreadId());
-
-       newchild = child;
-       child->hwnd = (HWND) SendMessage(Globals.hmdiclient, WM_MDICREATE, 0, (LPARAM)&mcs);
-       if (!child->hwnd) {
-               UnhookWindowsHookEx(hcbthook);
-               return 0;
-       }
-
-       UnhookWindowsHookEx(hcbthook);
-
-       ListBox_SetItemHeight(child->left.hwnd, 1, max(Globals.spaceSize.cy,IMAGE_HEIGHT+3));
-       ListBox_SetItemHeight(child->right.hwnd, 1, max(Globals.spaceSize.cy,IMAGE_HEIGHT+3));
-
-       idx = ListBox_FindItemData(child->left.hwnd, 0, child->left.cur);
-       ListBox_SetCurSel(child->left.hwnd, idx);
-
-       return child->hwnd;
-}
-
-
-struct ExecuteDialog {
-       TCHAR   cmd[MAX_PATH];
-       int             cmdshow;
-};
-
-static INT_PTR CALLBACK ExecuteDialogDlgProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       static struct ExecuteDialog* dlg;
-
-       switch(nmsg) {
-               case WM_INITDIALOG:
-                       dlg = (struct ExecuteDialog*) lparam;
-                       return 1;
-
-               case WM_COMMAND: {
-                       int id = (int)wparam;
-
-                       if (id == IDOK) {
-                               GetWindowText(GetDlgItem(hwnd, 201), dlg->cmd, MAX_PATH);
-                               dlg->cmdshow = Button_GetState(GetDlgItem(hwnd,214))&BST_CHECKED?
-                                                                                               SW_SHOWMINIMIZED: SW_SHOWNORMAL;
-                               EndDialog(hwnd, id);
-                       } else if (id == IDCANCEL)
-                               EndDialog(hwnd, id);
-
-                       return 1;}
-       }
-
-       return 0;
-}
-
-
-static INT_PTR CALLBACK DestinationDlgProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       TCHAR b1[BUFFER_LEN], b2[BUFFER_LEN];
-
-       switch(nmsg) {
-               case WM_INITDIALOG:
-                       SetWindowLongPtr(hwnd, GWLP_USERDATA, lparam);
-                       SetWindowText(GetDlgItem(hwnd, 201), (LPCTSTR)lparam);
-                       return 1;
-
-               case WM_COMMAND: {
-                       int id = (int)wparam;
-
-                       switch(id) {
-                         case IDOK: {
-                               LPTSTR dest = (LPTSTR) GetWindowLongPtr(hwnd, GWLP_USERDATA);
-                               GetWindowText(GetDlgItem(hwnd, 201), dest, MAX_PATH);
-                               EndDialog(hwnd, id);
-                               break;}
-
-                         case IDCANCEL:
-                               EndDialog(hwnd, id);
-                               break;
-
-                         case 254:
-                               MessageBox(hwnd, RS(b1,IDS_NO_IMPL), RS(b2,IDS_WINEFILE), MB_OK);
-                               break;
-                       }
-
-                       return 1;
-               }
-       }
-
-       return 0;
-}
-
-
-struct FilterDialog {
-       TCHAR   pattern[MAX_PATH];
-       int             flags;
-};
-
-static INT_PTR CALLBACK FilterDialogDlgProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       static struct FilterDialog* dlg;
-
-       switch(nmsg) {
-               case WM_INITDIALOG:
-                       dlg = (struct FilterDialog*) lparam;
-                       SetWindowText(GetDlgItem(hwnd, IDC_VIEW_PATTERN), dlg->pattern);
-                       Button_SetCheck(GetDlgItem(hwnd,IDC_VIEW_TYPE_DIRECTORIES), (dlg->flags&TF_DIRECTORIES? BST_CHECKED: BST_UNCHECKED));
-                       Button_SetCheck(GetDlgItem(hwnd,IDC_VIEW_TYPE_PROGRAMS), dlg->flags&TF_PROGRAMS? BST_CHECKED: BST_UNCHECKED);
-                       Button_SetCheck(GetDlgItem(hwnd,IDC_VIEW_TYPE_DOCUMENTS), dlg->flags&TF_DOCUMENTS? BST_CHECKED: BST_UNCHECKED);
-                       Button_SetCheck(GetDlgItem(hwnd,IDC_VIEW_TYPE_OTHERS), dlg->flags&TF_OTHERS? BST_CHECKED: BST_UNCHECKED);
-                       Button_SetCheck(GetDlgItem(hwnd,IDC_VIEW_TYPE_HIDDEN), dlg->flags&TF_HIDDEN? BST_CHECKED: BST_UNCHECKED);
-                       return 1;
-
-               case WM_COMMAND: {
-                       int id = (int)wparam;
-
-                       if (id == IDOK) {
-                               int flags = 0;
-
-                               GetWindowText(GetDlgItem(hwnd, IDC_VIEW_PATTERN), dlg->pattern, MAX_PATH);
-
-                               flags |= Button_GetCheck(GetDlgItem(hwnd,IDC_VIEW_TYPE_DIRECTORIES))&BST_CHECKED? TF_DIRECTORIES: 0;
-                               flags |= Button_GetCheck(GetDlgItem(hwnd,IDC_VIEW_TYPE_PROGRAMS))&BST_CHECKED? TF_PROGRAMS: 0;
-                               flags |= Button_GetCheck(GetDlgItem(hwnd,IDC_VIEW_TYPE_DOCUMENTS))&BST_CHECKED? TF_DOCUMENTS: 0;
-                               flags |= Button_GetCheck(GetDlgItem(hwnd,IDC_VIEW_TYPE_OTHERS))&BST_CHECKED? TF_OTHERS: 0;
-                               flags |= Button_GetCheck(GetDlgItem(hwnd,IDC_VIEW_TYPE_HIDDEN))&BST_CHECKED? TF_HIDDEN: 0;
-
-                               dlg->flags = flags;
-
-                               EndDialog(hwnd, id);
-                       } else if (id == IDCANCEL)
-                               EndDialog(hwnd, id);
-
-                       return 1;}
-       }
-
-       return 0;
-}
-
-
-struct PropertiesDialog {
-       TCHAR   path[MAX_PATH];
-       Entry   entry;
-       void*   pVersionData;
-};
-
-/* Structure used to store enumerated languages and code pages. */
-struct LANGANDCODEPAGE {
-       WORD wLanguage;
-       WORD wCodePage;
-} *lpTranslate;
-
-static LPCSTR InfoStrings[] = {
-       "Comments",
-       "CompanyName",
-       "FileDescription",
-       "FileVersion",
-       "InternalName",
-       "LegalCopyright",
-       "LegalTrademarks",
-       "OriginalFilename",
-       "PrivateBuild",
-       "ProductName",
-       "ProductVersion",
-       "SpecialBuild",
-       NULL
-};
-
-static void PropDlg_DisplayValue(HWND hlbox, HWND hedit)
-{
-       int idx = ListBox_GetCurSel(hlbox);
-
-       if (idx != LB_ERR) {
-               LPCTSTR pValue = (LPCTSTR) ListBox_GetItemData(hlbox, idx);
-
-               if (pValue)
-                       SetWindowText(hedit, pValue);
-       }
-}
-
-static void CheckForFileInfo(struct PropertiesDialog* dlg, HWND hwnd, LPCTSTR strFilename)
-{
-       static TCHAR sBackSlash[] = {'\\','\0'};
-       static TCHAR sTranslation[] = {'\\','V','a','r','F','i','l','e','I','n','f','o','\\','T','r','a','n','s','l','a','t','i','o','n','\0'};
-       static TCHAR sStringFileInfo[] = {'\\','S','t','r','i','n','g','F','i','l','e','I','n','f','o','\\',
-                                                                               '%','0','4','x','%','0','4','x','\\','%','s','\0'};
-       DWORD dwVersionDataLen = GetFileVersionInfoSize((LPTSTR)strFilename, NULL);     /* VC6 and MinGW headers use LPTSTR instead of LPCTSTR */
-
-       if (dwVersionDataLen) {
-               dlg->pVersionData = malloc(dwVersionDataLen);
-
-               if (GetFileVersionInfo((LPTSTR)strFilename, 0, dwVersionDataLen, dlg->pVersionData)) {  /* VC6 and MinGW headers use LPTSTR instead of LPCTSTR */
-                       LPVOID pVal;
-                       UINT nValLen;
-
-                       if (VerQueryValue(dlg->pVersionData, sBackSlash, &pVal, &nValLen)) {
-                               if (nValLen == sizeof(VS_FIXEDFILEINFO)) {
-                                       VS_FIXEDFILEINFO* pFixedFileInfo = (VS_FIXEDFILEINFO*)pVal;
-                                       char buffer[BUFFER_LEN];
-
-                                       sprintf(buffer, "%d.%d.%d.%d",
-                                               HIWORD(pFixedFileInfo->dwFileVersionMS), LOWORD(pFixedFileInfo->dwFileVersionMS),
-                                               HIWORD(pFixedFileInfo->dwFileVersionLS), LOWORD(pFixedFileInfo->dwFileVersionLS));
-
-                                       SetDlgItemTextA(hwnd, IDC_STATIC_PROP_VERSION, buffer);
-                               }
-                       }
-
-                       /* Read the list of languages and code pages. */
-                       if (VerQueryValue(dlg->pVersionData, sTranslation, &pVal, &nValLen)) {
-                               struct LANGANDCODEPAGE* pTranslate = (struct LANGANDCODEPAGE*)pVal;
-                               struct LANGANDCODEPAGE* pEnd = (struct LANGANDCODEPAGE*)((LPBYTE)pVal+nValLen);
-
-                               HWND hlbox = GetDlgItem(hwnd, IDC_LIST_PROP_VERSION_TYPES);
-
-                               /* Read the file description for each language and code page. */
-                               for(; pTranslate<pEnd; ++pTranslate) {
-                                       LPCSTR* p;
-
-                                       for(p=InfoStrings; *p; ++p) {
-                                               TCHAR subblock[200];
-#ifdef UNICODE
-                                               TCHAR infoStr[100];
-#endif
-                                               LPCTSTR pTxt;
-                                               UINT nValLen;
-
-                                               LPCSTR pInfoString = *p;
-#ifdef UNICODE
-                                               MultiByteToWideChar(CP_ACP, 0, pInfoString, -1, infoStr, 100);
-#else
-#define        infoStr pInfoString
-#endif
-                                               wsprintf(subblock, sStringFileInfo, pTranslate->wLanguage, pTranslate->wCodePage, infoStr);
-
-                                               /* Retrieve file description for language and code page */
-                                               if (VerQueryValue(dlg->pVersionData, subblock, (PVOID)&pTxt, &nValLen)) {
-                                                       int idx = ListBox_AddString(hlbox, infoStr);
-                                                       ListBox_SetItemData(hlbox, idx, pTxt);
-                                               }
-                                       }
-                               }
-
-                               ListBox_SetCurSel(hlbox, 0);
-
-                               PropDlg_DisplayValue(hlbox, GetDlgItem(hwnd,IDC_LIST_PROP_VERSION_VALUES));
-                       }
-               }
-       }
-}
-
-static INT_PTR CALLBACK PropertiesDialogDlgProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       static struct PropertiesDialog* dlg;
-
-       switch(nmsg) {
-               case WM_INITDIALOG: {
-                       const static TCHAR sByteFmt[] = {'%','s',' ','B','y','t','e','s','\0'};
-                       TCHAR b1[BUFFER_LEN], b2[BUFFER_LEN];
-                       LPWIN32_FIND_DATA pWFD;
-                       ULONGLONG size;
-
-                       dlg = (struct PropertiesDialog*) lparam;
-                       pWFD = (LPWIN32_FIND_DATA) &dlg->entry.data;
-
-                       GetWindowText(hwnd, b1, MAX_PATH);
-                       wsprintf(b2, b1, pWFD->cFileName);
-                       SetWindowText(hwnd, b2);
-
-                       format_date(&pWFD->ftLastWriteTime, b1, COL_DATE|COL_TIME);
-                       SetWindowText(GetDlgItem(hwnd, IDC_STATIC_PROP_LASTCHANGE), b1);
-
-                       size = ((ULONGLONG)pWFD->nFileSizeHigh << 32) | pWFD->nFileSizeLow;
-                       _stprintf(b1, sLongNumFmt, size);
-                       wsprintf(b2, sByteFmt, b1);
-                       SetWindowText(GetDlgItem(hwnd, IDC_STATIC_PROP_SIZE), b2);
-
-                       SetWindowText(GetDlgItem(hwnd, IDC_STATIC_PROP_FILENAME), pWFD->cFileName);
-                       SetWindowText(GetDlgItem(hwnd, IDC_STATIC_PROP_PATH), dlg->path);
-
-                       Button_SetCheck(GetDlgItem(hwnd,IDC_CHECK_READONLY), (pWFD->dwFileAttributes&FILE_ATTRIBUTE_READONLY? BST_CHECKED: BST_UNCHECKED));
-                       Button_SetCheck(GetDlgItem(hwnd,IDC_CHECK_ARCHIVE), (pWFD->dwFileAttributes&FILE_ATTRIBUTE_ARCHIVE? BST_CHECKED: BST_UNCHECKED));
-                       Button_SetCheck(GetDlgItem(hwnd,IDC_CHECK_COMPRESSED), (pWFD->dwFileAttributes&FILE_ATTRIBUTE_COMPRESSED? BST_CHECKED: BST_UNCHECKED));
-                       Button_SetCheck(GetDlgItem(hwnd,IDC_CHECK_HIDDEN), (pWFD->dwFileAttributes&FILE_ATTRIBUTE_HIDDEN? BST_CHECKED: BST_UNCHECKED));
-                       Button_SetCheck(GetDlgItem(hwnd,IDC_CHECK_SYSTEM), (pWFD->dwFileAttributes&FILE_ATTRIBUTE_SYSTEM? BST_CHECKED: BST_UNCHECKED));
-
-                       CheckForFileInfo(dlg, hwnd, dlg->path);
-                       return 1;}
-
-               case WM_COMMAND: {
-                       int id = (int)wparam;
-
-                       switch(HIWORD(wparam)) {
-                         case LBN_SELCHANGE: {
-                               HWND hlbox = GetDlgItem(hwnd, IDC_LIST_PROP_VERSION_TYPES);
-                               PropDlg_DisplayValue(hlbox, GetDlgItem(hwnd,IDC_LIST_PROP_VERSION_VALUES));
-                               break;
-                         }
-
-                         case BN_CLICKED:
-                               if (id==IDOK || id==IDCANCEL)
-                                       EndDialog(hwnd, id);
-                       }
-
-                       return 1;}
-
-               case WM_NCDESTROY:
-                       free(dlg->pVersionData);
-                       dlg->pVersionData = NULL;
-                       break;
-       }
-
-       return 0;
-}
-
-static void show_properties_dlg(Entry* entry, HWND hwnd)
-{
-       struct PropertiesDialog dlg;
-
-       memset(&dlg, 0, sizeof(struct PropertiesDialog));
-       get_path(entry, dlg.path);
-       memcpy(&dlg.entry, entry, sizeof(Entry));
-
-       DialogBoxParam(Globals.hInstance, MAKEINTRESOURCE(IDD_DIALOG_PROPERTIES), hwnd, PropertiesDialogDlgProc, (LPARAM)&dlg);
-}
-
-
-#ifndef _NO_EXTENSIONS
-
-static struct FullScreenParameters {
-       BOOL    mode;
-       RECT    orgPos;
-       BOOL    wasZoomed;
-} g_fullscreen = {
-    FALSE,     /* mode */
-       {0, 0, 0, 0},
-       FALSE
-};
-
-static void frame_get_clientspace(HWND hwnd, PRECT prect)
-{
-       RECT rt;
-
-       if (!IsIconic(hwnd))
-               GetClientRect(hwnd, prect);
-       else {
-               WINDOWPLACEMENT wp;
-
-               GetWindowPlacement(hwnd, &wp);
-
-               prect->left = prect->top = 0;
-               prect->right = wp.rcNormalPosition.right-wp.rcNormalPosition.left-
-                                               2*(GetSystemMetrics(SM_CXSIZEFRAME)+GetSystemMetrics(SM_CXEDGE));
-               prect->bottom = wp.rcNormalPosition.bottom-wp.rcNormalPosition.top-
-                                               2*(GetSystemMetrics(SM_CYSIZEFRAME)+GetSystemMetrics(SM_CYEDGE))-
-                                               GetSystemMetrics(SM_CYCAPTION)-GetSystemMetrics(SM_CYMENUSIZE);
-       }
-
-       if (IsWindowVisible(Globals.htoolbar)) {
-               GetClientRect(Globals.htoolbar, &rt);
-               prect->top += rt.bottom+2;
-       }
-
-       if (IsWindowVisible(Globals.hdrivebar)) {
-               GetClientRect(Globals.hdrivebar, &rt);
-               prect->top += rt.bottom+2;
-       }
-
-       if (IsWindowVisible(Globals.hstatusbar)) {
-               GetClientRect(Globals.hstatusbar, &rt);
-               prect->bottom -= rt.bottom;
-       }
-}
-
-static BOOL toggle_fullscreen(HWND hwnd)
-{
-       RECT rt;
-
-       if ((g_fullscreen.mode=!g_fullscreen.mode)) {
-               GetWindowRect(hwnd, &g_fullscreen.orgPos);
-               g_fullscreen.wasZoomed = IsZoomed(hwnd);
-
-               Frame_CalcFrameClient(hwnd, &rt);
-               ClientToScreen(hwnd, (LPPOINT)&rt.left);
-               ClientToScreen(hwnd, (LPPOINT)&rt.right);
-
-               rt.left = g_fullscreen.orgPos.left-rt.left;
-               rt.top = g_fullscreen.orgPos.top-rt.top;
-               rt.right = GetSystemMetrics(SM_CXSCREEN)+g_fullscreen.orgPos.right-rt.right;
-               rt.bottom = GetSystemMetrics(SM_CYSCREEN)+g_fullscreen.orgPos.bottom-rt.bottom;
-
-               MoveWindow(hwnd, rt.left, rt.top, rt.right-rt.left, rt.bottom-rt.top, TRUE);
-       } else {
-               MoveWindow(hwnd, g_fullscreen.orgPos.left, g_fullscreen.orgPos.top,
-                                                       g_fullscreen.orgPos.right-g_fullscreen.orgPos.left,
-                                                       g_fullscreen.orgPos.bottom-g_fullscreen.orgPos.top, TRUE);
-
-               if (g_fullscreen.wasZoomed)
-                       ShowWindow(hwnd, WS_MAXIMIZE);
-       }
-
-       return g_fullscreen.mode;
-}
-
-static void fullscreen_move(HWND hwnd)
-{
-       RECT rt, pos;
-       GetWindowRect(hwnd, &pos);
-
-       Frame_CalcFrameClient(hwnd, &rt);
-       ClientToScreen(hwnd, (LPPOINT)&rt.left);
-       ClientToScreen(hwnd, (LPPOINT)&rt.right);
-
-       rt.left = pos.left-rt.left;
-       rt.top = pos.top-rt.top;
-       rt.right = GetSystemMetrics(SM_CXSCREEN)+pos.right-rt.right;
-       rt.bottom = GetSystemMetrics(SM_CYSCREEN)+pos.bottom-rt.bottom;
-
-       MoveWindow(hwnd, rt.left, rt.top, rt.right-rt.left, rt.bottom-rt.top, TRUE);
-}
-
-#endif
-
-
-static void toggle_child(HWND hwnd, UINT cmd, HWND hchild)
-{
-       BOOL vis = IsWindowVisible(hchild);
-
-       CheckMenuItem(Globals.hMenuOptions, cmd, vis?MF_BYCOMMAND:MF_BYCOMMAND|MF_CHECKED);
-
-       ShowWindow(hchild, vis?SW_HIDE:SW_SHOW);
-
-#ifndef _NO_EXTENSIONS
-       if (g_fullscreen.mode)
-               fullscreen_move(hwnd);
-#endif
-
-       resize_frame_client(hwnd);
-}
-
-static BOOL activate_drive_window(LPCTSTR path)
-{
-       TCHAR drv1[_MAX_DRIVE], drv2[_MAX_DRIVE];
-       HWND child_wnd;
-
-       _tsplitpath(path, drv1, 0, 0, 0);
-
-       /* search for a already open window for the same drive */
-       for(child_wnd=GetNextWindow(Globals.hmdiclient,GW_CHILD); child_wnd; child_wnd=GetNextWindow(child_wnd, GW_HWNDNEXT)) {
-               ChildWnd* child = (ChildWnd*) GetWindowLongPtr(child_wnd, GWLP_USERDATA);
-
-               if (child) {
-                       _tsplitpath(child->root.path, drv2, 0, 0, 0);
-
-                       if (!lstrcmpi(drv2, drv1)) {
-                               SendMessage(Globals.hmdiclient, WM_MDIACTIVATE, (WPARAM)child_wnd, 0);
-
-                               if (IsMinimized(child_wnd))
-                                       ShowWindow(child_wnd, SW_SHOWNORMAL);
-
-                               return TRUE;
-                       }
-               }
-       }
-
-       return FALSE;
-}
-
-static BOOL activate_fs_window(LPCTSTR filesys)
-{
-       HWND child_wnd;
-
-       /* search for a already open window of the given file system name */
-       for(child_wnd=GetNextWindow(Globals.hmdiclient,GW_CHILD); child_wnd; child_wnd=GetNextWindow(child_wnd, GW_HWNDNEXT)) {
-               ChildWnd* child = (ChildWnd*) GetWindowLongPtr(child_wnd, GWLP_USERDATA);
-
-               if (child) {
-                       if (!lstrcmpi(child->root.fs, filesys)) {
-                               SendMessage(Globals.hmdiclient, WM_MDIACTIVATE, (WPARAM)child_wnd, 0);
-
-                               if (IsMinimized(child_wnd))
-                                       ShowWindow(child_wnd, SW_SHOWNORMAL);
-
-                               return TRUE;
-                       }
-               }
-       }
-
-       return FALSE;
-}
-
-static LRESULT CALLBACK FrameWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       TCHAR b1[BUFFER_LEN], b2[BUFFER_LEN];
-
-       switch(nmsg) {
-               case WM_CLOSE:
-                       DestroyWindow(hwnd);
-
-                        /* clear handle variables */
-                       Globals.hMenuFrame = 0;
-                       Globals.hMenuView = 0;
-                       Globals.hMenuOptions = 0;
-                       Globals.hMainWnd = 0;
-                       Globals.hmdiclient = 0;
-                       Globals.hdrivebar = 0;
-                       break;
-
-               case WM_DESTROY:
-                       PostQuitMessage(0);
-                       break;
-
-               case WM_INITMENUPOPUP: {
-                       HWND hwndClient = (HWND) SendMessage(Globals.hmdiclient, WM_MDIGETACTIVE, 0, 0);
-
-                       if (!SendMessage(hwndClient, WM_INITMENUPOPUP, wparam, lparam))
-                               return 0;
-                       break;}
-
-               case WM_COMMAND: {
-                       UINT cmd = LOWORD(wparam);
-                       HWND hwndClient = (HWND) SendMessage(Globals.hmdiclient, WM_MDIGETACTIVE, 0, 0);
-
-                       if (SendMessage(hwndClient, WM_DISPATCH_COMMAND, wparam, lparam))
-                               break;
-
-                       if (cmd>=ID_DRIVE_FIRST && cmd<=ID_DRIVE_FIRST+0xFF) {
-                               TCHAR drv[_MAX_DRIVE], path[MAX_PATH];
-                               ChildWnd* child;
-                               LPCTSTR root = Globals.drives;
-                               int i;
-
-                               for(i=cmd-ID_DRIVE_FIRST; i--; root++)
-                                       while(*root)
-                                               root++;
-
-                               if (activate_drive_window(root))
-                                       return 0;
-
-                               _tsplitpath(root, drv, 0, 0, 0);
-
-                               if (!SetCurrentDirectory(drv)) {
-                                       display_error(hwnd, GetLastError());
-                                       return 0;
-                               }
-
-                               GetCurrentDirectory(MAX_PATH, path); /*TODO: store last directory per drive */
-                               child = alloc_child_window(path, NULL, hwnd);
-
-                               if (!create_child_window(child))
-                                       free(child);
-                       } else switch(cmd) {
-                               case ID_FILE_EXIT:
-                                       SendMessage(hwnd, WM_CLOSE, 0, 0);
-                                       break;
-
-                               case ID_WINDOW_NEW: {
-                                       TCHAR path[MAX_PATH];
-                                       ChildWnd* child;
-
-                                       GetCurrentDirectory(MAX_PATH, path);
-                                       child = alloc_child_window(path, NULL, hwnd);
-
-                                       if (!create_child_window(child))
-                                               free(child);
-                                       break;}
-
-                               case ID_REFRESH:
-                                       refresh_drives();
-                                       break;
-
-                               case ID_WINDOW_CASCADE:
-                                       SendMessage(Globals.hmdiclient, WM_MDICASCADE, 0, 0);
-                                       break;
-
-                               case ID_WINDOW_TILE_HORZ:
-                                       SendMessage(Globals.hmdiclient, WM_MDITILE, MDITILE_HORIZONTAL, 0);
-                                       break;
-
-                               case ID_WINDOW_TILE_VERT:
-                                       SendMessage(Globals.hmdiclient, WM_MDITILE, MDITILE_VERTICAL, 0);
-                                       break;
-
-                               case ID_WINDOW_ARRANGE:
-                                       SendMessage(Globals.hmdiclient, WM_MDIICONARRANGE, 0, 0);
-                                       break;
-
-                               case ID_SELECT_FONT: {
-                                       TCHAR dlg_name[BUFFER_LEN], dlg_info[BUFFER_LEN];
-                                       CHOOSEFONT chFont;
-                                       LOGFONT lFont;
-
-                                       HDC hdc = GetDC(hwnd);
-                                       chFont.lStructSize = sizeof(CHOOSEFONT);
-                                       chFont.hwndOwner = hwnd;
-                                       chFont.hDC = NULL;
-                                       chFont.lpLogFont = &lFont;
-                                       chFont.Flags = CF_SCREENFONTS | CF_FORCEFONTEXIST | CF_LIMITSIZE | CF_NOSCRIPTSEL;
-                                       chFont.rgbColors = RGB(0,0,0);
-                                       chFont.lCustData = 0;
-                                       chFont.lpfnHook = NULL;
-                                       chFont.lpTemplateName = NULL;
-                                       chFont.hInstance = Globals.hInstance;
-                                       chFont.lpszStyle = NULL;
-                                       chFont.nFontType = SIMULATED_FONTTYPE;
-                                       chFont.nSizeMin = 0;
-                                       chFont.nSizeMax = 24;
-
-                                       if (ChooseFont(&chFont)) {
-                                               HWND childWnd;
-                                               HFONT hFontOld;
-
-                                               DeleteObject(Globals.hfont);
-                                               Globals.hfont = CreateFontIndirect(&lFont);
-                                               hFontOld = SelectFont(hdc, Globals.hfont);
-                                               GetTextExtentPoint32(hdc, sSpace, 1, &Globals.spaceSize);
-
-                                               /* change font in all open child windows */
-                                               for(childWnd=GetWindow(Globals.hmdiclient,GW_CHILD); childWnd; childWnd=GetNextWindow(childWnd,GW_HWNDNEXT)) {
-                                                       ChildWnd* child = (ChildWnd*) GetWindowLongPtr(childWnd, GWLP_USERDATA);
-                                                       SetWindowFont(child->left.hwnd, Globals.hfont, TRUE);
-                                                       SetWindowFont(child->right.hwnd, Globals.hfont, TRUE);
-                                                       ListBox_SetItemHeight(child->left.hwnd, 1, max(Globals.spaceSize.cy,IMAGE_HEIGHT+3));
-                                                       ListBox_SetItemHeight(child->right.hwnd, 1, max(Globals.spaceSize.cy,IMAGE_HEIGHT+3));
-                                                       InvalidateRect(child->left.hwnd, NULL, TRUE);
-                                                       InvalidateRect(child->right.hwnd, NULL, TRUE);
-                                               }
-
-                                               SelectFont(hdc, hFontOld);
-                                       }
-                                       else if (CommDlgExtendedError()) {
-                                               LoadString(Globals.hInstance, IDS_FONT_SEL_DLG_NAME, dlg_name, BUFFER_LEN);
-                                               LoadString(Globals.hInstance, IDS_FONT_SEL_ERROR, dlg_info, BUFFER_LEN);
-                                               MessageBox(hwnd, dlg_info, dlg_name, MB_OK);
-                                       }
-
-                                       ReleaseDC(hwnd, hdc);
-                                       break;
-                               }
-
-                               case ID_VIEW_TOOL_BAR:
-                                       toggle_child(hwnd, cmd, Globals.htoolbar);
-                                       break;
-
-                               case ID_VIEW_DRIVE_BAR:
-                                       toggle_child(hwnd, cmd, Globals.hdrivebar);
-                                       break;
-
-                               case ID_VIEW_STATUSBAR:
-                                       toggle_child(hwnd, cmd, Globals.hstatusbar);
-                                       break;
-
-                               case ID_EXECUTE: {
-                                       struct ExecuteDialog dlg;
-
-                                       memset(&dlg, 0, sizeof(struct ExecuteDialog));
-
-                                       if (DialogBoxParam(Globals.hInstance, MAKEINTRESOURCE(IDD_EXECUTE), hwnd, ExecuteDialogDlgProc, (LPARAM)&dlg) == IDOK) {
-                                               HINSTANCE hinst = ShellExecute(hwnd, NULL/*operation*/, dlg.cmd/*file*/, NULL/*parameters*/, NULL/*dir*/, dlg.cmdshow);
-
-                                               if ((int)hinst <= 32)
-                                                       display_error(hwnd, GetLastError());
-                                       }
-                                       break;}
-
-                               case ID_CONNECT_NETWORK_DRIVE: {
-                                       DWORD ret = WNetConnectionDialog(hwnd, RESOURCETYPE_DISK);
-                                       if (ret == NO_ERROR)
-                                               refresh_drives();
-                                       else if (ret != (DWORD)-1) {
-                                               if (ret == ERROR_EXTENDED_ERROR)
-                                                       display_network_error(hwnd);
-                                               else
-                                                       display_error(hwnd, ret);
-                                       }
-                                       break;}
-
-                               case ID_DISCONNECT_NETWORK_DRIVE: {
-                                       DWORD ret = WNetDisconnectDialog(hwnd, RESOURCETYPE_DISK);
-                                       if (ret == NO_ERROR)
-                                               refresh_drives();
-                                       else if (ret != (DWORD)-1) {
-                                               if (ret == ERROR_EXTENDED_ERROR)
-                                                       display_network_error(hwnd);
-                                               else
-                                                       display_error(hwnd, ret);
-                                       }
-                                       break;}
-
-#ifndef __MINGW32__    /* SHFormatDrive missing in MinGW (as of 13.5.2005) */
-                               case ID_FORMAT_DISK: {
-                                       UINT sem_org = SetErrorMode(0); /* Get the current Error Mode settings. */
-                                       SetErrorMode(sem_org & ~SEM_FAILCRITICALERRORS); /* Force O/S to handle */
-                                       SHFormatDrive(hwnd, 0 /* A: */, SHFMT_ID_DEFAULT, 0);
-                                       SetErrorMode(sem_org); /* Put it back the way it was. */
-                                       break;}
-#endif
-
-                               case ID_HELP:
-                                       WinHelp(hwnd, RS(b1,IDS_WINEFILE), HELP_INDEX, 0);
-                                       break;
-
-#ifndef _NO_EXTENSIONS
-                               case ID_VIEW_FULLSCREEN:
-                                       CheckMenuItem(Globals.hMenuOptions, cmd, toggle_fullscreen(hwnd)?MF_CHECKED:0);
-                                       break;
-
-#ifdef __WINE__
-                               case ID_DRIVE_UNIX_FS: {
-                                       TCHAR path[MAX_PATH];
-#ifdef UNICODE
-                                       char cpath[MAX_PATH];
-#endif
-                                       ChildWnd* child;
-
-                                       if (activate_fs_window(RS(b1,IDS_UNIXFS)))
-                                               break;
-
-
-#ifdef UNICODE
-                                       getcwd(cpath, MAX_PATH);
-                                       MultiByteToWideChar(CP_UNIXCP, 0, cpath, -1, path, MAX_PATH);
-#else
-                                       getcwd(path, MAX_PATH);
-#endif
-                                       child = alloc_child_window(path, NULL, hwnd);
-
-                                       if (!create_child_window(child))
-                                               free(child);
-                                       break;}
-#endif
-
-#ifdef _SHELL_FOLDERS
-                               case ID_DRIVE_SHELL_NS: {
-                                       TCHAR path[MAX_PATH];
-                                       ChildWnd* child;
-
-                                       if (activate_fs_window(RS(b1,IDS_SHELL)))
-                                               break;
-
-                                       GetCurrentDirectory(MAX_PATH, path);
-                                       child = alloc_child_window(path, get_path_pidl(path,hwnd), hwnd);
-
-                                       if (!create_child_window(child))
-                                               free(child);
-                                       break;}
-#endif
-#endif
-
-                               /*TODO: There are even more menu items! */
-
-#ifndef _NO_EXTENSIONS
-#ifdef __WINE__
-                               case ID_LICENSE:
-                                       WineLicense(Globals.hMainWnd);
-                                       break;
-
-                               case ID_NO_WARRANTY:
-                                       WineWarranty(Globals.hMainWnd);
-                                       break;
-
-                               case ID_ABOUT_WINE:
-                                       ShellAbout(hwnd, RS(b2,IDS_WINE), RS(b1,IDS_WINEFILE), 0);
-                                       break;
-#endif
-
-                               case ID_ABOUT:
-                                       ShellAbout(hwnd, RS(b1,IDS_WINEFILE), NULL, 0);
-                                       break;
-#endif /* _NO_EXTENSIONS */
-
-                               default:
-                                       /*TODO: if (wParam >= PM_FIRST_LANGUAGE && wParam <= PM_LAST_LANGUAGE)
-                                               STRING_SelectLanguageByNumber(wParam - PM_FIRST_LANGUAGE);
-                                       else */if ((cmd<IDW_FIRST_CHILD || cmd>=IDW_FIRST_CHILD+0x100) &&
-                                               (cmd<SC_SIZE || cmd>SC_RESTORE))
-                                               MessageBox(hwnd, RS(b2,IDS_NO_IMPL), RS(b1,IDS_WINEFILE), MB_OK);
-
-                                       return DefFrameProc(hwnd, Globals.hmdiclient, nmsg, wparam, lparam);
-                       }
-                       break;}
-
-               case WM_SIZE:
-                       resize_frame(hwnd, LOWORD(lparam), HIWORD(lparam));
-                       break;  /* do not pass message to DefFrameProc */
-
-#ifndef _NO_EXTENSIONS
-               case WM_GETMINMAXINFO: {
-                       LPMINMAXINFO lpmmi = (LPMINMAXINFO)lparam;
-
-                       lpmmi->ptMaxTrackSize.x <<= 1;/*2*GetSystemMetrics(SM_CXSCREEN) / SM_CXVIRTUALSCREEN */
-                       lpmmi->ptMaxTrackSize.y <<= 1;/*2*GetSystemMetrics(SM_CYSCREEN) / SM_CYVIRTUALSCREEN */
-                       break;}
-
-               case FRM_CALC_CLIENT:
-                       frame_get_clientspace(hwnd, (PRECT)lparam);
-                       return TRUE;
-#endif /* _NO_EXTENSIONS */
-
-               default:
-                       return DefFrameProc(hwnd, Globals.hmdiclient, nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-
-static TCHAR g_pos_names[COLUMNS][20] = {
-       {'\0'}  /* symbol */
-};
-
-static const int g_pos_align[] = {
-       0,
-       HDF_LEFT,       /* Name */
-       HDF_RIGHT,      /* Size */
-       HDF_LEFT,       /* CDate */
-#ifndef _NO_EXTENSIONS
-       HDF_LEFT,       /* ADate */
-       HDF_LEFT,       /* MDate */
-       HDF_LEFT,       /* Index */
-       HDF_CENTER,     /* Links */
-#endif
-       HDF_CENTER,     /* Attributes */
-#ifndef _NO_EXTENSIONS
-       HDF_LEFT        /* Security */
-#endif
-};
-
-static void resize_tree(ChildWnd* child, int cx, int cy)
-{
-       HDWP hdwp = BeginDeferWindowPos(4);
-       RECT rt;
-
-       rt.left   = 0;
-       rt.top    = 0;
-       rt.right  = cx;
-       rt.bottom = cy;
-
-       cx = child->split_pos + SPLIT_WIDTH/2;
-
-#ifndef _NO_EXTENSIONS
-       {
-               WINDOWPOS wp;
-               HD_LAYOUT hdl;
-
-               hdl.prc   = &rt;
-               hdl.pwpos = &wp;
-
-               Header_Layout(child->left.hwndHeader, &hdl);
-
-               DeferWindowPos(hdwp, child->left.hwndHeader, wp.hwndInsertAfter,
-                                               wp.x-1, wp.y, child->split_pos-SPLIT_WIDTH/2+1, wp.cy, wp.flags);
-               DeferWindowPos(hdwp, child->right.hwndHeader, wp.hwndInsertAfter,
-                                               rt.left+cx+1, wp.y, wp.cx-cx+2, wp.cy, wp.flags);
-       }
-#endif /* _NO_EXTENSIONS */
-
-       DeferWindowPos(hdwp, child->left.hwnd, 0, rt.left, rt.top, child->split_pos-SPLIT_WIDTH/2-rt.left, rt.bottom-rt.top, SWP_NOZORDER|SWP_NOACTIVATE);
-       DeferWindowPos(hdwp, child->right.hwnd, 0, rt.left+cx+1, rt.top, rt.right-cx, rt.bottom-rt.top, SWP_NOZORDER|SWP_NOACTIVATE);
-
-       EndDeferWindowPos(hdwp);
-}
-
-
-#ifndef _NO_EXTENSIONS
-
-static HWND create_header(HWND parent, Pane* pane, int id)
-{
-       HD_ITEM hdi;
-       int idx;
-
-       HWND hwnd = CreateWindow(WC_HEADER, 0, WS_CHILD|WS_VISIBLE|HDS_HORZ/*TODO: |HDS_BUTTONS + sort orders*/,
-                                                               0, 0, 0, 0, parent, (HMENU)id, Globals.hInstance, 0);
-       if (!hwnd)
-               return 0;
-
-       SetWindowFont(hwnd, GetStockObject(DEFAULT_GUI_FONT), FALSE);
-
-       hdi.mask = HDI_TEXT|HDI_WIDTH|HDI_FORMAT;
-
-       for(idx=0; idx<COLUMNS; idx++) {
-               hdi.pszText = g_pos_names[idx];
-               hdi.fmt = HDF_STRING | g_pos_align[idx];
-               hdi.cxy = pane->widths[idx];
-               Header_InsertItem(hwnd, idx, &hdi);
-       }
-
-       return hwnd;
-}
-
-#endif /* _NO_EXTENSIONS */
-
-
-static void init_output(HWND hwnd)
-{
-       const static TCHAR s1000[] = {'1','0','0','0','\0'};
-
-       TCHAR b[16];
-       HFONT old_font;
-       HDC hdc = GetDC(hwnd);
-
-       if (GetNumberFormat(LOCALE_USER_DEFAULT, 0, s1000, 0, b, 16) > 4)
-               Globals.num_sep = b[1];
-       else
-               Globals.num_sep = TEXT('.');
-
-       old_font = SelectFont(hdc, Globals.hfont);
-       GetTextExtentPoint32(hdc, sSpace, 1, &Globals.spaceSize);
-       SelectFont(hdc, old_font);
-       ReleaseDC(hwnd, hdc);
-}
-
-static void draw_item(Pane* pane, LPDRAWITEMSTRUCT dis, Entry* entry, int calcWidthCol);
-
-
-/* calculate preferred width for all visible columns */
-
-static BOOL calc_widths(Pane* pane, BOOL anyway)
-{
-       int col, x, cx, spc=3*Globals.spaceSize.cx;
-       int entries = ListBox_GetCount(pane->hwnd);
-       int orgWidths[COLUMNS];
-       int orgPositions[COLUMNS+1];
-       HFONT hfontOld;
-       HDC hdc;
-       int cnt;
-
-       if (!anyway) {
-               memcpy(orgWidths, pane->widths, sizeof(orgWidths));
-               memcpy(orgPositions, pane->positions, sizeof(orgPositions));
-       }
-
-       for(col=0; col<COLUMNS; col++)
-               pane->widths[col] = 0;
-
-       hdc = GetDC(pane->hwnd);
-       hfontOld = SelectFont(hdc, Globals.hfont);
-
-       for(cnt=0; cnt<entries; cnt++) {
-               Entry* entry = (Entry*) ListBox_GetItemData(pane->hwnd, cnt);
-
-               DRAWITEMSTRUCT dis;
-
-               dis.CtlType               = 0;
-               dis.CtlID                 = 0;
-               dis.itemID                = 0;
-               dis.itemAction    = 0;
-               dis.itemState     = 0;
-               dis.hwndItem      = pane->hwnd;
-               dis.hDC                   = hdc;
-               dis.rcItem.left   = 0;
-               dis.rcItem.top    = 0;
-               dis.rcItem.right  = 0;
-               dis.rcItem.bottom = 0;
-               /*dis.itemData    = 0; */
-
-               draw_item(pane, &dis, entry, COLUMNS);
-       }
-
-       SelectObject(hdc, hfontOld);
-       ReleaseDC(pane->hwnd, hdc);
-
-       x = 0;
-       for(col=0; col<COLUMNS; col++) {
-               pane->positions[col] = x;
-               cx = pane->widths[col];
-
-               if (cx) {
-                       cx += spc;
-
-                       if (cx < IMAGE_WIDTH)
-                               cx = IMAGE_WIDTH;
-
-                       pane->widths[col] = cx;
-               }
-
-               x += cx;
-       }
-
-       pane->positions[COLUMNS] = x;
-
-       ListBox_SetHorizontalExtent(pane->hwnd, x);
-
-       /* no change? */
-       if (!memcmp(orgWidths, pane->widths, sizeof(orgWidths)))
-               return FALSE;
-
-       /* don't move, if only collapsing an entry */
-       if (!anyway && pane->widths[0]<orgWidths[0] &&
-               !memcmp(orgWidths+1, pane->widths+1, sizeof(orgWidths)-sizeof(int))) {
-               pane->widths[0] = orgWidths[0];
-               memcpy(pane->positions, orgPositions, sizeof(orgPositions));
-
-               return FALSE;
-       }
-
-       InvalidateRect(pane->hwnd, 0, TRUE);
-
-       return TRUE;
-}
-
-
-/* calculate one preferred column width */
-
-static void calc_single_width(Pane* pane, int col)
-{
-       HFONT hfontOld;
-       int x, cx;
-       int entries = ListBox_GetCount(pane->hwnd);
-       int cnt;
-       HDC hdc;
-
-       pane->widths[col] = 0;
-
-       hdc = GetDC(pane->hwnd);
-       hfontOld = SelectFont(hdc, Globals.hfont);
-
-       for(cnt=0; cnt<entries; cnt++) {
-               Entry* entry = (Entry*) ListBox_GetItemData(pane->hwnd, cnt);
-               DRAWITEMSTRUCT dis;
-
-               dis.CtlType               = 0;
-               dis.CtlID                 = 0;
-               dis.itemID                = 0;
-               dis.itemAction    = 0;
-               dis.itemState     = 0;
-               dis.hwndItem      = pane->hwnd;
-               dis.hDC                   = hdc;
-               dis.rcItem.left   = 0;
-               dis.rcItem.top    = 0;
-               dis.rcItem.right  = 0;
-               dis.rcItem.bottom = 0;
-               /*dis.itemData    = 0; */
-
-               draw_item(pane, &dis, entry, col);
-       }
-
-       SelectObject(hdc, hfontOld);
-       ReleaseDC(pane->hwnd, hdc);
-
-       cx = pane->widths[col];
-
-       if (cx) {
-               cx += 3*Globals.spaceSize.cx;
-
-               if (cx < IMAGE_WIDTH)
-                       cx = IMAGE_WIDTH;
-       }
-
-       pane->widths[col] = cx;
-
-       x = pane->positions[col] + cx;
-
-       for(; col<COLUMNS; ) {
-               pane->positions[++col] = x;
-               x += pane->widths[col];
-       }
-
-       ListBox_SetHorizontalExtent(pane->hwnd, x);
-}
-
-
-static BOOL pattern_match(LPCTSTR str, LPCTSTR pattern)
-{
-       for( ; *str&&*pattern; str++,pattern++) {
-               if (*pattern == '*') {
-                       do pattern++;
-                       while(*pattern == '*');
-
-                       if (!*pattern)
-                               return TRUE;
-
-                       for(; *str; str++)
-                               if (*str==*pattern && pattern_match(str, pattern))
-                                       return TRUE;
-
-                       return FALSE;
-               }
-               else if (*str!=*pattern && *pattern!='?')
-                       return FALSE;
-       }
-
-       if (*str || *pattern)
-               if (*pattern!='*' || pattern[1]!='\0')
-                       return FALSE;
-
-       return TRUE;
-}
-
-static BOOL pattern_imatch(LPCTSTR str, LPCTSTR pattern)
-{
-       TCHAR b1[BUFFER_LEN], b2[BUFFER_LEN];
-
-       lstrcpy(b1, str);
-       lstrcpy(b2, pattern);
-       CharUpper(b1);
-       CharUpper(b2);
-
-       return pattern_match(b1, b2);
-}
-
-
-enum FILE_TYPE {
-       FT_OTHER                = 0,
-       FT_EXECUTABLE   = 1,
-       FT_DOCUMENT             = 2
-};
-
-static enum FILE_TYPE get_file_type(LPCTSTR filename);
-
-
-/* insert listbox entries after index idx */
-
-static int insert_entries(Pane* pane, Entry* dir, LPCTSTR pattern, int filter_flags, int idx)
-{
-       Entry* entry = dir;
-
-       if (!entry)
-               return idx;
-
-       ShowWindow(pane->hwnd, SW_HIDE);
-
-       for(; entry; entry=entry->next) {
-#ifndef _LEFT_FILES
-               if (pane->treePane && !(entry->data.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY))
-                       continue;
-#endif
-
-               if (entry->data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-                       /* don't display entries "." and ".." in the left pane */
-                       if (pane->treePane && entry->data.cFileName[0]==TEXT('.'))
-                               if (
-       #ifndef _NO_EXTENSIONS
-                                       entry->data.cFileName[1]==TEXT('\0') ||
-       #endif
-                                       (entry->data.cFileName[1]==TEXT('.') && entry->data.cFileName[2]==TEXT('\0')))
-                                       continue;
-
-                       /* filter directories in right pane */
-                       if (!pane->treePane && !(filter_flags&TF_DIRECTORIES))
-                               continue;
-               }
-
-               /* filter using the file name pattern */
-               if (pattern)
-                       if (!pattern_imatch(entry->data.cFileName, pattern))
-                               continue;
-
-               /* filter system and hidden files */
-               if (!(filter_flags&TF_HIDDEN) && (entry->data.dwFileAttributes&(FILE_ATTRIBUTE_HIDDEN|FILE_ATTRIBUTE_SYSTEM)))
-                       continue;
-
-               /* filter looking at the file type */
-               if ((filter_flags&(TF_PROGRAMS|TF_DOCUMENTS|TF_OTHERS)) != (TF_PROGRAMS|TF_DOCUMENTS|TF_OTHERS))
-                       switch(get_file_type(entry->data.cFileName)) {
-                         case FT_EXECUTABLE:
-                               if (!(filter_flags & TF_PROGRAMS))
-                                       continue;
-                               break;
-
-                         case FT_DOCUMENT:
-                               if (!(filter_flags & TF_DOCUMENTS))
-                                       continue;
-                               break;
-
-                         default: /* TF_OTHERS */
-                               if (!(filter_flags & TF_OTHERS))
-                                       continue;
-                       }
-
-               if (idx != -1)
-                       idx++;
-
-               ListBox_InsertItemData(pane->hwnd, idx, entry);
-
-               if (pane->treePane && entry->expanded)
-                       idx = insert_entries(pane, entry->down, pattern, filter_flags, idx);
-       }
-
-       ShowWindow(pane->hwnd, SW_SHOW);
-
-       return idx;
-}
-
-
-static void format_bytes(LPTSTR buffer, LONGLONG bytes)
-{
-       const static TCHAR sFmtGB[] = {'%', '.', '1', 'f', ' ', 'G', 'B', '\0'};
-       const static TCHAR sFmtMB[] = {'%', '.', '1', 'f', ' ', 'M', 'B', '\0'};
-       const static TCHAR sFmtkB[] = {'%', '.', '1', 'f', ' ', 'k', 'B', '\0'};
-
-       float fBytes = (float)bytes;
-
-#ifdef __WINE__        /* work around for incorrect implementation of wsprintf()/_stprintf() in WINE */
-       if (bytes >= 1073741824)        /* 1 GB */
-               wsprintf(buffer, sFmtGB, fBytes/1073741824.f+.5f);
-       else if (bytes >= 1048576)      /* 1 MB */
-               wsprintf(buffer, sFmtMB, fBytes/1048576.f+.5f);
-       else if (bytes >= 1024)         /* 1 kB */
-               wsprintf(buffer, sFmtkB, fBytes/1024.f+.5f);
-#else
-       if (bytes >= 1073741824)        /* 1 GB */
-               _stprintf(buffer, sFmtGB, fBytes/1073741824.f+.5f);
-       else if (bytes >= 1048576)      /* 1 MB */
-               _stprintf(buffer, sFmtMB, fBytes/1048576.f+.5f);
-       else if (bytes >= 1024)         /* 1 kB */
-               _stprintf(buffer, sFmtkB, fBytes/1024.f+.5f);
-#endif
-       else
-               _stprintf(buffer, sLongNumFmt, bytes);
-}
-
-static void set_space_status(void)
-{
-       ULARGE_INTEGER ulFreeBytesToCaller, ulTotalBytes, ulFreeBytes;
-       TCHAR fmt[64], b1[64], b2[64], buffer[BUFFER_LEN];
-
-       if (GetDiskFreeSpaceEx(NULL, &ulFreeBytesToCaller, &ulTotalBytes, &ulFreeBytes)) {
-               format_bytes(b1, ulFreeBytesToCaller.QuadPart);
-               format_bytes(b2, ulTotalBytes.QuadPart);
-               wsprintf(buffer, RS(fmt,IDS_FREE_SPACE_FMT), b1, b2);
-       } else
-               lstrcpy(buffer, sQMarks);
-
-       SendMessage(Globals.hstatusbar, SB_SETTEXT, 0, (LPARAM)buffer);
-}
-
-
-static WNDPROC g_orgTreeWndProc;
-
-static void create_tree_window(HWND parent, Pane* pane, int id, int id_header, LPCTSTR pattern, int filter_flags)
-{
-       const static TCHAR sListBox[] = {'L','i','s','t','B','o','x','\0'};
-
-       static int s_init = 0;
-       Entry* entry = pane->root;
-
-       pane->hwnd = CreateWindow(sListBox, sEmpty, WS_CHILD|WS_VISIBLE|WS_HSCROLL|WS_VSCROLL|
-                                                               LBS_DISABLENOSCROLL|LBS_NOINTEGRALHEIGHT|LBS_OWNERDRAWFIXED|LBS_NOTIFY,
-                                                               0, 0, 0, 0, parent, (HMENU)id, Globals.hInstance, 0);
-
-       SetWindowLongPtr(pane->hwnd, GWLP_USERDATA, (LPARAM)pane);
-       g_orgTreeWndProc = SubclassWindow(pane->hwnd, TreeWndProc);
-
-       SetWindowFont(pane->hwnd, Globals.hfont, FALSE);
-
-       /* insert entries into listbox */
-       if (entry)
-               insert_entries(pane, entry, pattern, filter_flags, -1);
-
-       /* calculate column widths */
-       if (!s_init) {
-               s_init = 1;
-               init_output(pane->hwnd);
-       }
-
-       calc_widths(pane, TRUE);
-
-#ifndef _NO_EXTENSIONS
-       pane->hwndHeader = create_header(parent, pane, id_header);
-#endif
-}
-
-
-static void InitChildWindow(ChildWnd* child)
-{
-       create_tree_window(child->hwnd, &child->left, IDW_TREE_LEFT, IDW_HEADER_LEFT, NULL, TF_ALL);
-       create_tree_window(child->hwnd, &child->right, IDW_TREE_RIGHT, IDW_HEADER_RIGHT, child->filter_pattern, child->filter_flags);
-}
-
-
-static void format_date(const FILETIME* ft, TCHAR* buffer, int visible_cols)
-{
-       SYSTEMTIME systime;
-       FILETIME lft;
-       int len = 0;
-
-       *buffer = TEXT('\0');
-
-       if (!ft->dwLowDateTime && !ft->dwHighDateTime)
-               return;
-
-       if (!FileTimeToLocalFileTime(ft, &lft))
-               {err: lstrcpy(buffer,sQMarks); return;}
-
-       if (!FileTimeToSystemTime(&lft, &systime))
-               goto err;
-
-       if (visible_cols & COL_DATE) {
-               len = GetDateFormat(LOCALE_USER_DEFAULT, 0, &systime, 0, buffer, BUFFER_LEN);
-               if (!len)
-                       goto err;
-       }
-
-       if (visible_cols & COL_TIME) {
-               if (len)
-                       buffer[len-1] = ' ';
-
-               buffer[len++] = ' ';
-
-               if (!GetTimeFormat(LOCALE_USER_DEFAULT, 0, &systime, 0, buffer+len, BUFFER_LEN-len))
-                       buffer[len] = TEXT('\0');
-       }
-}
-
-
-static void calc_width(Pane* pane, LPDRAWITEMSTRUCT dis, int col, LPCTSTR str)
-{
-       RECT rt = {0, 0, 0, 0};
-
-       DrawText(dis->hDC, (LPTSTR)str, -1, &rt, DT_CALCRECT|DT_SINGLELINE|DT_NOPREFIX);
-
-       if (rt.right > pane->widths[col])
-               pane->widths[col] = rt.right;
-}
-
-static void calc_tabbed_width(Pane* pane, LPDRAWITEMSTRUCT dis, int col, LPCTSTR str)
-{
-       RECT rt = {0, 0, 0, 0};
-
-/*     DRAWTEXTPARAMS dtp = {sizeof(DRAWTEXTPARAMS), 2};
-       DrawTextEx(dis->hDC, (LPTSTR)str, -1, &rt, DT_CALCRECT|DT_SINGLELINE|DT_NOPREFIX|DT_EXPANDTABS|DT_TABSTOP, &dtp);*/
-
-       DrawText(dis->hDC, (LPTSTR)str, -1, &rt, DT_CALCRECT|DT_SINGLELINE|DT_EXPANDTABS|DT_TABSTOP|(2<<8));
-       /*FIXME rt (0,0) ??? */
-
-       if (rt.right > pane->widths[col])
-               pane->widths[col] = rt.right;
-}
-
-
-static void output_text(Pane* pane, LPDRAWITEMSTRUCT dis, int col, LPCTSTR str, DWORD flags)
-{
-       int x = dis->rcItem.left;
-       RECT rt;
-
-       rt.left   = x+pane->positions[col]+Globals.spaceSize.cx;
-       rt.top    = dis->rcItem.top;
-       rt.right  = x+pane->positions[col+1]-Globals.spaceSize.cx;
-       rt.bottom = dis->rcItem.bottom;
-
-       DrawText(dis->hDC, (LPTSTR)str, -1, &rt, DT_SINGLELINE|DT_NOPREFIX|flags);
-}
-
-static void output_tabbed_text(Pane* pane, LPDRAWITEMSTRUCT dis, int col, LPCTSTR str)
-{
-       int x = dis->rcItem.left;
-       RECT rt;
-
-       rt.left   = x+pane->positions[col]+Globals.spaceSize.cx;
-       rt.top    = dis->rcItem.top;
-       rt.right  = x+pane->positions[col+1]-Globals.spaceSize.cx;
-       rt.bottom = dis->rcItem.bottom;
-
-/*     DRAWTEXTPARAMS dtp = {sizeof(DRAWTEXTPARAMS), 2};
-       DrawTextEx(dis->hDC, (LPTSTR)str, -1, &rt, DT_SINGLELINE|DT_NOPREFIX|DT_EXPANDTABS|DT_TABSTOP, &dtp);*/
-
-       DrawText(dis->hDC, (LPTSTR)str, -1, &rt, DT_SINGLELINE|DT_EXPANDTABS|DT_TABSTOP|(2<<8));
-}
-
-static void output_number(Pane* pane, LPDRAWITEMSTRUCT dis, int col, LPCTSTR str)
-{
-       int x = dis->rcItem.left;
-       RECT rt;
-       LPCTSTR s = str;
-       TCHAR b[128];
-       LPTSTR d = b;
-       int pos;
-
-       rt.left   = x+pane->positions[col]+Globals.spaceSize.cx;
-       rt.top    = dis->rcItem.top;
-       rt.right  = x+pane->positions[col+1]-Globals.spaceSize.cx;
-       rt.bottom = dis->rcItem.bottom;
-
-       if (*s)
-               *d++ = *s++;
-
-       /* insert number separator characters */
-       pos = lstrlen(s) % 3;
-
-       while(*s)
-               if (pos--)
-                       *d++ = *s++;
-               else {
-                       *d++ = Globals.num_sep;
-                       pos = 3;
-               }
-
-       DrawText(dis->hDC, b, d-b, &rt, DT_RIGHT|DT_SINGLELINE|DT_NOPREFIX|DT_END_ELLIPSIS);
-}
-
-
-static BOOL is_exe_file(LPCTSTR ext)
-{
-       static const TCHAR executable_extensions[][4] = {
-               {'C','O','M','\0'},
-               {'E','X','E','\0'},
-               {'B','A','T','\0'},
-               {'C','M','D','\0'},
-#ifndef _NO_EXTENSIONS
-               {'C','M','M','\0'},
-               {'B','T','M','\0'},
-               {'A','W','K','\0'},
-#endif /* _NO_EXTENSIONS */
-               {'\0'}
-       };
-
-       TCHAR ext_buffer[_MAX_EXT];
-       const TCHAR (*p)[4];
-       LPCTSTR s;
-       LPTSTR d;
-
-       for(s=ext+1,d=ext_buffer; (*d=tolower(*s)); s++)
-               d++;
-
-       for(p=executable_extensions; (*p)[0]; p++)
-               if (!lstrcmpi(ext_buffer, *p))
-                       return TRUE;
-
-       return FALSE;
-}
-
-static BOOL is_registered_type(LPCTSTR ext)
-{
-       /* check if there exists a classname for this file extension in the registry */
-       if (!RegQueryValue(HKEY_CLASSES_ROOT, ext, NULL, NULL))
-               return TRUE;
-
-       return FALSE;
-}
-
-static enum FILE_TYPE get_file_type(LPCTSTR filename)
-{
-       LPCTSTR ext = _tcsrchr(filename, '.');
-       if (!ext)
-               ext = sEmpty;
-
-       if (is_exe_file(ext))
-               return FT_EXECUTABLE;
-       else if (is_registered_type(ext))
-               return FT_DOCUMENT;
-       else
-               return FT_OTHER;
-}
-
-
-static void draw_item(Pane* pane, LPDRAWITEMSTRUCT dis, Entry* entry, int calcWidthCol)
-{
-       TCHAR buffer[BUFFER_LEN];
-       DWORD attrs;
-       int visible_cols = pane->visible_cols;
-       COLORREF bkcolor, textcolor;
-       RECT focusRect = dis->rcItem;
-       HBRUSH hbrush;
-       enum IMAGE img;
-       int img_pos, cx;
-       int col = 0;
-
-       if (entry) {
-               attrs = entry->data.dwFileAttributes;
-
-               if (attrs & FILE_ATTRIBUTE_DIRECTORY) {
-                       if (entry->data.cFileName[0]==TEXT('.') && entry->data.cFileName[1]==TEXT('.')
-                                       && entry->data.cFileName[2]==TEXT('\0'))
-                               img = IMG_FOLDER_UP;
-#ifndef _NO_EXTENSIONS
-                       else if (entry->data.cFileName[0]==TEXT('.') && entry->data.cFileName[1]==TEXT('\0'))
-                               img = IMG_FOLDER_CUR;
-#endif
-                       else if (
-#ifdef _NO_EXTENSIONS
-                                        entry->expanded ||
-#endif
-                                        (pane->treePane && (dis->itemState&ODS_FOCUS)))
-                               img = IMG_OPEN_FOLDER;
-                       else
-                               img = IMG_FOLDER;
-               } else {
-                       switch(get_file_type(entry->data.cFileName)) {
-                         case FT_EXECUTABLE:   img = IMG_EXECUTABLE;   break;
-                         case FT_DOCUMENT:             img = IMG_DOCUMENT;             break;
-                         default:                              img = IMG_FILE;
-                       }
-               }
-       } else {
-               attrs = 0;
-               img = IMG_NONE;
-       }
-
-       if (pane->treePane) {
-               if (entry) {
-                       img_pos = dis->rcItem.left + entry->level*(IMAGE_WIDTH+TREE_LINE_DX);
-
-                       if (calcWidthCol == -1) {
-                               int x;
-                               int y = dis->rcItem.top + IMAGE_HEIGHT/2;
-                               Entry* up;
-                               RECT rt_clip;
-                               HRGN hrgn_org = CreateRectRgn(0, 0, 0, 0);
-                               HRGN hrgn;
-
-                               rt_clip.left   = dis->rcItem.left;
-                               rt_clip.top    = dis->rcItem.top;
-                               rt_clip.right  = dis->rcItem.left+pane->widths[col];
-                               rt_clip.bottom = dis->rcItem.bottom;
-
-                               hrgn = CreateRectRgnIndirect(&rt_clip);
-
-                               if (!GetClipRgn(dis->hDC, hrgn_org)) {
-                                       DeleteObject(hrgn_org);
-                                       hrgn_org = 0;
-                               }
-
-                               /* HGDIOBJ holdPen = SelectObject(dis->hDC, GetStockObject(BLACK_PEN)); */
-                               ExtSelectClipRgn(dis->hDC, hrgn, RGN_AND);
-                               DeleteObject(hrgn);
-
-                               if ((up=entry->up) != NULL) {
-                                       MoveToEx(dis->hDC, img_pos-IMAGE_WIDTH/2, y, 0);
-                                       LineTo(dis->hDC, img_pos-2, y);
-
-                                       x = img_pos - IMAGE_WIDTH/2;
-
-                                       do {
-                                               x -= IMAGE_WIDTH+TREE_LINE_DX;
-
-                                               if (up->next
-#ifndef _LEFT_FILES
-                                                       && (up->next->data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
-#endif
-                                                       ) {
-                                                       MoveToEx(dis->hDC, x, dis->rcItem.top, 0);
-                                                       LineTo(dis->hDC, x, dis->rcItem.bottom);
-                                               }
-                                       } while((up=up->up) != NULL);
-                               }
-
-                               x = img_pos - IMAGE_WIDTH/2;
-
-                               MoveToEx(dis->hDC, x, dis->rcItem.top, 0);
-                               LineTo(dis->hDC, x, y);
-
-                               if (entry->next
-#ifndef _LEFT_FILES
-                                       && (entry->next->data.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY)
-#endif
-                                       )
-                                       LineTo(dis->hDC, x, dis->rcItem.bottom);
-
-                               SelectClipRgn(dis->hDC, hrgn_org);
-                               if (hrgn_org) DeleteObject(hrgn_org);
-                               /* SelectObject(dis->hDC, holdPen); */
-                       } else if (calcWidthCol==col || calcWidthCol==COLUMNS) {
-                               int right = img_pos + IMAGE_WIDTH - TREE_LINE_DX;
-
-                               if (right > pane->widths[col])
-                                       pane->widths[col] = right;
-                       }
-               } else  {
-                       img_pos = dis->rcItem.left;
-               }
-       } else {
-               img_pos = dis->rcItem.left;
-
-               if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       pane->widths[col] = IMAGE_WIDTH;
-       }
-
-       if (calcWidthCol == -1) {
-               focusRect.left = img_pos - 2;
-
-#ifdef _NO_EXTENSIONS
-               if (pane->treePane && entry) {
-                       RECT rt = {0};
-
-                       DrawText(dis->hDC, entry->data.cFileName, -1, &rt, DT_CALCRECT|DT_SINGLELINE|DT_NOPREFIX);
-
-                       focusRect.right = dis->rcItem.left+pane->positions[col+1]+TREE_LINE_DX + rt.right +2;
-               }
-#else
-
-               if (attrs & FILE_ATTRIBUTE_COMPRESSED)
-                       textcolor = COLOR_COMPRESSED;
-               else
-#endif /* _NO_EXTENSIONS */
-                       textcolor = RGB(0,0,0);
-
-               if (dis->itemState & ODS_FOCUS) {
-                       textcolor = COLOR_SELECTION_TXT;
-                       bkcolor = COLOR_SELECTION;
-               } else {
-                       bkcolor = GetSysColor(COLOR_WINDOW);
-               }
-
-               hbrush = CreateSolidBrush(bkcolor);
-               FillRect(dis->hDC, &focusRect, hbrush);
-               DeleteObject(hbrush);
-
-               SetBkMode(dis->hDC, TRANSPARENT);
-               SetTextColor(dis->hDC, textcolor);
-
-               cx = pane->widths[col];
-
-               if (cx && img!=IMG_NONE) {
-                       if (cx > IMAGE_WIDTH)
-                               cx = IMAGE_WIDTH;
-
-#ifdef _SHELL_FOLDERS
-                       if (entry->hicon && entry->hicon!=(HICON)-1)
-                               DrawIconEx(dis->hDC, img_pos, dis->rcItem.top, entry->hicon, cx, GetSystemMetrics(SM_CYSMICON), 0, 0, DI_NORMAL);
-                       else
-#endif
-                               ImageList_DrawEx(Globals.himl, img, dis->hDC,
-                                                                img_pos, dis->rcItem.top, cx,
-                                                                IMAGE_HEIGHT, bkcolor, CLR_DEFAULT, ILD_NORMAL);
-               }
-       }
-
-       if (!entry)
-               return;
-
-#ifdef _NO_EXTENSIONS
-       if (img >= IMG_FOLDER_UP)
-               return;
-#endif
-
-       col++;
-
-       /* ouput file name */
-       if (calcWidthCol == -1)
-               output_text(pane, dis, col, entry->data.cFileName, 0);
-       else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-               calc_width(pane, dis, col, entry->data.cFileName);
-
-       col++;
-
-#ifdef _NO_EXTENSIONS
-  if (!pane->treePane) {
-#endif
-
-        /* display file size */
-       if (visible_cols & COL_SIZE) {
-#ifdef _NO_EXTENSIONS
-               if (!(attrs&FILE_ATTRIBUTE_DIRECTORY))
-#endif
-               {
-                       ULONGLONG size;
-
-                       size = ((ULONGLONG)entry->data.nFileSizeHigh << 32) | entry->data.nFileSizeLow;
-
-                       _stprintf(buffer, sLongNumFmt, size);
-
-                       if (calcWidthCol == -1)
-                               output_number(pane, dis, col, buffer);
-                       else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                               calc_width(pane, dis, col, buffer);/*TODO: not in every case time enough */
-               }
-
-               col++;
-       }
-
-       /* display file date */
-       if (visible_cols & (COL_DATE|COL_TIME)) {
-#ifndef _NO_EXTENSIONS
-               format_date(&entry->data.ftCreationTime, buffer, visible_cols);
-               if (calcWidthCol == -1)
-                       output_text(pane, dis, col, buffer, 0);
-               else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       calc_width(pane, dis, col, buffer);
-               col++;
-
-               format_date(&entry->data.ftLastAccessTime, buffer, visible_cols);
-               if (calcWidthCol == -1)
-                       output_text(pane, dis, col, buffer, 0);
-               else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       calc_width(pane, dis, col, buffer);
-               col++;
-#endif /* _NO_EXTENSIONS */
-
-               format_date(&entry->data.ftLastWriteTime, buffer, visible_cols);
-               if (calcWidthCol == -1)
-                       output_text(pane, dis, col, buffer, 0);
-               else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       calc_width(pane, dis, col, buffer);
-               col++;
-       }
-
-#ifndef _NO_EXTENSIONS
-       if (entry->bhfi_valid) {
-            ULONGLONG index = ((ULONGLONG)entry->bhfi.nFileIndexHigh << 32) | entry->bhfi.nFileIndexLow;
-
-               if (visible_cols & COL_INDEX) {
-                       _stprintf(buffer, sLongHexFmt, index);
-
-                       if (calcWidthCol == -1)
-                               output_text(pane, dis, col, buffer, DT_RIGHT);
-                       else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                               calc_width(pane, dis, col, buffer);
-
-                       col++;
-               }
-
-               if (visible_cols & COL_LINKS) {
-                       wsprintf(buffer, sNumFmt, entry->bhfi.nNumberOfLinks);
-
-                       if (calcWidthCol == -1)
-                               output_text(pane, dis, col, buffer, DT_CENTER);
-                       else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                               calc_width(pane, dis, col, buffer);
-
-                       col++;
-               }
-       } else
-               col += 2;
-#endif /* _NO_EXTENSIONS */
-
-       /* show file attributes */
-       if (visible_cols & COL_ATTRIBUTES) {
-#ifdef _NO_EXTENSIONS
-               const static TCHAR s4Tabs[] = {' ','\t',' ','\t',' ','\t',' ','\t',' ','\0'};
-               lstrcpy(buffer, s4Tabs);
-#else
-               const static TCHAR s11Tabs[] = {' ','\t',' ','\t',' ','\t',' ','\t',' ','\t',' ','\t',' ','\t',' ','\t',' ','\t',' ','\t',' ','\t',' ','\0'};
-               lstrcpy(buffer, s11Tabs);
-#endif
-
-               if (attrs & FILE_ATTRIBUTE_NORMAL)                                      buffer[ 0] = 'N';
-               else {
-                       if (attrs & FILE_ATTRIBUTE_READONLY)                    buffer[ 2] = 'R';
-                       if (attrs & FILE_ATTRIBUTE_HIDDEN)                              buffer[ 4] = 'H';
-                       if (attrs & FILE_ATTRIBUTE_SYSTEM)                              buffer[ 6] = 'S';
-                       if (attrs & FILE_ATTRIBUTE_ARCHIVE)                             buffer[ 8] = 'A';
-                       if (attrs & FILE_ATTRIBUTE_COMPRESSED)                  buffer[10] = 'C';
-#ifndef _NO_EXTENSIONS
-                       if (attrs & FILE_ATTRIBUTE_DIRECTORY)                   buffer[12] = 'D';
-                       if (attrs & FILE_ATTRIBUTE_ENCRYPTED)                   buffer[14] = 'E';
-                       if (attrs & FILE_ATTRIBUTE_TEMPORARY)                   buffer[16] = 'T';
-                       if (attrs & FILE_ATTRIBUTE_SPARSE_FILE)                 buffer[18] = 'P';
-                       if (attrs & FILE_ATTRIBUTE_REPARSE_POINT)               buffer[20] = 'Q';
-                       if (attrs & FILE_ATTRIBUTE_OFFLINE)                             buffer[22] = 'O';
-                       if (attrs & FILE_ATTRIBUTE_NOT_CONTENT_INDEXED) buffer[24] = 'X';
-#endif /* _NO_EXTENSIONS */
-               }
-
-               if (calcWidthCol == -1)
-                       output_tabbed_text(pane, dis, col, buffer);
-               else if (calcWidthCol==col || calcWidthCol==COLUMNS)
-                       calc_tabbed_width(pane, dis, col, buffer);
-
-               col++;
-       }
-
-/*TODO
-       if (flags.security) {
-               const static TCHAR sSecTabs[] = {
-                       ' ','\t',' ','\t',' ','\t',' ',
-                       ' ','\t',' ',
-                       ' ','\t',' ','\t',' ','\t',' ',
-                       ' ','\t',' ',
-                       ' ','\t',' ','\t',' ','\t',' ',
-                       '\0'
-               };
-
-               DWORD rights = get_access_mask();
-
-               lstrcpy(buffer, sSecTabs);
-
-               if (rights & FILE_READ_DATA)                    buffer[ 0] = 'R';
-               if (rights & FILE_WRITE_DATA)                   buffer[ 2] = 'W';
-               if (rights & FILE_APPEND_DATA)                  buffer[ 4] = 'A';
-               if (rights & FILE_READ_EA)                              {buffer[6] = 'entry'; buffer[ 7] = 'R';}
-               if (rights & FILE_WRITE_EA)                             {buffer[9] = 'entry'; buffer[10] = 'W';}
-               if (rights & FILE_EXECUTE)                              buffer[12] = 'X';
-               if (rights & FILE_DELETE_CHILD)                 buffer[14] = 'D';
-               if (rights & FILE_READ_ATTRIBUTES)              {buffer[16] = 'a'; buffer[17] = 'R';}
-               if (rights & FILE_WRITE_ATTRIBUTES)             {buffer[19] = 'a'; buffer[20] = 'W';}
-               if (rights & WRITE_DAC)                                 buffer[22] = 'C';
-               if (rights & WRITE_OWNER)                               buffer[24] = 'O';
-               if (rights & SYNCHRONIZE)                               buffer[26] = 'S';
-
-               output_text(dis, col++, buffer, DT_LEFT, 3, psize);
-       }
-
-       if (flags.description) {
-               get_description(buffer);
-               output_text(dis, col++, buffer, 0, psize);
-       }
-*/
-
-#ifdef _NO_EXTENSIONS
-  }
-
-        /* draw focus frame */
-       if ((dis->itemState&ODS_FOCUS) && calcWidthCol==-1) {
-               /* Currently [04/2000] Wine neither behaves exactly the same */
-               /* way as WIN 95 nor like Windows NT... */
-               HGDIOBJ lastBrush;
-               HPEN lastPen;
-               HPEN hpen;
-
-               if (!(GetVersion() & 0x80000000)) {     /* Windows NT or higher? */
-                       LOGBRUSH lb = {PS_SOLID, RGB(255,255,255)};
-                       hpen = ExtCreatePen(PS_COSMETIC|PS_ALTERNATE, 1, &lb, 0, 0);
-               } else
-                       hpen = CreatePen(PS_DOT, 0, RGB(255,255,255));
-
-               lastPen = SelectPen(dis->hDC, hpen);
-               lastBrush = SelectObject(dis->hDC, GetStockObject(HOLLOW_BRUSH));
-               SetROP2(dis->hDC, R2_XORPEN);
-               Rectangle(dis->hDC, focusRect.left, focusRect.top, focusRect.right, focusRect.bottom);
-               SelectObject(dis->hDC, lastBrush);
-               SelectObject(dis->hDC, lastPen);
-               DeleteObject(hpen);
-       }
-#endif /* _NO_EXTENSIONS */
-}
-
-
-#ifdef _NO_EXTENSIONS
-
-static void draw_splitbar(HWND hwnd, int x)
-{
-       RECT rt;
-       HDC hdc = GetDC(hwnd);
-
-       GetClientRect(hwnd, &rt);
-
-       rt.left = x - SPLIT_WIDTH/2;
-       rt.right = x + SPLIT_WIDTH/2+1;
-
-       InvertRect(hdc, &rt);
-
-       ReleaseDC(hwnd, hdc);
-}
-
-#endif /* _NO_EXTENSIONS */
-
-
-#ifndef _NO_EXTENSIONS
-
-static void set_header(Pane* pane)
-{
-       HD_ITEM item;
-       int scroll_pos = GetScrollPos(pane->hwnd, SB_HORZ);
-       int i=0, x=0;
-
-       item.mask = HDI_WIDTH;
-       item.cxy = 0;
-
-       for(; x+pane->widths[i]<scroll_pos && i<COLUMNS; i++) {
-               x += pane->widths[i];
-               Header_SetItem(pane->hwndHeader, i, &item);
-       }
-
-       if (i < COLUMNS) {
-               x += pane->widths[i];
-               item.cxy = x - scroll_pos;
-               Header_SetItem(pane->hwndHeader, i++, &item);
-
-               for(; i<COLUMNS; i++) {
-                       item.cxy = pane->widths[i];
-                       x += pane->widths[i];
-                       Header_SetItem(pane->hwndHeader, i, &item);
-               }
-       }
-}
-
-static LRESULT pane_notify(Pane* pane, NMHDR* pnmh)
-{
-       switch(pnmh->code) {
-               case HDN_TRACK:
-               case HDN_ENDTRACK: {
-                       HD_NOTIFY* phdn = (HD_NOTIFY*) pnmh;
-                       int idx = phdn->iItem;
-                       int dx = phdn->pitem->cxy - pane->widths[idx];
-                       int i;
-
-                       RECT clnt;
-                       GetClientRect(pane->hwnd, &clnt);
-
-                       /* move immediate to simulate HDS_FULLDRAG (for now [04/2000] not really needed with WINELIB) */
-                       Header_SetItem(pane->hwndHeader, idx, phdn->pitem);
-
-                       pane->widths[idx] += dx;
-
-                       for(i=idx; ++i<=COLUMNS; )
-                               pane->positions[i] += dx;
-
-                       {
-                               int scroll_pos = GetScrollPos(pane->hwnd, SB_HORZ);
-                               RECT rt_scr;
-                               RECT rt_clip;
-
-                               rt_scr.left   = pane->positions[idx+1]-scroll_pos;
-                               rt_scr.top    = 0;
-                               rt_scr.right  = clnt.right;
-                               rt_scr.bottom = clnt.bottom;
-
-                               rt_clip.left   = pane->positions[idx]-scroll_pos;
-                               rt_clip.top    = 0;
-                               rt_clip.right  = clnt.right;
-                               rt_clip.bottom = clnt.bottom;
-
-                               if (rt_scr.left < 0) rt_scr.left = 0;
-                               if (rt_clip.left < 0) rt_clip.left = 0;
-
-                               ScrollWindowEx(pane->hwnd, dx, 0, &rt_scr, &rt_clip, 0, 0, SW_INVALIDATE);
-
-                               rt_clip.right = pane->positions[idx+1];
-                               RedrawWindow(pane->hwnd, &rt_clip, 0, RDW_INVALIDATE|RDW_UPDATENOW);
-
-                               if (pnmh->code == HDN_ENDTRACK) {
-                                       ListBox_SetHorizontalExtent(pane->hwnd, pane->positions[COLUMNS]);
-
-                                       if (GetScrollPos(pane->hwnd, SB_HORZ) != scroll_pos)
-                                               set_header(pane);
-                               }
-                       }
-
-                       return FALSE;
-               }
-
-               case HDN_DIVIDERDBLCLICK: {
-                       HD_NOTIFY* phdn = (HD_NOTIFY*) pnmh;
-                       HD_ITEM item;
-
-                       calc_single_width(pane, phdn->iItem);
-                       item.mask = HDI_WIDTH;
-                       item.cxy = pane->widths[phdn->iItem];
-
-                       Header_SetItem(pane->hwndHeader, phdn->iItem, &item);
-                       InvalidateRect(pane->hwnd, 0, TRUE);
-                       break;}
-       }
-
-       return 0;
-}
-
-#endif /* _NO_EXTENSIONS */
-
-
-static void scan_entry(ChildWnd* child, Entry* entry, int idx, HWND hwnd)
-{
-       TCHAR path[MAX_PATH];
-       HCURSOR old_cursor = SetCursor(LoadCursor(0, IDC_WAIT));
-
-       /* delete sub entries in left pane */
-       for(;;) {
-               LRESULT res = ListBox_GetItemData(child->left.hwnd, idx+1);
-               Entry* sub = (Entry*) res;
-
-               if (res==LB_ERR || !sub || sub->level<=entry->level)
-                       break;
-
-               ListBox_DeleteString(child->left.hwnd, idx+1);
-       }
-
-       /* empty right pane */
-       ListBox_ResetContent(child->right.hwnd);
-
-       /* release memory */
-       free_entries(entry);
-
-       /* read contents from disk */
-#ifdef _SHELL_FOLDERS
-       if (entry->etype == ET_SHELL)
-       {
-               read_directory(entry, NULL, child->sortOrder, hwnd);
-       }
-       else
-#endif
-       {
-               get_path(entry, path);
-               read_directory(entry, path, child->sortOrder, hwnd);
-       }
-
-       /* insert found entries in right pane */
-       insert_entries(&child->right, entry->down, child->filter_pattern, child->filter_flags, -1);
-       calc_widths(&child->right, FALSE);
-#ifndef _NO_EXTENSIONS
-       set_header(&child->right);
-#endif
-
-       child->header_wdths_ok = FALSE;
-
-       SetCursor(old_cursor);
-}
-
-
-/* expand a directory entry */
-
-static BOOL expand_entry(ChildWnd* child, Entry* dir)
-{
-       int idx;
-       Entry* p;
-
-       if (!dir || dir->expanded || !dir->down)
-               return FALSE;
-
-       p = dir->down;
-
-       if (p->data.cFileName[0]=='.' && p->data.cFileName[1]=='\0' && p->next) {
-               p = p->next;
-
-               if (p->data.cFileName[0]=='.' && p->data.cFileName[1]=='.' &&
-                               p->data.cFileName[2]=='\0' && p->next)
-                       p = p->next;
-       }
-
-       /* no subdirectories ? */
-       if (!(p->data.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY))
-               return FALSE;
-
-       idx = ListBox_FindItemData(child->left.hwnd, 0, dir);
-
-       dir->expanded = TRUE;
-
-       /* insert entries in left pane */
-       insert_entries(&child->left, p, NULL, TF_ALL, idx);
-
-       if (!child->header_wdths_ok) {
-               if (calc_widths(&child->left, FALSE)) {
-#ifndef _NO_EXTENSIONS
-                       set_header(&child->left);
-#endif
-
-                       child->header_wdths_ok = TRUE;
-               }
-       }
-
-       return TRUE;
-}
-
-
-static void collapse_entry(Pane* pane, Entry* dir)
-{
-       int idx = ListBox_FindItemData(pane->hwnd, 0, dir);
-
-       ShowWindow(pane->hwnd, SW_HIDE);
-
-       /* hide sub entries */
-       for(;;) {
-               LRESULT res = ListBox_GetItemData(pane->hwnd, idx+1);
-               Entry* sub = (Entry*) res;
-
-               if (res==LB_ERR || !sub || sub->level<=dir->level)
-                       break;
-
-               ListBox_DeleteString(pane->hwnd, idx+1);
-       }
-
-       dir->expanded = FALSE;
-
-       ShowWindow(pane->hwnd, SW_SHOW);
-}
-
-
-static void refresh_right_pane(ChildWnd* child)
-{
-       ListBox_ResetContent(child->right.hwnd);
-       insert_entries(&child->right, child->right.root, child->filter_pattern, child->filter_flags, -1);
-       calc_widths(&child->right, FALSE);
-
-#ifndef _NO_EXTENSIONS
-       set_header(&child->right);
-#endif
-}
-
-static void set_curdir(ChildWnd* child, Entry* entry, int idx, HWND hwnd)
-{
-       TCHAR path[MAX_PATH];
-
-       if (!entry)
-               return;
-
-       path[0] = '\0';
-
-       child->left.cur = entry;
-
-       child->right.root = entry->down? entry->down: entry;
-       child->right.cur = entry;
-
-       if (!entry->scanned)
-               scan_entry(child, entry, idx, hwnd);
-       else
-               refresh_right_pane(child);
-
-       get_path(entry, path);
-       lstrcpy(child->path, path);
-
-       if (child->hwnd)        /* only change window title, if the window already exists */
-               SetWindowText(child->hwnd, path);
-
-       if (path[0])
-               if (SetCurrentDirectory(path))
-                       set_space_status();
-}
-
-
-static void refresh_child(ChildWnd* child)
-{
-       TCHAR path[MAX_PATH], drv[_MAX_DRIVE+1];
-       Entry* entry;
-       int idx;
-
-       get_path(child->left.cur, path);
-       _tsplitpath(path, drv, NULL, NULL, NULL);
-
-       child->right.root = NULL;
-
-       scan_entry(child, &child->root.entry, 0, child->hwnd);
-
-#ifdef _SHELL_FOLDERS
-       if (child->root.entry.etype == ET_SHELL)
-               entry = read_tree(&child->root, NULL, get_path_pidl(path,child->hwnd), drv, child->sortOrder, child->hwnd);
-       else
-#endif
-               entry = read_tree(&child->root, path, NULL, drv, child->sortOrder, child->hwnd);
-
-       if (!entry)
-               entry = &child->root.entry;
-
-       insert_entries(&child->left, child->root.entry.down, NULL, TF_ALL, 0);
-
-       set_curdir(child, entry, 0, child->hwnd);
-
-       idx = ListBox_FindItemData(child->left.hwnd, 0, child->left.cur);
-       ListBox_SetCurSel(child->left.hwnd, idx);
-}
-
-
-static void create_drive_bar(void)
-{
-       TBBUTTON drivebarBtn = {0, 0, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0};
-#ifndef _NO_EXTENSIONS
-       TCHAR b1[BUFFER_LEN];
-#endif
-       int btn = 1;
-       PTSTR p;
-
-       GetLogicalDriveStrings(BUFFER_LEN, Globals.drives);
-
-       Globals.hdrivebar = CreateToolbarEx(Globals.hMainWnd, WS_CHILD|WS_VISIBLE|CCS_NOMOVEY|TBSTYLE_LIST,
-                               IDW_DRIVEBAR, 2, Globals.hInstance, IDB_DRIVEBAR, &drivebarBtn,
-                               0, 16, 13, 16, 13, sizeof(TBBUTTON));
-
-#ifndef _NO_EXTENSIONS
-#ifdef __WINE__
-       /* insert unix file system button */
-       b1[0] = '/';
-       b1[1] = '\0';
-       b1[2] = '\0';
-       SendMessage(Globals.hdrivebar, TB_ADDSTRING, 0, (LPARAM)b1);
-
-       drivebarBtn.idCommand = ID_DRIVE_UNIX_FS;
-       SendMessage(Globals.hdrivebar, TB_INSERTBUTTON, btn++, (LPARAM)&drivebarBtn);
-       drivebarBtn.iString++;
-#endif
-#ifdef _SHELL_FOLDERS
-       /* insert shell namespace button */
-       load_string(b1, IDS_SHELL);
-       b1[lstrlen(b1)+1] = '\0';
-       SendMessage(Globals.hdrivebar, TB_ADDSTRING, 0, (LPARAM)b1);
-
-       drivebarBtn.idCommand = ID_DRIVE_SHELL_NS;
-       SendMessage(Globals.hdrivebar, TB_INSERTBUTTON, btn++, (LPARAM)&drivebarBtn);
-       drivebarBtn.iString++;
-#endif
-
-       /* register windows drive root strings */
-       SendMessage(Globals.hdrivebar, TB_ADDSTRING, 0, (LPARAM)Globals.drives);
-#endif
-
-       drivebarBtn.idCommand = ID_DRIVE_FIRST;
-
-       for(p=Globals.drives; *p; ) {
-#ifdef _NO_EXTENSIONS
-               /* insert drive letter */
-               TCHAR b[3] = {tolower(*p)};
-               SendMessage(Globals.hdrivebar, TB_ADDSTRING, 0, (LPARAM)b);
-#endif
-               switch(GetDriveType(p)) {
-                       case DRIVE_REMOVABLE:   drivebarBtn.iBitmap = 1;        break;
-                       case DRIVE_CDROM:               drivebarBtn.iBitmap = 3;        break;
-                       case DRIVE_REMOTE:              drivebarBtn.iBitmap = 4;        break;
-                       case DRIVE_RAMDISK:             drivebarBtn.iBitmap = 5;        break;
-                       default:/*DRIVE_FIXED*/ drivebarBtn.iBitmap = 2;
-               }
-
-               SendMessage(Globals.hdrivebar, TB_INSERTBUTTON, btn++, (LPARAM)&drivebarBtn);
-               drivebarBtn.idCommand++;
-               drivebarBtn.iString++;
-
-               while(*p++);
-       }
-}
-
-static void refresh_drives(void)
-{
-       RECT rect;
-
-       /* destroy drive bar */
-       DestroyWindow(Globals.hdrivebar);
-       Globals.hdrivebar = 0;
-
-       /* re-create drive bar */
-       create_drive_bar();
-
-       /* update window layout */
-       GetClientRect(Globals.hMainWnd, &rect);
-       SendMessage(Globals.hMainWnd, WM_SIZE, 0, MAKELONG(rect.right, rect.bottom));
-}
-
-
-static BOOL launch_file(HWND hwnd, LPCTSTR cmd, UINT nCmdShow)
-{
-       HINSTANCE hinst = ShellExecute(hwnd, NULL/*operation*/, cmd, NULL/*parameters*/, NULL/*dir*/, nCmdShow);
-
-       if ((int)hinst <= 32) {
-               display_error(hwnd, GetLastError());
-               return FALSE;
-       }
-
-       return TRUE;
-}
-
-
-static BOOL launch_entry(Entry* entry, HWND hwnd, UINT nCmdShow)
-{
-       TCHAR cmd[MAX_PATH];
-
-#ifdef _SHELL_FOLDERS
-       if (entry->etype == ET_SHELL) {
-               BOOL ret = TRUE;
-
-               SHELLEXECUTEINFO shexinfo;
-
-               shexinfo.cbSize = sizeof(SHELLEXECUTEINFO);
-               shexinfo.fMask = SEE_MASK_IDLIST;
-               shexinfo.hwnd = hwnd;
-               shexinfo.lpVerb = NULL;
-               shexinfo.lpFile = NULL;
-               shexinfo.lpParameters = NULL;
-               shexinfo.lpDirectory = NULL;
-               shexinfo.nShow = nCmdShow;
-               shexinfo.lpIDList = get_to_absolute_pidl(entry, hwnd);
-
-               if (!ShellExecuteEx(&shexinfo)) {
-                       display_error(hwnd, GetLastError());
-                       ret = FALSE;
-               }
-
-               if (shexinfo.lpIDList != entry->pidl)
-                       IMalloc_Free(Globals.iMalloc, shexinfo.lpIDList);
-
-               return ret;
-       }
-#endif
-
-       get_path(entry, cmd);
-
-        /* start program, open document... */
-       return launch_file(hwnd, cmd, nCmdShow);
-}
-
-
-static void activate_entry(ChildWnd* child, Pane* pane, HWND hwnd)
-{
-       Entry* entry = pane->cur;
-
-       if (!entry)
-               return;
-
-       if (entry->data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
-               int scanned_old = entry->scanned;
-
-               if (!scanned_old)
-                       scan_entry(child, entry, ListBox_GetCurSel(child->left.hwnd), hwnd);
-
-#ifndef _NO_EXTENSIONS
-               if (entry->data.cFileName[0]=='.' && entry->data.cFileName[1]=='\0')
-                       return;
-#endif
-
-               if (entry->data.cFileName[0]=='.' && entry->data.cFileName[1]=='.' && entry->data.cFileName[2]=='\0') {
-                       entry = child->left.cur->up;
-                       collapse_entry(&child->left, entry);
-                       goto focus_entry;
-               } else if (entry->expanded)
-                       collapse_entry(pane, child->left.cur);
-               else {
-                       expand_entry(child, child->left.cur);
-
-                       if (!pane->treePane) focus_entry: {
-                               int idx = ListBox_FindItemData(child->left.hwnd, ListBox_GetCurSel(child->left.hwnd), entry);
-                               ListBox_SetCurSel(child->left.hwnd, idx);
-                               set_curdir(child, entry, idx, hwnd);
-                       }
-               }
-
-               if (!scanned_old) {
-                       calc_widths(pane, FALSE);
-
-#ifndef _NO_EXTENSIONS
-                       set_header(pane);
-#endif
-               }
-       } else {
-               if (GetKeyState(VK_MENU) < 0)
-                       show_properties_dlg(entry, child->hwnd);
-               else
-                       launch_entry(entry, child->hwnd, SW_SHOWNORMAL);
-       }
-}
-
-
-static BOOL pane_command(Pane* pane, UINT cmd)
-{
-       switch(cmd) {
-               case ID_VIEW_NAME:
-                       if (pane->visible_cols) {
-                               pane->visible_cols = 0;
-                               calc_widths(pane, TRUE);
-#ifndef _NO_EXTENSIONS
-                               set_header(pane);
-#endif
-                               InvalidateRect(pane->hwnd, 0, TRUE);
-                               CheckMenuItem(Globals.hMenuView, ID_VIEW_NAME, MF_BYCOMMAND|MF_CHECKED);
-                               CheckMenuItem(Globals.hMenuView, ID_VIEW_ALL_ATTRIBUTES, MF_BYCOMMAND);
-                               CheckMenuItem(Globals.hMenuView, ID_VIEW_SELECTED_ATTRIBUTES, MF_BYCOMMAND);
-                       }
-                       break;
-
-               case ID_VIEW_ALL_ATTRIBUTES:
-                       if (pane->visible_cols != COL_ALL) {
-                               pane->visible_cols = COL_ALL;
-                               calc_widths(pane, TRUE);
-#ifndef _NO_EXTENSIONS
-                               set_header(pane);
-#endif
-                               InvalidateRect(pane->hwnd, 0, TRUE);
-                               CheckMenuItem(Globals.hMenuView, ID_VIEW_NAME, MF_BYCOMMAND);
-                               CheckMenuItem(Globals.hMenuView, ID_VIEW_ALL_ATTRIBUTES, MF_BYCOMMAND|MF_CHECKED);
-                               CheckMenuItem(Globals.hMenuView, ID_VIEW_SELECTED_ATTRIBUTES, MF_BYCOMMAND);
-                       }
-                       break;
-
-#ifndef _NO_EXTENSIONS
-               case ID_PREFERRED_SIZES: {
-                       calc_widths(pane, TRUE);
-                       set_header(pane);
-                       InvalidateRect(pane->hwnd, 0, TRUE);
-                       break;}
-#endif
-
-                       /* TODO: more command ids... */
-
-               default:
-                       return FALSE;
-       }
-
-       return TRUE;
-}
-
-
-static void set_sort_order(ChildWnd* child, SORT_ORDER sortOrder)
-{
-       if (child->sortOrder != sortOrder) {
-               child->sortOrder = sortOrder;
-               refresh_child(child);
-       }
-}
-
-static void update_view_menu(ChildWnd* child)
-{
-       CheckMenuItem(Globals.hMenuView, ID_VIEW_SORT_NAME, child->sortOrder==SORT_NAME? MF_CHECKED: MF_UNCHECKED);
-       CheckMenuItem(Globals.hMenuView, ID_VIEW_SORT_TYPE, child->sortOrder==SORT_EXT? MF_CHECKED: MF_UNCHECKED);
-       CheckMenuItem(Globals.hMenuView, ID_VIEW_SORT_SIZE, child->sortOrder==SORT_SIZE? MF_CHECKED: MF_UNCHECKED);
-       CheckMenuItem(Globals.hMenuView, ID_VIEW_SORT_DATE, child->sortOrder==SORT_DATE? MF_CHECKED: MF_UNCHECKED);
-}
-
-
-static BOOL is_directory(LPCTSTR target)
-{
-       /*TODO correctly handle UNIX paths */
-       DWORD target_attr = GetFileAttributes(target);
-
-       if (target_attr == INVALID_FILE_ATTRIBUTES)
-               return FALSE;
-
-       return target_attr&FILE_ATTRIBUTE_DIRECTORY? TRUE: FALSE;
-}
-
-static BOOL prompt_target(Pane* pane, LPTSTR source, LPTSTR target)
-{
-       TCHAR path[MAX_PATH];
-       int len;
-
-       get_path(pane->cur, path);
-
-       if (DialogBoxParam(Globals.hInstance, MAKEINTRESOURCE(IDD_SELECT_DESTINATION), pane->hwnd, DestinationDlgProc, (LPARAM)path) != IDOK)
-               return FALSE;
-
-       get_path(pane->cur, source);
-
-       /* convert relative targets to absolute paths */
-       if (path[0]!='/' && path[1]!=':') {
-               get_path(pane->cur->up, target);
-               len = lstrlen(target);
-
-               if (target[len-1]!='\\' && target[len-1]!='/')
-                       target[len++] = '/';
-
-               lstrcpy(target+len, path);
-       } else
-               lstrcpy(target, path);
-
-       /* If the target already exists as directory, create a new target below this. */
-       if (is_directory(path)) {
-               TCHAR fname[_MAX_FNAME], ext[_MAX_EXT];
-               const static TCHAR sAppend[] = {'%','s','/','%','s','%','s','\0'};
-
-               _tsplitpath(source, NULL, NULL, fname, ext);
-
-               wsprintf(target, sAppend, path, fname, ext);
-       }
-
-       return TRUE;
-}
-
-
-static IContextMenu2* s_pctxmenu2 = NULL;
-
-#ifndef __MINGW32__    /* IContextMenu3 missing in MinGW (as of 6.2.2005) */
-static IContextMenu3* s_pctxmenu3 = NULL;
-#endif
-
-static void CtxMenu_reset(void)
-{
-       s_pctxmenu2 = NULL;
-
-#ifndef __MINGW32__    /* IContextMenu3 missing in MinGW (as of 6.2.2005) */
-       s_pctxmenu3 = NULL;
-#endif
-}
-
-static IContextMenu* CtxMenu_query_interfaces(IContextMenu* pcm1)
-{
-       IContextMenu* pcm = NULL;
-
-       CtxMenu_reset();
-
-#ifndef __MINGW32__    /* IContextMenu3 missing in MinGW (as of 6.2.2005) */
-       if (IUnknown_QueryInterface(pcm1, &IID_IContextMenu3, (void**)&pcm) == NOERROR)
-               s_pctxmenu3 = (LPCONTEXTMENU3)pcm;
-       else
-#endif
-       if (IUnknown_QueryInterface(pcm1, &IID_IContextMenu2, (void**)&pcm) == NOERROR)
-               s_pctxmenu2 = (LPCONTEXTMENU2)pcm;
-
-       if (pcm) {
-               IUnknown_Release(pcm1);
-               return pcm;
-       } else
-               return pcm1;
-}
-
-static BOOL CtxMenu_HandleMenuMsg(UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-#ifndef __MINGW32__    /* IContextMenu3 missing in MinGW (as of 6.2.2005) */
-       if (s_pctxmenu3) {
-               if (SUCCEEDED((*s_pctxmenu3->lpVtbl->HandleMenuMsg)(s_pctxmenu3, nmsg, wparam, lparam)))
-                       return TRUE;
-       }
-#endif
-
-       if (s_pctxmenu2)
-               if (SUCCEEDED((*s_pctxmenu2->lpVtbl->HandleMenuMsg)(s_pctxmenu2, nmsg, wparam, lparam)))
-                       return TRUE;
-
-       return FALSE;
-}
-
-
-static HRESULT ShellFolderContextMenu(IShellFolder* shell_folder, HWND hwndParent, int cidl, LPCITEMIDLIST* apidl, int x, int y)
-{
-       IContextMenu* pcm;
-       BOOL executed = FALSE;
-
-       HRESULT hr = IShellFolder_GetUIObjectOf(shell_folder, hwndParent, cidl, apidl, &IID_IContextMenu, NULL, (LPVOID*)&pcm);
-/*     HRESULT hr = CDefFolderMenu_Create2(dir?dir->_pidl:DesktopFolder(), hwndParent, 1, &pidl, shell_folder, NULL, 0, NULL, &pcm); */
-
-       if (SUCCEEDED(hr)) {
-               HMENU hmenu = CreatePopupMenu();
-
-               pcm = CtxMenu_query_interfaces(pcm);
-
-               if (hmenu) {
-                       hr = (*pcm->lpVtbl->QueryContextMenu)(pcm, hmenu, 0, FCIDM_SHVIEWFIRST, FCIDM_SHVIEWLAST, CMF_NORMAL);
-
-                       if (SUCCEEDED(hr)) {
-                               UINT idCmd = TrackPopupMenu(hmenu, TPM_LEFTALIGN|TPM_RETURNCMD|TPM_RIGHTBUTTON, x, y, 0, hwndParent, NULL);
-
-                               CtxMenu_reset();
-
-                               if (idCmd) {
-                                       CMINVOKECOMMANDINFO cmi;
-
-                                       cmi.cbSize = sizeof(CMINVOKECOMMANDINFO);
-                                       cmi.fMask = 0;
-                                       cmi.hwnd = hwndParent;
-                                       cmi.lpVerb = (LPCSTR)(INT_PTR)(idCmd - FCIDM_SHVIEWFIRST);
-                                       cmi.lpParameters = NULL;
-                                       cmi.lpDirectory = NULL;
-                                       cmi.nShow = SW_SHOWNORMAL;
-                                       cmi.dwHotKey = 0;
-                                       cmi.hIcon = 0;
-
-                                       hr = (*pcm->lpVtbl->InvokeCommand)(pcm, &cmi);
-                                       executed = TRUE;
-                               }
-                       } else
-                               CtxMenu_reset();
-               }
-
-               IUnknown_Release(pcm);
-       }
-
-       return FAILED(hr)? hr: executed? S_OK: S_FALSE;
-}
-
-
-static LRESULT CALLBACK ChildWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       ChildWnd* child = (ChildWnd*) GetWindowLongPtr(hwnd, GWLP_USERDATA);
-       ASSERT(child);
-
-       switch(nmsg) {
-               case WM_DRAWITEM: {
-                       LPDRAWITEMSTRUCT dis = (LPDRAWITEMSTRUCT)lparam;
-                       Entry* entry = (Entry*) dis->itemData;
-
-                       if (dis->CtlID == IDW_TREE_LEFT)
-                               draw_item(&child->left, dis, entry, -1);
-                       else if (dis->CtlID == IDW_TREE_RIGHT)
-                               draw_item(&child->right, dis, entry, -1);
-                       else
-                               goto draw_menu_item;
-
-                       return TRUE;}
-
-               case WM_CREATE:
-                       InitChildWindow(child);
-                       break;
-
-               case WM_NCDESTROY:
-                       free_child_window(child);
-                       SetWindowLongPtr(hwnd, GWLP_USERDATA, 0);
-                       break;
-
-               case WM_PAINT: {
-                       PAINTSTRUCT ps;
-                       HBRUSH lastBrush;
-                       RECT rt;
-                       GetClientRect(hwnd, &rt);
-                       BeginPaint(hwnd, &ps);
-                       rt.left = child->split_pos-SPLIT_WIDTH/2;
-                       rt.right = child->split_pos+SPLIT_WIDTH/2+1;
-                       lastBrush = SelectBrush(ps.hdc, (HBRUSH)GetStockObject(COLOR_SPLITBAR));
-                       Rectangle(ps.hdc, rt.left, rt.top-1, rt.right, rt.bottom+1);
-                       SelectObject(ps.hdc, lastBrush);
-#ifdef _NO_EXTENSIONS
-                       rt.top = rt.bottom - GetSystemMetrics(SM_CYHSCROLL);
-                       FillRect(ps.hdc, &rt, GetStockObject(BLACK_BRUSH));
-#endif
-                       EndPaint(hwnd, &ps);
-                       break;}
-
-               case WM_SETCURSOR:
-                       if (LOWORD(lparam) == HTCLIENT) {
-                               POINT pt;
-                               GetCursorPos(&pt);
-                               ScreenToClient(hwnd, &pt);
-
-                               if (pt.x>=child->split_pos-SPLIT_WIDTH/2 && pt.x<child->split_pos+SPLIT_WIDTH/2+1) {
-                                       SetCursor(LoadCursor(0, IDC_SIZEWE));
-                                       return TRUE;
-                               }
-                       }
-                       goto def;
-
-               case WM_LBUTTONDOWN: {
-                       RECT rt;
-                       int x = GET_X_LPARAM(lparam);
-
-                       GetClientRect(hwnd, &rt);
-
-                       if (x>=child->split_pos-SPLIT_WIDTH/2 && x<child->split_pos+SPLIT_WIDTH/2+1) {
-                               last_split = child->split_pos;
-#ifdef _NO_EXTENSIONS
-                               draw_splitbar(hwnd, last_split);
-#endif
-                               SetCapture(hwnd);
-                       }
-
-                       break;}
-
-               case WM_LBUTTONUP:
-                       if (GetCapture() == hwnd) {
-#ifdef _NO_EXTENSIONS
-                               RECT rt;
-                               int x = LOWORD(lparam);
-                               draw_splitbar(hwnd, last_split);
-                               last_split = -1;
-                               GetClientRect(hwnd, &rt);
-                               child->split_pos = x;
-                               resize_tree(child, rt.right, rt.bottom);
-#endif
-                               ReleaseCapture();
-                       }
-                       break;
-
-#ifdef _NO_EXTENSIONS
-               case WM_CAPTURECHANGED:
-                       if (GetCapture()==hwnd && last_split>=0)
-                               draw_splitbar(hwnd, last_split);
-                       break;
-#endif
-
-               case WM_KEYDOWN:
-                       if (wparam == VK_ESCAPE)
-                               if (GetCapture() == hwnd) {
-                                       RECT rt;
-#ifdef _NO_EXTENSIONS
-                                       draw_splitbar(hwnd, last_split);
-#else
-                                       child->split_pos = last_split;
-#endif
-                                       GetClientRect(hwnd, &rt);
-                                       resize_tree(child, rt.right, rt.bottom);
-                                       last_split = -1;
-                                       ReleaseCapture();
-                                       SetCursor(LoadCursor(0, IDC_ARROW));
-                               }
-                       break;
-
-               case WM_MOUSEMOVE:
-                       if (GetCapture() == hwnd) {
-                               RECT rt;
-                               int x = LOWORD(lparam);
-
-#ifdef _NO_EXTENSIONS
-                               HDC hdc = GetDC(hwnd);
-                               GetClientRect(hwnd, &rt);
-
-                               rt.left = last_split-SPLIT_WIDTH/2;
-                               rt.right = last_split+SPLIT_WIDTH/2+1;
-                               InvertRect(hdc, &rt);
-
-                               last_split = x;
-                               rt.left = x-SPLIT_WIDTH/2;
-                               rt.right = x+SPLIT_WIDTH/2+1;
-                               InvertRect(hdc, &rt);
-
-                               ReleaseDC(hwnd, hdc);
-#else
-                               GetClientRect(hwnd, &rt);
-
-                               if (x>=0 && x<rt.right) {
-                                       child->split_pos = x;
-                                       resize_tree(child, rt.right, rt.bottom);
-                                       rt.left = x-SPLIT_WIDTH/2;
-                                       rt.right = x+SPLIT_WIDTH/2+1;
-                                       InvalidateRect(hwnd, &rt, FALSE);
-                                       UpdateWindow(child->left.hwnd);
-                                       UpdateWindow(hwnd);
-                                       UpdateWindow(child->right.hwnd);
-                               }
-#endif
-                       }
-                       break;
-
-#ifndef _NO_EXTENSIONS
-               case WM_GETMINMAXINFO:
-                       DefMDIChildProc(hwnd, nmsg, wparam, lparam);
-
-                       {LPMINMAXINFO lpmmi = (LPMINMAXINFO)lparam;
-
-                       lpmmi->ptMaxTrackSize.x <<= 1;/*2*GetSystemMetrics(SM_CXSCREEN) / SM_CXVIRTUALSCREEN */
-                       lpmmi->ptMaxTrackSize.y <<= 1;/*2*GetSystemMetrics(SM_CYSCREEN) / SM_CYVIRTUALSCREEN */
-                       break;}
-#endif /* _NO_EXTENSIONS */
-
-               case WM_SETFOCUS:
-                       if (SetCurrentDirectory(child->path))
-                               set_space_status();
-                       SetFocus(child->focus_pane? child->right.hwnd: child->left.hwnd);
-                       break;
-
-               case WM_DISPATCH_COMMAND: {
-                       Pane* pane = GetFocus()==child->left.hwnd? &child->left: &child->right;
-
-                       switch(LOWORD(wparam)) {
-                               case ID_WINDOW_NEW: {
-                                       ChildWnd* new_child = alloc_child_window(child->path, NULL, hwnd);
-
-                                       if (!create_child_window(new_child))
-                                               free(new_child);
-
-                                       break;}
-
-                               case ID_REFRESH:
-                                       refresh_drives();
-                                       refresh_child(child);
-                                       break;
-
-                               case ID_ACTIVATE:
-                                       activate_entry(child, pane, hwnd);
-                                       break;
-
-                               case ID_FILE_MOVE: {
-                                       TCHAR source[BUFFER_LEN], target[BUFFER_LEN];
-
-                                       if (prompt_target(pane, source, target)) {
-                                               SHFILEOPSTRUCT shfo = {hwnd, FO_MOVE, source, target};
-
-                                               source[lstrlen(source)+1] = '\0';
-                                               target[lstrlen(target)+1] = '\0';
-
-                                               if (!SHFileOperation(&shfo))
-                                                       refresh_child(child);
-                                       }
-                                       break;}
-
-                               case ID_FILE_COPY: {
-                                       TCHAR source[BUFFER_LEN], target[BUFFER_LEN];
-
-                                       if (prompt_target(pane, source, target)) {
-                                               SHFILEOPSTRUCT shfo = {hwnd, FO_COPY, source, target};
-
-                                               source[lstrlen(source)+1] = '\0';
-                                               target[lstrlen(target)+1] = '\0';
-
-                                               if (!SHFileOperation(&shfo))
-                                                       refresh_child(child);
-                                       }
-                                       break;}
-
-                               case ID_FILE_DELETE: {
-                                       TCHAR path[BUFFER_LEN];
-                                       SHFILEOPSTRUCT shfo = {hwnd, FO_DELETE, path};
-
-                                       get_path(pane->cur, path);
-
-                                       path[lstrlen(path)+1] = '\0';
-
-                                       if (!SHFileOperation(&shfo))
-                                               refresh_child(child);
-                                       break;}
-
-                               case ID_VIEW_SORT_NAME:
-                                       set_sort_order(child, SORT_NAME);
-                                       break;
-
-                               case ID_VIEW_SORT_TYPE:
-                                       set_sort_order(child, SORT_EXT);
-                                       break;
-
-                               case ID_VIEW_SORT_SIZE:
-                                       set_sort_order(child, SORT_SIZE);
-                                       break;
-
-                               case ID_VIEW_SORT_DATE:
-                                       set_sort_order(child, SORT_DATE);
-                                       break;
-
-                               case ID_VIEW_FILTER: {
-                                       struct FilterDialog dlg;
-
-                                       memset(&dlg, 0, sizeof(struct FilterDialog));
-                                       lstrcpy(dlg.pattern, child->filter_pattern);
-                                       dlg.flags = child->filter_flags;
-
-                                       if (DialogBoxParam(Globals.hInstance, MAKEINTRESOURCE(IDD_DIALOG_VIEW_TYPE), hwnd, FilterDialogDlgProc, (LPARAM)&dlg) == IDOK) {
-                                               lstrcpy(child->filter_pattern, dlg.pattern);
-                                               child->filter_flags = dlg.flags;
-                                               refresh_right_pane(child);
-                                       }
-                                       break;}
-
-                               case ID_VIEW_SPLIT: {
-                                       last_split = child->split_pos;
-#ifdef _NO_EXTENSIONS
-                                       draw_splitbar(hwnd, last_split);
-#endif
-                                       SetCapture(hwnd);
-                                       break;}
-
-                               case ID_EDIT_PROPERTIES:
-                                       show_properties_dlg(pane->cur, child->hwnd);
-                                       break;
-
-                               default:
-                                       return pane_command(pane, LOWORD(wparam));
-                       }
-
-                       return TRUE;}
-
-               case WM_COMMAND: {
-                       Pane* pane = GetFocus()==child->left.hwnd? &child->left: &child->right;
-
-                       switch(HIWORD(wparam)) {
-                               case LBN_SELCHANGE: {
-                                       int idx = ListBox_GetCurSel(pane->hwnd);
-                                       Entry* entry = (Entry*) ListBox_GetItemData(pane->hwnd, idx);
-
-                                       if (pane == &child->left)
-                                               set_curdir(child, entry, idx, hwnd);
-                                       else
-                                               pane->cur = entry;
-                                       break;}
-
-                               case LBN_DBLCLK:
-                                       activate_entry(child, pane, hwnd);
-                                       break;
-                       }
-                       break;}
-
-#ifndef _NO_EXTENSIONS
-               case WM_NOTIFY: {
-                       NMHDR* pnmh = (NMHDR*) lparam;
-                       return pane_notify(pnmh->idFrom==IDW_HEADER_LEFT? &child->left: &child->right, pnmh);}
-#endif
-
-#ifdef _SHELL_FOLDERS
-               case WM_CONTEXTMENU: {
-                       POINT pt, pt_clnt;
-                       Pane* pane;
-                       int idx;
-
-                        /* first select the current item in the listbox */
-                       HWND hpanel = (HWND) wparam;
-                       pt_clnt.x = pt.x = (short)LOWORD(lparam);
-                       pt_clnt.y = pt.y = (short)HIWORD(lparam);
-                       ScreenToClient(hpanel, &pt_clnt);
-                       SendMessage(hpanel, WM_LBUTTONDOWN, 0, MAKELONG(pt_clnt.x, pt_clnt.y));
-                       SendMessage(hpanel, WM_LBUTTONUP, 0, MAKELONG(pt_clnt.x, pt_clnt.y));
-
-                        /* now create the popup menu using shell namespace and IContextMenu */
-                       pane = GetFocus()==child->left.hwnd? &child->left: &child->right;
-                       idx = ListBox_GetCurSel(pane->hwnd);
-
-                       if (idx != -1) {
-                               Entry* entry = (Entry*) ListBox_GetItemData(pane->hwnd, idx);
-
-                               LPITEMIDLIST pidl_abs = get_to_absolute_pidl(entry, hwnd);
-
-                               if (pidl_abs) {
-                                       IShellFolder* parentFolder;
-                                       LPCITEMIDLIST pidlLast;
-
-                                        /* get and use the parent folder to display correct context menu in all cases */
-                                       if (SUCCEEDED(SHBindToParent(pidl_abs, &IID_IShellFolder, (LPVOID*)&parentFolder, &pidlLast))) {
-                                               if (ShellFolderContextMenu(parentFolder, hwnd, 1, &pidlLast, pt.x, pt.y) == S_OK)
-                                                       refresh_child(child);
-
-                                               IShellFolder_Release(parentFolder);
-                                       }
-
-                                       IMalloc_Free(Globals.iMalloc, pidl_abs);
-                               }
-                       }
-                       break;}
-#endif
-
-                 case WM_MEASUREITEM:
-                 draw_menu_item:
-                       if (!wparam)    /* Is the message menu-related? */
-                               if (CtxMenu_HandleMenuMsg(nmsg, wparam, lparam))
-                                       return TRUE;
-
-                       break;
-
-                 case WM_INITMENUPOPUP:
-                       if (CtxMenu_HandleMenuMsg(nmsg, wparam, lparam))
-                               return 0;
-
-                       update_view_menu(child);
-                       break;
-
-#ifndef __MINGW32__    /* IContextMenu3 missing in MinGW (as of 6.2.2005) */
-                 case WM_MENUCHAR:     /* only supported by IContextMenu3 */
-                  if (s_pctxmenu3) {
-                          LRESULT lResult = 0;
-
-                          (*s_pctxmenu3->lpVtbl->HandleMenuMsg2)(s_pctxmenu3, nmsg, wparam, lparam, &lResult);
-
-                          return lResult;
-                  }
-
-                  break;
-#endif
-
-               case WM_SIZE:
-                       if (wparam != SIZE_MINIMIZED)
-                               resize_tree(child, LOWORD(lparam), HIWORD(lparam));
-                       /* fall through */
-
-               default: def:
-                       return DefMDIChildProc(hwnd, nmsg, wparam, lparam);
-       }
-
-       return 0;
-}
-
-
-static LRESULT CALLBACK TreeWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
-{
-       ChildWnd* child = (ChildWnd*) GetWindowLongPtr(GetParent(hwnd), GWLP_USERDATA);
-       Pane* pane = (Pane*) GetWindowLongPtr(hwnd, GWLP_USERDATA);
-       ASSERT(child);
-
-       switch(nmsg) {
-#ifndef _NO_EXTENSIONS
-               case WM_HSCROLL:
-                       set_header(pane);
-                       break;
-#endif
-
-               case WM_SETFOCUS:
-                       child->focus_pane = pane==&child->right? 1: 0;
-                       ListBox_SetSel(hwnd, TRUE, 1);
-                       /*TODO: check menu items */
-                       break;
-
-               case WM_KEYDOWN:
-                       if (wparam == VK_TAB) {
-                               /*TODO: SetFocus(Globals.hdrivebar) */
-                               SetFocus(child->focus_pane? child->left.hwnd: child->right.hwnd);
-                       }
-       }
-
-       return CallWindowProc(g_orgTreeWndProc, hwnd, nmsg, wparam, lparam);
-}
-
-
-static void InitInstance(HINSTANCE hinstance)
-{
-       const static TCHAR sFont[] = {'M','i','c','r','o','s','o','f','t',' ','S','a','n','s',' ','S','e','r','i','f','\0'};
-
-       WNDCLASSEX wcFrame;
-       WNDCLASS wcChild;
-       ATOM hChildClass;
-       int col;
-
-       INITCOMMONCONTROLSEX icc = {
-               sizeof(INITCOMMONCONTROLSEX),
-               ICC_BAR_CLASSES
-       };
-
-       HDC hdc = GetDC(0);
-
-       setlocale(LC_COLLATE, "");      /* set collating rules to local settings for compareName */
-
-       InitCommonControlsEx(&icc);
-
-
-       /* register frame window class */
-
-       wcFrame.cbSize        = sizeof(WNDCLASSEX);
-       wcFrame.style         = 0;
-       wcFrame.lpfnWndProc   = FrameWndProc;
-       wcFrame.cbClsExtra    = 0;
-       wcFrame.cbWndExtra    = 0;
-       wcFrame.hInstance     = hinstance;
-       wcFrame.hIcon         = LoadIcon(hinstance, MAKEINTRESOURCE(IDI_WINEFILE));
-       wcFrame.hCursor       = LoadCursor(0, IDC_ARROW);
-       wcFrame.hbrBackground = 0;
-       wcFrame.lpszMenuName  = 0;
-       wcFrame.lpszClassName = sWINEFILEFRAME;
-       wcFrame.hIconSm       = (HICON)LoadImage(hinstance,
-                                                                                        MAKEINTRESOURCE(IDI_WINEFILE),
-                                                                                        IMAGE_ICON,
-                                                                                        GetSystemMetrics(SM_CXSMICON),
-                                                                                        GetSystemMetrics(SM_CYSMICON),
-                                                                                        LR_SHARED);
-
-       Globals.hframeClass = RegisterClassEx(&wcFrame);
-
-
-       /* register tree windows class */
-
-       wcChild.style         = CS_CLASSDC|CS_DBLCLKS|CS_VREDRAW;
-       wcChild.lpfnWndProc   = ChildWndProc;
-       wcChild.cbClsExtra    = 0;
-       wcChild.cbWndExtra    = 0;
-       wcChild.hInstance     = hinstance;
-       wcChild.hIcon         = 0;
-       wcChild.hCursor       = LoadCursor(0, IDC_ARROW);
-       wcChild.hbrBackground = 0;
-       wcChild.lpszMenuName  = 0;
-       wcChild.lpszClassName = sWINEFILETREE;
-
-       hChildClass = RegisterClass(&wcChild);
-
-
-       Globals.haccel = LoadAccelerators(hinstance, MAKEINTRESOURCE(IDA_WINEFILE));
-
-       Globals.hfont = CreateFont(-MulDiv(8,GetDeviceCaps(hdc,LOGPIXELSY),72), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, sFont);
-
-       ReleaseDC(0, hdc);
-
-       Globals.hInstance = hinstance;
-
-#ifdef _SHELL_FOLDERS
-       CoInitialize(NULL);
-       CoGetMalloc(MEMCTX_TASK, &Globals.iMalloc);
-       SHGetDesktopFolder(&Globals.iDesktop);
-#ifdef __WINE__
-       Globals.cfStrFName = RegisterClipboardFormatA(CFSTR_FILENAME);
-#else
-       Globals.cfStrFName = RegisterClipboardFormat(CFSTR_FILENAME);
-#endif
-#endif
-
-       /* load column strings */
-       col = 1;
-
-       load_string(g_pos_names[col++], IDS_COL_NAME);
-       load_string(g_pos_names[col++], IDS_COL_SIZE);
-       load_string(g_pos_names[col++], IDS_COL_CDATE);
-#ifndef _NO_EXTENSIONS
-       load_string(g_pos_names[col++], IDS_COL_ADATE);
-       load_string(g_pos_names[col++], IDS_COL_MDATE);
-       load_string(g_pos_names[col++], IDS_COL_IDX);
-       load_string(g_pos_names[col++], IDS_COL_LINKS);
-#endif
-       load_string(g_pos_names[col++], IDS_COL_ATTR);
-#ifndef _NO_EXTENSIONS
-       load_string(g_pos_names[col++], IDS_COL_SEC);
-#endif
-}
-
-
-static void show_frame(HWND hwndParent, int cmdshow, LPCTSTR path)
-{
-       const static TCHAR sMDICLIENT[] = {'M','D','I','C','L','I','E','N','T','\0'};
-
-       TCHAR buffer[MAX_PATH], b1[BUFFER_LEN];
-       ChildWnd* child;
-       HMENU hMenuFrame, hMenuWindow;
-
-       CLIENTCREATESTRUCT ccs;
-
-       if (Globals.hMainWnd)
-               return;
-
-       hMenuFrame = LoadMenu(Globals.hInstance, MAKEINTRESOURCE(IDM_WINEFILE));
-       hMenuWindow = GetSubMenu(hMenuFrame, GetMenuItemCount(hMenuFrame)-2);
-
-       Globals.hMenuFrame = hMenuFrame;
-       Globals.hMenuView = GetSubMenu(hMenuFrame, 3);
-       Globals.hMenuOptions = GetSubMenu(hMenuFrame, 4);
-
-       ccs.hWindowMenu  = hMenuWindow;
-       ccs.idFirstChild = IDW_FIRST_CHILD;
-
-
-       /* create main window */
-       Globals.hMainWnd = CreateWindowEx(0, (LPCTSTR)(int)Globals.hframeClass, RS(b1,IDS_WINE_FILE), WS_OVERLAPPEDWINDOW,
-                                       CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT,
-                                       hwndParent, Globals.hMenuFrame, Globals.hInstance, 0/*lpParam*/);
-
-
-       Globals.hmdiclient = CreateWindowEx(0, sMDICLIENT, NULL,
-                                       WS_CHILD|WS_CLIPCHILDREN|WS_VSCROLL|WS_HSCROLL|WS_VISIBLE|WS_BORDER,
-                                       0, 0, 0, 0,
-                                       Globals.hMainWnd, 0, Globals.hInstance, &ccs);
-
-
-       CheckMenuItem(Globals.hMenuOptions, ID_VIEW_DRIVE_BAR, MF_BYCOMMAND|MF_CHECKED);
-
-       create_drive_bar();
-
-       {
-               TBBUTTON toolbarBtns[] = {
-                       {0, 0, 0, BTNS_SEP, {0, 0}, 0, 0},
-                       {0, ID_WINDOW_NEW, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-                       {1, ID_WINDOW_CASCADE, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-                       {2, ID_WINDOW_TILE_HORZ, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-                       {3, ID_WINDOW_TILE_VERT, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-/*TODO
-                       {4, ID_... , TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-                       {5, ID_... , TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0},
-*/             };
-
-               Globals.htoolbar = CreateToolbarEx(Globals.hMainWnd, WS_CHILD|WS_VISIBLE,
-                       IDW_TOOLBAR, 2, Globals.hInstance, IDB_TOOLBAR, toolbarBtns,
-                       sizeof(toolbarBtns)/sizeof(TBBUTTON), 16, 15, 16, 15, sizeof(TBBUTTON));
-               CheckMenuItem(Globals.hMenuOptions, ID_VIEW_TOOL_BAR, MF_BYCOMMAND|MF_CHECKED);
-       }
-
-       Globals.hstatusbar = CreateStatusWindow(WS_CHILD|WS_VISIBLE, 0, Globals.hMainWnd, IDW_STATUSBAR);
-       CheckMenuItem(Globals.hMenuOptions, ID_VIEW_STATUSBAR, MF_BYCOMMAND|MF_CHECKED);
-
-/* CreateStatusWindow does not accept WS_BORDER
-       Globals.hstatusbar = CreateWindowEx(WS_EX_NOPARENTNOTIFY, STATUSCLASSNAME, 0,
-                                       WS_CHILD|WS_VISIBLE|WS_CLIPSIBLINGS|WS_BORDER|CCS_NODIVIDER, 0,0,0,0,
-                                       Globals.hMainWnd, (HMENU)IDW_STATUSBAR, hinstance, 0);*/
-
-       /*TODO: read paths and window placements from registry */
-
-       if (!path || !*path) {
-               GetCurrentDirectory(MAX_PATH, buffer);
-               path = buffer;
-       }
-
-       ShowWindow(Globals.hMainWnd, cmdshow);
-
-//#if defined(_SHELL_FOLDERS) && !defined(__WINE__)
-//      // Shell Namespace as default:
-//     child = alloc_child_window(path, get_path_pidl(path,Globals.hMainWnd), Globals.hMainWnd);
-//#else
-       child = alloc_child_window(path, NULL, Globals.hMainWnd);
-//#endif
-
-       child->pos.showCmd = SW_SHOWMAXIMIZED;
-       child->pos.rcNormalPosition.left = 0;
-       child->pos.rcNormalPosition.top = 0;
-       child->pos.rcNormalPosition.right = 320;
-       child->pos.rcNormalPosition.bottom = 280;
-
-       if (!create_child_window(child))
-               free(child);
-
-       SetWindowPlacement(child->hwnd, &child->pos);
-
-       Globals.himl = ImageList_LoadBitmap(Globals.hInstance, MAKEINTRESOURCE(IDB_IMAGES), 16, 0, RGB(0,255,0));
-
-       Globals.prescan_node = FALSE;
-
-       UpdateWindow(Globals.hMainWnd);
-}
-
-static void ExitInstance(void)
-{
-#ifdef _SHELL_FOLDERS
-       IShellFolder_Release(Globals.iDesktop);
-       IMalloc_Release(Globals.iMalloc);
-       CoUninitialize();
-#endif
-
-       DeleteObject(Globals.hfont);
-       ImageList_Destroy(Globals.himl);
-}
-
-#ifdef _NO_EXTENSIONS
-
-/* search for already running win[e]files */
-
-static int g_foundPrevInstance = 0;
-
-static BOOL CALLBACK EnumWndProc(HWND hwnd, LPARAM lparam)
-{
-       TCHAR cls[128];
-
-       GetClassName(hwnd, cls, 128);
-
-       if (!lstrcmp(cls, (LPCTSTR)lparam)) {
-               g_foundPrevInstance++;
-               return FALSE;
-       }
-
-       return TRUE;
-}
-
-/* search for window of given class name to allow only one running instance */
-static int find_window_class(LPCTSTR classname)
-{
-       EnumWindows(EnumWndProc, (LPARAM)classname);
-
-       if (g_foundPrevInstance)
-               return 1;
-
-       return 0;
-}
-
-#endif
-
-static int winefile_main(HINSTANCE hinstance, int cmdshow, LPCTSTR path)
-{
-       MSG msg;
-
-       InitInstance(hinstance);
-
-       if (cmdshow == SW_SHOWNORMAL)
-               /*TODO: read window placement from registry */
-               cmdshow = SW_MAXIMIZE;
-
-       show_frame(0, cmdshow, path);
-
-       while(GetMessage(&msg, 0, 0, 0)) {
-               if (Globals.hmdiclient && TranslateMDISysAccel(Globals.hmdiclient, &msg))
-                       continue;
-
-               if (Globals.hMainWnd && TranslateAccelerator(Globals.hMainWnd, Globals.haccel, &msg))
-                       continue;
-
-               TranslateMessage(&msg);
-               DispatchMessage(&msg);
-       }
-
-       ExitInstance();
-
-       return msg.wParam;
-}
-
-
-#if defined(UNICODE) && defined(_MSC_VER)
-int APIENTRY wWinMain(HINSTANCE hinstance, HINSTANCE previnstance, LPWSTR cmdline, int cmdshow)
-#else
-int APIENTRY WinMain(HINSTANCE hinstance, HINSTANCE previnstance, LPSTR cmdline, int cmdshow)
-#endif
-{
-#ifdef _NO_EXTENSIONS
-       if (find_window_class(sWINEFILEFRAME))
-               return 1;
-#endif
-
-#if defined(UNICODE) && !defined(_MSC_VER)
-       { /* convert ANSI cmdline into WCS path string */
-       TCHAR buffer[MAX_PATH];
-       MultiByteToWideChar(CP_ACP, 0, cmdline, -1, buffer, MAX_PATH);
-       winefile_main(hinstance, cmdshow, buffer);
-       }
-#else
-       winefile_main(hinstance, cmdshow, cmdline);
-#endif
-
-       return 0;
-}
diff --git a/reactos/subsys/system/winefile/winefile.dsp b/reactos/subsys/system/winefile/winefile.dsp
deleted file mode 100644 (file)
index d595d14..0000000
+++ /dev/null
@@ -1,274 +0,0 @@
-# Microsoft Developer Studio Project File - Name="winefile" - Package Owner=<4>\r
-# Microsoft Developer Studio Generated Build File, Format Version 6.00\r
-# ** DO NOT EDIT **\r
-\r
-# TARGTYPE "Win32 (x86) Application" 0x0101\r
-\r
-CFG=winefile - Win32 Unicode Debug\r
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,\r
-!MESSAGE use the Export Makefile command and run\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "winefile.mak".\r
-!MESSAGE \r
-!MESSAGE You can specify a configuration when running NMAKE\r
-!MESSAGE by defining the macro CFG on the command line. For example:\r
-!MESSAGE \r
-!MESSAGE NMAKE /f "winefile.mak" CFG="winefile - Win32 Unicode Debug"\r
-!MESSAGE \r
-!MESSAGE Possible choices for configuration are:\r
-!MESSAGE \r
-!MESSAGE "winefile - Win32 Debug" (based on "Win32 (x86) Application")\r
-!MESSAGE "winefile - Win32 Unicode Debug" (based on "Win32 (x86) Application")\r
-!MESSAGE "winefile - Win32 UNICODE Release" (based on "Win32 (x86) Application")\r
-!MESSAGE "winefile - Win32 Release" (based on "Win32 (x86) Application")\r
-!MESSAGE \r
-\r
-# Begin Project\r
-# PROP AllowPerConfigDependencies 0\r
-# PROP Scc_ProjName ""\r
-# PROP Scc_LocalPath ""\r
-CPP=cl.exe\r
-MTL=midl.exe\r
-RSC=rc.exe\r
-\r
-!IF  "$(CFG)" == "winefile - Win32 Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Debug"\r
-# PROP BASE Intermediate_Dir "Debug"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "winefileDebug"\r
-# PROP Intermediate_Dir "winefileDebug"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c\r
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D _WIN32_WINNT=0x0501 /FR /FD /GZ /c\r
-# SUBTRACT CPP /YX\r
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32\r
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /i ".." /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib comdlg32.lib ole32.lib version.lib mpr.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept\r
-\r
-!ELSEIF  "$(CFG)" == "winefile - Win32 Unicode Debug"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 1\r
-# PROP BASE Output_Dir "Unicode Debug"\r
-# PROP BASE Intermediate_Dir "Unicode Debug"\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 1\r
-# PROP Output_Dir "winefileUDebug"\r
-# PROP Intermediate_Dir "winefileUDebug"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /FR /YX /FD /GZ /c\r
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "UNICODE" /D _WIN32_WINNT=0x0501 /FR /FD /GZ /c\r
-# SUBTRACT CPP /YX\r
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32\r
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32\r
-# ADD BASE RSC /l 0x407 /d "_DEBUG"\r
-# ADD RSC /l 0x407 /i ".." /d "_DEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept\r
-# ADD LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib comdlg32.lib ole32.lib version.lib mpr.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept\r
-\r
-!ELSEIF  "$(CFG)" == "winefile - Win32 UNICODE Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "winefile___Win32_UNICODE_Release"\r
-# PROP BASE Intermediate_Dir "winefile___Win32_UNICODE_Release"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "winefileURelease"\r
-# PROP Intermediate_Dir "winefileURelease"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c\r
-# ADD CPP /nologo /MD /W3 /GX /O2 /D "NDEBUG" /D "UNICODE" /D _WIN32_WINNT=0x0501 /FD /c\r
-# SUBTRACT CPP /YX\r
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32\r
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /i ".." /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib comdlg32.lib /nologo /subsystem:windows /machine:I386\r
-# ADD LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib comdlg32.lib ole32.lib version.lib mpr.lib /nologo /subsystem:windows /machine:I386\r
-\r
-!ELSEIF  "$(CFG)" == "winefile - Win32 Release"\r
-\r
-# PROP BASE Use_MFC 0\r
-# PROP BASE Use_Debug_Libraries 0\r
-# PROP BASE Output_Dir "winefile___Win32_Release"\r
-# PROP BASE Intermediate_Dir "winefile___Win32_Release"\r
-# PROP BASE Ignore_Export_Lib 0\r
-# PROP BASE Target_Dir ""\r
-# PROP Use_MFC 0\r
-# PROP Use_Debug_Libraries 0\r
-# PROP Output_Dir "winefileRelease"\r
-# PROP Intermediate_Dir "winefileRelease"\r
-# PROP Ignore_Export_Lib 0\r
-# PROP Target_Dir ""\r
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "NDEBUG" /D "UNICODE" /D WINE_UNUSED= /YX /FD /c\r
-# ADD CPP /nologo /MD /W3 /GX /O2 /D "NDEBUG" /D _WIN32_WINNT=0x0501 /FD /c\r
-# SUBTRACT CPP /YX\r
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32\r
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32\r
-# ADD BASE RSC /l 0x407 /d "NDEBUG"\r
-# ADD RSC /l 0x407 /i ".." /d "NDEBUG"\r
-BSC32=bscmake.exe\r
-# ADD BASE BSC32 /nologo\r
-# ADD BSC32 /nologo\r
-LINK32=link.exe\r
-# ADD BASE LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib comdlg32.lib /nologo /subsystem:windows /machine:I386\r
-# ADD LINK32 user32.lib gdi32.lib advapi32.lib comctl32.lib shell32.lib comdlg32.lib ole32.lib version.lib mpr.lib /nologo /subsystem:windows /machine:I386 /out:"winefileRelease/winefile-ansi.exe"\r
-\r
-!ENDIF \r
-\r
-# Begin Target\r
-\r
-# Name "winefile - Win32 Debug"\r
-# Name "winefile - Win32 Unicode Debug"\r
-# Name "winefile - Win32 UNICODE Release"\r
-# Name "winefile - Win32 Release"\r
-# Begin Group "Resources"\r
-\r
-# PROP Default_Filter ""\r
-# Begin Source File\r
-\r
-SOURCE=.\cs.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\de.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\drivebar.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\en.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\es.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\fr.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\hu.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\images.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\it.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\nl.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\pl.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\pt.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\resource.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\ru.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\si.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\Sv.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\toolbar.bmp\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\winefile.ico\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\winefile.rc\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\zh.rc\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# End Group\r
-# Begin Source File\r
-\r
-SOURCE=.\license.c\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\resource.h\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\splitpath.c\r
-# PROP Exclude_From_Build 1\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\winefile.c\r
-# End Source File\r
-# Begin Source File\r
-\r
-SOURCE=.\winefile.h\r
-# End Source File\r
-# End Target\r
-# End Project\r
diff --git a/reactos/subsys/system/winefile/winefile.dsw b/reactos/subsys/system/winefile/winefile.dsw
deleted file mode 100644 (file)
index 7fff73d..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-Microsoft Developer Studio Workspace File, Format Version 6.00\r
-# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!\r
-\r
-###############################################################################\r
-\r
-Project: "make_explorer"=.\make_winefile.dsp - Package Owner=<4>\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<4>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
-Project: "winefile"=.\winefile.dsp - Package Owner=<4>\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<4>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
-Global:\r
-\r
-Package=<5>\r
-{{{\r
-}}}\r
-\r
-Package=<3>\r
-{{{\r
-}}}\r
-\r
-###############################################################################\r
-\r
diff --git a/reactos/subsys/system/winefile/winefile.h b/reactos/subsys/system/winefile/winefile.h
deleted file mode 100644 (file)
index 8c0df5b..0000000
+++ /dev/null
@@ -1,170 +0,0 @@
-/*
- * Copyright 2000, 2003, 2004, 2005 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-#define WIN32_LEAN_AND_MEAN
-#define WIN32_EXTRA_LEAN
-#define NOSERVICE
-#define NOMCX
-#define NOIME
-#define NOCOMM
-#define NOKANJI
-#define NORPC
-#define NOPROXYSTUB
-#define NOIMAGE
-#define NOTAPE
-
-#define NONAMELESSUNION
-#include <windows.h>
-#include <windowsx.h>
-#include <commctrl.h>
-#include <commdlg.h>
-
-#ifdef UNICODE
-#define _UNICODE
-#endif
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <ctype.h>
-#include <locale.h>
-#include <time.h>
-
-#ifndef __WINE__
-#include <malloc.h> /* for alloca() */
-
- // ugly hack to use alloca() while keeping Wine's developers happy
-#define HeapAlloc(h,f,s) alloca(s)
-#define HeapFree(h,f,p)
-#endif
-
-#include <shellapi.h>   /* for ShellExecute() */
-#include <shlobj.h>     /* for SHFormatDrive() */
-
-#ifndef _NO_EXTENSIONS
-#define _SHELL_FOLDERS
-#endif /* _NO_EXTENSIONS */
-
-#ifndef FILE_ATTRIBUTE_NOT_CONTENT_INDEXED
-#define FILE_ATTRIBUTE_ENCRYPTED            0x00000040
-#define FILE_ATTRIBUTE_SPARSE_FILE          0x00000200
-#define FILE_ATTRIBUTE_REPARSE_POINT        0x00000400
-#define FILE_ATTRIBUTE_NOT_CONTENT_INDEXED  0x00002000
-#endif
-
-
-#ifdef  _DEBUG
-#define ASSERT(x)   {if (!(x)) DebugBreak();}
-#else
-#define ASSERT(x)   /* nothing */
-#endif
-
-#define BUFFER_LEN  1024
-
-
-enum IMAGE {
-    IMG_NONE=-1,    IMG_FILE=0,         IMG_DOCUMENT,   IMG_EXECUTABLE,
-    IMG_FOLDER,     IMG_OPEN_FOLDER,    IMG_FOLDER_PLUS,IMG_OPEN_PLUS,  IMG_OPEN_MINUS,
-    IMG_FOLDER_UP,  IMG_FOLDER_CUR
-};
-
-#define IMAGE_WIDTH         16
-#define IMAGE_HEIGHT        13
-#define SPLIT_WIDTH         5
-#define TREE_LINE_DX        3
-
-#define IDW_STATUSBAR       0x100
-#define IDW_TOOLBAR         0x101
-#define IDW_DRIVEBAR        0x102
-#define IDW_FIRST_CHILD     0xC000  /*0x200*/
-
-#define IDW_TREE_LEFT       3
-#define IDW_TREE_RIGHT      6
-#define IDW_HEADER_LEFT     2
-#define IDW_HEADER_RIGHT    5
-
-#define WM_DISPATCH_COMMAND 0xBF80
-
-#define COLOR_COMPRESSED    RGB(0,0,255)
-#define COLOR_SELECTION     RGB(0,0,128)
-#define COLOR_SELECTION_TXT RGB(255,255,255)
-
-#ifdef _NO_EXTENSIONS
-#define COLOR_SPLITBAR      WHITE_BRUSH
-#else
-#define COLOR_SPLITBAR      LTGRAY_BRUSH
-#endif
-
-#define FRM_CALC_CLIENT     0xBF83
-#define Frame_CalcFrameClient(hwnd, prt) ((BOOL)SNDMSG(hwnd, FRM_CALC_CLIENT, 0, (LPARAM)(PRECT)prt))
-
-
-typedef struct
-{
-  HANDLE    hInstance;
-  HACCEL    haccel;
-  ATOM      hframeClass;
-
-  HWND      hMainWnd;
-  HMENU     hMenuFrame;
-  HMENU     hWindowsMenu;
-  HMENU     hLanguageMenu;
-  HMENU     hMenuView;
-  HMENU     hMenuOptions;
-  HWND      hmdiclient;
-  HWND      hstatusbar;
-  HWND      htoolbar;
-  HWND      hdrivebar;
-  HFONT     hfont;
-
-  TCHAR     num_sep;
-  SIZE      spaceSize;
-  HIMAGELIST himl;
-
-  TCHAR     drives[BUFFER_LEN];
-  BOOL      prescan_node;   /*TODO*/
-
-#ifdef _SHELL_FOLDERS
-  IShellFolder* iDesktop;
-  IMalloc*      iMalloc;
-  UINT          cfStrFName;
-#endif
-} WINEFILE_GLOBALS;
-
-extern WINEFILE_GLOBALS Globals;
-
-#ifdef __WINE__
-
-extern void WineLicense(HWND hwnd);
-extern void WineWarranty(HWND hwnd);
-
-
-#ifdef UNICODE
-extern void _wsplitpath(const WCHAR* path, WCHAR* drv, WCHAR* dir, WCHAR* name, WCHAR* ext);
-#define _tsplitpath _wsplitpath
-#define _stprintf msvcrt_swprintf
-#else
-extern void _splitpath(const CHAR* path, CHAR* drv, CHAR* dir, CHAR* name, CHAR* ext);
-#define _tsplitpath _splitpath
-#define _stprintf sprintf
-#endif
-
-#else
-
-#include <tchar.h>     /* for _tsplitpath() */
-
-#endif
diff --git a/reactos/subsys/system/winefile/winefile.ico b/reactos/subsys/system/winefile/winefile.ico
deleted file mode 100644 (file)
index 3c7fd13..0000000
Binary files a/reactos/subsys/system/winefile/winefile.ico and /dev/null differ
diff --git a/reactos/subsys/system/winefile/winefile.rc b/reactos/subsys/system/winefile/winefile.rc
deleted file mode 100644 (file)
index d4cbc8e..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright 2000 Martin Fuchs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-#include "windows.h"
-#include "resource.h"
-
-/* define language neutral resources */
-
-LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
-
-#include "resource.rc"
-
-/* include localised resources */
-
-#include "en.rc"
-#include "cs.rc"
-#include "de.rc"
-#include "es.rc"
-#include "fr.rc"
-#include "hu.rc"
-#include "it.rc"
-#include "nl.rc"
-#include "pl.rc"
-#include "pt.rc"
-#include "ru.rc"
-#include "si.rc"
-#include "zh.rc"
-#include "Sv.rc"
-
diff --git a/reactos/subsys/system/winefile/winefile.xml b/reactos/subsys/system/winefile/winefile.xml
deleted file mode 100644 (file)
index bdb9c08..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-<module name="winefile" type="win32gui"  installbase="system32" installname="winefile.exe" allowwarnings="true">
-       <include base="winefile">.</include>
-       <define name="UNICODE" />
-       <define name="__USE_W32API" />
-       <define name="_WIN32_IE">0x0501</define>
-       <define name="_WIN32_WINNT">0x0501</define>
-       <library>uuid</library>
-       <library>kernel32</library>
-       <library>gdi32</library>
-       <library>user32</library>
-       <library>comctl32</library>
-       <library>comdlg32</library>
-       <library>shell32</library>
-       <library>ole32</library>
-       <library>version</library>
-       <library>mpr</library>
-       <file>winefile.c</file>
-       <file>winefile.rc</file>
-</module>
diff --git a/reactos/subsys/system/winefile/zh.rc b/reactos/subsys/system/winefile/zh.rc
deleted file mode 100644 (file)
index d68cd5e..0000000
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- * WineFile
- * Simplified Chinese Language Support
- *
- * Copyright 2002 liuspider <liuspider@yahoo.com>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED
-
-/* Menu */
-
-IDM_WINEFILE MENU FIXED IMPURE
-{
-    POPUP "Îļþ£¨&F£©"  {
-        MENUITEM "´ò¿ª£¨&O£©\tEnter",           ID_ACTIVATE
-        MENUITEM "Òƶ¯£¨&M£©...\tF7",           ID_FILE_MOVE
-        MENUITEM "¸´ÖÆ£¨&C£©...\tF8",           ID_FILE_COPY
-        MENUITEM "λÓÚ¼ôÌù°å£¨&I£©...\tF9",     118
-        MENUITEM "ɾ³ý£¨&D£©\tDel",             ID_FILE_DELETE
-        MENUITEM "¸ÄÃû£¨&N£©...",               109
-        MENUITEM "ÊôÐÔ£¨&I£©...\tAlt+Enter",    ID_EDIT_PROPERTIES
-        MENUITEM SEPARATOR
-        MENUITEM "ѹËõ£¨&O£©...",               119
-        MENUITEM "½âѹËõ£¨&O£©...",             120
-        MENUITEM SEPARATOR
-        MENUITEM "ÔËÐУ¨&R£©...",               ID_EXECUTE
-        MENUITEM "´òÓ¡£¨&P£©...",               102
-        MENUITEM "ÅäÖÃÎļþÏà¹Ø...",             103
-        MENUITEM SEPARATOR
-        MENUITEM "½¨Á¢Ä¿Â¼£¨&E£©...",           111
-        MENUITEM "²éÕÒ£¨&H£©...",               104
-        MENUITEM "Ñ¡ÔñÎļþ£¨&S£©...",           116
-        MENUITEM SEPARATOR
-#ifndef _NO_EXTENSIONS
-        MENUITEM "Í˳ö£¨&X£©\tAlt+X",           ID_FILE_EXIT
-#else
-        MENUITEM "Í˳ö£¨&X£©",                  ID_FILE_EXIT
-#endif
-    }
-
-    POPUP "´ÅÅÌ£¨&D£©"  {
-        MENUITEM "¸´ÖÆ£¨&C£©...",               201
-        MENUITEM "ÃüÃû£¨&L£©...",               202
-        MENUITEM SEPARATOR
-        MENUITEM "¸ñʽ»¯£¨&£©...",              ID_FORMAT_DISK
-#ifdef _WIN95
-        MENUITEM "½¨Á¢ÏµÍ³ÅÌ£¨&M£©...", -1  /*TODO*/
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "Á¬½ÓÍøÂçÇý¶¯Æ÷£¨&N£©",        ID_CONNECT_NETWORK_DRIVE
-        MENUITEM "¶Ï¿ªÍøÂçÇý¶¯Æ÷Á¬½Ó£¨&D£©",    ID_DISCONNECT_NETWORK_DRIVE
-        MENUITEM SEPARATOR
-        MENUITEM "¹²ÏíΪ...",                   254
-        MENUITEM "ɾ³ý¹²Ïí£¨&R£©...",           255
-        MENUITEM SEPARATOR
-        MENUITEM "Ñ¡ÔñÇý¶¯Æ÷£¨&S£©...",         251
-    }
-
-    POPUP "Ŀ¼£¨&D£©"  {
-        MENUITEM "ÏÂÒ»²ã£¨&N£©\t+",             301
-        MENUITEM "Õ¹¿ª£¨&T£©\t*",               302
-        MENUITEM "È«²¿Õ¹¿ª£¨&A£©\tStrg+*",      303
-        MENUITEM "ÕÛµþ£¨&R£©\t-",               304
-        MENUITEM SEPARATOR
-        MENUITEM "±ê¼Ç×ÓĿ¼£¨&M£©",            505
-    }
-
-    POPUP "ÊÓͼ£¨&V£©"  {
-        MENUITEM "Ŀ¼Ê÷»úÆ÷ÄÚÈÝ£¨&R£©",        413
-        MENUITEM "½öÏÔʾĿ¼Ê÷£¨&E£©",          411
-        MENUITEM "½öÏÔʾĿ¼ÄÚÈÝ£¨&O£©",        412
-        MENUITEM SEPARATOR
-        MENUITEM "·Ö¸î£¨&L£©",                  ID_VIEW_SPLIT
-        MENUITEM SEPARATOR
-        MENUITEM "ÎļþÃûÃû£¨&N£©",              ID_VIEW_NAME
-        MENUITEM "ÎļþÏêϤÁÐ±í£¨&A£©",          ID_VIEW_ALL_ATTRIBUTES, CHECKED
-        MENUITEM "²¿·ÖÊôÐÔ£¨&P£©...",           ID_VIEW_SELECTED_ATTRIBUTES
-        MENUITEM SEPARATOR
-        MENUITEM "°´ÎļþÃûÅÅÐò£¨&S£©",          ID_VIEW_SORT_NAME
-        MENUITEM "°´ÀàÐÍÅÅÐò£¨&B£©",            ID_VIEW_SORT_TYPE
-        MENUITEM "°´´óСÅÅÐò£¨&Z£©",            ID_VIEW_SORT_SIZE
-        MENUITEM "°´ÈÕÆÚÅÅÐò£¨&D£©",            ID_VIEW_SORT_DATE
-        MENUITEM SEPARATOR
-        MENUITEM "¶¨ÖÆÅÅÐò...",                 ID_VIEW_FILTER
-    }
-
-    POPUP "Ñ¡Ï&O£©"  {
-        MENUITEM "È·¶¨·½Ê½£¨&C£©...",           501
-        MENUITEM "×ÖÌ壨&F£©...",               ID_SELECT_FONT
-        MENUITEM "¶¨Öƹ¤¾ßÌõ£¨&B£©...",         512
-        MENUITEM SEPARATOR
-        MENUITEM "¹¤¾ßÌõ£¨&T£©",                ID_VIEW_TOOL_BAR, CHECKED
-        MENUITEM "Çý¶¯Æ÷ÁÐ±í£¨&D£©",            ID_VIEW_DRIVE_BAR, CHECKED
-        MENUITEM "״̬À¸£¨&S£©",                ID_VIEW_STATUSBAR, CHECKED
-#ifndef _NO_EXTENSIONS
-        MENUITEM "È«ÆÁ£¨&U£©\tCtrl+Shift+S",    ID_VIEW_FULLSCREEN
-#endif
-        MENUITEM SEPARATOR
-        MENUITEM "&Minimize on run",            504
-        MENUITEM "&Save settings on exit",      511
-    }
-
-
-    POPUP "°²È«£¨&S£©"  {
-        MENUITEM "·ÃÎÊ£¨&A£©...",               605
-        MENUITEM "µÇ¼£¨&L£©...",               606
-        MENUITEM "ËùÓÐÕߣ¨&O£©...",             607
-    }
-
-    POPUP "´°¿Ú£¨&W£©"  {
-        MENUITEM "н¨£¨&W)",                   ID_WINDOW_NEW
-        MENUITEM "²ãµþ\tCtrl+F5",               ID_WINDOW_CASCADE
-        MENUITEM "ˮƽƽÆÌ£¨&H£©",              ID_WINDOW_TILE_HORZ
-        MENUITEM "´¹Ö±Æ½ÆÌ£¨&£©\tCtrl+F4",      ID_WINDOW_TILE_VERT
-#ifndef _NO_EXTENSIONS
-        MENUITEM "×Ô¶¯ÅÅÁÐ",                    ID_WINDOW_AUTOSORT
-#endif
-        MENUITEM "×Ô¶¯ÅÅÁÐͼ±ê£¨&S£©",          ID_WINDOW_ARRANGE
-        MENUITEM "ˢУ¨&R£©\tF5",              ID_REFRESH
-    }
-
-    POPUP "&?"  {
-        MENUITEM "°ïÖúÖ÷Ì⣨&H£©\tF1",          ID_HELP
-        MENUITEM "ËÑË÷°ïÖú£¨&S£©...\tF1",       ID_HELP
-        MENUITEM "ʹÓðïÖú£¨&U£©\tF1",          ID_HELP_USING
-        MENUITEM SEPARATOR
-        MENUITEM "&¹ØÓÚ Winefile...",           ID_ABOUT
-#ifdef __WINE__
-        MENUITEM "¹ØÓÚ &Wine...",               ID_ABOUT_WINE
-#endif
-    }
-}
-
-
-IDD_EXECUTE DIALOG FIXED IMPURE 15, 13, 210, 63
-STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
-CAPTION "ÔËÐÐ"
-FONT 8, "MS Shell Dlg"
-{
-    CONTROL         "", 101, "Static", SS_SIMPLE|SS_NOPREFIX, 3, 6, 162, 10
-    CONTROL         "ÃüÁ&C£©£º", -1, "Static", SS_LEFTNOWORDWRAP|WS_GROUP, 3, 18, 60, 10
-    EDITTEXT        201, 3, 29, 134, 12, ES_AUTOHSCROLL
-    CONTROL         "×÷ΪÁ¬½Ó£¨&S£©", 214, "Button", BS_AUTOCHECKBOX|WS_TABSTOP,3, 45, 71, 12
-    DEFPUSHBUTTON   "È·¶¨", 1, 158, 6, 47, 14
-    PUSHBUTTON      "È¡Ïû", 2, 158, 23, 47, 14
-    PUSHBUTTON      "°ïÖú£¨&H£©", 254, 158, 43, 47, 14
-}